Fala pessoal tudo bem?
O mod na realidade é apenas uma pequena alteração no arquivo:
com.l2jfrozen.gameserver.handler.skillhandlers.Heal.java
A ideia é diminuir a porcentagem do Heal que é dado a players que estejam PK e/ou Flag.
O intuito é nerfar os Bishops nas tretas, mas sem interferir em Sieges ou nos Boss
Sei que vai ter muita gente contra, mas lembrem-se, adiciona este MOD quem quer.
Vamos la.
Abre o arquivo citado acima e procure por:
if (skill.getSkillType() == SkillType.HEAL_PERCENT)
{
hp = target.getMaxHp() * hp / 100.0;
}
else
{
if (bss)
{
hp *= 1.5;
}
else if (sps)
{
hp *= 1.3;
}
}
entao no final, antes do ULTIMO "}" adicione esta linha:
if (player != null && player.getPvpFlag() != 0 || player != null && player.getKarma() != 0)
{
if ( (player != null && player.getSiegeState() > 0 && player.isInsideZone(L2Character.ZONE_SIEGE)) || (player != null && player.isInsideZone(L2Character.ZONE_BOSS)) || (player != null && player.isInsideZone(L2Character.ZONE_FLAG)))
{}else{
hp *= 0.5;
}
}
ficando assim:
Spoiler
if (skill.getSkillType() == SkillType.HEAL_PERCENT)
{
hp = target.getMaxHp() * hp / 100.0;
}
else
{
if (bss)
{
hp *= 1.5;
}
else if (sps)
{
hp *= 1.3;
}
if (player != null && player.getPvpFlag() != 0 || player != null && player.getKarma() != 0)
{
if ( (player != null && player.getSiegeState() > 0 && player.isInsideZone(L2Character.ZONE_SIEGE)) || (player != null && player.isInsideZone(L2Character.ZONE_BOSS)) || (player != null && player.isInsideZone(L2Character.ZONE_FLAG)))
{}else{
hp *= 0.5;
}
}
}
### Eclipse Workspace Patch 1.0
#P L2jFrozen_GameServer
Index: head-src/com/l2jfrozen/gameserver/model/L2Character.java
===================================================================
--- head-src/com/l2jfrozen/gameserver/model/L2Character.java (revision 8)
+++ head-src/com/l2jfrozen/gameserver/model/L2Character.java (working copy)
@@ -356,6 +356,9 @@
/** The Constant ZONE_NOSTORE. */
public static final int ZONE_NOSTORE = 32768;
+ /** The Constant ZONE_BOSS. */
+ public static final int ZONE_BOSS = 65536;
+
+ /** The Constant ZONE_FLAG. */
+ public static final int ZONE_FLAG = 130000;
+
/** The _current zones. */
private int _currentZones = 0;
Index: head-src/com/l2jfrozen/gameserver/model/zone/type/L2BossZone.java
===================================================================
--- head-src/com/l2jfrozen/gameserver/model/zone/type/L2BossZone.java (revision 8)
+++ head-src/com/l2jfrozen/gameserver/model/zone/type/L2BossZone.java (working copy)
@@ -103,6 +103,9 @@
*/
protected void onEnter(final L2Character character)
{
+ if (character instanceof L2PcInstance)
+ character.setInsideZone(L2Character.ZONE_BOSS, true);
+
if (_enabled)
{
if (character instanceof L2PcInstance)
@@ -196,6 +199,9 @@
@Override
protected void onExit(final L2Character character)
{
+ if (character instanceof L2PcInstance)
+ character.setInsideZone(L2Character.ZONE_BOSS, false);
+
if (_enabled)
{
if (character instanceof L2PcInstance)
========================================================
com.l2jfrozen.gameserver.model.zone.type.L2FlagZone
@Override
protected void onEnter(L2Character character) {
+ if (character instanceof L2PcInstance)
+ character.setInsideZone(L2Character.ZONE_FLAG, true);
if (character instanceof L2PcInstance) {
@Override
protected void onExit(L2Character character) {
+ if (character instanceof L2PcInstance)
+ character.setInsideZone(L2Character.ZONE_FLAG, false);
if (character instanceof L2PcInstance) {
Prints do Mod:
Quero agradecer aos
Paulinho Souza* João. VitorB.
PeNaChO
que me ajudaram a localizar o caminho e a como "Reconhecer um Flag/Pk".
Agradecer ao Penacho por me ajudar a adicionar novas proteções as ZONAS
P.S.: Para aqueles que nao tiverem o Mod L2FlagZone (ZONE_FLAG) ignorem a ultima parte e excluam do codigo do Heal.java apenas esta parte:
|| (player != null && player.isInsideZone(L2Character.ZONE_FLAG))