forked from laineus/libra
-
Notifications
You must be signed in to change notification settings - Fork 0
/
assets.config.js
19 lines (19 loc) · 948 Bytes
/
assets.config.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
const replaceToExtrudedTiles = list => {
list.forEach(v => {
v[1] = v[1].replace('map/tilesets', 'map/extruded_tilesets')
})
}
module.exports = {
patterns: [
{ type: 'image', prefix: '', dir: './img/sprites', rule: /^\w+\.png$/ },
{ type: 'image', prefix: 'item/', dir: './img/items', rule: /^\w+\.png$/ },
{ type: 'image', prefix: 'chara_sprite/', dir: './img/chara_sprites', rule: /^\w+\.png$/ },
{ type: 'image', prefix: 'tileset/', dir: './img/map/tilesets', rule: /^\w+\.png$/, callback: replaceToExtrudedTiles },
{ type: 'image', prefix: 'tileset/', dir: './img/map/images', rule: /^\w+\.png$/ },
{ type: 'tilemapTiledJSONExternal', prefix: '', dir: './map', rule: /^\w+\.json$/ },
{ type: 'audio', prefix: 'se/', dir: './audio/se', rule: /^\w+\.wav$/ },
{ type: 'audio', prefix: 'bgm/', dir: './audio/bgm', rule: /^\w+\.(m4a|ogg)$/ }
],
documentRoot: './public',
output: './src/assets.json'
}