瀏覽代碼

implemente create_plane

mikymod 12 年之前
父節點
當前提交
b398c2950f
共有 1 個文件被更改,包括 3 次插入2 次删除
  1. 3 2
      engine/physics/Actor.cpp

+ 3 - 2
engine/physics/Actor.cpp

@@ -98,9 +98,10 @@ void Actor::create_box(const Vector3& position, float a, float b, float c)
 }
 
 //-----------------------------------------------------------------------------
-void Actor::create_plane(const Vector3& position, const Vector3& normal)
+void Actor::create_plane(const Vector3& /*position*/, const Vector3& /*normal*/)
 {
-	// TODO
+	Shape shape(m_actor->createShape(physx::PxPlaneGeometry(), *m_mat));
+	m_physics_graph.create(m_sg_node, shape);
 }
 
 //-----------------------------------------------------------------------------