SadBoy1981 Posted May 20, 2015 Report Share Posted May 20, 2015 Was working before, but now just cant add it. They going to be deleted after player come close add vehicle: if (isServer) then { private ["_objs"]; _objs = [ {"O_MRAP_02_hmg_F",{1070.57,2515.65,0},339.091,{{-0.356886,0.934148,0},{0,0,1}},false}, {"O_MRAP_02_hmg_F",{1065.77,2513.81,0},339.091,{{-0.356886,0.934148,0},{0,0,1}},false}, {"I_MRAP_03_hmg_F",{1060.96,2511.98,0},339.091,{{-0.356886,0.934148,0},{0,0,1}},false}, {"O_MRAP_02_F",{1056.16,2510.14,0},339.091,{{-0.356886,0.934148,0},{0,0,1}},false}, {"B_MRAP_01_hmg_F",{1051.36,2508.31,0},339.091,{{-0.356886,0.934148,0},{0,0,1}},false}, {"Cha_BTR60_TK",{1046.55,2506.47,0},339.091,{{-0.356886,0.934148,0},{0,0,1}},false}, {"I_MRAP_03_hmg_F",{1041.75,2504.64,0},339.091,{{-0.356886,0.934148,0},{0,0,1}},false}, {"I_Heli_Transport_02_EPOCH",{1083.95,2520.02,0},339.091,{{-0.356886,0.934148,0},{0,0,1}},false}, {"B_Heli_Light_01_EPOCH",{1098.56,2524.64,0},339.091,{{-0.356886,0.934148,0},{0,0,1}},false} ]; { private ["_obj"]; _obj = createVehicle [_x select 0, [0,0,0], [], 0, "CAN_COLLIDE"]; if (_x select 4) then { _obj setDir (_x select 2); _obj setPos (_x select 1); _obj setVariable["LASTLOGOUT_EPOCH",1000000000000]; _obj setVariable["LAST_CHECK",1000000000000]; _obj call EPOCH_server_setVToken; addToRemainsCollector[_obj]; clearWeaponCargoGlobal _obj; clearMagazineCargoGlobal _obj; clearBackpackCargoGlobal _obj; clearItemCargoGlobal _obj; } else { _obj setPosATL (_x select 1); _obj setVectorDirAndUp (_x select 3); _obj setVariable["LASTLOGOUT_EPOCH",1000000000000]; _obj setVariable["LAST_CHECK",1000000000000]; _obj call EPOCH_server_setVToken; addToRemainsCollector[_obj]; clearWeaponCargoGlobal _obj; clearMagazineCargoGlobal _obj; clearBackpackCargoGlobal _obj; clearItemCargoGlobal _obj; }; } foreach _objs; }; FIXED: just add sleep 60; before run script Sneakydude 1 Link to comment Share on other sites More sharing options...
0 SadBoy1981 Posted October 19, 2015 Author Report Share Posted October 19, 2015 Just trying your sleep 60; solution to this problem as I am getting the same error in my rpt ie ;-Error in expression <(_obj isKindOf "Ship"))then{ _obj call EPOCH_server_setVToken;};} foreach _ob> Error position: <EPOCH_server_setVToken;};} foreach _ob> Error Undefined variable in expression: epoch_server_setvtokenYou say you have put sleep 60; in before executing script so I have tried it before the private ["_objs"]; line in the code and also on the first line of the fm_init.sqf but both locations have not solved the issue so could you be more specific on where you included the sleep 60 delay ?sleep 60; if (isServer) then { private ["_objs"]; spartan 1 Link to comment Share on other sites More sharing options...
Question
SadBoy1981
Was working before, but now just cant add it. They going to be deleted after player come close
add vehicle:
FIXED: just add sleep 60; before run script
Link to comment
Share on other sites
26 answers to this question
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now