Jump to content
  • 0
Sign in to follow this  
Cyrus

Event structure for setDamageOnAge

Question

I have been finding that some people on my server has been losing base walls and floors even though DZE_godmodebase = true; , it has no effect on anything built inside the plot radius. So i have come to the conclusion that base items might receive damage on age and this ultimately being removed by server cleanup script. So my question is if I drop this event below will that stop me and others from losing base walls and floor? Or at the minimum update it without any cinder wall items?

Spoiler
DROP EVENT IF EXISTS `setDamageOnAge`;
DELIMITER ;;
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` = '[]') OR (`Classname` IN ('Land_DZE_GarageWoodDoorLocked','Land_DZE_LargeWoodDoorLocked','Land_DZE_WoodDoorLocked',
 'CinderWallDoorLocked_DZ','CinderWallDoorSmallLocked_DZ','Plastic_Pole_EP1_DZ')) )
;;
DELIMITER ;
                                                                
                                                               

 

like this  and set damage to 0.001:

Spoiler
DROP EVENT IF EXISTS `setDamageOnAge`;
DELIMITER ;;
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.001 WHERE `ObjectUID` <> 0 AND `CharacterID` <> 0 
AND `Datestamp` < DATE_SUB(CURRENT_TIMESTAMP, INTERVAL 3 DAY) AND ( (`Inventory` IS NULL) 
OR (`Inventory` = '[]') OR (`Classname` IN ('Plastic_Pole_EP1_DZ')) )
;;
DELIMITER ;

 

 

Edited by Cyrus
made correction

Share this post


Link to post
Share on other sites

0 answers to this question

Recommended Posts

There have been no answers to this question yet

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Answer this question...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
Sign in to follow this  

  • Similar Content

    • By WeepiestLem0n
      So I've been wanting to create a private ArmA 2 DayZ Epoch server for a bunch of my mates to play on, however I dont have a dedicated machine and want to run it on my PC. So I looked at the server download files on the GitHub page and followed the ReadMe, however I absolutely cannot figure out how to get the MySQL server and DB set up. I have downloaded MySQL Server on my PC and created the admin role, root passwords and ran it as a windows service. I now have no clue how to create the database and am wondering if anyone can help me set this up or let me know if I've done anything wrong. 

      I can add on Steam or Discord if need be for convenience.
    • By jackalopeday
      Every time i try and join my server its stuck at waiting for authorization and the logs say "failed to get id". Any idea whats going on here. I am very new to server hosting so please explain in easy terms. :)
    • By JasonTM
      Some time ago I started a youtube channel doing DayZ Epoch tutorials. Surprisingly, my DayZ Epoch 1.0.6.1 server install video has amassed over 2500 views (and people say this game is dead).
      Here are some updated videos for 1.0.6.2. There are other videos on my channel that are still relevant.
      How to Install a DayZ Epoch 1.0.6.2 Server
      Things you will need to download:
      PBO Manager
      MySQL Community Server 5.7.22
      HeidiSQL
      Notepad++
      Notepad++ SQF Highlighter (optional, but highly recommended)
      7-Zip
       
      How to Upgrade Your DayZ Epoch 1.0.6.2 Server to an Overpoch Server
      Things you will need to download:
      Overwatch Server Key
      Overwatch mission.sqm (to copy and paste from)
      My Overpoch Loot Tables
      My Non-ZSC Overpoch Trader Files
      Midget Porn (Just kidding)
       
      How to Install Epoch Admin Tools
      Do not install these with infistar.
       
      How to Install Wicked AI for DayZ Epoch and Overpoch
       
      How to install infistar admin tools/antihack and infistar's free BRC rcon tool
      Fix for the unfortunate error in infistar v1448
       
       
      How to make Battleye filter exceptions for Infistar and other mods
      Downloads
      Eraser1's scripts.txt Exception Generator
      Ebay's Guide to Battleye Filters
       
      How to Install Ebay's Testkit
      Download
       
      Battleye Filter Tutorial using Ebay's Testkit and infistar's BRC rcon tool
       
      Server Install: Troubleshooting "session lost" and "wait for host" type issues.
       
      How to install BattlEye Extended Controls for automatic restarts
       
       
       
      I am planning on doing more of these when I get time.
       
       
       
       
    • By Cyrus
      I found this on another forum, but seeing as I am truly dedicated to this one, I thought I'd share what i have found concerning the question I see a lot of people ask regarding default loadouts for everyone, including respawns and new players to the server. Its customizable with current 1.0.6.2 class IDs.
      Unpack dayz_server.pbo and navigate to the compiles folder. Open the file named server_playerlogin.sqf. Find the follow block of code :
      _config = (configFile >> "CfgSurvival" >> "Inventory" >> "Default"); _mags = getArray (_config >> "magazines"); _wpns = getArray (_config >> "weapons"); _bcpk = getText (_config >> "backpack"); _randomSpot = true; _key = format["CHILD:203:%1:%2:%3:",_charID,[_wpns,_mags],[_bcpk,[],[]]]; _key call server_hiveWrite; and comment this out by adding /* */ to the top and bottom of this code block. Like this 
      /* _config = (configFile >> "CfgSurvival" >> "Inventory" >> "Default"); _mags = getArray (_config >> "magazines"); _wpns = getArray (_config >> "weapons"); _bcpk = getText (_config >> "backpack"); _randomSpot = true; _key = format["CHILD:203:%1:%2:%3:",_charID,[_wpns,_mags],[_bcpk,[],[]]]; _key call server_hiveWrite; */ Then directly underneath this paste the following and configure to your liking. I have tried this and it works.  To understand the logic, it is pointless to add a custom sqf in the mission folder, whether it be inside the init.sqf or a "exeVM" or a "call" method pointing to another custom sqf file seeing as the init is processed before server_playerlogin.sqf. 
      _randomSpot = true; _inventory = [["ItemFlashlight","ItemMap","ItemGPS","NVGoggles","AK_74"],["ItemBandage","ItemPainkiller","30Rnd_545x39_AK"]]; _backpack = ["DZ_ALICE_Pack_EP1",[],[]]; _key = format["CHILD:203:%1:%2:%3:",_charID,_inventory,_backpack]; _key call server_hiveWrite; Here is a list of most of the class ID's currently being used. Not all of them are there, but for this purpose you will find it more than adequate.
      https://forums.dayz.com/topic/137361-dayz-chernarus-class-ids/ 
      Finally we can now lay this beast to rest. Hope this will help many solve their default loadouts. I can recommend <ESSV3>  by @ebayShopperif you need more than a single loadout for all spawns.
    • By Cyrus
      Im looking for an easy, effective way to randomize loot (weapons, ammo, toolbelt items, food, meds and building supplies) in static crate. I have a placed crate already and populated with stuff but i would like to have this random on spawn. Also i would like to know how to have this crate stay for 2 hours then destroy and respawn 15 min later. This is what my customLootCrate.sqf looks like :
       
  • Advertisement
  • Supporters
  • Discord

×
×
  • Create New...