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

#26 2011-12-31 12:36:09

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

Re: Editing Scratch Projects in Notepad

ZeroLuck wrote:

this topic is pointless.
You aren't able to edit a Scratch binary in Notepad.
lol

Yup, but you can do it in some text editors (the ones that preserve exact byte values. I think notepad++ can do that).

It's useful for quick find and replace, which Scratch doesn't do!

Offline

 

#27 2011-12-31 12:48:46

nXIII
Community Moderator
Registered: 2009-04-21
Posts: 1000+

Re: Editing Scratch Projects in Notepad

ZeroLuck wrote:

this topic is pointless.
You aren't able to edit a Scratch binary in Notepad.
lol

If you have a lot of time and a good knowledge of code points, it's probably possible. The problem with this topic's result is it reaches EOF before it runs out of fields to read.


nXIII

Offline

 

#28 2011-12-31 13:19:22

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

Re: Editing Scratch Projects in Notepad

I was able to change a costumes name in Notepad++. Just make sure the name you change it to is the same length as the original name.


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

Offline

 

#29 2011-12-31 13:21:16

nXIII
Community Moderator
Registered: 2009-04-21
Posts: 1000+

Re: Editing Scratch Projects in Notepad

MathWizz wrote:

I was able to change a costumes name in Notepad++. Just make sure the name you change it to is the same length as the original name.

or change the previous byte to the correct length (unless you have a string longer than 255 characters, in which case you'll need to change the two previous bytes)

Last edited by nXIII (2011-12-31 13:21:55)


nXIII

Offline

 

#30 2011-12-31 13:24:27

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

Re: Editing Scratch Projects in Notepad

nXIII wrote:

MathWizz wrote:

I was able to change a costumes name in Notepad++. Just make sure the name you change it to is the same length as the original name.

or change the previous byte to the correct length (unless you have a string longer than 255 characters, in which case you'll need to change the two previous bytes)

That's kinda hard to do in NP++.  tongue


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

Offline

 

#31 2011-12-31 13:25:34

fg123
Scratcher
Registered: 2008-11-13
Posts: 1000+

Re: Editing Scratch Projects in Notepad

Lol, I was getting all excited reading the post, then:

Looks like you Can't.

Okay.  sad


Hai.

Offline

 

#32 2011-12-31 13:29:35

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

Re: Editing Scratch Projects in Notepad

fg123 wrote:

Lol, I was getting all excited reading the post, then:

Looks like you Can't.

Okay.  sad

^^^ Look up ^^^


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

Offline

 

#33 2011-12-31 14:15:31

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

Re: Editing Scratch Projects in Notepad

Just downloaded NP++, and it didn't work for me.  hmm
Anyone willing to debug?

Offline

 

#34 2011-12-31 15:34:35

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

Re: Editing Scratch Projects in Notepad

scimonster wrote:

Just downloaded NP++, and it didn't work for me.  hmm
Anyone willing to debug?

I never actually tried myself..  tongue
I just remember that NP++ keeps the original bytes (or at least did when I had it) so you're able to open any file and re-save it losslessly.
It worked for the guys above though, so I don't see why it shouldn't for you!

Offline

 

#35 2011-12-31 17:56:12

DigiTechs
Scratcher
Registered: 2011-04-30
Posts: 500+

Re: Editing Scratch Projects in Notepad

you can also use SciTE, which is designed for things like this - really, a .db file (the files scratch uses) is just a big database, that is why it got the name db!


I'm back.
Maybe.

Offline

 

#36 2011-12-31 18:55:31

ZeroLuck
Scratcher
Registered: 2010-02-23
Posts: 500+

Re: Editing Scratch Projects in Notepad

DigiTechs wrote:

you can also use SciTE, which is designed for things like this - really, a .db file (the files scratch uses) is just a big database, that is why it got the name db!

You mean the "scratchthums.db"?
I thought they are talking about editing Scratch projects in Notepad...
not about the database files.  hmm


http://3.bp.blogspot.com/-oL2Atzp0Byw/T465vIQ36dI/AAAAAAAAADo/1vqL4PvhkM0/s1600/scratchdachwiki.png

Offline

 

#37 2012-01-02 12:13:00

rdococ
Scratcher
Registered: 2009-10-11
Posts: 1000+

Re: Editing Scratch Projects in Notepad

PowerBook wrote:

[lots of information]

  1) Open a new file in Notepad, preferably in a new window, not by pressing "New" in the file menu.
  2) Copy and paste the entire contents of the flag.sb file into the new window.
  3) Remove the bottom line of text:

Code:

EventHatMorph       Scratch-StartClicked


  4) Save, as test.sb.
  Make Sure It Is Called Test.sb, Not Test.txt!
  5) Open in Scratch. If you did everything like me, you will get this notice:

Could not read project; file may be damaged:
(Attempt to set the position of a PositionableStream out of bounds)


It seems it can't be edited on the Mac after all.  sad

Epic failure.

Offline

 

#38 2012-02-03 21:14:17

christian2000
Scratcher
Registered: 2010-11-01
Posts: 100+

Re: Editing Scratch Projects in Notepad

i tried this once with a rhy project. i think notepad crashed


blerp......
http://obscureinternet.com/wp-content/uploads/Fail-at-Life-Funny-Cards.png

Offline

 

#39 2012-02-04 12:01:47

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

Re: Editing Scratch Projects in Notepad

christian2000 wrote:

i tried this once with a rhy project. i think notepad crashed

lol


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

Offline

 

