+ Added flippable trade command arguments
This commit is contained in:
@@ -27,14 +27,23 @@ public class CommandTradeBeans extends Command
|
|||||||
}
|
}
|
||||||
|
|
||||||
int beans = 0;
|
int beans = 0;
|
||||||
try {
|
|
||||||
|
try
|
||||||
|
{
|
||||||
beans = Integer.parseInt(input.args.split(" ")[0]);
|
beans = Integer.parseInt(input.args.split(" ")[0]);
|
||||||
}
|
}
|
||||||
catch (NumberFormatException e)
|
catch (NumberFormatException e)
|
||||||
|
{
|
||||||
|
try
|
||||||
|
{
|
||||||
|
beans = Integer.parseInt(input.args.split(" ")[1]);
|
||||||
|
}
|
||||||
|
catch(Exception eInner)
|
||||||
{
|
{
|
||||||
res.send(LocStrings.stub("TradeBeansIntParseError"));
|
res.send(LocStrings.stub("TradeBeansIntParseError"));
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
if(user.getBeans() < beans)
|
if(user.getBeans() < beans)
|
||||||
{
|
{
|
||||||
|
|||||||
Reference in New Issue
Block a user