Last active
August 29, 2015 14:07
-
-
Save AgentRev/4caeb6dd68a7cf0310a8 to your computer and use it in GitHub Desktop.
First Person Cam
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// @file Name: cameraChecks.sqf | |
// @file Author: AgentRev | |
if (!hasInterface) exitWith {}; | |
private ["_fpOnFoot", "_forceFP"]; | |
_fpOnFoot = (difficultyEnabled "3rdPersonView" && ["A3W_firstPersonCamOnFoot"] call isConfigOn); | |
while {true} do | |
{ | |
waitUntil | |
{ | |
_forceFP = (_fpOnFoot && alive player && cameraOn == player); | |
((_forceFP && cameraView == "EXTERNAL") || cameraView == "GROUP") | |
}; | |
if (cameraView == "GROUP") then | |
{ | |
cameraOn switchCamera "EXTERNAL"; | |
}; | |
if (_forceFP && cameraView == "EXTERNAL") then | |
{ | |
cameraOn switchCamera "INTERNAL"; | |
}; | |
}; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment