#### Archived

This topic is now archived and is closed to further replies.

# Arrow Formula

This topic is 5970 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

## Recommended Posts

I would like to make a formula for a flying arrow that goes up and down, based on the gravity and angle of shooting. X is the horizontal position and y is the vertical of the screen. Can any of you help me? I will use it for a isometric game. Thanx, Bernardo Heynemann Gehenna Project Developer Veni, Vidi, Vici (Julius Caesar)

##### Share on other sites
The horizontal velocity will remain constant. Given the verticle velocity and gravity (Lets just say it equals -10.), the arrows current velocity = it''s last velocity + gravity, and it''s new postion equals it''s last position + (horizontal velocity,vertical velocity)

##### Share on other sites
Arrow, ball... same thing. Due to the relative sizes of the objects involved in the physical simulation, we consider all these objects as particles and manipulate them as such. In other words, there's an answer to your question just a few posts down, in a thread called "Ball physics" or so.

[Edit: The thread's actually called Ball in a football game.]

[ GDNet Start Here | GDNet Search Tool | GDNet FAQ | MS RTFM [MSDN] | SGI STL Docs | Google! ]
Thanks to Kylotan for the idea!

[edited by - Oluseyi on March 18, 2002 10:19:10 PM]

##### Share on other sites
In the absence of air resistance or any other retarding forces, then the motion of the arrow is given by the equations of projectile motion . The path of the arrow is given by:
                              gy = (tan  theta0)x - ------------   x2                    2(v0cos  theta0)2

Alternatively, if you want this expressed in terms of vertical and horizontal velicities, then

vy = v0sin theta0 - gt
vx = v0cos theta0

If you'd like to know the range of the arrow, that is given by:
    v02R = --- sin  (2theta0)     g

where:
v0: initial speed of arrow
theta0: firing angle (from horizontal)
g: gravitational acceleration
t: time
x: horizontal displacement from firing point
y: vertical displacement from firing point

I hope this helps!

Timkin

[edited by - Timkin on March 18, 2002 10:42:57 PM]

##### Share on other sites
Thank u all for the help!
Sure it does help!

That´s good to see that people are still willing to help each other!

Thanx again,
Bernardo Heynemann
Gehenna Project Developer

Veni, Vidi, Vici
(Julius Caesar)

1. 1
2. 2
Rutin
22
3. 3
4. 4
JoeJ
17
5. 5

• 14
• 30
• 13
• 11
• 11
• ### Forum Statistics

• Total Topics
631774
• Total Posts
3002297
×