Alice Community Need assistance Chapter 3 Execise 7. Snowman to Stool

 Need assistance Chapter 3 Execise 7. Snowman to Stool
kjobrien
Guest

Status:
Posts: n/a
Need assistance Chapter 3 Execise 7. Snowman to Stool - 06-23-2010, 02:09 PM

7. Snowman to Stool
This eexecise uses a number function as the count for a Loop. Create a world with a snowman and a stool, as seen below. Use a Loop to make the snowman (People) move to the Stool (Kitchen), one meter at a time. Use a distance to function to determine the number of times the loop repeats. (The distance to function might return a fractional distance such as 3.75 meters. The Loop statement truncates the fractional number to the interger 3 and will repeat three times.) We recomend that you test your solution by moving the snowman and the stool to diffrent locations on the screen and running the origram with each change, so you can know wheather it works no matter where the snowman and the stool are located.

This world is what I have to far I know how to change the number of time the loop is executed what I dont know how to do is make is stop when the snowman gets within a certian distance to the stool I have tried drgging in diffrent functions and tried makeing some more compicated loop nothing I do works please help Thank you all so much
Attached Files
 7. Snowman to Stool.a2w (173.4 KB, 73 views)

 x2495iiii Super Moderator     Status: Offline Posts: 3,508 Join Date: Dec 2008 Location: Somewhere in the Continental U.S. 06-23-2010, 04:21 PM Ah. Click the snowman to select it, then click the functions tab. The third available function, "snowman distance to" is the one you need.
 Tanks but one more thing
kjobrien
Guest

Status:
Posts: n/a
Tanks but one more thing - 06-23-2010, 04:30 PM

The example says I have to use a loop in my solution, so I added one I included the updated one how do I make the snow man stop short to avoid the colision in there with that loop now? Thanks for your help
Attached Files
 7. Snowman to Stoolv2Loop.a2w (166.5 KB, 89 views)

 x2495iiii Super Moderator     Status: Offline Posts: 3,508 Join Date: Dec 2008 Location: Somewhere in the Continental U.S. 06-23-2010, 05:11 PM That's a problem of center points. Try substituting stool's width + snowman's width for the number 1 in your loop.
 Thanks
 kjobrien Guest   Status: Posts: n/a Thanks - 06-23-2010, 07:56 PM I was trying to was but unsuscessful trying to drop those funtions into the spot where the 1 was for the number or f loops. Now that thanks to you alll I nkow know I can drop stuff in there and it makes alot more sensce thanks

 Thread Tools Display Modes Linear Mode

 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 Rules
 Forum Jump User Control Panel Private Messages Subscriptions Who's Online Search Forums Forums Home Announcements     Community News and Announcements Alice 3     How Do I?     Works In Progress     Share Your World     Share Custom Classes     Bugs and Trouble Shooting     Suggestion Box Alice 2     How do I...?     Works-In-Progress     Share Worlds     Share Objects     Bugs and Troubleshooting     Suggestion Box Educators     Teaching with Alice     Teaching Using Alice 3     Teaching Using Alice 2     CS Principles and Alice     AP CSA and Intro to Java and Alice     Workshops General Discussion     Questions and Comments     The Lounge