- add support for models, sounds and images to be able to load from commondata

This commit is contained in:
Mark Vejvoda
2011-05-05 07:15:12 +00:00
parent 102363f151
commit c3d1d6fca0
10 changed files with 96 additions and 79 deletions

View File

@@ -949,7 +949,7 @@ void MainWindow::loadUnit(string path, string skillName) {
foundSkillName = true;
if(sn->getChild("animation") != NULL) {
skillModelFile = unitPath + '/' + sn->getChild("animation")->getAttribute("path")->getRestrictedValue();
skillModelFile = sn->getChild("animation")->getAttribute("path")->getRestrictedValue(unitPath + '/');
printf("Found skill model [%s]\n",skillModelFile.c_str());
}
@@ -962,7 +962,7 @@ void MainWindow::loadUnit(string path, string skillName) {
const XmlNode *pf= particlesNode->getChild("particle-file");
if(pf != NULL) {
skillParticleFile = unitPath + '/' + pf->getAttribute("path")->getRestrictedValue();
printf("Found skill skill particle [%s]\n",skillParticleFile.c_str());
printf("Found skill particle [%s]\n",skillParticleFile.c_str());
}
}
}