|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object net.nexttext.behaviour.AbstractAction net.nexttext.behaviour.standard.MoveBy
public class MoveBy
Move an object by the given vector amount.
The vector amount is added to its position. The value of the Locatable is checked each time behave() is called, so a variable amount can be used.
Nested Class Summary |
---|
Nested classes/interfaces inherited from interface net.nexttext.behaviour.Action |
---|
Action.ActionResult |
Constructor Summary | |
---|---|
MoveBy(float x,
float y)
|
|
MoveBy(Locatable offset)
|
|
MoveBy(processing.core.PVector offset)
|
Method Summary | |
---|---|
Action.ActionResult |
behave(TextObject to)
Default behave method for single objects. |
void |
setTarget(float x,
float y)
Sets a target to approach. |
void |
setTarget(float x,
float y,
float z)
Sets a target to approach. |
void |
setTarget(Locatable offset)
Sets an offset to move by. |
void |
setTarget(processing.core.PVector target)
Sets a target to approach. |
Methods inherited from class net.nexttext.behaviour.AbstractAction |
---|
behave, behave, complete, getDisplayName, getRequiredProperties, makeBehaviour, properties, setDisplayName |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Methods inherited from interface net.nexttext.behaviour.Action |
---|
behave, behave, complete, getRequiredProperties |
Constructor Detail |
---|
public MoveBy(float x, float y)
public MoveBy(Locatable offset)
public MoveBy(processing.core.PVector offset)
Method Detail |
---|
public Action.ActionResult behave(TextObject to)
AbstractAction
This method does nothing; it should be overriden by subclasses if they wish to support actions on single objects.
Trying to call this method on an Action which doesn't override it will throw an UnsupportedActionException.
behave
in interface Action
behave
in class AbstractAction
public void setTarget(float x, float y)
setTarget
in interface TargetingAction
public void setTarget(float x, float y, float z)
setTarget
in interface TargetingAction
public void setTarget(processing.core.PVector target)
setTarget
in interface TargetingAction
public void setTarget(Locatable offset)
setTarget
in interface TargetingAction
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |