ModsJava
MOTD Ping API
Java mod listed for Minecraft 1.8–1.12. Downloads from the MC Java Mods app on Android.
⬇ Download on SpigotHow to use this API
add to your OnEnable()
Implement all the Plugin Wants, from com.designlyi.motdapi
now you should have a new Method in your Main class wich Looks like this one.
Now you can add this example to look if Everithing is working.
I Hope my API did Help you.
Maybe Leave a Rating <3
If you Liked this API maybe you want to support me
add to your OnEnable()
Code (Text):
@Override
public void onEnable() {
MOTDAPI.registerListener(this);
}
public void onEnable() {
MOTDAPI.registerListener(this);
}
now you should have a new Method in your Main class wich Looks like this one.
Code (Text):
@Override
public void onPing(PingEvent e) {
}
public void onPing(PingEvent e) {
}
I Hope my API did Help you.
Maybe Leave a Rating <3
Code (Text):
@Override
public void onPing(PingEvent e) {
PingReply reply = e.getReply();
reply.setMaxPlayers(new Random().nextInt(999));
reply.setOnlinePlayers(new Random().nextInt(999));
reply.setMOTD("Line 1" + "\n" + "Line 2);
List<String> sample = new LinkedList<String>();
sample.add("§4MaintenanceMode!");
reply.setPlayerSample(sample);
reply.setProtocolName("§4Maintenance!");
reply.setProtocolVersion(2);
}
public void onPing(PingEvent e) {
PingReply reply = e.getReply();
reply.setMaxPlayers(new Random().nextInt(999));
reply.setOnlinePlayers(new Random().nextInt(999));
reply.setMOTD("Line 1" + "\n" + "Line 2);
List<String> sample = new LinkedList<String>();
sample.add("§4MaintenanceMode!");
reply.setPlayerSample(sample);
reply.setProtocolName("§4Maintenance!");
reply.setProtocolVersion(2);
}
Quick facts
- Edition: Minecraft Java
- File type: .jar
- Minecraft versions listed: 1.8, 1.9, 1.10
- How to install: Install the matching mod loader (Forge, Fabric or NeoForge) for your Minecraft version. → Download the .jar. → Put it in the .minecraft/mods folder and launch that loader profile.
- Where to get it: Opens on Spigot — not every file is mirrored on our own servers.
Install steps are the general flow for this file type — How to install Minecraft Java mods & modpacks walks through it step by step.
MOTD Ping API is a free Minecraft Java mod. Compatible with Minecraft 1.8, 1.9, 1.10, 1.11 and newer. Downloaded 320 times (via Spigot). Download it and open it directly in the game.