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

#ifndef HolyWaveAction_hpp
#define HolyWaveAction_hpp

#include "src/main/cpp/net/eagle0/shardok/library/ShardokCommand.hpp"
#include "src/main/cpp/net/eagle0/shardok/library/settings/GameSettings.hpp"

namespace shardok {
class HolyWaveCommand : public ShardokCommand {
protected:
    auto InternalExecute(
            const GameStateW& currentState,
            const std::shared_ptr<RandomGenerator>& generator) const
            -> vector<ActionResult> override;

    const ActionCost cost;
    const UnitId actorId;

    const SettingsGetter settings;

public:
    HolyWaveCommand(
            const ActionCost& cost,
            PlayerId playerId,
            UnitId actorId,
            const SettingsGetter& settingsGetter);

    ~HolyWaveCommand() override = default;

    [[nodiscard]] auto GetCommandType() const -> CommandType override {
        return net::eagle0::shardok::common::HOLY_WAVE_COMMAND;
    }

    [[nodiscard]] auto GetCommandProto() const -> CommandProto override;
    [[nodiscard]] auto CanDoWithLowMorale() const -> bool override { return true; }
    [[nodiscard]] auto CanDoWhileStunned() const -> bool override { return true; }
};
}  // namespace shardok

#endif /* HolyWaveAction_hpp */
