Skip to content

Commit

Permalink
Improved /bfc info command
Browse files Browse the repository at this point in the history
  • Loading branch information
abc123me committed Dec 11, 2022
1 parent 2985850 commit e8cc5f5
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 7 deletions.
2 changes: 1 addition & 1 deletion src/main/java/com/jeremiahbl/bfcmod/BetterForgeChat.java
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
@Mod(BetterForgeChat.MODID)
public class BetterForgeChat {
public static final String CHAT_ID_STR =
"&cBetter &9&lForge &eChat&r &d(c) Jeremiah Lowe 2022-2023&r\n";
"&cBetter &9&lForge&r &eChat&r &d(c) Jeremiah Lowe 2022-2023&r\n";
public static final String MODID = "bfcmod";
public static final String VERSION = "V1.2.1";
public static final Logger LOGGER = LogUtils.getLogger();
Expand Down
12 changes: 6 additions & 6 deletions src/main/java/com/jeremiahbl/bfcmod/commands/BfcCommands.java
Original file line number Diff line number Diff line change
Expand Up @@ -62,13 +62,13 @@ public static int modCommand(CommandContext<CommandSourceStack> ctx) {
boolean hasMetaProv = BetterForgeChat.instance.metadataProvider != null;
boolean hasNickProv = BetterForgeChat.instance.nicknameProvider != null;
String metaProvName = hasMetaProv ? BetterForgeChat.instance.metadataProvider.getProviderName() : "";
String nickProvName = hasNickProv ? BetterForgeChat.instance.metadataProvider.getProviderName() : "";
if(hasMetaProv) metaProvName = "(via " + metaProvName + ")";
if(hasNickProv) nickProvName = "(via " + nickProvName + ")";
String nickProvName = hasNickProv ? BetterForgeChat.instance.nicknameProvider.getProviderName() : "";
if(hasMetaProv) metaProvName = " (via " + metaProvName + ")";
if(hasNickProv) nickProvName = " (via " + nickProvName + ")";
ctx.getSource().sendSuccess(TextFormatter.stringToFormattedText(
BetterForgeChat.CHAT_ID_STR + "&e" + BetterForgeChat.MODID + " " + BetterForgeChat.VERSION + "&r\n"
+ (hasMetaProv ? "&a&lWITH" : "&c&lWITHOUT") + "&r&e metadata integration" + metaProvName + "&r\n"
+ (hasNickProv ? "&a&lWITH" : "&c&lWITHOUT") + "&r&e nickname integration" + nickProvName + "&r\n"), false);
BetterForgeChat.CHAT_ID_STR + "\n&eMod ID: &d" + BetterForgeChat.MODID + " &r&eMod version: &d" + BetterForgeChat.VERSION + " (forge)&r\n\n"
+ (hasMetaProv ? "&a&lWITH" : "&c&lWITHOUT") + "&r&e metadata integration" + metaProvName + "&r\n"
+ (hasNickProv ? "&a&lWITH" : "&c&lWITHOUT") + "&r&e nickname integration" + nickProvName + "&r\n"), false);
return 1;
} else return failNoPermission(ctx);
} else if(arg.contentEquals("test")) {
Expand Down

0 comments on commit e8cc5f5

Please sign in to comment.