OFPEC Forum
Editors Depot - Mission Editing and Scripting => ArmA - Editing/Scripting General => Topic started by: Supergrunt on 25 Nov 2007, 16:56:58
-
hi there,
i hope somebody can help me
i am building a mission in wich the player has the ability to put on or off a ghillie suit (changing player.... bla bla) i need i small script in wich if the player activates the command to put on ghillie he will take his weapons to the other playermodel and back when putting the ghillie off
the player names are JC and JC1 (jc = without the ghillie / jc1 is with the ghillie)
so al i realy need is a script to take away the current load out in the players inventory and trasfer it to the second char.... (incl. main weapon, ammo, sidearm, ammo
thanks in advance
(btw i am a scripting retard so detailed help whould be more then welcome :P )
-
Bear in mind that if you do this, then all the player's magazines will fill up again and that, if you don't use something like Mando My Weapon (http://www.ofpec.com/ed_depot/index.php?action=details&id=435&page=0&game=ArmA&type=fu&cat=xyz) and selectWeapon to find out and use the weapon that player was using, then the new version won't necessarily be holding the same weapon as the old version was:
{
JC2 addMagazine _x;
} forEach (magazines JC);
{
JC2 addWeapon _x;
} forEach (weapons JC);
-
to bad about the refiilling part but its something we will have to learn to live by then
thanks for the reply, going to bed now (had a nightshift) and then i am going try to implent this in to the mission