OFPEC Forum

Editors Depot - Mission Editing and Scripting => OFP - Editing/Scripting General => Topic started by: Scratchdat on 16 Jan 2003, 00:20:05

Title: Basic: Giving A Group A Name
Post by: Scratchdat on 16 Jan 2003, 00:20:05
I never learned how to  :-[. lol

So how can u give a group a name:

e.g. if i wanted to do a script which needed a whole group instead of a single unit.
Title: Re:Basic: Giving A Group A Name
Post by: Tomb on 16 Jan 2003, 03:33:58
 :o INIT field of any GRP member must read :


Morons = Units Group This


 :D Then to use the named grp in a trigger/scroll, use this stuff :


"_x moveInCargo Chopper1" ForEach Morons

(this would instantly teleport the grp into some helo named "chopper1".)  :-*


[mod.] "any" GRP member = just ONE guy's INIT right?!
Title: Re:Basic: Giving A Group A Name
Post by: Chris Death on 16 Jan 2003, 18:51:43
Only one thing to take care about here:

If you are creating a multiplayer map (i know, this is general
editing section, but who knows for the future), and you have
a whole squad of playable soldiers. Think about the fact, that
each of these soldiers can be disabled from player selection
menu. So you can never be sure, which one will be present
when the game starts.

Therefore i'd suggest (only in this case) to:

Create a trigger with a radius as big as it covers the whole
group.

activation: side of the squad / present
condition: this
onActivation: Morons = group thislist select 0

Now you can be sure, that the group name "Morons" exists
in your multiplayer map.

~S~ CD
Title: Re:Basic: Giving A Group A Name
Post by: Tomb on 17 Jan 2003, 01:28:53
True that, crissy!  :D :-* Hek I didn't even know that (mp is a military copper to me!  ::) ;D )