package com.kduda.battleships.models.units;

public abstract class Unit {
    private int health;

    public Unit(int size) {
        this.health = size;
    }

    public boolean isAlive() {
        return this.health > 0;
    }

    public void hit() {
        this.health--;
    }
}



/* public final int LENGTH;
    public final Orientation ORIENTATION;
    private int health;

    public Unit(int type, Orientation orientation) {
        this.LENGTH = type;
        this.health = type;
        this.ORIENTATION = orientation;
    }

    public boolean isAlive() {
        return this.health > 0;
    }

    public void hit() {

    }*/
@@ -283,361 +283,4 @@
  %7D%0A%7D
-%0A%0A%0A%0A/* public final int LENGTH;%0A    public final Orientation ORIENTATION;%0A    private int health;%0A%0A    public Unit(int type, Orientation orientation) %7B%0A        this.LENGTH = type;%0A        this.health = type;%0A        this.ORIENTATION = orientation;%0A    %7D%0A%0A    public boolean isAlive() %7B%0A        return this.health %3E 0;%0A    %7D%0A%0A    public void hit() %7B%0A%0A    %7D*/

Reformat code