• 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] Triggers turning other triggers on

Status
Not open for further replies.
Level 7
Joined
Dec 8, 2005
Messages
319
triggering unit

so i create a unit using triggers so then i want to set the life to a percent and move him... yet he is not moving or going to the percent life... any ideas?
 
Level 7
Joined
Dec 8, 2005
Messages
319
hmm the even is a every 2 seconds to make a simple loop. then i create my unit then i set it;s life and the order it to move...

yet (triggering unit) does not work... any ideas

Spawn Team1 North
Events
Time - Every 2.00 seconds of game time
Conditions
Actions
Unit - Create 1 Sea Giant for Player 9 (Gray) at (Center of Team1 North <gen>) facing Default building facing degrees
Unit - Set life of (Triggering unit) to Percentageofunit%
Unit - Set Rally-Point for (Triggering unit) to (Center of Team1 South <gen>)
 
Level 13
Joined
Sep 24, 2007
Messages
1,023
  • Spawn Team1 North
  • Events
  • Time - Every 2.00 seconds of game time
  • Conditions
  • Actions
  • Unit - Create 1 Sea Giant for Player 9 (Gray) at (Center of Team1 North <gen>) facing Default building facing degrees
  • Unit - Set life of (picked unit) to 75.00%
  • Unit - order (picked unit) move to (Center of Team1 South <gen>)
i tihnk picked unit would work
 
Last edited:
Level 7
Joined
Dec 8, 2005
Messages
319
nope no luck...
anyone have any ideas on how to make a trigger for a TD?
need to set the life to a set percent... but not sure how to keep them from blocking... any ideas? and how do you remove fog... does not seem to want to turn off and thanks for all the help
 
Level 29
Joined
Jul 29, 2007
Messages
5,174
Guys, you need to understand that using Picked Unit, refers to units you picked with the Unit Group actions.

Triggering Unit refers to the unit that triggerd the trigger (in other words - the event).

So if you use a timed event, you won't have either of those.
When you create a unit you'll need to refer to it as "Last Created Unit", since it was the last created unit.

Example for Triggering Unit:
  • Untitled Trigger 001
    • Events
      • Unit - A unit Dies
    • Conditions
    • Actions
      • Hero - Instantly revive (Triggering unit) at (Center of (Playable map area)), Hide revival graphics

As you can see, you revive the unit that triggerd the trigger - the unit that died.

Example for Picked Unit:
  • Untitled Trigger 001
    • Events
      • Time - Elapsed game time is 5.00 seconds
    • Conditions
    • Actions
      • Unit Group - Pick every unit in (Units in (Playable map area)) and do (Actions)
        • Loop - Actions
          • Unit - Kill (Picked unit)

You picked all units in the map and killed them.


Anyway back to the subject, if you want your units to move in a certain way through points, make a region in each turning point and create a trigger like this one:
  • Untitled Trigger 001
    • Events
      • Unit - A unit enters someRegion
    • Conditions
    • Actions
      • Unit - Order (Triggering unit) to Move To nextRegion

Now to set a life of a unit (I guess its based on a host selecting difficulty?) you'll want to do something like this:
  • Untitled Trigger 001
    • Events
      • Unit - A unit enters (Current camera bounds)
    • Conditions
      • ((Owner of (Triggering unit)) controller) Equal to Computer
    • Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • Integer_Difficulty Equal to 1
        • Then - Actions
          • Unit - Set life of (Triggering unit) to 33.00%
        • Else - Actions
          • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            • If - Conditions
              • Integer_Difficulty Equal to 2
            • Then - Actions
              • Unit - Set life of (Triggering unit) to 66.00%
            • Else - Actions

If the level is easiest - set to 33%
If the level is medium - set to 66%
If the level is hard - no need to do anything since the default is 100%
 
Level 7
Joined
Dec 8, 2005
Messages
319
well difficulty is set by armor instead of life... but basicly i have the regions and the integer to set the life from 1% to 100% life.

but this is my idea and it might help on creating a trigger.

basicly both sides left and right get 100 units running south and north. = 200 units each. for each unit the left side kills, right side gets one more unit. i have never done the little board that tells you time untill next round, or how many units on each side or the other way around. but basicly when 1 side gets less then 50 units on one side then the other team loses. so any ideas or how i should go about making triggers for all those ideas? and thanks again everyone.
 
Last edited:
Level 29
Joined
Jul 29, 2007
Messages
5,174
First of all, I must say it sounds like a nice idea for a game ! *thumbs up*

