Class: Client

Client()

Representation of a client (user, bot, remote server...).

Constructor

new Client()

Source:

Extends

Classes

Client

Members

_isLoaded

Internal, set by WorldManager after the mesh/script has loaded.
Overrides:
Source:

active

Active i.e. online users
Overrides:
Source:

animation

Active animation
Overrides:
Source:

className

Server-side class name
Overrides:
Source:

id

Id, equal on server and all instances
Overrides:
Source:

listeners

Event listeners. Typically world manager listens to changes, and moves objects around.
Overrides:
Source:

loadListeners

Load listeners, functions that trigger after the mesh or script is loaded. Managed by WorldManager. CHECKME SoC
Overrides:
Source:

mesh

URL of 3D mesh
Overrides:
Source:

name

Client name, must be unique
Source:

permanent

Default false, permanent objects remain in the scene forever
Overrides:
Source:

position

Position, Point
Overrides:
Source:

properties

Custom properties of an object - shared transient object
Overrides:
Source:

rotation

Rotation, Point
Overrides:
Source:

scale

Scale, Point
Overrides:
Source:

sceneProperties

Scene properties
Source:

script

URL of dynamically loaded script TODO
Overrides:
Source:

temporary

Everything created by guest client is by default temporary
Overrides:
Source:

tokens

Private tokens
Source:

VRSPACE

Handy reference to VRSpace instance
Overrides:
Source:

Methods

addListener()

Add a change listener to the object.
Overrides:
Source:

addLoadListener()

Add a load listener function to the object. Triggers immediatelly if mesh/script has already loaded (_isLoaded is true).
Overrides:
Source:

getNameOrId()

Handy function, returns name if not null, else class and id
Source:

notifyListeners()

Called when server sends notification that the object has changed. Notifies all listeners of object and changes.
Overrides:
Source:

notifyLoadListeners()

Triggers all load listeners
Overrides:
Source:

publish()

Publish the object to the server. Can be used only on new objects.
Overrides:
Source:

removeListener()

Remove the listener.
Overrides:
Source:

removeLoadListener()

Remove a load listener.
Overrides:
Source: