From 0a317b944ef6dcec92f8e02776f6c592e7f3730d Mon Sep 17 00:00:00 2001 From: Gellule Xg Date: Tue, 6 Dec 2011 20:38:53 -1000 Subject: [PATCH] Drop the file extension from the node name generation. --- code/LWSLoader.cpp | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/code/LWSLoader.cpp b/code/LWSLoader.cpp index 5c5336fdd..1acd9e20f 100644 --- a/code/LWSLoader.cpp +++ b/code/LWSLoader.cpp @@ -295,8 +295,9 @@ void LWSImporter::SetupNodeName(aiNode* nd, LWS::NodeDesc& src) if (s == std::string::npos) s = 0; else ++s; - - nd->mName.length = ::sprintf(nd->mName.data,"%s_(%08X)",src.path.substr(s).c_str(),combined); + std::string::size_type t = src.path.substr(s).find_last_of("."); + + nd->mName.length = ::sprintf(nd->mName.data,"%s_(%08X)",src.path.substr(s).substr(0,t).c_str(),combined); return; } }