mirror of
https://github.com/scratchfoundation/scratch-vm.git
synced 2025-07-23 12:38:58 -04:00
Configuring scratch-vm to use changes made to scratch-parser.
This commit is contained in:
parent
e0b23cde31
commit
605ce4b16d
2 changed files with 18 additions and 2 deletions
|
@ -27,6 +27,9 @@
|
|||
"watch": "webpack --progress --colors --watch",
|
||||
"version": "json -f package.json -I -e \"this.repository.sha = '$(git log -n1 --pretty=format:%H)'\""
|
||||
},
|
||||
"dependencies": {
|
||||
"scratch-parser": "LLK/scratch-parser#save-load"
|
||||
},
|
||||
"devDependencies": {
|
||||
"adm-zip": "0.4.7",
|
||||
"babel-core": "^6.24.1",
|
||||
|
@ -59,7 +62,6 @@
|
|||
"scratch-parser": "latest",
|
||||
"scratch-render": "latest",
|
||||
"scratch-storage": "^0.4.0",
|
||||
"scratch-parser": "latest",
|
||||
"script-loader": "0.7.2",
|
||||
"socket.io-client": "2.0.4",
|
||||
"stats.js": "^0.17.0",
|
||||
|
|
|
@ -27,7 +27,13 @@ const deserializeSound = function (sound, runtime, zip) {
|
|||
// This sound has already been cached.
|
||||
return Promise.resolve(null);
|
||||
}
|
||||
|
||||
if (!zip) {
|
||||
// TODO adding this case to make integration tests pass, need to rethink
|
||||
// the entire structure of saving/loading here (w.r.t. differences between
|
||||
// loading from local zip file or from server)
|
||||
log.error('Zipped assets were not provided.');
|
||||
return Promise.resolve(null);
|
||||
}
|
||||
const soundFile = zip.file(fileName);
|
||||
if (!soundFile) {
|
||||
log.error(`Could not find sound file associated with the ${sound.name} sound.`);
|
||||
|
@ -82,6 +88,14 @@ const deserializeCostume = function (costume, runtime, zip) {
|
|||
return Promise.resolve(null);
|
||||
}
|
||||
|
||||
if (!zip) {
|
||||
// TODO adding this case to make integration tests pass, need to rethink
|
||||
// the entire structure of saving/loading here (w.r.t. differences between
|
||||
// loading from local zip file or from server)
|
||||
log.error('Zipped assets were not provided.');
|
||||
return Promise.resolve(null);
|
||||
}
|
||||
|
||||
const costumeFile = zip.file(fileName);
|
||||
if (!costumeFile) {
|
||||
log.error(`Could not find costume file associated with the ${costume.name} costume.`);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue