• Listen to a special audio message from Bill Roper to the Hive Workshop community (Bill is a former Vice President of Blizzard Entertainment, Producer, Designer, Musician, Voice Actor) 🔗Click here to hear his message!
  • Read Evilhog's interview with Gregory Alper, the original composer of the music for WarCraft: Orcs & Humans 🔗Click here to read the full interview.
  • The Hive's 22nd Icon Contest: Creep Abilities is now concluded, time to vote for your favourite set of icons! Click here to vote!
  • ✅ The POLL for Hive's Texturing Contest #34 is OPEN! Vote for the TOP 3 SKINS! 🔗Click here to cast your vote!
  • ✅ The POLL for Hive's Techtree Contest #20 is OPEN! Vote for the TOP 3 FACTIONS! 🔗Click here to cast your vote!

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.
 
Set those to 0
 

Attachments

  • Capture.JPG
    Capture.JPG
    12.1 KB · Views: 168
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.
Back
Top