Tap To Move Help
kew709
Member Posts: 10
I am having a slight problem with a Tap To Move. I have the tap to move working well, however I need some help with making my object (actor) respond to only one tap at a time. I have an indicator spawn where the player tapped and then the actor moves to where the device is touched. I also have it so that the indicator spawns an invisible actor so that the moving actor still knows where to go after the indicator is gone. I need a way for my moving actor to go to only one point at a time. If you tap a different space before the moving actor gets to the original it goes there, and then stops. I need a way for it to go to the original spot and if the user taps the screen again while the moving actor is in motion nothing happens.
Any help would be awesome. Thanks
Any help would be awesome. Thanks
Comments
Then only allow a new point to be chosen when game.StillMoving is false.
New to GameSalad? (FAQs) | Tutorials | Templates | Greenleaf Games | Educator & Certified GameSalad User
when game movement = 1
move to ... position h (game.Touches.Touch 1.X)
position v (game. Touches.Touch 1.Y)
i also have a rotate but thats not important right now. To reset the game movement back to 0 or false I have it collide with an invisible actor when it gets to the point. However when the user touches it before going to the first point it goes to the other point which is not marked on the screen and the moving actor will go there instead of the original point and then not move anymore.
If it's still not making sense, consider posting a video of what is happening and/or a screenshot of your rules.
New to GameSalad? (FAQs) | Tutorials | Templates | Greenleaf Games | Educator & Certified GameSalad User
New to GameSalad? (FAQs) | Tutorials | Templates | Greenleaf Games | Educator & Certified GameSalad User
The only thing that doesn't work is if you click while the actor is moving and expect the actor to then move to that destination after it reaches its current destination.
But I'm not sure what you're intending...
New to GameSalad? (FAQs) | Tutorials | Templates | Greenleaf Games | Educator & Certified GameSalad User
(The Move To behavior uses game.destinationX and game.destinationY, both real attributes.)
New to GameSalad? (FAQs) | Tutorials | Templates | Greenleaf Games | Educator & Certified GameSalad User