Now back to the triggers:

Its a bit confusing because of all the If/Then/Else but read it and you'll understand it :)
  • Untitled Trigger 19.24
    • Events
      • Unit - A unit Dies
    • Conditions
      • ((Owner of (Triggering unit)) controller) Equal to Computer
    • Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • (Owner of (Triggering unit)) Equal to Player 11 (Dark Green)
        • Then - Actions
          • Unit - Create 1 unitType for Player 12 (Brown) at rightTeamRegion facing Default building facing degrees
        • Else - Actions
          • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            • If - Conditions
              • (Owner of (Triggering unit)) Equal to Player 12 (Brown)
            • Then - Actions
              • Unit - Create 1 unitType for Player 11 (Dark Green) at leftTeamRegion facing Default building facing degrees
            • Else - Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • (Number of units in (Units in (Playable map area) owned by Player 11 (Dark Green))) Equal to 50
        • Then - Actions
          • some Actions
        • Else - Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • (Number of units in (Units in (Playable map area) owned by Player 12 (Brown))) Equal to 50
        • Then - Actions
          • some Actions
        • Else - Actions
 
Level 7
Joined
Dec 8, 2005
Messages
319
ya i t makes sense. but how do i get the units start moving and set the life. but both of those triggers really help and once i get this first trigger then i can implement those 2 triggers.
 
Level 7
Joined
Dec 8, 2005
Messages
319
So does anyone have an idea how to create and move units to a specific region. keep in mid this is for a TD. and not sure how to keep an anti block trigger as well. any ideas and thanks again for all the help.
 
Level 7
Joined
Dec 8, 2005
Messages
319
yet when you make a unit in a region... it cannot "enter" the region if it is placed in that region... so in there lies the problem.
 
Level 7
Joined
Dec 8, 2005
Messages
319
haha here we go... got it figured out... that for every ones help... but i would like your to hear how you think it is. and whether i should change anything?

Move Team1 North
Events
Unit - A unit enters Team1 North <gen>
Conditions
Actions
Unit Group - Pick every unit in (Units in Team1 North <gen>) and do (Actions)
Loop - Actions
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
(Owner of (Picked unit)) Equal to Player 10 (Light Blue)
Then - Actions
Unit - Set life of (Picked unit) to Percentageofunit%
Unit - Order (Picked unit) to Move To (Center of Team1 South <gen>)
Else - Actions

and how do you make the little bubble where you place your trigger in?
 
Last edited:
Level 12
Joined
Aug 18, 2006
Messages
1,193
that trigger is working, but could be improved a lot

Do you know what a Leak is? If you dont, please check out the "Things That Leak" thread

My tip before checking the thread out would be to make a "Trigger - Turn Off (This Trigger)" at the beginning of the trigger and a "Trigger - Turn On (This Trigger)" at the end, or this trigger will run 30 times every spawn, which could cause lagg if you havent destroyed the Leaks
 
Level 7
Joined
Dec 8, 2005
Messages
319
hmm i understand the need to be leak proof. i dont want to make a faulty game or one that muscled together. but razor think you could give me an example of what you mean? i think i get understand what our doing.

hmm but i still have no idea how to make an anti block system. and i am not sure how to limit the units to 200 total.

should i use when player9+player10 units = 200 turn off producing triggers. or should i just use a timer... after X amount of time turn off triggers and just do a simple math problem?
 
Level 12
Joined
Aug 18, 2006
Messages
1,193
An example of a Leak Fix
  • Events
    • A unit Starts the effect of an ability
  • Condition
    • (Ability being cast) Equal to Ultimate Suicide
  • Actions
    • Set UnitGroup = (Units within 600 of (Casting unit))
    • Pick every unit in Group and do (Actions)
      • Kill (Picked unit)
    • Custom script: call DestroyGroup(udg_Group)
Unit groups leak. If you dont temporary unit groups, they will remain in the game memory and might cause lagg later in the game.

Points also leak. An example of a Point is your (Center of Team1 South <gen>). To fix such a leak, you do like this
  • Events
    • A unit enters Region1
  • Condition
    • (Entering unit) Equal to TheHero
  • Actions
    • Set Point = (Center of Team1 South <gen>)
    • Unit - Order (Entering unit) to Move To Point
    • Custom script: call RemoveLocation(udg_Point)
this is just the basics, learn more at the "Things That Leak" Thread

