Jump to content

Lloyd Logan

Members
  • Content Count

    642
  • Joined

  • Last visited

Everything posted by Lloyd Logan

  1. It works! But, can you explain gsub
  2. Thanks for the triggerClientEvent, i'll change that! But, the real problem was addEventHandler, when it should have bee addEvent! Oh my bad, I didn't see that error. Such simple things! Thanks again
  3. Thanks for the triggerClientEvent, i'll change that! But, the real problem was addEventHandler, when it should have bee addEvent!
  4. Lloyd Logan

    Editbox

    Why does this say there is no text in the editbox even if there is? function checkRegField() inputusernamereg = guiGetText(GUIEditor.edituserreg) inputpasswordreg = guiGetText(GUIEditor.editpassreg) if inputusernamereg or inputpasswordreg == "" then guiSetVisible (GUIEditor.window[2], true ) guiBringToFront ( GUIEditor.window[2] ) else triggerServerEvent("submitRegister", getRootElement(), inputusernamereg, inputpasswordreg) end end
  5. Sorry, I should've been more specific, line 9 should be triggered to show, but line 2 should be triggered to hide!
  6. Why isn't this closing the GUI? SERVER function submitReg() dbExec(server, "CREATE TABLE IF NOT EXISTS accounts (accountname TEXT, password TEXT)") new = dbExec(server, "INSERT INTO accounts VALUES (accountname, password)", inputusernamereg, inputpasswordreg) output = outputChatBox("You have successfully created an account!") if new == true then triggerClientEvent("closedok", getRootElement()) triggerClientEvent("onErrorok", getRootElement()) end end addEvent( "submitRegister", true ) addEventHandler( "submitRegister", root, submitReg ) CLIENT f
  7. So there isn't a need for the variable 'server'?
  8. You're right, how does this look? local user = "root" local pass = "" local host = "127.0.0.1" local db = "servermta" server = dbConnect ( "mysql", "dbname=servermta;host=127.0.0.1","root")
  9. I tried adding an all privileged account, name = lloyd and pass = mtaserver, but still the same
  10. Lloyd Logan

    MySQL

    Hi, why isn't this working, it's saying access denied for user local user = "root" local pass = "" local host = "127.0.0.1" local db = "accounts" server = dbConnect ( "mysql", "dbname=accounts;host=127.0.0.1") Thanks
  11. Thanks for your time, I've have fixed it!
  12. Hmm, It is not showing the GUI when the register button is pressed, any ideas?
  13. Hey, So from my experience with Java, if a field is empty it equals to null . So, if I want to check if an edit box has no letters/words in it, how would i go about it? So far i got; function checkRegField() inputusername = guiGetText(editusername) if inputusername == "" then guiSetVisible (GUIEditor.window[2], not guiGetVisible ( GUIEditor.window[2] ) ) end end Thanks Lloyd
  14. Nah, my Internet is fine.
  15. Could you either, post your code here, or PM it to me!
  16. You mean edit the .img or using the GUI creator?
  17. Mad I may be, but I have a no complaints about it yet, so all is good for now!
  18. Thank you very, Highly appreciate that Anytime!
  19. dxDrawText If you are a scripter. or create it using this http://community.mtasa.com/index.php?p= ... ils&id=141 Thanks
  20. Yeah, he will have to getAccountData then setAccountData !
  21. I will go now, but I didn't know that language had numbers in it? Not really, some words that WE have doesn't exist at the English/latin alphabet, so we use numbers instead. Aha, you learn something new everyday! Oh, better get out of this section! Before i am حذر
×
×
  • Create New...