Max filesize or maximum size for DIF file?
by John Rockefeller · in Torque Game Engine · 05/11/2006 (7:24 pm) · 12 replies
Hey everyone..
I've been working away at my racing game pretty quietly lately, but I've run into a bit of a snag. I also popped this question on the Cartography Shop's forums but it's more of a Torque related question so I figured I'd repost here. I've searched the forums but there doesn't seem to be any information on this.
I have my entire highway put into one DIF file. It's around 800k in size. It loads the datablocks and objects fine but when it goes to calculate lighting it crashes.
Any idea why? Is it too big for Torque to handle?
Thanks!
PS: This is the last few lines in my console.log
//-----------------------------------------------
Synapse Gaming Lighting Pack
Starting scene lighting...
Starting TGE based scene lighting...
Lighting with light #1 (TGE vector light)...
I've been working away at my racing game pretty quietly lately, but I've run into a bit of a snag. I also popped this question on the Cartography Shop's forums but it's more of a Torque related question so I figured I'd repost here. I've searched the forums but there doesn't seem to be any information on this.
I have my entire highway put into one DIF file. It's around 800k in size. It loads the datablocks and objects fine but when it goes to calculate lighting it crashes.
Any idea why? Is it too big for Torque to handle?
Thanks!
PS: This is the last few lines in my console.log
//-----------------------------------------------
Synapse Gaming Lighting Pack
Starting scene lighting...
Starting TGE based scene lighting...
Lighting with light #1 (TGE vector light)...
About the author
Web developer from Guelph, Ontario, Canada.
#2
05/12/2006 (4:55 pm)
Definatly NOT too big for Torque to handle. I've been handling interiors of over 3 megabytes worth without any problems.
#3
05/12/2006 (4:57 pm)
The original CS file? I can give you the .map it exports and also the 3d world studio file I saved it as if needed.
#4
good luck
05/13/2006 (12:14 pm)
John, try to load the DIF file using DEBUG version of TGE. Very possible that on crash it will tell you what exactly is a problem.good luck
#5
Generally its not a good idea to have a huge (as in long) dif. Try breaking the dif into several highway segments and I bet your problem goes away. This will also allow you to have LOD for highway segments that are far away instead of the engine try to render all of the highway all of the time. You might not have trouble if the dif has portals, but I am assuming being its a highway its not.
05/13/2006 (1:44 pm)
I am not sure if this is why the engine is crashing, but the following jumped out at me:Quote:
I have my entire highway put into one DIF file.
Generally its not a good idea to have a huge (as in long) dif. Try breaking the dif into several highway segments and I bet your problem goes away. This will also allow you to have LOD for highway segments that are far away instead of the engine try to render all of the highway all of the time. You might not have trouble if the dif has portals, but I am assuming being its a highway its not.
#6
05/13/2006 (4:20 pm)
Still, 800kb for a DIF is nothing.
#7
05/13/2006 (5:48 pm)
I believe people have had trouble with superlong .difs before though, so definitely try to break it up.
#8
05/13/2006 (10:59 pm)
I don't think it's the size as much as it is complex geometry/shadows.
#9
Backup your mission .MIS file that you're having trouble with, go in and manually edit it, removing lights. Work backwards towards when you know it worked ok. I've had this happen before, just some light doesn't want to light the geometry right and so it just hangs. Once it loads, you can usually reintroduce your lights pretty much the same way you had them. See if that fixes it. I don't think it's size or complexity, I have some levels that have both and no problems.
- Alan
05/14/2006 (12:58 am)
@JohnBackup your mission .MIS file that you're having trouble with, go in and manually edit it, removing lights. Work backwards towards when you know it worked ok. I've had this happen before, just some light doesn't want to light the geometry right and so it just hangs. Once it loads, you can usually reintroduce your lights pretty much the same way you had them. See if that fixes it. I don't think it's size or complexity, I have some levels that have both and no problems.
- Alan
#10
I actually solved the problem with some advice from the 3D World Studio forums. I used the slice tool and sliced all of the brushes in my map. This will probably slow the framerate down a little because there are more polys (or does it? dun dun dunnnn) but at least it runs :)
I guess you can't have a rediculously huge long straightaway with only one box, you've got to split it up.
John
05/14/2006 (5:59 am)
This is all awesome advice. I'm sure as soon as constructor comes out this thread will be read a zillion times.I actually solved the problem with some advice from the 3D World Studio forums. I used the slice tool and sliced all of the brushes in my map. This will probably slow the framerate down a little because there are more polys (or does it? dun dun dunnnn) but at least it runs :)
I guess you can't have a rediculously huge long straightaway with only one box, you've got to split it up.
John
#11
05/14/2006 (6:14 am)
Glad you got it working.
#12
05/16/2006 (11:22 am)
I ran into this before too, the issue was that each face had a max size it could be. I forget the number (1024 maybe?) but anything larger I had to break up into multiple blocks or the calculations failed. But it could all fit in the same dif without issues.
Torque Owner PJjerry