From 7bf8abe917c6de7b7bd70fa876d00841ae4789af Mon Sep 17 00:00:00 2001 From: Lierrmm Date: Mon, 27 Feb 2023 10:46:44 +0000 Subject: [PATCH] feat: check client state before spawning bots --- src/client/component/bots.cpp | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/src/client/component/bots.cpp b/src/client/component/bots.cpp index 6d99ecf8..43f2a6e7 100644 --- a/src/client/component/bots.cpp +++ b/src/client/component/bots.cpp @@ -126,6 +126,15 @@ namespace bots command::add("spawnBot", [](const command::params& params) { + if (!game::is_server()) + { + const auto client_states = *reinterpret_cast(0x1576FB318_g); + if (!client_states) + { + return; + } + } + size_t count = 1; if (params.size() > 1) {