Jump to content
  • 0

[Help] me antibuff


Question

Posted

That's an anti-buss skill, it's toggle and when you enable it, noone except buffers can buff you

 

like L2Mxc and L2DeathAvenue

 

Core Part

Index: java/com/Ovenus/gameserver/handler/skillhandlers/Continuous.java
===================================================================
--- java/com/Ovenus/gameserver/handler/skillhandlers/Continuous.java	(revision 2)
+++ java/com/Ovenus/gameserver/handler/skillhandlers/Continuous.java	(working copy)
@@ -92,6 +92,9 @@
			{
				continue;
			}
+			// With Mystic Immunity you can't be buffed/debuffed
+			if (target.isBuffShieldOn())
+				continue;
			// Player holding a cursed weapon can't be buffed and can't buff
			if (skill.getSkillType() == L2Skill.SkillType.BUFF && !(activeChar instanceof L2ClanHallManagerInstance))
			{
Index: java/com/Ovenus/gameserver/handler/skillhandlers/Disablers.java
===================================================================
--- java/com/Ovenus/gameserver/handler/skillhandlers/Disablers.java	(revision 2)
+++ java/com/Ovenus/gameserver/handler/skillhandlers/Disablers.java	(working copy)
@@ -144,6 +144,8 @@
				// or dead
				continue;
			}
+			if (target.isBuffShieldOn())
+				continue;
			switch (type)
			{
				case BETRAY:
Index: java/com/Ovenus/gameserver/model/L2Character.java
===================================================================
--- java/com/Ovenus/gameserver/model/L2Character.java	(revision 2)
+++ java/com/Ovenus/gameserver/model/L2Character.java	(working copy)
@@ -28,6 +28,7 @@
import javolution.util.FastList;
import javolution.util.FastMap;
import javolution.util.FastTable;
+
import com.Ovenus.Config;
import com.Ovenus.gameserver.GameTimeController;
import com.Ovenus.gameserver.GeoData;
@@ -144,6 +145,7 @@
	// Data Field
	private List<L2Character> _attackByList;
	private volatile boolean _isCastingNow = false;
+	private boolean _buffShield = false;
	// private L2Character _attackingChar;
	private L2Skill _lastSkillCast;
	private boolean _isAfraid = false; // Flee in a random direction
@@ -7576,6 +7578,19 @@
		return _showSummonAnimation;
	}

