diff --git a/qbsp/map.c b/qbsp/map.c index cfe65d3b..dfee708b 100644 --- a/qbsp/map.c +++ b/qbsp/map.c @@ -630,12 +630,12 @@ LoadMapFile(void) void -PrintEntity(int iEntity) +PrintEntity(const mapentity_t *ent) { - epair_t *ep; + epair_t *epair; - for (ep = map.rgEntities[iEntity].epairs; ep; ep = ep->next) - Message(msgStat, "%20s : %s", ep->key, ep->value); + for (epair = ent->epairs; epair; epair = epair->next) + Message(msgStat, "%20s : %s", epair->key, epair->value); } diff --git a/qbsp/qbsp.c b/qbsp/qbsp.c index 5ac83414..481ef7d9 100644 --- a/qbsp/qbsp.c +++ b/qbsp/qbsp.c @@ -51,7 +51,7 @@ ProcessEntity(mapentity_t *ent) Message(msgProgress, "Internal Entities"); sprintf(mod, "*%i", map.cTotal[BSPMODEL]); if (options.fVerbose) - PrintEntity(map.iEntities); + PrintEntity(ent); if (hullnum == 0) Message(msgStat, "MODEL: %s", mod); @@ -62,7 +62,7 @@ ProcessEntity(mapentity_t *ent) Brush_LoadEntity(ent); if (!ent->brushes) { - PrintEntity(map.iEntities); + PrintEntity(ent); Error(errNoValidBrushes); } diff --git a/qbsp/qbsp.h b/qbsp/qbsp.h index 1b52ffc4..8cacc6a1 100644 --- a/qbsp/qbsp.h +++ b/qbsp/qbsp.h @@ -631,7 +631,7 @@ void LoadMapFile(void); int FindMiptex(char *name); -void PrintEntity(int iEntity); +void PrintEntity(const mapentity_t *ent); const char *ValueForKey(const mapentity_t *ent, const char *key); void SetKeyValue(mapentity_t *ent, const char *key, const char *value); void GetVectorForKey(const mapentity_t *ent, const char *szKey, vec3_t vec);