Jump to content

Recommended Posts

Posted

Well , It's Been AGES since i shared this thing , and i thought it would be better if i shared the new version to you.

no more talking.

 

Here's The Diff:

Index: java/config/l2jmods.properties
===================================================================
--- java/config/l2jmods.properties	(revision 4307)
+++ java/config/l2jmods.properties	(working copy)
@@ -132,3 +132,20 @@
# ex.: 1;2;3;4;5;6
# no ";" at the start or end
TvTEventDoorsCloseOpenOnStartEnd =
+
+#---------------------#
+#Noblesse Item Configs
+#---------------------#
+NoblesseItemEnabled = False
+
+# ID Of The Noblesse Item
+# Default : 6673 ( Festival Adena )
+NoblesseItemId = 6673
+
+# Noblesse Item Lvl Restriction
+# A Player Lower than 76 level won't be able to use this item
+NoblesseItemLvlRestriction = True
+
+# Noblesse Item Sub Restriction
+# A Player That is not with his subclass won't be able to use this item
+NoblesseItemSubRestriction = True
\ No newline at end of file
Index: java/net/sf/l2j/Config.java
===================================================================
--- java/net/sf/l2j/Config.java	(revision 4307)
+++ java/net/sf/l2j/Config.java	(working copy)
@@ -882,6 +882,11 @@
     public static boolean L2JMOD_WEDDING_FORMALWEAR;
     public static int L2JMOD_WEDDING_DIVORCE_COSTS;

+    public static int NOBLESSE_ITEM_ID;
+    public static boolean NOBLESSE_ITEM_LEVEL_RESTRICTION;
+    public static boolean NOBLESSE_ITEM_SUBCLASS_RESTRICTION;
+    public static boolean NOBLESSE_ITEM_ENABLED;
+    
     // Packet information
     /** Count the amount of packets per minute ? */
     public static boolean  COUNT_PACKETS           = false;
@@ -1858,7 +1863,11 @@
                 L2JMOD_WEDDING_SAMESEX                  = Boolean.parseBoolean(L2JModSettings.getProperty("WeddingAllowSameSex", "False"));
                 L2JMOD_WEDDING_FORMALWEAR               = Boolean.parseBoolean(L2JModSettings.getProperty("WeddingFormalWear", "True"));
                 L2JMOD_WEDDING_DIVORCE_COSTS            = Integer.parseInt(L2JModSettings.getProperty("WeddingDivorceCosts", "20"));
