Is there a way to ringify blocks but evalulate certain inputs such as
set [var v] to [Hello World] {say (var)} :: grey
where I want var to be replaced with "Hello World"
.
Is there a way to ringify blocks but evalulate certain inputs such as
set [var v] to [Hello World] {say (var)} :: grey
where I want var to be replaced with "Hello World"
.
Parametrized ring
[scratchblocks] run ({say (#1 :: variables) for (#2 :: variables) secs :: looks} input names:((#1 :: variables) :: grey) ((#2 :: variables) :: grey) @delInput @addInput :: grey ring) with inputs[Hello World] [1] @delInput @addInput :: control [/scratchblocks]
Page 48 in the manual explains this in more detail.
How was posting this helpful to the conversation?
ohk,ive changed it
Still not very helpful. All caps, and rather insulting. How about if you'd said "Page 48 in the manual explains this in more detail." Wouldn't that be better?
ok
The problem is that I need to return the blocks in a ring.
Snap! Build Your Own Blocks
Procedures
[scratchblocks] {( Say it later... ((msg :: variables) :: looks) :: looks)} :: control hat report ({run ({say [] for (2) secs :: looks} @addInput :: grey ring) with inputs(msg :: variables) @delInput @addInput :: control} @addInput :: grey ring) :: control [/scratchblocks]
[scratchblocks] {( Do it later... ((msg :: variables) :: looks) ((toDo λ :: variables) :: looks) :: looks)} :: control hat report ({run ( toDo :: variables) with inputs(msg :: variables) @delInput @addInput :: control} @addInput :: grey ring) :: control [/scratchblocks]
used this way
[scratchblocks] script variables undefined((toSay1 :: variables) :: grey) ((toSay2 :: variables) :: grey) @delInput @addInput :: grey set [toSay1 v] to (Say it later... [111] :: looks) :: variables set [toSay2 v] to (Say it later... [222] :: looks) :: variables run (toSay1 :: variables) @addInput :: control run (toSay2 :: variables) @addInput :: control set [toSay1 v] to (Do it later... [X111] ({say [] for (2) secs :: looks} @addInput :: grey ring) :: looks) :: variables set [toSay2 v] to (Do it later... [Y222] ({say [] for (2) secs :: looks} @addInput :: grey ring) :: looks) :: variables run (toSay1 :: variables) @addInput :: control run (toSay2 :: variables) @addInput :: control [/scratchblocks]