mirror of
https://github.com/jpenilla/MiniMOTD.git
synced 2026-11-07 01:42:36 -05:00
Compare commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
21b991b313 | ||
|
|
3720fec2f5 | ||
|
|
6fe11c729a | ||
|
|
c1e40216d4 | ||
|
|
b04de1b951 | ||
|
|
5673730693 |
No files matched your search
@@ -0,0 +1,32 @@
|
||||
---
|
||||
name: Bug Report
|
||||
about: Report a bug
|
||||
title: "[Bug Report] This happens when another thing should have"
|
||||
labels: bug
|
||||
assignees: ''
|
||||
|
||||
---
|
||||
|
||||
**Describe the bug**
|
||||
A clear and concise description of what the bug is.
|
||||
|
||||
**To Reproduce**
|
||||
Steps to reproduce the behavior:
|
||||
1. Dig straight down
|
||||
2. Right click 5 times
|
||||
3. Craft a Netherite Hoe
|
||||
4. See error
|
||||
|
||||
**Expected behavior**
|
||||
A clear and concise description of what you expected to happen.
|
||||
|
||||
**Screenshots**
|
||||
If applicable, add screenshots to help explain your problem.
|
||||
|
||||
**Server Software and Version:**
|
||||
- Vendor: [e.g. Paper, Spigot, Tuinity, Velocity, BungeeCord, Waterfall]
|
||||
- Minecraft Version: [e.g. 1.15.2, 1.16.3]
|
||||
- Output of /version command: [e.g. This server is running Paper version git-Paper-53 (MC: 1.16.1) (Implementing API version 1.16.1-R0.1-SNAPSHOT)]
|
||||
|
||||
**Additional context**
|
||||
Add any other context about the problem here.
|
||||
@@ -0,0 +1,20 @@
|
||||
---
|
||||
name: Feature Request
|
||||
about: Suggest a feature
|
||||
title: "[Feature Request] My Feature"
|
||||
labels: enhancement
|
||||
assignees: ''
|
||||
|
||||
---
|
||||
|
||||
**Is your feature request related to a problem? Please describe.**
|
||||
A clear and concise description of what the problem is. Ex. I'm always frustrated when [...]
|
||||
|
||||
**Describe the solution you'd like**
|
||||
A clear and concise description of what you want to happen.
|
||||
|
||||
**Describe alternatives you've considered**
|
||||
A clear and concise description of any alternative solutions or features you've considered.
|
||||
|
||||
**Additional context**
|
||||
Add any other context or screenshots about the feature request here.
|
||||
@@ -8,7 +8,7 @@
|
||||
<parent>
|
||||
<groupId>xyz.jpenilla</groupId>
|
||||
<artifactId>MiniMOTD</artifactId>
|
||||
<version>1.2.1</version>
|
||||
<version>1.2.2</version>
|
||||
</parent>
|
||||
|
||||
<artifactId>MiniMOTD-bungeecord</artifactId>
|
||||
|
||||
@@ -79,13 +79,7 @@ public class BungeeCommand extends Command {
|
||||
}
|
||||
|
||||
private void send(CommandSender sender, String message) {
|
||||
final String finalMessage;
|
||||
if (sender instanceof ProxiedPlayer) {
|
||||
finalMessage = message;
|
||||
} else {
|
||||
finalMessage = miniMessage.stripTokens(message);
|
||||
}
|
||||
sender.sendMessage(BungeeCordComponentSerializer.get().serialize(miniMessage.parse(finalMessage)));
|
||||
sender.sendMessage(BungeeCordComponentSerializer.get().serialize(miniMessage.parse(message)));
|
||||
}
|
||||
|
||||
private void send(CommandSender sender, List<String> messages) {
|
||||
|
||||
@@ -6,8 +6,6 @@ import net.md_5.bungee.api.plugin.Plugin;
|
||||
import org.bstats.bungeecord.Metrics;
|
||||
import xyz.jpenilla.minimotd.common.UpdateChecker;
|
||||
|
||||
import java.util.concurrent.ExecutionException;
|
||||
|
||||
public class MiniMOTD extends Plugin {
|
||||
@Getter private BungeeConfig cfg;
|
||||
@Getter private BungeeAudiences audiences;
|
||||
@@ -20,10 +18,8 @@ public class MiniMOTD extends Plugin {
|
||||
getProxy().getPluginManager().registerCommand(this, new BungeeCommand(this));
|
||||
Metrics metrics = new Metrics(this, 8137);
|
||||
|
||||
try {
|
||||
new UpdateChecker(this.getDescription().getVersion()).checkVersion().get().forEach(message -> getLogger().info(message));
|
||||
} catch (InterruptedException | ExecutionException e) {
|
||||
getLogger().info("failed to check for update: " + e.getMessage());
|
||||
if (cfg.isUpdateChecker()) {
|
||||
new UpdateChecker(this.getDescription().getVersion()).checkVersion().whenCompleteAsync((messages, t) -> messages.forEach(message -> getLogger().info(message)));
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -7,7 +7,7 @@
|
||||
<parent>
|
||||
<groupId>xyz.jpenilla</groupId>
|
||||
<artifactId>MiniMOTD</artifactId>
|
||||
<version>1.2.1</version>
|
||||
<version>1.2.2</version>
|
||||
</parent>
|
||||
|
||||
<artifactId>MiniMOTD-common</artifactId>
|
||||
@@ -54,7 +54,7 @@
|
||||
<dependency>
|
||||
<groupId>com.github.jmanpenilla</groupId>
|
||||
<artifactId>adventure-text-minimessage</artifactId>
|
||||
<version>test-MiniMessage-2.1.0-g341ae62-35</version>
|
||||
<version>571d2f4408</version>
|
||||
<scope>compile</scope>
|
||||
</dependency>
|
||||
<dependency>
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
# Do you want the plugin to check for updated on GitHub on launch?
|
||||
# Do you want the plugin to check for updates on GitHub at launch?
|
||||
# https://github.com/jmanpenilla/MiniMOTD
|
||||
updateChecker: true
|
||||
|
||||
|
||||
@@ -9,7 +9,7 @@
|
||||
<parent>
|
||||
<groupId>xyz.jpenilla</groupId>
|
||||
<artifactId>MiniMOTD</artifactId>
|
||||
<version>1.2.1</version>
|
||||
<version>1.2.2</version>
|
||||
</parent>
|
||||
|
||||
<artifactId>MiniMOTD-spigot</artifactId>
|
||||
|
||||
@@ -8,8 +8,6 @@ import org.bukkit.command.PluginCommand;
|
||||
import org.bukkit.plugin.java.JavaPlugin;
|
||||
import xyz.jpenilla.minimotd.common.UpdateChecker;
|
||||
|
||||
import java.util.concurrent.ExecutionException;
|
||||
|
||||
public final class MiniMOTD extends JavaPlugin {
|
||||
@Getter private static MiniMOTD instance;
|
||||
@Getter private SpigotConfig cfg;
|
||||
@@ -55,10 +53,8 @@ public final class MiniMOTD extends JavaPlugin {
|
||||
|
||||
Metrics metrics = new Metrics(this, 8132);
|
||||
|
||||
try {
|
||||
new UpdateChecker(this.getDescription().getVersion()).checkVersion().get().forEach(message -> getLogger().info(message));
|
||||
} catch (InterruptedException | ExecutionException e) {
|
||||
getLogger().info("failed to check for update: " + e.getMessage());
|
||||
if (cfg.isUpdateChecker()) {
|
||||
new UpdateChecker(this.getDescription().getVersion()).checkVersion().whenCompleteAsync((messages, m) -> messages.forEach(message -> getLogger().info(message)));
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -87,7 +87,7 @@ public class SpigotCommand implements CommandExecutor, TabCompleter {
|
||||
if (sender instanceof Player) {
|
||||
miniMOTD.getAudiences().player((Player) sender).sendMessage(miniMessage.parse(message));
|
||||
} else {
|
||||
miniMOTD.getAudiences().console().sendMessage(miniMessage.parse(miniMessage.stripTokens(message)));
|
||||
miniMOTD.getAudiences().console().sendMessage(miniMessage.parse(message));
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -5,7 +5,7 @@
|
||||
<parent>
|
||||
<artifactId>MiniMOTD</artifactId>
|
||||
<groupId>xyz.jpenilla</groupId>
|
||||
<version>1.2.1</version>
|
||||
<version>1.2.2</version>
|
||||
</parent>
|
||||
<modelVersion>4.0.0</modelVersion>
|
||||
|
||||
@@ -16,19 +16,19 @@
|
||||
<dependency>
|
||||
<groupId>xyz.jpenilla</groupId>
|
||||
<artifactId>MiniMOTD-spigot</artifactId>
|
||||
<version>1.2.1</version>
|
||||
<version>1.2.2</version>
|
||||
<scope>compile</scope>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>xyz.jpenilla</groupId>
|
||||
<artifactId>MiniMOTD-bungeecord</artifactId>
|
||||
<version>1.2.1</version>
|
||||
<version>1.2.2</version>
|
||||
<scope>compile</scope>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>xyz.jpenilla</groupId>
|
||||
<artifactId>MiniMOTD-velocity</artifactId>
|
||||
<version>1.2.1</version>
|
||||
<version>1.2.2</version>
|
||||
<scope>compile</scope>
|
||||
</dependency>
|
||||
</dependencies>
|
||||
|
||||
@@ -7,7 +7,7 @@
|
||||
<parent>
|
||||
<groupId>xyz.jpenilla</groupId>
|
||||
<artifactId>MiniMOTD</artifactId>
|
||||
<version>1.2.1</version>
|
||||
<version>1.2.2</version>
|
||||
</parent>
|
||||
|
||||
<artifactId>MiniMOTD-velocity</artifactId>
|
||||
|
||||
@@ -19,13 +19,12 @@ import org.slf4j.Logger;
|
||||
import xyz.jpenilla.minimotd.common.UpdateChecker;
|
||||
|
||||
import java.nio.file.Path;
|
||||
import java.util.concurrent.ExecutionException;
|
||||
import java.util.concurrent.ThreadLocalRandom;
|
||||
|
||||
@Plugin(
|
||||
id = "minimotd-velocity",
|
||||
name = "MiniMOTD",
|
||||
version = "1.2.1",
|
||||
version = "1.2.2",
|
||||
description = "Set the server list MOTD using MiniMessage!",
|
||||
url = "https://github.com/jmanpenilla/MiniMOTD/",
|
||||
authors = {"jmp"}
|
||||
@@ -58,10 +57,8 @@ public class MiniMOTD {
|
||||
this.commandManager.register(this.commandManager.metaBuilder("minimotdvelocity").build(), new VelocityCommand(this));
|
||||
this.cfg.reload();
|
||||
|
||||
try {
|
||||
new UpdateChecker(this.getPluginDescription().getVersion().orElse("")).checkVersion().get().forEach(this.logger::info);
|
||||
} catch (InterruptedException | ExecutionException e) {
|
||||
this.logger.info("failed to check for update: " + e.getMessage());
|
||||
if (cfg.isUpdateChecker()) {
|
||||
new UpdateChecker(this.getPluginDescription().getVersion().orElse("")).checkVersion().whenCompleteAsync((messages, t) -> messages.forEach(this.logger::info));
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user