Dropped addCharName message parameter.
This commit is contained in:
@ -158,7 +158,7 @@ public final class HandysBlockCheckerManager
|
||||
if (_arenaPlayers[i].getAllPlayers().contains(player))
|
||||
{
|
||||
final SystemMessage msg = SystemMessage.getSystemMessage(SystemMessageId.C1_IS_ALREADY_REGISTERED_ON_THE_MATCH_WAITING_LIST);
|
||||
msg.addCharName(player);
|
||||
msg.addString(player.getName());
|
||||
player.sendPacket(msg);
|
||||
return false;
|
||||
}
|
||||
|
@ -436,7 +436,7 @@ public class L2Party extends AbstractPlayerGroup
|
||||
|
||||
final SystemMessage sm = SystemMessage.getSystemMessage(SystemMessageId.C1_USED_S3_ON_C2);
|
||||
sm.addPcName(activeChar);
|
||||
sm.addCharName(target);
|
||||
sm.addString(target.getName());
|
||||
sm.addSystemString(TACTICAL_SYS_STRINGS[tacticalSignId]);
|
||||
|
||||
getMembers().forEach(m ->
|
||||
@ -459,7 +459,7 @@ public class L2Party extends AbstractPlayerGroup
|
||||
|
||||
final SystemMessage sm = SystemMessage.getSystemMessage(SystemMessageId.C1_USED_S3_ON_C2);
|
||||
sm.addPcName(activeChar);
|
||||
sm.addCharName(target);
|
||||
sm.addString(target.getName());
|
||||
sm.addSystemString(TACTICAL_SYS_STRINGS[tacticalSignId]);
|
||||
|
||||
getMembers().forEach(m ->
|
||||
|
@ -1026,7 +1026,7 @@ public class L2Attackable extends L2Npc
|
||||
if (isRaid() && !isRaidMinion())
|
||||
{
|
||||
final SystemMessage sm = SystemMessage.getSystemMessage(SystemMessageId.C1_DIED_AND_DROPPED_S3_S2_S);
|
||||
sm.addCharName(this);
|
||||
sm.addString(getName());
|
||||
sm.addItemName(item);
|
||||
sm.addLong(drop.getCount());
|
||||
broadcastPacket(sm);
|
||||
|
@ -11510,7 +11510,7 @@ public final class L2PcInstance extends L2Playable
|
||||
{
|
||||
final SystemMessage sm = SystemMessage.getSystemMessage(SystemMessageId.C1_HAS_EVADED_C2_S_ATTACK);
|
||||
sm.addPcName(target.getActingPlayer());
|
||||
sm.addCharName(this);
|
||||
sm.addString(getName());
|
||||
target.sendPacket(sm);
|
||||
}
|
||||
final SystemMessage sm = SystemMessage.getSystemMessage(SystemMessageId.C1_S_ATTACK_WENT_ASTRAY);
|
||||
|
@ -272,7 +272,7 @@ public final class L2TrapInstance extends L2Npc
|
||||
else
|
||||
{
|
||||
final SystemMessage sm = SystemMessage.getSystemMessage(SystemMessageId.C1_HAS_INFLICTED_S3_DAMAGE_ON_C2_S4);
|
||||
sm.addCharName(this);
|
||||
sm.addString(getName());
|
||||
sm.addString(target.getName());
|
||||
sm.addInt(damage);
|
||||
sm.addPopup(target.getObjectId(), getObjectId(), (damage * -1));
|
||||
|
@ -52,7 +52,7 @@ public class PetStatus extends SummonStatus
|
||||
if (!isDOT && (getActiveChar().getOwner() != null))
|
||||
{
|
||||
final SystemMessage sm = SystemMessage.getSystemMessage(SystemMessageId.YOUR_PET_RECEIVED_S2_DAMAGE_BY_C1);
|
||||
sm.addCharName(attacker);
|
||||
sm.addString(attacker.getName());
|
||||
sm.addInt((int) value);
|
||||
getActiveChar().sendPacket(sm);
|
||||
}
|
||||
|
@ -287,7 +287,7 @@ public class CeremonyOfChaosEvent extends AbstractEvent<CeremonyOfChaosMember>
|
||||
else
|
||||
{
|
||||
msg = SystemMessage.getSystemMessage(SystemMessageId.CONGRATULATIONS_C1_YOU_WIN_THE_MATCH);
|
||||
msg.addCharName(winners.get(0).getPlayer());
|
||||
msg.addString(winners.get(0).getPlayer().getName());
|
||||
}
|
||||
|
||||
for (CeremonyOfChaosMember member : getMembers().values())
|
||||
|
@ -31,7 +31,7 @@ public final class ConditionDistance extends Condition
|
||||
public ConditionDistance(InstanceTemplate template, StatsSet parameters, boolean onlyLeader, boolean showMessageAndHtml)
|
||||
{
|
||||
super(template, parameters, onlyLeader, showMessageAndHtml);
|
||||
setSystemMessage(SystemMessageId.C1_IS_IN_A_LOCATION_WHICH_CANNOT_BE_ENTERED_THEREFORE_IT_CANNOT_BE_PROCESSED, (message, player) -> message.addCharName(player));
|
||||
setSystemMessage(SystemMessageId.C1_IS_IN_A_LOCATION_WHICH_CANNOT_BE_ENTERED_THEREFORE_IT_CANNOT_BE_PROCESSED, (message, player) -> message.addString(player.getName()));
|
||||
}
|
||||
|
||||
@Override
|
||||
|
@ -40,7 +40,7 @@ public final class ConditionItem extends Condition
|
||||
_count = parameters.getLong("count");
|
||||
_take = parameters.getBoolean("take", false);
|
||||
// Set message
|
||||
setSystemMessage(SystemMessageId.C1_S_ITEM_REQUIREMENT_IS_NOT_SUFFICIENT_AND_CANNOT_BE_ENTERED, (msg, player) -> msg.addCharName(player));
|
||||
setSystemMessage(SystemMessageId.C1_S_ITEM_REQUIREMENT_IS_NOT_SUFFICIENT_AND_CANNOT_BE_ENTERED, (msg, player) -> msg.addString(player.getName()));
|
||||
}
|
||||
|
||||
@Override
|
||||
|
@ -38,7 +38,7 @@ public final class ConditionLevel extends Condition
|
||||
_min = parameters.getInt("min", 1);
|
||||
_max = parameters.getInt("max", Integer.MAX_VALUE);
|
||||
// Set message
|
||||
setSystemMessage(SystemMessageId.C1_S_LEVEL_DOES_NOT_CORRESPOND_TO_THE_REQUIREMENTS_FOR_ENTRY, (msg, player) -> msg.addCharName(player));
|
||||
setSystemMessage(SystemMessageId.C1_S_LEVEL_DOES_NOT_CORRESPOND_TO_THE_REQUIREMENTS_FOR_ENTRY, (msg, player) -> msg.addString(player.getName()));
|
||||
}
|
||||
|
||||
@Override
|
||||
|
@ -35,7 +35,7 @@ public final class ConditionQuest extends Condition
|
||||
{
|
||||
super(template, parameters, onlyLeader, showMessageAndHtml);
|
||||
// Set message
|
||||
setSystemMessage(SystemMessageId.C1_S_QUEST_REQUIREMENT_IS_NOT_SUFFICIENT_AND_CANNOT_BE_ENTERED, (message, player) -> message.addCharName(player));
|
||||
setSystemMessage(SystemMessageId.C1_S_QUEST_REQUIREMENT_IS_NOT_SUFFICIENT_AND_CANNOT_BE_ENTERED, (message, player) -> message.addString(player.getName()));
|
||||
}
|
||||
|
||||
@Override
|
||||
|
@ -33,7 +33,7 @@ public final class ConditionReenter extends Condition
|
||||
public ConditionReenter(InstanceTemplate template, StatsSet parameters, boolean onlyLeader, boolean showMessageAndHtml)
|
||||
{
|
||||
super(template, parameters, onlyLeader, showMessageAndHtml);
|
||||
setSystemMessage(SystemMessageId.C1_MAY_NOT_RE_ENTER_YET, (message, player) -> message.addCharName(player));
|
||||
setSystemMessage(SystemMessageId.C1_MAY_NOT_RE_ENTER_YET, (message, player) -> message.addString(player.getName()));
|
||||
}
|
||||
|
||||
@Override
|
||||
|
@ -175,7 +175,7 @@ public final class Formulas
|
||||
else
|
||||
{
|
||||
final SystemMessage sm = SystemMessage.getSystemMessage(SystemMessageId.C1_HAS_RESISTED_YOUR_S2);
|
||||
sm.addCharName(target);
|
||||
sm.addString(target.getName());
|
||||
sm.addSkillName(skill);
|
||||
attacker.sendPacket(sm);
|
||||
damage = 1;
|
||||
@ -185,7 +185,7 @@ public final class Formulas
|
||||
if (target.isPlayer())
|
||||
{
|
||||
final SystemMessage sm = (skill.hasEffectType(L2EffectType.HP_DRAIN)) ? SystemMessage.getSystemMessage(SystemMessageId.YOU_RESISTED_C1_S_DRAIN) : SystemMessage.getSystemMessage(SystemMessageId.YOU_RESISTED_C1_S_MAGIC);
|
||||
sm.addCharName(attacker);
|
||||
sm.addString(attacker.getName());
|
||||
target.sendPacket(sm);
|
||||
}
|
||||
}
|
||||
@ -674,7 +674,7 @@ public final class Formulas
|
||||
if (resisted)
|
||||
{
|
||||
final SystemMessage sm = SystemMessage.getSystemMessage(SystemMessageId.C1_HAS_RESISTED_YOUR_S2);
|
||||
sm.addCharName(target);
|
||||
sm.addString(target.getName());
|
||||
sm.addSkillName(skill);
|
||||
attacker.sendPacket(sm);
|
||||
return false;
|
||||
@ -705,7 +705,7 @@ public final class Formulas
|
||||
if ((finalRate <= Rnd.get(100)) && (target != attacker))
|
||||
{
|
||||
final SystemMessage sm = SystemMessage.getSystemMessage(SystemMessageId.C1_HAS_RESISTED_YOUR_S2);
|
||||
sm.addCharName(target);
|
||||
sm.addString(target.getName());
|
||||
sm.addSkillName(skill);
|
||||
attacker.sendPacket(sm);
|
||||
return false;
|
||||
@ -837,8 +837,8 @@ public final class Formulas
|
||||
if (attacker.isPlayer())
|
||||
{
|
||||
final SystemMessage sm = SystemMessage.getSystemMessage(SystemMessageId.DAMAGE_IS_DECREASED_BECAUSE_C1_RESISTED_C2_S_MAGIC);
|
||||
sm.addCharName(target);
|
||||
sm.addCharName(attacker);
|
||||
sm.addString(target.getName());
|
||||
sm.addString(attacker.getName());
|
||||
attacker.sendPacket(sm);
|
||||
damage /= 2;
|
||||
}
|
||||
@ -846,8 +846,8 @@ public final class Formulas
|
||||
if (target.isPlayer())
|
||||
{
|
||||
final SystemMessage sm2 = SystemMessage.getSystemMessage(SystemMessageId.C1_WEAKLY_RESISTED_C2_S_MAGIC);
|
||||
sm2.addCharName(target);
|
||||
sm2.addCharName(attacker);
|
||||
sm2.addString(target.getName());
|
||||
sm2.addString(attacker.getName());
|
||||
target.sendPacket(sm2);
|
||||
}
|
||||
}
|
||||
@ -976,13 +976,13 @@ public final class Formulas
|
||||
if (target.isPlayer())
|
||||
{
|
||||
final SystemMessage sm = SystemMessage.getSystemMessage(SystemMessageId.YOU_COUNTERED_C1_S_ATTACK);
|
||||
sm.addCharName(attacker);
|
||||
sm.addString(attacker.getName());
|
||||
target.sendPacket(sm);
|
||||
}
|
||||
if (attacker.isPlayer())
|
||||
{
|
||||
final SystemMessage sm = SystemMessage.getSystemMessage(SystemMessageId.C1_IS_PERFORMING_A_COUNTERATTACK);
|
||||
sm.addCharName(target);
|
||||
sm.addString(target.getName());
|
||||
attacker.sendPacket(sm);
|
||||
}
|
||||
|
||||
|
@ -210,7 +210,7 @@ public final class RequestCancelPostAttachment implements IClientIncomingPacket
|
||||
if (receiver != null)
|
||||
{
|
||||
final SystemMessage sm = SystemMessage.getSystemMessage(SystemMessageId.S1_CANCELED_THE_SENT_MAIL);
|
||||
sm.addCharName(activeChar);
|
||||
sm.addString(activeChar.getName());
|
||||
receiver.sendPacket(sm);
|
||||
receiver.sendPacket(new ExChangePostState(true, _msgId, Message.DELETED));
|
||||
}
|
||||
|
@ -233,7 +233,7 @@ public final class RequestEnchantItem implements IClientIncomingPacket
|
||||
if ((item.getEnchantLevel() == minEnchantAnnounce) || (item.getEnchantLevel() == maxEnchantAnnounce))
|
||||
{
|
||||
final SystemMessage sm = SystemMessage.getSystemMessage(SystemMessageId.C1_HAS_SUCCESSFULLY_ENCHANTED_A_S2_S3);
|
||||
sm.addCharName(activeChar);
|
||||
sm.addString(activeChar.getName());
|
||||
sm.addInt(item.getEnchantLevel());
|
||||
sm.addItemName(item);
|
||||
activeChar.broadcastPacket(sm);
|
||||
|
@ -115,7 +115,7 @@ public final class RequestJoinParty implements IClientIncomingPacket
|
||||
if (target.isPartyBanned())
|
||||
{
|
||||
final SystemMessage sm = SystemMessage.getSystemMessage(SystemMessageId.C1_HAS_BEEN_REPORTED_AS_AN_ILLEGAL_PROGRAM_USER_AND_CANNOT_JOIN_A_PARTY);
|
||||
sm.addCharName(target);
|
||||
sm.addString(target.getName());
|
||||
requestor.sendPacket(sm);
|
||||
return;
|
||||
}
|
||||
@ -144,7 +144,7 @@ public final class RequestJoinParty implements IClientIncomingPacket
|
||||
if (BlockList.isBlocked(target, requestor))
|
||||
{
|
||||
sm = SystemMessage.getSystemMessage(SystemMessageId.C1_HAS_PLACED_YOU_ON_HIS_HER_IGNORE_LIST);
|
||||
sm.addCharName(target);
|
||||
sm.addString(target.getName());
|
||||
requestor.sendPacket(sm);
|
||||
return;
|
||||
}
|
||||
@ -177,7 +177,7 @@ public final class RequestJoinParty implements IClientIncomingPacket
|
||||
}
|
||||
|
||||
sm = SystemMessage.getSystemMessage(SystemMessageId.C1_HAS_BEEN_INVITED_TO_THE_PARTY);
|
||||
sm.addCharName(target);
|
||||
sm.addString(target.getName());
|
||||
requestor.sendPacket(sm);
|
||||
|
||||
if (!requestor.isInParty())
|
||||
|
@ -244,7 +244,7 @@ public final class RequestPostAttachment implements IClientIncomingPacket
|
||||
sender.addAdena("PayMail", adena, activeChar, false);
|
||||
sm = SystemMessage.getSystemMessage(SystemMessageId.S2_HAS_MADE_A_PAYMENT_OF_S1_ADENA_PER_YOUR_PAYMENT_REQUEST_MAIL);
|
||||
sm.addLong(adena);
|
||||
sm.addCharName(activeChar);
|
||||
sm.addString(activeChar.getName());
|
||||
sender.sendPacket(sm);
|
||||
}
|
||||
else
|
||||
@ -259,7 +259,7 @@ public final class RequestPostAttachment implements IClientIncomingPacket
|
||||
else if (sender != null)
|
||||
{
|
||||
sm = SystemMessage.getSystemMessage(SystemMessageId.S1_ACQUIRED_THE_ATTACHED_ITEM_TO_YOUR_MAIL);
|
||||
sm.addCharName(activeChar);
|
||||
sm.addString(activeChar.getName());
|
||||
sender.sendPacket(sm);
|
||||
}
|
||||
|
||||
|
@ -95,7 +95,7 @@ public final class RequestRejectPostAttachment implements IClientIncomingPacket
|
||||
if (sender != null)
|
||||
{
|
||||
final SystemMessage sm = SystemMessage.getSystemMessage(SystemMessageId.S1_RETURNED_THE_MAIL);
|
||||
sm.addCharName(activeChar);
|
||||
sm.addString(activeChar.getName());
|
||||
sender.sendPacket(sm);
|
||||
}
|
||||
}
|
||||
|
@ -160,7 +160,7 @@ public final class TradeRequest implements IClientIncomingPacket
|
||||
if (!effect.checkCondition(BotReportTable.TRADE_ACTION_BLOCK_ID))
|
||||
{
|
||||
final SystemMessage sm = SystemMessage.getSystemMessage(SystemMessageId.C1_HAS_BEEN_REPORTED_AS_AN_ILLEGAL_PROGRAM_USER_AND_IS_CURRENTLY_BEING_INVESTIGATED);
|
||||
sm.addCharName(partner);
|
||||
sm.addString(partner.getName());
|
||||
client.sendPacket(sm);
|
||||
client.sendPacket(ActionFailed.STATIC_PACKET);
|
||||
return;
|
||||
@ -217,7 +217,7 @@ public final class TradeRequest implements IClientIncomingPacket
|
||||
if (BlockList.isBlocked(partner, player))
|
||||
{
|
||||
sm = SystemMessage.getSystemMessage(SystemMessageId.C1_HAS_PLACED_YOU_ON_HIS_HER_IGNORE_LIST);
|
||||
sm.addCharName(partner);
|
||||
sm.addString(partner.getName());
|
||||
client.sendPacket(sm);
|
||||
return;
|
||||
}
|
||||
|
@ -66,7 +66,7 @@ public final class RequestAnswerFriendInvite implements IClientIncomingPacket
|
||||
|| requestor.getFriendList().contains(player.getObjectId()))
|
||||
{
|
||||
final SystemMessage sm = SystemMessage.getSystemMessage(SystemMessageId.C1_IS_ALREADY_ON_YOUR_FRIEND_LIST);
|
||||
sm.addCharName(player);
|
||||
sm.addString(player.getName());
|
||||
requestor.sendPacket(sm);
|
||||
return;
|
||||
}
|
||||
|
@ -116,7 +116,7 @@ public final class RequestFriendInvite implements IClientIncomingPacket
|
||||
if (BlockList.isBlocked(activeChar, friend))
|
||||
{
|
||||
sm = SystemMessage.getSystemMessage(SystemMessageId.YOU_HAVE_BLOCKED_C1);
|
||||
sm.addCharName(friend);
|
||||
sm.addString(friend.getName());
|
||||
activeChar.sendPacket(sm);
|
||||
return;
|
||||
}
|
||||
|
@ -69,8 +69,8 @@ public class ConfirmMenteeAdd implements IClientIncomingPacket
|
||||
|
||||
if (_confirmed == 0)
|
||||
{
|
||||
mentee.sendPacket(SystemMessage.getSystemMessage(SystemMessageId.YOU_HAVE_DECLINED_S1_S_MENTORING_OFFER).addCharName(mentor));
|
||||
mentor.sendPacket(SystemMessage.getSystemMessage(SystemMessageId.S1_HAS_DECLINED_BECOMING_YOUR_MENTEE).addCharName(mentee));
|
||||
mentee.sendPacket(SystemMessage.getSystemMessage(SystemMessageId.YOU_HAVE_DECLINED_S1_S_MENTORING_OFFER).addString(mentor.getName()));
|
||||
mentor.sendPacket(SystemMessage.getSystemMessage(SystemMessageId.S1_HAS_DECLINED_BECOMING_YOUR_MENTEE).addString(mentee.getName()));
|
||||
}
|
||||
else if (validate(mentor, mentee))
|
||||
{
|
||||
@ -86,10 +86,10 @@ public class ConfirmMenteeAdd implements IClientIncomingPacket
|
||||
// Notify to scripts
|
||||
EventDispatcher.getInstance().notifyEventAsync(new OnPlayerMenteeAdd(mentor, mentee), mentor);
|
||||
|
||||
mentor.sendPacket(SystemMessage.getSystemMessage(SystemMessageId.FROM_NOW_ON_S1_WILL_BE_YOUR_MENTEE).addCharName(mentee));
|
||||
mentor.sendPacket(SystemMessage.getSystemMessage(SystemMessageId.FROM_NOW_ON_S1_WILL_BE_YOUR_MENTEE).addString(mentee.getName()));
|
||||
mentor.sendPacket(new ExMentorList(mentor));
|
||||
|
||||
mentee.sendPacket(SystemMessage.getSystemMessage(SystemMessageId.FROM_NOW_ON_S1_WILL_BE_YOUR_MENTOR).addCharName(mentor));
|
||||
mentee.sendPacket(SystemMessage.getSystemMessage(SystemMessageId.FROM_NOW_ON_S1_WILL_BE_YOUR_MENTOR).addString(mentor.getName()));
|
||||
mentee.sendPacket(new ExMentorList(mentee));
|
||||
}
|
||||
catch (Exception e)
|
||||
@ -142,7 +142,7 @@ public class ConfirmMenteeAdd implements IClientIncomingPacket
|
||||
}
|
||||
else if (mentee.getLevel() >= 86)
|
||||
{
|
||||
mentor.sendPacket(SystemMessage.getSystemMessage(SystemMessageId.S1_IS_ABOVE_LEVEL_85_AND_CANNOT_BECOME_A_MENTEE).addCharName(mentee));
|
||||
mentor.sendPacket(SystemMessage.getSystemMessage(SystemMessageId.S1_IS_ABOVE_LEVEL_85_AND_CANNOT_BECOME_A_MENTEE).addString(mentee.getName()));
|
||||
return false;
|
||||
}
|
||||
else if (mentee.isSubClassActive())
|
||||
@ -153,7 +153,7 @@ public class ConfirmMenteeAdd implements IClientIncomingPacket
|
||||
|
||||
// else if (mentee.getInventory().getItemByItemId(MENTEE_CERT) == null)
|
||||
// {
|
||||
// mentor.sendPacket(SystemMessage.getSystemMessage(SystemMessageId.S1_DOES_NOT_HAVE_THE_ITEM_NEEDED_TO_BECOME_A_MENTEE).addCharName(mentee));
|
||||
// mentor.sendPacket(SystemMessage.getSystemMessage(SystemMessageId.S1_DOES_NOT_HAVE_THE_ITEM_NEEDED_TO_BECOME_A_MENTEE).addString(mentee));
|
||||
// return false;
|
||||
// }
|
||||
else if ((MentorManager.getInstance().getMentees(mentor.getObjectId()) != null) && (MentorManager.getInstance().getMentees(mentor.getObjectId()).size() >= 3))
|
||||
@ -163,7 +163,7 @@ public class ConfirmMenteeAdd implements IClientIncomingPacket
|
||||
}
|
||||
else if (mentee.isMentee())
|
||||
{
|
||||
mentor.sendPacket(SystemMessage.getSystemMessage(SystemMessageId.S1_ALREADY_HAS_A_MENTOR).addCharName(mentee));
|
||||
mentor.sendPacket(SystemMessage.getSystemMessage(SystemMessageId.S1_ALREADY_HAS_A_MENTOR).addString(mentee.getName()));
|
||||
return false;
|
||||
}
|
||||
return true;
|
||||
|
@ -56,7 +56,7 @@ public class RequestMenteeAdd implements IClientIncomingPacket
|
||||
|
||||
if (ConfirmMenteeAdd.validate(mentor, mentee))
|
||||
{
|
||||
mentor.sendPacket(SystemMessage.getSystemMessage(SystemMessageId.YOU_HAVE_OFFERED_TO_BECOME_S1_S_MENTOR).addCharName(mentee));
|
||||
mentor.sendPacket(SystemMessage.getSystemMessage(SystemMessageId.YOU_HAVE_OFFERED_TO_BECOME_S1_S_MENTOR).addString(mentee.getName()));
|
||||
mentee.sendPacket(new ExMentorAdd(mentor));
|
||||
}
|
||||
}
|
||||
|
@ -21,10 +21,8 @@ import java.util.Arrays;
|
||||
|
||||
import com.l2jmobius.commons.network.PacketWriter;
|
||||
import com.l2jmobius.gameserver.datatables.ItemTable;
|
||||
import com.l2jmobius.gameserver.model.actor.L2Character;
|
||||
import com.l2jmobius.gameserver.model.actor.L2Npc;
|
||||
import com.l2jmobius.gameserver.model.actor.L2Summon;
|
||||
import com.l2jmobius.gameserver.model.actor.instance.L2DoorInstance;
|
||||
import com.l2jmobius.gameserver.model.actor.instance.L2PcInstance;
|
||||
import com.l2jmobius.gameserver.model.actor.templates.L2NpcTemplate;
|
||||
import com.l2jmobius.gameserver.model.items.L2Item;
|
||||
@ -182,38 +180,6 @@ public abstract class AbstractMessagePacket<T extends AbstractMessagePacket<?>>
|
||||
return (T) this;
|
||||
}
|
||||
|
||||
public final T addCharName(L2Character cha)
|
||||
{
|
||||
if (cha.isNpc())
|
||||
{
|
||||
final L2Npc npc = (L2Npc) cha;
|
||||
if (npc.getTemplate().isUsingServerSideName())
|
||||
{
|
||||
return addString(npc.getTemplate().getName());
|
||||
}
|
||||
return addNpcName(npc);
|
||||
}
|
||||
else if (cha.isPlayer())
|
||||
{
|
||||
return addPcName(cha.getActingPlayer());
|
||||
}
|
||||
else if (cha.isSummon())
|
||||
{
|
||||
final L2Summon summon = (L2Summon) cha;
|
||||
if (summon.getTemplate().isUsingServerSideName())
|
||||
{
|
||||
return addString(summon.getTemplate().getName());
|
||||
}
|
||||
return addNpcName(summon);
|
||||
}
|
||||
else if (cha.isDoor())
|
||||
{
|
||||
final L2DoorInstance door = (L2DoorInstance) cha;
|
||||
return addDoorName(door.getId());
|
||||
}
|
||||
return addString(cha.getName());
|
||||
}
|
||||
|
||||
public final T addPcName(L2PcInstance pc)
|
||||
{
|
||||
append(new SMParam(TYPE_PLAYER_NAME, pc.getAppearance().getVisibleName()));
|
||||
|
Reference in New Issue
Block a user