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

#2326 2011-11-08 21:03:30

Greenatic
Scratcher
Registered: 2009-05-03
Posts: 1000+

Re: ITopic: Welcome to your local block library!

Pecola1 wrote:

Greenatic wrote:

Pecola1 wrote:

smile  I remember these in NetScratch!  smile  They are some VERY cool blocks.

They were in NetScratch? ...Sorry if it looks like I copied, I promise I came up with this block and its code on my own.

No no no no no, I can tell you didn't copy it. I think NetScratch used the same type of thing as the time block, either that or an api, your block uses a different source, and more things to insert.  smile  I like blocks like this.

Thanks.  I was thinking about making a translate one but Google is abolishing their free translation API on the December 1st.   sad   I was also thinking about making a block using Google's stock API which they use for Google Finance--do you think that would be useful?

Last edited by Greenatic (2011-11-08 21:04:09)

Offline

 

#2327 2011-11-09 23:23:14

AIOlover
Scratcher
Registered: 2011-05-08
Posts: 100+

Re: ITopic: Welcome to your local block library!

Can I request a block?


I'm currently http://blocks.scratchr.org/API.php?user=AIOlover&action=onlineStatus&type=text!
big_smile ~AIOlover~ big_smile

Offline

 

#2328 2011-11-09 23:25:50

meowmeow55
Scratcher
Registered: 2008-12-24
Posts: 1000+

Re: ITopic: Welcome to your local block library!

AIOlover wrote:

Can I request a block?

Sure, go ahead!


Yawn.

Offline

 

#2329 2011-11-09 23:31:09

AIOlover
Scratcher
Registered: 2011-05-08
Posts: 100+

Re: ITopic: Welcome to your local block library!

If someone could create a play chord sound block with three note inputers, I would be extremely grateful. I would like it in Scratc. Thanks!

Last edited by AIOlover (2011-11-17 10:37:39)


I'm currently http://blocks.scratchr.org/API.php?user=AIOlover&action=onlineStatus&type=text!
big_smile ~AIOlover~ big_smile

Offline

 

#2330 2011-11-10 09:20:20

cocolover76
Scratcher
Registered: 2011-10-09
Posts: 500+

Re: ITopic: Welcome to your local block library!

YourLocalBlockLib wrote:

http://scratch.mit.edu/redirect/url?link=http://www.weebly.com/uploads/7/1/1/0/7110842/6396941.gif Shared by Pecola1

Blockspec:

