com.jme.math
Class SpringNodeForce

java.lang.Object
  extended bycom.jme.math.SpringNodeForce

public abstract class SpringNodeForce
extends java.lang.Object

SpringNodeForce is an abstract class defining an external force to be used with the SpringSystem class.

Version:
$Id: SpringNodeForce.java,v 1.1 2004/11/29 21:24:57 renanse Exp $
Author:
Joshua Slack

Constructor Summary
SpringNodeForce()
           
 
Method Summary
abstract  void apply(float dt, SpringNode node)
          Apply the force defined by this class on a given node.
 boolean isEnabled()
          Return whether or not this system is enabled.
 void setEnabled(boolean enabled)
          Set this force enabled or not.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SpringNodeForce

public SpringNodeForce()
Method Detail

setEnabled

public void setEnabled(boolean enabled)
Set this force enabled or not.

Parameters:
enabled - boolean

isEnabled

public boolean isEnabled()
Return whether or not this system is enabled.

Returns:
boolean

apply

public abstract void apply(float dt,
                           SpringNode node)
Apply the force defined by this class on a given node. Should do this by making a call to node.acceleration.addLocal(....);

Parameters:
dt - amount of time since last apply call in ms.
node - the node to apply the force to.