String Table Dictionary

From Valve Developer Community
Jump to: navigation, search
Wikipedia - Letter.png
This article has multiple issues. Please help improve it or discuss these issues on the talk page. (Learn how and when to remove these template messages)
Icon-broom.png
This article or section needs to be cleaned up to conform to a higher standard of quality.
For help, see the VDC Editing Help and Wikipedia cleanup process. Also, remember to check for any notes left by the tagger at this article's talk page.


String tables are used to lower network bandwidth for multiplayer games. It's created automatically when the map is first loaded.

Icon-Important.pngImportant:It is saved into the map file after you leave the map.
Warning.pngWarning:String table cannot be generated if the map is already packed in vpk
Note.pngNote:This page was created considering only Left 4 Dead 2's existence

Making sure string table is created

  1. Load a map that is not packed in vpk
  2. Use stringtabledictionary command
  3. Leave the map
  4. Check the map file last modified timestamp

Example

To get the general idea what they are for let's say we have string table.

Index String
0 Nick
1 Ellis
2 Coach
3 Rochelle

In a case string Rochelle is used what needs to be sent over the network is just the index of this string (3). This is a reason why all connected players need to have identical string table that their game looks into.

ConVars

Cvar/CommandParameters or default valueDescriptorEffect
sv_dumpstringtables0boolDump info about string tables when loading a map
stringtable_alwaysrebuilddictionaries0boolRebuild dictionary file on every level load
stringtable_usedictionaries1boolUse dictionaries for string table networking

ConCommands

Cvar/CommandParameters or default valueDescriptorEffect
dumpgamestringtableDump the contents of the game string table to the console.
dumpstringtablesPrint string tables to console.
stringtabledictionaryCreate dictionary for current strings.

Tables

Table Name Max size
downloadables 8192
modelprecache 2048
genericprecache 512
soundprecache 20000
decalprecache 512
instancebaseline 1024
lightstyles 64
userinfo 32
server_query_info 4
ParticleEffectNames 1024
EffectDispatch 1024
VguiScreen 256
Materials 1024
InfoPanel 128
Scenes 16384
MeleeWeapons 16
GameRulesCreation 1


Stub

This article or section is a stub. You can help by adding to it.