updated materials to use the new shader system

This commit is contained in:
devZoGok
2021-11-10 20:17:31 +02:00
parent 84cd930911
commit 6a399c2470
2 changed files with 7 additions and 7 deletions
+3 -3
View File
@@ -39,11 +39,11 @@ namespace battleship{
this->node = smgr->addAnimatedMeshSceneNode(mesh);
*/
this->node = new Model((projectileData::meshPath[id][weaponTypeId]));
Material *mat = new Material();
mat->setLightingEnabled(false);
Material *mat = new Material(Root::getSingleton()->getLibPath() + "texture");
mat->addVariable("lightingEnabled", false);
string f[]{projectileData::diffuseMapTextPath[id][weaponTypeId]};
Texture *diffuseTexture = new Texture(f, 1);
mat->addDiffuseMap(diffuseTexture);
mat->addVariable("textures[0]", diffuseTexture, true);
this->node->setMaterial(mat);
/*