geforkt von SteamWar/BungeeCore
Add First Join
Dieser Commit ist enthalten in:
Ursprung
a19e5db5e6
Commit
eb9c7df29d
@ -64,6 +64,7 @@ public class WhoisCommand extends BasicCommand {
|
||||
BungeeCore.send(player, "§7Username§8: §e" + user.getUserName());
|
||||
BungeeCore.send(player, "§7UUID§8: §e" + user.getUuid().toString(), "", new ClickEvent(ClickEvent.Action.SUGGEST_COMMAND, user.getUuid().toString()));
|
||||
BungeeCore.send(player, "§7ID§8: §e" + user.getId());
|
||||
BungeeCore.send(player, "§7Beigetreten am§8: §e" + user.getFirstjoin().toString());
|
||||
BungeeCore.send(player, "§7Online Time§8: §e" + new DecimalFormat("###.##").format(user.getOnlinetime() / (double) 3600) + "h");
|
||||
|
||||
Team team = Team.get(user.getTeam());
|
||||
|
@ -244,4 +244,14 @@ public class SteamwarUser {
|
||||
}
|
||||
return 0;
|
||||
}
|
||||
|
||||
public Timestamp getFirstjoin() {
|
||||
ResultSet set = SQL.select("SELECT MIN(StartTime) AS FirstJoin FROM Session WHERE UserID = ?", id);
|
||||
try {
|
||||
set.next();
|
||||
return set.getTimestamp("FirstJoin");
|
||||
} catch (SQLException throwables) {
|
||||
throw new SecurityException("Could not load First Join");
|
||||
}
|
||||
}
|
||||
}
|
||||
|
In neuem Issue referenzieren
Einen Benutzer sperren