Add files via upload

This commit is contained in:
cruzadernl 2017-10-28 12:31:48 +02:00 committed by GitHub
parent 63b5b8d6a1
commit e70b05fd9c
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
13 changed files with 128 additions and 0 deletions

7
description.ext Normal file
View File

@ -0,0 +1,7 @@
class RscTitles
{
#include "addons\status_bar\dialog\statusBar.hpp"
};

15
init.sqf Normal file
View File

@ -0,0 +1,15 @@
// Status Bar
[] execVM "addons\status_bar\fn_statusBar.sqf";

View File

@ -0,0 +1,56 @@
#define ST_RIGHT 0x01
class osefStatusBar {
idd = -1;
onLoad = "uiNamespace setVariable ['osefStatusBar', _this select 0]";
onUnload = "uiNamespace setVariable ['osefStatusBar', objNull]";
onDestroy = "uiNamespace setVariable ['osefStatusBar', objNull]";
fadein = 0;
fadeout = 0;
duration = 10e10;
movingEnable = 0;
objects[] = {};
class controlsBackground
{
class statusBarImage
{
idc = 55557;
type = 0;
style = 48;
x = safezoneX + safezoneW - 0.913;
y = safezoneY + safezoneH - 0.077; //0.068
w = 1.35;
h = 0.08; //0.06
colorText[] = {1, 1, 1, 1};
colorBackground[]={0,0,0,0};
sizeEx = 0.4;
font = "PuristaSemibold";
text = "addons\status_bar\StatusBarBackground.paa";
};
};
class controls
{
class statusBarText
{
idc = 1000;
x = safezoneX + safezoneW - 1.08;
y = safezoneY + safezoneH - 0.060;
w = 1.35;
h = 0.06;
shadow = 2;
font = "PuristaSemibold";
size = 0.035;
type = 13;
style = 2;
text = " ";
class Attributes {
align = "center";
color = "#fffae2";
font = "PuristaSemibold";
};
};
};
};

View File

@ -0,0 +1,50 @@
waitUntil {!(isNull (findDisplay 46))};
disableSerialization;
_rscLayer = "osefStatusBar" call BIS_fnc_rscLayer;
_rscLayer cutRsc["osefStatusBar","PLAIN"];
[] spawn {
sleep 5;
_counter = 180;
_timeSinceLastUpdate = 0;
while {true} do
{
sleep 1;
_counter = _counter - 1;
_time = (round(300-(serverTime)/60)); //edit the '240' (60*4=240) to change the countdown timer if your server restarts are shorter or longer than 4 hour intervals
_hours = (floor(_time/60));
_minutes = (_time - (_hours * 60));
_damage = round ((1 - (damage player)) * 100);
_thirst = round((EPOCH_playerThirst/2500) * 100);
_hunger = round((EPOCH_playerHunger/5000) * 100);
switch(_minutes) do
{
case 9: {_minutes = "09"};
case 8: {_minutes = "08"};
case 7: {_minutes = "07"};
case 6: {_minutes = "06"};
case 5: {_minutes = "05"};
case 4: {_minutes = "04"};
case 3: {_minutes = "03"};
case 2: {_minutes = "02"};
case 1: {_minutes = "01"};
case 0: {_minutes = "00"};
};
((uiNamespace getVariable "osefStatusBar")displayCtrl 1000)ctrlSetStructuredText parseText format
["
<t shadow='1' shadowColor='#000000'><img size='1.0' shadowColor='#000000' image='addons\status_bar\icons\fps.paa'/> %1</t>
<t shadow='1' shadowColor='#000000'><img size='1.6' shadowColor='#000000' image='addons\status_bar\icons\hunger.paa'/> %2</t>
<t shadow='1' shadowColor='#000000'><img size='1.6' shadowColor='#000000' image='addons\status_bar\icons\thirst.paa'/> %3</t>
<t shadow='1' shadowColor='#000000'><img size='1.0' shadowColor='#000000' image='addons\status_bar\icons\health.paa'/> %4</t>
<t shadow='1' shadowColor='#000000'><img size='1.0' shadowColor='#000000' image='addons\status_bar\icons\biohazard.paa'/> %5</t>
<t shadow='1' shadowColor='#000000'><img size='1.0' shadowColor='#000000' image='addons\status_bar\icons\nuclear.paa'/> %6</t>
<t shadow='1' shadowColor='#000000'><img size='1.0' shadowColor='#000000' image='addons\status_bar\icons\money.paa'/> %7</t>
<t shadow='1' shadowColor='#000000'><img size='1.6' shadowColor='#000000' image='addons\status_bar\icons\restart.paa'/>%8:%9</t>",
round diag_fps, _hunger, _thirst, _damage, EPOCH_playerToxicity, EPOCH_playerRadiation, EPOCH_playerCrypto, _hours, _minutes, _counter];
};
};

Binary file not shown.

BIN
status_bar/icons/fps.paa Normal file

Binary file not shown.

BIN
status_bar/icons/health.paa Normal file

Binary file not shown.

BIN
status_bar/icons/hunger.paa Normal file

Binary file not shown.

BIN
status_bar/icons/money.paa Normal file

Binary file not shown.

Binary file not shown.

Binary file not shown.

BIN
status_bar/icons/thirst.paa Normal file

Binary file not shown.

Binary file not shown.