}\r
\r
.float gurgle_oldstomachload;\r
-void Vore_Gurglesound()\r
+void Vore_GurgleSound()\r
{\r
if(time > self.gurglesound_finished || self.gurgle_oldstomachload != self.stomach_load)\r
{\r
}\r
}\r
\r
-void Vore_Weight_apply(entity e)\r
+void Vore_WeightApply(entity e)\r
{\r
// apply stomach weight that makes you heavier the more you eat\r
// slowing the player is done in cl_physics.qc\r
e.predator.stomach_load += 1;\r
e.predator.regurgitate_prepare = 0;\r
e.predator.spawnshieldtime = 0; // lose spawn shield when we vore\r
- Vore_Weight_apply(e.predator);\r
+ Vore_WeightApply(e.predator);\r
\r
// block firing for a small amount of time, or we'll be firing the next frame after we swallow\r
e.predator.weapon_delay = time + button_delay_time;\r
e.predator.stomach_load -= 1;\r
e.predator.regurgitate_prepare = 0;\r
e.predator.swallow_delay = time + cvar("g_balance_vore_swallow_delay");\r
- Vore_Weight_apply(e.predator);\r
+ Vore_WeightApply(e.predator);\r
\r
// block firing for a small amount of time, or we'll be firing the next frame\r
e.weapon_delay = time + button_delay_time;\r
{\r
// ran when the fulldigest feature is enabled and prey stays inside the stomach after dying\r
\r
- if(e.fakepredator.classname == "player" || e.predator.classname != "player") // already configured\r
+ if(e.fakeprey || e.predator.classname != "player") // already configured\r
return;\r
\r
// this entity is like e.predator but for dead prey, to avoid conflicts\r
e.fakepredator = e.predator;\r
+ e.fakeprey = TRUE;\r
\r
// first release the prey from the predator, as dead prey needs to be attached differently\r
// the predator's stomach load is also decreased, as dead prey doesn't count any more\r
e.predator.stomach_load -= 1;\r
- Vore_Weight_apply(e.predator);\r
+ Vore_WeightApply(e.predator);\r
e.predator = world;\r
\r
// now put our dead prey inside the predator's stomach, but only as an effect\r
\r
// completely remove the dead body\r
e.alpha = -1;\r
- setmodel(e, "");\r
}\r
\r
void Vore_DeadPrey_Detach(entity e)\r
\r
e.fakepredator = world;\r
e.aiment = world;\r
+\r
+ if(!e.deadflag)\r
+ e.fakeprey = FALSE;\r
}\r
\r
void Vore_PreyRelease(entity e)\r
if(self.fakepredator.classname != "player" || self.fakepredator.deadflag != DEAD_NO)\r
Vore_DeadPrey_Detach(self);\r
}\r
- else\r
+ else if(self.predator.classname != "player")\r
Vore_Regurgitate(e);\r
}\r
\r
if(head.predator == self)\r
Vore_PreyRelease(head);\r
}\r
- Vore_Gurglesound(); // stop the gurgling sound\r
+ Vore_GurgleSound(); // stop the gurgling sound\r
}\r
\r
self.stomach_load = self.gravity = 0; // prevents a bug\r
}\r
\r
if(cvar("g_vore_gurglesound"))\r
- Vore_Gurglesound();\r
+ Vore_GurgleSound();\r
\r
// --------------------------------\r
// Code that addresses the prey:\r