|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectcom.threerings.util.ShallowObject
com.threerings.tudey.server.logic.Logic
com.threerings.tudey.server.logic.ScriptLogic
com.threerings.tudey.server.logic.ScriptLogic.Move
public static class ScriptLogic.Move
Handles a move script.
| Nested Class Summary |
|---|
| Nested classes/interfaces inherited from class com.threerings.tudey.server.logic.ScriptLogic |
|---|
ScriptLogic.Action, ScriptLogic.ClearSpeed, ScriptLogic.Condition, ScriptLogic.Goto, ScriptLogic.Move, ScriptLogic.Rotate, ScriptLogic.SetSpeed, ScriptLogic.Wait |
| Nested classes/interfaces inherited from class com.threerings.tudey.server.logic.Logic |
|---|
Logic.ShapeObserver |
| Field Summary | |
|---|---|
protected Logic |
_finalTarget
The target location. |
protected Vector2f[] |
_path
The path. |
protected int |
_pidx
The index of the next point on the path. |
protected TargetLogic |
_target
The move target. |
| Fields inherited from class com.threerings.tudey.server.logic.ScriptLogic |
|---|
_agent, _config, _scripted, MAX_PATH_LENGTH |
| Fields inherited from class com.threerings.tudey.server.logic.Logic |
|---|
_scenemgr, _variables |
| Constructor Summary | |
|---|---|
ScriptLogic.Move()
|
|
| Method Summary | |
|---|---|
protected void |
createPath()
Create the movement path. |
protected void |
didInit()
Override to perform custom initialization. |
protected boolean |
finishedMove()
Checks if we've reached our target. |
protected void |
finishMove()
Position ourselves exactly on our target. |
protected float |
getReachRadius()
Returns the radius within which we can be consider ourselves to have reached a node (which depends on the actor's speed, since it's possible to overshoot). |
void |
start(int timestamp)
Called when we are about to start the current script. |
void |
suspend()
Called when we are suspending the current script. |
boolean |
tick(int timestamp)
Ticks the script. |
void |
transfer(Logic source,
Map<Object,Object> refs)
Transfers state from the specified source logic. |
| Methods inherited from class com.threerings.tudey.server.logic.ScriptLogic |
|---|
createScriptLogic, init, reachedTargetRotation, shutdown |
| Methods inherited from class com.threerings.tudey.server.logic.Logic |
|---|
addShapeObserver, createAction, createCondition, createExpression, createHandler, createRegion, createTarget, getEntityKey, getModel, getPatrolPath, getRotation, getSceneManager, getShape, getTags, getTransform, getTransform, getTranslation, getVariable, init, isActive, isDefaultEntrance, isVisible, removeShapeObserver, request, resolveTarget, setVariable, signal |
| Methods inherited from class com.threerings.util.ShallowObject |
|---|
equals, hashCode |
| Methods inherited from class java.lang.Object |
|---|
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
protected TargetLogic _target
protected Vector2f[] _path
protected int _pidx
protected Logic _finalTarget
| Constructor Detail |
|---|
public ScriptLogic.Move()
| Method Detail |
|---|
public void start(int timestamp)
ScriptLogic
start in class ScriptLogicpublic boolean tick(int timestamp)
ScriptLogic
tick in class ScriptLogicpublic void suspend()
ScriptLogic
suspend in class ScriptLogic
public void transfer(Logic source,
Map<Object,Object> refs)
Logic
transfer in class Logicprotected float getReachRadius()
protected void createPath()
protected boolean finishedMove()
protected void finishMove()
protected void didInit()
ScriptLogic
didInit in class ScriptLogic
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||