Moderator
M
Moderator
12th Dec 2015
IcemanBo: Too long as NeedsFix. Rejected.
18:14, 19th Jul 2012
Magtheridon96:
IcemanBo: Too long as NeedsFix. Rejected.
18:14, 19th Jul 2012
Magtheridon96:
- To make this an ideal jump system, you should make it work for units that don't have an initial height of 0.
- Allow the user to give a unit, jump speed and final coordinates (x, y, z)
- Take into account the fact that flying height is not z.
Z is flying height + terrain height.
You can get the terrain height by having a location variable which you
have to initialize to Location(0, 0) in custom scripts, and so that you don't have to leak it, you would move the location using the MoveLocation function.call MoveLocation(location, x, y)
.
After moving the location, you can get the terrain height using GetLocationZ. - Don't use IsTerrainPathable, it's not your responsibility to check if the unit is ending up at a non-pathable point, it's the user's responsibility.
- Your current method of indexing is out-dated.
Use Hanky's dynamic index method.