]> git.taranathan.com Git - FRC2026.git/commitdiff
incorrect comparison
authoriefomit <timofei.stem@gmail.com>
Thu, 9 Apr 2026 05:43:52 +0000 (22:43 -0700)
committeriefomit <timofei.stem@gmail.com>
Thu, 9 Apr 2026 05:43:52 +0000 (22:43 -0700)
it's actually there :0

src/main/java/frc/robot/commands/gpm/LockedShoot.java
src/main/java/frc/robot/commands/gpm/Superstructure.java

index e7a56f87d7a97e90aa59929167495b056ada1e94..d287970478a7ccb7d10cf060b91a9daf80ba3e5e 100644 (file)
@@ -111,7 +111,7 @@ public class LockedShoot extends Command {
             Translation3d lookahead3d = new Translation3d(lookaheadPose.getX(), lookaheadPose.getY(), TurretConstants.DISTANCE_FROM_ROBOT_CENTER.getZ());
             
             Translation3d target3d = new Translation3d(target.getX(), target.getY(),
-                target == FieldConstants.getHubTranslation().toTranslation2d() ?
+                target.equals(FieldConstants.getHubTranslation().toTranslation2d()) ?
                 FieldConstants.getHubTranslation().getZ() : 0.0); // Height of 0 if it's not the hub
 
             goalState = ShooterPhysics.getShotParams(
index 4fe7e0576399b8263cf5ac0273c019a537819e13..cfad74c670f0616893f9227582eb3187951244e8 100644 (file)
@@ -112,7 +112,7 @@ public class Superstructure extends Command {
             Translation3d lookahead3d = new Translation3d(lookaheadPose.getX(), lookaheadPose.getY(), TurretConstants.DISTANCE_FROM_ROBOT_CENTER.getZ());
             
             Translation3d target3d = new Translation3d(target.getX(), target.getY(),
-                target == FieldConstants.getHubTranslation().toTranslation2d() ?
+                target.equals(FieldConstants.getHubTranslation().toTranslation2d()) ?
                 FieldConstants.getHubTranslation().getZ() : 0.0); // Height of 0 if it's not the hub
 
             goalState = ShooterPhysics.getShotParams(