('password for %s is %s ?' #b #username:password:)

Code:

username: t1 password: t2
    (HTTPSocket httpGet: 'contentshttp://scratch.mit.edu/api/authenticateuser?username=' , t1 , '&password=' , t2) contents = 'false' ifTrue: [^false].
^true

What this block does:
Reports whether the password for the username that is inserted is the right password. Useful for making a project which requires you have a Scratch account.

I'm not exactly sure that that would always be used for the better...........


http://i.imgur.com/HfEPZ.gifhttp://i.imgur.com/pvKb6.png

Offline

 

#2331 2011-11-10 09:22:04

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

Re: ITopic: Welcome to your local block library!

cocolover76 wrote:

YourLocalBlockLib wrote:

http://scratch.mit.edu/redirect/url?lin … 396941.gif Shared by Pecola1

Blockspec:

('password for %s is %s ?' #b #username:password:)

Code:

username: t1 password: t2
    (HTTPSocket httpGet: 'contentshttp://scratch.mit.edu/api/authenticateuser?username=' , t1 , '&password=' , t2) contents = 'false' ifTrue: [^false].
^true

What this block does:
Reports whether the password for the username that is inserted is the right password. Useful for making a project which requires you have a Scratch account.

I'm not exactly sure that that would always be used for the better...........

>.> Why do we keep bringing this up?

XD


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

 

#2332 2011-11-10 09:26:53

cocolover76
Scratcher
Registered: 2011-10-09
Posts: 500+

Re: ITopic: Welcome to your local block library!

Pecola1 wrote:

cocolover76 wrote:

YourLocalBlockLib wrote:

http://scratch.mit.edu/redirect/url?lin … 396941.gif Shared by Pecola1

Blockspec:

('password for %s is %s ?' #b #username:password:)

Code:

What this block does:
Reports whether the password for the username that is inserted is the right password. Useful for making a project which requires you have a Scratch account.

I'm not exactly sure that that would always be used for the better...........

>.> Why do we keep bringing this up?

XD

Well, what if someone makes a random text block?
Then they'd have to delete either the random text block, both blocks, or even get rid of the whole block library.


http://i.imgur.com/HfEPZ.gifhttp://i.imgur.com/pvKb6.png

Offline

 

#2333 2011-11-10 09:27:59

cocolover76
Scratcher
Registered: 2011-10-09
Posts: 500+

Re: ITopic: Welcome to your local block library!

Greenatic wrote:

but Google is abolishing their free translation API on the December 1st

Then download it before December 1st.


http://i.imgur.com/HfEPZ.gifhttp://i.imgur.com/pvKb6.png

Offline

 

#2334 2011-11-10 16:57:20

Greenatic
Scratcher
Registered: 2009-05-03
Posts: 1000+

Re: ITopic: Welcome to your local block library!

cocolover76 wrote:

Greenatic wrote:

but Google is abolishing their free translation API on the December 1st

Then download it before December 1st.

It's on the Internet.  The source code isn't free, using the API is.

Offline

 

#2335 2011-11-10 19:10:52

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

Re: ITopic: Welcome to your local block library!

Greenatic wrote:

Pecola1 wrote:

Greenatic wrote:


They were in NetScratch? ...Sorry if it looks like I copied, I promise I came up with this block and its code on my own.

No no no no no, I can tell you didn't copy it. I think NetScratch used the same type of thing as the time block, either that or an api, your block uses a different source, and more things to insert.  smile  I like blocks like this.

Thanks.  I was thinking about making a translate one but Google is abolishing their free translation API on the December 1st.   sad   I was also thinking about making a block using Google's stock API which they use for Google Finance--do you think that would be useful?

Google has a stock Api?
It would be useful for some, so yes.  smile


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

 

#2336 2011-11-10 19:12:50

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

Re: ITopic: Welcome to your local block library!

cocolover76 wrote:

Pecola1 wrote:

cocolover76 wrote:


I'm not exactly sure that that would always be used for the better...........

>.> Why do we keep bringing this up?

XD

Well, what if someone makes a random text block?
Then they'd have to delete either the random text block, both blocks, or even get rid of the whole block library.

No then the step would be to take off the posting function.

How many times have I said that again?
tongue


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

 

#2337 2011-11-10 21:34:48

Greenatic
Scratcher
Registered: 2009-05-03
Posts: 1000+

Re: ITopic: Welcome to your local block library!

Fellow librarians, your advice is requested:  Should the two blocks here be combined?

Offline

 

#2338 2011-11-10 21:46:41

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

Re: ITopic: Welcome to your local block library!

Yes


Also we don't need the true and false booleans, I have the one with a text insert which can have true or false inserted into it.


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

 

#2339 2011-11-10 21:48:59

Greenatic
Scratcher
Registered: 2009-05-03
Posts: 1000+

Re: ITopic: Welcome to your local block library!

Pecola1 wrote:

Yes


Also we don't need the true and false booleans, I have the one with a text insert which can have true or false inserted into it.

I think we should deliberate with other librarians before removing the true/false blocks (even though I do agree).

EDIT:  The two megablocks are now one gigablock.   smile

Last edited by Greenatic (2011-11-10 21:55:37)

Offline

 

#2340 2011-11-13 21:19:41

Greenatic
Scratcher
Registered: 2009-05-03
Posts: 1000+

Re: ITopic: Welcome to your local block library!

The above post requires other librarians' opinions.

Sparks, I am unaware of the procedures for BYOB or Panther block updates (I don't even have BYOB; on a side note, could someone please give me a link?)  I saw two Panther requests and have fulfilled both of them.  Could you do a Panther update?

Blockspec: average color of pixels in square x:$Number$y:$Number$ to x:$Number$y:$Number$
Type: g
Category: Color blocks

Code:

^ Color r: (((self colorAtX: t1 y: t2) red + (self colorAtX: t3 y:t4) red) / 2) g: (((self colorAtX: t1 y: t2) green + (self colorAtX: t3 y:t4) green) / 2) b:  (((self colorAtX: t1 y: t2) blue + (self colorAtX: t3 y:t4) blue) / 2)

Blockspec: turn costume $Number$ into new sprite
Type: -
Category: Looks blocks

Code:

|t2 |
(t1 < 0) | (t1 ~= t1 rounded) | (t1 > (media select:[:t7| t7 isImage]) size) ifTrue:[^ self].
t2 _ self costumeNameFromNumber: t1.
((self costumesPage: 0) submorphs select:[:t5 |
t5 isKindOf: MediaItemMorph] ) do:[:t6 | t6 mediaName = t2
ifTrue:[
t2 _ self ownerThatIsA: ScratchFrameMorph.
    t2 ifNil: [^ self].
t2 addAndView:      (ScratchSpriteMorph new soleCostume: t6 media deepCopy).
    t6 deleteMedia]].

Offline

 

#2341 2011-11-13 22:37:18

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

Re: ITopic: Welcome to your local block library!

Greenatic wrote:

The above post requires other librarians' opinions.

Sparks, I am unaware of the procedures for BYOB or Panther block updates (I don't even have BYOB; on a side note, could someone please give me a link?)  I saw two Panther requests and have fulfilled both of them.  Could you do a Panther update?

Blockspec: average color of pixels in square x:$Number$y:$Number$ to x:$Number$y:$Number$
Type: g
Category: Color blocks

Code:

^ Color r: (((self colorAtX: t1 y: t2) red + (self colorAtX: t3 y:t4) red) / 2) g: (((self colorAtX: t1 y: t2) green + (self colorAtX: t3 y:t4) green) / 2) b:  (((self colorAtX: t1 y: t2) blue + (self colorAtX: t3 y:t4) blue) / 2)

Blockspec: turn costume $Number$ into new sprite
Type: -
Category: Looks blocks

Code:

|t2 |
(t1 < 0) | (t1 ~= t1 rounded) | (t1 > (media select:[:t7| t7 isImage]) size) ifTrue:[^ self].
t2 _ self costumeNameFromNumber: t1.
((self costumesPage: 0) submorphs select:[:t5 |
t5 isKindOf: MediaItemMorph] ) do:[:t6 | t6 mediaName = t2
ifTrue:[
t2 _ self ownerThatIsA: ScratchFrameMorph.
    t2 ifNil: [^ self].
t2 addAndView:      (ScratchSpriteMorph new soleCostume: t6 media deepCopy).
    t6 deleteMedia]].

SWEET! Your good with math blocks.  big_smile


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

 

#2342 2011-11-13 22:38:50

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

Re: ITopic: Welcome to your local block library!

Greenatic wrote:

Pecola1 wrote:

Yes


Also we don't need the true and false booleans, I have the one with a text insert which can have true or false inserted into it.

I think we should deliberate with other librarians before removing the true/false blocks (even though I do agree).

EDIT:  The two megablocks are now one gigablock.   smile

Of course we should, thats why I posted.
tongue
DISCUSS


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

 

#2343 2011-11-14 06:53:46

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

Re: ITopic: Welcome to your local block library!

I agree with removing <true/false>.
Only Sparks can do Panther updates.

BYOB is at byob.berkeley.edu.
To do an update, save an image of the script makeup, and the end result. Host the image.
If you added a download (broken for now), copy the code for a downloadable block, changing the URLs properly, and otherwise the code for a non-downloadable block.

Offline

 

#2344 2011-11-14 16:59:02

Greenatic
Scratcher
Registered: 2009-05-03
Posts: 1000+

Re: ITopic: Welcome to your local block library!

OK, now 3 out of 6 of the librarians support removal of the true/false blocks.  If one more librarian supports, we'll have a majority.

Offline

 

#2345 2011-11-14 17:00:42

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

Re: ITopic: Welcome to your local block library!

I wouldn't support. Why have something messy when it can be clean?


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

Offline

 

#2346 2011-11-14 17:04:11

Greenatic
Scratcher
Registered: 2009-05-03
Posts: 1000+

Re: ITopic: Welcome to your local block library!

MathWizz wrote:

I wouldn't support. Why have something messy when it can be clean?

I don't think <[ ] = [ ]>, <[ ] > [ ]>, or <[ ] < [ ]> look messy at all.

Offline

 

#2347 2011-11-14 17:04:47

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

Re: ITopic: Welcome to your local block library!

Hmm... I'm still undecided... They're not needed but then it is a feature that most any scripting language supports as a constant. I use them a lot in Panther. Then again, if they weren't in Panther I would be perfectly content to just type True and False into the = operators. I'll vote that we do remove them...


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

Offline

 

#2348 2011-11-14 17:11:29

Greenatic
Scratcher
Registered: 2009-05-03
Posts: 1000+

Re: ITopic: Welcome to your local block library!

sparks wrote:

Hmm... I'm still undecided... They're not needed but then it is a feature that most any scripting language supports as a constant. I use them a lot in Panther. Then again, if they weren't in Panther I would be perfectly content to just type True and False into the = operators. I'll vote that we do remove them...

Alright then, 66% of librarians support.  How many do you think are required to proceed with the deletion?

Offline

 

#2349 2011-11-14 17:19:41

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

Re: ITopic: Welcome to your local block library!

I still think they should stay. Why pick on the more reasonable of the blocks instead of something like [if <> bounce] that could just as easily be replaced by the following?

Code:

[if <CONDITION>]
  [turn [180] degrees]
[end if]

Scratch is supposed to be easy to use and understand. The <true> understood at a glance while <[0] = [0]> is not.

Last edited by MathWizz (2011-11-14 17:21:36)


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

Offline

 

#2350 2011-11-14 17:25:28

Greenatic
Scratcher
Registered: 2009-05-03
Posts: 1000+

Re: ITopic: Welcome to your local block library!

MathWizz wrote:

Scratch is supposed to be easy to use and understand. The <true> understood at a glance while <[0] = [0]> is not.

Actually, if I were a little kid, if 0 = 0 would make more sense than if true.   hmm

MathWizz wrote:

I still think they should stay. Why pick on the more reasonable of the blocks instead of something like [if <> bounce] that could just as easily be replaced by the following?

Code:

[if <CONDITION>]
  [turn [180] degrees]
[end if]

I actually support the removal of all or most of the blocks listed in this post, which includes [if < > bounce].  I'm just starting with <true> and <false>, since they're the worst offenders.

And are you a librarian?  The page doesn't say so...

Last edited by Greenatic (2011-11-14 17:29:36)

Offline

 

Board footer