title: libGDX Classes relationship
body: <p>I am trying Libgdx Game Class to make a game.And I am following a book.There is an example. Example has 4 classes and 1 DesktopLauncher. DesktopLauncher use StarfishCollector3() class to main function.  Despite I dont call create method and render method which are in GameBeta abstract class to StarfishCollector3, the project is working.Can you explain what I dont know.</p>
  <pre><code>    class StarfishCollector3 : GameBeta() {
      var turtle:Turtle=null
      var starfish:ActorBeta=null
      var ocean:ActorBeta=null
      var winMessage:ActorBeta=null
      var win:Boolean = true
  
      override fun initialize() {
          ocean= ActorBeta()
          ocean.setTexture(Texture( Gdx.files.internal(&quot;water.jpg&quot;)  ))
          mainStage.addActor(ocean)
  
          starfish = ActorBeta();
          starfish.setTexture(Texture(Gdx.files.internal(&quot;starfish.png&quot;)) );
          starfish.setPosition( 380F,380F );
          mainStage.addActor( starfish );
  
          turtle = Turtle()
          turtle.setTexture( Texture(Gdx.files.internal(&quot;turtle-1.png&quot;)) )
          turtle.setPosition( 20F,20F )
          mainStage.addActor( turtle )
  
          winMessage = ActorBeta();
          winMessage.setTexture( Texture(Gdx.files.internal(&quot;you-win.png&quot;)) );
          winMessage.setPosition( 180F,180F );
          winMessage.setVisible( false );
          mainStage.addActor( winMessage );
          win = false }
  
      override fun update(dt: Float) {
          if (turtle.overlaps(starfish as ActorBeta)){
              starfish.remove()
              winMessage.setVisible(true)} }
  }
  abstract class GameBeta: Game() {
      protected var mainStage: Stage=null
     
   abstract  fun initialize()
      
  override fun create() {`
          mainStage = Stage()
          initialize() }
  
      abstract  fun update(dt:Float)
      .
      override fun render() {
          var dt= Gdx.graphics.getDeltaTime()
          mainStage.act()
          update(dt)  
          Gdx.gl.glClearColor(0F,0F,0F,1F)
          Gdx.gl.glClear(GL20.GL_COLOR_BUFFER_BIT)
          mainStage.draw()
      }
  }
  
  
  
  
  
  
  
  
  
   
  </code></pre>