Jump to content

Recommended Posts

every second:
    loop all players:
        add 1 to {s::%loop-player's uuid%}
        if {s::%loop-player's uuid%} > 59:
            remove 60 from {s::%loop-player's uuid%} 
            add 1 to {m::%loop-player's uuid%}
        if {m::%loop-player's uuid%} > 59:
            remove 60 from {m::%loop-player's uuid%}
            add 1 to {h::%loop-player's uuid%}
        if {h::%loop-player's uuid%} > 23:
            remove 24 from {h::%loop-player's uuid%}
            add 1 to {d::%loop-player's uuid%}

command /playtime [<offlineplayer>]:
    trigger:
        arg isn't set:
            wait 1 tick
            send ""
            send "&f&l    YOUR PLAYTIME (&7&l%player%&f)"
            send ""
            send "&f&l  SECONDS:&7 %{s::%player's uuid%}%"
            send "&f&l  MINUTES:&7 %{m::%player's uuid%}%"
            send "&f&l  HOURS:&7 %{h::%player's uuid%}%"
            send "&f&l  DAYS:&7 %{d::%player's uuid%}%"
            send ""
        else:
            wait 1 tick
            send ""
            send "&f&l    PLAYTIME OF &7&l%arg%"
            send ""
            send "&f&l  SECONDS:&7 %{s::%arg's uuid%}%"
            send "&f&l  MINUTES:&7 %{m::%arg's uuid%}%"
            send "&f&l  HOURS:&7 %{h::%arg's uuid%}%"
            send "&f&l  DAYS:&7 %{d::%arg's uuid%}%"
            send ""

 

Edited by Twenjii
Link to post
Share on other sites
26 minutes ago, Twenjii said:

 

every second:
    loop all players:
        add 1 to {s::%loop-player's uuid%}
        if {s::%loop-player's uuid%} > 59:
            remove 60 from {s::%loop-player's uuid%} 
            add 1 to {m::%loop-player's uuid%}
        if {m::%loop-player's uuid%} > 59:
            remove 60 from {m::%loop-player's uuid%}
            add 1 to {h::%loop-player's uuid%}
        if {h::%loop-player's uuid%} > 23:
            remove 24 from {h::%loop-player's uuid%}
            add 1 to {d::%loop-player's uuid%}

command /playtime [<offlineplayer>]:
    trigger:
        arg isn't set:
            wait 1 tick
            send ""
            send "&f&l    YOUR PLAYTIME (&7&l%player%&f)"
            send ""
            send "&f&l  SECONDS:&7 %{s::%player's uuid%}%"
            send "&f&l  MINUTES:&7 %{m::%player's uuid%}%"
            send "&f&l  HOURS:&7 %{h::%player's uuid%}%"
            send "&f&l  DAYS:&7 %{d::%player's uuid%}%"
            send ""
        else:
            wait 1 tick
            send ""
            send "&f&l    PLAYTIME OF &7&l%arg%"
            send ""
            send "&f&l  SECONDS:&7 %{s::%arg's uuid%}%"
            send "&f&l  MINUTES:&7 %{m::%arg's uuid%}%"
            send "&f&l  HOURS:&7 %{h::%arg's uuid%}%"
            send "&f&l  DAYS:&7 %{d::%arg's uuid%}%"
            send ""

At least put it in code blocks...

Website Developer - Graphic Designer - Skript Developer - Professional Builder

Been on Minehut since January 2018. Throughout my time here I've mastered the skills you see above. I develop pretty static websites when I'm bored. I make free logos, banners, and server art for users on Minehut. I'm a proficient Skript developer. I'm also really good at building, you can see my portfolio by clicking here. Feel free to say hi if you see me somewhere 🙂

Link to post
Share on other sites
2 hours ago, Twenjii said:

And how do you do that in the new forums? @Farwl

image.png.715c7db2c461fa9a5ad19961289bde55.png

Website Developer - Graphic Designer - Skript Developer - Professional Builder

Been on Minehut since January 2018. Throughout my time here I've mastered the skills you see above. I develop pretty static websites when I'm bored. I make free logos, banners, and server art for users on Minehut. I'm a proficient Skript developer. I'm also really good at building, you can see my portfolio by clicking here. Feel free to say hi if you see me somewhere 🙂

Link to post
Share on other sites

.

Edited by TacticalModz

I've been doing skript for 4 years and a half. I don't find my self a "better" skripter or do competitions against others.

I just wish people can just get along & just help each out and be kind to one and another.

 

I have been hosting ValkNet for 5 years and a half

ever since 2015 when i joined minehut around February or January.

 

I'm the owner of ValkyrieNetwork (known as ValkNet) | https://discord.gg/rPTYbQY

A great service that i provide for the minehut community!

 

Contact:

Discord: https://discord.gg/6rQu2Vn

Link to post
Share on other sites

here's a non bad version of this

every second:
    loop all players:
        add 1 second to {playtime::%loop-player's uuid%}

function time(t: text) :: text:
    set {_n} to {_t}
    replace all " seconds" and " second" with "s" in {_n}
    replace all " minutes" and " minute" with "m" in {_n}
    replace all " hours" and " hour" with "h" in {_n}
    replace all " days" and " day" with "d" in {_n}
    replace all " and " with " " in {_n}
    return {_n}

command /playtime [<offlineplayer>]:
    trigger:
        set {_p} to arg 1 ? player
        set {_u} to {_p}'s uuid
        if {playtime::%{_u}%} is not set:
            send "&cThat user is not registered."
        else:
            set {_time} to time("%{playtime::%{_u}%}%")
            send ""
            send " &3%{_p}'s playtime: &7%{_time}%"
            send ""

 

  • Thanks 1

Discord: MrScopes#5548

Link to post
Share on other sites
2 hours ago, MrScopes said:

here's a non bad version of this


every second:
    loop all players:
        add 1 second to {playtime::%loop-player's uuid%}

function time(t: text) :: text:
    set {_n} to {_t}
    replace all " seconds" and " second" with "s" in {_n}
    replace all " minutes" and " minute" with "m" in {_n}
    replace all " hours" and " hour" with "h" in {_n}
    replace all " days" and " day" with "d" in {_n}
    replace all " and " with " " in {_n}
    return {_n}

command /playtime [<offlineplayer>]:
    trigger:
        set {_p} to arg 1 ? player
        set {_u} to {_p}'s uuid
        if {playtime::%{_u}%} is not set:
            send "&cThat user is not registered."
        else:
            set {_time} to time("%{playtime::%{_u}%}%")
            send ""
            send " &3%{_p}'s playtime: &7%{_time}%"
            send ""

 

bruh

Link to post
Share on other sites
  • 4 weeks later...

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now


×
×
  • Create New...