package entities.player; public class Mass { private Acceleration acceleration; private double value; public Mass(Acceleration acceleration) { this.acceleration = acceleration; } public void setValue(double x) { this.value = x; acceleration.updateByMass(value); } public double getValue() { return value; } }