multification
2 min read
Introduction
Powerful library for sending custom notifications based on Adventure API
Powerful library for sending custom notifications based on Adventure API
Multification is a state-of-the-art clean, type-safe API that easily allows sending chat messages, titles, actionbars, bossbars, and sounds – all from a single, configurable Notice object.
| Platform | Module | Java | Adventure |
|---|---|---|---|
| Paper 1.19.4+ | multification-paper | 21 | Native |
| Bukkit/Spigot | multification-bukkit | 8+ | Adapter |
| Custom | multification-core | 8+ | DIY |
// 1. Extend platform class
public class MyMultification extends PaperMultification<MessagesConfig> {
private final MessagesConfig config;
@Override
protected TranslationProvider<MessagesConfig> translationProvider() {
return locale -> config;
}
@Override
protected ComponentSerializer<Component, Component, String> serializer() {
return MiniMessage.miniMessage();
}
@Override
protected AudienceConverter<CommandSender> audienceConverter() {
return new PaperAudienceConverter();
}
}
// 2. Send messages
multification.create()
.player(playerUUID)
.notice(config -> config.welcomeMessage)
.placeholder("{player}", player.getName())
.send();