Jump to content
Sign in to follow this  
Egypt~Seal

Force BarGate !?

Recommended Posts

Hey guys,,

As long as we cannot disable the Open, Close door action from the Bargate, unless messing around with the pbo.

i just need a script to force the bargate to be closed ["Door_1_rot", 0] rightway when "Civillian" trys to open it with the default action menu!

Would be great if you guys helped me out :o

Cheers

Share this post


Link to post
Share on other sites

I found out that the only way to prevent civs "for example" from opening the gate "scroll down menu" is to figure out somthing that force the animation state to be switched the the closed position right away when trys to open it "Will look like its Locked"

because ill make a trigger that can be activated by Blufor and opens it "via trigger" not via the scroll down action.

Share this post


Link to post
Share on other sites

As you can't disable menu a trigger or adding more addactions is the only way.

You can check the animation phase

0 = shut

0 > opening

1 = open

It will work in a trigger condition but they are a little slow so placing in a script would be better

cond

mygate animationPhase "Door_1_rot" != 0 

on act

mygate animate ["Door_1_rot", 0] ;

You will also need to add another variable that will act as the key by disabling the forced lock situation.

Share this post


Link to post
Share on other sites

You are awesome !!!!

THX

---------- Post added at 17:06 ---------- Previous post was at 16:15 ----------

Would be awesome if you tell me how to disable that lock trigger, i tried with the deleteVehicle triggername; , but i couldnt run it back again because its simpl;y deleted !

so please help me with how to deactivate that trigger,

Share this post


Link to post
Share on other sites

I can't test it right now but it should be something like this

cond

mygate animationPhase "Door_1_rot" != 0   and mygate getvaraiable ["gate",true]

Then to unlock it mygate setvaraiable ["gate",false];

To lock it again mygate setvaraiable ["gate",true];

Share this post


Link to post
Share on other sites
I can't test it right now but it should be something like this

cond

mygate animationPhase "Door_1_rot" != 0   and mygate getvaraiable ["gate",true]

Then to unlock it mygate setvaraiable ["gate",false];

To lock it again mygate setvaraiable ["gate",true];

Seems like Not working :(

Share this post


Link to post
Share on other sites

sorry typo in getvariable

mygate animationPhase "Door_1_rot" != 0   and mygate getvariable ["gate",true]

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  

×