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

Investigate bridging Fabric Message API with Quilt Chat API #72

Open
EnnuiL opened this issue Feb 13, 2023 · 5 comments
Open

Investigate bridging Fabric Message API with Quilt Chat API #72

EnnuiL opened this issue Feb 13, 2023 · 5 comments
Labels
enhancement New feature or request

Comments

@EnnuiL
Copy link

EnnuiL commented Feb 13, 2023

While both appears to be besties so far? I do believe it's possible for one to be bridged to the another, since the latter appears to be a weird subset of the former

@EnnuiL EnnuiL added the enhancement New feature or request label Feb 13, 2023
@EnnuiL EnnuiL changed the title Investigate bridging Quilt Chat API with Fabric Message API Investigate bridging Fabric Message API with Quilt Chat API Feb 15, 2023
@JaaiDead
Copy link

so i have a question that what goes wrong?

@BeetMacol
Copy link

Fabric message events (CHAT_MESSAGE, GAME_MESSAGE and COMMAND_MESSAGE) are not analogous to the Quilt chat message types (CHAT, SYSTEM, PROFILE_INDEPENDENT). While some similarity exists, the differences are huge. For example, Quilt's CHAT is invoked on both normal chat messages and commands like /me while Fabric's CHAT_MESSAGE is invoked on player-sent chat messages and /msg, but for /me and /say COMMAND_MESSAGE is used instead. Also Fabric Message API seems to be server-side only while Quilt invokes the events on client too and even provides functionality (SERVER and CLIENT event types) to distinguish them.

Because of that, converting Fabric message events to Quilt ones might be tedious and hard to maintain. Slight changes in Minecraft chat and command output code may require changes in QFAPI. QSL Chat API supports a wider range of messages though and therefore creating such bridge would be beneficial for compatibility with Fabric mods.

@SilverAndro
Copy link

SilverAndro commented Feb 17, 2023

Quilt's CHAT is invoked on both normal chat messages and commands like /me

Only in the case of RawChatC2SMessage, as that is the raw message before any handling on the client side (and therefore includes all commands). Otherwise commands are not covered at all in quilt's api.

@EnnuiL
Copy link
Author

EnnuiL commented Feb 19, 2023

Ah, that was the investigation that I wanted to see! Hm, yeah, maybe a bridging between both APIs shouldn't be a high priority right now, but if it's feasible? It could be done

@SilverAndro
Copy link

well certainly dont go investigating right now haha

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

4 participants