fix: bots can't plant bomb on multi-scenario maps (fix #537)
This commit is contained in:
parent
61407341a0
commit
c03d8ac790
3 changed files with 462 additions and 460 deletions
2
.gitattributes
vendored
2
.gitattributes
vendored
|
|
@ -1,5 +1,5 @@
|
|||
# Auto detect text files and perform LF normalization
|
||||
* text=auto
|
||||
* text=lf
|
||||
|
||||
# Custom for Visual Studio
|
||||
*.sln merge=union
|
||||
|
|
|
|||
|
|
@ -182,7 +182,7 @@ void Bot::normal_ () {
|
|||
m_hostages.clear ();
|
||||
}
|
||||
}
|
||||
else if (m_team == Team::Terrorist && rg.chance (75)) {
|
||||
else if (m_team == Team::Terrorist && rg.chance (75) && !game.mapIs (MapFlags::Demolition)) {
|
||||
const int index = findDefendNode (m_path->origin);
|
||||
|
||||
startTask (Task::Camp, TaskPri::Camp, kInvalidNodeIndex, game.time () + rg.get (60.0f, 120.0f), true); // push camp task on to stack
|
||||
|
|
@ -193,7 +193,9 @@ void Bot::normal_ () {
|
|||
pushChatterMessage (Chatter::GoingToGuardVIPSafety); // play info about that
|
||||
}
|
||||
}
|
||||
else if (game.mapIs (MapFlags::Demolition) && ((m_pathFlags & NodeFlag::Goal) && m_inBombZone)) {
|
||||
|
||||
// was elseif here but brokes csde_ scenario
|
||||
if (game.mapIs (MapFlags::Demolition) && (m_pathFlags & NodeFlag::Goal) && m_inBombZone) {
|
||||
// is it a terrorist carrying the bomb?
|
||||
if (m_hasC4) {
|
||||
if ((m_states & Sense::SeeingEnemy) && numFriendsNear (pev->origin, 768.0f) == 0) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue