Jump to content

Logann

Members
  • Posts

    7
  • Joined

  • Last visited

Logann's Achievements

Newbie

Newbie (4/54)

1

Reputation

  1. I solved it. Thanks for help :D.
  2. I see, the problem is, that getAccount returns true no matter whatever it is. FINAL SOLUTION client function login() --if an element was clicked on screen username = guiGetText(GUIEditor.edit[1]) password2 = guiGetText(GUIEditor.edit[2]) account = triggerServerEvent ( "Account", getRootElement(),username) if (account == true) then local tf = triggerServerEvent ( "logInn", getRootElement(),localPlayer,username,password2) if (tf == true) then outputConsole("success") isLoggedIn = true showCursor(false) else outputConsole("wrn") end else outputConsole("lel2") end end server addEvent ( "Account", true ) function getAcc(username) local account = isGuestAccount(username) if (account == true) then return false else return true end end addEventHandler ( "Account", getRootElement(), getAcc ) addEvent ( "logInn", true ) function logInn(thePlayer,username,password2) local noole = logIn(thePlayer,getAccount(username),password2) return noole end addEventHandler ( "logInn", getRootElement(), logInn )
  3. Well, co i made this.. SERVER function getAcc(username,password2) local account = getAccount(username,password2) return account end CLIENT account = getAcc(username,password2) outputConsole("lel3") if account then outputConsole("lel3") logIn ( thePlayer, username, password2 ) else outputConsole("lel2") end Still, no results. Nevermind, I forgot to do it thru events. SOLUTION addEvent ( "Account", true ) function getAcc(username,password2) local account = getAccount(username,password2) return account end addEventHandler ( "Account", getRootElement(), getAcc ) account = triggerServerEvent ( "Account", getRootElement(),username, password2 )
  4. Hello there, I'm making my own login system. So far, it goes great, but code stucks at getAccount, which does not progress any further. It does no output since line getAccount. just nothing. Like if it's stuck at that line. username = guiGetText(GUIEditor.edit[1]) password2 = guiGetText(GUIEditor.edit[2]) if getAccount(username,password2) then outputConsole("passed") logIn ( thePlayer, username, password2 ) else outputConsole("false") end Basically it's that simple, but it won't work. And I have no clue why. Username and password2 are set.
  5. It works now. It was some bug, I guess
  6. https://upload.mtasa.com/u/102502036/[crown]login.zip_ Anyways, it gives me "Unexpected end of archive" on almost all resources i download.
  7. So... I downloaded many resources for server... And all of them are corrupted zip files... Why is this happening? Sometimes i can't even download the file!
×
×
  • Create New...