Update to new THROW message.
continuous-integration/drone/push Build is passing Details

This commit is contained in:
Deukhoofd 2021-11-21 12:40:25 +01:00
parent 50e2f39919
commit 6d3c027a08
Signed by: Deukhoofd
GPG Key ID: F63E044490819F6F
3 changed files with 4 additions and 4 deletions

View File

@ -65,7 +65,7 @@ namespace PkmnLib::Battling {
if (!this->_heldItem.IsEmpty()) {
auto item = _library->GetItemLibrary()->TryGet(this->_heldItem);
if (!item.has_value()) {
THROW("Unknown Item: " << this->_heldItem.std_str());
THROW("Unknown Item: ", this->_heldItem.std_str());
}
heldItem = item.value();
}
@ -147,7 +147,7 @@ namespace PkmnLib::Battling {
CreatureLib::Battling::AttackLearnMethod method) {
auto v = _library->GetMoveLibrary()->TryGet(moveName);
if (!v.has_value()) {
THROW("Invalid Move given: " << moveName.std_str());
THROW("Invalid Move given: ", moveName.std_str());
}
if (_currentMove >= _library->GetSettings()->GetMaximalAttacks()) {
throw ArbUt::Exception("This pokemon already has the maximal allowed moves.");

View File

@ -43,7 +43,7 @@ public:
} else {
ctx->PopState();
}
THROW("Script didn't finish properly; message " << scriptResult);
THROW("Script didn't finish properly; message ", scriptResult);
}
onEnd(ctx);
if (newContext) {

View File

@ -438,7 +438,7 @@ void AngelScriptResolver::InitializeByteCode(
_evolutionTypes.Set(val.first, type);
}
} else {
THROW("Resolving unknown script category value: " << innerDb.first);
THROW("Resolving unknown script category value: ", innerDb.first);
}
}
}