Staredit Network

Staredit Network -> UMS Assistance -> Dropships and Men...
Report, edit, etc...Posted by yoni45 on 2006-05-05 at 15:01:37
Before I get into specifics I'll give the gist of what I'm trying to do:

before the "matches" part of the game starts, each player has a bunch of units in his base...

At this point, each player's units are removed one by one with hypertriggers and various death counters keep track of which units each player had every time a unit is removed...

Now the dilemma is, what if a player has transports with units inside... So my idea is simply to remove transports last, as units inside the transports would be removed from inside the transport...

However, considering each unit being removed his its own trigger attached to it, there's no actual way to set priority of who gets removed first or last...

Unless, one possibility is to set a condition to remove a dropship IF there are no OTHER units around that are owned by that particular player...

However, how would I differentiate between dropships and "ALL OTHER" units? (without 38 conditions that go along the lines of current player brings exactly 0 unit1 to certain area, done through unit 38...; if need be this can be done, but i'd prefer not to...)

Dropships count as "Men", correct? (if they don't, then problem solved, but i'm fairly sure they do...)

Any ideas?
Report, edit, etc...Posted by Daedalus on 2006-05-05 at 15:27:36
There are a lot of different methods to accomplish that. The first one here is a good one, but I think your real goal is to to have the units in the transports to be counted as well, if that's right then use the second method.

- Give the dropships temporarily to another player then remove all the units for current player and he hasn't got any units left you can give the dropship back to the current player.

- Make a location called "air". Go to the properties of that location and uncheck all the properties except 'mid air'. Units inside a transport are located there. So with one extra trigger you can let them exit the transport (using Run Ai Script At Location action) so they will be counted as well.

EDIT: To answer your other question: yes, dropships also count as 'Men'. In fact ALL normal units count as Men. Only recources and powerups and things like that are not included in the Men group.
Report, edit, etc...Posted by yoni45 on 2006-05-05 at 15:32:01
QUOTE(Daedalus @ May 5 2006, 01:27 PM)
There are a lot of different methods to accomplish that. The first one here is a good one, but I think your real goal is to to have the units in the transports to be counted as well, if that's right then use the second method.

- Give the dropships temporarily to another player then remove all the units for current player and he hasn't got any units left you can give the dropship back to the current player.

- Make a location called "air". Go to the properties of that location and uncheck all the properties except 'mid air'. Units inside a transport are located there. So with one extra trigger you can let them exit the transport (using Run Ai Script At Location action) so they will be counted as well.

EDIT: To answer your other question: yes, dropships also count as 'Men'. In fact ALL normal units count as Men. Only recources and powerups and things like that are not included in the Men group.
[right][snapback]480063[/snapback][/right]


would i be able to simply Move units in midair to a ground location? The thing is all of these triggers have to be down within seconds, with no wait time that can hold up the game...
Report, edit, etc...Posted by Daedalus on 2006-05-05 at 15:51:10
Ehm, I just tested it and you won't have to worry about units within dropships. Since they are in the 'low air' field they are also in the 'anywhere' location. Your normal triggers which remove units which are not in a transport will also remove them from transports as long as you got 'low air' checked.
Report, edit, etc...Posted by Kenoli on 2006-05-05 at 17:03:30
Units in a transport could be in low, mid or high air, depending on what type of terrain the transport is flying over.

You can detect and remove units inside a transport, though there could be a slight problem. If you have multiple of the same type of unit in a transport and you try to remove one it will remove them all. (99.47% sure =P)

Alternatively you could force the units to exit the transports with an AI Script.
Report, edit, etc...Posted by yoni45 on 2006-05-05 at 19:47:27
heh we've gone a bit off topic... I know I can remove units from a transport, that's not a problem... my possible problem is removing units that are in a transport BEFORE removing the transport (since when removing the transport the units inside are lost)

when thinking of daedalus's first idea though, i got to thinking of this particular trigger set:

Trigger
Players:
¤ Competitors
Conditions:
¤ Current Player has At Least 1 Transport* in Bases
Actions:
¤ Move Location Empty Transport to Transport*
¤ Move All Units owned by Current Player at Empty Transport to Empty Transport
¤ remove Transport*
¤ Add death counter corresponding to transport


(where Transport is any unit that can carry units, OL, shuttle, or dropship)

Now, this assumes that

"Move All Units owned by Current Player at Empty Transport to Empty Transport"

would move all the units inside the transport to the ground underneath it...

The one other assumption i'm making is that the "transport" in question in the first action will be the same transport that's used in the 2nd trigger
Next Page (1)