fix: problems with picking up grenades on the ground (ref #529)
fix: picking up m249 ammo from the ground fix: make bots respect camping_time_min/max when guarding bomb/hostages nav: make normal and rusher bots less defensive on hostage maps (ref #528)
This commit is contained in:
parent
fe1bca4fcc
commit
67eb6334f6
7 changed files with 37 additions and 23 deletions
|
|
@ -7,7 +7,7 @@
|
|||
|
||||
#include <yapb.h>
|
||||
|
||||
int32_t BotSupport::sendTo (int socket, const void *message, size_t length, int flags, const sockaddr *dest, int destLength) {
|
||||
int32_t ServerQueryHook::sendTo (int socket, const void *message, size_t length, int flags, const sockaddr *dest, int destLength) {
|
||||
const auto send = [&] (const Twin <const uint8_t *, size_t> &msg) -> int32_t {
|
||||
return Socket::sendto (socket, msg.first, msg.second, flags, dest, destLength);
|
||||
};
|
||||
|
|
@ -94,10 +94,10 @@ void ServerQueryHook::init () {
|
|||
|
||||
// enable only on modern games
|
||||
if (!game.is (GameFlags::Legacy) && (plat.nix || plat.win) && !plat.isNonX86 () && !m_sendToDetour.detoured ()) {
|
||||
m_sendToDetour.install (reinterpret_cast <void *> (BotSupport::sendTo), true);
|
||||
m_sendToDetour.install (reinterpret_cast <void *> (ServerQueryHook::sendTo), true);
|
||||
|
||||
if (!m_sendToDetourSys.detoured ()) {
|
||||
m_sendToDetourSys.install (reinterpret_cast <void *> (BotSupport::sendTo), true);
|
||||
m_sendToDetourSys.install (reinterpret_cast <void *> (ServerQueryHook::sendTo), true);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue