From: Mario Date: Fri, 29 May 2020 08:26:39 +0000 (+1000) Subject: Fix type checking against PlayerState (owner is the client entity) X-Git-Url: https://git.rm.cloudns.org/?a=commitdiff_plain;h=ec8814914691876d017a9758c8f22a4d47540478;p=xonotic%2Fxonotic-data.pk3dir.git Fix type checking against PlayerState (owner is the client entity) --- diff --git a/qcsrc/lib/stats.qh b/qcsrc/lib/stats.qh index 39a375351b..06c168ba45 100644 --- a/qcsrc/lib/stats.qh +++ b/qcsrc/lib/stats.qh @@ -99,8 +99,8 @@ STATIC_INIT(Stats_renumber) { FOREACH(Stats, true, it.m_id = i); } REGISTER_NET_LINKED(ENT_CLIENT_STATS) -const int Stats_groups_minor = 24; -const int Stats_groups_major = 11; // ceil(Stats_MAX / Stats_groups_minor) +const int Stats_groups_minor = 12; +const int Stats_groups_major = 22; // ceil(Stats_MAX / Stats_groups_minor) #define G_MAJOR(id) (floor((id) / Stats_groups_minor)) #define G_MINOR(id) ((id) % Stats_groups_minor) @@ -180,7 +180,7 @@ bool Stats_Send(entity this, entity to, int sf) { TC(entity, this); WriteHeader(MSG_ENTITY, ENT_CLIENT_STATS); - TC(PlayerState, this.owner); + TC(entity, this.owner); Stats_Write(this); return true; }