diff --git a/localization.config b/localization.config index b810ae8..4f11193 100644 --- a/localization.config +++ b/localization.config @@ -1,21 +1,59 @@ +[CommandEightBall] +It is certain. = +Ask again later. = +Cannot predict now. = +My sources say no. = +You may rely on it. = +Concentrate and ask again. = +Signs point to yes. = +Most likely. = +Reply hazy, try again. = +Without a doubt. = +Very doubtful. = +It is decidedly so. = +Answers a yes or no question! Warning: Kitty can not actually tell the future, she claims no responsibility for any lion mauling, lack of lottery wins, or felony charges. = +Don't count on it. = +Yes. = +My reply is no. = +Yes - definitely. = +As I see it, yes. = +Better not tell you now. = +Outlook good. = +Outlook not so good. = + +[CommandColiru] +Will try to compile any c++ code you put in! Supports up to C++14 standard, uses g++. = + [CommandBeansShow] Displays how many beans you have = You have %s beans! = [CommandBetBeans] Please bet with at least 50 beans! = -Allows you to bet your beans, set your amount after the command! Warning! House always wins!\nSets of 3 will get 5x, 4 will get 10x, and 5 will get 1000x = That's not a valid bet! = Sorry, you didn't win, try again! = +Allows you to bet your beans, set your amount after the command! Warning! House always wins!\nSets of 3 will get 5x, 4 will get 10x, and 5 will get 1000x = You don't have enough beans! = You won %s beans! = +[CommandChangeIndicator] +Indicator changed to `%s` = +Changes the command indicator to any single character. By default, it's '!'. If more than one character is provided, the first one is used! = + [CommandBoop] -%s booped %s! = Kitty will react with a counter = +%s booped %s! = Woah! %s booped me! That's %s total! = %s booped several others - %s! = +[CommandChoose] +With an input of x,y,z where x y and z are all choices, kitty will choose one = +I chooooooose %s! = + +[CommandDoWork] +I finished with my work! :D = +Occupies a core for a few seconds = + [CommandBlurry] Blurs your icon or the icon of a friend you mentioned = diff --git a/src/commands/CommandChangeIndicator.java b/src/commands/CommandChangeIndicator.java index 0a7a725..da25d8d 100644 --- a/src/commands/CommandChangeIndicator.java +++ b/src/commands/CommandChangeIndicator.java @@ -1,6 +1,7 @@ package commands; import core.Command; +import core.Localizer; import dataStructures.*; public class CommandChangeIndicator extends Command @@ -8,7 +9,7 @@ public class CommandChangeIndicator extends Command public CommandChangeIndicator(KittyRole level, KittyRating rating) { super(level, rating); } @Override - public String HelpText() { return "Changes the command indicator to any single character. By default, it's '!'. If more than one character is provided, the first one is used!"; } + public String HelpText() { return Localizer.Stub("Changes the command indicator to any single character. By default, it's '!'. If more than one character is provided, the first one is used!"); } @Override public void OnRun(KittyGuild guild, KittyChannel channel, KittyUser user, UserInput input, Response res) @@ -21,6 +22,6 @@ public class CommandChangeIndicator extends Command } guild.SetCommandIndicator(arg.substring(0, 1)); - res.Call("Indicator changed to `" + guild.GetCommandIndicator() +"`!"); + res.Call(String.format(Localizer.Stub("Indicator changed to `%s`"), guild.GetCommandIndicator())); } } diff --git a/src/commands/CommandChoose.java b/src/commands/CommandChoose.java index d65672e..842e341 100644 --- a/src/commands/CommandChoose.java +++ b/src/commands/CommandChoose.java @@ -14,7 +14,7 @@ public class CommandChoose extends Command public CommandChoose(KittyRole level, KittyRating rating) { super(level, rating); } @Override - public String HelpText() { return "With an input of x,y,z where x y and z are all choices, kitty will choose one"; } + public String HelpText() { return Localizer.Stub("With an input of x,y,z where x y and z are all choices, kitty will choose one"); } @Override public void OnRun(KittyGuild guild, KittyChannel channel, KittyUser user, UserInput input, Response res) @@ -26,6 +26,6 @@ public class CommandChoose extends Command return; } - res.Call("I chooooooose" + choices[(int) (Math.random()*choices.length)] + "!"); + res.Call(String.format(Localizer.Stub("I chooooooose %s!"), (choices[(int) (Math.random()*choices.length)]).toString())); } } diff --git a/src/commands/CommandColiru.java b/src/commands/CommandColiru.java index 25145fa..d16e066 100644 --- a/src/commands/CommandColiru.java +++ b/src/commands/CommandColiru.java @@ -1,6 +1,7 @@ package commands; import core.Command; +import core.Localizer; import dataStructures.*; import network.NetworkColiru; @@ -11,7 +12,7 @@ public class CommandColiru extends Command public CommandColiru(KittyRole level, KittyRating rating) { super(level, rating);} @Override - public String HelpText() { return "Will try to compile any c++ code you put in! Supports up to C++14 standard, uses g++."; } + public String HelpText() { return Localizer.Stub("Will try to compile any c++ code you put in! Supports up to C++14 standard, uses g++."); } @Override public void OnRun(KittyGuild guild, KittyChannel channel, KittyUser user, UserInput input, Response res) diff --git a/src/commands/CommandDoWork.java b/src/commands/CommandDoWork.java index e219695..b1466e3 100644 --- a/src/commands/CommandDoWork.java +++ b/src/commands/CommandDoWork.java @@ -15,7 +15,7 @@ public class CommandDoWork extends Command public CommandDoWork(KittyRole level, KittyRating rating) { super(level, rating); } @Override - public String HelpText() { return "Occupies a core for a few seconds"; } + public String HelpText() { return Localizer.Stub("Occupies a core for a few seconds"); } // Called when the command is run! @Override @@ -28,6 +28,6 @@ public class CommandDoWork extends Command thispieceofshit += Math.log((double)i); } - res.Call("I finished with my work! :D"); + res.Call(Localizer.Stub("I finished with my work! :D")); } } \ No newline at end of file diff --git a/src/commands/CommandEightBall.java b/src/commands/CommandEightBall.java index 642e943..9ec450f 100644 --- a/src/commands/CommandEightBall.java +++ b/src/commands/CommandEightBall.java @@ -1,21 +1,41 @@ package commands; import core.Command; +import core.Localizer; import dataStructures.*; public class CommandEightBall extends Command { - String [] answers = {"It is certain.", "It is decidedly so.", "Without a doubt.", "Yes - definitely.", "You may rely on it.", "As I see it, yes.", "Most likely.", - "Outlook good.", "Yes.", "Signs point to yes.", "Reply hazy, try again.", "Ask again later.", "Better not tell you now.", "Cannot predict now.", - "Concentrate and ask again.", "Don't count on it.", "My reply is no.", "My sources say no.", "Outlook not so good.", "Very doubtful."}; - public CommandEightBall(KittyRole level, KittyRating rating) + String [] answers = { - super(level, rating); - } + Localizer.Stub("It is certain.") + , Localizer.Stub("It is decidedly so.") + , Localizer.Stub("Without a doubt.") + , Localizer.Stub("Yes - definitely.") + , Localizer.Stub("You may rely on it.") + , Localizer.Stub("As I see it, yes.") + , Localizer.Stub("Most likely.") + , Localizer.Stub("Outlook good.") + , Localizer.Stub("Yes.") + , Localizer.Stub("Signs point to yes.") + + , Localizer.Stub("Reply hazy, try again.") + , Localizer.Stub("Ask again later.") + , Localizer.Stub("Better not tell you now.") + , Localizer.Stub("Cannot predict now.") + , Localizer.Stub("Concentrate and ask again.") + + , Localizer.Stub("Don't count on it.") + , Localizer.Stub("My reply is no.") + , Localizer.Stub("My sources say no.") + , Localizer.Stub("Outlook not so good.") + , Localizer.Stub("Very doubtful.") + }; + + public CommandEightBall(KittyRole level, KittyRating rating) { super(level, rating); } @Override - public String HelpText() { return "Answers a yes or no question! Warning: Kitty can not actually tell the future," - + " she claims no responsibility for any lion mauling, lack of lottery wins, or felony charges."; } + public String HelpText() { return Localizer.Stub("Answers a yes or no question! Warning: Kitty can not actually tell the future, she claims no responsibility for any lion mauling, lack of lottery wins, or felony charges."); } @Override public void OnRun(KittyGuild guild, KittyChannel channel, KittyUser user, UserInput input, Response res)