Game Development Stack Exchange is a question and answer site for professional and independent game developers. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I have a couple of Models here, but there's only one, which will always draw in front of the others.

I tried to replace the asset-source to an other model and then the order is correct, but on this particular one, it won't render behind the other model like it should.

See the problem here (Problematic model is the dark mountain)

Why is that happening?

share|improve this question

closed as too localized by Byte56, bummzack, Anko, msell, Nate Apr 30 '13 at 21:51

This question is unlikely to help any future visitors; it is only relevant to a small geographic area, a specific moment in time, or an extraordinarily narrow situation that is not generally applicable to the worldwide audience of the internet. For help making this question more broadly applicable, visit the help center.If this question can be reworded to fit the rules in the help center, please edit the question.

You should probably post some code. Until you do, it's just a guessing game about what's wrong with your particular method. – Seth Battin Apr 24 '13 at 20:18

Make sure that the winding order is correct for this model. Try drawing the asset with an opposite winding.

share|improve this answer

I haven't wrote anything in XNA for a long time, but I think one of those XNA settings should solve your problem

 rs = new RasterizerState();
 rs.CullMode = CullMode.None;


 Device.Clear(ClearOptions.Target | ClearOptions.DepthBuffer, Color.AliceBlue, 1.0f,0);
 Device.DepthStencilState = DepthStencilState.Default;
share|improve this answer
I wrote that into the main Game-Class' init method. Didn't work :/ – IMX Apr 25 '13 at 0:05

Seeing as how it works correctly when using another model, have you check the file to make sure the vertices are in the correct place? Can you rotate the view around to see if the model is physically in-front of the models or if it's just rendering weirdly?

share|improve this answer
I've rotated it. Shows correctly but still draws not in order – IMX Apr 25 '13 at 0:10

The problem was the Z-Axis.

The model had an immense length regarding the Z-Axis, so that it seemed "always not drawed in order"

So solution: Decrease length in Z-Axis

share|improve this answer

Not the answer you're looking for? Browse other questions tagged or ask your own question.