

lemooca
-
Posts
19 -
Joined
-
Last visited
Reputation Activity
-
lemooca reacted to mascumbado in [GESIOR] VictorWEBMaster 2019v
Nuss que massa, teu site é mto foda mesmo kra, está de parabéns, tirando lá o erro que tem mas é bem simples de vender item vip na parte vip no shop, ta show de bola, parabéns pelo trabalho
REP +
Ae brother, eu arrumei lá o erro que vc n conseguiu arrumar dos items vip. Se quiser ta ai.
<?PHP
if($config['site']['shop_system'] == 1) {
if($logged)
$user_premium_points = $account_logged->getCustomField('premium_points');
else
$user_premium_points = 'Login first';
function getItemByID($id)
{
$id = (int) $id;
$SQL = $GLOBALS['SQL'];
$data = $SQL->query('SELECT * FROM '.$SQL->tableName('z_shop_offer').' WHERE '.$SQL->fieldName('id').' = '.$SQL->quote($id).';')->fetch();
if ($data['offer_type'] == 'pacc')
{
$offer['id'] = $data['id'];
$offer['type'] = $data['offer_type'];
$offer['days'] = $data['count1'];
$offer['points'] = $data['points'];
$offer['description'] = $data['offer_description'];
$offer['name'] = $data['offer_name'];
}
elseif ($data['offer_type'] == 'item')
{
$offer['id'] = $data['id'];
$offer['type'] = $data['offer_type'];
$offer['item_id'] = $data['itemid1'];
$offer['item_count'] = $data['count1'];
$offer['points'] = $data['points'];
$offer['description'] = $data['offer_description'];
$offer['name'] = $data['offer_name'];
}
elseif ($data['offer_type'] == 'vipdays')
{
$offer['id'] = $data['id'];
$offer['type'] = $data['offer_type'];
$offer['days'] = $data['count1'];
$offer['points'] = $data['points'];
$offer['description'] = $data['offer_description'];
$offer['name'] = $data['offer_name'];
}
elseif ($data['offer_type'] == 'itemvip')
{
$offer['id'] = $data['id'];
$offer['type'] = $data['offer_type'];
$offer['item_id'] = $data['itemid1'];
$offer['item_count'] = $data['count1'];
$offer['points'] = $data['points'];
$offer['description'] = $data['offer_description'];
$offer['name'] = $data['offer_name'];
}
elseif ($data['offer_type'] == 'container')
{
$offer['id'] = $data['id'];
$offer['type'] = $data['offer_type'];
$offer['container_id'] = $data['itemid2'];
$offer['container_count'] = $data['count2'];
$offer['item_id'] = $data['itemid1'];
$offer['item_count'] = $data['count1'];
$offer['points'] = $data['points'];
$offer['description'] = $data['offer_description'];
$offer['name'] = $data['offer_name'];
}
elseif ($data['offer_type'] == 'unban')
{
$offer['id'] = $data['id'];
$offer['type'] = $data['offer_type'];
$offer['points'] = $data['points'];
$offer['description'] = $data['offer_description'];
$offer['name'] = $data['offer_name'];
}
elseif ($data['offer_type'] == 'redskull')
{
$offer['id'] = $data['id'];
$offer['type'] = $data['offer_type'];
$offer['points'] = $data['points'];
$offer['description'] = $data['offer_description'];
$offer['name'] = $data['offer_name'];
}
elseif ($data['offer_type'] == 'itemlogout')
{
$offer['id'] = $data['id'];
$offer['type'] = $data['offer_type'];
$offer['points'] = $data['points'];
$offer['description'] = $data['offer_description'];
$offer['pid'] = $data['pid'];
$offer['count1'] = $data['count1'];
$offer['item_id'] = $data['itemid1'];
$offer['free_cap'] = $data['free_cap'];
}
elseif ($data['offer_type'] == 'changename')
{
$offer['id'] = $data['id'];
$offer['type'] = $data['offer_type'];
$offer['points'] = $data['points'];
$offer['description'] = $data['offer_description'];
$offer['name'] = $data['offer_name'];
}
return $offer;
}
function getOfferArray()
{
$offer_list = $GLOBALS['SQL']->query('SELECT * FROM '.$GLOBALS['SQL']->tableName('z_shop_offer').';');
$i_pacc = 0;
$i_item = 0;
$i_vipdays = 0;
$i_itemvip = 0;
$i_container = 0;
$i_unban = 0;
$i_redskull = 0;
$i_itemlogout = 0;
$i_changename = 0;
while($data = $offer_list->fetch()) {
if ($data['offer_type'] == 'pacc')
{
$offer_array['pacc'][$i_pacc]['id'] = $data['id'];
$offer_array['pacc'][$i_pacc]['days'] = $data['count1'];
$offer_array['pacc'][$i_pacc]['points'] = $data['points'];
$offer_array['pacc'][$i_pacc]['description'] = $data['offer_description'];
$offer_array['pacc'][$i_pacc]['name'] = $data['offer_name'];
$i_pacc++;
}
elseif ($data['offer_type'] == 'item')
{
$offer_array['item'][$i_item]['id'] = $data['id'];
$offer_array['item'][$i_item]['item_id'] = $data['itemid1'];
$offer_array['item'][$i_item]['item_count'] = $data['count1'];
$offer_array['item'][$i_item]['points'] = $data['points'];
$offer_array['item'][$i_item]['description'] = $data['offer_description'];
$offer_array['item'][$i_item]['name'] = $data['offer_name'];
$i_item++;
}
elseif ($data['offer_type'] == 'vipdays')
{
$offer_array['vipdays'][$i_vipdays]['id'] = $data['id'];
$offer_array['vipdays'][$i_vipdays]['days'] = $data['count1'];
$offer_array['vipdays'][$i_vipdays]['points'] = $data['points'];
$offer_array['vipdays'][$i_vipdays]['description'] = $data['offer_description'];
$offer_array['vipdays'][$i_vipdays]['name'] = $data['offer_name'];
$i_vipdays++;
}
elseif ($data['offer_type'] == 'itemvip')
{
$offer_array['itemvip'][$i_itemvip]['id'] = $data['id'];
$offer_array['itemvip'][$i_itemvip]['item_id'] = $data['itemid1'];
$offer_array['itemvip'][$i_itemvip]['item_count'] = $data['count1'];
$offer_array['itemvip'][$i_itemvip]['points'] = $data['points'];
$offer_array['itemvip'][$i_itemvip]['description'] = $data['offer_description'];
$offer_array['itemvip'][$i_itemvip]['name'] = $data['offer_name'];
$i_itemvip++;
}
elseif ($data['offer_type'] == 'container')
{
$offer_array['container'][$i_container]['id'] = $data['id'];
$offer_array['container'][$i_container]['container_id'] = $data['itemid2'];
$offer_array['container'][$i_container]['container_count'] = $data['count2'];
$offer_array['container'][$i_container]['item_id'] = $data['itemid1'];
$offer_array['container'][$i_container]['item_count'] = $data['count1'];
$offer_array['container'][$i_container]['points'] = $data['points'];
$offer_array['container'][$i_container]['description'] = $data['offer_description'];
$offer_array['container'][$i_container]['name'] = $data['offer_name'];
$i_container++;
}
elseif ($data['offer_type'] == 'unban')
{
$offer_array['unban'][$i_unban]['id'] = $data['id'];
$offer_array['unban'][$i_unban]['points'] = $data['points'];
$offer_array['unban'][$i_unban]['description'] = $data['offer_description'];
$offer_array['unban'][$i_unban]['name'] = $data['offer_name'];
$i_unban++;
}
elseif ($data['offer_type'] == 'redskull')
{
$offer_array['redskull'][$i_redskull]['id'] = $data['id'];
$offer_array['redskull'][$i_redskull]['points'] = $data['points'];
$offer_array['redskull'][$i_redskull]['description'] = $data['offer_description'];
$offer_array['redskull'][$i_redskull]['name'] = $data['offer_name'];
$i_redskull++;
}
elseif ($data['offer_type'] == 'itemlogout')
{
$offer_array['itemlogout'][$i_itemlogout]['id'] = $data['id'];
$offer_array['itemlogout'][$i_itemlogout]['points'] = $data['points'];
$offer_array['itemlogout'][$i_itemlogout]['description'] = $data['offer_description'];
$offer_array['itemlogout'][$i_itemlogout]['name'] = $data['offer_name'];
$offer_array['itemlogout'][$i_itemlogout]['count1'] = $data['count1'];
$offer_array['itemlogout'][$i_itemlogout]['pid'] = $data['pid'];
$offer_array['itemlogout'][$i_itemlogout]['item_id'] = $data['itemid1'];
$offer_array['itemlogout'][$i_itemlogout]['free_cap'] = $data['free_cap'];
$i_itemlogout++;
}
elseif ($data['offer_type'] == 'changename')
{
$offer_array['changename'][$i_changename]['id'] = $data['id'];
$offer_array['changename'][$i_changename]['points'] = $data['points'];
$offer_array['changename'][$i_changename]['description'] = $data['offer_description'];
$offer_array['changename'][$i_changename]['name'] = $data['offer_name'];
$i_changename++;
}
}
return $offer_array;
}
if($action == '') {
unset($_SESSION['viewed_confirmation_page']);
$main_content .= '<h2><center>Welcome to '.$config['server']['serverName'].' Shop</center></h2>';
$offer_list = getOfferArray();
//show list of vipdays offers
if(count($offer_list['vipdays']) > 0) {
$main_content .= '
<div class="TableContainer">
<div class="CaptionContainer">
<div class="CaptionInnerContainer">
<span class="CaptionEdgeLeftTop" style="background-image:url('.$layout_name.'/images/content/box-frame-edge.gif);"></span>
<span class="CaptionEdgeRightTop" style="background-image:url('.$layout_name.'/images/content/box-frame-edge.gif);"></span>
<span class="CaptionBorderTop" style="background-image:url('.$layout_name.'/images/content/table-headline-border.gif);"></span>
<span class="CaptionVerticalLeft" style="background-image:url('.$layout_name.'/images/content/box-frame-vertical.gif);"></span>
<div class="Text">Enhance Account</div>
<span class="CaptionVerticalRight" style="background-image:url('.$layout_name.'/images/content/box-frame-vertical.gif);"></span>
<span class="CaptionBorderBottom" style="background-image:url('.$layout_name.'/images/content/table-headline-border.gif);"></span>
<span class="CaptionEdgeLeftBottom" style="background-image:url('.$layout_name.'/images/content/box-frame-edge.gif);"></span>
<span class="CaptionEdgeRightBottom" style="background-image:url('.$layout_name.'/images/content/box-frame-edge.gif);"></span>
</div>
</div>
<table class="Table5" cellpadding="0" cellspacing="0">
<tbody>
<tr>
<td>
<div class="InnerTableContainer">
<table style="width:100%;">
<tbody>
<tr>
<td>
<div class="TableShadowContainerRightTop">
<div class="TableShadowRightTop" style="background-image:url('.$layout_name.'/images/content/table-shadow-rt.gif);"></div>
</div><div class="TableContentAndRightShadow" style="background-image:url('.$layout_name.'/images/content/table-shadow-rm.gif);">
<div class="TableContentContainer">
<table class="TableContent" style="border:1px solid #faf0d7;" width="100%">
<tbody>
<tr bgcolor="#D4C0A1">
<td valign="middle" align="center"><b>Product</b></td>
<td valign="middle" width="60%"><b>Description</b></td>
<td valign="middle"> </td>
</tr>';
foreach($offer_list['vipdays'] as $vipdays) {
if(!is_int($number_of_rows / 2)) { $bgcolor = $config['site']['lightborder']; } else { $bgcolor = $config['site']['darkborder']; } $number_of_rows++;
$main_content .= '<tr bgcolor="'.$config['site']['lightborder'].'"><td valign="middle" align="center"><img src="images/shop/vip.gif" /></td><td><b>'.$vipdays['name'].'</b> ('.$vipdays['points'].' points)<br />'.$vipdays['description'].'</td><td align="center">';
if(!$logged) $main_content .= '<input type="button" value="Login First" disabled="disabled" />'; else
$main_content .= '<form action="index.php?subtopic=shopsystem&action=select_player" method=POST><input type="hidden" name="buy_id" value="'.$vipdays['id'].'"><input type="submit" value="Comprar" /></form>';
$main_content .= '</td></tr>';
}
$main_content .= '</tbody>
</table>
</div>
</div>
<div class="TableShadowContainer">
<div class="TableBottomShadow" style="background-image:url('.$layout_name.'/images/content/table-shadow-bm.gif);">
<div class="TableBottomLeftShadow" style="background-image:url('.$layout_name.'/images/content/table-shadow-bl.gif);"></div>
<div class="TableBottomRightShadow" style="background-image:url('.$layout_name.'/images/content/table-shadow-br.gif);"></div>
</div>
</div>
</td>
</tr>
</tbody>
</table>
</div>
</td>
</tr>
</tbody>
</table>
</div><br />';}
//show list of itemsvip offers
if(count($offer_list['itemvip']) > 0) {
$main_content .= '
<div class="TableContainer">
<div class="CaptionContainer">
<div class="CaptionInnerContainer">
<span class="CaptionEdgeLeftTop" style="background-image:url('.$layout_name.'/images/content/box-frame-edge.gif);"></span>
<span class="CaptionEdgeRightTop" style="background-image:url('.$layout_name.'/images/content/box-frame-edge.gif);"></span>
<span class="CaptionBorderTop" style="background-image:url('.$layout_name.'/images/content/table-headline-border.gif);"></span>
<span class="CaptionVerticalLeft" style="background-image:url('.$layout_name.'/images/content/box-frame-vertical.gif);"></span>
<div class="Text">Enhance Account</div>
<span class="CaptionVerticalRight" style="background-image:url('.$layout_name.'/images/content/box-frame-vertical.gif);"></span>
<span class="CaptionBorderBottom" style="background-image:url('.$layout_name.'/images/content/table-headline-border.gif);"></span>
<span class="CaptionEdgeLeftBottom" style="background-image:url('.$layout_name.'/images/content/box-frame-edge.gif);"></span>
<span class="CaptionEdgeRightBottom" style="background-image:url('.$layout_name.'/images/content/box-frame-edge.gif);"></span>
</div>
</div>
<table class="Table5" cellpadding="0" cellspacing="0">
<tbody>
<tr>
<td>
<div class="InnerTableContainer">
<table style="width:100%;">
<tbody>
<tr>
<td>
<div class="TableShadowContainerRightTop">
<div class="TableShadowRightTop" style="background-image:url('.$layout_name.'/images/content/table-shadow-rt.gif);"></div>
</div><div class="TableContentAndRightShadow" style="background-image:url('.$layout_name.'/images/content/table-shadow-rm.gif);">
<div class="TableContentContainer">
<table class="TableContent" style="border:1px solid #faf0d7;" width="100%">
<tbody>
<tr bgcolor="#D4C0A1">
<td valign="middle" align="center"><b>Product</b></td>
<td valign="middle" width="60%"><b>Description</b></td>
<td valign="middle"> </td>
</tr>';
foreach($offer_list['itemvip'] as $itemvip) {
if(!is_int($number_of_rows / 2)) { $bgcolor = $config['site']['lightborder']; } else { $bgcolor = $config['site']['darkborder']; } $number_of_rows++;
$main_content .= '<tr bgcolor="'.$config['site']['lightborder'].'"><td valign="middle" align="center">'; if(file_exists('images/items/'.$itemvip['item_id'].'.gif')) { $main_content .= '<br /><img src="images/items/'.$itemvip['item_id'].'.gif" height="32" width="32"><br /><small><b>'.$itemvip['name'].'</b></small><br /> '; } else { $main_content .= '<br /> <img src="images/monsters/nophoto.png" height="32" width="32"><br /><small><b>'.$itemvip['name'].'</b></small>'; }
$main_content .='</td><td><b>'.$itemvip['name'].'</b> ('.$itemvip['points'].' points)<br />'.$itemvip['description'].'</td><td align="center">';
if(!$logged) $main_content .= '<input type="button" value="Login First" disabled="disabled" />'; else
$main_content .= '<form action="index.php?subtopic=shopsystem&action=select_player" method=POST>
<input type="hidden" name="buy_id" value="'.$itemvip['id'].'">
<table border="0" cellpadding="0" cellspacing="0">
<tbody>
<tr>
<td style="border: 0px none;">
<div class="BigButton" style="background-image: url('.$layout_name.'/images/buttons/sbutton.gif);">
<div onmouseover="MouseOverBigButton(this);" onmouseout="MouseOutBigButton(this);"><div class="BigButtonOver" style="background-image: url('.$layout_name.'/images/buttons/sbutton_over.gif);"></div>
<input class="ButtonText" name="Continue" alt="Continue" src="'.$layout_name.'/images/buttons/_sbutton_purchase.gif" type="image">
</div>
</div>
</td>
</tr>
</tbody>
</table>
</form>';
$main_content .= '</td></tr>';
}
$main_content .= '</tbody>
</table>
</div>
</div>
<div class="TableShadowContainer">
<div class="TableBottomShadow" style="background-image:url('.$layout_name.'/images/content/table-shadow-bm.gif);">
<div class="TableBottomLeftShadow" style="background-image:url('.$layout_name.'/images/content/table-shadow-bl.gif);"></div>
<div class="TableBottomRightShadow" style="background-image:url('.$layout_name.'/images/content/table-shadow-br.gif);"></div>
</div>
</div>
</td>
</tr>
</tbody>
</table>
</div>
</td>
</tr>
</tbody>
</table>
</div><br />';}
//show list of items offers
if(count($offer_list['item']) > 0 or count($offer_list['container']) > 0 or count($offer_list['itemlogout']) > 0)
$main_content .= '
<div class="TableContainer">
<div class="CaptionContainer">
<div class="CaptionInnerContainer">
<span class="CaptionEdgeLeftTop" style="background-image:url('.$layout_name.'/images/content/box-frame-edge.gif);"></span>
<span class="CaptionEdgeRightTop" style="background-image:url('.$layout_name.'/images/content/box-frame-edge.gif);"></span>
<span class="CaptionBorderTop" style="background-image:url('.$layout_name.'/images/content/table-headline-border.gif);"></span>
<span class="CaptionVerticalLeft" style="background-image:url('.$layout_name.'/images/content/box-frame-vertical.gif);"></span>
<div class="Text">Items</div>
<span class="CaptionVerticalRight" style="background-image:url('.$layout_name.'/images/content/box-frame-vertical.gif);"></span>
<span class="CaptionBorderBottom" style="background-image:url('.$layout_name.'/images/content/table-headline-border.gif);"></span>
<span class="CaptionEdgeLeftBottom" style="background-image:url('.$layout_name.'/images/content/box-frame-edge.gif);"></span>
<span class="CaptionEdgeRightBottom" style="background-image:url('.$layout_name.'/images/content/box-frame-edge.gif);"></span>
</div>
</div>
<table class="Table5" cellpadding="0" cellspacing="0">
<tbody>
<tr>
<td>
<div class="InnerTableContainer">
<table style="width:100%;">
<tbody>
<tr>
<td>
<div class="TableShadowContainerRightTop">
<div class="TableShadowRightTop" style="background-image:url('.$layout_name.'/images/content/table-shadow-rt.gif);"></div>
</div><div class="TableContentAndRightShadow" style="background-image:url('.$layout_name.'/images/content/table-shadow-rm.gif);">
<div class="TableContentContainer">
<table class="TableContent" style="border:1px solid #faf0d7;" width="100%">
<tbody>
<tr bgcolor="#D4C0A1">
<td valign="middle" align="center"><b>Product</b></td>
<td valign="middle" width="60%"><b>Description</b></td>
<td valign="middle"> </td>
</tr>';
if(count($offer_list['item']) > 0) {
foreach($offer_list['item'] as $item) {
if(!is_int($number_of_rows / 2)) { $bgcolor = $config['site']['lightborder']; } else { $bgcolor = $config['site']['darkborder']; } $number_of_rows++;
$main_content .= '
<tr bgcolor="'.$config['site']['lightborder'].'">
<td valign="middle" align="center">'; if(file_exists('images/items/'.$item['item_id'].'.gif')) { $main_content .= '<br /><img src="images/items/'.$item['item_id'].'.gif" height="32" width="32"><br /><small><b>'.$item['name'].'</b></small><br /> '; } else { $main_content .= '<br /> <img src="images/monsters/nophoto.png" height="32" width="32"><br /><small><b>'.$item['name'].'</b></small>'; }
$main_content .='</td>
<td>'.$item['description'].'<br /><small><b>('.$item['points'].'';
if ($item['points'] == 0)
$main_content .=' <o>no cost</o>';
if ($item['points'] >= 2)
$main_content .=' points';
else
$main_content .=' point';
$main_content .=')</b></small></td>
<td valign="middle" align="center">';
if(!$logged) $main_content .= '<input type="button" value="Login First" disabled="disabled" />'; else
$main_content .= '
<form action="index.php?subtopic=shopsystem&action=select_player" method="POST">
<input type="hidden" name="buy_id" value="'.$item['id'].'">
<table border="0" cellpadding="0" cellspacing="0">
<tbody>
<tr>
<td style="border: 0px none;">
<div class="BigButton" style="background-image: url('.$layout_name.'/images/buttons/sbutton.gif);">
<div onmouseover="MouseOverBigButton(this);" onmouseout="MouseOutBigButton(this);"><div class="BigButtonOver" style="background-image: url('.$layout_name.'/images/buttons/sbutton_over.gif);"></div>
<input class="ButtonText" name="Continue" alt="Continue" src="'.$layout_name.'/images/buttons/_sbutton_purchase.gif" type="image">
</div>
</div>
</td>
</tr>
</tbody>
</table>
</form>';
$main_content .= '</td></tr>';
}
$main_content .= '</tbody>
</table>
</div>
</div>
<div class="TableShadowContainer">
<div class="TableBottomShadow" style="background-image:url('.$layout_name.'/images/content/table-shadow-bm.gif);">
<div class="TableBottomLeftShadow" style="background-image:url('.$layout_name.'/images/content/table-shadow-bl.gif);"></div>
<div class="TableBottomRightShadow" style="background-image:url('.$layout_name.'/images/content/table-shadow-br.gif);"></div>
</div>
</div>
</td>
</tr>
</tbody>
</table>
</div>
</td>
</tr>
</tbody>
</table>
</div><br />';
}
//show list of containers offers
if(count($offer_list['container']) > 0) {
$main_content .= '
<div class="TableContainer">
<div class="CaptionContainer">
<div class="CaptionInnerContainer">
<span class="CaptionEdgeLeftTop" style="background-image:url('.$layout_name.'/images/content/box-frame-edge.gif);"></span>
<span class="CaptionEdgeRightTop" style="background-image:url('.$layout_name.'/images/content/box-frame-edge.gif);"></span>
<span class="CaptionBorderTop" style="background-image:url('.$layout_name.'/images/content/table-headline-border.gif);"></span>
<span class="CaptionVerticalLeft" style="background-image:url('.$layout_name.'/images/content/box-frame-vertical.gif);"></span>
<div class="Text">Containers Of Items</div>
<span class="CaptionVerticalRight" style="background-image:url('.$layout_name.'/images/content/box-frame-vertical.gif);"></span>
<span class="CaptionBorderBottom" style="background-image:url('.$layout_name.'/images/content/table-headline-border.gif);"></span>
<span class="CaptionEdgeLeftBottom" style="background-image:url('.$layout_name.'/images/content/box-frame-edge.gif);"></span>
<span class="CaptionEdgeRightBottom" style="background-image:url('.$layout_name.'/images/content/box-frame-edge.gif);"></span>
</div>
</div>
<table class="Table5" cellpadding="0" cellspacing="0">
<tbody>
<tr>
<td>
<div class="InnerTableContainer">
<table style="width:100%;">
<tbody>
<tr>
<td>
<div class="TableShadowContainerRightTop">
<div class="TableShadowRightTop" style="background-image:url('.$layout_name.'/images/content/table-shadow-rt.gif);"></div>
</div><div class="TableContentAndRightShadow" style="background-image:url('.$layout_name.'/images/content/table-shadow-rm.gif);">
<div class="TableContentContainer">
<table class="TableContent" style="border:1px solid #faf0d7;" width="100%">
<tbody>
<tr bgcolor="#D4C0A1">
<td valign="middle" align="center"><b>Product</b></td>
<td valign="middle" width="60%"><b>Description</b></td>
<td valign="middle"> </td>
</tr>';
foreach($offer_list['container'] as $container) {
if(!is_int($number_of_rows / 2)) { $bgcolor = $config['site']['lightborder']; } else { $bgcolor = $config['site']['darkborder']; } $number_of_rows++;
$main_content .= '<tr bgcolor="'.$config['site']['lightborder'].'"><td valign="middle" align="center">'; if(file_exists('images/items/'.$container['item_id'].'.gif')) { $main_content .= '<img src="images/items/'.$container['item_id'].'.gif" height="32" width="32">'; } else { $main_content .= '<img src="images/monsters/nophoto.png" height="32" width="32">'; } $main_content .='</td><td><b>'.$container['name'].'</b> ('.$container['points'].' points)<br />'.$container['description'].'</td><td align="center">';
if(!$logged) $main_content .= '<input type="button" value="Login First" disabled="disabled" />'; else
$main_content .= '
<form action="?subtopic=shopsystem&action=select_player" method="POST">
<input type="hidden" name="buy_id" value="'.$container['id'].'">
<table border="0" cellpadding="0" cellspacing="0">
<tbody>
<tr>
<td style="border: 0px none;">
<div class="BigButton" style="background-image: url('.$layout_name.'/images/buttons/sbutton.gif);">
<div onmouseover="MouseOverBigButton(this);" onmouseout="MouseOutBigButton(this);"><div class="BigButtonOver" style="background-image: url('.$layout_name.'/images/buttons/sbutton_over.gif);"></div>
<input class="ButtonText" name="Continue" alt="Continue" src="'.$layout_name.'/images/buttons/_sbutton_purchase.gif" type="image">
</div>
</div>
</td>
</tr>
</tbody>
</table>
</form>';
$main_content .= '</td></tr>';
}
$main_content .= '</tbody>
</table>
</div>
</div>
<div class="TableShadowContainer">
<div class="TableBottomShadow" style="background-image:url('.$layout_name.'/images/content/table-shadow-bm.gif);">
<div class="TableBottomLeftShadow" style="background-image:url('.$layout_name.'/images/content/table-shadow-bl.gif);"></div>
<div class="TableBottomRightShadow" style="background-image:url('.$layout_name.'/images/content/table-shadow-br.gif);"></div>
</div>
</div>
</td>
</tr>
</tbody>
</table>
</div>
</td>
</tr>
</tbody>
</table>
</div><br />';}
if(count($offer_list['itemlogout']) > 0) {
$main_content .= '
<div class="TableContainer">
<div class="CaptionContainer">
<div class="CaptionInnerContainer">
<span class="CaptionEdgeLeftTop" style="background-image:url('.$layout_name.'/images/content/box-frame-edge.gif);"></span>
<span class="CaptionEdgeRightTop" style="background-image:url('.$layout_name.'/images/content/box-frame-edge.gif);"></span>
<span class="CaptionBorderTop" style="background-image:url('.$layout_name.'/images/content/table-headline-border.gif);"></span>
<span class="CaptionVerticalLeft" style="background-image:url('.$layout_name.'/images/content/box-frame-vertical.gif);"></span>
<div class="Text">Items Logout</div>
<span class="CaptionVerticalRight" style="background-image:url('.$layout_name.'/images/content/box-frame-vertical.gif);"></span>
<span class="CaptionBorderBottom" style="background-image:url('.$layout_name.'/images/content/table-headline-border.gif);"></span>
<span class="CaptionEdgeLeftBottom" style="background-image:url('.$layout_name.'/images/content/box-frame-edge.gif);"></span>
<span class="CaptionEdgeRightBottom" style="background-image:url('.$layout_name.'/images/content/box-frame-edge.gif);"></span>
</div>
</div>
<table class="Table5" cellpadding="0" cellspacing="0">
<tbody>
<tr>
<td>
<div class="InnerTableContainer">
<table style="width:100%;">
<tbody>
<tr>
<td>
<div class="TableShadowContainerRightTop">
<div class="TableShadowRightTop" style="background-image:url('.$layout_name.'/images/content/table-shadow-rt.gif);"></div>
</div><div class="TableContentAndRightShadow" style="background-image:url('.$layout_name.'/images/content/table-shadow-rm.gif);">
<div class="TableContentContainer">
<table class="TableContent" style="border:1px solid #faf0d7;" width="100%">
<tbody>
<tr bgcolor="#D4C0A1">
<td valign="middle" align="center"><b>Product</b></td>
<td valign="middle" width="60%"><b>Description</b></td>
<td valign="middle"> </td>
</tr>';
foreach($offer_list['itemlogout'] as $itemlogout) {
if(!is_int($number_of_rows / 2)) { $bgcolor = $config['site']['lightborder']; } else { $bgcolor = $config['site']['darkborder']; } $number_of_rows++;
$main_content .= '<tr bgcolor="'.$config['site']['lightborder'].'"><td valign="middle" align="center"><img src="images/items/'.$itemlogout['id'].'.gif"></td><td><b>'.$itemlogout['name'].'</b> ('.$itemlogout['points'].' points)<br />'.$itemlogout['description'].'</td><td align="center">';
if(!$logged) $main_content .= '<input type="button" value="Login First" disabled="disabled" />'; else
$main_content .= '
<form action="index.php?subtopic=shopsystem&action=select_player" method=POST>
<input type="hidden" name="buy_id" value="'.$itemlogout['id'].'">
<table border="0" cellpadding="0" cellspacing="0">
<tbody>
<tr>
<td style="border: 0px none;">
<div class="BigButton" style="background-image: url('.$layout_name.'/images/buttons/sbutton.gif);">
<div onmouseover="MouseOverBigButton(this);" onmouseout="MouseOutBigButton(this);"><div class="BigButtonOver" style="background-image: url('.$layout_name.'/images/buttons/sbutton_over.gif);"></div>
<input class="ButtonText" name="Continue" alt="Continue" src="'.$layout_name.'/images/buttons/_sbutton_purchase.gif" type="image">
</div>
</div>
</td>
</tr>
</tbody>
</table>
</form>';
$main_content .= '</td></tr>';
}
$main_content .= '</tbody>
</table>
</div>
</div>
<div class="TableShadowContainer">
<div class="TableBottomShadow" style="background-image:url('.$layout_name.'/images/content/table-shadow-bm.gif);">
<div class="TableBottomLeftShadow" style="background-image:url('.$layout_name.'/images/content/table-shadow-bl.gif);"></div>
<div class="TableBottomRightShadow" style="background-image:url('.$layout_name.'/images/content/table-shadow-br.gif);"></div>
</div>
</div>
</td>
</tr>
</tbody>
</table>
</div>
</td>
</tr>
</tbody>
</table>
</div><br />';}
$main_content .= '
<div class="TableContainer">
<div class="CaptionContainer">
<div class="CaptionInnerContainer">
<span class="CaptionEdgeLeftTop" style="background-image:url('.$layout_name.'/images/content/box-frame-edge.gif);"></span>
<span class="CaptionEdgeRightTop" style="background-image:url('.$layout_name.'/images/content/box-frame-edge.gif);"></span>
<span class="CaptionBorderTop" style="background-image:url('.$layout_name.'/images/content/table-headline-border.gif);"></span>
<span class="CaptionVerticalLeft" style="background-image:url('.$layout_name.'/images/content/box-frame-vertical.gif);"></span>
<div class="Text">Items & Additional</div>
<span class="CaptionVerticalRight" style="background-image:url('.$layout_name.'/images/content/box-frame-vertical.gif);"></span>
<span class="CaptionBorderBottom" style="background-image:url('.$layout_name.'/images/content/table-headline-border.gif);"></span>
<span class="CaptionEdgeLeftBottom" style="background-image:url('.$layout_name.'/images/content/box-frame-edge.gif);"></span>
<span class="CaptionEdgeRightBottom" style="background-image:url('.$layout_name.'/images/content/box-frame-edge.gif);"></span>
</div>
</div>
<table class="Table5" cellpadding="0" cellspacing="0">
<tbody>
<tr>
<td>
<div class="InnerTableContainer">
<table style="width:100%;">
<tbody>
<tr>
<td>
<div class="TableShadowContainerRightTop">
<div class="TableShadowRightTop" style="background-image:url('.$layout_name.'/images/content/table-shadow-rt.gif);"></div>
</div><div class="TableContentAndRightShadow" style="background-image:url('.$layout_name.'/images/content/table-shadow-rm.gif);">
<div class="TableContentContainer">
<table class="TableContent" style="border:1px solid #faf0d7;" width="100%">
<tbody>
<tr bgcolor="#D4C0A1">
<td valign="middle" align="center"><b>Product</b></td>
<td valign="middle" width="60%"><b>Description</b></td>
<td valign="middle"> </td>
</tr>';
//Pacc
if(count($offer_list['changename']) > 0 or count($offer_list['pacc']) > 0 or count($offer_list['redskull']) > 0 or count($offer_list['unban']) > 0)
if(count($offer_list['pacc']) > 0)
foreach($offer_list['pacc'] as $pacc) {
if(!is_int($number_of_rows / 2)) { $bgcolor = $config['site']['lightborder']; } else { $bgcolor = $config['site']['darkborder']; } $number_of_rows++;
$main_content .= '<tr bgcolor="'.$config['site']['lightborder'].'"><td valign="middle" align="center">'.$pacc['days'].'</td><td><b>'.$pacc['name'].'</b> ('.$pacc['points'].' points)<br />'.$pacc['description'].'</td><td align="center">';
if(!$logged) $main_content .= '<input type="button" value="Login First" disabled="disabled" />'; else
$main_content .= '
<form action="index.php?subtopic=shopsystem&action=select_player" method="POST">
<input type="hidden" name="buy_id" value="'.$pacc['id'].'">
<table border="0" cellpadding="0" cellspacing="0">
<tbody>
<tr>
<td style="border: 0px none;">
<div class="BigButton" style="background-image: url('.$layout_name.'/images/buttons/sbutton.gif);">
<div onmouseover="MouseOverBigButton(this);" onmouseout="MouseOutBigButton(this);"><div class="BigButtonOver" style="background-image: url('.$layout_name.'/images/buttons/sbutton_over.gif);"></div>
<input class="ButtonText" name="Continue" alt="Continue" src="'.$layout_name.'/images/buttons/_sbutton_purchase.gif" type="image">
</div>
</div>
</td>
</tr>
</tbody>
</table>
</form>';}
//Change Name
if(count($offer_list['changename']) > 0)
foreach($offer_list['changename'] as $changename) {
if(!is_int($number_of_rows / 2)) { $bgcolor = $config['site']['lightborder']; } else { $bgcolor = $config['site']['darkborder']; } $number_of_rows++;
$main_content .= '<tr bgcolor="'.$config['site']['lightborder'].'"><td valign="middle" align="center"><img src="images/shop/name.gif" /></td><td><b>'.$changename['name'].'</b> ('.$changename['points'].' points)<br />'.$changename['description'].'</td><td align="center">';
if(!$logged) $main_content .= '<input type="button" value="Login First" disabled="disabled" />'; else
$main_content .= '
<form action="index.php?subtopic=shopsystem&action=select_player" method="POST">
<input type="hidden" name="buy_id" value="'.$changename['id'].'">
<table border="0" cellpadding="0" cellspacing="0">
<tbody>
<tr>
<td style="border: 0px none;">
<div class="BigButton" style="background-image: url('.$layout_name.'/images/buttons/sbutton.gif);">
<div onmouseover="MouseOverBigButton(this);" onmouseout="MouseOutBigButton(this);"><div class="BigButtonOver" style="background-image: url('.$layout_name.'/images/buttons/sbutton_over.gif);"></div>
<input class="ButtonText" name="Continue" alt="Continue" src="'.$layout_name.'/images/buttons/_sbutton_purchase.gif" type="image">
</div>
</div>
</td>
</tr>
</tbody>
</table>
</form>';}
//Remove Red Skull
if(count($offer_list['redskull']) > 0)
foreach($offer_list['redskull'] as $redskull) {
if(!is_int($number_of_rows / 2)) { $bgcolor = $config['site']['lightborder']; } else { $bgcolor = $config['site']['darkborder']; } $number_of_rows++;
$main_content .= '<tr bgcolor="'.$config['site']['lightborder'].'"><td valign="middle" align="center"><img src="images/shop/skull.gif" /></td><td><b>'.$redskull['name'].'</b> ('.$redskull['points'].' points)<br />'.$redskull['description'].'</td><td align="center">';
if(!$logged) $main_content .= '<input type="button" value="Login First" disabled="disabled" />'; else
$main_content .= '
<form action="index.php?subtopic=shopsystem&action=select_player" method="POST">
<input type="hidden" name="buy_id" value="'.$redskull['id'].'">
<table border="0" cellpadding="0" cellspacing="0">
<tbody>
<tr>
<td style="border: 0px none;">
<div class="BigButton" style="background-image: url('.$layout_name.'/images/buttons/sbutton.gif);">
<div onmouseover="MouseOverBigButton(this);" onmouseout="MouseOutBigButton(this);"><div class="BigButtonOver" style="background-image: url('.$layout_name.'/images/buttons/sbutton_over.gif);"></div>
<input class="ButtonText" name="Continue" alt="Continue" src="'.$layout_name.'/images/buttons/_sbutton_purchase.gif" type="image">
</div>
</div>
</td>
</tr>
</tbody>
</table>
</form>';
$main_content .= '</td></tr>';}
//Unban
if(count($offer_list['unban']) > 0)
foreach($offer_list['unban'] as $unban){
if(!is_int($number_of_rows / 2)) { $bgcolor = $config['site']['lightborder']; } else { $bgcolor = $config['site']['darkborder']; } $number_of_rows++;
$main_content .= '<tr bgcolor="'.$config['site']['lightborder'].'"><td valign="middle" align="center"><br /><img src="images/shop/ban.gif" /></td><td><b>'.$unban['name'].'</b> ('.$unban['points'].' points)<br />'.$unban['description'].'</td><td align="center">';
if(!$logged) $main_content .= '<input type="button" value="Login First" disabled="disabled" />'; else
$main_content .= '
<form action="index.php?subtopic=shopsystem&action=select_player" method="POST">
<input type="hidden" name="buy_id" value="'.$unban['id'].'">
<table border="0" cellpadding="0" cellspacing="0">
<tbody>
<tr>
<td style="border: 0px none;">
<div class="BigButton" style="background-image: url('.$layout_name.'/images/buttons/sbutton.gif);">
<div onmouseover="MouseOverBigButton(this);" onmouseout="MouseOutBigButton(this);"><div class="BigButtonOver" style="background-image: url('.$layout_name.'/images/buttons/sbutton_over.gif);"></div>
<input class="ButtonText" name="Continue" alt="Continue" src="'.$layout_name.'/images/buttons/_sbutton_purchase.gif" type="image">
</div>
</div>
</td>
</tr>
</tbody>
</table>
</form>';
$main_content .= '</td></tr>';}
$main_content .= '
</tbody>
</table>
</div>
</div>
<div class="TableShadowContainer">
<div class="TableBottomShadow" style="background-image:url('.$layout_name.'/images/content/table-shadow-bm.gif);">
<div class="TableBottomLeftShadow" style="background-image:url('.$layout_name.'/images/content/table-shadow-bl.gif);"></div>
<div class="TableBottomRightShadow" style="background-image:url('.$layout_name.'/images/content/table-shadow-br.gif);"></div>
</div>
</div>
</td>
</tr>
</tbody>
</table>
</div>
</td>
</tr>
</tbody>
</table>
</div>';}
elseif($action == 'select_player') {
unset($_SESSION['viewed_confirmation_page']);
if(!$logged) {
$main_content .= '<TABLE BORDER="0" CELLSPACING="1" CELLPADDING="4" WIDTH="100%">
<TR BGCOLOR="'.$config['site']['vdarkborder'].'">
<TD CLASS=white><B>Shoping Error</B></TD>
</TR>
<TR BGCOLOR='.$config['site']['darkborder'].'>
<td>
<TABLE BORDER="0" CELLSPACING="1" cellpadding="4">
<TR>
<TD>Please login first.</TD>
</TR>
</TABLE>
</td>
</tr>
</TABLE>';}
else {
$buy_id = (int) $_REQUEST['buy_id'];
if(empty($buy_id)) {
$main_content .= '<TABLE BORDER="0" CELLSPACING="1" CELLPADDING="4" WIDTH="100%">
<TR BGCOLOR="'.$config['site']['vdarkborder'].'">
<TD CLASS=white><B>Shoping Error</B></TD>
</TR>
<TR BGCOLOR='.$config['site']['darkborder'].'>
<td>
<TABLE BORDER="0" CELLSPACING="1" cellpadding="4">
<TR>
<TD>Please <a href="index.php?subtopic=shopsystem">select item</a> first.</TD>
</TR>
</TABLE>
</td>
</tr>
</TABLE>';}
else {
$buy_offer = getItemByID($buy_id);
if(isset($buy_offer['id'])) { //item exist in database
if($buy_offer['type'] != 'changename') {
if($user_premium_points >= $buy_offer['points']) {
$main_content .= '
<table border="0" cellpadding="4" cellspacing="1" width="100%">
<tr bgcolor="'.$config['site']['vdarkborder'].'">
<td class="white" colspan="2"><b>Item Informations</b></td>
</tr>
<tr bgcolor="#D4C0A1"><td width="100"><b>Image:</b></td><td width="550">';
if(file_exists('images/items/'.$buy_offer['item_id'].'.gif')) {
$main_content .= '<img src="images/items/'.$buy_offer['item_id'].'.gif" height="32" width="32">';
} else {
$main_content .= '<img src="images/monsters/nophoto.png" height="32" width="32">';
}
$main_content .='</td></tr>
<tr bgcolor="#F1E0C6"><td width="100"><b>Name:</b></td><td width="550">'.$buy_offer['name'].'</td></tr>
<tr bgcolor="#D4C0A1"><td width="100"><b>Description:</b></td><td width="550">'.$buy_offer['description'].'</td></tr>
<tr bgcolor="#F1E0C6"><td width="100"><b>Cost:</b></td><td width="550">'.$buy_offer['points'].' points</td></tr>
</table><br />
<form action="index.php?subtopic=shopsystem&action=confirm_transaction" method=POST>
<input type="hidden" name="buy_id" value="'.$buy_id.'">
<table border="0" cellpadding="4" cellspacing="1" width="100%">
<tr bgcolor="'.$config['site']['vdarkborder'].'">
<td class="white" colspan="2"><b>Select a Player</b></td>
</tr>
<tr bgcolor="#D4C0A1"><td width="110"><b>Name:</b> <select name="buy_name" style="padding: 5px;">';
$players_from_logged_acc = $account_logged->getPlayersList();
if(count($players_from_logged_acc) > 0) {
$players_from_logged_acc->orderBy('name');
foreach($players_from_logged_acc as $player)
$main_content .= '<option>'.$player->getName().'</option>';
} else {
$main_content .= 'You don\'t have any character on your account.';
}
$main_content .= '</select> <input type="submit" value="Purschase"><br /><small>Character <b> your account </b> you will receive.</small></td></tr></table>
</form>
<form action="index.php?subtopic=shopsystem&action=confirm_transaction" method="POST"><input type="hidden" name="buy_id" value="'.$buy_id.'">
<table border="0" cellpadding="4" cellspacing="1" width="100%">
<tr bgcolor="'.$config['site']['vdarkborder'].'">
<td class="white" colspan="2"><b>Send gift</b></td>
</tr>
<tr bgcolor="#D4C0A1"><td width="110"><b>To player:</b> <input type="text" name="buy_name" autocomplete="off" placeholder="Character to recive '.$buy_offer['name'].'" size="25"> <input type="submit" value="Purschase to friend"><br /><small>Put in the field above the name of the character that will receive the item.</small></td></tr>
</table><br /></form>';
} else {
$main_content .= '
<TABLE BORDER="0" CELLSPACING="1" CELLPADDING="4" WIDTH="100%">
<TR BGCOLOR="'.$config['site']['vdarkborder'].'">
<TD CLASS="white"><b>Erro</b></td>
</TR>
<TR BGCOLOR='.$config['site']['darkborder'].'><TD>Para comprar <b>'.$buy_offer['name'].'</b> voce precisa de <b>'.$buy_offer['points'].' premium points</b> disponíveis.<br />Atualmente você possui <b>'.$user_premium_points.'</b> premium points.</TD>
</TR>
</TABLE>
<br />
<table width="100%">
<tbody>
<tr align="center">
<td>
<table border="0" cellpadding="0" cellspacing="0">
<tbody><tr><td style="border: 0px none;">
<a href="javascript:void();" onclick=location.href="index.php?subtopic=donate">
<div class="BigButton" style="background-image: url('.$layout_name.'/images/buttons/sbutton.gif);">
<div onmouseover="MouseOverBigButton(this);" onmouseout="MouseOutBigButton(this);"><div class="BigButtonOver" style="background-image: url('.$layout_name.'/images/buttons/sbutton_over.gif);"></div>
<div class="ButtonText" style="background-image:url('.$layout_name.'/images/buttons/_sbutton_buypoints.png);"></div>
</div>
</div>
</a>
</td>
</tr>
<tr>
</tr>
</tbody>
</table>
</td>
<td>
<table border="0" cellpadding="0" cellspacing="0">
<tbody>
<tr>
<td style="border: 0px none;">
<a href="javascript:void();" onclick=location.href="index.php?subtopic=shopsystem"><div class="BigButton" style="background-image: url('.$layout_name.'/images/buttons/sbutton.gif);">
<div onmouseover="MouseOverBigButton(this);" onmouseout="MouseOutBigButton(this);"><div class="BigButtonOver" style="background-image: url('.$layout_name.'/images/buttons/sbutton_over.gif); visibility: hidden;"></div>
<input class="ButtonText" name="Back" alt="Back" src="'.$layout_name.'/images/vips/_sbutton_back.gif" type="image">
</table>
</td>
</tr>
</tbody>
</table>
<p> </p>';}
} else {
$main_content .= '<form action="index.php?subtopic=shopsystem&action=confirm_transaction" method=POST><input type="hidden" name="buy_id" value="'.$buy_id.'">
<table border="0" cellpadding="4" cellspacing="1" width="100%"><tr bgcolor="#505050"><td colspan="2"><b class="white">Change Name</b></td></tr>
<tr bgcolor="#D4C0A1"><td width="110"><b>Name:</b></td><td width="550"><select name="buy_name">';
$players_from_logged_acc = $account_logged->getPlayersList();
if(count($players_from_logged_acc) > 0) {
$players_from_logged_acc->orderBy('name');
foreach($players_from_logged_acc as $player) {
$main_content .= '<option>'.$player->getName().'</option>';}
} else {
$main_content .= 'You don\'t have any character on your account.';}
$main_content .= '</select></td></tr><tr bgcolor="#F1E0C6"><td width="110"><b>New name:</b></td><td width="550"><input type="text" name="buy_from"> <input type="submit" value="Change Name"></td></tr></table><br /></form>';}
} else {
$main_content .= '<TABLE BORDER="0" CELLSPACING="1" CELLPADDING="5" WIDTH="100%">
<tr BGCOLOR="'.$config['site']['vdarkborder'].'">
<td CLASS="white"><b>Error</b></td>
</tr>
<tr BGCOLOR='.$config['site']['darkborder'].'>
<td>Offer with ID <b>'.$buy_id.'</b> doesn\'t exist. Please <a href="index.php?subtopic=shopsystem">select item</a> again.</td>
</tr>
</TABLE>';}
}}}
elseif($action == 'confirm_transaction') {
if(!$logged) {
$main_content .= '<TABLE BORDER="0" CELLSPACING="1" CELLPADDING="4" WIDTH="100%">
<TR BGCOLOR="'.$config['site']['vdarkborder'].'">
<TD CLASS=white><B>Shoping Error</B></TD>
</TR>
<TR BGCOLOR='.$config['site']['darkborder'].'>
<td>
<TABLE BORDER="0" CELLSPACING="1" cellpadding="4">
<TR>
<TD>Please login first.</TD>
</TR>
</TABLE>
</td>
</tr>
</TABLE>';}
else {
$buy_id = (int) $_POST['buy_id'];
$buy_name = stripslashes(urldecode($_POST['buy_name']));
$buy_from = stripslashes(urldecode($_POST['buy_from']));
if(empty($buy_id)) {
$main_content .= 'Please <a href="index.php?subtopic=shopsystem">select item</a> first.';
} else {
if($buy_offer['type'] == 'changename'){
if(!check_name_new_char($buy_from)) {
$main_content .= 'Invalid name format of new name.';
}}
else {
$buy_offer = getItemByID($buy_id);
$check_name_in_database = $ots->createObject('Player');
$check_name_in_database->find($buy_from);
if($buy_offer['type'] == 'changename'){
if(!$check_name_in_database->isLoaded()) {
}}
if(isset($buy_offer['id'])) { //item exist in database
if($user_premium_points >= $buy_offer['points']) {
if(check_name($buy_name)) {
$buy_player = new OTS_Player();
$buy_player->find($buy_name);
if($buy_player->isLoaded()) {
$buy_player_account = $buy_player->getAccount();
if($_SESSION['viewed_confirmation_page'] == 'yes' && $_POST['buy_confirmed'] == 'yes') {
if($buy_offer['type'] == 'pacc') {
$player_premdays = $buy_player_account->getCustomField('premdays');
$player_lastlogin = $buy_player_account->getCustomField('lastday');
$save_transaction = 'INSERT INTO '.$SQL->tableName('z_shop_history_pacc').' (id, to_name, to_account, from_nick, from_account, price, pacc_days, trans_state, trans_start, trans_real) VALUES (NULL, '.$SQL->quote($buy_player->getName()).', '.$SQL->quote($buy_player_account->getId()).', '.$SQL->quote($buy_from).', '.$SQL->quote($account_logged->getId()).', '.$SQL->quote($buy_offer['points']).', '.$SQL->quote($buy_offer['days']).', \'realized\', '.$SQL->quote(time()).', '.$SQL->quote(time()).');';
$SQL->query($save_transaction);
$buy_player_account->setCustomField('premdays', $player_premdays+$buy_offer['days']);
$account_logged->setCustomField('premium_points', $user_premium_points-$buy_offer['points']);
$user_premium_points = $user_premium_points - $buy_offer['points'];
$main_content .= '<center><h2>VIP account added!</h2><b>'.$buy_offer['days'].' days</b> of VIP account added to the account of player <b>'.$buy_player->getName().'</b> for <b>'.$buy_offer['points'].' premium points</b> from your account.<br />Now you have <b>'.$user_premium_points.' premium points</b>.<br><br><a href="index.php?subtopic=shopsystem">Go to Shop Site</a><br>';
}
elseif($buy_offer['type'] == 'unban') {
$my_acc_id = $account_logged->getCustomField('id');
$datadata = $SQL->query('SELECT * FROM '.$SQL->tableName('bans').' WHERE value = '.$my_acc_id.';')->fetch();
if($datadata['value'] == $my_acc_id) {
if($SQL->query('DELETE FROM bans WHERE value= '.$my_acc_id.' LIMIT 1;')) {
} else {
$SQL->query('DELETE FROM bans WHERE account= '.$my_acc_id.' LIMIT 1;');
}
$account_logged->setCustomField('premium_points', $user_premium_points-$buy_offer['points']);
$user_premium_points = $user_premium_points - $buy_offer['points'];
$main_content .= '<center><h2>Ban Deleted!</h2><b>Your account has been unbanned for '.$buy_offer['points'].' premium points</b> from your account.
<br>Now you have <b>'.$user_premium_points.' premium points</b>.<br><br><a href="index.php?subtopic=shopsystem">Go to Shop Site</a><br>';
} else {
$main_content .= '<center><b>You don\'t have any bans in your account!</b><br><br><a href="index.php?subtopic=shopsystem">Go back</a><br>';
}
}
////////////////////////////////
elseif($buy_offer['type'] == 'itemlogout') {
$my_acc_id = $buy_player->getCustomField('id');
$playerinfo = $SQL->query('SELECT * FROM '.$SQL->tableName('players').' WHERE id = '.$my_acc_id.';')->fetch();
$playerslot = $SQL->query('SELECT * FROM '.$SQL->tableName('player_items').' WHERE player_id = '.$my_acc_id.';')->fetch();
if ($playerinfo['online'] == '0') {
if ($playerslot['pid'] != '10') {
if ($datadata['cap'] >= $SQL->quote($buy_offer['free_cap'])) {
$SQL->query('INSERT INTO player_items (player_id, pid, itemtype, count) VALUES ('.$my_acc_id.', '.$SQL->quote($buy_offer['pid']).', '.$SQL->quote($buy_offer['item_id']).', '.$SQL->quote($buy_offer['count1']).');');
$account_logged->setCustomField('premium_points', $user_premium_points-$buy_offer['points']);
$user_premium_points = $user_premium_points - $buy_offer['points'];
$main_content .= '<h2>Item received to player: '.$buy_player->getName().'!</h2><br />Now you have <b>'.$user_premium_points.' premium points</b>.
<br /><a href="index.php?subtopic=shopsystem">Go to Shop Site</a>';
} else {
$main_content .= '<b>You need '.$SQL->quote($buy_offer['free_cap']).' or more of cap!</b><br /><a href="index.php?subtopic=shopsystem">Go back</a>';
}} else {
$main_content .= '<b>Please leave the arrow slot in blank to receive item!</b><br /><a href="index.php?subtopic=shopsystem">Go back</a>';
}} else {
$main_content .= '<b>You need to be offline!</b><br /><a href="index.php?subtopic=shopsystem">Go back</a>';
}
}
////////////////////////////////
elseif($buy_offer['type'] == 'changename') {
$my_acc_id = $buy_player->getCustomField('id');
$playerinfo = $SQL->query('SELECT * FROM '.$SQL->tableName('players').' WHERE '.$SQL->fieldName('id').' = '.$my_acc_id.';')->fetch();
$checkname = $SQL->query('SELECT * FROM '.$SQL->tableName('players').' WHERE '.$SQL->fieldName('name').' = '. $SQL->quote($buy_from) .';')->fetch();
if($playerinfo['online'] == '0') {
if($checkname == false) {
$SQL->query('UPDATE `players` SET `name` = '. $SQL->quote($buy_from) .' WHERE `id` = '. $my_acc_id.' ;');
$account_logged->setCustomField('premium_points', $user_premium_points-$buy_offer['points']);
$user_premium_points = $user_premium_points - $buy_offer['points'];
$main_content .= '<center><h2>Your name has been changed to '.$buy_from.'.</h2><br /><b>You have '.$user_premium_points.' premium points left</b>.
<br /><br /><a href="index.php?subtopic=shopsystem">Go to Shop Site</a><br />';
} else {
$main_content .= '<center><h2>Sorry, the name "<i>'.$buy_from.'</i>" does already exist.<br />Please select another name.</h2><br />';
}} else {
$main_content .= '<center><h2>'.$buy_name.' has to be offline to complete transaction.</h2><br /><br /><a href="index.php?subtopic=shopsystem">Go back</a><br />';
}}
////////////////////////////////
elseif($buy_offer['type'] == 'redskull') {
$my_acc_id = $buy_player->getCustomField('id');
$playerinfo = $SQL->query('SELECT * FROM '.$SQL->tableName('players').' WHERE '.$SQL->fieldName('id').' = '.$my_acc_id.';')->fetch();
if($playerinfo['skull'] == '4' AND $playerinfo['online'] >= '0' AND $playerinfo['skulltime'] > '0') {
$SQL->query('UPDATE killers SET unjustified=0 WHERE id IN (SELECT kill_id FROM player_killers WHERE player_id='. $my_acc_id .');');
$SQL->query('UPDATE players SET skulltime=0, skull=0 WHERE id='. $my_acc_id .';');
$account_logged->setCustomField('premium_points', $user_premium_points-$buy_offer['points']);
$user_premium_points = $user_premium_points - $buy_offer['points'];
$main_content .= '<center><h2>RedSkull Removed!</h2><br /><b>Your redskull has been removed from the player '.$buy_player->getName().'.</b>
<br />Now you have<b> '.$user_premium_points.' premium points</b>.<br /><br /><a href="index.php?subtopic=shopsystem">Go to Shop Site</a><br />';
} else {
$main_content .= '<center><b>'.$buy_player->getName().' has to be offline or have redskull to complete transaction!.</b><br /><br /><a href="index.php?subtopic=shopsystem">Go back</a><br />';
}}
//////////////////////////
elseif($buy_offer['type'] == 'item') {
$sql = 'INSERT INTO '.$SQL->tableName('z_ots_comunication').' (id, name, type, action, param1, param2, param3, param4, param5, param6, param7, delete_it) VALUES (NULL, '.$SQL->quote($buy_player->getName()).', \'login\', \'give_item\', '.$SQL->quote($buy_offer['item_id']).', '.$SQL->quote($buy_offer['item_count']).', \'\', \'\', \'item\', '.$SQL->quote($buy_offer['name']).', \'\', \'1\');';
$SQL->query($sql);
$save_transaction = 'INSERT INTO '.$SQL->tableName('z_shop_history_item').' (id, to_name, to_account, from_nick, from_account, price, offer_id, trans_state, trans_start, trans_real) VALUES ('.$SQL->lastInsertId().', '.$SQL->quote($buy_player->getName()).', '.$SQL->quote($buy_player_account->getId()).', '.$SQL->quote($buy_from).', '.$SQL->quote($account_logged->getId()).', '.$SQL->quote($buy_offer['points']).', '.$SQL->quote($buy_offer['name']).', \'wait\', '.$SQL->quote(time()).', \'0\');';
$SQL->query($save_transaction);
$account_logged->setCustomField('premium_points', $user_premium_points-$buy_offer['points']);
$user_premium_points = $user_premium_points - $buy_offer['points'];
$main_content .= '<TABLE BORDER="0" CELLSPACING="1" CELLPADDING="4" WIDTH="100%">
<TR BGCOLOR="'.$config['site']['vdarkborder'].'">
<TD CLASS="white"><b>Item added successfully !</b></td>
</TR>
<TR BGCOLOR='.$config['site']['darkborder'].'>
<TD>
<b>'.$buy_offer['name'].'</b> added to player <b>'.$buy_player->getName().'</b> for <b>'.$buy_offer['points'].' premium points</b> from your account.<br />
Now you have <b>'.$user_premium_points.' premium points</b>.
</TD>
</TR>
</TABLE>
<br /><a href="index.php?subtopic=shopsystem">MAIN SHOP SITE</a><br /><br />';}
if($buy_offer['type'] == 'vipdays') {
$player_vip_time = $buy_player_account->getCustomField('vip_time');
$player_lastlogin = $buy_player_account->getCustomField('lastday');
$save_transaction = 'INSERT INTO '.$SQL->tableName('z_shop_history_pacc').' (id, to_name, to_account, from_nick, from_account, price, pacc_days, trans_state, trans_start, trans_real) VALUES (NULL, '.$SQL->quote($buy_player->getName()).', '.$SQL->quote($buy_player_account->getId()).', '.$SQL->quote($buy_from).', '.$SQL->quote($account_logged->getId()).', '.$SQL->quote($buy_offer['points']).', '.$SQL->quote($buy_offer['days']).', \'realized\', '.$SQL->quote(time()).', '.$SQL->quote(time()).');';
$SQL->query($save_transaction);
if($player_vip_time > 0)
$buy_player_account->setCustomField('vip_time', $player_vip_time + $buy_offer['days'] * 86400);
else
$buy_player_account->setCustomField('vip_time', time() + $buy_offer['days'] * 86400);
$account_logged->setCustomField('premium_points', $user_premium_points-$buy_offer['points']);
$user_premium_points = $user_premium_points - $buy_offer['points'];
if ($player_vip_days >= 1) {
}
$main_content .= '<center><h2>VIP Days added!</h2><b>'.$buy_offer['days'].' days</b> of VIP days added to the account of player <b>'.$buy_player->getName().'</b> for <b>'.$buy_offer['points'].' premium points</b> from your account.<br />Now you have <b>'.$user_premium_points.' premium points</b>.<br /><br /><a href="index.php?subtopic=shopsystem">Go to Shop Site</a><br />';}
elseif($buy_offer['type'] == 'itemvip') {
$sql = 'INSERT INTO '.$SQL->tableName('z_ots_comunication').' (id, name, type, action, param1, param2, param3, param4, param5, param6, param7, delete_it) VALUES (NULL, '.$SQL->quote($buy_player->getName()).', \'login\', \'give_item\', '.$SQL->quote($buy_offer['item_id']).', '.$SQL->quote($buy_offer['megaitems_count']).', \'\', \'\', \'megaitems\', '.$SQL->quote($buy_offer['name']).', \'\', \'1\');';
$SQL->query($sql);
$save_transaction = 'INSERT INTO '.$SQL->tableName('z_shop_history_item').' (id, to_name, to_account, from_nick, from_account, price, offer_id, trans_state, trans_start, trans_real) VALUES ('.$SQL->lastInsertId().', '.$SQL->quote($buy_player->getName()).', '.$SQL->quote($buy_player_account->getId()).', '.$SQL->quote($buy_from).', '.$SQL->quote($account_logged->getId()).', '.$SQL->quote($buy_offer['points']).', '.$SQL->quote($buy_offer['name']).', \'wait\', '.$SQL->quote(time()).', \'0\');';
$SQL->query($save_transaction);
$account_logged->setCustomField('premium_points', $user_premium_points-$buy_offer['points']);
$user_premium_points = $user_premium_points - $buy_offer['points'];
$main_content .= '<center><h2>Mega Item added!</h2><b>'.$buy_offer['name'].'</b> added to player <b>'.$buy_player->getName().'</b> for <b>'.$buy_offer['points'].' premium points</b> from your account.<br>Now you have <b>'.$user_premium_points.' premium points</b>.<br><br><a href="index.php?subtopic=shopsystem">GO TO MAIN SHOP SITE</a><br>';
}
elseif($buy_offer['type'] == 'container') {
$sql = 'INSERT INTO '.$SQL->tableName('z_ots_comunication').' (id, name, type, action, param1, param2, param3, param4, param5, param6, param7, delete_it) VALUES (NULL, '.$SQL->quote($buy_player->getName()).', \'login\', \'give_item\', '.$SQL->quote($buy_offer['item_id']).', '.$SQL->quote($buy_offer['item_count']).', '.$SQL->quote($buy_offer['container_id']).', '.$SQL->quote($buy_offer['container_count']).', \'container\', '.$SQL->quote($buy_offer['name']).', \'\', \'1\');';
$SQL->query($sql);
$save_transaction = 'INSERT INTO '.$SQL->tableName('z_shop_history_item').' (id, to_name, to_account, from_nick, from_account, price, offer_id, trans_state, trans_start, trans_real) VALUES ('.$SQL->lastInsertId().', '.$SQL->quote($buy_player->getName()).', '.$SQL->quote($buy_player_account->getId()).', '.$SQL->quote($buy_from).', '.$SQL->quote($account_logged->getId()).', '.$SQL->quote($buy_offer['points']).', '.$SQL->quote($buy_offer['name']).', \'wait\', '.$SQL->quote(time()).', \'0\');';
$SQL->query($save_transaction);
$account_logged->setCustomField('premium_points', $user_premium_points-$buy_offer['points']);
$user_premium_points = $user_premium_points - $buy_offer['points'];
$main_content .= '<center><h2>Container of items added!</h2><b>'.$buy_offer['name'].'</b> added to player <b>'.$buy_player->getName().'</b> for <b>'.$buy_offer['points'].' premium points</b> from your account.<br />Now you have <b>'.$user_premium_points.' premium points</b>.<br /><br /><a href="index.php?subtopic=shopsystem">GO TO MAIN SHOP SITE</a><br />';
}}
else {
if($buy_offer['type'] != 'changename') {
$set_session = TRUE;
$_SESSION['viewed_confirmation_page'] = 'yes';
$main_content .= '
<table border="0" cellpadding="4" cellspacing="1" width="100%">
<tr bgcolor="#505050"><td colspan="3"><font color="white"><b>Confirm transaction</b></font></td></tr>
<tr bgcolor="'.$config['site']['darkborder'].'"><td><b>Image:</b></td><td width="550" colspan="2"><img src="images/items/'.$buy_offer['item_id'].'.gif" align="absmiddle"/> <small><b>'.$buy_offer['name'].'</b></small></td></tr>
<tr bgcolor="'.$config['site']['lightborder'].'"><td><b>Description:</b></td><td width="550" colspan="2">'.$buy_offer['description'].'</td></tr>
<tr bgcolor="'.$config['site']['darkborder'].'"><td><b>Cost:</b></td><td width="550" colspan="2"><b>'.$buy_offer['points'].' premium points</b> from your account</td></tr>
<tr bgcolor="'.$config['site']['lightborder'].'"><td><b>For Player:</b></td><td width="550" colspan="2">'.$buy_player->getName().' <small>[<a href="index.php?subtopic=characters&name='.$buy_player->getName().'" target="_blank">View Character</a>]</small></td></tr>
<tr bgcolor="'.$config['site']['darkborder'].'"><td><b>Confirm Transaction ?</b></td>
<td><form action="index.php?subtopic=shopsystem&action=confirm_transaction" method="POST"><input type="hidden" name="buy_confirmed" value="yes"><input type="hidden" name="buy_id" value="'.$buy_id.'"><input type="hidden" name="buy_from" value="'.urlencode($new_name).'"><input type="hidden" name="buy_name" value="'.urlencode($buy_name).'"><input type="submit" value="Accept"></form></td><td><form action="index.php?subtopic=shopsystem" method="POST"><input type="submit" value="Cancel"></form></td></tr>
</table><br />';
} else {
$set_session = TRUE;
$_SESSION['viewed_confirmation_page'] = 'yes';
$main_content .= '<center><h2>Confirm Name Changing</h2>
<table border="0" cellpadding="4" cellspacing="1" width="100%">
<tr bgcolor="#505050"><td colspan="3"><font color="white" size="4"><b>Confirm transaction</b></font></td></tr>
<tr bgcolor="#D4C0A1"><td width="130"><b>Name:</b></td><td width="550" colspan="2">'.$buy_offer['name'].'</td></tr>
<tr bgcolor="#F1E0C6"><td width="130"><b>Description:</b></td><td width="550" colspan="2">'.$buy_offer['description'].'</td></tr>
<tr bgcolor="#D4C0A1"><td width="130"><b>Cost:</b></td><td width="550" colspan="2"><b>'.$buy_offer['points'].' premium points</b></td></tr>
<tr bgcolor="#F1E0C6"><td width="130"><b>Current Name:</b></td><td width="550" colspan="2"><font color="red">'.$buy_player->getName().'</font></td></tr>
<tr bgcolor="#D4C0A1"><td width="130"><b>New Name:</b></td><td width="550" colspan="2"><font color="red">'.$buy_from.'</font></td></tr>
<tr bgcolor="#F1E0C6"><td width="130"><b>Change Name?</b></td><td width="275" align="left">
<form action="index.php?subtopic=shopsystem&action=confirm_transaction" method="POST"><input type="hidden" name="buy_confirmed" value="yes"><input type="hidden" name="buy_id" value="'.$buy_id.'"><input type="hidden" name="buy_from" value="'.urlencode($buy_from).'"><input type="hidden" name="buy_name" value="'.urlencode($buy_name).'"><input type="submit" value="Accept"></form></td>
<td align="right"><form action="index.php?subtopic=shopsystem" method="POST"><input type="submit" value="Cancel"></form></td></tr>
</table>';}}}
else {
$main_content .= '<TABLE BORDER="0" CELLSPACING="1" CELLPADDING="5" WIDTH="100%">
<tr BGCOLOR="'.$config['site']['vdarkborder'].'">
<td CLASS="white"><b>Error</b></td>
</tr>
<tr BGCOLOR='.$config['site']['darkborder'].'>
<td>Player with name <b>'.$buy_name.'</b> doesn\'t exist. Please <a href="index.php?subtopic=shopsystem&action=select_player&buy_id='.$buy_id.'">select other name</a>.</td>
</tr>
</TABLE>';
}
} else {
$main_content .= '<TABLE BORDER="0" CELLSPACING="1" CELLPADDING="4" WIDTH="100%">
<TR BGCOLOR="'.$config['site']['vdarkborder'].'">
<TD CLASS=white><B>Shoping Error</B></TD>
</TR>
<TR BGCOLOR='.$config['site']['darkborder'].'>
<td>
<TABLE BORDER="0" CELLSPACING="1" cellpadding="4">
<TR>
<TD>Invalid name format. Please <a href="index.php?subtopic=shopsystem&action=select_player&buy_id='.$buy_id.'">select other name</a>.</TD>
</TR>
</TABLE>
</td>
</tr>
</TABLE><br />';}
} else {
$main_content .= '<TABLE BORDER="0" CELLSPACING="1" CELLPADDING="5" WIDTH="100%">
<tr BGCOLOR="'.$config['site']['vdarkborder'].'">
<td CLASS="white"><b>Error</b></td>
</tr>
<tr BGCOLOR='.$config['site']['darkborder'].'>
<td>For this item you need <b>'.$buy_offer['points'].'</b> points. You have only <b>'.$user_premium_points.'</b> premium points. Please <a href="index.php?subtopic=shopsystem">select other item</a> or buy premium points.</td>
</tr>
</TABLE>';
}}
else {
$main_content .= '<TABLE BORDER="0" CELLSPACING="1" CELLPADDING="5" WIDTH="100%">
<tr BGCOLOR="'.$config['site']['vdarkborder'].'">
<td CLASS="white"><b>Error</b></td>
</tr>
<tr BGCOLOR='.$config['site']['darkborder'].'>
<td>Offer with ID <b>'.$buy_id.'</b> doesn\'t exist. Please <a href="index.php?subtopic=shopsystem">select item</a> again.</td>
</tr>
</TABLE>';
}}}}
if(!$set_session) {
unset($_SESSION['viewed_confirmation_page']);
}}
if(!$logged)
$main_content .= '<br /><center><div class="notice"><b>Please login to see how much points you have</b></div></center>';
else
if($account_logged->getCustomField("premium_points") <= 0)
$main_content .='<br /><center><div class="error">You do not have premium points available.<br /><a href="index.php?subtopic=donate">Buy now Premium Points!</a></div></center>';
else
if($account_logged->getCustomField("premium_points") >= 1)
$main_content .='<br /><center><div class="success" style="width: 300px;">You have <b>'.$account_logged->getCustomField("premium_points").'</b> premium points available</div></center>';
}
else
$main_content .= '
<TABLE BORDER="0" CELLSPACING="1" CELLPADDING="4" WIDTH="100%">
<TR BGCOLOR="'.$config['site']['vdarkborder'].'">
<TD CLASS=white><B>Shoping Status</B></TD>
</TR>
<TR BGCOLOR='.$config['site']['darkborder'].'>
<td>
<TABLE BORDER="0" CELLSPACING="1" cellpadding="4">
<TR>
<TD>Inativamos o Shop para manutenção interna, dentro de poucos minutos voltaremos com nossos sistemas normalizados.<br /><b>Atenciosamente,<br /> Administração</b></TD>
</TR>
</TABLE>
</td>
</tr>
</TABLE>';
?>
-
lemooca reacted to GuuhTorres in Guuh Torres Vs 4.0
Guuh Torres Vs 4.0
*Pessoal,me desculpem pela demora da atualização,pois tinha muitos bugs nesta base,e em pedidos de vários xtibianos,arrumei o "Pokemon Squadium" do brun123...Este server era um bom server,mais tinha muitos bugs,irei listar os que eu arrumei,ou acrescentei:
-Catch
-Goback
-Portrait
-Pokedex
-Order
-Talkactions
-!lg para mudar a linguagem (English-Português)
-Status sistema
-Novos pokemons (Johto-Shinys)
-Coloquei mais moves (Johto)
-Npc Name (Que coloca um apelido ao pokemon) no ultimo andar do CP
-Novo Mapa do Betinhowz666
-Novas quests
-Novas Spawns (Eu não sei fazer muito bem,mais dá para usar)
-PVP ZONE
-Efeito ao upar level
-Client na pasta (IP : 127.0.0.1)
-Senha do GOD : guuh/torres
DOWNLOAD do server:
-Guuh Torres vs 4.0
Créditos :
-GuuhTorres 25%
-Brun123 40% (Caso você ler este tópico,peço que adicione ght-2-@hotmail.com)
-Betinhowz666 15%
-Xtibia 5%
-Victorkta 5%
-Ciffer 5%
-Italo 5%
QUE VENHAM OS REPS :button_ok:
-------------------------------------------------------------
PRÓXIMA ATUALIZAÇÃO!!!
Na próxima atualização irei fazer sem os BUGS,que vocês falarem...
-
-
lemooca reacted to Admrevolution in Npc Montarias 9.1!
Ola Vim Trazer Pra Vocês O Npc De Montaria 9.1!
Em Data/Npc Crie Um Arquivo Xml Com Nome De Domador E Adicione Isso :
Em Data/npc/scripts Crie Um Arquivo .lua Chamado mounts e Adicione Isso :
Espero Ter Ajudado
Créditos:50%Admrevolution (EU)por adicionar as montarias 9.1
50%deletera Npc Montarias Versão 8.7
Obrigado!
-
lemooca reacted to Alissow in Alissow Ots 4.11 [11/07/2010] 8.6 Completo!
Alissow OTs 4.11!
Esta versão 4.11 foi meio apressada, só adicionamos as features novas do 8.6.
Aproveitem.
Créditos:
Alissow
Comedinha
Luis
Nirk
TFS Team
Viniply
Xedegux
Sobre o OT/Mapa:
Principais quests:
-Annihilator
-Inquisition Quest
-Pits of inferno
-Demon Oak
-Solar axe quest
-HOTA
-MPA quest
-The Challenger
Monstros:
-Total monstros: 10292
-Total spawn: 5587+
Cidades:
-12 Cidades
-200 Houses+-
Raids/Invasões:
-Rat
-Orshabaal
-Ghazbaran
-Giant spider/The old window
-Ferumbras
-Morgaroth
Spells:
-Magias editadas para balanceamento das vocações
Changelog
Atualização [3.4 BETA]:
- Removido áreas não usadas no mapa, diminuindo o tamanho em MBs
- Adicionado Anti Magebomb System
- Corrigido bugs no npc addon
- Adicionado sistema onde os npcs falam sozinhos (Igual como foi adicionado no global). First ;]
- Adicionado Elf village em Venonh ( bem parecida com a do global ;])
- Potions desaparecem quando usadas
- Corrigido sistema de Up
- Corrigido sistema de Monster Counter
- Nova dragon lair em Mirand Theraan (Subsolo)
- Adicionado porta de level, que protege leveis baixos acessarem os demons da cidade de Flam
- Ampliado deserto da cidade de Mirand Theraan
- Adicionado Ilha de Goroma
- Adicionado Forbidden islands
- Ampliado floresta da cidade de alfon e colocado área de macacos parecida com Banuta.
- Ligação de alfon com Mirand Theraan
- Corrigido bugs reportados nas portas das casas
- Corrigido posição dos buracos e escadas
- Adicionado beds em todas as casas
- Corrigido bugs em casas de yalahar
- Adicionado Blue legs quest ( Koshei The Deathless global)
- Corrigidas quase todas as areas de Yalahar
- Teleports em Yalahar substituidos por NPCs de teleport do global
- Corrigido pequenos erros no npc Capitao Coruja, e adicionado viagem à goroma
- diminuido ataque do Eye of the seven
- Ice rapier agora quebra
- Corrigido npc Banker
- Adicionado quase todos os items 8.5
- Adicionado medusa
- Adicionado Todos os outfits novos
- Corrigido NPC Banker (que dava dinheiro) Script By Ta4e
- Corrigido Annihilator Quest
- Adicionado Notice System
- Adicionado novo distro, compilado por Comedinha
Atualização nº 2 [3.4]:
Otserv atualizado...
Corrigido debugs frequentes
Corrigido debugs na magia exevo pan
Corrigido bugs nos npcs Roy e Firewalker
Adicionados mais novos items 8.5, agora temos 90% dos items novos...
Atualização 3.5 [06/08/2009]:
- Cidade principal (dorion) totalmente reformada
- corrigido blue legs quest
- Corrigido alavancas de compra de potions
- Adicionado alavancas de compra de runas
- Corrigido npc Bank
- Adicionado NPC King Arthas, que vende promotion
- Adicionado npc Rashid, que vende items.
- Arrumado Wild Growth rune
- Arrumado Utani Hur
- Magias reajustadas
- Novo estilo de server save
- Ilha de mystic reformulada (by Nirk)
- Adicionado nova magia para knights "Exkordium".
- Adicionado nova magia para mages (promoted) "Exura Seil".
- Adicionado nova magia para mages (promoted) "Exevo Gran Frigo". (arrumar -> sem exhausted nem gasta mana)
- Adicionados novos monstros.
- Adicionado quest challenge (lvl 250)
- Corrigido bug do Dead Cyclops
- Bug aol Arrumado
- Poi Modificada
- Corrigido teleports ghouls yalahar
- Modificada demon helmet quest, assim como o premio da quest
- Corrigido nome do Hallowed axe
- Corrigido bug das houses
- Corrigido bug dos items andaveis
Atualização Patch 3.5.1 [07/08/2009]:
- Corrigido erro na inicialização do Ot
- Bug das potions corrigido
- Bug do aol corrigido (pelomenos pra mim)
- Bug dos outfits corrigido
- Corrigido erros nas escadas na ilha PvP
- O monstro The Fastest Turtle agora não morre, se tornando um monstro apenas para atrapalhar
- Retirada suposta quest dos 3 hellhounds e 1 minishabaal
- Adicionado teleport de retorno na Ferumbras Tower
- Corrigido posições da raid de The old widow
- Corrigido bug das escadas nas minas de demons
- Corrigido alguns bugs vistos no mapa
Atualização 3.6 [10/08/2009]:
- Arrumado bugs criticos
- Arrumado comando !promote/!demote
- Atualizado Items.xml
- Bug das Beds arrumado
- Modificações na cidade, como, nature e caves
- Nova sala de treino
- Adicionado comando !highscores
Atualização 3.7! Beta [18/12/2009]:
- Guildhall support (Elf)
- Nova deathlist(Elf, OpenTibia SVN)
- Frags funcionando (Elf)
- Atualizado monstros e items (slawkens, KaczooH, Elf)
- Novas talkactions: /commands, /wp, /storage, /config, /promote & /demote. (slawkens)
- Novas funções lua
- Novos creatureevents (slawkens, Elf)
- Novos configuráveis (Elf, slawkens)
- Modificado ataque de monstros existentes (especialmente outfits e velocidade) (Elf)
- Monstros reorganizados & atualizados (Nem todos) (slawkens)
- Melhorado sistema de banimentos (Elf)
- Reescrita janela de Rule Violation (Elf)
- Arrumado Stamina (Elf, OpenTibia SVN)
- Casas agora são salvas nas modificações do dono (Elf)
- Escadas de yalahar funcionando perfeitamente (Elf, Talaturen)
- Sistema de nado & waterball completo (slawkens)
- Monstros invisiveis não são mais mandandos ao client (anti bot) (OpenTibia SVN)
- Anti-dash (OpenTibia SVN)
- Sistema de leilão de casas, possibilidade de usar site para vender casas (house_actions table) (OpenTibia SVN, Elf)
- Salvando bot actions para /logs/bots por cada player. Por exemplo, bot pode enviar mensagem com mais de 255 caracteres (slawkens)
- Novos raid events- item spawning & disappearing and more (Elf)
- Modificações no NPC system (Elf)
- NPCs OutfitModule (Elf)
- Completo 8.53 support, com wars (Elf)
- Completo 8.54 support (Elf)
- Arrumado NPC voices (Elf)
- Players serão informados quando o Gamemaster logar ou ficar invisivel (slawkens)
- Arrumado Player Deaths (Elf, slawkens)
- Arrumado Abuso de PZ (slawkens)
- Portas agora não ajudam players a entrar em PZ (slawkens)
- Magic level formula (OpenTibia SVN, KaczooH)
- Memory leaks (Elf)
- Queries optimization (Talaturen)
- Janelas podem ser abertas do lado de fora da casa- agora apenas GMs podem fazer isso (slawkens)
- arrumado Efeitos para o Ghost (GM)- configuravel (slawkens)
- Corrigido >> Ghost debugging players (OpenTibia SVN, Elf)
- Corrigido erro na promotion (Elf)
- Corrigido vários erros no console. (slawkens)
- Corrigido Spam de magias (Elf)
- Corrigido stamina premium (Elf)
- Corrigido Clean (Elf)
- Corrigido vários outfits (Elf)
- Corrigido Ghost (Elf)
- Todas as correções no OpenTibia SVN (Open Tibia SVN, Elf)
- Corrigido Todos os crashes possiveis (Elf)
- Npcs Corrigidos (Comedinha)
- Distro Reformulado (comedinha)
- Bugs de reports arrumados (Comedinha)
- Novos outfits (Alissow)
- Actions Arrumadas (Comedinha)
- Libs trocadas (Comedinha)
- Talkactions bugadas arrumadas (Comedinha)
- Reforma na área Sul da cidade Dorion (Alissow)
- Adicionado monstros 8.54 (Alissow)
- Corrigido bug das potions infinitas (Alissow)
Atualização 3.7 Patch 1 [27/12/2009]:
- Rampa na frente da loja de foods retirada (Alissow)
- Arrumado bugs de mapa em anknor (Alissow)
- Bug na Lib dos npcs corrigido (Alissow)
- Bug do acc manager arrumado! (Alissow)
- Magias "Exkordium" e "Ice Storm" arrumadas (Alissow)
- Monstros 8.54 funcionando (Alissow)
- 2º Addon Yalaharian arrumado (Alissow)
- Addons Warmaster adicionados no NPC Addoner (Alissow)
- Pequenas modificações na cidade principal, Dorion, para melhora da jogabilidade (Alissow)
- Comando /Deathlist retirado (Alissow)
- Magic Wall Rune arrumada (Alissow)
- Quest Annihilator arrumada (Alissow)
- "Your depot contain x items" Arrumado (Alissow)
- Addons reorganizados, mais facil aggora (Alissow)
- Tempo de Red skull e Black skull reduzidos para 24 e 42 horas (Alissow)
- Reduzida porcentagem de morte (Alissow)
- Acrescentado chance de critical hits (Alissow)
- ShowHealingDamage Adicionado (Alissow)
- Várias partes do mapa remapeadas (Alissow)
- NPCs para recarga de Soft boots & Firewalker boots arrumados [Não testado] (Alissow)
- Comando !frags arrumado! (Alissow)
- Agora é possivel fazer addons sem precisar do comando !buypremium (Alissow)
Atualização 3.8 [17/01/2010]:
- Arrumado bug nas escadas do Dlair (Alissow)
- Todos os bugs nos NPCs arrumados (Comedinha)
- Novas talkactions [a pedidos] (Comedinha)
- Deathlist arrumada (Comedinha)
- Novo Distro (Comedinha)
- MySQL Atualizada (Comedinha)
- Firewarker boots não é mais gasta quando não está usando (Comedinha)
- Problemas com items no Rashid arrumados (Alissow, Comedinha, Comunidade)
- O NPC Banker foi corrigido, mas achei mais seguro retira-lo, visto que ninguem usava e poderia causar outro tipo de bug
- Ilha (Sim aqui é uma ilha) de Zao adicionada (Alissow, Barker)
- Monstros 8.54 aperfeiçoados (Alissow, Markithu, Zkum)
- Reduzido danos da magia Exkordium (Alissow)
- Os npcs Dark Rodo e Rachel vendem Blank Runes (Alissow)
- Magias que não hitavam anteriormente foram arrumadas (Alissow)
- Comando !buypremium arrumado (Alissow)
- Arena PVM - Mais conhecida como Arena Svargrond - FUNCIONANDO!!! (Alissow)
- Magia LightChain Retirada (Alissow)
- Adicionado um sisteminha legal no templo (Alissow)
- NPC Rashid retirado (Alissow)
Atualização 3.8 Minor Patch 1 [17/01/2010]:
- Comando Deathlist retirado novamente, fizemos testes equivocados.
Se você é uma das 16 pessoas que baixou a versão anterior (3.8) não precisa baixar esta, basta retirar o comando !deathlist e /deathlist do seu Talkactions.xml, Os comandos causam quedas no servidor.
Atualização 3.9 [15/02/2010]:
- Cidade principal (Dorion) reformada, novo templo, novo depot, novo porto, novos npcs :] (Alissow)
- Adicionado Reputation System (Comedinha, Cybermaster)
- Adicionado !bless system (Comedinha)
- /info melhorado (Comedinha)
- Jail System (Comedinha)
- Bug chatinho nos tiles pretos arrumado.
- Magic Wall Funcionando! (Alissow)
- Agora você pode fazer bolos e pães :] (Comedinha, Jean, Ojani)
- Adicionado sistema de casamento (Comedinha, ScorpiOOn93, Alissow)
- Loot The Fastest Turtle diminuido (Alissow)
- Loot e experiencia do Feromous mais baixo (Alissow)
- Sistema de parceis para Dorion funcionando (Alissow)
- Guildwar System (Comedinha)
- Anti MageBomb System (Comedinha, Huggen)
- Adicionado Anti Nuker - Esse funciona! (Comedinha)
- Adicionado Map Marks, para os players novos (Alissow, Comedinha)
Atualização 4.0 [15/02/2010]:
- Cidade Mountain totalmente reformada (Alissow)
- Montanha de Goblins de Dorion reformada (Alissow)
- Demonic Castle de Dorion reformado (Alissow)
- Cidade de Venonh modificada (Luis)
- Distro atualizado, funcionando nos clients 8.54, 8.55, 8.56 e 8.57 (Comedinha)
- Comando !bless retirado (Alissow)
- O NPC Ermes não vende mais items de decoração (Alissow)
- Arrumado bugs na Ferumbras Tower (Alissow)
- O comando !AFK on agora mantem o player parado (Comedinha)
- Arrumado bugs nas escadas da área de DeathFans (Alissow)
- Comando !Deathlist funcionando! (Alissow, Doidinmapper, GT Thionix)
- Sistema de REP atualizado (Comedinha)
- Sistema de Polls (Comedinha)
- Banco por comandos (Comedinha)
- Novos comandos de addon e accounts (Comedinha)
- Sistema de futebol completo! (Comedinha)
- Sistema Antibot (Comedinha)
- Magia Spared Hur modificada (Alissow, Orzeleagle)
- Adicionado sistema de montaria (Alissow, unknown666)
- Adicionado Canivetes (Alissow, Siramix)
- Nova hunt Subaquatica (Luis)
Atualização 4.11! [11/07/2010]:
- Versão 8.6, todos os items, outfits e monstros novos (Comedinhasss, Fireelement)
- Adicionados os novos monstros 8.6 (Alissow)
- Bug das potions arrumado (Comedinha, Matheusmkalo, Gabriel linhares, Fireelement)
- Erros das runas arrumado (Comedinha, Gabriel linhares, Matheusmkalo, fireelement)
Download
Servidor: 4shared
Tamanho: 17,416 KB
Download: http://www.4shared.com/file/ez8XKrju/860_Alissow_Ots_411.html
Link protegido: http://lix.in/-8d4bc0
Scan VirusTotal: http://www.virustotal.com/pt/analisis/983abb574dbb957a75aa1fd29eb804065f775e6a0c43216aa277686d32bce22a-1263702373
Atenção
- Acc do God: god/god
- LEIA o tópico antes de postar qualquer coisa ou duvida
- Reportem se houver algum bug
- A database fica na pasta schemas+Database
- Proibido o uso do nosso distro sem o nosso consenso, obrigado.
Andei percebendo que há muitos mapas feitos por mim em outros servidores postados aqui no xtibia, eu não sei se vocês sabem, mas isso é PLÁGIO.
Eu não sou uma pessoa egoista, tudo que eu posto aqui no XTibia é para ser compartilhado, mas desde que mantenham os devidos créditos.
Será denunciado qualquer tipo de "roubo" sem minha autorização para beneficio próprio. Eu sei que vocês não se importam muito com isso, eu também não deveria me
importar, mas é o tempo e a dedicação de outra pessoa que vocês estão roubando, então peço gentilmente aos que tem conhecimento desses mapas, que me apontem.
Não tem graça trabalhar horas e horas e ser roubado em dois minutos.
-
lemooca reacted to meubk in [Talkaction]System Moves [15/151]
Moves System Pokemon
O meu script de moves, foi atualizado, por enquanto está com esses pokemons, eu estárei adicionando os 151, aos pouco não tenha pressa e acompanhe todos dias avera atualização.
Novidades :
Crie um arquivo com nome de moves.lua e cole o new script :
function getTime(s) local n = math.floor(s / 600) s = s - (600 * n) return n, s end function getCreaturesInRange(position, radiusx, radiusy, showMonsters, showPlayers) local creaturesList = {} for x = -radiusx, radiusx do for y = -radiusy, radiusy do if not (x == 0 and y == 0) then creature = getTopCreature({x = position.x+x, y = position.y+y, z = position.z, stackpos = STACKPOS_TOP_CREATURE}) if (creature.type == 1 and showPlayers == 1) or (creature.type == 2 and showMonsters == 1) then table.insert(creaturesList, creature.uid) end end end end return creaturesList end -- CONDITIONS function Confused(inconfuse, rounds) if rounds == 0 then return false end if not inconfuse then return false end local c = {[1] = {x = 1, y = 0}, [2] = {x = 0, y = 1}, [3] = {x = -1, y = 0}, [4] = {x = 0, y = -1}} local p = getCreaturePosition(inconfuse) doSendMagicEffect(p, 31) local s = math.random(4) doTeleportThing(inconfuse, {x = p.x + c[s].x, y = p.y + c[s].y, z = p.z}) return addEvent(Confused, 400, inconfuse, rounds-1) end local paralize = createConditionObject(CONDITION_PARALYZE) setConditionParam(paralize, CONDITION_PARAM_TICKS, 5*1000) setConditionFormula(paralize, -0.7, 0, -0.8, 0) function Paralize(inparalize) doSendAnimatedText(getCreaturePosition(inparalize), "PAZ", 210) doAddCondition(inparalize , paralize) return true end local sleep = createConditionObject(CONDITION_PARALYZE) setConditionParam(sleep, CONDITION_PARAM_TICKS, 5*1000) setConditionFormula(sleep, -1.7, 0, -1.8, 0) function Sleep(insleep) doAddCondition(insleep , sleep) p = getCreaturePosition(insleep) doSendAnimatedText(p, "SLEEP", 154) for i = 1, 5 do if i == 1 then doSendMagicEffect(p, 32) else addEvent(doSendMagicEffect, i * 1000, p, 32) end end return true end function Poison(inpoison, ef, rounds) if rounds == 0 then return false end if not inpoison then return false end local p = getCreaturePosition(inpoison) doAreaCombatHealth(pet, COMBAT_EARTHDAMAGE, p, 0, -5, -10, ef) return addEvent(Poison, 800, inpoison, ef, rounds-1) end -- END CONDITIONS function getPosToStorm(posdecay) b = {x = posdecay.x-20, y = posdecay.y-20, z = posdecay.z} return b end local area1 = createCombatArea{ {0, 1, 1, 1, 0}, {1, 1, 1, 1, 1}, {1, 1, 2, 1, 1}, {1, 1, 1, 1, 1}, {0, 1, 1, 1, 0} } local area2 = createCombatArea{ {0, 0, 0, 0, 0}, {0, 1, 1, 1, 0}, {0, 1, 2, 1, 0}, {0, 1, 1, 1, 0}, {0, 0, 0, 0, 0} } local area3 = createCombatArea{ {0, 0, 1, 0, 0}, {0, 1, 1, 1, 0}, {1, 1, 2, 1, 1}, {0, 1, 1, 1, 0}, {0, 0, 1, 0, 0} } local areadirecion1 = { [2] = createCombatArea{ {0, 0, 0, 0, 0}, {0, 0, 0, 0, 0}, {0, 0, 0, 0, 0}, {0, 0, 1, 0, 0}, {0, 0, 2, 0, 0} }, [3] = createCombatArea{ {0, 0, 0, 0, 0}, {0, 0, 0, 0, 0}, {2, 1, 0, 0, 0}, {0, 0, 0, 0, 0}, {0, 0, 0, 0, 0} }, [0] = createCombatArea{ {0, 0, 2, 0, 0}, {0, 0, 1, 0, 0}, {0, 0, 0, 0, 0}, {0, 0, 0, 0, 0}, {0, 0, 0, 0, 0} }, [1] = createCombatArea{ {0, 0, 0, 0, 0}, {0, 0, 0, 0, 0}, {0, 0, 0, 1, 2}, {0, 0, 0, 0, 0}, {0, 0, 0, 0, 0} } } local areadirecion2 = { [2] = createCombatArea{ {0, 0, 1, 0, 0}, {0, 0, 1, 0, 0}, {0, 0, 1, 0, 0}, {0, 0, 1, 0, 0}, {0, 0, 2, 0, 0} }, [3] = createCombatArea{ {0, 0, 0, 0, 0}, {0, 0, 0, 0, 0}, {2, 1, 1, 1, 1}, {0, 0, 0, 0, 0}, {0, 0, 0, 0, 0} }, [0] = createCombatArea{ {0, 0, 2, 0, 0}, {0, 0, 1, 0, 0}, {0, 0, 1, 0, 0}, {0, 0, 1, 0, 0}, {0, 0, 1, 0, 0} }, [1] = createCombatArea{ {0, 0, 0, 0, 0}, {0, 0, 0, 0, 0}, {1, 1, 1, 1, 2}, {0, 0, 0, 0, 0}, {0, 0, 0, 0, 0} } } local areadirecion3 = { [2] = createCombatArea{ {0, 0, 1, 0, 0}, {0, 0, 1, 0, 0}, {0, 0, 1, 0, 0}, {0, 0, 1, 0, 0}, {0, 0, 1, 0, 0}, {0, 0, 1, 0, 0}, {0, 0, 1, 0, 0}, {0, 0, 1, 0, 0}, {0, 0, 2, 0, 0} }, [3] = createCombatArea{ {0, 0, 0, 0, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 0, 0, 0, 0}, {2, 1, 1, 1, 1, 1, 1, 1, 1}, {0, 0, 0, 0, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 0, 0, 0, 0} }, [0] = createCombatArea{ {0, 0, 2, 0, 0}, {0, 0, 1, 0, 0}, {0, 0, 1, 0, 0}, {0, 0, 1, 0, 0}, {0, 0, 1, 0, 0}, {0, 0, 1, 0, 0}, {0, 0, 1, 0, 0}, {0, 0, 1, 0, 0}, {0, 0, 1, 0, 0} }, [1] = createCombatArea{ {0, 0, 0, 0, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 0, 0, 0, 0}, {1, 1, 1, 1, 1, 1, 1, 1, 2}, {0, 0, 0, 0, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 0, 0, 0, 0} } } local areadirecion4 = { [2] = createCombatArea{ {0, 0, 0, 0, 0}, {0, 0, 0, 0, 0}, {0, 1, 1, 1, 0}, {0, 0, 1, 0, 0}, {0, 0, 2, 0, 0} }, [3] = createCombatArea{ {0, 0, 0, 0, 0}, {0, 0, 1, 0, 0}, {2, 1, 1, 0, 0}, {0, 0, 1, 0, 0}, {0, 0, 0, 0, 0} }, [0] = createCombatArea{ {0, 0, 2, 0, 0}, {0, 0, 1, 0, 0}, {0, 1, 1, 1, 0}, {0, 0, 0, 0, 0}, {0, 0, 0, 0, 0} }, [1] = createCombatArea{ {0, 0, 0, 0, 0}, {0, 0, 1, 0, 0}, {0, 0, 1, 1, 2}, {0, 0, 1, 0, 0}, {0, 0, 0, 0, 0} } } local d = { ["Bulbasaur"] = { ["m1"] = {atk = "Quick Attack", minlvl = 20, st = 2000, cd = 3, min = 100, max = 200, damage = COMBAT_PHYSICALDAMAGE, target = true, pz = false}, ["m2"] = {atk = "Razor Leaf", minlvl = 20, st = 2001, cd = 3, min = 100, max = 200, damage = COMBAT_EARTHDAMAGE, target = true, pz = false}, ["m3"] = {atk = "Vine Whip", minlvl = 20, st = 2002, cd = 3, min = 100, max = 200, damage = COMBAT_EARTHDAMAGE, target = false, pz = false}, ["m4"] = {atk = "Headbutt", minlvl = 20, st = 2003, cd = 3, min = 100, max = 200, damage = COMBAT_PHYSICALDAMAGE, target = true, pz = false}, ["m5"] = {atk = "Leech Seed", minlvl = 20, st = 2004, cd = 3, min = 100, max = 200, damage = COMBAT_EARTHDAMAGE, target = true, pz = false}, ["m6"] = {atk = "Solar Beam", minlvl = 20, st = 2005, cd = 3, min = 200, max = 400, damage = COMBAT_EARTHDAMAGE, target = false, pz = false}, ["m7"] = {atk = "Stun Spore", minlvl = 20, st = 2006, cd = 3, min = 0, max = 0, damage = COMBAT_EARTHDAMAGE, target = false, pz = false}, ["m8"] = {atk = "Poison Powder", minlvl = 20, st = 2007, cd = 3, min = 0, max = 0, damage = COMBAT_EARTHDAMAGE, target = false, pz = false}, ["m9"] = {atk = "Sleep Powder", minlvl = 20, st = 2008, cd = 3, min = 0, max = 0, damage = COMBAT_EARTHDAMAGE, target = false, pz = false}, }, ["Ivysaur"] = { ["m1"] = {atk = "Quick Attack", minlvl = 40, st = 2009, cd = 3, min = 300, max = 400, damage = COMBAT_PHYSICALDAMAGE, target = true, pz = false}, ["m2"] = {atk = "Razor Leaf", minlvl = 40, st = 2010, cd = 3, min = 300, max = 400, damage = COMBAT_EARTHDAMAGE, target = true, pz = false}, ["m3"] = {atk = "Vine Whip", minlvl = 40, st = 2011, cd = 3, min = 300, max = 440, damage = COMBAT_EARTHDAMAGE, target = false, pz = false}, ["m4"] = {atk = "Headbutt", minlvl = 40, st = 2012, cd = 3, min = 300, max = 400, damage = COMBAT_PHYSICALDAMAGE, target = true, pz = false}, ["m5"] = {atk = "Leech Seed", minlvl = 40, st = 2013, cd = 3, min =300, max = 400, damage = COMBAT_EARTHDAMAGE, target = true, pz = false}, ["m6"] = {atk = "Solar Beam", minlvl = 40, st = 2014, cd = 3, min = 300, max = 400, damage = COMBAT_EARTHDAMAGE, target = false, pz = false}, ["m7"] = {atk = "Stun Spore", minlvl = 40, st = 2015, cd = 3, min = 0, max = 0, damage = COMBAT_EARTHDAMAGE, target = false, pz = false}, ["m8"] = {atk = "Poison Powder", minlvl = 40, st = 2016, cd = 3, min = 0, max = 0, damage = COMBAT_EARTHDAMAGE, target = false, pz = false}, ["m9"] = {atk = "Sleep Powder", minlvl = 20, st = 2017, cd = 3, min = 0, max = 0, damage = COMBAT_EARTHDAMAGE, target = false, pz = false}, }, ["Venusaur"] = { ["m1"] = {atk = "Quick Attack", minlvl = 80, st = 2018, cd = 3, min = 1000, max = 2000, damage = COMBAT_PHYSICALDAMAGE, target = true, pz = false}, ["m2"] = {atk = "Razor Leaf", minlvl = 80, st = 2019, cd = 3, min = 1000, max = 2000, damage = COMBAT_EARTHDAMAGE, target = true, pz = false}, ["m3"] = {atk = "Vine Whip", minlvl = 80, st = 2020, cd = 3, min = 1000, max = 2000, damage = COMBAT_EARTHDAMAGE, target = false, pz = false}, ["m4"] = {atk = "Headbutt", minlvl = 80, st = 2021, cd = 3, min = 1000, max = 2000, damage = COMBAT_PHYSICALDAMAGE, target = true, pz = false}, ["m5"] = {atk = "Leech Seed", minlvl = 80, st = 2022, cd = 3, min = 1000, max = 2000, damage = COMBAT_EARTHDAMAGE, target = true, pz = false}, ["m6"] = {atk = "Solar Beam", minlvl = 80, st = 2023, cd = 3, min = 1000, max = 2000, damage = COMBAT_EARTHDAMAGE, target = false, pz = false}, ["m7"] = {atk = "Stun Spore", minlvl = 80, st = 2024, cd = 3, min = 0, max = 0, damage = COMBAT_EARTHDAMAGE, target = false, pz = false}, ["m8"] = {atk = "Poison Powder", minlvl = 80, st = 2025, cd = 3, min = 0, max = 0, damage = COMBAT_EARTHDAMAGE, target = false, pz = false}, ["m9"] = {atk = "Sleep Powder", minlvl = 20, st = 2026, cd = 3, min = 0, max = 0, damage = COMBAT_EARTHDAMAGE, target = false, pz = false}, ["m10"] = {atk = "Leaf Storm", minlvl = 80, st = 2027, cd = 3, min = 1000, max = 2000, damage = COMBAT_EARTHDAMAGE, target = false, pz = false}, }, ["Charmander"] = { ["m1"] = {atk = "Scratch", minlvl = 20, st = 2028, cd = 3, min = 100, max = 200, damage = COMBAT_PHYSICALDAMAGE, target = true, pz = false}, ["m2"] = {atk = "Ember", minlvl = 20, st = 2029, cd = 3, min = 100, max = 200, damage = COMBAT_FIREDAMAGE, target = false, pz = false}, ["m3"] = {atk = "Flamethrower", minlvl = 20, st = 2030, cd = 3, min = 100, max = 200, damage = COMBAT_FIREDAMAGE, target = false, pz = false}, ["m4"] = {atk = "Fire Ball", minlvl = 20, st = 2031, cd = 3, min = 100, max = 200, damage = COMBAT_FIREDAMAGE, target = true, pz = false}, ["m5"] = {atk = "Fire Blast", minlvl = 20, st = 2032, cd = 3, min = 100, max = 200, damage = COMBAT_FIREDAMAGE, target = false, pz = false}, ["m6"] = {atk = "Rage", minlvl = 20, st = 2033, cd = 3, min = 100, max = 200, damage = COMBAT_PHYSICALDAMAGE, target = true, pz = false}, ["m7"] = {atk = "Fire Fang", minlvl = 20, st = 2034, cd = 3, min = 100, max = 200, damage = COMBAT_FIREDAMAGE, target = true, pz = false}, }, ["Charmeleon"] = { ["m1"] = {atk = "Scratch", minlvl = 40, st = 2035, cd = 3, min = 300, max = 400, damage = COMBAT_PHYSICALDAMAGE, target = true, pz = false}, ["m2"] = {atk = "Ember", minlvl = 40, st = 2036, cd = 3, min = 300, max = 400, damage = COMBAT_FIREDAMAGE, target = false, pz = false}, ["m3"] = {atk = "Flamethrower", minlvl = 40, st = 2037, cd = 3, min = 400, max = 500, damage = COMBAT_FIREDAMAGE, target = false, pz = false}, ["m4"] = {atk = "Fire Ball", minlvl = 40, st = 2038, cd = 3, min = 300, max =400, damage = COMBAT_FIREDAMAGE, target = true, pz = false}, ["m5"] = {atk = "Fire Blast", minlvl = 40, st = 2039, cd = 3, min = 300, max = 400, damage = COMBAT_FIREDAMAGE, target = false, pz = false}, ["m6"] = {atk = "Rage", minlvl = 40, st = 2040, cd = 3, min = 100, max = 300, damage = COMBAT_PHYSICALDAMAGE, target = true, pz = false}, ["m7"] = {atk = "Fire Fang", minlvl = 40, st = 2041, cd = 3, min = 400, max = 800, damage = COMBAT_FIREDAMAGE, target = true, pz = false}, }, ["Charizard"] = { ["m1"] = {atk = "Dragon Claw", minlvl = 80, st = 2042, cd = 3, min = 1000, max = 2000, damage = COMBAT_PHYSICALDAMAGE, target = true, pz = false}, ["m2"] = {atk = "Ember", minlvl = 80, st = 2043, cd = 3, min = 1000, max = 2000, damage = COMBAT_FIREDAMAGE, target = false, pz = false}, ["m3"] = {atk = "Flamethrower", minlvl = 80, st = 2044, cd = 3, min = 1000, max = 2000, damage = COMBAT_FIREDAMAGE, target = false, pz = false}, ["m4"] = {atk = "Fire Ball", minlvl = 80, st = 2045, cd = 3, min = 1000, max = 2000, damage = COMBAT_FIREDAMAGE, target = true, pz = false}, ["m5"] = {atk = "Fire Blast", minlvl = 80, st = 2046, cd = 3, min = 1000, max = 2000, damage = COMBAT_FIREDAMAGE, target = false, pz = false}, ["m6"] = {atk = "Rage", minlvl = 80, st = 2047, cd = 3, min = 1000, max = 2000, damage = COMBAT_PHYSICALDAMAGE, target = true, pz = false}, ["m7"] = {atk = "Magma Storm", minlvl = 80, st = 2048, cd = 3, min = 1000, max = 2000, damage = COMBAT_FIREDAMAGE, target = false, pz = false}, ["m8"] = {atk = "Wing Attack", minlvl = 80, st = 2049, cd = 3, min = 1000, max = 2000, damage = COMBAT_PHYSICALDAMAGE, target = false, pz = false}, }, ["Squirtle"] = { ["m1"] = {atk = "Headbutt", minlvl = 20, st = 2050, cd = 3, min = 100, max = 200, damage = COMBAT_PHYSICALDAMAGE, target = true, pz = false}, ["m2"] = {atk = "Bubbles", minlvl = 20, st = 2051, cd = 3, min = 100, max = 200, damage = COMBAT_ICEDAMAGE, target = true, pz = false}, ["m3"] = {atk = "Water Gun", minlvl = 20, st = 2052, cd = 3, min = 100, max = 200, damage = COMBAT_ICEDAMAGE, target = false, pz = false}, ["m4"] = {atk = "Waterball", minlvl = 20, st = 2053, cd = 3, min = 100, max = 200, damage = COMBAT_ICEDAMAGE, target = true, pz = false}, ["m5"] = {atk = "Aqua Tail", minlvl = 20, st = 2054, cd = 3, min = 100, max = 200, damage = COMBAT_ICEDAMAGE, target = false, pz = false}, ["m6"] = {atk = "Hydro Cannon", minlvl = 20, st = 2055, cd = 3, min = 200, max = 400, damage = COMBAT_ICEDAMAGE, target = false, pz = false}, ["m7"] = {atk = "Harden", minlvl = 20, st = 2056, cd = 60, min = 100, max = 200, damage = COMBAT_PHYSICALDAMAGE, target = false, pz = true}, ["m8"] = {atk = "Surf", minlvl = 20, st = 2057, cd = 3, min = 100, max = 200, damage = COMBAT_ICEDAMAGE, target = false, pz = false}, }, ["Wartortle"] = { ["m1"] = {atk = "Headbutt", minlvl = 40, st = 2058, cd = 3, min = 100, max = 200, damage = COMBAT_PHYSICALDAMAGE, target = true, pz = false}, ["m2"] = {atk = "Bubbles", minlvl = 40, st = 2059, cd = 3, min = 100, max = 200, damage = COMBAT_ICEDAMAGE, target = true, pz = false}, ["m3"] = {atk = "Water Gun", minlvl = 40, st = 2060, cd = 3, min = 100, max = 200, damage = COMBAT_ICEDAMAGE, target = false, pz = false}, ["m4"] = {atk = "Waterball", minlvl = 40, st = 2061, cd = 3, min = 100, max = 200, damage = COMBAT_ICEDAMAGE, target = true, pz = false}, ["m5"] = {atk = "Aqua Tail", minlvl = 40, st = 2062, cd = 3, min = 100, max = 200, damage = COMBAT_ICEDAMAGE, target = false, pz = false}, ["m6"] = {atk = "Hydro Cannon", minlvl = 40, st = 2063, cd = 3, min = 200, max = 400, damage = COMBAT_ICEDAMAGE, target = false, pz = false}, ["m7"] = {atk = "Harden", minlvl = 40, st = 2064, cd = 60, min = 100, max = 200, damage = COMBAT_PHYSICALDAMAGE, target = false, pz = true}, ["m8"] = {atk = "Surf", minlvl = 40, st = 2065, cd = 3, min = 100, max = 200, damage = COMBAT_ICEDAMAGE, target = false, pz = false}, }, ["Blastoise"] = { ["m1"] = {atk = "Headbutt", minlvl = 40, st = 2066, cd = 3, min = 100, max = 200, damage = COMBAT_PHYSICALDAMAGE, target = true, pz = false}, ["m2"] = {atk = "Bubbles", minlvl = 40, st = 2067, cd = 3, min = 100, max = 200, damage = COMBAT_ICEDAMAGE, target = true, pz = false}, ["m3"] = {atk = "Water Gun", minlvl = 40, st = 2068, cd = 3, min = 100, max = 200, damage = COMBAT_ICEDAMAGE, target = false, pz = false}, ["m4"] = {atk = "Waterball", minlvl = 40, st = 2069, cd = 3, min = 100, max = 200, damage = COMBAT_ICEDAMAGE, target = true, pz = false}, ["m5"] = {atk = "Aqua Tail", minlvl = 40, st = 2070, cd = 3, min = 100, max = 200, damage = COMBAT_ICEDAMAGE, target = false, pz = false}, ["m6"] = {atk = "Hydro Cannon", minlvl = 40, st = 2071, cd = 3, min = 200, max = 400, damage = COMBAT_ICEDAMAGE, target = false, pz = false}, ["m7"] = {atk = "Harden", minlvl = 40, st = 2072, cd = 60, min = 100, max = 200, damage = COMBAT_PHYSICALDAMAGE, target = false, pz = true}, ["m8"] = {atk = "Surf", minlvl = 40, st = 2073, cd = 3, min = 100, max = 200, damage = COMBAT_ICEDAMAGE, target = false, pz = false}, ["m9"] = {atk = "Hydropump", minlvl = 40, st = 2074, cd = 3, min = 100, max = 200, damage = COMBAT_ICEDAMAGE, target = false, pz = false}, }, ["Caterpie"] = { ["m1"] = {atk = "Headbutt", minlvl = 1, st = 2075, cd = 3, min = 100, max = 200, damage = COMBAT_PHYSICALDAMAGE, target = true, pz = false}, ["m2"] = {atk = "String Shot", minlvl = 1, st = 2076, cd = 3, min = 100, max = 200, damage = COMBAT_PHYSICALDAMAGE, target = true, pz = false}, ["m3"] = {atk = "Bug Bite", minlvl = 1, st = 2077, cd = 3, min = 100, max = 200, damage = COMBAT_PHYSICALDAMAGE, target = true, pz = false}, }, ["Metapod"] = { ["m1"] = {atk = "Headbutt", minlvl = 10, st = 2078, cd = 3, min = 100, max = 200, damage = COMBAT_PHYSICALDAMAGE, target = true, pz = false}, ["m2"] = {atk = "String Shot", minlvl = 10, st = 2079, cd = 3, min = 100, max = 200, damage = COMBAT_PHYSICALDAMAGE, target = true, pz = false}, ["m3"] = {atk = "Bug Bite", minlvl = 10, st = 2080, cd = 3, min = 100, max = 200, damage = COMBAT_PHYSICALDAMAGE, target = true, pz = false}, ["m4"] = {atk = "Harden", minlvl = 10, st = 2081, cd = 3, min = 100, max = 200, damage = COMBAT_PHYSICALDAMAGE, target = false, pz = true}, }, ["Butterfree"] = { ["m1"] = {atk = "Headbutt", minlvl = 30, st = 2082, cd = 3, min = 100, max = 200, damage = COMBAT_PHYSICALDAMAGE, target = true, pz = false}, ["m2"] = {atk = "Whirlwind", minlvl = 30, st = 2083, cd = 3, min = 100, max = 200, damage = COMBAT_PHYSICALDAMAGE, target = false, pz = false}, ["m3"] = {atk = "Super Sonic", minlvl = 30, st = 2084, cd = 3, min = 100, max = 200, damage = COMBAT_PHYSICALDAMAGE, target = true, pz = false}, ["m4"] = {atk = "Stun Spore", minlvl = 30, st = 2085, cd = 3, min = 0, max = 0, damage = COMBAT_EARTHDAMAGE, target = false, pz = false}, ["m5"] = {atk = "Poison Powder", minlvl = 30, st = 2086, cd = 3, min = 0, max = 0, damage = COMBAT_EARTHDAMAGE, target = false, pz = false}, ["m6"] = {atk = "Sleep Powder", minlvl = 30, st = 2087, cd = 3, min = 0, max = 0, damage = COMBAT_EARTHDAMAGE, target = false, pz = false}, ["m7"] = {atk = "Psybeam", minlvl = 30, st = 2088, cd = 3, min = 100, max = 200, damage = COMBAT_PHYSICALDAMAGE, target = false, pz = false}, ["m8"] = {atk = "Confusion", minlvl = 30, st = 2089, cd = 3, min = 100, max = 200, damage = COMBAT_PHYSICALDAMAGE, target = false, pz = false}, }, ["Weedle"] = { ["m1"] = {atk = "Horn Attack", minlvl = 1, st = 2090, cd = 3, min = 100, max = 200, damage = COMBAT_PHYSICALDAMAGE, target = true, pz = false}, ["m2"] = {atk = "String Shot", minlvl = 1, st = 2091, cd = 3, min = 100, max = 200, damage = COMBAT_PHYSICALDAMAGE, target = true, pz = false}, ["m3"] = {atk = "Poison Sting", minlvl = 1, st = 2092, cd = 3, min = 100, max = 200, damage = COMBAT_PHYSICALDAMAGE, target = true, pz = false}, }, ["Kakuna"] = { ["m1"] = {atk = "Bug Bite", minlvl = 10, st = 2093, cd = 3, min = 100, max = 200, damage = COMBAT_PHYSICALDAMAGE, target = true, pz = false}, ["m2"] = {atk = "String Shot", minlvl = 10, st = 2094, cd = 3, min = 100, max = 200, damage = COMBAT_PHYSICALDAMAGE, target = true, pz = false}, ["m3"] = {atk = "Poison Sting", minlvl = 10, st = 2095, cd = 3, min = 100, max = 200, damage = COMBAT_PHYSICALDAMAGE, target = true, pz = false}, ["m4"] = {atk = "Harden", minlvl = 10, st = 2096, cd = 3, min = 100, max = 200, damage = COMBAT_PHYSICALDAMAGE, target = true, pz = true}, }, ["Beedrill"] = { ["m1"] = {atk = "Fury Cutter", minlvl = 10, st = 2097, cd = 3, min = 100, max = 200, damage = COMBAT_PHYSICALDAMAGE, target = true, pz = false}, ["m2"] = {atk = "String Shot", minlvl = 10, st = 2098, cd = 3, min = 100, max = 200, damage = COMBAT_PHYSICALDAMAGE, target = true, pz = false}, ["m3"] = {atk = "Poison Sting", minlvl = 10, st = 2099, cd = 3, min = 100, max = 200, damage = COMBAT_PHYSICALDAMAGE, target = true, pz = false}, ["m4"] = {atk = "Pin Missile", minlvl = 10, st = 2100, cd = 3, min = 100, max = 200, damage = COMBAT_PHYSICALDAMAGE, target = true, pz = false}, ["m5"] = {atk = "Rage", minlvl = 10, st = 2101, cd = 3, min = 100, max = 200, damage = COMBAT_PHYSICALDAMAGE, target = true, pz = false}, ["m6"] = {atk = "Strafe", minlvl = 10, st = 2102, cd = 3, min = 100, max = 200, damage = COMBAT_PHYSICALDAMAGE, target = true, pz = false}, }, } function onSay(cid, words, param) if #getCreatureSummons(cid) == 0 then return doPlayerSendCancel(cid, "You do not have any pokemon.") end local poke = d[getCreatureName(getCreatureSummons(cid)[1])][words] if not poke then return true end local storage = poke.st local exst = 16265 local cdexst = 0.5 local cd = math.ceil(poke.cd/2) local pet = getCreatureSummons(cid)[1] local target = getCreatureTarget(cid) local look = getCreatureLookDir(pet) local position = getThingPos(pet) if getTilePzInfo(getCreaturePosition(pet)) and poke.pz == false then return doPlayerSendCancel(cid, "Not Attack in protection zone.") end if getPlayerLevel(cid) < poke.minlvl then return doPlayerSendTextMessage(cid, 19, "Your need level "..poke.minlvl.." to use " ..poke.atk..".") end if os.time()-getPlayerStorageValue(cid, storage) <= cd then minutes,seconds = getTime(cd-(os.time()-getPlayerStorageValue(cid, storage))) return doPlayerSendTextMessage(cid, 27, "Wait "..seconds.." seconds to use "..poke.atk..".") end if target == 0 and poke.target then return doPlayerSendTextMessage(cid, 19, "This Pokemon Attack need any target.") end if os.time()-getPlayerStorageValue(cid, exst) <= cdexst then minutes,seconds = getTime(cdexst-(os.time()-getPlayerStorageValue(cid, exst))) return doPlayerSendCancel(cid, "Poke exhausted") end local critico = math.random(100) < 10 and 2 or 1 --ATTACKS if poke.atk == "Quick Attack" then if getDistanceBetween(getCreaturePosition(pet), getCreaturePosition(target)) > 1 then return doPlayerSendCancel(cid, "Target is far away.") end doAreaCombatHealth(pet, poke.damage, getThingPos(target), 0, -poke.min, -poke.max * critico, 148) elseif poke.atk == "Razor Leaf" then if getDistanceBetween(getCreaturePosition(pet), getCreaturePosition(target)) > 5 then return doPlayerSendCancel(cid, "Target is far away.") end doSendDistanceShoot(getCreaturePosition(pet), getCreaturePosition(target), 4) doAreaCombatHealth(pet, poke.damage, getThingPos(target), 0, -poke.min, -poke.max * critico, 79) elseif poke.atk == "Vine Whip" then local effects = { [0] = 80, [1] = 83, [2] = 81, [3] = 82 } doAreaCombatHealth(pet, poke.damage, getThingPos(pet), areadirecion1[look], -poke.min, -poke.max * critico, effects[look]) elseif poke.atk == "Headbutt" then if getDistanceBetween(getCreaturePosition(pet), getCreaturePosition(target)) > 1 then return doPlayerSendCancel(cid, "Target is far away.") end doAreaCombatHealth(pet, poke.damage, getThingPos(target), 0, -poke.min, -poke.max * critico, 111) elseif poke.atk == "Leech Seed" then if getDistanceBetween(getCreaturePosition(pet), getCreaturePosition(target)) > 5 then return doPlayerSendCancel(cid, "Target is far away.") end doSendDistanceShoot(getCreaturePosition(pet), getCreaturePosition(target), 6) doSendAnimatedText(getCreaturePosition(target), "POISON", 66) addEvent(Poison, 500, target, 45, 5) elseif poke.atk == "Solar Beam" then local a = { [0] = {x = 0, y = -1, effect={[1]=94,[2]=93,[3]=93,[4]=95}}, [1] = {x = 1, y = 0, effect={[1]=86,[2]=88,[3]=88,[4]=87}}, [2] = {x = 0, y = 1, effect={[1]=91,[2]=93,[3]=93,[4]=92}}, [3] = {x = -1, y = 0, effect={[1]=89,[2]=88,[3]=88,[4]=90}} } for i = 1,4 do doSendMagicEffect({x = position.x + a[look].x*i, y = position.y + a[look].y*i, z = position.z}, a[look].effect[i]) end doAreaCombatHealth(pet, poke.damage, getThingPos(pet), areadirecion2[look], -poke.min, -poke.max * critico, 59) elseif poke.atk == "Stun Spore" then local d = getCreaturesInRange(getThingPos(pet), 1, 1, 1, 0) for _,pid in pairs(d) do Paralize(pid) end doAreaCombatHealth(pet, poke.damage, getThingPos(pet), area2, -poke.min, -poke.max * critico, 85) elseif poke.atk == "Poison Powder" then local d = getCreaturesInRange(getThingPos(pet), 1, 1, 1, 0) for _,pid in pairs(d) do doSendAnimatedText(getCreaturePosition(pid), "POISON", 66) Poison(pid, 8, 5) end doAreaCombatHealth(pet, poke.damage, getThingPos(pet), area2, -poke.min, -poke.max * critico, 84) elseif poke.atk == "Sleep Powder" then local d = getCreaturesInRange(getThingPos(pet), 1, 1, 1, 0) for _,pid in pairs(d) do Sleep(pid) end doAreaCombatHealth(pet, poke.damage, getThingPos(pet), area2, -poke.min, -poke.max * critico, 27) elseif poke.atk == "Leaf Storm" then local d = getCreaturesInRange(getThingPos(pet), 3, 3, 1, 0) for _,pid in pairs(d) do for i = 1, 4 do if i == 1 then addEvent(doAreaCombatHealth, 400, pet, poke.damage, getThingPos(pid), 0, -poke.min, -poke.max * critico, 79) doSendDistanceShoot(getPosToStorm(getCreaturePosition(pid)), getCreaturePosition(pid), 4) else addEvent(doAreaCombatHealth, i*800 ,pet, poke.damage, getThingPos(pid), 0, -poke.min, -poke.max * critico, 79) addEvent(doSendDistanceShoot, i*600, getPosToStorm(getCreaturePosition(pid)), getCreaturePosition(pid), 4) end end end elseif poke.atk == "Scratch" then if getDistanceBetween(getCreaturePosition(pet), getCreaturePosition(target)) > 1 then return doPlayerSendCancel(cid, "Target is far away.") end doAreaCombatHealth(pet, poke.damage, getThingPos(target), 0, -poke.min, -poke.max * critico, 142) elseif poke.atk == "Ember" then doAreaCombatHealth(pet, poke.damage, getThingPos(pet), area2, -poke.min, -poke.max * critico, 15) elseif poke.atk == "Flamethrower" then local effects = { [0] = 55, [1] = 58, [2] = 56, [3] = 57 } doAreaCombatHealth(pet, poke.damage, getThingPos(pet), areadirecion1[look], -poke.min, -poke.max * critico, effects[look]) elseif poke.atk == "Fire Ball" then if getDistanceBetween(getCreaturePosition(pet), getCreaturePosition(target)) > 5 then return doPlayerSendCancel(cid, "Target is far away.") end doSendDistanceShoot(getCreaturePosition(pet), getCreaturePosition(target), 3) doAreaCombatHealth(pet, poke.damage, getThingPos(target), 0, -poke.min, -poke.max * critico, 5) elseif poke.atk == "Fire Blast" then local a = { [0] = {x = 0, y = -1, effect= 60}, [1] = {x = 1, y = 0, effect= 61}, [2] = {x = 0, y = 1, effect= 62}, [3] = {x = -1, y = 0, effect= 63} } for i = 1,8 do if i == 1 then doSendMagicEffect({x = position.x + a[look].x*i, y = position.y + a[look].y*i, z = position.z}, a[look].effect) doAreaCombatHealth(pet, poke.damage, getThingPos(pet), areadirecion3[look], -poke.min, -poke.max * critico, 15) else addEvent(doSendMagicEffect, i*300, {x = position.x + a[look].x*i, y = position.y + a[look].y*i, z = position.z}, a[look].effect) addEvent(doAreaCombatHealth, i*300, pet, poke.damage, getThingPos(pet), areadirecion3[look], -poke.min, -poke.max * critico, 15) end end elseif poke.atk == "Rage" then if getDistanceBetween(getCreaturePosition(pet), getCreaturePosition(target)) > 1 then return doPlayerSendCancel(cid, "Target is far away.") end for i = 1,4 do if i == 1 then doSendMagicEffect(position, 168) doAreaCombatHealth(pet, poke.damage, getThingPos(target), 0, -poke.min, -poke.max * critico, 142) else addEvent(doAreaCombatHealth, i*500, pet, poke.damage, getThingPos(target), 0, -poke.min, -poke.max * critico, 142) end end elseif poke.atk == "Fire Fang" then if getDistanceBetween(getCreaturePosition(pet), getCreaturePosition(target)) > 1 then return doPlayerSendCancel(cid, "Target is far away.") end doAreaCombatHealth(pet, poke.damage, getThingPos(target), 0, -poke.min, -poke.max * critico, 146) addEvent(doAreaCombatHealth, 200, pet, poke.damage, getThingPos(target), 0, -poke.min, -poke.max * critico, 15) addEvent(doAreaCombatHealth, 400, pet, poke.damage, getThingPos(target), 0, -poke.min, -poke.max * critico, 15) elseif poke.atk == "Dragon Claw" then if getDistanceBetween(getCreaturePosition(pet), getCreaturePosition(target)) > 1 then return doPlayerSendCancel(cid, "Target is far away.") end doAreaCombatHealth(pet, poke.damage, getThingPos(target), 0, -poke.min, -poke.max * critico, 141) elseif poke.atk == "Magma Storm" then doAreaCombatHealth(pet, poke.damage, getThingPos(pet), area2, -poke.min, -poke.max * critico, 36) addEvent(doAreaCombatHealth, 800, pet, poke.damage, getThingPos(pet), area1, -poke.min, -poke.max * critico, 6) elseif poke.atk == "Wing Attack" then doAreaCombatHealth(pet, poke.damage, getThingPos(pet), area2, -poke.min, -poke.max * critico, 115) addEvent(doAreaCombatHealth, 500, pet, poke.damage, getThingPos(pet), area1, -poke.min, -poke.max * critico, 42) elseif poke.atk == "Bubbles" then if getDistanceBetween(getCreaturePosition(pet), getCreaturePosition(target)) > 5 then return doPlayerSendCancel(cid, "Target is far away.") end doSendDistanceShoot(getCreaturePosition(pet), getCreaturePosition(target), 2) doAreaCombatHealth(pet, poke.damage, getThingPos(target), 0, -poke.min, -poke.max * critico, 68) elseif poke.atk == "Water Gun" then local a = { [0] = {x = 0, y = -1, effect={[1]=74,[2]=75,[3]=75,[4]=76}}, [1] = {x = 1, y = 0, effect={[1]=69,[2]=70,[3]=70,[4]=71}}, [2] = {x = 0, y = 1, effect={[1]=77,[2]=75,[3]=75,[4]=78}}, [3] = {x = -1, y = 0, effect={[1]=72,[2]=70,[3]=70,[4]=73}} } for i = 1,4 do doSendMagicEffect({x = position.x + a[look].x*i, y = position.y + a[look].y*i, z = position.z}, a[look].effect[i]) end doAreaCombatHealth(pet, poke.damage, getThingPos(pet), areadirecion2[look], -poke.min, -poke.max * critico, 59) elseif poke.atk == "Waterball" then for i = 1,5 do if i == 1 then addEvent(doAreaCombatHealth, 200 ,pet, poke.damage, getThingPos(target), 0, -poke.min, -poke.max * critico, 68) doSendDistanceShoot(getPosToStorm(getCreaturePosition(target)), getCreaturePosition(target), 2) else addEvent(doAreaCombatHealth, i*700 ,pet, poke.damage, getThingPos(target), 0, -poke.min, -poke.max * critico, 68) addEvent(doSendDistanceShoot, i*500, getPosToStorm(getCreaturePosition(target)), getCreaturePosition(target), 2) end end elseif poke.atk == "Aqua Tail" then doAreaCombatHealth(pet, poke.damage, getThingPos(pet), area2, -poke.min, -poke.max * critico, 160) elseif poke.atk == "Hydro Cannon" then local a = { [0] = {x = 0, y = -1, effect={[1]=74,[2]=75,[3]=75,[4]=75,[5]=75,[6]=75,[7]=75,[8]=76}}, [1] = {x = 1, y = 0, effect={[1]=69,[2]=70,[3]=70,[4]=70,[5]=70,[6]=70,[7]=70,[8]=71}}, [2] = {x = 0, y = 1, effect={[1]=77,[2]=75,[3]=75,[4]=75,[5]=75,[6]=75,[7]=75,[4]=78}}, [3] = {x = -1, y = 0, effect={[1]=72,[2]=70,[3]=70,[4]=70,[5]=70,[6]=70,[7]=70,[8]=73}} } for i = 1,8 do doSendMagicEffect({x = position.x + a[look].x*i, y = position.y + a[look].y*i, z = position.z}, a[look].effect[i]) end doAreaCombatHealth(pet, poke.damage, getThingPos(pet), areadirecion3[look], -poke.min, -poke.max * critico, 59) elseif poke.atk == "Harden" then function Harden(cid, rounds) if rounds == 0 then return false end if #getCreatureSummons(cid) == 0 then return false end doSendMagicEffect(getCreaturePosition(getCreatureSummons(cid)[1]), 144) return addEvent(Harden, 1000, cid, rounds-1) end addEvent(Harden, 500, cid, 40) elseif poke.atk == "Surf" then local a = { [0] = {x = 0, y = -1, effect= 66}, [1] = {x = 1, y = 0, effect= 67}, [2] = {x = 0, y = 1, effect= 64}, [3] = {x = -1, y = 0, effect= 65} } for i = 1,8 do if i == 1 then doSendMagicEffect({x = position.x + a[look].x*i, y = position.y + a[look].y*i, z = position.z}, a[look].effect) doAreaCombatHealth(pet, poke.damage, getThingPos(pet), areadirecion3[look], -poke.min, -poke.max * critico, 68) else addEvent(doSendMagicEffect, i*300, {x = position.x + a[look].x*i, y = position.y + a[look].y*i, z = position.z}, a[look].effect) addEvent(doAreaCombatHealth, i*300, pet, poke.damage, getThingPos(pet), areadirecion3[look], -poke.min, -poke.max * critico, 68) end end elseif poke.atk == "Hydropump" then local a = { [0] = {x = 0, y = -1, effect={[1]=74,[2]=75,[3]=75,[4]=75,[5]=75,[6]=75,[7]=75,[8]=76}}, [1] = {x = 1, y = 0, effect={[1]=69,[2]=70,[3]=70,[4]=70,[5]=70,[6]=70,[7]=70,[8]=71}}, [2] = {x = 0, y = 1, effect={[1]=77,[2]=75,[3]=75,[4]=75,[5]=75,[6]=75,[7]=75,[4]=78}}, [3] = {x = -1, y = 0, effect={[1]=72,[2]=70,[3]=70,[4]=70,[5]=70,[6]=70,[7]=70,[8]=73}} } for i = 1,8 do doSendMagicEffect({x = position.x + a[look].x*i, y = position.y + a[look].y*i, z = position.z}, a[look].effect[i]) end doAreaCombatHealth(pet, poke.damage, getThingPos(pet), areadirecion3[look], -poke.min, -poke.max * critico, 68) addEvent(doAreaCombatHealth, 400, pet, poke.damage, getThingPos(pet), areadirecion3[look], -poke.min, -poke.max * critico, 33) elseif poke.atk == "String Shot" then if getDistanceBetween(getCreaturePosition(pet), getCreaturePosition(target)) > 5 then return doPlayerSendCancel(cid, "Target is far away.") end doSendDistanceShoot(getCreaturePosition(pet), getCreaturePosition(target), 23) doAreaCombatHealth(pet, poke.damage, getThingPos(target), 0, -poke.min, -poke.max * critico, 137) Paralize(target) elseif poke.atk == "Bug Bite" then if getDistanceBetween(getCreaturePosition(pet), getCreaturePosition(target)) > 1 then return doPlayerSendCancel(cid, "Target is far away.") end doAreaCombatHealth(pet, poke.damage, getThingPos(target), 0, -poke.min, -poke.max * critico, 146) elseif poke.atk == "Whirlwind" then doAreaCombatHealth(pet, poke.damage, getThingPos(pet), areadirecion4[look], -poke.min, -poke.max * critico, 42) elseif poke.atk == "Super Sonic" then if getDistanceBetween(getCreaturePosition(pet), getCreaturePosition(target)) > 5 then return doPlayerSendCancel(cid, "Target is far away.") end for i = 1, 3 do if i == 1 then doSendDistanceShoot(getCreaturePosition(pet), getCreaturePosition(target), 24) else addEvent(doSendDistanceShoot, i * 200, getCreaturePosition(pet), getCreaturePosition(target), 24) end end addEvent(doSendAnimatedText, 500, getCreaturePosition(target), "CONF", 210) addEvent(Confused, 500, target, 15) elseif poke.atk == "Psybeam" then local a = { [0] = {x = 0, y = -1, effect={[1]=108,[2]=109,[3]=109,[4]=108}}, [1] = {x = 1, y = 0, effect={[1]=106,[2]=107,[3]=107,[4]=106}}, [2] = {x = 0, y = 1, effect={[1]=109,[2]=108,[3]=108,[4]=109}}, [3] = {x = -1, y = 0, effect={[1]=107,[2]=106,[3]=106,[4]=107}} } for i = 1,4 do doSendMagicEffect({x = position.x + a[look].x*i, y = position.y + a[look].y*i, z = position.z}, a[look].effect[i]) end doAreaCombatHealth(pet, poke.damage, getThingPos(pet), areadirecion2[look], -poke.min, -poke.max * critico, 59) elseif poke.atk == "Confusion" then doAreaCombatHealth(pet, poke.damage, getThingPos(pet), area3, -poke.min, -poke.max * critico, 136) elseif poke.atk == "Horn Attack" then if getDistanceBetween(getCreaturePosition(pet), getCreaturePosition(target)) > 1 then return doPlayerSendCancel(cid, "Target is far away.") end doAreaCombatHealth(pet, poke.damage, getThingPos(target), 0, -poke.min, -poke.max * critico, 111) elseif poke.atk == "Poison Sting" then if getDistanceBetween(getCreaturePosition(pet), getCreaturePosition(target)) > 5 then return doPlayerSendCancel(cid, "Target is far away.") end doSendDistanceShoot(getCreaturePosition(pet), getCreaturePosition(target), 15) doAreaCombatHealth(pet, poke.damage, getThingPos(target), 0, -poke.min, -poke.max * critico, 9) elseif poke.atk == "Fury Cutter" then if getDistanceBetween(getCreaturePosition(pet), getCreaturePosition(target)) > 1 then return doPlayerSendCancel(cid, "Target is far away.") end doAreaCombatHealth(pet, poke.damage, getThingPos(target), 0, -poke.min, -poke.max * critico, 110) addEvent(doAreaCombatHealth, 500, pet, poke.damage, getThingPos(target), 0, -poke.min, -poke.max * critico, 110) elseif poke.atk == "Pin Missile" then if getDistanceBetween(getCreaturePosition(pet), getCreaturePosition(target)) > 5 then return doPlayerSendCancel(cid, "Target is far away.") end for i = 1, 3 do if i == 1 then doSendDistanceShoot(getCreaturePosition(pet), getCreaturePosition(target), 13) doAreaCombatHealth(pet, poke.damage, getThingPos(target), 0, -poke.min, -poke.max * critico, 137) else addEvent(doSendDistanceShoot, i * 200, getCreaturePosition(pet), getCreaturePosition(target), 13) addEvent(doAreaCombatHealth, i * 200, pet, poke.damage, getThingPos(target), 0, -poke.min, -poke.max * critico, 137) end end elseif poke.atk == "Strafe" then if getDistanceBetween(getCreaturePosition(pet), getCreaturePosition(target)) > 1 then return doPlayerSendCancel(cid, "Target is far away.") end local dd = {142, 111, 110, 148} for i = 1,6 do af = math.random(4) if i == 1 then doAreaCombatHealth(pet, poke.damage, getThingPos(target), 0, -poke.min, -poke.max * critico, dd[af]) else addEvent(doAreaCombatHealth, i*500, pet, poke.damage, getThingPos(target), 0, -poke.min, -poke.max * critico, dd[af]) end end end -- END ATTACKS doPlayerSay(cid, getCreatureName(pet)..", use "..poke.atk..".", 1) setPlayerStorageValue(cid, storage, os.time()+cd) setPlayerStorageValue(cid, exst, os.time()+cdexst) local atknotcritic = {"Harden", "Poison Powder", "Sleep Powder", "Super Sonic", "Stun Spore"} if critico == 2 and not isInArray(atknotcritic, poke.atk) then doSendAnimatedText(getCreaturePosition(cid), "CRITICAL", 144) end return true end
New Tag :
<talkaction words="m1;m2;m3;m4;m5;m6;m7;m8;m9;m10;m11;m12" hide="yes" event="script" value="moves.lua"/>
Pokemons Configurados [15/151] :
-
lemooca reacted to r.f in System M1 ( Pokemon Ots )
Está ai o System m1... ele contem um cooldown, mas não mostra o tempo regressivo para poder mandar a magia denovo.
prescisa de uns reajustes mas acho que ja ajuda
vá em data/spells e crie 1 arquivo chamado m1.lua
local combat1 = createCombatObject() setCombatParam(combat1, COMBAT_PARAM_TYPE, COMBAT_PHYSICALDAMAGE) setCombatParam(combat1, COMBAT_PARAM_EFFECT, 111) setCombatFormula(combat1, COMBAT_FORMULA_LEVELMAGIC, -1, -10, -1, -20, 5, 5, 1.4, 2.1) local combat2 = createCombatObject() setCombatParam(combat2, COMBAT_PARAM_TYPE, COMBAT_PHYSICALDAMAGE) setCombatParam(combat2, COMBAT_PARAM_EFFECT, 42) setAttackFormula(combat2, COMBAT_FORMULA_LEVELMAGIC, 5, 5, 2.5, 4) arr2 = { {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, {0, 0, 0, 3, 0, 3, 0, 3, 0, 0, 0}, {0, 0, 0, 3, 0, 3, 0, 3, 0, 0, 0}, {0, 0, 0, 0, 3, 3, 3, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 3, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, } local area2 = createCombatArea(arr2) setCombatArea(combat2, area2) local combat3 = createCombatObject() setCombatParam(combat3, COMBAT_PARAM_TYPE, COMBAT_PHYSICALDAMAGE) setCombatParam(combat3, COMBAT_PARAM_EFFECT, 142) setCombatFormula(combat3, COMBAT_FORMULA_LEVELMAGIC, -100, -1000, -100, -2000, 500, 500, 100.400, 200.1) local combat4 = createCombatObject() setCombatParam(combat4, COMBAT_PARAM_EFFECT, 141) setCombatParam(combat4, COMBAT_PARAM_TYPE, COMBAT_PHYSICALDAMAGE) setCombatFormula(combat4, COMBAT_FORMULA_LEVELMAGIC, -1, 0, -1, -10, 5, 5, 0.85, 1.95, -20, -40) local combat5 = createCombatObject() setCombatParam(combat5, COMBAT_PARAM_EFFECT, 16) setCombatParam(combat5, COMBAT_PARAM_TYPE, COMBAT_PHYSICALDAMAGE) setCombatFormula(combat5, COMBAT_FORMULA_LEVELMAGIC, -1, 0, -1, -10, 5, 5, 0.85, 1.95, -20, -40) local combat6 = createCombatObject() setCombatParam(combat6, COMBAT_PARAM_TYPE, COMBAT_PHYSICALDAMAGE) setCombatParam(combat6, COMBAT_PARAM_EFFECT, 137) setCombatParam(combat6, COMBAT_PARAM_DISTANCEEFFECT, 23) setCombatFormula(combat6, COMBAT_FORMULA_LEVELMAGIC, -1, -10, -1, -20, 5, 5, 1.4, 2.1) local combat7 = createCombatObject() setCombatParam(combat7, COMBAT_PARAM_TYPE, COMBAT_PHYSICALDAMAGE) setCombatParam(combat7, COMBAT_PARAM_EFFECT, 59) setCombatParam(combat7, COMBAT_PARAM_DISTANCEEFFECT, 23) setCombatFormula(combat7, COMBAT_FORMULA_LEVELMAGIC, -1, -10, -1, -20, 5, 5, 1.4, 2.1) local combat8 = createCombatObject() setCombatParam(combat8, COMBAT_PARAM_TYPE, COMBAT_PHYSICALDAMAGE) setCombatParam(combat8, COMBAT_PARAM_EFFECT, 138) setCombatParam(combat8, COMBAT_PARAM_DISTANCEEFFECT, 138) setCombatFormula(combat8, COMBAT_FORMULA_LEVELMAGIC, -1, -10, -1, -20, 5, 5, 1.4, 2.1) local combat9 = createCombatObject() setCombatParam(combat9, COMBAT_PARAM_TYPE, COMBAT_PHYSICALDAMAGE) setCombatParam(combat9, COMBAT_PARAM_EFFECT, 112) setCombatFormula(combat9, COMBAT_FORMULA_LEVELMAGIC, -1, -10, -1, -20, 5, 5, 1.4, 2.1) local combat10 = createCombatObject() setCombatParam(combat10, COMBAT_PARAM_TYPE, COMBAT_PHYSICALDAMAGE) setCombatParam(combat10, COMBAT_PARAM_EFFECT, 79) setCombatParam(combat10, COMBAT_PARAM_DISTANCEEFFECT, 5) setCombatFormula(combat10, COMBAT_FORMULA_LEVELMAGIC, -2.5, 0, -3.0, 0) local combat11 = createCombatObject() setCombatParam(combat11, COMBAT_PARAM_TYPE, COMBAT_PHYSICALDAMAGE) setCombatParam(combat11, COMBAT_PARAM_EFFECT, 68) setCombatParam(combat11, COMBAT_PARAM_DISTANCEEFFECT, 2) setCombatFormula(combat11, COMBAT_FORMULA_LEVELMAGIC, -2.5, 0, -3.0, 0) local combat12 = createCombatObject() setCombatParam(combat12, COMBAT_PARAM_TYPE, COMBAT_PHYSICALDAMAGE) setCombatParam(combat12, COMBAT_PARAM_EFFECT, 137) setCombatParam(combat12, COMBAT_PARAM_DISTANCEEFFECT, 23) setCombatFormula(combat12, COMBAT_FORMULA_LEVELMAGIC, -1, -10, -1, -20, 5, 5, 1.4, 2.1) local combat13 = createCombatObject() setCombatParam(combat13, COMBAT_PARAM_TYPE, COMBAT_PHYSICALDAMAGE) setCombatParam(combat13, COMBAT_PARAM_EFFECT, 9) setCombatParam(combat13, COMBAT_PARAM_DISTANCEEFFECT, 25) setCombatFormula(combat13, COMBAT_FORMULA_LEVELMAGIC, -1, -10, -1, -20, 5, 5, 1.4, 2.1) local combat14 = createCombatObject() setCombatParam(combat14, COMBAT_PARAM_TYPE, COMBAT_PHYSICALDAMAGE) setCombatParam(combat14, COMBAT_PARAM_EFFECT, 22) setCombatParam(combat14, COMBAT_PARAM_DISTANCEEFFECT, 24) setCombatFormula(combat14, COMBAT_FORMULA_LEVELMAGIC, -2.5, 0, -3.0, 0) local combat15 = createCombatObject() setCombatParam(combat15, COMBAT_PARAM_EFFECT, 122) setCombatParam(combat15, COMBAT_PARAM_TYPE, COMBAT_PHYSICALDAMAGE) setCombatFormula(combat15, COMBAT_FORMULA_LEVELMAGIC, -1, 0, -1, -10, 5, 5, 0.85, 1.95, -20, -40) arr15 = { {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 3, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, } local area15 = createCombatArea(arr15) setCombatArea(combat15, area15) local c = { ["Bulbasaur"] = {x = { m1 = combat1, spell = "Quick Attack", minLv = 20 } }, ["Ivysaur"] = {x = { m1 = combat1, spell = "Quick Attack", minLv = 40 } }, ["Ivysaur"] = {x = { m1 = combat1, spell = "Quick Attack", minLv = 40 } }, ["Venusaur"] = {x = { m1 = combat1, spell = "Quick Attack", minLv = 85 } }, ["Pidgey"] = {x = { m1 = combat1, spell = "Quick Attack", minLv = 5 } }, ["Pidgeotto"] = {x = { m1 = combat1, spell = "Quick Attack", minLv = 20 } }, ["Pidgeotto"] = {x = { m1 = combat1, spell = "Quick Attack", minLv = 20 } }, ["Pidgeot"] = {x = { m1 = combat1, spell = "Quick Attack", minLv = 65 } }, ["Rattata"] = {x = { m1 = combat1, spell = "Quick Attack", minLv = 1 } }, ["Raticate"] = {x = { m1 = combat1, spell = "Quick Attack", minLv = 25 } }, ["Spearow"] = {x = { m1 = combat1, spell = "Quick Attack", minLv = 10 } }, ["Fearow"] = {x = { m1 = combat1, spell = "Quick Attack", minLv = 50 } }, ["Pikachu"] = {x = { m1 = combat1, spell = "Quick Attack", minLv = 20 } }, ["Nidoran Femea"] = {x = { m1 = combat1, spell = "Quick Attack", minLv = 10 } }, ["Nidorina"] = {x = { m1 = combat1, spell = "Quick Attack", minLv = 30 } }, ["Nidoqueen"] = {x = { m1 = combat1, spell = "Quick Attack", minLv = 65 } }, ["Nidoran Macho"] = {x = { m1 = combat1, spell = "Quick Attack", minLv = 10 } }, ["Nidorino"] = {x = { m1 = combat1, spell = "Quick Attack", minLv = 30 } }, ["Nidoking"] = {x = { m1 = combat1, spell = "Quick Attack", minLv = 65 } }, ["Vulpix"] = {x = { m1 = combat1, spell = "Quick Attack", minLv = 15 } }, ["Ninetales"] = {x = { m1 = combat1, spell = "Quick Attack", minLv = 70 } }, ["Ponyta"] = {x = { m1 = combat1, spell = "Quick Attack", minLv = 20 } }, ["Rapidash"] = {x = { m1 = combat1, spell = "Quick Attack", minLv = 55 } }, ["Scyther"] = {x = { m1 = combat1, spell = "Quick Attack", minLv = 80 } }, ["Electabuzz"] = {x = { m1 = combat1, spell = "Quick Attack", minLv = 80 } }, ["Vaporeon"] = {x = { m1 = combat1, spell = "Quick Attack", minLv = 55 } }, ["Jolteon"] = {x = { m1 = combat1, spell = "Quick Attack", minLv = 55 } }, ["Flareon"] = {x = { m1 = combat1, spell = "Quick Attack", minLv = 55 } }, ["Shiny Venusaur"] = {x = { m1 = combat1, spell = "Quick Attack", minLv = 100 } }, ["Shiny Rattata"] = {x = { m1 = combat1, spell = "Quick Attack", minLv = 1 } }, ["Shiny Raticate"] = {x = { m1 = combat1, spell = "Quick Attack", minLv = 25 } }, ["Shiny Scyther"] = {x = { m1 = combat1, spell = "Quick Attack", minLv = 100 } }, ["Shiny Scyther"] = {x = { m1 = combat1, spell = "Quick Attack", minLv = 100 } }, ["Zapdos"] = {x = { m1 = combat2, spell = "Whirlwind", minLv = 100 } }, ["Articuno"] = {x = { m1 = combat2, spell = "Whirlwind", minLv = 150 } }, ["Charmander"] = {x = { m1 = combat3, spell = "Scratch", minLv = 20 } }, ["Charmeleon"] = {x = { m1 = combat3, spell = "Scratch", minLv = 40 } }, ["Paras"] = {x = { m1 = combat3, spell = "Scratch", minLv = 5 } }, ["Mankey"] = {x = { m1 = combat3, spell = "Scratch", minLv = 15 } }, ["Primeape"] = {x = { m1 = combat3, spell = "Scratch", minLv = 50 } }, ["Magmar"] = {x = { m1 = combat3, spell = "Scratch", minLv = 80 } }, ["Pinsir"] = {x = { m1 = combat3, spell = "Scratch", minLv = 45 } }, ["Kabuto"] = {x = { m1 = combat3, spell = "Scratch", minLv = 20 } }, ["Kabutops"] = {x = { m1 = combat3, spell = "Scratch", minLv = 80 } }, ["Snorlax"] = {x = { m1 = combat3, spell = "Scratch", minLv = 1 } }, ["Shiny Paras"] = {x = { m1 = combat3, spell = "Scratch", minLv = 5 } }, ["Charizard"] = {x = { m1 = combat4, spell = "Dragon Claw", minLv = 85 } }, ["Elder Charizard"] = {x = { m1 = combat4, spell = "Dragon Claw", minLv = 100 } }, ["Squirtle"] = {x = { m1 = combat5, spell = "Headbutt", minLv = 20 } }, ["Wartortle"] = {x = { m1 = combat5, spell = "Headbutt", minLv = 40 } }, ["Blastoise"] = {x = { m1 = combat5, spell = "Headbutt", minLv = 85 } }, ["Caterpie"] = {x = { m1 = combat5, spell = "Headbutt", minLv = 1 } }, ["Seel"] = {x = { m1 = combat5, spell = "Headbutt", minLv = 20 } }, ["Drowzee"] = {x = { m1 = combat5, spell = "Headbutt", minLv = 25 } }, ["Hypno"] = {x = { m1 = combat5, spell = "Headbutt", minLv = 55 } }, ["Cubone"] = {x = { m1 = combat5, spell = "Headbutt", minLv = 20 } }, ["Marowak"] = {x = { m1 = combat5, spell = "Headbutt", minLv = 55 } }, ["Tauros"] = {x = { m1 = combat5, spell = "Headbutt", minLv = 45 } }, ["Dragonair"] = {x = { m1 = combat5, spell = "Headbutt", minLv = 60 } }, ["Dragonite"] = {x = { m1 = combat5, spell = "Headbutt", minLv = 100 } }, ["Shiny Blastoise"] = {x = { m1 = combat5, spell = "Headbutt", minLv = 100 } }, ["Shiny Dratini"] = {x = { m1 = combat5, spell = "Headbutt", minLv = 20 } }, ["Metapod"] = {x = { m1 = combat6, spell = "String Shot", minLv = 15, distance = 3 } }, ["Butterfree"] = {x = { m1 = combat6, spell = "String Shot", minLv = 30, distance = 3 } }, ["Kakuna"] = {x = { m1 = combat6, spell = "String Shot", minLv = 15, distance = 3 } }, ["Beedrill"] = {x = { m1 = combat6, spell = "String Shot", minLv = 25, distance = 3 } }, ["Shiny Beedrill"] = {x = { m1 = combat6, spell = "String Shot", minLv = 25, distance = 3 } }, ["Weedle"] = {x = { m1 = combat7, spell = "Horn Attack", minLv = 1, distance = 3 } }, ["Goldeen"] = {x = { m1 = combat7, spell = "Horn Attack", minLv = 10, distance = 3 } }, ["Seaking"] = {x = { m1 = combat7, spell = "Horn Attack", minLv = 35, distance = 3 } }, ["Lapras"] = {x = { m1 = combat7, spell = "Horn Attack", minLv = 80, distance = 3 } }, ["Ekans"] = {x = { m1 = combat8, spell = "Bite", minLv = 15, distance = 3 } }, ["Ekans"] = {x = { m1 = combat8, spell = "Bite", minLv = 15, distance = 3 } }, ["Arbok"] = {x = { m1 = combat8, spell = "Bite", minLv = 35, distance = 3 } }, ["Kangaskhan"] = {x = { m1 = combat8, spell = "Bite", minLv = 80, distance = 3 } }, ["Omanyte"] = {x = { m1 = combat8, spell = "Bite", minLv = 20, distance = 3 } }, ["Omastar"] = {x = { m1 = combat8, spell = "Bite", minLv = 80, distance = 3 } }, ["Raichu"] = {x = { m1 = combat9, spell = "Mega Kick", minLv = 50 } }, ["Shiny Raichu"] = {x = { m1 = combat9, spell = "Mega Kick", minLv = 80 } }, ["Bulbasaur"] = {x = { m1 = combat10, spell = "Razor Leaf", minLv = 20 } }, ["Ivysaur"] = {x = { m1 = combat10, spell = "Razor Leaf", minLv = 40 } }, ["Venusaur"] = {x = { m1 = combat10, spell = "Razor Leaf", minLv = 85 } }, ["Squirtle"] = {x = { m1 = combat11, spell = "Bubbles", minLv = 20 } }, ["Wartortle"] = {x = { m1 = combat11, spell = "Bubbles", minLv = 40 } }, ["Blastoise"] = {x = { m1 = combat11, spell = "Bubbles", minLv = 85 } }, ["Caterpie"] = {x = { m1 = combat12, spell = "String Shot", minLv = 1 } }, ["Metapod"] = {x = { m1 = combat12, spell = "String Shot", minLv = 15 } }, ["Butterfree"] = {x = { m1 = combat12, spell = "String Shot", minLv = 30 } }, ["Weedle"] = {x = { m1 = combat13, spell = "Horn Attack", minLv = 1 } }, ["Kakuna"] = {x = { m1 = combat13, spell = "Horn Attack", minLv = 15 } }, ["Beedrill"] = {x = { m1 = combat13, spell = "Horn Attack", minLv = 30 } }, ["Zubat"] = {x = { m1 = combat14, spell = "Super Sonic", minLv = 10 } }, ["Golbat"] = {x = { m1 = combat14, spell = "Super Sonic", minLv = 30 } }, ["Sandshrew"] = {x = { m1 = combat15, spell = "Sand Attack", minLv = 20 } }, ["Sandslash"] = {x = { m1 = combat15, spell = "Sand Attack", minLv = 55 } }, ["Diglett"] = {x = { m1 = combat15, spell = "Sand Attack", minLv = 10 } }, ["Dugtrio"] = {x = { m1 = combat15, spell = "Sand Attack", minLv = 35 } }, ["Farfetchd"] = {x = { m1 = combat15, spell = "Sand Attack", minLv = 40 } }, ["Doduo"] = {x = { m1 = combat15, spell = "Sand Attack", minLv = 15 } }, ["Dodrio"] = {x = { m1 = combat15, spell = "Sand Attack", minLv = 45 } }, ["Onix"] = {x = { m1 = combat15, spell = "Sand Attack", minLv = 50 } }, ["Eevee"] = {x = { m1 = combat15, spell = "Sand Attack", minLv = 20 } }, ["Eevee"] = {x = { m1 = combat15, spell = "Sand Attack", minLv = 20 } }, ["Shiny Farfetchd"] = {x = { m1 = combat15, spell = "Sand Attack", minLv = 80 } }, ["Crystal Onix"] = {x = { m1 = combat15, spell = "Sand Attack", minLv = 80 } }, ["Mew"] = {x = { m1 = combat1, spell = "Test", minLv = 1, distance = 3 } }, ["Minotaur"] = {x = { m1 = combat1, spell = "Tesurmomt", minLv = 1, distance = 3 } } } function onCastSpell(cid, var) local summ = getCreatureSummons(cid) if #summ == 0 then return doPlayerSendCancel(cid, "Sorry, but you need a pokemon.") end for i = 1, #summ do for name, _ in pairs(c) do if getCreatureName(summ[i]):lower() == name:lower() then local con = c[name].x if getPlayerLevel(cid) < con.minLv then return doPlayerSendCancel(cid, "Sorry, but you must be level " .. con.minLv .. " or higher to cast.") and doSendMagicEffect(getThingPos(cid), 2) end local distance = (not con.distance) and 1 or con.distance if not isCreature(getCreatureTarget(cid)) or getCreatureTarget(cid) == summ[i] then return doPlayerSendCancel(cid, "Invalid target.") and doSendMagicEffect(getThingPos(cid), 2) end if getDistanceBetween(getThingPos(summ[i]), getThingPos(getCreatureTarget(cid))) > distance then return doPlayerSendCancel(cid, "Sorry, your pokemon is too far away.") and doSendMagicEffect(getThingPos(cid), 2) end if getPlayerStorageValue(cid, 23000) <= os.time() then doPlayerSetStorageValue(cid, 23000, os.time()+5) doCombat(summ[i], con.m1, numberToVariant(getCreatureTarget(cid))) doCreatureSay(cid, name .. ", " .. con.spell .. ".") end doPlayerSendCancel(cid, "Cooldown: "..(getPlayerStorageValue(cid, 23000)-os.time()).." sec.") doSendMagicEffect(getThingPos(cid), 2) end end end return true end
TAG - em spells.xml cole isso
<instant name="" words="m1" lvl="1" mana="0" prem="0" range="3" casterTargetOrDirection="1" blockwalls="1" exhaustion="2000" needlearn="0" event="script" value="m1.lua">
Mais rep ali pra euu ;P
-
lemooca got a reaction from joaohd in [Talkaction]Sistema M1 Até M6 + Tutorial De Edições.
1- lugar nao vou postar meu sistema pq é do meu jogo, seu inutil
2- lugar eu entendi bem o tutorial, vc é um preguiçoso e quis ganhar alguns rep+ de graça
3- lugar, se o codigo fosse teu ainda, vc podia reclamar de boca cheia, MAS NEM SEU É, VC SÓ COPIOU DA DISTRO, QUE FOI RELEASED E COPIOU NOVAMENTE MAIS 5X, E FALOU QUE ERA ATÉ O M6.
Agora vai tomar no meio do seu cool você, vc é muito, repito, muito fail mesmo...
Noob
-
lemooca reacted to thalia in [8.54]Pokeserver Tfs 0.3.6 [V3.0]
Oi galera do xtibia, alguns já me conhece , posto scripts na seção de actions/talk/move!
Aqui está a versão 3.0 do PokeServer TFS 0.3.6pl1,
~~( O que contém na versão 3.0? ) ~~
~~>Fly System - Bug corrigido
~~>Ride System- Bug corrigido
~~>Catch System- Bug corrigido
~~>Go/back System- Bug corrigido
~~>Stones System - Bug corrigido
~~>Npc Heal - Bug arrumano
~~>Todos os 151 pokemons (50% configurados)
~~>Skill System - Para cada tipo de pokemon é um poder difirente!
~~>Mapa Svke 70%
~~>Todas as outfits
Stones,Go/back,Npc,Fly,Ride,Skill, foram testados, então não venha encher o saco falando merda
<--! Download !-->
Server 3.0
Client (È extremamento necessario para poder entrar no server!)
Versão 3.0 do server de pokemon
Faça você mesmo!
Créditos ao Drakylucas por me ajuda a fazer os scripts!
Não se esqueça de clicar ali no icone verde
-
Recently Browsing 0 members
- No registered users viewing this page.