Discuss Scratch

EngineerRunner
Scratcher
1000+ posts

Leopard: Convert Scratch projects to JavaScript AUTOMATICALLY!

Hey, I tried to use leopard (on this project https://scratch.mit.edu/projects/809729901/), but it just threw an error.


There was an error converting your project.

Cannot read properties of undefined (reading ‘0’)


How can I fix this?

social experiment: comment here to not get curator

simpsons and futurama fan

RickRoIler (the first l is a capital i) on PSN, NotXboxGamer765 on xbox (and by that i mean xbox 360), EngineerRunner on Minecraft (find me on hypixel)
also im on the orange cat social media as EngineerRunner

join the worst guild on hypixel with this command!!1/!/!?1/!/
/guild join los gamers

if any of my suggestions ever get accepted, i will have my profile picture set to Just Stamp The Ticket Man for 3 months

give internets pls

an australian cumquat ate my snag and onions

“maintainer” of Pyratch, a very simple text-focused frontend for Scratch
oh god am I becoming an ATer

when I am deleted ::hat control
ask (join (join [what the hell does ] (when I am deleted ::hat control)) [ do?]) and wait
create clone of [Stage v]
delete this project ::control
stop [eh, a few] sounds ::sound
casually taking over the forums:

this is what happens when school goes back in the US, scratch has like no activity













































































when I am deleted ::hat control

create clone of [Stage v]
delete this project ::control
stop [eh, a few] sounds ::sound
WojtekGame
Scratcher
1000+ posts

Leopard: Convert Scratch projects to JavaScript AUTOMATICALLY!

kittyguy14 wrote:

I keep getting this error when using project url:
“Cannot read properties of undefined (reading ‘0’)”
and uploading the .sb3 takes literally forever, I've left my laptop on for 2 hours in hopes of it eventually loading

It makes me unable to use Leopard at all
anybody know the fix?
Unsure, PullJosh maybe knows the problem before.


forgot to update sig, i own minecraft months ago lol
JS: code-gui | scratch-player | Roost.js | Pandoa | TOP: Roost.js || C++: Gamine | Gamiinuu | TOP: Gamine
Else: Emoji Painter | Forum Shopping Mall | TOP: Emoji Painter || Profile:Scratch | GitHub
Orgs: Chroast | Twerkish | Komond OS | JS Inventions | TOP: JS Inventions || Ocular Naming: 0 | 1 | 2 | 3
Games: Mom Hid My Game! | Creeper Adventuring
else might be outdated or removed by the ST.
medians
Scratcher
1000+ posts

Leopard: Convert Scratch projects to JavaScript AUTOMATICALLY!

WojtekGame wrote:

Engineerlife_ofline wrote:

Umm I don't know why but my project https://scratch.mit.edu/projects/639672856/editor/ keeps failing saying I am using an unusable extension but I am using none with it help!
Pen is unusable.
They just said they have no extensions.. and I hope this is not linked to those annoying saving and uploading issues.

:D: 2.0 is 11 years old https://scratch.mit.edu/projects/1018259409/
Medians bamboozled by 3.0 (version 3.0): https://scratch.mit.edu/projects/979822351/
hi875230163394: You're similar to valve in that you both hate a certain number…
Scratch 0.x, 1.x, 2.x, 3.x and LogoBlocks Archives
Bamboozlement: https://scratch.mit.edu/studios/33739789
Years on internet: 15 (soon 16)
medians: Oh god not this utc - 12 thing again..
Fun_Cupcake_i81: What, were you expecting not to see the utc - 12 thing again? THE UTC - 12 THIGN ALWAYS RETURNS. ALWAYS.
medians: I knew it would happen. I was the one who started it last year.
Fun_Cupcake_i81: Well then if you didn't want it back maybe you need to time travel to last year and fix that

Oh wait if you could time travel I think we all know exactly when you would go-
user1: That picture is from 2.0. Now he’s at my house and is my pet.
user2: But this is medians we're talking about, so “from 2.0” can mean the same thing as “from five seconds ago”.

Detect Scratch version here
My other accounts: @selfexplanatory @modesties @chaircard @fireflyhero @dividendyield @colloids @radians @skeuamorphism @dihectogon @anglebisector @aau- @EditBlockColors @AdamantOrb @MoongeistBeam @festively @Ampharos_ @straightforwardness
i trolled redcat LOL





if you see this
{what method did you use::control hat
answer on profile ::motion
} ::operators
;
1python11
Scratcher
1 post

Leopard: Convert Scratch projects to JavaScript AUTOMATICALLY!

How do you find the url for the project?
WojtekGame
Scratcher
1000+ posts

Leopard: Convert Scratch projects to JavaScript AUTOMATICALLY!

1python11 wrote:

How do you find the url for the project?
projects.scratch.mit.edu is a domain where the projects are stored

Here is what PullJosh used to get projects and place to codesandbox.io : https://github.com/PullJosh/leopard-website/blob/bfd3d6b767d3c72dca8cad3a3dc32ec2a4d18ccd/pages/api/%5BprojectId%5D/codesandbox.ts#L14-L28


forgot to update sig, i own minecraft months ago lol
JS: code-gui | scratch-player | Roost.js | Pandoa | TOP: Roost.js || C++: Gamine | Gamiinuu | TOP: Gamine
Else: Emoji Painter | Forum Shopping Mall | TOP: Emoji Painter || Profile:Scratch | GitHub
Orgs: Chroast | Twerkish | Komond OS | JS Inventions | TOP: JS Inventions || Ocular Naming: 0 | 1 | 2 | 3
Games: Mom Hid My Game! | Creeper Adventuring
else might be outdated or removed by the ST.
WojtekGame
Scratcher
1000+ posts

Leopard: Convert Scratch projects to JavaScript AUTOMATICALLY!

PullJosh allowed me to do this similarly for Python!

The module will be named leopardpy

when green flag clicked
move (10) steps
⬇️
from leopardpy import *
# code
greenFlag()
moveSteps(10)


forgot to update sig, i own minecraft months ago lol
JS: code-gui | scratch-player | Roost.js | Pandoa | TOP: Roost.js || C++: Gamine | Gamiinuu | TOP: Gamine
Else: Emoji Painter | Forum Shopping Mall | TOP: Emoji Painter || Profile:Scratch | GitHub
Orgs: Chroast | Twerkish | Komond OS | JS Inventions | TOP: JS Inventions || Ocular Naming: 0 | 1 | 2 | 3
Games: Mom Hid My Game! | Creeper Adventuring
else might be outdated or removed by the ST.
jaki_h723
New to Scratch
1 post

Leopard: Convert Scratch projects to JavaScript AUTOMATICALLY!

https://scratch.mit.edu/projects/810067066/, I'm not sure why its not working but I keep getting the error: Argument sandboxId for data.sandboxId is missing.
medians
Scratcher
1000+ posts

Leopard: Convert Scratch projects to JavaScript AUTOMATICALLY!

jaki_h723 wrote:

https://scratch.mit.edu/projects/810067066/,
Fixed link. It thought the comma was part of the link, so you just put blank quotes before the comma.
And same thing for me.

:D: 2.0 is 11 years old https://scratch.mit.edu/projects/1018259409/
Medians bamboozled by 3.0 (version 3.0): https://scratch.mit.edu/projects/979822351/
hi875230163394: You're similar to valve in that you both hate a certain number…
Scratch 0.x, 1.x, 2.x, 3.x and LogoBlocks Archives
Bamboozlement: https://scratch.mit.edu/studios/33739789
Years on internet: 15 (soon 16)
medians: Oh god not this utc - 12 thing again..
Fun_Cupcake_i81: What, were you expecting not to see the utc - 12 thing again? THE UTC - 12 THIGN ALWAYS RETURNS. ALWAYS.
medians: I knew it would happen. I was the one who started it last year.
Fun_Cupcake_i81: Well then if you didn't want it back maybe you need to time travel to last year and fix that

Oh wait if you could time travel I think we all know exactly when you would go-
user1: That picture is from 2.0. Now he’s at my house and is my pet.
user2: But this is medians we're talking about, so “from 2.0” can mean the same thing as “from five seconds ago”.

Detect Scratch version here
My other accounts: @selfexplanatory @modesties @chaircard @fireflyhero @dividendyield @colloids @radians @skeuamorphism @dihectogon @anglebisector @aau- @EditBlockColors @AdamantOrb @MoongeistBeam @festively @Ampharos_ @straightforwardness
i trolled redcat LOL





if you see this
{what method did you use::control hat
answer on profile ::motion
} ::operators
;
bloctans_4
Scratcher
1000+ posts

Leopard: Convert Scratch projects to JavaScript AUTOMATICALLY!

TheRailwayNoob87 wrote:

(#776)
Hello! Since I‘m a fan of both Scratch and JS, I‘ve decided to try converting my most recent project to JS to add some code more easily. But it didn‘t work for some reason…
The project link: https://scratch.mit.edu/projects/802825070

Error:
Cannot read properties of undefined (reading 'x')
I don‘t understand why this error is occurring in the first place…

1. Can the following be converted with LeopardJS?
([property v] of (value))
If not, then that could be fixed quite quickly! ;-)

2. Or this?
<key (join [key] []) pressed?>

3. I don’t even know which sprite is trying to read the value itself. Could it be a problem regarding clone handling in LeopardJS?

I hope the issue isn‘t too hard to solve!
once again, i remember making my own scratch vm just to have issues with opcodes.

Generation 4: the first time you see this copy and paste it on top of your sig in the scratch forums and increase generation by 1. Social experiment.
WojtekGame
Scratcher
1000+ posts

Leopard: Convert Scratch projects to JavaScript AUTOMATICALLY!

bloctans_4 wrote:

TheRailwayNoob87 wrote:

(#776)
Hello! Since I‘m a fan of both Scratch and JS, I‘ve decided to try converting my most recent project to JS to add some code more easily. But it didn‘t work for some reason…
The project link: https://scratch.mit.edu/projects/802825070

Error:
Cannot read properties of undefined (reading 'x')
I don‘t understand why this error is occurring in the first place…

1. Can the following be converted with LeopardJS?
([property v] of (value))
If not, then that could be fixed quite quickly! ;-)

2. Or this?
<key (join [key] []) pressed?>

3. I don’t even know which sprite is trying to read the value itself. Could it be a problem regarding clone handling in LeopardJS?

I hope the issue isn‘t too hard to solve!
once again, i remember making my own scratch vm just to have issues with opcodes.
cool i guess


forgot to update sig, i own minecraft months ago lol
JS: code-gui | scratch-player | Roost.js | Pandoa | TOP: Roost.js || C++: Gamine | Gamiinuu | TOP: Gamine
Else: Emoji Painter | Forum Shopping Mall | TOP: Emoji Painter || Profile:Scratch | GitHub
Orgs: Chroast | Twerkish | Komond OS | JS Inventions | TOP: JS Inventions || Ocular Naming: 0 | 1 | 2 | 3
Games: Mom Hid My Game! | Creeper Adventuring
else might be outdated or removed by the ST.
Robocamper510
Scratcher
1 post

Leopard: Convert Scratch projects to JavaScript AUTOMATICALLY!

PullJosh wrote:

--Explosion-- wrote:

Cool! I'll try it out!
Let me know if you run into any issues!

@PullJosh Is there an easy way to translate JavaScript into Python? I am a saginificanltly a better coder at Scratch than Python. And I am trying to find a way to Translate Scratch Projects into Python, or vise verse. Scratch->JavaScript->Python. Or even better Scratch->Python->Scratch.
Him_is_bob
Scratcher
69 posts

Leopard: Convert Scratch projects to JavaScript AUTOMATICALLY!

for some reason mine wont work
https://scratch.mit.edu/projects/815348900/editor/

Last edited by Him_is_bob (March 7, 2023 23:49:02)


when green flag clicked
if <cool scratcher :: sensing> then{
tell (username) [In a remaster race Go check out the original https://scratch.mit.edu/projects/644148324/] :: looks


} elif <uncool::sensing>{
tell (username) [Looking at my projects will make you cooler.....] :: looks
} :: control
Im sorry i had a bigger evil kumquat but it got eaten by a good signature :: #FFA500


PullJosh
Scratcher
1000+ posts

Leopard: Convert Scratch projects to JavaScript AUTOMATICALLY!

Great news everyone! Thanks to some very hard work by towerofnix, one of Leopard's longest-running issues is finally fixed.

You should no longer see errors like Cannot read properties of undefined (reading ‘0’) when attempting to convert your projects to JavaScript using Leopard.


In the past, the following people have posted about experiencing this error:

If you are one of these people, your projects should now convert successfully!

Additionally, you should now get far fewer errors involving the differences between strings and numbers in JavaScript. Compatibility should be much better now. Everyone give towerofnix a hand for their amazing contribution!

Last edited by PullJosh (March 10, 2023 01:30:14)

userprojectmaker
Scratcher
1 post

Leopard: Convert Scratch projects to JavaScript AUTOMATICALLY!

hi i don't know why my project isn't working for leo pard js apparent it says “Argument sandboxId for data.sandboxId is missing.” wich is weird

Last edited by userprojectmaker (March 10, 2023 11:01:16)

tt_thoma
Scratcher
100+ posts

Leopard: Convert Scratch projects to JavaScript AUTOMATICALLY!

I put an immensely large project in the converter and it's taking it's time. It's been 10 min and it's still going

​ ​ ​ ​ ​ ​ ​ ​ ​ ​ ​ ​ ​ ​ ​ ​ ​ ​ ​ ​ ​ ​ ​ ​ ​ ​ ​ ​ ​ ​ ​ ​ ​ ​ ​ ​ ​ ​ ​ ​ ​ ​ ​ ​ ​ ​ ​ ​ ​ ​ ​ ​ ​​ ​ ​ ​ ​ ​ ​ ​ ​ ​ ​ ​ ​ ​ ​ ​ ​ ​ ​ ​ ​ ​ ​ ​ ​ ​ ​ ​ ​ ​ ​ ​ ​ ​ ​ ​ ​ ​ ​ ​ ​ ​ ​ ​ ​ Advertisement
Hello scratcher!
Would you like to take a look at some of my projects ?

​​​ Mike's big Showdown - Practice mode ​ ​ ​ ​ ​ ​ ​ Just Shapes and Clones​ ​ ​ ​ ​ ​ ​ ​ ​ ​ ​ ​ ​ ​ ​ ​ ​ ​ ​ ​ ​ ​ ​​ScratchScript

And further more on my profile !

tt_thoma
—————-
Contact me: tt-thoma@programmer.net​ ​ ​ ​ ​ ​ - ​ ​ ​ ​ ​ ​My website: tt-thoma.github.io/tt-thoma
Forbidden website tag (13+) : tt_thoma#6939
DifferentDance8
Scratcher
1000+ posts

Leopard: Convert Scratch projects to JavaScript AUTOMATICALLY!

userprojectmaker wrote:

hi i don't know why my project isn't working for leo pard js apparent it says “Argument sandboxId for data.sandboxId is missing.” wich is weird
Because the issue described in #794 has been fixed, I only have two opitions sadly. Your browser is probably cached to use an older version of leopard, or it uses an incompatible extension

R.I.P Zydrolic, 2023-2024
WojtekGame
Scratcher
1000+ posts

Leopard: Convert Scratch projects to JavaScript AUTOMATICALLY!

Robocamper510 wrote:

PullJosh wrote:

--Explosion-- wrote:

Cool! I'll try it out!
Let me know if you run into any issues!

@PullJosh Is there an easy way to translate JavaScript into Python? I am a saginificanltly a better coder at Scratch than Python. And I am trying to find a way to Translate Scratch Projects into Python, or vise verse. Scratch->JavaScript->Python. Or even better Scratch->Python->Scratch.
Do i have to finish leopardpy for you?


forgot to update sig, i own minecraft months ago lol
JS: code-gui | scratch-player | Roost.js | Pandoa | TOP: Roost.js || C++: Gamine | Gamiinuu | TOP: Gamine
Else: Emoji Painter | Forum Shopping Mall | TOP: Emoji Painter || Profile:Scratch | GitHub
Orgs: Chroast | Twerkish | Komond OS | JS Inventions | TOP: JS Inventions || Ocular Naming: 0 | 1 | 2 | 3
Games: Mom Hid My Game! | Creeper Adventuring
else might be outdated or removed by the ST.
DEVIL_KOLLA
Scratcher
11 posts

Leopard: Convert Scratch projects to JavaScript AUTOMATICALLY!

I want to add JavaScript script to scratch. So can anyone can help me please?
WojtekGame
Scratcher
1000+ posts

Leopard: Convert Scratch projects to JavaScript AUTOMATICALLY!

I'm creating an alternative to Leopard, again but for the same language as Leopard: scratch-player.

Leopard will still exist, scratch-player is just going to be another option
For now the syntax of scratch-player is:
import "scratch-player"
const sprite1 = new Sprite("Sprite1", 1, ["costume1", "costume2"], 0, 0, 100, 90)
//       ^                   ^        ^        ^          ^        ^  ^   ^   ^
//      Name          Also name    costume   first     second      x  y  size rotate
//      of Sprite.    of Sprite.   Index.   costume.   costume    pos pos
sprite1.scripts.moveSteps(10)
using code-gui to print the directory:
#-- Project
| project.js
| costume1.png
| costume2.png
#----------


forgot to update sig, i own minecraft months ago lol
JS: code-gui | scratch-player | Roost.js | Pandoa | TOP: Roost.js || C++: Gamine | Gamiinuu | TOP: Gamine
Else: Emoji Painter | Forum Shopping Mall | TOP: Emoji Painter || Profile:Scratch | GitHub
Orgs: Chroast | Twerkish | Komond OS | JS Inventions | TOP: JS Inventions || Ocular Naming: 0 | 1 | 2 | 3
Games: Mom Hid My Game! | Creeper Adventuring
else might be outdated or removed by the ST.
-RedLight-
Scratcher
76 posts

Leopard: Convert Scratch projects to JavaScript AUTOMATICALLY!

I tried to use https://scratch.mit.edu/projects/113321949/ with leopard, but it threw the error “Cannot read properties of undefined (reading ‘name’)”



You should use Firefox

Powered by DjangoBB