Guest User

Untitled

a guest
Jan 7th, 2017
31
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.74 KB | None | 0 0
  1. function createAdminAccount(thePlayer, command, username, password)
  2. if getElementData(thePlayer, "adminlevel") >= 7 then
  3. if not (username) or not (password) then
  4. outputChatBox("#acd373[Freedom Gaming - Használat]: #ffffff/" .. command .. " [Felhasználónév] [Jelszó]", thePlayer, 255, 0, 0, true)
  5. else
  6. local query = dbExec(connection, "INSERT INTO admins SET username = ?, password = ?",username,password)
  7. if query then
  8. outputChatBox("#acd373[Freedom Gaming - Admins]: #ffffffHozzáadva!", thePlayer, 255, 0, 0, true)
  9. else
  10. outputChatBox("#acd373[Freedom Gaming - Admins] #ffffffMySQL Hiba [#001-es kód]", thePlayer, 255, 0, 0, true)
  11. end
  12. end
  13. end
  14. end
  15. addCommandHandler("createadminaccount", createAdminAccount)
Add Comment
Please, Sign In to add comment