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

Check region

Status
Not open for further replies.
Level 7
Joined
May 18, 2010
Messages
264
  • Turn
    • Events
      • Unit - A unit enters NPC mov 1 <gen>
      • Unit - A unit enters NPC mov 2 <gen>
      • Unit - A unit enters NPC mov 3 <gen>
    • Conditions
    • Actions
      • Multiple FunctionsIf (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • (Triggering unit) Equal to (==) Peasant 0002 <gen>
        • Then - Actions
        • Else - Actions
I cant find CHECK for REGION
EX: region enterd = NPC mov 1
:vw_sad::ogre_rage:
 
Level 7
Joined
May 18, 2010
Messages
264
What actions are you going to add?

There isn't GUI version for triggering region, but you can use
  • Custom script: set udg_region = GetTriggeringRegion()
  • Turn
    • Events
      • Unit - A unit enters NPC mov 1 <gen>
      • Unit - A unit enters NPC mov 2 <gen>
      • Unit - A unit enters NPC mov 3 <gen>
    • Conditions
    • Actions
      • Multiple FunctionsIf (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • (Triggering unit) Equal to (==) Peasant 0002 <gen>
        • Then - Actions
          • Wait 0.50 seconds
          • Unit - Make Peasant 0002 <gen> face 224.00 over 0.50 seconds
          • Wait (Random real number between 10.00 and 15.00) seconds
          • Set NPCmovRandom[1] = (Random integer number between 1 and 3)
            • Multiple FunctionsIf (All Conditions are True) then do (Then Actions) else do (Else Actions)
              • If - Conditions
                • NPCmovRandom[1] Less than or equal to (<=) 2
              • Then - Actions
                • Unit - Order Peasant 0002 <gen> to Move To (Center of NPC mov 2 <gen>)
              • Else - Actions
                • Multiple FunctionsIf (All Conditions are True) then do (Then Actions) else do (Else Actions)
                  • If - Conditions
                    • NPCmovRandom[1] Equal to (==) 3
                  • Then - Actions
                    • Unit - Order Peasant 0002 <gen> to Move To (Center of NPC mov 3 <gen>)
                  • Else - Actions
        • Else - Actions
 
You will have to you custom scripts to do such thing.
Maker told you already about function which returns you region you need.

  • Custom script: if GetTriggeringRegion() == <your NPC 1 region> then
  • <GUI actions>
  • Custom script: elseif GetTriggeringRegion() == <your NPC 2 region> then
  • <GUI actions here>
  • Custom script: else
  • <GUI actions here>
There is no condition in 'ekse' since if unit enters one of 3 regions and it's not region A nor B the last one left is C.
 
Status
Not open for further replies.
Top