source.ucregents.playground.physics
Class ScaledMassFieldForce

java.lang.Object
  extended by source.ucregents.playground.physics.BaseEntity
      extended by source.ucregents.playground.physics.BaseFieldForceEntity
          extended by source.ucregents.playground.physics.ScaledMassFieldForce
All Implemented Interfaces:
java.lang.Cloneable, IForceEntity

public class ScaledMassFieldForce
extends BaseFieldForceEntity


Constructor Summary
ScaledMassFieldForce()
           
ScaledMassFieldForce(int x_loc, int y_loc, int width, int height)
           
ScaledMassFieldForce(PolygonOrCircle forceShape, boolean isVisible)
           
 
Method Summary
 javax.vecmath.Vector2d getForceFor(MovingEntity be)
          Calculates the force to act on another entity
 double getForceScalar()
           
 void setForceScalar(double forceScalar)
           
 
Methods inherited from class source.ucregents.playground.physics.BaseFieldForceEntity
clone, DefaultImageLocation, Draw, getResizingObject, IntersectsWith, isCollidable, OnCenterScale, OnLocationChange, OnULScale
 
Methods inherited from class source.ucregents.playground.physics.BaseEntity
calculateAxes, Deserialize, getActualFrameDimensions, getAxes, getAxesClone, getAxis, getBounciness, getCenterPoint, getDrawType, getEvents, getFrameColor, getFrictionConstant, getGradientColor, getImageOffset, getName, getOrientation, getRoundedShapeMass, getScale, getShape, getShapeColor, getShapeFrame, getShapeMass, getSideVectors, getULPoint, getUserEvents, getVertexCount, getVerticesCoordinates, isCircle, isOverlapping, isPolygon, isSelected, isVisible, OnCollisionWith, OnOrientationChange, RegisterEvent, RegisterEvent, RegisterEvents, RemoveEvent, RemoveEvents, resetFrameColor, Scale, ScaleAroundCenter, Serialize, setBounciness, setCenterPoint, setCenterPoint, setCollidable, setDrawType, setFrameColor, setFrictionConstant, setGradientColor, setImageOffset, setName, setOrientation, setScale, setSelected, setShapeColor, setULPoint, setULPoint, setVisible, toString, toXMLElement
 
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

ScaledMassFieldForce

public ScaledMassFieldForce()

ScaledMassFieldForce

public ScaledMassFieldForce(int x_loc,
                            int y_loc,
                            int width,
                            int height)

ScaledMassFieldForce

public ScaledMassFieldForce(PolygonOrCircle forceShape,
                            boolean isVisible)
Method Detail

getForceFor

public javax.vecmath.Vector2d getForceFor(MovingEntity be)
Description copied from interface: IForceEntity
Calculates the force to act on another entity

Parameters:
be - The force is calculated for this entity
Returns:
A vector2d of the force to act on the parameter entity

getForceScalar

public double getForceScalar()

setForceScalar

public void setForceScalar(double forceScalar)