Jump to content
Sign in to follow this  
peeps

passing public variables to a server

Recommended Posts

having another issue :D Feels like i've been spamming these forums for the past few days, apolagies for that.

can someone explain to me what im doing wrong please. I've looked around and from what I can tell everything is correct.

Ok so the server is running this:

for [{}, {(cs_roundtime != 0) AND (!CS_bombplanted)}, {cs_roundtime = cs_roundtime - 1}] do
{
publicvariable "cs_roundtime";
if !(isdedicated) then {call cs_fnc_showroundtime};
sleep 1;
};

As you can see it is counting down and broadcasting the number to the clients.

There is an addaction on the mission that executes the following:

if (_canplant) then {

CS_bombplanted = true;
publicvariable "cs_bombplanted";

};

The problem im having is that the loop running on the server isn't ending when a client presses the addaction. From my understanding shouldn't the client be telling everyone that cs_bombplanted has changed to true and as such the condition in the for loop should be true?

Thanks for any help you guys can give.

PS bonus points if you can guess what im trying to make :D

Share this post


Link to post
Share on other sites

#bump

please someone help me, im so lost :(((

Share this post


Link to post
Share on other sites

CS_bombplanted = true;

Aren't variable names case-sensitive? Should that be:

cs_bombplanted = 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  

×