html.setFile("data/html/merchant/territorystatus.htm");
html.replace("%npcname%", getName());
Castle castle = getCastle(player);
if (castle != null && castle.getId() > 0) {
html.replace("%castlename%", castle.getName());
html.replace("%taxpercent%", String.valueOf(castle.getTaxPercent()));
if (castle.getOwnerId() > 0) {
L2Clan clan = ClanTable.getInstance().getClan(castle.getOwnerId());
if (clan != null) {
html.replace("%clanname%", clan.getName());
html.replace("%clanleadername%", clan.getLeaderName());