// Prey bot behavior:
// --------------------------------
- // all we can do in the stomach is kick and do some damage / try to escape
+ // all we can do in the stomach is kick and do some damage / try to escape, or leave if the circumstances allow it and we should
if(self.eater.classname == "player" && time > self.decide_delay2)
- if not(teams_matter && self.team == self.eater.team)
{
- // the higher the skill, the more the bot will kick in your stomack
- if(skill >= random_try)
- if not(teams_matter && prey.team == self.team) // if someone from the same team somehow made it in the belly, don't kick the eater
- self.BUTTON_ATCK = TRUE; // kick
+ if not(teams_matter && self.team == self.eater.team)
+ {
+ // the higher the skill, the more the bot will kick in your stomack
+ if(skill >= random_try)
+ if not(teams_matter && prey.team == self.team) // if someone from the same team somehow made it in the belly, don't kick the eater
+ self.BUTTON_ATCK = TRUE; // kick
+ }
+
+ // if a bot can willingly leave the predator, do so unless there's a reason not to
+ if(self.stat_canleave)
+ if not(teams_matter && self.team == self.eater.team && cvar("g_balance_vore_teamheal") && self.health < cvar("g_balance_vore_teamheal_stable")) // we are being team healed, don't leave
+ self.BUTTON_JUMP = TRUE;
self.decide_delay2 = time + decide_prey; // time before the bot decides what to do with their predator
}