]> git.rm.cloudns.org Git - xonotic/xonotic-data.pk3dir.git/commitdiff
Don't link mover controllers to the world, should improve performance a little
authorterencehill <piuntn@gmail.com>
Sat, 5 Nov 2022 17:33:50 +0000 (18:33 +0100)
committerterencehill <piuntn@gmail.com>
Sat, 5 Nov 2022 17:33:50 +0000 (18:33 +0100)
qcsrc/common/mapobjects/subs.qc

index c0b137404c55956d1fa509f697a23e1452c6676e..39573a4823676a0bab8e48e9a57844dc8c5f767f 100644 (file)
@@ -169,7 +169,8 @@ void SUB_CalcMove_controller_setbezier (entity controller, vector org, vector co
        // 2 * control * t - 2 * control * t * t + destin * t * t
        // 2 * control * t + (destin - 2 * control) * t * t
 
-       setorigin(controller, org);
+       //setorigin(controller, org); // don't link to the world
+       controller.origin = org;
        control -= org;
        destin -= org;
 
@@ -184,7 +185,8 @@ void SUB_CalcMove_controller_setlinear (entity controller, vector org, vector de
        // 2 * control * t - 2 * control * t * t + destin * t * t
        // 2 * control * t + (destin - 2 * control) * t * t
 
-       setorigin(controller, org);
+       //setorigin(controller, org); // don't link to the world
+       controller.origin = org;
        destin -= org;
 
        controller.destvec = destin; // end point