Revert the 10.0 change to the define block and make it its own block

looking at the changelog for 10.0 i saw something that caught my eye under the "noteable changes" section
"the "define" block now always creates a new custom block definition instead of sometimes modifying the definition body of an existing one with a matching label"
this is actually an issue, because now theres no way to easily do something like
"if this custom block doesn't exist, create it, if it does exist then overwrite its definition with this new stuff"
this breaks one of my (and possibly some other peoples) programs that utilize custom blocks to make something similar to how variables are created and used. along with possibly breaking libraries that use a single block to load all the block definitions because now it will duplicate the blocks.

I propose reverting this change and instead adding a new "create new (block^) with label " block that will work in the same way the new one does (always making a new block)
the current label can stay as "define" can both mean creating a new block as well as changing the definition of an already existing one.
this will keep the functionality of past programs in tact while still ensuring the function of the new block makes it in
possibly this could even be made a dropdown version of the original block?

lastly, if necessary the old version could be moved to dev mode like what happened with the old continuation system.

I don't think this should be changed, because you can still set the definition of a block without the define block.

1: that will throw an error if the block doesnt exist
2: you need the block itslef, not the label
3: already existing programs still will break
4: if you want to alter more than just that it will lag if done all in the same frame

You can find a block with a label using find first item, and the (my [blocks]) reporter

Technically if the block doesn't exist, then you wouldn't have the block to modify, which means you'd have to check if the block already exists.

Yes, I do know of the benefits of keeping the current behavior, I'm just saying, there are still other ways of achieving it.

Also, side note: apparently this is hyperized

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.