]> git.rm.cloudns.org Git - voretournament/voretournament.git/commitdiff
Base it on skill
authorMirceaKitsune <sonichedgehog_hyperblast00@yahoo.com>
Tue, 7 Sep 2010 23:37:04 +0000 (02:37 +0300)
committerMirceaKitsune <sonichedgehog_hyperblast00@yahoo.com>
Tue, 7 Sep 2010 23:37:04 +0000 (02:37 +0300)
data/defaultVoretournament.cfg
data/qcsrc/server/bot/havocbot/vore_ai.qc

index cb81b7d9bac6aa6b1760b96f11d813a0e34dd68d..c00a222a30446fac3c45498acf8c2259e07824b5 100644 (file)
@@ -351,7 +351,7 @@ set bot_ai_bunnyhop_firstjumpdelay 0.5 "Start running to the goal only if it was
 set bot_ai_vore_decide_pred 4 "How fast bots decide what to do with their prey, at lowest skill"\r
 set bot_ai_vore_decide_prey 4 "How fast bots decide what to do with their predator, at lowest skill"\r
 set bot_ai_vore_decide_fear 2 "How much bots will fear players more powerful than them, and therefore avoid them in some situations"\r
-set bot_ai_vore_decide_teamhealabandon 0.5 "Probability (from 0 to 1) of bot stopping a team heal when seeing a foe that they can vore"\r
+set bot_ai_vore_decide_teamhealabandon 0.5 "Probability (from 0 to 1) of the bot stopping a team heal when seeing a foe that they can vore, at lowest skill"\r
 set bot_god 0 "god mode for bots"\r
 set bot_ai_navigation_jetpack 0 "Enable bots to navigat maps using the jetpack"\r
 set bot_ai_navigation_jetpack_mindistance 3500 "Bots will try fly to objects located farther than this distance"\r
index e4138c50e9bdac7fb22bc04b89da31e4d882a579..11ef8380c6952eb74300e4c62c903035756e1d30 100644 (file)
@@ -32,10 +32,11 @@ void Vore_AI_Teamheal(entity prey)
 
        // if a teamheal is ongoing, decide whether or not to abandon it when seeing a foe that we can attack instead
        // this only causes the bot to regurgitate their team mate when seeing an enemy, with the hope that this enemy will still be there once we can swallow again
+       // the higher the skill, the greater the chance a bot will abandon a team heal for an enemy
        if(self.status_teamhealing > 1)
        if(Swallow_condition_check_bot(prey))
        if(prey.team != self.team)
-       if(random() < cvar("bot_ai_vore_decide_teamhealabandon"))
+       if(random() * 10 < cvar("bot_ai_vore_decide_teamhealabandon") * skill) // there are 10 bot skill steps
                self.BUTTON_REGURGITATE = TRUE; // release the team mate
 
        entity head;