Open kossnikita opened 2 years ago
while statistics would be useful, I don't think removing the time played expression is necessary
This is not necessary because the syntax %offlineplayer%'s %statistic%
completely replaces %offlineplayer%'s time played
. Because time played is statistic.
Removing a pretty much used expression is to be avoided unless for a very good/important reason which this isn't of type
But if this does not affect the work of existing scripts, then what could be wrong? The syntax will not change in any way, as will the functionality (get and set statistics)
a couple reasons -
%player%'s %statistic%
probably isn't viable. imagine some of the weird syntaxes that could allow (e.g. player's jump
, player's drop
or player's dispenser inspected
Initially, I assumed that all time related statistics would be timespans. This requires additional processing.
player's number of jumps
or player's number of stone drop
for these examples.
Okay, I see that there can be problems with this. Although so far it seems to me that everything can be solved.
Are you suggesting that instead of adding a single expression for the statistics, add multiple expressions for each of the statistics?
There will be one expression and it will look something like this statistic [value[s]] %strings/statistics% of %offlineplayers%
Chossing the %strings/statistics%
part will decide whether we should make it be as a string or add statistics enum values as literals which I don't think is needed since it may be misleading, so string would be fair and enough
Suggestion
The API has a class org.bukkit.Statistic which is currently not used in the Skript. Except for one expression new ExprTimePlayed #2522 This expression can be replaced with ExprStatistic for offline players and adding a new Statistic Skript type.
Why?
Some of the statistics may be useful for conditions. For example, the number of deaths or the time since the last sleep.
Other
No response
Agreement