RSSy MYGO.pl Opublikowano Wrzesień 13, 2016 o 19:13 RSSy Udostępnij Opublikowano Wrzesień 13, 2016 o 19:13 Simple Player Counter This is a simple plugin (my first one! :-) serving a very specific purpose: it keeps track of the players that are currently playing on a server by maintaining zero to three files: numberofplayers.txt -> you will find the number of currently connected clients here listofplayers.txt -> holds a list of all players currently connected idlenow.txt -> indicates when no one is connected Why would you need that? Well - you don't necessarily, I think. For me, I was looking for a simple way to check my server's activity by just logging in via SSH and looking into some files (so you don't have to start the game itself). I also use the idlenow.txt file to automatically update the server when no one is connected. Maybe there are other, even more simple ways to check how many clients are connected (and that can also be used in an automatic update script running periodically)? I don't really know, to be honest. But for me this was kind of fun to write my first SourceMod plugin, so here we are! :)CVars sm_spc_version -> the plugin's version, obviously... sm_spc_countplayersfile -> File name for keeping track of the number of connected players. If set to "", the file will not be generated sm_spc_listplayersfile -> File name for generating the list of players. Again: "" means no file. sm_spc_idlefile -> File name for indicating when the server has no playsers. "" = no such file. Installation Plain & easy: put the simpleplayercounter.smx into your SourceMod config folder and Bob's your uncle. If you want to rename or disable one or more of the files described above, just edit the file .../cfg/sourcemod/plugin.simpleplayercounter.cfg (after having loaded the plugin at least once).DownloadYou will always find the most recent version on GitHub!https://github.com/almostagreatcoder...player_counter Attached Files simpleplayercounter.smx (5.6 KB) Get Plugin or Get Source (simpleplayercounter.sp - 4.6 KB) Wyświetl pełny artykuł Odnośnik do komentarza Udostępnij na innych stronach Więcej opcji udostępniania...
Rekomendowane odpowiedzi
Jeśli chcesz dodać odpowiedź, zaloguj się lub zarejestruj nowe konto
Jedynie zarejestrowani użytkownicy mogą komentować zawartość tej strony.
Zarejestruj nowe konto
Załóż nowe konto. To bardzo proste!
Zarejestruj sięZaloguj się
Posiadasz już konto? Zaloguj się poniżej.
Zaloguj się