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

Trigger request!

Status
Not open for further replies.
Level 7
Joined
Aug 13, 2011
Messages
142
My friend needs this!! He doesn't have an account here nor does he have the time to make an account here,

ithink it might need 2 triggers

1st, he needs trigger like this
a unit builds a building(example, a crystalline spire)
after building, three summoning nodes(nodes that can be upgraded into various buildings) will appear around it

Somethin like this:
Untitled.jpg

the other trigger will be like this
when the crystalline spire is destroyed the summoning nodes and its upgrades will disappear

i dont know anything about his campaign, he just asked me to request this in this site, he doesnt make accounts on wc3 modding sites so he makes me download and request stuff, so in other words please dont ask me about his campaign.
 
Level 1
Joined
May 16, 2013
Messages
7
Like this?

Code:
Untitled Trigger 001
    Events
        Unit - A unit enters (Playable map area)
    Conditions
        (Unit-type of (Triggering unit)) Equal to Crystalline Spire
    Actions
        Unit - Create 1 Summoning node for (Owner of (Triggering unit)) at ((Position of (Triggering unit)) offset by 200.00 towards 85.00 degrees) facing Default building facing degrees
        Unit - Create 1 Summoning node for (Owner of (Triggering unit)) at ((Position of (Triggering unit)) offset by 180.00 towards 210.00 degrees) facing Default building facing degrees
        Unit - Create 1 Summoning node for (Owner of (Triggering unit)) at ((Position of (Triggering unit)) offset by 200.00 towards 335.00 degrees) facing Default building facing degrees
Code:
Untitled Trigger 002
    Events
        Unit - A unit Dies
    Conditions
        (Unit-type of (Triggering unit)) Equal to Crystalline Spire
    Actions
        Unit Group - Pick every unit in (Units within 200.00 of (Position of (Triggering unit)) matching ((Unit-type of (Matching unit)) Equal to Summoning node)) and do (Actions)
            Loop - Actions
                Unit - Kill (Picked unit)

Very simple but so many problems but I think you're asking for something like this?
 
Level 33
Joined
Mar 27, 2008
Messages
8,035
I understand when Spire is destroyed, all three nodes associate with the Spire will be destroyed too, but I don't understand the "...and its upgrades will disappear."
What upgrade ?
Is it a Research upgrade that applies to all Unit-type in the map ?
Or upgrade to that node itself - such as +HP Bonus to the node ?
Well if that's the upgrade, destroying the building itself contributes to that degrading already, so why do you need to rollback the upgrade ?

I still don't get this part.
 
@Xhiao
Post with trigger tags like this. Also u leak locations and a group and u should store (Owner of (Triggering unit)) into a variable and use the variable.
Anything u use twice or more store into a variable for efficiency and good coding practice.

  • Untitled Trigger 001
    • Events
      • Unit - A unit enters (Playable map area)
    • Conditions
      • (Unit-type of (Triggering unit)) Equal to Crystalline Spire
    • Actions
      • Unit - Create 1 Summoning node for (Owner of (Triggering unit)) at ((Position of (Triggering unit)) offset by 200.00 towards 85.00 degrees) facing Default building facing degrees
      • Unit - Create 1 Summoning node for (Owner of (Triggering unit)) at ((Position of (Triggering unit)) offset by 180.00 towards 210.00 degrees) facing Default building facing degrees
      • Unit - Create 1 Summoning node for (Owner of (Triggering unit)) at ((Position of (Triggering unit)) offset by 200.00 towards 335.00 degrees) facing Default building facing degrees
  • Untitled Trigger 002
    • Events
      • Unit - A unit Dies
    • Conditions
      • (Unit-type of (Triggering unit)) Equal to Crystalline Spire
    • Actions
      • Unit Group - Pick every unit in (Units within 200.00 of (Position of (Triggering unit)) matching ((Unit-type of (Matching unit)) Equal to Summoning node)) and do (Actions)
        • Loop - Actions
          • Unit - Kill (Picked unit)

  • Untitled Trigger 001
    • Events
      • Unit - A unit enters (Playable map area)
    • Conditions
      • (Unit-type of (Triggering unit)) Equal to Crystalline Spire
    • Actions
      • Set tempPlayer = (Owner of (Triggering unit))
      • Set tempPoint = (Position of (Triggering unit))
      • Set tempPoint2 = (tempPoint offset by 200.00 towards 85.00 degrees)
      • Unit - Create 1 Summoning node for tempPlayer at tempPoint2 facing Default building facing degrees
      • Custom script: call RemoveLocation( udg_tempPoint2)
      • Set tempPoint2 = (tempPoint offset by 180.00 towards 210.00 degrees)
      • Unit - Create 1 Summoning node for tempPlayer at tempPoint2 facing Default building facing degrees
      • Custom script: call RemoveLocation( udg_tempPoint2)
      • Set tempPoint2 = (tempPoint offset by 200.00 towards 335.00 degrees)
      • Unit - Create 1 Summoning node for tempPlayer at tempPoint2 facing Default building facing degrees
      • Custom script: call RemoveLocation( udg_tempPoint2)
      • Custom script: set udg_tempPoint2 = null
      • Custom script: call RemoveLocation( udg_tempPoint)
      • Custom script: set udg_tempPoint = null
      • Custom script: set udg_tempPlayer = null
  • Untitled Trigger 002
    • Events
      • Unit - A unit Dies
    • Conditions
      • (Unit-type of (Triggering unit)) Equal to Crystalline Spire
    • Actions
      • Set tempPoint = (Position of (Triggering unit))
      • Set tempGroup = ((Units within 200.00 of tempPoint) matching ((Unit-type of (Matching unit)) Equal to Summoning node))
      • Unit Group - Pick every unit in tempGroup and do (Actions)
        • Loop - Actions
          • Unit - Kill (Picked unit)
      • Custom script: call RemoveLocation( udg_tempPoint)
      • Custom script: set udg_tempPoint = null
      • Custom script: call DestroyGroup( udg_tempGroup)
      • Custom script: set udg_tempGroup = null
 
Last edited:
Level 11
Joined
Feb 23, 2009
Messages
577
  • Untitled Trigger 001
  • Events
  • Unit - A unit enters (Playable map area)
  • Conditions
  • (Unit-type of (Triggering unit)) Equal to Crystalline Spire
  • Actions
  • Set tempPlayer = (Owner of (Triggering unit))
  • Set tempPoint = (Position of (Triggering unit))
  • Unit - Create 1 Summoning node for tempPlayer at tempPoint offset by 200.00 towards 85.00 degrees) facing Default building facing degrees
  • Unit - Create 1 Summoning node for tempPlayer at tempPoint offset by 180.00 towards 210.00 degrees) facing Default building facing degrees
  • Unit - Create 1 Summoning node for tempPlayer at tempPoint offset by 200.00 towards 335.00 degrees) facing Default building facing degrees
  • Custom script: call RemoveLocation( udg_tempPoint)
  • Custom script: set udg_tempPoint = null
  • Custom script: set udg_tempPlayer = null
This still leaks because you have to remove the locations created here:
tempPoint offset by 200.00 towards 85.00 degrees
 
Status
Not open for further replies.
Top