data: 添加HAKUSH数据下载/建模

This commit is contained in:
bietiaop 2024-08-24 21:23:50 +08:00
parent d082c87809
commit 1c4798f9b8
7 changed files with 491 additions and 9 deletions

View file

@ -2,6 +2,7 @@ import * as convert from './convert.js';
import {
downloadMysImage,
downloadResourceImage,
downloadHakushFile,
} from './download/download.js';
/**
@ -130,3 +131,33 @@ export const getSuit3DImage = async suitId => {
);
return result;
};
/**
* 获取Hakush角色数据
* @param {string} charId
* @returns {Promise<string>}
*/
export const getHakushCharacter = async charId => {
const filename = `${charId}.json`;
const result = await downloadHakushFile(
'ZZZ_CHARACTER',
'HAKUSH_CHARACTER_DATA_PATH',
filename
);
return result;
};
/**
* 获取Hakush武器数据
* @param {string} weaponId
* @returns {Promise<string>}
*/
export const getHakushWeapon = async weaponId => {
const filename = `${weaponId}.json`;
const result = await downloadHakushFile(
'ZZZ_WEAPON',
'HAKUSH_WEAPON_DATA_PATH',
filename
);
return result;
};