• 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] Needing help with a trigger - [forzamoto]

Status
Not open for further replies.
Level 9
Joined
Apr 14, 2008
Messages
192
Needing help with a trigger UPDATE - [forzamoto]

This trigger I made is not working so well and it is leaking, what is supposed to happed is when the unit called zagarr gets hit once it summons 10 units around him but the problem show that when any unit gets hit summons 10 automatically, after the 10 have been summon around zagarr the trigger stops.


[FONT=&quot]1. zagarr gets hit[/FONT]
[FONT=&quot]2. 10 units are summoned[/FONT]
[FONT=&quot]3. Make the effects on the attacked unit and attacking unit[/FONT]
[FONT=&quot]4. End trigger[/FONT]

  • zagarr
  • Events
    • Unit - A unit owend by player 1 (Red) is attacked
    • Unit - A unit owend by player 2 (Blue) is attacked
    • Unit - A unit owend by player 3 (Teal) is attacked
    • Unit - A unit owend by player 4 (Purple) is attacked
    • Unit - A unit owend by player 5 (Yellow) is attacked
    • Unit - A unit owend by player 6 (Orange) is attacked
    • Unit - A unit owend by player 7 (Green) is attacked
    • Unit - A unit owend by player 8 (Pink) is attacked
  • Conditions
    • I need to know a Condition for this that will work
  • Actions
    • Unit - Create 5 Baby beast for (Owner of (Attacked unit)) at (Position of(Attacked unit)) facing Default building faceing degrees
    • Special Effect - Create a special effect attached to the chest of (Attacked unit) using Objects\Spawnmodels\NightElf\NEDeathSmall\NEDeathSmall.mdl
    • Special Effect - Create[ a special effect attached to the chest of (Attacking unit) using Objects\Spawnmodels\Other\NeutralBuildingExplosion\NeutralBuildingExplosion.mdl
  • Trigger - Turn off (This trigger)
Theres this new ability i was needing help with when a unit gets hit, its like poison nova but its not poison its a footman flying dealing 80 damage and it keeps making footmen nova for 6 seconds that should be about 4 times if you do this be love you long time, and when i say that Rep for you.

 
Last edited:
Level 5
Joined
May 6, 2008
Messages
175
uh what unit is attacking? is it a building?

well if it is a ground unit use this

((Attacking unit) is A ground unit) Equal to True

and why u end trigger? thats why it stops spawning baby beasts.(or is it?)
 
Level 4
Joined
Aug 9, 2004
Messages
70
In the conditions, go to Unit-Type conditions and make sure the Attacked Unit is equal to zagarr's type. Also you don't need to fill that event's section. Use A unit is attacked event instead.

And for the leaks, you better go read this http://www.hiveworkshop.com/forums/f269/things-leak-35124/
or some tut's if you want to improve yourself. I won't give you fish, maybe you can learn hot to catch them.
 
Level 5
Joined
May 6, 2008
Messages
175
yddohu dun double post plz and you said when the trigger is on, he will multiply and win game easily, but when u do da one you posted. they stop after multiplied. what does the thing you really want? well you should use periodic time so every xxx seconds he multiplies, but he is not attacked.
 
Level 8
Joined
May 21, 2008
Messages
218
Here's your real fish,

  • Melee Initialization
    • Events
      • Unit - A unit Is attacked
    • Conditions
      • ZaggerSpawnInteger[(Player number of (Owner of Zagger))] Equal to 0
      • (Unit-type of (Triggering unit)) Equal to Zagger
    • Actions
      • Set ZaggerSpawnInteger[(Player number of (Owner of Zagger))] = 1
      • Set Zagger = (Attacked unit)
      • Set ZaggerPosition = (Position of Zagger)
      • Unit - Create 5 Zagger Spawn for (Owner of Zagger) at ZaggerPosition facing 270.00 degrees
      • Custom script: Call Remove Unit (udg_Zagger)
      • Custom script: Call Remove Point (udg_ZaggerPosition)
  • Zagger
    • Events
      • Unit - A unit Dies
    • Conditions
      • (Unit-type of (Triggering unit)) Equal to Zagger Spawn
    • Actions
      • Set ZaggerSpawn = (ZaggerSpawn + 1)
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • ZaggerSpawn Equal to 5
        • Then - Actions
          • Set ZaggerSpawnInteger[(Player number of (Owner of (Dying unit)))] = 0
          • Set ZaggerSpawn = 0
        • Else - Actions
Tell me if i leaked im new to trigger leaks.
 
Level 9
Joined
Apr 14, 2008
Messages
192
Oh man thanks thats +Rep for show... Show variables please lol

Not leaks i need the right stuff...

wut cha talking about
lol i laughed when i saw ''all must do at ocne for it to work'' how do you think the ''player chat message'' that have 12 of them inside a trigger work if only one person say it? XD
 
Last edited by a moderator:
Level 28
Joined
Mar 25, 2008
Messages
2,955
..the fuck?
Just use this one:
  • Events
    • Unit - A unit enters (Playable map area)
  • Conditions
    • (Unit-type of (Triggering Unit)) equal to *your unit you want "zagarr" to be
  • Actions
    • Set zagarr = (Triggering Unit)
  • Events
    • Unit - A unit is attacked
  • Conditions
  • Actions
    • Set temppoint = (Position of zagarr)
    • For each Integer A from 1 to 5 do:
      • Set temppoint2 = temppoint offset by 100 towards (x + 72) degrees
      • Unit - Create 1 *your spawns* for (Owner of zagarr) at temppoint2 facing Random angle degrees
      • Custom script: call RemoveLocation(udg_temppoint2)
      • Set x = x + 72
    • Trigger - Turn off (this trigger)
    • Custom script: call RemoveLocation(udg_temppoint)
    • Set x = 0
 
Status
Not open for further replies.
Top