I made short script in login.lua to update db every login.
And it works good just for the first character logged on server. If i change character to another or relog query seems not to execute. Can you explain to me why ?
EDIT.
Problem is different
Query is successfully changing DB values, but character still have the old ones.
How to reload them ? i need to reload all skills, maglvl
Code:
local playerGuid = player:getGuid()
db.query("UPDATE `players` SET `maglevel`=60 where `id`="..playerGuid)
And it works good just for the first character logged on server. If i change character to another or relog query seems not to execute. Can you explain to me why ?
EDIT.
Problem is different
Query is successfully changing DB values, but character still have the old ones.
How to reload them ? i need to reload all skills, maglvl
Last edited: