Set Mining Speed

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

Status
Not open for further replies.

Brandawg

Member
May 8, 2017
19
0
1
22
Sp I have been looking all over the web to do this and I have not really found a good way. I have tried setting Mining fatigue and haste but that does not work too well. Because haste 2 is a lot faster also you can either see your pickaxe mine really slow or really fast. I also need to say for example a wood pick can be mine coal in 10 seconds but mine coal in 5. Also I have tried modifying packets but have now figured out how to. All help is appreciated.
 
So many people contact me asking about adding something like this to my addon and it's been spammed all over the forums a couple of times. Block breaking is client side. The client sends a packet when it starts mining, changes tools/aborts during mining and when it finishes mining. Having a constant system spamming packets to the server saying that the player is mining a block is ridiculous, which is why Mojang doesn't have that as a feature.

You can't change how fast a player mines a block. Also if you're giving this to donators, that is against Mojang's EULA which gives Mojang the rights to shut your server down if they want. If all players have the ability to access this feature, you won't have to worry. "Donators can not have gameplay-affecting features over other players" - Mojang

Mojang's EULA if interested Here and Here
(EULA has been around since 2014 and was put into action summer 2015)

The only way to "Simulate" block breaking is constantly cancel the on block damage or on break event and for every X hits of the block. Add 1 to a variable of the block. Then if that variable goes over X break the block. You can add the block crack effect or the block break packet to the block per stage to add an effect of breaking to it aswell.
 
Last edited by a moderator:
  • Like
Reactions: Snow-Pyon
So many people contact me asking about adding something like this to my addon and it's been spammed all over the forums a couple of times. Block breaking is client side. The client sends a packet when it starts mining, changes tools/aborts during mining and when it finishes mining. Having a constant system spamming packets to the server saying that the player is mining a block is ridiculous, which is why Mojang doesn't have that as a feature.

You can't change how fast a player mines a block. Also if you're giving this to donators, that is against Mojang's EULA which gives Mojang the rights to shut your server down if they want. If all players have the ability to access this feature, you won't have to worry. "Donators can not have gameplay-affecting features over other players" - Mojang

Mojang's EULA if interested Here and Here
(EULA has been around since 2014 and was put into action summer 2015)

The only way to "Simulate" block breaking is constantly cancel the on block damage or on break event and for every X hits of the block. Add 1 to a variable of the block. Then if that variable goes over X break the block. You can add the block crack effect or the block break packet to the block per stage to add an effect of breaking to it aswell.
I have tried the on break event and it does not work. Do you think you can help me? Also this is not meant to go against the EULA
 
Block break animation with randomzk
it says this
BhTGNH1sTse2nJbDTAW_xw.png


code_language.skript:
on rightclick with diamond pickaxe:
    set {_block} to targeted block
    loop 10 times:
        show block break stage loop-number at {_block}
        wait 10 ticks
    break {_block}
 
Status
Not open for further replies.