Formatting a timespan

  • Welcome to skUnity!

    Welcome to skUnity! This is a forum where members of the Skript community can communicate and interact. Skript Resource Creators can post their Resources for all to see and use.

    If you haven't done so already, feel free to join our official Discord server to expand your level of interaction with the comminuty!

    Now, what are you waiting for? Join the community now!

  • LOOKING FOR A VERSION OF SKRIPT?

    You can always check out skUnity Downloads for downloads and any other information about Skript!

Jun 3, 2023
25
1
3
16
(If you are not going to give the ACTUAL ANSWER, don't respond)

Skript's auto format timespan is awful, having "x days x.x hours" or "x hours x.x minutes" is completely useless and doesn't tell anything about timespans.
How would I convert this to "x d x h x m x s" or "x h x m x s", or "x d"
 
Keep track of the seconds that have passed. Then simply use the division to transform the number of seconds into the specified format.