+	
+	public final void enableBuffShield(boolean value)
+	{
+		_buffShield = value;
+	}
+
+	public boolean isBuffShieldOn()
+	{
+
+		return (_buffShield);
+			
+	}
+	
	/**
	 * @param showSummonAnimation
	 *            The showSummonAnimation to set.
Index: java/com/Ovenus/gameserver/model/L2Effect.java
===================================================================
--- java/com/Ovenus/gameserver/model/L2Effect.java	(revision 2)
+++ java/com/Ovenus/gameserver/model/L2Effect.java	(working copy)
@@ -51,7 +51,7 @@

	public static enum EffectType
	{
-		BUFF, BUFFIMMUNITY, CHARGE, DMG_OVER_TIME, HEAL_OVER_TIME, COMBAT_POINT_HEAL_OVER_TIME, MANA_DMG_OVER_TIME, MANA_HEAL_OVER_TIME, RELAXING, STUN, ROOT, SLEEP, HATE, FAKE_DEATH, CONFUSION, CONFUSE_MOB_ONLY, MUTE, FEAR, ILENT_MOVE, SEED, PARALYZE, STUN_SELF, PSYCHICAL_MUTE, REMOVE_TARGET, TARGET_ME, SILENCE_MAGIC_PHYSICAL, BETRAY, NOBLESSE_BLESSING, SOUL_OF_THE_PHOENIX, SALVATION, PETRIFICATION, BLUFF, INVUL, INTERRUPT, CHARM_OF_LUCK, SIGNET_GROUND, SIGNET_EFFECT, SIGNET, IMMOBILEUNTILATTACKED, DEBUFF, PROTECTION_BLESSING, CHARMOFCOURAGE, SILENT_MOVE, CHANCE_SKILL_TRIGGER
+		BUFF, BUFFIMMUNITY, CHARGE, DMG_OVER_TIME, HEAL_OVER_TIME, COMBAT_POINT_HEAL_OVER_TIME, MANA_DMG_OVER_TIME, MANA_HEAL_OVER_TIME, RELAXING, STUN, ROOT, SLEEP, HATE, FAKE_DEATH, CONFUSION, CONFUSE_MOB_ONLY, MUTE, FEAR, ILENT_MOVE, SEED, PARALYZE, STUN_SELF, PSYCHICAL_MUTE, REMOVE_TARGET, TARGET_ME, SILENCE_MAGIC_PHYSICAL, BETRAY, NOBLESSE_BLESSING, SOUL_OF_THE_PHOENIX, SALVATION, PETRIFICATION, BLUFF, INVUL, INTERRUPT, CHARM_OF_LUCK, SIGNET_GROUND, SIGNET_EFFECT, SIGNET, IMMOBILEUNTILATTACKED, DEBUFF, PROTECTION_BLESSING, CHARMOFCOURAGE, SILENT_MOVE, CHANCE_SKILL_TRIGGER, PREVENT_BUFF
	}

	private static final Func[] _emptyFunctionSet = new Func[0];
Index: java/com/Ovenus/gameserver/skills/effects/EffectAntiBuffShield.java
===================================================================
--- java/com/Ovenus/gameserver/skills/effects/EffectAntiBuffShield.java	(revision 0)
+++ java/com/Ovenus/gameserver/skills/effects/EffectAntiBuffShield.java	(revision 0)
@@ -0,0 +1,71 @@
+package com.Ovenus.gameserver.skills.effects;
+
+import com.Ovenus.gameserver.model.L2Effect;
+import com.Ovenus.gameserver.model.L2Effect.EffectType;
+import com.Ovenus.gameserver.skills.Env;
+
+/**
+ * An effect that prevents player to be buffed. Doesn't work when: <LI>
+ * Self-buffing</LI> <LI>Flagged/Karma</LI> <LI>Duelling</LI>
+ * 
+ * @author Ovenus
+ */
+public final class EffectAntiBuffShield extends L2Effect
+{
+	/**
+	 * @param env
+	 * @param template
+	 */
+	public EffectAntiBuffShield(Env env, EffectTemplate template)
+	{
+		super(env, template);
+	}
+
+	/*
+	 * (non-Javadoc)
+	 * 
+	 * @see com.Ovenus.gameserver.model.L2Effect#getEffectType()
+	 */
+	@Override
+	public EffectType getEffectType()
+	{
+		return EffectType.PREVENT_BUFF;
+	}
+
+	
+	/*
+	 * (non-Javadoc)
+	 * 
+	 * @see com.Ovenus.gameserver.model.L2Effect#onActionTime()
+	 */
+	@Override
+	public boolean onActionTime()
+	{
+		return false;
+	}
+	
+	/*
+	 * (non-Javadoc)
+	 * 
+	 * @see com.Ovenus.gameserver.model.L2Effect#onStart()
+	 */
+	@Override
+	public void onStart()
+	{
+		getEffected().enableBuffShield(true);
+		return;
+	}
+
+	/*
+	 * (non-Javadoc)
+	 * 
+	 * @see com.Ovenus.gameserver.model.L2Effect#onExit()
+	 */
+	@Override
+	public void onExit()
+	{
+		getEffected().enableBuffShield(false);
+	}
+
+
+}

 

 

DB Part

 

    
<skill id="Your Skill Here" levels="1" name="AntiBuff Shield">
    <set name="mpConsume" val="0"/>
    <set name="target" val="TARGET_SELF"/>
    <set name="reuseDelay" val="0"/>
    <set name="hitTime" val="-1"/>
    <set name="skillType" val="CONT"/>
    <set name="operateType" val="OP_TOGGLE"/>
    <set name="castRange" val="-1"/>
    <set name="effectRange" val="-1"/>
    <for>
      <effect count="1" name="AntiBuffShield" time="600000" val="0"/>
    </for>
  </skill>

Core Part

 

 

credits me..

 

paidia mporei na m pei kapoios p ta vazo ayta dld se poio arxeio kai etc gt den eksigei....

 

Thnx

7 answers to this question

Recommended Posts

  • 0
Posted

file edo les pos na to kanoume meso eclipse xoris eclipse den ginete??

 

