Smart Technology - Codemao

Form 3 - ECA

2024-2025

Floor 4 - Computer Room

Mr. Peter

Outline

Outline

1

2

3

Codemao Platform

Change language

Change to English

Ex09_1 - Bow & Arrow

Tasks:

Controlling the bow and arrow using mouse cursor.

1.

Clone 10 balloons and move to any random position.

2.

Hide balloon when arrow touch arrow

3.

Setup the scene

1.

Create a blank new project

2.

3.

Import balloon, bow and arrow

Set arrow and bow properties as follow:

-

X: 0, Y: -200, Scale: 40, Angle: 90

4.

Set balloon properties as follow:

-

Scale: 17, and hidden

5.

Select a background

Ex09_1 - Bow & Arrow

Bow

When game starts, forever to point towards to mouse cursor

1.

When game starts, forever to check if mouse pressed and change to corresponding costume

2.

Ex09_1 - Bow & Arrow

Arrow

When game starts, forever to point towards to mouse cursor

1.

When game starts, forever to check if mouse pressed and emit the arrow until left edge of screen.

2.

Ex09_1 - Bow & Arrow

Balloon

When game starts, clone ten balloons

1.

When balloon is cloned, show it and go to a random position in the sky, then check and hide

2.

Ex09_1 - Bow & Arrow

Download your program and name it as 01_YourName_Ex09_1.bcm4

Ex09_1 - Bow & Arrow

Tasks:

Moving gripper from left to right and right to left repeatedly

1.

Press space key to emit the gripper

2.

There are two situation for the emitting gripper:

3.

Touch any toy: Catch it up

-

Left edge of screen: go back to original Y axis

-

Ex09_2 - Crane Game

Setup the scene

1.

Create a blank new project

2.

Import Toy1, Toy2, Toy3 and Gripper

Edit the background and drag the background image into the editing.

3.

4.

Set gripper properties as follow:

5.

Set toys properties as follow:

(-239, -218)

(0, -218)

(237, -218)

All toys scale size: 35

Group the three toys and name the group as "toys"

6.

Right click

Ex09_2 - Crane Game

Gripper

1.

When game starts, forever to move from left to right and right to left

2.

Keep to check if space key is pressed while moving. If pressed, then emit the gripper by decreasing y-axis until left edge or touch any toy.

3.

If Space key is pressed and after the gripper touched any toy or left edge, then catch toy or resit gripper position depends on touch any toy or not during emitting.

Ex09_2 - Crane Game

Three toys

1.

If the toy caught by the gripper, then move up follow the gripper. And then disappear it after reach the top position.

Ex09_2 - Crane Game

Download your program and name it as 01_YourName_Ex09_2.bcm4

Ex09_2 - Crane Game

Ex09_3 - Fishing Game

Tasks:

Controlling gripper using mouse cursor.

1.

Emit the gripper by mouse clicking

2.

Fishes movement

3.

Setup the scene

1.

Create a blank new project

2.

Draw the sea background by yourself

3.

3.

Set gripper properties as follow:

4.

Set boat properties as follow:

5.

Move the fish and set a appropriate size, and set the rotation mode as Left-Right

Group the three fishes and name the group as "fishes"

6.

Ex09_3 - Fishing Game

Three fishes

1.

Fish movement and caught action

Ex09_3 - Fishing Game

Gripper

1.

Control the gripper and emit by mouse clicking.

Think about how to simulate the fishing line using pen function block code

2.

Ex09_3 - Fishing Game

Download your program and name it as 01_YourName_Ex09_3.bcm4

Ex09_3 - Fishing Game

Smart Technology - Codemao

By Mr Peter

Smart Technology - Codemao

  • 13