]> git.rm.cloudns.org Git - xonotic/xonotic-data.pk3dir.git/commitdiff
triggers: set bmodel correctly in CSQC
authorbones_was_here <bones_was_here@xonotic.au>
Sat, 26 Aug 2023 11:54:18 +0000 (21:54 +1000)
committerbones_was_here <bones_was_here@xonotic.au>
Sat, 26 Aug 2023 11:54:18 +0000 (21:54 +1000)
Previously the .model field would be (for example) "*2" in SVQC but ""
in CSQC.  This change makes it "*2" in both.

qcsrc/common/mapobjects/triggers.qc

index 5fc5f4f3fb1bea0af0fc09682ab7b6196e857aeb..cfc1d6fac67f6222162c444e665f2dd31133b443 100644 (file)
@@ -205,6 +205,8 @@ void trigger_common_read(entity this, bool withtarget)
                this.angles = '0 0 0';
 
        this.modelindex = ReadShort();
+       if (this.modelindex)
+               setmodelindex(this, this.modelindex);
        this.mins = ReadVector();
        this.maxs = ReadVector();
        this.scale = ReadByte() / 16;