Jump to content
Sign in to follow this  
nullsystems

Vehicle lock false doesnt work?

Recommended Posts

Hi all.

Heres the story:

1. Chopper locked from start of MP mission ( from within editor, not by a script ).

2. When objectives1-9 are complete, game logic unlocks a chopper:

cond: objective1 && objective2

onAct: heli lock false; hint 'unlocked';

Why does this work for ME, but when other people finnish the objectives, it doesnt unlock for them, but shows the hint..proving its got to the onact section.

Share this post


Link to post
Share on other sites

http://community.bistudio.com/wiki/lock

Lock is LOCAL and as the Game-Logic only exists on the server it will only work on the server.

/edit

To fix this you may either use a normal trigger or you make the command public. But JIP also requires you to repeat that "publication" all the time to unlock the vehicle also for players who join IP:

Init.sqf:

bool_iHeliUnlocked = false;

unlockHeli.sqf:

bool_iHeliUnlocked = true;

while{ true }do{ publicVariable "bool_iHeliUnlocked"; sleep 10 };

GameLogic-WP:

0 execVM "unlockHeli.sqf";

Trigger (Once):

Condition: bool_iHeliUnlocked

onActivation: obj_heli1 lock false;

Share this post


Link to post
Share on other sites

Well. That had to give you an error. Sorry. You shouldnt put "null = " biggrin_o.gifbiggrin_o.gif

rather write sc_test = ...

GameLogic-WP ment... I think what you mean by "my Gamelogic is unlocking it" is that your camelogic vomes over a WP which has "helo1 lock false" in its onactivation line.

so instead of ... you put in

sc_test = 0 execVM "unlockHeli.sqf";

€: whistle.gif great... i didnt explain what "WP" means - did I? rofl.gif

wAYpOINT

Share this post


Link to post
Share on other sites

lol thank, its working just fine I think.

I tested it with one person and he unlocked it biggrin_o.gif

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  

×