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

How to detect a "ramp"?

Status
Not open for further replies.
Working on a pathing issue for a system I'm making... I don't want units to jump from one cliff level to another because they can potentially get stuck on another cliff level. So I have it so that if the next projected point is a different cliff level, he doesn't go there. The problem is that they don't slide up/down ramps, and I want to have ramps be the exception to this rule so that the pathing is realistic.
 
Check the path between your unit and jump point,if it's pathable,then execute it. You can do it by creating items at points in path between those two,then check if the created item is on place where it's created,if it is then it's pathable.

I suppose it is doable, by hiding the unit and setting the item's position there, checking its coordinates, then showing the unit again... but seriously??? I was hoping there was something like "IsTerrainType(x, y, TERRAIN_TYPE_RAMP)".
 
Status
Not open for further replies.
Top