Bläddra i källkod

Initial analysis complete - planning format extension for QML and shader files

Co-authored-by: djeada <[email protected]>
copilot-swe-agent[bot] 2 månader sedan
förälder
incheckning
17c6c5ac5d

+ 1 - 1
app/controllers/action_vfx.cpp

@@ -33,4 +33,4 @@ void ActionVFX::spawnAttackArrow(Engine::Core::World *world,
                          Game::GameConfig::instance().arrow().speedAttack);
 }
 
-} // namespace App::Controllers
+} 

+ 2 - 2
app/controllers/action_vfx.h

@@ -7,7 +7,7 @@ namespace Core {
 class World;
 using EntityID = unsigned int;
 }
-} // namespace Engine
+} 
 
 namespace App::Controllers {
 
@@ -17,4 +17,4 @@ public:
                                Engine::Core::EntityID targetId);
 };
 
-} // namespace App::Controllers
+} 

+ 1 - 1
app/controllers/command_controller.cpp

@@ -211,4 +211,4 @@ void CommandController::resetMovement(Engine::Core::Entity *entity) {
   App::Utils::resetMovement(entity);
 }
 
-} // namespace App::Controllers
+} 

+ 2 - 2
app/controllers/command_controller.h

@@ -11,7 +11,7 @@ class World;
 class Entity;
 using EntityID = unsigned int;
 }
-} // namespace Engine
+} 
 
 namespace Game::Systems {
 class SelectionSystem;
@@ -62,4 +62,4 @@ private:
   void resetMovement(Engine::Core::Entity *entity);
 };
 
-} // namespace App::Controllers
+} 

+ 1 - 1
app/game_engine.cpp

@@ -112,7 +112,7 @@ GameEngine::GameEngine() {
   m_cursorManager = std::make_unique<CursorManager>();
   m_hoverTracker = std::make_unique<HoverTracker>(m_pickingService.get());
   
-  // Initialize MapCatalog for progressive loading
+  
   m_mapCatalog = std::make_unique<Game::Map::MapCatalog>();
   connect(m_mapCatalog.get(), &Game::Map::MapCatalog::mapLoaded, this, [this](QVariantMap mapData) {
     m_availableMaps.append(mapData);

+ 8 - 8
app/game_engine.h

@@ -24,8 +24,8 @@ using EntityID = unsigned int;
 struct MovementComponent;
 struct TransformComponent;
 struct RenderableComponent;
-} // namespace Core
-} // namespace Engine
+} 
+} 
 
 namespace Render {
 namespace GL {
@@ -37,8 +37,8 @@ class TerrainRenderer;
 class BiomeRenderer;
 class FogRenderer;
 class StoneRenderer;
-} // namespace GL
-} // namespace Render
+} 
+} 
 
 namespace Game {
 namespace Systems {
@@ -48,17 +48,17 @@ class ArrowSystem;
 class PickingService;
 class VictoryService;
 class CameraService;
-} // namespace Systems
+} 
 namespace Map {
 class MapCatalog;
-} // namespace Map
-} // namespace Game
+} 
+} 
 
 namespace App {
 namespace Controllers {
 class CommandController;
 }
-} // namespace App
+} 
 
 class QQuickWindow;
 

+ 3 - 3
app/hover_tracker.h

@@ -7,14 +7,14 @@ namespace Engine {
 namespace Core {
 class World;
 using EntityID = unsigned int;
-} // namespace Core
-} // namespace Engine
+} 
+} 
 
 namespace Render {
 namespace GL {
 class Camera;
 }
-} // namespace Render
+} 
 
 class HoverTracker {
 public:

+ 2 - 2
app/utils/engine_view_helpers.h

@@ -33,5 +33,5 @@ inline bool worldToScreen(const Game::Systems::PickingService *pickingService,
   return pickingService->worldToScreen(*camera, w, h, world, outScreen);
 }
 
-} // namespace Utils
-} // namespace App
+} 
+} 

+ 2 - 2
app/utils/movement_utils.h

@@ -33,5 +33,5 @@ inline void resetMovement(Engine::Core::Entity *entity) {
   }
 }
 
-} // namespace Utils
-} // namespace App
+} 
+} 

