Jump to content
Sign in to follow this  
PhelanKA7

Question: Make player inactive, then active again?

Recommended Posts

Here's what I am wanting to do:

I have an action in my mission that is supposed to fully occupy a single unit as he "works" on an object. Is there a way to keep a unit from firing his weapon until a trigger "unlocks" him? As of right now, the trigger is just removing his weapons, and when the countdown of the trigger is complete I have a script that adds a preset list of weapons back to the unit. The problems here should be obvious... Namely if the unit picked up a different weapon or expended a number of magazines, the disparity between the two would be obvious to the player.

So basically what I need is either of the following two options:

1) Remove the player's existing weapons and then add them back exactly as they were when they were removed after the trigger is complete.

OR

2) Disable the unit until the trigger is completed.

I'm not expecting anyone to write the script for me, but a few clues to point me down the right direction would be much appreciated :)

Thanks for any help!

Share this post


Link to post
Share on other sites

If the unit is AI:

unit disableAI section

and

unit enableAI section

If the unit is a player:

disableUserInput disable

If the unit is the player and he must be able to look around and use his weapons:

attachTo is the way to go

Edited by Väinämöinen

Share this post


Link to post
Share on other sites

If the unit is a player:

disableUserInput disable

I might give this a try as long as it can be used like "user1 disableUserInput true" and disable only one player in a multiplayer mission and not EVERYONE playing.

Thanks for the help.

Share this post


Link to post
Share on other sites

if (_playerToBeDisabled==player) then {disableUserinput true};

with some scripting you can disable the sucker :yay:

Edited by Väinämöinen

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  

×