Obsolete blocks are blocks that are not compatible with the version of Scratch being used; the interpreter cannot recognize them as actual blocks. They can be obtained by adding new code to a Scratch project's JSON file, which holds all specifications for a project. These blocks can be resurrected or created by using the Shift-Click-R method. Most of the resurrected blocks fail to work, but the stretch, abs, sqrt, point away from the edge, and some other blocks will function. The typical obsolete block is a command block, yet can fit in the space of any other type of block, as can be seen if you open up a project containing an (answer) block from Scratch 1.4 in any lower version of Scratch. Most of these blocks are red. The obsolete block that says "obsolete!" does nothing, and it is what all obsolete blocks appear as in the Experimental Viewer.
Undefined blocks are blocks that cannot be found as an actual script, and are undefined. One can get them as explained at the Getting an Obsolete or Undefined Block chapter.
For a list of obsolete blocks, see List of Obsolete Blocks.
Obsolete Blocks in 1.3/1.4
There are a large amount of Looks type blocks that do not have a function but had already been added Scratch. The
point away from the edge:: motion block is glitchy and completely impractical — which is probably why it was removed from the November 2006 beta release. Also, a
(note:: sensing block used to exist but was removed due to being buggy.
Obsolete Blocks in 1.0-1.2
- Main article: Experimental Blocks
There are many hidden blocks under 1.0-1.2.1, but the functions have not been completely explained. The start/stop movie blocks indicate that an experimental version of video support may have once existed.
There were 13 experimental Sound Blocks and 10 experimental Sensing Blocks.
Getting an Obsolete or Undefined Block
To obtain an obsolete (or undefined) block in Scratch 2.0, the user will need to create a custom block and drag the block (NOT the definition script) into your backpack. Once the user takes it out, it will turn into a red undefined block.
One can also create a obsolete that is not colored or renamed by creating a custom block in either the stage or a sprite, and drag the block, NOT the definition script, into another sprite or without a custom block with the same name, and the block will become obsolete (but not colored red nor renamed) because there is no definition script within the new sprite to define the block's procedure.
There are two ways to get obsolete blocks in Scratch 1.x:
- Get an obsolete block from a Scratch Modification. These are the steps:
- Edit the Scratch source to include a method and a blockspec that is not in the normal Scratch. When others download or play it, the block turns obsolete.
More Obsolete Blocks
Here is a project that contains lots of different obsolete blocks.
- Main article: Offline and Online Detection
|This article or section documents a feature not included in the current version of Scratch (2.0). It is only useful from a historical perspective.|
Obsolete blocks can also be used to detect whether a user is playing a project in the Java Player or the Experimental Viewer. Online, the script stops when it detects an undefined block, whereas when the project is played in Scratch 1.4, the script ignores the undefined block and carries on with the script. An offline/online sensor can be created with this script:
when green flag clicked set [Offline/Online v] to [Online] undefined set [Offline/Online v] to [Offline]
A more complex version is this:
when green flag clicked set [Playing... v] to [Online] broadcast ((0) / (0)) set [Playing... v] to [Offline Java] undefined set [Playing... v] to [Offline Flash]