Discuss Scratch
- Discussion Forums
- » Advanced Topics
- » Automating running and querying scratch projects ?
- gregsurname
- New to Scratch
3 posts
Automating running and querying scratch projects ?
Hi
I am new to Scratch and am seeking some direction as to whether the scenario outlined below is at all possible and if so, where to get some direction to start.
I would like to have students create sprites and after they submit the sprites, and associated scripts, be able to automatically import these scripts into a pre-built project, run the project and query the states of the sprites and the canvas at the end, possibly capturing the stage at time intervals to later build into a movie.
Has anyone else already tried something like this?
I am new to Scratch and am seeking some direction as to whether the scenario outlined below is at all possible and if so, where to get some direction to start.
I would like to have students create sprites and after they submit the sprites, and associated scripts, be able to automatically import these scripts into a pre-built project, run the project and query the states of the sprites and the canvas at the end, possibly capturing the stage at time intervals to later build into a movie.
Has anyone else already tried something like this?
- blob8108
- Scratcher
1000+ posts
Automating running and querying scratch projects ?
That's very difficult.
You could try using Python and my library Kurt to automatically import the sprites into a single project.
However, running the project and querying the states at the end is very difficult – you'd need to modify the Scratch application in order to do this.
Are you using Scratch 1.4 or 2.0?
(EDIT: Kurt will also let you analyse a project file, eg. query the position of a sprite from Python code, but it sounds like you're going to need a way to run the project first.)
You could try using Python and my library Kurt to automatically import the sprites into a single project.
However, running the project and querying the states at the end is very difficult – you'd need to modify the Scratch application in order to do this.
Are you using Scratch 1.4 or 2.0?
(EDIT: Kurt will also let you analyse a project file, eg. query the position of a sprite from Python code, but it sounds like you're going to need a way to run the project first.)
Last edited by blob8108 (Nov. 8, 2013 14:36:58)
- gregsurname
- New to Scratch
3 posts
Automating running and querying scratch projects ?
It would be with 1.4 or BYOB, et al
- blob8108
- Scratcher
1000+ posts
Automating running and querying scratch projects ?
Ah okay, that's not so bad. I would try and convince one of the Squeak modders to get the Scratch 1.4 app to automatically load the project, run it, and then save it at the end. Then you can analyse it from Python using Kurt.
- MathWizz
- Scratcher
100+ posts
Automating running and querying scratch projects ?
I think all you need to do is place a project called “default.sb” in Scratch's install directory and it will open by default.
running Chromium 42.0.2311.90 with Flash Player 15.0.0.189 on Arch Linux 3.19.5-1-ck
MathWizz — JsScratch && sb.js & Amber (coming soon! maybe)
- gregsurname
- New to Scratch
3 posts
Automating running and querying scratch projects ?
Getting scratch to open a project can be done by using the -filename command line argument.
I assume I'm going to need to mod scratch though to get it to execute without user interaction. Where's the best place to go to find information on where to start on such a project?
I assume I'm going to need to mod scratch though to get it to execute without user interaction. Where's the best place to go to find information on where to start on such a project?
- blob8108
- Scratcher
1000+ posts
Automating running and querying scratch projects ?
Try the wiki: Squeak Tutorial
- Discussion Forums
- » Advanced Topics
- » Automating running and querying scratch projects ?