Allow build organizations to be defined in XML

I would like this for this to be a thing

<organizations>
<organization uuid="uuid" contribution="Lobby Framework"/> <!-- Some
Build Team-->
</organizations>

If not then close me because I have no idea how to code
This commit is contained in:
Seth Winston 2017-08-20 21:15:50 -04:00
parent de6db0c98c
commit f3fcbba541
1 changed files with 14 additions and 0 deletions

View File

@ -232,6 +232,20 @@ public class MapCommands implements Commands {
}
}
List<Organization> organizations = mapInfo.getNamedOrganizations();
if(organizations.size() == 1) {
audience.sendMessage(new Component(
mapInfoLabel("command.map.mapInfo.organizationSingular"),
formatContribution(organizations.get(0))
));
} else if(!organizations.isEmpty()) {
audience.sendMessage(mapInfoLabel("command.map.mapInfo.organizationPlural"));
for(Contributor organization : organizations) {
audience.sendMessage(new Component(" ").extra(formatContribution(organization)));
}
}
if(mapInfo.rules.size() > 0) {
audience.sendMessage(mapInfoLabel("command.map.mapInfo.rules"));