Pages: 1
Topic closed
how can you make it to where if your "money" is 0 to make it not let you do stuff that needs "money". but how??????
Offline
its so confuseing how can i make it like that?
Offline
Assuming that you have Money as a variable, then you need to test the amount of money before you let them do stuff. In the example below, it costs 2 units of money to get into the Movie Theater so I test Money to see if it is at least 2 and charge them 2 to get in. Then, I use a broadcast to tell some other sprites to get set up for watching the movie.
[blocks]
<if> <( money <>> 1.99 )>
<say[ Welcome to the Movie Theater! ]for( 2 )secs>
<change{ money }by( -2
<broadcast[ Watch the Movie
<else>
<say[ I'm Sorry, You don't have enough money! ]for( 2 )secs>
<end>
[/blocks]
Last edited by Paddle2See (2008-04-11 04:36:13)
Offline
Topic closed
Pages: 1