Jump to content

Skript Help PLZ


MinecraftiestYT
 Share

Recommended Posts

Hai, i need a skript for "checks".

basically someone can do /check <number>

then it takes that number from their balance (if they have enough)

and gives them a piece of paper named "Check" with the amount in the lore (so you cant fake it with an anvil)

when a player right clicks with the "check" they get the amount of money specified in the lore.

 

Plz thx!

Link to comment
Share on other sites

I made this Skript for you that fully works! (WARNING: I disabled the usage of anvils in the Skript for you so you don't run into that issue. If you don't want them disabled contact me and ill figure something else out)

command /check [<integer>]:
    trigger:
        set {_a} to arg-1
        if player's balance >= {_a}:
            remove {_a} from player's balance
            give player 1 paper named "&6&lCHECK &e&l+%{_a}%"
            play sound "entity.villager.yes" with volume 5 to player
        else:
            send "&cYou don't have the specified amount of money!" to player
            play sound "entity.villager.no" with volume 5 to player

on right click with paper:
    if name of player's held item contains "CHECK":
        set {_a::*} to name of player's tool split at "+"
        remove 1 paper named "&6&lCHECK &e&l+%{_a::2}%" from player
        set {_m} to {_a::2} parsed as a integer
        add {_m} to player's balance
        play sound "entity.villager.yes" with volume 5 to player
        send "&aYou have claimed &2$%{_a::2}%&a from your check!" to player
        
on right click on anvil:
	cancel event

 

 

Active Minehut Player since 2016

Advanced at Skript - Know a lot about running a server 

If you need help with anything contact me @ KJPAKA#0001

 

Link to comment
Share on other sites

44 minutes ago, KJPAKA said:

I made this Skript for you that fully works! (WARNING: I disabled the usage of anvils in the Skript for you so you don't run into that issue. If you don't want them disabled contact me and ill figure something else out)


command /check [<integer>]:
    trigger:
        set {_a} to arg-1
        if player's balance >= {_a}:
            remove {_a} from player's balance
            give player 1 paper named "&6&lCHECK &e&l+%{_a}%"
            play sound "entity.villager.yes" with volume 5 to player
        else:
            send "&cYou don't have the specified amount of money!" to player
            play sound "entity.villager.no" with volume 5 to player

on right click with paper:
    if name of player's held item contains "CHECK":
        set {_a::*} to name of player's tool split at "+"
        remove 1 paper named "&6&lCHECK &e&l+%{_a::2}%" from player
        set {_m} to {_a::2} parsed as a integer
        add {_m} to player's balance
        play sound "entity.villager.yes" with volume 5 to player
        send "&aYou have claimed &2$%{_a::2}%&a from your check!" to player
        
on right click on anvil:
	cancel event

 

thank you so much! can you also help me open tuske crafting table gui? its ok if you cant

Link to comment
Share on other sites

open workbench to player or open virtual workbench to player or workbench is crafting table try that.

 

Active Minehut Player since 2016

Advanced at Skript - Know a lot about running a server 

If you need help with anything contact me @ KJPAKA#0001

 

Link to comment
Share on other sites

No problem, contact my discord anytime if you need more help @ KJPAKA#0001 

 

Active Minehut Player since 2016

Advanced at Skript - Know a lot about running a server 

If you need help with anything contact me @ KJPAKA#0001

 

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
 Share



×
×
  • Create New...