Jump to content
Sign in to follow this  
Recoilless

Locality issues in multiplayer

Recommended Posts

I'm trying to make a singleplayer mission into a multiplayer mission. However, I'm having some locality issues. How can I make a script execute only on the server?

Share this post


Link to post
Share on other sites

I tried this but to no avail, perhaps its something wrong with the scripting itself, and yes I know the names make no sense; it's altered copypasta.

if(isServer) then {
GroupAlpha1 = CreateGroup West;
Helo1 = createVehicle ["A10", [(getMarkerPos "Startingpoint1") select 0,(getMarkerPos "Startingpoint1") select 1,100], [], 0, "FLY"];
HeliPilot1 = GroupAlpha1 createUnit ["USMC_Soldier_Pilot", [0,0,1], [], 0, "CAN_COLLIDE"];
HeliPilot1 moveInDriver Helo1;
wp12 = GroupAlpha1 addwaypoint [position Targetarea, 0];
wp12 setwaypointtype "SAD";
}

Share this post


Link to post
Share on other sites
I tried this but to no avail, perhaps its something wrong with the scripting itself, and yes I know the names make no sense; it's altered copypasta.

if(isServer) then {
GroupAlpha1 = CreateGroup West;
Helo1 = createVehicle ["A10", [(getMarkerPos "Startingpoint1") select 0,(getMarkerPos "Startingpoint1") select 1,100], [], 0, "FLY"];
HeliPilot1 = GroupAlpha1 createUnit ["USMC_Soldier_Pilot", [0,0,1], [], 0, "CAN_COLLIDE"];
HeliPilot1 moveInDriver Helo1;
wp12 = GroupAlpha1 addwaypoint [position Targetarea, 0];
wp12 setwaypointtype "SAD";
}

Not sure if it will fix it, but add a ";" at the end.

Are you calling that directly in a trigger or from an sqf file ?

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  

×