com.jpemartin.jgt
Class FireRandom

java.lang.Object
  extended by com.jpemartin.jgt.FireRandom
All Implemented Interfaces:
FireControl

public class FireRandom
extends java.lang.Object
implements FireControl

Fire control that fires at random, with the given probability


Constructor Summary
FireRandom(double probabilityOfFiring)
           
 
Method Summary
 boolean shouldFire()
          fire with the given probability
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

FireRandom

public FireRandom(double probabilityOfFiring)
Method Detail

shouldFire

public boolean shouldFire()
fire with the given probability

Specified by:
shouldFire in interface FireControl