버그 패치
- 메인 페이지에서 턴 실행으로 세션락이 걸리지 않도록. - 토너먼트에서 매 라운드마다 텍스트가 초기화 되지 않던 문제 해결 - 전투 로그 표기에서 불필요한 빈칸 제거
This commit is contained in:
@@ -43,6 +43,19 @@ function getFormattedFileLogAll(string $path){
|
|||||||
}, getRawFileLogAll($path));
|
}, getRawFileLogAll($path));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
function eraseTnmtFightLogAll(){
|
||||||
|
foreach(range(0, 49) as $i){
|
||||||
|
eraseTnmtFightLog($i);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
function eraseTnmtFightLog(int $group){
|
||||||
|
$filepath = "logs/fight{$group}.txt";
|
||||||
|
if(file_exists($filepath)){
|
||||||
|
@unlink($filepath);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
function pushTnmtFightLog(int $group, $log) {
|
function pushTnmtFightLog(int $group, $log) {
|
||||||
pushRawFileLog("logs/fight{$group}.txt", $log);
|
pushRawFileLog("logs/fight{$group}.txt", $log);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -232,12 +232,7 @@ function startTournament($auto, $type) {
|
|||||||
$db = DB::db();
|
$db = DB::db();
|
||||||
$connect=$db->get();
|
$connect=$db->get();
|
||||||
|
|
||||||
for($i=0; $i<50; $i++){
|
eraseTnmtFightLogAll();
|
||||||
$filepath = "logs/fight{$i}.txt";
|
|
||||||
if(file_exists($filepath)){
|
|
||||||
@unlink($filepath);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
switch($auto) {
|
switch($auto) {
|
||||||
case 1: $unit = 60; break;
|
case 1: $unit = 60; break;
|
||||||
@@ -760,6 +755,8 @@ function fight($tnmt_type, $tnmt, $phs, $group, $g1, $g2, $type) {
|
|||||||
$db = DB::db();
|
$db = DB::db();
|
||||||
$connect=$db->get();
|
$connect=$db->get();
|
||||||
|
|
||||||
|
eraseTnmtFightLog($group);
|
||||||
|
|
||||||
$query = "select *,(ldr+pwr+itl)*7/15 as tot,h,w,b from tournament where grp='$group' and grp_no='$g1'";
|
$query = "select *,(ldr+pwr+itl)*7/15 as tot,h,w,b from tournament where grp='$group' and grp_no='$g1'";
|
||||||
$result = MYDB_query($query, $connect) or Error(__LINE__.MYDB_error($connect),"");
|
$result = MYDB_query($query, $connect) or Error(__LINE__.MYDB_error($connect),"");
|
||||||
$gen1 = MYDB_fetch_array($result);
|
$gen1 = MYDB_fetch_array($result);
|
||||||
|
|||||||
+1
-7
@@ -4,7 +4,7 @@ namespace sammo;
|
|||||||
include "lib.php";
|
include "lib.php";
|
||||||
include "func.php";
|
include "func.php";
|
||||||
|
|
||||||
$session = Session::requireLogin()->loginGame();
|
$session = Session::requireLogin()->loginGame()->setReadOnly();
|
||||||
$userID = Session::getUserID();
|
$userID = Session::getUserID();
|
||||||
|
|
||||||
increaseRefresh("메인", 1);
|
increaseRefresh("메인", 1);
|
||||||
@@ -31,12 +31,6 @@ if ($me === null) {
|
|||||||
header('Location: ../');
|
header('Location: ../');
|
||||||
die();
|
die();
|
||||||
}
|
}
|
||||||
if (!$session->generalID) {
|
|
||||||
$session = Session::requireGameLogin();
|
|
||||||
}
|
|
||||||
$session->setReadOnly();
|
|
||||||
$userID = Session::getUserID();
|
|
||||||
|
|
||||||
|
|
||||||
if ($me['newmsg'] == 1 || $me['newvote'] == 1) {
|
if ($me['newmsg'] == 1 || $me['newvote'] == 1) {
|
||||||
$db->update('general', [
|
$db->update('general', [
|
||||||
|
|||||||
@@ -1,9 +1,7 @@
|
|||||||
<div class="small_war_log">
|
<div class="small_war_log"
|
||||||
<span class="o_diamond">
|
><span class="o_diamond"></span
|
||||||
|
><span class="date"
|
||||||
</span>
|
><span class="year"><?=$year?></span>년
|
||||||
<span class="date">
|
|
||||||
<span class="year"><?=$year?></span>년
|
|
||||||
<span class="month"><?=$month?></span>월:
|
<span class="month"><?=$month?></span>월:
|
||||||
</span>
|
</span>
|
||||||
<span class="war_type war_type_<?=$war_type?>"><?=$war_type_str?></span>
|
<span class="war_type war_type_<?=$war_type?>"><?=$war_type_str?></span>
|
||||||
|
|||||||
Reference in New Issue
Block a user