Skip to content

Conversation

@Sakeran
Copy link
Contributor

@Sakeran Sakeran commented Apr 18, 2019

This closes #50 by adding an eventOnly config option to the Channel class, and by firing a channelSend event on the sender of the send function.

@shawncplus shawncplus self-requested a review April 18, 2019 15:56
* @param {Channel} channel
* @param {string} rawMessage
*/
sender.emit('channelSend', this, rawMessage);

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This PR has been open for a bit and I recently merged it into my local fork and tried using it. One thing that stood out is that it may be helpful to actually emit this on the audience if possible... Mainly, I would like to handle sending to different audience members in different ways depending on whether they use telnet or webclient.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hmm, on second thought, it is still possible to do with the way this is set up. The one thing it may make a bit harder is having NPCs use the channels but that can be done with a behavior.

@shawncplus shawncplus added this to the 3.1 milestone Aug 22, 2019
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.

Channel should trigger a channelSend event on sender

3 participants