to make a block with only a spot to attach it at the top simply do this:
first let's create our block...
in class view go to Scratch-Objects->ScriptableScratchMorph->blockspecs->blockspecs
('This is a sample end block' #- #sampleendblock)press accept
next let's make the method:
in instance view go to Scratch-Objects->ScriptableScratchMorph->other ops
sampleendblock
self sayNothingpress accept
now here is the secret sauce:
in instance view go to Scratch-Blocks->CommandBlockMorph->accessing->isStop
see the line where it says "#stopAll"?
Replace it with :
^ selector = #doReturn | (selector = #stopAll)|(selector = #sampleendblock)
press accept
and you are done, you now have a script-end block
Edit: here is a Image to show you:
Last edited by frowned (2011-01-28 13:26:46)
Offline
Not working.
Last edited by scimonster (2011-06-06 08:33:04)
Offline
No.
It says parentheses expected or something like that.
Last edited by scimonster (2011-06-06 08:33:27)
Offline
oh sorry i have a correction... the thing in isStop should be
^ selector = #doReturn | (selector = #stopAll)|(selector = #sampleendblock)
note: corrected in first post
Last edited by frowned (2011-01-28 13:05:10)
Offline
nice! Maybe with this you could add more to the method and make it do something!
Offline
Keep posting usefully and you'll be promoted to Scratcher. Scratchers can edit and delete their posts.
Last edited by scimonster (2011-06-06 08:33:46)
Offline