Pickaxe Stat

  • 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 community!

    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!

Status
Not open for further replies.

Jsam3

Member
Jul 26, 2022
2
0
1
I want the number of blocks I broke using pickaxe to be written in the first line of the pickaxe ( without any variable )
for example:
Code:
on mine:
    if player is holding a pickaxe:
        set line 1 of lore of item to " %1nd lore of player's tool + 1%" (for example that's not working)

command /pickaxe:
    trigger:
        execute console command "give %player% diamond_pickaxe 1 lore:0
 
Here you go.

Code:
on mine:
    if player is holding a pickaxe:
        set {_a} to uncolored line 3 of lore of player's held item
        replace all " Blocks Mined: " in {_a} with ""
        set {_a} to {_a} parsed as a integer
        set line 3 of lore of player's tool to " &3Blocks Mined: &7%{_a} + 1%"
 
command /pickaxe:
    permission: op
    trigger:
        give player 1 of diamond pickaxe with lore "" and "&d&lMining Stats" and " &3Blocks Mined: &70" and "" with nbt "{HideFlags:63}"
[doublepost=1658859376,1658859289][/doublepost]Just remove the "permission: op" so that everyone can use the /pickaxe command
 
Here you go.

Code:
on mine:
    if player is holding a pickaxe:
        set {_a} to uncolored line 3 of lore of player's held item
        replace all " Blocks Mined: " in {_a} with ""
        set {_a} to {_a} parsed as a integer
        set line 3 of lore of player's tool to " &3Blocks Mined: &7%{_a} + 1%"
 
command /pickaxe:
    permission: op
    trigger:
        give player 1 of diamond pickaxe with lore "" and "&d&lMining Stats" and " &3Blocks Mined: &70" and "" with nbt "{HideFlags:63}"
[doublepost=1658859376,1658859289][/doublepost]Just remove the "permission: op" so that everyone can use the /pickaxe command
thx
[doublepost=1658887544][/doublepost]
Here you go.

Code:
on mine:
    if player is holding a pickaxe:
        set {_a} to uncolored line 3 of lore of player's held item
        replace all " Blocks Mined: " in {_a} with ""
        set {_a} to {_a} parsed as a integer
        set line 3 of lore of player's tool to " &3Blocks Mined: &7%{_a} + 1%"
 
command /pickaxe:
    permission: op
    trigger:
        give player 1 of diamond pickaxe with lore "" and "&d&lMining Stats" and " &3Blocks Mined: &70" and "" with nbt "{HideFlags:63}"
[doublepost=1658859376,1658859289][/doublepost]Just remove the "permission: op" so that everyone can use the /pickaxe command
https://i.ibb.co/J56ByQ1/er2.png do i need install some addons or something?
it is worked when i delete " with nbt "{HideFlags:63}"
 
Last edited:
Status
Not open for further replies.