Fixed physic related bugs