Alice Community  

Go Back   Alice Community > Alice 2 > How do I...?

Reply
 
Thread Tools Display Modes
Help with assignment Plz
Old
Deekayone
Guest
 
Status:
Posts: n/a
Default Help with assignment Plz - 09-15-2010, 04:30 PM

My instructor was absent, and the substitute had no clue. I am totally lost on how to complete this. Specifically how to:


Create a world that contains any object that contains a turn method. When the
world first begins, ask the user for the number of times they want the object to
spin. If that number is less than 10, then use the turn method to spin the object
that number of times.
If the number is 10 or more, the object should say
“Spinning more than 10 times makes me sick!”.
   
Reply With Quote
Old
debussybunny563
Senior Member
 
debussybunny563's Avatar
 
Status: Offline
Posts: 852
Join Date: May 2010
Arrow 09-15-2010, 05:08 PM

I got an example.

If you have any questions, don't hesitate to ask.
Attached Files
File Type: a2w help1.a2w (341.0 KB, 7 views)


Last edited by debussybunny563; 12-21-2012 at 12:00 AM.

|--------------------------------------------------------------------------------------------------|
|Link to weapons collection: http://www.alice.org/community/showthread.php?t=7368 |
|--------------------------------------------------------------------------------------------------|

I have been dead for quite some time now; not much hope for resurrection.
   
Reply With Quote
Old
Deekayone
Guest
 
Status:
Posts: n/a
Default 09-15-2010, 07:15 PM

Thank you for you example. It helps alot.

Here is what i have done. Still not correct, i cannot figure out the process to get the number of revolutions nor the world turns methods that you created. Any other help would be much appreciated.
Attached Files
File Type: a2w Problem III.a2w (171.5 KB, 5 views)
   
Reply With Quote
Old
debussybunny563
Senior Member
 
debussybunny563's Avatar
 
Status: Offline
Posts: 852
Join Date: May 2010
Arrow 09-15-2010, 07:24 PM

OK, got it.

There are comments in the code.
The separate turn method was unnecessary, so I put it directly in the "my first method."

EDIT: Oh wow, I'm so dumb. Forgot the attachment!
Anyway, here you go.
Attached Files
File Type: a2w Problem III.a2w (176.6 KB, 3 views)


Last edited by debussybunny563; 12-21-2012 at 12:00 AM.

|--------------------------------------------------------------------------------------------------|
|Link to weapons collection: http://www.alice.org/community/showthread.php?t=7368 |
|--------------------------------------------------------------------------------------------------|

I have been dead for quite some time now; not much hope for resurrection.

Last edited by debussybunny563; 09-15-2010 at 09:05 PM.
   
Reply With Quote
Old
Deekayone
Guest
 
Status:
Posts: n/a
Default 09-15-2010, 08:37 PM

Got it! Thx again for your help
   
Reply With Quote
Old
debussybunny563
Senior Member
 
debussybunny563's Avatar
 
Status: Offline
Posts: 852
Join Date: May 2010
Thumbs up 09-15-2010, 08:38 PM

You're welcome.

Come back if you have any problems or would like to share a world of your own.


Last edited by debussybunny563; 12-21-2012 at 12:00 AM.

|--------------------------------------------------------------------------------------------------|
|Link to weapons collection: http://www.alice.org/community/showthread.php?t=7368 |
|--------------------------------------------------------------------------------------------------|

I have been dead for quite some time now; not much hope for resurrection.
   
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.