package Game;

public class NetGameBomb extends Bomb{

	public NetGameBomb(Game game, Role role) {
		super(game, role);
		// TODO Auto-generated constructor stub
	}

	public void update() {
		this.swellClock++;
		if (this.swellClock > Global.BOMB_EXPLODE_DELAY) {
			this.status = Global.BOMB_EXPLODE;
		}
		if (this.status == Global.BOMB_SWELL) {
			if (this.swellClock % 10 == 0) {
				bombLayer.setCell(col, row, bombLayer.getCell(col, row) % 3
						+ Global.IMAGE_BOMB_SWELL);
				return;
			}
		}

		if (explodeClock >= 5) {
			this.clearExplode();
			return;
		}

		if (this.status == Global.BOMB_EXPLODE) {
			explode();
		}
	}
}
