]> de.git.xonotic.org Git - voretournament/voretournament.git/blobdiff - data/qcsrc/server/vore.qc
Cvar the distance by which prey are separated in the stomach. Setting the cvar to...
[voretournament/voretournament.git] / data / qcsrc / server / vore.qc
index e0abddd907ca019de2f916b7dfac822484310445..b44e6ec478c2af571a4c0e630f8bcc3d211c5483 100644 (file)
@@ -109,9 +109,9 @@ void Vore_SetCamera()
        makevectors(self.v_angle);\r
        v_forward_z = 0;\r
 \r
-       // In order to allow prey to see each other in the same stomach, we must position each occupant differently,\r
+       // In order to allow prey to see each other in the stomach, we must position each occupant differently,\r
        // else all players would overlap in the center. To do this, we run a loop on all players in the same stomach.\r
-       // For each player, the origin is updated, then a new origin is used for the next player and so on.\r
+       // For each player, the origin is updated, then a new origin is used for the next player.\r
        // This requires that no more than 9 players can be in a stomach at a time!\r
        FOR_EACH_PLAYER(head)\r
        {\r
@@ -149,7 +149,8 @@ void Vore_SetCamera()
                                default:\r
                                        break;\r
                        }\r
-                       head.view_ofs = PL_PREY_VIEW_OFS + (v_forward + origin_apply * 16);\r
+                       // since prey have their predators set as an aiment, view_ofs will specify the real origin of prey, not just the view offset\r
+                       head.view_ofs = PL_PREY_VIEW_OFS + (v_forward + origin_apply * cvar("g_vore_preydistance"));\r
                        position_counter += 1;\r
                }\r
        }\r