Add Pokemon Status.
All checks were successful
continuous-integration/drone/push Build is passing

This commit is contained in:
2020-08-08 12:01:05 +02:00
parent d8e166e49a
commit 683f3ad08b
8 changed files with 67 additions and 11 deletions

View File

@@ -25,11 +25,13 @@ export void PkmnLib_Pokemon_Destruct(const Pokemon* p) { delete p; }
SIMPLE_GET_FUNC(Pokemon, IsShiny, bool)
SIMPLE_GET_FUNC_SMART_PTR(Pokemon, GetNature, const PkmnLib::Library::Nature*)
#undef SIMPLE_GET_FUNC
export uint8_t PkmnLib_Pokemon_GetIndividualValue(const Pokemon* p, CreatureLib::Library::Statistic stat) {
return p->GetIndividualValue(stat);
}
export uint8_t PkmnLib_Pokemon_GetEffortValue(const Pokemon* p, CreatureLib::Library::Statistic stat) {
return p->GetEffortValue(stat);
}
}
export uint8_t PkmnLib_Battle_SetStatus(Pokemon* p, const char* name) { Try(p->SetStatus(ArbUt::StringView(name))); };
export uint8_t PkmnLib_Battle_ClearStatus(Pokemon* p) { Try(p->ClearStatus()); };
export const char* PkmnLib_Battle_GetStatusName(Pokemon* p) { return p->GetStatusName().c_str(); }