Skip to content

Commit

Permalink
Add asnpclist type for flag tags which will return the values in a fl…
Browse files Browse the repository at this point in the history
…ag list with "npc." in front of them.
  • Loading branch information
davidcernat committed Mar 18, 2013
1 parent b8f709b commit 654fddc
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/main/java/net/aufdemrand/denizen/tags/core/FlagTags.java
Expand Up @@ -20,7 +20,7 @@ public FlagTags(Denizen denizen) {
denizen.getServer().getPluginManager().registerEvents(this, denizen);
}

private enum ReplaceType { LENGTH, SIZE, ASSTRING, ASINT, ASDOUBLE, ASLIST, ASMONEY, ASPLAYERLIST, ASCSLIST, ISEXPIRED, EXPIRATION }
private enum ReplaceType { LENGTH, SIZE, ASSTRING, ASINT, ASDOUBLE, ASLIST, ASMONEY, ASPLAYERLIST, ASNPCLIST, ASCSLIST, ISEXPIRED, EXPIRATION }

/**
* Replaces FLAG TAGs. Called automatically by the dScript ScriptBuilder and Executer.
Expand Down Expand Up @@ -113,6 +113,8 @@ private String getReplaceable(FlagManager.Flag flag, Value value, ReplaceType re
return String.valueOf(value.asList());
case ASPLAYERLIST:
return String.valueOf(value.asList("player."));
case ASNPCLIST:
return String.valueOf(value.asList("npc."));
case ASCSLIST:
return String.valueOf(value.asCommaSeparatedList());
case ASMONEY:
Expand Down

0 comments on commit 654fddc

Please sign in to comment.