• 🏆 Texturing Contest #33 is OPEN! Contestants must re-texture a SD unit model found in-game (Warcraft 3 Classic), recreating the unit into a peaceful NPC version. 🔗Click here to enter!
  • 🏆 Hive's 6th HD Modeling Contest: Mechanical is now open! Design and model a mechanical creature, mechanized animal, a futuristic robotic being, or anything else your imagination can tinker with! 📅 Submissions close on June 30, 2024. Don't miss this opportunity to let your creativity shine! Enter now and show us your mechanical masterpiece! 🔗 Click here to enter!

[Solved] Detecting when an item is used within a region

Status
Not open for further replies.
Level 2
Joined
Jun 19, 2011
Messages
12
I'm having trouble figuring out how to detect when an item is used within a specific region. Can anyone help?
 
Level 13
Joined
Oct 25, 2009
Messages
995
use this
  • Detect
    • Events
      • Unit - A unit Acquires an item
    • Conditions
    • Actions
      • Set Region = Region 000 <gen>
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • (Region contains (Hero manipulating item)) Equal to True
        • Then - Actions
          • Cinematic - Ping minimap for (All players) at (Position of (Hero manipulating item)) for 1.00 seconds
        • Else - Actions
 
Level 37
Joined
Mar 6, 2006
Messages
9,240
Setup the region
  • Melee Initialization
    • Events
      • Map initialization
    • Conditions
    • Actions
      • Set region = Region 000 <gen>
Detect when it's used
  • Untitled Trigger 104
    • Events
      • Unit - A unit Uses an item
    • Conditions
      • (region contains (Triggering unit)) Equal to True
    • Actions
      • Game - Display to (All players) the text: Item used in region
 
Level 2
Joined
Jun 19, 2011
Messages
12
Thanks guys! I had a lot of trouble finding a "region contains" condition, cause I forgot to use the boolean condition. Silly me! I gave +rep to both of you =)
 
Status
Not open for further replies.
Top