Discuss Scratch
- Discussion Forums
- » Advanced Topics
- » Leopard: Edit Scratch projects as JavaScript code
- Sheep_maker
-
1000+ posts
Leopard: Edit Scratch projects as JavaScript code
Not necessarily since JavaScript's setTimeout is different from Scratch's wait _ seconds block. I believe with a wait time of zero, setTimeout waits ~4 ms while Scratch waits one frame, or ~1/30 seconds (~33 ms). Using native setTimeout might also be slightly unreliable when running other scripts at the same time. Also, using callbacks are a bit difficult to use inside loops; in a JavaScript async function, you might instead typically do “await new Promise(resolve => setTimeout(resolve, 1000))” (or write a helper function for this)[…]
So wait(1); in leopard is setTimeout(myFunction, 1000); in Javascript?
- Sheep_maker This is a kumquat-free signature. :P
This is my signature. It appears below all my posts. Discuss it on my profile, not the forums. Here's how to make your own.
.postsignature { overflow: auto; } .scratchblocks { overflow-x: auto; overflow-y: hidden; }
- doublebox
-
19 posts
Leopard: Edit Scratch projects as JavaScript code
First off, how do i make it go 60fps and how do i change the stage size
- jeehu
-
30 posts
Leopard: Edit Scratch projects as JavaScript code
(long unnecessary quote removed by moderator - please don't spam)
Use turbowarp packager by garbomuffin. It is better
Use turbowarp packager by garbomuffin. It is better
Last edited by Paddle2See (Sept. 1, 2021 15:14:45)
when green flag clicked
if <mouse down?> then
say [I love henry stickmin!]
end
- kccuber
-
1000+ posts
Leopard: Edit Scratch projects as JavaScript code
you don't learn how javascript works from turbowarp packager Use turbowarp packager by garbomuffin. It is better
- -089-
-
33 posts
Leopard: Edit Scratch projects as JavaScript code
can someone tell me what this
{“error”:"This endpoint requires the params `files` or `parameters` in order to work. See https://codesandbox.io/docs/importing#create-wizard for more details.“}
means? after clicking on ”edit as javascript" I got redirected to https://codesandbox.io/api/v1/sandboxes/define where the message above appeared.
I was trying to convert this project https://scratch.mit.edu/projects/454347522/ if that helps anything.
{“error”:"This endpoint requires the params `files` or `parameters` in order to work. See https://codesandbox.io/docs/importing#create-wizard for more details.“}
means? after clicking on ”edit as javascript" I got redirected to https://codesandbox.io/api/v1/sandboxes/define where the message above appeared.
I was trying to convert this project https://scratch.mit.edu/projects/454347522/ if that helps anything.
- PullJosh
-
1000+ posts
Leopard: Edit Scratch projects as JavaScript code
As far as I can tell, that error appears when a project contains weird sprite or costume names. For example, your sprite “compressed file” has some strange symbols in its costume names. can someone tell me what this
{“error”:"This endpoint requires the params `files` or `parameters` in order to work. See https://codesandbox.io/docs/importing#create-wizard for more details.“}
means? after clicking on ”edit as javascript" I got redirected to https://codesandbox.io/api/v1/sandboxes/define where the message above appeared.
I was trying to convert this project https://scratch.mit.edu/projects/454347522/ if that helps anything.
Leopard should handle this gracefully, but it currently doesn't. If you want to make the translation work, you'll have to change those names.
- crawly_coder_15
-
17 posts
Leopard: Edit Scratch projects as JavaScript code
(long unnecessary quote removed by moderator - please don't spam)
Use turbowarp packager by garbomuffin. It is better
Or you can use scratch packager. Also made by garbomufffin. But turbowrap packeger is better. I still prefer leopard though
![](http://cdn.scratch.mit.edu/scratchr2/static/__9e4044de46c7852aec750b6571cceb92__/djangobb_forum/img/smilies/smile.png)
Fun fact: garbomuffin made turbowarp
search with ecosia.org to plant trees by you just searching! we need to save our world!
move (search) steps
move (plant tree) steps
- crawly_coder_15
-
17 posts
Leopard: Edit Scratch projects as JavaScript code
This is correct. Leopard provides some built-in functions, which are a bit like “My Blocks” in Scratch. Essentially, we use regular JavaScript code to create some additional functionality for you, and then your project can use that.They're all real JavaScript, but some require Leopard's library. Some of the translations in leopard to js are not real javascript code right?
So it's all real JavaScript code, but Leopard is doing a lot of the hard work for you.
What’s leopards library plug-in js?
search with ecosia.org to plant trees by you just searching! we need to save our world!
move (search) steps
move (plant tree) steps
- ego-lay_atman-bay
-
500+ posts
Leopard: Edit Scratch projects as JavaScript code
how do I convert a project from my computer in leopard.js?
- kccuber
-
1000+ posts
Leopard: Edit Scratch projects as JavaScript code
i guess you can upload it to an unshared project and link that how do I convert a project from my computer in leopard.js?
Last edited by kccuber (Sept. 4, 2021 19:45:21)
- ego-lay_atman-bay
-
500+ posts
Leopard: Edit Scratch projects as JavaScript code
about that… my project exceeds the scratch size limit, so I can't.i guess you can upload it to an unshared project and link that how do I convert a project from my computer in leopard.js?
- RoboBoy3
-
20 posts
Leopard: Edit Scratch projects as JavaScript code
There was an error converting your project.
Cannot read property ‘author’ of undefined
Leopard only supports new projects (created in Scratch 3.0). And the only supported extension is “pen”; all others will fail.
If you aren't sure why your project is failing, ask on the forums!
My project does not use pen nor any scratch extensions, but it's saying this error
Cannot read property ‘author’ of undefined
Leopard only supports new projects (created in Scratch 3.0). And the only supported extension is “pen”; all others will fail.
If you aren't sure why your project is failing, ask on the forums!
My project does not use pen nor any scratch extensions, but it's saying this error
- Avrothestickman
-
95 posts
Leopard: Edit Scratch projects as JavaScript code
Would be cool if people could learn js
Making an Ace Combat 7 fangame on scratch.
- RokCoder
-
1000+ posts
Leopard: Edit Scratch projects as JavaScript code
That's just plain wrong. Even Scratch wouldn't be described as easy if/when you're trying to do extremely complex or performant things with it. When you've picked up one computer language, picking up more becomes easier but it still depends on how deep into the language you want to go and/or what you want to use the language for. Using JS for simple things is relatively easy. Using it for complex things isn't.Most ATers know JS, it's a simple programming language Would be cool if people could learn js
- yunus4040
-
30 posts
Leopard: Edit Scratch projects as JavaScript code
Good I think this is a awesome way for Scratcher's to improve in programing and learn other programing languages like java-script
<script type=“text/javascript”>
function getInspiration(morningDay) {
if (morningDay === “morning” && boredomLevel === “bored”) {
startCoding();
getAwesome();
}
}
function startCoding() {
// Your code to start coding goes here.
}
function getAwesome() {
// Your code to get inspired goes here.
}
</script>
- NorthenSuperCoders
-
100+ posts
Leopard: Edit Scratch projects as JavaScript code
I Love that!! Great!!
NorthenSuperCoders
A self-programmer - also writes books, him self.
===================================================
- shonsh
-
1 post
Leopard: Edit Scratch projects as JavaScript code
great job
That would be nice,
If it will be possible to access variables, messages, … from outside the project.
(Assuming you know the names)
That would be nice,
If it will be possible to access variables, messages, … from outside the project.
(Assuming you know the names)
- Xx_YeetMasterXx
-
45 posts
Leopard: Edit Scratch projects as JavaScript code
I will try it lol
Xx_YeetMasterXx - 3+ Years Of Scratching - Forum Helper
- Ciyob86
-
500+ posts
Leopard: Edit Scratch projects as JavaScript code
{"error":"This endpoint requires the params `files` or `parameters` in order to work. See https://codesandbox.io/docs/importing#create-wizard for more details."}
Last edited by Ciyob86 (Sept. 16, 2021 19:33:33)