2023-03-07 17:52:11 +00:00
|
|
|
import { Data } from '#miao'
|
2022-09-24 12:19:59 +00:00
|
|
|
import lodash from 'lodash'
|
2022-09-24 22:42:48 +00:00
|
|
|
import calc from './calc.js'
|
2022-09-24 12:19:59 +00:00
|
|
|
|
|
|
|
let artiSetMap = {}
|
|
|
|
let artiMap = {}
|
|
|
|
|
2023-03-07 17:52:11 +00:00
|
|
|
let artis = Data.readJSON('resources/meta/artifact/data.json', 'miao')
|
2022-09-24 12:19:59 +00:00
|
|
|
|
|
|
|
lodash.forEach(artis, (ds) => {
|
|
|
|
let artiSet = {
|
|
|
|
name: ds.name,
|
|
|
|
effect: ds.effect,
|
|
|
|
sets: {}
|
|
|
|
}
|
|
|
|
artiSetMap[ds.name] = artiSet
|
|
|
|
lodash.forEach(ds.sets, (as, idx) => {
|
|
|
|
if (as.name) {
|
|
|
|
artiMap[as.name] = {
|
|
|
|
set: ds.name,
|
|
|
|
idx
|
|
|
|
}
|
|
|
|
artiSet.sets[idx] = as.name
|
|
|
|
}
|
|
|
|
})
|
|
|
|
})
|
|
|
|
|
2022-11-24 08:25:04 +00:00
|
|
|
export { artiMap, artiSetMap, calc }
|
|
|
|
export * from './meta.js'
|