diff --git a/src/hacks/FollowBot.cpp b/src/hacks/FollowBot.cpp index 878f0b32..898f292e 100644 --- a/src/hacks/FollowBot.cpp +++ b/src/hacks/FollowBot.cpp @@ -247,13 +247,13 @@ void DoWalking() { // If the local player is a medic and user settings allow, then keep the medigun out if (g_pLocalPlayer->clazz == tf_medic && always_medigun) { if (my_slot != 1) { - g_IEngine->ExecuteClientCmd("slot2"); + g_pUserCmd->weaponselect = 1; } // Else we attemt to keep our weapon mimiced with our follow target } else { if (my_slot != owner_slot) { - g_IEngine->ExecuteClientCmd(format("slot", owner_slot + 1).c_str()); + g_pUserCmd->weaponselect = owner_slot; } } } diff --git a/src/hacks/Walkbot.cpp b/src/hacks/Walkbot.cpp index bd12d78e..df73fb78 100644 --- a/src/hacks/Walkbot.cpp +++ b/src/hacks/Walkbot.cpp @@ -698,7 +698,7 @@ void UpdateSlot() { if (vfunc(weapon, 190, 0)(weapon)) { int slot = vfunc(weapon, 395, 0)(weapon); if (slot != int(force_slot) - 1) { - hack::ExecuteCommand(format("slot", int(force_slot))); + g_pUserCmd->weaponselect = int(force_slot) - 1; } } }