Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

.sb loading support #37

Open
adroitwhiz opened this issue Feb 29, 2020 · 6 comments
Open

.sb loading support #37

adroitwhiz opened this issue Feb 29, 2020 · 6 comments
Assignees
Labels
blocked This is blocked on other changes or resolutions compatibility Mismatch or currently unsupported language behavior fmt: SB Pertains to SB format (Scratch 1.4 and pre-1.4)

Comments

@adroitwhiz
Copy link
Collaborator

adroitwhiz commented Feb 29, 2020

The original Scratch 1.x file format (.sb) would be good to implement.

The following sources might be useful for figuring out how it works:

Scratch 1.x uses mostly the same block opcodes as 2.0, so the same opcode mappings could potentially be used for both formats. As such, this is kinda blocked on a .sb2 implementation. the library rework in #100.

@adroitwhiz adroitwhiz self-assigned this Feb 29, 2020
@adroitwhiz adroitwhiz added blocked This is blocked on other changes or resolutions enhancement labels Mar 4, 2020
@easrng
Copy link

easrng commented Apr 20, 2020

Couldn't you just use https://github.com/LLK/scratch-sb1-converter and load the sb2, once sb2 loading is done?

@BoomerScratch
Copy link

scratch-sb1-converter-bundle.zip
We can use the JS file I have above. Then you can use ScratchSB1Converter. If you don't know how to use it, here is an example:

fetch("https://projects.scratch.mit.edu/1000").then(res => res.arrayBuffer()).then(data => new ScratchSB1Converter.SB1File(data)).then(data => {
  console.log(data.json); // This logs a Scratch 1 project as a Scratch 2 JSON object in the console.
  console.log(data.zip); // This logs all bytes of the Scratch 1 project's assets in the console (but not the JSON).
});

@easrng
Copy link

easrng commented Jul 13, 2020 via email

@towerofnix towerofnix added compatibility Mismatch or currently unsupported language behavior and removed enhancement labels Mar 10, 2023
@towerofnix
Copy link
Member

@adroitwhiz, is this something you're interested in exploring in the near future or would you like to clear the assignment and let anyone (maybe yourself) come back to it later?

@adroitwhiz
Copy link
Collaborator Author

I'm interested on working this after the library is recoded to fix #100. I was blocked in the past on a resolution to #53, but I think we should be good once #100 is fixed.

@towerofnix
Copy link
Member

Sounds good, that makes sense!

@towerofnix towerofnix added the fmt: SB Pertains to SB format (Scratch 1.4 and pre-1.4) label Mar 11, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
blocked This is blocked on other changes or resolutions compatibility Mismatch or currently unsupported language behavior fmt: SB Pertains to SB format (Scratch 1.4 and pre-1.4)
Projects
None yet
Development

No branches or pull requests

4 participants