Replaced compareToIgnoreCase with equalsIgnoreCase.

This commit is contained in:
MobiusDevelopment 2020-01-24 20:00:24 +00:00
parent d4a8f7b744
commit 58f656ad74
3 changed files with 7 additions and 7 deletions

View File

@ -40,7 +40,7 @@ import org.l2jmobius.gameserver.network.serverpackets.NpcHtmlMessage;
* easier handling (s. admin command admin_box_access).<br>
* <br>
* To spawn an BoxInstance change the type in npc to Box.<br>
* example: update npc set type='L2Box' where id=1042;<br>
* example: update npc set type='Box' where id=1042;<br>
* It uses two tables: boxes and boxaccess. Create these with:<br>
* <code>
CREATE TABLE boxes (<br>

View File

@ -845,7 +845,7 @@ public class PetInstance extends Summon
try (Connection con = DatabaseFactory.getConnection())
{
if (template.getType().compareToIgnoreCase("BabyPet") == 0)
if (template.getType().equalsIgnoreCase("BabyPet"))
{
pet = new BabyPetInstance(IdFactory.getInstance().getNextId(), template, owner, control);
}

View File

@ -81,27 +81,27 @@ public class VIP
public static void setTeam(String team, PlayerInstance player)
{
if (team.compareToIgnoreCase("Human") == 0)
if (team.equalsIgnoreCase("Human"))
{
_team = 1;
_teamName = "Human";
}
else if (team.compareToIgnoreCase("Elf") == 0)
else if (team.equalsIgnoreCase("Elf"))
{
_team = 2;
_teamName = "Elf";
}
else if (team.compareToIgnoreCase("Dark") == 0)
else if (team.equalsIgnoreCase("Dark"))
{
_team = 3;
_teamName = "Dark Elf";
}
else if (team.compareToIgnoreCase("Orc") == 0)
else if (team.equalsIgnoreCase("Orc"))
{
_team = 4;
_teamName = "Orc";
}
else if (team.compareToIgnoreCase("Dwarf") == 0)
else if (team.equalsIgnoreCase("Dwarf"))
{
_team = 5;
_teamName = "Dwarf";