Hello, this week I am planning to make a dodgeball game in the ecode, please can just check here if you are interested to it!
By doing this, we need to prepare:
Hardware: A computer
Software : ecode(www.ecode.cn)
Prepare a background picture like this:
Create a role that could move left and right, choose a new sprite and add it to the project.
Click choose one role to check all in roles in ecode.
You can review by searching with a theme, click one that you like to add it in your project.
Add the following blocks to make the roles be controlled via the direction keys.
Adjust the sprite to a proper size.
Copy the code and set to press the left arrow key and change the face direction as -90, just like this:
Test your code to make sure it could work, while walking to the left, would it trun over?
If yes, try changing the directions through the mouse:
It also works by adding this block in the code:
We just get it done! Next time I would expand the functions of climbing a ladder and jumping!
If you have any ideas or opinions, please feel free to contact us via email@example.com.
Share this post
About the Author
ELECFREAKS focuses on microbit and publishes interesting articles
- Micro bit supplier
- Wholesale Suppliers
- Micro bit tutorial
- Micro bit classroom pack
- Mcorbit Environment Monitoring
- TPBot car
- Micro:bit car
- AI Lens
- Micor:bit AI Lens
- Microbit gyroscope
- Micro:bit LEDs
- BBC micro:bit
- Micro:bit Manipulator
- Wukong board
- Micro:bit Motorcycle
- Nezha breakout
- Micro:bit DIY
- 360° servos
- AI Lens
- Retro Arcade
- Microbit programming
- Do your:bit
- Rainbow LED Ring
- Wonder Building Kit