feat: 添加可视化地图系统

- 创建地图布局工具(mapLayout.js)
  - 预定义区域位置配置
  - BFS计算可达距离和最短路径
  - 地图数据结构构建
- 添加迷你地图组件(MiniMap.vue)
  - 可视化显示所有区域节点和连接线
  - 当前位置脉冲动画高亮
  - 相邻区域虚线标记
  - 锁定区域显示🔒图标
  - 显示到各区域的距离步数
  - 点击区域显示前往路径
  - 图例说明不同区域类型

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
Claude
2026-01-25 15:09:44 +08:00
parent 5d4371ba1f
commit 27e1c8d440
3 changed files with 718 additions and 0 deletions

View File

@@ -14,6 +14,11 @@
<text class="description-text">{{ currentLocation.description }}</text>
</view>
<!-- 迷你地图 -->
<view class="map-panel__minimap">
<MiniMap />
</view>
<!-- 战斗状态 -->
<view v-if="game.inCombat" class="combat-status">
<text class="combat-status__title"> 战斗中</text>
@@ -123,6 +128,7 @@ import { triggerExploreEvent, tryFlee } from '@/utils/eventSystem.js'
import TextButton from '@/components/common/TextButton.vue'
import ProgressBar from '@/components/common/ProgressBar.vue'
import FilterTabs from '@/components/common/FilterTabs.vue'
import MiniMap from '@/components/common/MiniMap.vue'
const game = useGameStore()
const player = usePlayerStore()
@@ -424,6 +430,10 @@ function toggleAutoCombat() {
margin-bottom: 16rpx;
}
&__minimap {
margin-bottom: 16rpx;
}
&__locations-header {
padding: 12rpx 16rpx 8rpx;
}