From 247e93b4ffafab5e68761f8522df50a0bfcf797f Mon Sep 17 00:00:00 2001 From: s1lent Date: Wed, 5 Jun 2019 20:08:50 +0700 Subject: [PATCH] Fix work cvar bot_chatter "radio", zbots doesn't send radio command into chat. Wrong ascii conversion. --- regamedll/dlls/bot/cs_bot_radio.cpp | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/regamedll/dlls/bot/cs_bot_radio.cpp b/regamedll/dlls/bot/cs_bot_radio.cpp index 7e27a196..3f5b858b 100644 --- a/regamedll/dlls/bot/cs_bot_radio.cpp +++ b/regamedll/dlls/bot/cs_bot_radio.cpp @@ -326,19 +326,19 @@ void CCSBot::SendRadioMessage(GameEventType event) if (event > EVENT_START_RADIO_1 && event < EVENT_START_RADIO_2) { - slot[0] = event - EVENT_START_RADIO_1; + slot[0] = '0' + event - EVENT_START_RADIO_1; ClientCommand("radio1"); - //Radio1(this, event - EVENT_START_RADIO_3); + //Radio1(this, event - EVENT_START_RADIO_1); } else if (event > EVENT_START_RADIO_2 && event < EVENT_START_RADIO_3) { - slot[0] = event - EVENT_START_RADIO_2; + slot[0] = '0' + event - EVENT_START_RADIO_2; ClientCommand("radio2"); - //Radio2(this, event - EVENT_START_RADIO_3); + //Radio2(this, event - EVENT_START_RADIO_2); } else { - slot[0] = event - EVENT_START_RADIO_3; + slot[0] = '0' + event - EVENT_START_RADIO_3; ClientCommand("radio3"); //Radio3(this, event - EVENT_START_RADIO_3); }