I'm creating a cannon game.The rule is this when touch is released shoot cannon ball, but when i unpause my game the cannon ball gets shoot with out doing nothing.i dont know what is the problem.
Comments
SlickZeroHouston, TexasMember, Sous ChefPosts: 2,870
Possibly because when you unpause the game there is a "when touch is released" rule that registers?
The rule to shoot the ball is: When touch is released shoot ball. To pause is: When touch is released pause game. To unpause is: When touch is released unpause game.
tatiangMember, Sous Chef, PRO, Senior Sous-ChefPosts: 11,949
I can't really tell from what you wrote. I know it can be time-consuming to type out the full rules, so sometimes a screenshot or video is better. If you'd like to compress your project file into a .zip file, upload it to a file-sharing service and then send me a private message with a link to download it, I can help you more. Or you can post screenshots/video of the rules so it's clearer.
well, the rule to shoot the ball is when mouse button is up shoot the ball.To pause the game is when touch the pause actor is released pause the game. and lastly when touch the unpause actor is released unpause the game.But as i said when i unpause the game the ball shoots with out doing nothing.Thanks for answer.
tatiangMember, Sous Chef, PRO, Senior Sous-ChefPosts: 11,949
When Touch is Released is different from When Mouse Button is Up. Touch means that the actor was clicked/tapped, while Mouse means that the screen was clicked/tapped anywhere. The two conditions work on both a computer/website and a mobile device.
To fix your problem, change the rule to When Touch is Released. If you can't use Touch, then you may have to build in a timer that changes a boolean value (e.g. game.CanShoot) after a brief time after the Unpause action in order to prevent unintentional firing (twss).
Comments
To pause is: When touch is released pause game.
To unpause is: When touch is released unpause game.
To fix your problem, change the rule to When Touch is Released. If you can't use Touch, then you may have to build in a timer that changes a boolean value (e.g. game.CanShoot) after a brief time after the Unpause action in order to prevent unintentional firing (twss).