a suggestion for your max 200 units limit trigger would be
  • Events
    • Every 1.00 seconds of game-time
  • Conditions
    • ((Player 9 (Gray) Food used) + (Player 10 (Light Blue) Food used)) Greater than or equal to 200
  • Actions
    • Trigger - Turn off (This trigger)
    • Trigger - Turn off SpawnTrigger
    • Wait for (((Player 9 (Gray) Food used) + (Player 10 (Light Blue) Food used)) Less than 200) checking every 1.00 seconds
    • Trigger - Turn on (This trigger)
    • Trigger - Turn on SpawnTrigger
 
Level 29
Joined
Jul 29, 2007
Messages
5,174
I already gave a better (in my opinion, time events kinda suck if they can be avoided. no point running every second if it can just run whenever a unit dies) solution for the 50 units.

And I was never sure if middle-of-region leaks. Are you hundred precent sure ?
 
Level 7
Joined
Dec 8, 2005
Messages
319
hmm ok here we go... i want to keep units that run north to south to continue running north to south. on either side of the map... to keep it balanced. well i used a buff on the units to tell them apart... and for me to make sure everything is right. yet this trigger is not working... here it is.

  • Death for Team1
    • Events
      • Unit - A unit Dies
    • Conditions
      • ((Owner of (Triggering unit)) controller) Equal to Computer
    • Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • ((Triggering unit) has buff North to South ) Equal to True
          • (Owner of (Triggering unit)) Equal to Player 10 (Light Blue)
        • Then - Actions
          • Unit - Create 1 Sea Giant North to South for Player 9 (Gray) at (Center of Team2 North Spawner <gen>) facing (Position of (Triggering unit))
        • Else - Actions
          • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            • If - Conditions
              • (Owner of (Triggering unit)) Equal to Player 10 (Light Blue)
              • ((Triggering unit) has buff South to North ) Equal to True
            • Then - Actions
              • Unit - Create 1 Sea Giant South to North for Player 9 (Gray) at (Center of Team2 South Spawner <gen>) facing (Position of (Triggering unit))
            • Else - Actions
 
Last edited:
Level 7
Joined
Dec 8, 2005
Messages
319
hmm well i think the triggers work but the condition with the buff. cant check a dead unit with a buff. but anyone know a way to keep the set of units going from north to south that die get spawned on the other side still going from north to south?

and vise versa.
 
Level 22
Joined
Feb 26, 2008
Messages
892
Custom Value is a number that has no real effect on gameplay but can be used in triggers. Each unit on the map has its own Custom Value that can be changed with the Unit action Set Custom Value.
These are often useful in keeping track of where a unit is along a Tower Defense path by setting all the regions into a region array variable and using the unit's Custom Value as the index of that variable. The value gets one added to it for each region the unit visits to keep it on track.
 
Level 7
Joined
Dec 8, 2005
Messages
319
hmm i dont know where you see or how you set custom value. think you could be alittle more informitive on where it is located. but that seems to be the perfect thing to use for this.
 
Level 22
Joined
Feb 26, 2008
Messages
892
> i dont know where you see or how you set custom value

Make sure you're using The Frozen Throne. I don't know if it is in Reign of Chaos, but it may not be there in that one.

It's a unit action. You see, the Custom Value can only be set through a trigger.
You can's click on a unit to set it, for example.
So, when you go to the unit category, you should be able to look down the list to find it.
Here's a picture:

CustomValue.jpg
 
Level 7
Joined
Dec 8, 2005
Messages
319
wow that solved the problem. thanks alot

but i am having trouble with my multi boards. take a look at it and tell me if i am doing anything wrong. but the problem is that the number of units that the player 9 and 10 own are not showing up on the multi board. any ideas guys.

  • Multiboard
    • Events
      • Time - Elapsed game time is 1.00 seconds
    • Conditions
    • Actions
      • Multiboard - Set the width for Multiboard item in column 1, row 1 to 8.00% of the total screen width
      • Multiboard - Set the width for Multiboard item in column 1, row 2 to 8.00% of the total screen width
      • Multiboard - Set the width for Multiboard item in column 2, row 1 to 8.00% of the total screen width
      • Multiboard - Set the width for Multiboard item in column 2, row 2 to 8.00% of the total screen width
      • Multiboard - Set the text for Multiboard item in column 1, row 1 to Team 1 Units
      • Multiboard - Set the text for Multiboard item in column 2, row 1 to Team 2 Units
      • Multiboard - Set the text for Multiboard item in column 1, row 2 to (String((Number of units in (Units in (Playable map area) owned by Player 10 (Light Blue)))))
      • Multiboard - Set the text for Multiboard item in column 2, row 2 to (String((Number of units in (Units in (Playable map area) owned by Player 9 (Gray)))))
      • Multiboard - Minimize Multiboard
 
