hleahfoiahf

This commit is contained in:
Gzod01 2024-01-06 16:59:28 +01:00
parent 5d1b168561
commit 636397f934

View file

@ -67,8 +67,8 @@ public class Werobot_FTC2024_carlike extends LinearOpMode {
rpower = gamepad1.right_stick_y; rpower = gamepad1.right_stick_y;
} }
else if (mode=="essaifranck"){ else if (mode=="essaifranck"){
double a = (y+x)/Math.pow(2,1/2); double a = (-y+x)/Math.pow(2,1/2);
double b = (y-x)/Math.pow(2,1/2); double b = (-y-x)/Math.pow(2,1/2);
double vmean = (Math.abs(a)+Math.abs(b))/2; double vmean = (Math.abs(a)+Math.abs(b))/2;
lpower = (a/vmean)*t2; lpower = (a/vmean)*t2;
rpower = (b/vmean)*t2; rpower = (b/vmean)*t2;