KubeJS

KubeJS

69M Downloads

Add message type and other properties to PlayerChatEventJS

NatSquared opened this issue ยท 0 comments

commented

Describe the feature

When getting a message in KubeJS, there is currently no way to differentiate between a global chat message, /me command, whisper/PM, and a team message (/tm).
PlayerChatEventJS should have a "type" property or similar with information about what kind of message it is, so scripts can handle it properly.
Also, for private messages, there should be a nullable EntityJS target (or EntityArray of targets). Maybe also include a team property for team messages (but this will always be the same as the sending player's team)

Additional info

Current workarounds include replacing the /w, /me, and /msg commands using command.registry but this is somewhat tedious and difficult