]> de.git.xonotic.org Git - xonotic/xonotic-data.pk3dir.git/commitdiff
Improve bandwidth of client walls
authorMario <mario@smbclan.net>
Sat, 8 Oct 2016 18:23:36 +0000 (04:23 +1000)
committerMario <mario@smbclan.net>
Sat, 8 Oct 2016 18:23:36 +0000 (04:23 +1000)
qcsrc/client/wall.qc
qcsrc/server/g_models.qc

index 01a86bb1ee44d2490402cac124a41b35c1229715..64916ad8c17d05251f940ed0ae9e02e340ffb8bf 100644 (file)
@@ -213,11 +213,11 @@ NET_HANDLE(ENT_CLIENT_WALL, bool isnew)
                        this.movedir_z = ReadCoord();
                        this.lip = ReadByte() / 255.0;
                }
-               this.fade_start = ReadShort();
-               this.fade_end = ReadShort();
-               this.alpha_max = ReadShort();
-               this.alpha_min = ReadShort();
-               this.inactive = ReadShort();
+               this.fade_start = ReadByte();
+               this.fade_end = ReadByte();
+               this.alpha_max = ReadByte();
+               this.alpha_min = ReadByte();
+               this.inactive = ReadByte();
                this.fade_vertical_offset = ReadShort();
                BGMScript_InitEntity(this);
        }
index 348f307270d84b52c2ab9a6486318a948a81fdaa..58fb26a4ed4a0acd1ed272252e3dbeac39bf7257 100644 (file)
@@ -152,11 +152,11 @@ bool g_clientmodel_genericsendentity(entity this, entity to, int sf)
                        WriteCoord(MSG_ENTITY, this.movedir.z);
                        WriteByte(MSG_ENTITY, floor(this.lip * 255));
                }
-               WriteShort(MSG_ENTITY, this.fade_start);
-               WriteShort(MSG_ENTITY, this.fade_end);
-               WriteShort(MSG_ENTITY, this.alpha_max);
-               WriteShort(MSG_ENTITY, this.alpha_min);
-               WriteShort(MSG_ENTITY, this.inactive);
+               WriteByte(MSG_ENTITY, this.fade_start);
+               WriteByte(MSG_ENTITY, this.fade_end);
+               WriteByte(MSG_ENTITY, this.alpha_max);
+               WriteByte(MSG_ENTITY, this.alpha_min);
+               WriteByte(MSG_ENTITY, this.inactive);
                WriteShort(MSG_ENTITY, this.fade_vertical_offset);
        }