PDA

View Full Version : Game problem


Silent Adonis
06-20-2011, 03:31 AM
Hey There
I have a game that Im doing about a wolf and a bunny. Its very short and simple but there is one part that Im struggling with and have not been able to do. The bunny is always in his hole and when the world starts he moves down the hole automatically .35 of a meter. the wolf then moves using the arrows as events and when he gets 4 meters directly in front of the bunny, the bunny should move down .5 of a meter. then when the wolf is at a safe distance the bunny should move back up to .35 when the wolf is 4 meters away from him. The wolf sneaks behind the bunny and eats him which I have done but I cant get the move down and move up part to work. the bunny just keeps going down and down and down when I press the up arrow to move forward. I hope it makes sense.

any help would be awesome thanks

room14
06-20-2011, 03:33 AM
post the world. that will help.

Silent Adonis
06-20-2011, 03:35 AM
5049

Silent Adonis
06-20-2011, 03:39 AM
I cant use variables, loops, user written functions or method parameters. I can only use ‘when the world starts’ and ‘when a key is pressed/typed.

room14
06-20-2011, 03:41 AM
umm.. you have not connected the bunny's method to the events section

Silent Adonis
06-20-2011, 03:46 AM
Yeah I took it out.

It looked like this though.

Method Bunny Down.

If both (wolfs foot) distance to (bunny's whiskers) < 4 and (Wolfs foot) is in front of (bunnys Whiskers)

Then, Bunny Move down .5

else
do nothing.

The bunny Up was similiar of course.

Cheers

room14
06-20-2011, 03:47 AM
that means that the world does not play the method.

room14
06-20-2011, 03:49 AM
okay so you are not allowed to use loop? but are you allowed to use the while world is running?

Silent Adonis
06-20-2011, 03:51 AM
Yeah I took it out on purpose haha sorry I should of kept there.

The world first can be used but not loops.

Silent Adonis
06-20-2011, 06:46 AM
I have tried everything I was told, its so frustrating! thanks heaps for your help. Let me know if you have any ideas.


Thanks

legolizard
06-20-2011, 08:48 AM
Can you use the "When something becomes true" event?

Silent Adonis
06-21-2011, 02:13 AM
Unfortunately not, All I can use is when the world starts and up down left right

room14
06-22-2011, 02:18 AM
I know how to loop it without using a loop method.(cos' you need to for your if to work.)
goto the end of the if else method and add your method inside the mthod

Silent Adonis
06-22-2011, 05:43 PM
So which if statement should I put where? Do you mean put the bunny goes down and up on the same statement?


Cheers Man

room14
06-23-2011, 12:39 AM
okay go to the method and do:

Silent Adonis
06-23-2011, 02:43 AM
Hey Mate
Thanks for that but i couldn't get it to work for some reason.

Not to worry Ill try something else.

Cheers

room14
06-23-2011, 04:48 AM
oh yeah the third step. link it to the events section.:)

room14
06-23-2011, 04:49 AM
oh my god... the picture....

arty-fishL
06-23-2011, 11:54 AM
okay go to the method and do:I thought you came from New Zealand, why the Japanese (or similar language) windows setup?

room14
06-23-2011, 02:36 PM
Yes i am from New Zealand. But I have a Japanese set up because I have a Japanese windows XP. because I came from Japan.

I bought (actually It was completely Free!:D) the machine in New Zealand but they forgot to give us the activation key so i just used the Japanese one that was lying in the cupboard gathering dust.:p

If you look carefully, you can see my name....

reuben2011
06-23-2011, 09:17 PM
Hideaki Murakami?

room14
06-24-2011, 02:08 AM
yes that's my name.

arty-fishL
06-24-2011, 08:29 PM
Yes i am from New Zealand. But I have a Japanese set up because I have a Japanese windows XP. because I came from Japan.

I bought (actually It was completely Free!:D) the machine in New Zealand but they forgot to give us the activation key so i just used the Japanese one that was lying in the cupboard gathering dust.:p

If you look carefully, you can see my name....I just presumed you were completely from New Zealand, not that it really makes a difference, you're still the same person.

I'm not just Scottish. I was born in Scotland. My Dad is Scottish, his mum is also. His Dad is Polish. His partner - Spanish. My Mum (or Mom) is English, her Mum is Irish. Her Dad is English.

I am: Scottish-Scottish-Scottish-Polish-(Spanish)-English-Irish-English