Jump to content

Basti890

Member
  • Posts

    33
  • Joined

  • Last visited

Reputation Activity

  1. Like
    Basti890 got a reaction from salival in [Request] Disabling salvaging for Locked Vehicles   
    got this working on my epoch 1.0.5.1
    salvage_vehicle.sqf:
    private ["_part","_cancel","_color","_percent","_string","_handle","_damage","_cmpt","_vehicle","_hitpoints"]; _vehicle = _this select 3; {dayz_myCursorTarget removeAction _x} count s_player_repairActions; s_player_repairActions = []; _hitpoints = _vehicle call vehicle_getHitpoints; { _damage = [_vehicle,_x] call object_getHit; _part = "PartGeneric"; //change "HitPart" to " - Part" rather than complicated string replace _cmpt = toArray (_x); _cmpt set [0,20]; _cmpt set [1,toArray ("-") select 0]; _cmpt set [2,20]; _cmpt = toString _cmpt; if(["Engine",_x,false] call fnc_inString) then { _part = "PartEngine"; }; if(["HRotor",_x,false] call fnc_inString) then { _part = "PartVRotor"; //yes you need PartVRotor to fix HRotor LOL }; if(["Fuel",_x,false] call fnc_inString) then { _part = "PartFueltank"; }; if(["Wheel",_x,false] call fnc_inString) then { _part = "PartWheel"; }; if(["Glass",_x,false] call fnc_inString) then { _part = "PartGlass"; }; // allow removal of any lightly damaged parts if (_damage < 1) then { // Do not allow removal of engine or fueltanks if( _part == "PartGlass" || _part == "PartWheel" || _part == "PartEngine" || _part == "PartVRotor" || _part == "PartFueltank" || _part == "PartGeneric" ) then { _color = "color='#00ff00'"; // green if (_damage >= 0.1) then {_color = "color='#bfff00'";}; //light-green if (_damage >= 0.35) then {_color = "color='#ffff00'";}; //yellow if (_damage >= 0.65) then {_color = "color='#ff8800'";}; //orange if (_damage >= 0.9) then {_color = "color='#ff0000'";}; //red _percent = round(_damage*100); _string = format["<t %2>Remove%1 (%3 %4)</t>",_cmpt,_color,_percent,"%"]; //Remove - Part _handle = dayz_myCursorTarget addAction [_string, "\z\addons\dayz_code\actions\salvage.sqf",[_vehicle,_part,_x], 0, false, true, "",""]; s_player_repairActions set [count s_player_repairActions,_handle]; }; }; } count _hitpoints; if(count _hitpoints > 0 ) then { _cancel = dayz_myCursorTarget addAction [localize "STR_EPOCH_PLAYER_CANCEL", "\z\addons\dayz_code\actions\repair_cancel.sqf","repair", 0, true, false, "",""]; s_player_repairActions set [count s_player_repairActions,_cancel]; s_player_repair_crtl = 1; };fn_selfActions.sqf (particular):
    //Repairing Vehicles if ((dayz_myCursorTarget != _cursorTarget) && _isVehicle && !_isMan && _hasToolbox && (damage _cursorTarget < 1) && !_isDisallowRepair) then { if (s_player_repair_crtl < 0) then { dayz_myCursorTarget = _cursorTarget; _menu = dayz_myCursorTarget addAction [localize "STR_EPOCH_PLAYER_REPAIRV", "\z\addons\dayz_code\actions\repair_vehicle.sqf",_cursorTarget, 0, true, false, "",""]; s_player_repairActions set [count s_player_repairActions,_menu]; if(!locked _cursorTarget) then { _menu1 = dayz_myCursorTarget addAction [localize "STR_EPOCH_PLAYER_SALVAGEV", "custom\salvage_vehicle.sqf",_cursorTarget, 0, true, false, "",""]; s_player_repairActions set [count s_player_repairActions,_menu1]; }; s_player_repair_crtl = 1; } else { {dayz_myCursorTarget removeAction _x} count s_player_repairActions;s_player_repairActions = []; s_player_repair_crtl = -1; }; }; 
  2. Like
    Basti890 reacted to Ganja in Show Off Your Base   
    My newest work in progress....
     
    I call it...Mt.WTF







     
    Still a lot of work to do to it but it will be a big part of the server redo coming up in the next few weeks. till then, i have it open for the players to roam and explore
  3. Like
    Basti890 reacted to Vipzer in Show Off Your Base   
  4. Like
    Basti890 reacted to BetterDeadThanZed in Show Off Your Base   
    My Takistan base:
     
  5. Like
    Basti890 reacted to TuBz in Show Off Your Base   
    New work in progress.. messy and unfinished...sadly the base on sauerland never got shown as the server change to napf before i got round to videoing it:(.. shame that one was very nice!
     

     
    Lots more to do but you'll get the gist of it!
  6. Like
    Basti890 reacted to Neville Bartos in Show Off Your Base   
    make two of them and i'll join your server just to fly planes into them..... good times
  7. Like
    Basti890 reacted to donelehon in Show Off Your Base   
    5 people building about 30 hours....
    we had a lot of lethal "constructionsite" accidents :)
    built on cpc epoch
     

  8. Like
    Basti890 reacted to vbawol in Show Off Your Base   
    We have created a monster!
  9. Like
    Basti890 reacted to Jaegr in Show Off Your Base   
  10. Like
    Basti890 reacted to Axle in Show Off Your Base   
    My Castle.
     






  11. Like
    Basti890 reacted to Radiix in Show Off Your Base   
  12. Like
    Basti890 reacted to Sharkking in Automatic Restart Scripts Linux?   
    im using BEC with wine and issue a #shutdown when the restart should happen
     
    a simple perl script restarts the server anyhow if its away  therefore no need for complex scripts (if you just want a restart and nothing else)
     
    * * * * * /path/to/perlscript.pl  for cron 
    $a2pid = `/usr/bin/pgrep <ARMASERVERNAME>`; if ($a2pid eq "") { @do = `~/restart_server.sh`; } example restart.sh (in this case a wasteland server)
    #/bin/bash pkill -e arma3server pkill -e Bec.exe pkill -e wine cd ~/ cd battleye echo Starting BEC ... screen -L -h 1024 -dmS bec wine-auto Bec.exe -f Config.cfg --dsc cd .. echo Starting A3 Wasteland Server screen -L -h 1024 -dmS wasteland ./arma3server -mod="@extDB;" -config="wasteland.cfg" -port=2302 -world=empty -profile=Player -noSound -noPause -autoInit sleep 5 echo Services up dirty but working. Only exception is that its actually just working if there is only one instance of the armaserver running
  13. Like
    Basti890 got a reaction from Cam Am in Advanced Alchemical Crafting v3.3   
    @Cam Am
     
    I modiefied the part in the custom_buildings.sqf where the Plotownership ischecked to the algorythm from plotmanagement.
     
    I added this starting around line 166 in custom_building.sqf:
    // check nearby plot's ownership and then for friend status //if plot does not belong to player _nearestPole = _findNearestPole select 0; _ownerID = _nearestPole getVariable["ownerPUID","0"]; if(_playerUID == _ownerID) then { //Keep ownership _canBuildOnPlot = true; } else { _friendlies = _nearestPole getVariable ["plotfriends",[]]; _fuid = []; { _friendUID = _x select 0; _fuid = _fuid + [_friendUID]; } forEach _friendlies; _builder = getPlayerUID player; // check if friendly to owner if(_builder in _fuid) then { _canBuildOnPlot = true; }; };
  14. Like
    Basti890 reacted to Zupa in [RELEASE] Vehicle Godmode in Plotpoles & Safezones & Everywhere Locked 2.0   
    Vehicle Godmode in Plotpoles & Safezones & Everywhere Locked 2.0 Fixed
     
    This scripts adds a configurable file where u can set the following options:
    Vechicles godmode in safezones Vechiles godmode in plotpole areas Locked or all vehicles godmoded  ​Only donaters godmode vehicles in plotpole areas. As soon someone is in them, DESTROY THEM Added later: Locked Vechicles all over the map.  
    Added later: Option to allow damage on vehicles with gear in them even when locked at plotpoles  
     
    In your compiles.sqf ABOVE:
    initialized = true; place
    fnc_usec_damageVehicle =        compile preprocessFileLineNumbers "zupa\fn_damageHandlerVehicle.sqf";        //Event handler run on damage vehicle_handleDamage = compile preprocessFileLineNumbers "zupa\vehicle_handleDamage.sqf"; and make a file in "zupa" folder called "vehicle_handleDamage.sqf" with inside:
     
    FIXED CODE
    private["_selection","_state","_strH","_total","_unit"]; //***Zupa Config ****// _godmodeVechilesEverywhere = false; // Godmode on all locked vehicles _onlyLockedVehicles = true; //Plotarea: Godmode for Only locked vehicles (true) or locked and unlocked(false) _onlyVehicleWithoutGear = true; // Only godmode on vehicles that hold no gear. _safeZoneGodVehicle = true; // Godmode vehicles in safezones. (or specific zone's) // donator plotpole only works with PLOT FOR LIFE, set FALSE if you dont have it. _donatorsPlots = false; // True = only godmode vehicles for donaters in the list, False = godmode for every guy. _plotDonators = ["76561198101253426","505"]; // PUID's of poeple who donated for plotpole // Chernarus safezone area's - change these to other coordinates for other maps. ( You can also add specific locations on the map. _safezones = [ [[5070.75,9729.54],100,"Air"], [[1606.6443,7803.5156],100,"Bandit"], [[4063.4226,11664.19],100,"Bash"], [[12944.227,12766.889],100,"Hero"], [[11447.472,11364.504],100,"Klen"], [[6315.88,7791.3],100,"Stary"] // [[x,y],distance,"just name"] ]; //***END Config ****// _unit = _this select 0; _selection = _this select 1; _total = _this select 2; _state = true; _HPBefore = -1; if (_selection != "") then { _strH = "hit_" + _selection; _HPBefore = [_unit,_strH] call object_getHit; } else { _strH = "totalDmg"; _HPBefore = getDammage _unit; }; if(_total > _HPBefore)then{ if((locked _unit && _godmodeVechilesEverywhere && (count (crew _unit)) < 1))then{_state = false; }; if(_state)then{ if(_safeZoneGodVehicle )then{ {if ((_unit distance (_x select 0)) < (_x select 1)) then {_state = false; };} forEach _safezones; }; }; if(_state)then{ _gearCount = 0; if(_onlyVehicleWithoutGear)then{ //_weaps = count(getWeaponCargo _unit); //_mags = count(getMagazineCargo _unit); //_backs = count(getBackpackCargo _unit); //_gearCount = _gearCount + _weaps + _mags + _backs; }; _plots = nearestObjects [_unit, ["Plastic_Pole_EP1_DZ"], DZE_PlotPole select 0]; if((count(_plots) > 0))then{ _thePlot = _plots select 0; _plotOwner = _thePlot getVariable ["ownerPUID",0]; if ( (_gearCount == 0) &&(locked _unit || !(_onlyLockedVehicles) ) && (count (crew _unit)) < 1 && ( !(_donatorsPlots) || (_plotOwner in _plotDonators))) then {_state = false; }; }; }; }; //fix if(_state)then{ if (_total >= 0.98) then { _total = 1.0; }; if (local _unit) then { if (_total > 0) then { _unit setVariable [_strH, _total, true]; _unit setHit [_selection, _total]; if (isServer) then { [_unit, "damage"] call server_updateObject; } else { PVDZE_veh_Update = [_unit,"damage"]; publicVariableServer "PVDZE_veh_Update"; }; }; } else { // vehicle is not local to this client, ask the client which vehicle is local to set damage /* PVS/PVC - Skaronator */ PVDZE_send = [_unit,"VehHandleDam",_this]; publicVariableServer "PVDZE_send"; }; }else{ _total = _HPBefore; }; // all "HandleDamage event" functions should return the effective damage that the engine will record for that part _total AND in "zupa" folder: fn_damageHandlerVehicle.sqf
    scriptName "Functions\misc\fn_damageHandler.sqf"; /*********************************************************** PROCESS DAMAGE TO A UNIT - Function - [unit, selectionName, damage, source, projectile] call fnc_usec_damageHandler; ************************************************************/ private ["_unit","_hit","_damage","_total"]; _unit = _this select 0; _hit = _this select 1; _damage = _this select 2; //_source = _this select 3; //_ammo = _this select 4; _total = _damage; _state = true; //***Zupa Config ****// _godmodeVechilesEverywhere = false; // Godmode on all locked vehicles _onlyLockedVehicles = true; //Plotarea: Godmode for Only locked vehicles (true) or locked and unlocked(false) _onlyVehicleWithoutGear = true; // Only godmode on vehicles that hold no gear. _safeZoneGodVehicle = true; // Godmode vehicles in safezones. (or specific zone's) // donator plotpole only works with PLOT FOR LIFE, set FALSE if you dont have it. _donatorsPlots = false; // True = only godmode vehicles for donaters in the list, False = godmode for every guy. _plotDonators = ["76561198101253426","505"]; // PUID's of poeple who donated for plotpole // Chernarus safezone area's - change these to other coordinates for other maps. ( You can also add specific locations on the map. _safezones = [ [[5070.75,9729.54],100,"Air"], [[1606.6443,7803.5156],100,"Bandit"], [[4063.4226,11664.19],100,"Bash"], [[12944.227,12766.889],100,"Hero"], [[11447.472,11364.504],100,"Klen"], [[6315.88,7791.3],100,"Stary"] // [[x,y],distance,"just name"] ]; //***END Config ****// systemChat "checks"; if((locked _unit && _godmodeVechilesEverywhere && (count (crew _unit)) < 1))then{_state = false; }; if(_state)then{ if(_safeZoneGodVehicle )then{ {if ((_unit distance (_x select 0)) < (_x select 1)) then {_state = false; };} forEach _safezones; }; }; if(_state)then{ _gearCount = 0; if(_onlyVehicleWithoutGear)then{ //_weaps = count(getWeaponCargo _unit); //_mags = count(getMagazineCargo _unit); //_backs = count(getBackpackCargo _unit); //_gearCount = _gearCount + _weaps + _mags + _backs; }; _plots = nearestObjects [_unit, ["Plastic_Pole_EP1_DZ"], DZE_PlotPole select 0]; if((count(_plots) > 0))then{ _thePlot = _plots select 0; _plotOwner = _thePlot getVariable ["ownerPUID",0]; if ( (_gearCount == 0) &&(locked _unit || !(_onlyLockedVehicles) ) && (count (crew _unit)) < 1 && ( !(_donatorsPlots) || (_plotOwner in _plotDonators))) then {_state = false; }; }; }; //diag_log ("DAMAGE VEH: " + typeof(_unit) + " / " + str(_hit) + " / " + str(_damage) + " / " + str(getDammage _unit)); if (local _unit && _state) then { _total = [_unit,_hit,_damage] call object_setHitServer; }; _total
×
×
  • Create New...