Simple PingKicker (hooked version included) -
2KY - 01.05.2013
Overview
Just figured I'd try out my new module-style coding and create this rather simple ping kicker. Nonetheless, maybe it'll be useful for someone, so here you go. A bit of customization is available, detailed below..
Information
Quote:
DIALOG_PINGKICKER - The dialogid associated with the Ping Kicker. (Uses 1 dialog)
MAX_PING - The maximum ping before the ping kicker is executed.
PING_CHECK_TIME - How often their ping is checked.
MAX_PING_WARNINGS - How many times their ping is checked.
PING_WARNINGMESSAGE - The message displayed every time their ping is over MAX_PING.
|
This ping kicker is called OnPlayerConnect, and uses a single timer which is destroyed after its allotted time is over with. The best part of this filterscript? Unless the player has a high ping - a normal player will never even know this is running!
Download
-
pingkicker.pwn (Filterscript version)
-
PK.pwn (module/hooked version)
Re: Simple PingKicker (hooked version included) -
Pottus - 01.05.2013
I don't like it....
Use one timer to check all the players in a foreach() loop creating a timer every time someone connects is silliness.
Re: Simple PingKicker (hooked version included) -
2KY - 01.05.2013
Quote:
Originally Posted by [uL]Pottus
I don't like it....
Use one timer to check all the players in a foreach() loop creating a timer every time someone connects is silliness.
|
Did you even look at the code? It creates the timer, checks what it needs to check, and then deletes itself..
Re: Simple PingKicker (hooked version included) -
Pottus - 01.05.2013
I looked at the code, and I said "I DON'T LIKE IT" it's a shitty implementation and shitty way to do it using a foreach() loop is much better as there is no need to create a timer for each player that is a complete nonsense way to do it.
Re: Simple PingKicker (hooked version included) -
Scenario - 01.05.2013
You would be much better off having a single running timer and using a foreach loop to determine if someone needs to have something said/done to them. Furthermore, I suggest that you take a look at the notice on the wiki about the GetPlayerPing function!
https://sampwiki.blast.hk/wiki/GetPlayerPing
Re: Simple PingKicker (hooked version included) -
[KHK]Khalid - 02.05.2013
Suggestion: make something like /pingsettings to set/change max ping limit, ping check time and max ping warnings.
Re: Simple PingKicker (hooked version included) -
freddy smyth - 02.05.2013
Pretty harsh feedback.
Kudos for sharing your ideas anyway, although I hate high ping kickers, namely because I'm always on the receiving end.
Re: Simple PingKicker (hooked version included) -
2KY - 02.05.2013
Quote:
Originally Posted by [KHK]Khalid
Suggestion: make something like /pingsettings to set/change max ping limit, ping check time and max ping warnings.
|
That is very possible, will complete when I have some time.
Quote:
Originally Posted by freddy smyth
Pretty harsh feedback.
Kudos for sharing your ideas anyway, although I hate high ping kickers, namely because I'm always on the receiving end.
|
I can see where you're coming from!
Quote:
Originally Posted by RealCop228
You would be much better off having a single running timer and using a foreach loop to determine if someone needs to have something said/done to them. Furthermore, I suggest that you take a look at the notice on the wiki about the GetPlayerPing function!
https://sampwiki.blast.hk/wiki/GetPlayerPing
|
That warning is precisely why it checks it multiple times before kicking them, and you can change the interval on how often it checks yourself using the definition.