aim: added optional hitbox-based aiming for bots (ref #579)
This commit is contained in:
parent
87cbd144c2
commit
8dece62df6
6 changed files with 264 additions and 3 deletions
|
|
@ -1229,6 +1229,9 @@ Bot::Bot (edict_t *bot, int difficulty, int personality, int team, int skin) {
|
|||
// init async planner
|
||||
m_planner = cr::makeUnique <AStarAlgo> (graph.length ());
|
||||
|
||||
// init player models parts enumerator
|
||||
m_hitboxEnumerator = cr::makeUnique <PlayerHitboxEnumerator> ();
|
||||
|
||||
// bot is not kicked by rotation
|
||||
m_kickedByRotation = false;
|
||||
|
||||
|
|
@ -1241,7 +1244,6 @@ Bot::Bot (edict_t *bot, int difficulty, int personality, int team, int skin) {
|
|||
newRound ();
|
||||
}
|
||||
|
||||
|
||||
void Bot::clearAmmoInfo () {
|
||||
plat.bzero (&m_ammoInClip, sizeof (m_ammoInClip));
|
||||
plat.bzero (&m_ammo, sizeof (m_ammo));
|
||||
|
|
@ -1545,6 +1547,7 @@ void Bot::newRound () {
|
|||
m_followWaitTime = 0.0f;
|
||||
|
||||
m_hostages.clear ();
|
||||
m_hitboxEnumerator->reset ();
|
||||
|
||||
m_approachingLadderTimer.invalidate ();
|
||||
m_forgetLastVictimTimer.invalidate ();
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue