Jump to content

Recommended Posts

Posted

Well i saw that there is no stuff like this on the forum.

I know that's one of the easiest things to do with Announcements, but as it is required on the forum i'm posting it to stand here for those who need it.

 

That's a patch to autoannounce when a player kills another. Probably this is much more useful on a PvP or High-rated Servers.

 

Options allowed on pvp.properties:

AnnounceAllKills [true|false] : Every time that a player kills another player an announcement will appear. Doesn't matter if it is a Pk kill or a PvP kill.

(Announcement: Player A killed Player B)

 

AnnouncePvPKills [true|false]: Every time that a player win in a PvP fight an announcement will appear.

(Announcement: Player A hunted Player B)

 

AnnouncePkKills [true|false]: Every time that a player kill another and becomes a Pk (or increases its pk points) an announcement will appear.

(Announcement: Player A has assassinated Player B )

 

* Note that you can enable AnnouncePvPKills and AnnouncePkKills at the same time, but if AnnounceAllKills is enabled, AnnouncePvPKills and AnnouncePkKills will get disabled automatically.

 

* Note that AwardPKKillPVPPoint affects to the announcement (PvP). If the AwardPKKillPVPPoint option is disabled, when a good character kills a chaotic character the announcement won't appear.

 

* Feel free to change the messages as you want.

 

 

Index: C:/Documents and Settings/YO/workspace/L2_GameServer_It/java/config/pvp.properties

===================================================================

--- C:/Documents and Settings/YO/workspace/L2_GameServer_It/java/config/pvp.properties (revision 1156)

+++ C:/Documents and Settings/YO/workspace/L2_GameServer_It/java/config/pvp.properties (working copy)

@@ -29,3 +29,11 @@

PvPVsNormalTime = 40000

# Length one stays in PvP mode after hitting a purple player (in ms)

PvPVsPvPTime = 20000

+

+# Announces when a Player PK another Player. Default - false

+AnnouncePkKill = false

+# Announces when a Player Pvp another Player. Default - false

+AnnouncePvPKill = false

+# Announces when a Player kill another Player. Default - false

+# NOTE: If AnnounceKill is enabled, AnnouncePk and AnnouncePvP will be disabled.  

+AnnounceAllKill = false

Index: C:/Documents and Settings/YO/workspace/L2_GameServer_It/java/net/sf/l2j/Config.java

===================================================================

--- C:/Documents and Settings/YO/workspace/L2_GameServer_It/java/net/sf/l2j/Config.java (revision 1156)

+++ C:/Documents and Settings/YO/workspace/L2_GameServer_It/java/net/sf/l2j/Config.java (working copy)

@@ -777,7 +777,13 @@

    /** Duration (in ms) while a player stay in PVP mode after hitting an innocent */

    public static int PVP_NORMAL_TIME;    

    /** Duration (in ms) while a player stay in PVP mode after hitting a purple player */

-    public static int PVP_PVP_TIME;    

+    public static int PVP_PVP_TIME;

+    /** Announce PvP */

+    public static boolean ANNOUNCE_PVP_KILL;

+    /** Announce PK */

+    public static boolean ANNOUNCE_PK_KILL;

+    /** Announce Kill */

+    public static boolean ANNOUNCE_ALL_KILL;

 

    // Karma Punishment

    /** Allow player with karma to be killed in peace zone ? */

@@ -1926,6 +1932,18 @@

 

                PVP_NORMAL_TIME = Integer.parseInt(pvpSettings.getProperty("PvPVsNormalTime", "15000"));

                PVP_PVP_TIME = Integer.parseInt(pvpSettings.getProperty("PvPVsPvPTime", "30000"));

+                ANNOUNCE_ALL_KILL = Boolean.parseBoolean(pvpSettings.getProperty("AnnounceAllKill", "False")); // Get the AnnounceAllKill, AnnouncePvpKill and AnnouncePkKill values

+                if ( !ANNOUNCE_ALL_KILL )

+                {

+                 ANNOUNCE_PVP_KILL = Boolean.parseBoolean(pvpSettings.getProperty("AnnouncePvPKill", "False"));

+                 ANNOUNCE_PK_KILL = Boolean.parseBoolean(pvpSettings.getProperty("AnnouncePkKill", "False"));

+                }

