Scinester Posted March 5, 2015 Report Share Posted March 5, 2015 Hello, i am trying to figure out why the hud for single currency doesnt work for me, everything else works with the script besides that. I will post what all the files look like. Playerhud.sqf/* Author : AsReMixhud Edited By : Peter Beer */ disableSerialization; AsReMixhud_Control = true; while {true} do { 1000 cutRsc ["AsReMixhud","PLAIN"]; _wpui = uiNameSpace getVariable "AsReMixhud"; _vitals = _wpui displayCtrl 4900; _Player = player; ZombieKills = _Player getVariable["zombieKills",0]; Money = _Player getVariable["headShots",0]; Hero_Kills = _Player getVariable["humanKills",0]; Bank_Balance = _Player getVariable["bank",0]; Bandit_Kills = _Player getVariable["banditKills",0]; Humanity = _Player getVariable["humanity",0]; Blood = _Player getVariable["USEC_BloodQty",12000]; Fps = (round diag_fps); _stime = 0; if(serverTime > 36000)then{_stime = time;}else{_stime = serverTime;}; _hours = (_stime/60/60); _hours = toArray (str _hours); _hours resize 1; _hours = toString _hours; _hours = compile _hours; _hours = call _hours; _minutes = floor(_stime/60); _minutes2 = ((_minutes - (_hours*60)) min 60) max 0;if (_minutes2 < 10) then {_minutes2 = format ['0%1',_minutes2];}; if(Humanity >= 5000) then { Humanity_Icon = ""; }; if((Humanity >= 200) && (Humanity <= 4999)) then { Humanity_Icon = ""; }; if(Humanity <= 199) then { Humanity_Icon = ""; }; _vitals ctrlSetStructuredText parseText format [" <t size='0.8' align='right'>~~~~~ Stats ~~~~~</t><br/> <t size='0.9'> %1 </t><img size='0.9' align='right' image='ZSC\icons\Health.paa'/><br/> <t size='0.9'> %2 %3 </t><br/> <t size='0.9'> £%4 </t><img size='0.9' align='right' image='ZSC\icons\Money.paa'/><br/> <t size='0.9'> £%5 </t><img size='0.9' align='right' image='ZSC\icons\Bank.paa'/><br/> <t size='0.9'> %6 </t><img size='0.9' align='right' image='ZSC\icons\HeroKills.paa'/><br/> <t size='0.9'> %7 </t><img size='0.9' align='right' image='ZSC\icons\BanditKills.paa'/><br/> <t size='0.9'> %8 </t><img size='0.9' align='right' image='ZSC\icons\ZombieKills.paa'/><br/> <t size='0.9'> %9h %10min </t><img size='0.9' align='right' image='ZSC\icons\Uptime.paa'/><br/> <t size='0.9'> %11 </t><img size='0.9' align='right' image='ZSC\icons\Fps.paa'/><br/> <t size='0.8' align='right'>~~~~~~~~~~~~~~~~~</t><br/>", ", Blood, [Humanity] call BIS_fnc_numberText, Humanity_Icon, [Money] call BIS_fnc_numberText, [bank_Balance] call BIS_fnc_numberText, Hero_Kills, Bandit_Kills, Zombiekills, _hours, _minutes2, Fps ]; _vitals ctrlCommit 0; sleep 1.5; }; Description.ext #include "ZSC\config\cfgServerTrader.hpp" respawn = "BASE"; respawndelay = 5; onLoadMission="DayZ_Epoch Taviana"; OnLoadIntro = "Welcome to Taviana"; OnLoadIntroTime = False; OnLoadMissionTime = False; disabledAI = true; disableChannels[]={0,2,6}; enableItemsDropping=0; #include "custom\custom_loot\Configs\CfgBuildingLoot.hpp" #include "custom\custom_loot\Configs\CfgLootSmall.hpp" #include "custom\custom_loot\Configs\CfgLoot.hpp" briefing = 0; debriefing = 0; onPauseScript = "custom\fixes\conn_check.sqf"; loadScreen = ""; class Header { gameType = COOP; //DM, Team, Coop, ... minPlayers = 1; //min # of players the mission supports maxPlayers = 100; //Max # of players the mission supports }; aiKills = 1; diagRadio = 1; diagHit = 1; class RscText { type = 0; idc = -1; x = 0; y = 0; h = 0.037; w = 0.3; style = 0x100; font = Zeppelin32; SizeEx = 0.03921; colorText[] = {1,1,1,1}; colorBackground[] = {0, 0, 0, 0}; linespacing = 1; }; class HW_RscText { idc = -1; type = CT_STATIC; style = ST_CENTER; text = ""; font = "Zeppelin32"; sizeEx = 0.023; colorBackground[] = { 1, 1, 1, 0.3 }; colorText[] = { 0, 0, 0, 1 }; x = 0.8; y = 0.1; w = 0.2; h = 0.05; }; class RscPicture { access=0; type=0; idc=-1; style=48; colorBackground[]={0,0,0,0}; colorText[]={1,1,1,1}; font="TahomaB"; sizeEx=0; lineSpacing=0; text=""; }; class RscLoadingText : RscText { style = 2; x = 0.323532; y = 0.666672; w = 0.352944; h = 0.039216; sizeEx = 0.03921; colorText[] = {0.543,0.5742,0.4102,1.0}; }; class RscProgress { x = 0.344; y = 0.619; w = 0.313726; h = 0.0261438; texture = "\ca\ui\data\loadscreen_progressbar_ca.paa"; colorFrame[] = {0,0,0,0}; colorBar[] = {1,1,1,1}; }; class RscProgressNotFreeze { idc = -1; type = 45; style = 0; x = 0.022059; y = 0.911772; w = 0.029412; h = 0.039216; texture = "#(argb,8,8,3)color(0,0,0,0)"; }; // // the loading screen itself // class DayZ_loadingScreen { idd = -1; duration = 10e10; fadein = 0; fadeout = 0; name = "loading screen"; class controlsBackground { class blackBG : RscText { x = safezoneX; y = safezoneY; w = safezoneW; h = safezoneH; text = ""; colorText[] = {0,0,0,0}; colorBackground[] = {0,0,0,1}; }; /* class nicePic : RscPicture { style = 48 + 0x800; // ST_PICTURE + ST_KEEP_ASPECT_RATIO x = safezoneX + safezoneW/2 - 0.25; y = safezoneY + safezoneH/2 - 0.2; w = 0.5; h = 0.4; text = "img\nicePic.paa"; }; */ }; class controls { class Title1 : RscLoadingText { text = "$STR_LOADING"; // "Loading" text in the middle of the screen }; class CA_Progress : RscProgress // progress bar, has to have idc 104 { idc = 104; type = 8; // CT_PROGRESS style = 0; // ST_SINGLE texture = "\ca\ui\data\loadscreen_progressbar_ca.paa"; }; class CA_Progress2 : RscProgressNotFreeze // progress bar that will go reverse { idc = 103; }; class Name2: RscText // the text on the top-left { idc = 101; x = 0.05; y = 0.029412; w = 0.9; h = 0.04902; text = ""; sizeEx = 0.05; colorText[] = {0.543,0.5742,0.4102,1.0}; }; }; }; class RscTextNS { idc = -1; type = 0; style = 2; LineSpacing = 1.0; h = 0.04; ColorBackground[] = {1,1,1,0.2}; ColorText[] = {0.1,0.1,0.1,1}; font = "BitStream"; SizeEx = 0.025; }; #include "custom\dzgm\defines.hpp" #include "custom\snap_pro\snappoints.hpp" #include "custom\dzgm\groupManagement.hpp" class RscPictureGUI { access = 0; type = 0; idc = -1; colorBackground[] = {0,0,0,0}; colorText[] = {0.38,0.63,0.26,0.75}; font = "TahomaB"; sizeEx = 0; lineSpacing = 0; text = ""; style = "0x30 + 0x100"; x = 0; y = 0; w = 0.2; h = 0.15; }; class RscTextGUIK { type = 0; idc = -1; style = 0x02; colorBackground[] = {0,0,0,0}; colorText[] = {1, 1, 1, 0.5}; //color[] = {1, 1, 1, 0.5}; font = "TahomaB"; size = 0.03; sizeEx = 0.03; x = 0; y = 0; w = 0.1; h = 0.2; }; class RscTitles { #include "ZSC\config\ZSChud.hpp" #include "ZSC\hud.hpp" }; #include "ZSC\commonhud.hpp" // Epoch Admin Tools #include "admintools\dialog.hpp" #include "ZSC\config\ZSCdefines.hpp" #include "ZSC\config\ZSCdialogs.hpp" Init.sqf: /* For DayZ Epoch Addons Credits: Jetski Yanahui by Kol9yN, Zakat, Gerasimow9, YuraPetrov, zGuba, A.Karagod, IceBreakr, Sahbazz */ startLoadingScreen ["","RscDisplayLoadCustom"]; cutText ["","BLACK OUT"]; enableSaving [false, false]; //REALLY IMPORTANT VALUES dayZ_instance = 13; //The instance dayzHiveRequest = []; initialized = false; dayz_previousID = 0; //disable greeting menu player setVariable ["BIS_noCoreConversations", true]; //disable radio messages to be heard and shown in the left lower corner of the screen enableRadio false; // May prevent "how are you civillian?" messages from NPC enableSentences false; // DayZ Epoch config spawnShoremode = 1; // Default = 1 (on shore) spawnArea = 2500; // Default = 1500 MaxVehicleLimit = 100; // Default = 50 MaxDynamicDebris = 0; // Default = 100 dayz_MapArea = 20000; // Default = 10000 /*ZSC*/ DZE_ConfigTrader = true; /*ZSC*/ EpochEvents = [["any","any","any","any",30,"crash_spawner"],["any","any","any","any",0,"crash_spawner"],["any","any","any","any",15,"supply_drop"]]; dayz_fullMoonNights = true; dayz_minpos = -26000; dayz_maxpos = 26000; dayz_sellDistance_vehicle = 10; dayz_sellDistance_boat = 30; dayz_sellDistance_air = 40; dayz_paraSpawn = false; dayz_maxAnimals = 0; // Default: 8 dayz_tameDogs = false; DynamicVehicleDamageLow = 0; // Default: 0 DynamicVehicleDamageHigh = 100; // Default: 100 DZE_BuildOnRoads = false; // Default: False DZE_MissionLootTable = true; DZE_ForceNameTagsInTrader = true; DZE_R3F_WEIGHT = false; DZE_StaticConstructionCount = 1; DZE_requireplot = 0; DZE_BuildingLimit = 700; //BuildingLimit DZE_APlotforLife = true; DZE_PlotOwnership = true; DZE_modularBuild = true; // DZEdebug = true; //Load in compiled functions call compile preprocessFileLineNumbers "custom\A_Plot_for_Life\Init\variables.sqf"; //Initilize the Variables (IMPORTANT: Must happen very early) progressLoadingScreen 0.1; call compile preprocessFileLineNumbers "custom\A_Plot_for_Life\Init\publicEH.sqf"; //Initilize the publicVariable event handlers progressLoadingScreen 0.2; call compile preprocessFileLineNumbers "\z\addons\dayz_code\medical\setup_functions_med.sqf"; //Functions used by CLIENT for medical progressLoadingScreen 0.4; call compile preprocessFileLineNumbers "custom\A_Plot_for_Life\Init\compiles.sqf"; //Compile custom compiles /*ZSC*/ call compile preprocessFileLineNumbers "ZSC\gold\ZSCinit.sqf"; /*ZSC*/ progressLoadingScreen 0.5; call compile preprocessFileLineNumbers "server_traders_tavi_13.sqf"; //Compile trader configs call compile preprocessFileLineNumbers "admintools\AdminList.sqf"; // Epoch admin Tools variables/UIDs progressLoadingScreen 1.0; "filmic" setToneMappingParams [0.153, 0.357, 0.231, 0.1573, 0.011, 3.750, 6, 4]; setToneMapping "Filmic"; if (isServer) then { call compile preprocessFileLineNumbers "\z\addons\dayz_server\missions\DayZ_Epoch_13.Tavi\dynamic_vehicle.sqf"; //Compile vehicle configs call compile preprocessFileLineNumbers "\z\addons\dayz_code\init\variables.sqf"; call compile preprocessFileLineNumbers "\z\addons\dayz_code\init\compiles.sqf"; // Add trader citys _nil = [] execVM "\z\addons\dayz_server\missions\DayZ_Epoch_13.Tavi\mission.sqf"; _serverMonitor = [] execVM "\z\addons\dayz_server\system\server_monitor.sqf"; //Map //execVM "custom\map\map.sqf"; }; if (!isDedicated) then { //Conduct map operations 0 fadeSound 0; waitUntil {!isNil "dayz_loadScreenMsg"}; dayz_loadScreenMsg = (localize "STR_AUTHENTICATING"); //Custom Loadouts [] ExecVM "custom\spawn\loadout.sqf"; //Run the player monitor _id = player addEventHandler ["Respawn", {_id = [] spawn player_death;}]; _playerMonitor = [] execVM "\z\addons\dayz_code\system\player_monitor.sqf"; execVM "ZSC\compiles\playerHud.sqf"; //Group Management execVM "custom\dzgm\init.sqf"; //Lights //[false,12] execVM "\z\addons\dayz_code\compile\local_lights_init.sqf"; //auto refuel/ repair execVM "custom\service_point\service_point.sqf"; }; #include "\z\addons\dayz_code\system\BIS_Effects\init.sqf" [] execVM "custom\actionMenu\actionmenu_activate.sqf"; //WPD's Action Menu [] execVM 'custom\trader\SafeZone.sqf'; [] execVM "admintools\Activate.sqf"; // Epoch admin tools setTerrainGrid 50; //Disable Grass Hud.hpp: /* Author : AsReMixhud Edited By : Peter Beer Credit : AsReMixhud,Zupa */ #define hud_status_idc 4900 class AsReMixhud { idd = -1; fadeout=0; fadein=0; duration = 20; name= "AsReMixhud"; onLoad = "uiNamespace setVariable ['AsReMixhud', _this select 0]"; class controlsBackground { class AsReMixhud_Status:Hw_RscText { idc = hud_status_idc; type = CT_STRUCTURED_TEXT; size = 0.040; x = safezoneX + (safezoneW -0.35); y = safezoneY + 0.05 * safezoneW; w = 0.35; h = 0.60; colorText[] = {1,1,1,1}; lineSpacing = 3; colorBackground[] = {0,0,0,0}; text = ""; shadow = 2; class Attributes { align = "right"; }; }; }; }; Link to comment Share on other sites More sharing options...
mickeyknox Posted March 5, 2015 Report Share Posted March 5, 2015 This should work, replace this in your playerhud /* Author : AsReMixhud Edited By : Peter Beer */ disableSerialization; AsReMixhud_Control = true; while {true} do { 1000 cutRsc ["AsReMixhud","PLAIN"]; _wpui = uiNameSpace getVariable "AsReMixhud"; _vitals = _wpui displayCtrl 4900; _Player = player; ZombieKills = _Player getVariable["zombieKills",0]; Money = _Player getVariable["headShots",0]; Hero_Kills = _Player getVariable["humanKills",0]; Bank_Balance = _Player getVariable["bank",0]; Bandit_Kills = _Player getVariable["banditKills",0]; Humanity = _Player getVariable["humanity",0]; Blood = _Player getVariable["USEC_BloodQty",12000]; Fps = (round diag_fps); _stime = 0; if(serverTime > 36000)then{_stime = time;}else{_stime = serverTime;}; _hours = (_stime/60/60); _hours = toArray (str _hours); _hours resize 1; _hours = toString _hours; _hours = compile _hours; _hours = call _hours; _minutes = floor(_stime/60); _minutes2 = ((_minutes - (_hours*60)) min 60) max 0;if (_minutes2 < 10) then {_minutes2 = format ['0%1',_minutes2];}; if(Humanity >= 5000) then { Humanity_Icon = ""; }; if((Humanity >= 200) && (Humanity <= 4999)) then { Humanity_Icon = ""; }; if(Humanity <= 199) then { Humanity_Icon = ""; }; _vitals ctrlSetStructuredText parseText format [" <t size='0.8' align='right'>~~~~~ Stats ~~~~~</t><br/> <t size='0.9'> %1 </t><img size='0.9' align='right' image='ZSC\icons\Health.paa'/><br/> <t size='0.9'> %2 %3 </t><br/> <t size='0.9'> £%4 </t><img size='0.9' align='right' image='ZSC\icons\Money.paa'/><br/> <t size='0.9'> £%5 </t><img size='0.9' align='right' image='ZSC\icons\Bank.paa'/><br/> <t size='0.9'> %6 </t><img size='0.9' align='right' image='ZSC\icons\HeroKills.paa'/><br/> <t size='0.9'> %7 </t><img size='0.9' align='right' image='ZSC\icons\BanditKills.paa'/><br/> <t size='0.9'> %8 </t><img size='0.9' align='right' image='ZSC\icons\ZombieKills.paa'/><br/> <t size='0.9'> %9h %10min </t><img size='0.9' align='right' image='ZSC\icons\Uptime.paa'/><br/> <t size='0.9'> %11 </t><img size='0.9' align='right' image='ZSC\icons\Fps.paa'/><br/> <t size='0.8' align='right'>~~~~~~~~~~~~~~~~~</t><br/>", Blood, [Humanity] call BIS_fnc_numberText, Humanity_Icon, [Money] call BIS_fnc_numberText, [Bank_Balance] call BIS_fnc_numberText, Hero_Kills, Bandit_Kills, Zombiekills, _hours, _minutes2, Fps ]; _vitals ctrlCommit 0; sleep 1.5; }; Link to comment Share on other sites More sharing options...
Scinester Posted March 5, 2015 Author Report Share Posted March 5, 2015 Hey thanks man, I am actually away from my pc for 4 days so I will try that out when I get back and will contact you if that doesn't fix my issue. Link to comment Share on other sites More sharing options...
Scinester Posted March 8, 2015 Author Report Share Posted March 8, 2015 Hey, i tried this and not working..do i need any of his older scripts for this to work? Like i only downloaded the global storage, do i need the banking one as well? Link to comment Share on other sites More sharing options...
Recommended Posts
Please sign in to comment
You will be able to leave a comment after signing in
Sign In Now