More PVS/PVC Stuff

This commit is contained in:
Skaronator
2014-01-16 14:39:53 +01:00
parent a363400d64
commit 40e4239d42
12 changed files with 100 additions and 29 deletions

View File

@@ -100,9 +100,14 @@ if(_IsNearVehicle >= 1) then {
// calculate new fuel
_newFuelSrc = (_newFuelSrc / _capacitySrc);
if (_newFuelSrc > 0) then {
PVDZE_veh_SFuel = [_vehicleSrc,_newFuelSrc];
PVDZE_veh_SFuel spawn local_setFuel;
publicVariable "PVDZE_veh_SFuel";
/* PVS/PVC - Skaronator */
if (local _vehicle) then {
[_vehicleSrc,_newFuelSrc] call local_setFuel;
} else {
/* PVS/PVC - Skaronator */
PVDZE_send = [_vehicle,"SFuel",[_vehicleSrc,_newFuelSrc]];
publicVariableServer "PVDZE_send";
};
} else {
_isFillok = false;
_abort = true;
@@ -118,10 +123,15 @@ if(_IsNearVehicle >= 1) then {
// calculate minimum needed fuel
_newFuel = (_newFuel / _capacity);
PVDZE_veh_SFuel = [_vehicle,_newFuel];
PVDZE_veh_SFuel spawn local_setFuel;
publicVariable "PVDZE_veh_SFuel";
/* PVS/PVC - Skaronator */
if (local _vehicle) then {
[_vehicle,_newFuel] call local_setFuel;
} else {
/* PVS/PVC - Skaronator */
PVDZE_send = [_vehicle,"SFuel",[_vehicle,_newFuel]];
publicVariableServer "PVDZE_send";
};
// Play sound
[player,"refuel",0,false] call dayz_zombieSpeak;

View File

@@ -76,7 +76,8 @@ if ((_hasKnife or _hasKnifeBlunt) and !_hasHarvested) then {
if (local _item) then {
[_item,_qty] spawn local_gutObject;
} else {
} else {
//Leave this as PV instead of PVS/PVC - Skaronator
PVDZE_plr_GutBody =[_item,_qty];
publicVariable "PVDZE_plr_GutBody";
};

View File

@@ -69,10 +69,14 @@ if ((_hasKnife or _hasKnifeBlunt) and !_hasHarvested) then {
[player,"gut",0,false,10] call dayz_zombieSpeak;
_qty = 1;
PVDZE_plr_GutBody = [_item,_qty];
PVDZE_plr_GutBody spawn local_gutObjectZ;
publicVariable "PVDZE_plr_GutBodyZ";
if (local _item) then {
[_item,_qty] spawn local_gutObjectZ;
} else {
//Leave this as PV instead of PVS/PVC - Skaronator
//Also not sure if we need this
PVDZE_plr_GutBodyZ = [_item,_qty];
publicVariable "PVDZE_plr_GutBodyZ";
};
// Reduce humanity for gutting zeds
_humanity = player getVariable["humanity",0];

View File

@@ -13,9 +13,9 @@ if (!isNull cursorTarget) then {
if (_ent isKindOf "Animal" or _isZombie) then {
_ent setDamage 1;
} else {
//["usecBreakLegs",[_target,player]] call broadcastRpcCallAll;
usecBreakLegs = [_ent,player];
publicVariable "usecBreakLegs";
/* PVS/PVC - Skaronator */
PVDZE_send = [_ent,"PZ_BreakLegs",[_ent,player]];
publicVariableServer "PVDZE_send";
};
[player,"hit",0,false] call dayz_zombieSpeak;

View File

@@ -159,9 +159,15 @@ if (_damage > 0.4) then { //0.25
if(!_isPZombie) then {
//Create Wound
_unit setVariable[_wound,true,true];
[_unit,_wound,_hit] spawn fnc_usec_damageBleed;
usecBleed = [_unit,_wound,_hit];
publicVariable "usecBleed";
/* PVS/PVC - Skaronator */
_pos = getPosATL _unit;
_inRange = _pos nearEntities ["CAManBase",1000];
{
PVDZE_send = [_x,"PlayerBleed",[_unit,_wound,_hit]];
publicVariableServer "PVDZE_send";
} forEach _inRange;
//Set Injured if not already
_isInjured = _unit getVariable["USEC_injured",false];

View File

@@ -66,11 +66,25 @@ if ((!r_player_handler1) and (r_handlerCount == 0)) then {
//Give Blood
r_player_blood = r_player_bloodTotal;
player setVariable["USEC_lowBlood",false,true];
//Self Healing
_id = [player,player] execVM "\z\addons\dayz_code\medical\publicEH\medMorphine.sqf";
player setVariable ["hit_legs",0,false];
player setVariable ["hit_hands",0,false];
player setVariable["medForceUpdate",true];
_id = [player,player] execVM "\z\addons\dayz_code\medical\publicEH\medBandaged.sqf";
player setVariable["medForceUpdate",true];
/* REMOVED USE THAT ABOVE
usecMorphine = [player,player];
publicVariable "usecMorphine";
player setVariable ["USEC_inPain", false, true];
usecBandage = [player,player];
publicVariable "usecBandage";
*/
player setVariable ["USEC_inPain", false, true];
player setdamage 0;
{player setVariable[_x,false,true];} forEach USEC_woundHit;
player setVariable ["USEC_injured",false,true];

View File

@@ -6,8 +6,12 @@ if (!(isNull _backpack) and local _backpack) then {
_weaponscnt = count (_weapons select 0);
_magazinescnt = count (_magazines select 0);
if((_magazinescnt > 0) or (_weaponscnt > 0)) then {
// hide backpack from everyone else
PVDZE_obj_Hide = _backpack;
publicVariable "PVDZE_obj_Hide";
/* PVS/PVC - Skaronator */
_pos = getPosATL player;
_inRange = _pos nearEntities ["CAManBase",300];
{
PVDZE_send = [_x,"HideObj",[_backpack]];
publicVariableServer "PVDZE_send";
} forEach _inRange;
};
};

View File

@@ -60,15 +60,29 @@ if (_ammo isKindOf "SmokeShell") then {
//hint str(_ammo);
_projectile = nearestObject [_unit, "RoadFlare"];
_id = [_projectile,0] spawn object_roadFlare;
PVDZE_obj_RoadFlare = [_projectile,0];
publicVariable "PVDZE_obj_RoadFlare";
/* PVS/PVC - Skaronator */
_pos = getPosATL player;
_inRange = _pos nearEntities ["CAManBase",1250];
{
PVDZE_send = [_x,"RoadFlare",[_projectile,0]];
publicVariableServer "PVDZE_send";
} forEach _inRange;
_id = _this spawn player_throwObject;
};
if (_ammo isKindOf "ChemLight") then {
_projectile = nearestObject [_unit, "ChemLight"];
_id = [_projectile,1] spawn object_roadFlare;
PVDZE_obj_RoadFlare = [_projectile,1];
publicVariable "PVDZE_obj_RoadFlare";
/* PVS/PVC - Skaronator */
_pos = getPosATL player;
_inRange = _pos nearEntities ["CAManBase",1250];
{
PVDZE_send = [_x,"RoadFlare",[_projectile,1]];
publicVariableServer "PVDZE_send";
} forEach _inRange;
_id = _this spawn player_throwObject;
};
};

View File

@@ -56,7 +56,6 @@ if (_finished) then {
//Self Healing
_id = [player,player] execVM "\z\addons\dayz_code\medical\publicEH\medMorphine.sqf";
} else {
//PVDZE_plr_HumanityChange = [player,50];
[player,50] call player_humanityChange;
};

View File

@@ -28,7 +28,6 @@ if(_num_removed == 1) then {
//Self Healing
_id = [player,player] execVM "\z\addons\dayz_code\medical\publicEH\medPainkiller.sqf";
} else {
//PVDZE_plr_HumanityChange = [player,20];
[player,20] call player_humanityChange;
};

View File

@@ -41,6 +41,26 @@ switch (_variable) do {
_owner publicVariableClient "PVDZE_plr_HumanityChange";
};
case "PZ_BreakLegs": {
usecBreakLegs = _arraytosend;
_owner publicVariableClient "usecBreakLegs";
};
case "PZ_BreakLegs": {
usecBleed = _arraytosend;
_owner publicVariableClient "usecBleed";
};
case "HideObj": {
PVDZE_obj_Hide = _arraytosend;
_owner publicVariableClient "PVDZE_obj_Hide";
};
case "RoadFlare": {
PVDZE_obj_RoadFlare = _arraytosend;
_owner publicVariableClient "PVDZE_obj_RoadFlare";
};
case "Transfuse": {
usecTransfuse = _arraytosend;
_owner publicVariableClient "usecTransfuse";

View File

@@ -1,5 +1,5 @@
5 !="remExField" !="remExFP" !="PVDZE_plr_TradeMenu" !="PVDZE_veh_SFuel" !="PVDZE_veh_Update" !="PVDZE_plr_GutBody" !="PVDZE_plr_GutBodyZ" !="PVDZE_veh_Lock" !="PVDZE_plr_DeathB" !="PVDZE_obj_Publish" !="PVDZE_obj_Swap" !="PVDZE_plr_Save" !="PVDZE_plr_FriendRQ" !="usecBreakLegs" !="PVDZE_obj_Delete" !="PVDZE_veh_SFix" !="PVDZE_obj_Trade" !="PVDZE_veh_Publish2" !="PVDZE_plr_DiscAdd" !="PVDZE_plr_HumanityChange" !="PVDZE_send" !="usecBleed" !="usecMorphine" !="usecBandage" !="PVDZE_plr_HideBody" !="PVDZE_plr_Died" !="PVDZE_obj_Hide" !="PVDZE_obj_RoadFlare" !="PVDZE_zed_Spawn" !="drn_DynamicWeather_DebugTextEventArgs" !="drn_AskServerDynamicWeatherEventArgs" !="drn_DynamicWeatherEventArgs" !="drn_var_DynamicWeather_Rain" !="drn_var_DynamicWeather_ServerInitialized" !="norrnRACarUp" !="norrnRAPicUp" !="norrnRaDrag" !="norrnR180" !="norrnRalie" !="usecEpi" !="norrnRLact" !="norrnRALW" !="norrinRAlie" !="usecPainK" !="usecTransfuse" !="atp" !="PVDZE_plr_Login" !="PVDZE_plr_Login2" !="PVDZE_plr_LoginRecord" !="PVDZE_plr_DiscRem" !="BIS_effects_gepv" !="PVDZE_plr_DeathBResult" !="customRemoteMessage" !="dayzPlayerLogin" !="PVDZE_veh_Init" !="PVDZE_obj_Fire" !="dayzTradeResult" !="PVDZE_plr_TradeMenuResult" !="PVDZE_plr_SetDate" !="sm_done" !="PVDZE_plr_Morph2" !="PVDZE_plr_Morph" !="norrnRnoAnim" !="norrnRDead" !="usecInject" !="PVDZE_plr_Hit" !="PVDZE_plr_HitV" !="PVDZE_plr_DelLocal" !="PVDZE_serverObjectMonitor" !="PVDZE_veh_Upgrade" !="maintainArea_log" !"player" !"PVAHR_" !="PVAH_AdminRequest" !="PVAH_WriteLogRequest"
5 PVAHR_ !PVAHR_0 !PVAHR_1 !PVAHR_2 !PVAHR_3 !PVAHR_4 !PVAHR_5 !PVAHR_6 !PVAHR_7 !PVAHR_8 !PVAHR_9
5 !="remExField" !="remExFP" !="PVDZE_plr_TradeMenu" !="PVDZE_veh_Update" !="PVDZE_veh_Lock" !="PVDZE_plr_DeathB" !="PVDZE_obj_Publish" !="PVDZE_obj_Swap" !="PVDZE_plr_Save" !="PVDZE_obj_Delete" !="PVDZE_veh_SFix" !="PVDZE_obj_Trade" !="PVDZE_veh_Publish2" !="PVDZE_send" !="usecBleed" !="PVDZE_plr_Died" !="PVDZE_zed_Spawn" !="drn_DynamicWeather_DebugTextEventArgs" !="drn_AskServerDynamicWeatherEventArgs" !="drn_DynamicWeatherEventArgs" !="drn_var_DynamicWeather_Rain" !="drn_var_DynamicWeather_ServerInitialized" !="norrnRACarUp" !="norrnRAPicUp" !="norrnRaDrag" !="norrnR180" !="norrnRalie" !="norrnRLact" !="norrnRALW" !="norrinRAlie" !="atp" !="PVDZE_plr_Login" !="PVDZE_plr_Login2" !="PVDZE_plr_LoginRecord" !="PVDZE_plr_DiscRem" !="BIS_effects_gepv" !="PVDZE_plr_DeathBResult" !="customRemoteMessage" !="dayzPlayerLogin" !="PVDZE_veh_Init" !="dayzTradeResult" !="PVDZE_plr_TradeMenuResult" !="PVDZE_plr_SetDate" !="PVDZE_plr_Morph2" !="PVDZE_plr_Morph" !="norrnRnoAnim" !="norrnRDead" !="PVDZE_plr_Hit" !="PVDZE_plr_HitV" !="PVDZE_plr_DelLocal" !="PVDZE_veh_Upgrade" !"player" !"PVAHR_" !="PVAH_AdminRequest" !="PVAH_WriteLogRequest"
5 PVAHR_ //!PVAHR_0 !PVAHR_1 !PVAHR_2 !PVAHR_3 !PVAHR_4 !PVAHR_5 !PVAHR_6 !PVAHR_7 !PVAHR_8 !PVAHR_9
5 "HangenderRE"
5 "vilegaming"
5 "v.i.l.e"