function bossbars_module() { global $eqdkp_root_path, $eqdkp, $user, $tpl, $db, $plang, $conf_plus, $pm, $html, $jqueryp; if (!$pm->check(PLUGIN_INSTALLED, 'bosssuite')) { return '<table><tr><td>BossSuite plugin not installed.</td></tr></table>'; } else { // new mgs class require_once $eqdkp_root_path . 'plugins/bosssuite/include/bsmgs.class.php'; $mybsmgs = new BSMGS(); $mybsmgs->load_game_specific_language('bossbase'); require_once $eqdkp_root_path . 'plugins/bosssuite/include/bssql.class.php'; $mybcsql = new BSSQL(); $bb_conf = $mybcsql->get_config('bossbase'); $bc_conf = $mybcsql->get_config('bosscounter'); $sbzone = $mybcsql->get_bzone('bosscounter'); $data = $mybcsql->get_data($bb_conf, $sbzone); require_once $eqdkp_root_path . 'plugins/bosssuite/include/bslink.class.php'; $mybslink = new BSLINK($bc_conf['linkurl'], $bc_conf['linklength']); $bcout = '<style>#bossbars{min-width:200px;}</style>'; $bcout .= '<table width="100%" cellspacing="0" cellpadding="0">'; foreach ($sbzone as $zone => $bosses) { if (!$bc_conf['dynZone'] or $data[$zone]['zk'] > 0) { $zone_name = $user->lang[$zone][$bc_conf['zonelength']]; $killed = $data[$zone]['zk']; $total = sizeof($data[$zone]['bosses']); $percentage = round($killed / $total * 100); $rc = $eqdkp->switch_row_class(); $tooltip = '<table width="100%">'; foreach ($bosses as $boss) { if ($data[$zone]['bosses'][$boss]['kc'] > 0) { $tooltip .= '<tr>'; $tooltip .= '<td align="right">' . $data[$zone]['bosses'][$boss]['kc'] . 'x</td>'; $tooltip .= '<td align="left"><b>' . $mybslink->get_boss_link($boss) . '</b></td>'; $tooltip .= '<td align="right">' . date($user->style['date_notime_short'], $data[$zone]['bosses'][$boss]['fkd']) . '</td>'; $tooltip .= '</tr>'; } else { $tooltip .= '<tr>'; $tooltip .= '<td align="right"> </td>'; $tooltip .= '<td align="left">' . $mybslink->get_boss_link($boss) . '</td>'; $tooltip .= '<td align="right"> </td>'; $tooltip .= '</tr>'; } } $tooltip .= '</table>'; $bcout .= '<tr><td class="' . $rc . '" nowrap="nowrap">'; $bcout .= $jqueryp->ProgressBar($zone . '_bar', $percentage, $html->ToolTip($tooltip, $zone_name . ' : ' . $killed . '/' . $total), 'left'); $bcout .= '</td></tr>'; } } $bcout .= '</table>'; return $bcout; } }
function plus_get_sig_data() { // new mgs class require_once dirname(__FILE__) . '/../include/bsmgs.class.php'; $mybsmgs = new BSMGS(); if (!$mybsmgs->game_supported('bossbase')) { return false; } else { # Get configuration data from the database #################################################### require_once dirname(__FILE__) . '/../include/bssql.class.php'; $mybcsql = new BSSQL(); $bb_conf = $mybcsql->get_config('bossbase'); $bc_conf = $mybcsql->get_config('bosscounter'); $sbzone = $mybcsql->get_bzone(); # Get data #################################################### $data = $mybcsql->get_data($bb_conf, $sbzone); return $data; } }
* Date: $Date$ * ----------------------------------------------------------------------- * @author $Author$ * @copyright 2006-2008 sz3 * @link http://eqdkp-plus.com * @package bosssuite * @version $Rev$ * * $Id$ */ if (!defined('EQDKP_INC')) { die('Do not access this file directly.'); } // new mgs class require_once dirname(__FILE__) . '/../include/bsmgs.class.php'; $mybsmgs = new BSMGS(); # Check whether the current game is supported #################################################### if (!$mybsmgs->game_supported('bossbase')) { $bcout = '<table width=100% class="borderless" cellspacing="0" cellpadding="2"> <tr><th colspan="2" align="center">BossCounter</th></tr>' . "\n" . '<tr><td>GAME NOT SUPPORTED!</td></tr></table>'; $bchout = '<table cellpadding=2 cellspacing=0 border=0 width=100% align=center>' . "\n" . '<tr><td>GAME NOT SUPPORTED</td></tr></table>'; } else { # Get configuration data from the database #################################################### $mybsmgs->load_game_specific_language('bossbase'); require_once dirname(__FILE__) . '/../include/bssql.class.php'; $mybcsql = new BSSQL(); $bb_conf = $mybcsql->get_config('bossbase'); $bc_conf = $mybcsql->get_config('bosscounter'); $sbzone = $mybcsql->get_bzone('bosscounter');
* Date: $Date$ * ----------------------------------------------------------------------- * @author $Author$ * @copyright 2006-2008 sz3 * @link http://eqdkp-plus.com * @package bosssuite * @version $Rev$ * * $Id$ */ if (!defined('EQDKP_INC')) { die('You cannot access this file directly.'); } // new mgs class require_once dirname(__FILE__) . '/../include/bsmgs.class.php'; $mybsmgs = new BSMGS(); if (!$mybsmgs->game_supported('bossbase')) { function bl_note2link($raidnote, $raidname = '') { return $raidnote; } } else { if (!$mybsmgs->game_supported('bossbase')) { message_die("GAME NOT SUPPORTED"); } // sql class require_once dirname(__FILE__) . '/../include/bssql.class.php'; $mybssql = new BSSQL(); //get config $bb_conf = $mybssql->get_config('bossbase'); $bb_delim = array('rnote' => '/' . $bb_conf['noteDelim'] . '/', 'rname' => '/' . $bb_conf['nameDelim'] . '/');
function do_hook($hook) { global $eqdkp_root_path; $valid_hooks = array('/admin/addevent.php?action=update', '/admin/addraid.php?action=add', '/admin/addraid.php?action=update', '/admin/addraid.php?action=delete', '/plugins/bosssuite/admin/settings.php', '/plugins/bosssuite/admin/cache.php', '/plugins/bosssuite/admin/entity_conf.php', '/plugins/ctrt/index.php', '/plugins/raidlogimport/admin/dkp.php'); if (in_array($hook, $valid_hooks)) { include $eqdkp_root_path . 'plugins/bosssuite/include/bsmgs.class.php'; $bsmgs = new BSMGS(); if ($bsmgs->game_supported('bossbase')) { include $eqdkp_root_path . 'plugins/bosssuite/include/bssql.class.php'; $bssql = new BSSQL(); $bssql->update_cache(); } } }