public class InterpolatedWorldNode extends java.lang.Object implements WorldNode, BasicInterpolatable
Modifier and Type | Class and Description |
---|---|
class |
InterpolatedWorldNode.InterpolatedDirLocOrientTime
A utility class provided solely to return these values atomically
|
Modifier and Type | Field and Description |
---|---|
protected java.util.Set<WorldNode> |
children |
protected long |
clientLastUpdate |
protected AOVector |
dir |
protected boolean |
followsTerrain |
protected OID |
instanceOid |
protected Point |
interpLoc |
protected long |
lastInterp |
protected long |
lastUpdate |
protected EntityHandle |
objHandle |
protected Quaternion |
orient |
protected WorldNode |
parent |
protected PathInterpolator |
pathInterpolator |
protected Point |
rawLoc |
protected boolean |
spawned |
Constructor and Description |
---|
InterpolatedWorldNode() |
InterpolatedWorldNode(BasicWorldNode bnode) |
InterpolatedWorldNode(WorldManagerClient.ObjectInfo info) |
protected volatile EntityHandle objHandle
protected volatile boolean followsTerrain
protected volatile boolean spawned
protected volatile OID instanceOid
protected volatile Point rawLoc
protected volatile Point interpLoc
protected volatile AOVector dir
protected volatile Quaternion orient
protected transient volatile PathInterpolator pathInterpolator
protected volatile long lastUpdate
protected volatile long clientLastUpdate
protected volatile long lastInterp
protected volatile WorldNode parent
protected volatile java.util.Set<WorldNode> children
public InterpolatedWorldNode()
public InterpolatedWorldNode(BasicWorldNode bnode)
public InterpolatedWorldNode(WorldManagerClient.ObjectInfo info)
public java.lang.String toString()
toString
in class java.lang.Object
public OID getInstanceOid()
getInstanceOid
in interface Locatable
public void setInstanceOid(OID oid)
public long getLastUpdate()
getLastUpdate
in interface Locatable
public void setLastUpdate(long time)
setLastUpdate
in interface Locatable
public long getClientLastUpdate()
public void setClientLastUpdate(long time)
public void setObjectOID(OID oid)
public OID getObjectOID()
public Quaternion getOrientation()
getOrientation
in interface BasicInterpolatable
getOrientation
in interface WorldNode
public void setOrientation(Quaternion orient)
setOrientation
in interface BasicInterpolatable
setOrientation
in interface WorldNode
public void setDirLocOrient(BasicWorldNode bnode)
public InterpolatedWorldNode.InterpolatedDirLocOrientTime getDirLocOrientTime()
public java.util.Set<WorldNode> getChildren()
getChildren
in interface WorldNode
public void setChildren(java.util.Set<WorldNode> children)
setChildren
in interface WorldNode
public void removeChild(WorldNode child)
removeChild
in interface WorldNode
public void isSpawned(boolean spawned)
public PathInterpolator getPathInterpolator()
getPathInterpolator
in interface BasicInterpolatable
public void setPathInterpolator(PathInterpolator pathInterpolator)
public PathLocAndDir interpolate(float t)
public AOVector getDir()
getDir
in interface BasicInterpolatable
public void setDir(AOVector dir)
setDir
in interface BasicInterpolatable
public void setDirNoInterpolate(AOVector dir)
protected void changeDir(AOVector dir, boolean performDirInterpolation)
public Point getRawLoc()
getRawLoc
in interface BasicInterpolatable
public void setRawLoc(Point p)
setRawLoc
in interface BasicInterpolatable
public long getLastInterp()
getLastInterp
in interface BasicInterpolatable
public void setLastInterp(long time)
setLastInterp
in interface BasicInterpolatable
public Point getInterpLoc()
getInterpLoc
in interface BasicInterpolatable
public Point getCurrentLoc()
getCurrentLoc
in interface Locatable
protected void setInterpLoc(Point p)
public void setPathInterpolatorValues(long time, AOVector newDir, Point newLoc, Quaternion orientation)
setPathInterpolatorValues
in interface BasicInterpolatable
public boolean getFollowsTerrain()
public void setFollowsTerrain(boolean flag)