+                else

+                {

+                 ANNOUNCE_PVP_KILL = false;

+                 ANNOUNCE_PK_KILL = false;

+                }

+                

            }

            catch (Exception e)

            {

@@ -2323,6 +2341,9 @@

 

        else if (pName.equalsIgnoreCase("PvPVsNormalTime")) PVP_NORMAL_TIME = Integer.parseInt(pValue);

        else if (pName.equalsIgnoreCase("PvPVsPvPTime")) PVP_PVP_TIME = Integer.parseInt(pValue);

+        else if (pName.equalsIgnoreCase("AnnouncePvPKill") && !ANNOUNCE_ALL_KILL ) ANNOUNCE_PVP_KILL = Boolean.valueOf(pValue); // Set announce Pvp value

+        else if (pName.equalsIgnoreCase("AnnouncePkKill") && !ANNOUNCE_ALL_KILL ) ANNOUNCE_PK_KILL = Boolean.valueOf(pValue); // Set announce Pk value

+        else if (pName.equalsIgnoreCase("AnnounceAllKill") && !ANNOUNCE_PVP_KILL && !ANNOUNCE_PK_KILL ) ANNOUNCE_ALL_KILL = Boolean.valueOf(pValue); // Set announce kill value

        else if (pName.equalsIgnoreCase("GlobalChat")) DEFAULT_GLOBAL_CHAT = pValue;

        else if (pName.equalsIgnoreCase("TradeChat"))  DEFAULT_TRADE_CHAT = pValue;

        else if (pName.equalsIgnoreCase("MenuStyle"))  GM_ADMIN_MENU_STYLE = pValue;

Index: C:/Documents and Settings/YO/workspace/L2_GameServer_It/java/net/sf/l2j/gameserver/model/actor/instance/L2PcInstance.java

===================================================================

--- C:/Documents and Settings/YO/workspace/L2_GameServer_It/java/net/sf/l2j/gameserver/model/actor/instance/L2PcInstance.java (revision 1156)

+++ C:/Documents and Settings/YO/workspace/L2_GameServer_It/java/net/sf/l2j/gameserver/model/actor/instance/L2PcInstance.java (working copy)

@@ -35,6 +35,7 @@

import javolution.util.FastMap;

import net.sf.l2j.Config;

import net.sf.l2j.L2DatabaseFactory;

+import net.sf.l2j.gameserver.Announcements;

import net.sf.l2j.gameserver.GameTimeController;

import net.sf.l2j.gameserver.GeoData;

import net.sf.l2j.gameserver.GmListTable;

@@ -4446,6 +4447,9 @@

)

{

            increasePvpKills();

+            if ( target instanceof L2PcInstance && Config.ANNOUNCE_PVP_KILL ) // Announces a PvP kill

+             Announcements.getInstance().announceToAll("Player "+this.getName()+" hunted Player "+target.getName());

+            return;

}

else                                                                        // Target player doesn't have pvp flag set

{

@@ -4458,6 +4462,10 @@

                    {

                        // 'Both way war' -> 'PvP Kill'

                        increasePvpKills();

+                        if ( target instanceof L2PcInstance && Config.ANNOUNCE_PVP_KILL ) // Announces a PvP kill

+                         Announcements.getInstance().announceToAll("Player "+this.getName()+" hunted Player "+target.getName());

+                        else if ( target instanceof L2PcInstance && Config.ANNOUNCE_ALL_KILL ) // Announces a kill

+                         Announcements.getInstance().announceToAll("Player "+this.getName()+" killed Player "+target.getName());

                        return;

                    }

                }

@@ -4469,13 +4477,19 @@

if ( Config.KARMA_AWARD_PK_KILL )

{

                    increasePvpKills();

+                    if ( target instanceof L2PcInstance && Config.ANNOUNCE_PVP_KILL ) // Announces a PvP kill

+                     Announcements.getInstance().announceToAll("Player "+this.getName()+" hunted Player "+target.getName());

}

}

else if (targetPlayer.getPvpFlag() == 0)                                                                    // Target player doesn't have karma