+ 2 - 2
app/utils/selection_utils.h

@@ -33,5 +33,5 @@ inline void sanitizeSelection(Engine::Core::World *world,
   }
 }
 
-} // namespace Utils
-} // namespace App
+} 
+} 

+ 4 - 4
game/map/environment.h

@@ -6,8 +6,8 @@ namespace Render {
 namespace GL {
 class Renderer;
 class Camera;
-} // namespace GL
-} // namespace Render
+} 
+} 
 
 namespace Game {
 namespace Map {
@@ -19,5 +19,5 @@ struct Environment {
                            Render::GL::Camera &camera);
 };
 
-} // namespace Map
-} // namespace Game
+} 
+} 

+ 2 - 2
game/map/level_loader.cpp

@@ -131,5 +131,5 @@ LevelLoadResult LevelLoader::loadFromAssets(const QString &mapPath,
   return res;
 }
 
-} // namespace Map
-} // namespace Game
+} 
+} 

+ 7 - 7
game/map/map_catalog.cpp

@@ -125,8 +125,8 @@ void MapCatalog::loadMapsAsync() {
     return;
   }
   
-  // Start loading the first map immediately
-  // Subsequent maps are loaded with a small delay to keep UI responsive
+  
+  
   QTimer::singleShot(0, this, &MapCatalog::loadNextMap);
 }
 
@@ -145,12 +145,12 @@ void MapCatalog::loadNextMap() {
   QVariantMap entry = loadSingleMap(path);
   if (!entry.isEmpty()) {
     m_maps.append(entry);
-    emit mapLoaded(entry);  // Notify that a new map is available
+    emit mapLoaded(entry);  
   }
-  // Note: Failed/invalid maps are silently skipped
   
-  // Schedule next map load with a small delay to keep UI responsive
-  // This allows the event loop to process UI updates between map loads
+  
+  
+  
   if (!m_pendingFiles.isEmpty()) {
     QTimer::singleShot(10, this, &MapCatalog::loadNextMap);
   } else {
@@ -209,7 +209,7 @@ QVariantMap MapCatalog::loadSingleMap(const QString &path) {
   }
   entry["playerIds"] = playerIdList;
 
-  // Load thumbnail
+  
   QString thumbnail;
   if (file.open(QIODevice::ReadOnly)) {
     QByteArray data = file.readAll();

+ 1 - 1
game/map/map_catalog.h

@@ -14,7 +14,7 @@ public:
   
   static QVariantList availableMaps();
   
-  // Asynchronous progressive loading
+  
   Q_INVOKABLE void loadMapsAsync();
   
   bool isLoading() const { return m_loading; }

+ 1 - 1
game/map/terrain_service.cpp

@@ -85,4 +85,4 @@ TerrainType TerrainService::getTerrainType(int gridX, int gridZ) const {
   return m_heightMap->getTerrainType(gridX, gridZ);
 }
 
-} // namespace Game::Map
+} 

+ 1 - 1
game/map/terrain_service.h

@@ -44,4 +44,4 @@ private:
   BiomeSettings m_biomeSettings;
 };
 
-} // namespace Game::Map
+} 

+ 1 - 1
game/visuals/team_colors.h

@@ -9,4 +9,4 @@ inline QVector3D teamColorForOwner(int ownerId) {
   auto color = registry.getOwnerColor(ownerId);
   return QVector3D(color[0], color[1], color[2]);
 }
-} // namespace Game::Visuals
+} 

+ 1 - 1
game/visuals/visual_catalog.cpp

@@ -95,4 +95,4 @@ void applyToRenderable(const VisualDef &def,
   }
 }
 
-} // namespace Game::Visuals
+} 

+ 2 - 2
game/visuals/visual_catalog.h

@@ -9,7 +9,7 @@ namespace Engine {
 namespace Core {
 class RenderableComponent;
 }
-} // namespace Engine
+} 
 
 namespace Game::Visuals {
 
@@ -35,4 +35,4 @@ VisualDef::MeshKind meshKindFromString(const QString &s);
 void applyToRenderable(const VisualDef &def,
                        Engine::Core::RenderableComponent &r);
 
-} // namespace Game::Visuals
+}