mirror of
https://github.com/yoimiya-kokomi/miao-plugin.git
synced 2024-11-16 04:35:42 +00:00
16 lines
400 B
JavaScript
16 lines
400 B
JavaScript
// eslint-disable-next-line no-unused-vars
|
|
import { Data } from '#miao'
|
|
import { ProfileDmg } from '#miao.models'
|
|
|
|
export async function calcDmg (inputData, enemyLv = 86) {
|
|
let dmg = new ProfileDmg(inputData)
|
|
let ret = await dmg.calcData({ enemyLv })
|
|
if (ret === false) {
|
|
return {}
|
|
} else {
|
|
ret = Data.getData(ret, 'ret,msg,enemyName')
|
|
ret.enemyLevel = enemyLv
|
|
}
|
|
return ret
|
|
}
|