• 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.
  • 💡 We're thrilled to announce that our upcoming texturing contest is in the works, and we're eager to hear your suggestions! Please take this opportunity to share your ideas in this theme discussion thread for the Texturing Contest #34!
  • 🏆 Hive's 7th HD Modeling Contest: Icecrown Creature is now open! The frozen wastes of Icecrown are home to some of Azeroth’s most terrifying and resilient creatures. For this contest, your challenge is to design and model a HD 3D monster that embodies the cold, undead, and sinister essence of Icecrown! 📅 Submissions close on April 13, 2025. Don't miss this opportunity to let your creativity shine! Enter now and show us your frozen masterpiece! 🔗 Click here to enter!

How to measure range (distance between points) precisely?

Status
Not open for further replies.
Level 33
Joined
Mar 27, 2008
Messages
8,035
There are many ways to measure range (distance), one of it, is this:

  • Measuring Distance
    • Events
      • Unit - A unit Starts the effect of an ability
    • Conditions
      • (Ability being cast) Equal to *YourAnyKindOfTargetGroundAbility*
    • Actions
      • Set CasterLoc = (Position of (Triggering unit))
      • Set TargetLoc = (Target point of ability being cast)
      • Set Range = (Distance between CasterLoc and TargetLoc)
      • Cinematic - Clear the screen of text messages for (All players)
      • Game - Display to (All players) the text: (The distance between caster's location and the target location is + (String((Integer(Range)))))
      • Custom script: call RemoveLocation(udg_CasterLoc)
      • Custom script: call RemoveLocation(udg_TargetLoc)
This trigger will calculate the distance between the caster's position and the target position.
This is the simplest measuring distance method (for simple purpose).

You need to be specify on what you want to measure, and how that it needs to be measured
 
Status
Not open for further replies.
Top