Made entity.update take the world as a param