mirror of
https://github.com/scratchfoundation/scratch-vm.git
synced 2025-07-30 08:01:18 -04:00
Add costume dataURI to costumes from storage (#517)
* Add costume dataURI to costumes from storage Towards #515, LLK/scratch-gui#279 * Fix tests * Load costumes incrementally Some of our tests assume that at least some of our costume data is available before the costume data is loaded. So, provide as much costume data as is available. * Remove unnecessary filter for null costumes Resolved when we updated to load costumes incrementally. /ht @cwillisf
This commit is contained in:
parent
a4aa3810ae
commit
57e73a68a6
3 changed files with 39 additions and 27 deletions
test/integration
|
@ -40,14 +40,17 @@ test('complex', function (t) {
|
|||
rotationStyle: 'all around',
|
||||
visible: true
|
||||
});
|
||||
vm.addCostume({
|
||||
costumeName: 'costume1',
|
||||
baseLayerID: 0,
|
||||
baseLayerMD5: 'f9a1c175dbe2e5dee472858dd30d16bb.svg',
|
||||
bitmapResolution: 1,
|
||||
rotationCenterX: 47,
|
||||
rotationCenterY: 55
|
||||
});
|
||||
vm.addCostume(
|
||||
'f9a1c175dbe2e5dee472858dd30d16bb.svg',
|
||||
{
|
||||
costumeName: 'costume1',
|
||||
baseLayerID: 0,
|
||||
baseLayerMD5: 'f9a1c175dbe2e5dee472858dd30d16bb.svg',
|
||||
bitmapResolution: 1,
|
||||
rotationCenterX: 47,
|
||||
rotationCenterY: 55
|
||||
}
|
||||
);
|
||||
}
|
||||
});
|
||||
|
||||
|
@ -73,14 +76,17 @@ test('complex', function (t) {
|
|||
vm.addSprite2(sprite);
|
||||
|
||||
// Add backdrop
|
||||
vm.addBackdrop({
|
||||
costumeName: 'baseball-field',
|
||||
baseLayerID: 26,
|
||||
baseLayerMD5: '6b3d87ba2a7f89be703163b6c1d4c964.png',
|
||||
bitmapResolution: 2,
|
||||
rotationCenterX: 480,
|
||||
rotationCenterY: 360
|
||||
});
|
||||
vm.addBackdrop(
|
||||
'6b3d87ba2a7f89be703163b6c1d4c964.png',
|
||||
{
|
||||
costumeName: 'baseball-field',
|
||||
baseLayerID: 26,
|
||||
baseLayerMD5: '6b3d87ba2a7f89be703163b6c1d4c964.png',
|
||||
bitmapResolution: 2,
|
||||
rotationCenterX: 480,
|
||||
rotationCenterY: 360
|
||||
}
|
||||
);
|
||||
});
|
||||
|
||||
// After two seconds, get playground data and stop
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue