Home   Help Search Login Register  

Author Topic: Assignment  (Read 513 times)

0 Members and 1 Guest are viewing this topic.

Robinhansen

  • Guest
Assignment
« on: 20 Oct 2004, 14:14:59 »
How do I assign the groupleader as man number 4 and not 1 in the group ??? It could turn out very usefull in a armoured infantry unit. (3 x crew, platoonleader, medic, machinegunner ect...) 8) 8)

Offline The-Architect

  • Former Staff
  • ****
  • Bite my shiny metal...
    • Bob's Un-official Flashpoint Page
Re:Assignment
« Reply #1 on: 20 Oct 2004, 16:55:18 »
Try creating a group of guys and then assigning three guys from the group, not the groupleader, as driver, gunner and commander.

Dunno if it will work but it sounds like it should.
James Andrew Wilkinson 1977 - 2005 R.I.P.
"If it ain't the friggin' incoming it's the friggin' outgoing. Only difference is who gets the friggin' grease, and that ain't no friggin' difference at all."

Offline THobson

  • OFPEC Patron
  • Former Staff
  • ****
Re:Assignment
« Reply #2 on: 20 Oct 2004, 20:51:56 »
Ok here is a script that will allow you to change the leader of a group.  Save it as something like:

ChangeLeader.sqs  

and call  it by

[NameOfNewLeader] exec "ChangeLeader.sqs"

Where:  NameOfNewLeader is the name you have given to the unit you want to be the leader.  

The code is:
Code: [Select]
_newleader = _this select 0

_units = units (group _newleader)

_units = _units - [_newleader]
_units join grpnull
_units join _newleader
exit

It even works if the group has waypoints.  The group will continue to follow the waypoints with the new leader
« Last Edit: 20 Oct 2004, 21:24:04 by THobson »

Robinhansen

  • Guest
Re:Assignment
« Reply #3 on: 22 Oct 2004, 16:08:54 »
Thanx for the schritp m8. JUST what I needed.
 ;D ;D ;D ;D ;D ;D ;D ;D ;D ;D ;D ;D ;D ;D ;D ;D ;D ;D ;D ;D ;D ;D ;D ;D ;D ;D