class Circle extends Soldier { Circle(float x, float y) { super(x, y); } /* draws the soldier */ void draw() { // draw the shape first fill(colour); ellipse(xPos, yPos, strength+MIN_SIZE, strength+MIN_SIZE); // draw the number over it fill(0); text(strength, xPos, yPos); } /* if the other Soldier is not of the same type, makes them collide */ boolean collidesWith(Soldier other) { if (!(other instanceof Circle)) { return super.collidesWith(other); } return false; } }