Call of Duty 5: Fixing 2048 materials Assets Error

From COD Modding & Mapping Wiki
Revision as of 18:11, 14 April 2009 by Zeroy (talk | contribs) (New page: Image:nutshell.png Clients usually gets this error but it can also show up on a Server side on map rotation. The solution is for the MAPPER in this article, and some advice for modders...)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search

Clients usually gets this error but it can also show up on a Server side on map rotation. The solution is for the MAPPER in this article, and some advice for modders.

Background on Error

After testing quite extensively we finally discovered the reason as to why only some players with some mods would get the error on mp_506th or other detailed maps.

Note that I say detailed because this only starts to happen when a map uses a total number of materials assets (Textures, Techsets, Probes, FXs..) over 680 (you can check your total using Launcher > BSP Info).



So when a map is detailed you can get easily over 680 materials assets and this combine with materials loaded by the engine as default - Thats all the MP game/hud stuff - you can be near the limit already (the limit is 2048).

There are however a few more factors which tip the balance and trigger the message:

  • The Mod assets: Of course the more materials the mod has the more change you have of triggering the error! At present AWE counts 12 materials, ACE has 11 and X5 has about 16.
  • COD4 assets: yes you heard correctly, Treyarch has left several COD4 materials assets in the rawfile and in the stock .ff so about 25 of them (maybe more) are taken up for no reason!
  • Duplicates: I don't know the origin of this problem yet but a lot of materials are listed in the count 2,3 sometimes 4 times!
  • Loadscreens from other stock/custom maps: This is where the difference is usually as the number of loadscreens materials (along with the thumbnail created - _ig) will varie depending on how many custom maps a user has in his <LocalAppData> Usermaps folder.

Workaround

Mappers

So how to fix it? Couple of things you can do as a mapper:

  • Decals: each time you place one a Techset will be created, a Techset can use 1 or more material files! An excellent workaround is to place your decal (nodraw brush or patch) exactly 0.25Units above the brush/patch its meant to go on.

This is not to be used for terrain in general, just for small decals like posters/grim/signs.

  • Textures:</dont> Dont go mad on textures is probably the best advice here, try and stay at around 180 - 200 textures in use to allow for overhead on the limit. Note that Xmodels/FXs also count as they all use materials, sometimes more than one file!
  • TIP #1: When making a map i suggest placing extra Destructable models in the map (hidden from view) and test with a few mods regularely during mapping, the extra destructables will provide a safety net if you reach the limit - you could then remove them.
  • TIP #2: Always test your map on local server using the main Mods, also tests on a dedicated before release.

Server Admins

Not much you can do, you can have as many maps you wish and it shouldnt make a difference on server.

Players

The only thing you can do is go to your LocalAppData folder, under usermaps and remove any map you arent playing anymore to free up materials when maps are loading.

Note that the IWD in the mods folder do not have any effect at all since they contains the IWI, not the materials.