#pragma once

#include "common/protocol.hpp"
#include "native_ui/ui_types.hpp"

#include <string>
#include <vector>

namespace poe2::ui {

struct RadarMarker {
    int screenX{0};
    int screenY{0};
    Color color{colors::White};
    std::string label;
    std::string symbol; // "BOSS", "BOX", "SHRINE"
    bool isClampedToBorder{false};
};

struct RadarLayout {
    Point center{0, 0};
    int radius{100};
    std::vector<RadarMarker> markers;
    int bossCount{0};
    int strongboxCount{0};
    int shrineCount{0};
};

class RadarHud {
public:
    /// @brief Tính toán bố cục hiển thị Radar la bàn POI trong game
    static RadarLayout ComputeLayout(
        const std::vector<PoiSharedEntity>& pois,
        float playerWorldX,
        float playerWorldZ,
        float playerAngleDeg,
        int screenW,
        int screenH,
        int radarRadius = 100,
        float maxRadarDistance = 1500.0f
    );
};

} // namespace poe2::ui
