Map Crashing for Unknown Reason

I know this is for TF2 but I thought you might be able to help as it's still a source/hammer question. I am making a CS:GO map and it keeps crashing people who download it. It seems very random, I have friends on different versions of windows and it seems to run fine regardless, but for some, it just crashes without any error message as to why, no matter if they have an excellent PC as well. I made a thread on steam but didn't get any responses that helped me solve this. I'll post the log file of the last compile below, but my hypothesis is that this error:
"DRASTIC MEMORY OVERFLOW: Fell out of small block heap!"
is related to what the root of the issue. Beyond that when I use VIDE to pak in the custom models and textures CS no longer acknowledges the BSP as valid. Quite frustrating as I've been trying to fix this for over a month, but I haven't given up. I really want to fix this so if you know what the issue is or what might be causing the problem please let me know.

Some errors that I have gotten in the past include Engine error in Lump 7 and micro brushes. Lump 7 errors seem to happen randomly after using VIDE (something to do with texture data) and I have since deleted the micro brushes but I'm not sure if these problems have any persistence in a way I can't see right now. I have no clue how the micro brushes got added.

*If you have time to help and need a better look I have a drop box with all the map files and custom models/textures. I also have multiple versions of the map, but the issue seems to persist through all of them. Although the "Drastic Memory overflow error" began occurring after version 5, there are 15 versions total atm.

I'm not sure if this is some type of hammer brush error or a VIDE problem. I will say that when the map was considerably smaller pakrat and VIDE added the files just fine, once it grew to a certain size, I specifically recall when adding models pakrat stopped working, and I could never test the VIDE version because of the crashing.

Thanks for your response. The map crashes on load and after VIDE CS says the BSP doesn't exist. And I do have quite a few teleports and a large number props. I didn't know collision could such a drastic error. I also have a decent number of displacements, however all of power 2 or 3. This type of error would lead me to believe that map would crash for all people, but it runs for some. Check for problems comes up with many unused spawn flags and unused key values. I don't know if this is really an issue to worry about, I assumed unwanted flags/key values are meant to be left unchecked. Now that you brought up entity edicts I found this line in the logs.

"entdata [variable] 575544/393216 (146.4%) VERY FULL!"

Could this be why some people can load the map and some can't? Are they running out of main memory? That would make sense. If I cut back on the entities perhaps it will go away. Let me know if this sounds like the culprit.

The entdata chunk "limit" is just a suggestion. What it does correlate with is however running into the entdict limit. The engine has a limit on how many entities it can track at the same time. Badness happens when you hit the limit.

The only guy who cares about the difference between a material and a texture.

You can list entities on csgo by loading the map, type sv_cheats 1 to console and then cl_showents. CSGO is more picky about the entity counts than TF2 is but if you have more than 500 in use (2 csgo maps that i did use about 350-400), it could be a sign of having too many entities, as well as your entity data. I dont know the hard limit for CSGO entities, but previously entity heavy maps have been crashing.

Though i suspect that your issue is somewhere in the entity logic. Try compiling without any entities, see if it crashes. Sometimes having lots of stuff rendering on the same time (LOTS visible and large map) can cause crashing but thats also rare.

So I just tried a few things. I ran the cl_showents command in csgo. There are 880 entities with one player in the game. Funny enough after this I compiled with no entities (except for a single T spawn) and I still got the memory overflow error. Also the map is all inside. I can't see it being unable to render everything. The most the game will ever have to render is a room with a door or two to another room. I have a decent number of logic entities, is there any easy way to check for the logic errors you're talking about? Here are some more compile logs of different version of the map I tested:

I had one of my friends (who was having the crashing issues) test both Limited entity versions and he crashed on the version with no brush entities but was able to run the version with no entities. Does this sure up what the problem is any or could it still be a logical error? Tell me what you think of these latest tests.

Ok So I just spoke to a fellow CSGO map maker and he just so happens to have just released a map with the exact same percentage of entdata: 146%. The map doesn't have any sort of crashing errors. This narrows the search to your logic related hypothesis. Any ideas on the best way to pinpoint it?

Ok So I just spoke to a fellow CSGO map maker and he just so happens to have just released a map with the exact same percentage of entdata: 146%. The map doesn't have any sort of crashing errors. This narrows the search to your logic related hypothesis. Any ideas on the best way to pinpoint it?

Click to expand...

That entdata number doesn't mean much. It can be indicative of a problem, but really you need to check in game to be sure.

To elaborate, the entdata chunk contains keyvalue definitions for all entities and their I/O connections. More entities naturally lead to a larger chunk. But all entities aren't equal. Some consume more endicts than others. Some don't consume any at all! And entities with a lot of I/O consume more space without costing any more entdicts than the same entity class without I/O.

TL;DR: Entdata has a fuzzy link to the entdict consumption.

Thanks x 1

The only guy who cares about the difference between a material and a texture.

Do you have any idea why it crashes some people but not others? That seems to me, to be the most confusing. If there were one issue that is causing it, why can some people run it but others crash? And how does it connect with VIDE? I ran the entity report commands and got this:
Total 730 entities (0 empty, 701 edicts)
Running around the map the only meter that went up and down was dynamic prop, but it never went past about 75%. Double checking all the I/Os they all checked out. The only thing marked in red was a "ModifySpeed" Parameter Override for a Player_speedmod but I'm pretty sure it's supposed to be in red.
This is what the game says after I use VIDE:
CModelLoader::Map_IsValid: No such map 'maps\seek_luftengsschacht15.bsp'
map load failed: seek_luftengsschacht15 not found or invalid

I would think that maybe there is a size limit where maps become too big and are thus no longer valid but I know of maps nearly 1 GB. The regular BSP works but after using VIDE the lumps become corrupt or what?

That sounds similar to errors I get every once and a while, where the compile failed to load the bsp due to a fatal error, and loads an old version of the map, often a VERY old version. I don't think this is the same error (if changes you make appear in game), but it may be similar, and may be worth checking out. I am sorry I can't tell you what caused my problems, because I am still confused, and have no idea how I fixed it, but the error would have to be something fairly game breaking, maybe unrelated to the symptoms.

I have no words besides "Eeeeeeeeeee!" which, technically, is just a letter. BUT STILL. --Ixy 2019

Update: I've released a test version and have gotten more people to test the map. It turns out the reason many people were crashing was that they were installing the custom files incorrectly. Once I helped them install the files properly it seems to be running fine for everyone. This leads me to believe that the only problem is VIDE not creating a BSP that works with all the files paked in. Maybe you know what might be causing any problems with VIDE. Let me know and thanks again!