//
//  FireSpreadActionFactory.hpp
//  eagle0_engine
//
//  Created by Dan Crosby on 1/6/19.
//  Copyright © 2019 none. All rights reserved.
//

#ifndef FireSpreadActionFactory_hpp
#define FireSpreadActionFactory_hpp

#include "src/main/cpp/net/eagle0/shardok/library/ShardokAction.hpp"
#include "src/main/cpp/net/eagle0/shardok/library/map/Coordinates.hpp"
#include "src/main/cpp/net/eagle0/shardok/library/settings/GameSettings.hpp"
#include "src/main/flatbuffer/net/eagle0/shardok/storage/hex_map.hpp"
#include "src/main/flatbuffer/net/eagle0/shardok/storage/hex_map_direction.hpp"
#include "src/main/flatbuffer/net/eagle0/shardok/storage/weather.hpp"

namespace shardok {

using HexMap = net::eagle0::shardok::storage::fb::HexMap;
using HexMapDirectionFb = net::eagle0::shardok::storage::fb::HexMapDirection;
using WeatherFb = net::eagle0::shardok::storage::fb::Weather;

class FireSpreadActionFactory {
private:
    const SettingsGetter settings;

public:
    explicit FireSpreadActionFactory(const SettingsGetter &getter);
    virtual ~FireSpreadActionFactory() = default;

    [[nodiscard]] virtual auto MakeFireSpreadAction(
            const Coords &coords,
            HexMapDirectionFb direction,
            const Terrain *terrain,
            const WeatherFb *weather) const -> ActionSPtr;

    [[nodiscard]] virtual auto MakeFireSpreadActions(const HexMap *hexMap, const WeatherFb *weather)
            const -> ActionList;
};
}  // namespace shardok

#endif /* FireSpreadActionFactory_hpp */
