Skip to content

Commit

Permalink
Rename oldTangentImpulse
Browse files Browse the repository at this point in the history
  • Loading branch information
notgiven688 committed Sep 1, 2024
1 parent cfe88fd commit d11dfac
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/Jitter2/Dynamics/Contact.cs
Original file line number Diff line number Diff line change
Expand Up @@ -557,10 +557,10 @@ public unsafe void Iterate(ContactData* cd)
float tangentImpulse1 = MassTangent1 * -vt1;
float tangentImpulse2 = MassTangent2 * -vt2;

float oldTangentImpulse = AccumulatedTangentImpulse1;
AccumulatedTangentImpulse1 = oldTangentImpulse + tangentImpulse1;
float oldTangentImpulse1 = AccumulatedTangentImpulse1;
AccumulatedTangentImpulse1 = oldTangentImpulse1 + tangentImpulse1;
AccumulatedTangentImpulse1 = Math.Clamp(AccumulatedTangentImpulse1, -maxTangentImpulse, maxTangentImpulse);
tangentImpulse1 = AccumulatedTangentImpulse1 - oldTangentImpulse;
tangentImpulse1 = AccumulatedTangentImpulse1 - oldTangentImpulse1;

float oldTangentImpulse2 = AccumulatedTangentImpulse2;
AccumulatedTangentImpulse2 = oldTangentImpulse2 + tangentImpulse2;
Expand Down

0 comments on commit d11dfac

Please sign in to comment.