Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Sven Co-op] Run records not print in MOTD list #34

Open
SmileyAG opened this issue Jan 2, 2022 · 3 comments
Open

[Sven Co-op] Run records not print in MOTD list #34

SmileyAG opened this issue Jan 2, 2022 · 3 comments

Comments

@SmileyAG
Copy link

SmileyAG commented Jan 2, 2022

Warning! It's not related to #33 request, bcz amdmodx doesn't error in console about hamdata.ini issues (debug mode been enabled btw)

Most likely it's requires additional support, bcz MOTD in Sven Coop been changed so much I guess.

All other functions from the hlkreedz plugin, like start and ending a run, creating checkpoints, hiding players and etc works without issues at all.

изображение

@SmileyAG
Copy link
Author

SmileyAG commented Jan 2, 2022

@fireblizzard sorry for ping yet, can you look to that issue when you get free time and push fix to unstable branch, please?

@fireblizzard
Copy link
Collaborator

I'll take a look next week hopefully

@fireblizzard
Copy link
Collaborator

You can print to console the buffer passed to show_motd(), which has each row in the leaderboard, and it will show it just fine in console, so I'm assuming it has something to do with show_motd() not working correctly for some reason.

show_motd(id, buffer, header);

I think this requires way more time than I'm willing to spend for an unsupported mod (only AG Steam is supported...), sorry. I don't know if printing to console is enough for you, and then you have to handle the client receiving too long or too many user messages, otherwise it will overflow and the client will probably crash. Well this happens in AG, I don't know if Sven Coop handles that gracefully or there's just no overflow there. You can also split the leaderboard in chunks and send them every few milliseconds, I'm guessing this would work too.

But about the MOTD, I don't know. You can try refactoring the buffer formating (formatex()), use another way of adding the contents to the buffer, and remove the len += and charsmax(buffer) - len which is not very maintainable code. It's been there since forever.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants