package game.actors.mainmenu;
import engine.geometry.Rectangle;
import engine.hierarchy.DefaultActor;
import game.habits.ClickHabit;
import game.scenes.FadeThroughBlackScene;
import game.scenes.OptionsScene;
public final class OptionsButtonActor extends DefaultActor implements ClickHabit.Listener {
private Rectangle bounds;
public OptionsButtonActor(final Rectangle bounds) {
this.bounds = bounds;
}
@Override
public void onAdd() {
addHabit(new ClickHabit(this, bounds));
}
@Override
public void onClick(final ClickHabit click) {
getStage().insertSceneAbove(new FadeThroughBlackScene(new OptionsScene()), getScene());
}
}