diff --git a/SQF/dayz_code/Configs/CfgArma.hpp b/SQF/dayz_code/Configs/CfgArma.hpp
index caf824889..623343b72 100644
--- a/SQF/dayz_code/Configs/CfgArma.hpp
+++ b/SQF/dayz_code/Configs/CfgArma.hpp
@@ -266,6 +266,171 @@ class CfgInGameUI
};
};
};
+ // Hide group hotbar
+ class CommandBar {
+ left = "-0.032 + SafeZoneX";
+ top = "(SafeZoneH + SafeZoneY) - (1 - 0.851)";
+ width = 0;
+ height = 0;
+ imageDefaultWeapons = "ca\ui\data\clear_empty.paa";
+ imageNoWeapons = "ca\ui\data\clear_empty.paa";
+ imageCommander = "ca\ui\data\clear_empty.paa";
+ imageDriver = "ca\ui\data\clear_empty.paa";
+ imageGunner = "ca\ui\data\clear_empty.paa";
+ imageCargo = "ca\ui\data\clear_empty.paa";
+ dimm = 0.3;
+ colorRedTeam[] = {0,0,0,0};
+ colorBlueTeam[] = {0,0,0,0};
+ colorGreenTeam[] = {0,0,0,0};
+ colorYellowTeam[] = {0,0,0,0};
+ colorWhiteTeam[] = {0,0,0,0};
+ class prevPage {
+ x = 0;
+ y = 0;
+ w = 0;
+ h = 0;
+ color[] = {0,0,0,0};
+ texture = "ca\ui\data\clear_empty.paa";
+ };
+ class nextPage {
+ x = 0;
+ y = 0;
+ w = 0;
+ h = 0;
+ color[] = {0,0,0,0};
+ texture = "ca\ui\data\clear_empty.paa";
+ };
+ class UnitInfo {
+ class GroupIcon {
+ x = 0;
+ y = 0;
+ w = 0;
+ h = 0;
+ };
+ class HcGroupText {
+ x = 0;
+ y = 0;
+ w = 0;
+ h = 0;
+ font = "Zeppelin32";
+ SizeEx = 0;
+ };
+ class UnitBackground {
+ x = 0;
+ y = 0;
+ w = 0;
+ h = 0;
+ textureNormal = "ca\ui\data\clear_empty.paa";
+ textureSelected = "ca\ui\data\clear_empty.paa";
+ texturePlayer = "ca\ui\data\clear_empty.paa";
+ textureFocus = "ca\ui\data\clear_empty.paa";
+ };
+ class UnitFocus {
+ x = 0;
+ y = 0;
+ w = 0;
+ h = 0;
+ color[] = {0,0,0,0};
+ texture = "ca\ui\data\clear_empty.paa";
+ };
+ class UnitIcon {
+ x = 0;
+ y = 0;
+ w = 0;
+ h = 0;
+ color[] = {0,0,0,0};
+ colorPlayer[] = {0,0,0,0};
+ colorNoAmmo[] = {0,0,0,0};
+ colorWounded[] = {0,0,0,0};
+ colorWoundedFade[] = {0,0,0,0};
+ colorNoFuel[] = {0,0,0,0};
+ };
+ class Semaphore {
+ x = 0;
+ y = 0;
+ w = 0;
+ h = 0;
+ color[] = {0,0,0,0};
+ texture = "ca\ui\data\clear_empty.paa";
+ };
+ class CommandBackground {
+ x = 0;
+ y = 0;
+ w = 0;
+ h = 0;
+ color[] = {0,0,0,0};
+ texture = "ca\ui\data\clear_empty.paa";
+ };
+ class CommandText {
+ x = 0;
+ y = 0;
+ w = 0;
+ h = 0;
+ color[] = {0,0,0,0};
+ font = "Zeppelin32";
+ SizeEx = 0;
+ };
+ class UnitSpecialRole {
+ x = 0;
+ y = 0;
+ w = 0;
+ h = 0;
+ color[] = {0,0,0,0};
+ };
+ class VehicleNumberBackground {
+ x = 0;
+ y = 0;
+ w = 0;
+ h = 0;
+ color[] = {0,0,0,0};
+ texture = "ca\ui\data\clear_empty.paa";
+ };
+ class VehicleNumberText {
+ x = 0;
+ y = 0;
+ w = 0;
+ h = 0;
+ colorText[] = {0,0,0,0};
+ font = "Zeppelin32";
+ SizeEx = 0;
+ };
+ class UnitRole {
+ x = 0;
+ y = 0;
+ w = 0;
+ h = 0;
+ color[] = {0,0,0,0};
+ };
+ class UnitNumberBackground {
+ x = 0;
+ y = 0;
+ w = 0;
+ h = 0;
+ color[] = {0,0,0,0};
+ texture = "ca\ui\data\clear_empty.paa";
+ };
+ class UnitNumberText {
+ x = 0;
+ y = 0;
+ w = 0;
+ h = 0;
+ colorText[] = {0,0,0,0};
+ font = "Zeppelin32";
+ SizeEx = 0;
+ };
+ class CombatMode {
+ x = 0;
+ y = 0;
+ w = 0;
+ h = 0;
+ textureMCareless = "ca\ui\data\clear_empty.paa";
+ textureMSafe = "ca\ui\data\clear_empty.paa";
+ textureMAware = "ca\ui\data\clear_empty.paa";
+ textureMCombat = "ca\ui\data\clear_empty.paa";
+ textureMStealth = "ca\ui\data\clear_empty.paa";
+ };
+ };
+ };
};
class CfgVoice {
diff --git a/SQF/dayz_code/Configs/CfgWeapons/CfgWeapons.hpp b/SQF/dayz_code/Configs/CfgWeapons/CfgWeapons.hpp
index 88b6dae5e..4d010b969 100644
--- a/SQF/dayz_code/Configs/CfgWeapons/CfgWeapons.hpp
+++ b/SQF/dayz_code/Configs/CfgWeapons/CfgWeapons.hpp
@@ -259,6 +259,7 @@ class CfgWeapons
#include "Tools\Flashlight.hpp"
#include "Tools\FlashlightRed.hpp"
+ #include "Tools\Radio.hpp"
#include "Item\ItemKeyKit.hpp"
#include "Item\ItemKeys.hpp"
diff --git a/SQF/dayz_code/Configs/CfgWeapons/Tools/Radio.hpp b/SQF/dayz_code/Configs/CfgWeapons/Tools/Radio.hpp
new file mode 100644
index 000000000..780d11312
--- /dev/null
+++ b/SQF/dayz_code/Configs/CfgWeapons/Tools/Radio.hpp
@@ -0,0 +1,11 @@
+class ItemRadio : ItemCore
+{
+ class ItemActions
+ {
+ class Groups
+ {
+ text = $STR_EPOCH_GROUPS_KEY;
+ script = "spawn dayz_openGroupDialog;";
+ };
+ };
+};
\ No newline at end of file
diff --git a/SQF/dayz_code/Configs/RscDisplay/RscGroups.hpp b/SQF/dayz_code/Configs/RscDisplay/RscGroups.hpp
new file mode 100644
index 000000000..9de7b2561
--- /dev/null
+++ b/SQF/dayz_code/Configs/RscDisplay/RscGroups.hpp
@@ -0,0 +1,227 @@
+class DZ_GroupText: RscText {
+ idc = -1;
+ type = 0;
+ style = 0x00;
+ sizeEx = .025;
+ shadow = 2;
+ colorBackground[] = {1,1,1,0};
+ colorText[] = {1,1,1,1};
+};
+
+class DZ_GroupDynamicText: RscStructuredText {
+ access = 0;
+ type = 13;
+ colorText[] = {1,1,1,1};
+ class Attributes {
+ font = "Zeppelin32";
+ color = "#ffffff";
+ align = "center";
+ shadow = true;
+ };
+};
+
+class DZ_GroupListBox: RscListBox {
+ type = 5;
+ style = 69;
+ text = "";
+ colorBackground[] = {0, 0, 0, 0};
+ colorSelectBackground[] = {0, 0, 0, 1.0};
+ colorSelectBackground2[] = {0, 0, 0, 0.8};
+ colorText[] = {0.95, 0.95, 0.95, 1};
+ colorScrollbar[] = {.2, .2, .2, 1};
+ arrowEmpty = "\ca\ui\data\ui_arrow_combo_ca.paa";
+ arrowFull = "\ca\ui\data\ui_arrow_combo_active_ca.paa";
+ wholeHeight = .45;
+ rowHeight = .04;
+ colorActive[] = {0,0,0,1};
+ colorDisabled[] = {0,0,0,.3};
+ sizeEx = .023;
+ soundSelect[] = {"",.1,1};
+ soundExpand[] = {"",.1,1};
+ soundCollapse[] = {"",.1,1};
+ class ScrollBar;
+};
+
+class DZ_GroupButton: RscButton {
+ idc = -1;
+ periodFocus = 1.2;
+ periodOver = .8;
+ period = .4;
+ size = .023;
+ sizeEx = .023;
+ text = "";
+ type = 16;
+ action = "";
+ x = .317;
+ w = .14;
+ h = .05 * safezoneH;
+ color[] = {0.95, 0.95, 0.95, 1.0};
+ color2[] = {0.95, 0.95, 0.95, 1};
+ colorDisabled[] = {1, 1, 1, 0.25};
+ colorText[] = {0.95, 0.95, 0.95, 1};
+ colorBackground[] = {1, 1, 1, 1};
+ colorbackground2[] = {1, 1, 1, 0.4};
+ colorBackgroundActive[] = {0.5, 0.5, 0.5, 1};
+ colorBackgroundDisabled[] = {0.1, 0.1, 0.1, 0.5};
+ colorShadow[] = {0.95, 0.95, 0.95, 1};
+ colorBorder[] = {0.95, 0.95, 0.95, 1};
+ animTextureNormal = "\z\addons\dayz_code\gui\grey\ui_button_normal_ca.paa";
+ animTextureDisabled = "\z\addons\dayz_code\gui\grey\ui_button_disabled_ca.paa";
+ animTextureOver = "\z\addons\dayz_code\gui\grey\ui_button_over_ca.paa";
+ animTextureFocused = "\z\addons\dayz_code\gui\grey\ui_button_focus_ca.paa";
+ animTexturePressed = "\z\addons\dayz_code\gui\grey\ui_button_down_ca.paa";
+ animTextureDefault = "\z\addons\dayz_code\gui\grey\ui_button_default_ca.paa";
+ animTextureNoShortcut = "\z\addons\dayz_code\gui\grey\ui_button_normal_ca.paa";
+ textureNoShortcut = "";
+ class HitZone {
+ left = .002;
+ top = .003;
+ right = .002;
+ bottom = .016;
+ };
+ class ShortcutPos {
+ left = -.006;
+ top = -.007;
+ w = .0392157;
+ h = .0522876;
+ };
+ class TextPos {
+ left = .002;
+ top = .0325;
+ right = .002;
+ bottom = .005;
+ };
+ class Attributes {
+ font = "Zeppelin32";
+ color = "#E5E5E5";
+ align = "center";
+ shadow = "1";
+ };
+ class AttributesImage {
+ font = "Zeppelin32";
+ color = "#E5E5E5";
+ align = "left";
+ };
+};
+
+class DZ_GroupDialog {
+ idd = 80000;
+ movingEnable = 1;
+ enableSimulation = 1;
+
+ class ControlsBackground {
+ class Window {
+ idc = -1;
+ type = 0;
+ style = 48;
+ font = "Zeppelin32";
+ sizeEx = .023;
+ colorBackground[] = {};
+ colorText[] = {};
+ text = "\z\addons\dayz_code\gui\grey\ui_background_controls_ca.paa";
+ moving = 1;
+ x = .0;
+ y = .1;
+ w = 1.0;
+ h = .65;
+ };
+ class Title: DZ_GroupText {
+ text = $STR_EPOCH_GROUPS;
+ sizeEx = .04;
+ x = .35;
+ y = .112;
+ w = .3;
+ h = .05;
+ };
+ class Players: DZ_GroupText {
+ text = $STR_EPOCH_PLAYERS;
+ x = .1075;
+ y = .165;
+ w = .3;
+ h = .050;
+ };
+ class MyGroup: DZ_GroupText {
+ text = $STR_EPOCH_MY_GROUP;
+ x = .5675;
+ y = .165;
+ w = .3;
+ h = .050;
+ };
+ class Invite: DZ_GroupDynamicText {
+ idc = 9;
+ style = 0;
+ size = .025;
+ x = .2735;
+ y = .4915;
+ w = .235;
+ h = .075;
+ };
+ };
+ class controls {
+ class Players: DZ_GroupListBox {
+ idc = 1;
+ onLBSelChanged = "(_this select 0) call dayz_selectPlayer;";
+ x = .04;
+ y = .21;
+ w = .235;
+ h = .425;
+ };
+ class MyGroup: DZ_GroupListBox {
+ idc = 2;
+ onLBSelChanged = "(_this select 0) call dayz_selectGroupMember;";
+ x = .5;
+ y = .21;
+ w = .235;
+ h = .425;
+ };
+ class Close: DZ_GroupButton {
+ idc = -1;
+ text = $STR_UI_CLOSE;
+ onButtonClick = "findDisplay 80000 closeDisplay 2;";
+ x = .03;
+ y = .6525;
+ };
+ class Invite: DZ_GroupButton {
+ idc = 3;
+ text = $STR_EPOCH_INVITE;
+ onButtonClick = "(_this select 0) call dayz_inviteToGroup;";
+ y = .184;
+ };
+ class Kick: DZ_GroupButton {
+ idc = 4;
+ text = $STR_EPOCH_KICK;
+ onButtonClick = "(_this select 0) call dayz_kickFromGroup;";
+ y = .239;
+ };
+ class Disband: DZ_GroupButton {
+ idc = 5;
+ text = $STR_EPOCH_DISBAND;
+ onButtonClick = "(_this select 0) call dayz_disbandGroup;";
+ y = .294;
+ };
+ class Promote: DZ_GroupButton {
+ idc = 10;
+ text = $STR_EPOCH_PROMOTE;
+ onButtonClick = "(_this select 0) call dayz_promotePlayer;";
+ y = .349;
+ };
+ class Leave: DZ_GroupButton {
+ idc = 6;
+ text = $STR_EPOCH_LEAVE;
+ onButtonClick = "(_this select 0) call dayz_leaveGroup;";
+ y = .405;
+ };
+ class Accept: DZ_GroupButton {
+ idc = 7;
+ text = $STR_EPOCH_ACCEPT;
+ onButtonClick = "(_this select 0) call dayz_joinGroup;";
+ y = .5265;
+ };
+ class Reject: DZ_GroupButton {
+ idc = 8;
+ text = $STR_EPOCH_REJECT;
+ onButtonClick = "(_this select 0) call dayz_rejectGroup;";
+ y = .5765;
+ };
+ };
+};
\ No newline at end of file
diff --git a/SQF/dayz_code/Configs/RscDisplay/RscPlayerUI.hpp b/SQF/dayz_code/Configs/RscDisplay/RscPlayerUI.hpp
index 28921a120..03841afe2 100644
--- a/SQF/dayz_code/Configs/RscDisplay/RscPlayerUI.hpp
+++ b/SQF/dayz_code/Configs/RscDisplay/RscPlayerUI.hpp
@@ -617,4 +617,135 @@ class RscTitles
};
};
};
+ class DZ_GroupIcons
+ {
+ idd = -1;
+ movingEnable = 1;
+ enableSimulation = 1;
+ enableDisplay = 1;
+ onLoad = "uiNamespace setVariable ['DZ_GroupIcons',_this select 0];";
+ duration = 99999999999999999;
+ fadein = 0;
+ fadeout = 0;
+ class controls
+ {
+ class Icons: DZ_GroupDynamicText
+ {
+ idc = -1;
+ style = 0x00;
+ x = .9;
+ y = .9;
+ w = .9;
+ h = .9;
+ size = .08;
+ colorBackground[] = {0,0,0,0};
+ colortext[] = {0,0,0,.7};
+ class Attributes {
+ align = "left";
+ };
+ };
+ // Max 100 players per group
+ class Icon0:Icons {idc = 100;};
+ class Icon1:Icons {idc = 101;};
+ class Icon2:Icons {idc = 102;};
+ class Icon3:Icons {idc = 103;};
+ class Icon4:Icons {idc = 104;};
+ class Icon5:Icons {idc = 105;};
+ class Icon6:Icons {idc = 106;};
+ class Icon7:Icons {idc = 107;};
+ class Icon8:Icons {idc = 108;};
+ class Icon9:Icons {idc = 109;};
+ class Icon10:Icons {idc = 110;};
+ class Icon11:Icons {idc = 111;};
+ class Icon12:Icons {idc = 112;};
+ class Icon13:Icons {idc = 113;};
+ class Icon14:Icons {idc = 114;};
+ class Icon15:Icons {idc = 115;};
+ class Icon16:Icons {idc = 116;};
+ class Icon17:Icons {idc = 117;};
+ class Icon18:Icons {idc = 118;};
+ class Icon19:Icons {idc = 119;};
+ class Icon20:Icons {idc = 120;};
+ class Icon21:Icons {idc = 121;};
+ class Icon22:Icons {idc = 122;};
+ class Icon23:Icons {idc = 123;};
+ class Icon24:Icons {idc = 124;};
+ class Icon25:Icons {idc = 125;};
+ class Icon26:Icons {idc = 126;};
+ class Icon27:Icons {idc = 127;};
+ class Icon28:Icons {idc = 128;};
+ class Icon29:Icons {idc = 129;};
+ class Icon30:Icons {idc = 130;};
+ class Icon31:Icons {idc = 131;};
+ class Icon32:Icons {idc = 132;};
+ class Icon33:Icons {idc = 133;};
+ class Icon34:Icons {idc = 134;};
+ class Icon35:Icons {idc = 135;};
+ class Icon36:Icons {idc = 136;};
+ class Icon37:Icons {idc = 137;};
+ class Icon38:Icons {idc = 138;};
+ class Icon39:Icons {idc = 139;};
+ class Icon40:Icons {idc = 140;};
+ class Icon41:Icons {idc = 141;};
+ class Icon42:Icons {idc = 142;};
+ class Icon43:Icons {idc = 143;};
+ class Icon44:Icons {idc = 144;};
+ class Icon45:Icons {idc = 145;};
+ class Icon46:Icons {idc = 146;};
+ class Icon47:Icons {idc = 147;};
+ class Icon48:Icons {idc = 148;};
+ class Icon49:Icons {idc = 149;};
+ class Icon50:Icons {idc = 150;};
+ class Icon51:Icons {idc = 151;};
+ class Icon52:Icons {idc = 152;};
+ class Icon53:Icons {idc = 153;};
+ class Icon54:Icons {idc = 154;};
+ class Icon55:Icons {idc = 155;};
+ class Icon56:Icons {idc = 156;};
+ class Icon57:Icons {idc = 157;};
+ class Icon58:Icons {idc = 158;};
+ class Icon59:Icons {idc = 159;};
+ class Icon60:Icons {idc = 160;};
+ class Icon61:Icons {idc = 161;};
+ class Icon62:Icons {idc = 162;};
+ class Icon63:Icons {idc = 163;};
+ class Icon64:Icons {idc = 164;};
+ class Icon65:Icons {idc = 165;};
+ class Icon66:Icons {idc = 166;};
+ class Icon67:Icons {idc = 167;};
+ class Icon68:Icons {idc = 168;};
+ class Icon69:Icons {idc = 169;};
+ class Icon70:Icons {idc = 170;};
+ class Icon71:Icons {idc = 171;};
+ class Icon72:Icons {idc = 172;};
+ class Icon73:Icons {idc = 173;};
+ class Icon74:Icons {idc = 174;};
+ class Icon75:Icons {idc = 175;};
+ class Icon76:Icons {idc = 176;};
+ class Icon77:Icons {idc = 177;};
+ class Icon78:Icons {idc = 178;};
+ class Icon79:Icons {idc = 179;};
+ class Icon80:Icons {idc = 180;};
+ class Icon81:Icons {idc = 181;};
+ class Icon82:Icons {idc = 182;};
+ class Icon83:Icons {idc = 183;};
+ class Icon84:Icons {idc = 184;};
+ class Icon85:Icons {idc = 185;};
+ class Icon86:Icons {idc = 186;};
+ class Icon87:Icons {idc = 187;};
+ class Icon88:Icons {idc = 188;};
+ class Icon89:Icons {idc = 189;};
+ class Icon90:Icons {idc = 190;};
+ class Icon91:Icons {idc = 191;};
+ class Icon92:Icons {idc = 192;};
+ class Icon93:Icons {idc = 193;};
+ class Icon94:Icons {idc = 194;};
+ class Icon95:Icons {idc = 195;};
+ class Icon96:Icons {idc = 196;};
+ class Icon97:Icons {idc = 197;};
+ class Icon98:Icons {idc = 198;};
+ class Icon99:Icons {idc = 199;};
+ class Icon100:Icons {idc = 200;};
+ };
+ };
};
\ No newline at end of file
diff --git a/SQF/dayz_code/Configs/RscDisplay/includes.hpp b/SQF/dayz_code/Configs/RscDisplay/includes.hpp
index 3ca944188..fe732916e 100644
--- a/SQF/dayz_code/Configs/RscDisplay/includes.hpp
+++ b/SQF/dayz_code/Configs/RscDisplay/includes.hpp
@@ -1,3 +1,4 @@
+#include "RscGroups.hpp"
#include "RscDisplayCraftingMenu.hpp"
#include "RscDisplayGear.hpp"
#include "RscDisplayGenderSelect.hpp"
diff --git a/SQF/dayz_code/actions/AdvancedTrading/functions/z_at_fillCategories.sqf b/SQF/dayz_code/actions/AdvancedTrading/functions/z_at_fillCategories.sqf
index 0a0705e19..18759bbac 100644
--- a/SQF/dayz_code/actions/AdvancedTrading/functions/z_at_fillCategories.sqf
+++ b/SQF/dayz_code/actions/AdvancedTrading/functions/z_at_fillCategories.sqf
@@ -5,5 +5,5 @@ call Z_clearBuyList;
{
_index = lbAdd [Z_AT_BUYABLELIST,_x select 0];
- lbSetPicture [Z_AT_BUYABLELIST,_index,"\z\addons\dayz_code\gui\epoch\arrow_right.paa"];
+ lbSetPicture [Z_AT_BUYABLELIST,_index,"\z\addons\dayz_code\gui\grey\arrow_right.paa"];
} forEach Z_traderData;
diff --git a/SQF/dayz_code/compile/keyboard.sqf b/SQF/dayz_code/compile/keyboard.sqf
index 6846aa01e..ff50e21dc 100644
--- a/SQF/dayz_code/compile/keyboard.sqf
+++ b/SQF/dayz_code/compile/keyboard.sqf
@@ -43,6 +43,18 @@ if (isNil "keyboard_keys") then {
};
_handled = true;
};
+ _openGroups = {
+ if (dayz_requireRadio && !("ItemRadio" in items player)) then {
+ localize "STR_EPOCH_NEED_RADIO" call dayz_rollingMessages;
+ } else {
+ if (isNull findDisplay 80000) then {
+ if (!isNil "dayz_groupInit") then {[] spawn dayz_openGroupDialog;};
+ } else {
+ findDisplay 80000 closeDisplay 2;
+ };
+ };
+ _handled = true;
+ };
_muteSound = {
call player_toggleSoundMute;
_handled = true;
@@ -350,6 +362,11 @@ if (isNil "keyboard_keys") then {
DIK_F8,DIK_F7,DIK_F6,DIK_F5,DIK_F4,
DIK_F3,DIK_F2,DIK_9,
DIK_8,DIK_7,DIK_6,DIK_5,DIK_4], _block] call _addArray;
+ if (dayz_groupSystem) then {
+ [[DIK_F5], _openGroups] call _addArray;
+ [[DIK_LWIN,DIK_RWIN], {dayz_groupNameTags = !dayz_groupNameTags;_handled = true;}] call _addArray;
+ [actionKeys "TacticalView", _block] call _addArray;
+ };
diag_log "keyboard_keys reset";
if (!isNil "bis_fnc_halo_keydown_eh") then {bis_fnc_halo_keydown_eh = (finddisplay 46) displayaddeventhandler ["keydown","_this call bis_fnc_halo_keydown;"];}; // halo in progress
};
diff --git a/SQF/dayz_code/compile/player_switchModel.sqf b/SQF/dayz_code/compile/player_switchModel.sqf
index 322c023ce..45e8418b3 100644
--- a/SQF/dayz_code/compile/player_switchModel.sqf
+++ b/SQF/dayz_code/compile/player_switchModel.sqf
@@ -123,7 +123,11 @@ _switchUnit = {
removeAllWeapons _oldUnit;
{_oldUnit removeMagazine _x;} count magazines _oldUnit;
if !(isNull _oldUnit) then {deleteVehicle _oldUnit;};
- deleteGroup _oldGroup;
+ if (!isNil "dayz_groupInit" && count (units _oldGroup) > 1) then {
+ [_newUnit] join _oldGroup;
+ if (count (units _group) == 0) then {deleteGroup _group;};
+ };
+ if (count (units _oldGroup) == 0) then {deleteGroup _oldGroup;};
if (_currentWpn != "") then {_newUnit selectWeapon _currentWpn;};
};
diff --git a/SQF/dayz_code/compile/ui_selectSlot.sqf b/SQF/dayz_code/compile/ui_selectSlot.sqf
index ce3eb0b7f..ecf802374 100644
--- a/SQF/dayz_code/compile/ui_selectSlot.sqf
+++ b/SQF/dayz_code/compile/ui_selectSlot.sqf
@@ -13,7 +13,10 @@ if (_button == 1) then {
_pos = ctrlPosition _group;
_item = gearSlotData _control;
- if (!DZE_SelfTransfuse && _item in ["ItemBloodbag","wholeBloodBagANEG","wholeBloodBagAPOS","wholeBloodBagBNEG","wholeBloodBagBPOS","wholeBloodBagABNEG","wholeBloodBagABPOS","wholeBloodBagONEG","wholeBloodBagOPOS"]) exitWith {}; // No right click option on bloodbags if DZE_SelfTransfuse = false;
+ if ( //No right click action
+ (!DZE_SelfTransfuse && _item in ["ItemBloodbag","wholeBloodBagANEG","wholeBloodBagAPOS","wholeBloodBagBNEG","wholeBloodBagBPOS","wholeBloodBagABNEG","wholeBloodBagABPOS","wholeBloodBagONEG","wholeBloodBagOPOS"]) or
+ (!dayz_groupSystem && _item == "ItemRadio")
+ ) exitWith {};
if (mouseOverCarry) then {
_item = DayZ_onBack;
carryClick = true;
diff --git a/SQF/dayz_code/configVariables.sqf b/SQF/dayz_code/configVariables.sqf
index 33009926a..fdc21cd6d 100644
--- a/SQF/dayz_code/configVariables.sqf
+++ b/SQF/dayz_code/configVariables.sqf
@@ -41,7 +41,6 @@ timezoneswitch = 0; // Changes murderMenu times with this offset in hours.
DZE_SafeZonePosArray = []; //Prevent players in safeZones from being killed if their vehicle is destroyed. Format is [[[3D POS], RADIUS],[[3D POS], RADIUS]]; Ex. DZE_SafeZonePosArray = [[[6325.6772,7807.7412,0],150],[[4063.4226,11664.19,0],150]];
DZE_GemOccurance = [["ItemTopaz",10], ["ItemObsidian",8], ["ItemSapphire",6], ["ItemAmethyst",4], ["ItemEmerald",3], ["ItemCitrine",2], ["ItemRuby",1]]; //Sets how rare each gem is in the order shown when mining (whole numbers only)
DZE_GodModeBaseExclude = []; //Array of object class names excluded from the god mode bases feature
-DZE_groupManagement = false; //Enable or disable group management. Enabled by default
DZE_salvageLocked = true; //Enable or disable salvaging of locked vehicles, useful for stopping griefing on locked vehicles.
// Trader Menu
@@ -83,6 +82,12 @@ DZE_doorManagementAdmins = []; //Array of admin PlayerUIDs enclosed in quotation
DZE_doorManagementAllowManualCode = true; //Allows opening doors still using PIN
DZE_doorManagementMaxFriends = 10; //Maximum number of friends allowed on a door.
+// Group System
+dayz_groupSystem = true; // Enable group system
+dayz_markGroup = 1; // Players can see group members positions on the map 0=never, 1=always, 2=With GPS only
+dayz_markSelf = 0; // Players can see their own position on the map 0=never, 1=always, 2=With GPS only
+dayz_markBody = 0; // Players can see their corpse position on the map 0=never, 1=always, 2=With GPS only
+dayz_requireRadio = false; // Require players to have a radio on their toolbelt to create a group, be in a group and receive invites
/*
Developers:
diff --git a/SQF/dayz_code/groups/disbandGroup.sqf b/SQF/dayz_code/groups/disbandGroup.sqf
new file mode 100644
index 000000000..d24c6733f
--- /dev/null
+++ b/SQF/dayz_code/groups/disbandGroup.sqf
@@ -0,0 +1,21 @@
+private "_group";
+
+_group = group player;
+if (count (units _group) == 1 or (!isNil "dayz_groupDisbandThread" && {!scriptDone dayz_groupDisbandThread})) exitWith {
+ _this ctrlShow false;
+};
+
+dayz_groupDisbanded = nil;
+PVDZ_Server_UpdateGroup = [4,player];
+publicVariableServer "PVDZ_Server_UpdateGroup";
+
+dayz_groupDisbandThread = _group spawn {
+ //Wait for response from server to confirm group finished updating in DB
+ waitUntil {!isNil "dayz_groupDisbanded"};
+
+ {
+ [_x] join grpNull;
+ } count (units _this);
+
+ deleteGroup _this;
+};
\ No newline at end of file
diff --git a/SQF/dayz_code/groups/filterGroup.sqf b/SQF/dayz_code/groups/filterGroup.sqf
new file mode 100644
index 000000000..2bd8334d4
--- /dev/null
+++ b/SQF/dayz_code/groups/filterGroup.sqf
@@ -0,0 +1,10 @@
+private "_group";
+
+_group = [];
+{
+ if (alive _x && isPlayer _x) then {
+ _group set [count _group,_x];
+ };
+} count (units group _this);
+
+_group
\ No newline at end of file
diff --git a/SQF/dayz_code/groups/getCrew.sqf b/SQF/dayz_code/groups/getCrew.sqf
new file mode 100644
index 000000000..48eb17860
--- /dev/null
+++ b/SQF/dayz_code/groups/getCrew.sqf
@@ -0,0 +1,8 @@
+private "_crew";
+
+_crew = [];
+{
+ _crew set [count _crew, if (alive _x) then {name _x} else {"unknown"}];
+} count crew _this;
+
+format ["%1%2",typeOf _this,_crew]
\ No newline at end of file
diff --git a/SQF/dayz_code/groups/getPlayer.sqf b/SQF/dayz_code/groups/getPlayer.sqf
new file mode 100644
index 000000000..3791f7597
--- /dev/null
+++ b/SQF/dayz_code/groups/getPlayer.sqf
@@ -0,0 +1,10 @@
+private "_player";
+
+_player = objNull;
+{
+ if (getPlayerUID _x == _this) exitWith {
+ _player = _x;
+ };
+} count allUnits;
+
+_player
\ No newline at end of file
diff --git a/SQF/dayz_code/groups/groupIcons.sqf b/SQF/dayz_code/groups/groupIcons.sqf
new file mode 100644
index 000000000..66f6ab34f
--- /dev/null
+++ b/SQF/dayz_code/groups/groupIcons.sqf
@@ -0,0 +1,45 @@
+// OnEachFrame loop
+private ["_display","_distance","_group","_icon","_index","_pos","_scale","_screen","_text"];
+
+_group = player call dayz_filterGroup;
+if (!visibleMap && count _group > 1 && cameraView in ["INTERNAL","EXTERNAL","GUNNER"]) then {
+ 80000 cutRsc ["DZ_GroupIcons","PLAIN"];
+
+ _display = uiNamespace getVariable "DZ_GroupIcons";
+ _index = 0;
+ {
+ _pos = getPosATL _x;
+ if (surfaceIsWater _pos) then {_pos = getPosASL _x;};
+ _distance = _pos distance player;
+ _icon = _display displayCtrl (100 + _index);
+ if (_distance > 1 && _distance < 2500) then {
+ _pos set [2,(_pos select 2) + 1.5];
+ _screen = worldToScreen _pos;
+ _text = composeText [image "\ca\ui\data\igui_side_unknown_ca.paa"," ",if (dayz_groupNameTags) then {name _x} else {""}];
+ if (count _screen > 1) then {
+ _scale = if (_distance < 200) then {.3} else {1 min ((1 - (_distance - 3) / 15) max .3)};
+ _icon ctrlSetStructuredText _text;
+ _icon ctrlSetPosition [(_screen select 0),(_screen select 1),.99,.65];
+ _icon ctrlSetScale _scale;
+ _icon ctrlSetFade ((1 - _scale) / 2);
+ _icon ctrlCommit 0;
+ _icon ctrlShow true;
+ } else {
+ _icon ctrlShow false;
+ };
+ } else {
+ _icon ctrlShow false;
+ };
+ _index = _index + 1;
+ } count _group;
+
+ if (dayz_oldGroupCount > count _group) then {
+ _display displayCtrl (100 + _index) ctrlShow false;
+ };
+
+ dayz_oldGroupCount = count _group;
+} else {
+ if (!isNull (uiNamespace getVariable "DZ_GroupIcons")) then {
+ 80000 cutText ["","PLAIN"];
+ };
+};
\ No newline at end of file
diff --git a/SQF/dayz_code/groups/groupInvite.sqf b/SQF/dayz_code/groups/groupInvite.sqf
new file mode 100644
index 000000000..3e977f693
--- /dev/null
+++ b/SQF/dayz_code/groups/groupInvite.sqf
@@ -0,0 +1,36 @@
+private ["_add","_inviter","_recipient","_uid","_unit"];
+
+_add = _this select 0;
+_uid = _this select 1;
+
+// Update active invites on all machines with the change
+if (_add) then {
+ _inviter = _uid select 0;
+ _recipient = _uid select 1;
+ dayz_activeInvites set [count dayz_activeInvites,_uid];
+ if (!isDedicated && {_recipient == getPlayerUID player} && {!dayz_requireRadio or {dayz_requireRadio && "ItemRadio" in items player}}) then {
+ localize "STR_EPOCH_INVITE_NEW" call dayz_rollingMessages;
+ };
+} else {
+ // Remove all invites to this player
+ _inviter = "0";
+ _recipient = _uid;
+ {
+ if (_recipient == _x select 1) then {
+ dayz_activeInvites set [_forEachIndex,"delete"];
+ };
+ } forEach dayz_activeInvites;
+ dayz_activeInvites = dayz_activeInvites - ["delete"];
+};
+
+// Send change to all active clients except the originator (they already updated themself)
+if (isServer) then {
+ PVDZ_groupInvite = _this;
+ {
+ _unit = getPlayerUID _x;
+ if (_unit != "" && ((!_add && _unit != _recipient) or (_add && _unit != _inviter))) then {
+ // Don't use regular PV because JIP clients don't need it (dayz_activeInvites is synced to them in server_playerLogin)
+ owner _x publicVariableClient "PVDZ_groupInvite";
+ };
+ } count allUnits;
+};
\ No newline at end of file
diff --git a/SQF/dayz_code/groups/groupMarkers.sqf b/SQF/dayz_code/groups/groupMarkers.sqf
new file mode 100644
index 000000000..265624608
--- /dev/null
+++ b/SQF/dayz_code/groups/groupMarkers.sqf
@@ -0,0 +1,57 @@
+// Two second loop
+private ["_count","_group","_hasGPS","_index","_marker","_markBody","_markGroup","_markSelf","_pos","_self","_vehicle"];
+
+_group = player call dayz_filterGroup;
+
+if (dayz_requireRadio && {count _group > 1} && {!("ItemRadio" in items player)}) exitWith {
+ [player] join grpNull;
+ _group = [];
+ if (!isNull findDisplay 80000) then {findDisplay 80000 closeDisplay 2;};
+ localize "STR_EPOCH_RADIO_CONTACT_LOST" call dayz_rollingMessages;
+};
+
+if (visibleMap or !isNull findDisplay 88890) then {
+ _hasGPS = "ItemGPS" in items player;
+ _markBody = (dayz_markBody == 1 or (dayz_markBody == 2 && _hasGPS));
+ _markGroup = (dayz_markGroup == 1 or (dayz_markGroup == 2 && _hasGPS));
+ _markSelf = (dayz_markSelf == 1 or (dayz_markSelf == 2 && _hasGPS));
+
+ _index = 0;
+ {
+ _self = _x == player;
+ _vehicle = vehicle _x;
+ if ((_self or _markGroup) && (!_self or _markSelf) && (driver _vehicle == _x)) then {
+ _pos = getPosATL _x;
+ if (surfaceIsWater _pos) then {_pos = getPosASL _x;};
+ deleteMarkerLocal format["groupMember%1",_index];
+ _marker = createMarkerLocal [format["groupMember%1",_index],_pos];
+ _marker setMarkerTypeLocal "DestroyedVehicle";
+ _marker setMarkerTextLocal format ["%1",if (_vehicle == _x) then {name _x} else {_vehicle call dayz_getCrew}];
+ _marker setMarkerColorLocal "ColorGreen";
+ } else {
+ deleteMarkerLocal format["groupMember%1",_index];
+ };
+ _index = _index + 1;
+ } count _group;
+
+ // Remove markers for group members that left
+ _count = count _group;
+ if (dayz_oldMemberCount > _count) then {
+ for "_i" from _count to dayz_oldMemberCount do {deleteMarkerLocal format["groupMember%1",_i];};
+ };
+ dayz_oldMemberCount = _count;
+
+ if (_markBody) then {
+ {
+ if (_x getVariable["bodyName",""] == name player) then {
+ deleteMarkerLocal "MyBody";
+ _marker = createMarkerLocal ["MyBody",getPosATL _x];
+ _marker setMarkerTypeLocal "DestroyedVehicle";
+ _marker setMarkerTextLocal localize "STR_EPOCH_RIP";
+ _marker setMarkerColorLocal "ColorRed";
+ };
+ } count allDead;
+ } else {
+ deleteMarkerLocal "MyBody";
+ };
+};
\ No newline at end of file
diff --git a/SQF/dayz_code/groups/init.sqf b/SQF/dayz_code/groups/init.sqf
new file mode 100644
index 000000000..b9cb818dd
--- /dev/null
+++ b/SQF/dayz_code/groups/init.sqf
@@ -0,0 +1,39 @@
+private "_oldGroup";
+
+if (count (units group player) > 1) then {
+ [player] join grpNull;
+};
+
+if (count dayz_myGroup > 1 && {!dayz_requireRadio or {dayz_requireRadio && "ItemRadio" in items player}}) then {
+ {
+ //Only auto join player into group if leader is in their savedGroup
+ if (getPlayerUID leader _x in dayz_myGroup) exitWith {
+ _oldGroup = group player;
+ [player] join _x;
+ if (count (units _oldGroup) == 0) then {deleteGroup _oldGroup;};
+
+ // Update saved group in DB
+ PVDZ_Server_UpdateGroup = [0,player];
+ publicVariableServer "PVDZ_Server_UpdateGroup";
+ };
+ } count allGroups;
+};
+
+dayz_oldGroupCount = 0;
+dayz_oldMemberCount = 0;
+dayz_disbandGroup = compile preprocessFileLineNumbers "\z\addons\dayz_code\groups\disbandGroup.sqf";
+dayz_filterGroup = compile preprocessFileLineNumbers "\z\addons\dayz_code\groups\filterGroup.sqf";
+dayz_getCrew = compile preprocessFileLineNumbers "\z\addons\dayz_code\groups\getCrew.sqf";
+dayz_getPlayer = compile preprocessFileLineNumbers "\z\addons\dayz_code\groups\getPlayer.sqf";
+dayz_groupIcons = compile preprocessFileLineNumbers "\z\addons\dayz_code\groups\groupIcons.sqf";
+dayz_groupMarkers = compile preprocessFileLineNumbers "\z\addons\dayz_code\groups\groupMarkers.sqf";
+dayz_inviteToGroup = compile preprocessFileLineNumbers "\z\addons\dayz_code\groups\inviteToGroup.sqf";
+dayz_joinGroup = compile preprocessFileLineNumbers "\z\addons\dayz_code\groups\joinGroup.sqf";
+dayz_kickFromGroup = compile preprocessFileLineNumbers "\z\addons\dayz_code\groups\kickFromGroup.sqf";
+dayz_leaveGroup = compile preprocessFileLineNumbers "\z\addons\dayz_code\groups\leaveGroup.sqf";
+dayz_openGroupDialog = compile preprocessFileLineNumbers "\z\addons\dayz_code\groups\openDialog.sqf";
+dayz_promotePlayer = compile preprocessFileLineNumbers "\z\addons\dayz_code\groups\promotePlayer.sqf";
+dayz_rejectGroup = compile preprocessFileLineNumbers "\z\addons\dayz_code\groups\rejectGroup.sqf";
+dayz_selectGroupMember = compile preprocessFileLineNumbers "\z\addons\dayz_code\groups\selectGroupMember.sqf";
+dayz_selectPlayer = compile preprocessFileLineNumbers "\z\addons\dayz_code\groups\selectPlayer.sqf";
+dayz_groupInit = true;
\ No newline at end of file
diff --git a/SQF/dayz_code/groups/inviteToGroup.sqf b/SQF/dayz_code/groups/inviteToGroup.sqf
new file mode 100644
index 000000000..cc33957e9
--- /dev/null
+++ b/SQF/dayz_code/groups/inviteToGroup.sqf
@@ -0,0 +1,32 @@
+private ["_hasInvite","_invite","_playerList","_recipient","_uid"];
+
+disableSerialization;
+_playerList = findDisplay 80000 displayCtrl 1;
+_uid = _playerList lbData (lbCurSel _playerList);
+_recipient = _uid call dayz_getPlayer;
+
+if (isNull _recipient or player != leader group player or count (units group _recipient) > 1) exitWith {
+ _this ctrlShow false;
+};
+
+_hasInvite = false;
+{
+ if (_x select 1 == _uid) then {
+ _hasInvite = true;
+ };
+} forEach dayz_activeInvites;
+
+if (_hasInvite) exitWith {
+ systemChat localize "STR_EPOCH_INVITE_PENDING";
+};
+
+_invite = [getPlayerUID player,_uid];
+
+//Update locally with change
+dayz_activeInvites set [count dayz_activeInvites,_invite];
+
+//Sync change to all remote machines (less data than sending whole array)
+PVDZ_groupInvite = [true,_invite];
+publicVariableServer "PVDZ_groupInvite";
+
+systemChat format[localize "STR_EPOCH_INVITE_TO",name _recipient];
\ No newline at end of file
diff --git a/SQF/dayz_code/groups/joinGroup.sqf b/SQF/dayz_code/groups/joinGroup.sqf
new file mode 100644
index 000000000..6017eae6c
--- /dev/null
+++ b/SQF/dayz_code/groups/joinGroup.sqf
@@ -0,0 +1,32 @@
+private ["_inviter","_inviterUID","_oldGroup","_uid"];
+
+_inviterUID = "0";
+_uid = getPlayerUID player;
+
+//Remove all invites to this player since they joined a group
+{
+ if (_uid == _x select 1) then {
+ _inviterUID = _x select 0; //Take most recent invite
+ dayz_activeInvites set [_forEachIndex,"delete"];
+ };
+} forEach dayz_activeInvites;
+dayz_activeInvites = dayz_activeInvites - ["delete"];
+
+//Sync change to all remote machines (less data than sending whole array)
+PVDZ_groupInvite = [false,_uid];
+publicVariableServer "PVDZ_groupInvite";
+
+_inviter = _inviterUID call dayz_getPlayer;
+
+if (!isNull _inviter) then {
+ _oldGroup = group player;
+ [player] join (group _inviter);
+ if (count (units _oldGroup) == 0) then {deleteGroup _oldGroup;};
+
+ // Update saved group in DB
+ PVDZ_Server_UpdateGroup = [1,player];
+ publicVariableServer "PVDZ_Server_UpdateGroup";
+} else {
+ _this ctrlShow false;
+ systemChat localize "STR_EPOCH_INVITE_EXPIRED";
+};
\ No newline at end of file
diff --git a/SQF/dayz_code/groups/kickFromGroup.sqf b/SQF/dayz_code/groups/kickFromGroup.sqf
new file mode 100644
index 000000000..2dc241126
--- /dev/null
+++ b/SQF/dayz_code/groups/kickFromGroup.sqf
@@ -0,0 +1,15 @@
+private ["_myGroup","_target","_targetUID"];
+
+disableSerialization;
+_myGroup = findDisplay 80000 displayCtrl 2;
+_targetUID = _myGroup lbData (lbCurSel _myGroup);
+_target = _targetUID call dayz_getPlayer;
+
+if (isNull _target or _target == player or player != leader group player) exitWith {
+ _this ctrlShow false;
+};
+
+[_target] join grpNull;
+
+PVDZ_Server_UpdateGroup = [2,player,_targetUID];
+publicVariableServer "PVDZ_Server_UpdateGroup";
\ No newline at end of file
diff --git a/SQF/dayz_code/groups/leaveGroup.sqf b/SQF/dayz_code/groups/leaveGroup.sqf
new file mode 100644
index 000000000..111a62d59
--- /dev/null
+++ b/SQF/dayz_code/groups/leaveGroup.sqf
@@ -0,0 +1,16 @@
+private "_group";
+_group = units group player;
+
+if (count _group == 1 or (!isNil "dayz_groupLeftThread" && {!scriptDone dayz_groupLeftThread})) exitWith {
+ _this ctrlShow false;
+};
+
+dayz_groupLeft = nil;
+PVDZ_Server_UpdateGroup = [3,player];
+publicVariableServer "PVDZ_Server_UpdateGroup";
+
+dayz_groupLeftThread = [] spawn {
+ //Wait for response from server to confirm group finished updating in DB
+ waitUntil {!isNil "dayz_groupLeft"};
+ [player] join grpNull;
+};
\ No newline at end of file
diff --git a/SQF/dayz_code/groups/openDialog.sqf b/SQF/dayz_code/groups/openDialog.sqf
new file mode 100644
index 000000000..633c38990
--- /dev/null
+++ b/SQF/dayz_code/groups/openDialog.sqf
@@ -0,0 +1,71 @@
+if (!isNull findDisplay 80000) exitWith {};
+
+private ["_disbandButton","_display","_group","_index","_inviteButton","_inviter","_inviterUID","_kickButton","_leader","_leaveButton","_myGroup","_playerList","_promoteButton","_uid"];
+disableSerialization;
+createDialog "DZ_GroupDialog";
+_display = findDisplay 80000;
+_uid = getPlayerUID player;
+_playerList = _display displayCtrl 1;
+_myGroup = _display displayCtrl 2;
+_inviteButton = _display displayCtrl 3;
+_kickButton = _display displayCtrl 4;
+_disbandButton = _display displayCtrl 5;
+_leaveButton = _display displayCtrl 6;
+_joinButton = _display displayCtrl 7;
+_rejectButton = _display displayCtrl 8;
+_inviteText = _display displayCtrl 9;
+_promoteButton = _display displayCtrl 10;
+{_x ctrlShow false;} count [_disbandButton,_inviteButton,_joinButton,_kickButton,_leaveButton,_promoteButton,_rejectButton];
+
+while {!isNull findDisplay 80000} do {
+ //Fill my group list
+ _group = group player;
+ _leader = leader _group;
+ lbClear _myGroup;
+ {
+ if (alive _x && isPlayer _x) then {
+ _index = _myGroup lbAdd (name _x);
+ _myGroup lbSetData [_index,getPlayerUID _x];
+ _myGroup lbSetPicture [_index, if (_x == _leader) then {"\ca\ui\data\icon_unit_teamleader_ca.paa"} else {"\ca\ui\data\map_bush_ca.paa"}];
+ };
+ } count (units _group);
+ lbSort _myGroup;
+
+ if (lbSize _myGroup > 1) then {
+ _leaveButton ctrlShow true;
+ if (player == _leader) then {_disbandButton ctrlShow true};
+ } else {
+ {_x ctrlShow false} count [_disbandButton,_leaveButton];
+ };
+
+ _hasInvite = false;
+ {
+ if (_x select 1 == _uid) then {
+ _hasInvite = true;
+ _inviterUID = _x select 0; //Take most recent invite
+ };
+ } forEach dayz_activeInvites;
+
+ if (_hasInvite) then {
+ {_x ctrlShow true} count [_inviteText,_joinButton,_rejectButton];
+ _inviter = _inviterUID call dayz_getPlayer;
+ if (!isNull _inviter) then {
+ _inviteText ctrlSetStructuredText parseText (format ["%1
%2",localize "STR_EPOCH_INVITE_FROM",name _inviter]);
+ };
+ } else {
+ {_x ctrlShow false} count [_inviteText,_joinButton,_rejectButton];
+ };
+
+ //Fill player list
+ lbClear _playerList;
+ {
+ if (isPlayer _x && _x != player) then {
+ _index = _playerList lbAdd (name _x);
+ _playerList lbSetData [_index, getPlayerUID _x];
+ _playerList lbSetPicture [_index, if (count (units group _x) > 1) then {"\ca\ui\data\ui_task_failed_ca.paa"} else {"\ca\ui\data\ui_task_done_ca.paa"}];
+ };
+ } count allUnits;
+ lbSort _playerList;
+
+ uiSleep 1;
+};
\ No newline at end of file
diff --git a/SQF/dayz_code/groups/promotePlayer.sqf b/SQF/dayz_code/groups/promotePlayer.sqf
new file mode 100644
index 000000000..59e41eeca
--- /dev/null
+++ b/SQF/dayz_code/groups/promotePlayer.sqf
@@ -0,0 +1,23 @@
+private ["_disbandButton","_display","_group","_myGroup","_target","_uid"];
+
+disableSerialization;
+_display = findDisplay 80000;
+_myGroup = _display displayCtrl 2;
+_disbandButton = _display displayCtrl 5;
+_promoteButton = _this;
+_uid = _myGroup lbData (lbCurSel _myGroup);
+
+_group = group player;
+_target = _uid call dayz_getPlayer;
+
+if (player == leader _group && {!isNull _target} && {_target != player}) then {
+ if (local _group) then {
+ _group selectLeader _target; //group must be local
+ _promoteButton ctrlShow false;
+ _disbandButton ctrlShow false;
+ } else {
+ systemChat "Failed: Group must be local to do this";
+ };
+} else {
+ _promoteButton ctrlShow false;
+};
\ No newline at end of file
diff --git a/SQF/dayz_code/groups/rejectGroup.sqf b/SQF/dayz_code/groups/rejectGroup.sqf
new file mode 100644
index 000000000..66eeedb13
--- /dev/null
+++ b/SQF/dayz_code/groups/rejectGroup.sqf
@@ -0,0 +1,16 @@
+private "_uid";
+_uid = getPlayerUID player;
+
+//Remove all invites to this player
+{
+ if (_uid == _x select 1) then {
+ dayz_activeInvites set [_forEachIndex,"delete"];
+ };
+} forEach dayz_activeInvites;
+dayz_activeInvites = dayz_activeInvites - ["delete"];
+
+_this ctrlShow false;
+
+//Sync change to all remote machines (less data than sending whole array)
+PVDZ_groupInvite = [false,_uid];
+publicVariableServer "PVDZ_groupInvite";
\ No newline at end of file
diff --git a/SQF/dayz_code/groups/selectGroupMember.sqf b/SQF/dayz_code/groups/selectGroupMember.sqf
new file mode 100644
index 000000000..a27e741c3
--- /dev/null
+++ b/SQF/dayz_code/groups/selectGroupMember.sqf
@@ -0,0 +1,15 @@
+private ["_display","_kickButton","_myGroup","_promoteButton","_target","_uid"];
+
+disableSerialization;
+_display = findDisplay 80000;
+_myGroup = _this;
+_kickButton = _display displayCtrl 4;
+_promoteButton = _display displayCtrl 10;
+_uid = _myGroup lbData (lbCurSel _myGroup);
+_target = _uid call dayz_getPlayer;
+
+if (player == leader group player && {!isNull _target} && {_target != player}) then {
+ {_x ctrlShow true;} count [_kickButton,_promoteButton];
+} else {
+ {_x ctrlShow false;} count [_kickButton,_promoteButton];
+};
\ No newline at end of file
diff --git a/SQF/dayz_code/groups/selectPlayer.sqf b/SQF/dayz_code/groups/selectPlayer.sqf
new file mode 100644
index 000000000..9546802a4
--- /dev/null
+++ b/SQF/dayz_code/groups/selectPlayer.sqf
@@ -0,0 +1,13 @@
+private ["_inviteButton","_playerList","_target","_uid"];
+
+disableSerialization;
+_playerList = _this;
+_inviteButton = findDisplay 80000 displayCtrl 3;
+_uid = _playerList lbData (lbCurSel _playerList);
+_target = _uid call dayz_getPlayer;
+
+if (player == leader group player && {!isNull _target} && {count (units group _target) == 1}) then {
+ _inviteButton ctrlShow true;
+} else {
+ _inviteButton ctrlShow false;
+};
\ No newline at end of file
diff --git a/SQF/dayz_code/groups/server_updateGroup.sqf b/SQF/dayz_code/groups/server_updateGroup.sqf
new file mode 100644
index 000000000..85b27110c
--- /dev/null
+++ b/SQF/dayz_code/groups/server_updateGroup.sqf
@@ -0,0 +1,42 @@
+private ["_event","_groupUIDs","_key","_newGroup","_player","_playerUID","_targetUID"];
+
+_event = _this select 0;
+_player = _this select 1;
+_targetUID = if (count _this > 2) then {_this select 2} else {"0"};
+_playerUID = getPlayerUID _player;
+
+_groupUIDs = [];
+{
+ if (alive _x && isPlayer _x) then {
+ _groupUIDs set [count _groupUIDs,getPlayerUID _x];
+ };
+} count (units group _player);
+
+_newGroup = [];
+_newGroup = switch _event do {
+ //Login
+ case 0;
+ //Join
+ case 1;
+ //Kick (target was already kicked from group)
+ case 2: {_groupUIDs};
+ //Leave
+ case 3: {
+ dayz_groupLeft = true;
+ (owner _player) publicVariableClient "dayz_groupLeft";
+ (_groupUIDs - [_playerUID])
+ };
+ //Disband
+ case 4: {
+ dayz_groupDisbanded = true;
+ (owner _player) publicVariableClient "dayz_groupDisbanded";
+ []
+ };
+};
+
+// Update all group members' saved group in DB
+{
+ _save = if ((_event == 2 && _x == _targetUID) or (_event == 3 && _x == _playerUID)) then {[]} else {_newGroup};
+ _key = format ["CHILD:204:%1:%2:%3:",_x,dayZ_instance,_save];
+ _key call server_hiveWrite;
+} count _groupUIDs;
\ No newline at end of file
diff --git a/SQF/dayz_code/gui/epoch/arrow_right.paa b/SQF/dayz_code/gui/grey/arrow_right.paa
similarity index 100%
rename from SQF/dayz_code/gui/epoch/arrow_right.paa
rename to SQF/dayz_code/gui/grey/arrow_right.paa
diff --git a/SQF/dayz_code/gui/grey/ui_arrow_top_active_ca.paa b/SQF/dayz_code/gui/grey/ui_arrow_top_active_ca.paa
new file mode 100644
index 000000000..25182252a
Binary files /dev/null and b/SQF/dayz_code/gui/grey/ui_arrow_top_active_ca.paa differ
diff --git a/SQF/dayz_code/gui/grey/ui_arrow_top_ca.paa b/SQF/dayz_code/gui/grey/ui_arrow_top_ca.paa
new file mode 100644
index 000000000..498b900fc
Binary files /dev/null and b/SQF/dayz_code/gui/grey/ui_arrow_top_ca.paa differ
diff --git a/SQF/dayz_code/gui/grey/ui_audio_background_ca.paa b/SQF/dayz_code/gui/grey/ui_audio_background_ca.paa
new file mode 100644
index 000000000..a67d6dbab
Binary files /dev/null and b/SQF/dayz_code/gui/grey/ui_audio_background_ca.paa differ
diff --git a/SQF/dayz_code/gui/grey/ui_background_controlers_ca.paa b/SQF/dayz_code/gui/grey/ui_background_controlers_ca.paa
new file mode 100644
index 000000000..722158f69
Binary files /dev/null and b/SQF/dayz_code/gui/grey/ui_background_controlers_ca.paa differ
diff --git a/SQF/dayz_code/gui/grey/ui_background_controls_ca.paa b/SQF/dayz_code/gui/grey/ui_background_controls_ca.paa
new file mode 100644
index 000000000..d4688010f
Binary files /dev/null and b/SQF/dayz_code/gui/grey/ui_background_controls_ca.paa differ
diff --git a/SQF/dayz_code/gui/grey/ui_background_messagebox_ca.paa b/SQF/dayz_code/gui/grey/ui_background_messagebox_ca.paa
new file mode 100644
index 000000000..2b99f5dc1
Binary files /dev/null and b/SQF/dayz_code/gui/grey/ui_background_messagebox_ca.paa differ
diff --git a/SQF/dayz_code/gui/grey/ui_background_modlauncher_ca.paa b/SQF/dayz_code/gui/grey/ui_background_modlauncher_ca.paa
new file mode 100644
index 000000000..62380658e
Binary files /dev/null and b/SQF/dayz_code/gui/grey/ui_background_modlauncher_ca.paa differ
diff --git a/SQF/dayz_code/gui/grey/ui_background_mp_pause_ca.paa b/SQF/dayz_code/gui/grey/ui_background_mp_pause_ca.paa
new file mode 100644
index 000000000..a0d3621b8
Binary files /dev/null and b/SQF/dayz_code/gui/grey/ui_background_mp_pause_ca.paa differ
diff --git a/SQF/dayz_code/gui/grey/ui_background_profile_ca.paa b/SQF/dayz_code/gui/grey/ui_background_profile_ca.paa
new file mode 100644
index 000000000..cbf092119
Binary files /dev/null and b/SQF/dayz_code/gui/grey/ui_background_profile_ca.paa differ
diff --git a/SQF/dayz_code/gui/grey/ui_background_video_buttons_ca.paa b/SQF/dayz_code/gui/grey/ui_background_video_buttons_ca.paa
new file mode 100644
index 000000000..3ad8eb3eb
Binary files /dev/null and b/SQF/dayz_code/gui/grey/ui_background_video_buttons_ca.paa differ
diff --git a/SQF/dayz_code/gui/grey/ui_background_video_ca.paa b/SQF/dayz_code/gui/grey/ui_background_video_ca.paa
new file mode 100644
index 000000000..a92b705eb
Binary files /dev/null and b/SQF/dayz_code/gui/grey/ui_background_video_ca.paa differ
diff --git a/SQF/dayz_code/gui/grey/ui_border_scroll_ca.paa b/SQF/dayz_code/gui/grey/ui_border_scroll_ca.paa
new file mode 100644
index 000000000..a3208d2cc
Binary files /dev/null and b/SQF/dayz_code/gui/grey/ui_border_scroll_ca.paa differ
diff --git a/SQF/dayz_code/gui/grey/ui_button_default_ca.paa b/SQF/dayz_code/gui/grey/ui_button_default_ca.paa
new file mode 100644
index 000000000..704e099d2
Binary files /dev/null and b/SQF/dayz_code/gui/grey/ui_button_default_ca.paa differ
diff --git a/SQF/dayz_code/gui/grey/ui_button_disabled_ca.paa b/SQF/dayz_code/gui/grey/ui_button_disabled_ca.paa
new file mode 100644
index 000000000..35610d6a6
Binary files /dev/null and b/SQF/dayz_code/gui/grey/ui_button_disabled_ca.paa differ
diff --git a/SQF/dayz_code/gui/grey/ui_button_down_ca.paa b/SQF/dayz_code/gui/grey/ui_button_down_ca.paa
new file mode 100644
index 000000000..2fdd1ca8f
Binary files /dev/null and b/SQF/dayz_code/gui/grey/ui_button_down_ca.paa differ
diff --git a/SQF/dayz_code/gui/grey/ui_button_focus_ca.paa b/SQF/dayz_code/gui/grey/ui_button_focus_ca.paa
new file mode 100644
index 000000000..30904aeb4
Binary files /dev/null and b/SQF/dayz_code/gui/grey/ui_button_focus_ca.paa differ
diff --git a/SQF/dayz_code/gui/grey/ui_button_main_disabled_ca.paa b/SQF/dayz_code/gui/grey/ui_button_main_disabled_ca.paa
new file mode 100644
index 000000000..2c52569d7
Binary files /dev/null and b/SQF/dayz_code/gui/grey/ui_button_main_disabled_ca.paa differ
diff --git a/SQF/dayz_code/gui/grey/ui_button_main_down_ca.paa b/SQF/dayz_code/gui/grey/ui_button_main_down_ca.paa
new file mode 100644
index 000000000..b38d4030f
Binary files /dev/null and b/SQF/dayz_code/gui/grey/ui_button_main_down_ca.paa differ
diff --git a/SQF/dayz_code/gui/grey/ui_button_main_focus_ca.paa b/SQF/dayz_code/gui/grey/ui_button_main_focus_ca.paa
new file mode 100644
index 000000000..a6f291b41
Binary files /dev/null and b/SQF/dayz_code/gui/grey/ui_button_main_focus_ca.paa differ
diff --git a/SQF/dayz_code/gui/grey/ui_button_main_normal_ca.paa b/SQF/dayz_code/gui/grey/ui_button_main_normal_ca.paa
new file mode 100644
index 000000000..b7755cb22
Binary files /dev/null and b/SQF/dayz_code/gui/grey/ui_button_main_normal_ca.paa differ
diff --git a/SQF/dayz_code/gui/grey/ui_button_main_over_ca.paa b/SQF/dayz_code/gui/grey/ui_button_main_over_ca.paa
new file mode 100644
index 000000000..bd173402e
Binary files /dev/null and b/SQF/dayz_code/gui/grey/ui_button_main_over_ca.paa differ
diff --git a/SQF/dayz_code/gui/grey/ui_button_normal_ca.paa b/SQF/dayz_code/gui/grey/ui_button_normal_ca.paa
new file mode 100644
index 000000000..704e099d2
Binary files /dev/null and b/SQF/dayz_code/gui/grey/ui_button_normal_ca.paa differ
diff --git a/SQF/dayz_code/gui/grey/ui_button_over_ca.paa b/SQF/dayz_code/gui/grey/ui_button_over_ca.paa
new file mode 100644
index 000000000..4b678fe38
Binary files /dev/null and b/SQF/dayz_code/gui/grey/ui_button_over_ca.paa differ
diff --git a/SQF/dayz_code/gui/grey/ui_gameoptions_background_ca.paa b/SQF/dayz_code/gui/grey/ui_gameoptions_background_ca.paa
new file mode 100644
index 000000000..05a929213
Binary files /dev/null and b/SQF/dayz_code/gui/grey/ui_gameoptions_background_ca.paa differ
diff --git a/SQF/dayz_code/gui/grey/ui_mainmenu_background_ca.paa b/SQF/dayz_code/gui/grey/ui_mainmenu_background_ca.paa
new file mode 100644
index 000000000..8bec0b0c5
Binary files /dev/null and b/SQF/dayz_code/gui/grey/ui_mainmenu_background_ca.paa differ
diff --git a/SQF/dayz_code/gui/grey/ui_mainmenu_background_small_ca.paa b/SQF/dayz_code/gui/grey/ui_mainmenu_background_small_ca.paa
new file mode 100644
index 000000000..48cec343c
Binary files /dev/null and b/SQF/dayz_code/gui/grey/ui_mainmenu_background_small_ca.paa differ
diff --git a/SQF/dayz_code/gui/grey/ui_messagebox_bottom_ca.paa b/SQF/dayz_code/gui/grey/ui_messagebox_bottom_ca.paa
new file mode 100644
index 000000000..13ffc8824
Binary files /dev/null and b/SQF/dayz_code/gui/grey/ui_messagebox_bottom_ca.paa differ
diff --git a/SQF/dayz_code/gui/grey/ui_messagebox_middle_ca.paa b/SQF/dayz_code/gui/grey/ui_messagebox_middle_ca.paa
new file mode 100644
index 000000000..18ae8f6a3
Binary files /dev/null and b/SQF/dayz_code/gui/grey/ui_messagebox_middle_ca.paa differ
diff --git a/SQF/dayz_code/gui/grey/ui_messagebox_top_ca.paa b/SQF/dayz_code/gui/grey/ui_messagebox_top_ca.paa
new file mode 100644
index 000000000..1395c375b
Binary files /dev/null and b/SQF/dayz_code/gui/grey/ui_messagebox_top_ca.paa differ
diff --git a/SQF/dayz_code/gui/grey/ui_newprofile_background_ca.paa b/SQF/dayz_code/gui/grey/ui_newprofile_background_ca.paa
new file mode 100644
index 000000000..49c8ecc18
Binary files /dev/null and b/SQF/dayz_code/gui/grey/ui_newprofile_background_ca.paa differ
diff --git a/SQF/dayz_code/gui/grey/ui_revert_background_ca.paa b/SQF/dayz_code/gui/grey/ui_revert_background_ca.paa
new file mode 100644
index 000000000..0869d1e51
Binary files /dev/null and b/SQF/dayz_code/gui/grey/ui_revert_background_ca.paa differ
diff --git a/SQF/dayz_code/gui/grey/ui_scrollbar_thumb_ca.paa b/SQF/dayz_code/gui/grey/ui_scrollbar_thumb_ca.paa
new file mode 100644
index 000000000..4a1f54f95
Binary files /dev/null and b/SQF/dayz_code/gui/grey/ui_scrollbar_thumb_ca.paa differ
diff --git a/SQF/dayz_code/init/compiles.sqf b/SQF/dayz_code/init/compiles.sqf
index 6472fea03..c1adbdd8e 100644
--- a/SQF/dayz_code/init/compiles.sqf
+++ b/SQF/dayz_code/init/compiles.sqf
@@ -4,6 +4,7 @@ if (isServer) then {
pvs_processSetAccessCode = compile preprocessFile "\z\addons\dayz_code\eventHandlers\processSetAccessCode.sqf";
pvs_processAccessCode = compile preprocessFile "\z\addons\dayz_code\eventHandlers\processAccessCode.sqf";
server_spawnTraders = compile preprocessFile "\z\addons\dayz_server\compile\server_spawnTraders.sqf";
+ server_updateGroup = compile preprocessFileLineNumbers "\z\addons\dayz_code\groups\server_updateGroup.sqf";
};
if (!isDedicated) then {
@@ -681,6 +682,7 @@ local_spawnObjects = compile preprocessFileLineNumbers "\z\addons\dayz_code\comp
FNC_GetSetPos = compile preprocessFileLineNumbers "\z\addons\dayz_code\compile\fnc_getSetPos.sqf";
FNC_GetPos = compile preprocessFileLineNumbers "\z\addons\dayz_code\compile\fnc_getPos.sqf";
dayz_EjectPlayer = compile preprocessFileLineNumbers "\z\addons\dayz_code\compile\dze_ejectPlayer.sqf";
+dayz_groupInvite = compile preprocessFileLineNumbers "\z\addons\dayz_code\groups\groupInvite.sqf";
DZE_FilterCheats = {
#define DIK_SUBTRACT 0x4A
diff --git a/SQF/dayz_code/init/publicEH.sqf b/SQF/dayz_code/init/publicEH.sqf
index 970e135f6..1c13519df 100644
--- a/SQF/dayz_code/init/publicEH.sqf
+++ b/SQF/dayz_code/init/publicEH.sqf
@@ -17,6 +17,9 @@
"PVDZE_plr_GutBodyZ" addPublicVariableEventHandler {(_this select 1) spawn local_gutObjectZ};
"PVDZE_veh_Init" addPublicVariableEventHandler {(_this select 1) call fnc_veh_ResetEH};
"PVDZE_obj_Remove" addPublicVariableEventHandler {_pos = (_this select 1); _obj = nearestObjects [_pos, DZE_isWreckBuilding, 5]; if (count _obj > 0) then {deleteVehicle (_obj select 0);};};
+if (dayz_groupSystem) then {
+ "PVDZ_groupInvite" addPublicVariableEventHandler {(_this select 1) call dayz_groupInvite};
+};
if (toLower worldName == "chernarus") then { //need to add building coordinates for other maps
{
@@ -99,6 +102,9 @@ if (isServer) then {
"PVDZE_plr_DeathB" addPublicVariableEventHandler {(_this select 1) spawn server_deaths};
"PVDZE_handleSafeGear" addPublicVariableEventHandler {(_this select 1) spawn server_handleSafeGear};
"PVDZE_fullobj_Publish" addPublicVariableEventHandler {(_this select 1) call server_publishFullObject}; // PlotForLife take base ownership
+ if (dayz_groupSystem) then {
+ "PVDZ_Server_UpdateGroup" addPublicVariableEventHandler {(_this select 1) call server_updateGroup};
+ };
//Added as part of the maintenance system to allow the server to replace the damaged model with a normal model.
"PVDZ_object_replace" addPublicVariableEventHandler {
diff --git a/SQF/dayz_code/init/variables.sqf b/SQF/dayz_code/init/variables.sqf
index 54aaa280a..7cabe0af4 100644
--- a/SQF/dayz_code/init/variables.sqf
+++ b/SQF/dayz_code/init/variables.sqf
@@ -510,6 +510,7 @@ switch (toLower worldName) do {
keypadCancel = false; //Brute force fix
keyPadReset = {uiSleep 2; keypadCancel = false;};
canbuild = true;
+dayz_activeInvites = [];
dayz_combination = "";
dayz_disallowedVault = ["TentStorage","BuiltItems","ModularItems","DZE_Base_Object","Generator_DZ"];
// These work with just a running generator
@@ -709,4 +710,5 @@ if (!isDedicated) then {
DZE_Quarantine = false;
DZE_InRadiationZone = false;
DZE_myVehicle = objNull;
+ dayz_groupNameTags = false;
};
diff --git a/SQF/dayz_code/stringtable.xml b/SQF/dayz_code/stringtable.xml
index d706d9e3b..754d1ee72 100644
--- a/SQF/dayz_code/stringtable.xml
+++ b/SQF/dayz_code/stringtable.xml
@@ -16182,6 +16182,106 @@
Hráč
プレイヤー
+
+ Players
+ Joueurs
+ Jugadores
+ Giocatori
+ Játékosok
+ Gracze
+ Игроки
+ Spieler
+ Hráči
+
+
+ Groups (F5)
+ групп
+ Gruppen (F5)
+
+
+ Groups
+ групп
+ Gruppen
+
+
+ My Group
+
+
+ Invite
+ приглашение
+ Einladen
+
+
+ Invite From
+
+
+ You invited %1 to join the group.
+
+
+ New group invite - Press F5 to view
+
+
+ This player already has a pending invite.
+
+
+ The invite expired.
+
+
+ You need a radio to join a group.
+
+
+ Lost radio contact with group
+
+
+ RIP
+
+
+ Promote
+
+
+ Disband
+ распускать
+ Auflösen
+
+
+ Leave
+ Оставлять
+ Verlassen
+
+
+ Accept
+ Accepter
+ Aceptar
+ Accetta
+ Elfogadás
+ Zaakceptuj
+ Принять
+ Annehmen
+ Přijmout
+
+
+ Reject
+ Refuser
+ Rechazar
+ Rifiuta
+ Elutasít
+ Odrzuć
+ Отказать
+ Ablehnen
+ Odmítnout
+
+
+ Kick
+ Ejecter
+ Expulsa
+ Espelli
+ Kirúgás
+ Wyrzuć
+ Выгнать
+ Kicken
+ Vyhostit
+ 排除
+
AI
IA
diff --git a/SQF/dayz_code/system/player_monitor.fsm b/SQF/dayz_code/system/player_monitor.fsm
index 9a6ba942d..abc5e3c68 100644
--- a/SQF/dayz_code/system/player_monitor.fsm
+++ b/SQF/dayz_code/system/player_monitor.fsm
@@ -486,7 +486,7 @@ class FSM
"_isHiveOk = false;" \n
"_newPlayer = false;" \n
"_isInfected = false;" \n
- "_mygroup = [];" \n
+ "dayz_myGroup = [];" \n
"_characterCoins = 0;" \n
"_globalCoins = 0;" \n
"_CoinsSpecial = 0;" \n
@@ -495,7 +495,7 @@ class FSM
" _isHiveOk = _msg select 7;" \n
" _newPlayer = _msg select 8;" \n
" _isInfected = _msg select 9;" \n
- " _mygroup = _msg select 10;" \n
+ " dayz_myGroup = _msg select 10;" \n
" _characterCoins = _msg select 11;" \n
" _globalCoins = _msg select 12;" \n
" _CoinsSpecial = _msg select 13;" \n
@@ -1171,12 +1171,6 @@ class FSM
" player setVariable [""GlobalMoney"", _globalCoins, true];" \n
" player setVariable [""MoneySpecial"", _CoinsSpecial, true];" \n
"};" \n
- "" \n
- "if (DZE_groupManagement) then {" \n
- " player setVariable [""savedGroup"", _mygroup, true];" \n
- " player setVariable [""purgeGroup"", 0, true];" \n
- "};" \n
- "" \n
"dayz_musicH = [] spawn player_music;" \n
"dayz_slowCheck = [] spawn player_spawn_2;" \n
"Dayz_logonTime = daytime;" \n
diff --git a/SQF/dayz_code/system/player_spawn_2.sqf b/SQF/dayz_code/system/player_spawn_2.sqf
index 96f2df560..32417aa7d 100644
--- a/SQF/dayz_code/system/player_spawn_2.sqf
+++ b/SQF/dayz_code/system/player_spawn_2.sqf
@@ -227,6 +227,8 @@ while {1 == 1} do {
player setVariable["USEC_infected",true,true];
};
};
+
+ if (!isNil "dayz_groupInit") then {call dayz_groupMarkers;};
// Radiation zones rapid blood loss
if (DZE_InRadiationZone) then {
diff --git a/SQF/dayz_code/system/progress_monitor.sqf b/SQF/dayz_code/system/progress_monitor.sqf
index 4d9c7f322..faadcc9b1 100644
--- a/SQF/dayz_code/system/progress_monitor.sqf
+++ b/SQF/dayz_code/system/progress_monitor.sqf
@@ -12,6 +12,7 @@ while {true} do {
if ((!isNil "Dayz_loginCompleted") and {(Dayz_loginCompleted)}) exitWith {
//diag_log [ __FILE__, __LINE__, "End loop"];
dayz_playerName = if (alive player) then {name player} else {"unknown"};
+ if (dayz_groupSystem) then {call compile preprocessFileLineNumbers "\z\addons\dayz_code\groups\init.sqf";};
};
_display = uiNameSpace getVariable "BIS_loadingScreen";
if ((!isNil "_display") and {(dayz_loadScreenMsg != "" )}) then {
diff --git a/SQF/dayz_code/system/scheduler/sched_oneachframe.sqf b/SQF/dayz_code/system/scheduler/sched_oneachframe.sqf
index 5cac9884c..3f6335bbd 100644
--- a/SQF/dayz_code/system/scheduler/sched_oneachframe.sqf
+++ b/SQF/dayz_code/system/scheduler/sched_oneachframe.sqf
@@ -28,6 +28,8 @@ sched_onEachFrame = {
hintSilent localize "str_player_lowPFS";
diag_log format [ "h1nt: LOW FPS (%1)", diag_fpsmin ];
};
+
+ if (!isNil "dayz_groupIcons") then {call dayz_groupIcons;};
_ret
};
\ No newline at end of file
diff --git a/SQF/dayz_server/compile/server_playerLogin.sqf b/SQF/dayz_server/compile/server_playerLogin.sqf
index 24eee97ef..59789983c 100644
--- a/SQF/dayz_server/compile/server_playerLogin.sqf
+++ b/SQF/dayz_server/compile/server_playerLogin.sqf
@@ -148,6 +148,11 @@ if (_endMission) exitwith {
//Sync chopped trees for JIP player
{_x setDamage 1} count dayz_choppedTrees;
+//Sync active group invites to JIP player
+if (count dayz_activeInvites > 0) then {
+ (owner _playerObj) publicVariableClient "dayz_activeInvites";
+};
+
//Record Player Login/LogOut
[_playerID,_charID,1,_playerName] call dayz_recordLogin;
diff --git a/SQF/dayz_server/compile/server_playerSync.sqf b/SQF/dayz_server/compile/server_playerSync.sqf
index cc033adbc..2ec88d939 100644
--- a/SQF/dayz_server/compile/server_playerSync.sqf
+++ b/SQF/dayz_server/compile/server_playerSync.sqf
@@ -1,5 +1,5 @@
private ["_distanceFoot","_playerPos","_lastPos","_playerGear","_medical","_currentModel","_currentAnim",
-"_currentWpn","_muzzles","_array","_coins","_key","_globalCoins","_bankCoins","_group","_playerBackp",
+"_currentWpn","_muzzles","_array","_coins","_key","_globalCoins","_bankCoins","_playerBackp",
"_backpack","_kills","_killsB","_killsH","_headShots","_humanity","_lastTime","_timeGross","_timeSince",
"_timeLeft","_config","_onLadder","_isTerminal","_modelChk","_temp","_currentState","_character",
"_magazines","_characterID","_charPos","_isInVehicle","_name","_isNewMed",
@@ -48,7 +48,6 @@ _distanceFoot = 0;
//all getVariable immediately
_globalCoins = _character getVariable ["GlobalMoney", -1];
_bankCoins = _character getVariable ["MoneySpecial", -1];
-_group = _character getVariable ["savedGroup", []];
_coins = _character getVariable [Z_MoneyVariable, -1]; //should getting coins fail set the variable to an invalid value to prevent overwritting the in the DB
_lastPos = _character getVariable ["lastPos",_charPos];
_usec_Dead = _character getVariable ["USEC_isDead",false];
@@ -237,10 +236,5 @@ if (Z_SingleCurrency) then { //update global coins
_key call server_hiveWrite;
};
-if (DZE_groupManagement) then { //update player group
- _key = format["CHILD:204:%1:%2:%3:",_playerUID,dayZ_instance, _group];
- _key call server_hiveWrite;
-};
-
// Force gear updates for nearby vehicles/tents
-{[_x,"gear"] call server_updateObject;} count nearestObjects [_charPos,DayZ_GearedObjects,10];
+{[_x,"gear"] call server_updateObject;} count nearestObjects [_charPos,DayZ_GearedObjects,10];
\ No newline at end of file
diff --git a/Server Files/Battleye/publicvariable.txt b/Server Files/Battleye/publicvariable.txt
index e34757516..db5302300 100644
--- a/Server Files/Battleye/publicvariable.txt
+++ b/Server Files/Battleye/publicvariable.txt
@@ -1,3 +1,3 @@
//new
-5 !=(remExField|remExFP) !=(PVCDZ_obj_GutBody|drn_AskServerDynamicWeatherEventArgs|BIS_effects_gepv|achievement|dayzFlies) !=PVDZ_(drg_(RaDrag|RaLW|RLact)|getTickTime|hlt_Bleed|obj_(Delete|Publish|RoadFlare|Destroy|Fire)|veh_Save|veh_SF) !=PVDZ_(plr_(Death|Login[12]|LoginRecord|Save|SwitchMove)|Server(_Simulation|StoreVar)|sec_atp) !=PVDZ_playerMedicalSync !=PVDZ_(send(|Unconscious)) !=PVDZ_Server_(buildLock|LogIt) !=PVDZ_Server_process(Code|SetAccessCode) !=PVDZ_objgather_(Delete|Knockdown) !=PVDZE_(obj_(Delete|Publish|Swap|Trade)|fullobj_Publish|maintainArea|veh_(Lock|Publish2|Upgrade)|handleSafeGear|plr_(DeathB|FriendRQ|GutBodyZ|TradeMenu))
+5 !=(remExField|remExFP) !=(PVCDZ_obj_GutBody|drn_AskServerDynamicWeatherEventArgs|BIS_effects_gepv|achievement|dayzFlies) !=PVDZ_(drg_(RaDrag|RaLW|RLact)|getTickTime|hlt_Bleed|obj_(Delete|Publish|RoadFlare|Destroy|Fire)|veh_Save|veh_SF) !=PVDZ_(plr_(Death|Login[12]|LoginRecord|Save|SwitchMove)|Server(_Simulation|StoreVar)|sec_atp) !=PVDZ_(playerMedicalSync|object_replace|groupInvite) !=PVDZ_(send(|Unconscious)) !=PVDZ_Server_(buildLock|LogIt|UpdateGroup) !=PVDZ_Server_process(Code|SetAccessCode) !=PVDZ_objgather_(Delete|Knockdown) !=PVDZE_(obj_(Delete|Publish|Swap|Trade)|fullobj_Publish|maintainArea|veh_(Lock|Publish2|Upgrade)|handleSafeGear|plr_(DeathB|FriendRQ|GutBodyZ|TradeMenu))
1=BIS_effects_gepv|PVDZ_(drg_RaDrag|hlt_Bleed|obj_Delete|obj_Destroy|obj_Publish|plr_Death|plr_LoginRecord|sec_atp|send|veh_SF)
\ No newline at end of file