Fixed a case where drag and drop a submodel didn't do anything.

This commit is contained in:
Leonardo Zide
2020-02-01 11:34:56 -08:00
parent 60aca425a0
commit fb7f952e98
4 changed files with 6 additions and 5 deletions
+2 -2
View File
@@ -521,7 +521,7 @@ void lcPiece::DrawInterface(lcContext* Context, const lcScene& Scene) const
const lcVector3& Max = BoundingBox.Max;
lcVector3 Edge((Max - Min) * 0.33f);
float LineVerts[48][3] =
const float LineVerts[48][3] =
{
{ Max[0], Max[1], Max[2] }, { Max[0] - Edge[0], Max[1], Max[2] },
{ Max[0], Max[1], Max[2] }, { Max[0], Max[1] - Edge[1], Max[2] },
@@ -593,7 +593,7 @@ void lcPiece::DrawInterface(lcContext* Context, const lcScene& Scene) const
Context->DrawIndexedPrimitives(GL_LINES, 24, GL_UNSIGNED_SHORT, 0);
}
if (AreControlPointsVisible())
if (!mControlPoints.IsEmpty() && AreControlPointsVisible())
{
float Verts[8 * 3];
float* CurVert = Verts;