ScratchData LogoScratchData
Back to S-cratch's profile

Amethyst Shine

S-S-cratch•Created November 1, 2014
Amethyst Shine
1
1
85 views
View on Scratch

Instructions

Click the squares to change their mode Press Space to emulate light Music by @NeonTech :D

Description

Backup of the comments inside: Chart Blocks overview: The chart blocks are a series of custom blocks that are used to make a list and add columns, allowing you to map 2d space in a list. They are helpful in storing the type of all pipes in an area. Note in the chart blocks when asked for the xy coordinates use the variables (xx)(yy)(clonex)(cloney) Initialise chart size: (columns)(rows) with a value of [string]: Creates a chart in a list of the set size (can not change afterwards without deleting the old chart!) and sets all values to [string] Get (x)(y) of chart Gets the value at that position of the chart and stores it in the _OUTPUT variable If chart contains [string] Checks if any of the chart has the value of [string]. Reports 1 in the _ChartContains variable for true and 0 for false {Is not used in this project!} Set (x)(y) of chart to [string] Sets that position of the chart to [string] Emulate Parent Light. Creates the light that starts, it repeats until the light is stoped and depending on it's direction it will move UDLR. Using Get(x)(y)of chart it will find what part it is on and act accordingly. If it is a pipe it will move through, if on a corner it will change direction and move, if on a blocker it will stop, if on a + it will create clones for the other paths if the + has not already been passed in that simulation preventing never ending loops. CloneLight[Dir](x)(y)(x2)(y2) Creates a clone at (x2)(y2) and sets its xy variables to (x)(y) and its direction to [Dir] Use example: Clonelight[U](xx)(yy)(x position*)(y postion*) Clones can create clones. * Blue Motion blocks Emulate Clone Light See Emulate Parent Light. Minor diferences though for clones ////////// I am not explaining in depth how the blocks work but more how to use them. Hope this helps everyone using this. ////////// I think you understand the update broadcast but incase: Tells the array to update where the pipes have moved to and triggers the parent light.

Project Details

Project ID32241960
CreatedNovember 1, 2014
Last ModifiedNovember 3, 2014
SharedNovember 1, 2014
Visibilityvisible
CommentsAllowed

Remix Information

Parent ProjectView Parent
Root ProjectView Root