Jump to content

[HELP] AddAccount


Recommended Posts

Posted

i Found a Bug Dunno how Solve it i will give example:

like i have an Account with Name "DUDE123" and another Player can register with same account Name but with small letter like "dude123" how solve that? o.O

P.S The Big Problem is that they Got the Same Data like ( weapons, Money and etc )

Giving a Fuck? Nope, That isn't in My Skill Set

castie11.png

  • Moderators
Posted

No they don't have.

Unless you use something else then a default database.

Do you want to improve your Lua programming skills and make less mistakes?   Start with Lua Language Server!   🙀

 

  Useful functions  3x 

  Tutorials  4x 

 

Posted

anyway how i can solve this? because i use onPlayerLogin get account data set elementdata and etc and as i was say before they little fail xD

Giving a Fuck? Nope, That isn't in My Skill Set

castie11.png

Posted

easy, whenever you do addAccount, make sure you make all the characters lowercase. In that way they won't be able to register a name twice. :)

logo-small.png?v=3 tiny-sapdfr.png

 

If you want to contact me directly concerning Advanced-Gaming, please contact me at [email protected]

Posted

i mean any way to check? xD to Prevent that like if i have an account "DUDE123" to can't register another with same but lowcase letters or the negativ if i have account dude123 to can't create another as DUDE123

Giving a Fuck? Nope, That isn't in My Skill Set

castie11.png

Posted

You can use s:lower() to force all the characters to be lowercase then check if the account exists.

local username = "HELLO123" 
local username = string.lower(username) 
          

username would return "hello123" after those operations were complete.

Posted

i have Question i found the follow think:

Find the first occurrence of the pattern in the string passed. If an instance of the pattern is found a pair of values representing the start and end of the string is returned. If the pattern cannot be found nil is returned. 
  
> = string.find("Hello Lua user", "Lua") 
7       9 
> = string.find("Hello Lua user", "banana") 
nil 

can i use it?

Giving a Fuck? Nope, That isn't in My Skill Set

castie11.png

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...