Jump to content

Question

Posted (edited)

i have add this code

### Eclipse Workspace Patch 1.0
#P aCis_gameserver
Index: java/net/sf/l2j/gameserver/model/actor/L2Character.java
===================================================================
--- java/net/sf/l2j/gameserver/model/actor/L2Character.java    (revision 16)
+++ java/net/sf/l2j/gameserver/model/actor/L2Character.java    (working copy)
@@ -136,6 +136,17 @@
*/
public abstract class L2Character extends L2Object
{
+    private boolean _isBuffProtected = false; //Protect From Debuffs
+    public final void setIsBuffProtected(boolean value)
+     {
+     _isBuffProtected = value;
+     }
+     
+     public boolean isBuffProtected()
+     {
+     return _isBuffProtected; 
+     }
+
    public static final Logger _log = Logger.getLogger(L2Character.class.getName());
    
    private Set<L2Character> _attackByList;
Index: java/net/sf/l2j/gameserver/handler/skillhandlers/Continuous.java
===================================================================
--- java/net/sf/l2j/gameserver/handler/skillhandlers/Continuous.java    (revision 16)
+++ java/net/sf/l2j/gameserver/handler/skillhandlers/Continuous.java    (working copy)
@@ -89,6 +89,15 @@
                    if (target.getFirstEffect(L2EffectType.BLOCK_BUFF) != null)
                        continue;
                    
+                    // Anti-Buff Protection prevents you from getting buffs by other players 
+                    if (activeChar instanceof L2PcInstance && target != activeChar && target.isBuffProtected() && !skill.isHeroSkill()
+                    && (skill.getSkillType() == L2SkillType.BUFF                        
+                    || skill.getSkillType() == L2SkillType.HEAL_PERCENT
+                    || skill.getSkillType() == L2SkillType.MANAHEAL_PERCENT
+                    || skill.getSkillType() == L2SkillType.COMBATPOINTHEAL
+                    || skill.getSkillType() == L2SkillType.REFLECT))
+                    continue;
+                                        
                    // Player holding a cursed weapon can't be buffed and can't buff
                    if (!(activeChar instanceof L2ClanHallManagerInstance) && target != activeChar)
                    {
Index: java/net/sf/l2j/gameserver/skills/effects/EffectDeflectBuff.java
===================================================================
--- java/net/sf/l2j/gameserver/skills/effects/EffectDeflectBuff.java    (revision 0)
+++ java/net/sf/l2j/gameserver/skills/effects/EffectDeflectBuff.java    (revision 0)
@@ -0,0 +1,82 @@
+package net.sf.l2j.gameserver.skills.effects;
+
+import net.sf.l2j.gameserver.model.L2Effect;
+import net.sf.l2j.gameserver.templates.skills.L2EffectType;
+import net.sf.l2j.gameserver.templates.skills.L2SkillType;
+import net.sf.l2j.gameserver.network.SystemMessageId;
+import net.sf.l2j.gameserver.network.serverpackets.SystemMessage;
+import net.sf.l2j.gameserver.skills.Env;
+
+/**
+* @author Java
+*/
+public final class EffectDeflectBuff extends L2Effect
+{
+ /**
+ * @param env
+ * @param template
+ */
+ public EffectDeflectBuff(Env env, EffectTemplate template)
+ {
+ super(env, template);
+ }
+
+ /*
+ * (non-Javadoc)
+ *
+ * @see net.sf.l2j.gameserver.model.L2Effect#getEffectType()
+ */
+ @Override
+ public L2EffectType getEffectType()
+ {
+     return L2EffectType.PREVENT_BUFF;
+ }
+ 
+ /*
+ * (non-Javadoc)
+ *
+ * @see net.sf.l2j.gameserver.model.L2Effect#onActionTime()
+ */
+ @Override
+ public boolean onActionTime()
+ {
+ // Only cont skills shouldn't end
+ if(getSkill().getSkillType() != L2SkillType.CONT)
+ return false;
+
+ double manaDam = calc();
+
+ if(manaDam > getEffected().getCurrentMp())
+ {
+     SystemMessage sm = new SystemMessage(SystemMessageId.SKILL_REMOVED_DUE_LACK_MP);
+ getEffected().sendPacket(sm);
+ return false;
+ }
+
+ getEffected().reduceCurrentMp(manaDam);
+ return true;
+ }
+ 
+ /*
+ * (non-Javadoc)
+ *
+ * @see net.sf.l2j.gameserver.model.L2Effect#onStart()
+ */
+ @Override
+ public boolean onStart()
+ {
+     getEffected().setIsBuffProtected(true);
+     return true;
+ }
+
+ /*
+ * (non-Javadoc)
+ *
+ * @see net.sf.l2j.gameserver.model.L2Effect#onExit()
+ */
+ @Override
+ public void onExit()
+ {
+     getEffected().setIsBuffProtected(false);
+ }
+}
\ No newline at end of file
Index: java/net/sf/l2j/gameserver/network/serverpackets/SystemMessage.java
===================================================================
--- java/net/sf/l2j/gameserver/network/serverpackets/SystemMessage.java    (revision 16)
+++ java/net/sf/l2j/gameserver/network/serverpackets/SystemMessage.java    (working copy)
@@ -110,7 +110,7 @@
    private SMParam[] _params;
    private int _paramIndex;
    
-    private SystemMessage(final SystemMessageId smId)
+    public SystemMessage(final SystemMessageId smId)
    {
        final int paramCount = smId.getParamCount();
        _smId = smId;
Index: java/net/sf/l2j/gameserver/templates/skills/L2EffectType.java
===================================================================
--- java/net/sf/l2j/gameserver/templates/skills/L2EffectType.java    (revision 16)
+++ java/net/sf/l2j/gameserver/templates/skills/L2EffectType.java    (working copy)
@@ -80,5 +80,6 @@
    WARP,
    
    SIGNET_GROUND,
-    SIGNET_EFFECT
+    SIGNET_EFFECT,
+    PREVENT_BUFF
}
\ No newline at end of file
#P aCis_datapack
Index: data/xml/skills/0100-0199.xml
===================================================================
--- data/xml/skills/0100-0199.xml    (revision 11)
+++ data/xml/skills/0100-0199.xml    (working copy)
@@ -949,10 +949,14 @@
            <add order="0x40" stat="cAtkAdd" val="#crit"/>
        </for>
    </skill>
-    <skill id="194" levels="1" name="Lucky">
+    <skill id="194" levels="1" name="Anti-Buff">
+     <!-- Blocks unwanted buffs. -->
        <set name="target" val="TARGET_SELF"/>
-        <set name="skillType" val="LUCK"/>
-        <set name="operateType" val="OP_PASSIVE"/>
+        <set name="skillType" val="CONT"/>
+        <set name="operateType" val="OP_TOGGLE"/>
+        <for>
+            <effect count="0x7fffffff" name="DeflectBuff" time="3" val="0"/>
+        </for>
    </skill>
    <skill id="195" levels="2" name="Boost Breath">
        <table name="#breath"> 180 300 </table>

i have delete the skill LUCKY with the same ID i have set AutoLearnSkills=True and i have this error

 

storeSkill() couldn't store new skill. It's null type.
 

and one problem dont working the oly rank's i use acis 300revision

Edited by Ta®oS™

1 answer to this question

Recommended Posts

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now


  • Posts

    • <dailyReward days="28" autoOpen="true" minimumOnlineTimeSeconds="30" oneRewardPerIP="true" resetIfMissDay="true">   For now, I have these settings in the XML—this is the V1 version I created, though I plan to make further improvements over time. Of course, I’ll also add more protections—MAC, HWID, and perhaps others like account-based restrictions—to make it more secure. We can also implement non-tradable items to further enhance the system's security. I’ll keep posting updates and refining both the system and the interface. I might make a video tomorrow; if you look at the top, you'll see the "auto-open" feature can be toggled on or off, allowing users to rely solely on the `.daily` command. Cheers! Note: If I sell it in this state, I’ll provide support and roll out updates to users. I’m not forcing anyone to buy anything; I’d even provide the patch files so that anyone with the necessary skills can add features, modify it, or improve it further.
    • If the problem is that the target is lost, the action of aiming at another character, upon losing collision, does not allow aiming.   This one works as it should, allowing you to target characters
    • MICROTEXT AND WATERMARKS BREAK MOST RENDERINGS Microtext and watermarks aren’t just small decorative details. They are one of the most common reasons a document fails verification, even when it looks decent at first glance. The issue is that these elements are almost impossible to reproduce “by eye.” Microtext requires precise geometry and legibility at a very small size, while a watermark needs the correct density, transparency, and accurate placement relative to other security features. Any deviation becomes obvious during detailed inspection. ▪ What’s most often done wrong: - microtext is drawn too thick or blurry - the watermark is made either too visible or almost invisible - the positioning between microtext and watermark is ignored - the original printing technology isn’t taken into account when choosing density and shape - The stronger the document’s security features, the less room there is for approximation. What matters here isn’t visual similarity, but accurate reproduction of the original technical characteristics. If your document contains microtext and watermarks, this is always an area that requires extra attention. Write to us in DMs. We’ll review your case and point out exactly which details need the highest precision during rendering. › TG: @mustang_service_ms ( https:// t.me/ mustang_service_ms ) › Channel: Mustang Service ( https:// t.me/ +JPpJCETg-xM1NjNl ) #drawing #microtext #photoshop #editing #watermarks
    • GoldRush launches tomorrow! July 18 16:00 GMT+3 Europe / International Register your account in the website, connect wallet and be ready to dominate!
  • Topics

×
×
  • Create New...

Important Information

This community uses essential cookies to function properly. Non-essential cookies and third-party services are used only with your consent. Read our Privacy Policy and We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue..