Hundreds of features to explore
Games made in Construct
Your questions answered
Popular & trusted by schools and Universities world-wide
Construct 3 runs in the browser & works offline
Students do not need accounts with us
Our educational partners
Free education resources to use in the classroom
World class complete documentation
Official and community submitted guides
Learn and share with other game developers
Upload and play games from the Construct community
Game development stories & opinions
So I'm making a sonic fan game where you're cream the rabbit and you have to find her pet chao "cheese" behind one of the bushes in each level. I was just wondering how I would make the chao end up behind a diffferent Bush each time you boot up the game. Would you use the random instance or what?
This is easy. Try this:
system condition: "Pick random instance" (bush)
Chao command: "set position to another object" (bush)
Than you only need to add the move to object command.
Event--->System/pick random BUSH instance
Action--->CHEESE/ (Here is where you can try a few things out that are available and see what works for you. Remember you can use an expression like BUSH.X to get the BUSH's x position and BUSH.Y to get y position.)
Sounds super simple! I saw the pick random instance expression the other day and wondered when ill be using it.
I just tried it and the chao ended up being behind every single Bush, not just one.
It's looping cos you haven't set any restrictions on it Add a Trigger Once, or make it a sub-event of "On start of layout"
Develop games in your browser. Powerful, performant & highly capable.
i've run into another problem; I also want bombs to appear if you pick the wrong bush. How do I choose random bushes with more than 1 bomb?