Meshes are not drawn correctly (invisible walls)
Blitz3D Forums/Blitz3D Beginners Area/Meshes are not drawn correctly (invisible walls)
| ||
Hey out there, I have a little problem importing meshes to Blitz 3D. I have a simple mesh created and textured in blender and exported it as *.x-file. Its just a ground plane and a wall beside. In blender everything looks alright, but if I let this mesh draw by B3D, it looks kind of weird. It seems like the top faces of the mesh have been deleted or were not shown. Can somebody help me out? the code looks like: Graphics3D 1920,1200,32,1 SetBuffer BackBuffer() ;Level laden, drehen, skalieren und positionieren bunker=LoadMesh("level001/gfx/bunker.x") PositionEntity bunker,0,0,0 TurnEntity bunker,70,0,0 ScaleEntity bunker,30,30,30 EntityAlpha bunker,1 ;Kamera erstellen, positionieren und auf die Insel zeigen lassen camera=CreateCamera() CameraClsColor camera,50,50,50 PositionEntity camera,0,55,0 PointEntity camera,bunker RotateEntity camera,70,0,0 ; ----- Hauptschleife While Not KeyHit(1) ; Steuerung If KeyDown(17) Then MoveEntity camera,0,0,1 ; W gedrückt = vorwärts If KeyDown(30) Then TurnEntity camera,0,2,0 ; A gedrückt = links drehen If KeyDown(31) Then MoveEntity camera,0,0,-1 ; S gedrückt = rückwärts If KeyDown(32) Then TurnEntity camera,0,-2,0 ; D gedrückt = rechts drehen If KeyDown(16) Then MoveEntity camera,-1,0,0 ; Q gedrückt = Strafe links If KeyDown(18) Then MoveEntity camera,1,0,0 ; E gedrückt = Strafe rechts If KeyDown(201) Then TranslateEntity camera,0,1,0 ; PGUP = hoch If KeyDown(209) Then TranslateEntity camera,0,-1,0 ; PGDWN = runter UpdateWorld RenderWorld Flip Wend ClearWorld End |
| ||
Hey DerRichie1984, it would also help if you can upload the x file that you are having problems with. |
| ||
@DerRichie1984>>Here is a code to check if your mesh/entity is the same in your modeling tool than in Blitz3d : http://www.blitzbasic.com/codearcs/codearcs.php?code=3264 It works well here, let me know if you find an error or have a problem with it. |
| ||
Problem solved, thank you all EntityFX bunker,16 Backface culling was not turned off *shame on me* |