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

Use new binocular magazine CBA functions and deprecate ACE functions #3814

Merged
merged 2 commits into from
May 30, 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
16 changes: 2 additions & 14 deletions addons/common/functions/fnc_binocularMagazine.sqf
Original file line number Diff line number Diff line change
Expand Up @@ -15,18 +15,6 @@
*/
#include "script_component.hpp"

params [["_unit", objNull, [objNull]]];
ACE_DEPRECATED("ace_common_fnc_binocularMagazine","3.8.0","CBA_fnc_binocularMagazine");

private _binocular = binocular _unit;

scopeName "main";

{
if ((_x select 0) isEqualTo _binocular) then {
// note: if there is no magazine, _x(4,0) will be nil, which skips the breakOut.
(_x select 4 select 0) breakOut "main";
};
false
} count weaponsitems _unit;

""
_this call CBA_fnc_binocularMagazine
2 changes: 1 addition & 1 deletion addons/common/functions/fnc_getAllGear.sqf
Original file line number Diff line number Diff line change
Expand Up @@ -64,5 +64,5 @@ if (isNull _unit) exitWith {[
handgunWeapon _unit, handgunItems _unit, handgunMagazine _unit,
assignedItems _unit,
binocular _unit,
[_unit] call FUNC(binocularMagazine)
[_unit] call CBA_fnc_binocularMagazine
]
11 changes: 2 additions & 9 deletions addons/common/functions/fnc_removeBinocularMagazine.sqf
Original file line number Diff line number Diff line change
Expand Up @@ -15,13 +15,6 @@
*/
#include "script_component.hpp"

params [["_unit", objNull, [objNull]]];
ACE_DEPRECATED("ace_common_fnc_removeBinocularMagazine","3.8.0","CBA_fnc_removeBinocularMagazine");

private _binocular = binocular _unit;
private _selectBinocular = currentWeapon _unit == _binocular;

_unit addWeapon _binocular;

if (_selectBinocular) then {
_unit selectWeapon _binocular;
};
_this call CBA_fnc_removeBinocularMagazine