Make UI toggleable between three options

Admin can choose vanilla, classic epoch or classic epoch dark.

dayz_hungerThirst was replaced with dayz_NutritionSystem
This commit is contained in:
ebaydayz
2016-03-29 19:54:19 -04:00
parent 71b975b05e
commit 91f9b3e33b
122 changed files with 977 additions and 1165 deletions

View File

@@ -1,5 +1,10 @@
[NEW] Fully updated to DayZ 1.8.7 code base @icomrade @ebaydayz
Some notable changes include (not a full list):
- Blood types system is disabled by default. Set DZE_UseBloodTypes = true; in init.sqf to enable
- Bandit heartbeat sound is disabled by default. Set DZE_HeartBeat = true; in init.sqf to enable
- Knife dulling is disabled by default. Set dayz_knifeDulling = true; in init.sqf to enable
- Water bottle breaking is disabled by default. Set dayz_waterBottleBreaking = true; in init.sqf to enable
- New loot table format is incompatible with old loot tables. See CfgLoot\README
- Mission.sqm and description.ext now use compact format
- Keyboard eventhandler updated, dayz_spaceInterupt is no longer used
@@ -7,7 +12,9 @@
- Weapon switch hotkeys added (1 = primary, 2 = pistol, 3 = melee)
- Journal is now functional for displaying stats
- ItemFish, Shotgun ammo and several other item classnames changed. See SQL\1.0.6_Updates
- Status UI icons are toggleable between "vanilla","epoch","dark" set i.e. DZE_UI = "epoch"; in init.sqf
- Dupicate functions have been renamed:
- dayz_HungerThirst --> dayz_NutritionSystem
- dayz_objectUID3 --> dayz_objectUID2
- object_handleServerKilled --> vehicle_handleServerKilled
- object_setFixServer --> fnc_veh_setFixServer
@@ -52,12 +59,11 @@
- usecMorphine --> PVCDZ_hlt_Morphine
- usecPainK --> PVCDZ_hlt_PainK
- usecTransfuse --> PVCDZ_hlt_Transfuse
[NEW] RedRyder BB Gun by @arma2WillRobinson
[NEW] Added "RedRyder" and "350Rnd_BB_Magazine" to loot pile. #1456 #1457 @Namindu
[NEW] DB Backup script. @RimBlock
[NEW] Use DayZ_UseSteamID = false; in your init.sqf to use the old PlayerUID, instead of SteamID @icomrade
[NEW] UI Update - Graphical and code changes, enable using Dayz_Dark_UI = true; in init.sqf. @hogscraper http://epochmod.com/forum/index.php?/topic/13654-proposed-ui-change/
[NEW] UI Update - Graphical and code changes, enable using DZE_UI = "dark"; in init.sqf. @hogscraper http://epochmod.com/forum/index.php?/topic/13654-proposed-ui-change/
[NOTE] It's recommend to convert to the new SteamID system if possible, new servers should not use DayZ_UseSteamID = false;
[NEW] Snap building (disabled by default), use DZE_modularBuild = true; in your init.sqf to enable. @raymix
[NEW] Auto login when a player joins the server, default 10 seconds, requires description.ext update in the mission (disable in description.ext by setting defValueParam1 = 31;) @icomrade

View File

@@ -1,319 +0,0 @@
class RscTitles
{
titles[] = {"DeathScreen","TitleScreen","RscTitleStructuredText"};
class DeathScreen
{
idd = -1;
movingEnable = "false";
duration = 120;
fadein = 0;
name = "DeathScreen";
controls[] = {"DeathScreen"};
class DeathScreen: RscPicture
{
x = "0.00001 * safezoneW + safezoneX";
y = "0.00001 * safezoneH + safezoneY";
w = "1 * safezoneW";
h = "1 * safezoneH";
text = "\z\addons\dayz_epoch\ui\screen_death_ca.paa";
};
};
class TitleScreen
{
idd = -1;
movingEnable = "false";
duration = 120;
fadein = 0;
name = "TitleScreen";
controls[] = {"TitleScreen"};
class TitleScreen: RscPicture
{
x = "0.00001 * safezoneW + safezoneX";
y = "0.00001 * safezoneH + safezoneY";
w = "1 * safezoneW";
h = "1 * safezoneH";
text = "\dayz\ui\screen_title_ca.paa";
};
};
class Default
{
idd = -1;
movingEnable = 0;
duration = 4;
};
class playerKillScore {
idd = 6902;
movingEnable = 0;
duration = 5;
name = "playerKillScore";
onLoad = "uiNamespace setVariable ['DAYZ_GUI_kills', _this select 0];";
class ControlsBackground {
class RscPicture_1201: RscPictureGUI
{
idc = 1400;
text = "\z\addons\dayz_code\gui\stats_kills_human_ca.paa";
x = 0.044687 * safezoneW + safezoneX;
y = 0.934779 * safezoneH + safezoneY;
w = 0.06;
h = 0.08;
};
class RscPicture_1200: RscPictureGUI
{
idc = 1401;
text = "\z\addons\dayz_code\gui\stats_kills_zombie_ca.paa";
x = 0.044687 * safezoneW + safezoneX;
y = 0.876025 * safezoneH + safezoneY;
w = 0.06;
h = 0.08;
};
};
class Controls{
class RscText1: RscStructuredTextGUI
{
idc = 1410;
text = "10";
x = (0.044687 * safezoneW + safezoneX) - 0.01;
y = 0.934779 * safezoneH + safezoneY;
w = 0.08;
h = 0.08;
};
class RscText2: RscStructuredTextGUI
{
idc = 1411;
text = "1000";
x = (0.044687 * safezoneW + safezoneX) - 0.01;
y = 0.876025 * safezoneH + safezoneY;
w = 0.08;
h = 0.08;
};
};
};
class playerStatusWaiting {
idd = 6901;
movingEnable = 0;
duration = 100000;
name = "playerStatusWaiting";
onLoad = "uiNamespace setVariable ['DAYZ_GUI_waiting', _this select 0];";
class ControlsBackground {
class RscText_1402: RscPictureGUI
{
idc = 1402;
text = "#(argb,8,8,3)color(1,1,1,1)";
x = 0.473572 * safezoneW + safezoneX;
y = 0.418158 * safezoneH + safezoneY;
w = 0.0634286 * safezoneW;
h = 0.136829 * safezoneH;
colorText[] = {1,1,1,1};
};
class RscText_1400: RscPictureGUI
{
idc = 1400;
text = "#(argb,8,8,3)color(1,1,1,1)";
x = 0.473572 * safezoneW + safezoneX;
y = 0.418158 * safezoneH + safezoneY;
w = 0.0634286 * safezoneW;
h = 0; //0.136829 * safezoneH;
colorText[] = {0,0,0,1};
};
};
class Controls {
class RscPicture_1401: RscPictureGUI
{
idc = 1401;
text = "\z\addons\dayz_code\gui\status_waiting_ca.paa";
x = 0.434999 * safezoneW + safezoneX;
y = 0.392207 * safezoneH + safezoneY;
w = 0.141 * safezoneW;
h = 0.188013 * safezoneH;
colorText[] = {0.38,0.63,0.26,1};
};
};
};
class playerStatusGUI {
idd = 6900;
movingEnable = 0;
duration = 100000;
name = "statusBorder";
onLoad = "uiNamespace setVariable ['DAYZ_GUI_display', _this select 0];";
class ControlsBackground {
class RscPicture_1901: RscPictureGUI
{
idc = 1901;
//text = "\z\addons\dayz_code\gui\status\status_bg.paa";
x = 0.955313 * safezoneW + safezoneX;
y = 0.86 * safezoneH + safezoneY;//2
w = 0.075;
h = 0.10;
};
class RscPicture_1201: RscPictureGUI
{
idc = 1201;
//text = "\z\addons\dayz_code\gui\status\status_food_border_ca.paa";
x = 0.955313 * safezoneW + safezoneX;
y = 0.86 * safezoneH + safezoneY;//2
w = 0.075;
h = 0.10;
};
class RscPicture_1900: RscPictureGUI
{
idc = 1900;
//text = "\z\addons\dayz_code\gui\status\status_bg.paa";
x = 0.955313 * safezoneW + safezoneX;
y = 0.79 * safezoneH + safezoneY; //3
w = 0.075;
h = 0.10;
};
class RscPicture_1200: RscPictureGUI
{
idc = 1200;
//text = "\z\addons\dayz_code\gui\status\status_blood_border_ca.paa";
x = 0.955313 * safezoneW + safezoneX;
y = 0.79 * safezoneH + safezoneY; //3
w = 0.075;
h = 0.10;
};
class RscPicture_1902: RscPictureGUI
{
idc = 1902;
//text = "\z\addons\dayz_code\gui\status\status_bg.paa";
x = 0.955313 * safezoneW + safezoneX;
y = 0.93 * safezoneH + safezoneY; //1
w = 0.075;
h = 0.10;
};
class RscPicture_1202: RscPictureGUI
{
idc = 1202;
//text = "\z\addons\dayz_code\gui\status\status_thirst_border_ca.paa";
x = 0.955313 * safezoneW + safezoneX;
y = 0.93 * safezoneH + safezoneY; //1
w = 0.075;
h = 0.10;
};
class RscPicture_1908: RscPictureGUI
{
idc = 1908;
//text = "\z\addons\dayz_code\gui\status\status_bg.paa";
x = 0.955313 * safezoneW + safezoneX;
y = 0.72 * safezoneH + safezoneY; //3
w = 0.075;
h = 0.10;
};
class RscPicture_1208: RscPictureGUI
{
idc = 1208;
//text = "\z\addons\dayz_code\gui\status\status_temp_outside_ca.paa";
x = 0.955313 * safezoneW + safezoneX;
y = 0.72 * safezoneH + safezoneY; //3
w = 0.075;
h = 0.10;
};
class RscPicture_1203: RscPictureGUI
{
idc = 1203;
text = "\z\addons\dayz_code\gui\status\status_effect_brokenleg.paa";
x = 0.955313 * safezoneW + safezoneX;
y = 0.58 * safezoneH + safezoneY;
w = 0.075;
h = 0.10;
colorText[] = {1,1,1,1};
};
class RscPicture_1204: RscPictureGUI
{
idc = 1204;
text = "\z\addons\dayz_code\gui\status\status_connection_ca.paa";
x = 0.955313 * safezoneW + safezoneX;
y = 0.51 * safezoneH + safezoneY;
w = 0.075;
h = 0.10;
colorText[] = {1,1,1,1};
};
class RscPicture_1205: RscPictureGUI
{
idc = 1205;
//text = "\z\addons\dayz_code\gui\status\status_bg.paa";
x = 0.955313 * safezoneW + safezoneX;
y = 0.30 * safezoneH + safezoneY;
w = 0.075;
h = 0.10;
};
class RscPicture_1206: RscPictureGUI
{
idc = 1206;
//text = "\z\addons\dayz_code\gui\status\status_bg.paa";
x = 0.955313 * safezoneW + safezoneX;
y = 0.37 * safezoneH + safezoneY;
w = 0.075;
h = 0.10;
};
};
class Controls {
class RscPicture_1301: RscPictureGUI
{
idc = 1301;
//text = "\z\addons\dayz_code\gui\status\status_food_inside_ca.paa";
x = 0.955313 * safezoneW + safezoneX;
y = 0.86 * safezoneH + safezoneY;
w = 0.075;
h = 0.10;
};
class RscPicture_1300: RscPictureGUI
{
idc = 1300;
//text = "\z\addons\dayz_code\gui\status\status_blood_inside_ca.paa";
x = 0.955313 * safezoneW + safezoneX;
y = 0.79 * safezoneH + safezoneY;
w = 0.075;
h = 0.10;
};
class RscPicture_1302: RscPictureGUI
{
idc = 1302;
//text = "\z\addons\dayz_code\gui\status\status_thirst_inside_ca.paa";
x = 0.955313 * safezoneW + safezoneX;
y = 0.93 * safezoneH + safezoneY;
w = 0.075;
h = 0.10;
};
class RscPicture_1306: RscPictureGUI
{
idc = 1306;
//text = "\z\addons\dayz_code\gui\status\status_temp_ca.paa";
x = 0.955313 * safezoneW + safezoneX;
y = 0.72 * safezoneH + safezoneY;
w = 0.075;
h = 0.10;
};
class RscPicture_1303: RscPictureGUI
{
idc = 1303;
text = "\z\addons\dayz_code\gui\status\status_bleeding_ca.paa";
x = 0.955313 * safezoneW + safezoneX;
y = 0.79 * safezoneH + safezoneY;
w = 0.075;
h = 0.10;
colorText[] = {1,1,1,0.5};
};
class RscPicture_1304: RscPictureGUI
{
idc = 1304;
text = "\z\addons\dayz_code\gui\status\status_noise.paa";
x = 0.955313 * safezoneW + safezoneX;
y = 0.30 * safezoneH + safezoneY;
w = 0.075;
h = 0.10;
};
class RscPicture_1305: RscPictureGUI
{
idc = 1305;
text = "\z\addons\dayz_code\gui\status\status_visible.paa";
x = 0.955313 * safezoneW + safezoneX;
y = 0.37 * safezoneH + safezoneY;
w = 0.075;
h = 0.10;
};
};
};
};

