OFPEC Forum

Editors Depot - Mission Editing and Scripting => OFP - Editing/Scripting General => Topic started by: Iva on 01 Jul 2004, 22:10:44

Title: Checking weapon
Post by: Iva on 01 Jul 2004, 22:10:44
Is there some way to get name of curently selected weapon or name of weapon that was just selected? ???
Title: Re:Checking weapon
Post by: TonyRanger on 04 Jul 2004, 10:16:52
_ap=_this select 0
#main
_weapon=primaryweapon _ap
?_weapon=="m16":hint"you get it"
goto"main"
Title: Re:Checking weapon
Post by: h- on 04 Jul 2004, 12:23:54
Nope, won't work Tony...

primaryWeapon returns the weapon in the primary weapon slot, not the weapon the soldier has selected / is holding...

But, if I misunderstood the first post, my apologies... ::)
Title: Re:Checking weapon
Post by: Iva on 16 Jul 2004, 20:36:47
Nope. Im searching for script that sa Hater_Kint said that returns curent selected weapon!
Something like

_wep =  _unit selectedweapon

or something   :-\
Title: Re:Checking weapon
Post by: h- on 16 Jul 2004, 23:34:54
Maybe some fancy nearestObject rune would do the trick?

Maybe the weapon could be detected with that, but then it would still probably pick the weapon on the units back as it's closer ::)

I think this is with the 'get units stance' is one the features BIS have forgotten to release for public use...