dkoz / palworld-palbot

Palbot - Palworld Discord Bot for RCON, Economy, and Server Management.
https://discord.kozejin.dev
GNU General Public License v3.0
40 stars 9 forks source link

/rcon broadcast cuts off after first space in message. #1

Closed StrikerMan780 closed 9 months ago

StrikerMan780 commented 9 months ago

When you use /rcon broadcast, the message cuts off at the first space in-game.

So, if you use the commmand, like:

/rcon broadcast (text)Greetings everyone! (servername)my server

in-game, you'll only see "Greetings"

dkoz commented 9 months ago

Do me a favor and use ctrl+r to reload your discord and try the command again. Palworld RCON does not allow spaces in broadcast or shutdown message, so I had to substitute space with an underscore.

StrikerMan780 commented 9 months ago

Seems to work. I wonder if maybe it's possible to use a non-breaking space or some other invisible character?

dkoz commented 9 months ago

I have an it acts weird with it. Always inserting weird characters when trying to using invisible characters. You're free to try it on the open source bot. If it works make a pull request.

StrikerMan780 commented 9 months ago

I'll experiment with different characters for a bit, and will see what might work. Obviously, no guarantees, but I'll report if I find a workaround.

dkoz commented 9 months ago

Alright cool. I was looking at so many different characters to try. I noticed it worked under a different scripting language. I was unsure if it was a python related issue.

StrikerMan780 commented 9 months ago

Ah, yeah, that might be it. Maybe you need to escape special characters somehow? My familiarity with Python is somewhat limited.

dkoz commented 9 months ago

Ah, yeah, that might be it. Maybe you need to escape special characters somehow? My familiarity with Python is somewhat limited.

This issue has now been resolved.