Convert File Script to MySQL Script - Printable Version
+- SA-MP Forums Archive (
https://sampforum.blast.hk)
+-- Forum: SA-MP Server (
https://sampforum.blast.hk/forumdisplay.php?fid=6)
+--- Forum: Server Support (
https://sampforum.blast.hk/forumdisplay.php?fid=19)
+--- Thread: Convert File Script to MySQL Script (
/showthread.php?tid=315384)
Convert File Script to MySQL Script -
Jeroen52 - 02.02.2012
Hello,
I have a good running server but lately I have the urge to store it all in a central database.
I have modified a INI to MySQL program to also convert SAV files to .mysql files.
I want to change my code from saving with (example):
!EXAMPLE!>>
dUserSetINT(PlayerName(playerid)).("Bankcash",Bank Cash[playerid]);
dUserSetINT(PlayerName(playerid)).("Money",Money[playerid]);
<<!EXAMPLE!
To MySQL and I want to know if it saves with Quote Marks or not, it is important for the Conversion.
I also want to change the reading from the MySQL Database from this example:
!EXAMPLE!>>
BankCash[playerid] =dUserINT(PlayerName(playerid)).("Bankcash");
GivePlayerMoney(playerid,dUserINT(PlayerName(playe rid)).("Money")-GetPlayerMoney(playerid));
<<!EXAMPLE!
The person who helps me enoungh to change the system from files to MySQL will get Rep'd and will receive VIP Level 2 on my Server.