Raised This Month: $12 Target: $400
 3% 

KeyValues or database?


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
joac1144
Senior Member
Join Date: Dec 2012
Location: Copenhagen, Denmark
Old 10-29-2020 , 19:24   KeyValues or database?
Reply With Quote #1

If I want to save some information about players - let's say a clan tag set through a plugin - would it be better to save it with KeyValues or a database?

My guess is KeyValues since it's not a lot of information, and it wouldn't require a database set up.
joac1144 is offline
asherkin
SourceMod Developer
Join Date: Aug 2009
Location: OnGameFrame()
Old 10-29-2020 , 20:17   Re: KeyValues or database?
Reply With Quote #2

Your use case as described is a perfect fit for the clientprefs API.

For other things, I'd certainly advise using a database for data, with sqlite if you don't need centralised storage.

KeyValues are almost never a sane option for anything other than configuration (and even there SMC is often a better choice).
__________________
asherkin is offline
joac1144
Senior Member
Join Date: Dec 2012
Location: Copenhagen, Denmark
Old 10-29-2020 , 21:46   Re: KeyValues or database?
Reply With Quote #3

Thanks!

Last edited by joac1144; 10-29-2020 at 21:46.
joac1144 is offline
Reply


Thread Tools
Display Modes

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 05:00.


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