I just added in pvp zones to get pvp point. But it does not update istant. The pvp winner must teleport or die so his pvps update +1. So i would like it to update instant if its possible.
l2jaCis
Here is the code:
// If in pvp zone, add pvp point.
if (isInsideZone(ZoneId.PVP) && targetPlayer.isInsideZone(ZoneId.PVP))
{
setPvpKills(getPvpKills() + 1);
// Until the zone was a siege zone. Check also if victim was a player. Randomers aren't counted.
if (target instanceof L2PcInstance && getSiegeState() > 0 && targetPlayer.getSiegeState() > 0 && getSiegeState() != targetPlayer.getSiegeState())
{
// Now check clan relations.
final L2Clan killerClan = getClan();
if (killerClan != null)
killerClan.setSiegeKills(killerClan.getSiegeKills() + 1);
final L2Clan targetClan = targetPlayer.getClan();
if (targetClan != null)
targetClan.setSiegeDeaths(targetClan.getSiegeDeaths() + 1);
}
return;
}
When I have free time, I will update it for version 409.
I might also make some changes, such as allowing you to choose whether you want the berserker at level 1 or 2.
The sale of the pack is valid until 12/31/2024.
The share is prohibited at any time, in any form.
This pack will never be shared by me personally because too many people work on it.
If you bought or will buy the pack not from me, do not expect any claims regarding functionality, answers to questions, help, etc., do not even write))
Question
MaDu7zU
Hello Guys!
I just added in pvp zones to get pvp point. But it does not update istant. The pvp winner must teleport or die so his pvps update +1. So i would like it to update instant if its possible.
l2jaCis
Here is the code:
// If in pvp zone, add pvp point. if (isInsideZone(ZoneId.PVP) && targetPlayer.isInsideZone(ZoneId.PVP)) { setPvpKills(getPvpKills() + 1); // Until the zone was a siege zone. Check also if victim was a player. Randomers aren't counted. if (target instanceof L2PcInstance && getSiegeState() > 0 && targetPlayer.getSiegeState() > 0 && getSiegeState() != targetPlayer.getSiegeState()) { // Now check clan relations. final L2Clan killerClan = getClan(); if (killerClan != null) killerClan.setSiegeKills(killerClan.getSiegeKills() + 1); final L2Clan targetClan = targetPlayer.getClan(); if (targetClan != null) targetClan.setSiegeDeaths(targetClan.getSiegeDeaths() + 1); } return; }
Okay i just found the problem!
I added this line:
setPvpKills(getPvpKills() + 1); + sendPacket(new UserInfo(this));
Any mod please close the topic. Dont delete it, maybe helps someone. :)
Thank you!
Edited by MaDu7zU1 answer to this question
Recommended Posts