
07-06-2006, 01:43 AM
|
Scriptess
|
 |
Join Date: Aug 2003
Location: asmgarden.gmap
Posts: 606
|
|
I've puzzled over this for awhile and eventually gave up.
At the time I didn't -need- it (was making a flak cannon-like thing on Archaic. instead of picking 7 xy's and doing it from there, i just did random angles and speeds)
though, you could do a getangle to find the xy angle. that's the easy one.
with the z angle, there's a whole line of possibilities - different zangles and different speeds.
you could find working zangle and speeds using trial-and-error and testing to see if the distance works out (and possibly limit your search to a certain range of angles or speeds to make the result look decent) with a formula somewhat like this pseudo-code one:
projectile_distance=projectile_speed*ticks_before_ impact
you could find ticks with the cosine of the zangle times projectile speed and divide that by your gravity (since its a static reduction)
somewhat like that would work (though i bet i confused you even more with that)
now go get some advil for your [new] headache. |
__________________
|
|
|