Jump to content

BigEgg

Member
  • Posts

    362
  • Joined

  • Last visited

  • Days Won

    28

Posts posted by BigEgg

  1. Here is my collection of cleanup scripts:

     

    -- --------------------------------------------------------------------------------
    -- --------------------------------Base Maintenance--------------------------------
    -- --------------------------------------------------------------------------------
    
    -- ----------------------------
    -- Fix inventory on maintainable objects.
    -- ----------------------------
    UPDATE `object_data`
    SET `inventory` = '[]',`LastUpdated` = `LastUpdated`
    WHERE `inventory` = '[[[],[]],[[],[]],[[],[]]]'
    AND
    `Classname` IN ('BagFenceRound_DZ','CinderWall_DZ','CinderWallDoorLocked_DZ','CinderWallDoorSmall_DZ','CinderWallDoorSmallLocked_DZ','CinderWallHalf_DZ','FireBarrel_DZ','GunRack_DZ','LightPole_DZ','MetalFloor_DZ','MetalPanel_DZ','OutHouse_DZ','TentStorage','TentStorageDomed','TentStorageDomed2','Sandbag1_DZ','Scaffolding_DZ','StickFence_DZ','StorageShed_DZ','WorkBench_DZ','WoodCrate_DZ','WoodFloor_DZ','WoodFloorQuarter_DZ','WoodLargeWall_DZ','WoodLargeWallWin_DZ','WoodShack_DZ','WoodSmallWall_DZ','WoodSmallWallThird_DZ','WoodSmallWallWin_DZ','Land_DZE_GarageWoodDoor','WoodFloorHalf_DZ','Fort_RazorWire','Land_DZE_LargeWoodDoorLocked','WoodStairsRails_DZ','WoodLadder_DZ','WoodStairsSans_DZ','M240Nest_DZ','Land_DZE_WoodDoor');
    
    -- ----------------------------
    -- Set 0.1 damage to objects daily.
    -- ----------------------------
    UPDATE `object_data`
    SET `Damage` = IF( `Damage` = 0.0, 0.1, `Damage` + 0.1 )
    WHERE `LastUpdated` <= DATE_SUB(NOW(), INTERVAL 1 DAY)
    AND `ObjectUID` <> 0
    AND `CharacterID` <> 0
    AND ( (`Inventory` IS NULL) OR (`Inventory` = '[]') );
    
    -- ----------------------------
    -- Set 0.1 damage doors/plots daily.
    -- ----------------------------
    UPDATE `object_data`
    SET `Damage` = IF( `Damage` = 0.0, 0.1, `Damage` + 0.1 )
    WHERE `Classname` IN ('Plastic_Pole_EP1_DZ','CinderWallDoorSmallLocked_DZ','CinderWallDoorLocked_DZ','CinderWallSmallDoorway_DZ','CinderWallDoorway_DZ','Land_DZE_WoodDoorLocked','CinderWallDoor_DZ','CinderWallDoorSmall_DZ','Land_DZE_WoodDoor','Land_DZE_GarageWoodDoor','Land_DZE_GarageWoodDoorLocked','Land_DZE_LargeWoodDoorLocked','Land_DZE_LargeWoodDoor','WoodLargeWallDoor_DZ')
    AND `LastUpdated` < DATE_SUB(CURRENT_TIMESTAMP, INTERVAL 1 DAY)
    AND `Inventory` != '[]';
    
    -- ----------------------------
    -- Set safe combinations to 0000 after 10 days of inactivity.
    -- ----------------------------
    UPDATE `object_data`
    SET `CharacterID` = 0
    WHERE `LastUpdated` < DATE_SUB(CURRENT_TIMESTAMP, INTERVAL 10 DAY)
    AND `CharacterID` > 0
    AND `Classname` = "VaultStorageLocked"
    AND `Inventory` <> '[]'
    AND `Inventory` IS NOT NULL;
    
    -- ----------------------------
    -- Set lockbox combinations to RED00 after 10 days of inactivity.
    -- ----------------------------
    UPDATE `object_data`
    SET `CharacterID` = 10000
    WHERE `LastUpdated` < DATE_SUB(CURRENT_TIMESTAMP, INTERVAL 10 DAY)
    AND `CharacterID` > 0
    AND `Classname` = "LockboxStorageLocked"
    AND `Inventory` <> '[]'
    AND `Inventory` IS NOT NULL;
    
    -- ----------------------------
    -- Delete empty storage objects.
    -- ----------------------------
    DELETE FROM `object_data`
    WHERE `LastUpdated` < DATE_SUB(CURRENT_TIMESTAMP, INTERVAL 3 DAY)
    AND ( (`Inventory` IS NULL) OR (`Inventory` = '[]') OR (`Inventory` = '[[[],[]],[[],[]],[[],[]]]') )
    AND `Classname` IN ('Wooden_shed_DZ','WoodShack_DZ', 'TentStorage', 'TentStorageDomed', 'TentStorageDomed2', 'WoodCrate_DZ', 'GunRack_DZ', 'OutHouse_DZ', 'StorageShed_DZ');
    
    -- ----------------------------
    -- Delete inactive storage objects.
    -- ----------------------------
    DELETE FROM `object_data`
    WHERE `LastUpdated` < DATE_SUB(CURRENT_TIMESTAMP, INTERVAL 10 DAY)
    AND `Classname` IN ('Wooden_shed_DZ','WoodShack_DZ', 'TentStorage', 'TentStorageDomed', 'TentStorageDomed2', 'WoodCrate_DZ', 'GunRack_DZ', 'OutHouse_DZ', 'StorageShed_DZ');
    
    -- ----------------------------
    -- Delete objects that have 1 damage.
    -- ----------------------------
    DELETE FROM `object_data`
    WHERE Damage = 1;
    
    -- ----------------------------
    -- Delete plot poles and doors not being deleted.
    -- ----------------------------
    DELETE FROM `object_data`
    WHERE `LastUpdated` < DATE_SUB(CURRENT_TIMESTAMP, INTERVAL 11 DAY)
    AND `Classname` IN ('Plastic_Pole_EP1_DZ','CinderWallDoorSmallLocked_DZ','CinderWallDoorLocked_DZ','CinderWallSmallDoorway_DZ','CinderWallDoorway_DZ','Land_DZE_WoodDoorLocked','CinderWallDoor_DZ','CinderWallDoorSmall_DZ','Land_DZE_WoodDoor','Land_DZE_GarageWoodDoor','Land_DZE_GarageWoodDoorLocked','Land_DZE_LargeWoodDoorLocked','Land_DZE_LargeWoodDoor','WoodLargeWallDoor_DZ');
    
    -- ----------------------------
    -- Delete old stuff.
    -- ----------------------------
    DELETE FROM `object_data`
    WHERE `LastUpdated` < DATE_SUB(CURRENT_TIMESTAMP, INTERVAL 21 DAY);
    
    -- --------------------------------------------------------------------------------
    -- ------------------------------Vehicle Maintenance-------------------------------
    -- --------------------------------------------------------------------------------
    
    -- ----------------------------
    -- Delete Bikes, ATV's, Mozzie's, 350z's, and Busses.
    -- ----------------------------
    DELETE FROM `object_data`
    WHERE `Classname` IN ('MMT_Civ','Old_bike_TK_INS_EP1','TT650_Civ','TT650_Ins','Old_moto_TK_Civ_EP1','M1030_US_DES_EP1','TT650_TK_CIV_EP1','ATV_CZ_EP1','ATV_US_EP1','CSJ_GyroC','350z','350z_red','350z_kiwi','350z_black','350z_silver','350z_green','350z_blue','350z_gold','350z_white','350z_pink','350z_mod','350z_ruben','350z_v','350z_city','350z_yellow','Ikarus','Ikarus_TK_CIV_EP1');
    
    -- ----------------------------
    -- Delete useless vehicles with no keys.
    -- ----------------------------
    DELETE FROM `object_data`
    WHERE `LastUpdated` < DATE_SUB(CURRENT_TIMESTAMP, INTERVAL 4 HOUR)
    AND `CharacterID` = '0'
    AND `Classname` IN ('AN2_DZ','GNT_C185U','GNT_C185','GNT_C185R','GNT_C185C','RHIB','Smallboat_1','Smallboat_2','Zodiac','Fishing_Boat','PBX','JetSkiYanahui_Case_Red','JetSkiYanahui_Case_Yellow','JetSkiYanahui_Case_Green','JetSkiYanahui_Case_Blue','CSJ_GyroP','CSJ_GyroCover','LandRover_CZ_EP1','LandRover_TK_CIV_EP1','HMMWV_M1035_DES_EP1','HMMWV_Ambulance','HMMWV_Ambulance_CZ_DES_EP1','HMMWV_DZ','HMMWV_DES_EP1','Civcar','Civcarbu','civcarbl','Civcarre','Civcarge','Civcarwh','Civcarsl','hilux1_civil_3_open_EP1','datsun1_civil_3_open_DZE','hilux1_civil_1_open_DZE','datsun1_civil_2_covered_DZE','datsun1_civil_1_open_DZE','hilux1_civil_2_covered_DZE','Skoda','SkodaBlue','SkodaGreen','SkodaRed','VolhaLimo_TK_CIV_EP1','Volha_1_TK_CIV_EP1','Volha_2_TK_CIV_EP1','VWGolf','car_hatchback','car_sedan','GLT_M300_LT','GLT_M300_ST','Lada1','Lada1_TK_CIV_EP1','Lada2','Lada2_TK_CIV_EP1','LadaLM','SUV_TK_CIV_EP1','SUV_Blue','SUV_Charcoal','SUV_Green','SUV_Orange','SUV_Pink','SUV_Red','SUV_Silver','SUV_White','SUV_Yellow','SUV_Camo','UAZ_CDF','UAZ_INS','UAZ_RU','UAZ_Unarmed_TK_CIV_EP1','UAZ_Unarmed_TK_EP1','UAZ_Unarmed_UN_EP1');
    
    -- ----------------------------
    -- Delete useless vehicles with keys.
    -- ----------------------------
    DELETE FROM `object_data`
    WHERE `LastUpdated` < DATE_SUB(CURRENT_TIMESTAMP, INTERVAL 3 DAY)
    AND `CharacterID` > 0
    AND `Classname` IN ('AN2_DZ','GNT_C185U','GNT_C185','GNT_C185R','GNT_C185C','RHIB','Smallboat_1','Smallboat_2','Zodiac','Fishing_Boat','PBX','JetSkiYanahui_Case_Red','JetSkiYanahui_Case_Yellow','JetSkiYanahui_Case_Green','JetSkiYanahui_Case_Blue','CSJ_GyroP','CSJ_GyroCover','LandRover_CZ_EP1','LandRover_TK_CIV_EP1','HMMWV_M1035_DES_EP1','HMMWV_Ambulance','HMMWV_Ambulance_CZ_DES_EP1','HMMWV_DZ','HMMWV_DES_EP1','Civcar','Civcarbu','civcarbl','Civcarre','Civcarge','Civcarwh','Civcarsl','hilux1_civil_3_open_EP1','datsun1_civil_3_open_DZE','hilux1_civil_1_open_DZE','datsun1_civil_2_covered_DZE','datsun1_civil_1_open_DZE','hilux1_civil_2_covered_DZE','Skoda','SkodaBlue','SkodaGreen','SkodaRed','VolhaLimo_TK_CIV_EP1','Volha_1_TK_CIV_EP1','Volha_2_TK_CIV_EP1','VWGolf','car_hatchback','car_sedan','GLT_M300_LT','GLT_M300_ST','Lada1','Lada1_TK_CIV_EP1','Lada2','Lada2_TK_CIV_EP1','LadaLM','SUV_TK_CIV_EP1','SUV_Blue','SUV_Charcoal','SUV_Green','SUV_Orange','SUV_Pink','SUV_Red','SUV_Silver','SUV_White','SUV_Yellow','SUV_Camo','UAZ_CDF','UAZ_INS','UAZ_RU','UAZ_Unarmed_TK_CIV_EP1','UAZ_Unarmed_TK_EP1','UAZ_Unarmed_UN_EP1');
    
    -- ----------------------------
    -- Delete server spawned vehicles.
    -- ----------------------------
    DELETE FROM `object_data`
    WHERE `LastUpdated` < DATE_SUB(CURRENT_TIMESTAMP, INTERVAL 3 DAY)
    AND `CharacterID` = '0'
    AND `Classname`
    NOT REGEXP 'barrier|storage|shed|bench|wall|floor|fence|pump|wood|hrescue|stick|pole|generator|panel|house|rack|bag|stand|barrel|canvas|wire|hedgehog|net|trap|ramp|fort|sand|scaffold|nest|killhouse|villa|castle|pub|shelter|stodola|garage|MBG|warehouse|sara';
    
    -- ----------------------------
    -- Delete all vehicles not touched in 10 days.
    -- ----------------------------
    DELETE FROM `object_data`
    WHERE `LastUpdated` < DATE_SUB(CURRENT_TIMESTAMP, INTERVAL 10 DAY)
    AND `Classname`
    NOT REGEXP 'barrier|storage|shed|bench|wall|floor|fence|pump|wood|hrescue|stick|pole|generator|panel|house|rack|bag|stand|barrel|canvas|wire|hedgehog|net|trap|ramp|fort|sand|scaffold|nest|killhouse|villa|castle|pub|shelter|stodola|garage|MBG|warehouse|sara';
    
    -- ----------------------------
    -- Unlock purchased, inactive vehicles.
    -- ----------------------------
    UPDATE `object_data`
    SET `CharacterID` = 0,`LastUpdated` = `LastUpdated`
    WHERE `LastUpdated` < DATE_SUB(CURRENT_TIMESTAMP, INTERVAL 7 DAY)
    AND `CharacterID` > 0
    AND `Classname`
    NOT REGEXP 'barrier|storage|shed|bench|wall|floor|fence|pump|wood|hrescue|stick|pole|generator|panel|house|rack|bag|stand|barrel|canvas|wire|hedgehog|net|trap|ramp|fort|sand|scaffold|nest|killhouse|villa|castle|pub|shelter|stodola|garage|MBG|warehouse|sara';
    
    -- ----------------------------
    -- Unlock vehicle's with no key.
    -- ----------------------------
    UPDATE `Object_DATA`
    SET `Object_DATA`.`CharacterID` = 0,`LastUpdated` = `LastUpdated`
    WHERE `Object_DATA`.`CharacterID` <> 0
    AND`Object_DATA`.`CharacterID` <= 12500
    AND`Object_DATA`.`Classname` NOT LIKE 'Tent%'
    AND`Object_DATA`.`Classname` NOT LIKE '%Locked'
    AND`Object_DATA`.`Classname` NOT LIKE 'Land%'
    AND`Object_DATA`.`Classname` NOT LIKE 'Cinder%'
    AND`Object_DATA`.`Classname` NOT LIKE 'Wood%'
    AND`Object_DATA`.`Classname` NOT LIKE 'Metal%'
    AND`Object_DATA`.`Classname` NOT LIKE '%Storage%'
    AND`Object_DATA`.`Classname` NOT IN ('OutHouse_DZ', 'GunRack_DZ', 'WorkBench_DZ', 'Sandbag1_DZ', 'FireBarrel_DZ', 'DesertCamoNet_DZ', 'StickFence_DZ', 'LightPole_DZ', 'DeerStand_DZ', 'ForestLargeCamoNet_DZ', 'Plastic_Pole_EP1_DZ', 'Hedgehog_DZ', 'FuelPump_DZ', 'Fort_RazorWire', 'SandNest_DZ', 'ForestCamoNet_DZ', 'Fence_corrugated_DZ', 'CanvasHut_DZ', 'Generator_DZ')
    AND FindVehicleKeysCount(Object_DATA.CharacterID) = 0;
    
    -- --------------------------------------------------------------------------------
    -- -------------------------------Player Maintenance-------------------------------
    -- --------------------------------------------------------------------------------
    
    -- ----------------------------
    -- Delete player login data.
    -- ----------------------------
    DELETE FROM `player_login`;
    
    -- ----------------------------
    -- Delete dead characters.
    -- ----------------------------
    DELETE from Character_data
    USING Character_data, Character_data as tempchartable
    WHERE (Character_data.PlayerUID = tempchartable.PlayerUID)
    AND (NOT Character_data.alive = tempchartable.alive)
    AND (Character_data.alive = 0);
    
    -- ----------------------------
    -- Delete characters inactive for 30 days.
    -- ----------------------------
    DELETE FROM Character_DATA 
    WHERE LastLogin < NOW() - INTERVAL 30 DAY;

     

  2. 20 hours ago, DieTanx said:
      Hide contents

    Error in expression <ernarus\vehicle_deploy\config.sqf"
    if !(_deployInCombat) then {
    if (player getVa>
      Error position: <_deployInCombat) then {
    if (player getVa>
      Error Undefined variable in expression: _deployincombat
    File mpmissions\__CUR_MP.Chernarus\vehicle_deploy\config.sqf, line 1

    I get a Client side error with this.

     

    I am still able to craft/pack without issues even with error.

        _combat = false; is set like this for all vehicles i have for crafting.

    It appears that when I fixed this issue, it also pasted the fixed code at the top of the config file when I made the commit (I did it through github website so that might have messed up or I was just tired lol) - anyways the fix is located here:

    https://github.com/BigEgg17/Vehicle-Deployment/commit/7465feb33061322a907002ed693d622f5b767d25

     

    Or you can simply re-download the files :)

  3. 8 hours ago, juandayz said:

    @hellraver great! this is awesome to start to play with the code a lil if u dont mine.

    nothing is tested ok? but maybe in churches.sqf you can use the epoch trader objects structure

    churches.sqf

      Hide contents
    
    
    //churchs by hellraver
    private ["_blockDamage","_fires","_object","_objects","_type"];
    
    fn_spawnchurch {
    _objects = _this select 0;
    _blockDamage = _this select 1;
    
    
    
    {
    	_type = _x select 0;
    	_object = _type createVehicleLocal [0,0,0];
    	_object setDir (_x select 2);
    	_object setPos (_x select 1);
    	_object setVariable ["",true,false]; // stops global setVariable by sched_townGenerator, checked in player_spawnCheck for loot spawn
    	if (_blockDamage) then {
    		_object addEventHandler ["HandleDamage",{0}];
    		
    	};
    } forEach _objects;
    };
    
    [[
    	["Land_Church_03",[6027.6387, 7777.9604,0.21592264],220.29143],//Church Stary Sobor
    	
    	["Land_Church_03",[6179.9837, 10411.974, 1.0130899],201.64735],//Church Grishino
    	
    	["Land_Church_03",[2718.3496, 10049.25,0.36714295],-22.087906],//Church Lopatino
    	
    	["Land_Church_03",[2741.4951, 5460.6431,0.59279299],-59.786922],//Church Zelenogorsk
    	
    	["Land_Church_03",[1731.7397, 3828.8367,0.36492082],-16.372017],//Church Pavlovo
    	
    	["Land_Church_03",[1743.2777, 3824.4163,-1.3266945],-196.41689],//Stairs Church Pavlovo
    	
    	["Land_Church_03",[7409.1499, 5175.6997,0.30705196],-134.79289],//Church Mogilevka
    	
    	["Land_Church_03",[12866.221, 10142.662,0.093297787],204.55789]//Church Sawmill
    
    ],true] call fn_spawnchurch;	

    call it from

    
    
    call compile preprocessFileLineNumbers "\z\addons\dayz_code\system\mission\chernarus11.sqf"; 
    call compile preprocessFileLineNumbers "\z\addons\dayz_server\churches.sqf";//new churches

     

     

    now you can use some actions into the churches.

    for example in a custom fn_selfactions.sqf

    at bottom add:

      Hide contents
    
    
    //churches pray
    private["_playerPos","_nearchurch"];
    
    _playerPos = getPosATL player;
    _nearchurch = count nearestObjects [_playerPos, ["Land_Church_03"], 3] > 0;
     
    if (_nearchurch) then {
            if (s_player_pray < 0) then {
                s_player_pray = player addaction[("<t color=""#F7D708"">" + ("Pray For a Miracle") +"</t>"),"churches\pray.sqf"];
            };
        } else {
            player removeAction s_player_pray;
            s_player_pray = -1;
        };		

     

    pray.sqf (mpmissions\instance_11-chernarus\churches\ )

      Reveal hidden contents
    
    
    private ["_LastUsedTime","_Time","_isHero","_isBandit","_miracleChanceB","_miracleChanceS","_miracleChanceH","_miraclerand"];
    
    _LastUsedTime = 900;
    _Time = time - lastuse;	
    _isHero = (player getVariable["humanity",0]) >= 5000;
    _isBandit = (player getVariable["humanity",0]) <= 5000;
    _miraclerand	= round(random 10);
    _miracleChanceH	= 5;
    _miracleChanceS	= 3;
    _miracleChanceB	= 2;
    
    if(_Time < _LastUsedTime) exitWith { 
        cutText [format["wait %1 seconds",(round(_Time - _LastUsedTime))], "PLAIN DOWN"]; 
    };
    
    fn_heal {
    
    	disableSerialization;
                                    dayz_sourceBleeding = objNull;
                                    r_player_blood = r_player_bloodTotal;
                                    r_player_inpain = false;
                                    r_player_infected = false;
                                    r_player_injured = false;
                                    dayz_hunger = 0;
                                    dayz_thirst = 0;
                                    dayz_temperatur = 37;
                                    r_fracture_legs = false;
                                    r_fracture_arms = false;
                                    r_player_dead = false;
                                    r_player_unconscious = false;
                                    r_player_loaded = false;
                                    r_player_cardiac = false;
                                    r_player_lowblood = false;
                                    r_player_timeout = 0;
                                    r_handlercount = 0;
                                    r_interrupt = false;
                                    r_doLoop = false;
                                    r_drag_sqf = false;
                                    r_self = false;
                                    r_action = false;
                                    r_action_unload = false;
                                    r_player_handler = false;
                                    r_player_handler1 = false;
                                    disableUserInput false;
                                    'dynamicBlur' ppEffectAdjust [0];
                                    'dynamicBlur' ppEffectCommit 5;
                                    _selection = 'legs';
                                    _damage = 0;
                                    player setHit[_selection,_damage];
                                    player setVariable['messing',[dayz_hunger,dayz_thirst],true];
                                    player setVariable['NORRN_unconscious',false,true];
                                    player setVariable['USEC_infected',false,true];
                                    player setVariable['USEC_injured',false,true];
                                    player setVariable['USEC_inPain',false,true];
                                    player setVariable['USEC_isCardiac',false,true];
                                    player setVariable['USEC_lowBlood',false,true];
                                    player setVariable['USEC_BloodQty',12000,true];
                                    player setVariable['unconsciousTime',0,true];
                                    player setVariable['hit_legs',0,true];
                                    player setVariable['hit_hands',0,true];
                                    player setVariable['medForceUpdate',true,true];
                                    _display = uiNameSpace getVariable 'DAYZ_GUI_display';
                                    _control = _display displayCtrl 1303;
                                    _control ctrlShow false;
                                    _display = uiNameSpace getVariable 'DAYZ_GUI_display';
                                    _control = _display displayCtrl 1203;
                                    _control ctrlShow false;
                                    player setdamage 0;
                                    0 fadeSound 1;
                                    resetCamShake;
    								lastuse = time;
    };
    
    
    
    
    if (_isHero) then {
    if (_miraclerand < _miracleChanceH)  exitWith {
    systemChat("God its not here today");
    };
    [player,50] call player_humanityChange;
    call fn_heal;
    }else{
    if (_isBandit) then {
    if (_miraclerand < _miracleChanceB)  exitWith {
    systemChat("God its not here today");
    };
    [player,50] call player_humanityChange;
    call fn_heal;
    }else{
    if (!_isHero && !_isBandit) then {	
    if (_miraclerand < _miracleChanceS)  exitWith {
    systemChat("God its not here today");
    };
    [player,50] call player_humanityChange;
    call fn_heal;
    };
    };
    };

     

    this is just an idea mate, nothing is tested.

    [[
    	["Land_Church_03", [6027.6387, 7777.9604,0.21592264], 220.29143], // Church Stary Sobor
    	["Land_Church_03", [6179.9837, 10411.974, 1.0130899], 201.64735], // Church Grishino
    	["Land_Church_03", [2718.3496, 10049.25,0.36714295], -22.087906], // Church Lopatino
    	["Land_Church_03", [2741.4951, 5460.6431,0.59279299], -59.786922], // Church Zelenogorsk
    	["Land_Church_03", [1731.7397, 3828.8367,0.36492082], -16.372017], // Church Pavlovo
    	["Land_Church_03", [1743.2777, 3824.4163,-1.3266945], -196.41689], // Stairs Church Pavlovo
    	["Land_Church_03", [7409.1499, 5175.6997,0.30705196], -134.79289], // Church Mogilevka
    	["Land_Church_03", [12866.221, 10142.662,0.093297787], 204.55789] // Church Sawmill
    ], true, false, false] call fnc_spawnObjects;

    Would spawn the churches globally instead of locally and would make them indestructible.

  4. 3 hours ago, kingpapawawa said:

    Getting about average 10 more FPS on 3 servers.

    I believe @BigEgg gets the credit for figuring out this one. @ndavalos wrote the code below to temp fix it and @icomrade patched it for the next update.... but unless you follow the github issues, (and you should)  you may have missed this one as its buried in a post i made several weeks ago.

    this code goes at the bottom of your init.

    see this for more info https://github.com/EpochModTeam/DayZ-Epoch/issues/1926

    edit:  this code will need to be removed when 1.0.6.2 comes out.

    Posting this because ive spoken with 2 other server owners who hadn't seen this info.

    
    if (hasInterface) then {
    dayz_rollingMessages = {
    	private "_showText";
    	disableSerialization;
    	_showText = {
    		private "_textLine";
    		15 cutRsc ["RSC_DZ_Messages","plain"];
    		_textLine = (uiNamespace getVariable "DZ_Messages") displayCtrl 4099998;
    		_textLine ctrlSetStructuredText (parseText _this);
    		_textLine ctrlCommit 0;
    	};
    	if (typeName _this == "ARRAY") exitWith {(_this select 0) call _showText}; //Special or multi-line message
    	if ((diag_ticktime - Message_1_time) < 5) then {
    		if ((time - Message_2_time) < 5) then {
    			Message_3 = Message_2;
    			Message_3_time = Message_2_time;
    		} else {
    			Message_3 = "";
    		};
    		
    		Message_2 = Message_1;
    		Message_2_time = Message_1_time;
    	} else {
    		Message_2 = "";
    		Message_3 = "";
    	};
    
    	Message_1 = _this;
    	Message_1_time = diag_ticktime;
    	(format ["%1<br></br>%2<br></br>%3", Message_1, Message_2, Message_3]) call _showText;
    };
    };

    Also throw some credit to @MG-Maximus - he was the one that lead me to test the issue ;)

  5. I needed a nice deploy script that was minimal but did everything I needed it to do. So I made my own :)

     

    I need to do some optimizing with this code (change the config into arrays - other small things) but it works great :)

     

    What it does:

    • Allows players to deploy a Bike, ATV, or a Mozzie (by default).

    • Compatible with almost all (if not all) vehicles.

    • Required parts can include both magazines and toolbelt items (or weapons in general if needed).

    • Vehicles can be deployed on high buildings, bases, or bridges without issue.

    • The server owner can:

      • Configure what vehicles players can deploy
      • Decide if the player will go through an animation while deploying the vehicle
      • Decide if the player can deploy the vehicle while within someone else's plot area
      • Decide if the player can deploy the vehicle while in combat
      • Decide if the vehicle can be sold at traders
      • Decide if the player can deploy the vehicle while in a vehicle
      • Decide if the vehicle should have it's ammo removed when deployed
      • Decide if the player can deploy the vehicle on a ladder
      • Decide what parts each vehicle needs to be deployed
      • Decide what the display name of the vehicle will be on all messages that appear during the process

     

    I have made the files more configurable (I normally don't have all of the config options - I put them there for other people to be easily able to configure it in whatever way they like), so there might be a bug or two I am unaware of, so please post if you find one :)

     

    Download and install instructions on my github:

    https://github.com/BigEgg17/Vehicle-Deployment#installation

     

  6. In your init.sqf, paste the following code:

    vehsRemoveThermal = [];

    In your server_monitor.sqf find:

    [_object,"damage"] call server_updateObject;

    Below it add:

    {
    	if (_object isKindOf _x) then {
    		_object disableTIEquipment true;
    	};
    } forEach vehsRemoveThermal;

    In dayz_server\compile\server_publishVehicle2.sqf, find:

    clearWeaponCargoGlobal  _object;
    clearMagazineCargoGlobal  _object;

    Below it add:

    {
    	if (_object isKindOf _x) then {
    		_object disableTIEquipment true;
    	};
    } forEach vehsRemoveThermal;

     

    Done - any vehicle you enter into vehsRemoveThermal will not have thermal.

     

    Example:

    vehsRemoveThermal = ["HMMWV_m998_crows_M2_DES_EP1"];

     

  7. 32 minutes ago, Jim90 said:

    In order to stop building around the airfields I made multiple points which overlap along the length of each runway.  Was wondering if this could cause any problems or if there is a better way to do it?  Below is my init.sqf config covering stock Chernarus 11 trader positions, airfields, 9 buildings, 2 plotpoles and 30m build height.  I have this on my server now and it all looks to all be working good.

      Reveal hidden contents

    // Restrict Building mod
    LimitPlotPoles = true; // Limit the amount of plot poles a player can own?
    if (LimitPlotPoles) then {PlotPoleLimit = 2; };    // Amount of plot poles each individual player is allowed to own

    LimitBuildHeight = true; // Limit the maximum height a player can build at
    if (LimitBuildHeight) then {MaxBuildHeight = 30;}; // Maximum build height in meters
        
    BlacklistedBuildings = [        // Restrict building near specific buildings
    ["Barracks", "Land_Mil_Barracks", 15],
    ["Barracks", "Land_Mil_Barracks_i", 15],
    ["Fire Station", "Land_a_stationhouse", 30],
    ["Fire Station", "Land_a_stationhouse_ep1", 30],
    ["Hospital", "Land_a_Hospital", 30],
    ["Factory", "Land_a_Tovarna2", 30],
    ["Factory", "Land_Ind_Pec_03a", 30],
    ["Supermarket", "Land_A_Generalstore_01", 30],
    ["Supermarket", "Land_A_Generalstore_01a", 30]
    ];    //  ["What text will say", "Class name of building you want to block", Distance around that building to block (radius in meters)]

    RestrictedBuildingZones = [     // Restrict building near map areas
    ["Stary Trader", [6325,7807, 0], 1000],
    ["Bash Trader", [4063,11664, 0], 500],
    ["Klen Trader", [11447,11364, 0], 500],
    ["Hero Trader", [12944,12766, 0], 500],
    ["Bandit Trader", [1606,7803, 0], 500],
    ["NEAF", [12475,12578, 0], 500],
    ["NEAF", [12302,12641, 0], 500],
    ["NEAF", [12130,12705, 0], 500],
    ["NEAF", [11957,12768, 0], 500],
    ["NEAF", [11785,12832, 0], 500],
    ["NWAF", [4159, 10895, 0], 500],
    ["NWAF", [4251, 10740, 0], 500],
    ["NWAF", [4343, 10548, 0], 500],
    ["NWAF", [4435, 10428, 0], 500],
    ["NWAF", [4527, 10272, 0], 500],
    ["NWAF", [4619, 10116, 0], 500],
    ["NWAF", [4711, 9960, 0], 500],
    ["NWAF", [4803, 9804, 0], 500],
    ["NWAF", [4897, 9648, 0], 500],
    ["Balota Airfield", [4612, 2473, 0], 500],
    ["Balota Airfield", [4767, 2432, 0], 500],
    ["Balota Airfield", [4923, 2392, 0], 500],
    ["Balota Airfield", [5079, 2301, 0], 500],
    ["Balota Airfield", [5235, 2211, 0], 500]
    ];    //  ["What text will say", [Choords of place to block], Distance around that area to block (radius in meters)]

     

    Not an issue at all, I do the same thing :) 

×
×
  • Create New...