View File

@@ -1,287 +0,0 @@
class RscTitles
{
titles[] = {"DeathScreen","TitleScreen","RscTitleStructuredText"};
class DeathScreen
{
idd = -1;
movingEnable = "false";
duration = 120;
fadein = 0;
name = "DeathScreen";
controls[] = {"DeathScreen"};
class DeathScreen: RscPicture
{
x = "0.00001 * safezoneW + safezoneX";
y = "0.00001 * safezoneH + safezoneY";
w = "1 * safezoneW";
h = "1 * safezoneH";
text = "\z\addons\dayz_epoch\ui\screen_death_ca.paa";
};
};
class TitleScreen
{
idd = -1;
movingEnable = "false";
duration = 120;
fadein = 0;
name = "TitleScreen";
controls[] = {"TitleScreen"};
class TitleScreen: RscPicture
{
x = "0.00001 * safezoneW + safezoneX";
y = "0.00001 * safezoneH + safezoneY";
w = "1 * safezoneW";
h = "1 * safezoneH";
text = "\dayz\ui\screen_title_ca.paa";
};
};
class Default
{
idd = -1;
movingEnable = 0;
duration = 4;
};
class playerKillScore
{
idd = 6902;
movingEnable = 0;
duration = 5;
name = "playerKillScore";
onLoad = "uiNamespace setVariable ['DAYZ_GUI_kills', _this select 0];";
class ControlsBackground {
class RscPicture_1201: RscPictureGUI
{
idc = 1400;
text = "\z\addons\dayz_code\gui\stats_kills_human_ca.paa";
x = 0.044687 * safezoneW + safezoneX;
y = 0.934779 * safezoneH + safezoneY;
w = 0.06;
h = 0.08;
};
class RscPicture_1200: RscPictureGUI
{
idc = 1401;
text = "\z\addons\dayz_code\gui\stats_kills_zombie_ca.paa";
x = 0.044687 * safezoneW + safezoneX;
y = 0.876025 * safezoneH + safezoneY;
w = 0.06;
h = 0.08;
};
};
class Controls{
class RscText1: RscStructuredTextGUI
{
idc = 1410;
text = "10";
x = (0.044687 * safezoneW + safezoneX) - 0.01;
y = 0.934779 * safezoneH + safezoneY;
w = 0.08;
h = 0.08;
};
class RscText2: RscStructuredTextGUI
{
idc = 1411;
text = "1000";
x = (0.044687 * safezoneW + safezoneX) - 0.01;
y = 0.876025 * safezoneH + safezoneY;
w = 0.08;
h = 0.08;
};
};
};
class playerStatusWaiting
{
idd = 6901;
movingEnable = 0;
duration = 100000;
name = "playerStatusWaiting";
onLoad = "uiNamespace setVariable ['DAYZ_GUI_waiting', _this select 0];";
class ControlsBackground {
class RscText_1402: RscPictureGUI
{
idc = 1402;
text = "#(argb,8,8,3)color(1,1,1,1)";
x = 0.473572 * safezoneW + safezoneX;
y = 0.418158 * safezoneH + safezoneY;
w = 0.0634286 * safezoneW;
h = 0.136829 * safezoneH;
colorText[] = {1,1,1,1};
};
class RscText_1400: RscPictureGUI
{
idc = 1400;
text = "#(argb,8,8,3)color(1,1,1,1)";
x = 0.473572 * safezoneW + safezoneX;
y = 0.418158 * safezoneH + safezoneY;
w = 0.0634286 * safezoneW;
h = 0; //0.136829 * safezoneH;
colorText[] = {0,0,0,1};
};
};
class Controls {
class RscPicture_1401: RscPictureGUI
{
idc = 1401;
text = "\z\addons\dayz_code\gui\status_waiting_ca.paa";
x = 0.434999 * safezoneW + safezoneX;
y = 0.392207 * safezoneH + safezoneY;
w = 0.141 * safezoneW;
h = 0.188013 * safezoneH;
colorText[] = {0.38,0.63,0.26,1};
};
};
};
class playerStatusGUI
{
idd = 6900;
movingEnable = 0;
duration = 100000;
name = "statusBorder";
onLoad = "uiNamespace setVariable ['DAYZ_GUI_display', _this select 0];";
class ControlsBackground {
class RscStructuredText_1199: RscStructuredText
{
idc = 1199;
x = 0.250001;
y = 0.350001;
w = 0.5;
h = 0.1;
};
class RscPicture_1203: RscPictureGUI
{
idc = 1203;
text = "\z\addons\dayz_code\gui\status_fracture_ca.paa";
x = 0.955313 * safezoneW + safezoneX;
y = 0.58 * safezoneH + safezoneY;
w = 0.06;
h = 0.08;
colorText[] = {1,1,1,1};
};
class RscPicture_1204: RscPictureGUI
{
idc = 1204;
text = "\z\addons\dayz_code\gui\status_connection_ca.paa";
x = 0.955313 * safezoneW + safezoneX;
y = 0.51 * safezoneH + safezoneY;
w = 0.06;
h = 0.08;
colorText[] = {1,1,1,1};
};
class RscPicture_1205: RscPictureGUI
{
idc = 1205;
text = "\z\addons\dayz_code\gui\status_ear_ca.paa";
x = 0.955313 * safezoneW + safezoneX;
y = 0.30 * safezoneH + safezoneY;
w = 0.06;
h = 0.08;
};
class RscPicture_1206: RscPictureGUI
{
idc = 1206;
text = "\z\addons\dayz_code\gui\status_eye_ca.paa";
x = 0.955313 * safezoneW + safezoneX;
y = 0.37 * safezoneH + safezoneY;
w = 0.06;
h = 0.08;
};
};
class Controls{
class RscPicture_1301: RscPictureGUI
{
idc = 1301;
//text = "\z\addons\dayz_code\gui\status_food_inside_ca.paa";
x = 0.955313 * safezoneW + safezoneX;
y = 0.93 * safezoneH + safezoneY;
w = 0.06;
h = 0.08;
};
class RscPicture_1300: RscPictureGUI
{
idc = 1300;
//text = "\z\addons\dayz_code\gui\status_blood_inside_ca.paa";
x = 0.955313 * safezoneW + safezoneX;
y = 0.86 * safezoneH + safezoneY;
w = 0.06;
h = 0.08;
};
class RscPicture_1302: RscPictureGUI
{
idc = 1302;
//text = "\z\addons\dayz_code\gui\status_thirst_inside_ca.paa";
x = 0.955313 * safezoneW + safezoneX;
y = 0.79 * safezoneH + safezoneY;
w = 0.06;
h = 0.08;
};
class RscPicture_1306: RscPictureGUI
{
idc = 1306;
//text = "\z\addons\dayz_code\gui\status_temp_ca.paa";
x = 0.955313 * safezoneW + safezoneX;
y = 0.72 * safezoneH + safezoneY;
w = 0.06;
h = 0.08;
};
class RscPicture_1303: RscPictureGUI
{
idc = 1303;
text = "\z\addons\dayz_code\gui\status_bleeding_ca.paa";
x = 0.955313 * safezoneW + safezoneX;
y = 0.86 * safezoneH + safezoneY;
w = 0.06;
h = 0.08;
colorText[] = {1,1,1,0.5};
};
class RscPicture_1304: RscPictureGUI
{
idc = 1304;
text = "";
x = 0.935313 * safezoneW + safezoneX;
y = 0.3 * safezoneH + safezoneY;
w = 0.06;
h = 0.08;
};
class RscPicture_1305: RscPictureGUI
{
idc = 1305;
text = "";
x = 0.935313 * safezoneW + safezoneX;
y = 0.37 * safezoneH + safezoneY;
w = 0.06;
h = 0.08;
};
class RscPicture_1307 : RscPictureGUI {
idc = 1307;
text = "\z\addons\dayz_code\gui\status_combat_inside_ca.paa";
x = "0.955313 * safezoneW + safezoneX";
y = "0.65 * safezoneH + safezoneY";
w = 0.06;
h = 0.08;
};
class RscPicture_1701: RscPictureGUI
{
idc = 1701;
//text = "\z\addons\dayz_code\gui\status_food_inside_ca.paa";
x = 0.945313 * safezoneW + safezoneX;
y = 0.95 * safezoneH + safezoneY;
w = 0.04;
h = 0.053333;
};
class RscPicture_1702: RscPictureGUI
{
idc = 1702;
//text = "\z\addons\dayz_code\gui\status_thirst_inside_ca.paa";
x = 0.945313 * safezoneW + safezoneX;
y = 0.816666 * safezoneH + safezoneY;
w = 0.04;
h = 0.053333;
};
};
};
};

View File

