Jump to content

I need help with my skript


Recommended Posts

on join:
    clear player's scoreboard
    erase player's sidebar

on script load:
    loop all players:
        clear loop-player's scoreboard
        erase loop-player's sidebar

every tick:
    set {_pref} to formatted loop-player's prefix
    loop all players:
        toggle loop-player's scoreboard to true
        set title of loop-player's scoreboard to "&4&lVelvetSurv"
        set line 11 of loop-player's scoreboard to "&b"
        set line 10 of loop-player's scoreboard to "&4&lRank&c:"
        set {_pref} to formatted player's prefix
        set line 9 of loop-player's scoreboard to " &4&lRank&c: "%f{_pref}%"
        set line 8 of loop-player's scoreboard to "  &4&lPing&c: &c%loop-player's ping%ms"
        set line 6 of loop-player's scoreboard to "&b"
        set line 5 of loop-player's scoreboard to "&b&lInformations"
        set line 4 of loop-player's scoreboard to "  &4&lTPS&c: &c%rounded 1st element of tps%"
        set line 3 of loop-player's scoreboard to "  &4&lOnline&c: &c%number of all players%&8/&c%max players%"
        set line 2 of loop-player's scoreboard to "&b"
        set line 1 of loop-player's scoreboard to "&4&lVelvetsurv.minehut.gg"
        wait 5 seconds

 

imgonline-com-ua-resize-CNNkL1drx5M-removebg-preview.png.d6a8ae8b5eb862005fb056c21f934200.png

Link to comment
Share on other sites

1 minute ago, LapEvents said:

on join:
    clear player's scoreboard
    erase player's sidebar

on script load:
    loop all players:
        clear loop-player's scoreboard
        erase loop-player's sidebar

every tick:
    set {_pref} to formatted loop-player's prefix
    loop all players:
        toggle loop-player's scoreboard to true
        set title of loop-player's scoreboard to "&4&lVelvetSurv"
        set line 11 of loop-player's scoreboard to "&b"
        set line 10 of loop-player's scoreboard to "&4&lRank&c:"
        set {_pref} to formatted player's prefix
        set line 9 of loop-player's scoreboard to " &4&lRank&c: "%f{_pref}%"
        set line 8 of loop-player's scoreboard to "  &4&lPing&c: &c%loop-player's ping%ms"
        set line 6 of loop-player's scoreboard to "&b"
        set line 5 of loop-player's scoreboard to "&b&lInformations"
        set line 4 of loop-player's scoreboard to "  &4&lTPS&c: &c%rounded 1st element of tps%"
        set line 3 of loop-player's scoreboard to "  &4&lOnline&c: &c%number of all players%&8/&c%max players%"
        set line 2 of loop-player's scoreboard to "&b"
        set line 1 of loop-player's scoreboard to "&4&lVelvetsurv.minehut.gg"
        wait 5 seconds

Dosent work

Link to comment
Share on other sites

on join:
    clear player's scoreboard
    erase player's sidebar

on script load:
    loop all players:
        clear loop-player's scoreboard
        erase loop-player's sidebar

every tick:
    set {_pref} to formatted loop-player's prefix
    loop all players:
        toggle loop-player's scoreboard to true
        set title of loop-player's scoreboard to "&4&lVelvetSurv"
        set line 11 of loop-player's scoreboard to "&b"
        set line 10 of loop-player's scoreboard to "&4&lRank&c:"
        set line 9 of loop-player's scoreboard to " &4&lRank&c: "%f{_pref}%"
        set line 8 of loop-player's scoreboard to "  &4&lPing&c: &c%loop-player's ping%ms"
        set line 6 of loop-player's scoreboard to "&b"
        set line 5 of loop-player's scoreboard to "&b&lInformations"
        set line 4 of loop-player's scoreboard to "  &4&lTPS&c: &c%rounded 1st element of tps%"
        set line 3 of loop-player's scoreboard to "  &4&lOnline&c: &c%number of all players%&8/&c%max players%"
        set line 2 of loop-player's scoreboard to "&b"
        set line 1 of loop-player's scoreboard to "&4&lVelvetsurv.minehut.gg"
        wait 5 seconds

 

