Very complicated zone capture trigger ...

obucke

Member
Reaction score
23
As i said in the thread name ... well here it is:
Code:
Tauren base enter
    Events
        Unit - A unit enters Tauren base circle <gen>
    Conditions
        ((Owner of Tauren Totem 0141 <gen>) is an ally of (Owner of (Triggering unit))) Equal to False
        ((Triggering unit) is A Hero) Equal to True
    Actions
        Set Tauren_capture_unit = (Triggering unit)
        Game - Display to (Player group((Owner of (Triggering unit)))) for 3.00 seconds the text: Now HOLD there for ...
        Set Tauren_tick = 0.00
        Trigger - Turn on Tauren tick <gen>
Code:
Tauren tick
    Events
        Time - Every 1.00 seconds of game time
    Conditions
    Actions
        Set Tauren_tick = (Tauren_tick + 1.00)
        Special Effect - Create a special effect at (Center of Tauren base circle <gen>) using Abilities\Spells\Orc\AncestralSpirit\AncestralSpiritCaster.mdl
        Set Tauren_base_takover = (Last created special effect)
        Floating Text - Create floating text that reads (String((Integer(Tauren_tick)))) at (Center of Tauren base circle <gen>) with Z offset 40.00, using font size 15.00, color (100.00%, 100.00%, 100.00%), and 0.00% transparency
        Wait 0.80 seconds
        Floating Text - Destroy (Last created floating text)
        Special Effect - Destroy Tauren_base_takover
this 1 is initialy off ...
Code:
Tauren base leave
    Events
        Unit - A unit leaves Tauren base circle <gen>
    Conditions
        (Triggering unit) Equal to Tauren_capture_unit
        ((Owner of Tauren Totem 0141 <gen>) is an ally of (Owner of (Triggering unit))) Equal to False
        ((Triggering unit) is A Hero) Equal to True
    Actions
        Trigger - Turn off Tauren tick <gen>
        Floating Text - Destroy (Last created floating text)
        Special Effect - Destroy Tauren_base_takover
Code:
Tauren base convert
    Events
        Game - Tauren_tick becomes Equal to 10.00
    Conditions
    Actions
        Unit Group - Add Tauren Totem 0141 <gen> to Tauren_base_buildings
        Unit Group - Add Tauren Field Quatermaster 0133 <gen> to Tauren_base_buildings
        Unit Group - Add Tauren Tent 0036 <gen> to Tauren_base_buildings
        Unit Group - Add Tauren Tent 0035 <gen> to Tauren_base_buildings
        Unit Group - Add Tauren Tent 0038 <gen> to Tauren_base_buildings
        Unit Group - Add Tauren Tent 0039 <gen> to Tauren_base_buildings
        Unit Group - Add Tauren Tent 0037 <gen> to Tauren_base_buildings
        Unit Group - Add Tauren 0143 <gen> to Tauren_base_buildings
        Unit Group - Add Tauren 0148 <gen> to Tauren_base_buildings
        Unit Group - Add Tauren 0149 <gen> to Tauren_base_buildings
        Unit Group - Add Circle of Power (large) 0120 <gen> to Tauren_base_buildings
        If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            If - Conditions
                ((Owner of Tauren_capture_unit) is an ally of Player 1 (Red)) Equal to True
            Then - Actions
                Unit Group - Pick every unit in Tauren_base_buildings and do (Actions)
                    Loop - Actions
                        Trigger - Turn off Tauren tick <gen>
                        Floating Text - Destroy (Last created floating text)
                        Special Effect - Destroy Tauren_base_takover
                        Unit Group - Pick every unit in Tauren_base_buildings and do (Unit - Change ownership of (Picked unit) to Player 1 (Red) and Change color)
            Else - Actions
                If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                    If - Conditions
                        ((Owner of Tauren_capture_unit) is an ally of Player 7 (Green)) Equal to True
                    Then - Actions
                        Unit Group - Pick every unit in Tauren_base_buildings and do (Actions)
                            Loop - Actions
                                Trigger - Turn off Tauren tick <gen>
                                Floating Text - Destroy (Last created floating text)
                                Special Effect - Destroy Tauren_base_takover
                                Unit Group - Pick every unit in Tauren_base_buildings and do (Unit - Change ownership of (Picked unit) to Player 7 (Green) and Change color)
                    Else - Actions
And heres the bug i get just in case u need some guidelines. The timer that is shown to the player in the form of floating text gets stuck sometimes ... and wont erase it self ... and thats the only thing ... the technical stuff works but its looks awful with this bugg some1 help me plz
 

Drunken_God

Hopes to get back into Mapmaking with SC2 :)
Reaction score
106
i dont read your triggers but
is it MPI?: more than one player can use it at the same time?

EDIT:
doesnt look MPI: e.g.
Code:
        Floating Text - Create floating text that reads (String((Integer(Tauren_tick)))) at (Center of Tauren base circle <gen>) with Z offset 40.00, using font size 15.00, color (100.00%, 100.00%, 100.00%), and 0.00% transparency
        Wait 0.80 seconds
        Floating Text - Destroy (Last created floating text)
 

oorosco

New Member
Reaction score
23
Ya, don't do the "destroy last created" do...
Code:
Floating Text - Change the lifespan of (Last created floating text) to 0.80 seconds
 

duderock101

Check out my 2 Player Co-op RPG!
Reaction score
71
havn't u overcompleticated ur triggers. I made sumthing like this but with a different means of doing it. It had no leaks, bugs or anything and it cud be done with 2 triggers...
 
General chit-chat
Help Users
  • No one is chatting at the moment.

      The Helper Discord

      Members online

      No members online now.

      Affiliates

      Hive Workshop NUON Dome World Editor Tutorials

      Network Sponsors

      Apex Steel Pipe - Buys and sells Steel Pipe.
      Top