aboutsummaryrefslogtreecommitdiff
path: root/util/master/list.js
diff options
context:
space:
mode:
authorproller <proller@github.com>2013-07-13 00:37:28 +0400
committerproller <proller@github.com>2013-07-13 01:41:49 +0400
commit0a2de78da418c7cdeb1cf9b898d049100804fb29 (patch)
treee7b423c1528775ab4bdf9aca5fb84e451526d16d /util/master/list.js
parent288948edf71b2f4f70f486df9c4b9a587ce68248 (diff)
downloadhax-minetest-server-0a2de78da418c7cdeb1cf9b898d049100804fb29.tar.gz
hax-minetest-server-0a2de78da418c7cdeb1cf9b898d049100804fb29.zip
Better masterserver html
Diffstat (limited to 'util/master/list.js')
-rw-r--r--util/master/list.js6
1 files changed, 5 insertions, 1 deletions
diff --git a/util/master/list.js b/util/master/list.js
index c414a92b4..9e033b609 100644
--- a/util/master/list.js
+++ b/util/master/list.js
@@ -49,8 +49,12 @@ function success(r) {
h += '<tr class="mts_row">';
h += '<td class="mts_address">' + e(s.address) + (s.port != 30000 ? (':' + e(s.port)) : '') + '</td>';
h += '<td class="mts_clients">' + e(s.clients) + (s.clients_max ? '/' + e(s.clients_max) : '') + (s.clients_top ? ', ' + s.clients_top : '') + '</td>';
- h += '<td class="mts_version">' + e(s.version) + ' ' + e(s.gameid);
+ var mods;
if (s.mods && jQuery.isArray(s.mods)) {
+ mods = 1;
+ }
+ h += '<td class="mts_version' + (mods ? ' mts_ismods' : '') + '">' + e(s.version) + ' ' + e(s.gameid);
+ if (mods) {
h += '<div class="mts_mods">Mods:<br/>';
for (m in s.mods) {
h += s.mods[m] + '<br/>';