Skip to content

Commit

Permalink
Merge pull request #1 from TheLivan/master
Browse files Browse the repository at this point in the history
Fix the strange code
  • Loading branch information
stephengold committed Apr 9, 2024
2 parents 8158d94 + 6f73547 commit fa22710
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -230,7 +230,7 @@ public BroadphasePair findPair(BroadphaseProxy proxy0, BroadphaseProxy proxy1) {
if (proxy0.getUid() > proxy1.getUid()) {
BroadphaseProxy tmp = proxy0;
proxy0 = proxy1;
proxy1 = proxy0;
proxy1 = tmp;
}
int proxyId1 = proxy0.getUid();
int proxyId2 = proxy1.getUid();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -405,7 +405,7 @@ public boolean getSolveTwistLimit() {
}

public boolean getSolveSwingLimit() {
return solveTwistLimit;
return solveSwingLimit;
}

public float getTwistLimitSign() {
Expand Down
4 changes: 3 additions & 1 deletion src/com/bulletphysics/linearmath/CProfileManager.java
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,8 @@

import com.bulletphysics.BulletStats;

import java.util.Objects;

/**
* Manager for the profile system.
*
Expand All @@ -49,7 +51,7 @@ public class CProfileManager {
* @param name must be {@link String#intern interned} String (not needed for String literals)
*/
public static void startProfile(String name) {
if (name != currentNode.getName()) {
if (!Objects.equals(name, currentNode.getName())) {
currentNode = currentNode.getSubNode(name);
}

Expand Down
2 changes: 1 addition & 1 deletion src/com/bulletphysics/linearmath/CProfileNode.java
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ public CProfileNode getSubNode(String name) {
// Try to find this sub node
CProfileNode child = this.child;
while (child != null) {
if (child.name == name) {
if (child.name.equals(name)) {
return child;
}
child = child.sibling;
Expand Down

0 comments on commit fa22710

Please sign in to comment.