ACE3/addons/markers/functions/fnc_canMove.sqf
commy2 3c41d37417 overhaul movable markers (#5922)
* overhaul movable markers

* moving markers setting

* disable debug

* fix conflict with map gestures
2018-01-05 18:55:00 +01:00

30 lines
663 B
Plaintext

/*
* Author: chris579
* Checks whether the player can move markers.
*
* Arguments:
* None
*
* Return Value:
* Whether the player can move markers <BOOL>
*
* Example:
* [] call ace_markers_fnc_canMove
*
* Public: No
*/
#include "script_component.hpp"
switch (GVAR(moveRestriction)) do {
case MOVE_RESTRICTION_NOBODY: {false};
case MOVE_RESTRICTION_ALL: {true};
case MOVE_RESTRICTION_ADMINS: {IS_ADMIN};
case MOVE_RESTRICTION_GROUP_LEADERS: {
leader ACE_player == ACE_player
};
case MOVE_RESTRICTION_GROUP_LEADERS_ADMINS: {
(leader ACE_player == ACE_player) || IS_ADMIN
};
default {true};
}; // return