Alice Community  

Go Back   Alice Community > Alice 2 > Works-In-Progress

Reply
 
Thread Tools Display Modes
Hi debussybunny563
Old
medinra
Guest
 
Status:
Posts: n/a
Exclamation Hi debussybunny563 - 10-15-2010, 07:14 PM

I am currently trying to achieve the same thing as Tommy and I watch your example , but it's does the spinning and jumping together and I have to do them with different amount. At the beggining it needs to ask which height i want the astrounaut to jump and the in should ask how many spins? . Based on what the user enters thats the amount the animation will do. I am really lost.
   
Reply With Quote
Old
Doctor Who
Guest
 
Status:
Posts: n/a
Default 10-15-2010, 07:18 PM

Go to World -> Functions -> Ask User For Number. You can invent you own code from there.
   
Reply With Quote
thanks
Old
medinra
Guest
 
Status:
Posts: n/a
Default thanks - 10-15-2010, 07:34 PM

thanks for the help,but this is what I am coming up with and is not working.

Last edited by medinra; 10-19-2010 at 02:27 PM.
   
Reply With Quote
Old
medinra
Guest
 
Status:
Posts: n/a
Exclamation 10-15-2010, 08:11 PM

can someone help me????
   
Reply With Quote
Old
Dameria
Senior Member
 
Dameria's Avatar
 
Status: Offline
Posts: 976
Join Date: Sep 2009
Location: United States
Default 10-15-2010, 08:54 PM

I saw what you did with all of the fancy animations that didn't work, and decided to just delete all of it. I started from scratch and made a really simple code that does the bare basics. If you want you can edit it so that there is more animation, like his legs moving to prepare for the jump, etc. Didn't want to do the whole project for you so just did the basics so you can see how it is done as simply as possible.
Attached Files
File Type: a2w my astronaut (1).a2w (843.7 KB, 117 views)


Check out my best projects so far and please comment:

Tic-Tac-Toe 2.0 ................... http://www.alice.org/community/showthread.php?t=3548
Alice Paint ........................... http://www.alice.org/community/showthread.php?p=23408
Real-Time Clock .................. http://www.alice.org/community/showthread.php?p=12725
Maze Game ......................... http://www.alice.org/community/showthread.php?t=4301

Last edited by Dameria; 11-15-2012 at 01:37 PM.
   
Reply With Quote
Awesome
Old
medinra
Guest
 
Status:
Posts: n/a
Exclamation Awesome - 10-15-2010, 10:54 PM

Dameria you are really good, thanks for helping with these issue. What you did was really good. Just wanted to ask you, if I wanted for the astronaut to first jump and then do the spinning while it's already in the air, how can I achieve that?? thank you very much for your quick help.
   
Reply With Quote
Old
jediaction
Senior Member
 
jediaction's Avatar
 
Status: Offline
Posts: 5,064
Join Date: Jul 2009
Location: Bel Air, Maryland
Default 10-16-2010, 08:38 AM

You can just put a turn 1 revolution. Or are you saying, just the first jump. I would do a variable with 1 or 0 or true or false. I would use 1 or 0 for this. Make the game start with the number 1. Then add the spin system in a true or false and say if you press the space bar or any button that is jump, make the variable for the spinning number go to 0 and it wont spin anymore because it will be reading the If/else and it should be blank


Website: www.salokingames.com
FaceBook: www.facebook.com/SalokinGames
   
Reply With Quote
Old
Dameria
Senior Member
 
Dameria's Avatar
 
Status: Offline
Posts: 976
Join Date: Sep 2009
Location: United States
Default 10-16-2010, 09:16 AM

Quote:
Originally Posted by medinra View Post
Dameria you are really good, thanks for helping with these issue. What you did was really good. Just wanted to ask you, if I wanted for the astronaut to first jump and then do the spinning while it's already in the air, how can I achieve that?? thank you very much for your quick help.
Like this?
Attached Files
File Type: a2w my astronaut (2).a2w (825.1 KB, 80 views)


Check out my best projects so far and please comment:

Tic-Tac-Toe 2.0 ................... http://www.alice.org/community/showthread.php?t=3548
Alice Paint ........................... http://www.alice.org/community/showthread.php?p=23408
Real-Time Clock .................. http://www.alice.org/community/showthread.php?p=12725
Maze Game ......................... http://www.alice.org/community/showthread.php?t=4301
   
Reply With Quote
Excellent!!!!
Old
medinra
Guest
 
Status:
Posts: n/a
Thumbs up Excellent!!!! - 10-16-2010, 09:53 AM

Dameria that was exactly what I meant..... thank you very much for your help. Just out of curiosity, how did you achieved it? just to have a idea. Thanks I owe you one or a couple lol .
   
Reply With Quote
Old
Dameria
Senior Member
 
Dameria's Avatar
 
Status: Offline
Posts: 976
Join Date: Sep 2009
Location: United States
Default 10-16-2010, 09:57 AM

I had 2 world number variables named "height" and "spin", and in the beginning of "my first method" I asked the user to enter the height, and assigned that to the "height" variable. Then I did the same thing, asked the user to enter the amount of spins, and assigned that to the "spin" variable. Then I simply told the astronaut to move up, and in the amount of meters to move up I dragged the variable "height" in there. That way he moves up the amount of height you previously entered. Then while right after that statement I told the astronaut to turn to the right "spin" times, so that he spins the amount of times you previously entered for him to spin. Then I just made the astronaut move down "height" meters again so he went back to the ground.

I personally like the first way I did it, it looks more realistic, but this way is even easier and it is the correct way to do it from the assignment.


Check out my best projects so far and please comment:

Tic-Tac-Toe 2.0 ................... http://www.alice.org/community/showthread.php?t=3548
Alice Paint ........................... http://www.alice.org/community/showthread.php?p=23408
Real-Time Clock .................. http://www.alice.org/community/showthread.php?p=12725
Maze Game ......................... http://www.alice.org/community/showthread.php?t=4301
   
Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump



Copyright ©2024, Carnegie Mellon University
Alice 2.x © 1999-2012, Alice 3.x © 2008-2012, Carnegie Mellon University. All rights reserved.