Alice Community How to make a game work?
 User Name Remember Me? Password

 Thread Tools Display Modes
 How to make a game work?
 infowire Guest   Status: Posts: n/a How to make a game work? - 12-07-2009, 03:58 AM Hi, so i am making a game where a guy kicks a football through a goal post, my question is how can i make the football fly to different parts of the world like miss the goal post depending on when the user clicks a button, also how do i make a power meter for the kick power? I need the power meeter jump back and fourth and depending when the user clicks a button it determines the power and kicks at it and that determines the flight of the football.... I need some help to accomplish this. Thank You
 x2495iiii Super Moderator     Status: Offline Posts: 3,508 Join Date: Dec 2008 Location: Somewhere in the Continental U.S. 12-07-2009, 04:05 AM You'd need a variable which determines how much power the kick has, and a loop which keeps making the direction of the ball and the power of the kick vary with time. Go ahead and show me what YOU think the code would look like. I'll help you along from there. (')> Last edited by x2495iiii; 12-07-2009 at 03:27 PM.
 infowire Guest   Status: Posts: n/a 12-07-2009, 02:46 PM how do you make a vehicle? i just have a football object
 x2495iiii Super Moderator     Status: Offline Posts: 3,508 Join Date: Dec 2008 Location: Somewhere in the Continental U.S. 12-07-2009, 03:28 PM Vehicles are in the vehicles section of the objects gallery. Or did you mean 'variable?' (')>
 infowire Guest   Status: Posts: n/a 12-07-2009, 04:59 PM lol i dont know why i said vehice, i think i was reading a different post and replied to this one. anyways, what would you suggest to do to make the football fly based on when the user presses a button. I was thinking of making the arrows turn the kicker to get the angle and then a power meter so when the user presses a button depending on what power it is at it kicks the ball. Not quite sure how to do that in Alice, all the help would be appreciated. So maybe for the power of the kick i can make the guys foot bend back and forth somehow on a loop, but i' am not sure how that would generate me a number for the force of the kick.
 x2495iiii Super Moderator     Status: Offline Posts: 3,508 Join Date: Dec 2008 Location: Somewhere in the Continental U.S. 12-07-2009, 05:29 PM It wouldn't. You'd need to make your own number generation which moves at the same time as the football player's leg and goes up until it hits max power, then starts decrementing until it hits zero, and repeats. (')>

 Thread Tools Display Modes Hybrid 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     Alice Player and VR General Discussion     Questions and Comments     The Lounge

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

 Contact Us - Alice.org - Archive - Top