trying to make physics engine work