diff --git a/libs/behaviors/_locales/behaviors-strings.json b/libs/behaviors/_locales/behaviors-strings.json index 1862c5ea..7cd82798 100644 --- a/libs/behaviors/_locales/behaviors-strings.json +++ b/libs/behaviors/_locales/behaviors-strings.json @@ -1,7 +1,7 @@ { "behaviors.addBehavior|block": "add behavior %behavior", "behaviors.avoidCrash|block": "avoid crash using %ultrasonic", - "behaviors.driveForward|block": "drive %motors|forward at %speed|%", + "behaviors.driveForward|block": "drive %motors|forward at %speed=motorSpeedPicker|%", "behaviors|block": "behaviors", "{id:category}Behaviors": "Behaviors" } \ No newline at end of file diff --git a/libs/behaviors/targetoverrides.ts b/libs/behaviors/targetoverrides.ts index 99023221..4d64e6b9 100644 --- a/libs/behaviors/targetoverrides.ts +++ b/libs/behaviors/targetoverrides.ts @@ -49,7 +49,7 @@ namespace behaviors { * @param motors * @param speed the desired speed, eg: 50 */ - //% blockId=behaviorsDriveForward block="drive %motors|forward at %speed|%" + //% blockId=behaviorsDriveForward block="drive %motors|forward at %speed=motorSpeedPicker|%" export function driveForward(motors: motors.MotorBase, speed: number): behaviors.Behavior { return new DriveForwardBehavior(motors, speed); } diff --git a/libs/core/_locales/core-strings.json b/libs/core/_locales/core-strings.json index d2482e3b..f581aa99 100644 --- a/libs/core/_locales/core-strings.json +++ b/libs/core/_locales/core-strings.json @@ -57,10 +57,10 @@ "motors.MotorBase.setReversed|block": "set %motor|reversed %reversed", "motors.MotorBase.setSpeedFor|block": "set %motor|speed to %speed=motorSpeedPicker|%|for %value|%unit", "motors.MotorBase.setSpeed|block": "set %motor|speed to %speed=motorSpeedPicker|%", - "motors.SynchedMotorPair.steerFor|block": "steer %chassis|turn ratio %turnRatio|speed %speed|%|for %value|%unit", - "motors.SynchedMotorPair.steer|block": "steer %chassis|turn ratio %turnRatio|speed %speed|%", - "motors.SynchedMotorPair.tankFor|block": "tank %motors|%speedLeft|%|%speedRight|%|for %value|%unit", - "motors.SynchedMotorPair.tank|block": "tank %motors|%speedLeft|%|%speedRight|%", + "motors.SynchedMotorPair.steerFor|block": "steer %chassis|turn ratio %turnRatio|speed %speed=motorSpeedPicker|%|for %value|%unit", + "motors.SynchedMotorPair.steer|block": "steer %chassis|turn ratio %turnRatio|speed %speed=motorSpeedPicker|%", + "motors.SynchedMotorPair.tankFor|block": "tank %motors|%speedLeft=motorSpeedPicker|%|%speedRight=motorSpeedPicker|%|for %value|%unit", + "motors.SynchedMotorPair.tank|block": "tank %motors|%speedLeft=motorSpeedPicker|%|%speedRight=motorSpeedPicker|%", "motors.largeAB|block": "large A+B", "motors.largeAD|block": "large A+D", "motors.largeA|block": "large A", diff --git a/libs/core/output.ts b/libs/core/output.ts index 3f8a4905..2bd1f9c2 100644 --- a/libs/core/output.ts +++ b/libs/core/output.ts @@ -465,7 +465,7 @@ namespace motors { * @param speedLeft the speed on the left motor, eg: 50 * @param speedRight the speed on the right motor, eg: 50 */ - //% blockId=motorPairTank block="tank %motors|%speedLeft|%|%speedRight|%" + //% blockId=motorPairTank block="tank %motors|%speedLeft=motorSpeedPicker|%|%speedRight=motorSpeedPicker|%" //% weight=20 blockGap=8 //% group="Sync Motion" tank(speedLeft: number, speedRight: number) { @@ -483,7 +483,7 @@ namespace motors { * @param value the amount of movement, eg: 2 * @param unit the unit of the value */ - //% blockId=motorPairTankFor block="tank %motors|%speedLeft|%|%speedRight|%|for %value|%unit" + //% blockId=motorPairTankFor block="tank %motors|%speedLeft=motorSpeedPicker|%|%speedRight=motorSpeedPicker|%|for %value|%unit" //% weight=19 //% speedLeft.min=-100 speedLeft=100 //% speedRight.min=-100 speedRight=100 @@ -511,7 +511,7 @@ namespace motors { * @param value the move quantity, eg: 2 * @param unit the meaning of the value */ - //% blockId=motorPairSteer block="steer %chassis|turn ratio %turnRatio|speed %speed|%" + //% blockId=motorPairSteer block="steer %chassis|turn ratio %turnRatio|speed %speed=motorSpeedPicker|%" //% weight=7 blockGap=8 //% turnRatio.min=-200 turnRatio=200 //% inlineInputMode=inline @@ -527,7 +527,7 @@ namespace motors { * @param value the move quantity, eg: 2 * @param unit the meaning of the value */ - //% blockId=motorPairSteerFor block="steer %chassis|turn ratio %turnRatio|speed %speed|%|for %value|%unit" + //% blockId=motorPairSteerFor block="steer %chassis|turn ratio %turnRatio|speed %speed=motorSpeedPicker|%|for %value|%unit" //% weight=6 blockGap=8 //% turnRatio.min=-200 turnRatio=200 //% inlineInputMode=inline