-
Novice
Set level to start for each reset
Hello guys, I need to edit the muweb 0.9 reset query.
I will make that:
1reset restart from lvl150
2reset restart from lvl150
3reset restart from lvl200
and so on, but I don't know very well how to do it.
The normal query for the reset in muweb 0.9 looks like this:
if($TR[5] == 1 && $TR[4] == 1){ $j_43_k = "Update character set [strength]='25',[dexterity]='25',[vitality]='25',[energy]='25',[clevel]='1',[experience]='1000000000',[money]=?,[LevelUpPoint]='$ex_l',[resets]=? where mu_id=?"; }
elseif ($TR[5] == 0 && $TR[4] == 1){ $j_43_k = "Update character set [clevel]='1',[experience]='1000000000',[money]=?,[LevelUpPoint]='$ex_l',[resets]=? where mu_id=?"; }
elseif ($TR[5] == 0 && $TR[4] == 0){ $j_43_k = "Update character set [clevel]='1',[experience]='1000000000',[money]=?,[LevelUpPoint]='$nr_l',[resets]=? where mu_id=?"; }
elseif ($TR[5] == 1 && $TR[4] == 0){ $j_43_k = "Update character set [strength]='25',[dexterity]='25',[vitality]='25',[energy]='25',[clevel]='1',[experience]='1000000000',[money]=?,[LevelUpPoint]='$nr_l',[resets]=? where mu_id=?"; }
Can someone help me?
Last edited by Paolo Forti; 25-01-14 at 02:37 PM.
-
-
Account Upgraded | Title Enabled!
Re: Set level to start for each reset
first of you need to make a separate if function and im guessing tr could be used to look at a spot on the table that would be defined like example:
$tr = mssql_query("Select resets,name,class,mu_id from character where accountID ='".$_SESSION['user_login_name']."' and mu_id=? ");
And lets say the persons resets are 3
and then you could put
if ($tr[0] > $tr[0] - 1 and $tr[2] == '16' ) { mssql_query("Update Character Set clevel = ' 200 ' , experience = '123124234234(idk amount you figure it out)' , etc etc etc where mu_id = '".$tr[3]."' ") ; }
or theres a bunch of other ways you can do it
Personally knowing that TR is exploded of some other stuff in muweb just go to where where its defined that whatever = tr and trace it back to where the -->execute function is, and just put whatever else you want TR to pull up and then put the corresponding number and then you can easily just do example: if ($tr[9] > $tr[9] - 1) or if you get confused you can do
$lalal = $tr[9] - 1 ;
if ($tr[9] > $lalal )
and no that TR[9] has no value i was just using it for example