The 'Space' global accessible in every script (for C# scripts, this inherits from the SpaceScript base class)
Allows access to the users inventory
Space.Inventory.Authorize()
Stores information between user sessions, and for other users
Space.Persistence.RetrieveValue("value1")
Allows access to the current scene graph (objects and avatars in the scene, and other information)
Space.Scene.PlayerAvatar
Access information about the current scripting runtime host
Space.Host.StartCoroutine(CoFunc)
Call physics-related commands, and variables, such as raycasting
Space.Physics.RayCast(trans.WorldPosition,trans.Forward,50)
Math related functions (Sin, Cos, Tan, etc)
Space.Math.Ceil(4.0)
Miscellaneous additional string functions (e.g. MD5Sum)
Space.String.GetBytes("some data")
Input device related functions (mouse position, keyboard state)
Space.Input.Vibrate(1,1,false)
Take and control the users camera
obj = Space.Host.ExecutingObject Space.Camera.LockCamera (obj)
Call remote web services to designated hosts (will not work with arbitrary domains, see page for details)
Space.WebServices.GetImage("example.com/mrlee.jpg")
Send data to other clients through the region server
Space.Network.SubscribeToNetwork("helloworld", gotAMessageFunction)
The current viewer time - this will usually correlate with the number of seconds the player has been in the current scene, increments each frame, typically used for animation/tweening
currentTime = Space.Time
The current server time - usually UTC, as according to the login server.
serverTime = Space.ServerTime
The current time between this frame, and the previous frame, as used in Update, LateUpdate events, if moving a object, you can multiply it by DeltaTime to get a consistent speed
deltaTime = Space.DeltaTime
Logs the message to the script debug console
Space.Log("Hello World!")
Returns a resource with its name.
--Print "Texture" when it is exists.
Log a message to console.
Space.Log("Log",true)
Return current RuntimeType name.
Return current platform name.
Return the type name of the value.
Return current SessionID.
Always return false on the main grid.
Return true if in unity editor.
Return all resources.
Returns time at the beginning of this frame.
Returns current server time.
Returns current local time.
Returns server unix timestamp.
Returns local unix timestamp.
The completion time in seconds since the last frame.
Return true if in preview server.
|