HELP! I SUCK! 2 hours and I still can't figure it out!
So here's a sample trigger I have when the unit jumps from the ground:
Oh, also I know about this standard parabola equation already:
But I decided not to use it cuz this doesn't quite work when I want the unit to jump without moving. Or the unit is just free falling (yes, I want gravity), due to the fact that it calculates the distance traveled.
I'm not exactly limited to just using my trigger I posted above (as I don't really know what I'm doing). If you know the math on how to do this better, PLEASE!
Just want to mention, I really, REALLY, suck at math! If you could just please give me the solution converted already to GUI/Jass/vJass script, or explain how without using fancy math words and symbols I would really appreciate it!!! I would prefer the former though, my head hurts already...
So here's a sample trigger I have when the unit jumps from the ground:
-
Set InitialVelocity = 100
-
Set InitialHeight = 0
-
Set InitialVelocity = 2*InitialVelocty + (Acceleration_Variable)*(Time_Variable)
-
Set InitialHeight = Player_Height
-
Set Player_Height = InitialVelocity * Time_Variable + 0.5 * (Acceleration_Variable) * (Time_Variable * Time_Variable) + InitialHeight
-
Animation - Change Footman's Height to Player_Height at rate 0.00
Oh, also I know about this standard parabola equation already:
JASS:
function Parabola takes real height, real current, real max returns real
return 4 * height * current * (max - current) / (max * max)
endfunction
I'm not exactly limited to just using my trigger I posted above (as I don't really know what I'm doing). If you know the math on how to do this better, PLEASE!
Just want to mention, I really, REALLY, suck at math! If you could just please give me the solution converted already to GUI/Jass/vJass script, or explain how without using fancy math words and symbols I would really appreciate it!!! I would prefer the former though, my head hurts already...