Merge pull request #896 from ericrosenbaum/feature/register-music-extension-assets

Register music extension assets
This commit is contained in:
Eric Rosenbaum authored and GitHub committed 2017-11-20 15:43:44 -05:00
commit 686139dad3
2 files changed
+8

No files matched your search

+4
View File
@@ -25,6 +25,10 @@ class Storage extends ScratchStorage {
[this.AssetType.ImageVector, this.AssetType.ImageBitmap, this.AssetType.Sound],
asset => `${ASSET_SERVER}/internalapi/asset/${asset.assetId}.${asset.dataFormat}/get/`
);
this.addWebSource(
[this.AssetType.Sound],
asset => `/static/extension-assets/scratch3_music/${asset.assetId}.${asset.dataFormat}`
);
defaultProjectAssets.forEach(asset => this.cache(
this.AssetType[asset.assetType],
this.DataFormat[asset.dataFormat],
+4
View File
@@ -107,6 +107,10 @@ module.exports = {
from: 'node_modules/scratch-blocks/media',
to: 'static/blocks-media'
}]),
new CopyWebpackPlugin([{
from: 'node_modules/scratch-vm/dist/node/assets',
to: 'static/extension-assets'
}]),
new CopyWebpackPlugin([{
from: 'extensions/**',
to: 'static',