• 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.

Several Questions

Status
Not open for further replies.
Level 3
Joined
Nov 5, 2006
Messages
32
Hey um... I have a few questions...

The orientation of my map is a Laser Tag map.

1. How do I make a unit avoid height adjustment with terrain?
Just like in Elimination Tournament, the projectile's height doesn't change with the height of the terrain (unless it's going down), but if it does, it moves smoothly. I want to know how to implement this.

2. How do I detect the difference between hills and cliffs?
I want to be able to make people shoot up hills, down cliffs, but not up cliffs.
___

That's all for now... if you are answering any of the questions in JASS, it's best that you explain every single chunk, because I have this thing where I find simple things quiet hard...
 
1.
JASS:
native GetLocationZ             takes location whichLocation returns real
I know what you mean. You have to get the difference of the Z values ( old position in relation to the new ) and set the height of the unit. For example you are moving the projectile ( sound like ur going to make a system ) and the old Z was 100 and the new one is 150 - then you would have to decrease units height about 50 because the height of the unit is in relation to the terrain height.

2.
JASS:
native GetTerrainCliffLevel         takes real x, real y returns integer
 
Status
Not open for further replies.
Top