Level 7
Joined
Dec 8, 2005
Messages
319
ya that is in another trigger and that is just setting up some other stuff. but that is not the problem. the number of units on each side is not working.
 
Level 7
Joined
Dec 8, 2005
Messages
319
haha i figured it out... the trigger was working perfectly. yet everytime a new unit entered the game. it would not update because. so i made a new trigger that everytime a new unit enters the game. the multiboard is updated.
 
Level 5
Joined
Aug 16, 2007
Messages
149
about the blocking thing: you could make a little dude run through each of the paths and if he hasn't reached a region within, say, 60 secs, the player is blocking. That's how I would do it.
 
Level 12
Joined
Aug 18, 2006
Messages
1,193
that can be quite flawed if done wrong

my maze can be so long, that it will take longer than 60 seconds for the little dude to the end

and players would just build towers when the level has started

I would use a little dude too, but i would give him an Permanent Immolation that would deal a small amount of damage. That way, if he stops at a place, he will keep dealing damage to the tower he is standing next too. I would also send one to check before the level starts, and send one when the level starts so it can check then too.
 
Level 7
Joined
Dec 8, 2005
Messages
319
ah it is ok... if you block... and they walk back and forth long enough... they just attack... haha

but hey razor you said my code is leaky... so i took your advise and read the leak sticky and well here we go.... i only did one trigger, so tell me if i did it right. or something i might of missed. but here we go. if i did it right then i will work on the more complicated triggers. but take a look

  • Spawn Team1
    • Events
      • Time - Every 2.00 seconds of game time
    • Conditions
    • Actions
      • Set T1Fspawner = Team1 First Spawner <gen>
      • Set T1Sspawner = Team1 Second Spawner <gen>
      • Set T1Tspawner = Team1 Third Spawner <gen>
      • Set T1FHspawner = Team1 FourthSpawner <gen>
      • Unit - Create 1 Sea Giant for Player 10 (Light Blue) at (Center of T1Fspawner) facing (Center of T1Fspawner)
      • Unit - Create 1 Sea Giant for Player 10 (Light Blue) at (Center of T1Sspawner) facing (Center of T1Sspawner)
      • Unit - Create 1 Sea Giant for Player 10 (Light Blue) at (Center of T1Tspawner) facing (Center of T1Tspawner)
      • Unit - Create 1 Sea Giant for Player 10 (Light Blue) at (Center of T1FHspawner) facing (Center of T1FHspawner)
      • Custom script: call RemoveLocation(udg_T1Fspawner)
      • Custom script: call RemoveLocation(udg_T1Sspawner)
      • Custom script: call RemoveLocation(udg_T1Tspawner)
      • Custom script: call RemoveLocation(udg_T1FHspawner)
 
Level 12
Joined
Aug 18, 2006
Messages
1,193
the position of which you create the Creeps must be the Variable. An example
  • Events
    • Time - Every 2.00 seconds of game time
  • Conditions
  • Actions
    • Set T1Fspawner = (Center of Team1 First Spawner <gen>)
    • Unit - Create 1 Sea Giant for Player 10 (Light Blue) at T1Fspawner facing Default building facing
    • Custom script: call RemoveLocation(udg_T1Fspawner)
remember that the same variable shouldnt be used twice(unless you destroy them and then Set them to something else or the same thing) since it will create a leak(i think)

else everything is correct :p
 
Last edited:
Level 7
Joined
Dec 8, 2005
Messages
319
ya i had it facing the triggering unit at first.. and that might cause i leak if i understood correctly so i figure i would just use the variable but so skipped over using default building facing... lol

cool and give me a miinute. let me work on another code and just run it past you guys real fast... oh and i made a new trigger for upgrades. here it is and just tell me if there might be leaks and if so why plz. nvr saw anything about his.

  • Upgrade MultiShot
    • Events
      • Unit - A unit Finishes an upgrade
    • Conditions
      • (Researched tech-type) Equal to Multi Shot
    • Actions
      • Unit Group - Pick every unit in (Units owned by (Triggering player) of type Tower of the Reef) and do (Actions)
        • Loop - Actions
          • Unit - Set level of MultiShot for (Triggering unit) to (Current research level of Multi Shot for (Triggering player))
 
