Hi Everyone!
Did you know you can have your students practice multiplication facts and coding at the same time? Here’s fun way to use the Art Canvas + Playground in VEXcode VR to play a 2-player game the combines multiplication, coding and a little bit of strategy. In this game, students will share the same device and take turns coding the robot in VEXcode VR.
-
First, open the Art Canvas + Playground, and upload an image of a multiplication chart to VEXcode VR. This VEX Library article can help with that if you need it. Here is an image you can use as well:
-
The object of the game is to claim 3 spots in a row on the gameboard.
-
Students will pair up and share one device - they will take turns coding the VR Robot to drive to a square on the multiplication chart, and claim it by placing a dot on the chart using the [Move pen down] and [Move pen up ] blocks. Each player should also choose an identifying color which they will set in the parameter in the [Set pen color] block.
-
In order to claim a square, player 1 must first generate a product to a multiplication problem to for the robot to drive to using the code below. In this example, the product generated was the number 50.
This will have the VEXcode VR generate a random product that will be displayed in the print console, and will set the cursor to the next row, since that arrow has been selected.
-
Next, player 1 should drag another {When started} block to use to create a project for the robot to drive to the number 50, followed by a comment block. In the comment block, they should write a multiplication fact that goes with the product they generated.
-
Before beginning to code the project, the player should double check that their multiplication fact is correct, and if not, try again. Don’t code until the fact is correct!
Player one’s screen would look something like this at this point:
- Now player 1 should build a project to drive their robot to the product, and place a dot on the game board in their chosen color.
Here’s what the code could look like for driving to the product ‘50’
ould look like for driving to the product ‘50’.
And here’s a picture of the dot (with the robot moved out of the way)
Note: Before students run their project to drive to a product, detach the [Print] block from the first stack, so that project doesn’t run and repeatedly generate new random products as players are building an testing their project. Then when it is time for player 2 to take a turn, just reattach them.
- The first player that gets three dots in row, wins. Of course, one player can block another by placing a dot on the board on a number that obstructs their ability to get 3 in a row.
(Blue wins )
If desired, you can add a rule that allows players to claim another player’s dot on numbers that are products of more than one multiplication fact. In that case the player claiming the dot can use the VR Pen blocks to code the robot to cover over the dot with their color.
If you try this game, let me know if you like it! You might think of a better variation on it, and if so, please share. And, if your kids really get into it, they might want to try to come up with their own games riffing on the ideas in this one, and I would absolutely love to see that!