2018-09-17 19:19:29 +00:00
|
|
|
#include "script_component.hpp"
|
2017-08-12 13:25:48 +00:00
|
|
|
/*
|
2023-08-17 10:02:17 +00:00
|
|
|
* Author: Nelson Duarte, kymckay
|
2017-08-12 13:25:48 +00:00
|
|
|
* Function used to set camera slow speed mode
|
|
|
|
*
|
|
|
|
* Arguments:
|
|
|
|
* 0: Enable slow speed <BOOL>
|
|
|
|
*
|
|
|
|
* Return Value:
|
|
|
|
* None
|
|
|
|
*
|
|
|
|
* Example:
|
|
|
|
* [true] call ace_spectator_fnc_cam_toggleSlow
|
|
|
|
*
|
|
|
|
* Public: No
|
|
|
|
*/
|
|
|
|
|
|
|
|
params ["_slowSpeed"];
|
|
|
|
|
2021-02-27 17:05:05 +00:00
|
|
|
if (GVAR(camSlow) isNotEqualTo _slowSpeed) then {
|
2017-08-12 13:25:48 +00:00
|
|
|
private _camera = GVAR(camera);
|
|
|
|
|
|
|
|
if (GVAR(camMode) == MODE_FREE) then {
|
|
|
|
GVAR(camSlow) = _slowSpeed;
|
|
|
|
|
|
|
|
if (_slowSpeed) then {
|
|
|
|
_camera camCommand format ["speedDefault %1", SPEED_SLOW];
|
|
|
|
} else {
|
|
|
|
_camera camCommand format ["speedDefault %1", SPEED_DEFAULT];
|
|
|
|
};
|
|
|
|
} else {
|
|
|
|
_camera camCommand format ["speedDefault %1", SPEED_DEFAULT];
|
|
|
|
GVAR(camSlow) = false;
|
|
|
|
};
|
|
|
|
};
|