make pressing a button choose a random thing out of a list.

Apr 22, 2011 at 4:29pm
So I want a if(choice == 4) to randomly pick something out of a list

because I want to make a game where you press a button and it picks a random creature

To make the program pick a random creature, then run it, how would you do that?
Last edited on Apr 22, 2011 at 4:44pm
Apr 22, 2011 at 4:38pm
mewditto wrote:
So I want a if(choice == 4) to randomly pick something out of a list


if(choice == 4) isn't some sort of universal panacea, you'll have to use something else to do that.

mewditto wrote:
Wouldn't it be this:

What is this mysterious "it"?

You seriously need to organize your thoughts before starting to write something.
Last edited on Apr 22, 2011 at 4:39pm
Topic archived. No new replies allowed.