Class VRObject

  • Direct Known Subclasses:
    Client

    @Node
    public class VRObject
    extends Entity
    Basic VR Object encapsulates minimal spatial and other properties.
    Author:
    joe
    • Constructor Detail

      • VRObject

        public VRObject​(World world)
      • VRObject

        public VRObject​(Long id,
                        VRObject... vrObjects)
      • VRObject

        public VRObject​(Long id,
                        double x,
                        double y,
                        double z,
                        VRObject... vrObjects)
      • VRObject

        public VRObject​(double x,
                        double y,
                        double z)
      • VRObject

        public VRObject​(World world,
                        double x,
                        double y,
                        double z)
      • VRObject

        public VRObject()
    • Method Detail

      • addChildren

        public void addChildren​(VRObject... vrObjects)
      • isPermanent

        public boolean isPermanent()
      • addListener

        public void addListener​(VRObject obj)
      • removeListener

        public void removeListener​(VRObject obj)
      • notifyListeners

        public void notifyListeners​(VREvent event)
      • processEvent

        public void processEvent​(VREvent event)
        This implementation does nothing
        Parameters:
        event - Whatever has changed
      • getObjectId

        public ID getObjectId()
      • isActive

        public boolean isActive()
      • isTemporary

        public boolean isTemporary()
      • getWorld

        public World getWorld()
        World this object is in
      • getPosition

        public Point getPosition()
        Position in 3D space, used for spatial operations.
      • getRotation

        public Rotation getRotation()
      • getScale

        public Point getScale()
      • getPermanent

        public Boolean getPermanent()
        Permanent objects are always present (e.g. sky)
      • getTemporary

        public Boolean getTemporary()
        Temporary objects will be deleted from the database along with their owner
      • getActive

        public Boolean getActive()
        Whether an object is active (can send events). E.g. online users, robots.
      • getMesh

        public String getMesh()
        URL of the file containing the mesh.
      • getScript

        public String getScript()
      • getAnimation

        public Animation getAnimation()
        Currently active animation
      • getProperties

        public Map<String,​Object> getProperties()
        Custom object properties
      • getStreamId

        public String getStreamId()
      • setChildren

        public void setChildren​(List<VRObject> children)
      • setWorld

        public void setWorld​(World world)
        World this object is in
      • setPosition

        public void setPosition​(Point position)
        Position in 3D space, used for spatial operations.
      • setRotation

        public void setRotation​(Rotation rotation)
      • setScale

        public void setScale​(Point scale)
      • setPermanent

        public void setPermanent​(Boolean permanent)
        Permanent objects are always present (e.g. sky)
      • setTemporary

        public void setTemporary​(Boolean temporary)
        Temporary objects will be deleted from the database along with their owner
      • setActive

        public void setActive​(Boolean active)
        Whether an object is active (can send events). E.g. online users, robots.
      • setMesh

        public void setMesh​(String mesh)
        URL of the file containing the mesh.
      • setScript

        public void setScript​(String script)
      • setAnimation

        public void setAnimation​(Animation animation)
        Currently active animation
      • setProperties

        public void setProperties​(Map<String,​Object> properties)
        Custom object properties
      • setStreamId

        public void setStreamId​(String streamId)
      • hashCode

        public int hashCode()
        Overrides:
        hashCode in class Entity