Need help with Anti Camp trigger

For fulfilled maps that most likely don't work on the latest patch (1.24 or later).

Moderator: Cheaters

Darkness568
Member
Posts: 97
Joined: June 18th, 2007, 12:45 am

Need help with Anti Camp trigger

Post by Darkness568 »

Hi, i have been trying to create a clan tree tag map and the one i have currently has no anti camping trigger and the one i have made just doesnt work as it doesnt check whether or not the unit is within the region specified for the whole duration.

If someone could help me make one that would be great, but here is what i got so far. I have repeated this trigger 3 times each specifying the other infernal enemy unit so it doesnt camp the center or rescuing zone.

Events

Unit a unit comes within 600 of Sentry Ward 0019 <gen> (ward is in center of the anti camp area)

Conditions
Actions
if all conditions are true then do then actions else do else actions
if conditions unit type of triggering unit equal to Infernal Agi

Then Actions

Unit Move triggering unit instantly to center of camptele1
Game display to all players the text |cffff0000No Spawn Camping!!!

Else Actions
Do nothing

I would also to maybe make it so that it will randomly appear at one of the 4 regions where one is slightly north west east and south of the camping zone.
User avatar
Syre
Forum Staff
Posts: 506
Joined: November 17th, 2008, 3:49 pm

Re: Need help with Anti Camp trigger

Post by Syre »

Here, i made for ya. Its..a little different than you wanted, as ive made a timer that has ten seconds before it kicks the unit out of the spawn. You can change the time to whatever. But first, ill tell you what you need to do to complete it, i only made it for Light blue, and only randomly spawning in two regions.

Code: Select all

Countdown Timer - Start Timer[1] as a One-shot timer that will expire in 10.00 seconds
This is a timer array, change the [1] to, 2 for dark green, and 3 for brown.

Code: Select all

Set TimerDisplay[1] = (Last created timer window)
Same thing for this one.

Code: Select all

Set RandomSpawn[1] = (Random integer number between 1 and 4)
and this one. Its all to make sure that the timers dont cancel eachother out.

Code: Select all

If (All Conditions are True) then do (Then Actions) else do (Else Actions)
    If - Conditions
        RandomSpawn[1] Equal to 1
    Then - Actions
        Unit Group - Pick every unit in (Units in Region 000 <gen>) and do (If ((Owner of (Picked unit)) Equal to Player 10 (Light Blue)) then do (Unit - Move (Picked unit) instantly to (Center of Region 001 <gen>)) else do (Do nothing))
        Countdown Timer - Destroy TimerDisplay[1]
        Trigger - Turn on LBTimer <gen>
    Else - Actions
        Do nothing
Notice that i made only two of these, this is the trigger that will make your infernal spawn in a random spot. You have to copy this, and paste it for the last two regions.

Code: Select all

RandomSpawn[1] Equal to 1
And finally, this part. Its the one that makes sure its random. For each part above, change the number from 1 to 4. (Not the one in the bracket) Just follow the example in the map.

Besides that, thats all. Its simply a job of C&P and changeing a few numbers.
You do not have the required permissions to view the files attached to this post.
Image
Darkness568
Member
Posts: 97
Joined: June 18th, 2007, 12:45 am

Re: Need help with Anti Camp trigger

Post by Darkness568 »

Thank you. I will test it out and see if i put it all in alright :p And thanks for the fast response.

One thing i just realized is that the infernals are not all the same. In the beginning of the game a multiboard shows up and each person can choose which infernal they want like a agi, str, and int one so how would i setup a variable to detect that or should i just add a unit type comparison and put each one in the trigger, but have the color of the player be separate so there r still 3 triggers for each player.
User avatar
Syre
Forum Staff
Posts: 506
Joined: November 17th, 2008, 3:49 pm

Re: Need help with Anti Camp trigger

Post by Syre »

No worries, after thinking about it for a bit, if you have units in your map that infernals spawn or don't click me, than they wouldent be detected by this trigger and would be able to camp the entire game. Just go ahead and remove the

Code: Select all

(Unit-type of (Triggering unit)) Equal to Infernal
from the trigger, as long as it works for the player color thats all you need.

Edit : I also forgot to mention that i dident add a message that says that the infernals been kicked out of the spawn, you may want to add that as well.
Image
Darkness568
Member
Posts: 97
Joined: June 18th, 2007, 12:45 am

Re: Need help with Anti Camp trigger

Post by Darkness568 »

So by removing that instead of detecting unit it just detects the player and unit controlled and owned by lb, dg, and brown. Also i noticed that if there is no player operating the infernal the timer appears, but doesnt countdown and doesnt disappear.
Last edited by Darkness568 on July 11th, 2009, 12:46 am, edited 1 time in total.
User avatar
Syre
Forum Staff
Posts: 506
Joined: November 17th, 2008, 3:49 pm

Re: Need help with Anti Camp trigger

