void Cl_ResetTransTables() { if (serverMaterials) { delete serverMaterials; serverMaterials = 0; } xlatMobjType.clear(); xlatMobjState.clear(); }
void Cl_ResetTransTables() { if(serverMaterials) { MaterialArchive_Delete(serverMaterials); serverMaterials = 0; } xlatMobjType.clear(); xlatMobjState.clear(); }
void Cl_ReadServerMobjTypeIDs() { LOG_AS("Cl_ReadServerMobjTypeIDs"); StringArray *ar = StringArray_New(); StringArray_Read(ar, msgReader); LOGDEV_NET_VERBOSE("Received %i mobj type IDs") << StringArray_Size(ar); xlatMobjType.resize(StringArray_Size(ar)); // Translate the type IDs to local. for (dint i = 0; i < StringArray_Size(ar); ++i) { xlatMobjType[i] = DED_Definitions()->getMobjNum(StringArray_At(ar, i)); if (xlatMobjType[i] < 0) { LOG_NET_WARNING("Could not find '%s' in local thing definitions") << StringArray_At(ar, i); } } StringArray_Delete(ar); }
void Cl_InitTransTables() { serverMaterials = 0; xlatMobjType.clear(); xlatMobjState.clear(); }
int Cl_LocalMobjState(int serverMobjState) { if (serverMobjState < 0 || serverMobjState >= xlatMobjState.size()) return 0; // Invalid state. return xlatMobjState[serverMobjState]; }
int Cl_LocalMobjType(int serverMobjType) { if (serverMobjType < 0 || serverMobjType >= xlatMobjType.size()) return 0; // Invalid type. return xlatMobjType[serverMobjType]; }