@@ -119,35 +119,19 @@ class RscTitles
name = "statusBorder";
onLoad = "uiNamespace setVariable ['DAYZ_GUI_display', _this select 0];";
class ControlsBackground {
class RscStructuredText_1199: RscStructuredText
{
idc = 1199;
x = 0.250001;
y = 0.350001;
w = 0.5;
h = 0.1;
};
class RscPicture_1901: RscPictureGUI
{
idc = 1901;
//text = "\z\addons\dayz_code\gui\status\status_bg.paa";
text = "\z\addons\dayz_code\gui\status\status_bg.paa";
x = 0.955313 * safezoneW + safezoneX;
y = 0.86 * safezoneH + safezoneY;//2
w = 0.075;
h = 0.10;
};
class RscPicture_1307 : RscPictureGUI {
idc = 1307;
text = "\z\addons\dayz_code\gui\status_combat_inside_ca.paa";
x = "0.955313 * safezoneW + safezoneX";
y = "0.65 * safezoneH + safezoneY";
w = 0.06;
h = 0.08;
};
class RscPicture_1201: RscPictureGUI
{
idc = 1201;
//text = "\z\addons\dayz_code\gui\status\status_food_border_ca.paa";
text = "\z\addons\dayz_code\gui\status\status_food_border_ca.paa";
x = 0.955313 * safezoneW + safezoneX;
y = 0.86 * safezoneH + safezoneY;//2
w = 0.075;
@@ -156,7 +140,7 @@ class RscTitles
class RscPicture_1900: RscPictureGUI
{
idc = 1900;
//text = "\z\addons\dayz_code\gui\status\status_bg.paa";
text = "\z\addons\dayz_code\gui\status\status_bg.paa";
x = 0.955313 * safezoneW + safezoneX;
y = 0.79 * safezoneH + safezoneY; //3
w = 0.075;
@@ -174,7 +158,7 @@ class RscTitles
class RscPicture_1902: RscPictureGUI
{
idc = 1902;
//text = "\z\addons\dayz_code\gui\status\status_bg.paa";
text = "\z\addons\dayz_code\gui\status\status_bg.paa";
x = 0.955313 * safezoneW + safezoneX;
y = 0.93 * safezoneH + safezoneY; //1
w = 0.075;
@@ -183,7 +167,7 @@ class RscTitles
class RscPicture_1202: RscPictureGUI
{
idc = 1202;
//text = "\z\addons\dayz_code\gui\status\status_thirst_border_ca.paa";
text = "\z\addons\dayz_code\gui\status\status_thirst_border_ca.paa";
x = 0.955313 * safezoneW + safezoneX;
y = 0.93 * safezoneH + safezoneY; //1
w = 0.075;
@@ -192,7 +176,7 @@ class RscTitles
class RscPicture_1908: RscPictureGUI
{
idc = 1908;
//text = "\z\addons\dayz_code\gui\status\status_bg.paa";
text = "\z\addons\dayz_code\gui\status\status_bg.paa";
x = 0.955313 * safezoneW + safezoneX;
y = 0.72 * safezoneH + safezoneY; //3
w = 0.075;
@@ -201,7 +185,7 @@ class RscTitles
class RscPicture_1208: RscPictureGUI
{
idc = 1208;
//text = "\z\addons\dayz_code\gui\status\status_temp_outside_ca.paa";
text = "\z\addons\dayz_code\gui\status\status_temp_outside_ca.paa";
x = 0.955313 * safezoneW + safezoneX;
y = 0.72 * safezoneH + safezoneY; //3
w = 0.075;
@@ -230,7 +214,7 @@ class RscTitles
class RscPicture_1205: RscPictureGUI
{
idc = 1205;
//text = "\z\addons\dayz_code\gui\status\status_bg.paa";
text = "\z\addons\dayz_code\gui\status\status_bg.paa";
x = 0.955313 * safezoneW + safezoneX;
y = 0.30 * safezoneH + safezoneY;
w = 0.075;
@@ -239,7 +223,7 @@ class RscTitles
class RscPicture_1206: RscPictureGUI
{
idc = 1206;
//text = "\z\addons\dayz_code\gui\status\status_bg.paa";
text = "\z\addons\dayz_code\gui\status\status_bg.paa";
x = 0.955313 * safezoneW + safezoneX;
y = 0.37 * safezoneH + safezoneY;
w = 0.075;
@@ -322,4 +306,206 @@ class RscTitles
};
};
};
class playerStatusGUI_epoch {
idd = 690000;
movingEnable = 0;
duration = 100000;
name = "statusBorder";
onLoad = "uiNamespace setVariable ['DAYZ_GUI_display', _this select 0];";
class ControlsBackground {
class RscStructuredText_1199: RscStructuredText
{
idc = 1199;
x = 0.250001;
y = 0.350001;
w = 0.5;
h = 0.1;
};
class RscPicture_1901: RscPictureGUI
{
idc = 1901;
//text = "\z\addons\dayz_code\gui\status_epoch\status_bg.paa";
x = 0.955313 * safezoneW + safezoneX;
y = 0.86 * safezoneH + safezoneY;//2
w = 0.075;
h = 0.10;
};
class RscPicture_1307 : RscPictureGUI {
idc = 1307;
text = "\z\addons\dayz_code\gui\status_epoch\status_combat_inside_ca.paa";
x = "0.955313 * safezoneW + safezoneX";
y = "0.65 * safezoneH + safezoneY";
w = 0.06;
h = 0.08;
};
class RscPicture_1201: RscPictureGUI
{
idc = 1201;
//text = "\z\addons\dayz_code\gui\status_epoch\status_food_border_ca.paa";
x = 0.955313 * safezoneW + safezoneX;
y = 0.86 * safezoneH + safezoneY;//2
w = 0.075;
h = 0.10;
};
class RscPicture_1900: RscPictureGUI
{
idc = 1900;
//text = "\z\addons\dayz_code\gui\status_epoch\status_bg.paa";
x = 0.955313 * safezoneW + safezoneX;
y = 0.79 * safezoneH + safezoneY; //3
w = 0.075;
h = 0.10;
};
class RscPicture_1200: RscPictureGUI
{
idc = 1200;
//text = "\z\addons\dayz_code\gui\status_epoch\status_blood_border_ca.paa";
x = 0.955313 * safezoneW + safezoneX;
y = 0.79 * safezoneH + safezoneY; //3
w = 0.075;
h = 0.10;
};
class RscPicture_1902: RscPictureGUI
{
idc = 1902;
//text = "\z\addons\dayz_code\gui\status_epoch\status_bg.paa";
x = 0.955313 * safezoneW + safezoneX;
y = 0.93 * safezoneH + safezoneY; //1
w = 0.075;
h = 0.10;
};
class RscPicture_1202: RscPictureGUI
{
idc = 1202;
//text = "\z\addons\dayz_code\gui\status_epoch\status_thirst_border_ca.paa";
x = 0.955313 * safezoneW + safezoneX;
y = 0.93 * safezoneH + safezoneY; //1
w = 0.075;
h = 0.10;
};
class RscPicture_1908: RscPictureGUI
{
idc = 1908;
//text = "\z\addons\dayz_code\gui\status_epoch\status_bg.paa";
x = 0.955313 * safezoneW + safezoneX;
y = 0.72 * safezoneH + safezoneY; //3
w = 0.075;
h = 0.10;
};
class RscPicture_1208: RscPictureGUI
{
idc = 1208;
//text = "\z\addons\dayz_code\gui\status_epoch\status_temp_outside_ca.paa";
x = 0.955313 * safezoneW + safezoneX;
y = 0.72 * safezoneH + safezoneY; //3
w = 0.075;
h = 0.10;
};
class RscPicture_1203: RscPictureGUI
{
idc = 1203;
text = "\z\addons\dayz_code\gui\status_epoch\status_effect_brokenleg.paa";
x = 0.955313 * safezoneW + safezoneX;
y = 0.58 * safezoneH + safezoneY;
w = 0.075;
h = 0.10;
colorText[] = {1,1,1,1};
};
class RscPicture_1204: RscPictureGUI
{
idc = 1204;
text = "\z\addons\dayz_code\gui\status_epoch\status_connection_ca.paa";
x = 0.955313 * safezoneW + safezoneX;
y = 0.51 * safezoneH + safezoneY;
w = 0.075;
h = 0.10;
colorText[] = {1,1,1,1};
};
class RscPicture_1205: RscPictureGUI
{
idc = 1205;
//text = "\z\addons\dayz_code\gui\status_epoch\status_bg.paa";
x = 0.955313 * safezoneW + safezoneX;
y = 0.30 * safezoneH + safezoneY;
w = 0.075;
h = 0.10;
};
class RscPicture_1206: RscPictureGUI
{
idc = 1206;
//text = "\z\addons\dayz_code\gui\status_epoch\status_bg.paa";
x = 0.955313 * safezoneW + safezoneX;
y = 0.37 * safezoneH + safezoneY;
w = 0.075;
h = 0.10;
};
};
class Controls {
class RscPicture_1301: RscPictureGUI
{
idc = 1301;
//text = "\z\addons\dayz_code\gui\status_epoch\status_food_inside_ca.paa";
x = 0.955313 * safezoneW + safezoneX;
y = 0.86 * safezoneH + safezoneY;
w = 0.075;
h = 0.10;
};
class RscPicture_1300: RscPictureGUI
{
idc = 1300;
//text = "\z\addons\dayz_code\gui\status_epoch\status_blood_inside_ca.paa";
x = 0.955313 * safezoneW + safezoneX;
y = 0.79 * safezoneH + safezoneY;
w = 0.075;
h = 0.10;
};
class RscPicture_1302: RscPictureGUI
{
idc = 1302;
//text = "\z\addons\dayz_code\gui\status_epoch\status_thirst_inside_ca.paa";
x = 0.955313 * safezoneW + safezoneX;
y = 0.93 * safezoneH + safezoneY;
w = 0.075;
h = 0.10;
};
class RscPicture_1306: RscPictureGUI
{
idc = 1306;
//text = "\z\addons\dayz_code\gui\status_epoch\status_temp_ca.paa";
x = 0.955313 * safezoneW + safezoneX;
y = 0.72 * safezoneH + safezoneY;
w = 0.075;
h = 0.10;
};
class RscPicture_1303: RscPictureGUI
{
idc = 1303;
text = "\z\addons\dayz_code\gui\status_epoch\status_bleeding_ca.paa";
x = 0.955313 * safezoneW + safezoneX;
y = 0.79 * safezoneH + safezoneY;
w = 0.075;
h = 0.10;
colorText[] = {1,1,1,0.5};
};
class RscPicture_1304: RscPictureGUI
{
idc = 1304;
text = "\z\addons\dayz_code\gui\status_epoch\status_noise.paa";
x = 0.955313 * safezoneW + safezoneX;
y = 0.30 * safezoneH + safezoneY;
w = 0.075;
h = 0.10;
};
class RscPicture_1305: RscPictureGUI
{
idc = 1305;
text = "\z\addons\dayz_code\gui\status_epoch\status_visible.paa";
x = 0.955313 * safezoneW + safezoneX;
y = 0.37 * safezoneH + safezoneY;
w = 0.075;
h = 0.10;
};
};
};
};

View File

@@ -1,14 +1,7 @@
NEW VAR DZE_HeartBeat
USE TO ENABLE HEARTBEAT SOUND WHEN LOOKING AT BANDIT PLAYER (less than -5000 humanity), DISABLED BY DEFAULT
player_updateGui.sqf
Convert traders + loot (if old system) to ItemBloodbag
REMOVE TOOL BREAKING, IT'S STUPID
player_craftItem_DZV = compile preprocessFileLineNumbers "\z\addons\dayz_code\actions\player_craftItem.sqf";
trap_monitor.fsm is no more!
////////////////////////////////////////

View File

@@ -54,7 +54,7 @@ if(_IsNearVehicle >= 1) then {
_finished = false;
[1,1] call dayz_HungerThirst;
["Working",0,[20,40,15,0]] call dayz_NutritionSystem;
// force animation
player playActionNow "Medic";

View File

@@ -9,7 +9,7 @@ s_player_fillgen = 1;
// Use target from addaction
_vehicle = _this select 3;
[1,1] call dayz_HungerThirst;
["Working",0,[20,40,15,0]] call dayz_NutritionSystem;
// force animation
player playActionNow "Medic";

View File

@@ -6,7 +6,7 @@ _isOk = count (_location isFlatEmpty [0.5,0,0,4,0,false,player]) > 0;
if (_isOk) then {
_dir = getDir player;
_classname = "Land_Fire";
[1,1] call dayz_HungerThirst;
["Working",0,[20,40,15,0]] call dayz_NutritionSystem;
player playActionNow "Medic";
uiSleep 6;
dayz_hasFire = createVehicle [_classname, _location, [], 0, "CAN_COLLIDE"];

View File

@@ -26,7 +26,7 @@ _qty = count _fuelCans;
cutText [format[(localize "str_siphon_preparing"),_displayName], "PLAIN DOWN"];
[1,1] call dayz_HungerThirst;
["Working",0,[20,40,15,0]] call dayz_NutritionSystem;
// force animation
player playActionNow "Medic";
// Play sound && alert zombies

View File

@@ -463,7 +463,7 @@ if (_hasrequireditem) then {
while {_isOk} do { //publish phase
[10,10] call dayz_HungerThirst;
["Working",0,[100,15,10,0]] call dayz_NutritionSystem;
player playActionNow "Medic"; //animation
//alert zombies

View File

@@ -412,7 +412,7 @@ if (_hasrequireditem) then {
while {_isOk} do {
[10,10] call dayz_HungerThirst;
["Working",0,[100,15,10,0]] call dayz_NutritionSystem;
player playActionNow "Medic";
_dis=20;

View File

@@ -84,7 +84,7 @@ if ((count _upgrade) > 0) then {
_newclassname = _upgrade select 0;
_refund = _upgrade select 1;
[1,1] call dayz_HungerThirst;
["Working",0,[20,40,15,0]] call dayz_NutritionSystem;
player playActionNow "Medic";
[player,20,true,(getPosATL player)] spawn player_alertZombies;

View File

@@ -48,7 +48,7 @@ _proceed = true;
} forEach _requirements;
if (_proceed) then {
[1,1] call dayz_HungerThirst;
["Working",0,[20,40,15,0]] call dayz_NutritionSystem;
player playActionNow "Medic";
[player,20,true,(getPosATL player)] spawn player_alertZombies;

View File

@@ -1,8 +1,6 @@
/*
Created by Alby exclusively for DayZMod.
Please request permission to use/alter from Alby.
Included in Epoch with permission by @ebaydayz
*/
private ["_items","_counts","_config","_isRecipe","_item","_index","_amount","_count","_entry","_input","_array"];

View File

@@ -25,7 +25,7 @@ call gear_ui_init;
// require one tin bar per key
_hasTinBar = "ItemTinBar" in magazines player;
if (!_hasTinBar) exitWith {DZE_ActionInProgress = false; cutText [localize "str_epoch_player_59","PLAIN DOWN"]};
[1,1] call dayz_HungerThirst;
["Working",0,[20,40,15,0]] call dayz_NutritionSystem;
player playActionNow "Medic";
[player,"repair",0,false] call dayz_zombieSpeak;

View File

@@ -124,7 +124,7 @@ if (_canDo) then {
cutText [localize "str_epoch_player_62","PLAIN DOWN"];
[1,1] call dayz_HungerThirst;
["Working",0,[20,40,15,0]] call dayz_NutritionSystem;
player playActionNow "Medic";
[player,_sfx,0,false] call dayz_zombieSpeak;

View File

@@ -1,8 +1,6 @@
/*
Created by Alby exclusively for DayZMod.
Please request permission to use/alter from Alby.
Included in Epoch with permission by @ebaydayz
*/
private["_config","_input","_output","_required","_failChance","_hasInput","_availabeSpace"];

View File

@@ -52,7 +52,7 @@ if (count(_findNearestTree) >= 1) then {
_proceed = false;
while {_isOk} do {
[1,1] call dayz_HungerThirst;
["Working",0,[20,40,15,0]] call dayz_NutritionSystem;
player playActionNow "Medic";
[player,20,true,(getPosATL player)] spawn player_alertZombies;

View File

@@ -35,7 +35,7 @@ _classname = "WeaponHolder";
//return empty crate to inventory
player addMagazine "bulk_empty";
[1,1] call dayz_HungerThirst;
["Working",0,[20,40,15,0]] call dayz_NutritionSystem;
// Change to optional wait to complete
player playActionNow "Medic";
uiSleep 6;

View File

@@ -98,7 +98,7 @@ if ((count _upgrade) > 0) then {
} forEach _requirements;
if (_proceed) then {
[1,1] call dayz_HungerThirst;
["Working",0,[20,40,15,0]] call dayz_NutritionSystem;
player playActionNow "Medic";
[player,20,true,(getPosATL player)] spawn player_alertZombies;

View File

@@ -92,7 +92,7 @@ while {_isOk} do {
_isOk = false;
_proceed = false;
};
[1,1] call dayz_HungerThirst;
["Working",0,[20,40,15,0]] call dayz_NutritionSystem;
player playActionNow "Medic";
_dis=20;
[player,_dis,true,(getPosATL player)] spawn player_alertZombies;

View File

@@ -9,7 +9,7 @@ s_player_fillgen = 1;
// Use target from addaction
_vehicle = _this select 3;
[1,1] call dayz_HungerThirst;
["Working",0,[20,40,15,0]] call dayz_NutritionSystem;
// force animation
player playActionNow "Medic";

View File

@@ -39,7 +39,7 @@ if(_IsNearVehicle >= 1) then {
_finished = false;
[1,1] call dayz_HungerThirst;
["Working",0,[20,40,15,0]] call dayz_NutritionSystem;
// force animation
player playActionNow "Medic";

View File

@@ -28,7 +28,7 @@ if(_inTow) then {
_finished = false;
[1,1] call dayz_HungerThirst;
["Working",0,[20,40,15,0]] call dayz_NutritionSystem;
// force animation
player playActionNow "Medic";

View File

@@ -23,7 +23,7 @@ if(_buy_o_sell == "sell") then {
cutText [localize "str_epoch_player_105","PLAIN DOWN"];
[1,1] call dayz_HungerThirst;
["Working",0,[3,2,8,0]] call dayz_NutritionSystem;
// force animation
player playActionNow "Medic";

View File

@@ -29,7 +29,7 @@ if (_qty >= _qty_in) then {
cutText [localize "str_epoch_player_105","PLAIN DOWN"];
[1,1] call dayz_HungerThirst;
["Working",0,[3,2,8,0]] call dayz_NutritionSystem;
// force animation
player playActionNow "Medic";

View File

@@ -27,7 +27,7 @@ if(_buy_o_sell == "sell") then {
cutText [localize "str_epoch_player_105","PLAIN DOWN"];
[1,1] call dayz_HungerThirst;
["Working",0,[3,2,8,0]] call dayz_NutritionSystem;
// force animation
player playActionNow "Medic";

View File

@@ -34,7 +34,7 @@ if (_qty >= _qty_in) then {
cutText [localize "str_epoch_player_105","PLAIN DOWN"];
[1,1] call dayz_HungerThirst;
["Working",0,[3,2,8,0]] call dayz_NutritionSystem;
// force animation
player playActionNow "Medic";

View File

@@ -27,7 +27,7 @@ if(_buy_o_sell == "sell") then {
cutText [localize "str_epoch_player_105","PLAIN DOWN"];
[1,1] call dayz_HungerThirst;
["Working",0,[3,2,8,0]] call dayz_NutritionSystem;
// force animation
player playActionNow "Medic";

View File

@@ -27,7 +27,7 @@ if(_buy_o_sell == "sell") then {
cutText [localize "str_epoch_player_105","PLAIN DOWN"];
[1,1] call dayz_HungerThirst;
["Working",0,[3,2,8,0]] call dayz_NutritionSystem;
// force animation
player playActionNow "Medic";

View File

@@ -38,7 +38,7 @@ if (_qty >= _qty_in) then {
cutText [localize "str_epoch_player_105","PLAIN DOWN"];
[1,1] call dayz_HungerThirst;
["Working",0,[3,2,8,0]] call dayz_NutritionSystem;
// force animation
player playActionNow "Medic";

View File

@@ -26,7 +26,7 @@ cutText [localize "str_epoch_player_105","PLAIN DOWN"];
// force animation
player playActionNow "Medic";
[1,1] call dayz_HungerThirst;
["Working",0,[3,2,8,0]] call dayz_NutritionSystem;
r_interrupt = false;
_animState = animationState player;

View File

@@ -32,7 +32,7 @@ if (_qty >= _qty_in) then {
cutText [localize "str_epoch_player_105","PLAIN DOWN"];
[1,1] call dayz_HungerThirst;
["Working",0,[3,2,8,0]] call dayz_NutritionSystem;
// force animation
player playActionNow "Medic";

View File

@@ -61,7 +61,7 @@ while {r_autoTrade} do {
cutText [localize "str_epoch_player_105","PLAIN DOWN"];
[1,1] call dayz_HungerThirst;
["Working",0,[3,2,8,0]] call dayz_NutritionSystem;
player playActionNow "Medic";
//_dis=20;

View File

@@ -51,7 +51,7 @@ for "_x" from 1 to _total_trades do {
} else {
cutText [format[(localize "str_epoch_player_187"),_tradeCounter,_total_trades] , "PLAIN DOWN"];
};
[1,1] call dayz_HungerThirst;
["Working",0,[3,2,8,0]] call dayz_NutritionSystem;
player playActionNow "Medic";
//_dis=20;

View File

@@ -41,7 +41,7 @@ for "_x" from 1 to _total_trades do {
} else {
cutText [format[(localize "str_epoch_player_187"),_tradeCounter,_total_trades] , "PLAIN DOWN"];
};
[1,1] call dayz_HungerThirst;
["Working",0,[3,2,8,0]] call dayz_NutritionSystem;
player playActionNow "Medic";
r_interrupt = false;

View File

@@ -77,7 +77,7 @@ cutText [localize "str_epoch_player_105","PLAIN DOWN"];
// force animation
player playActionNow "Medic";
[1,1] call dayz_HungerThirst;
["Working",0,[3,2,8,0]] call dayz_NutritionSystem;
r_interrupt = false;
_animState = animationState player;

View File

@@ -28,7 +28,7 @@ if (_qty >= _qty_in) then {
cutText [localize "str_epoch_player_105","PLAIN DOWN"];
[1,1] call dayz_HungerThirst;
["Working",0,[3,2,8,0]] call dayz_NutritionSystem;
// force animation
player playActionNow "Medic";

View File

@@ -120,7 +120,7 @@ if(!_cancel) then {
//call dayz_forceSave;
_dir = round(direction player);
[1,1] call dayz_HungerThirst;
["Working",0,[20,40,15,0]] call dayz_NutritionSystem;
//wait a bit
player playActionNow "Medic";
uiSleep 1;

View File

@@ -3,8 +3,6 @@
Please request permission to use/alter from ziellos2k.
Edited by Alby with permission from ziellos2k.
Included in Epoch with permission by @ebaydayz
*/
disableSerialization;

View File

@@ -1,70 +1,58 @@
/*
count player magazines with ammo count
value = call player_countMagazines; //must be called from a spawned thread (|| use spawn)
value = call player_countMagazines;
return all player magazines with ammo count
Modified to save backpack magazine count by icomrade - Base for fix by Ziellos2k
*/
private ["_control","_item","_val","_max","_count","_magazineArray","_dialog"];
private ["_dialog","_created","_magazineArray"];
disableSerialization;
disableUserInput true;
_magazineArray = [[],[]];
_dialog = ["0"] call gearDialog_create;
if ((isNull _dialog) || (isNil "_dialog")) exitWith {disableUserInput false; (findDisplay 106) closeDisplay 0; closeDialog 0; _magazineArray};
_dialog = findDisplay 106;
_created = false;
//Main inventory
for "_i" from 109 to 120 do {
if ( isNull _dialog ) then {
//startLoadingScreen [""];
createGearDialog [player, "RscDisplayGear"];
_dialog = findDisplay 106;
_created = true;
};
_magazineArray = [];
for "_i" from 109 to 120 do
{
_control = _dialog displayCtrl _i;
_item = gearSlotData _control;
_val = gearSlotAmmoCount _control;
_max = getNumber (configFile >> "CfgMagazines" >> _item >> "count");
if (_item != "") then {
if (_val != _max) then {
(_magazineArray select 0) set [count (_magazineArray select 0),[_item,_val]];
_magazineArray set [count _magazineArray,[_item,_val]];
} else {
(_magazineArray select 0) set [count (_magazineArray select 0),_item];
_magazineArray set [count _magazineArray,_item];
};
};
};
//Pistol/secondary ammo
for "_i" from 122 to 129 do {
for "_i" from 122 to 129 do
{
_control = _dialog displayCtrl _i;
_item = gearSlotData _control;
_val = gearSlotAmmoCount _control;
_max = getNumber (configFile >> "CfgMagazines" >> _item >> "count");
if (_item != "") then {
if (_val != _max) then {
(_magazineArray select 0) set [count (_magazineArray select 0),[_item,_val]];
_magazineArray set [count _magazineArray,[_item,_val]];
} else {
(_magazineArray select 0) set [count (_magazineArray select 0),_item];
_magazineArray set [count _magazineArray,_item];
};
};
};
//backpack items
if ((typeOf (unitBackPack player)) != "") then {
_count = getNumber (configFile >> "CfgVehicles" >> (typeOf (unitBackpack Player)) >> "transportMaxMagazines");
ctrlActivate (_dialog displayCtrl 157);
if (gear_done) then {
waitUntil {ctrlShown (_dialog displayCtrl 159)};
uiSleep 0.001;
if ( _created ) then {
closeDialog 0;
//endLoadingScreen;
};
for "_i" from 5000 to (5000 + _count) do {
_control = _dialog displayCtrl _i;
_item = gearSlotData _control;
_val = gearSlotAmmoCount _control;
_max = getNumber (configFile >> "CfgMagazines" >> _item >> "count");
if (_item != "") then {
if (_val != _max) then {
(_magazineArray select 1) set [count (_magazineArray select 1),[_item,_val]];
} else {
(_magazineArray select 1) set [count (_magazineArray select 1),_item];
};
};
};
};
(findDisplay 106) closeDisplay 0;
if (gear_done) then {uiSleep 0.001;};
disableUserInput false;
_magazineArray

View File

@@ -19,7 +19,7 @@ _text = getText (configFile >> "CfgVehicles" >> _objType >> "displayName");
// Silently exit if object no longer exists
if(isNull _obj) exitWith { DZE_ActionInProgress = false; };
[1,1] call dayz_HungerThirst;
["Working",0,[3,2,8,0]] call dayz_NutritionSystem;
player playActionNow "Medic";
uiSleep 1;
[player,"tentpack",0,false] call dayz_zombieSpeak;

View File

@@ -56,7 +56,7 @@ _pos = _obj getVariable["OEMPos",(getposATL _obj)];
if(!isNull _obj && alive _obj) then {
[1,1] call dayz_HungerThirst;
["Working",0,[20,40,15,0]] call dayz_NutritionSystem;
player playActionNow "Medic";
[player,"tentpack",0,false] call dayz_zombieSpeak;
uiSleep 3;

View File

@@ -46,7 +46,7 @@ if (!isNull dayz_selectedDoor) then {
};
KeyCodeTry = nil;
} else {
[10,10] call dayz_HungerThirst;
["Working",0,[100,15,10,0]] call dayz_NutritionSystem;
DZE_Lock_Door = "";
[player,"combo_locked",0,false] call dayz_zombieSpeak;
[player,20,true,(getPosATL player)] spawn player_alertZombies;

View File

@@ -66,7 +66,7 @@ if ((_ownerID == dayz_combination) || (_ownerID == dayz_playerUID)) then {
waitUntil {!isNil "dze_waiting"};
_obj setVariable["packing",1];
[1,1] call dayz_HungerThirst;
["Working",0,[3,2,8,0]] call dayz_NutritionSystem;
_weapons = _obj getVariable["WeaponCargo",[]];
_magazines = _obj getVariable["MagazineCargo",[]];
_backpacks = _obj getVariable["BackpackCargo",[]];
@@ -130,7 +130,7 @@ if ((_ownerID == dayz_combination) || (_ownerID == dayz_playerUID)) then {
cutText [format[(localize "str_player_beinglooted"),_text] , "PLAIN DOWN"];
};
} else {
[10,10] call dayz_HungerThirst;
["Working",0,[100,15,10,0]] call dayz_NutritionSystem;
player playActionNow "Medic";
uiSleep 1;
[player,"repair",0,false] call dayz_zombieSpeak;

View File

@@ -1,349 +1,211 @@
private ["_display","_ctrlBlood","_ctrlBleed","_bloodVal","_humanityName","_ctrlFood","_ctrlThirst","_thirstVal","_foodVal","_ctrlTemp","_tempVal","_combatVal","_array","_ctrlEar","_ctrlEye","_ctrlCombat","_ctrlFracture","_visualText","_visual","_audibleText","_audible","_blood","_thirstLvl","_foodLvl","_tempImg","_thirst","_food","_temp","_bloodLvl","_tempLvl","_color","_string","_humanity","_size","_friendlies","_charID","_rcharID","_rfriendlies","_rfriendlyTo","_distance","_targetControl","_combattimeout","_timeleft"];
//private ["_display","_ctrlBloodOuter","_ctrlBlood","_ctrlBleed","_bloodVal","_ctrlFood","_ctrlThirst","_thirstVal","_foodVal","_ctrlTemp","_ctrlFoodBorder","_ctrlThirstBorder","_ctrlTempBorder","_tempVal","_array","_ctrlEar","_ctrlEye","_ctrlFracture","_visual","_audible","_uiNumber","_bloodText","_blood","_thirstLvl","_foodLvl","_tempImg","_bloodLvl","_tempLvl","_thirst","_food","_temp"];
private ["_flash","_array","_bloodText","_tempImg","_uiNumber","_blood","_foodLvl","_thirstLvl","_audible","_visual","_bloodType","_rhFactor","_ctrlBloodType", "_bloodTestdone"];
_flash = {
if (ctrlShown _this) then {
_this ctrlShow false;
} else {
_this ctrlShow true;
};
};
disableSerialization;
if(Dayz_Dark_UI) then {
_foodVal = 1 - (dayz_hunger / SleepFood);
_thirstVal = 1 - (dayz_thirst / SleepWater);
_tempVal = 1 - ((dayz_temperatur - dayz_temperaturmin)/(dayz_temperaturmax - dayz_temperaturmin)); // Normalise to [0,1]
if (uiNamespace getVariable ["DZ_displayUI", 0] == 1) exitWith {
if (uiNamespace getVariable ['DZ_displayUI', 0] == 1) exitWith {
_array = [_foodVal,_thirstVal];
_array
};
if(dayz_combat == 1) then {
_combattimeout = player getVariable["combattimeout",0];
_timeleft = _combattimeout - time;
_combatVal = (_timeleft/30);
} else {
_combatVal = 0;
};
_tempVal = ((dayz_temperatur - dayz_temperaturmin)/(dayz_temperaturmax - dayz_temperaturmin)); // Normalise to [0,1]
_audible = (dayz_disAudial / 50);
_visual = (dayz_disVisual / 100);
_bloodVal = r_player_blood / r_player_bloodTotal;
_display = uiNamespace getVariable 'DAYZ_GUI_display';
if (isNil "_display") exitWith { [_foodVal,_thirstVal] }; // not ready
_ctrlBloodOuter = _display displayCtrl 1200;
_ctrlFoodBorder = _display displayCtrl 1201;
_ctrlThirstBorder = _display displayCtrl 1202;
_ctrlTempBorder = _display displayCtrl 1208;
//Border white
_ctrlBloodOuter ctrlSetTextColor [1,1,1,1];
_ctrlFoodBorder ctrlSetTextColor [1,1,1,1];
_ctrlThirstBorder ctrlSetTextColor [1,1,1,1];
_ctrlTempBorder ctrlSetTextColor [1,1,1,1];
_ctrlBlood = _display displayCtrl 1300;
_ctrlBloodType = _display displayCtrl 1307;
_ctrlBleed = _display displayCtrl 1303;
_bloodVal = r_player_blood / r_player_bloodTotal;
_ctrlFood = _display displayCtrl 1301;
_ctrlThirst = _display displayCtrl 1302;
_ctrlTemp = _display displayCtrl 1306; //TeeChange
_ctrlTemp = _display displayCtrl 1306;
_ctrlEar = _display displayCtrl 1304;
_ctrlEye = _display displayCtrl 1305;
//_ctrlHumanity = _display displayCtrl 1207;
_ctrlCombat = _display displayCtrl 1307;
_ctrlFracture = _display displayCtrl 1203;
_control = _display displayCtrl 1204; //status_connection_ca.paa ???
_control ctrlShow false;
//Food/Water/Blood
_ctrlBlood ctrlSetTextColor [(1 - _bloodVal),(1 - _bloodVal),(1 - _bloodVal), 0.5];
_ctrlFood ctrlSetTextColor [ _foodVal,_foodVal,_foodVal, 0.5];
_ctrlThirst ctrlSetTextColor [ _thirstVal, _thirstVal, _thirstVal, 0.5];
_ctrlTemp ctrlSetTextColor [(1 - _tempVal),(1 - _tempVal), (1 - _tempVal), 0.5]; // Color ranges from iceblue (cold) to red (hot)
_ctrlCombat ctrlSetTextColor [ _combatVal, _combatVal, _combatVal, 0.5];
_ctrlEye ctrlSetTextColor [ _visual, _visual, _visual, 0.5];
_ctrlEar ctrlSetTextColor [ _audible, _audible, _audible, 0.5];
/*
Blood: round((r_player_blood / 2) / 1000) = _bloodLvl (6 = full, 1 = empty)
Thirst: round(_thirstVal / 0.25) = _thirstLvl (4 = full, 0 = empty)
Hunger: round(_foodVal / 0.25) = _foodLvl (4 = full, 0 = empty)
Temp: round(dayz_temperatur) = tempLvl (>= 36 = full <= 28 = empty)
NEW SYSTEM SHOULD BE: (EXAMPLE)
if (_bloodVal > 0.5) then { GREEN TO YELLOW } else { YELLOW TO RED};
Same with Food and Thirst
*/
/*
_ctrlTemp ctrlSetTextColor [(Dayz_GUI_R + (0.3 * (1-_tempVal))), (Dayz_GUI_G * _tempVal), _tempVal, 1]; // Color ranges from iceblue (cold) to red (hot) // << Already Done :)
// OLD SYSTEM
_ctrlBlood ctrlSetTextColor [(Dayz_GUI_R + (0.3 * (1-_bloodVal))),(Dayz_GUI_G * _bloodVal),(Dayz_GUI_B * _bloodVal), 1];
_ctrlFood ctrlSetTextColor [(Dayz_GUI_R + (0.3 * (1-_foodVal))),(Dayz_GUI_G * _foodVal),(Dayz_GUI_B * _foodVal), 1];
_ctrlThirst ctrlSetTextColor [(Dayz_GUI_R + (0.3 * (1-_thirstVal))),(Dayz_GUI_G * _thirstVal),(Dayz_GUI_B * _thirstVal), 1];
/* //Debugging Stuff would be usefull
diag_log format["DEBUG: bloodlvl: %1 r_player_blood: %2 bloodval: %3",_bloodLvl, r_player_blood, _bloodVal];
diag_log format["DEBUG: thirstlvl: %1 dayz_thirst: %2 thirstval: %3",_thirstLvl, dayz_thirst, _thirstVal];
diag_log format["DEBUG: foodlvl: %1 dayz_hunger: %2 foodval: %3",_foodLvl, dayz_hunger, _foodVal];
diag_log format["DEBUG: templvl: %1 dayz_temperatur: %2 tempval: %3",_tempLvl, dayz_temperatur, _tempVal];
*/
//left naming conventions the same in case other files are re-introduced at a later time
_blood = "\z\addons\dayz_code\gui\status_blood_inside_6_ca.paa";
_thirst = "\z\addons\dayz_code\gui\status_thirst_inside_4_ca.paa";
_food = "\z\addons\dayz_code\gui\status_food_inside_4_ca.paa";
_temp = "\z\addons\dayz_code\gui\status_temp_4_ca.paa";
_visualtext = "\z\addons\dayz_code\gui\status_eye_ca.paa";
_audibletext = "\z\addons\dayz_code\gui\status_ear_ca.paa";
_ctrlBlood ctrlSetText _blood;
_ctrlThirst ctrlSetText _thirst;
_ctrlFood ctrlSetText _food;
_ctrlTemp ctrlSetText _temp;
_ctrlEye ctrlSetText _visualtext;
_ctrlEar ctrlSetText _audibletext;
/*
Fracture:
*/
if (!canStand player) then {
if (!(ctrlShown _ctrlFracture)) then {
r_fracture_legs = true;
_ctrlFracture ctrlShow true;
};
};
/*
Flashing:
*/
_ctrl_Array=[];
if (_combatVal > 0) then {
_ctrl_Array=_ctrl_Array + [_ctrlCombat];
} else {
_ctrlCombat ctrlShow true;
};
if (_bloodVal < 0.4) then {
_ctrl_Array=_ctrl_Array + [_ctrlBlood];
} else {
_ctrlBlood ctrlShow true;
};
if (_thirstVal < 0.2) then {
_ctrl_Array=_ctrl_Array + [_ctrlThirst];
} else {
_ctrlThirst ctrlShow true;
};
if (_foodVal < 0.2) then {
_ctrl_Array=_ctrl_Array + [_ctrlFood];
} else {
_ctrlFood ctrlShow true;
};
if (_tempVal < 0.2) then { //TeeChange
_ctrl_Array=_ctrl_Array + [_ctrlTemp];
} else {
_ctrlTemp ctrlShow true;
};
if (r_player_injured) then {
_ctrl_Array=_ctrl_Array + [_ctrlBleed];
} else {
_ctrlBleed ctrlShow false;
};
if ((count _ctrl_Array) > 0) then
{
_ctrl_Array call player_guiControlFlash;
};
} else {
_foodVal = 1 - (dayz_hunger / SleepFood);
_thirstVal = 1 - (dayz_thirst / SleepWater);
_tempVal = 1 - ((dayz_temperatur - dayz_temperaturmin)/(dayz_temperaturmax - dayz_temperaturmin)); // Normalise to [0,1]
_combatVal = 1 - dayz_combat; // May change later to be a range of red/green to loosely indicate 'time left in combat'
if (uiNamespace getVariable ["DZ_displayUI", 0] == 1) exitWith {
_array = [_foodVal,_thirstVal];
_array
};
_display = uiNamespace getVariable 'DAYZ_GUI_display';
_ctrlBlood = _display displayCtrl 1300;
_ctrlBleed = _display displayCtrl 1303;
_bloodVal = r_player_blood / r_player_bloodTotal;
_ctrlFood = _display displayCtrl 1301;
_ctrlThirst = _display displayCtrl 1302;
_ctrlTemp = _display displayCtrl 1306; //TeeChange
_ctrlEar = _display displayCtrl 1304;
_ctrlEye = _display displayCtrl 1305;
//_ctrlHumanity = _display displayCtrl 1207;
_ctrlCombat = _display displayCtrl 1307;
_ctrlFracture = _display displayCtrl 1203;
//Food/Water/Blood
_ctrlBlood ctrlSetTextColor [(Dayz_GUI_R + (0.3 * (1-_bloodVal))),(Dayz_GUI_G * _bloodVal),(Dayz_GUI_B * _bloodVal), 0.5];
_ctrlFood ctrlSetTextColor [(Dayz_GUI_R + (0.3 * (1-_foodVal))),(Dayz_GUI_G * _foodVal),(Dayz_GUI_B * _foodVal), 0.5];
_ctrlThirst ctrlSetTextColor [(Dayz_GUI_R + (0.3 * (1-_thirstVal))),(Dayz_GUI_G * _thirstVal),(Dayz_GUI_B * _thirstVal), 0.5];
_ctrlTemp ctrlSetTextColor [(Dayz_GUI_R + (0.3 * (1-_tempVal))), (Dayz_GUI_G * _tempVal), _tempVal, 0.5]; // Color ranges from iceblue (cold) to red (hot)
_ctrlCombat ctrlSetTextColor [(Dayz_GUI_R + (0.3 * (1-_combatVal))),(Dayz_GUI_G * _combatVal),(Dayz_GUI_B * _combatVal), 0.5];
/*
Blood: round((r_player_blood / 2) / 1000) = _bloodLvl (6 = full, 1 = empty)
Thirst: round(_thirstVal / 0.25) = _thirstLvl (4 = full, 0 = empty)
Hunger: round(_foodVal / 0.25) = _foodLvl (4 = full, 0 = empty)
Temp: round(dayz_temperatur) = tempLvl (>= 36 = full <= 28 = empty)
*/
_blood = "";
_thirst = "";
_food = "";
_temp = "";
_tempImg = 0;
_bloodLvl = round((r_player_blood / 2) / 1000);
_bloodLvl = 6 min (0 max (round((r_player_blood / 2) / 1000 + 0.49)));
_thirstLvl = round(_thirstVal / 0.25);
_foodLvl = round(_foodVal / 0.25);
_tempLvl = round(dayz_temperatur);
/*
diag_log format["DEBUG: bloodlvl: %1 r_player_blood: %2 bloodval: %3",_bloodLvl, r_player_blood, _bloodVal];
diag_log format["DEBUG: thirstlvl: %1 dayz_thirst: %2 thirstval: %3",_thirstLvl, dayz_thirst, _thirstVal];
diag_log format["DEBUG: foodlvl: %1 dayz_hunger: %2 foodval: %3",_foodLvl, dayz_hunger, _foodVal];
diag_log format["DEBUG: templvl: %1 dayz_temperatur: %2 tempval: %3",_tempLvl, dayz_temperatur, _tempVal];
*/
// Blood Regen & BloodLoss:
switch true do {
case (r_player_bloodpersec <= -50): { _uiNumber = -3 }; // -3
case ((r_player_bloodpersec <= -25) and (r_player_bloodpersec > -50)): { _uiNumber = -2 }; // -2
case ((r_player_bloodpersec < 0) and (r_player_bloodpersec > -25)): { _uiNumber = -1 }; // -1
case ((r_player_bloodpersec > 5) and (r_player_bloodpersec < 25)): { _uiNumber = 1 }; // 1
case ((r_player_bloodpersec >= 25) and (r_player_bloodpersec < 50)): { _uiNumber = 2 }; // 2
case (r_player_bloodpersec >= 50): { _uiNumber = 3 }; // 3
default { _uiNumber = 0 };
};
_bloodText = "\z\addons\dayz_code\gui\status\status_blood_border";
if (r_player_infected) then {
switch true do {
case (_uiNumber < 0): { _bloodText = _bloodText + "_down" + str(-_uiNumber) + "_sick_ca.paa" };
case (_uiNumber > 0): { _bloodText = _bloodText + "_up" + str(_uiNumber) + "_sick_ca.paa" };
default { _bloodText = _bloodText + "_sick_ca.paa" };
};
} else {
//if (r_player_Sepsis select 0) then {
// _bloodText = "\z\addons\dayz_code\gui\status\status_blood_border_sick_ca.paa"
//} else {
switch true do {
case (_uiNumber < 0): { _bloodText = _bloodText + "_down" + str(-_uiNumber) + "_ca.paa" };
case (_uiNumber > 0): { _bloodText = _bloodText + "_up" + str(_uiNumber) + "_ca.paa" };
default { _bloodText = _bloodText + "_ca.paa" };
};
//};
};
_ctrlBloodOuter ctrlSetText _bloodText;
if (_bloodLvl <= 0) then {
_blood = "\z\addons\dayz_code\gui\status_blood_inside_1_ca.paa";
_blood = "\z\addons\dayz_code\gui\status\status_blood_inside_1_ca.paa";
} else {
_blood = "\z\addons\dayz_code\gui\status_blood_inside_" + str(_bloodLvl) + "_ca.paa";
_blood = "\z\addons\dayz_code\gui\status\status_blood_inside_" + str(_bloodLvl) + "_ca.paa";
};
_bloodTestdone = player getVariable ["blood_testdone", false];
if (_bloodTestdone) then {
_bloodType = player getVariable ["blood_type", "O"];
_rhFactor = if (player getVariable ["rh_factor", false]) then { "pos" } else { "neg" };
_ctrlBloodType ctrlSetText ("\z\addons\dayz_code\gui\status\status_blood_type_"+_bloodType+"_"+_rhFactor+"_ca.paa");
};
if (_thirstLvl < 0) then { _thirstLvl = 0 };
_thirst = "\z\addons\dayz_code\gui\status_thirst_inside_" + str(_thirstLvl) + "_ca.paa";
_thirst = "\z\addons\dayz_code\gui\status\status_thirst_inside_" + str(_thirstLvl) + "_ca.paa";
if (_foodLvl < 0) then { _foodLvl = 0 };
_food = "\z\addons\dayz_code\gui\status_food_inside_" + str(_foodLvl) + "_ca.paa";
_food = "\z\addons\dayz_code\gui\status\status_food_inside_" + str(_foodLvl) + "_ca.paa";
if ( _tempLvl >= 36 ) then { _tempImg = 4 };
if ( _tempLvl > 33 && _tempLvl < 36 ) then { _tempImg = 3 };
if ( _tempLvl >= 30 && _tempLvl <= 33 ) then { _tempImg = 2 };
if ( _tempLvl > 28 && _tempLvl < 30 ) then { _tempImg = 1 };
if ( _tempLvl <= 28 ) then { _tempImg = 0 };
switch true do {
case (_tempLvl >= 36): { _tempImg = 4 };
case (_tempLvl > 33 and _tempLvl < 36): { _tempImg = 3 };
case (_tempLvl >= 30 and _tempLvl <= 33): { _tempImg = 2 };
case (_tempLvl > 28 and _tempLvl < 30): { _tempImg = 1 };
default { _tempImg = 0 };
};
_temp = "\z\addons\dayz_code\gui\status_temp_" + str(_tempImg) + "_ca.paa";
_temp = "\z\addons\dayz_code\gui\status\status_temp_" + str(_tempImg) + "_ca.paa";
_ctrlBlood ctrlSetText _blood;
_ctrlThirst ctrlSetText _thirst;
_ctrlFood ctrlSetText _food;
_ctrlTemp ctrlSetText _temp;
/*
Visual:
*/
_visualtext = "";
_visual = (round((dayz_disVisual / 100) * 4)) min 5;
if (_visual > 0) then {_visualtext = "\z\addons\dayz_code\gui\val_" + str(_visual) + "_ca.paa"};
_ctrlEye ctrlSetText _visualtext;
// Visual:
_visual = (dayz_disVisual / 185) min 1;
if (_visual < 0.2) then {_visual = 0.2;};
_ctrlEye ctrlSetTextColor [1, 1, 1, _visual];
/*
Audible:
*/
_audibletext = "";
_audible = (round((dayz_disAudial / 50) * 4)) min 5;
if (_audible > 0) then {_audibletext = "\z\addons\dayz_code\gui\val_" + str(_audible) + "_ca.paa"};
_ctrlEar ctrlSetText _audibletext;
// Audible
_audible = (dayz_disAudial / 40) min 1;
if (_audible < 0.2) then {_audible = 0.2;};
_ctrlEar ctrlSetTextColor [1, 1, 1, _audible];
/*
Fracture:
*/
if (!canStand player) then {
if (!(ctrlShown _ctrlFracture)) then {
r_fracture_legs = true;
// Fracture/Broken Legs
if (!(canStand player) and !(ctrlShown _ctrlFracture)) then {
_ctrlFracture ctrlShow true;
};
}
else {
_ctrlFracture ctrlShow false;
};
/*
Flashing:
*/
_ctrl_Array=[];
if (_combatVal == 0) then {
_ctrl_Array=_ctrl_Array + [_ctrlCombat];
} else {
_ctrlCombat ctrlShow true;
};
if (_bloodVal < 0.4) then {
_ctrl_Array=_ctrl_Array + [_ctrlBlood];
// Flashing
if (_bloodVal < 0.2) then {
_ctrlBlood call _flash;
} else {
if (!ctrlShown _ctrlBlood) then {
_ctrlBlood ctrlShow true;
};
};
if (_thirstVal < 0.2) then {
_ctrl_Array=_ctrl_Array + [_ctrlThirst];
_ctrlThirst call _flash;
} else {
if (!ctrlShown _ctrlThirst) then {
_ctrlThirst ctrlShow true;
};
};
if (_foodVal < 0.2) then {
_ctrl_Array=_ctrl_Array + [_ctrlFood];
_ctrlFood call _flash;
} else {
if (!ctrlShown _ctrlFood) then {
_ctrlFood ctrlShow true;
};
};
if (_tempVal > 0.8) then { //TeeChange
_ctrl_Array=_ctrl_Array + [_ctrlTemp];
if (_tempVal > 0.8) then {
_ctrlTemp call _flash;
} else {
if (!ctrlShown _ctrlTemp) then {
_ctrlTemp ctrlShow true;
};
};
if (r_player_injured) then {
_ctrl_Array=_ctrl_Array + [_ctrlBleed];
} else {
_ctrlBleed call _flash;
}
else {
_ctrlBleed ctrlShow false;
};
if((count _ctrl_Array) > 0) then
{
_ctrl_Array call player_guiControlFlash;
};
};
/*
Opt-in tag system with friend tagging
*/
_string = "";
_humanityTarget = cursorTarget;
if (!isNull _humanityTarget && isPlayer _humanityTarget && alive _humanityTarget) then {
_distance = player distance _humanityTarget;
if (_distance < DZE_HumanityTargetDistance) then {
_size = (1-(floor(_distance/5)*0.1)) max 0.1;
// Display name if player opt-in || if friend
_friendlies = player getVariable ["friendlies", []];
_charID = player getVariable ["CharacterID", "0"];
_rcharID = _humanityTarget getVariable ["CharacterID", "0"];
_rfriendlies = _humanityTarget getVariable ["friendlies", []];
_rfriendlyTo = _humanityTarget getVariable ["friendlyTo", []];
if ((_rcharID in _friendlies) && (_charID in _rfriendlies)) then {
if !(_charID in _rfriendlyTo) then {
// diag_log format["IS FRIENDLY: %1", _player];
_rfriendlyTo set [count _rfriendlyTo, _charID];
_humanityTarget setVariable ["friendlyTo", _rfriendlyTo, true];
};
// <br /><t %2 align='center' size='0.7'>Humanity: %3</t>
_color = "color='#339933'";
_string = format["<t %2 align='center' size='%3'>%1</t>",(name _humanityTarget),_color,_size];
} else {
// Humanity checks
_humanity = _humanityTarget getVariable ["humanity",0];
_color = "color='#ffffff'";
if(_humanity < -5000) then {
_color = "color='#ff0000'";
} else {
if(_humanity > 5000) then {
_color = "color='#3333ff'";
};
};
if((_humanityTarget getVariable ["DZE_display_name", false]) || (DZE_ForceNameTagsInTrader && isInTraderCity)) then {
_string = format["<t %2 align='center' size='%3'>%1</t>",(name _humanityTarget),_color,_size];
};
};
};
};
// update gui if changed
if (dayz_humanitytarget != _string) then {
_targetControl = _display displayCtrl 1199;
_targetControl ctrlSetStructuredText (parseText _string);
dayz_humanitytarget = _string;
};
_array = [_foodVal,_thirstVal];
_array

View File

@@ -0,0 +1,205 @@
private ["_flash","_display","_ctrlBlood","_ctrlBleed","_bloodVal","_humanityName","_ctrlFood","_ctrlThirst","_thirstVal","_foodVal","_ctrlTemp","_tempVal","_combatVal","_array","_ctrlEar","_ctrlEye","_ctrlCombat","_ctrlFracture","_visualText","_visual","_audibleText","_audible","_blood","_thirstLvl","_foodLvl","_tempImg","_thirst","_food","_temp","_bloodLvl","_tempLvl","_color","_string","_humanity","_size","_friendlies","_charID","_rcharID","_rfriendlies","_rfriendlyTo","_distance","_targetControl","_combattimeout","_timeleft"];
_flash = {
if (ctrlShown _this) then {
_this ctrlShow false;
} else {
_this ctrlShow true;
};
};
disableSerialization;
_foodVal = 1 - (dayz_hunger / SleepFood);
_thirstVal = 1 - (dayz_thirst / SleepWater);
_tempVal = ((dayz_temperatur - dayz_temperaturmin)/(dayz_temperaturmax - dayz_temperaturmin)); // Normalise to [0,1]
if (uiNamespace getVariable ["DZ_displayUI", 0] == 1) exitWith {
_array = [_foodVal,_thirstVal];
_array
};
if(dayz_combat == 1) then {
_combattimeout = player getVariable["combattimeout",0];
_timeleft = _combattimeout - time;
_combatVal = (_timeleft/30);
} else {
_combatVal = 0;
};
_audible = (dayz_disAudial / 50);
_visual = (dayz_disVisual / 100);
_bloodVal = r_player_blood / r_player_bloodTotal;
_display = uiNamespace getVariable 'DAYZ_GUI_display';
if (isNil "_display") exitWith { [_foodVal,_thirstVal] }; // not ready
_ctrlBlood = _display displayCtrl 1300;
_ctrlBleed = _display displayCtrl 1303;
_ctrlFood = _display displayCtrl 1301;
_ctrlThirst = _display displayCtrl 1302;
_ctrlTemp = _display displayCtrl 1306; //TeeChange
_ctrlEar = _display displayCtrl 1304;
_ctrlEye = _display displayCtrl 1305;
//_ctrlHumanity = _display displayCtrl 1207;
_ctrlCombat = _display displayCtrl 1307;
_ctrlFracture = _display displayCtrl 1203;
//Food/Water/Blood
_ctrlBlood ctrlSetTextColor [(1 - _bloodVal),(1 - _bloodVal),(1 - _bloodVal), 0.5];
_ctrlFood ctrlSetTextColor [ _foodVal,_foodVal,_foodVal, 0.5];
_ctrlThirst ctrlSetTextColor [ _thirstVal, _thirstVal, _thirstVal, 0.5];
_ctrlTemp ctrlSetTextColor [(1 - _tempVal),(1 - _tempVal), (1 - _tempVal), 0.5]; // Color ranges from iceblue (cold) to red (hot)
_ctrlCombat ctrlSetTextColor [ _combatVal, _combatVal, _combatVal, 0.5];
_ctrlEye ctrlSetTextColor [ _visual, _visual, _visual, 0.5];
_ctrlEar ctrlSetTextColor [ _audible, _audible, _audible, 0.5];
/*
Blood: round((r_player_blood / 2) / 1000) = _bloodLvl (6 = full, 1 = empty)
Thirst: round(_thirstVal / 0.25) = _thirstLvl (4 = full, 0 = empty)
Hunger: round(_foodVal / 0.25) = _foodLvl (4 = full, 0 = empty)
Temp: round(dayz_temperatur) = tempLvl (>= 36 = full <= 28 = empty)
*/
/*
diag_log format["DEBUG: bloodlvl: %1 r_player_blood: %2 bloodval: %3",_bloodLvl, r_player_blood, _bloodVal];
diag_log format["DEBUG: thirstlvl: %1 dayz_thirst: %2 thirstval: %3",_thirstLvl, dayz_thirst, _thirstVal];
diag_log format["DEBUG: foodlvl: %1 dayz_hunger: %2 foodval: %3",_foodLvl, dayz_hunger, _foodVal];
diag_log format["DEBUG: templvl: %1 dayz_temperatur: %2 tempval: %3",_tempLvl, dayz_temperatur, _tempVal];
*/
//left naming conventions the same in case other files are re-introduced at a later time
_blood = "\z\addons\dayz_code\gui\status_epoch\status_blood_inside_6_ca.paa";
_thirst = "\z\addons\dayz_code\gui\status_epoch\status_thirst_inside_4_ca.paa";
_food = "\z\addons\dayz_code\gui\status_epoch\status_food_inside_4_ca.paa";
_temp = "\z\addons\dayz_code\gui\status_epoch\status_temp_4_ca.paa";
_visualtext = "\z\addons\dayz_code\gui\status_epoch\status_eye_ca.paa";
_audibletext = "\z\addons\dayz_code\gui\status_epoch\status_ear_ca.paa";
_ctrlBlood ctrlSetText _blood;
_ctrlThirst ctrlSetText _thirst;
_ctrlFood ctrlSetText _food;
_ctrlTemp ctrlSetText _temp;
_ctrlEye ctrlSetText _visualtext;
_ctrlEar ctrlSetText _audibletext;
// Fracture/Broken Legs
if (!(canStand player) and !(ctrlShown _ctrlFracture)) then {
_ctrlFracture ctrlShow true;
}
else {
_ctrlFracture ctrlShow false;
};
// Flashing
if (_combatVal > 0) then {
_ctrlCombat call _flash;
} else {
if (!ctrlShown _ctrlCombat) then {
_ctrlCombat ctrlShow true;
};
};
if (_bloodVal < 0.4) then {
_ctrlBlood call _flash;
} else {
if (!ctrlShown _ctrlBlood) then {
_ctrlBlood ctrlShow true;
};
};
if (_thirstVal < 0.2) then {
_ctrlThirst call _flash;
} else {
if (!ctrlShown _ctrlThirst) then {
_ctrlThirst ctrlShow true;
};
};
if (_foodVal < 0.2) then {
_ctrlFood call _flash;
} else {
if (!ctrlShown _ctrlFood) then {
_ctrlFood ctrlShow true;
};
};
if (_tempVal < 0.2) then { //TeeChange
_ctrlTemp call _flash;
} else {
if (!ctrlShown _ctrlTemp) then {
_ctrlTemp ctrlShow true;
};
};
if (r_player_injured) then {
_ctrlBleed call _flash;
}
else {
_ctrlBleed ctrlShow false;
};
/*
Opt-in tag system with friend tagging
*/
_string = "";
_humanityTarget = cursorTarget;
if (!isNull _humanityTarget && {isPlayer _humanityTarget} && {alive _humanityTarget}) then {
_distance = player distance _humanityTarget;
if (_distance < DZE_HumanityTargetDistance) then {
_size = (1-(floor(_distance/5)*0.1)) max 0.1;
// Display name if player opt-in or if friend
_friendlies = player getVariable ["friendlies", []];
_charID = player getVariable ["CharacterID", "0"];
_rcharID = _humanityTarget getVariable ["CharacterID", "0"];
_rfriendlies = _humanityTarget getVariable ["friendlies", []];
_rfriendlyTo = _humanityTarget getVariable ["friendlyTo", []];
if ((_rcharID in _friendlies) && (_charID in _rfriendlies)) then {
if !(_charID in _rfriendlyTo) then {
// diag_log format["IS FRIENDLY: %1", _player];
_rfriendlyTo set [count _rfriendlyTo, _charID];
_humanityTarget setVariable ["friendlyTo", _rfriendlyTo, true];
};
// <br /><t %2 align='center' size='0.7'>Humanity: %3</t>
_color = "color='#339933'";
_string = format["<t %2 align='center' size='%3'>%1</t>",(name _humanityTarget),_color,_size];
} else {
// Humanity checks
_humanity = _humanityTarget getVariable ["humanity",0];
_color = "color='#ffffff'";
if(_humanity < -5000) then {
_color = "color='#ff0000'";
} else {
if(_humanity > 5000) then {
_color = "color='#3333ff'";
};
};
if((_humanityTarget getVariable ["DZE_display_name", false]) || (DZE_ForceNameTagsInTrader && isInTraderCity)) then {
_string = format["<t %2 align='center' size='%3'>%1</t>",(name _humanityTarget),_color,_size];
};
};
};
};
// update gui if changed
if (dayz_humanitytarget != _string) then {
_targetControl = _display displayCtrl 1199;
_targetControl ctrlSetStructuredText (parseText _string);
dayz_humanitytarget = _string;
};
_array = [_foodVal,_thirstVal];
_array

View File

@@ -0,0 +1,228 @@
private ["_flash","_display","_ctrlBlood","_ctrlBleed","_bloodVal","_humanityName","_ctrlFood","_ctrlThirst","_thirstVal","_foodVal","_ctrlTemp","_tempVal","_combatVal","_array","_ctrlEar","_ctrlEye","_ctrlCombat","_ctrlFracture","_visualText","_visual","_audibleText","_audible","_blood","_thirstLvl","_foodLvl","_tempImg","_thirst","_food","_temp","_bloodLvl","_tempLvl","_color","_string","_humanity","_size","_friendlies","_charID","_rcharID","_rfriendlies","_rfriendlyTo","_distance","_targetControl","_combattimeout","_timeleft"];
_flash = {
if (ctrlShown _this) then {
_this ctrlShow false;
} else {
_this ctrlShow true;
};
};
disableSerialization;
_foodVal = 1 - (dayz_hunger / SleepFood);
_thirstVal = 1 - (dayz_thirst / SleepWater);
_tempVal = 1 - ((dayz_temperatur - dayz_temperaturmin)/(dayz_temperaturmax - dayz_temperaturmin)); // Normalise to [0,1]
_combatVal = 1 - dayz_combat; // May change later to be a range of red/green to loosely indicate 'time left in combat'
if (uiNamespace getVariable ["DZ_displayUI", 0] == 1) exitWith {
_array = [_foodVal,_thirstVal];
_array
};
_display = uiNamespace getVariable 'DAYZ_GUI_display';
if (isNil "_display") exitWith { [_foodVal,_thirstVal] }; // not ready
_ctrlBlood = _display displayCtrl 1300;
_ctrlBleed = _display displayCtrl 1303;
_bloodVal = r_player_blood / r_player_bloodTotal;
_ctrlFood = _display displayCtrl 1301;
_ctrlThirst = _display displayCtrl 1302;
_ctrlTemp = _display displayCtrl 1306; //TeeChange
_ctrlEar = _display displayCtrl 1304;
_ctrlEye = _display displayCtrl 1305;
//_ctrlHumanity = _display displayCtrl 1207;
_ctrlCombat = _display displayCtrl 1307;
_ctrlFracture = _display displayCtrl 1203;
//Food/Water/Blood
_ctrlBlood ctrlSetTextColor [(Dayz_GUI_R + (0.3 * (1-_bloodVal))),(Dayz_GUI_G * _bloodVal),(Dayz_GUI_B * _bloodVal), 0.5];
_ctrlFood ctrlSetTextColor [(Dayz_GUI_R + (0.3 * (1-_foodVal))),(Dayz_GUI_G * _foodVal),(Dayz_GUI_B * _foodVal), 0.5];
_ctrlThirst ctrlSetTextColor [(Dayz_GUI_R + (0.3 * (1-_thirstVal))),(Dayz_GUI_G * _thirstVal),(Dayz_GUI_B * _thirstVal), 0.5];
_ctrlTemp ctrlSetTextColor [(Dayz_GUI_R + (0.3 * (1-_tempVal))), (Dayz_GUI_G * _tempVal), _tempVal, 0.5]; // Color ranges from iceblue (cold) to red (hot)
_ctrlCombat ctrlSetTextColor [(Dayz_GUI_R + (0.3 * (1-_combatVal))),(Dayz_GUI_G * _combatVal),(Dayz_GUI_B * _combatVal), 0.5];
/*
Blood: round((r_player_blood / 2) / 1000) = _bloodLvl (6 = full, 1 = empty)
Thirst: round(_thirstVal / 0.25) = _thirstLvl (4 = full, 0 = empty)
Hunger: round(_foodVal / 0.25) = _foodLvl (4 = full, 0 = empty)
Temp: round(dayz_temperatur) = tempLvl (>= 36 = full <= 28 = empty)
*/
_blood = "";
_thirst = "";
_food = "";
_temp = "";
_tempImg = 0;
_bloodLvl = round((r_player_blood / 2) / 1000);
_thirstLvl = round(_thirstVal / 0.25);
_foodLvl = round(_foodVal / 0.25);
_tempLvl = round(dayz_temperatur);
/*
diag_log format["DEBUG: bloodlvl: %1 r_player_blood: %2 bloodval: %3",_bloodLvl, r_player_blood, _bloodVal];
diag_log format["DEBUG: thirstlvl: %1 dayz_thirst: %2 thirstval: %3",_thirstLvl, dayz_thirst, _thirstVal];
diag_log format["DEBUG: foodlvl: %1 dayz_hunger: %2 foodval: %3",_foodLvl, dayz_hunger, _foodVal];
diag_log format["DEBUG: templvl: %1 dayz_temperatur: %2 tempval: %3",_tempLvl, dayz_temperatur, _tempVal];
*/
if (_bloodLvl <= 0) then {
_blood = "\z\addons\dayz_code\gui\status_epoch\status_blood_inside_1_ca.paa";
} else {
_blood = "\z\addons\dayz_code\gui\status_epoch\status_blood_inside_" + str(_bloodLvl) + "_ca.paa";
};
if (_thirstLvl < 0) then { _thirstLvl = 0 };
_thirst = "\z\addons\dayz_code\gui\status_epoch\status_thirst_inside_" + str(_thirstLvl) + "_ca.paa";
if (_foodLvl < 0) then { _foodLvl = 0 };
_food = "\z\addons\dayz_code\gui\status_epoch\status_food_inside_" + str(_foodLvl) + "_ca.paa";
switch true do {
case (_tempLvl >= 36): { _tempImg = 4 };
case (_tempLvl > 33 and _tempLvl < 36): { _tempImg = 3 };
case (_tempLvl >= 30 and _tempLvl <= 33): { _tempImg = 2 };
case (_tempLvl > 28 and _tempLvl < 30): { _tempImg = 1 };
default { _tempImg = 0 };
};
_temp = "\z\addons\dayz_code\gui\status_epoch\status_temp_" + str(_tempImg) + "_ca.paa";
_ctrlBlood ctrlSetText _blood;
_ctrlThirst ctrlSetText _thirst;
_ctrlFood ctrlSetText _food;
_ctrlTemp ctrlSetText _temp;
// Visual:
_visualtext = "";
_visual = (round((dayz_disVisual / 100) * 4)) min 5;
if (_visual > 0) then {_visualtext = "\z\addons\dayz_code\gui\status_epoch\val_" + str(_visual) + "_ca.paa"};
_ctrlEye ctrlSetText _visualtext;
// Audible
_audibletext = "";
_audible = (round((dayz_disAudial / 50) * 4)) min 5;
if (_audible > 0) then {_audibletext = "\z\addons\dayz_code\gui\status_epoch\val_" + str(_audible) + "_ca.paa"};
_ctrlEar ctrlSetText _audibletext;
// Fracture/Broken Legs
if (!(canStand player) and !(ctrlShown _ctrlFracture)) then {
_ctrlFracture ctrlShow true;
}
else {
_ctrlFracture ctrlShow false;
};
// Flashing
if (_combatVal == 0) then {
_ctrlCombat call _flash;
} else {
if (!ctrlShown _ctrlCombat) then {
_ctrlCombat ctrlShow true;
};
};
if (_bloodVal < 0.4) then {
_ctrlBlood call _flash;
} else {
if (!ctrlShown _ctrlBlood) then {
_ctrlBlood ctrlShow true;
};
};
if (_thirstVal < 0.2) then {
_ctrlThirst call _flash;
} else {
if (!ctrlShown _ctrlThirst) then {
_ctrlThirst ctrlShow true;
};
};
if (_foodVal < 0.2) then {
_ctrlFood call _flash;
} else {
if (!ctrlShown _ctrlFood) then {
_ctrlFood ctrlShow true;
};
};
if (_tempVal > 0.8) then { //TeeChange
_ctrlTemp call _flash;
} else {
if (!ctrlShown _ctrlTemp) then {
_ctrlTemp ctrlShow true;
};
};
if (r_player_injured) then {
_ctrlBleed call _flash;
}
else {
_ctrlBleed ctrlShow false;
};
/*
Opt-in tag system with friend tagging
*/
_string = "";
_humanityTarget = cursorTarget;
if (!isNull _humanityTarget && {isPlayer _humanityTarget} && {alive _humanityTarget}) then {
_distance = player distance _humanityTarget;
if (_distance < DZE_HumanityTargetDistance) then {
_size = (1-(floor(_distance/5)*0.1)) max 0.1;
// Display name if player opt-in or if friend
_friendlies = player getVariable ["friendlies", []];
_charID = player getVariable ["CharacterID", "0"];
_rcharID = _humanityTarget getVariable ["CharacterID", "0"];
_rfriendlies = _humanityTarget getVariable ["friendlies", []];
_rfriendlyTo = _humanityTarget getVariable ["friendlyTo", []];
if ((_rcharID in _friendlies) && (_charID in _rfriendlies)) then {
if !(_charID in _rfriendlyTo) then {
// diag_log format["IS FRIENDLY: %1", _player];
_rfriendlyTo set [count _rfriendlyTo, _charID];
_humanityTarget setVariable ["friendlyTo", _rfriendlyTo, true];
};
// <br /><t %2 align='center' size='0.7'>Humanity: %3</t>
_color = "color='#339933'";
_string = format["<t %2 align='center' size='%3'>%1</t>",(name _humanityTarget),_color,_size];
} else {
// Humanity checks
_humanity = _humanityTarget getVariable ["humanity",0];
_color = "color='#ffffff'";
if(_humanity < -5000) then {
_color = "color='#ff0000'";
} else {
if(_humanity > 5000) then {
_color = "color='#3333ff'";
};
};
if((_humanityTarget getVariable ["DZE_display_name", false]) || (DZE_ForceNameTagsInTrader && isInTraderCity)) then {
_string = format["<t %2 align='center' size='%3'>%1</t>",(name _humanityTarget),_color,_size];
};
};
};
};
// update gui if changed
if (dayz_humanitytarget != _string) then {
_targetControl = _display displayCtrl 1199;
_targetControl ctrlSetStructuredText (parseText _string);
dayz_humanitytarget = _string;
};
_array = [_foodVal,_thirstVal];
_array

View File

@@ -3,7 +3,11 @@ disableSerialization;
// Hard code the GUI on and the Debug Monitor off
if (dayzState != 0) then {
if (toLower DZE_UI == "vanilla") then {
3 cutRsc ["playerStatusGUI", "PLAIN",0];
} else {
3 cutRsc ["playerStatusGUI_epoch", "PLAIN",0];
};
//Update GUI
call player_updateGui;
call ui_initDisplay;

View File

@@ -1,13 +1,17 @@
#include "Configs\basicDefines.hpp"
#include "Configs\CfgNonAIVehicles.hpp"
#include "Configs\CfgNonAIVehicles.hpp" //Axeman lights
class CfgPatches {
class dayz_code {
class CfgPatches
{
class dayz_code
{
units[] = {};
weapons[] = {};
requiredVersion = 0.1;
requiredAddons[] = {
requiredAddons[] =
{
"map_eu",
//dayz_anim references all CA addons
"dayz_anim",
@@ -33,26 +37,21 @@ class CfgPatches {
"usec_ch53"
};
};
class DZ_DebriefingRemoved
{
units[] = {};
weapons[] = {};
requiredVersion = 0.1;
requiredAddons[] = {"CAUI"};
};
};
class CfgMods
{
class DayZ
{
dir = "@DayZ_Epoch";
dir = "DayZ_Epoch";
name = "DayZ Epoch";
picture = "z\addons\dayz_code\gui\loadingscreen.paa";
hidePicture = 0;
hideName = 0;
action = "http://www.dayzepoch.com";
version = "1.0.6";
hiveVersion = 0.96; //0.93
hiveVersion = 0.96;
//requiredAddons[] = {"Chernarus"}; // No need to load for other maps
};
};

View File

@@ -24,9 +24,11 @@ DZE_HaloJump = true; // Enable halo jumping out of air vehicles above 400m
DZE_NameTags = 1; // Name displays when looking at player up close 0 = Off, 1= On, 2 = Player choice
DZE_ForceNameTagsInTrader = false; // Force name display when looking at player up close in traders. Overrides player choice.
DZE_HumanityTargetDistance = 25; // Distance to show name tags (red for bandit, blue for hero, green for friend)
DZE_HeartBeat = false; // Enable heartbeat sound when looking at bandit (<= -3000 humanity) up close
DZE_HeliLift = true; // Enable Epoch heli lift system
DZE_PlayerZed = false; // Enable spawning as a player zombie when players die with infected status
DZE_R3F_WEIGHT = false; // Enable R3F weight. Players carrying too much will be overburdened and knocked out.
DZE_UI = "vanilla"; //"vanilla","epoch","dark" UI status icons style. Dark accommodates color blind people.
MaxAmmoBoxes = 3; // Max number of random Supply_Crate_DZE to spawn around the map
MaxMineVeins = 50; // Max number of random mine veins to spawn around the map
timezoneswitch = 0; // Changes murderMenu times with this offset in hours.

Binary file not shown.

Binary file not shown.

Some files were not shown because too many files have changed in this diff Show More