Skip to content

Some viewer-related fixes#4030

Merged
Faithcaio merged 2 commits intoSpongePowered:api-11from
MrHell228:api-11-minor-viewer-fix
Jun 23, 2024
Merged

Some viewer-related fixes#4030
Faithcaio merged 2 commits intoSpongePowered:api-11from
MrHell228:api-11-minor-viewer-fix

Conversation

@MrHell228
Copy link
Contributor

@MrHell228 MrHell228 commented Jun 14, 2024

Viewer#sendWorldType():

  • DimensionType effects are contained in ClientLevel#effects so we need to modify it instead of modifying actual DimensionType
  • Removed implements LevelBridge from ClientLevelMixin because LevelMixin already implements it

BookItemStackData:

  • Don't know if we want to expose WrittenBookContent or keep current keys but for now I just made it working with current stuff

BookUtil:

  • There is no more need to manually localize book content because it's done on client
  • bookSlot was changed from inventory.items.size() + inventory.selected to inventory.selected and container id was changed from 0 to -2 because the only reason it works now is that (picture) size of red area (inventoryMenu indexing) luckily equals to size of blue area (inventory.items.size()). -2 stands for Player#inventory and first 9 items in it is hotbar
    image

@MrHell228 MrHell228 changed the title Some Viewer fixes Some viewer-related fixes Jun 17, 2024
@Faithcaio Faithcaio merged commit 61a1982 into SpongePowered:api-11 Jun 23, 2024
@MrHell228 MrHell228 deleted the api-11-minor-viewer-fix branch June 23, 2024 22:48
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