This is a read-only archive of the old Scratch 1.x Forums.
Try searching the current Scratch discussion forums.

#1 2011-07-10 01:05:31

parcheesidude
Scratcher
Registered: 2009-10-07
Posts: 500+

Please Help Me!

I was trying to create my first block, and I had finished the block spec, it showed up as a block, but then I couldn't find it's code(method?). Where is it? The block Spec:

('%n ^ %n' #r #testMethod). under 'operators'.


My signature is trying to find itself :3

Offline

 

#2 2011-07-10 06:10:32

nathanprocks
Scratcher
Registered: 2011-04-14
Posts: 1000+

Re: Please Help Me!

the code for your block should go here:
          Scratch-Objects/ScriptableScratchMorph/'...' ops/
'...' is type of block code for your block. i think you can put it under any ops.
the first line of code should look like this:
          #testMethod
also, for user input, you have to use variables which i am not very good at coding in squeak so don't ask me about variables in squeak.


http://carrot.cassiedragonandfriends.org/Scratch_Signature/randomsig.php
http://trinary.site40.net/images/scratchrank.php?username=nathanprocks&display=small

Offline

 

#3 2011-07-10 10:34:09

parcheesidude
Scratcher
Registered: 2009-10-07
Posts: 500+

Re: Please Help Me!

Um... How do I put it there?


My signature is trying to find itself :3

Offline

 

#4 2011-07-10 10:58:21

parcheesidude
Scratcher
Registered: 2009-10-07
Posts: 500+

Re: Please Help Me!

('Bump!' #- #bumpTopic)

Last edited by parcheesidude (2011-07-10 10:58:36)


My signature is trying to find itself :3

Offline

 

#5 2011-07-10 11:50:07

poemon1
Scratcher
Registered: 2011-01-12
Posts: 500+

Re: Please Help Me!

under other ops, type ur method at the bottom.


http://i47.tinypic.com/rrqe13.gif

Offline

 

#6 2011-07-10 12:09:54

parcheesidude
Scratcher
Registered: 2009-10-07
Posts: 500+

Re: Please Help Me!

I couldn't type it!  mad


My signature is trying to find itself :3

Offline

 

#7 2011-07-10 14:22:13

parcheesidude
Scratcher
Registered: 2009-10-07
Posts: 500+

Re: Please Help Me!

bump?


My signature is trying to find itself :3

Offline

 

#8 2011-07-10 14:39:57

scimonster
Community Moderator
Registered: 2010-06-13
Posts: 1000+

Re: Please Help Me!

Go to Scratch-Objects >> ScriptableScratchMorph instance >> other ops.
Paste in the following code:

Code:

x: t1 raisedTo: t2
^ t1 raisedTo: t2

And your spec needs to be

Code:

('%n ^ %n' #r #x:raisedTo:)

Offline

 

#9 2011-07-10 16:23:55

parcheesidude
Scratcher
Registered: 2009-10-07
Posts: 500+

Re: Please Help Me!

Thanks!


My signature is trying to find itself :3

Offline

 

Board footer