Jump to content

[Resolved][Help] Resetting account data (setAccountData)


GERgta

Recommended Posts

Hello people :)

I've been trying to reset account data for a system I wrote to save the player's weapons, however; I can not find a way to delete account data that I've set. I've tried setAccountData(acc,"key",false) and setAccountData(acc,"key",nil), but nothing seems to work :|

I get no errors and the the account that I used exists. Any help?

Edited by Guest
Link to comment

It might still be a better idea to use "nil" instead of "false" as false is technically the value 0 while "nil" allow you to allocate that space for other stuff in your memory, and your server hard disks. On a small server we're talking about a few bits of space, (even on larger servers it might not even be noticeable, at least not in the beginnig but later on you might get a database filled with the value "false"). Therefore it's a good idea to set the account data to "nil", if you want to truly reset it. :wink:

Link to comment
It might still be a better idea to use "nil" instead of "false" as false is technically the value 0 while "nil" allow you to allocate that space for other stuff in your memory, and your server hard disks. On a small server we're talking about a few bits of space, (even on larger servers it might not even be noticeable, at least not in the beginnig but later on you might get a database filled with the value "false"). Therefore it's a good idea to set the account data to "nil", if you want to truly reset it. :wink:

That is extremely true, even with variables

Especially if you aspire to have server with 100+ players without lag

that small thing may case lag with alot players, who know

Link to comment
  • 3 weeks later...

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...