update ship class and make it more readable