Jump to content
  • 0

Manually spawned / Editor placed vehicles being deleted


drunkenjawa

Question

There is a post on the Open Dayz forums that's similar to this (http://www.opendayz.net/threads/help-map-edited-vehicles-disappear.7387/) , but I thought I would be more specific about the problem just in case it wasn't understandable, and I also had another question too. First question regards server spawned vehicles. We're running OWPack on our server, with all the RH guns and a few new planes, like the F16 and AC130 Spooky. Is it just a case of me needing to add these new vehicles to dynamic_vehicle.sqf to get the server to dynamically spawn them? Or do they also need to have an entry elsewhere? As far as I've discovered, Epoch only uses the trader_data table is the only one that's used - but for custom vehicles, should I also have antries in the object_data table too? Assuming not anyway. Just can't see any of the new vehicles spawning in.

Second question relates to the topic regarding manually and editor placed spawned in vehicles. We use the Phoenix Admintools script for manually spawning vehicles. Vehicles would spawn in, remain in game about 10 seconds after a player has intereacted with them, then disappear. This is the same issue with trying to use Sarge AI helis that have landed (despawn upon contact) and also editor placed vehicles. I would be immensely greatful to be pointed in the right direction here. The vehicles don't have to last through the restart, just till the restart would be nice as temporary vehicles.

When interacted with, our servers RPT file shows 'Deleting Object [objectname] with invalid ID and pos [worldspace coords]' then keeps spamming an 'Object not found' error once in a while till server restart. E.G."Deleting object ATV_US_EP1 with invalid ID at pos [13663.4,11926.3,0.0198975]"

This happens with all of the above despawns. Also, we're using Sarge AI as well and it's working fine. The code that as far as I'm aware controls this on Epoch, is:

if (!_parachuteWest) and !(locked _object)) then {

if (_objectID == "0" && _uid == "0") then

{

_object_position = getPosATL _object;

diag_log(format["Deleting object %1 with invalid ID at pos [%2,%3,%4]",

typeOf _object,

_object_position select 0,

_object_position select 1,

_object_position select 2]);

_isNotOk = true;

};

};

I've tried lots of different ways of altering this code (which I'll post below), as well as commenting it out all together, but then the server won't start, spamming something about 'safeobject' reference not found, in another sqf file that I haven't touched.

I've tried:

if (!_parachuteWest) and !(locked _object)) then {

if (_objectID == "0" && _uid == "0"&& (vehicle _object getVariable ["Sarge",0] != 1)) then

{

_object_position = getPosATL _object;

diag_log(format["Deleting object %1 with invalid ID at pos [%2,%3,%4]",

typeOf _object,

_object_position select 0,

_object_position select 1,

_object_position select 2]);

_isNotOk = true;

};

};

Didn't work.

Tried:

if (!_parachuteWest) and !(locked _object) and (vehicle _object getVariable ["Sarge",0] != 1)) then {

if (_objectID == "0" && _uid == "0") then

{

_object_position = getPosATL _object;

diag_log(format["Deleting object %1 with invalid ID at pos [%2,%3,%4]",

typeOf _object,

_object_position select 0,

_object_position select 1,

_object_position select 2]);

_isNotOk = true;

};

};

I also tried something with # signs that I don't seem to be able to find any more. Anyways, no matter how I alter this code, it goes back to spitting out errors to do with 'safeobject' from server_monitor.sqf, which I never actually touched, and referencing a whole bunch of items. Leaving this code alone, the server starts fine.

So yeah this would solve multiple issues all at once I think. Oh yeah I've also commented out the actual bit that runs the command to delete too:

//if (_isNotOk) exitWith { deleteVehicle _object; diag_log(format["Deleting object %1 with invalid ID at pos [%2,%3,%4]",typeOf _object,_object_position select 0,_object_position select 1, _object_position select 2]); };

Link to comment
Share on other sites

10 answers to this question

Recommended Posts

  • 0
22:15:21 Error in expression < _entity]);

}
else {
if (!(_class in SafeObjects )) then {
_damage = 1;
};>
22:15:21 Error position: <SafeObjects )) then {
_damage = 1;
};>
22:15:21 Error Undefined variable in expression: safeobjects
22:15:21 File z\addons\dayz_server\system\server_monitor.sqf, line 193
22:15:21 Error in expression <pace = [_class, _point, _booleans] call fn_niceSpot;
if (_booleans select 3) the>
22:15:21 Error position: <fn_niceSpot;
if (_booleans select 3) the>
22:15:21 Error Undefined variable in expression: fn_nicespot
22:15:21 File z\addons\dayz_server\system\server_monitor.sqf, line 201
22:15:21 Error in expression < _entity]); 

