OBJ question

If you are a new Irrlicht Engine user, and have a newbie-question, this is the forum for you. You may also post general programming questions here.
Post Reply
WaxyChicken
Posts: 95
Joined: Sat Jun 25, 2011 6:15 am

OBJ question

Post by WaxyChicken »

I keep getting:

>> Opening Network Port for clients...
>> Server started...
>> Public Sub StartListener()
Could not load mesh, because file could not be opened: : E:\Program Files\Microsoft Visual Studio 10
.0\My Documents\Projects\DUST\DustServer\Bin\Release\Bin\Release\Bin\maps\Landscape1.obj
>> SentPings
What is the proper way to load .OBJ files for use with a selector?

(VB.NET 2010 code)

Code: Select all

 
   Public Sub LoadMap(ByRef MapName As String, ByRef q3node As MeshSceneNode, ByRef Camera As CameraSceneNode, ByRef device As IrrlichtDevice, ByRef anim As SceneNodeAnimator, ByRef q3LevelMesh As AnimatedMesh, ByRef selector As TriangleSelector)
        Dim x As Integer
        x = 0
 
        Dim driver As VideoDriver = device.VideoDriver
 
        Dim smgr As SceneManager = device.SceneManager
        smgr.MeshCache.Clear()
        Debug.Print("LOADING CUSTOM MAP=============")
 
        smgr.AddToDeletionQueue(q3node)
        Debug.Print("LOADING CUSTOM MAP")
 
        q3LevelMesh = smgr.GetMesh(MyPath + "\Bin\Release\Bin\maps\" + MapName + ".obj")
        q3node = Nothing
 
        If q3LevelMesh IsNot Nothing Then
            Application.DoEvents()
            '/ old BSP     q3node = smgr.AddOctreeSceneNode(q3LevelMesh.GetMesh(0), Nothing, 1)
            q3node = smgr.AddMeshSceneNode(q3LevelMesh.GetMesh(0), Nothing, 1)
 
        End If
 
        If q3node IsNot Nothing Then
            q3node.Position = New Vector3Df(0, 0, 0)
            selector = smgr.CreateOctreeTriangleSelector(q3node.Mesh, q3node, 128)
            q3node.TriangleSelector = selector
        End If
        Camera.Position = New Vector3Df(0, -15000, 0)
        Camera.FarValue = 6000
 
        Camera.RemoveAnimator(anim)
        If selector IsNot Nothing Then
            svEntityClass.BulletSelector = selector
            anim = smgr.CreateCollisionResponseAnimator(selector, Camera, New Vector3Df(30, 50, 30), New Vector3Df(0, -10, 0), New Vector3Df(0, 30, 0), 0.0F)
            Camera.AddAnimator(anim)
            anim.Drop() '
 
        MyMap = MapName
        ChangeServerMap(MapName)
    End Sub
_______________________________________________________
You could argue with me all day long about which language is best.
But what it comes down to is:
which language is best for YOU and which language is best for ME.
Adler1337
Posts: 471
Joined: Sat Aug 09, 2008 6:10 pm
Location: In your base.

Re: OBJ question

Post by Adler1337 »

Really? :roll:
Look at your path again.
multum in parvo
WaxyChicken
Posts: 95
Joined: Sat Jun 25, 2011 6:15 am

Re: OBJ question

Post by WaxyChicken »

haha -
"did you plug in your computer?"
"oops"

thanks Adler
_______________________________________________________
You could argue with me all day long about which language is best.
But what it comes down to is:
which language is best for YOU and which language is best for ME.
WaxyChicken
Posts: 95
Joined: Sat Jun 25, 2011 6:15 am

Re: OBJ question

Post by WaxyChicken »

"Could not lock texture for making normal map."

it's a BMP 256x256.

It was 24bit color, got that error.
changed it to 256 color, still get that error.
the file is not open in any other program.

what could be causing it?
_______________________________________________________
You could argue with me all day long about which language is best.
But what it comes down to is:
which language is best for YOU and which language is best for ME.
Post Reply