Add world saving logic, register tick handler