Post by Syre »

Exactly. Which is pretty much all you will need for this kind of map. Making the conditions unit-specific would be a waste of time and space that you could go without.
Image
Darkness568
Member
Posts: 97
Joined: June 18th, 2007, 12:45 am

Re: Need help with Anti Camp trigger

Post by Darkness568 »

Alright, but now my problem is that the brown timer even though i am brown isnt counting down and the timer just says brown anti camp and then a blank of where the countdown should go. here is the expires trigger for him.
Spoiler:

Code: Select all

BrownExpires
    Events
        Time - Timer[3] expires
    Conditions
    Actions
        Set RandomSpawn[1] = (Random integer number between 1 and 4)
        If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            If - Conditions
                RandomSpawn[1] Equal to 1
            Then - Actions
                Unit Group - Pick every unit in (Units in CampZone <gen>) and do (If ((Owner of (Picked unit)) Equal to Player 12 (Brown)) then do (Unit - Move (Picked unit) instantly to (Center of Camptele1 <gen>)) else do (Do nothing))
                Countdown Timer - Destroy TimerDisplay[3]
                Trigger - Turn on LBTimer <gen>
            Else - Actions
                Do nothing
        If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            If - Conditions
                RandomSpawn[1] Equal to 2
            Then - Actions
                Unit Group - Pick every unit in (Units in CampZone <gen>) and do (If ((Owner of (Picked unit)) Equal to Player 12 (Brown)) then do (Unit - Move (Picked unit) instantly to (Center of Campetele3 <gen>)) else do (Do nothing))
                Countdown Timer - Destroy TimerDisplay[3]
                Trigger - Turn on LBTimer <gen>
            Else - Actions
                Do nothing
        If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            If - Conditions
                RandomSpawn[1] Equal to 3
            Then - Actions
                Unit Group - Pick every unit in (Units in CampZone <gen>) and do (If ((Owner of (Picked unit)) Equal to Player 12 (Brown)) then do (Unit - Move (Picked unit) instantly to (Center of Camptele2 <gen>)) else do (Do nothing))
                Countdown Timer - Destroy TimerDisplay[3]
                Trigger - Turn on LBTimer <gen>
            Else - Actions
                Do nothing
        If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            If - Conditions
                RandomSpawn[1] Equal to 4
            Then - Actions
                Unit Group - Pick every unit in (Units in CampZone <gen>) and do (If ((Owner of (Picked unit)) Equal to Player 12 (Brown)) then do (Unit - Move (Picked unit) instantly to (Center of Camptele4 <gen>)) else do (Do nothing))
                Countdown Timer - Destroy TimerDisplay[3]
                Trigger - Turn on LBTimer <gen>
            Else - Actions
                Do nothing
And heres the timer
Spoiler:

Code: Select all

BrownTimer
    Events
        Unit - A unit enters CampZone <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 12 (Brown)
            Then - Actions
                Countdown Timer - Start Timer[3] as a One-shot timer that will expire in 10.00 seconds
                Countdown Timer - Create a timer window for Timer[2] with title |cff5C4033Brown Ant...
                Set TimerDisplay[3] = (Last created timer window)
                Countdown Timer - Change the color of the title for TimerDisplay[3] to (100.00%, 0.00%, 0.00%) with 0.00% transparency
                Trigger - Turn off (This trigger)
            Else - Actions
                Do nothing
Also i noticed that if the infernals dont have players controlling them like they leave or something or are just bots there is no timer countdown for them and does the same thing as browns timer was doing.

Hmm seems after i fixed that timer issue with it turning on the lb timer trigger it keeps doing it. all the triggers are the same and yet i cant get brown working.
User avatar
Syre
Forum Staff
Posts: 506
Joined: November 17th, 2008, 3:49 pm

Re: Need help with Anti Camp trigger

Post by Syre »

Here, i just completed it for all three colors. Try it out, see if it works. If it does, transfer it to your map, or just compare whats different.
You do not have the required permissions to view the files attached to this post.
Image
Darkness568
Member
Posts: 97
Joined: June 18th, 2007, 12:45 am

Re: Need help with Anti Camp trigger

Post by Darkness568 »

Is Time - Timer[3] supposed to be 1 for all of them??? Otherwise they all appear to be the same. I will pm you the map. The updated triggers with the other colors are also contained in it.
User avatar
Syre
Forum Staff
Posts: 506
Joined: November 17th, 2008, 3:49 pm

Re: Need help with Anti Camp trigger

Post by Syre »

No, the number in brackets are for each color. So [1] is Light blue. [2] is Dark Green, and [3] would be for Brown. This is so that you wont have to make sperate variables for each color. So like you wont need Time - TimerLB, Time - TimerDG, Time - TimerBrown. Each one of those timers are a seperate variable, while the one we have now Timer[1], only uses one, but its an array so it doesnt mess with other ones.
Image