Raised This Month: $ Target: $400
 0% 

[CS:GO] Rank based on Time played.


Post New Thread Reply   
 
Thread Tools Display Modes
ThatOneGuy
Veteran Member
Join Date: Jul 2012
Location: Oregon, USA
Old 07-07-2015 , 01:49   Re: [CS:GO] Rank based on Time played.
Reply With Quote #11

I have such a plugin already coded. Works with either mysql or sqlite. Just updated it today to be able to be used as a rank system (so that part is already done), and added natives for other plugins to use it based on minutes played or rank. If using mysql (I know youre not, but others may be), it tracks time both globally, and separates out into servers as well. The structure will give you an idea of what im talking about...



Granted, with mysql, the id and server fields are gone.....so it is just (2) - (7). I do need to make one tweak for sqlite, but that is nothing big. PM me if interested.

Alternately, you might be able to tweak the other plugins suggested here for your needs.
__________________
ThatOneGuy is offline
Puppetmaster
Senior Member
Join Date: Jun 2015
Location: Probably at a computer.
Old 07-07-2015 , 01:57   Re: [CS:GO] Rank based on Time played.
Reply With Quote #12

Quote:
Originally Posted by ThatOneGuy View Post
I have such a plugin already coded. Works with either mysql or sqlite. Just updated it today to be able to be used as a rank system (so that part is already done), and added natives for other plugins to use it based on minutes played or rank. If using mysql (I know youre not, but others may be), it tracks time both globally, and separates out into servers as well. The structure will give you an idea of what im talking about...



Granted, with mysql, the id and server fields are gone.....so it is just (2) - (7). I do need to make one tweak for sqlite, but that is nothing big. PM me if interested.

Alternately, you might be able to tweak the other plugins suggested here for your needs.
Thats really cool, by what method do other plugins access its API? Im guessing directly from the DB or via a series of convars?
__________________

GZS Servers
Puppetmaster is offline
ThatOneGuy
Veteran Member
Join Date: Jul 2012
Location: Oregon, USA
Old 07-07-2015 , 02:09   Re: [CS:GO] Rank based on Time played.
Reply With Quote #13

Quote:
Originally Posted by Puppetmaster View Post
Thats really cool, by what method do other plugins access its API? Im guessing directly from the DB or via a series of convars?
Natives coded into the plugin.

Spoiler
__________________
ThatOneGuy is offline
Lannister
Veteran Member
Join Date: Apr 2015
Old 07-07-2015 , 12:00   Re: [CS:GO] Rank based on Time played.
Reply With Quote #14

So this is actually possible?
Lannister is offline
friagram
Veteran Member
Join Date: Sep 2012
Location: Silicon Valley
Old 07-07-2015 , 13:24   Re: [CS:GO] Rank based on Time played.
Reply With Quote #15

Quote:
Originally Posted by Puppetmaster View Post
I think a database would be the way to go, since you want to track a potentially large number of players a database would both allow you to store large numbers and efficiently run queries on the data. For instance calculating the top 10 players without a database could be quite hard as you would have to iterate over a list using something like a heap. With a database you would simply make a query ordered by biggest first with a limit of 10 which is quite efficient.
That db has hundreds of thousands of unique steam ids. If you were to use sqlite, you may experience some problems like server stalls and such. I'v not use sqlite for a while, but back in the day it got really congested with clientprefs, and got corrupt sometimes.
__________________
Profile - Plugins
Add me on steam if you are seeking sp/map/model commissions.
friagram is offline
ThatOneGuy
Veteran Member
Join Date: Jul 2012
Location: Oregon, USA
Old 07-07-2015 , 14:58   Re: [CS:GO] Rank based on Time played.
Reply With Quote #16

Quote:
Originally Posted by friagram View Post
That db has hundreds of thousands of unique steam ids. If you were to use sqlite, you may experience some problems like server stalls and such. I'v not use sqlite for a while, but back in the day it got really congested with clientprefs, and got corrupt sometimes.
I'd agree with friagram that you really should look into getting a website. They arent expensive, and using sqlite is gonna be heavy on your server....but yea...the possibility is there if you need it. Alternately, you could use gameme or another stats plugin that hosts it from their own website....i think they also track time...not positive though.
__________________
ThatOneGuy is offline
Lannister
Veteran Member
Join Date: Apr 2015
Old 07-07-2015 , 15:13   Re: [CS:GO] Rank based on Time played.
Reply With Quote #17

But i wonder, how's possible for plugins like SoDStats to track everyones kills/death, time, headshots and everything without "hurting" the server? sorry if it sounds dumb!

And thanks for your help guys i appreciate it.
Lannister is offline
Puppetmaster
Senior Member
Join Date: Jun 2015
Location: Probably at a computer.
Old 07-07-2015 , 20:03   Re: [CS:GO] Rank based on Time played.
Reply With Quote #18

Quote:
Originally Posted by friagram View Post
That db has hundreds of thousands of unique steam ids. If you were to use sqlite, you may experience some problems like server stalls and such. I'v not use sqlite for a while, but back in the day it got really congested with clientprefs, and got corrupt sometimes.
You could always add purge code that cleans it if say the players have not logged into the server for two weeks or have not spent x amount of time on in the past month? That would clean up a ton of the useless player data and keep everything running smoothly.
__________________

GZS Servers
Puppetmaster is offline
Lannister
Veteran Member
Join Date: Apr 2015
Old 07-07-2015 , 20:20   Re: [CS:GO] Rank based on Time played.
Reply With Quote #19

Seems like you guys are having great ideas, i'm glad !
Lannister is offline
PlayBoy31
Senior Member
Join Date: May 2011
Location: into the void
Old 07-08-2015 , 08:44   Re: [CS:GO] Rank based on Time played.
Reply With Quote #20

I have done a rank plugins for my servers, i can implement the rank with time played

Last edited by PlayBoy31; 05-07-2022 at 20:21.
PlayBoy31 is offline
Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 10:12.


Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Theme made by Freecode