Staredit Network

Staredit Network -> UMS Assistance -> center over multiple units
Report, edit, etc...Posted by l)ark_13 on 2005-05-29 at 17:49:03
I know you cant center one location over multiple of the same unit for the same player... So I thought I'd try the grid system. I give the unit to another player and center the location around it until I have centered the location around all the units, then I start over. What I wanted was when a zergling touched the unit it would die, but this didn't happen. I know that the "give unit to diff player" trigger is working because you cant select the unit (because it deselcts it for you because of diff player..) but the location isn't going to all the units, only the very last one. Does anyone have any ideas how I can get this to work?
Report, edit, etc...Posted by MapUnprotector on 2005-05-29 at 17:53:49
After each unit has had a location centered on it, are you giving all of the units back to the original player so that the cycle can start all over again? And what are the exact triggers you are using?

Also, if you are doing a maze type thing with the zergling dying when it touches a unit, you can just center a unit on the zergling constantly.
Report, edit, etc...Posted by l)ark_13 on 2005-05-29 at 18:08:10
No, its not a bound. There are multiple zergling of a computer player. Im actually not giving all the units back to the player at the end, so I'll try that. Thank you.

ADDITION:
Okay, its still not working. These are my triggers, they are probably wrong. Go easy on me if they are tongue.gif

Conditions:
Always

Actions:
PreserveTrigger();
GiveUnits(All, Psi Emitter, All Players, Anywhere, P1);
MoveLocation(center around mines, Psi Emitter, P1, Anywhere);
GiveUnits(1, Psi Emitter, P1, Anywhere, P2);
MoveLocation(center around mines, Psi Emitter, P1, Anywhere);
GiveUnits(All, Psi Emitter, All Players, Anywhere, P1);
GiveUnits(2, Psi Emitter, P1, Anywhere, P2);
MoveLocation(center around mines, Psi Emitter, P1, Anywhere);
GiveUnits(All, Psi Emitter, All Players, Anywhere, P1);
GiveUnits(3, Psi Emitter, P1, Anywhere, P2);
MoveLocation(center around mines, Psi Emitter, P1, Anywhere);
GiveUnits(All, Psi Emitter, All Players, Anywhere, P1);
GiveUnits(4, Psi Emitter, P1, Anywhere, P2);
MoveLocation(center around mines, Psi Emitter, P1, Anywhere);
GiveUnits(All, Psi Emitter, All Players, Anywhere, P1);
GiveUnits(5, Psi Emitter, P1, Anywhere, P2);
MoveLocation(center around mines, Psi Emitter, P1, Anywhere);
GiveUnits(All, Psi Emitter, All Players, Anywhere, P1);
GiveUnits(6, Psi Emitter, P1, Anywhere, P2);
MoveLocation(center around mines, Psi Emitter, P1, Anywhere);

If you cant read that then I'll reword it into the human language tongue.gif
Report, edit, etc...Posted by MapUnprotector on 2005-05-29 at 18:12:14
Um, it won't work if you have it all in one trigger, because then when your other trigger runs to detect if the zergling touches anything it will only be on the last one as you said before.

You need to make one trigger like this

Condition:
Currentplayer(or w/e has the units) commands at least 1 psi emitter

Actions:
GiveUnits(1, Psi Emitter, currentplayer, Anywhere, P1);
MoveLocation(center around mines, Psi Emitter, P1, Anywhere);
PreserveTriger();

Then another one

Condition:
Currentplayer commands exactly 0 psi emitter

Actions:
GiveUnits(All, Psi Emitter,p1, Anywhere, currentplayer);
PreserveTrigger();

The psi emitters are stationary right?
Report, edit, etc...Posted by l)ark_13 on 2005-05-29 at 18:26:22
Yes, the emitters are stationary. But, that trigger wont work because I have around 7 psi emitters. Unless, if I say I command seven psi emitters I would give the psi emitters one by one until I give seven (which is what I'm doing with the first trigger, I think). If you misunderstood me, I will restate what I want to do:

I use the grid system to center one location over multiple units. So, I have 7 psi emitters and I use the grid system to give the psi emitters in order so I can center a location around all of them quickly. I know this should be pretty simple but its just not working.
Report, edit, etc...Posted by MapUnprotector on 2005-05-29 at 18:28:06
Those triggers WILL work if the units are stationary. SC gives units and centers locations over same units owned by same player in a certain way.
Report, edit, etc...Posted by LegacyWeapon on 2005-05-29 at 18:35:17
QUOTE(l)ark_13 @ May 29 2005, 06:26 PM)
Yes, the emitters are stationary.  But, that trigger wont work because I have around 7 psi emitters.  Unless, if I say I command seven psi emitters I would give the psi emitters one by one until I give seven (which is what I'm doing with the first trigger, I think).  If you misunderstood me, I will restate what I want to do:

I use the grid system to center one location over multiple units.  So, I have 7 psi emitters and I use the grid system to give the psi emitters in order so I can center a location around all of them quickly.  I know this should be pretty simple but its just not working.
[right][snapback]220457[/snapback][/right]
The reason your trigger wont work is because another trigger cannot run inside the first one.
QUOTE(ICL @ May 29 2005, 06:28 PM)
Those triggers WILL work if the units are stationary. SC gives units and centers locations over same units owned by same player in a certain way.
[right][snapback]220460[/snapback][/right]
Even if the units weren't stationary, I'm sure it will work.

ICL's triggers should work.
Report, edit, etc...Posted by l)ark_13 on 2005-05-29 at 18:37:22
Okay, actually I just got it working. My trigger was right, but I just needed to add a "Wait 0" in between the "center location" and "give all the emitters back to the player". Thanks though ICL and LegacyWeapon.
Report, edit, etc...Posted by MapUnprotector on 2005-05-29 at 18:37:35
To legacy- Naw they wouldn't work if the units weren't stationary, you would have to rearrange the trigger a bit

