SmileYzn / MatchBot

Counter-Strike 1.6 Match Plugin for ReHLDS and ReGameDLL_CS
GNU General Public License v3.0
28 stars 14 forks source link

No commands are registered, printed as chat #103

Closed that-is-not-great closed 8 months ago

that-is-not-great commented 9 months ago

Compiled a71a8b9 and its running, but no commands are registered. Example .ready or !menu is printed as chat. Tested with non-admin and admin player.

meta list
Currently loaded plugins:
      description      stat pend  file                    vers      src  load  unload
 [ 1] SafeNameAndChat  RUN   -    SafeNameAndChat_1.1.so  v1.1      ini  ANY   ANY  
 [ 2] Reunion          RUN   -    reunion_mm_i386.so      v0.1.92d  ini  Start Never
 [ 3] ReAuthCheck      RUN   -    reauthcheck_mm_i386.so  v0.1.6    ini  Start Never
 [ 4] Match Bot        RUN   -    matchbot_mm.so          v1.0.0    ini  ANY   ANY  
 [ 5] HitBox Fix       RUN   -    hitbox_fix_mm_i386.so   v1.1.4    ini  Start ANY  
 [ 6] Accuracy Fix     RUN   -    accuracyfix_mm.so       v1.0.2    ini  ANY   ANY  
