PictoBlox Cloud Chat System Using Cloud Variables

by jashdesai in Circuits > Computers

38 Views, 1 Favorites, 0 Comments

PictoBlox Cloud Chat System Using Cloud Variables

Screenshot 2026-05-11 092725.png

This project demonstrates a simple cloud-based chat system created using PictoBlox Cloud Variables. Two or more users connected to the same cloud project can send messages using keyboard keys and receive messages in real time.

Supplies

PictoBlox

Cloud Variables

Keyboard Inputs

Conditional Logic

Setting Up Pictoblox

Screenshot 2026-05-11 093604.png

Select Blocks

Select Cloud Variable Extention

Screenshot 2026-05-11 093852.png

Cloud Variables are special variables in PictoBlox that store data on the internet instead of only on a single computer. This allows multiple users and devices connected to the same project to share and update data in real time.

Unlike normal variables, cloud variables automatically synchronize across all connected devices. When one user changes a cloud variable, the updated value is instantly visible to everyone connected to that project.

Connect to Cloud Server

Screenshot 2026-05-11 094954.png

Code and Logic

Screenshot 2026-05-11 095408.png

Step 1: Connect to Cloud Server

When the green flag is clicked:

  1. The device connects to the Pictoblox cloud server.
  2. Cloud variables are initialized.

Step 2: Sending Message from User A

When key A is pressed:

  1. Counter increases by 1.
  2. Message variable stores: A says: Hello at <Counter>
  3. LastSender is set to A.
  4. Sprite displays: Message Send from A


Step 3: Sending Message from User B

When key B is pressed:

  1. Counter increases by 1.
  2. Message variable stores: B says: Hello at <Counter>
  3. LastSender is set to B.
  4. Sprite displays: Message Send from B


Step 4: Receiving Messages

A forever loop continuously checks:

  1. If oldvariable < Counter
  2. Then a new message has arrived.

The sprite then:

  1. Updates the old counter value.
  2. Displays the received cloud message.

Logic Explanation

The project works using a cloud counter system.

Every time a user sends a message:

  1. The counter value increases.
  2. Other connected devices compare the current counter with their stored old counter.
  3. If the value changes, it means a new message has been received.

This method helps all devices stay synchronized.

Download the SB3 file

Result

Result_screen.png
Recording2026-05-18093150-ezgif.com-video-to-gif-converter.gif

The project allows users to send and receive messages in real time while storing shared data online. The interface displays multiple cloud variables such as Counter, LastSender, Message, and a list of usernames connected to the system.

Whenever a user sends a message, the cloud variables update instantly, showing the latest sender and message details across all connected devices. This project introduces the concept of cloud computing, real-time data synchronization, and multiplayer communication using cloud variables in an interactive and beginner-friendly way.