• There is NO official Otland's Discord server and NO official Otland's server list. The Otland's Staff does not manage any Discord server or server list. Moderators or administrator of any Discord server or server lists have NO connection to the Otland's Staff. Do not get scammed!

TalkAction Perfect Bounty Hunters System with PHP for M-AAC (TFS 0.4)

Im back.. for now

Aff, when people die don't recive his reward and the website doesn't works too. appears that in console:

Code:
[05/09/2011 19:23:04] mysql_real_query(): SELECT * FROM `bounty_hunters` WHERE `sp_id` = 46 AND `killed` = 0; - MYSQL ERROR: Unknown column 'sp_id' in 'where clause' (1054)
[05/09/2011 19:23:04] mysql_real_query(): INSERT INTO `bounty_hunters` VALUES (NULL,44,46,0,1315243384,10000,0,0); - MYSQL ERROR: Column count doesn't match value count at row 1 (1136)

Your SQL tables seem corrupt, you will have to drop the "bounty_hunters" table and re-add it. (BEWARE! -This will remove all bountys already set.)

i tried it but im getting target does not exit.
!bounty [10000], [Killme]
/bounty [10000], [Killme]
!hunt

You should write !bounty 10000, killme
 
I configured the system to be run only by god!

for this i need put one protection for if hunted player killer your sef whit mc he no get reward!!!

now u understand ??

sry my inglish
im from brazil!
 
This should have a configurable part, like kill this players 10 times and earn the money.
 
ill look into that sometime after christmas.. im currently making a pot that gives hp to knights, mana to sorcs/druids and hp+mana to paladins :)
 
I configured the system to be run only by god!

for this i need put one protection for if hunted player killer your sef whit mc he no get reward!!!

now u understand ??

sry my inglish
im from brazil!


I understand after reading it 15 times lol >_<

You basically want some kind of MC protection so that the hunted player can not kill himself with another character.. that should be doable.. ill look into it
 
i got an error

cant put a bounty on players

in every intent i got this: 03:12 [Bounty System]: shugah has already got a bounty on his/her head.

i looked in the db and searched for shugah in the BH table and damn, it was empty

suggetions plz?

- - - Updated - - -

i dont get any reward or message when i kill a hunted player

and in the web its still in "still alive"
 
Here is the bountyhunter.php for GESIOR:

PHP:
<?php
if(!defined('INITIALIZED'))
	exit;

$main_content .= '<center><h2>Bounty Hunter</h2><br>Type !hunt [priceOnHead],[name] ingame to put a price on someones head.</center><br>';
$list = $SQL->query('SELECT * FROM `bounty_hunters` ORDER by `id` DESC');

echo '<table border="0" cellspacing="1" width="100%">
<tr bgcolor="'.$a.'"><td width="3%">#</td><td width="20%"><b>Hunted by</b></td><td width="15%" colspan="2"><b>Reward</b></td><td width="20%"><b>Hunted player</b></td><td width="20%"><b>Killed by</b></td></tr>';

$datalist = 0;
foreach($list as $data) {
    if(is_int($datalist / 2))
        $bgcolor = $b;
            else
        $bgcolor = $c;
$datalist++;

$huntedby = $SQL->query('SELECT * FROM `players` WHERE `id` = '.$data['fp_id'].'')->fetch();
$huntedplayer = $SQL->query('SELECT * FROM `players` WHERE `id` = '.$data['sp_id'].'')->fetch();
$killedby = $SQL->query('SELECT * FROM `players` WHERE `id` = '.$data['k_id'].'')->fetch();

if($killedby == 0) { $killedby['name'] = 'STILL ALIVE'; }

echo '<tr bgcolor="'.$bgcolor.'"><td><span style="font-size:11px;color:#a8a8a8;">'.$datalist.'</span></td><td><a href="?subtopic=characters&name='.strtolower($huntedby['name']).'"><span style="font-size:11px;">'.strtoupper($huntedby['name']).'</span></a></td><td><span style="font-size:11px;color:#909090;">'.$data['prize'].'</span></td><td><span style="font-size:11px;">GOLD</span></td><td><a href="?subtopic=characters&name='.strtolower($huntedplayer['name']).'"><span style="font-size:11px;">'.strtoupper($huntedplayer['name']).'</a></td><td><a href="?subtopic=characters&name='.strtolower($killedby['name']).'"><span style="font-size:11px;">'.strtoupper($killedby['name']).'</a></td></tr>';
}
echo '</table>';

