Closed lamperi closed 11 years ago
Well, how this would work exactly? I mean, updating the bans, checking if the time has run out. Everything else seems easy. o.O
How would the sys.banList function change? This probably needs some internal data structure changes, not much though.
On Thursday 1. March 2012 at 4.19, Blastcore wrote:
Well, how this would work exactly? I mean, updating the bans, checking if the time has run out. Everything else seems easy. o.O
Reply to this email directly or view it on GitHub: https://github.com/coyotte508/pokemon-online/issues/54#issuecomment-4251289
I mean... Gah, i suck at explaining. When you ban someone, there needs to be something running on background to check each banned user and see if it's ban expired. (Threaded?, like deleting inactive members and updating tiers...?)
Much more efficient would be doing that on demand. The daily member remover could do this too, if needed.
On Thursday 1. March 2012 at 20.20, Blastcore wrote:
I mean... Gah, i suck at explaining. When you ban someone, there needs to be something running on background to check each banned user and see if it's ban expired. (Threaded?, like deleting inactive members and updating tiers...?)
Reply to this email directly or view it on GitHub: https://github.com/coyotte508/pokemon-online/issues/54#issuecomment-4265196
But the daily how it says, does the update EACH day. When there are 1 day, 1 hour or 1 minute ban.
Well, now. After some of my inactivity (preparing stuff for classes), i've figured out this could be threaded, to work like the Database Cleaner does. Threaded, works exactly like the cleaner. What i've figured out, that it's pretty easy to do. We don't need to be checking each 1 minute if someone is banned. Just when required (Someone logins, script functions, or when looking at Players in Server, i'll look into this now to see how it works :))
EDIT: As how i said, before login in a player, we check if he's still banned. Right? EDIT2: And we could use QDateTime or however it is for this. :)
I'd say to implement it on devel, as it may not work how we want. And devel wont take too much to be released, as we're going fine with the stuff.
You might want to look into https://github.com/lamperi/pokemon-online/tree/feature-tempban
I just pushed something I coded a month ago. It would be ideal for you to use that as a starting point if possible.
IOn Saturday 10. March 2012 at 6.24, Blastcore wrote:
Well, now. After some of my inactivity (preparing stuff for classes), i've figured out this could be threaded, to work like the Database Cleaner does. Threaded, works exactly like the cleaner. What i've figured out, that it's pretty easy to do. We don't need to be checking each 1 minute if someone is banned. Just when required (Someone logins, script functions, or when looking at Players in Server, i'll look into this now to see how it works :))
Reply to this email directly or view it on GitHub: https://github.com/coyotte508/pokemon-online/issues/54#issuecomment-4428776
Well, actually i had other idea instead of that. Whatever, what's missing on it? :confusedface:
@lamperi Okay, so seems like coyo merged it into devel (If i'm not wrong), whatever it doesn't work, it does normal ban.
He merged only one of the commits ...
Tempban works now in devel, but we might want to fully use it.
Referring to: """Controlpanel could use "Change ban time" and "Unban on..". Server could just readjust the ban length. Needs to think about the two scenaries: Ban for xxx time and ban until xxx datetime."""
It would be very cool for admins to set unban dates in Control Panel. Basically, only a GUI is needed, server should behave nicely already.
Also protocol should be added http://wiki.pokemon-online.eu/view/Network_Protocol_v2
I believe this issue can be closed.
Idk, i didn't get "change expire to" to work correctly (or i didn't understand the format of the date set)
you can just click the arrows which allow you to choose from calendar
Should we use that or make it work like it does server-side? (Instead of date, minutes.)
I have used the calendar successfully to set unban dates to people :)
If you change it, please make sure it is still possible to select unban dates.
By adding a new field into SecurityManager::Member.
Protocol does not need to be broken for this, can be implemented to master branch.
Think about the client GUI a bit. Maybe add on player list right click: Tempban for -> one hour | one day | choose time
Controlpanel could use "Change ban time" and "Unban on..". Server could just readjust the ban length. Needs to think about the two scenaries: Ban for xxx time and ban until xxx datetime.
What about auth levels? Put everything on auth >= 2 or grant a short tempban to mods?
Also needs scripts functions: sys.tempBan(name, time_as_seconds) or extend sys.ban().