Add ability to complete challenge multiple times at once via command.
This commit is contained in:
parent
526fe9ce81
commit
4e2181f524
|
@ -69,6 +69,8 @@ public class CompleteChallengeCommand extends CompositeCommand
|
|||
String challengeName = Util.getWorld(this.getWorld()).getName() + "_" + args.get(0);
|
||||
Challenge challenge = this.addon.getChallengesManager().getChallenge(challengeName);
|
||||
|
||||
int count = args.size() == 2 ? Integer.valueOf(args.get(1)) : 1;
|
||||
|
||||
if (challenge != null)
|
||||
{
|
||||
return TryToComplete.complete(this.addon,
|
||||
|
@ -76,7 +78,8 @@ public class CompleteChallengeCommand extends CompositeCommand
|
|||
challenge,
|
||||
this.getWorld(),
|
||||
this.getTopLabel(),
|
||||
this.getPermissionPrefix());
|
||||
this.getPermissionPrefix(),
|
||||
count);
|
||||
}
|
||||
else
|
||||
{
|
||||
|
|
Loading…
Reference in New Issue