Logo
  • Features
  • Educators
  • What's New
  • Blog
  • Showcase
  • About us
  • Contact
Try it now!
Comment
Comment

Comment

✍️
This document is created by ne0Light from Gandi IDE community and edited by Gandi IDE Team.
image

ne0Light Cocrea: https://cocrea.world/@ne0light

What are comment blocks?

Comment blocks are a way to help organize your scripts to make them more legible when coding. This allows for cleaner and more concise coding! They can also be used as notes on how the script itself functions.

This extension is made by LilyMakesThings.

What can they do?

Comment blocks can be placed within scripts and have no effect on the code within them. They have inputs on where you are able to insert text to make comments on your scripts.

How to use Comment?

First, install the comment extension located in the community tab.

image
image
image
image
image

There are 5 different blocks in the extension.

Block Type
Use
Hat Block
Connects to blocks from the top, does not run the script attached.
Stack Block
Connects next to or in between other stack blocks.
C Block
Connects by encasing other blocks within it.
Boolean Block
Connects with the left input to a boolean block.
Reporter Block
Connects with the left input to a reporter block.

Each block has an input to place a comment at, indicated by the part to the right named “comment”.

Best Practices

Let’s use these comment blocks in a script. Here is an example of implementation:

image

The comment blocks are implemented as labels for the script's purpose, within the “Movement” C Block, we can see the script for X movement and Y movement and insert a Multiplier for the speed. The comment tells us that the boolean functions as letting us move only when we are touching the color white. The Hat Block allows us to run the script while in the editor to quickly reset the X and Y positions of the player.

These comment blocks allow for more in-depth understanding of coding and more organized labeling. I hope you use this wonderful extension in your projects as well.

💡
If you have any questions or suggestions, you can find us in the discord server: https://discord.gg/U3nyveCvRa
Logo

Designed by 2ndR with love

Discord