If you plan on making a Jump Ability, though, try looking at Missile Movers. Here's a mini tutorial that I'm just remembering off the top of my head. This is entirely in the Data Editor, but is pretty simple:
Open the Data Editor, and make your way into the Movers tab
Create new mover (by right clicking and selecting Add New Mover or something...)
Call it Jump Mover
Go to sub property of this mover called Motion Phases, and double click it.
There's a list at the top of this page that shows how many motion phases you have for the mover. We want to only have 1. Delete all extra Motion Phases if there are any extras.
After deleting the extras, select the one that you have left by highlighting it. Scroll a tiny bit down to where the drop down box is and change the Motion Type to Ballistics
There are only up to two properties on this window that you should look at. All the other ones are basically Irrelevant. The first one is Gravity. Gravity will determine how high the jump will go. Gravity at 10 will make for a short jump. Increase it to 100 and you'll have a higher jump.
The other two properties are Flight Time, or Speed. You can only pick one of these two, and should leave the other one at its default setting. If you specify the Flight Time, this will determine how long the jump lasts for, and the speed will be calculated automatically. If you set the Flight Time to 0.1 second, the unit will jump really fast, and reach its landing target within that time. If you increase it to 10 seconds, the unit will jump to its landing target much slower, perhaps giving the impression of a slow-motion jump.
If you leave Flight Time alone, and modify Speed, you will instead specify how fast the unit is going, and the Flight Time setting will be automatically calculated and irrelevant. Let's say your Unit is jumping to a very far away place. If you set the Speed setting to 1, it will take a very long time for the jump to be completed (slow-motion-esque). If you increase the speed, to say 15, the jump will happen much more fast and probably end up looking more realistic.
After we've completed the tutorial, and you've got the jump basically working, you can come back later and tweak these settings to get them right. Once you've set this up, all you have to do now are 3 more simple things: Create an Effect, Create an Ability, and Add the Ability to the unit.
To Create the Effect, in the Data Editor:
Open the Effects tab
Right click to Add New Effect (Type = Launch Missle)
Call the effect Jump
Once Created, set the Ammo Unit = None (if set to None, instead of launching a new ammo bullet unit, the Caster Unit itself is the ammo)
Also set the Impact Death Type = None (this will make the unit not die when he lands)
Set Target Location, or Impact Location = Target Point or something... I can't remember the name exactly. Should be easy to find.
Set the Mover = Jump Mover (the one we created earlier)
Now, in the Data Editor still, open the Abilities tab.
Right click to Add New Ability (Type = Effect - Target)
Name the Ability Jump
Set the Effect field to our Jump effect.
Now, set the Default Button up (with a picture and a hotkey, so that you can soon add it to your Unit's abilities).
You can name it too if you want, or you can come in later and change it after you've confirmed it has worked.
Now, lastly in the Data Editor, open the Units tab.
Go to the unit that you want to add Jumping to, and go into that unit's abilities.
Add the ability we made Jump to the list of the abilities the unit has.
Open the units Command Card and make sure you put a button for the ability on the grid there. If you don't see the ability in the list of possible abilities for the command card, that's because your Ability itself in the Abilities tab doesn't have the Default Button set up properly. It's annoying, but you have to do that step of setting up the Default Button in order to add the ability to a Unit's command card.
Now, give yourself a unit of that type, fire up the game, and see if when you use that ability and click a point on the ground, the Unit Jumps!
Great, thanks a lot! Really helpful. Would the parabola only look at the vertical jump? The height and distance will constantly change.What's the best way to find the right velocity so the height will hit 0 as the unit gets to the point. Trying to make sure the unit height isn't at , say, 3 when it's already at the point.
Oh, umm, let's say the height, distance, initial velocity is given, what's a good equation to make that arc while making sure vertical velocity slows Dow then speeds back up. Would there have to be 2, one for x and one for y?
hey, anyone know a good equation for a horizontal jump?
@DrHu: Go
I think you're going to have to clarify that question: equation for what exactly? Height over time? Total Distance? Launch Speed?
Here's a parabolic graph that is created when you give it two parameters: Height, and Time.
If you plan on making a Jump Ability, though, try looking at Missile Movers. Here's a mini tutorial that I'm just remembering off the top of my head. This is entirely in the Data Editor, but is pretty simple:
Open the Data Editor, and make your way into the Movers tab
There are only up to two properties on this window that you should look at. All the other ones are basically Irrelevant. The first one is Gravity. Gravity will determine how high the jump will go. Gravity at 10 will make for a short jump. Increase it to 100 and you'll have a higher jump.
The other two properties are Flight Time, or Speed. You can only pick one of these two, and should leave the other one at its default setting. If you specify the Flight Time, this will determine how long the jump lasts for, and the speed will be calculated automatically. If you set the Flight Time to 0.1 second, the unit will jump really fast, and reach its landing target within that time. If you increase it to 10 seconds, the unit will jump to its landing target much slower, perhaps giving the impression of a slow-motion jump.
If you leave Flight Time alone, and modify Speed, you will instead specify how fast the unit is going, and the Flight Time setting will be automatically calculated and irrelevant. Let's say your Unit is jumping to a very far away place. If you set the Speed setting to 1, it will take a very long time for the jump to be completed (slow-motion-esque). If you increase the speed, to say 15, the jump will happen much more fast and probably end up looking more realistic.
After we've completed the tutorial, and you've got the jump basically working, you can come back later and tweak these settings to get them right. Once you've set this up, all you have to do now are 3 more simple things: Create an Effect, Create an Ability, and Add the Ability to the unit.
To Create the Effect, in the Data Editor:
Now, in the Data Editor still, open the Abilities tab.
Now, lastly in the Data Editor, open the Units tab.
Now, give yourself a unit of that type, fire up the game, and see if when you use that ability and click a point on the ground, the Unit Jumps!
Good Luck
Great, thanks a lot! Really helpful. Would the parabola only look at the vertical jump? The height and distance will constantly change.What's the best way to find the right velocity so the height will hit 0 as the unit gets to the point. Trying to make sure the unit height isn't at , say, 3 when it's already at the point.
@Prime9: Go
Oh, umm, let's say the height, distance, initial velocity is given, what's a good equation to make that arc while making sure vertical velocity slows Dow then speeds back up. Would there have to be 2, one for x and one for y?
from the top of my memory, look correct:
y(t) = y<sub>0</sub> + V<sub>y</sub>t + gt2/2
x(t) = x<sub>0</sub> + V<sub>x</sub>t
g = 9.8, it's free fall acceleration
since V<sub>y</sub> and g have opposite direction, you can use negative g value
note: it's 2d case, and y here is top direction
metanote: mover's ballistic driver calculates this stuff without any equotions, you just set up gravity and horizontal speed
remember gravity is 9.8 m/s^2