#include "CellGridModule.hpp"
#include "CellGrid.hpp"
#include "GeneratedPhysicsTag.hpp"
#include <nlohmann/json.hpp>
#include <Ogre.h>

namespace CellGridModule {

using json = nlohmann::json;

void registerComponents(flecs::world& world)
{
    // Register components without .member<> for complex types (std::string, std::vector)
    // Flecs doesn't have built-in reflection for these, but JSON serialization handles them
    
    // CellGridComponent
    world.component<CellGridComponent>();
    
    // Cell struct  
    world.component<Cell>();
    
    // FurnitureCell struct
    world.component<FurnitureCell>();
    
    // LotComponent
    world.component<LotComponent>();
    
    // DistrictComponent
    world.component<DistrictComponent>();
    
    // TownComponent
    world.component<TownComponent>();
    
    // TownComponent::ColorRect
    world.component<TownComponent::ColorRect>();
    
    // RoomComponent
    world.component<RoomComponent>();
    
    // RoofComponent
    world.component<RoofComponent>();
    
    // FurnitureTemplateComponent
    world.component<FurnitureTemplateComponent>();
	world.component<GeneratedPhysicsTag>();
}

} // namespace CellGridModule
