Jump to content

Place + Remove item = Crash


mattstat716

Recommended Posts

To consume it like a food item.
Rightclicking it should remove 1 of the heads in the stack, and give saturation + a buff to the player.
But due to the fact that it can be placed, it crashes the server whenever it is both placed + consumed.

Edited by mattstat716
Link to comment
Share on other sites

Nevermind, fixed it myself.
For anyone else also having the problem or just wanting to quickly use it for their own consumable items
finalized code
|
V
on rightclick on air holding (item)
        set {_name} to name of player's tool    
        if {_name} contains "(name)":
                remove 1 of tool from tool
                (insert effects)
 

Edited by mattstat716
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...