Discuss Scratch
- Discussion Forums
- » Advanced Topics
- » Is it possible to use Inspect Element to see the values of a hidden list/variable in a Scratch project without pressing See Inside?
- donotforgetmycode
-
Scratcher
1000+ posts
Is it possible to use Inspect Element to see the values of a hidden list/variable in a Scratch project without pressing See Inside?
If you're on a Scratch project with a variable or list that's hidden, is it possible to use Inspect Element to see the value of the variable/list?
- Maximouse
-
Scratcher
1000+ posts
Is it possible to use Inspect Element to see the values of a hidden list/variable in a Scratch project without pressing See Inside?
I don't think that's possible on the Scratch website. If you run a project on TurboWarp, you can use the following code in the console to get values of all variables in the project:
for (let target of vm.runtime.targets) { for (let variable of Object.values(target.variables)) { console.log(`${target.sprite.name}: ${variable.name} = ${variable.value}`); } }
- donotforgetmycode
-
Scratcher
1000+ posts
Is it possible to use Inspect Element to see the values of a hidden list/variable in a Scratch project without pressing See Inside?
for (let target of vm.runtime.targets) {thanks!
for (let variable of Object.values(target.variables)) {
console.log(`${target.sprite.name}: ${variable.name} = ${variable.value}`);
}
}
- Sid72020123
-
Scratcher
500+ posts
Is it possible to use Inspect Element to see the values of a hidden list/variable in a Scratch project without pressing See Inside?
You can also get project scripts in JSON format from the Scratch API and check those values…
I think…
I think…
- donotforgetmycode
-
Scratcher
1000+ posts
Is it possible to use Inspect Element to see the values of a hidden list/variable in a Scratch project without pressing See Inside?
You can also get project scripts in JSON format from the Scratch API and check those values…Not scripts, variable values
I think…
- Sid72020123
-
Scratcher
500+ posts
Is it possible to use Inspect Element to see the values of a hidden list/variable in a Scratch project without pressing See Inside?
Oh. Sorry. I misread it as “script”You can also get project scripts in JSON format from the Scratch API and check those values…Not scripts, variable values
I think…
- Chiroyce
-
Scratcher
1000+ posts
Is it possible to use Inspect Element to see the values of a hidden list/variable in a Scratch project without pressing See Inside?
I don't think this is a good idea to discuss this as it can be used against a project, like for setting high scores in a game while looking at the variables.
- god286
-
Scratcher
1000+ posts
Is it possible to use Inspect Element to see the values of a hidden list/variable in a Scratch project without pressing See Inside?
I don't think this is a good idea to discuss this as it can be used against a project, like for setting high scores in a game while looking at the variables.Well we already are discussing about scratchclient and scratchconnect
- Chiroyce
-
Scratcher
1000+ posts
Is it possible to use Inspect Element to see the values of a hidden list/variable in a Scratch project without pressing See Inside?
Well we already are discussing about scratchclient and scratchconnectThis is easier to do for the average scratcher…
- god286
-
Scratcher
1000+ posts
Is it possible to use Inspect Element to see the values of a hidden list/variable in a Scratch project without pressing See Inside?
This is easier to do for the average scratcher…Anyone can make a website, gets username and password, then set any variable. I know one website that was going to be made, or maybe already exists, which does this. That website used the owner's account.
Last edited by god286 (April 4, 2022 06:06:48)
- donotforgetmycode
-
Scratcher
1000+ posts
Is it possible to use Inspect Element to see the values of a hidden list/variable in a Scratch project without pressing See Inside?
This would work on the Scratch website:thanks!const { vm } = document.getElementById('app')._reactRootContainer._internalRoot.current.child.pendingProps.store.getState().scratchGui; for (const target of vm.runtime.targets) { for (const variable of Object.values(target.variables)) { console.log(`${target.sprite.name}: ${variable.name} = ${variable.value}`); } }
Last edited by donotforgetmycode (April 4, 2022 08:01:15)
- zadyzad
-
Scratcher
2 posts
Is it possible to use Inspect Element to see the values of a hidden list/variable in a Scratch project without pressing See Inside?
What does “vm” stand for in this script?This would work on the Scratch website:thanks!const { vm } = document.getElementById('app')._reactRootContainer._internalRoot.current.child.pendingProps.store.getState().scratchGui; for (const target of vm.runtime.targets) { for (const variable of Object.values(target.variables)) { console.log(`${target.sprite.name}: ${variable.name} = ${variable.value}`); } }
- DifferentDance8
-
Scratcher
1000+ posts
Is it possible to use Inspect Element to see the values of a hidden list/variable in a Scratch project without pressing See Inside?
vm means scratch vm.What does “vm” stand for in this script?This would work on the Scratch website:thanks!const { vm } = document.getElementById('app')._reactRootContainer._internalRoot.current.child.pendingProps.store.getState().scratchGui; for (const target of vm.runtime.targets) { for (const variable of Object.values(target.variables)) { console.log(`${target.sprite.name}: ${variable.name} = ${variable.value}`); } }
the thing that actually RUNS a scratch project
- WojtekGame
-
Scratcher
1000+ posts
Is it possible to use Inspect Element to see the values of a hidden list/variable in a Scratch project without pressing See Inside?
+1vm means scratch vm.What does “vm” stand for in this script?This would work on the Scratch website:thanks!const { vm } = document.getElementById('app')._reactRootContainer._internalRoot.current.child.pendingProps.store.getState().scratchGui; for (const target of vm.runtime.targets) { for (const variable of Object.values(target.variables)) { console.log(`${target.sprite.name}: ${variable.name} = ${variable.value}`); } }
the thing that actually RUNS a scratch project
and i think the user is new to scratchfoundation/llk's repos.
i think the st has a endpoint for cloud vars but it's kinda hard to get some data out of it, unless there's a script.Oh. Sorry. I misread it as “script”You can also get project scripts in JSON format from the Scratch API and check those values…Not scripts, variable values
I think…
- Discussion Forums
- » Advanced Topics
-
» Is it possible to use Inspect Element to see the values of a hidden list/variable in a Scratch project without pressing See Inside?