Fragdonut
Banned User
anyone using this script, and could give me link to their ots?
In case you want to create the whole monster list, here you go:
PHP:<?php $strg_num = 9541; if(file_exists($path = '/home/migxxx/tfs/data/monster/monsters.xml') && $xml = simplexml_load_file($path)) foreach($xml as $xmlx) echo('["'.strtolower($xmlx['name']).'"] = '.$strg_num++.',<br />'); ?>
<?php
$strg_num = 9541;
if(file_exists($path = '/data/monster/monsters.xml') && $xml = simplexml_load_file($path))
foreach($xml as $xmlx)
echo('\''.strtolower($xmlx['name']).'\' => '.$strg_num++.', ');
?>
<?php
/* Scrip by zonet */
$kills = $config['site']['creatureKills'];
$limit = $config['site']['creatureKillShowLimit'];
$main_content .= '<table border="0px" cellspacing="1px" cellpadding="4px" width="100%">
<tr bgcolor="#505050" style="color: white;"><th width="10%">Creature</th><th>Creature name</th><th>Most Killer ( '.$limit.' )</th></tr>';
$row = 1;
foreach($kills as $name => $storage) {
$qa = $SQL->query('SELECT `player_storage`.`player_id`, `player_storage`.`key`, `player_storage`.`value` AS `value`, `players`.`id`, `players`.`name` AS `name` FROM `player_storage` LEFT JOIN `players` ON `player_storage`.`player_id` = `players`.`id` WHERE `player_storage`.`key` = '.$storage.' ORDER BY ABS(value) DESC LIMIT '.$limit)->fetchAll();
$color = ( $row % 2 ? $config['site']['darkborder'] : $config['site']['lightborder']);
$row++;
$main_content .= '<tr bgcolor="'.$color.'"><td><img src="/monsters/'.(str_replace(" ", "" , $name)).'.gif"></td><td width="20%" style="font-size: 13pt; font-weight: bold; color: darkorange;"><center>'.(ucfirst($name)).'</center></td><td>';
$a = 0;
foreach( $qa as $q )
{
$a++;
if($a == 1)
$main_content .= '<font color="green">';
if($a == $limit)
$main_content .= '<font color="red">';
if($a == $limit/2)
$main_content .= '<font color="darkorange">';
$main_content .= '<b>'.$a.'. Name:</b> <a href="?subtopic=characters&name='.urlencode($q['name']).'">'.$q['name'].'</a> (Kills: '.$q['value'].') </font></font></font><br />';
}
}
$main_content .= '</td></table>';
?>
it will work on 0.3.5? xd
it will work on 0.3.5? xd
I believe there is no need to use this creatureevent, because all can be taken from `environment_killers` & `killers`. But I'm not good in such queries so I can't help you, maybe Elf can do it.
Anyway - good idea & script.
Should work.
How would I go about finding a monster's ID?
Like for example I want to add Orshabaal/Morgaroth/ & Ferumbras.
Anyway very nice <3
There is no monster id, you have just to add the storage for the monster, any storage that is not taken, then name of the monster, and do the same in the lua part.
Try doing it yourself, if you couldn't then tell me name of the monsters
i dont like this script o.o its kinda useless S;:S/
i dont like it :/
D repped anyway