- Use a map for symbol tables instead of an array.

SVN r2258 (scripting)
This commit is contained in:
Randy Heit 2010-03-30 04:11:16 +00:00
commit d87d2c731f
4 changed files with 28 additions and 57 deletions

View file

@ -389,9 +389,12 @@ void DObject::SerializeUserVars(FArchive &arc)
// Write all user variables.
for (; symt != NULL; symt = symt->ParentSymbolTable)
{
for (unsigned i = 0; i < symt->Symbols.Size(); ++i)
PSymbolTable::MapType::Iterator it(symt->Symbols);
PSymbolTable::MapType::Pair *pair;
while (it.NextPair(pair))
{
PSymbol *sym = symt->Symbols[i];
PSymbol *sym = pair->Value;
if (sym->SymbolType == SYM_Variable)
{
PSymbolVariable *var = static_cast<PSymbolVariable *>(sym);