MCPcopy Create free account
hub / github.com/defold/defold / ResolvePathCallback

Function ResolvePathCallback

engine/gamesys/src/gamesys/test/test_script_http.cpp:44–56  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

42};
43
44static int ResolvePathCallback(lua_State* L)
45{
46 DM_LUA_STACK_CHECK(L, 1);
47
48 const int self_index = 1;
49
50 ScriptInstance* i = (ScriptInstance*)lua_touserdata(L, self_index);
51 assert(i);
52 assert(i->m_ContextTableReference != LUA_NOREF);
53 const char* path = luaL_checkstring(L, 2);
54 dmScript::PushHash(L, dmHashString64(path));
55 return 1;
56}
57
58static int GetURLCallback(lua_State* L)
59{

Callers

nothing calls this directly

Calls 3

lua_touserdataFunction · 0.85
PushHashFunction · 0.85
assertFunction · 0.50

Tested by

no test coverage detected