MCPcopy Create free account
hub / github.com/OpenMW/openmw / set

Method set

components/lua/storage.cpp:86–101  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

84 }
85
86 void LuaStorage::Section::set(std::string_view key, const sol::object& value)
87 {
88 checkIfActive();
89 throwIfCallbackRecursionIsTooDeep();
90 if (value != sol::nil)
91 mValues[std::string(key)] = Value(value);
92 else
93 {
94 auto it = mValues.find(key);
95 if (it != mValues.end())
96 mValues.erase(it);
97 }
98 if (mStorage->mListener)
99 mStorage->mListener->valueChanged(mSectionName, key, value);
100 runCallbacks(key);
101 }
102
103 void LuaStorage::Section::setAll(const sol::optional<sol::table>& values)
104 {

Callers 10

setViewSizeMethod · 0.45
setUniformMethod · 0.45
applyMethod · 0.45
applyMethod · 0.45
_setAlignMethod · 0.45
readMethod · 0.45
initLuaBindingsMethod · 0.45
loadMethod · 0.45
setSingleValueMethod · 0.45

Calls 5

ValueClass · 0.70
findMethod · 0.45
endMethod · 0.45
eraseMethod · 0.45
valueChangedMethod · 0.45

Tested by

no test coverage detected