uwcse.sim
Class OilBlob

java.lang.Object
  |
  +--uwcse.sim.OilThing
        |
        +--uwcse.sim.OilBlob
All Implemented Interfaces:
Thing

class OilBlob
extends OilThing

A blob of oil doesn't do much besides kill algae and Fish.


Fields inherited from class uwcse.sim.OilThing
alive, rand, world, x, y
 
Constructor Summary
OilBlob(WorldModel wm, int x, int y)
          Create a new oil blob.
 
Method Summary
 void action()
          Float about at random, checking neighbors.
 void displayOn(uwcse.graphics.GWindow g)
          Display as black blob.
 void interact(OilThing t)
          Kills fish and algae.
 
Methods inherited from class uwcse.sim.OilThing
checkNeighbors, getX, getY, isAlive, kill, toString
 
Methods inherited from class java.lang.Object
, clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

OilBlob

public OilBlob(WorldModel wm,
               int x,
               int y)
Create a new oil blob.
Method Detail

displayOn

public void displayOn(uwcse.graphics.GWindow g)
Display as black blob.
Overrides:
displayOn in class OilThing

action

public void action()
Float about at random, checking neighbors.
Overrides:
action in class OilThing

interact

public void interact(OilThing t)
Kills fish and algae.
Overrides:
interact in class OilThing