Skip to content

Commit

Permalink
Fix Errors On Orangebox Engine Branch
Browse files Browse the repository at this point in the history
  • Loading branch information
caxanga334 committed Apr 3, 2024
1 parent b6e5165 commit 6462f0e
Showing 1 changed file with 28 additions and 0 deletions.
28 changes: 28 additions & 0 deletions extension/bot/tf2/tf2bot_upgrades.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -116,6 +116,8 @@ bool CTF2BotUpgradeManager::CanAffordAnyUpgrade() const
return false;
}

#if SOURCE_ENGINE == SE_TF2

void CTF2BotUpgradeManager::BeginBuyingUpgrades()
{
KeyValues* kvcmd = new KeyValues("MvM_UpgradesBegin");
Expand Down Expand Up @@ -156,6 +158,32 @@ void CTF2BotUpgradeManager::EndBuyingUpgrades()
m_numupgrades = 0;
}

#else

// The orangebox engine branch doesn't have ClientCommandKeyValues
// This code will only run under the TF2 branch so we just do this to avoid compile errors.

void CTF2BotUpgradeManager::BeginBuyingUpgrades()
{
}

void CTF2BotUpgradeManager::BuySingleUpgrade(const int upgradeID, const int itemslot, const int quantity)
{
}

void CTF2BotUpgradeManager::RefundUpgrades()
{
}

void CTF2BotUpgradeManager::EndBuyingUpgrades()
{
}

#endif // SOURCE_ENGINE == SE_TF2




void CTF2BotUpgradeManager::FetchUpgrades()
{
CTeamFortress2Mod::GetTF2Mod()->GetMvMUpgradeManager().CollectUpgradesToBuy(m_tobuylist, m_nextpriority, m_me->GetMyClassType());
Expand Down

0 comments on commit 6462f0e

Please sign in to comment.