Welcome!
This is the community forum for my apps Pythonista and Editorial.
For individual support questions, you can also send an email. If you have a very short question or just want to say hello — I'm @olemoritz on Twitter.
How do I make arrows fly in a new arc?
-
Hi guys,
I'm building a game with the scene module,
and I figured out how to make sprites move in a straight line. Does anyone know if I can also make them move in an arc, like an arrow? And can I make a sprite move at a fixed speed, so that it doesn't move to a certain point in 5 seconds, but that it moves at a speed of 500px/second? Because action.run_action(move_to, x, y, time) has both of these issuesThanks :)
Drizzel -
You basically have to implement a physics system with a gravity component.
Here is a simple example. Change the initial velocity to change angle of arc.
https://gist.github.com/563cf7498dda79c3ca824b12a9103e5a