move game logic to level class and add attack event in game