Terraria v1.4.4.9
Terraria source code documentation
Loading...
Searching...
No Matches

◆ ToggleCamera()

void Terraria.Graphics.Capture.CaptureInterface.ToggleCamera ( bool On = true)
inline

Definition at line 1001 of file CaptureInterface.cs.

1002 {
1003 if (CameraLock)
1004 {
1005 return;
1006 }
1007 bool active = Active;
1008 Active = Modes.ContainsKey(SelectedMode) && On;
1009 if (active != Active)
1010 {
1011 SoundEngine.PlaySound(On ? 10 : 11);
1012 }
1014 {
1015 mode.Value.ToggleActive(Active && mode.Key == SelectedMode);
1016 }
1017 if (On && !active)
1018 {
1019 JustActivated = true;
1020 }
1021 }
static void PlaySound(int type, Vector2 position, int style=1)
static Dictionary< int, CaptureInterfaceMode > Modes

References Terraria.Graphics.Capture.CaptureInterface.Active, Terraria.Graphics.Capture.CaptureInterface.CameraLock, Terraria.Graphics.Capture.CaptureInterface.JustActivated, Terraria.Graphics.Capture.CaptureInterface.Modes, Terraria.Audio.SoundEngine.PlaySound(), and Terraria.Graphics.Capture.CaptureInterface.SelectedMode.

Referenced by Terraria.Graphics.Capture.CaptureInterface.Update(), and Terraria.Graphics.Capture.CaptureInterface.UpdateButtons().