feat: custom prefix system protocol layer

Prefix parsers, composers and events:
- UserPrefixesParser, PrefixReceivedParser, ActivePrefixUpdatedParser
- PurchasePrefixComposer, SetActivePrefixComposer, DeletePrefixComposer, RequestPrefixesComposer
- RoomUnitChatParser reads prefixText/Color/Icon/Effect from chat packets
- RoomSessionChatEvent carries prefix data to client
- RoomChatHandler passes prefix fields through event chain
This commit is contained in:
simoleo89
2026-03-20 17:22:50 +01:00
committed by Life
parent 958693fe2e
commit ae0773706d
23 changed files with 367 additions and 5 deletions
@@ -37,7 +37,7 @@ export class RoomChatHandler extends BaseHandler
if(event instanceof RoomUnitChatShoutEvent) chatType = RoomSessionChatEvent.CHAT_TYPE_SHOUT;
else if(event instanceof RoomUnitChatWhisperEvent) chatType = RoomSessionChatEvent.CHAT_TYPE_WHISPER;
const chatEvent = new RoomSessionChatEvent(RoomSessionChatEvent.CHAT_EVENT, session, parser.roomIndex, parser.message, chatType, parser.bubble, parser.chatColours);
const chatEvent = new RoomSessionChatEvent(RoomSessionChatEvent.CHAT_EVENT, session, parser.roomIndex, parser.message, chatType, parser.bubble, parser.chatColours, null, -1, parser.prefixText, parser.prefixColor, parser.prefixIcon, parser.prefixEffect);
GetEventDispatcher().dispatchEvent(chatEvent);
}