![]() If there is an obscured shadow, the third element is its ID or an array representing it. The second is either the ID of the input or an array representing it as described in the table below. The first element of each array is 1 if the input is a shadow, 2 if there is no shadow, and 3 if there is a shadow but it is obscured by the input. inputs An object associating names with arrays representing inputs into which other blocks may be dropped, including C mouths. If the block is an input to another block, this is the ID of that other block. If the block is the first stack block in a C mouth, this is the ID of the C block. parent If the block is a stack block and is preceded, this is the ID of the preceding block. next The ID of the following block or null. The opcode of a "core" block may be found in the Scratch source code here or here for shadows, and the opcode of an extension's block may be found in the extension's source code here. Most blocks are represented by objects with the following properties: (These notions come from Blockly, which Scratch Blocks is based on.) Scratch internally considers these to be blocks although they are not usually thought of as such. However, more often than not, one should be able to do this in this case no field exists directly in the block, but an input does, and that input may have a shadow block in it.Ī shadow block is a reporter in an input for which one can enter or pick a value, and which cannnot be dragged around but can be replaced by a normal reporter. These are used directly in blocks where there is an input into which one cannot drop a reporter. Blocksįields are text boxes, drop-down menus, etc. Possible values are "all around", "left-right", or "don't rotate". draggable True if the sprite is draggable and false otherwise. direction The sprite's direction in degrees clockwise from up. Visible True if the sprite is visible and false otherwise. Sprites have the following properties as well as those of all targets: textToSpeechLanguage The language of the Text to Speech extension. Has no effect if videoState is "off" or if the project does not use an extension with video input. videoTransparency The video transparency. Has no effect if the project does not use an extension with video input. Determines if video is visible on the stage and if it is flipped. videoState Possible values are "on", "off" and "on-flipped". The stage has the following properties as well as those of all targets. comments An object associating IDs with comments. blocks An object associating IDs with blocks. broadcasts An object associating IDs with broadcast names. The first element of the array is the list name and the second is the list as an array. lists An object associating IDs with arrays representing lists. The first element of the array is the variable name, the second is the value and the third is `true` if the variable is a cloud variable, or otherwise not present. variables An object associating IDs with arrays representing variables. If not provided, the target will not be loaded. Targets have the following properties: isStage True if this is the stage and false otherwise. TargetsĪ target is the stage or a sprite. Meta Metadata about the project's author and the Scratch version used. gdxfor ( Go Direct Force & Acceleration Extension).videoSensing ( Video Sensing Extension).text2speech ( Text to Speech Extension).wedo2 ( LEGO Education WeDo 2.0 Extension).extensions An array of the identifiers of the extensions used. monitors An array of monitors, in their layer order. Targets An array of targets, in the same order as in the Scratch User Interface. sprite3 files are the same as project files except that the JSON file is named sprite.json and it represents the sprite as a target. zip (settings of the file manager might need to be changed to show file extensions), or one can use a program such as 7-Zip.) Backdrops, costumes, and sounds are stored as individual files with names beginning with their MD5 checksums followed by a file extension. sb3 file by first renaming it so that it ends with. (On most operating systems, one can extract an. ![]() sb3 file is a ZIP archive containing one JSON file, project.json, representing the project.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |