kingpapawawa Posted January 27, 2017 Report Share Posted January 27, 2017 ["z\addons\dayz_server\system\scheduler\sched_safetyVehicle.sqf","KILLING A HACKER","kpw"," IN ","KORD_high_TK_EP1"] in my custom variables i have DZE_safeVehicle = ["ParachuteWest","ParachuteC","KORD_high_TK_EP1"]; loading the KORD in via .sqf in the server pbo _vehicle_613 = objNull; if (true) then { _this = createVehicle ["KORD_high_TK_EP1", [4118.1001, 7245.6196, 9.1946907], [], 0, "CAN_COLLIDE"]; _vehicle_613 = _this; _this setDir 186.50471; _this setPos [4118.1001, 7245.6196, 9.1946907]; }; Any ideas? Link to comment Share on other sites More sharing options...
0 Airwaves Man Posted January 27, 2017 Report Share Posted January 27, 2017 Hmm it looks like your server does not load the custom variables. I tested it and had no problems with that one. Make sure that no other script overwrites the custom variables path. Link to comment Share on other sites More sharing options...
0 salival Posted January 27, 2017 Report Share Posted January 27, 2017 1 hour ago, kingpapawawa said: ["z\addons\dayz_server\system\scheduler\sched_safetyVehicle.sqf","KILLING A HACKER","kpw"," IN ","KORD_high_TK_EP1"] in my custom variables i have DZE_safeVehicle = ["ParachuteWest","ParachuteC","KORD_high_TK_EP1"]; loading the KORD in via .sqf in the server pbo _vehicle_613 = objNull; if (true) then { _this = createVehicle ["KORD_high_TK_EP1", [4118.1001, 7245.6196, 9.1946907], [], 0, "CAN_COLLIDE"]; _vehicle_613 = _this; _this setDir 186.50471; _this setPos [4118.1001, 7245.6196, 9.1946907]; }; Any ideas? _vehicle_613 = objNull; if (true) then { _this = createVehicle ["KORD_high_TK_EP1", [4118.1001, 7245.6196, 9.1946907], [], 0, "CAN_COLLIDE"]; _vehicle_613 = _this; _this setDir 186.50471; _this setPos [4118.1001, 7245.6196, 9.1946907]; dayz_serverObjectMonitor set [count dayz_serverObjectMonitor,_this]; }; This should fix it. Airwaves Man 1 Link to comment Share on other sites More sharing options...
0 kingpapawawa Posted January 27, 2017 Author Report Share Posted January 27, 2017 45 minutes ago, salival said: _vehicle_613 = objNull; if (true) then { _this = createVehicle ["KORD_high_TK_EP1", [4118.1001, 7245.6196, 9.1946907], [], 0, "CAN_COLLIDE"]; _vehicle_613 = _this; _this setDir 186.50471; _this setPos [4118.1001, 7245.6196, 9.1946907]; dayz_serverObjectMonitor set [count dayz_serverObjectMonitor,_this]; }; This should fix it. Yes! thank you. been pulling my hair out. Link to comment Share on other sites More sharing options...
0 TheBillsProject Posted July 15, 2017 Report Share Posted July 15, 2017 I have the same issue but with custom vehicles. Where do I put what you said above to fix the issue. Link to comment Share on other sites More sharing options...
0 juandayz Posted July 15, 2017 Report Share Posted July 15, 2017 Just now, TheBillsProject said: I have the same issue but with custom vehicles. Where do I put what you said above to fix the issue. If ure spawning vehicles by server side use the line from above. If ure using this veh by client..example spawn a bike with right click action then add the veh id into dze safevehicle variable. Example: 1-Server side like kingpapawa case: veh.sqf Spoiler if (isServer) then { _vehicle_1 = objNull; if (true) then { _this = createVehicle ["BAF_Offroad_W", [5420.7915, 3807.813, -3.0517578e-005], [], 0, "CAN_COLLIDE"]; _vehicle_1 = _this; _this setDir 110.14845; _this setPos [5420.7915, 3807.813, -3.0517578e-005]; dayz_serverObjectMonitor set [count dayz_serverObjectMonitor,_this]; }; _vehicle_2 = objNull; if (true) then { _this = createVehicle ["HMMWV_M2_DZ", [5420.7915, 3807.813, -3.0517578e-005], [], 0, "CAN_COLLIDE"]; _vehicle_2 = _this; _this setDir 110.14845; _this setPos [5420.7915, 3807.813, -3.0517578e-005]; dayz_serverObjectMonitor set [count dayz_serverObjectMonitor,_this]; }; }; Example 2: server side (spawning an heli with a epoch event) Spoiler _carrier = createVehicle [_plane_class, [(_positionp select 0) + 50, (_positionp select 1) + 50],[], 0, "FLY"]; _carrier setVehicleVarName "heli"; _carrier setFuel 1; _carrier engineOn true; _carrier setVehicleAmmo 1; _carrier flyInHeight 150; _carrier limitSpeed 60; _carrier setVehicleLock "LOCKED"; dayz_serverObjectMonitor set [count dayz_serverObjectMonitor,_carrier];//heres the line Example 3: client. (add a vehicles in server spawns and locals scripts) custom variables.sqf at bottom add: Spoiler DZE_myVeh = ["BAF_Offroad_W","HMMWV_M2_DZ"]; DZE_safeVehicle = DZE_myVeh +["ParachuteWest","ParachuteC"]; and into: \@DayZ_Epoch_Server\addons\dayz_server\system\dynamic_vehicle.sqf Spoiler AllowedVehiclesList = [ ["BAF_Offroad_W",_Ratio3], ["HMMWV_M2_DZ",_Ratio1], //the rest of default vehicles And for understand all of this.. check this file: \@DayZ_Epoch_Server\addons\dayz_server\system\scheduler\sched_safetyVehicle.sqf Spoiler sched_safetyVehicle = { { if (vehicle _x != _x && !(vehicle _x in dayz_serverObjectMonitor) && !((typeOf vehicle _x) in DZE_safeVehicle)) then { diag_log [ __FILE__, "KILLING A HACKER", name _x, " IN ", typeOf vehicle _x ]; (vehicle _x) setDamage 1; _x setDamage 1; }; } forEach allUnits; objNull }; So now you know about this file.. other way is create a variable for custom vehicles.. then you dont need add the obj monitor line or entry his id in DZE_safevehicle. Ok: first open the sched_safetyVehicle.sqf and replace the whole code by this one: Spoiler sched_safetyVehicle = { { if (vehicle _x != _x && !(vehicle _x in dayz_serverObjectMonitor) && !((typeOf vehicle _x) in DZE_safeVehicle)) then { if (vehicle _x getVariable ["itsnotahacker",0] == 1) exitWith { }; diag_log [ __FILE__, "KILLING A HACKER", name _x, " IN ", typeOf vehicle _x ]; (vehicle _x) setDamage 1; _x setDamage 1; }; } forEach allUnits; objNull }; Now in the file that youre creating the vehicle.. add the variable.. gonna take the first example that i give you: veh.sqf Spoiler if (isServer) then { _vehicle_1 = objNull; if (true) then { _this = createVehicle ["BAF_Offroad_W", [5420.7915, 3807.813, -3.0517578e-005], [], 0, "CAN_COLLIDE"]; _vehicle_1 = _this; _this setDir 110.14845; _this setPos [5420.7915, 3807.813, -3.0517578e-005]; _this setvariable ["itsnotahacker",1,true]; }; _vehicle_2 = objNull; if (true) then { _this = createVehicle ["HMMWV_M2_DZ", [5420.7915, 3807.813, -3.0517578e-005], [], 0, "CAN_COLLIDE"]; _vehicle_2 = _this; _this setDir 110.14845; _this setPos [5420.7915, 3807.813, -3.0517578e-005]; _this setvariable ["itsnotahacker",1,true]; }; }; Link to comment Share on other sites More sharing options...
Question
kingpapawawa
["z\addons\dayz_server\system\scheduler\sched_safetyVehicle.sqf","KILLING A HACKER","kpw"," IN ","KORD_high_TK_EP1"]
in my custom variables i have
DZE_safeVehicle = ["ParachuteWest","ParachuteC","KORD_high_TK_EP1"];
loading the KORD in via .sqf in the server pbo
_vehicle_613 = objNull;
if (true) then
{
_this = createVehicle ["KORD_high_TK_EP1", [4118.1001, 7245.6196, 9.1946907], [], 0, "CAN_COLLIDE"];
_vehicle_613 = _this;
_this setDir 186.50471;
_this setPos [4118.1001, 7245.6196, 9.1946907];
};
Any ideas?
Link to comment
Share on other sites
5 answers to this question
Recommended Posts
Please sign in to comment
You will be able to leave a comment after signing in
Sign In Now