Difference between revisions of "DayZ Epoch"
(10 intermediate revisions by one other user not shown) | |||
Line 1: | Line 1: | ||
− | |||
− | Base Building steps: | + | |
− | Crafting cookbook: | + | |
− | Tagging friendlies: | + | <h2> <span class="mw-headline" id="Basic_Information"> Basic Information </span></h2> |
− | + | ||
+ | '''All Epoch information can be found at http://dayzepoch.com/ or the Epoch official wiki here: http://dayzepoch.com/wiki/index.php?title=Main_Page''' | ||
+ | Base Building steps: http://dayzepoch.com/wiki/index.php/Base_Building_System | ||
+ | Crafting cookbook: http://dayzepoch.com/wiki/index.php/Crafting_System#Building_Recipes_for_1.0.1 | ||
+ | Tagging friendlies: http://dayzepoch.com/wiki/index.php/Tag_Friendly_Players | ||
+ | Tree Cutting: http://dayzepoch.com/wiki/index.php/Tree_Cutting_System | ||
+ | |||
+ | <h2> <span class="mw-headline" id="General_Options"> General Options </span></h2> | ||
+ | <p><b>Inside Init.sqf:</b><br /> | ||
+ | </p><p><br /> | ||
+ | </p><p>Enable purchased vehicle parachute spawning setting this to true. (Default: false) | ||
+ | </p> | ||
+ | <pre>DZE_TRADER_SPAWNMODE = true; | ||
+ | </pre> | ||
+ | <p><br /> | ||
+ | Enable full moon nights by setting this to true. (Default: false) | ||
+ | </p> | ||
+ | <pre>dayz_fullMoonNights = true; | ||
+ | </pre> | ||
+ | <p><br /> | ||
+ | Controls if the player will spawn on shore or not. 1 = Spawn must be on shore, 0 = anywhere. (Default: 1) | ||
+ | </p> | ||
+ | <pre>spawnShoremode = 1; | ||
+ | </pre> | ||
+ | <p><br /> | ||
+ | Controls how large of an area to search for a suitable spawn location. (Default: 1500) | ||
+ | </p> | ||
+ | <pre>spawnArea = 1500; | ||
+ | </pre> | ||
+ | <p><br /> | ||
+ | Defines acceptable play area if player is outside of area the players position will reset on reconnect. (Default: -20000) | ||
+ | </p> | ||
+ | <pre>dayz_minpos = -20000; | ||
+ | </pre> | ||
+ | <p><br /> | ||
+ | Defines acceptable play area if player is outside of area the players position will reset on reconnect. (Default: 20000) | ||
+ | </p> | ||
+ | <pre>dayz_maxpos = 20000; | ||
+ | </pre> | ||
+ | <p><br /> | ||
+ | Controls the max overall vehicle limit if this limit is reached no new vehicles will spawn. | ||
+ | </p> | ||
+ | <pre>MaxVehicleLimit = 50; | ||
+ | </pre> | ||
+ | <p><br /> | ||
+ | This is the overall area used to determine where to spawn vehicles, road debris, and helicopter crashes. (Default: 10000) | ||
+ | </p> | ||
+ | <pre>dayz_MapArea = 12000; | ||
+ | </pre> | ||
+ | <p><br /> | ||
+ | Experimental feature that will parachute spawn all players into the game. (Default: false) | ||
+ | </p> | ||
+ | <pre>dayz_paraSpawn = true; | ||
+ | </pre> | ||
+ | <p><br /> | ||
+ | Allows adding more potential spawn points. PLEASE NOTE: The extra markers named spawn5 - spawn10 must exist. *Don't use this unless you know exactly what you are doing* (Default: 4) | ||
+ | </p> | ||
+ | <pre>spawnMarkerCount = 10; | ||
+ | </pre> | ||
+ | <p><br /> | ||
+ | Controls animal spawn limits (Default: 8) | ||
+ | </p> | ||
+ | <pre>dayz_maxAnimals = 8; | ||
+ | </pre> | ||
+ | <p><br /> | ||
+ | Enables the ability to tame dogs with raw meat. (Default: false) | ||
+ | </p> | ||
+ | <pre>dayz_tameDogs = true; | ||
+ | </pre> | ||
+ | <p><br /> | ||
+ | Sets the lowest possible damage a fresh spawned vehicle will have. (Default: 0) | ||
+ | </p> | ||
+ | <pre>DynamicVehicleDamageLow = 0; | ||
+ | </pre> | ||
+ | <p><br /> | ||
+ | Sets the highest possible damage a fresh spawned vehicle will have. (Default: 100) | ||
+ | </p> | ||
+ | <pre>DynamicVehicleDamageHigh = 100; | ||
+ | </pre> | ||
+ | <p><br /> | ||
+ | Sets the lowest possible fuel level a fresh spawned vehicle will have. (Default: 0) | ||
+ | </p> | ||
+ | <pre>DynamicVehicleFuelLow = 0; | ||
+ | </pre> | ||
+ | <p><br /> | ||
+ | Sets the highest possible fuel level a fresh spawned vehicle will have. (Default: 100) | ||
+ | </p> | ||
+ | <pre>DynamicVehicleFuelHigh = 100; | ||
+ | </pre> | ||
+ | <p><br /> | ||
+ | Max number of zombies spawned per player. (Default: 40) | ||
+ | </p> | ||
+ | <pre>dayz_maxLocalZombies = 40; | ||
+ | </pre> | ||
+ | <p><br /> | ||
+ | Starting global max zombie count, this will increase for each player within 400m (Default: 40) | ||
+ | </p> | ||
+ | <pre>dayz_maxGlobalZombiesInit = 40; | ||
+ | </pre> | ||
+ | <p><br /> | ||
+ | Global zombie limit increase per player within 400m (Default: 10) | ||
+ | </p> | ||
+ | <pre>dayz_maxGlobalZombiesIncrease = 10; | ||
+ | </pre> | ||
+ | <p><br /> | ||
+ | Total zombie limit (Default: 500) | ||
+ | </p> | ||
+ | <pre>dayz_maxZeds = 500; | ||
+ | </pre> | ||
+ | <p><br /> | ||
+ | Disables zombies attacking vehicles. | ||
+ | </p> | ||
+ | <pre>dayz_zedsAttackVehicles = false; | ||
+ | </pre> | ||
+ | <p><br /> | ||
+ | Control the distance that you can sell a vehicle to the traders. | ||
+ | </p> | ||
+ | <pre>dayz_sellDistance = 20; | ||
+ | </pre> | ||
+ | <p><br /> | ||
+ | To enable debug so that road debris and new vehicle spawns are visible via map markers. Also debug will enable "Save to arma.RPT" that allows access of a tool to obtain lootpos information for buildings used for adding support for additional maps. *Only use this to diagnose issues with spawning* (Default: false) | ||
+ | </p> | ||
+ | <pre>DZEdebug = true; | ||
+ | </pre> | ||
+ | <p><br /> | ||
+ | To change how many debris spawn edit the MaxDynamicDebris variable in the missions init.sqf. | ||
+ | </p> | ||
+ | <pre>MaxDynamicDebris = 100; // Max number of road debris spawns (Default: 100) | ||
+ | </pre> | ||
+ | <p><br /> | ||
+ | Enable global chat messaging of player deaths. (Also requires enableRadio true;?) | ||
+ | </p> | ||
+ | <pre>DZE_DeathMsgGlobal = true; | ||
+ | </pre> | ||
+ | <p><br /> | ||
+ | Enable side chat messaging of player deaths. (Also requires enableRadio true;?) | ||
+ | </p> | ||
+ | <pre>DZE_DeathMsgSide = true; | ||
+ | </pre> | ||
+ | <p><br /> | ||
+ | Enable global title text messaging of player deaths. | ||
+ | </p> | ||
+ | <pre>DZE_DeathMsgTitleText = true; | ||
+ | </pre> | ||
+ | <p>Change amount of ammo boxes that spawn on the server. | ||
+ | </p> | ||
+ | <pre>MaxAmmoBoxes = 5; | ||
+ | </pre> | ||
+ | <p>Change amount of mining veins on the server. | ||
+ | </p> | ||
+ | <pre>MaxMineVeins = 50; | ||
+ | </pre> | ||
+ | <p>Enable/Disable machine gun ammo for vehicles with turrets being set to 0 ammo on server restarts. | ||
+ | </p> | ||
+ | <pre>DZE_vehicleAmmo = 0; //Default = 0, 1 to disable, 0 to enable. | ||
+ | </pre> | ||
+ | <p>Enable/Disable backpack contents being wiped if logging out or losing connection beside another player. | ||
+ | </p> | ||
+ | <pre>DZE_BackpackGuard = true; //Default = true, true to enable, false to disable | ||
+ | </pre> | ||
+ | <p>Change the number of constructed objects within range of a 30m Plot Pole. (default=150) | ||
+ | </p> | ||
+ | <ul><li><ul><li>Be very carefull with this number, as setting it too high will cause a huge amount of local lag** | ||
+ | </li></ul> | ||
+ | </li></ul> | ||
+ | <pre>DZE_BuildingLimit = 150; | ||
+ | </pre> | ||
+ | <p>Color coded name tag system, normally players will choose to show or not when logging in- | ||
+ | </p><p>Force all tags off for everyone: | ||
+ | </p> | ||
+ | <pre>DZE_ForceNameTagsOff | ||
+ | </pre> | ||
+ | <p>Force all tags to show for everyone: | ||
+ | </p> | ||
+ | <pre>DZE_ForceNameTags | ||
+ | </pre> | ||
+ | <p>Tag max view distance (default=25m): | ||
+ | </p> | ||
+ | <pre>DZE_HumanityTargetDistance = 25 | ||
+ | </pre> | ||
+ | <p><br /> | ||
+ | </p><p><b>Customize fresh spawn loadout</b> | ||
+ | </p><p>Change default fresh spawn loadout by adding: | ||
+ | </p> | ||
+ | <pre>DefaultMagazines = ["ItemBandage","ItemPainkiller"]; | ||
+ | DefaultWeapons = ["ItemFlashlight"]; | ||
+ | DefaultBackpack = ""; | ||
+ | DefaultBackpackWeapon = ""; | ||
+ | </pre> | ||
+ | <p>Magazines are anything that goes in the normal and sidearm inventory. | ||
+ | Weapons are any mainhand weapon, sidearm, or toolbelt item. | ||
+ | </p><p><br /> | ||
+ | <b>Lighting system</b> | ||
+ | </p><p>Epoch has a built in system for lighting streetlamps and house windows at night. | ||
+ | You can enable it by removing the '\\' in Front of the variable string at the bottom of the init.sqf, so that it looks like this: | ||
+ | </p> | ||
+ | <pre>//Lights | ||
+ | [17,6,true,false,true,true,72,242,600,10,[0.698, 0.556, 0.419],"Generator_DZ",208,"",0.5] execVM "\z\addons\dayz_code\compile\local_lights_init.sqf"; | ||
+ | </pre> | ||
+ | <p>The long string of variables all define how the lighting works, when it works, what percentage of lights to use, etc. The more lights you have on and the longer range you decide to show them on, the more load put on the server. If you already have issues with lag or desync, I recommend leaving this option commented out, or lowering the range and rates. More info on exactly what the variables are can be found here: <a rel="nofollow" class="external free" href="http://dayzepoch.com/wiki/index.php?title=Lighting_System">http://dayzepoch.com/wiki/index.php?title=Lighting_System</a> | ||
+ | </p> | ||
+ | <h2> <span class="mw-headline" id="Map_Marker">Turn off the red player map marker in game</span></h2> | ||
+ | <p>Follow the steps below to learn how to turn off the red map marker in game for players: | ||
+ | </p> | ||
+ | '''Step 1:'''Log into your FTP client. | ||
+ | |||
+ | '''Step 2:'''Follow this path to get to the proper file located in your FTP. (Admin/Users/Admin/Admin.ArmA2OAProfile). | ||
+ | |||
+ | '''Step 3:'''Copy Admin.ArmAOAProfile to your desktop. | ||
+ | |||
+ | '''Step 4:'''Stop your server using the stop button in your server panel under "Server Details". | ||
+ | |||
+ | '''Step 5:'''Open the Admin.ArmAOAProfile file in notepad++ and look for the following line "Map=1;" | ||
+ | |||
+ | <h2> <span class="mw-headline" id="Vehicles"> Vehicles </span></h2> | ||
+ | <p><br /> | ||
+ | <b>Change Vehicle Spawns</b> | ||
+ | <br /><br /> | ||
+ | Edit AllowedVehiclesList array found in dynamic_vehicle.sqf inside the mission.pbo.<br /> | ||
+ | <br /> | ||
+ | </p> | ||
+ | <pre>AllowedVehiclesList = [ <br /> | ||
+ | ["TT650_TK_CIV_EP1",1], <br /> | ||
+ | ["ATV_US_EP1",10],<br /> | ||
+ | ["hilux1_civil_3_open_EP1",5],<br /> | ||
+ | ["hilux1_civil_2_covered",2],<br /> | ||
+ | ["datsun1_civil_3_open",5],<br /> | ||
+ | ["Pickup_PK_TK_GUE_EP1",5]...<br /> | ||
+ | </pre> | ||
+ | <p><br /> | ||
+ | This controls the type of vehicle and the total limit per vehicle type. Note that the limit is soft and will typically spawn one more than the actual numbers.<br /><br /> | ||
+ | <b>Change total vehicle limit</b><br /> | ||
+ | <br /> | ||
+ | Edit the init.sqf variable MaxVehicleLimit and you change the total max vehicles, if this limit is reached no new vehicles will spawn.<br /> | ||
+ | <br /> | ||
+ | </p> | ||
+ | <pre>MaxVehicleLimit = 300; // Default : 50<br /> | ||
+ | </pre> | ||
+ | <p><br /> | ||
+ | Damage system uses a random percent between min and max variables. Defaults: <br /> | ||
+ | </p> | ||
+ | <pre>(DynamicVehicleDamageLow = 0; DynamicVehicleDamageHigh = 100;)<br /> | ||
+ | </pre> | ||
+ | <p><br /> | ||
+ | Fuel system uses a random percent between min and max variables. Defaults:<br /> | ||
+ | </p> | ||
+ | <pre>(DynamicVehicleFuelLow = 0; DynamicVehicleFuelHigh = 100;) <br /> | ||
+ | </pre> | ||
+ | <p><br /> | ||
+ | </p> | ||
+ | <h2> <span class="mw-headline" id="Traders"> Traders </span></h2> | ||
+ | <p><br /> | ||
+ | <br /> | ||
+ | SQL tables used by the game currently<br /> | ||
+ | <br /> | ||
+ | The traders_data table is the only one used at this time by the server. <br />The server_traders, trader_items, and trader_tids tables are used by a soon to be released web tool that is used to configure the traders_data table as well as generate server_traders.sqf.<br /><br /> | ||
+ | <b>Adding new items to traders</b><br /> | ||
+ | <br /> | ||
+ | </p> | ||
+ | <pre>INSERT INTO `Traders_DATA` (`item`,`qty`,`buy`,`sell`,`order`,`tid`,`afile`) VALUES ('["1Rnd_HE_M203",1]',10,'[4,"ItemGoldBar",1]','[2,"ItemGoldBar",1]',0,60,'trade_items')<br /> | ||
+ | </pre> | ||
+ | <p><br /> | ||
+ | item -- ["classname",type]<br /> | ||
+ | <br /> | ||
+ | qty -- Number of items in stock<br /> | ||
+ | <br /> | ||
+ | buy or sell -- [qty,"classname",type]<br /> | ||
+ | <br /> | ||
+ | Use the following as a table for items types in the columns Item, Buy and Sell:<br /> | ||
+ | <br /> | ||
+ | </p> | ||
+ | <pre> Weapons = 3<br /> | ||
+ | Vehicles and backpacks = 2<br /> | ||
+ | Magazines = 1 <br /> | ||
+ | </pre> | ||
+ | <p><br /> | ||
+ | order -- Allows override of display order. Typical range is 0 (low priority. Eg: 'Get out') to 6 (high priority. Eg: 'Auto-hover on').<br /> | ||
+ | <br /> | ||
+ | tid -- This number must match the trader category id found in the mission file server_traders.sqf<br /> | ||
+ | <br /> | ||
+ | afile -- Use the following types each of these represent a different .sqf file that performs the work:<br /> | ||
+ | <br /> | ||
+ | </p> | ||
+ | <pre> trade_items<br /> | ||
+ | trade_weapons<br /> | ||
+ | trade_any_vehicle<br /> | ||
+ | trade_any_boat<br /> | ||
+ | trade_backpacks <br /> | ||
+ | </pre> | ||
+ | <p><br /><br /> | ||
+ | <b>How to add stock for a specific item:</b><br /> | ||
+ | <br /> | ||
+ | In "Traders_DATA" table use SQL editor to filter by column "item" then "contains" then "Itemvault" then change the "qty" column to add more stock and save. Any changes to the qty will be live to the server instantly.<br /> | ||
+ | <br /> | ||
+ | Or execute this SQL:<br /> | ||
+ | <br /> | ||
+ | </p> | ||
+ | <pre>UPDATE `Traders_DATA` SET qty=10 WHERE `item` LIKE '%ItemVault%' AND qty=0;<br /> | ||
+ | </pre> | ||
+ | <p><br /> | ||
+ | We recommend running this code daily to ensure that traders have some stock except vehicles and boats since they should normally spawn dynamically and are already sold for profit.<br /> | ||
+ | <br /> | ||
+ | </p> | ||
+ | <pre>UPDATE `Traders_DATA` SET qty=10 WHERE qty=0 AND afile<>'trade_any_vehicle' AND afile<>'trade_any_boat';<br /> | ||
+ | </pre> | ||
+ | <p><br /> | ||
+ | <br /><br /> | ||
+ | </p> | ||
+ | <h2> <span class="mw-headline" id="Server_Maintenance"> Server Maintenance </span></h2> | ||
+ | <p><br /> | ||
+ | <br /> | ||
+ | <b>Remove destroyed vehicles from database</b>:<br /> | ||
+ | <br /> | ||
+ | Use the following SQL code: <br /> | ||
+ | </p> | ||
+ | <pre>DELETE FROM Object_DATA WHERE Damage = 1<br /> | ||
+ | </pre> | ||
+ | <p><br /> | ||
+ | Schedule it to run every day:<br /> | ||
+ | <br /> | ||
+ | </p> | ||
+ | <pre>DROP EVENT IF EXISTS removeDamageVehicles | ||
+ | CREATE EVENT removeDamagedVehicles<br /> | ||
+ | ON SCHEDULE EVERY 1 DAY<br /> | ||
+ | COMMENT 'Removes damaged vehicles'<br /> | ||
+ | DO<br /> | ||
+ | DELETE FROM Object_DATA WHERE Damage = 1<br /> | ||
+ | </pre> | ||
+ | <p><br /> | ||
+ | <br /> | ||
+ | <b>Prevent server cleanup of built objects</b>:<br /> | ||
+ | </p><p>We have already set the HiveExt.ini cleanup cycle for crafted items at -1, meaning it should not delete them in the default 6 days. However, sometimes the server code ignores this setting and does a cleanup anyways. To avoid losing any of your constructs, make sure you do the maintenance on them every week through the scroll-wheel menu for each item. | ||
+ | </p><p>If you really don't want to worry about anything being deleted, you can run the following SQL in the database to auto-update the timestamp on everything everyday. <b>This WILL lead to unused buildings staying on your server forever and causing lag and desync unless you go in the DB manually and prune things.</b> | ||
+ | </p><p><br /> | ||
+ | Use the following SQL code: <br /> | ||
+ | </p> | ||
+ | <pre>UPDATE `Object_DATA` SET `Datestamp`=CURRENT_TIMESTAMP WHERE `ObjectUID` <> 0 AND `CharacterID` <> 0 AND ( (`Inventory` IS NULL) OR (`Inventory` = '[]') )<br /> | ||
+ | </pre> | ||
+ | <p><br /> | ||
+ | Schedule it to run every day:<br /> | ||
+ | <br /> | ||
+ | </p> | ||
+ | <pre>DROP EVENT IF EXISTS preventCleanup | ||
+ | CREATE EVENT preventCleanup<br /> | ||
+ | ON SCHEDULE EVERY 1 DAY<br /> | ||
+ | COMMENT 'prevents all cleanup by setting datestamp to current'<br /> | ||
+ | DO<br /> | ||
+ | UPDATE `Object_DATA` SET `Datestamp`=CURRENT_TIMESTAMP WHERE `ObjectUID` <> 0 AND `CharacterID` <> 0 AND ( (`Inventory` IS NULL) OR (`Inventory` = '[]') )<br /> | ||
+ | </pre> | ||
+ | <p><br /> | ||
+ | If you only want to keep objects build by players that have logged in the last week. Use the following scheduled event instead:<br /> | ||
+ | <br /> | ||
+ | </p> | ||
+ | <pre> DROP EVENT IF EXISTS preventCleanup | ||
+ | CREATE EVENT preventCleanup | ||
+ | ON SCHEDULE EVERY 1 DAY | ||
+ | COMMENT 'prevents cleanup of objects build by active player by setting the timestamp to currect' | ||
+ | DO | ||
+ | |||
+ | UPDATE Object_DATA | ||
+ | SET Datestamp = CURRENT_TIMESTAMP | ||
+ | WHERE ObjectUID <> 0 | ||
+ | AND CharacterID <> 0 | ||
+ | AND ((Inventory IS NULL) OR (Inventory = '[]')) | ||
+ | AND EXISTS (SELECT 1 | ||
+ | FROM Character_DATA c | ||
+ | WHERE c.PlayerUID = (SELECT p.PlayerUID | ||
+ | FROM Player_DATA p, | ||
+ | Character_DATA c2 | ||
+ | WHERE p.PlayerUID = c2.PlayerUID | ||
+ | AND c2.CharacterID = Object_DATA.CharacterID) | ||
+ | AND c.Alive = 1 | ||
+ | AND c.LastLogin > NOW() - INTERVAL 1 WEEK)</pre> | ||
+ | <p><br /> | ||
+ | </p><p><br /> | ||
+ | </p><p><br /> | ||
+ | This is the full run of SQL events that the Epoch devs recommend using, you can choose to run any or all or none of these as you like. You can also modify them to change the intervals or quantities of stock/dmg/etc by reading them and changing the values logically. | ||
+ | </p><p>Update trader stock daily: | ||
+ | </p> | ||
+ | <pre>DROP EVENT IF EXISTS updateStockDaily; | ||
+ | CREATE EVENT updateStockDaily | ||
+ | ON SCHEDULE EVERY 1 DAY | ||
+ | COMMENT 'Updates out of stock vendors' | ||
+ | DO | ||
+ | UPDATE `Traders_DATA` SET qty=10 WHERE qty=0 AND afile<>'trade_any_vehicle' AND afile<>'trade_any_boat'; | ||
+ | ; | ||
+ | </pre> | ||
+ | <p>Remove destroyed vehicles: | ||
+ | </p> | ||
+ | <pre>DROP EVENT IF EXISTS removeDamagedVehicles; | ||
+ | CREATE EVENT removeDamagedVehicles | ||
+ | ON SCHEDULE EVERY 1 DAY | ||
+ | COMMENT 'Removes damaged vehicles' | ||
+ | DO | ||
+ | DELETE FROM `Object_DATA` WHERE Damage = 1; | ||
+ | ; | ||
+ | </pre> | ||
+ | <p>Remove abandoned objects that are 2 weeks old and empty: | ||
+ | </p> | ||
+ | <pre>DROP EVENT IF EXISTS removeObjectEmpty; | ||
+ | CREATE EVENT removeObjectEmpty | ||
+ | ON SCHEDULE EVERY 1 DAY | ||
+ | COMMENT 'Removes abandoned storage objects and vehicles' | ||
+ | DO | ||
+ | DELETE FROM `Object_DATA` WHERE `LastUpdated` < DATE_SUB(CURRENT_TIMESTAMP, INTERVAL 14 DAY) AND `Datestamp` < DATE_SUB(CURRENT_TIMESTAMP, INTERVAL 24 DAY) AND ( (`Inventory` IS NULL) OR (`Inventory` = '[]') OR (`Inventory` = '[[[],[]],[[],[]],[[],[]]]') ) | ||
+ | ; | ||
+ | </pre> | ||
+ | <p>Remove objects and vehicles that haven't been touched in 24 days: | ||
+ | </p> | ||
+ | <pre>DROP EVENT IF EXISTS removeObjectOld; | ||
+ | CREATE EVENT removeObjectOld | ||
+ | ON SCHEDULE EVERY 1 DAY | ||
+ | COMMENT 'Removes old objects and vehicles' | ||
+ | DO | ||
+ | DELETE FROM `Object_DATA` WHERE `LastUpdated` < DATE_SUB(CURRENT_TIMESTAMP, INTERVAL 24 DAY) AND `Datestamp` < DATE_SUB(CURRENT_TIMESTAMP, INTERVAL 42 DAY) | ||
+ | ; | ||
+ | </pre> | ||
+ | <p>Apply a small amount of damage to structures to allow maintenance after 3 days: | ||
+ | </p> | ||
+ | <pre>DROP EVENT IF EXISTS setDamageOnAge; | ||
+ | CREATE EVENT setDamageOnAge | ||
+ | ON SCHEDULE EVERY 1 DAY | ||
+ | COMMENT 'This sets damage on a wall so that it can be maintained' | ||
+ | DO | ||
+ | UPDATE `Object_DATA` SET `Damage`=0.1 WHERE `ObjectUID` <> 0 AND `CharacterID` <> 0 AND `Datestamp` < DATE_SUB(CURRENT_TIMESTAMP, INTERVAL 3 DAY) AND ( (`Inventory` IS NULL) OR (`Inventory` = '[]') ) | ||
+ | ; | ||
+ | </pre> |
Latest revision as of 13:41, 30 November 2014
Contents
Basic Information
All Epoch information can be found at http://dayzepoch.com/ or the Epoch official wiki here: http://dayzepoch.com/wiki/index.php?title=Main_Page Base Building steps: http://dayzepoch.com/wiki/index.php/Base_Building_System Crafting cookbook: http://dayzepoch.com/wiki/index.php/Crafting_System#Building_Recipes_for_1.0.1 Tagging friendlies: http://dayzepoch.com/wiki/index.php/Tag_Friendly_Players Tree Cutting: http://dayzepoch.com/wiki/index.php/Tree_Cutting_System
General Options
Inside Init.sqf:
Enable purchased vehicle parachute spawning setting this to true. (Default: false)
DZE_TRADER_SPAWNMODE = true;
Enable full moon nights by setting this to true. (Default: false)
dayz_fullMoonNights = true;
Controls if the player will spawn on shore or not. 1 = Spawn must be on shore, 0 = anywhere. (Default: 1)
spawnShoremode = 1;
Controls how large of an area to search for a suitable spawn location. (Default: 1500)
spawnArea = 1500;
Defines acceptable play area if player is outside of area the players position will reset on reconnect. (Default: -20000)
dayz_minpos = -20000;
Defines acceptable play area if player is outside of area the players position will reset on reconnect. (Default: 20000)
dayz_maxpos = 20000;
Controls the max overall vehicle limit if this limit is reached no new vehicles will spawn.
MaxVehicleLimit = 50;
This is the overall area used to determine where to spawn vehicles, road debris, and helicopter crashes. (Default: 10000)
dayz_MapArea = 12000;
Experimental feature that will parachute spawn all players into the game. (Default: false)
dayz_paraSpawn = true;
Allows adding more potential spawn points. PLEASE NOTE: The extra markers named spawn5 - spawn10 must exist. *Don't use this unless you know exactly what you are doing* (Default: 4)
spawnMarkerCount = 10;
Controls animal spawn limits (Default: 8)
dayz_maxAnimals = 8;
Enables the ability to tame dogs with raw meat. (Default: false)
dayz_tameDogs = true;
Sets the lowest possible damage a fresh spawned vehicle will have. (Default: 0)
DynamicVehicleDamageLow = 0;
Sets the highest possible damage a fresh spawned vehicle will have. (Default: 100)
DynamicVehicleDamageHigh = 100;
Sets the lowest possible fuel level a fresh spawned vehicle will have. (Default: 0)
DynamicVehicleFuelLow = 0;
Sets the highest possible fuel level a fresh spawned vehicle will have. (Default: 100)
DynamicVehicleFuelHigh = 100;
Max number of zombies spawned per player. (Default: 40)
dayz_maxLocalZombies = 40;
Starting global max zombie count, this will increase for each player within 400m (Default: 40)
dayz_maxGlobalZombiesInit = 40;
Global zombie limit increase per player within 400m (Default: 10)
dayz_maxGlobalZombiesIncrease = 10;
Total zombie limit (Default: 500)
dayz_maxZeds = 500;
Disables zombies attacking vehicles.
dayz_zedsAttackVehicles = false;
Control the distance that you can sell a vehicle to the traders.
dayz_sellDistance = 20;
To enable debug so that road debris and new vehicle spawns are visible via map markers. Also debug will enable "Save to arma.RPT" that allows access of a tool to obtain lootpos information for buildings used for adding support for additional maps. *Only use this to diagnose issues with spawning* (Default: false)
DZEdebug = true;
To change how many debris spawn edit the MaxDynamicDebris variable in the missions init.sqf.
MaxDynamicDebris = 100; // Max number of road debris spawns (Default: 100)
Enable global chat messaging of player deaths. (Also requires enableRadio true;?)
DZE_DeathMsgGlobal = true;
Enable side chat messaging of player deaths. (Also requires enableRadio true;?)
DZE_DeathMsgSide = true;
Enable global title text messaging of player deaths.
DZE_DeathMsgTitleText = true;
Change amount of ammo boxes that spawn on the server.
MaxAmmoBoxes = 5;
Change amount of mining veins on the server.
MaxMineVeins = 50;
Enable/Disable machine gun ammo for vehicles with turrets being set to 0 ammo on server restarts.
DZE_vehicleAmmo = 0; //Default = 0, 1 to disable, 0 to enable.
Enable/Disable backpack contents being wiped if logging out or losing connection beside another player.
DZE_BackpackGuard = true; //Default = true, true to enable, false to disable
Change the number of constructed objects within range of a 30m Plot Pole. (default=150)
- Be very carefull with this number, as setting it too high will cause a huge amount of local lag**
DZE_BuildingLimit = 150;
Color coded name tag system, normally players will choose to show or not when logging in-
Force all tags off for everyone:
DZE_ForceNameTagsOff
Force all tags to show for everyone:
DZE_ForceNameTags
Tag max view distance (default=25m):
DZE_HumanityTargetDistance = 25
Customize fresh spawn loadout
Change default fresh spawn loadout by adding:
DefaultMagazines = ["ItemBandage","ItemPainkiller"]; DefaultWeapons = ["ItemFlashlight"]; DefaultBackpack = ""; DefaultBackpackWeapon = "";
Magazines are anything that goes in the normal and sidearm inventory. Weapons are any mainhand weapon, sidearm, or toolbelt item.
Lighting system
Epoch has a built in system for lighting streetlamps and house windows at night.
You can enable it by removing the '\\' in Front of the variable string at the bottom of the init.sqf, so that it looks like this:
//Lights [17,6,true,false,true,true,72,242,600,10,[0.698, 0.556, 0.419],"Generator_DZ",208,"",0.5] execVM "\z\addons\dayz_code\compile\local_lights_init.sqf";
The long string of variables all define how the lighting works, when it works, what percentage of lights to use, etc. The more lights you have on and the longer range you decide to show them on, the more load put on the server. If you already have issues with lag or desync, I recommend leaving this option commented out, or lowering the range and rates. More info on exactly what the variables are can be found here: <a rel="nofollow" class="external free" href="http://dayzepoch.com/wiki/index.php?title=Lighting_System">http://dayzepoch.com/wiki/index.php?title=Lighting_System</a>
Turn off the red player map marker in game
Follow the steps below to learn how to turn off the red map marker in game for players:
Step 1:Log into your FTP client.
Step 2:Follow this path to get to the proper file located in your FTP. (Admin/Users/Admin/Admin.ArmA2OAProfile).
Step 3:Copy Admin.ArmAOAProfile to your desktop.
Step 4:Stop your server using the stop button in your server panel under "Server Details".
Step 5:Open the Admin.ArmAOAProfile file in notepad++ and look for the following line "Map=1;"
Vehicles
Change Vehicle Spawns
Edit AllowedVehiclesList array found in dynamic_vehicle.sqf inside the mission.pbo.
AllowedVehiclesList = [ <br /> ["TT650_TK_CIV_EP1",1], <br /> ["ATV_US_EP1",10],<br /> ["hilux1_civil_3_open_EP1",5],<br /> ["hilux1_civil_2_covered",2],<br /> ["datsun1_civil_3_open",5],<br /> ["Pickup_PK_TK_GUE_EP1",5]...<br />
This controls the type of vehicle and the total limit per vehicle type. Note that the limit is soft and will typically spawn one more than the actual numbers.
Change total vehicle limit
Edit the init.sqf variable MaxVehicleLimit and you change the total max vehicles, if this limit is reached no new vehicles will spawn.
MaxVehicleLimit = 300; // Default : 50<br />
Damage system uses a random percent between min and max variables. Defaults:
(DynamicVehicleDamageLow = 0; DynamicVehicleDamageHigh = 100;)<br />
Fuel system uses a random percent between min and max variables. Defaults:
(DynamicVehicleFuelLow = 0; DynamicVehicleFuelHigh = 100;) <br />
Traders
SQL tables used by the game currently
The traders_data table is the only one used at this time by the server.
The server_traders, trader_items, and trader_tids tables are used by a soon to be released web tool that is used to configure the traders_data table as well as generate server_traders.sqf.
Adding new items to traders
INSERT INTO `Traders_DATA` (`item`,`qty`,`buy`,`sell`,`order`,`tid`,`afile`) VALUES ('["1Rnd_HE_M203",1]',10,'[4,"ItemGoldBar",1]','[2,"ItemGoldBar",1]',0,60,'trade_items')<br />
item -- ["classname",type]
qty -- Number of items in stock
buy or sell -- [qty,"classname",type]
Use the following as a table for items types in the columns Item, Buy and Sell:
Weapons = 3<br /> Vehicles and backpacks = 2<br /> Magazines = 1 <br />
order -- Allows override of display order. Typical range is 0 (low priority. Eg: 'Get out') to 6 (high priority. Eg: 'Auto-hover on').
tid -- This number must match the trader category id found in the mission file server_traders.sqf
afile -- Use the following types each of these represent a different .sqf file that performs the work:
trade_items<br /> trade_weapons<br /> trade_any_vehicle<br /> trade_any_boat<br /> trade_backpacks <br />
How to add stock for a specific item:
In "Traders_DATA" table use SQL editor to filter by column "item" then "contains" then "Itemvault" then change the "qty" column to add more stock and save. Any changes to the qty will be live to the server instantly.
Or execute this SQL:
UPDATE `Traders_DATA` SET qty=10 WHERE `item` LIKE '%ItemVault%' AND qty=0;<br />
We recommend running this code daily to ensure that traders have some stock except vehicles and boats since they should normally spawn dynamically and are already sold for profit.
UPDATE `Traders_DATA` SET qty=10 WHERE qty=0 AND afile<>'trade_any_vehicle' AND afile<>'trade_any_boat';<br />
Server Maintenance
Remove destroyed vehicles from database:
Use the following SQL code:
DELETE FROM Object_DATA WHERE Damage = 1<br />
Schedule it to run every day:
DROP EVENT IF EXISTS removeDamageVehicles CREATE EVENT removeDamagedVehicles<br /> ON SCHEDULE EVERY 1 DAY<br /> COMMENT 'Removes damaged vehicles'<br /> DO<br /> DELETE FROM Object_DATA WHERE Damage = 1<br />
Prevent server cleanup of built objects:
We have already set the HiveExt.ini cleanup cycle for crafted items at -1, meaning it should not delete them in the default 6 days. However, sometimes the server code ignores this setting and does a cleanup anyways. To avoid losing any of your constructs, make sure you do the maintenance on them every week through the scroll-wheel menu for each item.
If you really don't want to worry about anything being deleted, you can run the following SQL in the database to auto-update the timestamp on everything everyday. This WILL lead to unused buildings staying on your server forever and causing lag and desync unless you go in the DB manually and prune things.
Use the following SQL code:
UPDATE `Object_DATA` SET `Datestamp`=CURRENT_TIMESTAMP WHERE `ObjectUID` <> 0 AND `CharacterID` <> 0 AND ( (`Inventory` IS NULL) OR (`Inventory` = '[]') )<br />
Schedule it to run every day:
DROP EVENT IF EXISTS preventCleanup CREATE EVENT preventCleanup<br /> ON SCHEDULE EVERY 1 DAY<br /> COMMENT 'prevents all cleanup by setting datestamp to current'<br /> DO<br /> UPDATE `Object_DATA` SET `Datestamp`=CURRENT_TIMESTAMP WHERE `ObjectUID` <> 0 AND `CharacterID` <> 0 AND ( (`Inventory` IS NULL) OR (`Inventory` = '[]') )<br />
If you only want to keep objects build by players that have logged in the last week. Use the following scheduled event instead:
DROP EVENT IF EXISTS preventCleanup CREATE EVENT preventCleanup ON SCHEDULE EVERY 1 DAY COMMENT 'prevents cleanup of objects build by active player by setting the timestamp to currect' DO UPDATE Object_DATA SET Datestamp = CURRENT_TIMESTAMP WHERE ObjectUID <> 0 AND CharacterID <> 0 AND ((Inventory IS NULL) OR (Inventory = '[]')) AND EXISTS (SELECT 1 FROM Character_DATA c WHERE c.PlayerUID = (SELECT p.PlayerUID FROM Player_DATA p, Character_DATA c2 WHERE p.PlayerUID = c2.PlayerUID AND c2.CharacterID = Object_DATA.CharacterID) AND c.Alive = 1 AND c.LastLogin > NOW() - INTERVAL 1 WEEK)
This is the full run of SQL events that the Epoch devs recommend using, you can choose to run any or all or none of these as you like. You can also modify them to change the intervals or quantities of stock/dmg/etc by reading them and changing the values logically.
Update trader stock daily:
DROP EVENT IF EXISTS updateStockDaily; CREATE EVENT updateStockDaily ON SCHEDULE EVERY 1 DAY COMMENT 'Updates out of stock vendors' DO UPDATE `Traders_DATA` SET qty=10 WHERE qty=0 AND afile<>'trade_any_vehicle' AND afile<>'trade_any_boat'; ;
Remove destroyed vehicles:
DROP EVENT IF EXISTS removeDamagedVehicles; CREATE EVENT removeDamagedVehicles ON SCHEDULE EVERY 1 DAY COMMENT 'Removes damaged vehicles' DO DELETE FROM `Object_DATA` WHERE Damage = 1; ;
Remove abandoned objects that are 2 weeks old and empty:
DROP EVENT IF EXISTS removeObjectEmpty; CREATE EVENT removeObjectEmpty ON SCHEDULE EVERY 1 DAY COMMENT 'Removes abandoned storage objects and vehicles' DO DELETE FROM `Object_DATA` WHERE `LastUpdated` < DATE_SUB(CURRENT_TIMESTAMP, INTERVAL 14 DAY) AND `Datestamp` < DATE_SUB(CURRENT_TIMESTAMP, INTERVAL 24 DAY) AND ( (`Inventory` IS NULL) OR (`Inventory` = '[]') OR (`Inventory` = '[[[],[]],[[],[]],[[],[]]]') ) ;
Remove objects and vehicles that haven't been touched in 24 days:
DROP EVENT IF EXISTS removeObjectOld; CREATE EVENT removeObjectOld ON SCHEDULE EVERY 1 DAY COMMENT 'Removes old objects and vehicles' DO DELETE FROM `Object_DATA` WHERE `LastUpdated` < DATE_SUB(CURRENT_TIMESTAMP, INTERVAL 24 DAY) AND `Datestamp` < DATE_SUB(CURRENT_TIMESTAMP, INTERVAL 42 DAY) ;
Apply a small amount of damage to structures to allow maintenance after 3 days:
DROP EVENT IF EXISTS setDamageOnAge; CREATE EVENT setDamageOnAge ON SCHEDULE EVERY 1 DAY COMMENT 'This sets damage on a wall so that it can be maintained' DO UPDATE `Object_DATA` SET `Damage`=0.1 WHERE `ObjectUID` <> 0 AND `CharacterID` <> 0 AND `Datestamp` < DATE_SUB(CURRENT_TIMESTAMP, INTERVAL 3 DAY) AND ( (`Inventory` IS NULL) OR (`Inventory` = '[]') ) ;
Share your opinion