Skip to content

implement item.OffHand to offhand items #1062

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

Open
wants to merge 3 commits into
base: master
Choose a base branch
from

Conversation

FDUTCH
Copy link
Contributor

@FDUTCH FDUTCH commented May 11, 2025

It would be useful to know if you can put item in the offhand

Ps:
maybe I miss some items

@cjmustard
Copy link
Contributor

arrow, spectral arrow, tipped arrow, firework rocket, totem of undying, shield, map, nautilus shell

I think you have all of the existent ones added

@Dasciam
Copy link
Contributor

Dasciam commented May 12, 2025

also you could add validation. if an item can't be placed in the off hand the action should be cancelled

@FDUTCH
Copy link
Contributor Author

FDUTCH commented May 12, 2025

also you could add validation. if an item can't be placed in the off hand the action should be cancelled

I had no plans to validate slots because then I would have to do validation for armor as well

@FDUTCH
Copy link
Contributor Author

FDUTCH commented May 12, 2025

maybe I'll implement validation in the next pr

@DaPigGuy
Copy link
Member

also you could add validation. if an item can't be placed in the off hand the action should be cancelled

I had no plans to validate slots because then I would have to do validation for armor as well

https://github.com/df-mc/dragonfly/blob/master/server/item/inventory/armour.go#L24

@FDUTCH
Copy link
Contributor Author

FDUTCH commented May 25, 2025

also you could add validation. if an item can't be placed in the off hand the action should be cancelled

I had no plans to validate slots because then I would have to do validation for armor as well

https://github.com/df-mc/dragonfly/blob/master/server/item/inventory/armour.go#L24

right, I overlooked that

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.

4 participants