Problem using 3D Editor and then adding it onto the server

Texas_Assassin

New Member
Hi i recently used the 3D editor and added what i made into my mission files with a custom building folder and adjusted my init.sqf file but when i log into my server to view the buildings i added they are not there does anyone know where i may of made a mistake. or is anyone else having this problem.
 
Unpack your dayz_server.pbo
Copy your 3d mission.sqf file into a folder CustomBuildings and add a line at the bottom of your dayz_server/init/server_functions.sqf file
Code:
execVM "\z\addons\dayz_server\CustomBuildings\static_vehicles.sqf";
of course replacing the path and file name with your own.

You CAN run the custom buildings from your init.sqf file but it increases the size of the mission download so its best to keep it in the dayz_server.pbo

But your problem is ost likely you didn't delete the extra lines at the top and bottom of the script. The file the 3d editor creates will look something like this
Code:
activateAddons [
];

activateAddons [];
initAmbientLife;

//--------------------------THIS IS MY FIRST BUILDING OR VEHICLE------------------
_vehicle_4 = objNull;
if (true) then
{
  _this = createVehicle ["S1203_TK_CIV_EP1", [2024.7681, 4641.4805, 9.5367432e-007], [], 0, "CAN_COLLIDE"];
  _vehicle_4 = _this;
  _this setDir 85.390762;
  _this setPos [2024.7681, 4641.4805, 9.5367432e-007];
};

_vehicle_5 = objNull;
if (true) then
{
  _this = createVehicle ["car_sedan", [2024.8523, 4628.834, 9.5367432e-007], [], 0, "CAN_COLLIDE"];
  _vehicle_5 = _this;
  _this setDir 90.888153;
  _this setPos [2024.8523, 4628.834, 9.5367432e-007];
};

_vehicle_6 = objNull;
if (true) then
{
  _this = createVehicle ["Lada2", [2025.2577, 4637.9126, 1.9073486e-006], [], 0, "CAN_COLLIDE"];
  _vehicle_6 = _this;
  _this setDir -90.602074;
  _this setPos [2025.2577, 4637.9126, 1.9073486e-006];
};
//----------------------------ABOVE IS MY LAST BUILDING/VEHICLE---------------------

_this = createCenter west;
_center_0 = _this;

_group_0 = createGroup _center_0;

_unit_0 = objNull;
if (true) then
{
  _this = _group_0 createUnit ["BAF_Soldier_AA_DDPM", [2026.5259, 4613.5835, 0], [], 0, "CAN_COLLIDE"];
  _unit_0 = _this;
  _this setUnitAbility 0.60000002;
  if (true) then {_group_0 selectLeader _this;};
  if (true) then {selectPlayer _this;};
};

processInitCommands;
runInitScript;
finishMissionInit;

First thing is you want to delete all the stuff at the top that is ABOVE your first building. I created vehicles here, but it doesn't matter, they are treated identically.
So delete ANY code you might have above the first building such as this in my example file.
Code:
activateAddons [];
initAmbientLife;

And then you have to delete all the stuff that is BELOW your last building.
Code:
processInitCommands;
runInitScript;
finishMissionInit;

If you use setvehicleinit commands then you should keep the processinitcommands; at the bottom, but delete the rest.

ALSO, you cannot save your mission without having a playable unit, so you have to delete that unit although that will not affect your sqf from loading, just puts an extra character on the map.
Code:
_this = createCenter west;
_center_0 = _this;

_group_0 = createGroup _center_0;

_unit_0 = objNull;
if (true) then
{
  _this = _group_0 createUnit ["BAF_Soldier_AA_DDPM", [2026.5259, 4613.5835, 0], [], 0, "CAN_COLLIDE"];
  _unit_0 = _this;
  _this setUnitAbility 0.60000002;
  if (true) then {_group_0 selectLeader _this;};
  if (true) then {selectPlayer _this;};
};
 
Back
Top