public void destroyBodies(){
		rayHandler.removeAll();
		//record last position of entity so it can be saved
		for (Entity e : objects) {
			if(e==null) continue;
			if(e.getBody()==null) continue;
			Vector2 lastPos = e.getPixelPosition();
			if (e instanceof Mob) {
				lastPos.y -= ((Mob)e).rh;	//this offset allows entity to be spawned from right location
				if(((Mob)e).getCurrentState().resetType.equals(ResetType.ON_LEVEL_CHANGE))
					((Mob)e).resetState();
			}
			e.setPosition(lastPos);
			e.addLight(null);
		}

		//destroy all the bodies
		Array<Body> tmp = new Array<Body>();
		world.getBodies(tmp);
		for(Body b : tmp) {
			world.destroyBody(b);
		}
		//invalidate references to the destroyed bodies
		for (Entity e : objects) {
			if (e == null) continue;
			if (e.getBody() == null) continue;
			e.setBody(null);
		}
	}