Jhosef Posted June 28, 2012 Posted June 28, 2012 (edited) i just want to reset the stats of all my player in the server is this correct update `char` set str=1,agi=1,vit=1,`int`=1,dex=1,luk=1; update `char` set status_point = ( 45 + ( base_level %5 ) * floor( base_level /5 ) + base_level *3 + floor( ( floor( ( base_level -5 )/5 ) * ( 10 + ( floor( ( base_level -5 )/5 ) -1 ) * 5 ) ) /2 ) ) where base_level > 5; update `char` set status_point = status_point + 52 where class >= 4001 and class <= 4022; Edited June 28, 2012 by Jhosef Quote
Yanji Posted June 28, 2012 Posted June 28, 2012 I don't think you can use the second SQL query, but I'm not completely sure about it, but the first and third queries look good to me. (Not a SQL expert, so I might be wrong) Quote
Rikimaru Posted June 28, 2012 Posted June 28, 2012 I tested the following SQL Script on my SQL Database and it worked : UPDATE `char` set `str`=1,`agi`=1,`vit`=1,`int`=1,`dex`=1,`luk`=1; UPDATE `char` set `status_point` = (45+(base_level*160)) where `base_level`>5; UPDATE `char` set `status_point` = (status_point+52) where class >= 4001 and class <= 4022; Quote
Question
Jhosef
i just want to reset the stats of all my player in the server
is this correct
update `char` set str=1,agi=1,vit=1,`int`=1,dex=1,luk=1;
update `char` set status_point = ( 45 + ( base_level %5 ) * floor( base_level /5 ) + base_level *3 + floor( ( floor( ( base_level -5 )/5 ) * ( 10 + ( floor( ( base_level -5 )/5 ) -1 ) * 5 ) ) /2 ) ) where base_level > 5;
update `char` set status_point = status_point + 52 where class >= 4001 and class <= 4022;
Edited by Jhosef3 answers to this question
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.