Combo codes

Is it possible to make a code where it’s a mix between a motion, sensing, and looks block? (Just asking because I’m guessing that if a custom block is a certain colour, so like dark blue = motion, it’ll mean that it is only that type of block.)

(Sorry making custom blocks is not really a thing I do that much.)

A custom block can only be in one category and only be one colour (the colour of that category). However, you can create custom categories:

download > New Category


You can then put custom blocks in that category.

PS: I chose to name the category “Affect Stage” to describe blocks that would fit in Motion, Sensing, and Looks as you described and tried to pick a colour in between the colours of each of those categories.

Ohhh :slight_smile:

for custom category colors, right click the pallette.
image
To find the category color mixed, use this:


(drag the image into snap).

To have text of multiple colors, use $text-sizemultiplier-r-g-b (with the dashes in it)** in the label of the block. I have created a script for easy use:


drag the script into snap to use it.

I’d just like to add one thing to what other people have said so far: The category of a block is just a mnemonic aid for human readers. You don’t have to invent custom categories to make blocks that actually do things that bridge different categories. For example, it’s common to see blocks like


that mix Motion and Pen blocks.

As a teacher, I’ve been known to put blocks in entirely unrelated categories to make them stand out in the code:



Here the purpose is to highlight the nature of recursion, with a procedure calling itself.

That’s really cool!