diff --git a/Build_God_Admin_Frontend/Frontend/src/views/admin/MonstersView.vue b/Build_God_Admin_Frontend/Frontend/src/views/admin/MonstersView.vue index bd4d9f5..2817321 100644 --- a/Build_God_Admin_Frontend/Frontend/src/views/admin/MonstersView.vue +++ b/Build_God_Admin_Frontend/Frontend/src/views/admin/MonstersView.vue @@ -46,15 +46,17 @@ const searchQuery = ref('') const monsterIconOptions = [ { value: '', label: '无图标' }, - { value: 'monster-wolf.svg', label: '狼' }, - { value: 'monster-skeleton.svg', label: '骷髅' }, - { value: 'monster-dragon.svg', label: '龙' }, - { value: 'monster-ghost.svg', label: '鬼' }, - { value: 'monster-slime.svg', label: '史莱姆' }, - { value: 'monster-bat.svg', label: '蝙蝠' }, - { value: 'monster-spider.svg', label: '蜘蛛' }, - { value: 'monster-snake.svg', label: '蛇' }, - { value: 'monster-golem.svg', label: '石魔' } + { value: '狗.svg', label: '狗' }, + { value: '猴.svg', label: '猴' }, + { value: '狐狸.svg', label: '狐狸' }, + { value: '鼠.svg', label: '老鼠' }, + { value: '猫咪.svg', label: '猫咪' }, + { value: '蛇.svg', label: '蛇' }, + { value: '螳螂.svg', label: '螳螂' }, + { value: '乌鸦.svg', label: '乌鸦' }, + { value: '羊.svg', label: '羊' }, + { value: '蜘蛛.svg', label: '蜘蛛' }, + { value: '猪.svg', label: '猪' } ] const formData = ref({ diff --git a/Build_God_Game/src/views/BagView.vue b/Build_God_Game/src/views/BagView.vue index f4df902..31692e4 100644 --- a/Build_God_Game/src/views/BagView.vue +++ b/Build_God_Game/src/views/BagView.vue @@ -44,10 +44,9 @@ const scrapLevelColorMap: Record = { 5: '#FF8C00' } -const getItemIcon = (item: { icon: string | null }) => { +const getItemIcon = (item: { icon: string | null },itemType:string) => { if (item.icon) { - const [dir, file] = item.icon.split('/') - return new URL(`../assets/icons/${dir}/${file}`, import.meta.url).href + return new URL(`../assets/icons/${itemType}/${item.icon}`, import.meta.url).href } return itemDefaultIcon } @@ -126,7 +125,7 @@ onMounted(() => {
-
⚔️
{{ item.itemName }} @@ -156,7 +155,7 @@ onMounted(() => {
- +
💊
{{ item.itemName }} {{ item.quantity }} @@ -186,7 +185,7 @@ onMounted(() => {
-
📦
{{ item.itemName }} diff --git a/Build_God_Game/src/views/MonsterListView.vue b/Build_God_Game/src/views/MonsterListView.vue index 32568bc..e624e4d 100644 --- a/Build_God_Game/src/views/MonsterListView.vue +++ b/Build_God_Game/src/views/MonsterListView.vue @@ -13,7 +13,7 @@ const characterStore = useCharacterStore() const getMonsterIcon = (iconName?: string) => { if (!iconName) return defaultIcon - return `/src/assets/images/monster/${iconName}` + return `/src/assets/icons/monster/${iconName}` } const getMonsterTypeLabel = (type: number) => {