This site requires JavaScript, please enable it in your browser!
Greenfoot back
Heet_Patel
Heet_Patel wrote ...

2018/4/21

Start Button

Heet_Patel Heet_Patel

2018/4/21

#
Hi i actually want a game where it starts with the main menu and on the main menu i have a start button. I would like a code where once you click the start button it will switch to the second world. The first world is called Start, and the second world is called Water. The actor is called Start_Button
nolttr21 nolttr21

2018/4/21

#
in your Start_Button class you could write,
1
2
3
4
if(Greenfoot.mouseClicked(this))
{
Greenfoot.setWorld(new Water());
}
You need to login to post a reply.