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

#1526 2011-07-08 03:14:41

littlebird2472
Scratcher
Registered: 2010-03-05
Posts: 42

Re: Cool custom blocks in Scratch

Can somebody make answer contains[] for me? I'm a beginner at squeak and I want it for my coding language.


http://dragcave.net/image/MoLDl.gif Please click and help my dragon survive!

Offline

 

#1527 2011-07-08 09:51:58

flurr
Scratcher
Registered: 2010-12-26
Posts: 21

Re: Cool custom blocks in Scratch

i tried to get the get time/date block and the save stage area to sprite block and they didn't work i think it was because whenever i went out of the system browser or pressed a button it said nothing had been saved continue or not i continued because i dont know how to save in the system browser. if this is the problem can somebody tell me how to save if this is not the problem can somebody tell me what is because i did what the instructions said to do.  sad


flurr rockz :p
http://2.bp.blogspot.com/-4skvYONnbxI/TlZnrENJ7II/AAAAAAAA238/9jTbJJN4OmM/s1600/Cool-Abstract-Background.jpg

Offline

 

#1528 2011-07-08 09:56:03

flurr
Scratcher
Registered: 2010-12-26
Posts: 21

Re: Cool custom blocks in Scratch

flurr wrote:

i tried to get the get time/date block and the save stage area to sprite block and they didn't work i think it was because whenever i went out of the system browser or pressed a button it said nothing had been saved continue or not i continued because i dont know how to save in the system browser. if this is the problem can somebody tell me how to save if this is not the problem can somebody tell me what is because i did what the instructions said to do.  sad

wait never mind i know wat it was.


flurr rockz :p
http://2.bp.blogspot.com/-4skvYONnbxI/TlZnrENJ7II/AAAAAAAA238/9jTbJJN4OmM/s1600/Cool-Abstract-Background.jpg

Offline

 

#1529 2011-07-09 18:21:22

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

Re: Cool custom blocks in Scratch

littlebird2472 wrote:

Can somebody make answer contains[] for me? I'm a beginner at squeak and I want it for my coding language.

