From 48375acd7d6581b42b354618ed694a9d1cd25439 Mon Sep 17 00:00:00 2001 From: fusion32 Date: Sat, 18 Oct 2025 20:37:00 -0300 Subject: overall improvements + keep up with querymanager v0.2 --- templates/character_create.tmpl | 2 +- templates/character_profile.tmpl | 2 +- templates/world_info.tmpl | 17 ++++++++++++++--- templates/world_list.tmpl | 6 ++++++ 4 files changed, 22 insertions(+), 5 deletions(-) (limited to 'templates') diff --git a/templates/character_create.tmpl b/templates/character_create.tmpl index c243f2d..1a235dd 100644 --- a/templates/character_create.tmpl +++ b/templates/character_create.tmpl @@ -1,6 +1,6 @@ {{template "_header.tmpl" .Common}}
-

Create Account

+

Create Character

diff --git a/templates/character_profile.tmpl b/templates/character_profile.tmpl index 824e908..2711e03 100644 --- a/templates/character_profile.tmpl +++ b/templates/character_profile.tmpl @@ -35,7 +35,7 @@ Last Login: - {{.LastLogin}} + {{FormatTimestamp .LastLogin}} Account Status: diff --git a/templates/world_info.tmpl b/templates/world_info.tmpl index 578a0f7..353b674 100644 --- a/templates/world_info.tmpl +++ b/templates/world_info.tmpl @@ -16,13 +16,24 @@ {{.NumPlayers}} - Online Record: - {{if .OnlineRecord}} - {{.OnlineRecord}} players (on {{.OnlineRecordTime}}) + Online Peak: + {{if eq .OnlinePeak 1}} + {{.OnlinePeak}} player (on {{FormatTimestamp .OnlinePeakTimestamp}}) + {{else if gt .OnlinePeak 1}} + {{.OnlinePeak}} players (on {{FormatTimestamp .OnlinePeakTimestamp}}) {{else}} None {{end}} + + {{if gt .LastStartup .LastShutdown}} + Uptime: + {{FormatDurationSince .LastStartup}} + {{else}} + Downtime: + {{FormatDurationSince .LastShutdown}} + {{end}} + Kill Statistics {{else}} diff --git a/templates/world_list.tmpl b/templates/world_list.tmpl index de9786c..07494b6 100644 --- a/templates/world_list.tmpl +++ b/templates/world_list.tmpl @@ -7,12 +7,18 @@ Name Type Players Online + Status {{range .Worlds}} {{.Name}} {{.Type}} {{.NumPlayers}} + {{if gt .LastStartup .LastShutdown}} + Online + {{else}} + Offline + {{end}} {{end}} -- cgit v1.2.3