{

                increasePkKillsAndKarma(targetPlayer.getLevel());

+                if ( target instanceof L2PcInstance && Config.ANNOUNCE_PK_KILL ) // Announces a Pk kill

+                 Announcements.getInstance().announceToAll("Player "+this.getName()+" has assassinated Player "+target.getName());

}

}

+ if ( target instanceof L2PcInstance && Config.ANNOUNCE_ALL_KILL ) // Announces a kill

+ Announcements.getInstance().announceToAll("Player "+this.getName()+" killed Player "+target.getName());

}

 

    /**

credits:l2jforum i dont remember name

this works on l2j

enjoy ;)

 

 

Posted

Very Nice Share.. But I have saw it in Any Pack anymore... So .... Anyway Gratz for your Work!

 

i dont know what are u talking about but this isnt at packs,this is to announce names when someone kill somebody

Posted

i dont know what are u talking about but this isnt at packs,this is to announce names when someone kill somebody

 

you are the creator of this code?

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

    • ARC RAIDERS - 29/03/2026 Fixed dlc stop work, or crash when join maps or at end of the party Fixed color picker Fixed WeaponRack/WeaponCase Added Supply Station with status Added Stack Loot with radius in m Added option in loot filter for display line direction to selected items, with dynamic distance color
    • Any updated links for this content? 
    • Opening April 25 at 19:00 (UTC +3) Open Beta Test from April 21 This is pre-announcing of NEW season server, so we want to share some key points of it. Full details with road map, patch notes we will announce a bit latter If this is your first time on Dex and you haven’t played on our seasonal servers before, the information below will help you understand what our project is about and its key features. Dex veterans can skip the following section and go straight to the “What’s New in the New Season” part. Why Choose Dex? Best Balance on Interlude+ - we offer the most polished balance among all modified Interlude servers(It may not be perfect yet, but we are committed to continuous improvements and refinements. ). Our build is 100% unique, developed on retail PTS files, and refined over 6+ years. This is not a copy–paste pack – it’s our own work, shaped by players feedback and suggestions for more than 6 years. Proven Stability & Long-Term Life - Our Union x25 server has been running since April 2020 – 6 years of stability and still active with strong online! This makes Dex the only server with real players (not phantoms) with such a setup and longevity. Always Fresh, Always Engaging - Every Seasonal server comes with a clear roadmap of changes and updates. At the end of the season, the server merges with Union, so your effort is never wasted. New players can start fresh together with everyone else on the new season. Before the merge, we run exclusive boosted events for about a month, giving seasonal players a massive head start. (Union players don’t get these events) Endless Endgame Content - High-end activities, unique PvP events, and continuous new features will keep you engaged long-term. We’re always working to improve and deliver fresh, fun content for our community. All your progress, items, and characters are safe - when the season ends, you continue on Union. Main features Modern Classic client (less lags, smoother gameplay, a lot of useful interface features). Anti-bot protection - we use our own system in combine with popular solutions like AAC, so in the end our project have one of the best anti-bot shield exists. Buff book to buff yourself or your summon/pet. With regular buff book you can create only 1 buff profile, if you need more - get the modern buff book and create up to 10 profiles! 36 buff slots - 24 regular buffs, and addictiona 12 slots for Dance/Song Daily rewards - login to the game every day and get rewards. Expanded subclass slots - you can have 5 subclasses from the beginning and expand up to 10. Class/Gender change - you can change your main class and gender if you want. Masterwork items (can be obtained by crafting or farming RBs, have better bonuses than regular items). Item Broker Auctions in towns can sell some epic jewelry and other useful goods for adena (3 times per week). Giran Harbor Fair - daily event which allows you to get rare items for adena. Talents - special tree with passive skills which will help you to tune your class better. Events like TvT and new event WarHunt Epic Replica system. Episodes - we open new content step by step to keep you engaged, bring more fun and extend the game. Episodes reveal following features: Progressive grade unlocks: B-grade is max available at launch → then A-grade opens → later S-grade. Reworked locations: Mithril Mines and Plunderouse Plains Hellbound Island Isle of Preyer, with new content, new Dynasty gear PvP item improvement allows you to improve your items with additional bonuses. Charms can be equipped in one of the special slots that open when wearing a bracelet. Each type of charm grants the wearer certain bonuses New Epic Bosses - Freya, Beleth, Tiat, Trasken Cyclic macros (macros restarts when finishes) What’s New in the Upcoming Season? Below is a brief overview of the main changes coming in the new season, along with short explanations. More detailed information about each feature will be published later, most likely in our wiki. Divisions We plan to test a Division system on Dex, initially only for low-tier epic bosses (AQ, Core, Orfen, Zaken). At the same time as the main Epic Boss respawn, an additional instance version of the boss will appear. Clans from the big war will not be able to enter this instance. The drop table is identical to the main boss, but the Epic Jewelry have not a 100% drop chance. Mithril Mines /data/attachments/4/4662-e7b9c5989ccf81d0b2d48e88b7aa9bc7.jpg A reworked location that will open on the first Monday after S-grade becomes available. In this zone you will be able to: Obtain alternative recipes for S-grade equipment Get your first Charms and upgrade them up to Level 3 Obtain bracelets with 2 Charm slots Farm Void Neolithics (used for upgrade any item to Masterwork, but lose enchant level) 2 New Raid Bosses with valuable drop Fight the Raid Boss Trasken Plunderous Plains /data/attachments/4/4661-2ecd2d0a4702d31c1ba26d4b7e369285.jpg Another reworked location, which will open one week after Mithril Mines. This zone provides: GCM drops LS drop More different Charms 2 New Raid Bosses with valuable drop 3-slot Charm bracelet The ability to make PvP versions of equipment Isle of Prayer A location where players will be able to obtain a new type of equipment - Dynasty. This area will also provide: More different Charms 4-slot Charm bracelet Upgrade charms to level 4 Hellbound Hellbound is now an endgame location. Almost everything can be farmed there, and the drop quality is very high. However, the location will only be available during weeks without Olympiad battles. This means it will be open for one week and closed for the next. This area will also provide: 5-6 slot Charm bracelet bracelet engravement ancient scrolls Best drop GCM Best drop LS More different charms Upgrade charms to level 5 Talents An additional talent tree has been added: the PvE branch. The PvE talent tree has its own limits and does not overlap with the standard tree. Olympiad The Olympiad will now run 5 days per week, from Wednesday to Sunday. Each day you will have a limit on the number of battles you can participate in. War Hunt Event A new event. Players who previously played on Skadi may already be familiar with it. The idea is simple: You enter a PvP zone Killing monsters grants points These points can be exchanged for rewards Killing other players allows you to steal their points PvE / PvP Layers The locations Mithril Mines, Plunderous Plains, IOP and Hellbound will have two separate layers. The drop on both versions are identical. Open World Version: Full PvP zone Instance Version: No PvP zone, works like the regular world with standard war/flag/PK rules Players who enjoy PvP can defend their farming spots and gain extra advantage, while players who prefer a safer farming experience can use the instance version, though with more competition and higher population. As you can see, this season brings quite a lot of changes However, these are mostly content-related additions - the core spirit and classic gameplay of the season remain unchanged. Please note that this is a pre-announcement, and some details may still change before the Beta Test begins. A full roadmap and patch notes will be published later. https://forum.lineage2dex.com/threads/16738/#lg=post-72311&slide=0  
    • Automatic Streamer Rewards System (Twitch / Kick / TikTok) Hey everyone, I’ve developed a Streamer Rewards system for Lineage 2 servers that automatically rewards players who stream the server. The system works fully automatic: Detects if the streamer is currently live Checks if the stream title contains the server name If everything matches, the system sends a custom reward coin to the streamer’s character Rewards are given every 30 minutes while streaming Supported platforms Twitch Kick TikTok Live Configurable options Reward Item ID Reward interval time Server name keyword detection Character name linked to the streamer This makes it easy to encourage players to promote the server without manual work from admins. Example flow: Player goes live on Twitch/Kick/TikTok Stream title includes the server name System detects the stream automatically Every 30 minutes the player receives a reward coin in-game Setup I can also help set up and integrate the system with your server. Works with custom coin rewards Can be configured for different intervals Additional help with installation and configuration available If you're interested or want more details, feel free to send me a PM. I also have a ticket ping system, if new ticket created on the website you can make it send you a ping on discord server for selected roles (support and stuff) but this one is basic and most likely not needed, my discord: zujarka
  • 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..