Browse Source

Do not destroy m_debug_line in release mode

Daniele Bartolini 11 năm trước cách đây
mục cha
commit
0f06853380
1 tập tin đã thay đổi với 3 bổ sung1 xóa
  1. 3 1
      engine/physics/PhysicsWorld.cpp

+ 3 - 1
engine/physics/PhysicsWorld.cpp

@@ -296,7 +296,9 @@ PhysicsWorld::~PhysicsWorld()
 	m_controller_manager->release();
 	m_scene->release();
 
-	m_world.destroy_debug_line(m_debug_line);
+	#if defined(CROWN_DEBUG) || defined(CROWN_DEVELOPMENT)
+		m_world.destroy_debug_line(m_debug_line);
+	#endif
 }
 
 //-----------------------------------------------------------------------------