gamelayer with bugs fixed