Problems with .bsp file


(stadilainen) #1

At first I couldn’t recieve the .bsp file after compiling, then I deleted some gamemodels (which also LEAKed) and finally could get the .bsp file.
After that I added 2 more rooms, both had some gamemodels in it. Now I cannot get the .bsp file.

The following error came up in Radiant’s last line:

ERROR*
MAX_MAP_LEAFFACES

NOTE:
I am using GTKRadiant 1.4.0.
My map is not very big, and it has an amount of 14 misc_gamemodels and 7 misc_models.
I used BSP -meta for compiling.

Any advice would be more than appreciated.
Thanks in advance.


(kamikazee) #2

Have you set the spawnflag SOLID for the misc_models? This may result in seriously messed up portalling causing a lot of leafs. If they are quit complicated in shape, put a brush with a clip texture around it instead.


(stadilainen) #3

Nope, I actually copied the brushes with clip textures from the original maps.


(stadilainen) #4

Just in general, what does the error MAX_MAP_LEAFFACES mean?
Please answer in English, I am not a rocket scientist :S


(codejockey13) #5

http://www.gamedesign.net/book/print/263

MAX_MAP_LEAFFACES

The map is too big, it exceeds some of Quake 2/qbsp3/qrad3/qvis3’s internal maximums. Simplify, make it smaller, or split it up.

Your map must be huge.


(kamikazee) #6

He needs to simplify his map, or use MORE detail. (Actually, you need to build a good solid hull and make all other stuff detail)
The quake engine uses a void space: only what you create is there.
Solid brushes will split up this huge “virtual” space. First q3map will take that largest brushes. When q3map has split the space into large cubes it will look if there are still solid brushes into that cube. If not, it simply saves that space and calls it a leaf.

Here you probably have too much solid brushes. When pressing CTRL+D in Radiant, all detail gets hidden. Check if all the remaining brushes really should be detail. (aka: if you would make them detail and hide them, they don’t cause your map to leak)

Maps don’t need to be huge to spawn this error, sometimes small brushes so small they allmost cannot be seen, can cause this as well. (such brushes can be caused by using the CGI tools)


(stadilainen) #7

He needs to simplify his map, or use MORE detail. (Actually, you need to build a good solid hull and make all other stuff detail)
The quake engine uses a void space: only what you create is there.
Solid brushes will split up this huge “virtual” space. First q3map will take that largest brushes. When q3map has split the space into large cubes it will look if there are still solid brushes into that cube. If not, it simply saves that space and calls it a leaf.

Here you probably have too much solid brushes. When pressing CTRL+D in Radiant, all detail gets hidden. Check if all the remaining brushes really should be detail. (aka: if you would make them detail and hide them, they don’t cause your map to leak)

Maps don’t need to be huge to spawn this error, sometimes small brushes so small they allmost cannot be seen, can cause this as well. (such brushes can be caused by using the CGI tools)[/quote]Thanks for your reply…
But how do I know which brushes need to be detailed and which don’t?
How will detailing many brushes affect to gamespeed? Will FPS drop radically?

Thanks again.


(kamikazee) #8

Well, if you detail everything possible, FPS will drop significantly as visibility checks will go weird.
Not detailling enough causes higher BSP sizes.

So you quickly see detailling is not an exact science, but must be used somewhat in the midle.
Try to look for brushes that only show detail, like furniture in a room. Walls however will probably remain solid, so the brushes that ‘bound spaces’ should be solid.

You’d better look for a tutorial on how to optimize your map for VIS. Such tutorials should describe portals and detailling as well. I don’t have got any at hand, but there have been links posted on this forum.
“May the search button be with you”.


(stadilainen) #9

I still can’t get the .bsp file…
I tried detailing stuff and removing gamemodels and rooms but it won’t give me the .bsp file.

The only LEAKs I have are some of the gamemodels (I heard this doesn’t matter in most cases) and the rest of the map works just fine.

