Adding custom buildings in Vilayer

leemo

New Member
Right, I'm running a Chernarus server, using Vilayer.com as the host. I've been trying in vain to add custom buildings. Every tutorial I've tried to follow is for a different hosting package, or using different upload methods etc. (For those not familiar with Vilayer, they allow access to everything in their own interface - the PBO is already unpacked in the file manager and you just drop things in and it compiles it)

So, Here's where I am currently.
I have used the 3D editor (I don't get how people can spend all that time using the 2D editor to add buildings... Crazy people :)) with Jon's editor upgrade to add the buildings I want to the map. I've saved it and located the mission.sqf and mission.biedi files. I have also used a website to convert the biedi - which the tutorial I was following told me to add the code to the Mission.SQM on my server.

So, I have done that, but still no buildings are showing up... I'm guessing I have to add some code to the init.sqf telling it to read that particular file? Any help is greatly appreciated :)
 
you almost got it right.

  1. do your 3d editor stuff.
  2. save progress
  3. go to where you have files saved. (C:\Users\yourname\Documents\ArmA 2 Other Profiles\your profile\missions or C:\Users\yourname\Documents\ArmA 2\missions).
  4. copy your mission.sqf file to desktop
  5. open mission.sqf file that is on desktop
  6. FIND
    Code:
    activateAddons [
    ];
     
    activateAddons [];
    initAmbientLife;
     
    _this = createCenter west;
    _center_0 = _this;
     
    _group_0 = createGroup _center_0;
     
    _unit_1 = objNull;
    if (true) then
    {
      _this = _group_0 createUnit ["BAF_Soldier_Officer_W", [3899.1416, 8529.7217, -5.7220459e-006], [], 0, "CAN_COLLIDE"];
      _unit_1 = _this;
      _this setUnitAbility 0.60000002;
      if (true) then {_group_0 selectLeader _this;};
      if (true) then {selectPlayer _this;};
    };
  7. REPLACE WITH
    Code:
    if (isServer) then {
  8. FIND
    Code:
    processInitCommands;
    runInitScript;
    finishMissionInit;
  9. REPLACE WITH
    Code:
    };
  10. save file
  11. rename file to what ever you want.
  12. open your dayz_#.chernarus folder
  13. add a new folder inside (call it what you want to call it.)
  14. paste your new file from your desktop to your new folder.
  15. now open your INIT.SQF file
  16. FIND
    Code:
    // Logo watermark: adding a logo in the bottom left corner of the screen with the server name in it
    if (!isNil "dayZ_serverName") then {
  17. PLACE BEFORE
    Code:
    [] execVM "your folder\your file name.sqf";
now your done. just restart your server.
 
Thanks for that, I'm giving it a test now,
I couldn't find
Code:
// Logo watermark: adding a logo in the bottom left corner of the screen with the server name in it
if (!isNil "dayZ_serverName") then {
anywhere in the init.sqf so I've placed the other code at the end of the sqf to see if it works...
 
I have tried it in a few places with no luck yet... I'm booting the server up with it in this position:

Code:
startLoadingScreen ["","DayZ_loadingScreen"];
enableSaving [false, false];
 
dayZ_instance = 9036;    //The instance
hiveInUse    =    true;
initialized = false;
dayz_previousID = 0;
 
call compile preprocessFileLineNumbers "\z\addons\dayz_code\init\variables.sqf"; //Initilize the Variables (IMPORTANT: Must happen very early)
progressLoadingScreen 0.1;
call compile preprocessFileLineNumbers "\z\addons\dayz_code\init\publicEH.sqf";    //Initilize the publicVariable event handlers
progressLoadingScreen 0.2;
call compile preprocessFileLineNumbers "\z\addons\dayz_code\medical\setup_functions_med.sqf"; //Functions used by CLIENT for medical
progressLoadingScreen 0.4;
call compile preprocessFileLineNumbers "dayz_code\init\compiles.sqf"; //Compile regular functions
progressLoadingScreen 1.0;
 
player setVariable ["BIS_noCoreConversations", true];
//enableRadio false;
 
"filmic" setToneMappingParams [0.153, 0.357, 0.231, 0.1573, 0.011, 3.750, 6, 4]; setToneMapping "Filmic";
 
if (isServer) then {
    hiveInUse = true;
    _serverMonitor = [] execVM "\z\addons\dayz_server\system\server_monitor.sqf";
};
 
if (!isDedicated) then {
    0 fadeSound 0;
    0 cutText [(localize "STR_AUTHENTICATING"), "BLACK FADED",60];
    _id = player addEventHandler ["Respawn", {_id = [] spawn player_death;}];
    _playerMonitor =    [] execVM "\z\addons\dayz_code\system\player_monitor.sqf";
 
 
};
 
[] execVM "buildings\resistance.sqf";
 
};
 
#include "sargeai_init.sqf"
[] execVM "addons\refuel_action.sqf";
[] execVM "addons\R3F_ARTY_AND_LOG\init.sqf";

Where abouts in there would you recommend putting it?
 
Try this. If it dont work let me know and ill look at it a little closer.

Code:
startLoadingScreen ["","DayZ_loadingScreen"];
enableSaving [false, false];
 
dayZ_instance = 9036;    //The instance
hiveInUse    =    true;
initialized = false;
dayz_previousID = 0;
 
call compile preprocessFileLineNumbers "\z\addons\dayz_code\init\variables.sqf"; //Initilize the Variables (IMPORTANT: Must happen very early)
progressLoadingScreen 0.1;
call compile preprocessFileLineNumbers "\z\addons\dayz_code\init\publicEH.sqf";    //Initilize the publicVariable event handlers
progressLoadingScreen 0.2;
call compile preprocessFileLineNumbers "\z\addons\dayz_code\medical\setup_functions_med.sqf"; //Functions used by CLIENT for medical
progressLoadingScreen 0.4;
call compile preprocessFileLineNumbers "dayz_code\init\compiles.sqf"; //Compile regular functions
progressLoadingScreen 1.0;
 
player setVariable ["BIS_noCoreConversations", true];
//enableRadio false;
 
"filmic" setToneMappingParams [0.153, 0.357, 0.231, 0.1573, 0.011, 3.750, 6, 4]; setToneMapping "Filmic";
 
if (isServer) then {
    hiveInUse = true;
    _serverMonitor = [] execVM "\z\addons\dayz_server\system\server_monitor.sqf";
};
 
if (!isDedicated) then {
    0 fadeSound 0;
    0 cutText [(localize "STR_AUTHENTICATING"), "BLACK FADED",60];
    _id = player addEventHandler ["Respawn", {_id = [] spawn player_death;}];
    _playerMonitor =    [] execVM "\z\addons\dayz_code\system\player_monitor.sqf";
};
 
#include "sargeai_init.sqf"
[] execVM "addons\refuel_action.sqf";
[] execVM "addons\R3F_ARTY_AND_LOG\init.sqf";
[] execVM "buildings\resistance.sqf";
 
Still not seeing any buildings :(
I've double checked the code you said to change in the "resistance.sqf" it's all looking fine...

Do I still need to add the code to the mission.sqm?
 
no you do not have to add it to your mission.sqm

take a loot at your RTP file and post it on pastebin and post a link so that i can look at it.

also post your resistance.sqf so that i can take a look at that too
 
your RPT should look something like this

arma2oaserver.rpt

it should be in your FTP. Give me about 10 minutes to check your pastebin
 
That works like a charm! What was it you changed to get it going?
Thanks a lot for all the help! :) you're more than welcome to come take a look at the server at 91.121.157.115:2332 if you like :)
 
you had 2 problems.

1. you had the top like this
Code:
if (is server) then {
instead of like this
Code:
if (isServer) then {

2. you still had this in the middle of the script.
Code:
_group_0 = createGroup _center_0;
 
_unit_1 = objNull;
if (true) then
{
  _this = _group_0 createUnit ["BAF_Soldier_Officer_W", [3899.1416, 8529.7217, -5.7220459e-006], [], 0, "CAN_COLLIDE"];
  _unit_1 = _this;
  _this setUnitAbility 0.60000002;
  if (true) then {_group_0 selectLeader _this;};
  if (true) then {selectPlayer _this;};
}

I'm glad it works for you. now have fun adding more. :)
 
Ah right, so the chap I was using in the editor was still in there! I'll remember to get rid of him next time :)
Thanks again for all the help!
 
Hello ! I have problm with this tutorial.
I do all that is written and said about the video but it still does not work, need help please

There is my init.sqf :

/*

INITILIZATION
*/
startLoadingScreen ["","RscDisplayLoadCustom"];
cutText ["","BLACK OUT"];
enableSaving [false, false];
//REALLY IMPORTANT VALUES
dayZ_instance = 11198;// The instance
//dayZ_serverName = "UK1337";// server name (country code + server number)
dayzHiveRequest = [];
initialized = false;
dayz_previousID = 0;
//disable greeting menu
player setVariable ["BIS_noCoreConversations", true];
//disable radio messages to be heard and shown in the left lower corner of the screen
enableRadio false;
//Load in compiled functions
call compile preprocessFileLineNumbers "\z\addons\dayz_code\init\variables.sqf";//Initilize the Variables (IMPORTANT: Must happen very early)
progressLoadingScreen 0.1;
call compile preprocessFileLineNumbers "\z\addons\dayz_code\init\publicEH.sqf";//Initilize the publicVariable event handlers
progressLoadingScreen 0.2;
call compile preprocessFileLineNumbers "\z\addons\dayz_code\medical\setup_functions_med.sqf";//Functions used by CLIENT for medical
progressLoadingScreen 0.4;
call compile preprocessFileLineNumbers "\z\addons\dayz_code\init\compiles.sqf";//Compile regular functions
progressLoadingScreen 1.0;
"filmic" setToneMappingParams [0.153, 0.357, 0.231, 0.1573, 0.011, 3.750, 6, 4]; setToneMapping "Filmic";
/* BIS_Effects_* fixes from Dwarden */
BIS_Effects_EH_Killed = compile preprocessFileLineNumbers "\z\addons\dayz_code\system\BIS_Effects\killed.sqf";
BIS_Effects_AirDestruction = compile preprocessFileLineNumbers "\z\addons\dayz_code\system\BIS_Effects\AirDestruction.sqf";
BIS_Effects_AirDestructionStage2 = compile preprocessFileLineNumbers "\z\addons\dayz_code\system\BIS_Effects\AirDestructionStage2.sqf";
BIS_Effects_globalEvent = {
BIS_effects_gepv = _this;
publicVariable "BIS_effects_gepv";
_this call BIS_Effects_startEvent;
};
BIS_Effects_startEvent = {
switch (_this select 0) do {
case "AirDestruction": {
[_this select 1] spawn BIS_Effects_AirDestruction;
};
case "AirDestructionStage2": {
[_this select 1, _this select 2, _this select 3] spawn BIS_Effects_AirDestructionStage2;
};
case "Burn": {
[_this select 1, _this select 2, _this select 3, false, true] spawn BIS_Effects_Burn;
};
};
};
"BIS_effects_gepv" addPublicVariableEventHandler {
(_this select 1) call BIS_Effects_startEvent;
};
if ((!isServer) && (isNull player) ) then
{
waitUntil {!isNull player};
waitUntil {time > 3};
};
if ((!isServer) && (player != player)) then
{
waitUntil {player == player};
waitUntil {time > 3};
};
if (isServer) then {
_serverMonitor = [] execVM "\z\addons\dayz_code\system\server_monitor.sqf";
// "PVDZ_sec_atp" addPublicVariableEventHandler { diag_log format["%1", _this select 1];};
};
if (!isDedicated) then {
//Conduct map operations
0 fadeSound 0;
waitUntil {!isNil "dayz_loadScreenMsg"};
dayz_loadScreenMsg = (localize "STR_AUTHENTICATING");
//Run the player monitor
_id = player addEventHandler ["Respawn", {_id = [] spawn player_death;}];
_playerMonitor = [] execVM "\z\addons\dayz_code\system\player_monitor.sqf";
// [] execVM "\z\addons\dayz_code\system\antihack.sqf";
};
// Logo watermark: adding a logo in the bottom left corner of the screen with the server name in it
if (!isNil "dayZ_serverName") then {
[] spawn {
waitUntil {(!isNull Player) and (alive Player) and (player == player)};
waituntil {!(isNull (findDisplay 46))};
5 cutRsc ["wm_disp","PLAIN"];
((uiNamespace getVariable "wm_disp") displayCtrl 1) ctrlSetText dayZ_serverName;
};
};
#include "\z\addons\dayz_code\system\REsec.sqf";
[] execVM "addons\refuel_action.sqf";
[] execVM "batiments\batiment.sqf";

And this is my batiment.sqf :
if (isServer) then {

_vehicle_4 = objNull;
if (true) then
{
_this = createVehicle ["Land_HouseV2_02_Interier", [7243.9937, 7829.4937, -0.00012207031], [], 0, "CAN_COLLIDE"];
_vehicle_4 = _this;
_this setPos [7243.9937, 7829.4937, -0.00012207031];
};

_vehicle_5 = objNull;
if (true) then
{
_this = createVehicle ["Land_HouseBlock_D2", [7262.5161, 7798.8398, -0.00024414063], [], 0, "CAN_COLLIDE"];
_vehicle_5 = _this;
_this setPos [7262.5161, 7798.8398, -0.00024414063];
};

};

Help me please :(
 
Back
Top