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

Make Momento stackable and update recipe #6

Merged
merged 5 commits into from
Jul 10, 2024
Merged

Make Momento stackable and update recipe #6

merged 5 commits into from
Jul 10, 2024

Conversation

cpaca
Copy link
Contributor

@cpaca cpaca commented Jul 10, 2024

No description provided.

@dlee13
Copy link
Owner

dlee13 commented Jul 10, 2024

I was going cross-eyed looking at Klin's code trying to understand if this would interfere with onion ring

@cpaca
Copy link
Contributor Author

cpaca commented Jul 10, 2024

It wouldn't, due to the last commit I put in

@cpaca
Copy link
Contributor Author

cpaca commented Jul 10, 2024

Correction: It never would have, since PlayerInventory.getContents() doesn't (to my knowledge) return the offhand

@dlee13
Copy link
Owner

dlee13 commented Jul 10, 2024

From checking the javadocs, PlayerInventory inherits getContents from Inventory, and that does return every slot

@cpaca
Copy link
Contributor Author

cpaca commented Jul 10, 2024

From what I can tell (both googling and checking docs) it doesn't return getArmorContents?

@cpaca
Copy link
Contributor Author

cpaca commented Jul 10, 2024

It also doesn't return getExtraContents but I can't figure out what's in extraContents

@dlee13
Copy link
Owner

dlee13 commented Jul 10, 2024

Indexes 36 through 39 are the armor slots. Index 40 is the offhand slot. And getContents returns the entire ItemStack array. That includes what getExtraContents would return. For a player, getExtraContents would probably be the crafting slots and crafting result slot. Those are probably after index 40.

@cpaca
Copy link
Contributor Author

cpaca commented Jul 10, 2024

Interesting!

Either way, with the last commit I pushed, it doesn't matter since onion ring only deletes your weapon (and itself) if keepInventory is off

@dlee13 dlee13 changed the title Make Momento Actually Decent Make Momento stackable and update recipe Jul 10, 2024
@dlee13 dlee13 merged commit c0c4119 into dlee13:main Jul 10, 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