visual studio 2010 - C# Xna 4.0 foreach loop 3d Model not loading -


i have tried making drawmodel method using foreach loops:

void drawmodel(model model, vector3 modelposition)     {         foreach (modelmesh mesh in model.meshes)         {             foreach (basiceffect effect in mesh.effects)             {                 effect.lightingenabled = true;                 effect.enabledefaultlighting();                 effect.preferperpixellighting = true;                  effect.world = matrix.createtranslation(modelposition);                 effect.projection = cameraprojectionmatrix;                 effect.view = cameraviewmatrix;             }             mesh.draw();         }      } 

any ideas on missing?


Comments

Popular posts from this blog

php - Submit Form Data without Reloading page -

linux - Rails running on virtual machine in Windows -

php - $params->set Array between square bracket -