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

Function ReportPathError

engine/gamesys/src/gamesys/gamesys_script.cpp:116–132  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

114namespace dmGameSystem
115{
116 int ReportPathError(lua_State* L, dmResource::Result result, dmhash_t path_hash)
117 {
118 const char* format = 0;
119 switch(result)
120 {
121 case dmResource::RESULT_RESOURCE_NOT_FOUND:
122 format = "The resource was not found (%d): %llu, %s";
123 break;
124 case dmResource::RESULT_NOT_SUPPORTED:
125 format = "The resource type does not support this operation (%d): %llu, %s";
126 break;
127 default:
128 format = "The resource was not updated (%d): %llu, %s";
129 break;
130 }
131 return luaL_error(L, format, result, (unsigned long long)path_hash, dmHashReverseSafe64(path_hash));
132 }
133
134 void* CheckResource(lua_State* L, dmResource::HFactory factory, dmhash_t path_hash, const char* resource_ext)
135 {

Callers 11

CheckResourceFunction · 0.85
SetFunction · 0.85
LoadFunction · 0.85
CreateTextureFunction · 0.85
CreateTextureAsyncFunction · 0.85
SetTextureFunction · 0.85
CreateAtlasFunction · 0.85
SetAtlasFunction · 0.85
SetSoundFunction · 0.85
CreateSoundDataFunction · 0.85
CreateBufferFunction · 0.85

Calls 2

luaL_errorFunction · 0.85
dmHashReverseSafe64Function · 0.85

Tested by

no test coverage detected