Here's the information:
There are 8 builders and 4 vampires, each of the 8 builders have something called "Base Control" which is a circle of power in each of the base's entrances. Inside of their base is something called "Harvester Control"(which is the teleporter to the Green Areas) which is also a circle of power. By accessing the Harvester control, players can manage their Green Areas(What their Harvester Circle of Power teleports them to) which is an area their Harvesters teleport for trees and harvesting. Only the harvesters and the vampire can access the Green Area, the builders cannot. Because of this, there are 8 different Green Areas, which are not assigned to any builder until a Harvester from the owner of the Base, which the Harvester Control is in, is entered. (<--confusing sentence, I know) Also, the Bases are not owned until entered by a Builder. Sooooo.. the problem here for me is the following:
In my trigger, I recognize who is entering the base, setting all necessary conditions (IE: checking the color of the player, seeing if he already owns a Green Area, etc).. I also check if their Green Area is closed or opened depending on the Owner's choice (they might not want their teammate's harvesters in their area, so they have the option to close the harvester area to keep them from going inside)
So when the Builder first gets their Base, they still don't have a Green Area until they enter the Harvester Control circle of power, which RANDOMLY PICKS ONE OF THE 8 GREEN AREAS THAT ARE NOT CONTROLLED CURRENTLY and teleports their harvester to it, so after that happens, those two teleporters (the Harvester Control and the Green Area) are now connected.. so my problem is this: I cannot connect the two circle of powers together and assigned to that player.
This is what I've tried doing:
-using unit groups to easily and randomly teleport and link(which doesn't work for me for some odd reason)
So, as you can see, I hope you have enough information about my current situation concerning this trigger.
Long story short, I need the teleporters to link with eachother and also account the necessary conditions whenever the teleporter is entered by a vampire or a Harvester.
If you need any more information, let me know. Also, I can PM you the map if you're interested in seeing the triggers and my 100 variables for messy triggers (this is why I don't want to post it, it's very hard to understand the variables I use and the triggers associated with them)
Thanks to any help, and +rep to it as well.
Refer to the images on the bottom for additional information.
I want to tell you guys the conditions that I need to checked for when the Harvester Teleporter is first entered and after they're assigned here they are.
When it's first entered:
-Check which player (1-8)
-What base they own (1-9)
-If it's not the owner's Harvester that's entering, it won't do anything
-It only activates if the Harvester enters it, not vampire/builder
After the two teleporters are linked:
-Check if it's open/closed if it's not the owner's harvester
-check if it's a vampire
-Check if they still own the base that the harvester teleporter is in
-If it is closed, it will port the other harvesters to the side of the teleporter
Will add more if I missed anything.
CODE:
Here is how each of the triggers I'm linking work.
I made, in total, 24 triggers because I have 8 bases. (3 [the triggers] times[x] 8[How many bases there are)
The first three triggers are for Base 1 out of 8.
The first one is when the player's Harvester FIRST enters the Harvester Control Teleporter. It then moves the Harvester to a random unit from the HarvesterTP_Group(which is the green areas), after that, the trigger is turned off and the second trigger is then activated.
The second one activates when the unit ENTERS the green area, then it removes the Green Area Teleporter from the HarvesterTP_Group and puts it into the owner's TP group(PlayerHarvestArea1), this group will ONLY HAVE the player's Green Area Teleporter in it. This one is now turned off and the third one is activated.
The third one is turned on automatically with the second one. It just checks if the Green Area is closed, if it's a harvester or not, etc.. all those necessary conditions that I've stated previously.
Things you should know:
-P1B1, etc means he is player one and that he owns base 1, etc.
-Survivor = the Builder
-P1OPEN checks if the Harvester Control Teleporter is Open
-Base1Cntrl checks if the base is in control or not.
-InsideHarvester TP1 means he's inside the Green Area.
-HarvOpen checks if the player has an open Green Area for his teammates.
-Used unit groups to get the random teleports, then I remove the unit from the available Green Area Group and put it in the Player's Teleporter Group after to make them link.
-This is for the third trigger: "PlayerHarvestArea1" is the ONE unit inside the player's Teleporter Group, it is the green area.
Any other questions.. please lemme know.
FIRST TRIGGER:
Spoiler:
SECOND TRIGGER:
Spoiler:
THIRD TRIGGER:
Spoiler:
Note: Sorry for the HUGE wall of text, it's just that I'm not very good with the editor, and I've been asking on multiple help-sites and I never got the help I needed. Thanks to any help!