?>

Here you go!
 
can anyone help me plz?

the kill trigger doesn't trigger

that means that nothing happends when i killed a hunted player

and in the web it says "still alive"
 
ok it finnaly worked awesome work

but is there a way to edit the code so a player's friend couldn't get the reward abusing with the blesses?

because they get the bless so the dont loose exp or loot and the let their friends kill him.

that makes the bounty hunter system useless

not this i mean every BH system unless they catch those exceptions you follow me right?
 
Here is the bountyhunter.php for GESIOR:

PHP:
<?php
if(!defined('INITIALIZED'))
	exit;

$main_content .= '<center><h2>Bounty Hunter</h2><br>Type !hunt [priceOnHead],[name] ingame to put a price on someones head.</center><br>';
$list = $SQL->query('SELECT * FROM `bounty_hunters` ORDER by `id` DESC');

echo '<table border="0" cellspacing="1" width="100%">
<tr bgcolor="'.$a.'"><td width="3%">#</td><td width="20%"><b>Hunted by</b></td><td width="15%" colspan="2"><b>Reward</b></td><td width="20%"><b>Hunted player</b></td><td width="20%"><b>Killed by</b></td></tr>';

$datalist = 0;
foreach($list as $data) {
    if(is_int($datalist / 2))
        $bgcolor = $b;
            else
        $bgcolor = $c;
$datalist++;

$huntedby = $SQL->query('SELECT * FROM `players` WHERE `id` = '.$data['fp_id'].'')->fetch();
$huntedplayer = $SQL->query('SELECT * FROM `players` WHERE `id` = '.$data['sp_id'].'')->fetch();
$killedby = $SQL->query('SELECT * FROM `players` WHERE `id` = '.$data['k_id'].'')->fetch();

if($killedby == 0) { $killedby['name'] = 'STILL ALIVE'; }

echo '<tr bgcolor="'.$bgcolor.'"><td><span style="font-size:11px;color:#a8a8a8;">'.$datalist.'</span></td><td><a rel="nofollow" href="?subtopic=characters&name='.strtolower($huntedby['name']).'"><span style="font-size:11px;">'.strtoupper($huntedby['name']).'</span></a></td><td><span style="font-size:11px;color:#909090;">'.$data['prize'].'</span></td><td><span style="font-size:11px;">GOLD</span></td><td><a rel="nofollow" href="?subtopic=characters&name='.strtolower($huntedplayer['name']).'"><span style="font-size:11px;">'.strtoupper($huntedplayer['name']).'</a></td><td><a rel="nofollow" href="?subtopic=characters&name='.strtolower($killedby['name']).'"><span style="font-size:11px;">'.strtoupper($killedby['name']).'</a></td></tr>';
}
echo '</table>';

?>

Here you go!


not work for me, you help me?
Blank page
 
Anyone got the sqlite queery for this?
 
Anyone got the sqlite queery for this?

Code:
CREATE TABLE IF NOT EXISTS `bounty_hunters` (
  `id` int(11) NOT NULL,
  `fp_id` int(11) NOT NULL,
  `sp_id` int(11) NOT NULL,
  `k_id` int(11) NOT NULL,
  `added` int(15) NOT NULL,
  `prize` bigint(20) NOT NULL,
  `killed` int(11) NOT NULL,
  `kill_time` int(15) NOT NULL,
  PRIMARY KEY  (`id`)
)
 
Back
Top