Search Home Members Contacts
About Us
Products
Downloads
Community
Support
Bug #537: Array of Landscapes
Product:
TV3D SDK 6.5
Language:
Visual Basic 6
Current State:
Closed
Resolution:
Fixed
Created On:
December 30th, 2005
Last Modified:
April 10th, 2006
Reported By:
monsenrm
With the last release, my array of landscapes now crashes or acts wierd (FixSeams causes crash, CreateStaticTerrainBody stops working) etc. With only 4 landscapes everything is ok.

The problem instantly ocurred when switching to the new dll (I changed no code). Switching back to the October release fixes the problems.

Here is some 'working' code that can be used duplicate the problem:


If I use landscape indexes 1-9 rather then 0-8 fixseams crashes! With 0-8 the physics doesn't work above about the first 4 landscapes.

Just subtracting landscapes, changing indexes, etc. randomly moves the crashes and problems around!

Nchunks = 16
scl = 1

For j = 0 To 8
Set Land(j) = New TVLandscape
With Land(j)
.GenerateTerrain "s" & CStr(j) & ".bmp", TV_PRECISION_AVERAGE, Nchunks, Nchunks, 0, 0, 0, True
.SetMaterial matg
.ExpandTexture GetTex("st" & CStr(j)), 0, 0, Nchunks, Nchunks
.SetScale scl, scl, scl
End With
Next

Land(0).SetPosition 0, 0, 0
Land(1).SetPosition 1 * Nchunks * 256 * scl, 0, 0
Land(2).SetPosition 2 * Nchunks * 256 * scl, 0, 0
Land(3).SetPosition 0, 0, 1 * Nchunks * 256 * scl
Land(4).SetPosition 1 * Nchunks * 256 * scl, 0, 1 * Nchunks * 256 * scl
Land(5).SetPosition 2 * Nchunks * 256 * scl, 0, 1 * Nchunks * 256 * scl
Land(6).SetPosition 0, 0, 2 * Nchunks * 256 * scl
Land(7).SetPosition 1 * Nchunks * 256 * scl, 0, 2 * Nchunks * 256 * scl
Land(8).SetPosition 2 * Nchunks * 256 * scl, 0, 2 * Nchunks * 256 * scl

Land(1).FixSeams Land(0)
Land(2).FixSeams Land(1)
Land(3).FixSeams Land(0)

Land(4).FixSeams Land(5)
Land(4).FixSeams Land(3)
Land(4).FixSeams Land(1)
Land(4).FixSeams Land(7)

Land(5).FixSeams Land(2)
Land(6).FixSeams Land(3)
Land(7).FixSeams Land(6)
Land(7).FixSeams Land(8)
Land(8).FixSeams Land(5)


For j = 0 To 8
With Land(j)
.EnableLOD True, 4096, 128, 512, False
End With
Next

For j = 0 To 8
landid(j) = Physics.CreateStaticTerrainBody(Land(j))
Next

Comments:

Posted by SylvainTV on December 31st, 2005 at 2:29 PM
I think i know the problem, i will be releasing a patch shortly :)
Posted by SylvainTV on April 10th, 2006 at 12:17 AM
I suppose it is fixed :) If it is not, please reopen another bug,thanks ;)