OFPEC Forum
Editors Depot - Mission Editing and Scripting => OFP - Editing/Scripting General => Topic started by: jepo on 19 Jan 2004, 12:05:00
-
how do i make it so at the start of a mission there is a weapon lying on the ground and i can pik it up
-
You could put this in a players init field or a script e.t.c
MyHolder="WeaponHolder" CreateVehicle (GetPos Player)
MyHolder addWeaponCargo ["AK47", 1]
MyHolder addMagazineCargo ["AK47", 4]
Bear in mind the weapons holder will disapear when you empty it.
-
If ya wanna have a few stashed rifles (say, in a bunker or alike), then ya can also
create a tiny addon (just a PBO'ed config file), like this :
Class CfgVehicles
{
class All{};
class Static: All{};
class Building: Static{};
class Strategic: Building{};
class ReammoBox: Strategic{};
class WeaponHolder: ReammoBox{};
class TMB_M16Stash: WeaponHolder
{
scope=2;
vehicleClass="Ammo";
icon=Ammo_move;
mapSize=0.58;
armor=1000;
destrType=destructNo;
displayName="Rifle Stash";
model=\data3d\deka;
irTarget=false;
nameSound=weapon;
showWeaponCargo=True;
class TransportMagazines
{
class M16
{
magazine=M16;
count=4;
};
};
class TransportWeapons
{
class _w_M16
{
weapon="M16";
count=1;
};
};
};
:) summit like that (it will create a verticallly stashed M16)
-
thanx, i'll try it out