MCPcopy Create free account
hub / github.com/InoriRus/Kyty / LuaWriter

Method LuaWriter

source/lib/Scripts/src/Scripts.cpp:903–911  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

901}
902
903int ScriptFunction::LuaWriter(LuaState* /*LS*/, const void* p, size_t sz, void* ud)
904{
905 lua_init();
906
907 auto* f = static_cast<ScriptFunction*>(ud);
908 EXIT_IF(sizeof(size_t) > 4 && (static_cast<uint64_t>(sz) >> 32u) > 0);
909 f->m_dump.Add(static_cast<const uint8_t*>(p), static_cast<uint32_t>(sz));
910 return 0;
911}
912
913ScriptPair::ScriptPair(const ScriptVar& key, const ScriptVar& value): m_key(new ScriptVar(key)), m_value(new ScriptVar(value)) {}
914

Callers

nothing calls this directly

Calls 2

lua_initFunction · 0.85
AddMethod · 0.45

Tested by

no test coverage detected