pluginSDK
Class Obstacle

java.lang.Object
  |
  +--pluginSDK.Entity
        |
        +--pluginSDK.Obstacle
All Implemented Interfaces:
Plugin, Serializable

public abstract class Obstacle
extends Entity

Title: the Wondrous Farm
Description: La classe de base des plugins d'obstacles de la simulation
Copyright: Copyright (c) 2002
Company: minfo

See Also:
Serialized Form

Field Summary
private  int type
           
 
Fields inherited from class pluginSDK.Entity
h, IS_BEHAVIOUR, IS_BOID, IS_MOTHER, IS_OBSTACLE, isLeader, isSelected, myColor, myWorld, path, w, x, y
 
Constructor Summary
Obstacle()
           
Obstacle(int X, int Y)
           
 
Method Summary
abstract  void drawEntity(Graphics g)
           
abstract  String getKind()
          Renvoie le type de Boids ou d'obstacles auquels on a affaire.
 int getType()
          Renvoie une constante entière qui permet de savoir si on affaire à un Boids, un Obstacle, ...
C'est pour faire un peu plus propre et plus léger que le instanceof
 
Methods inherited from class pluginSDK.Entity
computeTargetHeading, directionDepuisUnPoint, distanceDepuisUnPoint, getBehaviour, getHeight, getPath, getPosX, getPosY, getSelected, getWidth, getWorld, isLeader, isLeader, seekNearest, seekNearest, setHeight, setMyColor, setPath, setPosX, setPosY, setSelected, setWidth, setWorld, toString, whatIsMyColor
 
Methods inherited from class java.lang.Object
, clone, equals, finalize, getClass, hashCode, notify, notifyAll, registerNatives, wait, wait, wait
 

Field Detail

type

private int type
Constructor Detail

Obstacle

public Obstacle()

Obstacle

public Obstacle(int X,
                int Y)
Method Detail

getType

public int getType()
Description copied from interface: Plugin
Renvoie une constante entière qui permet de savoir si on affaire à un Boids, un Obstacle, ...
C'est pour faire un peu plus propre et plus léger que le instanceof
Overrides:
getType in class Entity
Following copied from interface: pluginSDK.Plugin
Returns:
int: le type du Boid

getKind

public abstract String getKind()
Description copied from interface: Plugin
Renvoie le type de Boids ou d'obstacles auquels on a affaire. En fait on ne s'en set pas.
Overrides:
getKind in class Entity
Following copied from interface: pluginSDK.Plugin
Returns:
String: la description du type de Boids ou d'obstacles.

drawEntity

public abstract void drawEntity(Graphics g)
Overrides:
drawEntity in class Entity