Fix two issues with pivot points (#382)
- ResetPivotPoint() now truely resets the pivot point (and not only invalidating it). - The copy constructor of lcPiece now also copies the state of the pivot point. Thus, duplicating pieces also duplicates the pivot points.
This commit is contained in:
committed by
Leonardo Zide
parent
5b857ccf65
commit
516ddcbf7e
@@ -44,7 +44,9 @@ lcPiece::lcPiece(const lcPiece& Other)
|
||||
mStepHide = Other.mStepHide;
|
||||
mGroup = Other.mGroup;
|
||||
mFileLine = -1;
|
||||
|
||||
mPivotMatrix = Other.mPivotMatrix;
|
||||
mState |= ( Other.mState & LC_PIECE_PIVOT_POINT_VALID );
|
||||
|
||||
mPositionKeys = Other.mPositionKeys;
|
||||
mRotationKeys = Other.mRotationKeys;
|
||||
|
||||
@@ -535,6 +535,7 @@ public:
|
||||
void ResetPivotPoint()
|
||||
{
|
||||
mState &= ~LC_PIECE_PIVOT_POINT_VALID;
|
||||
mPivotMatrix = lcMatrix44Identity();
|
||||
}
|
||||
|
||||
public:
|
||||
|
||||
Reference in New Issue
Block a user