[DiscordArchive] I'd double check the dbc files.
[DiscordArchive] I'd double check the dbc files.
Archived author: Honey • Posted: 2024-09-26T20:14:32.844000+00:00
Original source
I'd double check the dbc files.
Can you open them with an dbc editor?
tring dbcFilename = dbcPath + filename;
tring localizedName(dbcPath);
tring buf = stream.str();Archived author: bhr • Posted: 2024-09-26T20:14:36.774000+00:00
Original source
```c++
// compatibility format and C++ structure sizes
ASSERT(DBCFileLoader::GetFormatRecordSize(storage.GetFormat()) == sizeof(T) || LoadDBC_assert_print(DBCFileLoader::GetFormatRecordSize(storage.GetFormat()), sizeof(T), filename));
++DBCFileCount;
std:
tring dbcFilename = dbcPath + filename;
bool existDBData = false;
if (storage.Load(dbcFilename.c_str()))
{
for (uint8 i = 0; i < TOTAL_LOCALES; ++i)
{
if (!(availableDbcLocales & (1 << i)))
continue;
std:
tring localizedName(dbcPath);
localizedName.append(localeNames[i]);
localizedName.push_back('/');
localizedName.append(filename);
if (!storage.LoadStringsFrom(localizedName.c_str()))
availableDbcLocales &= ~(1 << i); // mark as not available for speedup next checks
}
}
if (dbTable)
storage.LoadFromDB(dbTable, storage.GetFormat());
if (storage.GetNumRows())
existDBData = true;
if (!existDBData)
{
// sort problematic dbc to (1) non compatible and (2) non-existed
if (FILE* f = fopen(dbcFilename.c_str(), "rb"))
{
std::ostringstream stream;
stream << dbcFilename << " exists, and has " << storage.GetFieldCount() << " field(s) (expected " << strlen(storage.GetFormat()) << "). Extracted file might be from wrong client version or a database-update has been forgotten.";
std:
tring buf = stream.str();
errors.push_back(buf);
fclose(f);
}
else
errors.push_back(dbcFilename);
}
```
Archived author: bhr • Posted: 2024-09-26T20:14:41.787000+00:00
Original source
good question i have no idea