]> de.git.xonotic.org Git - xonotic/xonotic-data.pk3dir.git/commitdiff
Use a 24 bit sendflag to allow more wepent props
authorMario <mario@smbclan.net>
Fri, 16 Feb 2018 11:01:25 +0000 (21:01 +1000)
committerMario <mario@smbclan.net>
Fri, 16 Feb 2018 11:01:25 +0000 (21:01 +1000)
qcsrc/common/wepent.qc

index 9335a4788da1e0c2da70a08391826dab7521fec9..e8afba86405e82abc48bde9746ce6ed4ea21af46 100644 (file)
@@ -82,7 +82,7 @@ MACRO_END
                }
                WEPENT_NETPROPS(X);
        #undef X
-               if (i >= BITS(16 - 1)) LOG_FATAL("Exceeded WEPENT_NETPROPS limit");
+               if (i >= BITS(24 - 1)) LOG_FATAL("Exceeded WEPENT_NETPROPS limit");
        }
 
        bool _wepent_send(entity this, entity to, int sf, int chan)
@@ -95,7 +95,7 @@ MACRO_END
                        WriteHeader(chan, CLIENT_WEPENT);
                .entity weaponentity = this.owner.weaponentity_fld;
                WriteByte(chan, weaponslot(weaponentity));
-               WriteShort(chan, sf);
+               WriteInt24_t(chan, sf);
                int i = 0;
                #define X(public, fld, set, sv, cl) { \
                        if (sf & BIT(i)) { \
@@ -164,7 +164,7 @@ MACRO_END
                int slot = ReadByte();
                this.m_wepent_slot = slot;
                viewmodels[slot].m_wepent_slot = slot;
-               int sf = ReadShort();
+               int sf = ReadInt24_t();
                int i = 0;
                #define X(public, fld, set, sv, cl) { \
                        if (sf & BIT(i)) { \