Όχι μόνο με το eclipse μπορείς να τα περάσεις..

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Answer this question...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Posts

    • We are excited to announce the open beta testing of the Fulgrim x4 server, starting November 29th, 2024, at 19:00 server time (19:00 по МСК). There will be an NPC available on the test server from whom you can purchase items, gain levels, professions, and other services.   More information at our >Forum
    • Server mid rate craft PvP   CLIENTE INTERLUDE Website server Discord olympus x25 &nbsp;server 🇧🇷🇦🇷🇨🇱🇬🇷🇲🇽🇵🇪🇸🇰🇪🇸🇺🇾 Server mid rate craft PvP 🔱CLIENTE INTERLUDE🔱 🔅xpx25 🔅Sp x25 🔅Adena x15 🔅Droop x2 🔅Spoil x2 🔅Raidboss xp x2 🔅Raidboss sp x2 🔅Raidboss droop x1 🔅All Rate quest reward  x1 ⚠️All Quest drop reward. x1 🔅Manor x 3 🔅Seal stone x1 🛡️🗡️INFO GRADO S🗡️🛡️ ⚠️Inicia desabilitado drop/spoil/quest. 🔱PROFESIONES/SUBCLASS🔱 🛡️1st profession - 50medal 🛡️2nd profession - 500 medal 🛡️3rd profession - 1k medal +30kk adena 🛡️Sub class - Quest. No necesita matar raids. ⚙️Configuraciones⚙️ 🛡️Gmshop  grade - B. 🛡️Grade A-S Craft - yes x1 chance 🛡️Globlal teleport - yes 🛡️Buffer 1hora. 🛡️Buffer slot 24(+4divine)+12 dances-song 🛡️Auto learn skils - yes 🛡️Autoloot - yes 🛡️Mana potion recarga 1000 ,9segundos delay. 🛡️Champions system:     ▫️lvl 30 - 76     ▫️chance respawn 0.5%.     ▫️adena x20 🛡️Max lvl party 14 lvl. 🛡️Festive sweeper on. 🛡️Max client pc 2. 🛡️Raid boss respawn retail. 🛡️Nobleza quest - yes. 🛡️Barakiel respawn 6 horas + -30 min. 🛡️Olimpiada duracion 14 dias. 🛡️Olimpiada de 18:00 a 00:00 🛡️Safe enchant +3 🛡️Normal enchant scroll 50% ⚠️+11-16 chance 30% 🛡️Bleesed enchant scroll 55% ⚠️+11-16 chance 35% 🛡️Rate dinamico x1 lvl 77-80   🛡️🗡️CLANES INFO🗡️🛡️ 🔅Crear clan min. level 20 🔅Max Alianzas 1 🔅Duracion penalidades clan / alianzas 8 horas. 🔅Cambio de lider 24 horas. 🛡️⚔️ ASEDIOS ⚔️🛡️ 🔅Cada 2 semanas. 🔅Proteccion hwid 1 pc. 🔅Clanes registrados. acceden a zona de asedio. 🔅Castillo asediable Aden. 🔅Reward 1000 FA 🔅Horario 16:00 GMT-3 🎊PACK DE INICIO🎊 🔅Start set - armor\weapon no grade. 🔅Level 20  - 5 shadow cuppon grado D 🔅Level 40 - 5 shadow cuppon grado C 🔅Free Autofarm 24 horas. 💰 INFO PREMIUM 💰 🔅Free autofarm. 🔅xp x30 🔅sp x30 🔅adena x17 🔅drop x4 🔅spoil x4 🔅enchant +2% 🔅seal stone x1 🔅Altb Gk-Gmshop/buffe ⚔️ RAID  BOSS INFO ⚔️ 🔅Raid boss 70 ++ respawn 5 días despues. 🔅Raid boss 75 ++ respawn 15 días despues 🔅Drop LETTER L2DAY para tradear en GMshop. ⚔️ INFO SEVEN SING ⚔️ 🔅Inicio del drop Seal stones dia 5 de iniciado el server. 🎊 EPIC RAID INFO 🎊 🔅Queen Ant (lvl 40)respawn Lunes a Viernes 22:00 GMT-3 drop chance 30%. 🔅Core (lvl 80)respawn Martes-miercoles 20:20 GMT-3 drop chance 100%. 🔅Orfen (lvl 80)respawn Martes-miercoles 21:00 GMT-3 drop chance 100%. 🔅Zaken (lvl 80)respawn Jueves 23:00 GMT-3 drop chance 100%. 🔅Frintezza (lvl 80)respawn Viernes 23:00 GMT-3 drop chance 100%. 🔅Baium (lvl 80)respawn Sabado 22:00 GMT-3 drop chance 100%. 🔅Valakas (lvl 80)respawn Domingo 20:00 GMT-3 drop chance 100%. 🔅Antharas (lvl 80)respawn Domingo 22:00 GMT-3 drop chance 100%.
  • Topics

×
×
  • Create New...