Major terrain crash with lightpack
by arteria3d · in · 12/20/2004 (7:53 am) · 8 replies
I have a major concern, which has cost me the last three weeks work.Yesterday, i attempted to recompile, cos i added one small performance change to TGE - anyway i then tried loading my level and it wouldnt load.
I reversed the change and tried loading again - still the load fail.
Two days of bug hunting found it to be the terrain file .ter - and when i looked at it in the notepad, its structure, especially at the bottom of the file was completely different to my other terrain files and the ones supplied with starter fps - it seemed that loads of information was missing.
This terrain file will not load into any version of torque, but when i take it out of tge with the lighting pack, the mission loads - when i put the terrain back it crashes.
As i have never experienced this probelem before, and it has cost me a lot of hard work, i am wondering whether this is cos of the lightpack??? as it does render the shadows into the terrain doesnt it?
Anyone any ideas?
Also an important fact to note - i did a system resotre back to just after the lightpack installation - and that actually worked, with the seemingly corrupt file - but any recompiles of its sdk - and it crashes. Also moving the Ter and Mission files into another version of torque, still made the mission crash.
I am wondering whether it is anything possibly to do with datablock of the lighting maybe? and whether the terrain file has somehow got corrupt with respects to the light rendering on it?
Steve
I reversed the change and tried loading again - still the load fail.
Two days of bug hunting found it to be the terrain file .ter - and when i looked at it in the notepad, its structure, especially at the bottom of the file was completely different to my other terrain files and the ones supplied with starter fps - it seemed that loads of information was missing.
This terrain file will not load into any version of torque, but when i take it out of tge with the lighting pack, the mission loads - when i put the terrain back it crashes.
As i have never experienced this probelem before, and it has cost me a lot of hard work, i am wondering whether this is cos of the lightpack??? as it does render the shadows into the terrain doesnt it?
Anyone any ideas?
Also an important fact to note - i did a system resotre back to just after the lightpack installation - and that actually worked, with the seemingly corrupt file - but any recompiles of its sdk - and it crashes. Also moving the Ter and Mission files into another version of torque, still made the mission crash.
I am wondering whether it is anything possibly to do with datablock of the lighting maybe? and whether the terrain file has somehow got corrupt with respects to the light rendering on it?
Steve
About the author
Owner of uk based Ltd company ArteriaMediaLtd. with a trading name of Arteria3d Website;arteria3d.com
#2
12/20/2004 (1:19 pm)
No the performance changes didnt cause the problem. The reason it was highlighted when i implemented the changes because this was the first time i had recompiled since installing the lighting pack - so the problem was there all along. When i went back to the original one version i was using, using system restore, that one worked - but as straight as i tried to see if that terrain file worked in fresh installs of the lightpack - it wouldnt work and hence even if u just moved the terrain file into the tge demo or other versions it still wouldnt work.
#3
Am I understanding this correctly - the terrain file is corrupt, right? Here's the history of events as I understand them:
-Level is fine.
-Make changes and install Lighting Pack.
-Level is broken.
-Try loading level in other TGE based demos, which failed (because the terrain file is corrupt).
-Try loading level on other systems, which failed (because the terrain file is corrupt).
-Perform a system restore, which worked (because you replaced the terrain file with the original).
If your performance code in any way affects the terrain info it could corrupt the terrain file when it's save. My guess is that you saved the mission while using the modified code writing to and corrupting the terrain file.
12/20/2004 (5:21 pm)
The Lighting Pack does not alter this code in any way, in fact the terrain files are 100% backward and forward compatible between TGE and the Lighting Pack.Am I understanding this correctly - the terrain file is corrupt, right? Here's the history of events as I understand them:
-Level is fine.
-Make changes and install Lighting Pack.
-Level is broken.
-Try loading level in other TGE based demos, which failed (because the terrain file is corrupt).
-Try loading level on other systems, which failed (because the terrain file is corrupt).
-Perform a system restore, which worked (because you replaced the terrain file with the original).
If your performance code in any way affects the terrain info it could corrupt the terrain file when it's save. My guess is that you saved the mission while using the modified code writing to and corrupting the terrain file.
#4
Have you tried deleting these *.ml files before running your mission?
12/20/2004 (10:07 pm)
I'm only new to Torque and have Torque 1.3 and the lighting pack 1.2. One thing I have noticed was that when a mission compiles it creates a file with an ML extension (it stands for mission lighting) in the missions directory.Have you tried deleting these *.ml files before running your mission?
#5
12/21/2004 (3:01 am)
No - remember as i explained - i did system restore to 2 weeks ago - ad using the file from then when the light pack was still installed. The only reason the performance fix highlighted this situation, was because it was the first time i had try to recompile. For some odd reason, the terrain file from a few weeks ago -works in the application there - but when i try this terrain file in any other version of tge or try to recompile it crashes.
#6
12/21/2004 (6:14 am)
I don't know what to tell you, as I said the Lighting Pack and TGE terrain files are 100% compatible.
#7
Dont know whether this is anything to do with it, but i looked in my console file - and this is what i saw:
Loading Synapse Gaming light datablocks from: starter.fps/server/scripts/sgLights/*.cs
Loading compiled script starter.fps/server/scripts/sgLights/shoresun.cs.
Loading compiled script starter.fps/server/scripts/sgLights/shorelight.cs.
Compiling starter.fps/server/scripts/sgLights/shorelight sunset.cs...
starter.fps/server/scripts/sgLights/shorelight sunset.cs Line: 2 - Syntax error.
>>> Advanced script error report. Line 2.
>>> Some error context, with ## on sides of error halt:
/--- OBJECT WRITE BEGIN ---
datablock sgUniversalStaticLightData(shorelight sunset)## ##{
className = "sgUniversalStaticLightData";
};
//--- OBJECT WRITE END ---
>>> Error report complete.
Executing starter.fps/server/scripts/sgLights/shorelight sunset.cs.
starter.fps/server/scripts/sgLights/shorelight sunset.cs Line: 2 - Syntax error.
>>> Advanced script error report. Line 2.
>>> Some error context, with ## on sides of error halt:
/--- OBJECT WRITE BEGIN ---
datablock sgUniversalStaticLightData(shorelight sunset)## ##{
className = "sgUniversalStaticLightData";
};
thanks
Steve
12/22/2004 (5:26 pm)
Hi,Dont know whether this is anything to do with it, but i looked in my console file - and this is what i saw:
Loading Synapse Gaming light datablocks from: starter.fps/server/scripts/sgLights/*.cs
Loading compiled script starter.fps/server/scripts/sgLights/shoresun.cs.
Loading compiled script starter.fps/server/scripts/sgLights/shorelight.cs.
Compiling starter.fps/server/scripts/sgLights/shorelight sunset.cs...
starter.fps/server/scripts/sgLights/shorelight sunset.cs Line: 2 - Syntax error.
>>> Advanced script error report. Line 2.
>>> Some error context, with ## on sides of error halt:
/--- OBJECT WRITE BEGIN ---
datablock sgUniversalStaticLightData(shorelight sunset)## ##{
className = "sgUniversalStaticLightData";
};
//--- OBJECT WRITE END ---
>>> Error report complete.
Executing starter.fps/server/scripts/sgLights/shorelight sunset.cs.
starter.fps/server/scripts/sgLights/shorelight sunset.cs Line: 2 - Syntax error.
>>> Advanced script error report. Line 2.
>>> Some error context, with ## on sides of error halt:
/--- OBJECT WRITE BEGIN ---
datablock sgUniversalStaticLightData(shorelight sunset)## ##{
className = "sgUniversalStaticLightData";
};
thanks
Steve
#8
I recommend:
-starting with a fresh Lighting Pack 1.3, compile it and make sure it works as expected
-add your art assets checking periodically for problems (don't add the bad terrain file that definitely won't work)
-merge in any script changes you've made checking periodically for problems
-merge in any code changes you've made checking periodically for problems
This will help identify what's happening.
12/23/2004 (10:11 am)
Were those files hand edited?I recommend:
-starting with a fresh Lighting Pack 1.3, compile it and make sure it works as expected
-add your art assets checking periodically for problems (don't add the bad terrain file that definitely won't work)
-merge in any script changes you've made checking periodically for problems
-merge in any code changes you've made checking periodically for problems
This will help identify what's happening.
Torque Owner John Kabus (BobTheCBuilder)