FrozenShadow
I am a WolfieeifloW fan.
- Reaction score
- 75
Title says all
you forgot to add less laggy to that listbut definately get away from enter/leave triggers for each tower separately... that's just redundant and prone to bugs.
The Xel'Naga tower has a VERY simple ability. When a unit comes within range of it, it will select that unit and share sight with it. It's done via a few checked boxes by an "ability - interact" method.
It then has a power up actor that executes whenever it is in sight of another unit.
completely simple.
There are probably a few ways to go about bending it to your will; however, you will not be using one simple "ability - interact" method, as it is too simple for your need. (a unit can only "select" one unit at a time...)
You could use a periodic search ability on your xel'naga towers so that they choose all units within range every few seconds and share sight with all of them... fairly simple to accomplish.
The other way that I can think of is that you could just make ONE trigger that says:
Events: every 1 second of game time
--pick all units in (units within range of xel'naga tower1)
Actions: for each picked unit share vision... etc.
but definately get away from enter/leave triggers for each tower separately... that's just redundant and prone to bugs.
Ok that last statement confusled the bajinxses out of me...
you want it to be active for only one person at a time... so... like it works now? I thought the idea was that if one player activated the tower then all players could see the area around the tower... if not, then you're going to have restate what you want exactly.
bugs... hmmm... off the top of my head...
well for one thing you are using "a unit leaves zone" as an action. What if the unit dies? or explodes... or is transported away from the zone with the mothership ability. You have to cover all your bases to make sure that the "leaves zone" action is going to pick up on all the various different possibilities.
Sometimes such an action might not fire correctly if several units are entering and leaving all at once. There might be small time increments that have to be obeyed for it to fire. A unit also could leave as one is entering and the entering trigger would fire right before the leaving trigger, thus there would be a unit at the xel naga, but it would be turned off. Also, you won't be able to really test for a lot of these situations because they can have a small rate of occurrence or might just not present themselves up front during your tests. Chances are, you have been testing with only a few units in a very controlled situation as it is.
Usually actions are much more simplistic than you would hope for when you first make your trigger. It's up to you to think of these things. You also don't want to have 4 triggers controlling one simple task. it gets messy.
Well it's kind of funky form but it will do then I suppose. I would still look into situations such as custom hero abilities warping or pushing units around via knockback or the such. There could be something that comes up later and you would just have to revisit this issue again worst case.
As long as it works, who am I to complain? Good luck with your map!