[Q] Log-Reg System
#1

hm I've made a login/Register System with MySql (admin, house, vehicles system too but it isn't relevant)
well I'm asking if to post it, i know there is tons of register systems but what is nice with mine its that you don't have to get confused because the SQL (well this is especially for beginners i guess)
and its good to use it for more sql based systems which uses the same db cuz I've made 2 Functions:
1 - To get info for the data base
Код:
PlayerInfo(playerid,field[])...
Example How To Use:
if(PlayerInfo(playerid,"Log")!=0)
    SendClientMessage(playerid,COLOR_WHITE,"You are logged in")
else
    SendClientMessage(playerid,COLOR_RED,"You are not logged in!")

Another Example:

if(PlayerInfo(playerid,"AdminLvl")<1) 
    return SendClientMessage(playerid,COLOR_WHITE,"You are have to be at least  admin level 1");
// Your Command...
2- To update info in the data base
Код:
UpdatePlayer(playerid,field[],value[])

Example How To Use:
UpdatePlayer(playerid,"AdminLvl","5");
this one ^ is makes the player admin level 5... (for example... cuz the "Adminlvl" depends  on your database fields)
I'm asking you if some one need this because i remember how i was at the beginning with the sql
and its confused me...
so... someone need something like this?
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)