Jump to content

MySQL Accounts 1.0.0

   (3 reviews)

1 Screenshot

About This File

GitHub Repository: https://github.com/RageMpOpenSource/RAGE-Accounts

A MySQL boilerplate to quickly create an account system without all the work. This handles both logging in and registration. This also utilised the delayedInitilisation feature added in RAGE:MP 1.1 to allow time for your database and any other assets on your server to be loaded first before allowing any user connections. By using this feature, this avoids any errors of users connecting before your resources are done loading. Read below for more information. A custom config file has also been used to easily change your database variables (username/database name/database password) and will allow you to easily add more configuration options going forward.

 

Features

  • CEF Login/Registration pages with error handling
  • Idle Kicker (Kicks any player who is sitting on the login/register pages after 60 seconds of no attempts)
  • Promise Based Loading
  • Easy Imported SQL into your MySQL Database

Installation

Prerequisites

  • NodeJS
  • MySQL Server (Fully setup)

Steps

  1. Download this resource and place it inside of your server folder
  2. Open your command prompt and change your directory of your command prompt to the server folder and then type npm install (You could also Shift + Right click inside your server folder and 'Open PowerShell window here' and type npm install if you don't know how to do this step)
  3. Head to packages/<folder>/settings.example.json and rename the file to settings.json (Remove the .example from the file name)
  4. Open up the settings.json file and edit the database details to connect to your server, if you're running it locally the default settings may be fine.
  5. Using the .sql file inside the server folder, run this inside your database to set it up (I won't be going into how to do this, Google "How to set up a MySQL server" if you don't know how to do this as I won't be offering support).
  6. Run your server, if there are no errors and it prints "Database connected successfully" then you're all done.

 

Looking for more information? Look at the GitHub repository here: https://github.com/RageMpOpenSource/RAGE-Accounts

  • Like 4

User Feedback

Recommended Comments

In my case, I did everything following the instructions, but it does not write the data in the SQL database, I do not know if maybe it is because I am using a hosting instead of the localhost, could that be or why?

Link to comment
Share on other sites

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 account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...