better comparison

This commit is contained in:
Leijurv 2019-06-30 21:55:32 -07:00
parent a8155b4b0b
commit 199e0e5ed3
No known key found for this signature in database
GPG Key ID: 44A3EA646EADAC6A
1 changed files with 1 additions and 1 deletions

View File

@ -92,7 +92,7 @@ public class PathingControlManager implements IPathingControlManager {
p.secretInternalSetGoal(null); p.secretInternalSetGoal(null);
return; return;
} }
if (inControlThisTick != inControlLastTick && command.commandType != PathingCommandType.REQUEST_PAUSE && inControlLastTick != null && !inControlLastTick.isTemporary()) { if (!Objects.equals(inControlThisTick, inControlLastTick) && command.commandType != PathingCommandType.REQUEST_PAUSE && inControlLastTick != null && !inControlLastTick.isTemporary()) {
// if control has changed from a real process to another real process, and the new process wants to do something // if control has changed from a real process to another real process, and the new process wants to do something
p.cancelSegmentIfSafe(); p.cancelSegmentIfSafe();
// get rid of the in progress stuff from the last process // get rid of the in progress stuff from the last process