feat: 实现游戏摄像机控制器并优化地图系统

重构地图系统,增加摄像机控制器管理相机行为。主要变更包括:
- 新增 GameCameraController 类,支持跟随目标和调试模式
- 重构 GameMap 类,分离相机逻辑到控制器
- 优化地图资源加载和同步逻辑
- 改进动画系统的事件处理
- 添加地图测试场景用于快速验证
This commit is contained in:
2026-04-02 20:07:42 +08:00
parent d55808d80f
commit ec16aeffa6
27 changed files with 16891 additions and 15694 deletions

View File

@@ -44,7 +44,6 @@ struct MoveAreaTarget {
struct TileInfo {
std::string spritePath;
int spriteIndex = 0;
int imgPos = 0;
};
struct MapConfig {
@@ -52,6 +51,7 @@ struct MapConfig {
std::string mapPath;
std::string mapDir;
int backgroundPos = 0;
Vec2 tilePos = Vec2::Zero();
int farSightScroll = 100;
bool hasCameraLimit = false;
int cameraLimitMinX = -1;