DARIOcaptain Posted March 26, 2020 Share Posted March 26, 2020 Hello everyone, I just started my adventure with scripting in MTA, I have some basic knowledge, but I have problems with finding some tutorials on the internet, so I have decided to start a new topic for my question. I already made SQLite database and now I want to create a basic login-panel GUI and connect it to database. Please keep in mind that I'm beginner. Thanks for help. Link to comment
Moderators Patrick Posted March 26, 2020 Moderators Share Posted March 26, 2020 (edited) Hi! You need to use dbConnect to connect databases. (both MySQL / SQLite) For the GUI, you need: guiCreateWindow - background window guiCreateLabel - texts guiCreateEdit - inputs guiCreateButton - buttons guiGetText - get input's text onClientGUIClick - detect when client push to button (event) triggerServerEvent - send datas to server side You can use default login/register functions addAccount - add new account (register) getAccount - get the account from username and password logIn - login player the the account Or do your own account system, with database. Edited March 26, 2020 by Patrick 1 Link to comment
DARIOcaptain Posted March 26, 2020 Author Share Posted March 26, 2020 No I don't have account system, as I said I'm a beginner and I don't know to write it. I only have database, but there is nothing in it. Thanks for reply, I will try it. Link to comment
Moderators Patrick Posted March 26, 2020 Moderators Share Posted March 26, 2020 6 minutes ago, DARIOcaptain said: No I don't have account system, as I said I'm a beginner and I don't know to write it. I only have database, but there is nothing in it. Thanks for reply, I will try it. Some tutorial: https://www.youtube.com/watch?v=0S0k9ny3d4M (Check the whole channel) https://forum.multitheftauto.com/topic/121619-Lua-for-absolute-beginners https://forum.multitheftauto.com/topic/95654-tut-debugging/ https://forum.multitheftauto.com/topic/114541-tut-events/ 1 Link to comment
DARIOcaptain Posted March 26, 2020 Author Share Posted March 26, 2020 Oh, thank you very much for this tutorial. I will learn it and then I will progress. Link to comment
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now