View Single Post
Old
chickentree
Super Moderator
 
Status: Offline
Posts: 250
Join Date: Dec 2012
Location: Frosno, Ca
Default 07-12-2018, 05:58 PM

Quote:
Originally Posted by aprils1293 View Post
Hello guys,
Im trying to make a game called puttbull (similar to golf ) so wherever the ground is clicked on the baseball will go in that direction to go to the closest hole and then you score a certain amount of points.I have the timer made but I'm lost on how to make it actually work.Please help me if you can! thanks
You need to do a few things for this:
  1. Let the user determine which direction to hit the ball.
  2. Move in the desired direction some random amount. This assumes the user doesn't always get a whole in one.
  3. Test if the ball ended up in the hole.
I added a method to do this for the 3rd hole and an event that calls it if the 'S' key is pressed. You would need to do something similar for the other holes.

Mark
Attached Files
File Type: a2w putt_V2.a2w (577.1 KB, 3 views)


Mark Henwood
mhenwood@ieee.org
   
Reply With Quote