Home   Help Search Login Register  

Author Topic: Weapon Detection  (Read 556 times)

0 Members and 1 Guest are viewing this topic.

Captain Winters

  • Guest
Weapon Detection
« on: 29 Jul 2003, 01:22:59 »
I need to know if theres a way where you can detect if a player picks a certain weapon during the briefing, and if that weapon "X" isn't selected, an action I already added to the player not show up?  :o

Man o man, you don't know how appreciative I'd be  ;D TIA

Tanks! 8)

deaddog

  • Guest
Re:Weapon Detection
« Reply #1 on: 29 Jul 2003, 02:08:31 »
Add the action in question after the mission starts, not in the init line or init.sqs.  The player can't do anything before the mission starts anyway.   :)

Captain Winters

  • Guest
Re:Weapon Detection
« Reply #2 on: 29 Jul 2003, 03:07:38 »
yea, but the action only pertains to one gun. how can i detect if he has that gun?

Tanks! 8)

peter

  • Guest
Re:Weapon Detection
« Reply #3 on: 29 Jul 2003, 03:18:52 »
i would use :

? _unit hasweapon "M16" : _unit addaction ["whatever","m16action.sqs"]

... not sure but should work

deaddog

  • Guest
Re:Weapon Detection
« Reply #4 on: 29 Jul 2003, 04:18:33 »
Peter's way works and also this:

"M16" in weapons unitname

Captain Winters

  • Guest
Re:Weapon Detection
« Reply #5 on: 30 Jul 2003, 00:15:20 »
thanks guys. works great!

Tanks! 8)