Anti-Multi account/ remove old unused accounts?

Started by Kewun, Sep 19, 2016, 05:34 PM

Previous topic - Next topic

Kewun

i dont have any idea how to do it with ini parser plugin
could anyone give me an example of how to do that or atleast how could it be madden? i want like if account is 2 months old unused, then its get removed from the stats.ini

Thijn

I'm not sure why you would want to do that, since people take breaks from VC:MP all the time and would be pissed if their account has been removed or someone else could impersonate him because his account isn't registered anymore.

But to answer your question: save the timestamp using time(), loop through all your accounts and see if that timestamp is older then 2 months, if so remove his data

Ankris


Mötley

Well I do not really know Kewun,

I will just throw some whatevers at you.

Maybe you could create a UID ini list.

and do something in the logic of if uid == player.uid
Then player.Name = that accounts name xD
Sounds really bad.... As if you would break your server.
But might work,...

 

Kewun

Quote from: Ankris on Sep 19, 2016, 07:58 PM:whensomeonetriestocopyaurora:

copy? what do you mean? im just making a server. You have nothing to it, youre just envy that i am better than you.

Kewun

#5
Alright, thijn, ill try it. by the way i wanted to do remove old unused accounts, because they might take eat space ( like trash )

KAKAN

Quote from: Kewun on Sep 20, 2016, 02:18 PMAlright, thijn, ill try it. by the way i wanted to do remove old unused accounts, because they might take eat space ( like trash )
With a MySQL database, I think 1200 or 12000 records take about 5 MB. With INI, I guess it will be even lower.
oh no

Kewun

well, i dont know the max of kb in stats ini of a player

because multi accounts might lag my server in a ini with 30 kb when i tested with vehicles in onscriptload, saving all their pos and health ( the accounts stat.ini is 1 kb, so still much to achieve 30 kb)

KAKAN

Quote from: Kewun on Sep 20, 2016, 02:24 PMwell, i dont know the max of kb in stats ini of a player

because multi accounts might lag my server in a ini with 30 kb when i tested with vehicles in onscriptload, saving all their pos and health ( the accounts stat.ini is 1 kb, so still much to achieve 30 kb)
Use the newly released INIParser plugin or make your own( using squirrel ofc ).
oh no

Kewun

the new one sucks, because trying to use INI_Open("stats.ini") Gives error: Wrong INI Pointer even if the file exists

Kewun


Ankris

Quote from: Kewun on Sep 20, 2016, 02:15 PM
Quote from: Ankris on Sep 19, 2016, 07:58 PM:whensomeonetriestocopyaurora:

copy? what do you mean? im just making a server. You have nothing to it, youre just envy that i am better than you.

Quote from: Kewun on Sep 20, 2016, 03:57 PMthe new one sucks, because trying to use INI_Open("stats.ini") Gives error: Wrong INI Pointer even if the file exists
Quote from: Kewun on Sep 20, 2016, 02:24 PMbecause multi accounts might lag my server in a ini with 30 kb when i tested with vehicles in onscriptload, saving all their pos and health ( the accounts stat.ini is 1 kb, so still much to achieve 30 kb)


Kewun

#12
Quote from: Ankris on Sep 21, 2016, 02:57 PM
Quote from: Kewun on Sep 20, 2016, 02:15 PM
Quote from: Ankris on Sep 19, 2016, 07:58 PM:whensomeonetriestocopyaurora:

copy? what do you mean? im just making a server. You have nothing to it, youre just envy that i am better than you.

Quote from: Kewun on Sep 20, 2016, 03:57 PMthe new one sucks, because trying to use INI_Open("stats.ini") Gives error: Wrong INI Pointer even if the file exists
Quote from: Kewun on Sep 20, 2016, 02:24 PMbecause multi accounts might lag my server in a ini with 30 kb when i tested with vehicles in onscriptload, saving all their pos and health ( the accounts stat.ini is 1 kb, so still much to achieve 30 kb)



haha very funny...

Seems you cant write, so you instead post a shitty picture.
I dont need to talk to a young kid of 14 years old
Look at your self, you are failing all the time, and being angry at others. Others tell you good things, you take it as bad.
You have only critics, not doing good things. Try acting your age.