I am making games in greenfoot, and wanted to make a ingame shop spending points earned from playing, but I cant find out if it is possible to save the game state? Please help!


Greenfoot.setWorld(new ShopWorld(this));
// instance variable private World mainWorld; // constructor public ShopWorld(World world) { super(600, 400, 1); // whatever mainWorld = world; // other code } // when conditions are right to return Greenfoot.setWorld(mainWorld);