diff --git a/CInterface/Battling/Creature.cpp b/CInterface/Battling/Creature.cpp index 65f6ca4..f1fdbc2 100644 --- a/CInterface/Battling/Creature.cpp +++ b/CInterface/Battling/Creature.cpp @@ -12,7 +12,7 @@ export uint8_t CreatureLib_Creature_Construct(Creature*& out, const BattleLibrar Try(auto attacksVec = std::vector(attacks, attacks + (attacksNum * sizeof(LearnedAttack*))); out = new Creature(library, ArbUt::BorrowedPtr(species), variant, level, experience, uid, gender, coloring, - ArbUt::BorrowedPtr(heldItem), nickname, + ArbUt::BorrowedPtr(heldItem), std::string(nickname), CreatureLib::Library::TalentIndex(secretTalent, talent), attacksVec, allowedExperienceGain);) }; diff --git a/src/Battling/Models/Creature.cpp b/src/Battling/Models/Creature.cpp index 4bc286f..6dc53a0 100644 --- a/src/Battling/Models/Creature.cpp +++ b/src/Battling/Models/Creature.cpp @@ -10,7 +10,7 @@ Battling::Creature::Creature(ArbUt::BorrowedPtr library, const ArbUt::BorrowedPtr& species, const ArbUt::BorrowedPtr& variant, uint8_t level, uint32_t experience, uint32_t uid, Library::Gender gender, uint8_t coloring, - const ArbUt::BorrowedPtr heldItem, const std::string_view& nickname, + const ArbUt::BorrowedPtr heldItem, const std::string& nickname, const Library::TalentIndex& talent, const std::vector& attacks, bool allowedExperienceGain) : _library(library), _species(species), _variant(variant), _level(level), _experience(experience), diff --git a/src/Battling/Models/Creature.hpp b/src/Battling/Models/Creature.hpp index ab14354..2e24cdf 100644 --- a/src/Battling/Models/Creature.hpp +++ b/src/Battling/Models/Creature.hpp @@ -45,7 +45,7 @@ namespace CreatureLib::Battling { ArbUt::BorrowedPtr _side = nullptr; bool _onBattleField = false; - std::string_view _nickname = ""; + std::string _nickname = ""; CreatureLib::Library::TalentIndex _talentIndex; std::unique_ptr