Discuss Scratch
- Discussion Forums
- » Suggestions
- » Comment as a first-class block?
- endlessimagination
- Scratcher
3 posts
Comment as a first-class block?
Right now comments feel like an afterthought, get stuck to the side, and don't always move with their code blocks when “Clean up Blocks” is used. Wouldn't it be nice for comments to be a first class block that can go into the code itself, just that it does nothing? This is how it is for real programming languages too, and will encourage the habit of writing comments, making the codes much more readable. WDYT?
Last edited by endlessimagination (Aug. 14, 2021 13:08:14)
- KangaCoder
- Scratcher
1000+ posts
Comment as a first-class block?
Comments, as notes in projects?
If they were to go into the blocks, wouldn’t that defeat the whole purpose of having them explain what the blocks do?
If they were to go into the blocks, wouldn’t that defeat the whole purpose of having them explain what the blocks do?
don't feed the trolls. feed yourself pizza cupcakez .[1] [2] [3] [4]
KangaCoder • [he/him] • kæŋɡəˈ koʊdər
• Random Fun Facts: Male, Christian, US resident, EST time zone, Ravenclaw, likes Math and Science, learning German, knows HTML, Python and Java, loves chocolate, favorite color, possibly a kangaroo
• On the Main Site: Experienced Wikian, Camp Counselor, SWC Reviewer, SDS Helper, Forum Helper
• On the Forums: 2.65K+ forum posts
• Project Ideas Directory 6.0 - need a project idea? Check it out!
• Check out some weird and cool Scratch pages!
- mybearworld
- Scratcher
1000+ posts
Comment as a first-class block?
Something like this?
Do you mean something like this?
[section v] v {If so, someone already had that idea.
move (10) steps
turn cw (25) degrees
}::grey
Do you mean something like this?
comment [hello world]::greyIf so, that's rejected. If not, please elaborate.
repeat (10)
move (10) steps
end
Last edited by mybearworld (Aug. 14, 2021 14:49:09)
Signatures are the only place where assets links still work.
- endlessimagination
- Scratcher
3 posts
Comment as a first-class block?
EDIT: Sorry mybearworld, you replied while i was composing this, this reply is my reply to wangat
I think you misunderstood me. Right now comments look like this
It's next to the code, it's not part of the code. And more annoyingly, it doesn't always move with the code. I'm suggesting doing something like this, but with nicer wrapping and such so long comments don't look awful.
I think you misunderstood me. Right now comments look like this
It's next to the code, it's not part of the code. And more annoyingly, it doesn't always move with the code. I'm suggesting doing something like this, but with nicer wrapping and such so long comments don't look awful.
COMMENT: Scratch has no explicit layer control other than relative movement between layers...
set [LAYER] to [0]
repeat [20]
broadcast [layer] and wait
change [LAYER] by [1]
Last edited by endlessimagination (Aug. 14, 2021 15:07:48)
- PenguinLover1123
- Scratcher
1000+ posts
Comment as a first-class block?
Easy workaround:
define comment [comment]
//Put nothing in the define
comment [Your comment here]//Then use this
Good morning/afternoon/night
- endlessimagination
- Scratcher
3 posts
Comment as a first-class block?
Hah thanks, you all are fast :-). Glad to know these have been suggested before, but sad that it was rejected. I think making it a block would encourage its use much more. Writing good comments is an important software engineering skill so it shouldn't be stashed into a hard-to-find right-click popup menu, and instead should be front and center. I guess this has been debated before so i won't push this further. Thanks all for the discussion!
- ScolderCreations
- Scratcher
1000+ posts
Comment as a first-class block?
It appears this is rejected, as someone else has stated. Edit: ninjaed by the op :'(
Last edited by ScolderCreations (Aug. 14, 2021 15:04:10)
- Totodile_star
- Scratcher
500+ posts
Comment as a first-class block?
I hate my life
Pokemon Fan
SpongeBob Fan
Namesnipe Hunter
- mybearworld
- Scratcher
1000+ posts
Comment as a first-class block?
Signatures are the only place where assets links still work.
- k7e
- Scratcher
1000+ posts
Comment as a first-class block?
EDIT: Sorry mybearworld, you replied while i was composing this, this reply is my reply to wangatyou can use the “quote” button to reply to someone easier. when you do that, though, make sure you delete parts that you don't need to reply to.
@mythoslore was so much more obvious than @spookily
- Discussion Forums
- » Suggestions
- » Comment as a first-class block?