diff --git a/README.md b/README.md index 4b83a690..c75a5fa4 100644 --- a/README.md +++ b/README.md @@ -23,6 +23,19 @@ Java bot with many features. Developed by @CodeDoctorDE (Discord: CodeDoctor#871 ### What is it? Guess what word the writer has chosen. This is a turn based game. Every player can join in. +# Contributing + +To contribute, fork this repository and create a pull request. If you want you can also join my discord. If you contribute more, you can get the contributor role. + +## Branches + +Name | Description +--- | --- +feature/* | Every new feature will developed here +hotfix/* | Fixing bugs will be developed here +master | Every feature and hotfix will be merged here +stable | Stable changes will be merged here + # Current servers You can visit my bot on this servers: * [KniffelGames](https://discord.gg/J7EUgvN) diff --git a/pom.xml b/pom.xml index 215f9662..8edd6384 100644 --- a/pom.xml +++ b/pom.xml @@ -6,7 +6,7 @@ com.github.codedoctorde linwood - 1.0.2 + 1.0.3 11 UTF-8 diff --git a/src/main/java/com/github/codedoctorde/linwood/apps/single/game/mode/tictactoe/TicTacToe.java b/src/main/java/com/github/codedoctorde/linwood/apps/single/game/mode/tictactoe/TicTacToe.java index 5bedb972..84b379ed 100644 --- a/src/main/java/com/github/codedoctorde/linwood/apps/single/game/mode/tictactoe/TicTacToe.java +++ b/src/main/java/com/github/codedoctorde/linwood/apps/single/game/mode/tictactoe/TicTacToe.java @@ -57,8 +57,8 @@ public void start(SingleApplication app) { var bundle = getBundle(session); Category finalCategory = category; ChannelAction action; - action = finalCategory == null ?game.getGuild().createTextChannel(MessageFormat.format(bundle.getString("TextChannel"),game.getId())): - finalCategory.createTextChannel(MessageFormat.format(bundle.getString("TextChannel"),game.getId())); + action = finalCategory == null ?game.getGuild().createTextChannel(String.format(bundle.getString("TextChannel"),game.getId())): + finalCategory.createTextChannel(String.format(bundle.getString("TextChannel"),game.getId())); session.close(); action.queue((textChannel -> { this.textChannelId = textChannel.getIdLong(); diff --git a/src/main/java/com/github/codedoctorde/linwood/apps/single/game/mode/whatisit/WhatIsIt.java b/src/main/java/com/github/codedoctorde/linwood/apps/single/game/mode/whatisit/WhatIsIt.java index 5ab721ae..2e4051a4 100644 --- a/src/main/java/com/github/codedoctorde/linwood/apps/single/game/mode/whatisit/WhatIsIt.java +++ b/src/main/java/com/github/codedoctorde/linwood/apps/single/game/mode/whatisit/WhatIsIt.java @@ -46,16 +46,12 @@ public void start(SingleApplication app) { var guild = GuildEntity.get(session, game.getGuildId()); Category category = null; if(guild.getGameEntity().getGameCategoryId() != null) - category = guild.getGameEntity().getGameCategory(); + category = guild.getGameEntity().getGameCategory(); var bundle = getBundle(session); Category finalCategory = category; - ChannelAction action; - if(finalCategory == null) - action = game.getGuild().createTextChannel(MessageFormat.format(bundle.getString("TextChannel"),game.getId())); - else - action = finalCategory.createTextChannel(MessageFormat.format(bundle.getString("TextChannel"),game.getId())); session.close(); - action.queue((textChannel -> { + ((finalCategory == null)?game.getGuild().createTextChannel(String.format(bundle.getString("TextChannel"),game.getId())): + finalCategory.createTextChannel(String.format(bundle.getString("TextChannel"),game.getId()))).queue((textChannel -> { this.textChannelId = textChannel.getIdLong(); if(finalCategory != null) textChannel.getManager().setParent(finalCategory).queue(); @@ -84,10 +80,10 @@ public void chooseNextPlayer(){ var session = Linwood.getInstance().getDatabase().getSessionFactory().openSession(); var bundle = getBundle(session); sendLeaderboard(session); - getTextChannel().sendMessage(MessageFormat.format(bundle.getString("Next"), currentRound + 1)).queue(message -> { + getTextChannel().sendMessageFormat(bundle.getString("Next"), currentRound + 1).queue(message -> { wantWriterMessageId = message.getIdLong(); message.addReaction("\uD83D\uDD90️").queue(aVoid -> - message.addReaction("⛔").queue()); + message.addReaction("⛔").queue()); stopTimer(); timer.schedule(new TimerTask() { @Override @@ -117,7 +113,7 @@ public void nextRound(Session session, long writerId){ var bundle = getBundle(session); game.getGuild().retrieveMemberById(writerId).queue(member -> { var session1 = Linwood.getInstance().getDatabase().getSessionFactory().openSession(); - getTextChannel().sendMessage(MessageFormat.format(bundle.getString("Round"), member.getAsMention())).queue(); + getTextChannel().sendMessageFormat(bundle.getString("Round"), member.getAsMention()).queue(); sendLeaderboard(session1); session1.close(); round.inputWriter(); @@ -164,7 +160,7 @@ public void finishRound(){ wantWriter.clear(); if(currentRound >= maxRounds) finishGame(); else - chooseNextPlayer(); + chooseNextPlayer(); session.close(); }); } @@ -182,16 +178,16 @@ private void sendLeaderboard(ResourceBundle bundle, TextChannel textChannel){ var leaderboard = getLeaderboard(); if(textChannel == null) return; - textChannel.getGuild().retrieveMembersByIds(leaderboard.stream().map(Map.Entry::getKey).collect(Collectors.toList())).onSuccess(members -> { - StringBuilder stringBuilder = new StringBuilder(); - for (int i = 0; i < members.size(); i++) { - var member = members.get(i); - if (member != null) - stringBuilder.append(MessageFormat.format(bundle.getString("Leaderboard"), i + 1, - member.getAsMention(), leaderboard.get(i).getValue())); - } - textChannel.sendMessage(new EmbedBuilder().setTitle(bundle.getString("LeaderboardHeader")).setDescription(stringBuilder.toString()).setFooter(bundle.getString("LeaderboardFooter")).build()).queue(); - }); + textChannel.getGuild().retrieveMembersByIds(leaderboard.stream().map(Map.Entry::getKey).collect(Collectors.toList())).onSuccess(members -> { + StringBuilder stringBuilder = new StringBuilder(); + for (int i = 0; i < members.size(); i++) { + var member = members.get(i); + if (member != null) + stringBuilder.append(String.format(bundle.getString("Leaderboard"), i + 1, + member.getAsMention(), leaderboard.get(i).getValue())); + } + textChannel.sendMessage(new EmbedBuilder().setTitle(bundle.getString("LeaderboardHeader")).setDescription(stringBuilder.toString()).setFooter(bundle.getString("LeaderboardFooter")).build()).queue(); + }); } private ArrayList> getLeaderboard() { @@ -251,12 +247,12 @@ public boolean wantWriter(Session session, Member member) { if(getRound() != null) return false; wantWriter.add(member.getIdLong()); - getTextChannel().sendMessage(MessageFormat.format(getBundle(session).getString("Join"), member.getUser().getAsMention())).queue(); + getTextChannel().sendMessageFormat(getBundle(session).getString("Join"), member.getUser().getAsMention()).queue(); return true; } public void removeWriter(Session session, Member member) { wantWriter.remove(member.getIdLong()); - getTextChannel().sendMessage(MessageFormat.format(getBundle(session).getString("Leave"), member.getUser().getAsMention())).queue(); + getTextChannel().sendMessageFormat(getBundle(session).getString("Leave"), member.getUser().getAsMention()).queue(); } } diff --git a/src/main/java/com/github/codedoctorde/linwood/apps/single/game/mode/whatisit/WhatIsItEvents.java b/src/main/java/com/github/codedoctorde/linwood/apps/single/game/mode/whatisit/WhatIsItEvents.java index 4328c04a..a59532e9 100644 --- a/src/main/java/com/github/codedoctorde/linwood/apps/single/game/mode/whatisit/WhatIsItEvents.java +++ b/src/main/java/com/github/codedoctorde/linwood/apps/single/game/mode/whatisit/WhatIsItEvents.java @@ -6,6 +6,7 @@ import net.dv8tion.jda.api.events.message.MessageReceivedEvent; import net.dv8tion.jda.api.events.message.react.MessageReactionAddEvent; import net.dv8tion.jda.api.events.message.react.MessageReactionRemoveEvent; +import net.dv8tion.jda.api.exceptions.PermissionException; import net.dv8tion.jda.api.hooks.SubscribeEvent; import java.text.MessageFormat; @@ -21,9 +22,9 @@ public WhatIsItEvents(WhatIsIt whatIsIt){ } @SubscribeEvent public void onGuess(MessageReceivedEvent event){ - try { + try{ if (event.getChannel().getIdLong() != whatIsIt.getTextChannelId() || event.getMember() == null) - ; + return; var session = Linwood.getInstance().getDatabase().getSessionFactory().openSession(); var message = event.getMessage(); if (whatIsIt.getTextChannelId() == message.getTextChannel().getIdLong()){ @@ -31,7 +32,7 @@ public void onGuess(MessageReceivedEvent event){ if (round != null && round.getWord() != null && message.getContentStripped().toLowerCase().contains(round.getWord().toLowerCase())) { message.delete().queue(); if (!round.isGuesser(event.getMember()) && message.getAuthor().getIdLong() != round.getWriterId()) - event.getChannel().sendMessage(MessageFormat.format(whatIsIt.getBundle(session).getString("Guess"), event.getAuthor().getName(), round.guessCorrectly(event.getMember()))).queue(message1 -> { + event.getChannel().sendMessageFormat(whatIsIt.getBundle(session).getString("Guess"), event.getAuthor().getName(), round.guessCorrectly(event.getMember())).queue(message1 -> { var session1 = Linwood.getInstance().getDatabase().getSessionFactory().openSession(); round.checkEverybody(session1); session1.close(); @@ -40,6 +41,9 @@ public void onGuess(MessageReceivedEvent event){ } session.close(); } + catch(PermissionException e){ + e.printStackTrace(); + } catch(Exception e){ e.printStackTrace(); Sentry.capture(e); @@ -51,6 +55,9 @@ public void onWord(MessageReceivedEvent event) { if (event.getChannelType() == ChannelType.PRIVATE && whatIsIt.getRound() != null && whatIsIt.getRound().getWriterId() == event.getAuthor().getIdLong() && whatIsIt.getRound().getWord() == null) whatIsIt.getRound().startRound(event.getMessage().getContentStripped()); } + catch(PermissionException e){ + e.printStackTrace(); + } catch(Exception e){ e.printStackTrace(); Sentry.capture(e); @@ -83,6 +90,9 @@ public void onJoin(MessageReactionAddEvent event){ session.close(); }); } + catch(PermissionException e){ + e.printStackTrace(); + } catch(Exception e){ e.printStackTrace(); Sentry.capture(e); @@ -99,6 +109,9 @@ public void onLeave(MessageReactionRemoveEvent event){ session.close(); }); } + catch(PermissionException e){ + e.printStackTrace(); + } catch(Exception e){ e.printStackTrace(); Sentry.capture(e); diff --git a/src/main/java/com/github/codedoctorde/linwood/apps/single/game/mode/whatisit/WhatIsItRound.java b/src/main/java/com/github/codedoctorde/linwood/apps/single/game/mode/whatisit/WhatIsItRound.java index 62e3ac11..8e2bb38e 100644 --- a/src/main/java/com/github/codedoctorde/linwood/apps/single/game/mode/whatisit/WhatIsItRound.java +++ b/src/main/java/com/github/codedoctorde/linwood/apps/single/game/mode/whatisit/WhatIsItRound.java @@ -72,7 +72,7 @@ public void run() { String message = null; switch (time) { case 120: - message = MessageFormat.format(bundle.getString("CountdownMinutes"), time / 60); + message = String.format(bundle.getString("CountdownMinutes"), time / 60); break; case 60: message = bundle.getString("CountdownMinute"); @@ -84,7 +84,7 @@ public void run() { case 4: case 3: case 2: - message = MessageFormat.format(bundle.getString("CountdownSeconds"), time); + message = String.format(bundle.getString("CountdownSeconds"), time); break; case 1: message = bundle.getString("CountdownSecond"); @@ -101,7 +101,7 @@ public void stopRound(){ var session = Linwood.getInstance().getDatabase().getSessionFactory().openSession(); var bundle = whatIsIt.getBundle(session); if(word != null) - whatIsIt.getTextChannel().sendMessage(MessageFormat.format(bundle.getString("Word"), word)).queue(); + whatIsIt.getTextChannel().sendMessageFormat(bundle.getString("Word"), word).queue(); stopTimer(); session.close(); } diff --git a/src/main/java/com/github/codedoctorde/linwood/commands/ClearCommand.java b/src/main/java/com/github/codedoctorde/linwood/commands/ClearCommand.java index a73aa7d9..0a95d0b7 100644 --- a/src/main/java/com/github/codedoctorde/linwood/commands/ClearCommand.java +++ b/src/main/java/com/github/codedoctorde/linwood/commands/ClearCommand.java @@ -33,7 +33,7 @@ public boolean onCommand(Session session, Message message, GuildEntity entity, S message.getChannel().sendMessage(bundle.getString("Between")).queue(); message.getChannel().getHistory().retrievePast(count).queue(messages -> { messages.forEach(deleteMessage -> deleteMessage.delete().queue()); - message.getChannel().sendMessage(MessageFormat.format(bundle.getString("Success"), messages.size())).queue(); + message.getChannel().sendMessageFormat(bundle.getString("Success"), messages.size()).queue(); }); return true; } diff --git a/src/main/java/com/github/codedoctorde/linwood/commands/CommandManager.java b/src/main/java/com/github/codedoctorde/linwood/commands/CommandManager.java index 2aef8fea..1d8e07d0 100644 --- a/src/main/java/com/github/codedoctorde/linwood/commands/CommandManager.java +++ b/src/main/java/com/github/codedoctorde/linwood/commands/CommandManager.java @@ -27,7 +27,7 @@ public boolean onCommand(Session session, Message message, GuildEntity entity, S if (!command.onCommand(session, message, entity, (args.length > 0) ? args[0] : "", (args.length > 0) ? Arrays.copyOfRange(args, 1, args.length) : new String[0])) - message.getChannel().sendMessage(MessageFormat.format(ResourceBundle.getBundle("locale.Command").getString("Syntax"), Objects.requireNonNull(command.getBundle(entity)).getString("Syntax"))).queue(); + message.getChannel().sendMessageFormat(ResourceBundle.getBundle("locale.Command").getString("Syntax"), Objects.requireNonNull(command.getBundle(entity)).getString("Syntax")).queue(); } else message.getChannel().sendMessage(baseBundle.getString("NoPermission")).queue(); diff --git a/src/main/java/com/github/codedoctorde/linwood/commands/InfoCommand.java b/src/main/java/com/github/codedoctorde/linwood/commands/InfoCommand.java index 5d76f85f..76cee935 100644 --- a/src/main/java/com/github/codedoctorde/linwood/commands/InfoCommand.java +++ b/src/main/java/com/github/codedoctorde/linwood/commands/InfoCommand.java @@ -36,7 +36,7 @@ public String infoFormat(Message message, GuildEntity entity, String text){ long hour = (uptime / (1000 * 60 * 60)) % 24; long days = (uptime / (1000 * 60 * 24)); var prefixes = String.join(", ", entity.getPrefixes()); - return MessageFormat.format(text, Linwood.getInstance().getVersion(), message.getAuthor().getAsMention(), prefixes.isBlank()? " ": prefixes, + return String.format(text, Linwood.getInstance().getVersion(), message.getAuthor().getAsMention(), prefixes.isBlank()? " ": prefixes, days, hour, minute, second, millis, Linwood.getInstance().getConfig().getSupportURL()); } diff --git a/src/main/java/com/github/codedoctorde/linwood/commands/PlanCommand.java b/src/main/java/com/github/codedoctorde/linwood/commands/PlanCommand.java index 81195832..68b833d2 100644 --- a/src/main/java/com/github/codedoctorde/linwood/commands/PlanCommand.java +++ b/src/main/java/com/github/codedoctorde/linwood/commands/PlanCommand.java @@ -24,7 +24,7 @@ public boolean onCommand(Session session, Message message, GuildEntity entity, S var bundle = getBundle(entity); message.getChannel().sendMessage(new EmbedBuilder() .addField(bundle.getString("Plan"), bundle.getString("Plan" + entity.getPlan().name()), false) - .addField(bundle.getString("PrefixLimitTitle"), MessageFormat.format(bundle.getString("PrefixLimitBody"), entity.getPlan().getPrefixLimit()), false) + .addField(bundle.getString("PrefixLimitTitle"), String.format(bundle.getString("PrefixLimitBody"), entity.getPlan().getPrefixLimit()), false) .build()).queue(); return true; } diff --git a/src/main/java/com/github/codedoctorde/linwood/commands/fun/DiceCommand.java b/src/main/java/com/github/codedoctorde/linwood/commands/fun/DiceCommand.java index c9e409e6..1e74b959 100644 --- a/src/main/java/com/github/codedoctorde/linwood/commands/fun/DiceCommand.java +++ b/src/main/java/com/github/codedoctorde/linwood/commands/fun/DiceCommand.java @@ -20,7 +20,7 @@ public boolean onCommand(Session session, Message message, GuildEntity entity, S if(args.length > 0) return false; var bundle = getBundle(entity); - message.getChannel().sendMessage(MessageFormat.format(bundle.getString("Output"), random.nextInt(5) + 1)).queue(); + message.getChannel().sendMessageFormat(bundle.getString("Output"), random.nextInt(5) + 1).queue(); return true; } diff --git a/src/main/java/com/github/codedoctorde/linwood/commands/karma/KarmaLeaderboardCommand.java b/src/main/java/com/github/codedoctorde/linwood/commands/karma/KarmaLeaderboardCommand.java index cb9307c5..a091d13a 100644 --- a/src/main/java/com/github/codedoctorde/linwood/commands/karma/KarmaLeaderboardCommand.java +++ b/src/main/java/com/github/codedoctorde/linwood/commands/karma/KarmaLeaderboardCommand.java @@ -28,10 +28,10 @@ public boolean onCommand(Session session, Message message, GuildEntity entity, S var leaderboard = Linwood.getInstance().getDatabase().getKarmaLeaderboard(session, message.getGuild().getIdLong()); message.getGuild().retrieveMembersByIds(Arrays.stream(leaderboard).map(MemberEntity::getMemberId).collect(Collectors.toList())).onSuccess(members -> { var description = new StringBuilder(); - description.append(bundle.getString("LeaderboardBodyStart")); + description.append(bundle.getString("LeaderboardBodyStart") + "\n"); for (int i = 0; i < members.size(); i++) { var member = members.get(i); - description.append(MessageFormat.format(bundle.getString("LeaderboardBody"), i, member.getUser().getAsMention(), leaderboard[i].getLikes() - leaderboard[i].getDislikes(), + description.append(String.format(bundle.getString("LeaderboardBody"), i + 1, member.getUser().getAsMention(), leaderboard[i].getLikes() - leaderboard[i].getDislikes(), leaderboard[i].getLikes(), leaderboard[i].getDislikes())); } description.append(bundle.getString("LeaderboardBodyEnd")); @@ -55,6 +55,6 @@ public boolean onCommand(Session session, Message message, GuildEntity entity, S @Override public @NotNull ResourceBundle getBundle(GuildEntity entity) { - return ResourceBundle.getBundle("locale.commands.karma.Leaderbaord"); + return ResourceBundle.getBundle("locale.commands.karma.Leaderboard"); } } \ No newline at end of file diff --git a/src/main/java/com/github/codedoctorde/linwood/commands/settings/game/GameCategoryCommand.java b/src/main/java/com/github/codedoctorde/linwood/commands/settings/game/GameCategoryCommand.java index 7de1086b..689272e1 100644 --- a/src/main/java/com/github/codedoctorde/linwood/commands/settings/game/GameCategoryCommand.java +++ b/src/main/java/com/github/codedoctorde/linwood/commands/settings/game/GameCategoryCommand.java @@ -26,7 +26,7 @@ public boolean onCommand(Session session, Message message, GuildEntity entity, S return false; if(args.length == 0) if(entity.getGameEntity().getGameCategoryId() != null) - message.getChannel().sendMessage(MessageFormat.format(bundle.getString("Get"), entity.getGameEntity().getGameCategory().getName(), entity.getGameEntity().getGameCategoryId())).queue(); + message.getChannel().sendMessageFormat(bundle.getString("Get"), entity.getGameEntity().getGameCategory().getName(), entity.getGameEntity().getGameCategoryId()).queue(); else message.getChannel().sendMessage(bundle.getString("GetNull")).queue(); else { @@ -50,7 +50,7 @@ else if(categories.size() > 1) } entity.getGameEntity().setGameCategory(category); entity.save(session); - message.getChannel().sendMessage(MessageFormat.format(bundle.getString("Set"), entity.getGameEntity().getGameCategory().getName(), entity.getGameEntity().getGameCategoryId())).queue(); + message.getChannel().sendMessageFormat(bundle.getString("Set"), entity.getGameEntity().getGameCategory().getName(), entity.getGameEntity().getGameCategoryId()).queue(); }catch(NullPointerException e){ message.getChannel().sendMessage(bundle.getString("NotValid")).queue(); } diff --git a/src/main/java/com/github/codedoctorde/linwood/commands/settings/game/GameMasterCommand.java b/src/main/java/com/github/codedoctorde/linwood/commands/settings/game/GameMasterCommand.java index 964637f1..5cafb51c 100644 --- a/src/main/java/com/github/codedoctorde/linwood/commands/settings/game/GameMasterCommand.java +++ b/src/main/java/com/github/codedoctorde/linwood/commands/settings/game/GameMasterCommand.java @@ -25,8 +25,10 @@ public boolean onCommand(Session session, Message message, GuildEntity entity, S if(args.length > 1) return false; if(args.length == 0) - message.getChannel().sendMessage((entity.getGameEntity().getGameCategoryId() != null)?MessageFormat.format(bundle.getString("Get"), entity.getGameEntity().getGameMasterRole().getName(), entity.getGameEntity().getGameMasterRoleId()): - bundle.getString("GetNull")).queue(); + if((entity.getGameEntity().getGameCategoryId() != null)) + message.getChannel().sendMessageFormat(bundle.getString("Get"), entity.getGameEntity().getGameMasterRole().getName(), entity.getGameEntity().getGameMasterRoleId()).queue(); + else + message.getChannel().sendMessage(bundle.getString("GetNull")).queue(); else { try { Role role = null; @@ -48,7 +50,7 @@ else if(roles.size() > 1) return true; entity.getGameEntity().setGameMasterRole(role); entity.save(session); - message.getChannel().sendMessage(MessageFormat.format(bundle.getString("Set"), entity.getGameEntity().getGameMasterRole().getName(), entity.getGameEntity().getGameMasterRoleId())).queue(); + message.getChannel().sendMessageFormat(bundle.getString("Set"), entity.getGameEntity().getGameMasterRole().getName(), entity.getGameEntity().getGameMasterRoleId()).queue(); }catch(NullPointerException e){ message.getChannel().sendMessage(bundle.getString("NotValid")).queue(); } diff --git a/src/main/java/com/github/codedoctorde/linwood/commands/settings/general/AddPrefixCommand.java b/src/main/java/com/github/codedoctorde/linwood/commands/settings/general/AddPrefixCommand.java index 431d1797..c85b7b0f 100644 --- a/src/main/java/com/github/codedoctorde/linwood/commands/settings/general/AddPrefixCommand.java +++ b/src/main/java/com/github/codedoctorde/linwood/commands/settings/general/AddPrefixCommand.java @@ -30,7 +30,7 @@ public boolean onCommand(Session session, Message message, GuildEntity entity, S return true; } entity.save(session); - message.getChannel().sendMessage(MessageFormat.format(bundle.getString("Success"), prefix)).queue(); + message.getChannel().sendMessageFormat(bundle.getString("Success"), prefix).queue(); } catch (NullPointerException e) { message.getChannel().sendMessage(bundle.getString("NotValid")).queue(); } diff --git a/src/main/java/com/github/codedoctorde/linwood/commands/settings/general/LanguageCommand.java b/src/main/java/com/github/codedoctorde/linwood/commands/settings/general/LanguageCommand.java index 1c4fc931..00e1c8df 100644 --- a/src/main/java/com/github/codedoctorde/linwood/commands/settings/general/LanguageCommand.java +++ b/src/main/java/com/github/codedoctorde/linwood/commands/settings/general/LanguageCommand.java @@ -24,12 +24,12 @@ public boolean onCommand(Session session, Message message, GuildEntity entity, S if(args.length > 1) return false; if(args.length == 0) - message.getChannel().sendMessage(MessageFormat.format(bundle.getString("Get"), entity.getLocalization().getDisplayName(entity.getLocalization()))).queue(); + message.getChannel().sendMessageFormat(bundle.getString("Get"), entity.getLocalization().getDisplayName(entity.getLocalization())).queue(); else { try { entity.setLocale(args[0]); entity.save(session); - message.getChannel().sendMessage(MessageFormat.format(bundle.getString("Set"), entity.getLocalization().getDisplayName(entity.getLocalization()))).queue(); + message.getChannel().sendMessageFormat(bundle.getString("Set"), entity.getLocalization().getDisplayName(entity.getLocalization())).queue(); }catch(NullPointerException e){ message.getChannel().sendMessage(bundle.getString("NotValid")).queue(); } diff --git a/src/main/java/com/github/codedoctorde/linwood/commands/settings/general/MaintainerCommand.java b/src/main/java/com/github/codedoctorde/linwood/commands/settings/general/MaintainerCommand.java index fcf8c3ff..bab52e41 100644 --- a/src/main/java/com/github/codedoctorde/linwood/commands/settings/general/MaintainerCommand.java +++ b/src/main/java/com/github/codedoctorde/linwood/commands/settings/general/MaintainerCommand.java @@ -23,7 +23,7 @@ public boolean onCommand(Session session, Message message, GuildEntity entity, S return false; if(args.length == 0) if(entity.getMaintainerId() != null) - message.getChannel().sendMessage(MessageFormat.format(bundle.getString("Get"), entity.getMaintainer().getName(), entity.getMaintainerId())).queue(); + message.getChannel().sendMessageFormat(bundle.getString("Get"), entity.getMaintainer().getName(), entity.getMaintainerId()).queue(); else message.getChannel().sendMessage(bundle.getString("GetNull")).queue(); else { @@ -45,7 +45,7 @@ else if(roles.size() > 1) return true; entity.setMaintainer(role); entity.save(session); - message.getChannel().sendMessage(MessageFormat.format(bundle.getString("Set"), entity.getMaintainer().getName(), entity.getMaintainerId())).queue(); + message.getChannel().sendMessageFormat(bundle.getString("Set"), entity.getMaintainer().getName(), entity.getMaintainerId()).queue(); }catch(NullPointerException e){ message.getChannel().sendMessage(bundle.getString("NotValid")).queue(); } diff --git a/src/main/java/com/github/codedoctorde/linwood/commands/settings/general/PrefixesCommand.java b/src/main/java/com/github/codedoctorde/linwood/commands/settings/general/PrefixesCommand.java index 6bb3ebd8..0136e9c3 100644 --- a/src/main/java/com/github/codedoctorde/linwood/commands/settings/general/PrefixesCommand.java +++ b/src/main/java/com/github/codedoctorde/linwood/commands/settings/general/PrefixesCommand.java @@ -20,7 +20,7 @@ public boolean onCommand(Session session, Message message, GuildEntity entity, S if(args.length != 0) return false; var bundle = getBundle(entity); - message.getChannel().sendMessage(MessageFormat.format(bundle.getString("Get"), String.join("," , entity.getPrefixes()))).queue(); + message.getChannel().sendMessageFormat(bundle.getString("Get"), String.join("," , entity.getPrefixes())).queue(); return true; } diff --git a/src/main/java/com/github/codedoctorde/linwood/commands/settings/general/RemovePrefixCommand.java b/src/main/java/com/github/codedoctorde/linwood/commands/settings/general/RemovePrefixCommand.java index 87015f18..6c31eb39 100644 --- a/src/main/java/com/github/codedoctorde/linwood/commands/settings/general/RemovePrefixCommand.java +++ b/src/main/java/com/github/codedoctorde/linwood/commands/settings/general/RemovePrefixCommand.java @@ -24,7 +24,7 @@ public boolean onCommand(Session session, Message message, GuildEntity entity, S return true; } entity.save(session); - message.getChannel().sendMessage(MessageFormat.format(bundle.getString("Success"), args[0])).queue(); + message.getChannel().sendMessageFormat(bundle.getString("Success"), args[0]).queue(); return true; } diff --git a/src/main/java/com/github/codedoctorde/linwood/commands/settings/karma/DislikeCommand.java b/src/main/java/com/github/codedoctorde/linwood/commands/settings/karma/DislikeCommand.java index 0b4c95bd..24392c98 100644 --- a/src/main/java/com/github/codedoctorde/linwood/commands/settings/karma/DislikeCommand.java +++ b/src/main/java/com/github/codedoctorde/linwood/commands/settings/karma/DislikeCommand.java @@ -22,7 +22,7 @@ public boolean onCommand(Session session, Message message, GuildEntity entity, S return false; if(args.length == 0) if(entity.getKarmaEntity().getDislikeEmote() != null) - message.getChannel().sendMessage(MessageFormat.format(bundle.getString("Get"), entity.getKarmaEntity().getDislikeEmote())).queue(); + message.getChannel().sendMessageFormat(bundle.getString("Get"), entity.getKarmaEntity().getDislikeEmote()).queue(); else message.getChannel().sendMessage(bundle.getString("GetNull")).queue(); else { @@ -33,7 +33,7 @@ public boolean onCommand(Session session, Message message, GuildEntity entity, S } entity.getKarmaEntity().setDislikeEmote(emote); entity.save(session); - message.getChannel().sendMessage(MessageFormat.format(bundle.getString("Set"), entity.getKarmaEntity().getDislikeEmote())).queue(); + message.getChannel().sendMessageFormat(bundle.getString("Set"), entity.getKarmaEntity().getDislikeEmote()).queue(); } return true; } diff --git a/src/main/java/com/github/codedoctorde/linwood/commands/settings/karma/LikeCommand.java b/src/main/java/com/github/codedoctorde/linwood/commands/settings/karma/LikeCommand.java index 2f8e5b9d..22457d9d 100644 --- a/src/main/java/com/github/codedoctorde/linwood/commands/settings/karma/LikeCommand.java +++ b/src/main/java/com/github/codedoctorde/linwood/commands/settings/karma/LikeCommand.java @@ -22,7 +22,7 @@ public boolean onCommand(Session session, Message message, GuildEntity entity, S return false; if(args.length == 0) if(entity.getKarmaEntity().getLikeEmote() != null) - message.getChannel().sendMessage(MessageFormat.format(bundle.getString("Get"), entity.getKarmaEntity().getLikeEmote())).queue(); + message.getChannel().sendMessageFormat(bundle.getString("Get"), entity.getKarmaEntity().getLikeEmote()).queue(); else message.getChannel().sendMessage(bundle.getString("GetNull")).queue(); else { @@ -33,7 +33,7 @@ public boolean onCommand(Session session, Message message, GuildEntity entity, S } entity.getKarmaEntity().setLikeEmote(args[0]); entity.save(session); - message.getChannel().sendMessage(MessageFormat.format(bundle.getString("Set"), entity.getKarmaEntity().getLikeEmote())).queue(); + message.getChannel().sendMessageFormat(bundle.getString("Set"), entity.getKarmaEntity().getLikeEmote()).queue(); } return true; } diff --git a/src/main/java/com/github/codedoctorde/linwood/commands/settings/notification/StatusChatCommand.java b/src/main/java/com/github/codedoctorde/linwood/commands/settings/notification/StatusChatCommand.java index f010da46..3e3ecc77 100644 --- a/src/main/java/com/github/codedoctorde/linwood/commands/settings/notification/StatusChatCommand.java +++ b/src/main/java/com/github/codedoctorde/linwood/commands/settings/notification/StatusChatCommand.java @@ -27,7 +27,7 @@ public boolean onCommand(Session session, Message message, GuildEntity entity, S return false; if(args.length == 0) if(entity.getNotificationEntity().getStatusChatId() != null) - message.getChannel().sendMessage(MessageFormat.format(bundle.getString("Get"), entity.getNotificationEntity().getStatusChat().getName(), entity.getNotificationEntity().getStatusChatId())).queue(); + message.getChannel().sendMessageFormat(bundle.getString("Get"), entity.getNotificationEntity().getStatusChat().getName(), entity.getNotificationEntity().getStatusChatId()).queue(); else message.getChannel().sendMessage(bundle.getString("GetNull")).queue(); else { @@ -45,7 +45,7 @@ public boolean onCommand(Session session, Message message, GuildEntity entity, S } entity.getNotificationEntity().setStatusChat(channel); entity.save(session); - message.getChannel().sendMessage(MessageFormat.format(bundle.getString("Set"), entity.getNotificationEntity().getStatusChat().getAsMention(), entity.getNotificationEntity().getStatusChatId())).queue(); + message.getChannel().sendMessageFormat(bundle.getString("Set"), entity.getNotificationEntity().getStatusChat().getAsMention(), entity.getNotificationEntity().getStatusChatId()).queue(); }catch(NullPointerException e){ message.getChannel().sendMessage(bundle.getString("NotValid")).queue(); } diff --git a/src/main/java/com/github/codedoctorde/linwood/commands/settings/notification/SupportChatCommand.java b/src/main/java/com/github/codedoctorde/linwood/commands/settings/notification/SupportChatCommand.java index 52a2a440..99dc1313 100644 --- a/src/main/java/com/github/codedoctorde/linwood/commands/settings/notification/SupportChatCommand.java +++ b/src/main/java/com/github/codedoctorde/linwood/commands/settings/notification/SupportChatCommand.java @@ -27,7 +27,7 @@ public boolean onCommand(Session session, Message message, GuildEntity entity, S return false; if(args.length == 0) if(entity.getNotificationEntity().getSupportChatId() != null) - message.getChannel().sendMessage(MessageFormat.format(bundle.getString("Get"), entity.getNotificationEntity().getSupportChat().getName(), entity.getNotificationEntity().getSupportChatId())).queue(); + message.getChannel().sendMessageFormat(bundle.getString("Get"), entity.getNotificationEntity().getSupportChat().getName(), entity.getNotificationEntity().getSupportChatId()).queue(); else message.getChannel().sendMessage(bundle.getString("GetNull")).queue(); else { @@ -44,7 +44,7 @@ public boolean onCommand(Session session, Message message, GuildEntity entity, S } entity.getNotificationEntity().setSupportChat(channel); entity.save(session); - message.getChannel().sendMessage(MessageFormat.format(bundle.getString("Set"), entity.getNotificationEntity().getSupportChat().getAsMention(), entity.getNotificationEntity().getSupportChatId())).queue(); + message.getChannel().sendMessageFormat(bundle.getString("Set"), entity.getNotificationEntity().getSupportChat().getAsMention(), entity.getNotificationEntity().getSupportChatId()).queue(); } return true; } diff --git a/src/main/java/com/github/codedoctorde/linwood/commands/settings/notification/TeamCommand.java b/src/main/java/com/github/codedoctorde/linwood/commands/settings/notification/TeamCommand.java index 887b300e..9e840260 100644 --- a/src/main/java/com/github/codedoctorde/linwood/commands/settings/notification/TeamCommand.java +++ b/src/main/java/com/github/codedoctorde/linwood/commands/settings/notification/TeamCommand.java @@ -23,7 +23,7 @@ public boolean onCommand(Session session, Message message, GuildEntity entity, S return false; if(args.length == 0) if(entity.getNotificationEntity().getTeamRoleId() != null) - message.getChannel().sendMessage(MessageFormat.format(bundle.getString("Get"), entity.getNotificationEntity().getTeamRole().getName(), entity.getNotificationEntity().getTeamRoleId())).queue(); + message.getChannel().sendMessageFormat(bundle.getString("Get"), entity.getNotificationEntity().getTeamRole().getName(), entity.getNotificationEntity().getTeamRoleId()).queue(); else message.getChannel().sendMessage(bundle.getString("GetNull")).queue(); else { @@ -45,7 +45,7 @@ else if(roles.size() > 1) return true; entity.getNotificationEntity().setTeamRole(role); entity.save(session); - message.getChannel().sendMessage(MessageFormat.format(bundle.getString("Set"), entity.getNotificationEntity().getTeamRole().getName(), entity.getNotificationEntity().getTeamRoleId())).queue(); + message.getChannel().sendMessageFormat(bundle.getString("Set"), entity.getNotificationEntity().getTeamRole().getName(), entity.getNotificationEntity().getTeamRoleId()).queue(); }catch(NullPointerException e){ message.getChannel().sendMessage(bundle.getString("NotValid")).queue(); } diff --git a/src/main/java/com/github/codedoctorde/linwood/config/ActivityConfig.java b/src/main/java/com/github/codedoctorde/linwood/config/ActivityConfig.java index 888fadc0..f2415e7f 100644 --- a/src/main/java/com/github/codedoctorde/linwood/config/ActivityConfig.java +++ b/src/main/java/com/github/codedoctorde/linwood/config/ActivityConfig.java @@ -21,7 +21,7 @@ public ActivityConfig(Activity.ActivityType type, String name){ public Activity build(Object... format){ var status = name; if(format != null) - status = MessageFormat.format(status, format); + status = String.format(status, format); return Activity.of(type, status); } diff --git a/src/main/java/com/github/codedoctorde/linwood/config/MainConfig.java b/src/main/java/com/github/codedoctorde/linwood/config/MainConfig.java index 90fdd0d4..e515d98f 100644 --- a/src/main/java/com/github/codedoctorde/linwood/config/MainConfig.java +++ b/src/main/java/com/github/codedoctorde/linwood/config/MainConfig.java @@ -20,9 +20,9 @@ public class MainConfig { add(new ActivityConfig(Activity.ActivityType.LISTENING, "CodeDoctor")); add(new ActivityConfig(Activity.ActivityType.WATCHING, "github/CodeDoctorDE")); add(new ActivityConfig(Activity.ActivityType.DEFAULT, "games with players :D")); - add(new ActivityConfig(Activity.ActivityType.DEFAULT, "{0}")); - add(new ActivityConfig(Activity.ActivityType.WATCHING, "on {1} servers")); - add(new ActivityConfig(Activity.ActivityType.DEFAULT, "with {1} players")); + add(new ActivityConfig(Activity.ActivityType.DEFAULT, "%s")); + add(new ActivityConfig(Activity.ActivityType.WATCHING, "on %2$s servers")); + add(new ActivityConfig(Activity.ActivityType.DEFAULT, "with %2$s players")); }}; private String supportURL = "https://discord.gg/97zFtYN"; diff --git a/src/main/java/com/github/codedoctorde/linwood/listener/CommandListener.java b/src/main/java/com/github/codedoctorde/linwood/listener/CommandListener.java index 080f9fdd..277cedf2 100644 --- a/src/main/java/com/github/codedoctorde/linwood/listener/CommandListener.java +++ b/src/main/java/com/github/codedoctorde/linwood/listener/CommandListener.java @@ -5,6 +5,8 @@ import io.sentry.Sentry; import net.dv8tion.jda.api.entities.ChannelType; import net.dv8tion.jda.api.events.message.MessageReceivedEvent; +import net.dv8tion.jda.api.exceptions.InsufficientPermissionException; +import net.dv8tion.jda.api.exceptions.PermissionException; import net.dv8tion.jda.api.hooks.SubscribeEvent; import org.apache.tools.ant.types.Commandline; @@ -44,8 +46,11 @@ else if (content.startsWith(normalMention)) var commandBundle = Linwood.getInstance().getBaseCommand().getBundle(guild); try { if (!Linwood.getInstance().getBaseCommand().onCommand(session, event.getMessage(), guild, prefix, command)) - event.getChannel().sendMessage(MessageFormat.format(bundle.getString("Syntax"), commandBundle.getString("Syntax"))).queue(); - } catch (Exception e) { + event.getChannel().sendMessageFormat(bundle.getString("Syntax"), commandBundle.getString("Syntax")).queue(); + }catch(PermissionException e){ + event.getChannel().sendMessage(bundle.getString("InsufficientPermission")).queue(); + e.printStackTrace(); + }catch (Exception e) { event.getChannel().sendMessage(bundle.getString("Error")).queue(); e.printStackTrace(); Sentry.capture(e); diff --git a/src/main/java/com/github/codedoctorde/linwood/listener/NotificationListener.java b/src/main/java/com/github/codedoctorde/linwood/listener/NotificationListener.java index bbdf5c59..cbb99fa3 100644 --- a/src/main/java/com/github/codedoctorde/linwood/listener/NotificationListener.java +++ b/src/main/java/com/github/codedoctorde/linwood/listener/NotificationListener.java @@ -60,7 +60,7 @@ public void onStatus(UserUpdateOnlineStatusEvent event){ session.close(); } public String statusFormat(String string, Member member){ - return MessageFormat.format(string, member.getAsMention(), member.getUser().getAsTag()); + return String.format(string, member.getAsMention(), member.getUser().getAsTag()); } public @NotNull ResourceBundle getBundle(GuildEntity entity){ diff --git a/src/main/java/com/github/codedoctorde/linwood/utils/DatabaseUtil.java b/src/main/java/com/github/codedoctorde/linwood/utils/DatabaseUtil.java index 42218aff..3af51ec9 100644 --- a/src/main/java/com/github/codedoctorde/linwood/utils/DatabaseUtil.java +++ b/src/main/java/com/github/codedoctorde/linwood/utils/DatabaseUtil.java @@ -129,8 +129,11 @@ private void cleanupGuilds(Session session) { } logger.info("Successfully clean up " + count + " guilds!"); } - public MemberEntity[] getKarmaLeaderboard(Session session, @Nullable Long guild){ + return getKarmaLeaderboard(session, guild, 20); + } + + public MemberEntity[] getKarmaLeaderboard(Session session, @Nullable Long guild, int maxResults){ // Create CriteriaBuilder var builder = session.getCriteriaBuilder(); @@ -142,7 +145,7 @@ public MemberEntity[] getKarmaLeaderboard(Session session, @Nullable Long guild) if(guild != null) all.where(builder.equal(from.get("guildId"), guild)); var allQuery = session.createQuery(all); - allQuery.setMaxResults(10); + allQuery.setMaxResults(maxResults); return allQuery.getResultList().toArray(new MemberEntity[0]); } diff --git a/src/main/resources/locale/Command_de.properties b/src/main/resources/locale/Command_de.properties index df31d7b6..64ea3092 100644 --- a/src/main/resources/locale/Command_de.properties +++ b/src/main/resources/locale/Command_de.properties @@ -1,3 +1,4 @@ -Syntax=Falsche Benutzung. Bitte nutze: \n{0} +Syntax=Falsche Benutzung. Bitte nutze: \n%s Error=Ein unerwarteter Fehler ist passiert! Sollte es noch einmal passieren, kontaktiere bitte den Entwickler NoPermission=:no_entry_sign: Keine Rechte! +InsufficientPermission=**:warning: Der Bot hat keine Rechte dies zu tun! :warning: ** \ No newline at end of file diff --git a/src/main/resources/locale/Command_en.properties b/src/main/resources/locale/Command_en.properties index dbd18bb2..bd12b458 100644 --- a/src/main/resources/locale/Command_en.properties +++ b/src/main/resources/locale/Command_en.properties @@ -1,3 +1,4 @@ -Syntax=Wrong usage. Please use: \n{0} +Syntax=Wrong usage. Please use: \n%s Error=An error has occurred! Please contact the developer if it happens multiple times! NoPermission=:no_entry_sign: No permission! +InsufficientPermission=**:warning: The bot has no permission to do this! :warning: ** \ No newline at end of file diff --git a/src/main/resources/locale/Notification_de.properties b/src/main/resources/locale/Notification_de.properties index 48bbc545..7bb38c10 100644 --- a/src/main/resources/locale/Notification_de.properties +++ b/src/main/resources/locale/Notification_de.properties @@ -1,5 +1,5 @@ -OnlineTitle=:green_circle: Status von {1} geändert! -OnlineBody=:smile: {0} ist nun online! -OfflineTitle=:black_circle: Status von {1} geändert! -OfflineBody=:smile: {0} ist nun offline! +OnlineTitle=:green_circle: Status von %2$s geändert! +OnlineBody=:smile: %s ist nun online! +OfflineTitle=:black_circle: Status von %2$s geändert! +OfflineBody=:smile: %s ist nun offline! NoSupport=Sorry, kein Supporter ist online :sleeping_accommodation: \ No newline at end of file diff --git a/src/main/resources/locale/Notification_en.properties b/src/main/resources/locale/Notification_en.properties index 56cfd108..bc62184f 100644 --- a/src/main/resources/locale/Notification_en.properties +++ b/src/main/resources/locale/Notification_en.properties @@ -1,5 +1,5 @@ -OnlineTitle=:green_circle: Status changed from {1}! -OnlineBody=:smile: {0} is online now! -OfflineTitle=:black_circle: Status changed from {1}! -OfflineBody=:smile: {0} is offline now! +OnlineTitle=:green_circle: Status changed from %2$s! +OnlineBody=:smile: %s is online now! +OfflineTitle=:black_circle: Status changed from %2$s! +OfflineBody=:smile: %s is offline now! NoSupport=Sorry, no supporter is online :sleeping_accommodation: \ No newline at end of file diff --git a/src/main/resources/locale/commands/Clear_de.properties b/src/main/resources/locale/commands/Clear_de.properties index 6961c6f2..5798960e 100644 --- a/src/main/resources/locale/commands/Clear_de.properties +++ b/src/main/resources/locale/commands/Clear_de.properties @@ -1,5 +1,5 @@ Syntax=clear Description=Leere den derzeitigen Chat -Success=Erfolgreich {0} Nachrichten geleert! +Success=Erfolgreich %s Nachrichten geleert! Invalid=Das Argument muss eine Zahl sein! Between=Das Argument muss zwischen 1 und 100 sein! \ No newline at end of file diff --git a/src/main/resources/locale/commands/Clear_en.properties b/src/main/resources/locale/commands/Clear_en.properties index e50eed1e..8c878024 100644 --- a/src/main/resources/locale/commands/Clear_en.properties +++ b/src/main/resources/locale/commands/Clear_en.properties @@ -1,5 +1,5 @@ Syntax=clear Description=Clear the current chat -Success=Successfully {0} messages cleared! +Success=Successfully %s messages cleared! Invalid=The argument should be a number! Between=The argument should be between 1 and 100! \ No newline at end of file diff --git a/src/main/resources/locale/commands/Info_de.properties b/src/main/resources/locale/commands/Info_de.properties index b972b2e0..94beddc0 100644 --- a/src/main/resources/locale/commands/Info_de.properties +++ b/src/main/resources/locale/commands/Info_de.properties @@ -1,4 +1,4 @@ -title=Linwood {0} -Body.regexp=Hallo {1}! Ich möchte mich gerne vorstellen! Ich bin Linwood, geboren am 12.05.2020 und programmiert von CodeDoctor. Du darfst mich mit `{2}` ansprechen :D Rufe die Hilfe mit `{2} help` auf! Derzeit online: {3} Tag(e), {4} Stunde(n), {5} Minute(n), {6} Sekunde(n) und {7} Millisekunden! Wenn du Fragen hast, kannst du uns [dort]({8}) besuchen! +title=Linwood %s +Body.regexp=Hallo %2$s! Ich möchte mich gerne vorstellen! Ich bin Linwood, geboren am 12.05.2020 und programmiert von CodeDoctor. Du darfst mich mit `%3$s` ansprechen :D Rufe die Hilfe mit `%3$s help` auf! Derzeit online: %4$s Tag(e), %5$s Stunde(n), %6$s Minute(n), %7$s Sekunde(n) und %8$s Millisekunden! Wenn du Fragen hast, kannst du uns [dort](%9$s) besuchen! Syntax=info Description=Genereller Botinformationsbefehl \ No newline at end of file diff --git a/src/main/resources/locale/commands/Info_en.properties b/src/main/resources/locale/commands/Info_en.properties index 5f1f1b09..2091d37b 100644 --- a/src/main/resources/locale/commands/Info_en.properties +++ b/src/main/resources/locale/commands/Info_en.properties @@ -1,4 +1,4 @@ -title=Linwood {0} -Body.regexp=Hi {1}! I want to introduce me! I''m Linwood, born on 05/12/2020 and programmed by CodeDoctor. You can address me with `{2}` :D Get the help with `{2} help`! Current uptime: {3} day(s), {4} hour(s), {5} minute(s), {6} second(s) and {7} milliseconds! If you have questions, you can ask [here]({8})! +title=Linwood %s +Body.regexp=Hi %2$s! I want to introduce me! I''m Linwood, born on 05/12/2020 and programmed by CodeDoctor. You can address me with `%3$s` :D Get the help with `%3$s help`! Current uptime: %4$s day(s), %5$s hour(s), %6$s minute(s), %7$s second(s) and %8$s milliseconds! If you have questions, you can ask [here](%9$s)! Syntax=info Description=General bot information command \ No newline at end of file diff --git a/src/main/resources/locale/commands/fun/Dice_de.properties b/src/main/resources/locale/commands/fun/Dice_de.properties index 849fd4f1..61b50be9 100644 --- a/src/main/resources/locale/commands/fun/Dice_de.properties +++ b/src/main/resources/locale/commands/fun/Dice_de.properties @@ -1,3 +1,3 @@ -Output={0} wurde gewürfelt! +Output=%s wurde gewürfelt! Syntax=fun dice Description=Sende eine zufällige Würfelzahl \ No newline at end of file diff --git a/src/main/resources/locale/commands/fun/Dice_en.properties b/src/main/resources/locale/commands/fun/Dice_en.properties index e03f0535..0d3eb99a 100644 --- a/src/main/resources/locale/commands/fun/Dice_en.properties +++ b/src/main/resources/locale/commands/fun/Dice_en.properties @@ -1,3 +1,3 @@ -Output={0} was rolled! +Output=%s was rolled! Syntax=fun dice Description=Send a random number of dice \ No newline at end of file diff --git a/src/main/resources/locale/commands/karma/Base_de.properties b/src/main/resources/locale/commands/karma/Base_de.properties index 9e752f0d..e5ae4353 100644 --- a/src/main/resources/locale/commands/karma/Base_de.properties +++ b/src/main/resources/locale/commands/karma/Base_de.properties @@ -1,2 +1,2 @@ -Syntax=**Verfügbare Befehle:** \n\n`karma info` \n*Bekomme dein Karma* +Syntax=**Verfügbare Befehle:** \n\n`karma info` \n*Bekomme dein Karma* \n\n`karma leaderboard` \n*Sendet dir das Leaderboard* Description=Karma Modul diff --git a/src/main/resources/locale/commands/karma/Base_en.properties b/src/main/resources/locale/commands/karma/Base_en.properties index dc092499..0e259fbd 100644 --- a/src/main/resources/locale/commands/karma/Base_en.properties +++ b/src/main/resources/locale/commands/karma/Base_en.properties @@ -1,2 +1,2 @@ -Syntax=**Available commands:** \n\n`karma info` \n*Get your karma* +Syntax=**Available commands:** \n\n`karma info` \n*Get your karma* \n\n`karma leaderboard` \n*Send you the leaderboard* Description=Karma module \ No newline at end of file diff --git a/src/main/resources/locale/commands/karma/Leaderboard_de.properties b/src/main/resources/locale/commands/karma/Leaderboard_de.properties index e69de29b..c602329c 100644 --- a/src/main/resources/locale/commands/karma/Leaderboard_de.properties +++ b/src/main/resources/locale/commands/karma/Leaderboard_de.properties @@ -0,0 +1,7 @@ +Syntax=fun leaderboard +Description=Sendet dir das Leaderboard +LeaderboardHeader=Karma Leaderboard +LeaderboardBodyStart=Derzeitige Top-20: +LeaderboardBody=:star: **%s. Platz** \n*%2$s Punkte (%3$s Likes und %4$s Dislikes)* \n\n +LeaderboardBodyEnd=... +LeaderboardFooter=Karma ~ Linwood \ No newline at end of file diff --git a/src/main/resources/locale/commands/karma/Leaderboard_en.properties b/src/main/resources/locale/commands/karma/Leaderboard_en.properties index e69de29b..94ed71b3 100644 --- a/src/main/resources/locale/commands/karma/Leaderboard_en.properties +++ b/src/main/resources/locale/commands/karma/Leaderboard_en.properties @@ -0,0 +1,7 @@ +Syntax=fun leaderboard +Description=Send you the leaderboard +LeaderboardHeader=Karma Leaderboard +LeaderboardBodyStart=Current Top-20: +LeaderboardBody=:star: **%s. place** \n*%2$s points (%3$s likes and %4$s dislikes)* \n\n +LeaderboardBodyEnd=... +LeaderboardFooter=Karma ~ Linwood \ No newline at end of file diff --git a/src/main/resources/locale/commands/settings/game/GameCategory_de.properties b/src/main/resources/locale/commands/settings/game/GameCategory_de.properties index 777389b6..8de96674 100644 --- a/src/main/resources/locale/commands/settings/game/GameCategory_de.properties +++ b/src/main/resources/locale/commands/settings/game/GameCategory_de.properties @@ -1,5 +1,5 @@ -Set=:white_check_mark: Erfolgreich Spielkategorie gesetzt zu {0} (Id: `{1}`)! -Get=Die derzeitige Spielkategorie ist {0} (Id: `{1}`)! +Set=:white_check_mark: Erfolgreich Spielkategorie gesetzt zu %s (Id: `%2$s`)! +Get=Die derzeitige Spielkategorie ist %s (Id: `%2$s`)! GetNull=Die Eigenschaft ist leer! Syntax=settings game category [] Description=Setze/bekomme die Spielkategorie diff --git a/src/main/resources/locale/commands/settings/game/GameCategory_en.properties b/src/main/resources/locale/commands/settings/game/GameCategory_en.properties index 26f24f1d..1105ffc4 100644 --- a/src/main/resources/locale/commands/settings/game/GameCategory_en.properties +++ b/src/main/resources/locale/commands/settings/game/GameCategory_en.properties @@ -1,7 +1,7 @@ -Set=:white_check_mark: Successfully set game category to {0} (Id: `{1}`)! +Set=:white_check_mark: Successfully set game category to %s (Id: `%2$s`)! SetNothing=This category does not exist! SetMultiple=There are more than 1 category with that name! -Get=The current game category is {0} (Id: `{1}`)! +Get=The current game category is %s (Id: `%2$s`)! GetNull=This property is empty! Syntax=settings game category [] Description=Set/get the game category diff --git a/src/main/resources/locale/commands/settings/game/GameMaster_de.properties b/src/main/resources/locale/commands/settings/game/GameMaster_de.properties index 6cba8f3d..dbb1062c 100644 --- a/src/main/resources/locale/commands/settings/game/GameMaster_de.properties +++ b/src/main/resources/locale/commands/settings/game/GameMaster_de.properties @@ -1,7 +1,7 @@ -Set=:white_check_mark: Erfolgreich Game Master gesetzt zu {0} (Id: `{1}`)! +Set=:white_check_mark: Erfolgreich Game Master gesetzt zu %s (Id: `%2$s`)! SetNothing=Diese Rolle gibt es nicht! SetMultiple=Es gibt mehrere Rollen mit diesem Namen! -Get=Der derzeitige Game Master ist {0} (Id: `{1}`)! +Get=Der derzeitige Game Master ist %s (Id: `%2$s`)! GetNull=Die Eigenschaft ist leer! Syntax=settings game master [] Description=Setze/bekomme den Game Master diff --git a/src/main/resources/locale/commands/settings/game/GameMaster_en.properties b/src/main/resources/locale/commands/settings/game/GameMaster_en.properties index 45c4e63e..1b130602 100644 --- a/src/main/resources/locale/commands/settings/game/GameMaster_en.properties +++ b/src/main/resources/locale/commands/settings/game/GameMaster_en.properties @@ -1,7 +1,7 @@ -Set=:white_check_mark: Successfully set game master to {0} (Id: `{1}`)! +Set=:white_check_mark: Successfully set game master to %s (Id: `%2$s`)! SetNothing=This role does not exist! SetMultiple=There are more than 1 role with that name! -Get=The current game master is {0} (Id: `{1}`)! +Get=The current game master is %s (Id: `%2$s`)! GetNull=This property is empty! Syntax=settings game master [] Description=Set/get the game master diff --git a/src/main/resources/locale/commands/settings/general/AddPrefix_de.properties b/src/main/resources/locale/commands/settings/general/AddPrefix_de.properties index 2d96884b..72222bb2 100644 --- a/src/main/resources/locale/commands/settings/general/AddPrefix_de.properties +++ b/src/main/resources/locale/commands/settings/general/AddPrefix_de.properties @@ -1,4 +1,4 @@ -Success=:white_check_mark: Erfolgreich Prefix `{0}` hinzugefügt! +Success=:white_check_mark: Erfolgreich Prefix `%s` hinzugefügt! Syntax=settings general addprefix Description=Füge ein Prefix zum Bot hinzu Permission=Server verwalten diff --git a/src/main/resources/locale/commands/settings/general/AddPrefix_en.properties b/src/main/resources/locale/commands/settings/general/AddPrefix_en.properties index e8c17f08..b870c372 100644 --- a/src/main/resources/locale/commands/settings/general/AddPrefix_en.properties +++ b/src/main/resources/locale/commands/settings/general/AddPrefix_en.properties @@ -1,4 +1,4 @@ -Success=:white_check_mark: Successfully add the prefix `{0}`! +Success=:white_check_mark: Successfully add the prefix `%s`! Syntax=settings general addprefix Description=Add a prefix of the bot Permission=Manage server diff --git a/src/main/resources/locale/commands/settings/general/Language_de.properties b/src/main/resources/locale/commands/settings/general/Language_de.properties index 98826612..4b94a4c2 100644 --- a/src/main/resources/locale/commands/settings/general/Language_de.properties +++ b/src/main/resources/locale/commands/settings/general/Language_de.properties @@ -1,5 +1,5 @@ -Set=:white_check_mark: Erfolgreich Sprache gesetzt zu {0}! -Get=Die derzeitige Sprache ist {0}! +Set=:white_check_mark: Erfolgreich Sprache gesetzt zu %s! +Get=Die derzeitige Sprache ist %s! Syntax=settings general language [] Description=Setze/bekomme die Sprache vom Bot NotValid=Diese Sprache ist nicht gültig! diff --git a/src/main/resources/locale/commands/settings/general/Language_en.properties b/src/main/resources/locale/commands/settings/general/Language_en.properties index 26d16d6e..78c99f00 100644 --- a/src/main/resources/locale/commands/settings/general/Language_en.properties +++ b/src/main/resources/locale/commands/settings/general/Language_en.properties @@ -1,5 +1,5 @@ -Set=:white_check_mark: Successfully set the language to {0}! -Get=The current language is {0}! +Set=:white_check_mark: Successfully set the language to %s! +Get=The current language is %s! Syntax=settings general language [] Description=Set/get the language of the bot NotValid=This language is no valid! diff --git a/src/main/resources/locale/commands/settings/general/Maintainer_de.properties b/src/main/resources/locale/commands/settings/general/Maintainer_de.properties index 6cba8f3d..dbb1062c 100644 --- a/src/main/resources/locale/commands/settings/general/Maintainer_de.properties +++ b/src/main/resources/locale/commands/settings/general/Maintainer_de.properties @@ -1,7 +1,7 @@ -Set=:white_check_mark: Erfolgreich Game Master gesetzt zu {0} (Id: `{1}`)! +Set=:white_check_mark: Erfolgreich Game Master gesetzt zu %s (Id: `%2$s`)! SetNothing=Diese Rolle gibt es nicht! SetMultiple=Es gibt mehrere Rollen mit diesem Namen! -Get=Der derzeitige Game Master ist {0} (Id: `{1}`)! +Get=Der derzeitige Game Master ist %s (Id: `%2$s`)! GetNull=Die Eigenschaft ist leer! Syntax=settings game master [] Description=Setze/bekomme den Game Master diff --git a/src/main/resources/locale/commands/settings/general/Maintainer_en.properties b/src/main/resources/locale/commands/settings/general/Maintainer_en.properties index 45c4e63e..1b130602 100644 --- a/src/main/resources/locale/commands/settings/general/Maintainer_en.properties +++ b/src/main/resources/locale/commands/settings/general/Maintainer_en.properties @@ -1,7 +1,7 @@ -Set=:white_check_mark: Successfully set game master to {0} (Id: `{1}`)! +Set=:white_check_mark: Successfully set game master to %s (Id: `%2$s`)! SetNothing=This role does not exist! SetMultiple=There are more than 1 role with that name! -Get=The current game master is {0} (Id: `{1}`)! +Get=The current game master is %s (Id: `%2$s`)! GetNull=This property is empty! Syntax=settings game master [] Description=Set/get the game master diff --git a/src/main/resources/locale/commands/settings/general/Prefixes_de.properties b/src/main/resources/locale/commands/settings/general/Prefixes_de.properties index dd9809db..f4d2c1b0 100644 --- a/src/main/resources/locale/commands/settings/general/Prefixes_de.properties +++ b/src/main/resources/locale/commands/settings/general/Prefixes_de.properties @@ -1,4 +1,4 @@ -Get=Der derzeitige Prefixe sind `{0}`! +Get=Der derzeitige Prefixe sind `%s`! Syntax=settings general prefixes Description=Bekomme den Prefix vom Bot Permission=Server verwalten \ No newline at end of file diff --git a/src/main/resources/locale/commands/settings/general/Prefixes_en.properties b/src/main/resources/locale/commands/settings/general/Prefixes_en.properties index 3105cee0..22e19e25 100644 --- a/src/main/resources/locale/commands/settings/general/Prefixes_en.properties +++ b/src/main/resources/locale/commands/settings/general/Prefixes_en.properties @@ -1,4 +1,4 @@ -Get=The current prefixes are `{0}`! +Get=The current prefixes are `%s`! Syntax=settings general prefixes Description=Get the prefixes of the bot Permission=Manage server \ No newline at end of file diff --git a/src/main/resources/locale/commands/settings/general/RemovePrefix_de.properties b/src/main/resources/locale/commands/settings/general/RemovePrefix_de.properties index 36af057b..531f329d 100644 --- a/src/main/resources/locale/commands/settings/general/RemovePrefix_de.properties +++ b/src/main/resources/locale/commands/settings/general/RemovePrefix_de.properties @@ -1,4 +1,4 @@ -Success=:white_check_mark: Erfolgreich Prefix `{0}` gelöscht! +Success=:white_check_mark: Erfolgreich Prefix `%s` gelöscht! Syntax=settings general removeprefix Description=Lösche ein Prefix vom Bot Permission=Server verwalten diff --git a/src/main/resources/locale/commands/settings/general/RemovePrefix_en.properties b/src/main/resources/locale/commands/settings/general/RemovePrefix_en.properties index 8230d0de..65dfb951 100644 --- a/src/main/resources/locale/commands/settings/general/RemovePrefix_en.properties +++ b/src/main/resources/locale/commands/settings/general/RemovePrefix_en.properties @@ -1,5 +1,5 @@ Syntax=settings general addprefix -Success=:white_check_mark: Successfully removed the prefix `{0}`! +Success=:white_check_mark: Successfully removed the prefix `%s`! Description=Remove a prefix of the bot Permission=Manage server Invalid=This prefix does not exist! \ No newline at end of file diff --git a/src/main/resources/locale/commands/settings/karma/Base_de.properties b/src/main/resources/locale/commands/settings/karma/Base_de.properties index 7445fc4b..4a427e37 100644 --- a/src/main/resources/locale/commands/settings/karma/Base_de.properties +++ b/src/main/resources/locale/commands/settings/karma/Base_de.properties @@ -1,2 +1,2 @@ -Syntax=**Verfügbare Befehle:** \n\n`settings karma like []` \n*Set/get like emote*\n__Benötigte Rechte: Server verwalten__ +Syntax=**Verfügbare Befehle:** \n\n`settings karma like []` \n*Setze/bekomme den Like Emote*\n__Benötigte Rechte: Server verwalten__ \n\n`settings karma clearlike` \n*Leere die Like Eigenschaft*\n__Benötigte Rechte: Server verwalten__ \n\n`settings karma dislike []` \n*Setze/bekomme den Dislike Emote*\n__Benötigte Rechte: Server verwalten__ \n\n`settings karma cleardislike` \n*Leere die Dislike Eigenschaft*\n__Benötigte Rechte: Server verwalten__ Description=Personalisiere das Karma Modul vom Bot! diff --git a/src/main/resources/locale/commands/settings/karma/Base_en.properties b/src/main/resources/locale/commands/settings/karma/Base_en.properties index 6e08c679..f1eac361 100644 --- a/src/main/resources/locale/commands/settings/karma/Base_en.properties +++ b/src/main/resources/locale/commands/settings/karma/Base_en.properties @@ -1,2 +1,2 @@ -Syntax=**Verfügbare Befehle:** \n\n`settings karma like []` \n*Set/get like emote*\n__Benötigte Rechte: Server verwalten__ +Syntax=**Verfügbare Befehle:** \n\n`settings karma like []` \n*Set/get like emote*\n__Benötigte Rechte: Server verwalten__ \n\n`settings karma clearlike` \n*Clear the like property*\n__Benötigte Rechte: Server verwalten__ \n\n`settings karma dislike []` \n*Set/get dislike emote*\n__Benötigte Rechte: Server verwalten__ \n\n`settings karma cleardislike` \n*Clear the dislike property*\n__Benötigte Rechte: Server verwalten__ Description=Customize the karma module of the bot! diff --git a/src/main/resources/locale/commands/settings/karma/Dislike_de.properties b/src/main/resources/locale/commands/settings/karma/Dislike_de.properties index 2dadb466..bcf38a64 100644 --- a/src/main/resources/locale/commands/settings/karma/Dislike_de.properties +++ b/src/main/resources/locale/commands/settings/karma/Dislike_de.properties @@ -1,5 +1,5 @@ -Set=:white_check_mark: Erfolgreich Dislike gesetzt zu {0}! -Get=Der derzeitige Dislike Emote ist {0}! +Set=:white_check_mark: Erfolgreich Dislike gesetzt zu %s! +Get=Der derzeitige Dislike Emote ist %s! GetNull=Die Eigenschaft ist leer! Syntax=settings karma dislike [] Description=Setze/bekomme den Dislike Emote diff --git a/src/main/resources/locale/commands/settings/karma/Dislike_en.properties b/src/main/resources/locale/commands/settings/karma/Dislike_en.properties index d3ef5658..2337ed09 100644 --- a/src/main/resources/locale/commands/settings/karma/Dislike_en.properties +++ b/src/main/resources/locale/commands/settings/karma/Dislike_en.properties @@ -1,5 +1,5 @@ -Set=:white_check_mark: Successfully set the dislike property to {0}! -Get=The current dislike emote is {0}! +Set=:white_check_mark: Successfully set the dislike property to %s! +Get=The current dislike emote is %s! GetNull=The property is empty! Syntax=settings karma dislike [] Description=Set/get the dislike emote diff --git a/src/main/resources/locale/commands/settings/karma/Like_de.properties b/src/main/resources/locale/commands/settings/karma/Like_de.properties index 61e4536b..4f840f94 100644 --- a/src/main/resources/locale/commands/settings/karma/Like_de.properties +++ b/src/main/resources/locale/commands/settings/karma/Like_de.properties @@ -1,5 +1,5 @@ -Set=:white_check_mark: Erfolgreich Like gesetzt zu {0}! -Get=Der derzeitige Like Emote ist `{0}`! +Set=:white_check_mark: Erfolgreich Like gesetzt zu %s! +Get=Der derzeitige Like Emote ist `%s`! GetNull=Die Eigenschaft ist leer! Syntax=settings karma like [] Description=Setze/bekomme den Like Emote diff --git a/src/main/resources/locale/commands/settings/karma/Like_en.properties b/src/main/resources/locale/commands/settings/karma/Like_en.properties index 97ba35d6..06ed023d 100644 --- a/src/main/resources/locale/commands/settings/karma/Like_en.properties +++ b/src/main/resources/locale/commands/settings/karma/Like_en.properties @@ -1,5 +1,5 @@ -Set=:white_check_mark: Successfully set the like property to {0}! -Get=The current like emote is {0}! +Set=:white_check_mark: Successfully set the like property to %s! +Get=The current like emote is %s! GetNull=The property is empty! Syntax=settings karma like [] Description=Set/get the like emote diff --git a/src/main/resources/locale/commands/settings/notification/StatusChat_de.properties b/src/main/resources/locale/commands/settings/notification/StatusChat_de.properties index d269774e..038e7705 100644 --- a/src/main/resources/locale/commands/settings/notification/StatusChat_de.properties +++ b/src/main/resources/locale/commands/settings/notification/StatusChat_de.properties @@ -1,7 +1,7 @@ -Set=:white_check_mark: Erfolgreich Statuschat gesetzt zu {0} (Id: `{1}`)! +Set=:white_check_mark: Erfolgreich Statuschat gesetzt zu %s (Id: `%2$s`)! SetNothing=Dieser Chat gibt es nicht! SetMultiple=Es gibt mehrere Chats mit diesem Namen! -Get=Der derzeitige Statuschat ist {0} (Id: `{1}`)! +Get=Der derzeitige Statuschat ist %s (Id: `%2$s`)! GetNull=Die Eigenschaft ist leer! Syntax=settings notification status [] Description=Setze/bekomme den Statuschat diff --git a/src/main/resources/locale/commands/settings/notification/StatusChat_en.properties b/src/main/resources/locale/commands/settings/notification/StatusChat_en.properties index e302547b..429b8931 100644 --- a/src/main/resources/locale/commands/settings/notification/StatusChat_en.properties +++ b/src/main/resources/locale/commands/settings/notification/StatusChat_en.properties @@ -1,7 +1,7 @@ -Set=:white_check_mark: Successfully set the status chat to {0} (Id: `{1}`)! +Set=:white_check_mark: Successfully set the status chat to %s (Id: `%2$s`)! SetNothing=This chat does not exist! SetMultiple=There are multiple chats with that name! -Get=The current status chat is {0} (Id: `{1}`)! +Get=The current status chat is %s (Id: `%2$s`)! GetNull=This property is empty! Syntax=settings notification status [] Description=Set/get the status chat diff --git a/src/main/resources/locale/commands/settings/notification/SupportChat_de.properties b/src/main/resources/locale/commands/settings/notification/SupportChat_de.properties index b1b62788..53c15760 100644 --- a/src/main/resources/locale/commands/settings/notification/SupportChat_de.properties +++ b/src/main/resources/locale/commands/settings/notification/SupportChat_de.properties @@ -1,7 +1,7 @@ -Set=:white_check_mark: Erfolgreich Supportchat gesetzt zu {0} (Id: `{1}`)! +Set=:white_check_mark: Erfolgreich Supportchat gesetzt zu %s (Id: `%2$s`)! SetNothing=Dieser Chat gibt es nicht! SetMultiple=Es gibt mehrere Chats mit diesem Namen! -Get=Der derzeitige Support Chat ist {0} (Id: `{1}`)! +Get=Der derzeitige Support Chat ist %s (Id: `%2$s`)! GetNull=Die Eigenschaft ist leer! Syntax=settings notification support [] Description=Setze/bekomme den Supportchat diff --git a/src/main/resources/locale/commands/settings/notification/SupportChat_en.properties b/src/main/resources/locale/commands/settings/notification/SupportChat_en.properties index fa66e921..3b5d9ee9 100644 --- a/src/main/resources/locale/commands/settings/notification/SupportChat_en.properties +++ b/src/main/resources/locale/commands/settings/notification/SupportChat_en.properties @@ -1,7 +1,7 @@ -Set=:white_check_mark: Successfully set the support chat to {0} (Id: `{1}`)! +Set=:white_check_mark: Successfully set the support chat to %s (Id: `%2$s`)! SetNothing=This chat does not exist! SetMultiple=There are multiple chats with that name! -Get=The current support chat is {0} (Id: `{1}`)! +Get=The current support chat is %s (Id: `%2$s`)! GetNull=This property is empty! Syntax=settings notification support [] Description=Set/get the support chat diff --git a/src/main/resources/locale/commands/settings/notification/Team_de.properties b/src/main/resources/locale/commands/settings/notification/Team_de.properties index 14deeddb..d82708bf 100644 --- a/src/main/resources/locale/commands/settings/notification/Team_de.properties +++ b/src/main/resources/locale/commands/settings/notification/Team_de.properties @@ -1,7 +1,7 @@ -Set=:white_check_mark: Erfolgreich Team gesetzt zu {0} (Id: `{1}`)! +Set=:white_check_mark: Erfolgreich Team gesetzt zu %s (Id: `%2$s`)! SetNothing=Diese Rolle gibt es nicht! SetMultiple=Es gibt mehrere Rollen mit diesem Namen! -Get=Der derzeitige Team ist {0} (Id: `{1}`)! +Get=Der derzeitige Team ist %s (Id: `%2$s`)! GetNull=Die Eigenschaft ist leer! Syntax=settings game master [] Description=Setze/bekomme den Team diff --git a/src/main/resources/locale/commands/settings/notification/Team_en.properties b/src/main/resources/locale/commands/settings/notification/Team_en.properties index caaca9dc..0873b75a 100644 --- a/src/main/resources/locale/commands/settings/notification/Team_en.properties +++ b/src/main/resources/locale/commands/settings/notification/Team_en.properties @@ -1,7 +1,7 @@ -Set=:white_check_mark: Successfully set team to {0} (Id: `{1}`)! +Set=:white_check_mark: Successfully set team to %s (Id: `%2$s`)! SetNothing=This role does not exist! SetMultiple=There are more than 1 role with that name! -Get=The current team is {0} (Id: `{1}`)! +Get=The current team is %s (Id: `%2$s`)! GetNull=This property is empty! Syntax=settings game team [] Description=Set/get the team diff --git a/src/main/resources/locale/game/QuizFactory_de.properties b/src/main/resources/locale/game/QuizFactory_de.properties index 08b0fe27..a94a3f02 100644 --- a/src/main/resources/locale/game/QuizFactory_de.properties +++ b/src/main/resources/locale/game/QuizFactory_de.properties @@ -1,5 +1,5 @@ -VoiceChannel=Quiz-Voicechannel #{0} -TextChannel=Quiz-Textchannel #{0} +VoiceChannel=Quiz-Voicechannel #%s +TextChannel=Quiz-Textchannel #%s SetupAddMessage=Willkommen im Quizerstellungsprozess! Schreibe hier die Fragen nun hier herein, bestätige es mit :white_check_mark: oder breche es ab mit :no_entry_sign:! NoQuestions=Du hast keine Fragen hinzugefügt! Das Setup wurde abgebrochen! TimedOut=Du hast nichts eingegeben! Das Spiel wurde abgebrochen! @@ -7,5 +7,5 @@ Welcome=Willkommen bei QuizFactory! Hier bekommt ihr Fragen gestellt und müsst YourQuestion=Deine Frage: Pregame=Alle gejoint? Dann los geht's! Ingame=Das Spiel beginnt! -Join=:arrow_right: {0} ist beigetreten! -Leave=:arrow_left: {0} hat das Spiel verlassen! +Join=:arrow_right: %s ist beigetreten! +Leave=:arrow_left: %s hat das Spiel verlassen! diff --git a/src/main/resources/locale/game/QuizFactory_en.properties b/src/main/resources/locale/game/QuizFactory_en.properties index f5a9e19b..d092cd20 100644 --- a/src/main/resources/locale/game/QuizFactory_en.properties +++ b/src/main/resources/locale/game/QuizFactory_en.properties @@ -1,5 +1,5 @@ -VoiceChannel=Quiz-Voice channel #{0} -TextChannel=Quiz-Text channel #{0} +VoiceChannel=Quiz-Voice channel #%s +TextChannel=Quiz-Text channel #%s SetupAddMessage=Welcome to the quiz factory creator! Write your questions here and confirm it with :white_check_mark: or cancel it with :no_entry_sign:! NoQuestions=You don't created questions! The setup was cancelled! TimedOut=You don't have entered questions! The game was cancelled! @@ -7,5 +7,5 @@ Welcome=Welcome to QuizFactory! Here you can answer questions and the player who YourQuestion=Your question: Pregame=All players joined? Then let's go! Ingame=The game starts! -Join=:arrow_right: {0} joined the game! -Leave=Quiz-Voice channel #{0} +Join=:arrow_right: %s joined the game! +Leave=Quiz-Voice channel #%s diff --git a/src/main/resources/locale/game/TicTacToe_de.properties b/src/main/resources/locale/game/TicTacToe_de.properties index f9524b85..36876734 100644 --- a/src/main/resources/locale/game/TicTacToe_de.properties +++ b/src/main/resources/locale/game/TicTacToe_de.properties @@ -1,15 +1,15 @@ Start=Das Spiel hat gestartet! Spielt! RoundX=Die Runde beginnt. Benutze die Reaktionen um ein Feld auszuwählen -Next=Eine neue Runde hat gestartet (Derzeitige Runde {0})! Reagiert mit :hand_splayed: um die Chance zu haben, der Schreiber zu sein! :no_entry_sign: beendet das Spiel! +Next=Eine neue Runde hat gestartet (Derzeitige Runde %s)! Reagiert mit :hand_splayed: um die Chance zu haben, der Schreiber zu sein! :no_entry_sign: beendet das Spiel! NoPermission=:no_entry_sign: Du hast keine Rechte dies zu tun! -Guess={0} hat das Wort erraten! :+1: (+{1} Punkte) +Guess=%s hat das Wort erraten! :+1: (+%2$s Punkte) TextChannel=What is it Cancel=Die Runde wurde vorzeitig beendet! -Join=:arrow_right: {0} ist beigetreten! -Leave=:arrow_left: {0} hat das Spiel verlassen! +Join=:arrow_right: %s ist beigetreten! +Leave=:arrow_left: %s hat das Spiel verlassen! Finish=Die Runde ist beendet! LeaderboardHeader=Leaderboard -Leaderboard=:star: *{2} Punkte* \n**{0}. Platz** {1} \n\n +Leaderboard=:star: *%3$s Punkte* \n**%s. Platz** %2$s \n\n LeaderboardFooter=What is it ~ Linwood Input=Bitte gebe das Wort ein! Afk=The current player does no react! Next round... \ No newline at end of file diff --git a/src/main/resources/locale/game/WhatIsIt_de.properties b/src/main/resources/locale/game/WhatIsIt_de.properties index 5d899bb0..aa6a6612 100644 --- a/src/main/resources/locale/game/WhatIsIt_de.properties +++ b/src/main/resources/locale/game/WhatIsIt_de.properties @@ -1,20 +1,20 @@ Start=Das Spiel hat gestartet! Ratet! -Round=Die Runde beginnt. Der Schreiber ist nun {0}! Ratet mit um Punkte zu bekommen! Warte darauf, dass der Schreiber sich ein Wort aussucht... -Next=Eine neue Runde hat gestartet (Derzeitige Runde {0})! Reagiert mit :hand_splayed: um die Chance zu haben, der Schreiber zu sein! :no_entry_sign: beendet das Spiel! +Round=Die Runde beginnt. Der Schreiber ist nun %s! Ratet mit um Punkte zu bekommen! Warte darauf, dass der Schreiber sich ein Wort aussucht... +Next=Eine neue Runde hat gestartet (Derzeitige Runde %s)! Reagiert mit :hand_splayed: um die Chance zu haben, der Schreiber zu sein! :no_entry_sign: beendet das Spiel! NoPermission=:no_entry_sign: Du hast keine Rechte dies zu tun! -Guess={0} hat das Wort erraten! :+1: (+{1} Punkte) +Guess=%s hat das Wort erraten! :+1: (+%2$s Punkte) TextChannel=What is it Cancel=Die Runde wurde vorzeitig beendet! -Join=:arrow_right: {0} ist beigetreten! -Leave=:arrow_left: {0} hat das Spiel verlassen! +Join=:arrow_right: %s ist beigetreten! +Leave=:arrow_left: %s hat das Spiel verlassen! Finish=Die Runde ist beendet! LeaderboardHeader=Leaderboard -Leaderboard=:star: *{2} Punkte* \n**{0}. Platz** {1} \n\n +Leaderboard=:star: *%3$s Punkte* \n**%s. Platz** %2$s \n\n LeaderboardFooter=What is it ~ Linwood Input=Bitte gebe das Wort ein! -CountdownMinutes={0} Minuten noch verbleibend! +CountdownMinutes=%s Minuten noch verbleibend! CountdownMinute=1 Minute verbleibend! -CountdownSeconds={0} Sekunden verbleibend! +CountdownSeconds=%s Sekunden verbleibend! CountdownSecond=1 Sekunde verbleibend! Everybody=Jeder hat das Wort erraten! -Word=Das Wort war `{0}`! \ No newline at end of file +Word=Das Wort war `%s`! \ No newline at end of file diff --git a/src/main/resources/locale/game/WhatIsIt_en.properties b/src/main/resources/locale/game/WhatIsIt_en.properties index c25031e8..b515321a 100644 --- a/src/main/resources/locale/game/WhatIsIt_en.properties +++ b/src/main/resources/locale/game/WhatIsIt_en.properties @@ -1,20 +1,20 @@ Start=The game starts! Guess! -Round=The round starts. The writer is {0}! Guess to gain points! -Next=A new round starts (Current round {0})! React with :hand_splayed: to have a chance, being writer! :no_entry_sign: stops the game! +Round=The round starts. The writer is %s! Guess to gain points! +Next=A new round starts (Current round %s)! React with :hand_splayed: to have a chance, being writer! :no_entry_sign: stops the game! NoPermission=:no_entry_sign: No permission! -Guess={0} guesses the word! :+1: (+{1} points) +Guess=%s guesses the word! :+1: (+%2$s points) TextChannel=What is it Cancel=The round ended prematurely! -Join=:arrow_right: {0} joined the game! -Leave=:arrow_left: {0} left the game! +Join=:arrow_right: %s joined the game! +Leave=:arrow_left: %s left the game! Finish=The round ends! LeaderboardHeader=Leaderboard -Leaderboard=:star: *{2} points* \n**Place: {0}** {1} \n\n +Leaderboard=:star: *%3$s points* \n**Place: %s** %2$s \n\n LeaderboardFooter=What is it ~ Linwood Input=Please enter the word! -CountdownMinutes={0} minutes left! +CountdownMinutes=%s minutes left! CountdownMinute=1 minute left! -CountdownSeconds={0} seconds left! +CountdownSeconds=%s seconds left! CountdownSecond=1 second left! Everybody=Everybody guesses the word! -Word=The word was `{0}`! \ No newline at end of file +Word=The word was `%s`! \ No newline at end of file