jtams / Rust-Game-Alerts-Discord-Bot

Discord Bot that alerts channel when someones is online/offline on Rust (game)
MIT License
3 stars 1 forks source link

Tracker should track playerID instead of name #1

Closed crilleaz closed 4 years ago

crilleaz commented 4 years ago

Players changes their name pretty often, this will make the bot not work properly.

Could you make it go by ID instead of names?

Example: https://api.battlemetrics.com/players/956053153/servers/4094307, although the name isn't really there, but you might find a solution to that ^^

Also, maybe grouping?

jtams commented 4 years ago

Thank you for the idea. I changed a lot about the way the bot functions. Now you can add users like normal (by their in-game username), and it'll fetch their ID and use that from then on. It checks if their name has changed every time they get on or off.

If you use the command !add ally, !add enemy, or !add squad they will appear in separate groups.

In the future I'd like to implement adding users by their ID and custom group names.

Tracking users by ID rather than username now uses less CPU and, in most cases, less bandwidth.

I'm currently working on a website in my spare time that gives this bot a better interface and keeps a database of every time a user gets on or off.