Level 7
Joined
Dec 8, 2005
Messages
319
hmm well i went to save the game and well.... 200 errors later and about 2hrs work of making it leaks proof and my triggers turned off.

tell me if you see anything wrong. this is one that is turned off.

  • Move Team1 First to Third
    • Events
      • Unit - A unit enters Team1 First Spawner <gen>
    • Conditions
    • Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • (Owner of (Triggering unit)) Equal to Player 10 (Light Blue)
        • Then - Actions
          • Set T1Treciever = Team1 Third Receive <gen>
          • Unit - Set life of (Triggering unit) to Percentageofunit%
          • Unit - Order (Triggering unit) to Move To (Center of T1Treciever)
          • Unit - Set the custom value of (Triggering unit) to 1
          • Custom script: call RemoveLocation(udg_T1Treciever)
        • Else - Actions
 
Level 7
Joined
Dec 8, 2005
Messages
319
hmm then why am i getting compile errors? better yet. would anyone want to download my map and see if they want to check though my triggers. just have to add some comments but most of it is straight forward. but no point in making a game with leaks and bugs but then again having errors does not help either. and yes this is TFT editor
 
Level 7
Joined
Dec 8, 2005
Messages
319
anyone got any ideas on whats going wrong? but only thing i can think of but dont know why it would effect. if my variables are being used in multiply local triggers... then would that cause a problem? i mean they are all being set to the same region but still could that cause a problem?
 
Level 5
Joined
Aug 16, 2007
Messages
149
sometimes when you get compile errors, it shows th errors in the wrong places. Post all triggers with custom script in.
 
