Support for (un)suppressing weather, adds hook to block weather changes.
All checks were successful
continuous-integration/drone/push Build is passing
All checks were successful
continuous-integration/drone/push Build is passing
This commit is contained in:
@@ -191,8 +191,8 @@ void RegisterBattleClass::RegisterBattle(asIScriptEngine* engine) {
|
||||
asCALL_THISCALL);
|
||||
Ensure(r >= 0);
|
||||
r = engine->RegisterObjectMethod(
|
||||
"Battle", "void SetWeather(const constString &in name) const",
|
||||
asMETHODPR(PkmnLib::Battling::Battle, SetWeather, (const ArbUt::StringView&), void), asCALL_THISCALL);
|
||||
"Battle", "bool SetWeather(const constString &in name) const",
|
||||
asMETHODPR(PkmnLib::Battling::Battle, SetWeather, (const ArbUt::StringView&), bool), asCALL_THISCALL);
|
||||
Ensure(r >= 0);
|
||||
r = engine->RegisterObjectMethod("Battle", "void ClearWeather(const constString &in name) const",
|
||||
asMETHODPR(PkmnLib::Battling::Battle, ClearWeather, (), void), asCALL_THISCALL);
|
||||
@@ -201,6 +201,12 @@ void RegisterBattleClass::RegisterBattle(asIScriptEngine* engine) {
|
||||
"Battle", "const constString& GetWeatherName() const",
|
||||
asMETHODPR(PkmnLib::Battling::Battle, GetWeatherName, (), const ArbUt::StringView&), asCALL_THISCALL);
|
||||
Ensure(r >= 0);
|
||||
r = engine->RegisterObjectMethod("Battle", "void SuppressWeather() const",
|
||||
asMETHOD(PkmnLib::Battling::Battle, SuppressWeather), asCALL_THISCALL);
|
||||
Ensure(r >= 0);
|
||||
r = engine->RegisterObjectMethod("Battle", "void UnsuppressWeather() const",
|
||||
asMETHOD(PkmnLib::Battling::Battle, UnsuppressWeather), asCALL_THISCALL);
|
||||
Ensure(r >= 0);
|
||||
r = engine->RegisterObjectMethod("Battle", "BattleSide@ GetBattleSide(uint8 index)",
|
||||
asFUNCTION(GetBattleSideWrapper), asCALL_CDECL_OBJFIRST);
|
||||
Ensure(r >= 0);
|
||||
|
||||
Reference in New Issue
Block a user