From 251fab0d75cd403ce5907b0f6b50006b8a2facc5 Mon Sep 17 00:00:00 2001 From: Erwin Coumans Date: Mon, 20 Jun 2016 12:40:08 -0700 Subject: [PATCH] expand b3ResourcePath automagic resource localization capability. --- examples/Utils/b3ResourcePath.cpp | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/examples/Utils/b3ResourcePath.cpp b/examples/Utils/b3ResourcePath.cpp index d27b61e99..fdd546d5e 100644 --- a/examples/Utils/b3ResourcePath.cpp +++ b/examples/Utils/b3ResourcePath.cpp @@ -77,6 +77,12 @@ int b3ResourcePath::findResourcePath(const char* resourceName, char* resourcePat { return strlen(resourcePath); } + sprintf(resourcePath,"%s.runfiles/google3/third_party/bullet/data/%s",exePath,resourceName); + //printf("try resource at %s\n", resourcePath); + if (b3FileUtils::findFile(resourcePath, resourcePath, resourcePathMaxNumBytes)) + { + return strlen(resourcePath); + } } }