title: Resetting object in java
body: <p>I'm working on an Android Game. Entire gameplay is in "Gameplay" class. The problem is when i want to have start again option and i have no idea how to remove "mg" object from "Gameplay" class and make a new one. Here is my code:</p>
  
  <pre><code>package com.PJA.game;
  
  import com.badlogic.gdx.Gdx;
  import com.badlogic.gdx.graphics.g2d.SpriteBatch;
  
  public class GameScreen extends BaseScreen {
      static short state=1;
      Gameplay mg;
      Menu mm;
      LostScreen ls;
      public GameScreen(Gra game) {
          super(game);
          mm=new Menu();
          mg=new Gameplay();
          ls=new LostScreen();
      }
  
      public void update() {
          if(state==1)    mm.live();
          if(state==2)    mg.live();
          if(state==3)    ls.live();
  
          Gdx.app.log("CurrentState: ", Integer.toString(state));
      }
  
      public void drau(SpriteBatch sb) {
          if(state==1)    mm.show(sb);
          if(state==2)    mg.show(sb);    
          if(state==3)    ls.show(sb);
      }
  }
  </code></pre>