Update to newer CreatureLib.
All checks were successful
continuous-integration/drone/push Build is passing

This commit is contained in:
2020-07-04 15:50:30 +02:00
parent 698bc62b47
commit 7f1bc252ba
49 changed files with 207 additions and 237 deletions

View File

@@ -1,21 +1,21 @@
#ifndef PKMNLIB_WEATHERCHANGEEVENT_HPP
#define PKMNLIB_WEATHERCHANGEEVENT_HPP
#include <Arbutils/ConstString.hpp>
#include <Arbutils/StringView.hpp>
#include <CreatureLib/Battling/EventHooks/EventData.hpp>
#include "PkmnEventKind.hpp"
namespace PkmnLib::Battling {
class WeatherChangeEvent : public CreatureLib::Battling::EventData {
ArbUt::CaseInsensitiveConstString _weatherName;
ArbUt::StringView _weatherName;
public:
explicit WeatherChangeEvent(const ArbUt::CaseInsensitiveConstString& name) : _weatherName(name) {}
explicit WeatherChangeEvent(const ArbUt::StringView& name) : _weatherName(name) {}
[[nodiscard]] CreatureLib::Battling::EventDataKind GetKind() const noexcept override {
return static_cast<CreatureLib::Battling::EventDataKind>(PkmnEventDataKind::WeatherChange);
}
const ArbUt::CaseInsensitiveConstString GetWeatherName() const noexcept { return _weatherName; }
const ArbUt::StringView& GetWeatherName() const noexcept { return _weatherName; }
};
}