Sinespace Client  2023.2.17543
Client-side scripting for Sinespace
SineSpace.Scripting.Client.SInput Class Reference
Inheritance diagram for SineSpace.Scripting.Client.SInput:
ScriptClass< T > ScriptClassWrapper< T >

Public Member Functions

override void Initialise (SScript runtime, object wrapper)
 
bool GetKeyDown (string key)
 Returns whether a key has been depressed since the end of the last frame. More...
 
bool GetKeyUp (string key)
 
bool GetKey (string key)
 
bool GetMouseDown (int button)
 
bool GetMouseUp (int button)
 
bool GetMouseHold (int button)
 
void Vibrate (float intensity, float duration, bool leftHand)
 Vibrates the controller (or phone, or gamepad) if a rumble device is present. More...
 
- Public Member Functions inherited from ScriptClass< T >
void ReportError (string error, bool fatal, UnityEngine.Object target=null)
 
- Public Member Functions inherited from ScriptClassWrapper< T >
override void Initialise (SScript runtime, object wrapper)
 

Properties

float ScrollWheel [get]
 
SVector MousePosition [get]
 
SVector MovementAxis [get]
 
SVectorTurnAxis [get]
 
bool MouseLook [get, set]
 
float MouseX [get]
 
float MouseY [get]
 
bool ClickToWalk [get, set]
 
bool Fire [get]
 
bool AltFire [get]
 
bool CursorInUI [get]
 
- Properties inherited from ScriptClass< T >
override bool Alive [get]
 Return if the component is alive. More...
 
virtual bool Alive [get]
 
DynValue CachedData [get, set]
 
- Properties inherited from ScriptClassWrapper< T >
_wrap [get]
 

Additional Inherited Members

- Protected Member Functions inherited from ScriptClass< T >
void Initialise (SScript runtime)
 

Member Function Documentation

◆ GetKey()

bool SineSpace.Scripting.Client.SInput.GetKey ( string  key)

◆ GetKeyDown()

bool SineSpace.Scripting.Client.SInput.GetKeyDown ( string  key)

Returns whether a key has been depressed since the end of the last frame.

Parameters
key
Returns

◆ GetKeyUp()

bool SineSpace.Scripting.Client.SInput.GetKeyUp ( string  key)

◆ GetMouseDown()

bool SineSpace.Scripting.Client.SInput.GetMouseDown ( int  button)

◆ GetMouseHold()

bool SineSpace.Scripting.Client.SInput.GetMouseHold ( int  button)

◆ GetMouseUp()

bool SineSpace.Scripting.Client.SInput.GetMouseUp ( int  button)

◆ Initialise()

override void SineSpace.Scripting.Client.SInput.Initialise ( SScript  runtime,
object  wrapper 
)
virtual

Implements ScriptClass< T >.

◆ Vibrate()

void SineSpace.Scripting.Client.SInput.Vibrate ( float  intensity,
float  duration,
bool  leftHand 
)

Vibrates the controller (or phone, or gamepad) if a rumble device is present.

Parameters
intensityIntensity from 0 to 1.0
durationDuration (max 1.0s)
leftHandRumble on the left hand (false = right hand), where applicable.

Property Documentation

◆ AltFire

bool SineSpace.Scripting.Client.SInput.AltFire
get

◆ ClickToWalk

bool SineSpace.Scripting.Client.SInput.ClickToWalk
getset

◆ CursorInUI

bool SineSpace.Scripting.Client.SInput.CursorInUI
get

◆ Fire

bool SineSpace.Scripting.Client.SInput.Fire
get

◆ MouseLook

bool SineSpace.Scripting.Client.SInput.MouseLook
getset

◆ MousePosition

SVector SineSpace.Scripting.Client.SInput.MousePosition
get

◆ MouseX

float SineSpace.Scripting.Client.SInput.MouseX
get

◆ MouseY

float SineSpace.Scripting.Client.SInput.MouseY
get

◆ MovementAxis

SVector SineSpace.Scripting.Client.SInput.MovementAxis
get

◆ ScrollWheel

float SineSpace.Scripting.Client.SInput.ScrollWheel
get

◆ TurnAxis

SVector? SineSpace.Scripting.Client.SInput.TurnAxis
get