Example #1
0
            echo "parent.document.getElementById('logtime1').innerHTML = '" . cfu_time_convert($t_now) . "';";
            echo "parent.document.getElementById('loglog1').innerHTML = '你與" . $Op->Player['gamename'] . "交戰!{$Pl_Log_Tag}';";
        }
        if ($Pl_MS_JSUpdate) {
            echo $Pl_MS_JSUpdate;
        }
        echo "function numberFormat(num){";
        echo "\tvar numF = '';";
        echo "\tvar pNum = num;";
        echo "\tvar l = num.length;";
        echo "\tvar tx = Math.floor(l/3);";
        echo "\tvar rx = (l%3);";
        echo "\tif (rx == 1){numF = num.substr(0,1);pNum = num.substr(1);}";
        echo "\telse if (rx == 2){numF = num.substr(0,2);pNum = num.substr(2);}";
        echo "\telse {numF = num.substr(0,3);pNum = num.substr(3);}";
        echo "\twhile(pNum.length >= 3){";
        echo "\tnumF = numF+','+pNum.substr(0,3);";
        echo "\tpNum = pNum.substr(3);";
        echo "\t}";
        echo "\treturn numF;";
        echo "}";
        echo "</script>";
    }
    if ($Use_Behavior_Checker) {
        include_once 'includes/behavior_checker.class.php';
        $BhvrChecker = new BehaviorChecker($Pl, $GLOBALS['Btl_Intv'], $VictoryFlag, $GLOBALS['Offline_Time'], $GLOBALS['CFU_Time'], $GLOBALS['DBPrefix']);
        $BhvrChecker->checkInsomnia();
        $BhvrChecker->checkRationalBattle();
    }
    echo "</html>";
}
        $TimetS['minutes'] = floor(($TimeTSSec - $TimetS['hours'] * 3600) / 60);
        $TimetS['seconds'] = floor($TimeTSSec - $TimetS['hours'] * 3600 - $TimetS['minutes'] * 60);
        $Otp_TellTime = "還有{$TimetS['hours']}小時{$TimetS['minutes']}分鐘{$TimetS['seconds']}秒開始戰爭。";
    } else {
        $TimeTSSec = $Otp_A_ITar['t_end'] - $CFU_Time;
        $TimetS['hours'] = floor($TimeTSSec / 3600);
        $TimetS['minutes'] = floor(($TimeTSSec - $TimetS['hours'] * 3600) / 60);
        $TimetS['seconds'] = floor($TimeTSSec - $TimetS['hours'] * 3600 - $TimetS['minutes'] * 60);
        $Otp_TellTime = "還有{$TimetS['hours']}小時{$TimetS['minutes']}分鐘{$TimetS['seconds']}秒戰爭宣告終了。";
    }
}
//Behaviour Check
if ($Use_Behavior_Checker) {
    include_once 'includes/behavior_checker.class.php';
    $BChecker = new BehaviorChecker($Pl, $GLOBALS['Btl_Intv'], 0, $GLOBALS['Offline_Time'], $GLOBALS['CFU_Time'], $GLOBALS['DBPrefix']);
    $BChecker->checkInsomnia();
}
//
// View Phase
//Start Printing
echo '<script type="text/javascript">';
echo "window.moveTo(0,0);";
echo "this.window.name = '{$PriTarget}';";
echo "window.PriTarget = '{$PriTarget}';";
echo "window.SecTarget = '{$SecTarget}';";
echo "resizeTo(screen.availWidth,screen.availHeight);";
echo "window.SP_Stat_Req = {$SP_Stat_Req}";
echo "</script>";
echo '<link href="/images/gmscrn.style.css" rel="stylesheet" type="text/css" />';
echo '<script type="text/javascript" src="/js/gmscrn_base.js"></script>';
echo "<body leftmargin=\"0\" topmargin=\"0\" bgcolor=\"#000000\" text=#dcdcdc link=#dcdcdc style=\"margin:0px 0px 0px 0px;\" oncontextmenu=\"return true;\">";