import java.awt.Color;
import java.awt.Graphics;

public class FlashingBlock extends Block{
	//Overview: A FlashingBlock is a changable color block.
	//If the hp changes its value, the block changes its color.
	
	public FlashingBlock(){
		super(true,3,Color.red);
		 
	}
	public void drawImage(Graphics g, int x, int y, int w, int h){
		switch(hp){
			case 0:
				g.setColor(getColor());
				break;
			case 1:
				g.setColor(Color.blue);
				break;
			case 2:
				g.setColor(Color.white);
				break;
			case 3:
				g.setColor(Color.red);
				break;
		}
		g.fillRect(x+1,y+1,w-2,h-2);
			
	}

}