Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 10 additions & 4 deletions librtt/Display/Rtt_ShapeAdapterMesh.cpp
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
//////////////////////////////////////////////////////////////////////////////
//
// This file is part of the Corona game engine.
// With contributions from Dianchu Technology
// For overview and more information on licensing please refer to README.md
// Home page: https://github.com/coronalabs/corona
// Contact: support@coronalabs.com
Expand Down Expand Up @@ -602,11 +603,16 @@ int ShapeAdapterMesh::setVertex( lua_State *L )
}

Vertex2& orig = tesselator->GetMesh().WriteAccess()[vertIndex];

if( !Rtt_RealEqual(x, orig.x) || !Rtt_RealEqual(y, orig.y) || zChanged)

bool xyChanged = !Rtt_RealEqual( x, orig.x ) || !Rtt_RealEqual( y, orig.y );
if ( xyChanged || zChanged )
{
orig.x = x;
orig.y = y;
if ( xyChanged )
{
orig.x = x;
orig.y = y;
tesselator->Invalidate();
}

path->Invalidate( ClosedPath::kFillSource |
ClosedPath::kStrokeSource );
Expand Down