Advertisement
Guest User

Untitled

a guest
Jan 24th, 2020
138
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.95 KB | None | 0 0
  1. function registroS(user, clave)
  2. if(addAccount(user, clave)) then
  3. outputChatBox("Usted se registro con exito!!", source, 0, 255, 0, true)
  4. triggerClientEvent(source,"cerrarPanel", source)
  5. logIn(source, getAccount(user, clave), clave)
  6. else
  7. outputChatBox("Esta cuenta ya existe!", source, 255, 0, 0, true)
  8. end
  9.  
  10. end
  11.  
  12. addEvent("RegistrarUsuario", true)
  13. addEventHandler("RegistrarUsuario", root, registroS)
  14.  
  15.  
  16. function loginS(user, clave)
  17.  
  18. usuario = getAccount(user, clave)
  19. if (cuenta) then
  20. outputChatBox("Te has logeado con exito!!!", source, 255, 0, 0, true)
  21. triggerClientEvent (source, "cerrarPanel2", source)
  22. logIn(source, getAccount(user, clave), clave)
  23. else
  24. outputChatBox("No existe usuario o la clave es incorrecta!!", source, 255, 0, 0, true)
  25.  
  26. end
  27. end
  28.  
  29. addEvent("UserLogeado", true)
  30. addEventHandler("UserLogeado", root, registroS)
  31.  
  32. addEventHandler("onPlayerJoin", root, function()
  33. triggerClientEvent(source, "abrirPanel", source)
  34. end)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement