Hey there.
I would like you, then I say that his first work.
Quest and I wrote a database with the help of a simple quest :)
Is to find out exactly determine when a game is up
Oh, and to give the player the status of a table column named integer type ;)
Sorry about Google Translate :S
Happy new year EPVP :3
I would like you, then I say that his first work.
Quest and I wrote a database with the help of a simple quest :)
Is to find out exactly determine when a game is up
Code:
quest status begin
state start begin
when login begin
local mysql_user = "mt2"
local mysql_pw = "metin2"
local player_id = tonumber(pc.get_player_id())
local status = 1
local mysql_query = "UPDATE player.player SET status ="..status.." WHERE id = "..player_id..";"
os.execute("mysql --host=localhost --user="..mysql_user.." --password="..mysql_pw.." --execute='"..mysql_query.."'")
chat("Log In")
end
when logout begin
local mysql_user = "mt2"
local mysql_pw = "metin2"
local player_id = tonumber(pc.get_player_id())
local status = 0
local mysql_query = "UPDATE player.player SET status ="..status.." WHERE id = "..player_id..";"
os.execute("mysql --host=localhost --user="..mysql_user.." --password="..mysql_pw.." --execute='"..mysql_query.."'")
chat("Log Out")
end
end
end
Oh, and to give the player the status of a table column named integer type ;)
Sorry about Google Translate :S
Happy new year EPVP :3