Level 7
Joined
Dec 8, 2005
Messages
319
honestly... that is about 30 triggers. and when i look at the problem... sometimes it does not make sense. like my post #42 it says it is my else that is causing the problem... and as you can see... there is nothin in the else. so why would it matter. and putting do nothing does not matter either way. so i am really confused. it would be easier to let you DL the map and look at it your self... i dont really have anything to steal. since it is not working
(haha) oh wait =(
but either way i could post all the triggers if you really want.
 
Level 5
Joined
Aug 16, 2007
Messages
149
Post them each in a hidden block like this:
All triggers like this would make them easier to read.
 
Level 7
Joined
Dec 8, 2005
Messages
319
Ok well the second time i make this... i guess the hiveworkshop was down the second i posted it... yay ok so i will label them to help you follow along. enjoy.

  • Spawn Team1
    • Events
      • Time - Every 2.00 seconds of game time
    • Conditions
    • Actions
      • Set T1Fspawner = Team1 First Spawner <gen>
      • Set T1Sspawner = Team1 Second Spawner <gen>
      • Set T1Tspawner = Team1 Third Spawner <gen>
      • Set T1FHspawner = Team1 FourthSpawner <gen>
      • Unit - Create 1 Sea Giant for Player 10 (Light Blue) at (Center of T1Fspawner) facing Default building facing degrees
      • Unit - Create 1 Sea Giant for Player 10 (Light Blue) at (Center of T1Sspawner) facing Default building facing degrees
      • Unit - Create 1 Sea Giant for Player 10 (Light Blue) at (Center of T1Tspawner) facing Default building facing degrees
      • Unit - Create 1 Sea Giant for Player 10 (Light Blue) at (Center of T1FHspawner) facing Default building facing degrees
      • Custom script: call RemoveLocation(udg_T1Fspawner)
      • Custom script: call RemoveLocation(udg_T1Sspawner)
      • Custom script: call RemoveLocation(udg_T1Tspawner)
      • Custom script: call RemoveLocation(udg_T1FHspawner)
  • Spawn Team2
    • Events
      • Time - Every 2.00 seconds of game time
    • Conditions
    • Actions
      • Set T2Fspawner = Team2 First Spawner <gen>
      • Set T2Sspawner = Team2 Second Spawner <gen>
      • Set T2Tspawner = Team2 Third Spawner <gen>
      • Set T2FHspawner = Team2 Fourth Spawner <gen>
      • Unit - Create 1 Sea Giant for Player 9 (Gray) at (Center of T2Fspawner) facing Default building facing degrees
      • Unit - Create 1 Sea Giant for Player 9 (Gray) at (Center of T2Sspawner) facing Default building facing degrees
      • Unit - Create 1 Sea Giant for Player 9 (Gray) at (Center of T2Tspawner) facing Default building facing degrees
      • Unit - Create 1 Sea Giant for Player 9 (Gray) at (Center of T2FHspawner) facing Default building facing degrees
      • Custom script: call RemoveLocation(udg_T2Fspawner)
      • Custom script: call RemoveLocation(udg_T2Sspawner)
      • Custom script: call RemoveLocation(udg_T2Tspawner)
      • Custom script: call RemoveLocation(udg_T2FHspawner)
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

  • Move Team1 First to Third
    • Events
      • Unit - A unit enters Team1 First Spawner <gen>
    • Conditions
    • Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • (Owner of (Triggering unit)) Equal to Player 10 (Light Blue)
        • Then - Actions
          • Set T1Treciever = Team1 Third Receive <gen>
          • Unit - Set life of (Triggering unit) to Percentageofunit%
          • Unit - Order (Triggering unit) to Move To (Center of T1Treciever)
          • Unit - Set the custom value of (Triggering unit) to 1
          • Custom script: call RemoveLocation(udg_T1Treciever)
        • Else - Actions
  • Move Team1 Second to Forth
    • Events
      • Unit - A unit enters Team1 Second Spawner <gen>
    • Conditions
    • Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • (Owner of (Triggering unit)) Equal to Player 10 (Light Blue)
        • Then - Actions
          • Set T1FHreciever = Team1 Forth Receive <gen>
          • Unit - Set life of (Triggering unit) to Percentageofunit%
          • Unit - Order (Triggering unit) to Move To (Center of T1FHreciever)
          • Unit - Set the custom value of (Triggering unit) to 2
          • Custom script: call RemoveLocation(udg_T1FHreciever)
        • Else - Actions
  • Move Team1 Third to Fifth
    • Events
      • Unit - A unit enters Team1 Third Spawner <gen>
    • Conditions
    • Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • (Owner of (Triggering unit)) Equal to Player 10 (Light Blue)
        • Then - Actions
          • Set T1Freciever = Team1 Fifth Receive <gen>
          • Unit - Set life of (Triggering unit) to Percentageofunit%
          • Unit - Order (Triggering unit) to Move To (Center of T1Freciever)
          • Unit - Set the custom value of (Triggering unit) to 3
          • Custom script: call RemoveLocation(udg_T1Freciever)
        • Else - Actions
  • Move Team1 Fourth to Bot
    • Events
      • Unit - A unit enters Team1 FourthSpawner <gen>
    • Conditions
    • Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • (Owner of (Triggering unit)) Equal to Player 10 (Light Blue)
        • Then - Actions
          • Set T1Bot = Team1 Bottom Sender <gen>
          • Unit - Set life of (Triggering unit) to Percentageofunit%
          • Unit - Order (Triggering unit) to Move To (Center of T1Bot)
          • Unit - Set the custom value of (Triggering unit) to 4
          • Custom script: call RemoveLocation(udg_T1Bot)
        • Else - Actions
  • Move Team1 Bot to Top
    • Events
      • Unit - A unit enters Team1 Bottom Sender <gen>
    • Conditions
    • Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • (Owner of (Triggering unit)) Equal to Player 10 (Light Blue)
          • (Custom value of (Triggering unit)) Equal to 4
        • Then - Actions
          • Set T1Top = Team1 Top Sender <gen>
          • Set T1Sreciever = Team1 Second Receive <gen>
          • Unit - Move (Triggering unit) instantly to (Center of T1Top)
          • Unit - Order (Triggering unit) to Move To (Center of T1Sreciever)
          • Custom script: call RemoveLocation(udg_T1Top)
          • Custom script: call RemoveLocation(udg_T1Sreciever)
        • Else - Actions
  • ReSend Team1 Second
    • Events
      • Unit - A unit enters Team1 Second Receive <gen>
    • Conditions
      • (Owner of (Triggering unit)) Equal to Player 10 (Light Blue)
      • (Custom value of (Triggering unit)) Equal to 4
    • Actions
      • Set T1FHresend = Team1 Forth ReSend <gen>
      • Set T1Bot = Team1 Bottom Sender <gen>
      • Unit - Move (Triggering unit) instantly to (Center of T1FHresend)
      • Unit - Order (Triggering unit) to Move To (Center of T1Bot)
      • Custom script: call RemoveLocation(udg_T1FHresend)
      • Custom script: call RemoveLocation(udg_T1Bot)
  • ReSend Team1 Third
    • Events
      • Unit - A unit enters Team1 Third Receive <gen>
    • Conditions
      • (Owner of (Triggering unit)) Equal to Player 10 (Light Blue)
      • (Custom value of (Triggering unit)) Equal to 1
    • Actions
      • Set T1Fresend = Team1 First ReSend <gen>
      • Set T1Treciever = Team1 Third Receive <gen>
      • Unit - Move (Triggering unit) instantly to (Center of T1Fresend)
      • Unit - Order (Triggering unit) to Move To (Center of T1Treciever)
      • Custom script: call RemoveLocation(udg_T1Fresend)
      • Custom script: call RemoveLocation(udg_T1Treciever)
  • ReSend Team1 Forth
    • Events
      • Unit - A unit enters Team1 Forth Receive <gen>
    • Conditions
      • (Owner of (Triggering unit)) Equal to Player 10 (Light Blue)
      • (Custom value of (Triggering unit)) Equal to 2
    • Actions
      • Set T1Sresend = Team1 Second Receive <gen>
      • Set T1FHreciever = Team1 Forth Receive <gen>
      • Unit - Move (Triggering unit) instantly to (Center of T1Sresend)
      • Unit - Order (Triggering unit) to Move To (Center of T1FHreciever)
      • Custom script: call RemoveLocation(udg_T1Sresend)
      • Custom script: call RemoveLocation(udg_T1FHreciever)
  • ReSend Team1 Fifth
    • Events
      • Unit - A unit enters Team1 Fifth Receive <gen>
    • Conditions
      • (Owner of (Triggering unit)) Equal to Player 10 (Light Blue)
      • (Custom value of (Triggering unit)) Equal to 3
    • Actions
      • Set T1Tresend = Team1 Third ReSend <gen>
      • Set T1Freciever = Team1 Fifth Receive <gen>
      • Unit - Move (Triggering unit) instantly to (Center of T1Tresend)
      • Unit - Order (Triggering unit) to Move To (Center of T1Freciever)
      • Custom script: call RemoveLocation(udg_T1Tresend)
      • Custom script: call RemoveLocation(udg_T1Freciever)
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

  • Move Team2 First to Third
    • Events
      • Unit - A unit enters Team2 First Spawner <gen>
    • Conditions
    • Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • (Owner of (Triggering unit)) Equal to Player 9 (Gray)
        • Then - Actions
          • Set T2Treciever = Team2 Third Receive <gen>
          • Unit - Set life of (Triggering unit) to Percentageofunit%
          • Unit - Order (Triggering unit) to Move To (Center of T2Treciever)
          • Unit - Set the custom value of (Triggering unit) to 1
          • Custom script: call RemoveLocation(udg_T2Treciever)
        • Else - Actions
  • Move Team2 Second to Forth
    • Events
      • Unit - A unit enters Team2 Second Spawner <gen>
    • Conditions
    • Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • (Owner of (Triggering unit)) Equal to Player 9 (Gray)
        • Then - Actions
          • Set T2FHreciever = Team2 Forth Receive <gen>
          • Unit - Set life of (Triggering unit) to Percentageofunit%
          • Unit - Order (Triggering unit) to Move To (Center of T2FHreciever)
          • Unit - Set the custom value of (Triggering unit) to 2
          • Custom script: call RemoveLocation(udg_T2FHreciever)
        • Else - Actions
  • Move Team2 Third to Fifth
    • Events
      • Unit - A unit enters Team2 Third Spawner <gen>
    • Conditions
    • Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • (Owner of (Triggering unit)) Equal to Player 9 (Gray)
        • Then - Actions
          • Set T2Freciever = Team2 Fifth Receive <gen>
          • Unit - Set life of (Triggering unit) to Percentageofunit%
          • Unit - Order (Triggering unit) to Move To (Center of T2Freciever)
          • Unit - Set the custom value of (Triggering unit) to 3
          • Custom script: call RemoveLocation(udg_T2Freciever)
        • Else - Actions
  • Move Team2 Fourth to Bot
    • Events
      • Unit - A unit enters Team2 Fourth Spawner <gen>
    • Conditions
    • Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • (Owner of (Triggering unit)) Equal to Player 9 (Gray)
        • Then - Actions
          • Set T2Bot = Team2 Bottom Sender <gen>
          • Unit - Set life of (Triggering unit) to Percentageofunit%
          • Unit - Order (Triggering unit) to Move To (Center of T2Bot)
          • Unit - Set the custom value of (Triggering unit) to 4
          • Custom script: call RemoveLocation(udg_T2Bot)
        • Else - Actions
  • Move Team2 Bot to Top
    • Events
      • Unit - A unit enters Team2 Bottom Sender <gen>
    • Conditions
    • Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • (Owner of (Triggering unit)) Equal to Player 9 (Gray)
          • (Custom value of (Triggering unit)) Equal to 4
        • Then - Actions
          • Set T2Top = Team2 Top Sender <gen>
          • Set T2Sreciever = Team2 Second Receive <gen>
          • Unit - Move (Triggering unit) instantly to (Center of T2Top)
          • Unit - Order (Triggering unit) to Move To (Center of T2Sreciever)
          • Custom script: call RemoveLocation(udg_T2Top)
          • Custom script: call RemoveLocation(udg_T2Sreciever)
        • Else - Actions
  • ReSend Team2 Second
    • Events
      • Unit - A unit enters Team2 Second Receive <gen>
    • Conditions
      • (Owner of (Triggering unit)) Equal to Player 9 (Gray)
      • (Custom value of (Triggering unit)) Equal to 4
    • Actions
      • Set T2FHresend = Team2 Fourth ReSend <gen>
      • Set T2Bot = Team2 Bottom Sender <gen>
      • Unit - Move (Triggering unit) instantly to (Center of T2FHresend)
      • Unit - Order (Triggering unit) to Move To (Center of T2Bot)
      • Custom script: call RemoveLocation(udg_T2FHresend)
      • Custom script: call RemoveLocation(udg_T2Bot)
  • ReSend Team2 Third
    • Events
      • Unit - A unit enters Team2 Third Receive <gen>
    • Conditions
      • (Owner of (Triggering unit)) Equal to Player 9 (Gray)
      • (Custom value of (Triggering unit)) Equal to 1
    • Actions
      • Set T2Fresend = Team2 First ReSend <gen>
      • Set T2Treciever = Team2 Third Receive <gen>
      • Unit - Move (Triggering unit) instantly to (Center of T2Fresend)
      • Unit - Order (Triggering unit) to Move To (Center of T2Treciever)
      • Custom script: call RemoveLocation(udg_T2Fresend)
      • Custom script: call RemoveLocation(udg_T2Treciever)
  • ReSend Team2 Forth
    • Events
      • Unit - A unit enters Team2 Forth Receive <gen>
    • Conditions
      • (Owner of (Triggering unit)) Equal to Player 9 (Gray)
      • (Custom value of (Triggering unit)) Equal to 2
    • Actions
      • Set T2Sresend = Team2 Second ReSend <gen>
      • Set T2FHreciever = Team2 Forth Receive <gen>
      • Unit - Move (Triggering unit) instantly to (Center of T2Sresend)
      • Unit - Order (Triggering unit) to Move To (Center of T2FHreciever)
      • Custom script: call RemoveLocation(udg_T2Sresend)
      • Custom script: call RemoveLocation(udg_T2FHreciever)
  • ReSend Team2 Fifth
    • Events
      • Unit - A unit enters Team2 Fifth Receive <gen>
    • Conditions
      • (Owner of (Triggering unit)) Equal to Player 9 (Gray)
      • (Custom value of (Triggering unit)) Equal to 3
    • Actions
      • Set T2Tresend = Team2 Third ReSend <gen>
      • Set T2Freciever = Team2 Fifth Receive <gen>
      • Unit - Move (Triggering unit) instantly to (Center of T2Tresend)
      • Unit - Order (Triggering unit) to Move To (Center of T2Freciever)
      • Custom script: call RemoveLocation(udg_T2Tresend)
      • Custom script: call RemoveLocation(udg_T2Freciever)

ok that is all of them... enjoy and tell me if you have an questions
 
Level 12
Joined
Aug 18, 2006
Messages
1,193
your problem is that you arent using any Points

even if you used "RemoveRect" instead of "RemoveLocation"(which will cause the triggers to work) you wouldnt be leak free

convert all your Region variables that you are trying to Leak-Fix and make them into Point variables and make them (Center of (Whatever Region)) instead. This is how to remove Point Leaks
 
Status
Not open for further replies.
Top