diff options
| author | Darkelarious <darkelarious@333networks.com> | 2021-09-09 14:02:36 +0200 |
|---|---|---|
| committer | Darkelarious <darkelarious@333networks.com> | 2021-09-09 14:02:36 +0200 |
| commit | abf0ef36b57c72b17d414673ecaadd74cf408134 (patch) | |
| tree | 9f56739bf25d209a7a795b28fe39ace05647b7ed /lib/MasterWebInterface/Handler/Servers.pm | |
| parent | 91729ec8ac5a8098cef2aa1c006aba88f6ef7eb3 (diff) | |
| download | WebInterface-Perl-abf0ef36b57c72b17d414673ecaadd74cf408134.tar.gz WebInterface-Perl-abf0ef36b57c72b17d414673ecaadd74cf408134.zip | |
style fix, readable gametypes
Diffstat (limited to 'lib/MasterWebInterface/Handler/Servers.pm')
| -rwxr-xr-x | lib/MasterWebInterface/Handler/Servers.pm | 15 |
1 files changed, 6 insertions, 9 deletions
diff --git a/lib/MasterWebInterface/Handler/Servers.pm b/lib/MasterWebInterface/Handler/Servers.pm index 374cddf..c360683 100755 --- a/lib/MasterWebInterface/Handler/Servers.pm +++ b/lib/MasterWebInterface/Handler/Servers.pm @@ -152,10 +152,10 @@ sub serverlist td $gn; } - # game type (CTF, DM, Masterserver, CoopGame) - td class => "tc4", - title => $l->{gametype} // "", - $l->{gametype} // ""; + # game type (hover: raw, display: parsed) + td class => "tc4", + title => $l->{gametype}, + $self->better_gametype($l->{gametype}); # number of players / maximum players td class => "tc5"; @@ -165,11 +165,8 @@ sub serverlist end; # map title/name - my $mapname = $l->{mapname} // $l->{maptitle} // ""; - my $maptitle = ( $l->{maptitle} && lc $l->{maptitle} ne "untitled" ) - ? $l->{maptitle} - : $mapname; - td class => "tc6", title => $mapname, $maptitle; + my $maplabel = ($l->{maptitle} && lc $l->{maptitle} ne "untitled" ? $l->{maptitle} : $l->{mapname}); + td class => "tc6", title => $maplabel // "---", $maplabel // "---"; end; }, ); |
