org.game.JVirus
Class AnimImage

java.lang.Object
  |
  +--org.game.JVirus.AnimImage

public class AnimImage
extends java.lang.Object

simply a array if images.


Field Summary
protected  java.awt.Image[] array
          image array
protected  int number
          current image number
 
Constructor Summary
AnimImage(java.awt.Image[] img_arr)
          simply constructor
 
Method Summary
 java.awt.Image nextImage()
          get the current image.
 void reset()
          reset image counter to 0
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

array

protected java.awt.Image[] array
image array

number

protected int number
current image number
Constructor Detail

AnimImage

public AnimImage(java.awt.Image[] img_arr)
simply constructor
Parameters:
img_arr - list with images
Method Detail

reset

public void reset()
reset image counter to 0

nextImage

public java.awt.Image nextImage()
get the current image. If index of the array is >=, then set index zo 0 and start from beginning.