#40 2012-02-04 12:20:41

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

Re: Editing Scratch Projects in Notepad

cocolover76 wrote:

christian2000 wrote:

i tried this once with a rhy project. i think notepad crashed

lol

RHY was too epic for a Microsoft product to sustain.


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

Offline

 

#41 2012-02-04 16:13:28

DigiTechs
Scratcher
Registered: 2011-04-30
Posts: 500+

Re: Editing Scratch Projects in Notepad

ZeroLuck wrote:

DigiTechs wrote:

you can also use SciTE, which is designed for things like this - really, a .db file (the files scratch uses) is just a big database, that is why it got the name db!

You mean the "scratchthums.db"?
I thought they are talking about editing Scratch projects in Notepad...
not about the database files.  hmm

I meant - .sb, not .db - fail  tongue


I'm back.
Maybe.

Offline

 

#42 2012-10-31 23:49:50

wiz99903
New Scratcher
Registered: 2012-10-23
Posts: 53

Re: Editing Scratch Projects in Notepad

I looked at what I got when I tried opening a blank Scratch binary (without the Scratch cat). Here's what I got:


ScratchV02  RObjSStch      c  c  c  c  c  c  c  c      c 
c  c  c 
c  c         history       12012-10-31 20:45:40    save    blank    wiz99903    wiz99903
       platform       Win32       language       en      
os-version       NT       scratch-version       1.4 of 30-Jun-09           thumbnail#   x c  c         author   wiz99903    âXéaÿ   c  c       ?ÿÿÿObjSStch   }c  c  c    c  c  c  c  c      ?ð          c 
 d <c  c  !    àh    ?ÿÿÿ       Stage           c      c 
¢c  c  c              ¤c  c   d 2       background1"àh c    ð ´       popmc    € c  +  €     õÿ  Ta        Õ½
rïS#<$› â«sñUÚ_Ä`³©i¨’±åÅGáAó&íGÑaJo}p#a
DÎêó*ɧj‘ý%˜îµ9Ýè â:`Dvpyµh¢EØgäJµl’zÞ†kŸqÈŽü!0â]}yßäq7M©¶ç©¸O–Œ‰‘i®OÙõ \< _PoïiNV$
òqÅY£g“¶™x²øÚh    £6ŽWkf)_¢F¼õòÈÊ­õ¢Î«Ä2êñÀ9«Q(VñI4+NÛ,º¾¨ì©¼ÑÝŒ¼.<K€YR'9]¬êÅq­­§)³ºÐö°¥?zQÈQÊ?k}ùçÖÓ¾¶¾UÕ¬õ¼*3‚Aõ@„/, òW՟ó¿õËtãœz z6‰?†8Ò$:Ãç’ο†ÀÏéQk%~: A8µ#–Sè/ÏVÂ*ÂêÑZêI"”5×<Ð5ì#J    ZîGØËwË
Öfêo±’*30x+ª<ôódá¿×¸Öö߬ïÍ)\#¨H«¯óRæpߺàÛé3öÌ$ÛòJ„É|òäç5á
á†èzôg¡,_Œ^ =þtòçêÊç–é„ïàøùÔ J’Ù    7ûyöô–õÝù×ÿŽ—
ŠUþa

Offline

 

#43 2012-10-31 23:53:00

wiz99903
New Scratcher
Registered: 2012-10-23
Posts: 53

Re: Editing Scratch Projects in Notepad

So don't try getting rid of this, or it won't be a proper Scratch file.

Offline

 

#44 2012-11-01 12:53:59

DigiTechs
Scratcher
Registered: 2011-04-30
Posts: 500+

Re: Editing Scratch Projects in Notepad

wiz99903 wrote:

So don't try getting rid of this, or it won't be a proper Scratch file.

I would like to point out, that that would not be exactly the same for everyone, so all I would do would be to change somthing I know, like if I named the scratch cat "awesomeness", I would look for the string "awesomeness" and change that.


I'm back.
Maybe.

Offline

 

#45 2012-11-03 20:41:25

scratchisthebest
Scratcher
Registered: 2009-02-08
Posts: 500+

Re: Editing Scratch Projects in Notepad

Maybe the length of the file is encoded in the file format, and removing things causes the actual file to be shorter. Try replacing the green flag code with an equal or greater amount of spaces.


bye 1.4, we all loved you. but we all outgrew the site. 2.0 is a welcome change.
http://scratch.mit.edu/img/Pico3-med.pnghttp://scratch.mit.edu/img/Pico3-med.pnghttp://scratch.mit.edu/img/Pico3-med.pnghttp://scratch.mit.edu/img/Pico3-med.pnghttp://scratch.mit.edu/img/Pico3-med.png

Offline

 

#46 2012-11-07 10:41:37

iTweak0r
Scratcher
Registered: 2011-07-30
Posts: 100+

Re: Editing Scratch Projects in Notepad

LS97 wrote:

scimonster wrote:

LS97 wrote:

It works for the opening part, but saving doesn't.
This is because notepad is a text editor and saves whatever file in an ASCII format, regardless of the bytes in it. Some bytes are then obviously lost. I think Visual Studio should do the trick  wink


Really?
I'll have to get this Visual Studio.

If you're willing to pay 600 pounds, go ahead.
Or you can register via Dreamspark, like I did. You get heaps of free stuff!

Uh VisualStudio is free.


Make it in Scratch! because it's cooler when it's made in scratch
http://i.imgur.com/D4iqPHR.png

Offline

 

Board footer