I am very confused, it’s not like my map is very big, it’s only 9000 kb max.


(kamikazee) #10

You mean 9 MB?
Still, that’s quite a lot. :stuck_out_tongue: (Well, not for a terrain-using map) Anyhow, that doesn’t matter, I’ve done maps that were slightly larger.

Does it still gives you the error you had first? If not, what error occurs now? Q3Map2 allways gives a reason if he won’t complete his task.
You say the map is leaked, there is a difference between entity leaked and map leaked. But where you can get away with “entity leaked”, a map leakage can abort the bsp building.
If it’s the map, you’ve probably “detailed” one of the brushes which define the border of your map. Those won’t stop leaks when being detail.


(stadilainen) #11

In Q3Map Debug Window:
Entity 101, brush 0: Entity leaked (<— this is a gamemodel)
Map is leaked

However, in radiant:
Entity 101, brush 0: Entity leaked
23151 flooded leafs
entity reached from outside - no filling


leaked*


                ---leakfile---

etc.etc.

So as you can see, the debug window says the ‘Map is leaked’ but it informs only about entity leak in radiant.
And yes, still got the MAX_MAP_LEAFFACES -error.


(metho) #12

i don’t know all that much about mapping but i had that error before i had made the sky box around my map detailed and there for the compiler said my map leaked and entitys leaked so i made the sky box solid and it worked fine


(metho) #13

entity reached from outside - no filling


leaked*


this means that the void on the out side of the map is viewable by a player


(stadilainen) #14

I am not using skyboxes, but thanks anyway.


(SCDS_reyalP) #15

MAX_MAP_LEAFFACES is 1048576 in recent versions of q3map2. It could probably be increased at the expense of memory in the compiler.

this http://graphics.stanford.edu/~kekoa/q3/#Leaffaces tells you what they are. Simply, each leafnode in your BSP contains (pointers to) a list of faces which touch it. The leaffaces lump stores all of these lists. So the total number of leaffaces is a product of the number of leafnodes and the number of faces in each node.

It sounds to me like your misc_models are very high poly, and perhaps they touch a bunch of leafs.

I wouldn’t worry about the other errors until you have fixed this one, because it prevents you from creating a valid .bsp file,


(stadilainen) #16

Hehe… It’s funny, but I still do not know what a leafface or a leaf is… Not everyone is a professional.
If anyone here could tell me what to try or do in English I would be really happy. (No, please do not give me a link to a site where it’s explained like this http://graphics.stanford.edu/~kekoa/q3/#Leaffaces
There must be an easier way to tell me what am I doing wrong)


(SCDS_reyalP) #17

I’ll try again

[ul]
[li]The BSP is split into pieces called leafs.
[/li][li]For each leaf, the bsp has a list of the faces that belong to that leaf. *
[/li][li]MAX_MAP_LEAFFACES error means that all of these lists, combined total more than 1 million.
[/li][/ul]
This means that either you have some very complex models with a lot of faces, or your have too many leafs, or both. Note that a face can belong to more than one leaf.

If the problem is too many faces, make your models simpler.
If the problem is too many leafs, learn to use structure and detail. Try searching the forum for that.

  • The leafaces lists do not contain the actual data that defines the leafs. Instead, they are a list of numbers that tell where in the .bsp the actual definition can be found.

(The Wanderer) #18

This is your problem. Copy/paste brushes has been known to cause issues by creating invisible complex brushes or just copying extra stuff that you never selected. You should try to avoid it.
Your map most likely has a lot of brushes outside your skybox that you never even noticed.

Select everything in your map. DO NOT use select all. Instead either draw a brush around your skybox and do select inside or just select your brushes one by one.
Inverse your selection and hit delete. This should erase the bad brushes …although it’s not guaranteed.


(Mark.C) #19

Use the brush cleanup tool, fixed this error for me ages ago :smiley: :blah:


(stadilainen) #20

I tried it ages ago, and it didn’t do the desired :frowning: