diff --git a/src/UserData/UserDataValue.hpp b/src/UserData/UserDataValue.hpp index af2c386..8e06d61 100644 --- a/src/UserData/UserDataValue.hpp +++ b/src/UserData/UserDataValue.hpp @@ -74,6 +74,12 @@ namespace Porygon::UserData { delete value; } + void SetIndexValue(const Utilities::HashedString *key, const EvalValue *value) const override { + auto field = _userData->Get()->GetField(key->GetHash()); + field->Set(_obj, value); + delete value; + } + [[nodiscard]] inline void* GetObjectPointer() const{ return _obj; } @@ -82,7 +88,6 @@ namespace Porygon::UserData { EvalValue* Cast(shared_ptr castType) const final{ return _userData->Get()->Cast(_obj, castType.get()); } - }; }