Code improvements.

This commit is contained in:
MobiusDev
2016-04-24 16:30:15 +00:00
parent 8bd51aba1c
commit 2dd14bef9b
860 changed files with 8865 additions and 17041 deletions

View File

@@ -177,8 +177,7 @@ final class Wedding extends AbstractNpcAI
@Override
public String onFirstTalk(L2Npc npc, L2PcInstance player)
{
final String htmltext = getHtm(player.getHtmlPrefix(), "Start.html");
return htmltext.replaceAll("%fee%", String.valueOf(Config.L2JMOD_WEDDING_PRICE));
return getHtm(player.getHtmlPrefix(), "Start.html").replaceAll("%fee%", String.valueOf(Config.L2JMOD_WEDDING_PRICE));
}
private String sendHtml(L2PcInstance player, String fileName, String regex, String replacement)

View File

@@ -139,8 +139,7 @@ public class ListenerTest extends AbstractNpcAI
// Make sure a player killed this monster.
if ((event.getAttacker() != null) && event.getAttacker().isPlayable() && event.getTarget().isAttackable())
{
final L2Attackable monster = (L2Attackable) event.getTarget();
monster.dropItem(event.getAttacker().getActingPlayer(), new ItemHolder(57, Rnd.get(100, 1000)));
((L2Attackable) event.getTarget()).dropItem(event.getAttacker().getActingPlayer(), new ItemHolder(57, Rnd.get(100, 1000)));
}
}