Class MuteSender
java.lang.Object
net.flectone.pulse.platform.sender.MuteSender
Sends mute notifications to players when they attempt to chat while muted.
Usage example:
MuteSender muteSender = flectonePulse.get(MuteSender.class);
// Check if player is muted and send notification
if (muteSender.sendIfMuted(player)) {
// Player is muted, message sent
}
- Since:
- 1.6.0
-
Constructor Summary
ConstructorsConstructorDescriptionMuteSender(MuteChecker muteChecker, MessagePipeline messagePipeline, ModerationMessageFormatter moderationMessageFormatter, EventDispatcher eventDispatcher) -
Method Summary
Modifier and TypeMethodDescriptionbooleansendIfMuted(FEntity entity) Checks if a player is muted and sends a mute notification.
-
Constructor Details
-
MuteSender
@Inject public MuteSender(MuteChecker muteChecker, MessagePipeline messagePipeline, ModerationMessageFormatter moderationMessageFormatter, EventDispatcher eventDispatcher)
-
-
Method Details
-
sendIfMuted
Checks if a player is muted and sends a mute notification. Only sends messages to players, not other entities.- Parameters:
entity- the entity to check- Returns:
- true if player is muted and notification was sent, false otherwise
-