Pecola1 wrote:
ProgrammingFreak wrote:
Pecola1 wrote:
sparks wrote:
Non-librarians are welcome to add help with the library by working on new ideas - librarians are just there to keep the library updated
![]()
What we need is an online program that can edit the contents of the Scratch smalltalk browser. The program would be able to give a user a list of blocks with checkbox options as to which blocks they want - then add the code for those blocks to the correct section of that copy of Scratch before providing a download link to it. No idea if that's possible. If a patches system is possible to easily use with normal Scratch that will be very cool, I've wanted to find a way to make Scratch blocks downloadable too for ages!YAY! BTW yall, I have been sick, so I just got a 2-3 hour nap. That felt good, I wonder if i can do my SAT tomorrow? I feel better. [/offTopicness] Let me tell you a problem we will run into and a way too solve it. By making a patch, you cannot simply add to a method, only overwrite it, so for the blockspec, we cannot do. UNLESS we make a dialog which would tell you, "This will over right any block you have made beside ones you download, is that okay?" How do we fix it, we simply make it so each block has its own blockspec, for example the say nothing would be:
sayNothingBlockspec
^( 'looks' ('say nothing' #- #sayNothing) )And we could simply have a beginning patch for you to download which would have at the end
This it will also make all the blockspecs, but they will all be blank, until you download that block.Hope you feel better!
![]()
SAT? What grade are you in?
So it reports a block. Cool!I am in 7th, LOL, in break time I started writing squeak for the new download feature and my friend next to me (who was also done) was like, "What the..." I WROTE ON THE PAPER I'll tell you later... its a programming code called Squeak Smalltalk. Later he thought i had said squeaky talk, and I told him what it really was and...[/offTOPIC]
I thought about what we can do, we could simply make a place named findCustomDropdown: and it would go at the end of uncoloredArgMorphFor:. The method would be like uncolored arg morph for only it would contain only the custom ones, it would on the first download (THE ORIGINAL PATCH) make all the drop-downs and at the end it would have report the default number drop-down. I have some questions, should we make a remove custom block option? Also an export block?
BUMP!
Offline
Pecola1 wrote:
ProgrammingFreak wrote:
Pecola1 wrote:
YAY! BTW yall, I have been sick, so I just got a 2-3 hour nap. That felt good, I wonder if i can do my SAT tomorrow? I feel better. [/offTopicness] Let me tell you a problem we will run into and a way too solve it. By making a patch, you cannot simply add to a method, only overwrite it, so for the blockspec, we cannot do. UNLESS we make a dialog which would tell you, "This will over right any block you have made beside ones you download, is that okay?" How do we fix it, we simply make it so each block has its own blockspec, for example the say nothing would be:
And we could simply have a beginning patch for you to download which would have at the end
This it will also make all the blockspecs, but they will all be blank, until you download that block.Hope you feel better!
![]()
SAT? What grade are you in?
So it reports a block. Cool!I am in 7th, LOL, in break time I started writing squeak for the new download feature and my friend next to me (who was also done) was like, "What the..." I WROTE ON THE PAPER I'll tell you later... its a programming code called Squeak Smalltalk. Later he thought i had said squeaky talk, and I told him what it really was and...[/offTOPIC]
I thought about what we can do, we could simply make a place named findCustomDropdown: and it would go at the end of uncoloredArgMorphFor:. The method would be like uncolored arg morph for only it would contain only the custom ones, it would on the first download (THE ORIGINAL PATCH) make all the drop-downs and at the end it would have report the default number drop-down. I have some questions, should we make a remove custom block option? Also an export block?
BUMP!
Offline
777w wrote:
YourLocalBlockLib wrote:
The downloadable Scratch blocks post.
..........
Step 9: File in the selection by right-clicking (Mac option+click) the selection and clicking "more..." then "file it in"
.....
^Back to Scratch blocksIt appears that this doesn't work...
![]()
I figured it out. You misunderstood; so did I. I changed the wording to be more comfortable.
~~Scimonster
Last edited by YourLocalBlockLib (2011-05-01 01:05:30)
Offline
Oh, I didn't have time to add any blocks right now, sorry.
Offline
You guys never to seem to consider my blocks...
Offline
ProgrammingFreak wrote:
You guys never to seem to consider my blocks...
What blocks have you shared that we have not added? It may be that we missed them! We're not being discriminative, don't worry, we just miss things sometimes!
@pecola1, the new feature for Scratch blocks looks great and the option is there, but I can't see any blocks in the library that can be downloaded using this feature. We should create some working .block files for the library so people can experiment with the feature. Also, for people having trouble adding the code, why not have a download link to a copy of the Scratch 1.4 image that has this feature already installed? Something like
"Click here to download the block library patch. Once it is downloaded, paste it into your Scratch folder (probably in your program files folder) and replace the existing .image file there with this one"
The replacement .image can still be called scratch 1.4.image (I hope) and it would be exactly the same as the normal copy of Scratch, just with the block download menu added!
Offline
sparks wrote:
ProgrammingFreak wrote:
You guys never to seem to consider my blocks...
What blocks have you shared that we have not added? It may be that we missed them! We're not being discriminative, don't worry, we just miss things sometimes!
@pecola1, the new feature for Scratch blocks looks great and the option is there, but I can't see any blocks in the library that can be downloaded using this feature. We should create some working .block files for the library so people can experiment with the feature. Also, for people having trouble adding the code, why not have a download link to a copy of the Scratch 1.4 image that has this feature already installed? Something like
"Click here to download the block library patch. Once it is downloaded, paste it into your Scratch folder (probably in your program files folder) and replace thi cant get the .block workinge existing .image file there with this one"
The replacement .image can still be called scratch 1.4.image (I hope) and it would be exactly the same as the normal copy of Scratch, just with the block download menu added!
I tried making a test .block, but it didn't work at all! I kept getting errors, I was hoping someone else could help.
Last edited by Pecola1 (2011-05-01 17:51:40)
Offline
SSBBM wrote:
Here are somethings that were forgotten.
SSBBM wrote:
What do you think of a page for the librarians and/or the history of the library.
sparks wrote:
Oh yes, I forgot to add the updates archive!
I'm thinking, what are people's thoughts on rather than having a link back to the block home at the bottom of each pallet catagory, we put small images too? Here, I'll mockup:
______________________________
^back to Scratch blocks
^back to contents
█ █ █ █ █ █ █ █We still want these right?
BUMP
Offline
SSBBM wrote:
SSBBM wrote:
Here are somethings that were forgotten.
SSBBM wrote:
What do you think of a page for the librarians and/or the history of the library.
sparks wrote:
Oh yes, I forgot to add the updates archive!
I'm thinking, what are people's thoughts on rather than having a link back to the block home at the bottom of each pallet catagory, we put small images too? Here, I'll mockup:
______________________________
^back to Scratch blocks
^back to contents
█ █ █ █ █ █ █ █We still want these right?
BUMP
I think we do. I do.
Offline
New panther block
box1
number of projects $String$ has uploaded
color can be any
code:
^getUrl: 'http://scratch.mit.edu/api/getnumprojectsbyuser/', t1
Offline
uh, you know that block for panther in sensing called < password for [user] is [password] > ? wouldn't that be able to be used by hackers or something? although I suppose it would be difficult to use that to hack into people's accounts, versus confirming things, but also:
I remember that in the terms of use of the source code you're not supposed to interact with the scratch web site much with the mods. although I think it said only don't share projects.
Offline
DarthPickley wrote:
uh, you know that block for panther in sensing called < password for [user] is [password] > ? wouldn't that be able to be used by hackers or something? although I suppose it would be difficult to use that to hack into people's accounts, versus confirming things, but also:
I remember that in the terms of use of the source code you're not supposed to interact with the scratch web site much with the mods. although I think it said only don't share projects.
That might be a problem...
Yeah, I think it's just not uploading.
Offline
scimonster wrote:
Hardmath123 wrote:
ProgrammingFreak wrote:
New Block!
Goto Url
By ProgrammingFreak
Code:Code:
gotourl: t1 | url | url _ 'http://', t1. Cursor wait showWhile: [ScratchPlugin primOpenURL: url]BlockSpec:
Code:
('goto url %s' #- #gotourl:)Won't work if you input http://{address}, which most people do (because they copy the url from the address bar). I'll optimize it:
Code:
gotourl: t1 httpIncluded: t2 | url | url _ t1. t2 = true ifFalse: [url _ 'http://' , t1]. Cursor wait showWhile: [ScratchPlugin primOpenURL: url]Code:
('Go to url %s . Http prefix included? %b' #- #gotourl:httpIncluded: 'scratch.mit.edu')•••••••••••••••••••••••••••••••••••••••
Hardmath123 wrote:
Blockspec:
Code:
('Set the list blocks color to %c' #- #setListBlockColorSelf:)Code:
Code:
setListBlockColorSelf: t1 ListBlockColor _ t1Anybody?
•••••••••••••••••••••••••••••••••••••••Code:
openForum: url Cursor wait showWhile: [ScratchPlugin primOpenURL: 'http://scratch.mit.edu/forums/viewtopic.php?id=' , url asString]Code:
('Open the %n th forum page' #- #openForum: 58790)Default value is the block library.
•••••••••••••••••••••••••••••••••••••Code:
('Post on the %nth forum topic' #- #postForum: 58790)Code:
postForum: t1 Cursor wait showWhile: [ScratchPlugin primOpenURL: 'http://scratch.mit.edu/forums/post.php?tid=' , t1 asString]I really like those, Hardmath!
![]()
WYB I didn't need you to tell me the default value for the [open the ()th forum page]?I think I've been spending too much time here.
![]()
So... Will you add them?
Offline
DarthPickley wrote:
uh, you know that block for panther in sensing called < password for [user] is [password] > ? wouldn't that be able to be used by hackers or something? although I suppose it would be difficult to use that to hack into people's accounts, versus confirming things, but also:
I remember that in the terms of use of the source code you're not supposed to interact with the scratch web site much with the mods. although I think it said only don't share projects.
A valid point. I can see that it might be a problem but it was the Scratch team who released the URL this block uses. The Scratch site does not have a cut-out limit if too many incorrect passwords are given so guessing the password in Scratch is as time-consuming and fruitless as doing it on the Site. An MD5 dictionary onslaught will be just as easy to do with Panther as some other program such as C++ and probably even python.
My main worry is that someone might release a project containing this block and then use Panther's URL connection blocks to send the user name and password that someone enters in the project to a MySQL database of their own, this is unlikely to happen though as I thoroughly check all Panther projects before I upload them. I will report my post to the Scratch team and see what they think. If they want me to remove it from the library I am more than happy to do so
Offline
sparks wrote:
DarthPickley wrote:
uh, you know that block for panther in sensing called < password for [user] is [password] > ? wouldn't that be able to be used by hackers or something? although I suppose it would be difficult to use that to hack into people's accounts, versus confirming things, but also:
I remember that in the terms of use of the source code you're not supposed to interact with the scratch web site much with the mods. although I think it said only don't share projects.A valid point. I can see that it might be a problem but it was the Scratch team who released the URL this block uses. The Scratch site does not have a cut-out limit if too many incorrect passwords are given so guessing the password in Scratch is as time-consuming and fruitless as doing it on the Site. An MD5 dictionary onslaught will be just as easy to do with Panther as some other program such as C++ and probably even python.
My main worry is that someone might release a project containing this block and then use Panther's URL connection blocks to send the user name and password that someone enters in the project to a MySQL database of their own, this is unlikely to happen though as I thoroughly check all Panther projects before I upload them. I will report my post to the Scratch team and see what they think. If they want me to remove it from the library I am more than happy to do so![]()
I completely agree. I could conjure up something to test each string made from all standard ASCII characters in about 30 minutes. It'd take over an hour to check them all, though. I'm not going to do it, but I could, and I'm sure quite a few others could, too.
Offline
Pecola1 wrote:
New panther block
box1
number of projects $String$ has uploaded
color can be any
code:Code:
^getUrl: 'http://scratch.mit.edu/api/getnumprojectsbyuser/', t1
Thanks Pecola1, the URL is useful, but getURL isn't a smalltalk command. I've fixed your block like so:
^ self readLine: 2 FromUrl: 'http://scratch.mit.edu/api/getnumprojectsbyuser/', t1
and added it to the library
Offline
Hardmath123 wrote:
scimonster wrote:
Hardmath123 wrote:
ProgrammingFreak wrote:
New Block!
Goto Url
By ProgrammingFreak
Code:Code:
gotourl: t1 | url | url _ 'http://', t1. Cursor wait showWhile: [ScratchPlugin primOpenURL: url]BlockSpec:
Code:
('goto url %s' #- #gotourl:)Won't work if you input http://{address}, which most people do (because they copy the url from the address bar). I'll optimize it:
Code:
gotourl: t1 httpIncluded: t2 | url | url _ t1. t2 = true ifFalse: [url _ 'http://' , t1]. Cursor wait showWhile: [ScratchPlugin primOpenURL: url]Code:
('Go to url %s . Http prefix included? %b' #- #gotourl:httpIncluded: 'scratch.mit.edu')•••••••••••••••••••••••••••••••••••••••
Anybody?
•••••••••••••••••••••••••••••••••••••••Code:
openForum: url Cursor wait showWhile: [ScratchPlugin primOpenURL: 'http://scratch.mit.edu/forums/viewtopic.php?id=' , url asString]Code:
('Open the %n th forum page' #- #openForum: 58790)Default value is the block library.
•••••••••••••••••••••••••••••••••••••Code:
('Post on the %nth forum topic' #- #postForum: 58790)Code:
postForum: t1 Cursor wait showWhile: [ScratchPlugin primOpenURL: 'http://scratch.mit.edu/forums/post.php?tid=' , t1 asString]I really like those, Hardmath!
![]()
WYB I didn't need you to tell me the default value for the [open the ()th forum page]?I think I've been spending too much time here.
![]()
So... Will you add them?
![]()
When I have a little while.
Offline
. 
Panther blocks added: [1]
by Pecola1, edited by Sparks
Other updates[2]
New Panther block contributor: Pecola1
Added new links to categories
Update carried out by block librarians: Sparks and SSBBM
________________________________________________________________________________
^home
^updates archive
Last edited by YourLocalBlockLib (2011-05-02 12:51:35)
Offline
YourLocalBlockLib wrote:
http://dl.dropbox.com/u/6273449/BlockLibraryTitle.png
^Back to Scratch blocks
How to download a Scratch blockCode:
'From MIT Squeak 0.9.4 (June 1, 2003) [No updates present.] on 18 June 2010 at 5:06:17 pm'! !ScratchFileChooserDialog methodsFor: 'initialization'! createBlockFileChooserFor: t1 scratchFrame _ nil. readingScratchFile _ true. list _ ScratchFilePicker new extensions: #(#block ). self removeAllMorphs. bottomSpacer delete. bottomSpacer _ nil. mainColumn addMorphBack: list. self title: 'Import Block'. list scratchInfoClient: nil. mainColumn addMorphBack: (Morph new extent: 5 @ 9; color: Color transparent); addMorphBack: newTitleBin. fileInfoColumn addMorphBack: buttonRow. self addMorphBack: shortcutColumn; addMorphBack: mainColumn; addMorphBack: fileInfoColumn! ! !ScratchFrameMorph methodsFor: 'menu/button actions'! addBlock | t1 t2 t3 t4 | t1 _ ScratchFileChooserDialog new createBlockFileChooserFor: self; type: #block. t2 _ t1 getUserResponse. t2 = #cancelled ifTrue: [^ self]. t3 _ (FileDirectory forFileName: t2) oldFileNamed: t2. t4 _ t3 contentsOfEntireFile. (ReadWriteStream on: t4 from: 1 to: t4 size) fileIn! ! !ScratchFrameMorph methodsFor: 'menu/button actions'! fileMenu: t1 | t2 | t2 _ CustomMenu new. t2 add: 'New' action: #newScratchProject. t2 add: 'Open' action: #openScratchProject. t2 add: 'Save' action: #saveScratchProjectNoDialog. t2 add: 'Save As' action: #saveScratchProject. t2 addLine. t2 add: 'Import Project' action: #importScratchProject. t2 add: 'Export Sprite' action: #exportSprite. t2 addLine. t2 add: 'Import Block' action: #addBlock. t2 addLine. t2 add: 'Project Notes' action: #editNotes. Sensor shiftPressed ifTrue: [t2 addLine. t2 add: 'Write Project Summary' action: #writeSummaryFile. t2 add: 'Write Multiple Project Summaries' action: #writeMultipleSummaries]. t2 addLine. t2 add: 'Quit' action: #quitScratch. t2 localize. #(2 4 5 6 7 8 ) do: [:t3 | t2 labels at: t3 put: ((t2 labels at: t3) copyFrom: 1 to: (t2 labels at: t3) size - 1) , ScratchTranslator ellipsesSuffix]. t2 invokeOn: self at: t1 bottomLeft + (0 @ 10)! !http://dl.dropbox.com/u/6273449/BlockLibDiv2.png
^Back to Scratch blocks
I looked at this code to try and work out what the contents of the .block file has to be. I was hoping it would be similar to the block files I have created for Panther, but I can't see anything in that code that tells me what the file needs to contain...
Offline
Yes.
~~sci
Offline
scimonster wrote:
Yes.
~~sci![]()
Great, I forgot other. Adding it now...
Offline
Scratch now? Panther?
Offline