Discuss Scratch
- Discussion Forums
- » Suggestions
- » Boolean variables :D
- TO0601
-
54 posts
Boolean variables :D
WARNING!!! Maybe:set (boolean var v) to (true v)
set (☁ boolean var v) to (true v)
set (boolean var v) to (false v)
set checkbox color of (boolean var v) to [#01a15b]::variables //checkboxes would represent boolean vars as a readout
<boolean var::variables>Also, you could already do this with regular cloud variablesI feel like it would not really cause any problems, as they would only be able to have two values (less than with regular cloud variables) Are cloud boolean variables included in this suggestion?
this block is not real
- jmdzti_0-0
-
1000+ posts
Boolean variables :D
we can tell?? WARNING!!!
this block is not real
Last edited by jmdzti_0-0 (Aug. 9, 2025 09:15:52)
- Toodchop
-
100+ posts
Boolean variables :D
Semi-support, there's already an easy workaround:
But! It can be a good idea!
<(foo) = [bar]>
But! It can be a good idea!
<my variable :: variables>
<☁ my variable :: variables>
set [my variable v] to [true v]
- AceCoderClaws
-
51 posts
Boolean variables :D
I don't feel like a specifically boolean-type of variable is necessary. Why not just make it so you can put a variable into a conditional statement? If the value is a couple of specific binary values (true/false, 1/0, on/off, yes/no) would be treated as a boolean, otherwise it would just check for if the variable's value isn't empty like in other sorts of languages.
if (foo) then
say [True!]
end
if (foo) { console.log("True!"); }
- medians
-
1000+ posts
Boolean variables :D
Yeah, it was intended as a mockup for this suggestion WARNING!!!
this block is not real
- redspacecat
-
500+ posts
Boolean variables :D
I support this, it would be a huge timesaver. Right now only I don't feel like a specifically boolean-type of variable is necessary. Why not just make it so you can put a variable into a conditional statement? If the value is a couple of specific binary values (true/false, 1/0, on/off, yes/no) would be treated as a boolean, otherwise it would just check for if the variable's value isn't empty like in other sorts of languages.if (foo) then
say [True!]
endif (foo) { console.log("True!"); }
(item () of [list v] :: list)can go in boolean inputs and it would be nice if they all could. Booleans can already fit in round inputs, so why not the other way around?
(item # of [] in [list v])
- secretuch
-
100+ posts
Boolean variables :D
http://scratch.mit.edu/projects/10841526/The project doesn’t exist
Don’t advertise
- redspacecat
-
500+ posts
Boolean variables :D
That post was made 12 years ago, do you think the poster will still be active?http://scratch.mit.edu/projects/10841526/The project doesn’t exist
Don’t advertise
The project was made a really long time ago, it probably got unshared later.
Checking the project's thumbnail, it is, in fact related to boolean variables.

- rdococ
-
1000+ posts
Boolean variables :D
Any new feature must be weighed against the cognitive load it puts on newcomers trying the editor for the first time. At least, that's how the Scratch Team sees it, and it's why a lot of convenient but kind of unnecessary features like this don't make it in.
Last edited by rdococ (Aug. 20, 2025 19:44:53)
- lapisi
-
1000+ posts
Boolean variables :D
(#391)if they understand booleans and variables they'll be able to understand boolean variables
Any new feature must be weighed against the cognitive load it puts on newcomers trying the editor for the first time. At least, that's how the Scratch Team sees it, and it's why a lot of convenient but kind of unnecessary features like this don't make it in.
- secretuch
-
100+ posts
Boolean variables :D
Large type…(#391)if they understand booleans and variables they'll be able to understand boolean variables
Any new feature must be weighed against the cognitive load it puts on newcomers trying the editor for the first time. At least, that's how the Scratch Team sees it, and it's why a lot of convenient but kind of unnecessary features like this don't make it in.
Bread eggs, breaded eggs?
- AceCoderClaws
-
51 posts
Boolean variables :D
The majority of users don't know how to do this. It would be a lot simpler for something like what Use hacked blocks.I mentioned above to be implemented.
- lapisi
-
1000+ posts
Boolean variables :D
(#393)TV Tropes reference, can't link the actual TV Tropes article so I just typed the name into large-type.com, the short description of the trope is “'Thing A, Thing B, Thing A+B', though it can be longer.”Large type…(#391)if they understand booleans and variables they'll be able to understand boolean variables
Any new feature must be weighed against the cognitive load it puts on newcomers trying the editor for the first time. At least, that's how the Scratch Team sees it, and it's why a lot of convenient but kind of unnecessary features like this don't make it in.
Bread eggs, breaded eggs?
[/offtopic]
Last edited by lapisi (Aug. 21, 2025 19:49:20)
- medians
-
1000+ posts
Boolean variables :D
I feel like for the switch () block (not saying you made it), you could just do:
set [bool v] to <not <bool::variables>>
- Discussion Forums
- » Suggestions
-
» Boolean variables :D