6 plugins, 6 running
bool CMatchCommand::ClientCommand(CBasePlayer* Player, const char* pcmd, const char* parg1)
{
    LOG_CONSOLE(PLID, "cmd");
    gMatchUtil.SayText(Player->edict(), PRINT_TEAM_DEFAULT, _T("cmd"));

I tried this simple debug but cmd is never logged as well

SmileYzn commented 9 months ago

Did you put it in command hook system or just created function on CPP?

Em sex., 1 de dez. de 2023 11:33, Ken Hotate @.***> escreveu:

Assigned #103 https://github.com/SmileYzn/MatchBot/issues/103 to @SmileYzn https://github.com/SmileYzn.

— Reply to this email directly, view it on GitHub https://github.com/SmileYzn/MatchBot/issues/103#event-11122905108, or unsubscribe https://github.com/notifications/unsubscribe-auth/ABMUVS27BSJSFHQZFSNDCHLYHHTCNAVCNFSM6AAAAABAC5Z54KVHI2DSMVQWIX3LMV45UABCJFZXG5LFIV3GK3TUJZXXI2LGNFRWC5DJN5XDWMJRGEZDEOJQGUYTAOA . You are receiving this because you were assigned.Message ID: @.***>

SmileYzn commented 9 months ago

Check Match command.cpp switch case, it is how you can implement the command I a correct way

Em sáb., 2 de dez. de 2023 08:49, Cleverson Souza @.***> escreveu:

Did you put it in command hook system or just created function on CPP?

Em sex., 1 de dez. de 2023 11:33, Ken Hotate @.***> escreveu:

Assigned #103 https://github.com/SmileYzn/MatchBot/issues/103 to @SmileYzn https://github.com/SmileYzn.

— Reply to this email directly, view it on GitHub https://github.com/SmileYzn/MatchBot/issues/103#event-11122905108, or unsubscribe https://github.com/notifications/unsubscribe-auth/ABMUVS27BSJSFHQZFSNDCHLYHHTCNAVCNFSM6AAAAABAC5Z54KVHI2DSMVQWIX3LMV45UABCJFZXG5LFIV3GK3TUJZXXI2LGNFRWC5DJN5XDWMJRGEZDEOJQGUYTAOA . You are receiving this because you were assigned.Message ID: @.***>

that-is-not-great commented 9 months ago

no I dont want to implement anything, the matchbot does not take any command like .ready

SmileYzn commented 9 months ago

Did you have commands.txt in match it folder? Check it

Em sáb., 2 de dez. de 2023 15:06, Ken Hotate @.***> escreveu:

no I dont want to implement anything, the matchbot does not take any command like .ready

— Reply to this email directly, view it on GitHub https://github.com/SmileYzn/MatchBot/issues/103#issuecomment-1837218151, or unsubscribe https://github.com/notifications/unsubscribe-auth/ABMUVS6WJFSBFVWMGR57VS3YHNUZFAVCNFSM6AAAAABAC5Z54KVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMYTQMZXGIYTQMJVGE . You are receiving this because you were mentioned.Message ID: @.***>

that-is-not-great commented 9 months ago

yes its the original file /cstrike/addons/matchbot/commands.txt

// File:    commands.txt
// Updated:     10:22 2023/08/26
// Description: This file is used to manage commands and access.
//////////////////////////////////////////////////////////////////////////////////////////////////////
// ID           Index of command;
// Command      Command string
// Flag         Flag access to that command, see users.txt
// Description      Description of command
//////////////////////////////////////////////////////////////////////////////////////////////////////
//  ID      Command     Flag        Description
//////////////////////////////////////////////////////////////////////////////////////////////////////
    1       ".status"   "z"     // Show the match status
    2       ".score"    "z"     // Show the match scores
    3       ".ready"    "z"     // Tells the server the Player is ready
    ....

and my debug code is directly in the original code function in file "\MatchBot\MatchBot\MatchCommand.cpp" bool CMatchCommand::ClientCommand(CBasePlayer* Player, const char* pcmd, const char* parg1)

SmileYzn commented 9 months ago

Thanks for reporting it, I will return with a response and fix 🙏

Em sáb., 2 de dez. de 2023 19:20, Ken Hotate @.***> escreveu:

yes its the original file /cstrike/addons/matchbot/commands.txt

// File: commands.txt // Updated: 10:22 2023/08/26 // Description: This file is used to manage commands and access. ////////////////////////////////////////////////////////////////////////////////////////////////////// // ID Index of command; // Command Command string // Flag Flag access to that command, see users.txt // Description Description of command ////////////////////////////////////////////////////////////////////////////////////////////////////// // ID Command Flag Description ////////////////////////////////////////////////////////////////////////////////////////////////////// 1 ".status" "z" // Show the match status 2 ".score" "z" // Show the match scores 3 ".ready" "z" // Tells the server the Player is ready ....

— Reply to this email directly, view it on GitHub https://github.com/SmileYzn/MatchBot/issues/103#issuecomment-1837267803, or unsubscribe https://github.com/notifications/unsubscribe-auth/ABMUVS7SMVRFTK743C465WDYHOST7AVCNFSM6AAAAABAC5Z54KVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMYTQMZXGI3DOOBQGM . You are receiving this because you were mentioned.Message ID: @.***>

SmileYzn commented 9 months ago

@that-is-not-great

I forgot to tell, Did you using UTF-8 commands.txt file without BOM? For some reason i also have problems with that a time ago

Did you can test it?

Ps. I also updated CSSDK

Linux: https://github.com/SmileYzn/MatchBot/actions/runs/7087445711 Windows: https://github.com/SmileYzn/MatchBot/actions/runs/7087445703

that-is-not-great commented 9 months ago

yes had BOM utf8. I removed BOM from all .cfg and .txt files now, but it is still not working. is there any debug option to check for more

SmileYzn commented 9 months ago

Check if is work with new build, i have updated CSSDK

germansassone commented 9 months ago

I'm having the same issue, even with the new version

h4wesss commented 9 months ago

Unfortunately I also encountered this

SmileYzn commented 9 months ago

I added a debug message to command manager.

LOG_CONSOLE(PLID, "[%s] %d %s %s", __func__, Index, Command, Flag);

Did someone can see what is output at linux HLDS console?

Ps. Shoud work on windows too, but i suspect that command sytstem is not being loaded only on linux

@h4wesss @that-is-not-great @germansassone

Thanks for help,

https://github.com/SmileYzn/MatchBot/actions/runs/7143731437

h4wesss commented 9 months ago

Hello @SmileYzn , this is what I see in the console when starting the server:

[BOT] Interface CCSEntity API version 'CSENTITY_API_INTERFACE_VERSION003' not found ReGameDLL version: 5.22.0.593-dev Executing ReGameDLL Configuration File [ServerActivate] 0 0 [ServerActivate] 1 .status 33554432 [ServerActivate] 2 .score 33554432 [ServerActivate] 3 .ready 33554432 [ServerActivate] 4 .notready 33554432 [ServerActivate] 5 .hp 33554432 [ServerActivate] 6 .dmg 33554432 [ServerActivate] 7 .rdmg 33554432 [ServerActivate] 8 .sum 33554432 [ServerActivate] 9 .help 33554432 [ServerActivate] 10 .vote 33554432 [ServerActivate] 11 .votekick 33554432 [ServerActivate] 12 .votemap 33554432 [ServerActivate] 13 .votepause 33554432 [ServerActivate] 14 .voterestart 33554432 [ServerActivate] 15 .votestop 33554432 [ServerActivate] 16 .mute 33554432 [ServerActivate] 33 !menu 1048576 [ServerActivate] 34 !kick 4 [ServerActivate] 35 !ban 8 [ServerActivate] 36 !kill 16 [ServerActivate] 37 !team 4096 [ServerActivate] 38 !map 32 [ServerActivate] 39 !control 8192 [ServerActivate] 40 !msg 256 [ServerActivate] 41 !cmd 2048 [ServerActivate] 42 !swap 64 [ServerActivate] 43 !votemap 512 [ServerActivate] 44 !voteteam 512 [ServerActivate] 45 !start 8192 [ServerActivate] 46 !stop 8192 [ServerActivate] 47 !restart 8192 [ServerActivate] 48 !pause 8192 [ServerActivate] 49 !help 16384 [ServerActivate] 50 !players 1048576 [ServerActivate] 51 !cvars 64 [S_API FAIL] SteamAPI_Init() failed; SteamAPI_IsSteamRunning() failed. CAppInfoCacheReadFromDiskThread took 3 milliseconds to initialize Looking up breakpad interfaces from steamclient Calling BreakpadMiniDumpSystemInit

SmileYzn commented 9 months ago

Well, commands.txt is ok in that builds, i will investigate what is going with ReHLDS server

Thanks for sharing results.

h4wesss commented 9 months ago

Wait, I didn't read your message carefully! This is the result with ReHLDS

@SmileYzn

SmileYzn commented 8 months ago

Someone can check if it will work with new release? I had updated metamod plugins and metamod dll itself on final package

h4wesss commented 8 months ago

[ReHLDS 3.13.0.788-dev]

[ 1] AMX Mod X RUN - amxmodx_mm_i386.so v1.9.0-dev+5210 ini Start ANY
[ 2] Reunion RUN - reunion_mm_i386.so v0.1.92d ini Start Never
[ 3] VoiceTranscoder RUN - VoiceTranscoder.so v2017RC5 ini ANY ANY
[ 4] Accuracy Fix RUN - accuracyfix_mm.so v1.0.2 ini ANY ANY
[ 5] HitBox Fix RUN - hitbox_fix_mm_i386.so v1.1.4 ini Start ANY
[ 6] Match Bot RUN - matchbot_mm.so v1.0.0 ini ANY ANY
[ 7] CStrike RUN - cstrike_amxx_i386.so v1.9.0-dev+5210 pl1 ANY ANY
[ 8] Ham Sandwich RUN - hamsandwich_amxx_i386.so v1.9.0-dev+5210 pl1 ANY ANY
[ 9] CSX RUN - csx_amxx_i386.so v1.9.0-dev+5210 pl1 ANY ANY

The problem remains, chat commands are not registered

SmileYzn commented 8 months ago

Did someone can try it again? I have done a new build, in windows build is working

Thanks 🙏

h4wesss commented 8 months ago

Может ли кто-нибудь попробовать еще раз? Я сделал новую сборку, в Windows сборка работает

Спасибо 🙏

I can provide access to linux hosting. What would you try yourself?

SmileYzn commented 8 months ago

@h4wesss Thanks, but i will test at my gamepanel when i get home.

Ps. My ReHLDS is installed from steamcmd with:

app_set_config 90 mod cstrike app_update 90 -beta steam_legacy validate

ReHLDS action build from https://github.com/dreamstalker/rehlds/actions/runs/7202895726

RegameDLL_CS build from https://github.com/s1lentq/ReGameDLL_CS/actions/runs/7205289640

I always use latest action build that touch only on master branch from ReHLDS and RegameDLL_CS

And only using HLDS legacy mode until ReHLDS and ReGameDLL_CS be compatible with newest VALVe update

SmileYzn commented 8 months ago

Ubuntu 18 04 6 LTS

Working on ubuntu 18.04.6 LTS

SmileYzn commented 8 months ago

@h4wesss

Did has some edit in text files ? I have issues with UTF8 with BOM character.

EVOLCORE commented 8 months ago

Downloaded, latest version commands are still not registering, also there is something like in console [BOT] Interface CCSEntity API version 'CSENTITY_API_INTERFACE_VERSION003' not found I guess is from sdk

image

SmileYzn commented 8 months ago

Install HLDS via steamcmd with:

app_set_config 90 mod cstrike
app_update 90 -beta steam_legacy validate

After that, install ReHLDS files from: https://github.com/dreamstalker/rehlds/actions/runs/7202895726 (Latest action build in master branch)

ReGameDLL_CS from: https://github.com/s1lentq/ReGameDLL_CS/actions/runs/7303376272 (Latest action build in master branch)

And error CSENTITY_API_INTERFACE_VERSION003 just go out.

And matchbot from: https://github.com/SmileYzn/MatchBot/actions/runs/7289992483 (Windows) https://github.com/SmileYzn/MatchBot/actions/runs/7289992478 (Linux) (Latest action build in master branch)

Ps.: image

drk1590 commented 8 months ago

the error also exists since the last update and the plugin writes bad load :c

[ 1] Reunion RUN - reunion_mm_i386.so v0.1.92d ini Start Never [ 2] badf load matchbot_mm.so v - ini - -
[ 3] HitBox Fix RUN - hitbox_fix_mm_i386.so v1.1.5 ini Start ANY
[ 4] Accuracy Fix RUN - accuracyfix_mm.so v1.0.2 ini ANY ANY
[ 5] AMX Mod X RUN - amxmodx_mm_i386.so v1.10.0.5461 ini Start ANY
[ 6] ReAuthCheck RUN - reauthcheck_mm_i386.so v0.1.6 ini Start Never [ 7] WHBlocker RUN - whblocker_mm_i386.so v1.5.697 ini Chlvl ANY
[ 8] ReAPI RUN - reapi_amxx_i386.so v5.22.0.254-dev pl5 ANY Never [ 9] ReAimDetector RUN - reaimdetector_amxx_i386.so v0.2.2 pl5 ANY Never [10] Fun RUN - fun_amxx_i386.so v1.10.0.5461 pl5 ANY ANY
[11] FakeMeta RUN - fakemeta_amxx_i386.so v1.10.0.5461 pl5 ANY ANY
[12] Engine RUN - engine_amxx_i386.so v1.10.0.5461 pl5 ANY ANY
[13] CStrike RUN - cstrike_amxx_i386.so v1.10.0.5461 pl5 ANY ANY
[14] Ham Sandwich RUN - hamsandwich_amxx_i386.so v1.10.0.5461 pl5 ANY ANY

SmileYzn commented 8 months ago

@drk1590 Thanks for reporting it

I have static linked lib gcc and lib stdc++ again

Try it the fix from https://github.com/SmileYzn/MatchBot/actions/runs/7462329699

🙏

drk1590 commented 8 months ago

yes, it already works, but I don't have an admin, did I miss something?

SmileYzn commented 8 months ago

What you put on users.txt? of matchbot?

cstrike/addons/matchbot/users.txt

MATCHBOT already has admin flags, do nothing with amxx

drk1590 commented 8 months ago

I tried without admin.amxx as well

drk1590 commented 8 months ago

st id is written, you may be right, thank you for your answer

SmileYzn commented 8 months ago

st id is written, you may be right, thank you for your answer

What you put on users.txt? It will only support steamid inside!

SamuelGogarty commented 4 months ago

I am still facing this, I have the latest metamod, regamedll_cs and rehlds. I am using the latest release of match bot, released feb 7th of this year, which has the commits you have made in regards of linking those 2 libraries. I can see that metamod as well as match bot is working as I can see the "players not ready" and "players ready", however trying to run any command such as .ready in-game results in nothing.

SamuelGogarty commented 4 months ago

I have tried again with the latest actions build, issue persists.

SamuelGogarty commented 4 months ago

https://github.com/SmileYzn/MatchBot/issues/146