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

#1 2010-08-12 14:02:27

johnnydean1
Scratcher
Registered: 2010-02-12
Posts: 1000+

|How to make a new block type?|

a
|  block |
block type. No it doesnt have to go in a colour slot.


You can now reach me on Twitter @johnnydean1_

Offline

 

#2 2010-08-12 14:29:59

henley
Scratcher
Registered: 2008-06-21
Posts: 1000+

Re: |How to make a new block type?|

What do you mean by "block type" do you mean like command, boolean, reporter? Or do you mean like control, motion, looks? Or do you mean something else?


"I've worked so hard for you and you give me nothing in return. Do you need help... Or do I?"

Offline

 

#3 2010-08-12 14:43:25

johnnydean1
Scratcher
Registered: 2010-02-12
Posts: 1000+

Re: |How to make a new block type?|

command reporter boolean
60
s
e
c
o
n
d
s
!
!
!
!
!






R
u
l
e
!
!
!
!


You can now reach me on Twitter @johnnydean1_

Offline

 

#4 2010-08-12 15:06:20

Jwosty
Scratcher
Registered: 2009-12-19
Posts: 500+

Re: |How to make a new block type?|

That probbably depend, what kind do you want and what would you like it to do? I'll help.  wink


http://i39.tinypic.com/18ert5.png Google it.  smile

Offline

 

#5 2010-08-12 15:38:55

nXIII
Community Moderator
Registered: 2009-04-21
Posts: 1000+

Re: |How to make a new block type?|

Make a CommandBlockMorph subclass and some changes to ScriptableScratchMorph's blocks methods. Change the drawing method to make it a different shape (I was thinking a W-shaped jagged edge might look cool)

Out of curiosity, what are you doing with this new block type?

Last edited by nXIII (2010-08-12 15:39:15)


nXIII

Offline

 

#6 2010-08-12 15:43:51

johnnydean1
Scratcher
Registered: 2010-02-12
Posts: 1000+

Re: |How to make a new block type?|

Its like a label. It will act like a reporter but will not fit in anything else.


You can now reach me on Twitter @johnnydean1_

Offline

 

#7 2010-08-12 15:46:06

johnnydean1
Scratcher
Registered: 2010-02-12
Posts: 1000+

Re: |How to make a new block type?|

Oh can you add more deatai to your guide.


You can now reach me on Twitter @johnnydean1_

Offline

 

#8 2010-08-13 08:27:51

Billybob-Mario
Scratcher
Registered: 2008-01-05
Posts: 500+

Re: |How to make a new block type?|

nXIII wrote:

Make a CommandBlockMorph subclass and some changes to ScriptableScratchMorph's blocks methods. Change the drawing method to make it a different shape (I was thinking a W-shaped jagged edge might look cool)

Out of curiosity, what are you doing with this new block type?

How do you tell it what letter to be?
ex: command is -, reporter is r, Boolean is b.

Offline

 

#9 2010-08-13 08:58:14

LS97
Scratcher
Registered: 2009-06-14
Posts: 1000+

Re: |How to make a new block type?|

for that you need to the blockFromSpec:color: method under 'blocks' in ScriptableScratchMorph

Offline

 

#10 2010-08-14 09:56:52

Billybob-Mario
Scratcher
Registered: 2008-01-05
Posts: 500+

Re: |How to make a new block type?|

LS97 wrote:

for that you need to the blockFromSpec:color: method under 'blocks' in ScriptableScratchMorph

That was the last thing that I needed to know before posting 1.0. Thank you.

Offline

 

#11 2010-08-14 11:14:31

LS97
Scratcher
Registered: 2009-06-14
Posts: 1000+

Re: |How to make a new block type?|

you're welcome  smile

Offline

 

#12 2011-03-11 15:46:16

scratcher7_13
Scratcher
Registered: 2011-02-09
Posts: 1000+

Re: |How to make a new block type?|

I don't get this. I added a block type, but whenever I make a block spec with that type as the block, I get an error. Could someone explain this in more detail?<wait(60)secsc>


♫ 90% of teens can't do math. If you are one of the 40% of teens who can, copy and paste this into your signature. ♫♪
http://dl.dropbox.com/u/6273449/BlockLibraryTitle.pnghttp://i.imgur.com/mr9Hf.gif

Offline

 

#13 2013-02-01 23:32:44

WIlliam7777
Scratcher
Registered: 2012-07-21
Posts: 41

Re: |How to make a new block type?|

scratcher7_13 wrote:

I don't get this. I added a block type, but whenever I make a block spec with that type as the block, I get an error. Could someone explain this in more detail?<wait(60)secsc>

Error what?

Offline

 

#14 2013-02-02 03:40:26

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

Re: |How to make a new block type?|

WIlliam7777 wrote:

scratcher7_13 wrote:

I don't get this. I added a block type, but whenever I make a block spec with that type as the block, I get an error. Could someone explain this in more detail?<wait(60)secsc>

Error what?

Please look at the date something was posted before replying to it.


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

Offline

 

Board footer