You would need to first center the location on the unit then give it away to another player, so that it would always center on a unit that hasn't had a location centered on it yet.

To l)ark_13- Lol... the wait just makes the other trigger run and stops your trigger, it's a really bad solution closedeyes.gif
Report, edit, etc...Posted by l)ark_13 on 2005-05-29 at 18:56:30
No actually, the waits just (sorta) break up the trigger and give it a little wait time... Even though it says wait "0". It doesn't stop all the other trigger or anything. You also use the wait 0 for the dropship spell system when reloading the units, or at least from my experience it works much better because of the wait 0.
If it matters, I have hyper triggers. I usually never use waits but I dont see how wait "0" could mess anything up, especially with HP's.
Report, edit, etc...Posted by MapUnprotector on 2005-05-29 at 18:57:31
It breaks up the trigger because during the wait it goes through other triggers. It could screw up other triggers because of that wait.

If what you said was true and just gave the trigger a little more wait time, it wouldn't do anything because the other trigger wouldn't run. But it does run due to how wait triggers work.

QUOTE
If it matters, I have hyper triggers. I usually never use waits but I dont see how wait "0" could mess anything up, especially with HP's.


What do you think HP are made of? Waits! And look at how they affect triggers.
Report, edit, etc...Posted by l)ark_13 on 2005-05-29 at 19:00:00
Well as far as I can tell everything is still working, and I solved my problem. tongue.gif Thanks happy.gif

Lol, theres 63 of those waits in a row, then multiplied a few times. I have 4 or 5 waits, broken up. It wont affect anything. wink.gif
Report, edit, etc...Posted by MapUnprotector on 2005-05-29 at 19:01:22
Meh, I just don't like your trigger tongue.gif

BTW: My method is also one of the grid methods.
Report, edit, etc...Posted by (U)Bolt_Head on 2005-05-29 at 22:35:52
Devilesk Adding waits will be just fine and not any different than yours the way you listed it.

Because the units are given back to the primary owner in the same trigger it is impossible for that action to fire out of sequence. The way i prefer to do it is like Devilesk does it EXCEPT I would make multiple copies of the triggers.

Now lets assume that instead of 7 psi emitters you had 100 or some a large number where it would take a long time for them to all cycle though even with hyper triggers.

First what you would need to do is determine what your doing with that location at each spot. For Dark's trigger it is almost redundant because the function of the location is pure output and can be included in the same triggers that center the location.
But say you were giving players 'points' for being next to a psi emitter, another words you’re using the location as an input or detection.

So I’ll have say you need 3 triggers for this
Center Location
Detect Zergling, and
Reset Player

I would make several copies of the triggers like so.

Center Location
Detect Zergling
Center Location
Detect Zergling
Center Location
Detect Zergling
Center Location
Detect Zergling
Center Location
Detect Zergling
Center Location
Detect Zergling
Center Location
Detect Zergling
Reset Player

This way during every 'hyper stage' the trigger will run multiple times (cause there’s multiple copies)

This is the basic idea behind speeding up cycles Beyond the god-like speed of hyper triggers (Amakakeru Ryu no Hirameki).
Report, edit, etc...Posted by in_a_biskit on 2005-05-31 at 04:36:01
In fact, you probably don't need two separate triggers for centering and detecting at all.

Actions:
1. Center Location
2. Give Psi Emitter
3. Destroy Zerglings at Location
4. Preserve.

If you know that there are many Psi Emitters on the map, then repeat actions 1-3:

1. Center Location
2. Give Psi Emitter
3. Destroy Zerglings
4. Center Location
5. Give Psi Emitter
6. Destroy Zerglings
7. Center Location
8. Give Psi Emitter
. etc...
.
#. Give Psi Emitters back.
#. Preserve.

If there are too many units to cycle through, then don't give the Psi Emitters back; Copy the trigger as many times as needed to go through every Psi Emitter, then either on the last trigger, or on a new trigger at the end, reset the player.



It may be the case that you don't need any of this at all, if you just want a player's zergling to die when it touches a Psi Emitter, and the player has only one zergling.
In that case, simply always center a location on the zergling. If a Psi emitter is brought to the location, then kill the zergling.
Report, edit, etc...Posted by (U)Bolt_Head on 2005-05-31 at 14:57:10
QUOTE(in_a_biskit @ May 31 2005, 03:36 AM)
In fact, you probably don't need two separate triggers for centering and detecting at all.
[right][snapback]221851[/snapback][/right]


QUOTE((U)Bolt_Head @ May 29 2005, 09:35 PM)
For Dark's trigger it is almost redundant because the function of the location is pure output and can be included in the same triggers that center the location is in. 
But say you were giving players 'points' for being next to a psi emitter, another words you’re using the location as an input or detection.
[right][snapback]220660[/snapback][/right]


Yeah, but you arn't detecting it, your just killing it IF it is there.
Next Page (1)