Editing a question Because I have no longer privileges to Ask One.
So I have a Game Name Space XD: where
Game(main) class -> run()(gameloop)|-> render(gui) -> handler.render()(all Gameobjects render)
|-> tick() -> handler.tick()(all Gameobjects tick)
lets imagine a condition where player is in level 3 And on user input i want the game state the same as it was when player was in level two like points decreased, health at that particular moment etc..
I tried one solution
if(level == 3){
this.game = previous_game; // i define previous_game = this.game; when level was 2. But nothing changed.
this.handler = handler; // same as up;
this.HUD = HUD;// heads of display but nothing was changed except i saw a black screen i thing because the background is black(background is black) please help i dont see any answers of this.
}
Please Help!