Obstsalat
16-04-2010 11:39:50
Ok, I am still a beginner. I read the Tutorials and finished yesterday with thisone: http://www.ogre3d.org/wiki/index.php/Mo ... orial_VB_3
Now I thought it is maybe a good training if you try something not in tutorial.
I wanted to create a simple Room. Means 6 Walls. Nothing more.
The problem is that this tutorial doesnt really explain the plane object. The only thing in tutorial to this topic is this:
Now i tried to build my wall sameway, that looks like this:
This works more or less. I can see the wall only from one side (this is normal if i understand right) but the side i can see is always pitch black. I created a light and set the backgroundcolor to white so this shouldnt be. Thats why i need help because i didn't get it, why it doesnt work.
Here the code i used for light:
Please help me.
Edit: Sorry forgot this. Im using Vb.net
Greetings Obstsalat
Now I thought it is maybe a good training if you try something not in tutorial.
I wanted to create a simple Room. Means 6 Walls. Nothing more.
The problem is that this tutorial doesnt really explain the plane object. The only thing in tutorial to this topic is this:
'Ground to stand on
Dim myPlane As Plane = New Plane(Vector3.UNIT_Y, 0)
MeshManager.Singleton.CreatePlane("ground", ResourceGroupManager.DEFAULT_RESOURCE_GROUP_NAME, myPlane, 1500, 1500, 20, 20, True, 1, 5, 5, -Vector3.UNIT_Z)
Dim myGround As Entity = mySceneManager.CreateEntity("GroundEntity", "ground")
mySceneManager.RootSceneNode.CreateChildSceneNode.AttachObject(myGround)
myGround.SetMaterialName("Examples/Rockwall")
myGround.CastShadows = False
Now i tried to build my wall sameway, that looks like this:
myPlane = New Plane(-Vector3.UNIT_X, 0)
MeshManager.Singleton.CreatePlane("wall1", ResourceGroupManager.DEFAULT_RESOURCE_GROUP_NAME, myPlane, 1500, 1500, 20, 20, True, 1, 5, 5, Vector3.UNIT_Z)
myGround = mySceneManager.CreateEntity("WallEntity", "wall1")
mySceneManager.RootSceneNode.CreateChildSceneNode.AttachObject(myGround)
myGround.SetMaterialName("Examples/Rockwall")
myGround.CastShadows = False
This works more or less. I can see the wall only from one side (this is normal if i understand right) but the side i can see is always pitch black. I created a light and set the backgroundcolor to white so this shouldnt be. Thats why i need help because i didn't get it, why it doesnt work.
Here the code i used for light:
Dim myLight As Light = mySceneManager.CreateLight("Light1")
myLight.Type = Light.LightTypes.LT_POINT
myLight.Position = New Vector3(0, 150, -50)
myLight.DiffuseColour = ColourValue.Red
myLight.SpecularColour = ColourValue.Red
Please help me.
Edit: Sorry forgot this. Im using Vb.net
Greetings Obstsalat