imgonline-com-ua-resize-CNNkL1drx5M-removebg-preview.png.d6a8ae8b5eb862005fb056c21f934200.png

Link to comment
Share on other sites

1 hour ago, nolando09 said:

Im just desperate to get hex codes to work XD

I just saw in the screen that you're using hexcodes that won't work with skript. Skript only reads hexcodes like this 

<##123456>

 

tumblr_lqahoaPLkC1ql1l0v.gif

Feel free to add me on discord if you:

dc3456c-e0ec58e8-c807-43e3-b986-5224b91a need help with plugins

dc3456c-e0ec58e8-c807-43e3-b986-5224b91a need help with skripts

dc3456c-e0ec58e8-c807-43e3-b986-5224b91a need to vent about something

tumblr_lqahoaPLkC1ql1l0v.gif

>[ ‧₊˚꒰ʚ Starshine ɞ ‧✦ *#2683 ]<

Link to comment
Share on other sites

Just now, nolando09 said:

But if i use <##123456> it doesnt work in luckperms

 

hmm I have an idea we already set {_pref} to player's prefix so maybe we can try something like the following

set {_pref} to player's prefix
replace "&" in {_pref} with "##"
set {_pref} to formatted {_pref}

 

tumblr_lqahoaPLkC1ql1l0v.gif

Feel free to add me on discord if you:

dc3456c-e0ec58e8-c807-43e3-b986-5224b91a need help with plugins

dc3456c-e0ec58e8-c807-43e3-b986-5224b91a need help with skripts

dc3456c-e0ec58e8-c807-43e3-b986-5224b91a need to vent about something

tumblr_lqahoaPLkC1ql1l0v.gif

>[ ‧₊˚꒰ʚ Starshine ɞ ‧✦ *#2683 ]<

Link to comment
Share on other sites

Just now, StarBunnie said:

hmm I have an idea we already set {_pref} to player's prefix so maybe we can try something like the following

set {_pref} to player's prefix
replace "&" in {_pref} with "##"
set {_pref} to formatted {_pref}

 

Ok ill try hold on

 

Link to comment
Share on other sites

32 minutes ago, nolando09 said:

Ok i tried it got me to here BUT the hex codes arent surrounded by <>

 

2021-07-30_16_47_12.thumb.png.e9e10884bfbba270943777f7058e3efd.png

Alright slapped something together

function convHex(t: text) :: text:
 set {_t2::*} to {_t} split at "&##"
 set {_t} to ""
 delete {_t2::1}
 loop {_t2::*}:
  set {_word} to loop-value
  set {_char} to first 6 characters of {_word}
  replace {_char} in {_word} with ""
  set {_t} to "%{_t}%<##%{_char}%>%{_word}%"
 return {_t}
 
 set {_pref} to formatted convHex(player's prefix)

 

tumblr_lqahoaPLkC1ql1l0v.gif

Feel free to add me on discord if you:

dc3456c-e0ec58e8-c807-43e3-b986-5224b91a need help with plugins

dc3456c-e0ec58e8-c807-43e3-b986-5224b91a need help with skripts

dc3456c-e0ec58e8-c807-43e3-b986-5224b91a need to vent about something

tumblr_lqahoaPLkC1ql1l0v.gif

>[ ‧₊˚꒰ʚ Starshine ɞ ‧✦ *#2683 ]<

Link to comment
Share on other sites

1 minute ago, StarBunnie said:

Alright slapped something together

function convHex(t: text) :: text:
 set {_t2::*} to {_t} split at "&##"
 set {_t} to ""
 delete {_t2::1}
 loop {_t2::*}:
  set {_word} to loop-value
  set {_char} to first 6 characters of {_word}
  replace {_char} in {_word} with ""
  set {_t} to "%{_t}%<##%{_char}%>%{_word}%"
 return {_t}
 
 set {_pref} to formatted convHex(player's prefix)

 

Ok thanks ill try it

 

Link to comment
Share on other sites

And here is what i did

 

on join:
    clear player's scoreboard
    erase player's sidebar

on script load:
    loop all players:
        clear loop-player's scoreboard
        erase loop-player's sidebar

every tick:
    loop all players:
        toggle loop-player's scoreboard to true
        set title of loop-player's scoreboard to "&4&lVelvetSurv"
        set line 11 of loop-player's scoreboard to "&b"
        set line 10 of loop-player's scoreboard to "&4&lRank&c:"
        function convHex(t: text) :: text:
            set {_t2::*} to {_t} split at "&##"
            set {_t} to ""
        delete {_t2::1}
        loop {_t2::*}:
            set {_word} to loop-value
            set {_char} to first 6 characters of {_word}
        replace {_char} in {_word} with ""
        set {_t} to "%{_t}%<##%{_char}%>%{_word}%"
        return {_t}
 
        set {_pref} to formatted convHex(player's prefix)
        set line 9 of loop-player's scoreboard to " &4&lRank&c: %{_pref}%"
        set line 8 of loop-player's scoreboard to "  &4&lPing&c: &c%loop-player's ping%ms"
        set line 6 of loop-player's scoreboard to "&b"
        set line 5 of loop-player's scoreboard to "&b&lInformations"
        set line 4 of loop-player's scoreboard to "  &4&lTPS&c: &c%rounded 1st element of tps%"
        set line 3 of loop-player's scoreboard to "  &4&lOnline&c: &c%number of all players%&8/&c%max players%"
        set line 2 of loop-player's scoreboard to "&b"
        set line 1 of loop-player's scoreboard to "&4&lVelvetsurv.minehut.gg"

Link to comment
Share on other sites

14 minutes ago, nolando09 said:

And here is what i did

 

on join:
    clear player's scoreboard
    erase player's sidebar

on script load:
    loop all players:
        clear loop-player's scoreboard
        erase loop-player's sidebar

every tick:
    loop all players:
        toggle loop-player's scoreboard to true
        set title of loop-player's scoreboard to "&4&lVelvetSurv"
        set line 11 of loop-player's scoreboard to "&b"
        set line 10 of loop-player's scoreboard to "&4&lRank&c:"
        function convHex(t: text) :: text:
            set {_t2::*} to {_t} split at "&##"
            set {_t} to ""
        delete {_t2::1}
        loop {_t2::*}:
            set {_word} to loop-value
            set {_char} to first 6 characters of {_word}
        replace {_char} in {_word} with ""
        set {_t} to "%{_t}%<##%{_char}%>%{_word}%"
        return {_t}
 
        set {_pref} to formatted convHex(player's prefix)
        set line 9 of loop-player's scoreboard to " &4&lRank&c: %{_pref}%"
        set line 8 of loop-player's scoreboard to "  &4&lPing&c: &c%loop-player's ping%ms"
        set line 6 of loop-player's scoreboard to "&b"
        set line 5 of loop-player's scoreboard to "&b&lInformations"
        set line 4 of loop-player's scoreboard to "  &4&lTPS&c: &c%rounded 1st element of tps%"
        set line 3 of loop-player's scoreboard to "  &4&lOnline&c: &c%number of all players%&8/&c%max players%"
        set line 2 of loop-player's scoreboard to "&b"
        set line 1 of loop-player's scoreboard to "&4&lVelvetsurv.minehut.gg"

You can't just add the function into the scoreboard code xD Let it stand alone there are no indent errors the only line you need to use in your scoreboard itself is 

set {_pref} to formatted convHex(loop-player's prefix)

A function stands alone so just copy it above you're scoreboard skript

tumblr_lqahoaPLkC1ql1l0v.gif

Feel free to add me on discord if you:

dc3456c-e0ec58e8-c807-43e3-b986-5224b91a need help with plugins

dc3456c-e0ec58e8-c807-43e3-b986-5224b91a need help with skripts

dc3456c-e0ec58e8-c807-43e3-b986-5224b91a need to vent about something

tumblr_lqahoaPLkC1ql1l0v.gif

>[ ‧₊˚꒰ʚ Starshine ɞ ‧✦ *#2683 ]<

Link to comment
Share on other sites

1 minute ago, StarBunnie said:

You can't just add the function into the scoreboard code xD Let it stand alone there are no indent errors the only line you need to use in your scoreboard itself is 

set {_pref} to formatted convHex(loop-player's prefix)

A function stands alone so just copy it above you're scoreboard skript

xD so sorry 

Link to comment
Share on other sites

Like this xD??

 

function convHex(t: text) :: text:
 set {_t2::*} to {_t} split at "&##"
 set {_t} to ""
 delete {_t2::1}
 loop {_t2::*}:
  set {_word} to loop-value
  set {_char} to first 6 characters of {_word}
  replace {_char} in {_word} with ""
  set {_t} to "%{_t}%<##%{_char}%>%{_word}%"
 return {_t}
 
 set {_pref} to formatted convHex(player's prefix)

on join:
    clear player's scoreboard
    erase player's sidebar

on script load:
    loop all players:
        clear loop-player's scoreboard
        erase loop-player's sidebar

every tick:
    loop all players:
        toggle loop-player's scoreboard to true
        set title of loop-player's scoreboard to "&4&lVelvetSurv"
        set line 11 of loop-player's scoreboard to "&b"
        set line 10 of loop-player's scoreboard to "&4&lRank&c:"
        set line 9 of loop-player's scoreboard to " &4&lRank&c: %{_pref}%"
        set line 8 of loop-player's scoreboard to "  &4&lPing&c: &c%loop-player's ping%ms"
        set line 6 of loop-player's scoreboard to "&b"
        set line 5 of loop-player's scoreboard to "&b&lInformations"
        set line 4 of loop-player's scoreboard to "  &4&lTPS&c: &c%rounded 1st element of tps%"
        set line 3 of loop-player's scoreboard to "  &4&lOnline&c: &c%number of all players%&8/&c%max players%"
        set line 2 of loop-player's scoreboard to "&b"
        set line 1 of loop-player's scoreboard to "&4&lVelvetsurv.minehut.gg"

Link to comment
Share on other sites

1 minute ago, nolando09 said:

Like this xD??

 

function convHex(t: text) :: text:
 set {_t2::*} to {_t} split at "&##"
 set {_t} to ""
 delete {_t2::1}
 loop {_t2::*}:
  set {_word} to loop-value
  set {_char} to first 6 characters of {_word}
  replace {_char} in {_word} with ""
  set {_t} to "%{_t}%<##%{_char}%>%{_word}%"
 return {_t}
 
 set {_pref} to formatted convHex(player's prefix)

on join:
    clear player's scoreboard
    erase player's sidebar

on script load:
    loop all players:
        clear loop-player's scoreboard
        erase loop-player's sidebar

every tick:
    loop all players:
        toggle loop-player's scoreboard to true
        set title of loop-player's scoreboard to "&4&lVelvetSurv"
        set line 11 of loop-player's scoreboard to "&b"
        set line 10 of loop-player's scoreboard to "&4&lRank&c:"
        set line 9 of loop-player's scoreboard to " &4&lRank&c: %{_pref}%"
        set line 8 of loop-player's scoreboard to "  &4&lPing&c: &c%loop-player's ping%ms"
        set line 6 of loop-player's scoreboard to "&b"
        set line 5 of loop-player's scoreboard to "&b&lInformations"
        set line 4 of loop-player's scoreboard to "  &4&lTPS&c: &c%rounded 1st element of tps%"
        set line 3 of loop-player's scoreboard to "  &4&lOnline&c: &c%number of all players%&8/&c%max players%"
        set line 2 of loop-player's scoreboard to "&b"
        set line 1 of loop-player's scoreboard to "&4&lVelvetsurv.minehut.gg"

image.png.38a405789f9a5b4a330b2488ae38dfc9.png

That line was just an example on how to use it you can leave that out just write it below into your actual scoreboard skript but remember to use loop-player

tumblr_lqahoaPLkC1ql1l0v.gif

Feel free to add me on discord if you:

dc3456c-e0ec58e8-c807-43e3-b986-5224b91a need help with plugins

dc3456c-e0ec58e8-c807-43e3-b986-5224b91a need help with skripts

dc3456c-e0ec58e8-c807-43e3-b986-5224b91a need to vent about something

tumblr_lqahoaPLkC1ql1l0v.gif

>[ ‧₊˚꒰ʚ Starshine ɞ ‧✦ *#2683 ]<

Link to comment
Share on other sites

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...