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

Function GetResourcesPath

engine/dlib/src/dlib/sys_win32.cpp:230–246  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

228#endif
229
230 Result GetResourcesPath(int argc, char* argv[], char* path, uint32_t path_len)
231 {
232 assert(path_len > 0);
233 path[0] = '\0';
234
235 char module_file_name[DMPATH_MAX_PATH];
236 DWORD copied = GetModuleFileNameA(NULL, module_file_name, DMPATH_MAX_PATH);
237
238 if (copied < DMPATH_MAX_PATH)
239 {
240 dmPath::Dirname(module_file_name, path, path_len);
241 return RESULT_OK;
242 }
243
244 dmLogFatal("Unable to get module file name");
245 return RESULT_UNKNOWN;
246 }
247
248 // Default
249 Result GetLogPath(char* path, uint32_t path_len)

Callers

nothing calls this directly

Calls 2

DirnameFunction · 0.85
assertFunction · 0.50

Tested by

no test coverage detected