Added Hobbit card quantity restrictions

Also added a forum link as per request by Enola. I am very illiterate in HTML, so ensure I haven't made any mistakes here.
This commit is contained in:
PhallenCassidy
2016-10-24 10:51:15 -04:00
committed by GitHub
parent b2d127a271
commit 99afc9e546

View File

@@ -350,6 +350,20 @@ public class HallRequestHandler extends LotroServerRequestHandler implements Uri
if (lotroFormat.getValidCards().size() == 0)
result.append("none,");
result.append("</li>");
//Additional Hobbit Draft format section
if (lotroFormat.getLimit2Cards().size() != 0) {
result.append("<li>Cards limited to 2 copies: ");
for (String blueprintId : lotroFormat.getLimit2Cards())
result.append(GameUtils.getCardLink(blueprintId, _library.getLotroCardBlueprint(blueprintId)) + ", ");
result.append("</li>");
}
if (lotroFormat.getLimit3Cards().size() != 0) {
result.append("<li>Cards limited to 3 copies: ");
for (String blueprintId : lotroFormat.getLimit3Cards())
result.append(GameUtils.getCardLink(blueprintId, _library.getLotroCardBlueprint(blueprintId)) + ", ");
result.append("</li>");
result.append('<a href="http://lotrtcgwiki.com/forums/index.php/topic,10735.0.html">Click here for additional information</a>');
}
result.append("</ul>");
responseWriter.writeHtmlResponse(result.toString());
@@ -384,6 +398,20 @@ public class HallRequestHandler extends LotroServerRequestHandler implements Uri
if (lotroFormat.getValidCards().size() == 0)
result.append("none,");
result.append("</li>");
//Additional Hobbit Draft format section
if (lotroFormat.getLimit2Cards().size() != 0) {
result.append("<li>Cards limited to 2 copies: ");
for (String blueprintId : lotroFormat.getLimit2Cards())
result.append(GameUtils.getCardLink(blueprintId, _library.getLotroCardBlueprint(blueprintId)) + ", ");
result.append("</li>");
}
if (lotroFormat.getLimit3Cards().size() != 0) {
result.append("<li>Cards limited to 3 copies: ");
for (String blueprintId : lotroFormat.getLimit3Cards())
result.append(GameUtils.getCardLink(blueprintId, _library.getLotroCardBlueprint(blueprintId)) + ", ");
result.append("</li>");
result.append('<a href="http://lotrtcgwiki.com/forums/index.php/topic,10735.0.html">Click here for additional information</a>');
}
result.append("</ul>");
}