Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Item unbreakable changes #2200

Merged
merged 1 commit into from
Sep 23, 2024
Merged

Item unbreakable changes #2200

merged 1 commit into from
Sep 23, 2024

Conversation

krivey
Copy link
Contributor

@krivey krivey commented Sep 22, 2024

Add setUnbreakable() and changes to isUnbreakable()

Codes like this:

ItemSwordStone sword = Item.get(ItemID.STONE_SWORD);
sword.setNamedTag(sword.getNamedTag().putByte("Unbreakable", 1));
return sword;

Can be shortened into this:

return Item.get(ItemID.STONE_SWORD).setUnbreakable();

@PetteriM1 PetteriM1 merged commit fb217e1 into CloudburstMC:master Sep 23, 2024
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants