Unit Z orientation (getting shifted by terrain)

Status
Not open for further replies.
Level 20
Joined
Jul 6, 2009
Messages
1,885
I made a projectile system where projectiles travel in a line and are not affected by terrain height (height is defined by: travel height - projectile location's Z). The problem is that when projectiles fly over a bumpy terrain, their Z orientation changes so it looks ugly :\ (Unit movement type is foot)
When i tried the fly movement type, their Z orientation didn't change, but their height was varying.
Any way to fix this?

EDIT: I use quilboar's missile as projectile as it looks quite like a bullet.
 
Level 23
Joined
Jan 1, 2009
Messages
1,616
Set those to 0
 

Attachments

  • Capture.JPG
    Capture.JPG
    12.1 KB · Views: 109
Level 20
Joined
Jul 6, 2009
Messages
1,885
By height you mean their actual flying height? E.g. GetUnitFlyHeight() would return various values? If not, then please, explain the difference between Z orientation and Height. Sometimes Pitch angle and Roll angle is they problem to that, but I still don't understand what do you mean by orientation.
Visual height, they go up and down (not sure about their fly height value). By Z orientation i mean projectile's facing in Z axis (pitch).
Frotty's way worked, but thanks for posting.
Set those to 0
Thanks, that worked.
 
Status
Not open for further replies.
Top