mirror of
https://github.com/plan-player-analytics/Plan.git
synced 2025-01-27 10:31:42 +01:00
New Html, Rewrote Config, Deprecated some Settings enums
This commit is contained in:
parent
1709ba394e
commit
ff3fb9eac1
@ -3,7 +3,7 @@
|
||||
<modelVersion>4.0.0</modelVersion>
|
||||
<groupId>com.djrapitops</groupId>
|
||||
<artifactId>Plan</artifactId>
|
||||
<version>3.6.3</version>
|
||||
<version>4.0.0</version>
|
||||
<build>
|
||||
<sourceDirectory>${basedir}/src</sourceDirectory>
|
||||
<testSourceDirectory>${basedir}/test</testSourceDirectory>
|
||||
|
22
Plan/pom.xml
22
Plan/pom.xml
@ -107,10 +107,28 @@
|
||||
<directory>${basedir}/src/main/resources</directory>
|
||||
<includes>
|
||||
<include>*.keystore</include>
|
||||
<include>*.js</include>
|
||||
<include>*.css</include>
|
||||
<include>*.yml</include>
|
||||
</includes>
|
||||
<excludes>
|
||||
<exclude>licence.yml</exclude>
|
||||
</excludes>
|
||||
</resource>
|
||||
<resource>
|
||||
<targetPath>.</targetPath>
|
||||
<directory>${basedir}/src/main/resources/html</directory>
|
||||
<includes>
|
||||
<include>*.html</include>
|
||||
<include>*.txt</include>
|
||||
</includes>
|
||||
<excludes>
|
||||
<exclude>*Example*</exclude>
|
||||
</excludes>
|
||||
</resource>
|
||||
<resource>
|
||||
<targetPath>.</targetPath>
|
||||
<directory>${basedir}/src/main/resources/js</directory>
|
||||
<includes>
|
||||
<include>*.js</include>
|
||||
</includes>
|
||||
</resource>
|
||||
</resources>
|
||||
|
@ -44,7 +44,6 @@ import main.java.com.djrapitops.plan.ui.webserver.api.bukkit.*;
|
||||
import main.java.com.djrapitops.plan.utilities.Benchmark;
|
||||
import main.java.com.djrapitops.plan.utilities.Check;
|
||||
import main.java.com.djrapitops.plan.utilities.MiscUtils;
|
||||
import main.java.com.djrapitops.plan.utilities.metrics.BStats;
|
||||
import main.java.com.djrapitops.plan.utilities.webserver.api.WebAPIManager;
|
||||
import org.apache.logging.log4j.LogManager;
|
||||
import org.bukkit.ChatColor;
|
||||
@ -277,25 +276,11 @@ public class Plan extends BukkitPlugin<Plan> {
|
||||
private void registerListeners() {
|
||||
Benchmark.start("Register Listeners");
|
||||
registerListener(new PlanPlayerListener(this));
|
||||
boolean chatListenerIsEnabled = Check.isTrue(Settings.GATHERCHAT.isTrue(), Locale.get(Msg.ENABLE_NOTIFY_DISABLED_CHATLISTENER).toString());
|
||||
boolean commandListenerIsEnabled = Check.isTrue(Settings.GATHERCOMMANDS.isTrue(), Locale.get(Msg.ENABLE_NOTIFY_DISABLED_COMMANDLISTENER).toString());
|
||||
boolean deathListenerIsEnabled = Check.isTrue(Settings.GATHERKILLS.isTrue(), Locale.get(Msg.ENABLE_NOTIFY_DISABLED_DEATHLISTENER).toString());
|
||||
|
||||
if (chatListenerIsEnabled) {
|
||||
registerListener(new PlanChatListener(this));
|
||||
}
|
||||
|
||||
registerListener(new PlanChatListener(this));
|
||||
registerListener(new PlanGamemodeChangeListener(this));
|
||||
registerListener(new PlanWorldChangeListener(this));
|
||||
|
||||
if (commandListenerIsEnabled) {
|
||||
registerListener(new PlanCommandPreprocessListener(this));
|
||||
}
|
||||
|
||||
if (deathListenerIsEnabled) {
|
||||
registerListener(new PlanDeathEventListener(this));
|
||||
}
|
||||
|
||||
registerListener(new PlanCommandPreprocessListener(this));
|
||||
registerListener(new PlanDeathEventListener(this));
|
||||
Benchmark.stop("Enable", "Register Listeners");
|
||||
}
|
||||
|
||||
|
@ -10,86 +10,108 @@ import java.util.List;
|
||||
* @since 2.3.2
|
||||
*/
|
||||
public enum Settings {
|
||||
// Boolean
|
||||
WEBSERVER_ENABLED("Settings.WebServer.Enabled"),
|
||||
ANALYSIS_REFRESH_ON_ENABLE("Settings.Cache.AnalysisCache.RefreshAnalysisCacheOnEnable"),
|
||||
ANALYSIS_LOG_TO_CONSOLE("Settings.Analysis.LogProgressOnConsole"),
|
||||
ANALYSIS_LOG_FINISHED("Settings.Analysis.NotifyWhenFinished"),
|
||||
ANALYSIS_EXPORT("Settings.Analysis.Export.Enabled"),
|
||||
SHOW_ALTERNATIVE_IP("Settings.WebServer.ShowAlternativeServerIP"),
|
||||
USE_ALTERNATIVE_UI("Settings.UseTextUI"),
|
||||
GATHERCHAT("Settings.Data.ChatListener"),
|
||||
GATHERKILLS("Settings.Data.GatherKillData"),
|
||||
GATHERCOMMANDS("Settings.Data.GatherCommandUsage"),
|
||||
DO_NOT_LOG_UNKNOWN_COMMANDS("Customization.Data.DoNotLogUnknownCommands"),
|
||||
COMBINE_COMMAND_ALIASES_TO_MAIN_COMMAND("Customization.Data.CombineCommandAliasesToMainCommand"),
|
||||
SECURITY_IP_UUID("Settings.WebServer.Security.DisplayIPsAndUUIDs"),
|
||||
PLAYERLIST_SHOW_IMAGES("Customization.SmallHeadImagesOnAnalysisPlayerlist"),
|
||||
WRITE_NEW_LOCALE("Settings.WriteNewLocaleFileOnStart"),
|
||||
// Boolean
|
||||
BUNGEE_COPY_CONFIG("Bungee-Override.CopyBungeeConfig"),
|
||||
BUNGEE_OVERRIDE_STANDALONE_MODE("Bungee-Override.StandaloneMode"),
|
||||
@Deprecated WEBSERVER_ENABLED("Settings.WebServer.Enabled"),
|
||||
@Deprecated ANALYSIS_REFRESH_ON_ENABLE("Settings.Cache.AnalysisCache.RefreshAnalysisCacheOnEnable"),
|
||||
@Deprecated ANALYSIS_LOG_TO_CONSOLE("Settings.Analysis.LogProgressOnConsole"),
|
||||
@Deprecated ANALYSIS_LOG_FINISHED("Settings.Analysis.NotifyWhenFinished"),
|
||||
ANALYSIS_EXPORT("Analysis.Export.Enabled"),
|
||||
SHOW_ALTERNATIVE_IP("Commands.AlternativeIP.Enabled"),
|
||||
@Deprecated USE_ALTERNATIVE_UI("Settings.UseTextUI"),
|
||||
LOG_UNKNOWN_COMMANDS("DAta.Commands.LogUnknownCommands"),
|
||||
COMBINE_COMMAND_ALIASES("Data.Commands.CombineCommandAliases"),
|
||||
@Deprecated SECURITY_IP_UUID("Settings.WebServer.Security.DisplayIPsAndUUIDs"),
|
||||
@Deprecated PLAYERLIST_SHOW_IMAGES("Customization.SmallHeadImagesOnAnalysisPlayerlist"),
|
||||
WRITE_NEW_LOCALE("Plugin.WriteNewLocaleFileOnStart"),
|
||||
|
||||
// Integer
|
||||
ANALYSIS_MINUTES_FOR_ACTIVE("Settings.Analysis.MinutesPlayedUntilConsidiredActive"),
|
||||
SAVE_CACHE_MIN("Settings.Cache.DataCache.SaveEveryXMinutes"),
|
||||
CLEAR_INSPECT_CACHE("Settings.Cache.InspectCache.ClearFromInspectCacheAfterXMinutes"),
|
||||
CLEAR_CACHE_X_SAVES("Settings.Cache.DataCache.ClearCacheEveryXSaves"),
|
||||
WEBSERVER_PORT("Settings.WebServer.Port"),
|
||||
ANALYSIS_AUTO_REFRESH("Settings.Cache.AnalysisCache.RefreshEveryXMinutes"),
|
||||
PROCESS_GET_LIMIT("Settings.Cache.Processing.GetLimit"),
|
||||
PROCESS_SAVE_LIMIT("Settings.Cache.Processing.SaveLimit"),
|
||||
PROCESS_CLEAR_LIMIT("Settings.Cache.Processing.ClearLimit"),
|
||||
TPS_GRAPH_HIGH("Customization.Colors.HTML.TPSGraph.TPSHigh"),
|
||||
TPS_GRAPH_MED("Customization.Colors.HTML.TPSGraph.TPSMedium"),
|
||||
@Deprecated ANALYSIS_MINUTES_FOR_ACTIVE("Settings.Analysis.MinutesPlayedUntilConsidiredActive"),
|
||||
@Deprecated SAVE_CACHE_MIN("Settings.Cache.DataCache.SaveEveryXMinutes"),
|
||||
@Deprecated CLEAR_INSPECT_CACHE("Settings.Cache.InspectCache.ClearFromInspectCacheAfterXMinutes"),
|
||||
@Deprecated CLEAR_CACHE_X_SAVES("Settings.Cache.DataCache.ClearCacheEveryXSaves"),
|
||||
WEBSERVER_PORT("WebServer.Port"),
|
||||
ANALYSIS_AUTO_REFRESH("Analysis.AutoRefreshPeriod"),
|
||||
@Deprecated PROCESS_GET_LIMIT("Settings.Cache.Processing.GetLimit"),
|
||||
@Deprecated PROCESS_SAVE_LIMIT("Settings.Cache.Processing.SaveLimit"),
|
||||
@Deprecated PROCESS_CLEAR_LIMIT("Settings.Cache.Processing.ClearLimit"),
|
||||
@Deprecated TPS_GRAPH_HIGH("Customization.Colors.HTML.TPSGraph.TPSHigh"),
|
||||
@Deprecated TPS_GRAPH_MED("Customization.Colors.HTML.TPSGraph.TPSMedium"),
|
||||
// String
|
||||
DEBUG("Settings.Debug"),
|
||||
ALTERNATIVE_IP("Settings.WebServer.AlternativeIP"),
|
||||
DB_TYPE("database.type"),
|
||||
DEM_TRIGGERS("Customization.DemographicsTriggers.Trigger"),
|
||||
DEM_FEMALE("Customization.DemographicsTriggers.Female"),
|
||||
DEM_MALE("Customization.DemographicsTriggers.Male"),
|
||||
DEM_IGNORE("Customization.DemographicsTriggers.IgnoreWhen"),
|
||||
LOCALE("Settings.Locale"),
|
||||
WEBSERVER_IP("Settings.WebServer.InternalIP"),
|
||||
ANALYSIS_EXPORT_PATH("Settings.Analysis.Export.DestinationFolder"),
|
||||
WEBSERVER_CERTIFICATE_PATH("Settings.WebServer.Security.Certificate.KeyStorePath"),
|
||||
WEBSERVER_CERTIFICATE_KEYPASS("Settings.WebServer.Security.Certificate.KeyPass"),
|
||||
WEBSERVER_CERTIFICATE_STOREPASS("Settings.WebServer.Security.Certificate.StorePass"),
|
||||
WEBSERVER_CERTIFICATE_ALIAS("Settings.WebServer.Security.Certificate.Alias"),
|
||||
LINK_PROTOCOL("Settings.WebServer.ExternalWebServerLinkProtocol"),
|
||||
DEBUG("Plugin.Debug"),
|
||||
ALTERNATIVE_IP("Commands.AlternativeIP.Link"),
|
||||
DB_TYPE("Database.Type"),
|
||||
LOCALE("Plugin.Locale"),
|
||||
WEBSERVER_IP("WebServer.InternalIP"),
|
||||
ANALYSIS_EXPORT_PATH("Analysis.Export.DestinationFolder"),
|
||||
WEBSERVER_CERTIFICATE_PATH("WebServer.Security.Certificate.KeyStorePath"),
|
||||
WEBSERVER_CERTIFICATE_KEYPASS("WebServer.Security.Certificate.KeyPass"),
|
||||
WEBSERVER_CERTIFICATE_STOREPASS("WebServer.Security.Certificate.StorePass"),
|
||||
WEBSERVER_CERTIFICATE_ALIAS("WebServer.Security.Certificate.Alias"),
|
||||
ETERNAL_WEBSERVER_LINK_PROTOCOL("Analysis.Export.ExternalWebServerLinkProtocol"),
|
||||
//
|
||||
SERVER_NAME("Customization.ServerName"),
|
||||
SERVER_NAME("Server.ServerName"),
|
||||
//
|
||||
FORMAT_YEAR("Customization.Formats.TimeAmount.Year"),
|
||||
FORMAT_YEARS("Customization.Formats.TimeAmount.Years"),
|
||||
FORMAT_DAY("Customization.Formats.TimeAmount.Day"),
|
||||
FORMAT_DAYS("Customization.Formats.TimeAmount.Days"),
|
||||
FORMAT_HOURS("Customization.Formats.TimeAmount.Hours"),
|
||||
FORMAT_MINUTES("Customization.Formats.TimeAmount.Minutes"),
|
||||
FORMAT_SECONDS("Customization.Formats.TimeAmount.Seconds"),
|
||||
FORMAT_DECIMALS("Customization.Formats.DecimalPoints"),
|
||||
FORMAT_YEAR("Customization.Formatting.TimeAmount.Year"),
|
||||
FORMAT_YEARS("Customization.Formatting.TimeAmount.Years"),
|
||||
FORMAT_MONTH("Customization.Formatting.TimeAmount.Month"),
|
||||
FORMAT_MONTHS("Customization.Formatting.TimeAmount.Months"),
|
||||
FORMAT_DAY("Customization.Formatting.TimeAmount.Day"),
|
||||
FORMAT_DAYS("Customization.Formatting.TimeAmount.Days"),
|
||||
FORMAT_HOURS("Customization.Formatting.TimeAmount.Hours"),
|
||||
FORMAT_MINUTES("Customization.Formatting.TimeAmount.Minutes"),
|
||||
FORMAT_SECONDS("Customization.Formatting.TimeAmount.Seconds"),
|
||||
FORMAT_DECIMALS("Customization.Formatting.DecimalPoints"),
|
||||
//
|
||||
COLOR_MAIN("Customization.Colors.Commands.Main"),
|
||||
COLOR_SEC("Customization.Colors.Commands.Secondary"),
|
||||
COLOR_TER("Customization.Colors.Commands.Highlight"),
|
||||
COLOR_MAIN("Commands.Colors.Main"),
|
||||
COLOR_SEC("Commands.Colors.Secondary"),
|
||||
COLOR_TER("Commands.Colors.Highlight"),
|
||||
//
|
||||
HCOLOR_MAIN("Customization.Colors.HTML.UI.Main"),
|
||||
HCOLOR_MAIN_DARK("Customization.Colors.HTML.UI.MainDark"),
|
||||
HCOLOR_SEC("Customization.Colors.HTML.UI.Secondary"),
|
||||
HCOLOR_TER("Customization.Colors.HTML.UI.Tertiary"),
|
||||
HCOLOR_TER_DARK("Customization.Colors.HTML.UI.TertiaryDark"),
|
||||
HCOLOR_TPS_HIGH("Customization.Colors.HTML.TPSGraph.TPSHighCol"),
|
||||
HCOLOR_TPS_MED("Customization.Colors.HTML.TPSGraph.TPSMediumCol"),
|
||||
HCOLOR_TPS_LOW("Customization.Colors.HTML.TPSGraph.TPSLowCol"),
|
||||
HCOLOR_ACT_ONL("Customization.Colors.HTML.ActivityGraph.OnlinePlayers"),
|
||||
HCOLOR_ACTP_ACT("Customization.Colors.HTML.ActivityPie.Active"),
|
||||
HCOLOR_ACTP_BAN("Customization.Colors.HTML.ActivityPie.Banned"),
|
||||
HCOLOR_ACTP_INA("Customization.Colors.HTML.ActivityPie.Inactive"),
|
||||
HCOLOR_ACTP_JON("Customization.Colors.HTML.ActivityPie.JoinedOnce"),
|
||||
HCOLOR_GMP_0("Customization.Colors.HTML.GamemodePie.Survival"),
|
||||
HCOLOR_GMP_1("Customization.Colors.HTML.GamemodePie.Creative"),
|
||||
HCOLOR_GMP_2("Customization.Colors.HTML.GamemodePie.Adventure"),
|
||||
HCOLOR_GMP_3("Customization.Colors.HTML.GamemodePie.Spectator"),
|
||||
THEME_BASE("Theme.Base"),
|
||||
THEME_FONT_STYLESHEET("Theme.Font.FontStyleSheet"),
|
||||
THEME_FONT_FAMILY("Theme.Font.FontFamily"),
|
||||
THEME_FONT_COLOR_DARK("Theme.Font.Dark"),
|
||||
THEME_FONT_COLOR_LIGHT("Theme.Font.Light"),
|
||||
THEME_COLOR_MAIN("Theme.Colors.Main"),
|
||||
THEME_COLOR_SECONDARY("Theme.Colors.Secondary"),
|
||||
THEME_COLOR_SECONDARY_DARK("Theme.Colors.Secondary-Dark"),
|
||||
THEME_COLOR_TERTIARY("Theme.Colors.Tertiary"),
|
||||
THEME_COLOR_BACKGROUND("Theme.Colors.Background"),
|
||||
THEME_COLOR_TABLE_DARK("Theme.Colors.Table-Dark"),
|
||||
THEME_COLOR_TABLE_LIGHT("Theme.Colors.Table-Light"),
|
||||
THEME_GRAPH_PUNCHCARD("Theme.Graphs.PunchCard"),
|
||||
THEME_GRAPH_PLAYERS_ONLINE("Theme.Graphs.PlayersOnline"),
|
||||
THEME_GRAPH_TPS_THRESHOLD_HIGH("Theme.Graphs.TPS.High-Threshold"),
|
||||
THEME_GRAPH_TPS_THRESHOLD_MED("Theme.Graphs.TPS.Medium-Threshold"),
|
||||
THEME_GRAPH_TPS_HIGH("Theme.Graphs.TPS.High"),
|
||||
THEME_GRAPH_TPS_MED("Theme.Graphs.TPS.Medium"),
|
||||
THEME_GRAPH_TPS_LOW("Theme.Graphs.TPS.Low"),
|
||||
THEME_GRAPH_CPU("Theme.Graphs.CPU"),
|
||||
THEME_GRAPH_RAM("Theme.Graphs.RAM"),
|
||||
THEME_GRAPH_CHUNKS("Theme.Graphs.Chunks"),
|
||||
THEME_GRAPH_ENTITIES("Theme.Graphs.Entities"),
|
||||
//
|
||||
@Deprecated HCOLOR_MAIN("Customization.Colors.HTML.UI.Main"),
|
||||
@Deprecated HCOLOR_MAIN_DARK("Customization.Colors.HTML.UI.MainDark"),
|
||||
@Deprecated HCOLOR_SEC("Customization.Colors.HTML.UI.Secondary"),
|
||||
@Deprecated HCOLOR_TER("Customization.Colors.HTML.UI.Tertiary"),
|
||||
@Deprecated HCOLOR_TER_DARK("Customization.Colors.HTML.UI.TertiaryDark"),
|
||||
@Deprecated HCOLOR_TPS_HIGH("Customization.Colors.HTML.TPSGraph.TPSHighCol"),
|
||||
@Deprecated HCOLOR_TPS_MED("Customization.Colors.HTML.TPSGraph.TPSMediumCol"),
|
||||
@Deprecated HCOLOR_TPS_LOW("Customization.Colors.HTML.TPSGraph.TPSLowCol"),
|
||||
@Deprecated HCOLOR_ACT_ONL("Customization.Colors.HTML.ActivityGraph.OnlinePlayers"),
|
||||
@Deprecated HCOLOR_ACTP_ACT("Customization.Colors.HTML.ActivityPie.Active"),
|
||||
@Deprecated HCOLOR_ACTP_BAN("Customization.Colors.HTML.ActivityPie.Banned"),
|
||||
@Deprecated HCOLOR_ACTP_INA("Customization.Colors.HTML.ActivityPie.Inactive"),
|
||||
@Deprecated HCOLOR_ACTP_JON("Customization.Colors.HTML.ActivityPie.JoinedOnce"),
|
||||
@Deprecated HCOLOR_GMP_0("Customization.Colors.HTML.GamemodePie.Survival"),
|
||||
@Deprecated HCOLOR_GMP_1("Customization.Colors.HTML.GamemodePie.Creative"),
|
||||
@Deprecated HCOLOR_GMP_2("Customization.Colors.HTML.GamemodePie.Adventure"),
|
||||
@Deprecated HCOLOR_GMP_3("Customization.Colors.HTML.GamemodePie.Spectator"),
|
||||
// StringList
|
||||
HIDE_FACTIONS("Customization.Plugins.Factions.HideFactions"),
|
||||
HIDE_TOWNS("Customization.Plugins.Towny.HideTowns");
|
||||
HIDE_FACTIONS("Plugins.Factions.HideFactions"),
|
||||
HIDE_TOWNS("Plugins.Towny.HideTowns");
|
||||
|
||||
private final String configPath;
|
||||
private Boolean value;
|
||||
|
@ -28,7 +28,7 @@ public class DataCacheClearQueue extends Queue<UUID> {
|
||||
* @param handler current instance of DataCacheHandler.
|
||||
*/
|
||||
public DataCacheClearQueue(DataCacheHandler handler) {
|
||||
super(new ArrayBlockingQueue<>(Settings.PROCESS_CLEAR_LIMIT.getNumber()));
|
||||
super(new ArrayBlockingQueue<>(20000));
|
||||
setup = new ClearSetup(queue, handler);
|
||||
setup.go();
|
||||
}
|
||||
|
@ -27,7 +27,7 @@ public class DataCacheGetQueue extends Queue<Map<UUID, List<DBCallableProcessor>
|
||||
* @param plugin current instance of Plan
|
||||
*/
|
||||
public DataCacheGetQueue(Plan plugin) {
|
||||
super(new ArrayBlockingQueue<>(Settings.PROCESS_GET_LIMIT.getNumber()));
|
||||
super(new ArrayBlockingQueue<>(20000));
|
||||
setup = new GetSetup(queue, plugin.getDB());
|
||||
setup.go();
|
||||
}
|
||||
|
@ -30,7 +30,7 @@ public class DataCacheSaveQueue extends Queue<UserData> {
|
||||
* @param handler DataCacheHandler
|
||||
*/
|
||||
public DataCacheSaveQueue(Plan plugin, DataCacheHandler handler) {
|
||||
super(new ArrayBlockingQueue<>(Settings.PROCESS_SAVE_LIMIT.getNumber()));
|
||||
super(new ArrayBlockingQueue<>(20000));
|
||||
setup = new SaveSetup(queue, handler, plugin.getDB());
|
||||
setup.go();
|
||||
}
|
||||
|
@ -45,8 +45,8 @@ public class PlanCommandPreprocessListener implements Listener {
|
||||
|
||||
String commandName = event.getMessage().substring(1).split(" ")[0].toLowerCase();
|
||||
|
||||
boolean doNotLogUnknownCommands = Settings.DO_NOT_LOG_UNKNOWN_COMMANDS.isTrue();
|
||||
boolean combineCommandAliasesToMainCommand = Settings.COMBINE_COMMAND_ALIASES_TO_MAIN_COMMAND.isTrue();
|
||||
boolean doNotLogUnknownCommands = Settings.LOG_UNKNOWN_COMMANDS.isTrue();
|
||||
boolean combineCommandAliasesToMainCommand = Settings.COMBINE_COMMAND_ALIASES.isTrue();
|
||||
|
||||
if (doNotLogUnknownCommands || combineCommandAliasesToMainCommand) {
|
||||
Command command = plugin.getServer().getPluginCommand(commandName);
|
||||
|
@ -79,7 +79,7 @@ public class HtmlUtils {
|
||||
|
||||
private static String getProtocol() {
|
||||
WebServer uiServer = Plan.getInstance().getUiServer();
|
||||
return uiServer.isEnabled() ? uiServer.getProtocol() : Settings.LINK_PROTOCOL.toString();
|
||||
return uiServer.isEnabled() ? uiServer.getProtocol() : Settings.ETERNAL_WEBSERVER_LINK_PROTOCOL.toString();
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -204,12 +204,8 @@ public class DumpUtils {
|
||||
boolean analysisExport = Settings.ANALYSIS_EXPORT.isTrue();
|
||||
boolean usingAlternativeServerIP = Settings.USE_ALTERNATIVE_UI.isTrue();
|
||||
|
||||
boolean chatGathering = Settings.GATHERCHAT.isTrue();
|
||||
boolean killGathering = Settings.GATHERKILLS.isTrue();
|
||||
boolean commandGathering = Settings.GATHERCOMMANDS.isTrue();
|
||||
|
||||
boolean combineAliases = Settings.COMBINE_COMMAND_ALIASES_TO_MAIN_COMMAND.isTrue();
|
||||
boolean unknownCommandLogging = Settings.DO_NOT_LOG_UNKNOWN_COMMANDS.isTrue();
|
||||
boolean combineAliases = Settings.COMBINE_COMMAND_ALIASES.isTrue();
|
||||
boolean unknownCommandLogging = Settings.LOG_UNKNOWN_COMMANDS.isTrue();
|
||||
|
||||
String locale = Settings.LOCALE.toString();
|
||||
String dbType = Settings.DB_TYPE.toString();
|
||||
@ -222,10 +218,6 @@ public class DumpUtils {
|
||||
log.add("Analysis Export", analysisExport);
|
||||
log.add("Alternative Server IP", usingAlternativeServerIP);
|
||||
|
||||
log.add("Chat Gathering", chatGathering);
|
||||
log.add("Kill Gathering", killGathering);
|
||||
log.add("Command Gathering", commandGathering);
|
||||
|
||||
log.add("Combine Aliases", combineAliases);
|
||||
log.add("Unknown Command Logging", unknownCommandLogging);
|
||||
log.add("Locale", locale);
|
||||
|
169
Plan/src/main/resources/Placeholders.txt
Normal file
169
Plan/src/main/resources/Placeholders.txt
Normal file
@ -0,0 +1,169 @@
|
||||
Placeholders:
|
||||
|
||||
${}
|
||||
|
||||
player.html:
|
||||
${playerName}
|
||||
${serverName}
|
||||
${version}
|
||||
|
||||
${playerClassification} (Active • Offline etc)
|
||||
${nicknames} • name<br>
|
||||
${geolocations} • country<br>
|
||||
|
||||
${registered} time format full
|
||||
${lastSeen} time format full
|
||||
${sessionCount} num
|
||||
${playtimeTotal} timeamount
|
||||
${sessionLengthMedian} timeamount
|
||||
${sessionLengthLongest} timeamount
|
||||
|
||||
${kickCount} num
|
||||
${playerKillCount} num
|
||||
${mobKillCount} num
|
||||
${deathCount} num
|
||||
|
||||
${sessionCountDay} num
|
||||
${sessionCountWeek} num
|
||||
${playtimeDay} timeamount
|
||||
${playtimeWeek} timeamount
|
||||
${sessionLengthLongestDay} timeamount
|
||||
${sessionLengthLongestWeek} timeamount
|
||||
|
||||
${contentSessions} See example page
|
||||
${contentServerOverview} See example page
|
||||
|
||||
${tabContentPlugins} See example page
|
||||
|
||||
${tableBodyActions} (3) (100)
|
||||
|
||||
punchcard
|
||||
serverPie
|
||||
worldPie
|
||||
|
||||
network.html:
|
||||
${networkName}
|
||||
${playersOnlineSeries}
|
||||
${version}
|
||||
|
||||
${playersOnline} num
|
||||
${playersMax} num
|
||||
${playersTotal} num
|
||||
${playersActive} num
|
||||
|
||||
${playersNewDay} num
|
||||
${playersNewWeek} num
|
||||
|
||||
${contentServers} row[column[box-header, box, box-footer[p,button right, refresh button right]], column...], row...
|
||||
|
||||
server.html:
|
||||
${serverName} String
|
||||
${timeZone} num
|
||||
|
||||
${playersOnline} num
|
||||
${playersMax} num
|
||||
${playersTotal} num
|
||||
${playersActive} num
|
||||
|
||||
${playersAverage} num
|
||||
${playersNewAverage} num
|
||||
|
||||
${playersDay} num
|
||||
${playersWeek} num
|
||||
${playersMonth} num
|
||||
${playersAverageDay} num
|
||||
${playersAverageWeek} num
|
||||
${playersAverageMonth} num
|
||||
${playersNewDay} num
|
||||
${playersNewWeek} num
|
||||
${playersNewMonth} num
|
||||
${playersNewAverageDay} num
|
||||
${playersNewAverageWeek} num
|
||||
${playersNewAverageMonth} num
|
||||
|
||||
${lastPeakTime} time format hh:mm
|
||||
${playersLastPeak} num
|
||||
${bestPeakTime} time format full
|
||||
${playersBestPeak} num
|
||||
|
||||
${sessionAverage} timeamount
|
||||
|
||||
${playtimeTotal} timeamount
|
||||
${sessionCount} num
|
||||
${killCount} num
|
||||
${mobKillCount} num
|
||||
${deathCount} num
|
||||
|
||||
${tpsAverageDay} num
|
||||
${tpsAverageWeek} num
|
||||
${cpuAverageDay} num%
|
||||
${cpuAverageWeek} num%
|
||||
${ramAverageDay} num MB
|
||||
${ramAverageWeek} num MB
|
||||
${entityAverageDay} num
|
||||
${entityAverageWeek} num
|
||||
${chunkAverageDay} num
|
||||
${chunkAverageWeek} num
|
||||
|
||||
${tableBodyRecentLogins} tr th html (2) (15-20)
|
||||
${tableBodySessions} tr th html (4) (50)
|
||||
${tableBodyPlayerList} tr th html (7) (250)
|
||||
${tableBodyCommands} tr th html (2) (100)
|
||||
|
||||
${playersOnlineSeries}
|
||||
${tpsSeries}
|
||||
${cpuSeries}
|
||||
${ramSeries}
|
||||
${entitySeries}
|
||||
${chunkSeries}
|
||||
${worldSeries}
|
||||
${geoMapSeries}
|
||||
${sessionLengthSeries}
|
||||
${punchCardSeries}
|
||||
|
||||
${playersGraphColor}
|
||||
|
||||
${gmData}
|
||||
${gmTotal} timeamount
|
||||
${gmColors}
|
||||
|
||||
${active}
|
||||
${inactive}
|
||||
${joinLeaver}
|
||||
${banned}
|
||||
${activityColors}
|
||||
|
||||
${worldTotal} timeamount
|
||||
${worldColors} NOT IMPLEMENTED //TODO
|
||||
|
||||
${tpsMedium}
|
||||
${tpsHigh}
|
||||
${tpsLowColor}
|
||||
${tpsMediumColor}
|
||||
${tpsHighColor}
|
||||
|
||||
${tabContentPlugins} row[column[box-header[h2[i, text]],box plugin], column...], row... + style="width: 200%;" <h2>That's all..</h2> <p>Do you have more plugins? ._.</p>
|
||||
|
||||
STYLE:
|
||||
|
||||
#267f00 - Theme
|
||||
#222 - Punchcard
|
||||
#89c471 - Theme (+sessionLength)
|
||||
#b58310 - Chunks
|
||||
#ac69ef - Entities
|
||||
#7dcc24 - RAM
|
||||
#e0d264 - CPU
|
||||
|
||||
https://fonts.googleapis.com/css?family=Quicksand:300,400 (Font Link)
|
||||
|
||||
main.css:
|
||||
#fff (white)
|
||||
#000 (black)
|
||||
|
||||
#e2e2e2 (Table, even)
|
||||
#eee (Table, odd)
|
||||
|
||||
#348e0f Theme (Header, on hover) Darker
|
||||
#5da341 Theme (Main color)
|
||||
|
||||
'Quicksand', sans-serif (Font Family)
|
File diff suppressed because it is too large
Load Diff
@ -1,108 +1,102 @@
|
||||
Settings:
|
||||
Server:
|
||||
ServerName: 'Plan'
|
||||
|
||||
Plugin:
|
||||
Debug: false
|
||||
Locale: default
|
||||
WriteNewLocaleFileOnStart: false
|
||||
UseTextUI: false
|
||||
Data:
|
||||
ChatListener: true
|
||||
GatherKillData: true
|
||||
GatherCommandUsage: true
|
||||
Analysis:
|
||||
LogProgressOnConsole: false
|
||||
NotifyWhenFinished: true
|
||||
MinutesPlayedUntilConsidiredActive: 10
|
||||
Export:
|
||||
Enabled: false
|
||||
DestinationFolder: 'Analysis Results'
|
||||
Cache:
|
||||
Processing:
|
||||
GetLimit: 5000
|
||||
SaveLimit: 2500
|
||||
ClearLimit: 2500
|
||||
AnalysisCache:
|
||||
RefreshAnalysisCacheOnEnable: true
|
||||
RefreshEveryXMinutes: -1
|
||||
InspectCache:
|
||||
ClearFromInspectCacheAfterXMinutes: 5
|
||||
DataCache:
|
||||
SaveEveryXMinutes: 2
|
||||
ClearCacheEveryXSaves: 5
|
||||
WebServer:
|
||||
Enabled: true
|
||||
Port: 8804
|
||||
InternalIP: 0.0.0.0
|
||||
ShowAlternativeServerIP: false
|
||||
AlternativeIP: your.ip.here:%port%
|
||||
WriteNewLocaleFileOnEnable: false
|
||||
Bungee-Override:
|
||||
StandaloneMode: false
|
||||
CopyBungeeConfig: true
|
||||
|
||||
WebServer:
|
||||
Port: 8804
|
||||
InternalIP: 0.0.0.0
|
||||
Security:
|
||||
SSL-Certificate:
|
||||
KeyStorePath: 'SSLCertificate.keystore'
|
||||
KeyPass: 'default'
|
||||
StorePass: 'default'
|
||||
Alias: 'alias'
|
||||
|
||||
Database:
|
||||
Type: SQLite
|
||||
MySQL:
|
||||
Host: localhost
|
||||
Port: 3306
|
||||
User: root
|
||||
Password: minecraft
|
||||
Database: Plan
|
||||
|
||||
Commands:
|
||||
AlternativeIP:
|
||||
Enabled: false
|
||||
Link: your.domain.here:%port%
|
||||
Colors:
|
||||
Main: '&2'
|
||||
Secondary: '&7'
|
||||
Highlight: '&f'
|
||||
|
||||
Analysis:
|
||||
AutoRefreshPeriod: 60
|
||||
Export:
|
||||
Enabled: false
|
||||
ExternalWebServerLinkProtocol: http
|
||||
Security:
|
||||
DisplayIPsAndUUIDs: true
|
||||
Certificate:
|
||||
KeyStorePath: 'SSLCertificate.keystore'
|
||||
KeyPass: 'default'
|
||||
StorePass: 'default'
|
||||
Alias: 'alias'
|
||||
DestinationFolder: 'Analysis Results'
|
||||
|
||||
Data:
|
||||
Commands:
|
||||
LogUnknownCommands: false
|
||||
CombineCommandAliases: true
|
||||
|
||||
Customization:
|
||||
ServerName: 'Plan'
|
||||
SmallHeadImagesOnAnalysisPlayerlist: true
|
||||
Data:
|
||||
DoNotLogUnknownCommands: false
|
||||
CombineCommandAliasesToMainCommand: false
|
||||
Formats:
|
||||
Formatting:
|
||||
DecimalPoints: '#.##'
|
||||
TimeAmount:
|
||||
Year: '1 year, '
|
||||
Years: '%years% years, '
|
||||
Month: '1 month, '
|
||||
Months: '%months% months, '
|
||||
Day: '1d '
|
||||
Days: '%days%d '
|
||||
Hours: '%hours%h '
|
||||
Minutes: '%minutes%m '
|
||||
Seconds: '%seconds%s'
|
||||
DecimalPoints: '#.##'
|
||||
Colors:
|
||||
Commands:
|
||||
Main: '&2'
|
||||
Secondary: '&7'
|
||||
Highlight: '&f'
|
||||
HTML:
|
||||
UI:
|
||||
Main: 348e0f
|
||||
MainDark: 267F00
|
||||
Secondary: 5cb239
|
||||
Tertiary: 89c471
|
||||
TertiaryDark: 5da341
|
||||
TPSGraph:
|
||||
TPSHigh: 18
|
||||
TPSMedium: 10
|
||||
TPSHighCol: 267F00
|
||||
TPSMediumCol: e5cc12
|
||||
TPSLowCol: b74343
|
||||
ActivityGraph:
|
||||
OnlinePlayers: '1E90FF'
|
||||
NewPlayers: '228B22'
|
||||
GamemodePie:
|
||||
Survival: '438c99'
|
||||
Creative: '639A67'
|
||||
Adventure: 'D8EBB5'
|
||||
Spectator: 'D9BF77'
|
||||
ActivityPie:
|
||||
Active: '228B22'
|
||||
Banned: '951800'
|
||||
Inactive: 'A9A9A9'
|
||||
JoinedOnce: '808080'
|
||||
Plugins:
|
||||
Factions:
|
||||
HideFactions:
|
||||
- ExampleFaction
|
||||
Towny:
|
||||
HideTowns:
|
||||
- ExampleTown
|
||||
|
||||
database:
|
||||
type: sqlite
|
||||
|
||||
mysql:
|
||||
host: localhost
|
||||
port: 3306
|
||||
user: root
|
||||
password: minecraft
|
||||
database: Plan
|
||||
Theme:
|
||||
Base: Default
|
||||
Font:
|
||||
FontStyleSheet: https://fonts.googleapis.com/css?family=Quicksand:300,400
|
||||
FontFamily: "'Quicksand', sans-serif"
|
||||
Color:
|
||||
Dark: Base
|
||||
Light: Base
|
||||
Colors:
|
||||
Main: Base
|
||||
Secondary: Base
|
||||
Secondary-Dark: Base
|
||||
Tertiary: Base
|
||||
Background: Base
|
||||
Table-Light: Base
|
||||
Table-Dark: Base
|
||||
Graphs:
|
||||
PunchCard: Base
|
||||
PlayersOnline: Base
|
||||
TPS:
|
||||
High-Threshold: 18
|
||||
Medium-Threshold: 10
|
||||
High: Base
|
||||
Medium: Base
|
||||
Low: Base
|
||||
CPU: Base
|
||||
RAM: Base
|
||||
Chunks: Base
|
||||
Entities: Base
|
||||
|
||||
Plugins:
|
||||
Factions:
|
||||
HideFactions:
|
||||
- ExampleFaction
|
||||
Towny:
|
||||
HideTowns:
|
||||
- ExampleTown
|
||||
|
130
Plan/src/main/resources/html/network – Example.html
Normal file
130
Plan/src/main/resources/html/network – Example.html
Normal file
@ -0,0 +1,130 @@
|
||||
<!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<title>Plan | Network</title>
|
||||
<meta name="description" content="Player Analysis window">
|
||||
<meta name="author" content="Rsl1122">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1">
|
||||
<link rel="icon" href="https://puu.sh/tK0KL/6aa2ba141b.ico" type="image/x-icon">
|
||||
<link rel="stylesheet" href="./main.css">
|
||||
<link href="https://fonts.googleapis.com/css?family=Quicksand:300,400" rel="stylesheet">
|
||||
<script src="https://use.fontawesome.com/df48eb908b.js"></script>
|
||||
</head>
|
||||
<body>
|
||||
<header>
|
||||
<div>
|
||||
<img class="right" src="https://puu.sh/tJZUb/c2e0ab220f.png" alt="Player Analytics | Analysis">
|
||||
<p class="right">Player Analytics v.4.0.0</p>
|
||||
<h1>Plan | Network</h1>
|
||||
</div>
|
||||
</header>
|
||||
<div class="content">
|
||||
<div class="row">
|
||||
<div class="column">
|
||||
<div class="box-header">
|
||||
<h2><i class="fa fa-bar-chart" aria-hidden="true"></i> Players Online</h2>
|
||||
</div>
|
||||
<div class="box-footer">
|
||||
<img style="width: 100%;" src="http://puu.sh/xdcdv/77aca85f4c.png">
|
||||
</div>
|
||||
</div>
|
||||
<div class="column">
|
||||
<div class="box-header">
|
||||
<h2><i class="fa fa-info-circle" aria-hidden="true"></i> Information</h2>
|
||||
</div>
|
||||
<div class="box" style="height: 75%;">
|
||||
<p>53/175 Players Online</p>
|
||||
<p>497 Active Players<br>1246 Total Players</p>
|
||||
<p>43 New Players Today<br>124 New Players This Week</p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="column">
|
||||
<div class="box-header">
|
||||
<h2><i class="fa fa-server" aria-hidden="true"></i> Server 1</h2>
|
||||
</div>
|
||||
<div class="box">
|
||||
<p>30/50 Players Online</p>
|
||||
<p>100 Active Players</p>
|
||||
</div>
|
||||
<div class="box-footer">
|
||||
<p>Last Refresh: 13:08</p>
|
||||
<a href="#" class="button right">Analysis</a>
|
||||
<a href="#" class="refresh button right" style="color: #000; background-color: #fff;"><i
|
||||
class="fa fa-refresh" aria-hidden="true"></i></a>
|
||||
</div>
|
||||
</div>
|
||||
<div class="column">
|
||||
<div class="box-header">
|
||||
<h2><i class="fa fa-server" aria-hidden="true"></i> Server 2</h2>
|
||||
</div>
|
||||
<div class="box">
|
||||
<p>0/25 Players Online</p>
|
||||
<p>3 Active Players</p>
|
||||
</div>
|
||||
<div class="box-footer">
|
||||
<p>Last Refresh: Never</p>
|
||||
<a class="button disabled right">Analysis</a>
|
||||
<a href="#" class="refresh button right" style="color: #000; background-color: #fff;"><i
|
||||
class="fa fa-refresh" aria-hidden="true"></i></a>
|
||||
</div>
|
||||
</div>
|
||||
<div class="column">
|
||||
<div class="box-header">
|
||||
<h2><i class="fa fa-server" aria-hidden="true"></i> Server 3</h2>
|
||||
</div>
|
||||
<div class="box">
|
||||
<p>23/100 Players Online</p>
|
||||
<p>432 Active Players</p>
|
||||
</div>
|
||||
<div class="box-footer">
|
||||
<p>Last Refresh: Analyzing..</p>
|
||||
<a class="button disabled right">Analysis</a>
|
||||
<a href="#" class="refresh button right" style="color: #000; background-color: #fff;"><i
|
||||
class="fa fa-refresh fa-spin" aria-hidden="true"></i></a>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="column">
|
||||
<div class="box-header">
|
||||
<h2><i class="fa fa-server" aria-hidden="true"></i> Server 4</h2>
|
||||
</div>
|
||||
<div class="box">
|
||||
<p>Offline</p>
|
||||
<p> </p>
|
||||
</div>
|
||||
<div class="box-footer">
|
||||
<p>Last Refresh: Never</p>
|
||||
<a class="button disabled right">Analysis</a>
|
||||
</div>
|
||||
</div>
|
||||
<div class="column">
|
||||
<div class="box-header">
|
||||
<h2><i class="fa fa-server" aria-hidden="true"></i> Hub</h2>
|
||||
</div>
|
||||
<div class="box" style="height: 75%;">
|
||||
<p>0/175 Players Online</p>
|
||||
<p> </p>
|
||||
</div>
|
||||
</div>
|
||||
<div class="column"></div>
|
||||
</div>
|
||||
</div>
|
||||
<script src="./js/playerGraph.js"></script>
|
||||
<script>
|
||||
var playersOnlineSeries = {
|
||||
name: 'Players Online',
|
||||
data: %playersonlineseries%,
|
||||
type: 'areaspline',
|
||||
color: '#%playersgraphcolor%',
|
||||
tooltip: {
|
||||
valueDecimals: 0
|
||||
}
|
||||
};
|
||||
/*playersChart('playerChart', playersOnlineSeries, 3);*/
|
||||
|
||||
</script>
|
||||
</body>
|
||||
</html>
|
59
Plan/src/main/resources/html/network.html
Normal file
59
Plan/src/main/resources/html/network.html
Normal file
@ -0,0 +1,59 @@
|
||||
<!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<title>Plan | Network</title>
|
||||
<meta name="description" content="Player Analysis window">
|
||||
<meta name="author" content="Rsl1122">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1">
|
||||
<link rel="icon" href="https://puu.sh/tK0KL/6aa2ba141b.ico" type="image/x-icon">
|
||||
<link rel="stylesheet" href="./main.css">
|
||||
<link href="https://fonts.googleapis.com/css?family=Quicksand:300,400" rel="stylesheet">
|
||||
<script src="https://use.fontawesome.com/df48eb908b.js"></script>
|
||||
</head>
|
||||
<body>
|
||||
<header>
|
||||
<div>
|
||||
<img class="right" src="https://puu.sh/tJZUb/c2e0ab220f.png" alt="Player Analytics | Analysis">
|
||||
<p class="right">Player Analytics v.${version}</p>
|
||||
<h1>${networkName} | Network</h1>
|
||||
</div>
|
||||
</header>
|
||||
<div class="content">
|
||||
<div class="row">
|
||||
<div class="column">
|
||||
<div class="box-header">
|
||||
<h2><i class="fa fa-bar-chart" aria-hidden="true"></i> Players Online</h2>
|
||||
</div>
|
||||
<div class="box-footer">
|
||||
<div id="playersOnline" style="width: 100%; height: 500px;"></div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="column">
|
||||
<div class="box-header">
|
||||
<h2><i class="fa fa-info-circle" aria-hidden="true"></i> Information</h2>
|
||||
</div>
|
||||
<div class="box" style="height: 75%;">
|
||||
<p>${playersOnline}/${playersMax} Players Online</p>
|
||||
<p>${playersActive} Active Players<br>${playersTotal} Total Players</p>
|
||||
<p>${playersNewDay} New Players Today<br>${playersNewWeek} New Players This Week</p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
${contentServers}
|
||||
</div>
|
||||
<script src="./js/playerGraph.js"></script>
|
||||
<script>
|
||||
var playersOnlineSeries = {
|
||||
name: 'Players Online',
|
||||
data: %playersonlineseries%,
|
||||
type: 'areaspline',
|
||||
color: '#%playersgraphcolor%',
|
||||
tooltip: {
|
||||
valueDecimals: 0
|
||||
}
|
||||
};
|
||||
/*playersChart('playerChart', playersOnlineSeries, 3);*/
|
||||
|
||||
</script>
|
||||
</body>
|
||||
</html>
|
446
Plan/src/main/resources/html/player - Example.html
Normal file
446
Plan/src/main/resources/html/player - Example.html
Normal file
@ -0,0 +1,446 @@
|
||||
<!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<title>Plan | Rsl1122</title>
|
||||
<meta name="description" content="Player Analysis window">
|
||||
<meta name="author" content="Rsl1122">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1">
|
||||
<link rel="icon" href="https://puu.sh/tK0KL/6aa2ba141b.ico" type="image/x-icon">
|
||||
<link rel="stylesheet" href="./main.css">
|
||||
<link href="https://fonts.googleapis.com/css?family=Quicksand:300,400" rel="stylesheet">
|
||||
<script src="https://use.fontawesome.com/df48eb908b.js"></script>
|
||||
<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.2.1/jquery.min.js"></script>
|
||||
</head>
|
||||
<body>
|
||||
<header>
|
||||
<div>
|
||||
<img class="right" src="https://puu.sh/tJZUb/c2e0ab220f.png" alt="Player Analytics | Analysis">
|
||||
<p class="right">Player Analytics v.4.0.0</p>
|
||||
<h1>Plan | Rsl1122</h1>
|
||||
</div>
|
||||
</header>
|
||||
<div class="content-server">
|
||||
<div class="nav-bar row">
|
||||
<a href="javascript:void(0)" class="nav-button">
|
||||
<i class="fa fa-info-circle" aria-hidden="true"></i> Information
|
||||
</a>
|
||||
<a href="javascript:void(0)" class="nav-button">
|
||||
<i class="fa fa-calendar" aria-hidden="true"></i> Sessions
|
||||
</a>
|
||||
<a href="javascript:void(0)" class="nav-button">
|
||||
<i class="fa fa-line-chart" aria-hidden="true"></i> Overview
|
||||
</a>
|
||||
<a href="javascript:void(0)" class="nav-button">
|
||||
<i class="fa fa-cubes" aria-hidden="true"></i> Plugins
|
||||
</a>
|
||||
</div>
|
||||
<div id="limiter" class="main-limiter">
|
||||
<div id="main" class="main-wrapper">
|
||||
<div id="tab-information" class="tab">
|
||||
<div class="row">
|
||||
<div class="column">
|
||||
<div class="box-header">
|
||||
<h2><i class="fa fa-info-circle" aria-hidden="true"></i> Information</h2>
|
||||
</div>
|
||||
<div class="box" style="margin-bottom: 5px;">
|
||||
<div class="row">
|
||||
<div class="column">
|
||||
<p>Active • <span class="darkred">Offline</span> • Operator<br>
|
||||
<br>
|
||||
Also Known As:<br>
|
||||
• <span class="darkred">Rsl</span><br>
|
||||
• Rsl1122<br>
|
||||
<br>
|
||||
Has Logged in From:<br>
|
||||
• Finland</p>
|
||||
</div>
|
||||
<div class="column">
|
||||
<p>Registered: May 01 2016, 13:39<br>
|
||||
Last Seen: Aug 18 2017, 20:00<br>
|
||||
<br>
|
||||
Sessions: 76<br>
|
||||
Total Playtime: 4d 4h 40m<br>
|
||||
Session Median: 7m<br>
|
||||
<br>
|
||||
Longest Session: 2h 37m
|
||||
</p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="box-header">
|
||||
<h2><i class="fa fa-drivers-license" aria-hidden="true"></i> Rsl1122</h2>
|
||||
</div>
|
||||
<div class="box-footer scrollbar" style="padding: 2px;">
|
||||
<div class="row">
|
||||
<div class="column" style="padding: 5px 0px 5px 10px;"><p>Times Kicked: 0<br></p></div>
|
||||
<div class="column"><img style="padding: 10px 100px; height: 100px; width: 100px;"
|
||||
src="https://cravatar.eu/avatar/Rsl1122/100"></div>
|
||||
<div class="column"><p>Player Kills: 49<br>
|
||||
Mob Kills: 548<br>
|
||||
Deaths: 12
|
||||
</p>
|
||||
</div>
|
||||
</div>
|
||||
<table class="sortable table">
|
||||
<thead>
|
||||
<tr>
|
||||
<th>Time</th>
|
||||
<th>Action</th>
|
||||
<th>Info</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<tr>
|
||||
<th>Aug 16 2017, 17:20</th>
|
||||
<th>Killed</th>
|
||||
<th>HannesDaDon with Iron Sword</th>
|
||||
</tr>
|
||||
<tr>
|
||||
<th>Aug 16 2017, 17:19</th>
|
||||
<th>Killed</th>
|
||||
<th>Einsamer_Keksi with Iron Sword</th>
|
||||
</tr>
|
||||
<tr>
|
||||
<th>Aug 16 2017, 15:19</th>
|
||||
<th>Changed name</th>
|
||||
<th>Rsl1122 <i class="fa fa-long-arrow-right" aria-hidden="true"></i> <span
|
||||
class="darkred">Rsl</span></th>
|
||||
</tr>
|
||||
<tr>
|
||||
<th>May 01 2016, 14:24</th>
|
||||
<th>First Logout</th>
|
||||
<th>Messages sent: 74</th>
|
||||
</tr>
|
||||
<tr>
|
||||
<th>May 01 2016, 13:39</th>
|
||||
<th>Registered</th>
|
||||
<th>Online: 34 Players</th>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
<div class="column">
|
||||
<div class="box-header">
|
||||
<h2><i class="fa fa-braille" aria-hidden="true"></i> Join PunchCard</h2>
|
||||
</div>
|
||||
<div class="box-footer">
|
||||
<img id="playersOnlineDay" src="http://puu.sh/xdhil/73c2c5b944.png"
|
||||
style="width: 100%; /height: 700px;"><!--</div>-->
|
||||
</div>
|
||||
<div class="box-header">
|
||||
<h2><i class="fa fa-pie-chart" aria-hidden="true"></i> Server Preference</h2>
|
||||
</div>
|
||||
<div class="box-footer">
|
||||
<img id="playersOnlineDay" src="http://puu.sh/xdgXa/f4a3b7df80.png"
|
||||
style="width: 100%; /height: 700px;"><!--</div>-->
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div id="tab-sessions" class="tab">
|
||||
<div class="row" style="flex-grow: 2; width: 140%;">
|
||||
<div class="column">
|
||||
<div class="box-header">
|
||||
<h2><i class="fa fa-calendar" aria-hidden="true"></i> 50 Most Recent Sessions</h2>
|
||||
</div>
|
||||
<div class="session column">
|
||||
<div class="session-header">
|
||||
<div class="session-col" style="width: 200%;"><h3>Aug 14 2017, 12:12 • 1h</h3>
|
||||
<p>Click to Expand</p></div>
|
||||
</div>
|
||||
<div class="session-content">
|
||||
<div class="row">
|
||||
<div class="session-col" style="padding: 0px;">
|
||||
<div class="box-header" style="margin: 0px;">
|
||||
<h2><i class="fa fa-calendar" aria-hidden="true"></i> Aug 13 2017, 13:23
|
||||
</h2>
|
||||
</div>
|
||||
<div class="box" style="margin: 0px;">
|
||||
<p>Session Length: 3h 5m<br>
|
||||
Session Ended: Aug 14 2017, 13:12<br>
|
||||
Server: Server 2<br>
|
||||
<br>
|
||||
Mob Kills: 0<br>
|
||||
Deaths: 1</p>
|
||||
<table class="sortable table">
|
||||
<thead>
|
||||
<tr>
|
||||
<th><i class="fa fa-clock-o" aria-hidden="true"> Time</th>
|
||||
<th>Killed</th>
|
||||
<th>With</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<tr>
|
||||
<th>12:42</th>
|
||||
<th>Zubat</th>
|
||||
<th>Lightning</th>
|
||||
</tr>
|
||||
<tr>
|
||||
<th>12:53</th>
|
||||
<th>Zezima</th>
|
||||
<th>Iron Sword</th>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
<div class="session-col">
|
||||
<img id="worldPie" style="width: 100%;"
|
||||
src="http://puu.sh/xdhF0/3c7ae10d4e.png">
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="session column">
|
||||
<div class="session-header">
|
||||
<div class="session-col" style="width: 200%;"><h3>Aug 13 2017, 15:23 • 3h 5m</h3>
|
||||
<p>Click to Expand</p></div>
|
||||
</div>
|
||||
<div class="session-content">
|
||||
<div class="row">
|
||||
<div class="session-col" style="padding: 0px;">
|
||||
<div class="box-header" style="margin: 0px;">
|
||||
<h2><i class="fa fa-calendar" aria-hidden="true"></i> Aug 13 2017, 13:23
|
||||
</h2>
|
||||
</div>
|
||||
<div class="box" style="margin: 0px;">
|
||||
<p>Session Length: 3h 5m<br>
|
||||
Session Ended: Aug 13 2017, 16:28<br>
|
||||
Server: Server 1<br>
|
||||
<br>
|
||||
Mob Kills: 45<br>
|
||||
Deaths: 6</p>
|
||||
<table class="sortable table">
|
||||
<thead>
|
||||
<tr>
|
||||
<th><i class="fa fa-clock-o" aria-hidden="true"> Time</th>
|
||||
<th>Killed</th>
|
||||
<th>With</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<tr>
|
||||
<th>13:42</th>
|
||||
<th>Zubat</th>
|
||||
<th>Lightning</th>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
<div class="session-col">
|
||||
<img id="worldPie" style="width: 100%;"
|
||||
src="http://puu.sh/xdhF0/3c7ae10d4e.png">
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div id="tab-performance" class="tab">
|
||||
<div class="row">
|
||||
<div class="column"> <!--First row (horizontal)-->
|
||||
<div class="column">
|
||||
<div class="box-header">
|
||||
<h2><i class="fa fa-pie-chart" aria-hidden="true"></i> World Playtime</h2>
|
||||
</div>
|
||||
<div class="box-footer">
|
||||
<img id="worldPie" style="width: 100%;" src="http://puu.sh/xdhF0/3c7ae10d4e.png">
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="column">
|
||||
<div class="box-header">
|
||||
<h2>Last 24 Hours</h2>
|
||||
</div>
|
||||
<div class="box" style="margin-bottom: 5px;">
|
||||
<p>Sessions: 4<br>
|
||||
Playtime: 4h 20m<br>
|
||||
<br>
|
||||
Longest Session: 1h 43m
|
||||
</p>
|
||||
</div>
|
||||
</div>
|
||||
<div class="column">
|
||||
<div class="box-header">
|
||||
<h2>Last 7 Days</h2>
|
||||
</div>
|
||||
<div class="box" style="margin-bottom: 5px;">
|
||||
<p>Sessions: 63<br>
|
||||
Playtime: 1d 3h 32m<br>
|
||||
<br>
|
||||
Longest Session: 1h 43m
|
||||
</p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</div> <!--First row (horizontal)-->
|
||||
<div class="row">
|
||||
<div class="column">
|
||||
<div class="box-header">
|
||||
<h2><i class="fa fa-server" aria-hidden="true"></i> Server 1</h2>
|
||||
</div>
|
||||
<div class="box" style="margin-bottom: 5px;">
|
||||
<p>Sessions: 24<br>
|
||||
Playtime: 3d 2h 2m<br>
|
||||
<br>
|
||||
Longest Session: 2h 43m
|
||||
</p>
|
||||
</div>
|
||||
<div class="box-header">
|
||||
<h2><i class="fa fa-server" aria-hidden="true"></i> Server 2</h2>
|
||||
</div>
|
||||
<div class="box" style="margin-bottom: 5px;">
|
||||
<p>Sessions: 52<br>
|
||||
Playtime: 6d 10h 2m<br>
|
||||
<br>
|
||||
Longest Session: 3h 7m
|
||||
</p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="tab-plugins" class="tab column">
|
||||
<div class="plugins-server">
|
||||
<div class="plugins-header">
|
||||
<div class="row">
|
||||
<div class="column">
|
||||
<div class="box-header">
|
||||
<h2><i class="fa fa-server" aria-hidden="true"></i> Server 2</h2>
|
||||
<p>Click to Expand</p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="plugins-content">
|
||||
<div class="row">
|
||||
<div class="column">
|
||||
<div class="box-header">
|
||||
<h2><i class="fa fa-cube" aria-hidden="true"></i> Plugin 1</h2>
|
||||
</div>
|
||||
<div class="box plugin">
|
||||
<p>Test: 5 / 25<br>
|
||||
Test: 20%</p>
|
||||
<p>More data: Yes<br>
|
||||
Data: 4</p>
|
||||
</div>
|
||||
</div>
|
||||
<div class="column">
|
||||
<div class="box-header">
|
||||
<h2><i class="fa fa-cube" aria-hidden="true"></i> Plugin 2</h2>
|
||||
</div>
|
||||
<div class="box plugin">
|
||||
<p>Yes<br>
|
||||
Yes<br>
|
||||
Yes<br>Yes<br>Yes<br>Yes<br>Yes<br>
|
||||
Yes<br>Yes<br>Yes<br>Yes<br>Yes<br>
|
||||
Yes<br>Yes<br>Yes<br>Yes<br>Yes<br>
|
||||
</p>
|
||||
</div>
|
||||
</div>
|
||||
<div class="column">
|
||||
<div class="box-header">
|
||||
<h2><i class="fa fa-cube" aria-hidden="true"></i> Plugin 3</h2>
|
||||
</div>
|
||||
<div class="box plugin">
|
||||
<img id="worldPie" style="width: 100%;" src="http://puu.sh/xdhF0/3c7ae10d4e.png">
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="column">
|
||||
<div class="box-header" style="margin-top: 10px;">
|
||||
<h2><i class="fa fa-cube" aria-hidden="true"></i> Plugin 4</h2>
|
||||
</div>
|
||||
<div class="box plugin" style="height: 100%;">
|
||||
<table class="sortable table">
|
||||
<thead>
|
||||
<tr>
|
||||
<th>Test</th>
|
||||
<th>Test2</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<tr>
|
||||
<th>Data</th>
|
||||
<th>Data</th>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
<div class="column"></div>
|
||||
<div class="column"></div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<script src="https://www.kryogenix.org/code/browser/sorttable/sorttable.js"></script>
|
||||
<script src="https://code.highcharts.com/stock/highstock.js"></script>
|
||||
<script src="https://code.highcharts.com/maps/modules/map.js"></script>
|
||||
<script src="https://code.highcharts.com/mapdata/custom/world.js"></script>
|
||||
<script src="./js/activityPie.js"></script>
|
||||
<script src="./js/gmPie.js"></script>
|
||||
<script src="./js/playerGraph.js"></script>
|
||||
<script src="./js/punchCard.js"></script>
|
||||
<script src="./js/resourceGraph.js"></script>
|
||||
<script src="./js/sessionDistributionChart.js"></script>
|
||||
<script src="./js/tpsGraph.js"></script>
|
||||
<script src="./js/worldGraph.js"></script>
|
||||
<script src="./js/worldMap.js"></script>
|
||||
<script src="./js/worldPie.js"></script>
|
||||
<script src="./js/pluginsTabExpand.js"></script>
|
||||
<script src="./js/sessionTabExpand.js"></script>
|
||||
<script>
|
||||
var navButtons = document.getElementsByClassName("nav-button");
|
||||
var tabs = document.getElementsByClassName("tab");
|
||||
var slideIndex = window.sessionStorage.getItem("InspectSlideIndex");
|
||||
if (slideIndex === null) {
|
||||
slideIndex = 0;
|
||||
}
|
||||
var x = document.getElementById("main");
|
||||
x.style.transform = "translate3d(0px,0px,0)";
|
||||
x.style.width = "" + navButtons.length * 100 + "%";
|
||||
for (var i = 0; i < navButtons.length; i++) {
|
||||
navButtons[i].onclick = openFunc(i)
|
||||
tabs[i].style.width = "" + 100 / navButtons.length + "%";
|
||||
}
|
||||
x.style.opacity = "1";
|
||||
openFunc(slideIndex)();
|
||||
|
||||
function openFunc(i) {
|
||||
return function() {
|
||||
var max = navButtons.length;
|
||||
for (var j = 0; j < max; j++) {
|
||||
if (j === i) {
|
||||
navButtons[j].classList.add('active');
|
||||
continue;
|
||||
}
|
||||
if (navButtons[j].classList.contains('active')) {
|
||||
navButtons[j].classList.remove('active');
|
||||
}
|
||||
}
|
||||
var perc = - 100 / navButtons.length;
|
||||
slideIndex = i;
|
||||
if (slideIndex > max) {slideIndex = 0};
|
||||
if (slideIndex < 0) {slideIndex = max};
|
||||
window.sessionStorage.setItem("InspectSlideIndex", slideIndex);
|
||||
var value = slideIndex * perc;
|
||||
x.style.transition = "0.5s";
|
||||
x.style.transform = "translate3d(" + value + "%,0px,0)";
|
||||
};
|
||||
}
|
||||
|
||||
</script>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
227
Plan/src/main/resources/html/player.html
Normal file
227
Plan/src/main/resources/html/player.html
Normal file
@ -0,0 +1,227 @@
|
||||
<!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<title>Plan | ${playerName}</title>
|
||||
<meta name="description" content="Player Analysis window">
|
||||
<meta name="author" content="Rsl1122">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1">
|
||||
<link rel="icon" href="https://puu.sh/tK0KL/6aa2ba141b.ico" type="image/x-icon">
|
||||
<link rel="stylesheet" href="./main.css">
|
||||
<link href="https://fonts.googleapis.com/css?family=Quicksand:300,400" rel="stylesheet">
|
||||
<script src="https://use.fontawesome.com/df48eb908b.js"></script>
|
||||
<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.2.1/jquery.min.js"></script>
|
||||
</head>
|
||||
<body>
|
||||
<header>
|
||||
<div>
|
||||
<img class="right" src="https://puu.sh/tJZUb/c2e0ab220f.png" alt="Player Analytics | Analysis">
|
||||
<p class="right">Player Analytics v.${version}</p>
|
||||
<h1>${serverName} | ${playerName}</h1>
|
||||
</div>
|
||||
</header>
|
||||
<div class="content-server">
|
||||
<div class="nav-bar row">
|
||||
<a href="javascript:void(0)" class="nav-button">
|
||||
<i class="fa fa-info-circle" aria-hidden="true"></i> Information
|
||||
</a>
|
||||
<a href="javascript:void(0)" class="nav-button">
|
||||
<i class="fa fa-calendar" aria-hidden="true"></i> Sessions
|
||||
</a>
|
||||
<a href="javascript:void(0)" class="nav-button">
|
||||
<i class="fa fa-line-chart" aria-hidden="true"></i> Overview
|
||||
</a>
|
||||
<a href="javascript:void(0)" class="nav-button">
|
||||
<i class="fa fa-cubes" aria-hidden="true"></i> Plugins
|
||||
</a>
|
||||
</div>
|
||||
<div id="limiter" class="main-limiter">
|
||||
<div id="main" class="main-wrapper">
|
||||
<div id="tab-information" class="tab">
|
||||
<div class="row">
|
||||
<div class="column">
|
||||
<div class="box-header">
|
||||
<h2><i class="fa fa-info-circle" aria-hidden="true"></i> Information</h2>
|
||||
</div>
|
||||
<div class="box" style="margin-bottom: 5px;">
|
||||
<div class="row">
|
||||
<div class="column">
|
||||
<p>${playerClassification}<br>
|
||||
<br>
|
||||
Also Known As:<br>
|
||||
${nicknames}
|
||||
<br>
|
||||
Has Logged in From:<br>
|
||||
${geolocations}</p>
|
||||
</div>
|
||||
<div class="column">
|
||||
<p>Registered: ${registered}<br>
|
||||
Last Seen: ${lastSeen}<br>
|
||||
<br>
|
||||
Sessions: ${sessionCount}<br>
|
||||
Total Playtime: ${playtimeTotal}<br>
|
||||
Session Median: ${sessionLengthMedian}<br>
|
||||
<br>
|
||||
Longest Session: ${sessionLengthLongest}
|
||||
</p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="box-header">
|
||||
<h2><i class="fa fa-drivers-license" aria-hidden="true"></i> ${playerName}</h2>
|
||||
</div>
|
||||
<div class="box-footer scrollbar" style="padding: 2px;">
|
||||
<div class="row">
|
||||
<div class="column" style="padding: 5px 0px 5px 10px;"><p>Times Kicked: ${kickCount}<br>
|
||||
</p></div>
|
||||
<div class="column"><img style="padding: 10px 100px; height: 100px; width: 100px;"
|
||||
src="https://cravatar.eu/avatar/${playerName}/100"></div>
|
||||
<div class="column"><p>Player Kills: ${playerKillCount}<br>
|
||||
Mob Kills: ${mobKillCount}<br>
|
||||
Deaths: ${deathCount}
|
||||
</p>
|
||||
</div>
|
||||
</div>
|
||||
<table class="sortable table">
|
||||
<thead>
|
||||
<tr>
|
||||
<th>Time</th>
|
||||
<th>Action</th>
|
||||
<th>Info</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
${tableBodyActions}
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
<div class="column">
|
||||
<div class="box-header">
|
||||
<h2><i class="fa fa-braille" aria-hidden="true"></i> Join PunchCard</h2>
|
||||
</div>
|
||||
<div class="box-footer">
|
||||
<div id="punchcard" style="width: 100%; height: 400px;"></div>
|
||||
</div>
|
||||
<div class="box-header">
|
||||
<h2><i class="fa fa-pie-chart" aria-hidden="true"></i> Server Preference</h2>
|
||||
</div>
|
||||
<div class="box-footer">
|
||||
<div id="serverPie" style="width: 100%; height: 400px;"></div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div id="tab-sessions" class="tab">
|
||||
<div class="row" style="flex-grow: 2; width: 140%;">
|
||||
<div class="column">
|
||||
<div class="box-header">
|
||||
<h2><i class="fa fa-calendar" aria-hidden="true"></i> 50 Most Recent Sessions</h2>
|
||||
</div>
|
||||
${contentSessions}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div id="tab-performance" class="tab">
|
||||
<div class="row">
|
||||
<div class="column"> <!--First row (horizontal)-->
|
||||
<div class="column">
|
||||
<div class="box-header">
|
||||
<h2><i class="fa fa-pie-chart" aria-hidden="true"></i> World Playtime</h2>
|
||||
</div>
|
||||
<div class="box-footer">
|
||||
<div id="worldPie" style="width: 100%; height: 400px;"></div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="column">
|
||||
<div class="box-header">
|
||||
<h2>Last 24 Hours</h2>
|
||||
</div>
|
||||
<div class="box" style="margin-bottom: 5px;">
|
||||
<p>Sessions: ${sessionCountDay}<br>
|
||||
Playtime: ${playtimeDay}<br>
|
||||
<br>
|
||||
Longest Session: ${sessionLengthLongestDay}
|
||||
</p>
|
||||
</div>
|
||||
</div>
|
||||
<div class="column">
|
||||
<div class="box-header">
|
||||
<h2>Last 7 Days</h2>
|
||||
</div>
|
||||
<div class="box" style="margin-bottom: 5px;">
|
||||
<p>Sessions: ${sessionCountWeek}<br>
|
||||
Playtime: ${playtimeWeek}<br>
|
||||
<br>
|
||||
Longest Session: ${sessionLengthLongestWeek}
|
||||
</p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</div> <!--First row (horizontal)-->
|
||||
<div class="row">
|
||||
${contentServerOverview}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="tab-plugins" class="tab column">
|
||||
${tabContentPlugins}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<script src="https://www.kryogenix.org/code/browser/sorttable/sorttable.js"></script>
|
||||
<script src="https://code.highcharts.com/stock/highstock.js"></script>
|
||||
<script src="https://code.highcharts.com/maps/modules/map.js"></script>
|
||||
<script src="https://code.highcharts.com/mapdata/custom/world.js"></script>
|
||||
<script src="./js/punchCard.js"></script>
|
||||
<script src="./js/serverPie.js"></script>
|
||||
<script src="./js/worldPie.js"></script>
|
||||
<script src="./js/pluginsTabExpand.js"></script>
|
||||
<script src="./js/sessionTabExpand.js"></script>
|
||||
<script>
|
||||
var navButtons = document.getElementsByClassName("nav-button");
|
||||
var tabs = document.getElementsByClassName("tab");
|
||||
var slideIndex = window.sessionStorage.getItem("InspectSlideIndex");
|
||||
if (slideIndex === null) {
|
||||
slideIndex = 0;
|
||||
}
|
||||
var x = document.getElementById("main");
|
||||
x.style.transform = "translate3d(0px,0px,0)";
|
||||
x.style.width = "" + navButtons.length * 100 + "%";
|
||||
for (var i = 0; i < navButtons.length; i++) {
|
||||
navButtons[i].onclick = openFunc(i)
|
||||
tabs[i].style.width = "" + 100 / navButtons.length + "%";
|
||||
}
|
||||
x.style.opacity = "1";
|
||||
openFunc(slideIndex)();
|
||||
|
||||
function openFunc(i) {
|
||||
return function() {
|
||||
var max = navButtons.length;
|
||||
for (var j = 0; j < max; j++) {
|
||||
if (j === i) {
|
||||
navButtons[j].classList.add('active');
|
||||
continue;
|
||||
}
|
||||
if (navButtons[j].classList.contains('active')) {
|
||||
navButtons[j].classList.remove('active');
|
||||
}
|
||||
}
|
||||
var perc = - 100 / navButtons.length;
|
||||
slideIndex = i;
|
||||
if (slideIndex > max) {slideIndex = 0};
|
||||
if (slideIndex < 0) {slideIndex = max};
|
||||
window.sessionStorage.setItem("InspectSlideIndex", slideIndex);
|
||||
var value = slideIndex * perc;
|
||||
x.style.transition = "0.5s";
|
||||
x.style.transform = "translate3d(" + value + "%,0px,0)";
|
||||
};
|
||||
}
|
||||
|
||||
</script>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
639
Plan/src/main/resources/html/server - Example.html
Normal file
639
Plan/src/main/resources/html/server - Example.html
Normal file
@ -0,0 +1,639 @@
|
||||
<!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<title>Plan | Server</title>
|
||||
<meta name="description" content="Player Analysis window">
|
||||
<meta name="author" content="Rsl1122">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1">
|
||||
<link rel="icon" href="https://puu.sh/tK0KL/6aa2ba141b.ico" type="image/x-icon">
|
||||
<link rel="stylesheet" href="./main.css">
|
||||
<link href="https://fonts.googleapis.com/css?family=Quicksand:300,400" rel="stylesheet">
|
||||
<script src="https://use.fontawesome.com/df48eb908b.js"></script>
|
||||
</head>
|
||||
<body>
|
||||
<header>
|
||||
<div>
|
||||
<img class="right" src="https://puu.sh/tJZUb/c2e0ab220f.png" alt="Player Analytics | Analysis">
|
||||
<p class="right">Player Analytics v.4.0.0</p>
|
||||
<h1>Plan | Server Analysis</h1>
|
||||
</div>
|
||||
</header>
|
||||
<div class="content-server">
|
||||
<div class="row nav-bar">
|
||||
<a href="javascript:void(0)" class="nav-button">
|
||||
<i class="fa fa-info-circle" aria-hidden="true"></i> Information
|
||||
</a>
|
||||
<a href="javascript:void(0)" class="nav-button">
|
||||
<i class="fa fa-bar-chart" aria-hidden="true"></i> Online Activity
|
||||
</a>
|
||||
<a href="javascript:void(0)" class="nav-button">
|
||||
<i class="fa fa-calendar" aria-hidden="true"></i> Sessions
|
||||
</a>
|
||||
<a href="javascript:void(0)" class="nav-button">
|
||||
<i class="fa fa-cogs" aria-hidden="true"></i> Performance
|
||||
</a>
|
||||
<a href="javascript:void(0)" class="nav-button">
|
||||
<i class="fa fa-list-alt" aria-hidden="true"></i> Playerlist
|
||||
</a>
|
||||
<a href="javascript:void(0)" class="nav-button">
|
||||
<i class="fa fa-terminal" aria-hidden="true"></i> Command usage
|
||||
</a>
|
||||
<a href="javascript:void(0)" class="nav-button">
|
||||
<i class="fa fa-globe" aria-hidden="true"></i> Demographics
|
||||
</a>
|
||||
<a href="javascript:void(0)" class="nav-button">
|
||||
<i class="fa fa-cubes" aria-hidden="true"></i> Plugins
|
||||
</a>
|
||||
</div>
|
||||
<div id="limiter" class="main-limiter">
|
||||
<div id="main" class="main-wrapper row">
|
||||
<div id="tab-information" class="tab">
|
||||
<div class="row">
|
||||
<div class="column">
|
||||
<div class="box-header">
|
||||
<h2><i class="fa fa-bar-chart" aria-hidden="true"></i> Players Online</h2>
|
||||
</div>
|
||||
<div class="box-footer">
|
||||
<img id="playersOnline" style="width: 100%;" src="http://puu.sh/xdcdv/77aca85f4c.png">
|
||||
</div>
|
||||
</div>
|
||||
<div class="column">
|
||||
<div class="box-header">
|
||||
<h2><i class="fa fa-info-circle" aria-hidden="true"></i> Information</h2>
|
||||
</div>
|
||||
<div class="box" style="margin-bottom: 5px;">
|
||||
<div class="row">
|
||||
<div class="column">
|
||||
<p>30/50 Players Online<br>43 New Players Today<br>
|
||||
<br>
|
||||
100 Active Players<br>
|
||||
1246 Total Players<br>
|
||||
<br>
|
||||
Peak Time: 18:23 Pm<br>
|
||||
Last Peak: 53 Players<br>
|
||||
<br>
|
||||
<b>All Time Peak:</b><br>
|
||||
Aug 13 2017, 18:46: 75 Players
|
||||
</p>
|
||||
</div>
|
||||
<div class="column">
|
||||
<p><b>Averages:</b></p>
|
||||
<li>Session Length: 28m 42s</li>
|
||||
<li>Players / Day: 196</li>
|
||||
<li>New Players / Day: 24</li>
|
||||
<p><b>Total:</b></p>
|
||||
<li>Playtime: 3 months 5d 53h</li>
|
||||
<li>Sessions: 6480</li>
|
||||
<li>Kills: 3403</li>
|
||||
<li>Mob Kills: 503402</li>
|
||||
<li>Deaths: 5704</li>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="box-header">
|
||||
<h2><i class="fa fa-calendar-check-o" aria-hidden="true"></i> Recent Logins</h2>
|
||||
</div>
|
||||
<div class="box-footer" style="padding: 2px;">
|
||||
<table>
|
||||
<thead>
|
||||
<tr>
|
||||
<th>Player</th>
|
||||
<th>Seen</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<tr>
|
||||
<th><a class="link" href="#">Rsl1122</a></th>
|
||||
<th>18 Aug 2017, 15:56</th>
|
||||
</tr>
|
||||
<tr>
|
||||
<th><a class="link" href="#">Melonking</a></th>
|
||||
<th>18 Aug 2017, 15:43</th>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div id="tab-online-activity" class="tab column">
|
||||
<div class="row">
|
||||
<div class="column">
|
||||
<div class="box-header">
|
||||
<h2><i class="fa fa-bar-chart" aria-hidden="true"></i> Players Online</h2>
|
||||
</div>
|
||||
<div class="box-footer">
|
||||
<img id="playersOnline2" style="width: 100%;" src="http://puu.sh/xdcdv/77aca85f4c.png">
|
||||
</div>
|
||||
</div>
|
||||
<div class="column">
|
||||
<div class="box-header">
|
||||
<h2><i class="fa fa-braille" aria-hidden="true"></i> Player Join PunchCard</h2>
|
||||
</div>
|
||||
<div class="box-footer">
|
||||
<img id="punchCard" style="width: 100%;" src="http://puu.sh/xdhil/73c2c5b944.png">
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="column">
|
||||
<div class="box-header">
|
||||
<h2>Last 24 Hours</h2>
|
||||
</div>
|
||||
<div class="box">
|
||||
<p>Unique Players: 217<br>
|
||||
Unique / Day: 217</p>
|
||||
<p>New Players: 38<br>
|
||||
New / Day: 38</p>
|
||||
</div>
|
||||
</div>
|
||||
<div class="column">
|
||||
<div class="box-header">
|
||||
<h2>Last 7 Days</h2>
|
||||
</div>
|
||||
<div class="box">
|
||||
<p>Unique Players: 670<br>
|
||||
Unique / Day: 204</p>
|
||||
<p>New Players: 247<br>
|
||||
New / Day: 35</p>
|
||||
</div>
|
||||
</div>
|
||||
<div class="column">
|
||||
<div class="box-header">
|
||||
<h2>Last 30 Days</h2>
|
||||
</div>
|
||||
<div class="box">
|
||||
<p>Unique Players: 812<br>
|
||||
Unique / Day: 196</p>
|
||||
<p>New Players: 463<br>
|
||||
New / Day: 15</p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div id="tab-sessions" class="tab">
|
||||
<div class="row" style="flex-grow: 2; width: 140%;">
|
||||
<div class="column">
|
||||
<div class="box-header">
|
||||
<h2><i class="fa fa-calendar" aria-hidden="true"></i> 50 Most Recent Sessions</h2>
|
||||
</div>
|
||||
<div class="box-footer scrollbar" style="padding: 2px;">
|
||||
<table class="sortable table">
|
||||
<thead>
|
||||
<tr>
|
||||
<th>Player</th>
|
||||
<th>Started</th>
|
||||
<th>Length</th>
|
||||
<th>World - Time</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<tr>
|
||||
<th><a class="link" href="#">Rsl1122</a></th>
|
||||
<th>18 Aug, 16:22</th>
|
||||
<th>Online</th>
|
||||
<th>freebuildnew - 100%</th>
|
||||
</tr>
|
||||
<tr>
|
||||
<th><a class="link" href="#">Rsl1122</a></th>
|
||||
<th>18 Aug, 15:56</th>
|
||||
<th>1h 45m 43s</th>
|
||||
<th>world - 87%</th>
|
||||
</tr>
|
||||
<tr>
|
||||
<th><a class="link" href="#">Melonking</a></th>
|
||||
<th>18 Aug, 15:43</th>
|
||||
<th>5m 2s</th>
|
||||
<th>gm3 - 62%</th>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="column">
|
||||
<div class="box-header">
|
||||
<h2><i class="fa fa-pie-chart" aria-hidden="true"></i> World Playtime</h2>
|
||||
</div>
|
||||
<div class="box-footer">
|
||||
<img id="worldPie" style="width: 100%;" src="http://puu.sh/xdhF0/3c7ae10d4e.png">
|
||||
</div>
|
||||
<div class="box-header">
|
||||
<h2><i class="fa fa-pie-chart" aria-hidden="true"></i> Playerbase</h2>
|
||||
</div>
|
||||
<div class="box-footer">
|
||||
<img id="activityPie" style="width: 100%;" src="http://puu.sh/xdgXa/f4a3b7df80.png">
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div id="tab-performance" class="tab">
|
||||
<div class="column">
|
||||
<div class="row"> <!--First row (horizontal)-->
|
||||
<div class="column">
|
||||
<div class="box-header">
|
||||
<h2><i class="fa fa-bar-chart" aria-hidden="true"></i> Ticks Per Second</h2>
|
||||
</div>
|
||||
<div class="box-footer">
|
||||
<img id="tpsGraph" style="width: 100%;" src="http://puu.sh/xdivg/0dfd27035a.png">
|
||||
</div>
|
||||
</div>
|
||||
<div class="column">
|
||||
<div class="box-header">
|
||||
<h2><i class="fa fa-bar-chart" aria-hidden="true"></i> Resource Usage</h2>
|
||||
</div>
|
||||
<div class="box-footer">
|
||||
<img id="resourceGraph" style="width: 100%;" src="http://puu.sh/xdjtY/419496ddf3.png">
|
||||
</div>
|
||||
</div>
|
||||
</div> <!--First row (horizontal)-->
|
||||
<div class="row">
|
||||
<div class="column">
|
||||
<div class="box-header">
|
||||
<h2><i class="fa fa-bar-chart" aria-hidden="true"></i> World Load</h2>
|
||||
</div>
|
||||
<div class="box-footer">
|
||||
<img id="worldGraph" style="width: 100%;" src="http://puu.sh/xdjut/bcc8d4d7ff.png">
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="column">
|
||||
<div class="box-header">
|
||||
<h2><i class="fa fa-cogs" aria-hidden="true"></i> Last 24 Hours</h2>
|
||||
</div>
|
||||
<div class="box">
|
||||
<p><b>Averages:</b></p>
|
||||
<ul>
|
||||
<li>TPS: 19.83</li>
|
||||
<li>CPU: 25.51%</li>
|
||||
<li>RAM: 5282 Mb</li>
|
||||
<li>Entities: 3649</li>
|
||||
<li>Chunks: 1789</li>
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
<div class="column">
|
||||
<div class="box-header">
|
||||
<h2><i class="fa fa-cogs" aria-hidden="true"></i> Last 7 Days</h2>
|
||||
</div>
|
||||
<div class="box">
|
||||
<p><b>Averages:</b></p>
|
||||
<ul>
|
||||
<li>TPS: 19.83</li>
|
||||
<li>CPU: 25.51%</li>
|
||||
<li>RAM: 5282 Mb</li>
|
||||
<li>Entities: 3649</li>
|
||||
<li>Chunks: 1789</li>
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div id="tab-playerlist" class="tab">
|
||||
<div class="column">
|
||||
<div class="box-header">
|
||||
<h2><i class="fa fa-list" aria-hidden="true"></i> Playerlist</h2>
|
||||
</div>
|
||||
<div class="box-footer scrollbar" style="padding: 2px;">
|
||||
<table class="sortable table">
|
||||
<thead>
|
||||
<tr>
|
||||
<th><i class="fa fa-user" aria-hidden="true"></i> Player</th>
|
||||
<th><i class="fa fa-check" aria-hidden="true"></i> Active</th>
|
||||
<th><i class="fa fa-clock-o" aria-hidden="true"></i> Playtime</th>
|
||||
<th><i class="fa fa-calendar-plus-o" aria-hidden="true"></i> Login times</th>
|
||||
<th><i class="fa fa-user-plus" aria-hidden="true"></i> Registered</th>
|
||||
<th><i class="fa fa-calendar-check-o" aria-hidden="true"></i> Last seen</th>
|
||||
<th><i class="fa fa-globe" aria-hidden="true"></i> Geolocation</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<tr>
|
||||
<th><a class="link" href="#">Rsl1122</a></th>
|
||||
<th>Active</th>
|
||||
<th>1d 20h 4m 2s</th>
|
||||
<th>324</th>
|
||||
<th>Aug 18 2017, 15:54</th>
|
||||
<th>Aug 18, 16:48</th>
|
||||
<th>Finland</th>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div id="tab-command-usage" class="tab">
|
||||
<div class="column">
|
||||
<div class="box-header">
|
||||
<h2><i class="fa fa-list" aria-hidden="true"></i> Playerlist</h2>
|
||||
</div>
|
||||
<div class="box-footer scrollbar" style="padding: 2px;">
|
||||
<table class="sortable table">
|
||||
<thead>
|
||||
<tr>
|
||||
<th><i class="fa fa-chevron-right" aria-hidden="true"></i> Command</th>
|
||||
<th><i class="fa fa-list-ol" aria-hidden="true"></i> Times used</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<tr>
|
||||
<th>/plan</th>
|
||||
<th>432</th>
|
||||
</tr>
|
||||
<tr>
|
||||
<th>/spawn</th>
|
||||
<th>23</th>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div id="tab-demographics" class="tab">
|
||||
<div class="column">
|
||||
<div class="box-header">
|
||||
<h2><i class="fa fa-globe" aria-hidden="true"></i> Geolocations</h2>
|
||||
</div>
|
||||
<div class="box-footer" style="padding: 2px;">
|
||||
<img id="geoChart" style="width: 100%;" src="http://puu.sh/xdVkp/9eddada8bd.png">
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div id="tab-plugins" class="tab column">
|
||||
<div class="row">
|
||||
<div class="column">
|
||||
<div class="box-header">
|
||||
<h2><i class="fa fa-cube" aria-hidden="true"></i> Plugin 1</h2>
|
||||
</div>
|
||||
<div class="box plugin">
|
||||
<p>Test: 5 / 25<br>
|
||||
Test: 20%</p>
|
||||
<p>More data: Yes<br>
|
||||
Data: 4</p>
|
||||
</div>
|
||||
</div>
|
||||
<div class="column">
|
||||
<div class="box-header">
|
||||
<h2><i class="fa fa-cube" aria-hidden="true"></i> Plugin 2</h2>
|
||||
</div>
|
||||
<div class="box plugin">
|
||||
<p>Yes<br>
|
||||
Yes<br>
|
||||
Yes<br>Yes<br>Yes<br>Yes<br>Yes<br>
|
||||
Yes<br>Yes<br>Yes<br>Yes<br>Yes<br>
|
||||
Yes<br>Yes<br>Yes<br>Yes<br>Yes<br>
|
||||
</p>
|
||||
</div>
|
||||
</div>
|
||||
<div class="column">
|
||||
<div class="box-header">
|
||||
<h2><i class="fa fa-cube" aria-hidden="true"></i> Plugin 3</h2>
|
||||
</div>
|
||||
<div class="box plugin">
|
||||
<img id="pluginpie" style="width: 100%;" src="http://puu.sh/xdhF0/3c7ae10d4e.png">
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="column">
|
||||
<div class="box-header" style="margin-top: 10px;">
|
||||
<h2><i class="fa fa-cube" aria-hidden="true"></i> Plugin 4</h2>
|
||||
</div>
|
||||
<div class="box plugin" style="height: 100%;">
|
||||
<table class="sortable table">
|
||||
<thead>
|
||||
<tr>
|
||||
<th>Test</th>
|
||||
<th>Test2</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<tr>
|
||||
<th>Data</th>
|
||||
<th>Data</th>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
<div class="column" style="width: 200%;">
|
||||
<div class="box-header" style="margin-top: 10px;">
|
||||
<h2>That's all..</h2>
|
||||
</div>
|
||||
<div class="box plugin">
|
||||
<p>Do you have more plugins? ._.</p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<script src="https://www.kryogenix.org/code/browser/sorttable/sorttable.js"></script>
|
||||
<script src="https://code.highcharts.com/stock/highstock.js"></script>
|
||||
<script src="https://code.highcharts.com/maps/modules/map.js"></script>
|
||||
<script src="https://code.highcharts.com/mapdata/custom/world.js"></script>
|
||||
<script src="./js/activityPie.js"></script>
|
||||
<script src="./js/gmPie.js"></script>
|
||||
<script src="./js/playerGraph.js"></script>
|
||||
<script src="./js/punchCard.js"></script>
|
||||
<script src="./js/resourceGraph.js"></script>
|
||||
<script src="./js/sessionDistributionChart.js"></script>
|
||||
<script src="./js/tpsGraph.js"></script>
|
||||
<script src="./js/worldGraph.js"></script>
|
||||
<script src="./js/worldMap.js"></script>
|
||||
<script src="./js/worldPie.js"></script>
|
||||
<script>
|
||||
Highcharts.setOptions({
|
||||
global: {
|
||||
timezoneOffset: ${timeZone} * 60
|
||||
}
|
||||
});
|
||||
// Data Variables
|
||||
var playersOnlineSeries = {
|
||||
name: 'Players Online',
|
||||
data: ${playersOnlineSeries},
|
||||
type: 'areaspline',
|
||||
color: '#%playersgraphcolor%',
|
||||
tooltip: {
|
||||
valueDecimals: 0
|
||||
}
|
||||
};
|
||||
var tpsSeries = {
|
||||
name: 'TPS',
|
||||
data: ${tpsSeries},
|
||||
type: 'spline',
|
||||
zones: [{
|
||||
value: %tpsmedium%,
|
||||
color: '${tpsLowColor}'
|
||||
}, {
|
||||
value: %tpshigh%,
|
||||
color: '${tpsMediumColor}'
|
||||
}, {
|
||||
value: 30,
|
||||
color: '${tpsHighColor}'
|
||||
}],
|
||||
tooltip: {
|
||||
valueDecimals: 2
|
||||
},
|
||||
yAxis: 1
|
||||
};
|
||||
var cpuSeries = {
|
||||
name: 'CPU Usage',
|
||||
data: ${cpuSeries},
|
||||
type: 'areaspline',
|
||||
color: '#e0d264',
|
||||
tooltip: {
|
||||
pointFormat: '{series.name}: <b>{point.y:.2f}%</b>'
|
||||
}
|
||||
};
|
||||
var ramSeries = {
|
||||
name: 'RAM Usage',
|
||||
data: ${ramSeries},
|
||||
type: 'areaspline',
|
||||
color: '#7dcc24',
|
||||
tooltip: {
|
||||
valueDecimals: 0
|
||||
},
|
||||
yAxis: 1
|
||||
};
|
||||
var entitySeries = {
|
||||
name: 'Loaded Entities',
|
||||
data: ${entitySeries},
|
||||
type: 'areaspline',
|
||||
color: '#ac69ef',
|
||||
tooltip: {
|
||||
valueDecimals: 0
|
||||
},
|
||||
yAxis: 1
|
||||
};
|
||||
var chunkSeries = {
|
||||
name: 'Loaded Chunks',
|
||||
data: ${chunkSeries},
|
||||
type: 'areaspline',
|
||||
color: '#b58310',
|
||||
tooltip: {
|
||||
valueDecimals: 0
|
||||
}
|
||||
};
|
||||
var activitySeries = {
|
||||
name: 'Players',
|
||||
colorByPoint: true,
|
||||
data: [{
|
||||
name: 'Active',
|
||||
y: ${active}
|
||||
}, {
|
||||
name: 'Inactive',
|
||||
y: ${inactive},
|
||||
sliced: true,
|
||||
selected: true
|
||||
}, {
|
||||
name: 'Single Join',
|
||||
y: ${joinLeaver}
|
||||
}, {
|
||||
name: 'Banned',
|
||||
y: ${banned}
|
||||
}]
|
||||
};
|
||||
var gmData = ${gmData};
|
||||
var gmSeries = {
|
||||
name: 'GM Usage',
|
||||
colorByPoint: true,
|
||||
data: [{
|
||||
name: 'Survival',
|
||||
y: gmData[0],
|
||||
sliced: true,
|
||||
selected: true
|
||||
}, {
|
||||
name: 'Creative',
|
||||
y: gmData[1]
|
||||
}, {
|
||||
name: 'Adventure',
|
||||
y: gmData[2]
|
||||
}, {
|
||||
name: 'Spectator',
|
||||
y: gmData[3]
|
||||
}]
|
||||
};
|
||||
var worldSeries = {
|
||||
name: 'World Playtime',
|
||||
colorByPoint: true,
|
||||
data: ${worldSeries}
|
||||
};
|
||||
var mapSeries = {
|
||||
name: 'Players',
|
||||
type: 'map',
|
||||
mapData: Highcharts.maps['custom/world'],
|
||||
data: ${geoMapSeries}
|
||||
joinBy: ['iso-a3', 'code']
|
||||
};
|
||||
var sessionLengthSeries = {
|
||||
name: 'Sessions',
|
||||
color: '#89c471',
|
||||
data: ${sessionLengthSeries}
|
||||
};
|
||||
var punchcardSeries = {
|
||||
name: 'Relative Activity',
|
||||
color: '#222',
|
||||
data: ${punchCardSeries}
|
||||
};
|
||||
|
||||
</script>
|
||||
<script>
|
||||
var navButtons = document.getElementsByClassName("nav-button");
|
||||
var tabs = document.getElementsByClassName("tab");
|
||||
var slideIndex = window.sessionStorage.getItem("AnalysisSlideIndex");
|
||||
if (slideIndex === null) {
|
||||
slideIndex = 0;
|
||||
}
|
||||
var x = document.getElementById("main");
|
||||
x.style.transform = "translate3d(0px,0px,0)";
|
||||
x.style.width = "" + navButtons.length * 100 + "%";
|
||||
for (var i = 0; i < navButtons.length; i++) {
|
||||
navButtons[i].onclick = openFunc(i)
|
||||
tabs[i].style.width = "" + 100 / navButtons.length + "%";
|
||||
}
|
||||
x.style.opacity = "1";
|
||||
openFunc(slideIndex)();
|
||||
/*gmPie('gmPie', gmSeries, '%gmtotal%', [%gmcolors%]);
|
||||
activityPie('activityPie', activitySeries, %activitytotal%, [%activitycolors%]);
|
||||
worldPie('worldPie', worldSeries, '%worldtotal%');
|
||||
playersChart('playerChartDay', playersOnlineSeries, 1);
|
||||
playersChart('playerChartMonth', playersOnlineSeries, 4);
|
||||
tpsChart('tpsGraph', tpsSeries, playersOnlineSeries);
|
||||
resourceChart('resourceGraph', cpuSeries, ramSeries);
|
||||
worldChart('worldGraph', entitySeries, chunkSeries);
|
||||
worldMap('choropleth', '#EEFFEE', '#267f00', mapSeries);
|
||||
sessionDistributionChart('sessionDistribution', sessionLengthSeries);
|
||||
punchCard('punchcard', punchcardSeries);
|
||||
countUpTimer();*/
|
||||
|
||||
function openFunc(i) {
|
||||
return function() {
|
||||
var max = navButtons.length;
|
||||
for (var j = 0; j < max; j++) {
|
||||
if (j === i) {
|
||||
navButtons[j].classList.add('active');
|
||||
continue;
|
||||
}
|
||||
if (navButtons[j].classList.contains('active')) {
|
||||
navButtons[j].classList.remove('active');
|
||||
}
|
||||
}
|
||||
var perc = - 100 / navButtons.length;
|
||||
slideIndex = i;
|
||||
if (slideIndex > max) {slideIndex = 0};
|
||||
if (slideIndex < 0) {slideIndex = max};
|
||||
window.sessionStorage.setItem("AnalysisSlideIndex", slideIndex);
|
||||
var value = slideIndex * perc;
|
||||
x.style.transition = "0.5s";
|
||||
x.style.transform = "translate3d(" + value + "%,0px,0)";
|
||||
};
|
||||
}
|
||||
|
||||
</script>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
536
Plan/src/main/resources/html/server.html
Normal file
536
Plan/src/main/resources/html/server.html
Normal file
@ -0,0 +1,536 @@
|
||||
<!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<title>Plan | Server</title>
|
||||
<meta name="description" content="Player Analysis window">
|
||||
<meta name="author" content="Rsl1122">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1">
|
||||
<link rel="icon" href="https://puu.sh/tK0KL/6aa2ba141b.ico" type="image/x-icon">
|
||||
<link rel="stylesheet" href="./main.css">
|
||||
<link href="https://fonts.googleapis.com/css?family=Quicksand:300,400" rel="stylesheet">
|
||||
<script src="https://use.fontawesome.com/df48eb908b.js"></script>
|
||||
</head>
|
||||
<body>
|
||||
<header>
|
||||
<div>
|
||||
<img class="right" src="https://puu.sh/tJZUb/c2e0ab220f.png" alt="Player Analytics | Analysis">
|
||||
<p class="right">Player Analytics v.${version}</p>
|
||||
<h1>${serverName} | Server Analysis</h1>
|
||||
</div>
|
||||
</header>
|
||||
<div class="content-server">
|
||||
<div class="nav-bar row">
|
||||
<a href="javascript:void(0)" class="nav-button">
|
||||
<i class="fa fa-info-circle" aria-hidden="true"></i> Information
|
||||
</a>
|
||||
<a href="javascript:void(0)" class="nav-button">
|
||||
<i class="fa fa-bar-chart" aria-hidden="true"></i> Online Activity
|
||||
</a>
|
||||
<a href="javascript:void(0)" class="nav-button">
|
||||
<i class="fa fa-calendar" aria-hidden="true"></i> Sessions
|
||||
</a>
|
||||
<a href="javascript:void(0)" class="nav-button">
|
||||
<i class="fa fa-cogs" aria-hidden="true"></i> Performance
|
||||
</a>
|
||||
<a href="javascript:void(0)" class="nav-button">
|
||||
<i class="fa fa-list-alt" aria-hidden="true"></i> Playerlist
|
||||
</a>
|
||||
<a href="javascript:void(0)" class="nav-button">
|
||||
<i class="fa fa-terminal" aria-hidden="true"></i> Command usage
|
||||
</a>
|
||||
<a href="javascript:void(0)" class="nav-button">
|
||||
<i class="fa fa-globe" aria-hidden="true"></i> Demographics
|
||||
</a>
|
||||
<a href="javascript:void(0)" class="nav-button">
|
||||
<i class="fa fa-cubes" aria-hidden="true"></i> Plugins
|
||||
</a>
|
||||
</div>
|
||||
<div id="limiter" class="main-limiter">
|
||||
<div id="main" class="main-wrapper">
|
||||
<div id="tab-information" class="tab">
|
||||
<div class="row">
|
||||
<div class="column">
|
||||
<div class="box-header">
|
||||
<h2><i class="fa fa-bar-chart" aria-hidden="true"></i> Players Online</h2>
|
||||
</div>
|
||||
<div class="box-footer">
|
||||
<div id="playersOnlineDay" style="width: 100%; height: 700px;"></div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="column">
|
||||
<div class="box-header">
|
||||
<h2><i class="fa fa-info-circle" aria-hidden="true"></i> Information</h2>
|
||||
</div>
|
||||
<div class="box" style="margin-bottom: 5px;">
|
||||
<div class="row">
|
||||
<div class="column">
|
||||
<p>${playersOnline}/${playersMax} Players Online<br>43 New Players Today<br>
|
||||
<br>
|
||||
${playersActive} Active Players<br>
|
||||
${playersTotal} Total Players<br>
|
||||
<br>
|
||||
Peak Time: ${lastPeakTime}<br>
|
||||
Last Peak: ${playersLastPeak} Players<br>
|
||||
<br>
|
||||
<b>All Time Peak:</b><br>
|
||||
${bestPeakTime}: ${playersBestPeak} Players
|
||||
</p>
|
||||
</div>
|
||||
<div class="column">
|
||||
<p><b>Averages:</b></p>
|
||||
<li>Session Length: ${sessionAverage}</li>
|
||||
<li>Players / Day: ${playersAverage}</li>
|
||||
<li>New Players / Day: ${playersNewAverage}</li>
|
||||
<p><b>Total:</b></p>
|
||||
<li>Playtime: ${playtimeTotal}</li>
|
||||
<li>Sessions: ${sessionCount}</li>
|
||||
<li>Kills: ${killCount}</li>
|
||||
<li>Mob Kills: ${mobKillCount}</li>
|
||||
<li>Deaths: ${deathCount}</li>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="box-header">
|
||||
<h2><i class="fa fa-calendar-check-o" aria-hidden="true"></i> Recent Logins</h2>
|
||||
</div>
|
||||
<div class="box-footer" style="padding: 2px;">
|
||||
<table>
|
||||
<thead>
|
||||
<tr>
|
||||
<th>Player</th>
|
||||
<th>Seen</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
${tableBodyRecentLogins}
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div id="tab-online-activity" class="tab column">
|
||||
<div class="row">
|
||||
<div class="column">
|
||||
<div class="box-header">
|
||||
<h2><i class="fa fa-bar-chart" aria-hidden="true"></i> Players Online</h2>
|
||||
</div>
|
||||
<div class="box-footer">
|
||||
<div id="playersOnlineMonth" style="width: 100%; height: 700px;"></div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="column">
|
||||
<div class="box-header">
|
||||
<h2><i class="fa fa-braille" aria-hidden="true"></i> Player Join PunchCard</h2>
|
||||
</div>
|
||||
<div class="box-footer">
|
||||
<div id="punchcard" style="width: 100%; height: 700px;"></div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="column">
|
||||
<div class="box-header">
|
||||
<h2>Last 24 Hours</h2>
|
||||
</div>
|
||||
<div class="box">
|
||||
<p>Unique Players: ${playersDay}<br>
|
||||
Unique / Day: ${playersAverageDay}</p>
|
||||
<p>New Players: ${playersNewDay} <br>
|
||||
New / Day: ${playersNewAverageDay}</p>
|
||||
</div>
|
||||
</div>
|
||||
<div class="column">
|
||||
<div class="box-header">
|
||||
<h2>Last 7 Days</h2>
|
||||
</div>
|
||||
<div class="box">
|
||||
<p>Unique Players: ${playersWeek}<br>
|
||||
Unique / Day: ${playersAverageWeek}</p>
|
||||
<p>New Players: ${playersNewWeek}<br>
|
||||
New / Day: ${playersNewAverageWeek}</p>
|
||||
</div>
|
||||
</div>
|
||||
<div class="column">
|
||||
<div class="box-header">
|
||||
<h2>Last 30 Days</h2>
|
||||
</div>
|
||||
<div class="box">
|
||||
<p>Unique Players: ${playersMonth}<br>
|
||||
Unique / Day: ${playersAverageMonth}</p>
|
||||
<p>New Players: ${playersNewMonth}<br>
|
||||
New / Day: ${playersNewAverageMonth}</p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div id="tab-sessions" class="tab">
|
||||
<div class="row" style="flex-grow: 2; width: 140%;">
|
||||
<div class="column">
|
||||
<div class="box-header">
|
||||
<h2><i class="fa fa-calendar" aria-hidden="true"></i> 50 Most Recent Sessions</h2>
|
||||
</div>
|
||||
<div class="box-footer scrollbar" style="padding: 2px;">
|
||||
<table class="sortable table">
|
||||
<thead>
|
||||
<tr>
|
||||
<th>Player</th>
|
||||
<th>Started</th>
|
||||
<th>Length</th>
|
||||
<th>World - Time</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
${tableBodySessions}
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="column">
|
||||
<div class="box-header">
|
||||
<h2><i class="fa fa-pie-chart" aria-hidden="true"></i> World Playtime</h2>
|
||||
</div>
|
||||
<div class="box-footer">
|
||||
<div id="worldPie" style="width: 100%; height: 450px;"></div>
|
||||
</div>
|
||||
<div class="box-header">
|
||||
<h2><i class="fa fa-pie-chart" aria-hidden="true"></i> Playerbase</h2>
|
||||
</div>
|
||||
<div class="box-footer">
|
||||
<div id="activityPie" style="width: 100%; height: 450px;"></div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div id="tab-performance" class="tab">
|
||||
<div class="column">
|
||||
<div class="row"> <!--First row (horizontal)-->
|
||||
<div class="column">
|
||||
<div class="box-header">
|
||||
<h2><i class="fa fa-bar-chart" aria-hidden="true"></i> Ticks Per Second</h2>
|
||||
</div>
|
||||
<div class="box-footer">
|
||||
<div id="tpsGraph" style="width: 100%; height: 700px;"></div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="column">
|
||||
<div class="box-header">
|
||||
<h2><i class="fa fa-bar-chart" aria-hidden="true"></i> Resource Usage</h2>
|
||||
</div>
|
||||
<div class="box-footer">
|
||||
<div id="resourceGraph" style="width: 100%; height: 700px;"></div>
|
||||
</div>
|
||||
</div>
|
||||
</div> <!--First row (horizontal)-->
|
||||
<div class="row">
|
||||
<div class="column">
|
||||
<div class="box-header">
|
||||
<h2><i class="fa fa-bar-chart" aria-hidden="true"></i> World Load</h2>
|
||||
</div>
|
||||
<div class="box-footer">
|
||||
<div id="worldGraph" style="width: 100%; height: 700px;"></div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="column">
|
||||
<div class="box-header">
|
||||
<h2><i class="fa fa-cogs" aria-hidden="true"></i> Last 24 Hours</h2>
|
||||
</div>
|
||||
<div class="box">
|
||||
<p><b>Averages:</b></p>
|
||||
<ul>
|
||||
<li>TPS: ${tpsAverageDay}</li>
|
||||
<li>CPU: ${cpuAverageDay}</li>
|
||||
<li>RAM: ${ramAverageDay}</li>
|
||||
<li>Entities: ${entityAverageDay}</li>
|
||||
<li>Chunks: ${chunkAverageDay}</li>
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
<div class="column">
|
||||
<div class="box-header">
|
||||
<h2><i class="fa fa-cogs" aria-hidden="true"></i> Last 7 Days</h2>
|
||||
</div>
|
||||
<div class="box">
|
||||
<p><b>Averages:</b></p>
|
||||
<ul>
|
||||
<li>TPS: ${tpsAverageWeek}</li>
|
||||
<li>CPU: ${cpuAverageWeek}</li>
|
||||
<li>RAM: ${ramAverageWeek}</li>
|
||||
<li>Entities: ${entityAverageWeek}</li>
|
||||
<li>Chunks: ${chunkAverageWeek}</li>
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div id="tab-playerlist" class="tab">
|
||||
<div class="column">
|
||||
<div class="box-header">
|
||||
<h2><i class="fa fa-list" aria-hidden="true"></i> Playerlist</h2>
|
||||
</div>
|
||||
<div class="box-footer scrollbar" style="padding: 2px;">
|
||||
<table class="sortable table">
|
||||
<thead>
|
||||
<tr>
|
||||
<th><i class="fa fa-user" aria-hidden="true"></i> Player</th>
|
||||
<th><i class="fa fa-check" aria-hidden="true"></i> Active</th>
|
||||
<th><i class="fa fa-clock-o" aria-hidden="true"></i> Playtime</th>
|
||||
<th><i class="fa fa-calendar-plus-o" aria-hidden="true"></i> Login times</th>
|
||||
<th><i class="fa fa-user-plus" aria-hidden="true"></i> Registered</th>
|
||||
<th><i class="fa fa-calendar-check-o" aria-hidden="true"></i> Last seen</th>
|
||||
<th><i class="fa fa-globe" aria-hidden="true"></i> Geolocation</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
${tableBodyPlayerList}
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div id="tab-command-usage" class="tab">
|
||||
<div class="column">
|
||||
<div class="box-header">
|
||||
<h2><i class="fa fa-list" aria-hidden="true"></i> Playerlist</h2>
|
||||
</div>
|
||||
<div class="box-footer scrollbar" style="padding: 2px;">
|
||||
<table class="sortable table">
|
||||
<thead>
|
||||
<tr>
|
||||
<th><i class="fa fa-chevron-right" aria-hidden="true"></i> Command</th>
|
||||
<th><i class="fa fa-list-ol" aria-hidden="true"></i> Times used</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
${tableBodyCommands}
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div id="tab-demographics" class="tab">
|
||||
<div class="column">
|
||||
<div class="box-header">
|
||||
<h2><i class="fa fa-globe" aria-hidden="true"></i> Geolocations</h2>
|
||||
</div>
|
||||
<div class="box-footer" style="padding: 2px;">
|
||||
<div id="choropleth" style="width: 100%; height: 700px;"></div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div id="tab-plugins" class="tab column">
|
||||
${tabContentPlugins}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<script src="https://www.kryogenix.org/code/browser/sorttable/sorttable.js"></script>
|
||||
<script src="https://code.highcharts.com/stock/highstock.js"></script>
|
||||
<script src="https://code.highcharts.com/maps/modules/map.js"></script>
|
||||
<script src="https://code.highcharts.com/mapdata/custom/world.js"></script>
|
||||
<script src="./js/activityPie.js"></script>
|
||||
<script src="./js/gmPie.js"></script>
|
||||
<script src="./js/playerGraph.js"></script>
|
||||
<script src="./js/punchCard.js"></script>
|
||||
<script src="./js/resourceGraph.js"></script>
|
||||
<script src="./js/sessionDistributionChart.js"></script>
|
||||
<script src="./js/tpsGraph.js"></script>
|
||||
<script src="./js/worldGraph.js"></script>
|
||||
<script src="./js/worldMap.js"></script>
|
||||
<script src="./js/worldPie.js"></script>
|
||||
<script>
|
||||
Highcharts.setOptions({
|
||||
global: {
|
||||
timezoneOffset: ${timeZone} * 60
|
||||
}
|
||||
});
|
||||
// Data Variables
|
||||
var playersOnlineSeries = {
|
||||
name: 'Players Online',
|
||||
data: ${playersOnlineSeries},
|
||||
type: 'areaspline',
|
||||
color: '${playersGraphColor}',
|
||||
tooltip: {
|
||||
valueDecimals: 0
|
||||
}
|
||||
};
|
||||
var tpsSeries = {
|
||||
name: 'TPS',
|
||||
data: ${tpsSeries},
|
||||
type: 'spline',
|
||||
zones: [{
|
||||
value: ${tpsMedium},
|
||||
color: '${tpsLowColor}'
|
||||
}, {
|
||||
value: ${tpsHigh},
|
||||
color: '${tpsMediumColor}'
|
||||
}, {
|
||||
value: 30,
|
||||
color: '${tpsHighColor}'
|
||||
}],
|
||||
tooltip: {
|
||||
valueDecimals: 2
|
||||
},
|
||||
yAxis: 1
|
||||
};
|
||||
var cpuSeries = {
|
||||
name: 'CPU Usage',
|
||||
data: ${cpuSeries},
|
||||
type: 'areaspline',
|
||||
color: '#e0d264',
|
||||
tooltip: {
|
||||
pointFormat: '{series.name}: <b>{point.y:.2f}%</b>'
|
||||
}
|
||||
};
|
||||
var ramSeries = {
|
||||
name: 'RAM Usage',
|
||||
data: ${ramSeries},
|
||||
type: 'areaspline',
|
||||
color: '#7dcc24',
|
||||
tooltip: {
|
||||
valueDecimals: 0
|
||||
},
|
||||
yAxis: 1
|
||||
};
|
||||
var entitySeries = {
|
||||
name: 'Loaded Entities',
|
||||
data: ${entitySeries},
|
||||
type: 'areaspline',
|
||||
color: '#ac69ef',
|
||||
tooltip: {
|
||||
valueDecimals: 0
|
||||
},
|
||||
yAxis: 1
|
||||
};
|
||||
var chunkSeries = {
|
||||
name: 'Loaded Chunks',
|
||||
data: ${chunkSeries},
|
||||
type: 'areaspline',
|
||||
color: '#b58310',
|
||||
tooltip: {
|
||||
valueDecimals: 0
|
||||
}
|
||||
};
|
||||
var activitySeries = {
|
||||
name: 'Players',
|
||||
colorByPoint: true,
|
||||
data: [{
|
||||
name: 'Active',
|
||||
y: ${active}
|
||||
}, {
|
||||
name: 'Inactive',
|
||||
y: ${inactive},
|
||||
sliced: true,
|
||||
selected: true
|
||||
}, {
|
||||
name: 'Single Join',
|
||||
y: ${joinLeaver}
|
||||
}, {
|
||||
name: 'Banned',
|
||||
y: ${banned}
|
||||
}]
|
||||
};
|
||||
var gmData = ${gmData};
|
||||
var gmSeries = {
|
||||
name: 'GM Usage',
|
||||
colorByPoint: true,
|
||||
data: [{
|
||||
name: 'Survival',
|
||||
y: gmData[0],
|
||||
sliced: true,
|
||||
selected: true
|
||||
}, {
|
||||
name: 'Creative',
|
||||
y: gmData[1]
|
||||
}, {
|
||||
name: 'Adventure',
|
||||
y: gmData[2]
|
||||
}, {
|
||||
name: 'Spectator',
|
||||
y: gmData[3]
|
||||
}]
|
||||
};
|
||||
var worldSeries = {
|
||||
name: 'World Playtime',
|
||||
colorByPoint: true,
|
||||
data: ${worldSeries}
|
||||
};
|
||||
var mapSeries = {
|
||||
name: 'Players',
|
||||
type: 'map',
|
||||
mapData: Highcharts.maps['custom/world'],
|
||||
data: ${geoMapSeries}
|
||||
joinBy: ['iso-a3', 'code']
|
||||
};
|
||||
var sessionLengthSeries = {
|
||||
name: 'Sessions',
|
||||
color: '#89c471',
|
||||
data: ${sessionLengthSeries}
|
||||
};
|
||||
var punchcardSeries = {
|
||||
name: 'Relative Activity',
|
||||
color: '#222',
|
||||
data: ${punchCardSeries}
|
||||
};
|
||||
|
||||
</script>
|
||||
<script>
|
||||
var navButtons = document.getElementsByClassName("nav-button");
|
||||
var tabs = document.getElementsByClassName("tab");
|
||||
var slideIndex = window.sessionStorage.getItem("AnalysisSlideIndex");
|
||||
if (slideIndex === null) {
|
||||
slideIndex = 0;
|
||||
}
|
||||
var x = document.getElementById("main");
|
||||
x.style.transform = "translate3d(0px,0px,0)";
|
||||
x.style.width = "" + navButtons.length * 100 + "%";
|
||||
for (var i = 0; i < navButtons.length; i++) {
|
||||
navButtons[i].onclick = openFunc(i)
|
||||
tabs[i].style.width = "" + 100 / navButtons.length + "%";
|
||||
}
|
||||
x.style.opacity = "1";
|
||||
openFunc(slideIndex)();
|
||||
/*gmPie('gmPie', gmSeries, '${gmTotal}', [${gmColors}]);
|
||||
activityPie('activityPie', activitySeries, ${playersTotal}, [${activityColors}]);
|
||||
worldPie('worldPie', worldSeries, '${worldTotal}');
|
||||
playersChart('playerChartDay', playersOnlineSeries, 1);
|
||||
playersChart('playerChartMonth', playersOnlineSeries, 4);
|
||||
tpsChart('tpsGraph', tpsSeries, playersOnlineSeries);
|
||||
resourceChart('resourceGraph', cpuSeries, ramSeries);
|
||||
worldChart('worldGraph', entitySeries, chunkSeries);
|
||||
worldMap('choropleth', '#EEFFEE', '#267f00', mapSeries);
|
||||
sessionDistributionChart('sessionDistribution', sessionLengthSeries);
|
||||
punchCard('punchcard', punchcardSeries);
|
||||
countUpTimer();*/
|
||||
|
||||
function openFunc(i) {
|
||||
return function() {
|
||||
var max = navButtons.length;
|
||||
for (var j = 0; j < max; j++) {
|
||||
if (j === i) {
|
||||
navButtons[j].classList.add('active');
|
||||
continue;
|
||||
}
|
||||
if (navButtons[j].classList.contains('active')) {
|
||||
navButtons[j].classList.remove('active');
|
||||
}
|
||||
}
|
||||
var perc = - 100 / navButtons.length;
|
||||
slideIndex = i;
|
||||
if (slideIndex > max) {slideIndex = 0};
|
||||
if (slideIndex < 0) {slideIndex = max};
|
||||
window.sessionStorage.setItem("AnalysisSlideIndex", slideIndex);
|
||||
var value = slideIndex * perc;
|
||||
x.style.transition = "0.5s";
|
||||
x.style.transform = "translate3d(" + value + "%,0px,0)";
|
||||
};
|
||||
}
|
||||
|
||||
</script>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
26
Plan/src/main/resources/js/activityPie.js
Normal file
26
Plan/src/main/resources/js/activityPie.js
Normal file
@ -0,0 +1,26 @@
|
||||
function activityPie(id, activitySeries, activityTotal, activityColors) {
|
||||
var myChart = Highcharts.chart(id, {
|
||||
chart: {
|
||||
plotBackgroundColor: null,
|
||||
plotBorderWidth: null,
|
||||
plotShadow: false,
|
||||
type: 'pie'
|
||||
},
|
||||
subtitle: {text: 'Total Players:' + activityTotal},
|
||||
tooltip: {
|
||||
pointFormat: '{series.name}: <b>{point.y}</b>'
|
||||
},
|
||||
plotOptions: {
|
||||
pie: {
|
||||
allowPointSelect: true,
|
||||
cursor: 'pointer',
|
||||
dataLabels: {
|
||||
enabled: false
|
||||
},
|
||||
colors: activityColors,
|
||||
showInLegend: true
|
||||
}
|
||||
},
|
||||
series: [activitySeries]
|
||||
});
|
||||
}
|
24
Plan/src/main/resources/js/gmPie.js
Normal file
24
Plan/src/main/resources/js/gmPie.js
Normal file
@ -0,0 +1,24 @@
|
||||
function gmPie(id, gmSeries, gmtotal, gmColors) {
|
||||
Highcharts.chart(id, {
|
||||
chart: {
|
||||
plotBackgroundColor: null, plotBorderWidth: null, plotShadow: false,
|
||||
type: 'pie'
|
||||
},
|
||||
subtitle: {text: gmtotal},
|
||||
tooltip: {
|
||||
pointFormat: '{series.name}: <b>{point.percentage:.2f}%</b>'
|
||||
},
|
||||
plotOptions: {
|
||||
pie: {
|
||||
allowPointSelect: true,
|
||||
cursor: 'pointer',
|
||||
dataLabels: {
|
||||
enabled: false
|
||||
},
|
||||
colors: gmColors,
|
||||
showInLegend: true
|
||||
}
|
||||
},
|
||||
series: [gmSeries]
|
||||
});
|
||||
}
|
33
Plan/src/main/resources/js/playerGraph.js
Normal file
33
Plan/src/main/resources/js/playerGraph.js
Normal file
@ -0,0 +1,33 @@
|
||||
function playersChart(id, playersOnlineSeries, sel) {
|
||||
Highcharts.stockChart(id, {
|
||||
rangeSelector: {
|
||||
selected: sel,
|
||||
buttons: [{
|
||||
type: 'hour',
|
||||
count: 12,
|
||||
text: '12h'
|
||||
},{
|
||||
type: 'hour',
|
||||
count: 24,
|
||||
text: '24h'
|
||||
},{
|
||||
type: 'day',
|
||||
count: 7,
|
||||
text: '7d'
|
||||
},{
|
||||
type: 'month',
|
||||
count: 1,
|
||||
text: '30d'
|
||||
},{
|
||||
type: 'all',
|
||||
text: 'All'
|
||||
}]
|
||||
},
|
||||
plotOptions: {
|
||||
areaspline: {
|
||||
fillOpacity: 0.4
|
||||
}
|
||||
},
|
||||
series: [playersOnlineSeries]
|
||||
});
|
||||
}
|
8
Plan/src/main/resources/js/pluginsTabExpand.js
Normal file
8
Plan/src/main/resources/js/pluginsTabExpand.js
Normal file
@ -0,0 +1,8 @@
|
||||
$(".plugins-header").click(function () {
|
||||
$header = $(this);
|
||||
$content = $header.next();
|
||||
$(this).parent().siblings().children().next().slideUp(500);
|
||||
$content.slideToggle(500, function () {
|
||||
//execute this after slideToggle is done
|
||||
});
|
||||
});
|
21
Plan/src/main/resources/js/punchCard.js
Normal file
21
Plan/src/main/resources/js/punchCard.js
Normal file
@ -0,0 +1,21 @@
|
||||
function punchCard(id, punchcardSeries) {
|
||||
Highcharts.chart(id, {
|
||||
chart: {
|
||||
defaultSeriesType: 'scatter'
|
||||
},
|
||||
xAxis: {
|
||||
type: 'datetime',
|
||||
dateTimeLabelFormats: {
|
||||
hour: '%I %P'
|
||||
},
|
||||
tickInterval: 3600000
|
||||
},
|
||||
yAxis: {
|
||||
categories: ['Monday','Tuesday','Wednesday','Thursday','Friday','Saturday','Sunday'],
|
||||
},
|
||||
tooltip: {
|
||||
pointFormat: 'Activity: {point.z}'
|
||||
},
|
||||
series: [punchcardSeries]
|
||||
});
|
||||
}
|
59
Plan/src/main/resources/js/resourceGraph.js
Normal file
59
Plan/src/main/resources/js/resourceGraph.js
Normal file
@ -0,0 +1,59 @@
|
||||
function resourceChart(id, cpuSeries, ramSeries) {
|
||||
var myChart = Highcharts.stockChart(id, {
|
||||
rangeSelector: {
|
||||
selected: 1,
|
||||
buttons: [{
|
||||
type: 'hour',
|
||||
count: 12,
|
||||
text: '12h'
|
||||
},{
|
||||
type: 'hour',
|
||||
count: 24,
|
||||
text: '24h'
|
||||
},{
|
||||
type: 'day',
|
||||
count: 7,
|
||||
text: '7d'
|
||||
},{
|
||||
type: 'month',
|
||||
count: 1,
|
||||
text: '30d'
|
||||
},{
|
||||
type: 'all',
|
||||
text: 'All'
|
||||
}]
|
||||
},
|
||||
yAxis: [{
|
||||
labels: {
|
||||
align: 'right',
|
||||
x: -3
|
||||
},
|
||||
title: {
|
||||
text: 'CPU / %'
|
||||
},
|
||||
height: '55%',
|
||||
lineWidth: 2
|
||||
}, {
|
||||
labels: {
|
||||
align: 'right',
|
||||
x: -3
|
||||
},
|
||||
title: {
|
||||
text: 'RAM / MB'
|
||||
},
|
||||
top: '55%',
|
||||
height: '40%',
|
||||
offset: 0,
|
||||
lineWidth: 2
|
||||
}],
|
||||
tooltip: {
|
||||
split: true
|
||||
},
|
||||
plotOptions: {
|
||||
areaspline: {
|
||||
fillOpacity: 0.4
|
||||
}
|
||||
},
|
||||
series: [cpuSeries, ramSeries]
|
||||
});
|
||||
}
|
29
Plan/src/main/resources/js/sessionDistributionChart.js
Normal file
29
Plan/src/main/resources/js/sessionDistributionChart.js
Normal file
@ -0,0 +1,29 @@
|
||||
function sessionDistributionChart(id, sessionLengthSeries) {
|
||||
Highcharts.chart(id, {
|
||||
chart: {
|
||||
type: 'column'
|
||||
},
|
||||
xAxis: {
|
||||
type: 'category',
|
||||
labels: {
|
||||
rotation: -45
|
||||
}
|
||||
},
|
||||
yAxis: {
|
||||
min: 0,
|
||||
title: {
|
||||
text: 'Sessions'
|
||||
}
|
||||
},
|
||||
legend: {
|
||||
enabled: false
|
||||
},
|
||||
plotOptions: {
|
||||
series: {
|
||||
groupPadding: 0
|
||||
},
|
||||
pointPadding: 0
|
||||
},
|
||||
series: [sessionLengthSeries]
|
||||
});
|
||||
}
|
8
Plan/src/main/resources/js/sessionTabExpand.js
Normal file
8
Plan/src/main/resources/js/sessionTabExpand.js
Normal file
@ -0,0 +1,8 @@
|
||||
$(".session-header").click(function () {
|
||||
$header = $(this);
|
||||
$content = $header.next();
|
||||
$(this).parent().siblings().children().next().slideUp(500);
|
||||
$content.slideToggle(500, function () {
|
||||
//execute this after slideToggle is done
|
||||
});
|
||||
});
|
59
Plan/src/main/resources/js/tpsGraph.js
Normal file
59
Plan/src/main/resources/js/tpsGraph.js
Normal file
@ -0,0 +1,59 @@
|
||||
function tpsChart(id, tpsSeries, playersOnlineSeries) {
|
||||
var myChart = Highcharts.stockChart(id, {
|
||||
rangeSelector: {
|
||||
selected: 1,
|
||||
buttons: [{
|
||||
type: 'hour',
|
||||
count: 12,
|
||||
text: '12h'
|
||||
},{
|
||||
type: 'hour',
|
||||
count: 24,
|
||||
text: '24h'
|
||||
},{
|
||||
type: 'day',
|
||||
count: 7,
|
||||
text: '7d'
|
||||
},{
|
||||
type: 'month',
|
||||
count: 1,
|
||||
text: '30d'
|
||||
},{
|
||||
type: 'all',
|
||||
text: 'All'
|
||||
}]
|
||||
},
|
||||
yAxis: [{
|
||||
labels: {
|
||||
align: 'right',
|
||||
x: -3
|
||||
},
|
||||
title: {
|
||||
text: 'Players'
|
||||
},
|
||||
height: '30%',
|
||||
}, {
|
||||
lineWidth: 2,
|
||||
labels: {
|
||||
align: 'right',
|
||||
x: -3
|
||||
},
|
||||
title: {
|
||||
text: 'TPS'
|
||||
},
|
||||
height: '70%',
|
||||
top: '30%',
|
||||
offset: 0,
|
||||
lineWidth: 2
|
||||
}],
|
||||
tooltip: {
|
||||
split: true
|
||||
},
|
||||
plotOptions: {
|
||||
areaspline: {
|
||||
fillOpacity: 0.4
|
||||
}
|
||||
},
|
||||
series: [tpsSeries, playersOnlineSeries]
|
||||
});
|
||||
}
|
59
Plan/src/main/resources/js/worldGraph.js
Normal file
59
Plan/src/main/resources/js/worldGraph.js
Normal file
@ -0,0 +1,59 @@
|
||||
function worldChart(id, entitySeries, chunkSeries) {
|
||||
var myChart = Highcharts.stockChart(id, {
|
||||
rangeSelector: {
|
||||
selected: 1,
|
||||
buttons: [{
|
||||
type: 'hour',
|
||||
count: 12,
|
||||
text: '12h'
|
||||
},{
|
||||
type: 'hour',
|
||||
count: 24,
|
||||
text: '24h'
|
||||
},{
|
||||
type: 'day',
|
||||
count: 7,
|
||||
text: '7d'
|
||||
},{
|
||||
type: 'month',
|
||||
count: 1,
|
||||
text: '30d'
|
||||
},{
|
||||
type: 'all',
|
||||
text: 'All'
|
||||
}]
|
||||
},
|
||||
yAxis: [{
|
||||
labels: {
|
||||
align: 'right',
|
||||
x: -3
|
||||
},
|
||||
title: {
|
||||
text: 'Chunks'
|
||||
},
|
||||
height: '50%',
|
||||
lineWidth: 2
|
||||
}, {
|
||||
labels: {
|
||||
align: 'right',
|
||||
x: -3
|
||||
},
|
||||
title: {
|
||||
text: 'Entities'
|
||||
},
|
||||
top: '50%',
|
||||
height: '40%',
|
||||
offset: 0,
|
||||
lineWidth: 2
|
||||
}],
|
||||
tooltip: {
|
||||
split: true
|
||||
},
|
||||
plotOptions: {
|
||||
areaspline: {
|
||||
fillOpacity: 0.4
|
||||
}
|
||||
},
|
||||
series: [entitySeries, chunkSeries]
|
||||
});
|
||||
}
|
14
Plan/src/main/resources/js/worldMap.js
Normal file
14
Plan/src/main/resources/js/worldMap.js
Normal file
@ -0,0 +1,14 @@
|
||||
function worldMap(id, colorMin, colorMax, mapSeries) {
|
||||
var myChart = Highcharts.mapChart(id, {
|
||||
chart: {
|
||||
animation: true
|
||||
},
|
||||
colorAxis: {
|
||||
min: 1,
|
||||
type: 'logarithmic',
|
||||
minColor: colorMin,
|
||||
maxColor: colorMax
|
||||
},
|
||||
series: [mapSeries]
|
||||
});
|
||||
}
|
25
Plan/src/main/resources/js/worldPie.js
Normal file
25
Plan/src/main/resources/js/worldPie.js
Normal file
@ -0,0 +1,25 @@
|
||||
function worldPie(id, worldSeries, worldTotal) {
|
||||
var myChart = Highcharts.chart(id, {
|
||||
chart: {
|
||||
plotBackgroundColor: null,
|
||||
plotBorderWidth: null,
|
||||
plotShadow: false,
|
||||
type: 'pie'
|
||||
},
|
||||
subtitle: {text: worldTotal},
|
||||
tooltip: {
|
||||
pointFormat: '{series.name}: <b>{point.percentage:.2f}%</b>'
|
||||
},
|
||||
plotOptions: {
|
||||
pie: {
|
||||
allowPointSelect: true,
|
||||
cursor: 'pointer',
|
||||
dataLabels: {
|
||||
enabled: false
|
||||
},
|
||||
showInLegend: true
|
||||
}
|
||||
},
|
||||
series: [worldSeries]
|
||||
});
|
||||
}
|
327
Plan/src/main/resources/main.css
Normal file
327
Plan/src/main/resources/main.css
Normal file
@ -0,0 +1,327 @@
|
||||
.black {
|
||||
color: #000000;
|
||||
}
|
||||
.darkblue {
|
||||
color: #0000AA;
|
||||
}
|
||||
.darkgreen {
|
||||
color: #00AA00;
|
||||
}
|
||||
.darkaqua {
|
||||
color: #00AAAA;
|
||||
}
|
||||
.darkred {
|
||||
color: #AA0000;
|
||||
}
|
||||
.darkpurple {
|
||||
color: #AA00AA;
|
||||
}
|
||||
.gold {
|
||||
color: #FFAA00;
|
||||
}
|
||||
.gray {
|
||||
color: #AAAAAA;
|
||||
}
|
||||
.darkgray {
|
||||
color: #555555;
|
||||
}
|
||||
.blue {
|
||||
color: #5555FF;
|
||||
}
|
||||
.green {
|
||||
color: #55FF55;
|
||||
}
|
||||
.aqua {
|
||||
color: #55FFFF;
|
||||
}
|
||||
.red {
|
||||
color: #FF5555;
|
||||
}
|
||||
.pink {
|
||||
color: #FF55FF;
|
||||
}
|
||||
.yellow {
|
||||
color: #FFFF55;
|
||||
text-shadow: 0px 0px 6px #000;
|
||||
}
|
||||
.white {
|
||||
color: #FFFFFF;
|
||||
text-shadow: 0px 0px 8px #000;
|
||||
}
|
||||
|
||||
body {
|
||||
font-family: 'Quicksand', sans-serif;
|
||||
background-color: #ddd;
|
||||
color: #fff;
|
||||
font-weight: 400;
|
||||
}
|
||||
header {
|
||||
position: fixed;
|
||||
top: 0;
|
||||
left: 0;
|
||||
width: 100%;
|
||||
height: 80px;
|
||||
padding: 0;
|
||||
background-color: #348e0f;
|
||||
z-index: 1;
|
||||
}
|
||||
header h1 {
|
||||
font-weight: 500;
|
||||
font-size: 55px;
|
||||
margin-top: 0px;
|
||||
margin-bottom: 0px;
|
||||
margin-left: 10px;
|
||||
}
|
||||
header p {
|
||||
font-weight: 400;
|
||||
}
|
||||
header div {
|
||||
padding: 5pxpx 20px;
|
||||
}
|
||||
|
||||
.right {
|
||||
float: right;
|
||||
}
|
||||
.left {
|
||||
float: left;
|
||||
}
|
||||
.button {
|
||||
background-color: #5da341;
|
||||
text-decoration: none!important;
|
||||
color: #fff;
|
||||
padding: 10px 20px;
|
||||
text-align: center;
|
||||
}
|
||||
.button:hover {
|
||||
background-color: #348e0f;
|
||||
}
|
||||
.link {
|
||||
color: #5da341;
|
||||
text-decoration: none!important;
|
||||
}
|
||||
.button:hover {
|
||||
background-color: #348e0f;
|
||||
}
|
||||
.disabled {
|
||||
background-color: #89c471;
|
||||
}
|
||||
.disabled:hover {
|
||||
background-color: #89c471;
|
||||
}
|
||||
|
||||
.content {
|
||||
margin-top: 100px;
|
||||
margin-left: 15%;
|
||||
margin-right: 15%;
|
||||
width: 70%;
|
||||
}
|
||||
.content-server {
|
||||
margin-top: 100px;
|
||||
margin-left: 10%;
|
||||
margin-right: 10%;
|
||||
width: 80%;
|
||||
}
|
||||
.box-header {
|
||||
color: #fff;
|
||||
background-color: #5da341;
|
||||
padding: 5px 20px;
|
||||
text-align: left;
|
||||
margin: 5px 5px 0px 5px;
|
||||
}
|
||||
.box {
|
||||
background-color: #fff;
|
||||
padding: 5px 20px;
|
||||
color: #000;
|
||||
text-align: left;
|
||||
margin: 0px 5px;
|
||||
}
|
||||
.box-footer {
|
||||
vertical-align: middle;
|
||||
display: inline-block;
|
||||
background-color: #fff;
|
||||
padding: 5px 10px 5px 20px;
|
||||
color: #000;
|
||||
text-align: left;
|
||||
margin: 2px 5px 5px 5px;
|
||||
}
|
||||
.box-footer p {
|
||||
display: inline-block;
|
||||
}
|
||||
.box-footer a {
|
||||
margin-top: 5px;
|
||||
display: inline-block;
|
||||
}
|
||||
.plugin {
|
||||
max-height: 300px;
|
||||
overflow-y: auto;
|
||||
height: 100%;
|
||||
}
|
||||
.row {
|
||||
width: 100%;
|
||||
display: flex;
|
||||
flex-direction: row;
|
||||
}
|
||||
.column {
|
||||
width: 100%;
|
||||
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
}
|
||||
|
||||
.nav-bar {
|
||||
|
||||
}
|
||||
.nav-button {
|
||||
font-size: 20px;
|
||||
font-weight: 400;
|
||||
padding: 5px 10px;
|
||||
margin: 5px;
|
||||
text-decoration: none!important;
|
||||
color: #fff;
|
||||
background-color: #5da341;
|
||||
}
|
||||
.nav-button:hover {
|
||||
background-color: #348e0f;
|
||||
}
|
||||
.active {
|
||||
background-color: #348e0f;
|
||||
}
|
||||
|
||||
table {
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
thead th {
|
||||
color: #fff;
|
||||
background-color: #5da341;
|
||||
font-weight: 600;
|
||||
}
|
||||
th {
|
||||
padding: 5px;
|
||||
font-weight: 400;
|
||||
}
|
||||
th.text {
|
||||
font-size: 120%;
|
||||
}
|
||||
tr:nth-child(even) {background: #e2e2e2}
|
||||
tr:nth-child(odd) {background: #eee}
|
||||
|
||||
|
||||
.main-limiter {
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
overflow: hidden;
|
||||
}
|
||||
|
||||
.main-wrapper {
|
||||
transform: translate3d(0, 0, 0);
|
||||
opacity: 0;
|
||||
transition: 1.5s;
|
||||
width: 100%;
|
||||
display: flex;
|
||||
flex-direction: row;
|
||||
}
|
||||
.tab {
|
||||
width: 20%;
|
||||
height: 100%;
|
||||
display: flex;
|
||||
align-content: flex-start;
|
||||
}
|
||||
|
||||
.scrollbar {
|
||||
max-height: 650px;
|
||||
overflow-y: auto;
|
||||
}
|
||||
|
||||
.session-header h3 {
|
||||
margin: 0px;
|
||||
}
|
||||
.session-header p {
|
||||
margin: 0px;
|
||||
}
|
||||
.session {
|
||||
|
||||
}
|
||||
|
||||
.session-header {
|
||||
background: #ddd;
|
||||
color: #000;
|
||||
margin: 1px 3px;
|
||||
display: flex;
|
||||
flex-direction: row;
|
||||
padding: 0px;
|
||||
}
|
||||
|
||||
.session-col {
|
||||
width: 100%;
|
||||
background: #fff;
|
||||
color: #000;
|
||||
margin: 0px 2px;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
padding: 10px 20px;
|
||||
}
|
||||
|
||||
.session-content {
|
||||
display: none;
|
||||
margin: 2px 10px;
|
||||
flex-direction: row;
|
||||
}
|
||||
|
||||
.plugins-content {
|
||||
display: none;
|
||||
}
|
||||
.plugins-header h2 {
|
||||
margin: 0px;
|
||||
}
|
||||
.plugins-header p {
|
||||
margin: 0px;
|
||||
}
|
||||
|
||||
@media only screen and (max-width: 1680px) {
|
||||
.nav-button {
|
||||
font-size: 19px;
|
||||
}
|
||||
}
|
||||
@media only screen and (max-width: 1150px) {
|
||||
header h1 {
|
||||
font-weight: 400;
|
||||
font-size: 40px;
|
||||
}
|
||||
.content {
|
||||
margin-top: 100px;
|
||||
margin-left: 0%;
|
||||
margin-right: 0%;
|
||||
width: 100%;
|
||||
}
|
||||
.content-server {
|
||||
margin-top: 100px;
|
||||
margin-left: 0%;
|
||||
margin-right: 0%;
|
||||
width: 100%;
|
||||
}
|
||||
.nav-bar {
|
||||
flex-wrap:wrap;
|
||||
}
|
||||
}
|
||||
@media only screen and (max-width: 850px) {
|
||||
header h1 {
|
||||
font-weight: 400;
|
||||
font-size: 30px;
|
||||
}
|
||||
}
|
||||
@media only screen and (max-width: 780px) {
|
||||
.scrollbar {
|
||||
overflow-x: auto;
|
||||
width: 100%;
|
||||
}
|
||||
.nav-bar {
|
||||
flex-direction: row;
|
||||
}
|
||||
.row {
|
||||
flex-direction: column;
|
||||
}
|
||||
header p {
|
||||
display: none;
|
||||
}
|
||||
}
|
@ -1,779 +0,0 @@
|
||||
<!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<title>Plan | Inspect %name%</title>
|
||||
<meta name="description" content="Player Analysis window">
|
||||
<meta name="author" content="Rsl1122">
|
||||
<link rel="icon" href="https://puu.sh/tK0KL/6aa2ba141b.ico" type="image/x-icon"/>
|
||||
<script src="https://use.fontawesome.com/df48eb908b.js"></script>
|
||||
<style>
|
||||
header {
|
||||
position: fixed;
|
||||
top: 0;
|
||||
left: 0;
|
||||
width: 100%;
|
||||
height: 88px;
|
||||
padding: 0;
|
||||
background-color: #348e0f;
|
||||
z-index: 1;
|
||||
}
|
||||
.header-content {
|
||||
padding: 5px 20px;
|
||||
}
|
||||
body {
|
||||
font-family: Verdana, sans-serif;
|
||||
background-color: #ddd;
|
||||
color: #fff;
|
||||
}
|
||||
.sidenav {
|
||||
height: 100%;
|
||||
width: 15%;
|
||||
position: fixed;
|
||||
top: 0;
|
||||
left: 0;
|
||||
background-color: #5cb239;
|
||||
overflow-x: hidden;
|
||||
transition: 0.5s;
|
||||
padding-top: 88px;
|
||||
text-align: left;
|
||||
}
|
||||
.sidenav p {
|
||||
width: 100%;
|
||||
padding: 8px 8px 8px 16px;
|
||||
text-decoration: none;
|
||||
background-color: #89c471;
|
||||
color: #fff;
|
||||
margin: 10px 0;
|
||||
}
|
||||
|
||||
.sidenav a {
|
||||
margin: 10px 0;
|
||||
width: 100%;
|
||||
padding: 8px 8px 8px 16px;
|
||||
text-decoration: none;
|
||||
background-color: #89c471;
|
||||
font-size: 22px;
|
||||
color: #fff;
|
||||
display: block;
|
||||
transition: 0.3s;
|
||||
z-index: 1;
|
||||
}
|
||||
|
||||
.sidenav a.active {
|
||||
background-color: #5da341
|
||||
}
|
||||
|
||||
.sidenav a:hover, .offcanvas a:focus{
|
||||
background-color: #5da341;
|
||||
}
|
||||
|
||||
.main-limiter {
|
||||
margin-left: 15%;
|
||||
width: 85%;
|
||||
height: 100%;
|
||||
overflow: hidden;
|
||||
}
|
||||
|
||||
.main-wrapper {
|
||||
padding-top: 88px;
|
||||
transform: translate3d(0, 0, 0);
|
||||
opacity: 0;
|
||||
transition: 1.5s;
|
||||
}
|
||||
|
||||
.box {
|
||||
background-color: #fff;
|
||||
padding: 5px;
|
||||
text-decoration: none;
|
||||
color: #000;
|
||||
text-align: left;
|
||||
margin: 5px;
|
||||
}
|
||||
|
||||
.box p {
|
||||
color: #000;
|
||||
}
|
||||
|
||||
.tab {
|
||||
width: 20%;
|
||||
height: 100%;
|
||||
float: left;
|
||||
display: flex;
|
||||
text-align: left;
|
||||
align-content: flex-start;
|
||||
}
|
||||
.row {
|
||||
width: 50%;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
}
|
||||
.content {
|
||||
text-align: center;
|
||||
padding: 5px;
|
||||
margin: 0;
|
||||
}
|
||||
|
||||
.columns {
|
||||
display: flex;
|
||||
}
|
||||
|
||||
.column {
|
||||
flex: 1;
|
||||
}
|
||||
|
||||
.infobox {
|
||||
margin-left: 3px;
|
||||
color: white;
|
||||
background-color: #348e0f;
|
||||
padding: 8px 14px;
|
||||
border-radius: 10px;
|
||||
float: right;
|
||||
}
|
||||
.info-text {
|
||||
float: right;
|
||||
width: 50%;
|
||||
text-align: right;
|
||||
}
|
||||
.info-number {
|
||||
font-size: x-large;
|
||||
float: right;
|
||||
}
|
||||
.info-label {
|
||||
float: right;
|
||||
font-size: medium;
|
||||
}
|
||||
.info-icon {
|
||||
font-size: xx-large;
|
||||
float: left;
|
||||
}
|
||||
.headerbox {
|
||||
color: #348e0f;
|
||||
display: inline-block;
|
||||
border: solid #348e0f;
|
||||
padding: 8px 14px;
|
||||
border-radius: 10px;
|
||||
width: 95%;
|
||||
}
|
||||
.header-icon {
|
||||
font-size: xx-large;
|
||||
float: left;
|
||||
}
|
||||
.header-text {
|
||||
font-size: x-large;
|
||||
}
|
||||
.header-label {
|
||||
padding: 0;
|
||||
margin: 0;
|
||||
border: 0;
|
||||
}
|
||||
|
||||
.table {
|
||||
border-collapse: collapse;
|
||||
table-layout: fixed;
|
||||
border: 1px solid;
|
||||
padding: 8px 14px;
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
.link {
|
||||
color: #348e0f;
|
||||
text-decoration:none!important;
|
||||
}
|
||||
.link:hover {
|
||||
color: #267F00;
|
||||
}
|
||||
table.sortable thead {
|
||||
background-color: #348e0f;
|
||||
color:#fff;
|
||||
font-weight: bold;
|
||||
cursor: default;
|
||||
width: 100%;
|
||||
overflow: hidden;
|
||||
}
|
||||
table.sortable tbody {
|
||||
color: #000;
|
||||
}
|
||||
table.sortable th:not(.sorttable_sorted):not(.sorttable_sorted_reverse):not(.sorttable_nosort):after {
|
||||
content: " \25B4\25BE"
|
||||
}
|
||||
.plugin-container {
|
||||
color: #000;
|
||||
height: 100%;
|
||||
max-height: 400px;
|
||||
overflow: auto;
|
||||
}
|
||||
.plugin-data {
|
||||
color: #000;
|
||||
}
|
||||
.black {
|
||||
color: #000000;
|
||||
}
|
||||
.darkblue {
|
||||
color: #0000AA;
|
||||
}
|
||||
.darkgreen {
|
||||
color: #00AA00;
|
||||
}
|
||||
.darkaqua {
|
||||
color: #00AAAA;
|
||||
}
|
||||
.darkred {
|
||||
color: #AA0000;
|
||||
}
|
||||
.darkpurple {
|
||||
color: #AA00AA;
|
||||
}
|
||||
.gold {
|
||||
color: #FFAA00;
|
||||
}
|
||||
.gray {
|
||||
color: #AAAAAA;
|
||||
}
|
||||
.darkgray {
|
||||
color: #555555;
|
||||
}
|
||||
.blue {
|
||||
color: #5555FF;
|
||||
}
|
||||
.green {
|
||||
color: #55FF55;
|
||||
}
|
||||
.aqua {
|
||||
color: #55FFFF;
|
||||
}
|
||||
.red {
|
||||
color: #FF5555;
|
||||
}
|
||||
.pink {
|
||||
color: #FF55FF;
|
||||
}
|
||||
.yellow {
|
||||
color: #FFFF55;
|
||||
}
|
||||
.white {
|
||||
color: #FFFFFF;
|
||||
}
|
||||
#navbutton {
|
||||
display: none;
|
||||
font-size: 40px;
|
||||
cursor:pointer;
|
||||
}
|
||||
@media only screen and (max-width: 850px) {
|
||||
#navbutton {
|
||||
display: inline;
|
||||
}
|
||||
.sidenav p {
|
||||
display: none;
|
||||
}
|
||||
header {
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
}
|
||||
header h1 {
|
||||
margin: 0;
|
||||
}
|
||||
header img {
|
||||
margin: 0px;
|
||||
padding: 0;
|
||||
}
|
||||
header p {
|
||||
margin: 5px 0px 0px;
|
||||
}
|
||||
.tab {
|
||||
flex-direction: column;
|
||||
}
|
||||
.columns {
|
||||
flex-direction: column;
|
||||
}
|
||||
.row {
|
||||
width: 100%;
|
||||
}
|
||||
.sidenav {
|
||||
width: 0;
|
||||
transition: 0s;
|
||||
}
|
||||
.main-limiter {
|
||||
margin-left: 0;
|
||||
width: 100%;
|
||||
}
|
||||
}
|
||||
|
||||
</style>
|
||||
</head>
|
||||
<body>
|
||||
<header>
|
||||
<div class="header-content">
|
||||
<img style="float: right; padding: 5px" src="https://puu.sh/tJZUb/c2e0ab220f.png"
|
||||
alt="Player Analytics | Analysis">
|
||||
<p style="float: right; text-align: right;">Player Analytics v.%version%</p>
|
||||
<h1><span id="navbutton" onclick="openNav()">☰ </span>%servername% | Inspect Player %name%%op%</h1>
|
||||
</div>
|
||||
</header>
|
||||
<div id="content" class="content">
|
||||
<div id="sidenav" class="sidenav">
|
||||
<p>Last Refresh: <br><span id="divTime">%refresh%</span> ago</p>
|
||||
<a href="javascript:void(0)" class="nav-button">
|
||||
<i class="fa fa-info-circle" aria-hidden="true"></i> Information
|
||||
</a>
|
||||
<a href="javascript:void(0)" class="nav-button">
|
||||
<i class="fa fa-calendar" aria-hidden="true"></i> Sessions
|
||||
</a>
|
||||
<a href="javascript:void(0)" class="nav-button">
|
||||
<i class="fa fa-cubes" aria-hidden="true"></i> Plugins
|
||||
</a>
|
||||
</div>
|
||||
<div id="limiter" class="main-limiter">
|
||||
<div id="main" class="main-wrapper">
|
||||
<div class="tab">
|
||||
<div class="row">
|
||||
<div class="about box column">
|
||||
<div class="headerbox">
|
||||
<div class="header-icon">
|
||||
<div class="header-label"><i class="fa fa-info-circle" aria-hidden="true"></i><span
|
||||
class="header-text"> Information</span></div>
|
||||
</div>
|
||||
<div class="infobox" style="float: right;">
|
||||
<div class="info-icon">
|
||||
<i class="fa fa-user-plus" aria-hidden="true"></i>
|
||||
</div>
|
||||
<div class="info-text" style="width: 70%;">
|
||||
<div class="info-number">
|
||||
%registered%
|
||||
</div>
|
||||
<div class="info-label">
|
||||
Registered
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<img style="float: right; padding: 5px" alt="%name%"
|
||||
src="https://cravatar.eu/head/%name%/128.png">
|
||||
<p><i class="fa fa-user" aria-hidden="true"></i> %active% %isonline%%banned%<br/>
|
||||
<i class="fa fa-address-card-o" aria-hidden="true"></i> Nicknames: %nicknames%<br/>
|
||||
<i class="fa fa-clock-o" aria-hidden="true"></i> Playtime: %playtime%<br/>
|
||||
<i class="fa fa-calendar-plus-o" aria-hidden="true"></i> Login times: %logintimes%<br/>
|
||||
<i class="fa fa-gavel" aria-hidden="true"></i> Times kicked: %timeskicked%<br/>
|
||||
<i class="fa fa-crosshairs" aria-hidden="true"></i> Player kills: %playerkills% | <i
|
||||
class="fa fa-crosshairs" aria-hidden="true"></i> Mob kills: %mobkills% | <i
|
||||
class="fa fa-meh-o" aria-hidden="true"></i> Deaths: %deaths%<br/>
|
||||
<br/>
|
||||
<i class="fa fa-globe" aria-hidden="true"></i> Geolocation: %geoloc%<br/>
|
||||
<i class="fa fa-tag" aria-hidden="true"></i> UUID: %uuid%<br/>
|
||||
<i class="fa fa-globe" aria-hidden="true"></i> Has Connected from ips: %ips%</p>
|
||||
</div>
|
||||
<div class="about box column">
|
||||
<div id="worldPie" style="width: 100%; height: 400px;"></div>
|
||||
</div>
|
||||
<div class="about box column">
|
||||
<div id="gmPie" style="width: 100%; height: 400px;"></div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="about box column">
|
||||
<div class="headerbox">
|
||||
<div class="header-icon">
|
||||
<div class="header-label"><i class="fa fa-bar-chart" aria-hidden="true"></i><span
|
||||
class="header-text"> Player Activity: 7d</span></div>
|
||||
</div>
|
||||
<div class="infobox" style="float: right;">
|
||||
<div class="info-icon">
|
||||
<i class="fa fa-calendar-check-o" aria-hidden="true"></i>
|
||||
</div>
|
||||
<div class="info-text" style="width: 70%;">
|
||||
<div class="info-number">
|
||||
%lastseen%
|
||||
</div>
|
||||
<div class="info-label">
|
||||
Last seen
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div id="playerChart" style="width:100%; height:350px;"></div>
|
||||
</div>
|
||||
<div class="about box column">
|
||||
<div class="headerbox">
|
||||
<div class="header-icon">
|
||||
<div class="header-label"><i class="fa fa-crosshairs" aria-hidden="true"></i><span
|
||||
class="header-text"> Last 25 Kills</span></div>
|
||||
</div>
|
||||
<div class="infobox" style="float: right;">
|
||||
<div class="info-icon">
|
||||
<i class="fa fa-crosshairs" aria-hidden="true"></i>
|
||||
</div>
|
||||
<div class="info-text" style="width: 70%;">
|
||||
<div class="info-number">
|
||||
%playerkills%
|
||||
</div>
|
||||
<div class="info-label">
|
||||
Player Kills
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
%killstable%
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="tab">
|
||||
<div class="row">
|
||||
<div class="about box column">
|
||||
<div class="headerbox">
|
||||
<div class="header-icon" style="width: 50%">
|
||||
<div class="header-label"><i class="fa fa-braille" aria-hidden="true"></i><span
|
||||
class="header-text"> PunchCard</span></div>
|
||||
</div>
|
||||
<div class="infobox">
|
||||
<div class="info-icon">
|
||||
<i class="fa fa-calendar-plus-o" aria-hidden="true"></i>
|
||||
</div>
|
||||
<div class="info-text" style="width: 70%;">
|
||||
<div class="info-number">
|
||||
%logintimes%
|
||||
</div>
|
||||
<div class="info-label">
|
||||
Login Times
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div id="punchcard" style="width: 100%; height:400px;"></div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="about box column">
|
||||
<div class="headerbox">
|
||||
<div class="header-icon">
|
||||
<div class="header-label"><i class="fa fa-bar-chart" aria-hidden="true"></i><span
|
||||
class="header-text"> Length Distribution</span></div>
|
||||
</div>
|
||||
<div class="infobox">
|
||||
<div class="info-icon">
|
||||
<i class="fa fa-clock-o" aria-hidden="true"></i>
|
||||
</div>
|
||||
<div class="info-text" style="width: 70%;">
|
||||
<div class="info-number">
|
||||
%sessionaverage%
|
||||
</div>
|
||||
<div class="info-label">
|
||||
Average Length
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div id="sessionDistribution" style="width: 100%; height:400px;"></div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="tab" style="display: block;">
|
||||
%plugins%
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<script src="https://www.kryogenix.org/code/browser/sorttable/sorttable.js"></script>
|
||||
<script src="https://code.highcharts.com/stock/highstock.js"></script>
|
||||
<script>
|
||||
Highcharts.setOptions({
|
||||
global: {
|
||||
timezoneOffset: %timezone% * 60
|
||||
}
|
||||
});
|
||||
function formatTime(seconds) {
|
||||
var out = "";
|
||||
seconds = Math.floor(seconds / 1000);
|
||||
|
||||
var dd = Math.floor(seconds / 86400);
|
||||
seconds -= (dd * 86400);
|
||||
|
||||
var dh = Math.floor(seconds / 3600);
|
||||
seconds -= (dh * 3600);
|
||||
|
||||
var dm = Math.floor(seconds / 60);
|
||||
seconds -= (dm * 60);
|
||||
|
||||
seconds = Math.floor(seconds);
|
||||
|
||||
if (dd !== 0) {
|
||||
out += dd.toString() + "d ";
|
||||
}
|
||||
if (dh !== 0) {
|
||||
out += dh.toString() + "h ";
|
||||
}
|
||||
if (dm !== 0) {
|
||||
out += dm.toString() + "m ";
|
||||
}
|
||||
out += seconds.toString() + "s ";
|
||||
return out;
|
||||
}
|
||||
var playersOnlineSeries = {
|
||||
name: 'Online',
|
||||
data: %playersonlineseries%,
|
||||
type: 'areaspline',
|
||||
color: '#%playersgraphcolor%',
|
||||
tooltip: {
|
||||
valueDecimals: 0
|
||||
}
|
||||
};
|
||||
var gmData = %gmdata%;
|
||||
var gmSeries = {
|
||||
name: 'GM Usage',
|
||||
colorByPoint: true,
|
||||
data: [{
|
||||
name: 'Survival',
|
||||
y: gmData[0],
|
||||
sliced: true,
|
||||
selected: true
|
||||
}, {
|
||||
name: 'Creative',
|
||||
y: gmData[1]
|
||||
}, {
|
||||
name: 'Adventure',
|
||||
y: gmData[2]
|
||||
}, {
|
||||
name: 'Spectator',
|
||||
y: gmData[3]
|
||||
}]
|
||||
};
|
||||
var worldSeries = {
|
||||
name: 'World Playtime',
|
||||
colorByPoint: true,
|
||||
data: %worldseries%
|
||||
};
|
||||
var sessionLengthSeries = {
|
||||
name: 'Sessions',
|
||||
color: '#89c471',
|
||||
data: %sessionlengthseries%
|
||||
};
|
||||
var punchcardSeries = {
|
||||
name: 'Relative Activity',
|
||||
color: '#222',
|
||||
data: %punchcardseries%
|
||||
};
|
||||
</script>
|
||||
<script>
|
||||
function playersChart() {
|
||||
Highcharts.stockChart('playerChart', {
|
||||
rangeSelector: {
|
||||
selected: 2,
|
||||
buttons: [{
|
||||
type: 'hour',
|
||||
count: 12,
|
||||
text: '12h'
|
||||
},{
|
||||
type: 'hour',
|
||||
count: 24,
|
||||
text: '24h'
|
||||
},{
|
||||
type: 'day',
|
||||
count: 7,
|
||||
text: '7d'
|
||||
},{
|
||||
type: 'month',
|
||||
count: 1,
|
||||
text: '30d'
|
||||
},{
|
||||
type: 'all',
|
||||
text: 'All'
|
||||
}]
|
||||
},
|
||||
plotOptions: {
|
||||
areaspline: {
|
||||
fillOpacity: 0.4
|
||||
}
|
||||
},
|
||||
title: {text: 'Online Activity'},
|
||||
series: [playersOnlineSeries]
|
||||
});
|
||||
}
|
||||
</script>
|
||||
<script>
|
||||
function gmPie() {
|
||||
Highcharts.chart('gmPie', {
|
||||
chart: {
|
||||
plotBackgroundColor: null, plotBorderWidth: null, plotShadow: false,
|
||||
type: 'pie'
|
||||
},
|
||||
title: {text: 'Gamemode Usage'},
|
||||
subtitle: {text: '%gmtotal%'},
|
||||
tooltip: {
|
||||
pointFormat: '{series.name}: <b>{point.percentage:.2f}%</b>'
|
||||
},
|
||||
plotOptions: {
|
||||
pie: {
|
||||
allowPointSelect: true,
|
||||
cursor: 'pointer',
|
||||
dataLabels: {
|
||||
enabled: false
|
||||
},
|
||||
colors: [%gmcolors%],
|
||||
showInLegend: true
|
||||
}
|
||||
},
|
||||
series: [gmSeries]
|
||||
});
|
||||
};
|
||||
</script>
|
||||
<script>
|
||||
function worldPie() {
|
||||
Highcharts.chart('worldPie', {
|
||||
chart: {
|
||||
plotBackgroundColor: null,
|
||||
plotBorderWidth: null,
|
||||
plotShadow: false,
|
||||
type: 'pie'
|
||||
},
|
||||
title: {text: 'World Playtime'},
|
||||
subtitle: {text: '%worldtotal%'},
|
||||
tooltip: {
|
||||
pointFormat: '{series.name}: <b>{point.percentage:.2f}%</b>'
|
||||
},
|
||||
plotOptions: {
|
||||
pie: {
|
||||
allowPointSelect: true,
|
||||
cursor: 'pointer',
|
||||
dataLabels: {
|
||||
enabled: false
|
||||
},
|
||||
showInLegend: true
|
||||
}
|
||||
},
|
||||
series: [worldSeries]
|
||||
});
|
||||
};
|
||||
|
||||
</script>
|
||||
<script>
|
||||
function punchCard() {
|
||||
Highcharts.chart('punchcard' , {
|
||||
chart: {
|
||||
defaultSeriesType: 'scatter'
|
||||
},
|
||||
title: {
|
||||
text: 'Player Join PunchCard'
|
||||
},
|
||||
xAxis: {
|
||||
type: 'datetime',
|
||||
dateTimeLabelFormats: {
|
||||
hour: '%I %P'
|
||||
},
|
||||
tickInterval: 3600000
|
||||
},
|
||||
yAxis: {
|
||||
categories: ['Monday','Tuesday','Wednesday','Thursday','Friday','Saturday','Sunday']
|
||||
},
|
||||
tooltip: {
|
||||
pointFormat: 'Activity: {point.z}'
|
||||
},
|
||||
series: [punchcardSeries]
|
||||
});
|
||||
}
|
||||
</script>
|
||||
<script>
|
||||
function sessionDistributionChart() {
|
||||
Highcharts.chart('sessionDistribution', {
|
||||
chart: {
|
||||
type: 'column'
|
||||
},
|
||||
title: {
|
||||
text: 'Session Length Distribution'
|
||||
},
|
||||
xAxis: {
|
||||
type: 'category',
|
||||
labels: {
|
||||
rotation: -45
|
||||
}
|
||||
},
|
||||
yAxis: {
|
||||
min: 0,
|
||||
title: {
|
||||
text: 'Sessions'
|
||||
}
|
||||
},
|
||||
legend: {
|
||||
enabled: false
|
||||
},
|
||||
plotOptions: {
|
||||
series: {
|
||||
groupPadding: 0
|
||||
},
|
||||
pointPadding: 0
|
||||
},
|
||||
series: [sessionLengthSeries]
|
||||
});
|
||||
};
|
||||
</script>
|
||||
<script>
|
||||
function openNav() {
|
||||
document.getElementById("sidenav").style.width = "100%";
|
||||
document.getElementById("limiter").style.display = "none";
|
||||
document.getElementById("navbutton").onclick = function () { closeNav(); };
|
||||
}
|
||||
function closeNav() {
|
||||
document.getElementById("sidenav").style.width = "0%";
|
||||
document.getElementById("limiter").style.display = "block";
|
||||
document.getElementById("navbutton").onclick = function () { openNav(); };
|
||||
}
|
||||
var navButtons = document.getElementsByClassName("nav-button");
|
||||
var tabs = document.getElementsByClassName("tab");
|
||||
var slideIndex = window.sessionStorage.getItem("InspectSlideIndex");
|
||||
if (slideIndex === null) {
|
||||
slideIndex = 0;
|
||||
}
|
||||
var x = document.getElementById("main");
|
||||
|
||||
x.style.transform = "translate3d(0px,0px,0)";
|
||||
x.style.width = ""+navButtons.length*100+"%";
|
||||
|
||||
for (var i = 0; i < navButtons.length; i++) {
|
||||
navButtons[i].onclick = openFunc(i)
|
||||
tabs[i].style.width = ""+100/navButtons.length+"%";
|
||||
}
|
||||
x.style.opacity = "1";
|
||||
openFunc(slideIndex)();
|
||||
|
||||
playersChart();
|
||||
sessionDistributionChart();
|
||||
gmPie();
|
||||
worldPie();
|
||||
punchCard();
|
||||
|
||||
countUpTimer();
|
||||
|
||||
function openFunc(i) {
|
||||
return function() {
|
||||
if (window.getComputedStyle(document.getElementById("navbutton")).getPropertyValue('display') === "inline") {
|
||||
closeNav();
|
||||
}
|
||||
var max = navButtons.length;
|
||||
for (var j = 0; j < max; j++) {
|
||||
if (j === i) {
|
||||
navButtons[j].classList.add('active');
|
||||
continue;
|
||||
}
|
||||
if (navButtons[j].classList.contains('active')) {
|
||||
navButtons[j].classList.remove('active');
|
||||
}
|
||||
}
|
||||
var perc = -100 / navButtons.length;
|
||||
slideIndex = i;
|
||||
if (slideIndex>max) {slideIndex=0};
|
||||
if (slideIndex<0) {slideIndex=max};
|
||||
window.sessionStorage.setItem("InspectSlideIndex", slideIndex);
|
||||
var value = slideIndex*perc;
|
||||
x.style.transition = "0.5s";
|
||||
x.style.transform = "translate3d("+value+"%,0px,0)";
|
||||
};
|
||||
}
|
||||
|
||||
function countUpTimer() {
|
||||
var now = new Date();
|
||||
var begin = new Date(%refreshlong%);
|
||||
var seconds = now.getTime() - begin.getTime();
|
||||
|
||||
document.getElementById('divTime').innerHTML = formatTime(seconds);
|
||||
setTimeout('countUpTimer()', 1000);
|
||||
}
|
||||
</script>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
@ -17,9 +17,7 @@ import test.java.utils.TestInit;
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
|
||||
import static org.junit.Assert.assertEquals;
|
||||
import static org.junit.Assert.assertFalse;
|
||||
import static org.junit.Assert.assertTrue;
|
||||
import static org.junit.Assert.*;
|
||||
|
||||
/**
|
||||
* @author Rsl1122
|
||||
@ -38,12 +36,12 @@ public class SettingsTest {
|
||||
|
||||
@Test
|
||||
public void testIsTrue() {
|
||||
assertTrue("Webserver supposed to be enabled by default", Settings.WEBSERVER_ENABLED.isTrue());
|
||||
assertTrue("COMBINE_COMMAND_ALIASES supposed to be true by default", Settings.COMBINE_COMMAND_ALIASES.isTrue());
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testIsTrue2() {
|
||||
Settings gatherCommands = Settings.GATHERCOMMANDS;
|
||||
Settings gatherCommands = Settings.LOG_UNKNOWN_COMMANDS;
|
||||
|
||||
gatherCommands.setValue(false);
|
||||
assertFalse(gatherCommands.isTrue());
|
||||
@ -54,7 +52,7 @@ public class SettingsTest {
|
||||
|
||||
@Test
|
||||
public void testToString() {
|
||||
assertEquals("sqlite", Settings.DB_TYPE.toString());
|
||||
assertEquals("SQLite", Settings.DB_TYPE.toString());
|
||||
}
|
||||
|
||||
@Test
|
||||
@ -72,6 +70,6 @@ public class SettingsTest {
|
||||
|
||||
@Test
|
||||
public void testGetPath() {
|
||||
assertEquals("Settings.WebServer.Enabled", Settings.WEBSERVER_ENABLED.getPath());
|
||||
assertEquals("WebServer.Port", Settings.WEBSERVER_PORT.getPath());
|
||||
}
|
||||
}
|
||||
|
@ -88,7 +88,7 @@ public class TestInit {
|
||||
when(planMock.getDataFolder()).thenReturn(testFolder);
|
||||
|
||||
// Html Files
|
||||
File analysis = new File(getClass().getResource("/analysis.html").getPath());
|
||||
File analysis = new File(getClass().getResource("/server.html").getPath());
|
||||
when(planMock.getResource("analysis.html")).thenReturn(new FileInputStream(analysis));
|
||||
File player = new File(getClass().getResource("/player.html").getPath());
|
||||
when(planMock.getResource("player.html")).thenReturn(new FileInputStream(player));
|
||||
|
Loading…
Reference in New Issue
Block a user