I really think we should know a way to use code editing to make new types of blocks. To open the squeak code, do as instructed below.
1. Open scratch.
2. Shift click the loop in the R in scratch, click turn fill screen off.
3. Click the white space that appears below.
4. Choose open, then browser.
5. Find the materials.
__________________
I just need info on how to do the kinds of blocks. I already know how to do blockspecs and block codes, I need info on how to get the types.
______________________
Confused? Don't even dare to view up this page, it will really tangle you up.
___________________
Blocks wanted:
A C block that fits into strings. (currently being worked on)
An area that command blocks can go into.
A block that can connect to a hat block BELOW.
A hat block attached to a C block.
A place where only reporter blocks fit.
Lots more!
Example:
Image from BYOB3 wiki page.
____________________
Important messages received:
1. Q. Could you give us examples of ways you would use them, and describe a little more about what they are suppose to do? A.
2. A pathway: Scratch-Objects>scriptableScratchMorph>instance>blocks>blockFromSpec:
3. I've came up with an idea: Lets find someone who knows how to use squeak and has BYOB3!
4. HOW TO HACK BYOB:
Step 1. Right Click A Block (It Cannot Be A Custom Made Block.) Step 2. Drag Some Of The Block Things Away Then Put Them Back EXACTLY How They Used To Be. Step 3. Click The Little Save Button That Appeared. Step 4. When It Asks For Your Initials, Type: Preferences enableProgrammerFacilities Step 5. Highlight The Text And Press Alt+D Step 6. Exit Out Of All Of That. Step 7. Alt+Click The Scripting Area Step 8. Press The Goldenish Circle Step 9. Click Anywhere In The White Area That Appears. Step 10. Press Open Then Press Browser
5. EXTREMELY IMPORTANT MESSAGE: fit C blocks inside strings! Here you go!
6. A pathway to find where the block is drawn: Scratch blocks > command block morph > drawing.
7. Here is an easier way to get into squeak's source, written by pecola1:
Just edit elements, click class, then take a red report block (the squeak one) place a blue text insert block over into the report block and type in
self
click save. Type in your initials. A syntax error should come up. Right click on the 'ScratchSpriteMorph class as yet classified Message' (the ScratchSpriteMorph may be ScriptableScratchMorph or ScratchStageMorph depending on what block you edited and where.) select 'browse full' and there you have it!
Last edited by zorket (2011-04-18 15:14:53)
Offline
Would you describe what you mean and what their uses could be?
Offline
Magnie wrote:
Would you describe what you mean and what their uses could be?
I tried. Users can find it interesting in many ways.
This is my 300'th post.
Last edited by zorket (2010-10-20 19:03:05)
Offline
Well to start off, creating new blocks is not "using cheat codes." It's not even hacking. It's just editing the code.
Secondly, I really don't understand what you mean by "how to get the types". Are you looking for methods and code for specific blocks? If so, check out The Scratch Block Library thread in Advanced Topics.
Offline
Harakou wrote:
Well to start off, creating new blocks is not "using cheat codes." It's not even hacking. It's just editing the code.
![]()
Secondly, I really don't understand what you mean by "how to get the types". Are you looking for methods and code for specific blocks? If so, check out The Scratch Block Library thread in Advanced Topics.
I don't know how to help you confused guys. I'll help a little by posting a picture from a WIKI page.
Offline
Zorket: Could you give us examples of ways you would use them, and describe a little more about what they are suppose to do?
Offline
Magnie wrote:
Zorket: Could you give us examples of ways you would use them, and describe a little more about what they are suppose to do?
I'm gonna put this message in important messages.
Answer: The new type of C block is half C, half reporter. In the C, you put blocks, then clicking it reports all the block names in the script. One block down.
The inserter that oval shaped can only fit reporter blocks, when nothing can be typed in.
That's all I can answer. If you have more questions, post!
Offline
zorket wrote:
Magnie wrote:
Zorket: Could you give us examples of ways you would use them, and describe a little more about what they are suppose to do?
I'm gonna put this message in important messages.
Answer: The new type of C block is half C, half reporter. In the C, you put blocks, then clicking it reports all the block names in the script. One block down.
The inserter that oval shaped can only fit reporter blocks, when nothing can be typed in.
That's all I can answer. If you have more questions, post!
Listen, I get that, but... Do you want to know how to make them in Scratch?
Offline
This belongs in advanced topics, not in all about scratch.
I think there is a thread that has all sorts of blocks in advanced topics, might wanna go check there.
Offline
This really belongs in suggestions. XplodingEggs.
Offline
If you're asking where the block types are coded, I can answer you with a brief path:
ScriptableScratchMorph -> blocks -> blockFromSpec:
For the actual 'block making' scripts, you find those in the various classes of
Scratch-UI-Blocks!
If this is not what you're asking please expand.
(PS. sorry for the really late reply but my computer has defunct and I'm using my other (not that awesome) computer now)
Offline
LS97 wrote:
If you're asking where the block types are coded, I can answer you with a brief path:
ScriptableScratchMorph -> blocks -> blockFromSpec:
For the actual 'block making' scripts, you find those in the various classes of
Scratch-UI-Blocks!
If this is not what you're asking please expand.
(PS. sorry for the really late reply but my computer has defunct and I'm using my other (not that awesome) computer now)
Don't worry about posting late, I was at school anyway. I just got home and got on.
Anyway, I'm gonna help you understand what I mean. Lots of helping materials below!
The C blockspec:
('the script' #isc #theScript)
isc makes the block so it fits into strings
And the 2nd block, the new area where only reporter blocks fit (not strings)
('the %rbo block' #r #the:block)
%rbo makes a space where only reporter blocks fit.
The first blockspec:
('run %cbo' #- #run:)
%cbo produces where only command blocks fit.
These are some of the things I want.
Alright, I need to know what code to use and where, please. (I guess you told me where)
Help?
Last edited by zorket (2010-10-22 16:28:41)
Offline
I can assure you, it's not easy to make new types of blocks. BYOB did it alright though, so if you want it quick just mod off BYOB to get the blocks. But, to actually create a block, the process becomes more complicated.
Offline
zorket wrote:
Were gonna need some experts on squeak, like nXIII.
not necessarily. i can do it, but it's difficult to explain to you unless i give you my changes file
which i prefer not to do. so, you have two options:
1. If you just want those blocks to put in your mod and that's it, ask nXIII for his changes file (if he feels like making one).
2. If you want to learn something from squeak and have fun, explore the different classes and methods i explained above and make your own code by taking bits and pieces from other existing codes
Offline
The really major things you change are the #drawOn: and #fixBlockLayout messages. You can look at the various block type classes for inspiration, but feel free to ask me if you can't find anything!
Last edited by nXIII (2010-10-23 09:57:27)
Offline
LS97, I'm not making a mod, I just want the codes to put in. You probably aren't gonna help, unless I work like a big brain.
nXIII, I mostly want the C block that fits into strings. Can you help me with the codes?
Maby Bhavery or jens can help. They builded BYOB!
Last edited by zorket (2010-10-23 10:07:17)
Offline
Harakou wrote:
zorket wrote:
Magnie wrote:
Zorket: Could you give us examples of ways you would use them, and describe a little more about what they are suppose to do?
I'm gonna put this message in important messages.
Answer: The new type of C block is half C, half reporter. In the C, you put blocks, then clicking it reports all the block names in the script. One block down.
The inserter that oval shaped can only fit reporter blocks, when nothing can be typed in.
That's all I can answer. If you have more questions, post!Listen, I get that, but... Do you want to know how to make them in Scratch?
Yep, in scratch!
Offline
zorket wrote:
nXIII, I mostly want the C block that fits into strings. Can you help me with the codes?
Maby Bhavery or jens can help. They builded BYOB!
Jens wrote all/most of BYOB.
And trust me, closures aren't easy. I've been working on them for a while.
Offline
nXIII wrote:
zorket wrote:
nXIII, I mostly want the C block that fits into strings. Can you help me with the codes?
Maby Bhavery or jens can help. They builded BYOB!Jens wrote all/most of BYOB.
And trust me, closures aren't easy. I've been working on them for a while.
What are those?
Offline
Base your mod on BYOB.
Offline
Billybob-Mario wrote:
Base your mod on BYOB.
I could try, but I'm NOT (NOT) (NOT) gonna make a mod, nethier am I gonna download a mod maker.
I'm not even gonna download BYOB!
bbbeb wrote:
Billybob-Mario wrote:
Base your mod on BYOB.
That's a failure.
Correct bbbeb!
Last edited by zorket (2010-10-26 20:18:10)
Offline
zorket wrote:
Billybob-Mario wrote:
Base your mod on BYOB.
I could try, but I'm NOT (NOT) (NOT) gonna make a mod, nethier am I gonna download a mod maker.
a... mod... maker??
never heard of those. what are they
Offline