its probably so basic tier knowlage but im just supernew to skript and i read the docs and stuff i just cant figure out why for offline players the playtime is <none>
discord command sstats <offlineplayer>:
prefixes: /
trigger:
set {_p} to arg-1
if {_p} is not set:
reply with "A player with that name has never joined this server."
stop
set {_online} to {_p}'s name parsed as player
if {_online} is set:
set {_minutes} to tagPlayMinutes({_online})
set {_playtime} to tagFormatMinutes({_minutes})
else:
set {_seconds} to time played of {_p}
if {_seconds} is not set:
reply with "A player named **%{_p}%** has never joined this server."
stop
set {_hours} to floor({_seconds} / 3600)
set {_playtime} to "%{_hours}% hours"
set {_kills} to value of placeholder "statistic_player_kills" from {_p}
set {_deaths} to value of placeholder "statistic_deaths" from {_p}
reply with "**Stats for %{_p}%:**"
reply with "⚔️ Kills: %{_kills}%"
reply with "💀 Deaths: %{_deaths}%"
reply with "⏰ Playtime: %{_playtime}%"