wiki.sine.space | sinespace

Difference between revisions of "Scripting/SVirtualCamera"

From wiki.sine.space
Jump to: navigation, search
(Replaced content with "This page has moved to: https://docs.sine.space/v/scripting/client-scripting/components/svirtualcamera")
 
Line 1: Line 1:
=Properties=
+
This page has moved to: https://docs.sine.space/v/scripting/client-scripting/components/svirtualcamera
 
+
{{ScriptFunction|bool|Enabled|{get; set;}|Is this virtual camera enabled?|5=
+
local camera=Space.Host.GetReference("Camera").VirtualCamera<br>
+
Space.Log(camera.Enabled)|6=<pre>--clicking this object will Enable/Disable it's Virtual Camera component
+
thisGameObject = Space.Host.ExecutingObject
+
component = thisGameObject.VirtualCamera
+
 
+
OnClick = function()
+
component.Enabled =  not component.Enabled
+
end
+
 
+
 
+
thisGameObject.AddClickable()
+
thisGameObject.Clickable.OnClick(OnClick)</pre>
+
}}
+
 
+
 
+
{{ScriptFunction|float|FieldOfView|{get; set;}|Field of view of this virtual camera.|5=
+
local camera=Space.Host.GetReference("Camera").VirtualCamera<br>
+
Space.Log(camera.FieldOfView)
+
}}
+
 
+
{{ScriptFunction|float|Dutch|{get; set;}|Dutch of view of this virtual camera. In degrees.|5=
+
local camera=Space.Host.GetReference("Camera").VirtualCamera<br>
+
Space.Log(camera.Dutch)
+
}}
+
 
+
{{ScriptFunction|float|NearClip|{get; set;}|The near clip plane of this virtual camera.|5=
+
local camera=Space.Host.GetReference("Camera").VirtualCamera<br>
+
Space.Log(camera.NearClip)
+
}}
+
 
+
{{ScriptFunction|float|FarClip|{get; set;}|The far clip plane of this virtual camera.|5=
+
local camera=Space.Host.GetReference("Camera").VirtualCamera<br>
+
Space.Log(camera.FarClip)
+
}}
+
 
+
{{ScriptFunction|float|OrthographicSize|{get; set;}|The orthographic size of this virtual camera.|5=
+
local camera=Space.Host.GetReference("Camera").VirtualCamera<br>
+
Space.Log(camera.OrthographicSize)
+
}}
+
 
+
{{ScriptFunction|int|Priority|{get; set;}|The priority of this virtual camera. Higher priority cameras will be used over lower priority cameras when conflicted.|5=
+
local camera=Space.Host.GetReference("Camera").VirtualCamera<br>
+
Space.Log(camera.Priority)
+
}}
+
 
+
{{ScriptFunction|SGameObject|Follow|{get; set;}|The object that this virtual camera should be following.|5=
+
local camera=Space.Host.GetReference("Camera").VirtualCamera<br>
+
Space.Log(camera.Follow.Name)
+
}}
+
 
+
{{ScriptFunction|SGameObject|LookAt|{get; set;}|The object that this virtual camera should be looking at.|5=
+
local camera=Space.Host.GetReference("Camera").VirtualCamera<br>
+
Space.Log(camera.LookAt.Name)
+
}}
+
 
+
 
+
{{Scripting Navbox}}
+

Latest revision as of 06:49, 19 September 2022

This page has moved to: https://docs.sine.space/v/scripting/client-scripting/components/svirtualcamera