From 64a7eef33573e55c3bc234d10f8c27adebccf039 Mon Sep 17 00:00:00 2001 From: ac-stef Date: Tue, 1 Nov 2016 00:36:19 +0100 Subject: [PATCH] some fixes --- source/src/entities.cpp | 2 +- source/src/tools.cpp | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/source/src/entities.cpp b/source/src/entities.cpp index 27889ba1..cd44c0e9 100644 --- a/source/src/entities.cpp +++ b/source/src/entities.cpp @@ -672,7 +672,7 @@ void entstats_(void) loopi(MAXENTTYPES) if(es.entcnt[i]) switch(i) { case MAPMODEL: conoutf(" %d %s, %d clipped, %s%d unconfigured", es.entcnt[i], entnames[i], clipents, xmodels ? "\f3" : "", xmodels); break; - case SOUND: conoutf(" %d %s, %s%d unconfigured", es.entcnt[i], entnames[i], xsounds ? "\f3" : "", xsounds); + case SOUND: conoutf(" %d %s, %s%d unconfigured", es.entcnt[i], entnames[i], xsounds ? "\f3" : "", xsounds); break; case PLAYERSTART: conoutf(" %d %s, %d CLA, %d RVSF, %d FFA%c \f3unknown %d", es.entcnt[i], entnames[i], es.spawns[0], es.spawns[1], es.spawns[2], es.unknownspawns ? ',' : '\0', es.unknownspawns); break; case CTF_FLAG: conoutf(" %d %s, %d CLA, %d RVSF%c \f3unknown %d", es.entcnt[i], entnames[i], es.flags[0], es.flags[1], es.unknownflags ? ',' : '\0', es.unknownflags); break; case CLIP: diff --git a/source/src/tools.cpp b/source/src/tools.cpp index a36069e4..0a33b620 100644 --- a/source/src/tools.cpp +++ b/source/src/tools.cpp @@ -252,8 +252,8 @@ void calcentitystats(entitystats_s &es, const persistent_entity *pents, int pent if(!pents) { // use regular ents list loopv(ents) _pents.add() = ents[i]; - pents = &_pents[0]; pentsize = _pents.length(); + if(pentsize) pents = &_pents[0]; } #endif memset(&es, 0, sizeof(es));