mirror of
https://github.com/acemod/ACE3.git
synced 2024-08-30 18:23:18 +00:00
Enforcing the speed limit
This commit is contained in:
parent
341f3a253e
commit
0d798264b0
@ -137,7 +137,7 @@ switch (toLower _mode) do {
|
|||||||
if (GVAR(ctrlKey)) then {
|
if (GVAR(ctrlKey)) then {
|
||||||
GVAR(camZoom) = ((GVAR(camZoom) + _zChange * 0.1) max 0.01) min 2;
|
GVAR(camZoom) = ((GVAR(camZoom) + _zChange * 0.1) max 0.01) min 2;
|
||||||
} else {
|
} else {
|
||||||
GVAR(camSpeed) = (GVAR(camSpeed) + _zChange * 0.2) max 0.05;
|
GVAR(camSpeed) = ((GVAR(camSpeed) + _zChange * 0.2) max 0.05) min 10;
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
case "onmousemoving": {
|
case "onmousemoving": {
|
||||||
|
@ -31,8 +31,8 @@ _deltaX = _oldX - _x;
|
|||||||
_deltaY = _oldY - _y;
|
_deltaY = _oldY - _y;
|
||||||
|
|
||||||
if (_leftButton) then {
|
if (_leftButton) then {
|
||||||
GVAR(camDolly) set [0, _deltaX * -10 * GVAR(camSpeed)];
|
GVAR(camDolly) set [0, _deltaX * -100 * GVAR(camSpeed)];
|
||||||
GVAR(camDolly) set [1, _deltaY * 10 * GVAR(camSpeed)];
|
GVAR(camDolly) set [1, _deltaY * 100 * GVAR(camSpeed)];
|
||||||
} else {
|
} else {
|
||||||
if (_rightButton) then {
|
if (_rightButton) then {
|
||||||
GVAR(camPan) = GVAR(camPan) - (_deltaX * 360);
|
GVAR(camPan) = GVAR(camPan) - (_deltaX * 360);
|
||||||
|
@ -52,8 +52,8 @@ if !(_vision in GVAR(availableVisions)) then {
|
|||||||
|
|
||||||
GVAR(camPan) = ((_heading % 360) max 0);
|
GVAR(camPan) = ((_heading % 360) max 0);
|
||||||
GVAR(camPosition) = (ATLtoASL _position);
|
GVAR(camPosition) = (ATLtoASL _position);
|
||||||
GVAR(camSpeed) = _speed;
|
GVAR(camSpeed) = (_speed min 0.05) max 10;
|
||||||
GVAR(camTilt) = ((_heading min -90) max 90);
|
GVAR(camTilt) = (_heading min -89) max 89;
|
||||||
GVAR(camUnit) = _unit;
|
GVAR(camUnit) = _unit;
|
||||||
GVAR(camVision) = _vision;
|
GVAR(camVision) = _vision;
|
||||||
GVAR(camZoom) = (_zoom min 2) max 0;
|
GVAR(camZoom) = (_zoom min 2) max 0;
|
||||||
|
Loading…
Reference in New Issue
Block a user