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

#1126 2011-01-07 19:41:34

Pecola1
Scratcher
Registered: 2010-09-06
Posts: 1000+

Re: Welcome to the OLD local block library!

the users name was not entered for this quote so we will just put:  wrote:

('%b=%b' #b #a:equalsb:)

Code:

a:t1 equalsb:t2
t1 = t2 ifTrue [^true].
^false.

What it does:
Reports wether or not the two booleans are equal.
http://dl.dropbox.com/u/6273449/BlockLibDiv2.png

@Sparks This block is the same as the original
[blocks]    <(     <=>     )> [/blocks]
block. Remember you can insert booleans into text inserts, so the original is the same only allows you to use text and/or booleans. It is taking up space on Scratch.mit.edu and it isn't free to have a webpage they have to pay $.


                                            <(  <mouse down?> <=>   <loud?> )> [/blocks]

sparks wrote:

SaveTheSpaces!DueToCarelessOveruseageOfSpaces,
TheyHaveBecomeAnEndangeredSpecies!StandUpForWhatIsRight!

Last edited by Pecola1 (2011-01-07 19:49:37)


If you are reading this, please read to the end, because if you don't you won't know what's at the end. Don't just skip to the end though otherwise you won't be able to read the middle, which is most important. Now you must be wondering why you just read all that, the reason is you may have not noticed something, read it again and see if you notice it this time  smile

Offline

 

#1127 2011-01-08 07:36:09

ProgrammingFreak
Scratcher
Registered: 2010-09-04
Posts: 1000+

Re: Welcome to the OLD local block library!

I tried my code and it didn't work!

Offline

 

#1128 2011-01-08 08:31:28

SSBBM
Scratcher
Registered: 2009-10-09
Posts: 100+

Re: Welcome to the OLD local block library!

floppy_gunk wrote:

I've got several BYOB blocks...

Wow, Panther is a great tool for automating stuff (like typing out the images and links) that would normally take an hour!  big_smile

Nice! That's about how much I added when I first saw this thread.


http://goo.gl/zVfAp http://goo.gl/laci8

Offline

 

#1129 2011-01-08 08:47:02

Hardmath123
Scratcher
Registered: 2010-02-19
Posts: 1000+

Re: Welcome to the OLD local block library!

Pecola1 wrote:

the users name was not entered for this quote so we will just put:  wrote:

('%b=%b' #b #a:equalsb:)

Code:

a:t1 equalsb:t2
t1 = t2 ifTrue [^true].
^false.

What it does:
Reports wether or not the two booleans are equal.
http://dl.dropbox.com/u/6273449/BlockLibDiv2.png

@Sparks This block is the same as the original
[blocks]    <(     <=>     )> [/blocks]
block. Remember you can insert booleans into text inserts, so the original is the same only allows you to use text and/or booleans. It is taking up space on Scratch.mit.edu and it isn't free to have a webpage they have to pay $.


                                            <(  <mouse down?> <=>   <loud?> )> [/blocks]

sparks wrote:

SaveTheSpaces!DueToCarelessOveruseageOfSpaces,
TheyHaveBecomeAnEndangeredSpecies!StandUpForWhatIsRight!

Ok, I get it.  mad

jk, I understand. On that note, why are the <[]>[]> blocks string inputs?


Hardmaths-MacBook-Pro:~ Hardmath$ sudo make $(whoami) a sandwich

Offline

 

#1130 2011-01-08 08:52:37

Hardmath123
Scratcher
Registered: 2010-02-19
Posts: 1000+

Re: Welcome to the OLD local block library!

Pecola1 wrote:

MathWizz wrote:

Pecola1 wrote:


The hashes are like broadcast almost; it means that the computer will look for a code named whatever is after the #.
The [ and ] are (I am not really sure)  Like for conditions such as ifTrue: [^ true].

(I thought you were an expert?)

No, #selector is a selector. It is almost identical to a string.

I know but it also SELECTS different codes like broadcasting. That is how it is used in block specs.

So it's like this:

Code:

 docodingof: t1

#t1

should do the coding of the inout (i.e. 'forward: 10' will make it go forward 10 steps)?


Hardmaths-MacBook-Pro:~ Hardmath$ sudo make $(whoami) a sandwich

Offline

 

#1131 2011-01-08 08:54:39

Hardmath123
Scratcher
Registered: 2010-02-19
Posts: 1000+

Re: Welcome to the OLD local block library!

sparks wrote:

yeah, you can still post it, I'll just add a note to say, warning, takes some time to execute.

Doesn't take time, freezes Scratch for upto 2 seconds!


Hardmaths-MacBook-Pro:~ Hardmath$ sudo make $(whoami) a sandwich

Offline

 

#1132 2011-01-08 10:26:42

comp500
Scratcher
Registered: 2010-01-08
Posts: 1000+

Re: Welcome to the OLD local block library!

comp500 wrote:

sparks wrote:

Yes, sorry comp, they're already in the library but thanks all the same for your contribution  smile

The second one isn't in panther or scratch, just byob.

ADD IT!


800 posts! W00T! Oh sorry im not on a lot but at least i have 1000+ posts

Offline

 

#1133 2011-01-08 11:32:05

SSBBM
Scratcher
Registered: 2009-10-09
Posts: 100+

Re: Welcome to the OLD local block library!

comp500 wrote:

ADD IT!

You do know that Sparks, me, and almost everyone here has a life outside of scratch. I know how boring it is to wait, but sometimes we have to.


http://goo.gl/zVfAp http://goo.gl/laci8

Offline

 

#1134 2011-01-08 12:51:37

Pecola1
Scratcher
Registered: 2010-09-06
Posts: 1000+

Re: Welcome to the OLD local block library!

SSBBMIsSavingSpacesToo!Yay!Hey...MeToo!


If you are reading this, please read to the end, because if you don't you won't know what's at the end. Don't just skip to the end though otherwise you won't be able to read the middle, which is most important. Now you must be wondering why you just read all that, the reason is you may have not noticed something, read it again and see if you notice it this time  smile

Offline

 

#1135 2011-01-08 12:55:24

Pecola1
Scratcher
Registered: 2010-09-06
Posts: 1000+

Re: Welcome to the OLD local block library!

Hardmath123 wrote:

Pecola1 wrote:

MathWizz wrote:

No, #selector is a selector. It is almost identical to a string.

I know but it also SELECTS different codes like broadcasting. That is how it is used in block specs.

So it's like this:

Code:

 docodingof: t1

#t1

should do the coding of the inout (i.e. 'forward: 10' will make it go forward 10 steps)?

Yes, notice how whoever put on the press green flag used:

Code:

pressGreenFlag
     #pressGreenFlagButton

But it didn't work, why? Because it was not in the same class as pressGreenFlagButton. I am not sure exactly how or why but this is what I am pretty sure is true.
BTW great block!
Just found out:
the

Code:

 docodingof: t1

#t1

block will not work because it has to be:

Code:

 docodingof: t1

^#t1

but that wont work because the # before t1 makes t1 not the insert, it tries to do t1 instead, even when you make it a reporter it will report t1. I couldn't find a way to fix it  hmm  .

Last edited by Pecola1 (2011-01-08 13:05:32)


If you are reading this, please read to the end, because if you don't you won't know what's at the end. Don't just skip to the end though otherwise you won't be able to read the middle, which is most important. Now you must be wondering why you just read all that, the reason is you may have not noticed something, read it again and see if you notice it this time  smile

Offline

 

#1136 2011-01-08 12:58:29

ProgrammingFreak
Scratcher
Registered: 2010-09-04
Posts: 1000+

Re: Welcome to the OLD local block library!

ProgrammingFreak wrote:

I tried my code and it didn't work!

Offline

 

#1137 2011-01-08 13:06:02

Pecola1
Scratcher
Registered: 2010-09-06
Posts: 1000+

Re: Welcome to the OLD local block library!

ProgrammingFreak wrote:

I tried my code and it didn't work!

What code?

Last edited by Pecola1 (2011-01-08 13:06:57)


If you are reading this, please read to the end, because if you don't you won't know what's at the end. Don't just skip to the end though otherwise you won't be able to read the middle, which is most important. Now you must be wondering why you just read all that, the reason is you may have not noticed something, read it again and see if you notice it this time  smile

Offline

 

#1138 2011-01-08 13:08:37

ProgrammingFreak
Scratcher
Registered: 2010-09-04
Posts: 1000+

Re: Welcome to the OLD local block library!

Blockspec:
('alert %s' #- #alert:)

code:
alert: t1
t1<-DialogBoxMorph new title: '?' inform: t1.

Offline

 

#1139 2011-01-08 14:12:18

sparks
Community Moderator
Registered: 2008-11-05
Posts: 1000+

Re: Welcome to the OLD local block library!

Hi guys, my life in unpredictable and slightly manic at the moment due to exams, essays and university applications. I'm not going to sit down and update for a bit, but please feel free to continue sharing! Thanks for understanding  smile


http://img541.imageshack.us/img541/7563/scratchbetabanner.png

Offline

 

#1140 2011-01-08 14:41:39

Pecola1
Scratcher
Registered: 2010-09-06
Posts: 1000+

Re: Welcome to the OLD local block library!

ProgrammingFreak wrote:

Blockspec:
('alert %s' #- #alert:)

code:
alert: t1
t1<-DialogBoxMorph new title: '?' inform: t1.

The reason why is because you cannot change an insert in the code, you will need to make a new variable like this:

Code:

alert: t1
| t2 |
t2 _ DialogBoxMorph new title: '?' inform: t1
^ t2

Note it still wont work.

Last edited by Pecola1 (2011-01-08 14:42:33)


If you are reading this, please read to the end, because if you don't you won't know what's at the end. Don't just skip to the end though otherwise you won't be able to read the middle, which is most important. Now you must be wondering why you just read all that, the reason is you may have not noticed something, read it again and see if you notice it this time  smile

Offline

 

#1141 2011-01-08 14:45:47

ProgrammingFreak
Scratcher
Registered: 2010-09-04
Posts: 1000+

Re: Welcome to the OLD local block library!

Pecola1 wrote:

ProgrammingFreak wrote:

Blockspec:
('alert %s' #- #alert:)

code:
alert: t1
t1<-DialogBoxMorph new title: '?' inform: t1.

The reason why is because you cannot change an insert in the code, you will need to make a new variable like this:

Code:

alert: t1
| t2 |
t2 _ DialogBoxMorph new title: '?' inform: t1
^ t2

Note it still wont work.

if we fix it do you want it in RKT?

Offline

 

#1142 2011-01-08 15:01:22

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

Re: Welcome to the OLD local block library!

Pecola1 wrote:

ProgrammingFreak wrote:

Blockspec:
('alert %s' #- #alert:)

code:
alert: t1
t1<-DialogBoxMorph new title: '?' inform: t1.

The reason why is because you cannot change an insert in the code, you will need to make a new variable like this:

Code:

alert: t1
| t2 |
t2 _ DialogBoxMorph new title: '?' inform: t1
^ t2

Note it still wont work.

it works!

Code:

alert: t1 
    DialogBoxMorph inform: t1 title: '?'

it has to have the inform before the title, and there is no reason for a second variable.

Last edited by scimonster (2011-01-08 15:08:33)

Offline

 

#1143 2011-01-08 15:15:00

ProgrammingFreak
Scratcher
Registered: 2010-09-04
Posts: 1000+

Re: Welcome to the OLD local block library!

scimonster wrote:

Pecola1 wrote:

ProgrammingFreak wrote:

Blockspec:
('alert %s' #- #alert:)

code:
alert: t1
t1<-DialogBoxMorph new title: '?' inform: t1.

The reason why is because you cannot change an insert in the code, you will need to make a new variable like this:

Code:

alert: t1
| t2 |
t2 _ DialogBoxMorph new title: '?' inform: t1
^ t2

Note it still wont work.

it works!

Code:

alert: t1 
    DialogBoxMorph inform: t1 title: '?'

it has to have the inform before the title, and there is no reason for a second variable.

yay! like?

Offline

 

#1144 2011-01-08 15:27:28

Pecola1
Scratcher
Registered: 2010-09-06
Posts: 1000+

Re: Welcome to the OLD local block library!

ProgrammingFreak wrote:

Pecola1 wrote:

ProgrammingFreak wrote:

Blockspec:
('alert %s' #- #alert:)

code:
alert: t1
t1<-DialogBoxMorph new title: '?' inform: t1.

The reason why is because you cannot change an insert in the code, you will need to make a new variable like this:

Code:

alert: t1
| t2 |
t2 _ DialogBoxMorph new title: '?' inform: t1
^ t2

Note it still wont work.

if we fix it do you want it in RKT?

Nah... we can use the open dialogue titled ( ) with text ()


If you are reading this, please read to the end, because if you don't you won't know what's at the end. Don't just skip to the end though otherwise you won't be able to read the middle, which is most important. Now you must be wondering why you just read all that, the reason is you may have not noticed something, read it again and see if you notice it this time  smile

Offline

 

#1145 2011-01-08 15:32:44

Pecola1
Scratcher
Registered: 2010-09-06
Posts: 1000+

Re: Welcome to the OLD local block library!

New block
Spec
('Play default system beep' #- #beepDefault)

Method
beepDeafault
self beep


If you are reading this, please read to the end, because if you don't you won't know what's at the end. Don't just skip to the end though otherwise you won't be able to read the middle, which is most important. Now you must be wondering why you just read all that, the reason is you may have not noticed something, read it again and see if you notice it this time  smile

Offline

 

#1146 2011-01-08 15:44:10

MathWizz
Scratcher
Registered: 2009-08-31
Posts: 1000+

Re: Welcome to the OLD local block library!

Pecola1 wrote:

New block
Spec
('Play default system beep' #- #beepDefault)

Method
beepDeafault
self beep

Just use:
('beep' #- #beep)


http://block.site90.net/scratch.mit/text.php?size=30&amp;text=%20A%20signature!&amp;color=333333

Offline

 

#1147 2011-01-08 16:04:25

Pecola1
Scratcher
Registered: 2010-09-06
Posts: 1000+

Re: Welcome to the OLD local block library!

MathWizz wrote:

Pecola1 wrote:

New block
Spec
('Play default system beep' #- #beepDefault)

Method
beepDeafault
self beep

Just use:
('beep' #- #beep)

No, then they don't know what it does, i think It should be
('sound the default system beep' #- #beepDefault)


If you are reading this, please read to the end, because if you don't you won't know what's at the end. Don't just skip to the end though otherwise you won't be able to read the middle, which is most important. Now you must be wondering why you just read all that, the reason is you may have not noticed something, read it again and see if you notice it this time  smile

Offline

 

#1148 2011-01-08 16:06:38

Pecola1
Scratcher
Registered: 2010-09-06
Posts: 1000+

Re: Welcome to the OLD local block library!

Hardmath123 wrote:

Pecola1 wrote:

the users name was not entered for this quote so we will just put:  wrote:

('%b=%b' #b #a:equalsb:)

Code:

What it does:
Reports wether or not the two booleans are equal.
http://dl.dropbox.com/u/6273449/BlockLibDiv2.png

@Sparks This block is the same as the original
[blocks]    <(     <=>     )> [/blocks]
block. Remember you can insert booleans into text inserts, so the original is the same only allows you to use text and/or booleans. It is taking up space on Scratch.mit.edu and it isn't free to have a webpage they have to pay $.


                                            <(  <mouse down?> <=>   <loud?> )> [/blocks]

sparks wrote:

SaveTheSpaces!DueToCarelessOveruseageOfSpaces,
TheyHaveBecomeAnEndangeredSpecies!StandUpForWhatIsRight!

Ok, I get it.  mad

jk, I understand. On that note, why are the <[]>[]> blocks string inputs?

What note?


If you are reading this, please read to the end, because if you don't you won't know what's at the end. Don't just skip to the end though otherwise you won't be able to read the middle, which is most important. Now you must be wondering why you just read all that, the reason is you may have not noticed something, read it again and see if you notice it this time  smile

Offline

 

#1149 2011-01-08 17:03:42

MathWizz
Scratcher
Registered: 2009-08-31
Posts: 1000+

Re: Welcome to the OLD local block library!

Pecola1 wrote:

MathWizz wrote:

Pecola1 wrote:

New block
Spec
('Play default system beep' #- #beepDefault)

Method
beepDeafault
self beep

Just use:
('beep' #- #beep)

No, then they don't know what it does, i think It should be
('sound the default system beep' #- #beepDefault)

No, the point is, you don't need to make a new method for a method that's already there.
('sound the default system beep' #- #beep) works fine.


http://block.site90.net/scratch.mit/text.php?size=30&amp;text=%20A%20signature!&amp;color=333333

Offline

 

#1150 2011-01-09 01:32:00

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

Re: Welcome to the OLD local block library!

Pecola1 wrote:

Hardmath123 wrote:

Pecola1 wrote:

@Sparks This block is the same as the original
[blocks]    <(     <=>     )> [/blocks]
block. Remember you can insert booleans into text inserts, so the original is the same only allows you to use text and/or booleans. It is taking up space on Scratch.mit.edu and it isn't free to have a webpage they have to pay $.


                                            <(  <mouse down?> <=>   <loud?> )> [/blocks]

Ok, I get it.  mad

jk, I understand. On that note, why are the <[]>[]> blocks string inputs?

What note?

While we're on the topic of the >=< booleans, why are they string inserts?

Let me have a guess...

Scratch 1.4 is the first version to actually have good string technology.  In 1.3.1 and lower, variables couldn't be strings  yikes  , strings couldn't be compared, there were no ask or answer blocks, and there were none of the string control blocks (join [][], letter () of [], length of []).  There were four places for strings:

[blocks]<say[ Hello ]for( 2 )secs><say[ Hello <think[ Hmm... ]for( 2 )secs><think[ Hmm... [/blocks]

So now numbers, strings, reporters, and booleans can be compared.  smile
Anything is a string.  cool

Last edited by scimonster (2011-01-09 04:06:29)

Offline

 

Board footer