class ContinueButton : Button { override fun begin() { val countdown = Game.instance.scene.findActorByName( "countdown" ).role as Countdown if (countdown.score <= countdown.requiredSeconds) { actor.die() } if ( ! Game.instance.resources.sceneExists( Play.instance.nextScene ) ) { TickleErrorHandler.instance.warn( "Continue Button : scene not found : ${Play.instance.nextScene}" ) actor.die() } } override fun onClicked( event : MouseEvent ) { Game.instance.startScene( Play.instance.nextScene ) } }