This is the error message that is spammed in our servers RPT when I try and change anything in the "if (!_parachuteWest)" part.

 

Calls all sorts of lines, just continually spams it like it's doing this for every vehicle on the server or something. Client side just goes into debug plains when logging in.

Link to comment
Share on other sites

  • 0

The parachute west change solved the issue for me, using admin tools to spawn in, for example, an Apache. would then disappear soon thereafter. With the change the vehicle will stay until restart, it did break Sarge, AI helis stay until restart and the spawned in infantry only seem to spawn in one type all with the same weapon. 

 

The only change I made:

 

 

if (_objectID == "0" && _uid == "0" && (vehicle _object getVariable ["Sarge",0] != 1)) then 

 

The game also tends to spawn me into the debugging plains since I made the change. It seems to throw up sync position errors with the client using admin tools. 

Link to comment
Share on other sites

  • 0

Yeah strange. I made this change as well but kept on getting lots of errors spammed in the log. And really, code wise, it seems fine. While testing things last night we found that basically any jet or tank stays in (without the change), also the armoured SUV. Static placed weapons also stay in, basically anything that isn't in normal Day Z seems to skip this error and stay till restart. It's interesting to say the least, giving bandits static placed SU23 cannons... lol. We test in a live environment so yeah, a few people got a few pretty big shocks lol.

 

Anyways, I always go into debug plains, try to log back in but get spat back there all the time after changing the parachute west thing. Should I just wait this out, do you think?

Link to comment
Share on other sites

  • 0

Hah yeah I kinda ruled out the Shilka and other AA arty after testing them, Stingers are good since they tend to just damage modules rather than take out the whole heli. 

 

Basically before I went with the new patch I found anything spawned in by either admin tools or using the mission system would only persist until restart, probably because they never really write to the database and so go back to the same position in the case of map items when the server boots again. 

 

The only real way I got armour to stay on was to add them to a trader menu, then when they are purchased they stay in. Although some vehicles just wouldn't work such as the landy with the recoilless rifle. 

Link to comment
Share on other sites

  • 0

Awesome! How did you get them to just do that? That's really all I'm after, just so they stay till restart. Have almost given up searching lol, all suggestions that have been made have seemed to fail for me. Any help you could give and I love you long time, lol Also it seems as though everyone is kinda having their own unique problem in regards to this, are any devs able to shed any light?

Link to comment
Share on other sites

  • 0

Okay I figured out what was happening - I was altering the code fine, it's just that repacking this PBO using PBO Manager made it have an incorrect prefix that caused everything to fall over.

 

I got rid of PBO Manager and now use BinPBO Personal Edition - http://www.armaholic.com/page.php?id=2068 this lets you speficy a prefix... and now I am completely sorted!

Link to comment
Share on other sites

  • 0

Sure thing man. I downloaded the PBO Personal Edition that I linked above, and when packing up the server pbo (It doesn't matter with the mission PBO) you press 'Options' (I think it's options - it's the button beside 'Pack' anyway - sorry I'm at work so can't confirm the button name). At the bottom there it will allow you to designate your own prefix - designate this as:

 

z\addons\dayz_server

 

Repack, upload, and you're good to go!

if (!_parachuteWest) and !(locked _object)) then {
if (_objectID == "0" && _uid == "0" && (vehicle _object getVariable ["Sarge",0] != 1)) then
{
_object_position = getPosATL _object;
diag_log(format["Deleting object %1 with invalid ID at pos [%2,%3,%4]",
typeOf _object,
_object_position select 0,
_object_position select 1,
_object_position select 2]);
_isNotOk = true;
};
};

OR, you can just comment out the code that deletes it below this part if you want:

 

//if (_isNotOk) exitWith { deleteVehicle _object; diag_log(format["Deleting object %1 with invalid ID at pos [%2,%3,%4]",typeOf _object,_object_position select 0,_object_position select 1, _object_position select 2]); };

 

I actually did something else with this though, basically before the parachutewest part I just put a line saying if sarge == 1 then exitwith {}. so if that doesn't work let me know, and I'll just post the code I have in my updateobjects when I get home.

Link to comment
Share on other sites

  • 0

if (_objectID == "0" && _uid == "0" && (vehicle _object getVariable ["Sarge",0] != 1)) then 

Sorry just saw this again, this stopped working for me and I just realised it possibly stopped working because I had just started using PBOManager? Might give it a whirl now and see if my Kord stays in. 

Link to comment
Share on other sites

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 account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Advertisement
  • Discord

×
×
  • Create New...