Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

remove obsolete team synch code #511

Merged
merged 2 commits into from
Sep 24, 2016
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 0 additions & 6 deletions addons/common/CfgEventHandlers.hpp
Original file line number Diff line number Diff line change
@@ -1,10 +1,4 @@

class Extended_PreStart_EventHandlers {
class ADDON {
init = QUOTE(call COMPILE_FILE(XEH_preStart));
};
};

class Extended_PreInit_EventHandlers {
class ADDON {
init = QUOTE(call COMPILE_FILE(XEH_preInit));
Expand Down
27 changes: 5 additions & 22 deletions addons/common/XEH_postInit.sqf
Original file line number Diff line number Diff line change
Expand Up @@ -35,28 +35,11 @@ for "_i" from 0 to ((count (CFG)) - 1) do {
};
};

// system to synch team colors
// Note: 1.62 added Multiplayer synchronization for assigned team
// Run the PFEH only if on previous versions, keep the event for backwards compatability

PREP(onTeamColorChanged);
PREP(synchTeamColors);

["CBA_teamColorChanged", FUNC(onTeamColorChanged)] call CBA_fnc_addEventHandler;

if (hasInterface && {(productVersion select 2) < 162}) then {
[FUNC(synchTeamColors), 1, []] call CBA_fnc_addPerFrameHandler;

if (didJIP) then {
{
private _team = _x getVariable [QGVAR(synchedTeam), ""];
if (_team != "") then {
_x assignTeam _team;
};
true
} count allUnits;
};
};
// event for switching team colors, DEPRECATED
["CBA_teamColorChanged", {
params ["_unit", "_team"];
_unit assignTeam _team;
}] call CBA_fnc_addEventHandler;

//Event for switching vehicle var names from CBA_fnc_switchPlayer
["CBA_setVehicleVarName", {
Expand Down
4 changes: 0 additions & 4 deletions addons/common/XEH_preStart.sqf

This file was deleted.

27 changes: 0 additions & 27 deletions addons/common/fnc_onTeamColorChanged.sqf

This file was deleted.

26 changes: 0 additions & 26 deletions addons/common/fnc_synchTeamColors.sqf

This file was deleted.