Addon MAX SITE REBORN SYSTEM
#1

This script will work on MaX Entertament No purchased MaX Site fail to use my script

Buy 2

2

 

 

$playerz = $_POST[Name];
mysql_select_db( $SiteSQL["config-database_db"] , $Site_sqlcon) or die( mysql_error() );
$chars_info = mysql_query("SELECT a_index, a_user_index, a_name, a_level, a_max_hp, a_str, a_dex, a_int, a_con, a_teach_complete, a_job, a_job2, a_reborn, a_exp, a_statpt_remain FROM t_characters WHERE a_name = $playerz");

$r = 1;
$t = 1;
while( $row = mysql_fetch_array( $chars_info ) )
{

if (($row[a_level] >= 150) && ($row[a_reborn] < 5))
{
$doreborn = mysql_query("UPDATE t_characters SET a_level=1, a_exp=0, a_reborn=(a_reborn+1),a_statpt_remain=(a_statpt_remain+250) WHERE a_name =".$row[a_name]." AND a_name = $playerz");
$rest = substr($row[a_index], -1);
echo "

Reborn Success";
}
else
{
echo "

Not meeting requirements";
}

$r++;
$t++;
}

?>

#2
I dont kno if im posting this in the right place but how do i add this to my site

#3

you forgot to say to ppl to add a column in t_characters called a_reborn with default 0 otherwise it will fail.

 

aight put the file reborn.php in your main folder and change those field :

 

[ATTACH=CONFIG]718[/ATTACH]

 

 

and in your template folder, change index.tlp. change the char block with this one :

 



{Name}
{Level}

#4
yea i just dint want to add our server web script

#5
i have just left the minimum, icon, name and lvl. The rest is not there.

#6

Ok I have used this an made it better, added to my next update release coming soon.

Options added to enable or disable the reborn system, set the char level needed for reborn and set the allowed amount of reborns per char all in the site setting.

#7
i was trying to add a cash system like 10mil per reborn but item are stored in 10 different table, and in 5 different column. That make a lot of union of table and a lot of possibilities.

#8

why not add a reborn npc that sells a reborn ticket Smile

Then just use this to find the item:

 

$userid = $User->ID;
$end = substr("$userid", -1);
$table="t_inven0".$end;

$sql = "SELECT * FROM ".$table." WHERE
a_item_idx0 = your ticket index OR
a_item_idx1 = your ticket index OR
a_item_idx2 = your ticket index OR
a_item_idx3 = your ticket index OR
a_item_idx4 = your ticket index
";

 

That code could be wrong or there will be a better way to do the $sql im not pro php scripter Smile

#9
yes, that could be done. NPC sell a ticket that price of the reborn, then when you reborn, the item is deleted. But have no cash issue is ok too ;p

#10

pls any one help me how i add reborn at max hompage

and i click at buy lc cash i dont see any think pls what i do



Forum Jump:


Users browsing this thread: 1 Guest(s)