mirror of https://github.com/axmolengine/axmol.git
Use relative path in the cocos2dxLuaLoader for showing useless msg when lua script trigger errors
This commit is contained in:
parent
ea2165e6ba
commit
b482a5e971
|
@ -77,7 +77,6 @@ extern "C"
|
||||||
|
|
||||||
pos = prefix.find("?.lua");
|
pos = prefix.find("?.lua");
|
||||||
chunkName = prefix.substr(0, pos) + filename + BYTECODE_FILE_EXT;
|
chunkName = prefix.substr(0, pos) + filename + BYTECODE_FILE_EXT;
|
||||||
chunkName = utils->fullPathForFilename(chunkName.c_str());
|
|
||||||
if (utils->isFileExist(chunkName))
|
if (utils->isFileExist(chunkName))
|
||||||
{
|
{
|
||||||
chunk = utils->getFileData(chunkName.c_str(), "rb", &chunkSize);
|
chunk = utils->getFileData(chunkName.c_str(), "rb", &chunkSize);
|
||||||
|
@ -86,7 +85,6 @@ extern "C"
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
chunkName = prefix.substr(0, pos) + filename + NOT_BYTECODE_FILE_EXT;
|
chunkName = prefix.substr(0, pos) + filename + NOT_BYTECODE_FILE_EXT;
|
||||||
chunkName = utils->fullPathForFilename(chunkName.c_str());
|
|
||||||
if (utils->isFileExist(chunkName))
|
if (utils->isFileExist(chunkName))
|
||||||
{
|
{
|
||||||
chunk = utils->getFileData(chunkName.c_str(), "rb", &chunkSize);
|
chunk = utils->getFileData(chunkName.c_str(), "rb", &chunkSize);
|
||||||
|
|
Loading…
Reference in New Issue