<?php // // This Plugin must be used in collaboration with cfu.php and sfo.class.php // include '../../cfu.php'; include '../../includes/sfo.class.php'; include 'mining.class.php'; include 'mining.config.php'; AuthUser("{$Pl_Value['USERNAME']}", "{$Pl_Value['PASSWORD']}"); $Pl = new player_stats(); $Pl->SetUser($Pl_Value['USERNAME']); $Pl->FetchPlayer(); $Area = ReturnMap($Pl->Player['coordinates']); $AreaLandForm = ReturnMType($Area['Sys']['type']); $Area_Org = ReturnOrg($Area['User']['occupied']); $Pl_Org = $Area['User']['occupied'] != $Pl->Player['organization'] ? ReturnOrg($Pl->Player['organization']) : $Area_Org; global $Pl_LocalOrgFlag; $Pl_LocalOrgFlag = 0; if ($Area['User']['occupied'] == 0) { $Pl_LocalOrgFlag = 2; } elseif ($Area['User']['occupied'] == $Pl->Player['organization']) { $Pl_LocalOrgFlag = 1; } $mode = isset($_POST['action']) ? $_POST['action'] : ''; postHead('', '../../phpeb_session_dir', $additionalHeader); $Mining = new mining($DBPrefix, $CFU_Time, $Work_Length, $Base_Unit_Cost); $Mining->getDetails($Pl->User, $Pl->Player['coordinates'], $Pl->Player['level'], $Pl->Player['organization']); echo "<font style='font-size: 12pt;'>原料採集</font><hr>"; // // Make Payment Process
} else { $O_Inf[$a] = $O_Inf[$b]; } $b = $a; } $sql = "SELECT `coordinates`, COUNT( `coordinates` ) AS `count` FROM `" . $GLOBALS['DBPrefix'] . "phpeb_user_general_info` GROUP BY `coordinates`;"; $query = mysql_query($sql); while ($results = mysql_fetch_array($query)) { $PlayerCount[$results['coordinates']] = $results['count']; } $Tbl_i = array(array('C1W', 'C1N', 'C2W', 'C2N', 'C3W', 'C3N'), array('C1S', 'C1E', 'C2S', 'C2E', 'C3S', 'C3E'), array('B1W', 'B1N', 'B2W', 'B2N', 'B3W', 'B3N'), array('B1S', 'B1E', 'B2S', 'B2E', 'B3S', 'B3E'), array('A1W', 'A1N', 'A2W', 'A2N', 'A3W', 'A3N'), array('A1S', 'A1E', 'A2S', 'A2E', 'A3S', 'A3E')); echo "<table align=center border=0 cellpadding=0 cellspacing=0 class='AlphaChan' width=420 height=312 id='mapTable'>"; foreach ($Tbl_i as $i_r) { echo "<tr>"; foreach ($i_r as $i_c => $a_id) { $MType = ReturnMType($A_Inf[$a_id]['Sys']['type']); echo "<span id=MapDiscription_" . $a_id . " style=\"visibility: hidden; position: absolute;\">"; echo $A_Inf[$a_id]['User']['aname'] . " ({$MType})<br> 軍力: " . $A_Inf[$a_id]['User']['tickets']; echo "<br> 所屬國: " . $O_Inf[$a_id]['name']; echo "<br> 區域人數: " . $PlayerCount[$a_id]; echo "</span>"; $cursor = 'default'; $dis = 'return false;'; $border = ''; $label = "<span style='background: black; width: 30px'>{$a_id}</span>"; if (strpos($Pl->Area['Sys']['movement'], $A_Inf[$a_id]['Sys']['area']) !== false || $Pl->Area['Sys']['area'] == $A_Inf[$a_id]['Sys']['area'] && $Pl->Player['coordinates'] != $a_id) { $dis = "mainform.destination.value='{$a_id}';mainform.moveBtn.disabled=false;mainform.moveBtn.value='移動往{$a_id}';"; $cursor = 'pointer'; } elseif ($a_id == $Pl->Player['coordinates']) { $border = 'border: 2px solid white;'; } else {
$ReClr = colorConvert("{$PlGameVal['reacting']}"); $TaClr = colorConvert("{$PlGameVal['targeting']}"); $NextStatPt_At = $PlGameVal['attacking'] + 1; $NextStatPt_De = $PlGameVal['defending'] + 1; $NextStatPt_Re = $PlGameVal['reacting'] + 1; $NextStatPt_Ta = $PlGameVal['targeting'] + 1; CalcStatReq('At', "{$NextStatPt_At}"); $AtAdd = ''; CalcStatReq('De', "{$NextStatPt_De}"); $DeAdd = ''; CalcStatReq('Re', "{$NextStatPt_Re}"); $ReAdd = ''; CalcStatReq('Ta', "{$NextStatPt_Ta}"); $TaAdd = ''; $Area = ReturnMap("{$UsrGenrl['coordinates']}"); $AreaLandForm = ReturnMType($Area["Sys"]["type"]); $LandFormBg = ReturnMBg($Area["Sys"]["type"]); $AreaOrg = ReturnOrg($Area["User"]["occupied"]); $Pl_Org = ReturnOrg($PlGameVal['organization']); if ($UsrGenrl['fame'] >= 0) { $TypeFame = '名聲'; } else { $TypeFame = '惡名'; } $ShowFame = abs($UsrGenrl['fame']); unset($RightsTitle); if ($PlGameVal['rights'] == '1') { $RightsTitle = $RightsClass['Major']; } elseif ($PlGameVal['rights']) { $RightsTitle = $RightsClass['Leader']; }
$O_Inf[$a] = $O_Inf[$b]; } $b = $a; } $sql = "SELECT `coordinates`, COUNT( `coordinates` ) AS `count` FROM `" . $GLOBALS['DBPrefix'] . "phpeb_user_general_info` GROUP BY `coordinates`;"; $query = mysql_query($sql); while ($results = mysql_fetch_array($query)) { $PlayerCount[$results['coordinates']] = $results['count']; } // Draw Map echo "<table align=center border=0 cellpadding=0 cellspacing=0 class='AlphaChan' width=420 height=312 id=\"mapTable\">"; foreach ($Tbl_i as $i_r) { echo "<tr>"; foreach ($i_r as $i_c => $a_id) { echo "<span id=MapDiscription_" . $a_id . " style=\"visibility: hidden; position: absolute;\">"; echo "{$a_id} (" . ReturnMType($A_Inf[$a_id]['Sys']['type']) . ")<br>" . $A_Inf[$a_id]['User']['aname'] . "<br> 軍力: " . $A_Inf[$a_id]['User']['tickets']; echo "<br> 所屬國: " . $O_Inf[$a_id]['name']; echo "<br> 區域人數: " . $PlayerCount[$a_id]; echo "</span>"; echo '<td align=center width=70 height=52 style="cursor: pointer; '; if ($A_Inf[$a_id]['User']['occupied'] == $Info['id']) { echo "background: " . $Info['color'] . ';"'; } else { echo '"'; } echo ' onClick="getAreaInfo(\'' . $a_id . '\');"'; echo ' OnMouseOver="setLayer(event.clientX,event.clientY,150,80,\'document.getElementById(\\\'MapDiscription_' . $a_id . '\\\').innerHTML\');"'; echo ' OnMouseOut="offLayer();">'; if ($A_Inf[$a_id]['User']['occupied'] == $Info['id']) { echo "<span style='background: black; width: 30'>{$a_id}</span>"; } else {