forked from devsam/core
서버 정보 추가 제공
This commit is contained in:
@@ -64,7 +64,7 @@ if(file_exists(__dir__.'/.htaccess')){
|
||||
|
||||
//TODO: 천통시에도 예약 오픈 알림이 필요..?
|
||||
|
||||
$admin = $gameStor->getValues(['isunited', 'npcmode', 'year', 'month', 'scenario', 'scenario_text', 'maxgeneral', 'turnterm', 'opentime', 'turntime']);
|
||||
$admin = $gameStor->getValues(['isunited', 'npcmode', 'year', 'month', 'scenario', 'scenario_text', 'maxgeneral', 'turnterm', 'opentime', 'turntime', 'join_mode', 'fiction']);
|
||||
$admin['maxUserCnt'] = $admin['maxgeneral'];
|
||||
$admin['npcMode'] = $admin['npcmode'];
|
||||
$admin['turnTerm'] = $admin['turnterm'];
|
||||
@@ -85,6 +85,23 @@ $admin['userCnt'] = $genCnt;
|
||||
$admin['npcCnt'] = $npcCnt;
|
||||
$admin['nationCnt'] = $nationCnt;
|
||||
|
||||
$admin['npcMode'] = $admin['npcMode']?'가능':'불가';
|
||||
$admin['fictionMode'] = $admin['fiction']?'가상':'사실';
|
||||
|
||||
$otherTextInfo = [];
|
||||
|
||||
if($options['join_mode'] == 'onlyRandom'){
|
||||
$otherTextInfo[] = '랜덤 임관 전용';
|
||||
}
|
||||
|
||||
if(!$otherTextInfo){
|
||||
$otherTextInfo = '표준';
|
||||
}
|
||||
else{
|
||||
$otherTextInfo = join(', ', $otherTextInfo);
|
||||
}
|
||||
$admin['otherTextInfo'] = $otherTextInfo;
|
||||
$admin['defaultStatTotal'] = GameConst::$defaultStatTotal;
|
||||
$me = [];
|
||||
|
||||
$general = $db->queryFirstRow('SELECT name, picture, imgsvr from general where owner=%i', $userID);
|
||||
|
||||
+8
-5
@@ -12,7 +12,8 @@ var serverListTemplate = "\
|
||||
var serverTextInfo = "\
|
||||
<td>\
|
||||
서기 <%year%>년 <%month%>월 (<span style='color:orange;'><%scenario%></span>)<br>\
|
||||
유저 : <%userCnt%> / <%maxUserCnt%>명 <span style='color:cyan;'>NPC : <%npcCnt%>명</span> (<span style='color:limegreen;'><%turnTerm%>분 턴 서버</span>)\
|
||||
유저 : <%userCnt%> / <%maxUserCnt%>명 <span style='color:cyan;'>NPC : <%npcCnt%>명</span> (<span style='color:limegreen;'><%turnTerm%>분 턴 서버</span>)<br>\
|
||||
(상성 설정:<%fictionMode%>), (기타 설정:<%otherTextInfo%>)\
|
||||
</td>\
|
||||
";
|
||||
|
||||
@@ -20,7 +21,9 @@ var serverProvisionalInfo = "\
|
||||
<td>\
|
||||
- 오픈 일시 : <%opentime%> -<br>\
|
||||
서기 <%year%>년 <%month%>월 (<span style='color:orange;'><%scenario%></span>)<br>\
|
||||
유저 : <%userCnt%> / <%maxUserCnt%>명 <span style='color:cyan;'>NPC : <%npcCnt%>명</span> (<span style='color:limegreen;'><%turnTerm%>분 턴 서버</span>)\
|
||||
유저 : <%userCnt%> / <%maxUserCnt%>명 <span style='color:cyan;'>NPC : <%npcCnt%>명</span> (<span style='color:limegreen;'><%turnTerm%>분 턴 서버</span>)<br>\
|
||||
(상성 설정:<%fictionMode%>), (기타 설정:<%otherTextInfo%>)\
|
||||
</td>\
|
||||
";
|
||||
|
||||
var serverFullTemplate = "\
|
||||
@@ -56,7 +59,8 @@ var serverReservedTemplate = "\
|
||||
<%openDatetime==starttime?'':'- 가오픈 일시 : '+openDatetime+ '- <br>'%>\
|
||||
- 오픈 일시 : <%starttime%> - <br>\
|
||||
<span style='color:orange;'><%scenarioName%></span> <span style='color:limegreen;'><%turnterm%>분 턴 서버</span><br>\
|
||||
(상성 설정:<%fictionMode%>), (빙의 여부:<%npcMode%>), (최대 스탯:<%gameConf.defaultStatTotal%>), (기타 설정:<%otherTextInfo%>)</td>\
|
||||
(상성 설정:<%fictionMode%>), (빙의 여부:<%npcMode%>), (최대 스탯:<%gameConf.defaultStatTotal%>), (기타 설정:<%otherTextInfo%>)\
|
||||
</td>\
|
||||
";
|
||||
|
||||
$(function(){
|
||||
@@ -121,7 +125,6 @@ function Entrance_drawServerList(serverInfos){
|
||||
$serverHtml.find('.server_date').html('{0} ~'.format(game.starttime));
|
||||
}
|
||||
|
||||
console.log(game.opentime, now);
|
||||
if(game.opentime <= now){
|
||||
$serverHtml.append(
|
||||
TemplateEngine(serverTextInfo, game)
|
||||
@@ -146,7 +149,7 @@ function Entrance_drawServerList(serverInfos){
|
||||
TemplateEngine(serverFullTemplate, {})
|
||||
);
|
||||
}
|
||||
else if(game.npcMode == 1){
|
||||
else if(game.npcMode == '가눙'){
|
||||
$serverHtml.append(
|
||||
TemplateEngine(serverCreateAndSelectTemplate, {serverPath:serverPath})
|
||||
).addClass('server_create_and_select');
|
||||
|
||||
Reference in New Issue
Block a user