I`m a Chinese, so it is unavoidable for me to made mistakes of English grammar, please try to understand it.I`m sorry for this......
I am using Irrlicht .11 in VB.NET.
"examples.net" for vb.net is good for beginner, but "examples" is all coded in C++, I tried my best to understand them(I only know Basic and few Pascal), but the "04.Movement"(and all next...) is too hard for me to understand, I think it`s code is fully different from Basic. Anyone have example codes for VB.net or the vb codes of "examples"?
I load the Quake3 Map(map-20kdm2.pk3) into my program using "AddOctTreeSceneNode", but before I load the map I have 200 FPS, after I loaded the map I only have 70 FPS. What`s wrong??(My video card is GeForce4 MX440)
I hope Irrlicht`s examples can translate to VB.net as soon as possible......
Here`s my code:
Label1.Text = "Engine running..."
Dim FormSize As Irrlicht.Core.Dimension2D
FormSize.Height = 600
FormSize.Width = 800
Dim Dev1 As New IrrlichtDevice(DriverType.DIRECTX9, FormSize, 32, False, True, True)
FormSize = Nothing
Dev1.ResizeAble = True
Dev1.WindowCaption = "Irrlicht 3D engine test program by allfox"
Dev1.CursorControl.Visible = False
Dim Ftxture As ITexture = Dev1.VideoDriver.GetTexture("data\Faerie.BMP")
Dim Fmesh As Irrlicht.Scene.IAnimatedMesh = Dev1.SceneManager.GetMesh("data\faerie.md2")
If Fmesh Is Nothing Then
MessageBox.Show("Can`t load mesh for Faerie.", "Unexpect error")
Dev1.CloseDevice()
End If
If Ftxture Is Nothing Then
MessageBox.Show("Can`t load texture for Faerie.", "Unexpect error")
Dev1.CloseDevice()
End If
Dim Cam1Location As Vector3D
Cam1Location = New Vector3D(20, 0, -50)
Dim Cam1 As ICameraSceneNode = Dev1.SceneManager.AddCameraSceneNodeFPS(Nothing, 100, 100, -1)
Cam1.Position = Cam1Location
Cam1Location = Nothing
Dim Fnode As ISceneNode
Fnode = Dev1.SceneManager.AddAnimatedMeshSceneNode(Fmesh, Nothing, -1)
Fnode.SetMaterialTexture(0, Ftxture)
Fnode.SetMaterialFlag(MaterialFlag.LIGHTING, False)
Dim Map1 As ISceneManager = Dev1.SceneManager
Dim Video1 As IVideoDriver = Dev1.VideoDriver
Dim LoadMesh As Boolean
LoadMesh = Dev1.FileSystem.AddZipFileArchive("data\map1.pk3")
If LoadMesh Then
'Map1.AddMeshSceneNode(Map1.GetMesh("20kdm2.bsp").GetMesh(0), Nothing, -1).Position = New Vector3D(-1300, -144, -1249)
Map1.AddOctTreeSceneNode(Map1.GetMesh("20kdm2.bsp").GetMesh(0), Nothing, -1, -1).Position = New Vector3D(-1300, -144, -1249)
End If
While (Dev1.Run = True) And (Dev1.WindowActive = True)
Dev1.VideoDriver.BeginScene(True, True, New Color(0, 100, 100, 100))
Dev1.SceneManager.DrawAll()
Dev1.VideoDriver.EndScene()
Dev1.WindowCaption = "Engine running at " & Dev1.VideoDriver.FPS.ToString & "FPS " & "Camming at " & Cam1.Position.X.ToString & "," & Cam1.Position.Y.ToString & "," & Cam1.Position.Z.ToString
End While
Dev1.CloseDevice()
Label1.Text = "Engine stopped"
If you using Irrlicht in VB.net , come in and help me please
-
mikeyj21
VB.NET
Hi! Thank goodness.... someone else trying to use Irrlicht with VB.NET!
I only discovered Irrlicht a couple of days ago, but I have translated a couple of the C++ tutorials into my own little project.
At the moment I have got three dynamic lights rotating around the 'hello world' girl, inside a .x file level. (I was using a .3ds level, but either there is a bug in the import, or 3d max exports a 'hidden' light, because the level was always improperly lit).
I will post my code towards the end of the week, if you are interested, as it's still a little shoddy.
Unfortunately there are a few of the C++ features which don't seem to be implemented yet in .NET... for example, the particle system, and dynamic shadows. I'm sure they will be added in the near future!
Anyway, best of luck!
I only discovered Irrlicht a couple of days ago, but I have translated a couple of the C++ tutorials into my own little project.
At the moment I have got three dynamic lights rotating around the 'hello world' girl, inside a .x file level. (I was using a .3ds level, but either there is a bug in the import, or 3d max exports a 'hidden' light, because the level was always improperly lit).
I will post my code towards the end of the week, if you are interested, as it's still a little shoddy.
Unfortunately there are a few of the C++ features which don't seem to be implemented yet in .NET... for example, the particle system, and dynamic shadows. I'm sure they will be added in the near future!
Anyway, best of luck!
Re: If you using Irrlicht in VB.net , come in and help me pl
Yes, I'm going to do this when Irrlicht.NET is feature complete.allfox wrote:I hope Irrlicht`s examples can translate to VB.net as soon as possible......
BTW: I just opened a new forum, just for .NET users.
-
sabima
I have rhe same pb but with #
Niko,
I have the same pb with Allfox! I'm french so my english is not very good and i want to use irrlicht with C# but there are not enough examples and documentations to permit us to understand concepts!
When irrlicht.net could be complete?
thank u for ur work!
I have the same pb with Allfox! I'm french so my english is not very good and i want to use irrlicht with C# but there are not enough examples and documentations to permit us to understand concepts!
When irrlicht.net could be complete?
thank u for ur work!