Jump to content

[Solved} converting ancient debris to netherite ingot (skript)


coolguy76

Recommended Posts

I am trying to convert ancient debris into netherite ingots. so every time you do the command /convertancientdebris it will check your inventory and if you have lets say you have 128 ancient debris. then it will give you 128 netherite ingots. Heres the script I already have.

 

command /convertancientdebris:
    trigger:
        set {_netheriteingot} to amount of ancient_debris in player's inventory

 

this isn't working can somebody help?

 

Edit: I figure it out the code is

  1. command /convertancientdebris:
  2. trigger:
  3. if player does not have ancient debris in their inventory:
  4. send "&eYou have nothing to convert." to player
  5. else:
  6. set {_a} to amount of ancient debris in player's inventory
  7. remove {_a} of ancient debris from player's inventory
  8. give player {_a} of netherite ingot
  9. send "&eConverted &b&l%{_a}% &eAncient Debris to netherite." to player
Edited by coolguy76
i figured out the code want people to be able to see my code
Link to comment
Share on other sites

figured out the code its 

  1. command /convertancientdebris:
  2. trigger:
  3. if player does not have ancient debris in their inventory:
  4. send "&eYou have nothing to convert." to player
  5. else:
  6. set {_a} to amount of ancient debris in player's inventory
  7. remove {_a} of ancient debris from player's inventory
  8. give player {_a} of netherite ingot
  9. send "&eConverted &b&l%{_a}% &eAncient Debris to netherite." to player
Link to comment
Share on other sites

  • coolguy76 changed the title to [Solved} converting ancient debris to netherite ingot (skript)

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