('answer contains %s' #b #answerContains 'thing')


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

Offline

 

#1530 2011-07-09 20:24:42

tpaley
Scratcher
Registered: 2011-05-22
Posts: 100+

Re: Cool custom blocks in Scratch

The website block doesn't work


http://i49.tinypic.com/2z82h3d.gif

Offline

 

#1531 2011-07-11 13:37:27

tpaley
Scratcher
Registered: 2011-05-22
Posts: 100+

Re: Cool custom blocks in Scratch

also, I can't download if the the get date/time/etc. block is being used <{get [time]}>


http://i49.tinypic.com/2z82h3d.gif

Offline

 

#1532 2011-07-11 17:21:41

meman124
Scratcher
Registered: 2010-12-11
Posts: 3

Re: Cool custom blocks in Scratch

what is the command for "delete me? <when green flag clicked> eat pie


You Must Enter the Nether!
-Minecraft

Offline

 

#1533 2011-07-12 21:13:43

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

Re: Cool custom blocks in Scratch

meman124 wrote:

what is the command for "delete me? <when green flag clicked> eat pie

delete me is ('delete me' #- #undoableDeleteSprite)


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

Offline

 

#1534 2011-07-26 16:19:09

littlebird2472
Scratcher
Registered: 2010-03-05
Posts: 42

Re: Cool custom blocks in Scratch

poemon1 wrote:

littlebird2472 wrote:

Can somebody make answer contains[] for me? I'm a beginner at squeak and I want it for my coding language.

('answer contains %s' #b #answerContains 'thing')

The block doesn't work.

Last edited by littlebird2472 (2011-07-26 16:19:21)


http://dragcave.net/image/MoLDl.gif Please click and help my dragon survive!

Offline

 

#1535 2011-07-26 16:38:05

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

Re: Cool custom blocks in Scratch

littlebird2472 wrote:

poemon1 wrote:

littlebird2472 wrote:

Can somebody make answer contains[] for me? I'm a beginner at squeak and I want it for my coding language.

('answer contains %s' #b #answerContains 'thing')

The block doesn't work.

try copying the code off slash


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

Offline

 

#1536 2011-07-26 16:41:25

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

Re: Cool custom blocks in Scratch

poemon1 wrote:

littlebird2472 wrote:

poemon1 wrote:


('answer contains %s' #b #answerContains 'thing')

The block doesn't work.

try copying the code off slash

('%s contains %s' #b #if:contains: 'something' 'thing')
and
if: t1 contains: t2
    (t1 findString: t2)
        > 0 ifTrue: [^ true].
    ^ false


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

Offline

 

#1537 2011-07-27 06:29:52

littlebird2472
Scratcher
Registered: 2010-03-05
Posts: 42

Re: Cool custom blocks in Scratch

poemon1 wrote:

poemon1 wrote:

littlebird2472 wrote:


The block doesn't work.

try copying the code off slash

('%s contains %s' #b #if:contains: 'something' 'thing')
and
if: t1 contains: t2
    (t1 findString: t2)
        > 0 ifTrue: [^ true].
    ^ false

Testing it now. Thanks!


http://dragcave.net/image/MoLDl.gif Please click and help my dragon survive!

Offline

 

#1538 2011-07-27 08:15:30

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

Re: Cool custom blocks in Scratch

littlebird2472 wrote:

poemon1 wrote:

poemon1 wrote:


try copying the code off slash

('%s contains %s' #b #if:contains: 'something' 'thing')
and
if: t1 contains: t2
    (t1 findString: t2)
        > 0 ifTrue: [^ true].
    ^ false

Testing it now. Thanks!

yw


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

Offline

 

#1539 2011-09-25 21:10:45

xboxdude
Scratcher
Registered: 2010-08-25
Posts: 12

Re: Cool custom blocks in Scratch

Thank you for this useful tutorial! Now, I can create my,"Say Nothing" block! It will allow you to stop your chat and get rid of your speech bubble.  big_smile   cool I LOVEZ BLEW!  big_smile


My Page                  Most Popular Project
https://lh5.googleusercontent.com/-gh6d1qRHWDM/T2PqJxe9FDI/AAAAAAAAAEE/yyCU_u8DEbg/s351/finish.png

Offline

 

#1540 2011-09-25 21:19:49

xboxdude
Scratcher
Registered: 2010-08-25
Posts: 12

Re: Cool custom blocks in Scratch

Hello again, I created a code to help me do something in Javascript and maybe help others to create a hacking software for other games.

Code:

javascript;c#_(hack)01_addPoints[999999999999999]client;sideHack:giveTeleportaccessEverywhere+freeAdmin4Life:D.createJump/RunValues(Jump:9999999999.Run:9999999999);

Thanks for looking at it!


My Page                  Most Popular Project
https://lh5.googleusercontent.com/-gh6d1qRHWDM/T2PqJxe9FDI/AAAAAAAAAEE/yyCU_u8DEbg/s351/finish.png

Offline

 

#1541 2011-09-25 23:29:30

bbbeb
Scratcher
Registered: 2009-06-11
Posts: 1000+

Re: Cool custom blocks in Scratch

xboxdude wrote:

Hello again, I created a code to help me do something in Javascript and maybe help others to create a hacking software for other games.

Code:

javascript;c#_(hack)01_addPoints[999999999999999]client;sideHack:giveTeleportaccessEverywhere+freeAdmin4Life:D.createJump/RunValues(Jump:9999999999.Run:9999999999);

Thanks for looking at it!

Don't post such things here. They don't belong here. Make a new topic?
But that is a cool thing there...


Back in my day.... there were no laws that censored the internet... now, there are.... nah.

Offline

 

#1542 2011-09-26 11:38:10

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

Re: Cool custom blocks in Scratch

placeholder post: ignore

Offline

 

#1543 2011-10-13 12:14:42

racso
Scratcher
Registered: 2008-07-06
Posts: 15

Re: Cool custom blocks in Scratch

Could you say how to use the (link to [____]).
Thanks  smile


Lalalalalalalalalalalalalalalayellowbananalalalalalalalalalalalalalalalalalalalalalalalalalalalalalalalalalalalalalalalalalalalalalalalalalalalalalal

Offline

 

#1544 2011-10-13 12:16:30

racso
Scratcher
Registered: 2008-07-06
Posts: 15

Re: Cool custom blocks in Scratch

xboxdude wrote:

Thank you for this useful tutorial! Now, I can create my,"Say Nothing" block! It will allow you to stop your chat and get rid of your speech bubble.  big_smile   cool I LOVEZ BLEW!  big_smile

What's the code for that?


Lalalalalalalalalalalalalalalayellowbananalalalalalalalalalalalalalalalalalalalalalalalalalalalalalalalalalalalalalalalalalalalalalalalalalalalalalal

Offline

 

#1545 2011-10-15 03:55:38

racso
Scratcher
Registered: 2008-07-06
Posts: 15

Re: Cool custom blocks in Scratch

flurr wrote:

i tried to get the get time/date block and the save stage area to sprite block and they didn't work i think it was because whenever i went out of the system browser or pressed a button it said nothing had been saved continue or not i continued because i dont know how to save in the system browser. if this is the problem can somebody tell me how to save if this is not the problem can somebody tell me what is because i did what the instructions said to do.  sad

If you want to save the custom block scroll to the bottom and right click the blank space and then click "accept (s)".


Lalalalalalalalalalalalalalalayellowbananalalalalalalalalalalalalalalalalalalalalalalalalalalalalalalalalalalalalalalalalalalalalalalalalalalalalalal

Offline

 

#1546 2011-10-15 04:11:49

rookwood101
Scratcher
Registered: 2011-07-29
Posts: 500+

Re: Cool custom blocks in Scratch

guys, use the block library, it's much more easy to navigate and understand.


http://i.imgur.com/zeIZW.png

Offline

 

#1547 2011-10-15 16:06:29

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

Re: Cool custom blocks in Scratch

rookwood101 wrote:

guys, use the block library, it's much more easy to navigate and understand.

Thank you. I even specified in first post.

Offline

 

#1548 2011-10-29 14:21:41

tmbates12
New Scratcher
Registered: 2011-10-06
Posts: 1

Re: Cool custom blocks in Scratch

I used many of these blocks,but once i closed scratch they dissapeared :~(

Offline

 

#1549 2012-02-07 21:54:06

AlexamonSpace
Scratcher
Registered: 2012-01-20
Posts: 16

Re: Cool custom blocks in Scratch

LS97 wrote:

Note. IF THIS IS THE FIRST TIME YOU ARE READING THIS THREAD, READ THIS!
I am not doing any requests for blocks. This thread is now defunct, so please use it for information only and do not post requests. I will not answer any requests nor anymore clarifications. There's an amazing block library now where you can find many more blocks. If you have a good question about mods, you may post, but your question might not be answered.

Hey Scratchers!
Are you all wondering how to make your own blocks in Scratch using Squeak? Well then, you've come to the right place. This forum thread will include tutorials, links to other projects, and more to make blocks like this:

http://www.freeimagehosting.net/uploads/ef0a230720.gif

The blocks are pretty much self-explanatory, so no need for a list of what they do. i'll start with the block-making right away.

Note for the lazy people: this tutorial aims to teach people to work in Squeak, not only to get the new blocks. So do not ask for my image file.

First, we have to open the system browser. Here's a tutorial for it:
T - Open Browser

Now, we're ready to start programming. From the browser, go to:
>Scratch-Objects
>ScriptableScratchMorph
>Click onto Class
>Scratch (or) BlockSpecs
>blockSpecks

Here we've got the main bit of blocks. it all looks very messy, so you can use the find option if you want to save your eyes when looking for a block. Now let's take a block to analize: the yellow repeat(X) block.
http://www.freeimagehosting.net/uploads/fb29012635.png
See how i highlighted a bit? that's the code for that block.
The block coding structure is as follows:

('repeat %n' #c #doRepeat 10)
the block is identified by the two brackets (blue).
the block text is in between apostrophes (black).
the block type identifier or block arguments follow a # sign (red).
the command also follows a # sign (green).
any additional arguments follow the command (purple).

the %n in the block is the input box, where the user can put the number. in fact, %n produces that round textbox where only numbers can be inserted. here's the full list:

Code:

a:  attribute of another sprite, such as X position or size.
b:  a boolean inserter
c:  a colour picker that shows the menu.
C:  a colour picker that doesn't
d:  the sprite direction menu/numerical inserter.
D:  the menu for midi drums
e:  The broadcast message menu
f:  math function menu (with sin, abs, etc.)
g:  menu for the different graphic effects.
h:  numerical sensor board selector menu
H:  boolean sensor board selector menu
i:  midi instrument menu/numerical inserter
k:  menu for the names of the different keys, used in the key sensor blocks.
l:  menu with the costume names of the given sprite.
L:  list name menu.
m:  sprite list
n:  numerical inserter
N:  note name menu/inserter
s:  string inserter
S:  sound selector menu
v:  variable labels menu
y:  menu used to delete either a number of the last value or all of a list.

Credit to billyedward for this list.

the repeat block, having to 'host' other blocks in it, is C shaped. that's why the block argument (above in red) is a c.
Here's a brief list of the different arguments:

Code:

#-   no arguments (command or 'stack' block)
#r   Reporter block (the round ones)
#b   boolean block (diamond shaped)
#c   C shaped block (like the forever block)
#t   Time block (like wait X secs)
#W   'when' hat block (obsolete)
#S   start button click hat block
#K   key-activated hat block
#E   event hat block (broadcast)
#s   special form (hard to code)

but it's not all that simple! now that we've got the block in the block palette, we need to give it the code it needs to perform the action. for this you need to go to 'instance', then to the appropriate 'ops'. there, after creating a method, you can add the code you need.
________
Now that you know a bit about the structure, we can move on quickly to the actual new blocks you saw at the beginning. I'm not going to add them into this post, it would be too long. you'll find the different blocks in different posts.
I hope you'll enjoy your new blocks!

well, I can't find the first block specs in 1.4. Are you using something different?


http://alexamonspace.webs.com/logo.png<----->http://www.lxshare.com/vi-BPqfwA.png
-Alexamon at http://alexamonspace.webs.com/

Offline

 

#1550 2012-02-24 07:27:13

dreamod
New Scratcher
Registered: 2012-01-22
Posts: 100+

Re: Cool custom blocks in Scratch

bbbeb wrote:

oh my god.

i swear, no one will make a <talking?> block!  tongue

I already made one, wait I made four! <talking?> <thinking?> (saying) (thinking)

Offline

 

Board footer