MCPcopy Create free account
hub / github.com/OpenStarbound/OpenStarbound / tableSet

Method tableSet

source/core/StarLua.cpp:825–838  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

823}
824
825void LuaEngine::tableSet(bool raw, int handleIndex, LuaValue const& key, LuaValue const& value) {
826 lua_checkstack(m_state, 1);
827
828 pushHandle(m_state, handleIndex);
829 pushLuaValue(m_state, key);
830 pushLuaValue(m_state, value);
831
832 if (raw)
833 lua_rawset(m_state, -3);
834 else
835 lua_settable(m_state, -3);
836
837 lua_pop(m_state, 1);
838}
839
840void LuaEngine::tableSet(bool raw, int handleIndex, char const* key, LuaValue const& value) {
841 lua_checkstack(m_state, 1);

Callers 4

removeMethod · 0.80
setMethod · 0.80
removeMethod · 0.80
rawSetMethod · 0.80

Calls 4

lua_checkstackFunction · 0.85
lua_rawsetFunction · 0.85
lua_settableFunction · 0.85
lua_setfieldFunction · 0.85

Tested by

no test coverage detected