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

Method addImGui

source/core/StarLua.cpp:592–600  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

590}
591
592void LuaEngine::addImGui() {
593 lua_checkstack(m_state, 1);
594
595 lua_rawgeti(m_state, LUA_REGISTRYINDEX, m_scriptDefaultEnvRegistryId);
596 pushImguiBindings(m_state);
597 lua_setfield(m_state, -2, "imgui");
598
599 lua_pop(m_state, 1);
600}
601
602LuaEngine* LuaEngine::luaEnginePtr(lua_State* state) {
603 return (*reinterpret_cast<LuaEngine**>(lua_getextraspace(state)));

Callers 1

restartLuaMethod · 0.80

Calls 4

lua_checkstackFunction · 0.85
lua_rawgetiFunction · 0.85
pushImguiBindingsFunction · 0.85
lua_setfieldFunction · 0.85

Tested by

no test coverage detected