Jump to content
Sign in to follow this  
RaiseoHitsu

setcaptive true = shoot people in the face without consequences

Recommended Posts

So here's the problem, I'm making a stealth mission and the team is composed by 2 indipendents, enemy of the opfor, and 1 civilian which acts as a "disguised scout" for the team. So, when I put the civilian in the indipendent team, obviously, the civ get shot, so I've put on his inizialization "c1 setcaptive true;" this way the civilian (c1) doesn't get shot and everything goes smooth and well... until the civ gets a weapon. The civ can shoot everyone without the opfor even considering for a second that he might be an enemy or just an idiot that should die, any ideas of how to make this work? The civ should not go near some places, that's when the trigger "c1 setcaptive false;" activates and the guy is shot to death, but what if he takes a weapon? What if he shoots? Is there a way for the opfor to treat him as an enemy if he shoots someone, or better, just take a gun? If not, is there a way to keep the civ from getting weapons from dead soldiers?

Share this post


Link to post
Share on other sites

Thank you! I will search how to do that immediately

EDIT: Oh and in the mean time, feel free to explain it anyway lol

Share this post


Link to post
Share on other sites

hi,

Try with addEventHandler fired and removeEventHandler

You should have something like this:

Spy civilian init field

this setCaptive true; this addEventHandler ["fired","_this exec {fired.sqs}"]

fired.sqs

_u=_this select 0

_u removeEventHandler ["fired",0]
_u setCaptive false

exit

Nobody will fire on the civilian but as soon as he will fire, enemies will open up on him. Not tested but it should work.

cya.

Nikiller.

Share this post


Link to post
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
Sign in to follow this  

×