-
+                NOBLESSE_ITEM_ID						= Integer.parseInt(L2JModSettings.getProperty("NoblesseItemId", "6673"));
+                NOBLESSE_ITEM_LEVEL_RESTRICTION			= Boolean.parseBoolean(L2JModSettings.getProperty("NoblesseItemLvlRestriction", "True"));
+                NOBLESSE_ITEM_SUBCLASS_RESTRICTION		= Boolean.parseBoolean(L2JModSettings.getProperty("NoblesseItemSubRestriction", "True"));
+                NOBLESSE_ITEM_ENABLED					= Boolean.parseBoolean(L2JModSettings.getProperty("NoblesseItemEnabled", "False"));
+                
                 if (TVT_EVENT_PARTICIPATION_NPC_ID == 0)
                 {
                     TVT_EVENT_ENABLED = false;
Index: java/net/sf/l2j/gameserver/GameServer.java
===================================================================
--- java/net/sf/l2j/gameserver/GameServer.java	(revision 4307)
+++ java/net/sf/l2j/gameserver/GameServer.java	(working copy)
@@ -136,6 +136,7 @@
import net.sf.l2j.gameserver.handler.itemhandlers.Harvester;
import net.sf.l2j.gameserver.handler.itemhandlers.MercTicket;
import net.sf.l2j.gameserver.handler.itemhandlers.MysteryPotion;
+import net.sf.l2j.gameserver.handler.itemhandlers.NoblesseItem;
import net.sf.l2j.gameserver.handler.itemhandlers.PaganKeys;
import net.sf.l2j.gameserver.handler.itemhandlers.Potions;
import net.sf.l2j.gameserver.handler.itemhandlers.Recipes;
@@ -476,6 +477,10 @@
		_itemHandler.registerItemHandler(new SpecialXMas());
		_itemHandler.registerItemHandler(new SummonItems());
		_itemHandler.registerItemHandler(new BeastSpice());
+		
+		if (Config.NOBLESSE_ITEM_ENABLED)
+		_itemHandler.registerItemHandler(new NoblesseItem());
+		
         _log.config("ItemHandler: Loaded " + _itemHandler.size() + " handlers.");

		_skillHandler = SkillHandler.getInstance();
Index: java/net/sf/l2j/gameserver/handler/itemhandlers/NoblesseItem.java
===================================================================
--- java/net/sf/l2j/gameserver/handler/itemhandlers/NoblesseItem.java	(revision 0)
+++ java/net/sf/l2j/gameserver/handler/itemhandlers/NoblesseItem.java	(revision 0)
@@ -0,0 +1,54 @@
+package net.sf.l2j.gameserver.handler.itemhandlers;
+
+import net.sf.l2j.Config;
+import net.sf.l2j.gameserver.handler.IItemHandler;
+import net.sf.l2j.gameserver.model.L2ItemInstance;
+import net.sf.l2j.gameserver.model.actor.instance.L2PcInstance;
+import net.sf.l2j.gameserver.model.actor.instance.L2PlayableInstance;
+import net.sf.l2j.gameserver.serverpackets.MagicSkillUser;
+
+public class NoblesseItem implements IItemHandler
+{
+    private static final int ITEM_IDS[] = 
+    {
+        Config.NOBLESSE_ITEM_ID
+    };
+    
+    public void useItem(L2PlayableInstance playable, L2ItemInstance item)
+    {
+            if(!(playable instanceof L2PcInstance))
+                return;
+            L2PcInstance activeChar = (L2PcInstance)playable;
+            if(activeChar.isNoble())
+            {
+                activeChar.sendMessage("You Are Already A Noblesse!");
+                return;
+            } 
+            if (activeChar.getLevel() < 76 && Config.NOBLESSE_ITEM_LEVEL_RESTRICTION)
+            {
+            	activeChar.sendMessage("You Must Be Over 76 Level To Use This Item!");
+            	return;
+            }
+            if (!activeChar.isSubClassActive() && Config.NOBLESSE_ITEM_SUBCLASS_RESTRICTION)
+            {
+            	activeChar.sendMessage("You Must Be With Your Subclass To Use This Item!");
+            	return;
+            }
+            else
+            {
+                MagicSkillUser MSU = new MagicSkillUser(playable, activeChar, 2023, 1, 1, 0);
+                activeChar.sendPacket(MSU);
+                activeChar.broadcastPacket(MSU);
+                activeChar.setNoble(true);
+                activeChar.sendMessage("You Are Now a Noble,You Are Granted With Noblesse Status , And Noblesse Skills.");
+                activeChar.broadcastUserInfo();
+                activeChar.getInventory().addItem("Noblesse Tiara",7694, 1, activeChar, playable);
+                playable.destroyItem("Consume", item.getObjectId(), 1, null, false);
+            }
+        }
+
+    public int[] getItemIds()
+    {
+        return ITEM_IDS;
+    }
+}
\ No newline at end of file

 

Enjoy.

Posted

Stefoulis is back ? :o Niceeee

Can i ask?What do you mean new version?What difference this custom item have?

 

 

well , the last version i've shared

hadn't any restrictions about level and active subclass.

eh , this gives you noblesse tiara when u click the item

also , when u clicked appeared the social action that appears when you become a hero. now its just a firework effect.

last one, the other wasnt that configurable. the only config was enable/disable.

now it has configs about the restrictions , the item id and enable/disable.

Posted

well , the last version i've shared

hadn't any restrictions about level and active subclass.

eh , this gives you noblesse tiara when u click the item

also , when u clicked appeared the social action that appears when you become a hero. now its just a firework effect.

last one, the other wasnt that configurable. the only config was enable/disable.

now it has configs about the restrictions , the item id and enable/disable.

too nice.

Thnx for sharing.

Keep up :D

Posted

WOOOOOOW!

I'm soo excited, Stef is BACK!

I hope you make the forum full of shares mate!

Jeus are u that... god..

 

Anyway, nice to have u back stef.

  • 2 weeks later...

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

    • Tell a Škoda 1.4 driver that a Škoda 1.8 is faster — and suddenly, you’re riding a mini race car. On the way, they might share random stories — gas prices, the perfect BBQ recipe, or how passengers once called them “just for a minute.” Maybe even how someone left a suitcase full of money in their car once.     The important part? You’ll get there on time, no delays.     Vibe SMS works just as fast — messages fly like that driver who just heard their 1.8 isn’t the fastest.     🌐 https://vibe-sms.net/ 📲 https://t.me/vibe_sms  
    • ⚔️ The Grand Opening Has Arrived! ⚔️ In just a few hours the gate to the eternal battlefield will be open and the war between Order and Chaos will be set once again ! Its time to claim your destiny 🔥 👉 Register now and join the fight today! 🌐 https://l2ovc.com register now : https://l2ovc.com The gates are open the war between Order and Chaos has officially started! 🔥 Join the battlefield NOW and claim your destiny in Order vs Chaos! 💥 Don’t fall behind your faction needs you. ➡️ https://l2ovc.com  
    • Don’t miss the new Telegram gifts with our Telegram Stars purchasing bot! A great opportunity to invest in a stable digital asset at an early stage while the market is still forming. Buy other existing gifts in the official store using Telegram Stars, pay for subscriptions, donate to games and projects, pay for Premium subscriptions, and react to messages in channels! Low prices, multiple payment options, and other cool unique features! ⚡ Try it today — SOCNET STARS BOT ⚡ Active links to SOCNET stores: Digital Goods Store (Website): Go Store Telegram Bot: Go – convenient access to the store via Telegram messenger. ⭐ Telegram Stars Purchase Bot: Go – fast and profitable way to buy stars in Telegram. SMM Panel: Go – promote your social media accounts. We present to you the current list of promotions and special offers for purchasing our products and services: 1️⃣ Promo code OCTOBER2025 (8% discount) for purchases in our store (Website, bot) in October! You can also use the promo code SOCNET (15% discount) for your first purchase. 2️⃣ Get $1 on your store balance or a 10–20% discount — just write your username after registration on our website using the template: "SEND ME BONUS, MY USERNAME IS..." — post it in our forum thread! 3️⃣ Get $1 for your first SMM Panel trial — simply open a ticket titled “Get Trial Bonus” on our website (Support). 4️⃣ Weekly ⭐ Telegram Stars giveaways in our Telegram channel and in our Telegram Stars bot! News: ➡ Telegram Channel: https://t.me/accsforyou_shop ➡ WhatsApp Channel: https://chat.whatsapp.com/K8rBy500nA73z27PxgaJUw?mode=ems_copy_t ➡ Discord Server: https://discord.gg/y9AStFFsrh Contacts and Support: ➡ Telegram: https://t.me/socnet_support ➡ WhatsApp: https://wa.me/79051904467 ➡ Discord: socnet_support ➡ ✉ Email: solomonbog@socnet.store
    • Don’t miss the new Telegram gifts with our Telegram Stars purchasing bot! A great opportunity to invest in a stable digital asset at an early stage while the market is still forming. Buy other existing gifts in the official store using Telegram Stars, pay for subscriptions, donate to games and projects, pay for Premium subscriptions, and react to messages in channels! Low prices, multiple payment options, and other cool unique features! ⚡ Try it today — SOCNET STARS BOT ⚡ Active links to SOCNET stores: Digital Goods Store (Website): Go Store Telegram Bot: Go – convenient access to the store via Telegram messenger. ⭐ Telegram Stars Purchase Bot: Go – fast and profitable way to buy stars in Telegram. SMM Panel: Go – promote your social media accounts. We present to you the current list of promotions and special offers for purchasing our products and services: 1️⃣ Promo code OCTOBER2025 (8% discount) for purchases in our store (Website, bot) in October! You can also use the promo code SOCNET (15% discount) for your first purchase. 2️⃣ Get $1 on your store balance or a 10–20% discount — just write your username after registration on our website using the template: "SEND ME BONUS, MY USERNAME IS..." — post it in our forum thread! 3️⃣ Get $1 for your first SMM Panel trial — simply open a ticket titled “Get Trial Bonus” on our website (Support). 4️⃣ Weekly ⭐ Telegram Stars giveaways in our Telegram channel and in our Telegram Stars bot! News: ➡ Telegram Channel: https://t.me/accsforyou_shop ➡ WhatsApp Channel: https://chat.whatsapp.com/K8rBy500nA73z27PxgaJUw?mode=ems_copy_t ➡ Discord Server: https://discord.gg/y9AStFFsrh Contacts and Support: ➡ Telegram: https://t.me/socnet_support ➡ WhatsApp: https://wa.me/79051904467 ➡ Discord: socnet_support ➡ ✉ Email: solomonbog@socnet.store
  • Topics

×
×
  • Create New...

AdBlock Extension Detected!

Our website is made possible by displaying online advertisements to our members.

Please disable AdBlock browser extension first, to be able to use our community.

I've Disabled AdBlock