0% found this document useful (0 votes)
39 views7 pages

Events Blocks in PictoBlox_ Block Coding

Download as pdf or txt
Download as pdf or txt
Download as pdf or txt
You are on page 1/ 7

PICTOBLOX EXTENSION

Events

Extension Description
Events blocks are related to various triggers in a project, or when one part signals another to run.

Available in: Block Coding, Python Coding


Mode: Stage Mode
WiFi Required: No
Compatible Hardware in Block Coding: evive, Quarky, Arduino Uno, Arduino Mega, Arduino
Nano, ESP32, T-Watch, Boffin, micro:bit, TECbits, LEGO EV3, LEGO Boost, LEGO WeDo 2.0, Go DFA,
None
Compatible Hardware in Python: evive, Quarky, Arduino Uno, Arduino Mega, Arduino Nano,
ESP32, T-Watch, Boffin, micro:bit, TECbits, LEGO EV3, LEGO Boost, LEGO WeDo 2.0, Go DFA, None
Object Declaration in Python: sprite = Sprite("Sprite-Name")
Extension Catergory: Default

Introduction

Events is one of the ten categories of default Scratch blocks. They are color-coded light yellow and
are used to sense events, which trigger scripts to run. Event blocks are essential for every project:
without the hat blocks from this category, a project would not be able to begin except by manually
running scripts.

Read More
PictoBlox Blocks

Scripts that wear this block will activate once the Green Flag has been clicked — these scripts can
activate other scripts and enable the entire program. Without this block, the only way a project could
run would be that it would sense the pressing of a key or clicking a sprite; the project would only last
until all scripts depending on the starting scripts have ended.

Scripts placed underneath this block will activate when the specified key is pressed.

Scripts that wear this block will be triggered once the specified backdrop has been switched to on the
Stage.

Scripts that wear the block will activate once its sprite or clone of the sprite is clicked. Contrary to its
definite name, the block will also execute the clone’s script when the clone is clicked on.

Scripts that begin with this block will be invoked once the specified broadcast has been sent by a calling
script. If a Forever block is sending the broadcast faster than the attached script can finish running, the
script will restart without reaching the blocks at the end. This can be avoided by using Broadcast () and
Wait.

The block sends a broadcast throughout the whole Scratch program. Any scripts in any sprites that are
hatted with the When I Receive () block that is set to a specified broadcast will activate. This broadcast
block lets scripts send broadcasts without any waits in its script (unlike the Broadcast () and Wait block).
Broadcasts are a good way to have sprites and scripts communicate.

7
The block sends a broadcast throughout the whole Scratch project — any scripts that are halted with the
When I Receive () block and are set to the broadcast will activate. This broadcast block lets scripts send
broadcasts, and have them wait until all scripts are activated by the broadcast ends.

Block Coding Examples

1 Ball Movement
The example demonstrates how to add movement to a sprite
using the key detection hat block.

2 Change costume when Clicked


The example demonstrates the costume change and gliding
to the random location when clicked.

3
Falling Tobi
The example demonstrates the use of clone and gliding
function in Sprite.

4 Follow the Mouse


The example demonstrates how to make the sprite follow the
mouse.

5 LED Control with Keys


The example demonstrates how to control the glowing LED
using the keyboard keys.

6
Making a Sprite glide to Random Location
The example demonstrates how to make the sprite glide to a
random position on the stage when it is clicked.

7 Show and Hide


The example demonstrates the show and hides of the sprite
using the buttons.

8 Walking Tobi
The example demonstrates the wall bouncing of the sprite
and rotation style.

Company
About Us
Blog
Partners and Distributors
Terms and Conditions
Privacy Policy
Careers

Community
Codeavour - AI Competition
Community Projects
Projects by STEMpedia
Example Projects
International Python Bootcamp
International Junior Blocks Bootcamp
International 3D and XR Studio Bootcamp

Products
Quarky - AI & Robotics Kit
Quarky Addon Kits
evive - STEM Kit
PictoBlox Software
Dabble App

School Programs
AI & Robotics Lab
Atal Tinkering Labs
STEM Innovation Lab
CBSE Aligned Coding & AI Lab
ICSE Aligned Robotics & AI Lab

Impact Programs
CSR & Government Impact Program

Learning Resources
Education Center
Courses & Teacher Resources

Product Documentation
Quarky Kits
evive Kits
PictoBlox Software
PictoBlox Extensions & Libraries
Dabble App
Arduino with PictoBlox

Get in Touch
Contact Us
Book a Demo
Request a Quote

Follow Us

PictoBlox - Block & Python Coding for Kids

Dabble App - One App. Infinite Control.

Copyright 2024 – Agilo Research Pvt. Ltd. All rights reserved – Terms & Condition | Privacy Policy

You might also like