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

#ifndef EAGLE0_SHARDOK_LIBRARY_ACTIONS_FIRE_SPREAD_ACTION_HPP
#define EAGLE0_SHARDOK_LIBRARY_ACTIONS_FIRE_SPREAD_ACTION_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/flatbuffer/net/eagle0/shardok/storage/tile_modifier.hpp"

namespace shardok {

class FireSpreadAction : public ShardokAction {
private:
    auto InternalExecute(
            const GameStateW& currentState,
            const std::shared_ptr<RandomGenerator>& generator) const
            -> vector<ActionResult> override;

    const Coords coords;
    const net::eagle0::shardok::storage::fb::TileModifier existingModifier;
    const PercentileRollOdds fireSpreadOdds;

public:
    FireSpreadAction(
            const Coords& coords,
            net::eagle0::shardok::storage::fb::TileModifier existingModifier,
            PercentileRollOdds odds);

    auto GetFireSpreadOdds() const -> const PercentileRollOdds&;
    auto GetCoords() const -> const Coords&;
};
}  // namespace shardok

#endif  // EAGLE0_SHARDOK_LIBRARY_ACTIONS_FIRE_SPREAD_ACTION_HPP
