Jump to content

[Share]Transform All Clan Members


Recommended Posts

Hello. As usual I share nothing amazing. This patch allows you to transform all clan members(if clan has aden castle) to npc.

 

Index: java/net/sf/l2j/gameserver/network/clientpackets/EnterWorld.java
===================================================================
--- java/net/sf/l2j/gameserver/network/clientpackets/EnterWorld.java	(revision 5)
+++ java/net/sf/l2j/gameserver/network/clientpackets/EnterWorld.java	(working copy)
@@ -24,6 +24,7 @@
import net.sf.l2j.gameserver.datatables.MapRegionTable;
import net.sf.l2j.gameserver.datatables.SkillTable;
import net.sf.l2j.gameserver.datatables.SkillTable.FrequentSkill;
+import net.sf.l2j.gameserver.instancemanager.CastleManager;
import net.sf.l2j.gameserver.instancemanager.ClanHallManager;
import net.sf.l2j.gameserver.instancemanager.CoupleManager;
import net.sf.l2j.gameserver.instancemanager.DimensionalRiftManager;
@@ -35,6 +36,7 @@
import net.sf.l2j.gameserver.model.L2World;
import net.sf.l2j.gameserver.model.actor.L2Character;
import net.sf.l2j.gameserver.model.actor.instance.L2PcInstance;
+import net.sf.l2j.gameserver.model.entity.Castle;
import net.sf.l2j.gameserver.model.entity.ClanHall;
import net.sf.l2j.gameserver.model.entity.Couple;
import net.sf.l2j.gameserver.model.entity.Siege;
@@ -114,6 +116,17 @@

		if (activeChar.getClan() != null)
		{
+			L2Clan clan = activeChar.getClan();
+			Castle castle = CastleManager.getInstance().getCastleByOwner(clan);
+			if (Config.ALLOW_ADEN_TRANFORM && (castle != null) && (castle == CastleManager.getInstance().getCastleById(5)))
+			{
+				String aden_transform_id = Config.TRANSFORM_NPC_ADEN;
+				activeChar.getPoly().setPolyInfo("npc", aden_transform_id);
+				activeChar.teleToLocation(activeChar.getX(), activeChar.getY(), activeChar.getZ(), false);				
+				activeChar.sendMessage("The castle of Aden Belongs to your clan");				
+				activeChar.sendMessage("You have been transformed to "+Config.TRANSFORM_NPC_ADEN_NAME+".");
+				activeChar.broadcastUserInfo();
+			}
			activeChar.sendPacket(new PledgeSkillList(activeChar.getClan()));
			notifyClanMembers(activeChar);
			notifySponsorOrApprentice(activeChar);

Index: config/ByLeki.properties
===================================================================
--- config/ByLeki.properties	(revision 6)
+++ config/ByLeki.properties	(working copy)
@@ -26,4 +26,17 @@
PKCleanItemID = 4037

#PK Cleaning price
-PKCleanPrice = 1
+PKCleanPrice = 1
+
+########################################
+# Allow clan members tranformation if 
+# it has Aden Castle?
+########################################
+#Default: False
+EnableTransformAden = False
+
+#NPC id of transformation
+TransformAdenNPCID = 12564
+
+#NPC name
+TransformAdenNPCName = Sin Eater
\ No newline at end of file
Index: java/net/sf/l2j/Config.java
===================================================================
--- java/net/sf/l2j/Config.java	(revision 6)
+++ java/net/sf/l2j/Config.java	(working copy)
@@ -505,7 +505,10 @@
	public static boolean SEVEN_SIGNS_MSG;		
	public static boolean GM_STARTUP_HASTE;		
	public static int PK_CLEAN_ID;	
-	public static int PK_CLEAN_PRICE;		
+	public static int PK_CLEAN_PRICE;
+	public static boolean ALLOW_ADEN_TRANFORM;		
+	public static String  TRANSFORM_NPC_ADEN;
+    public static String  TRANSFORM_NPC_ADEN_NAME;
	// --------------------------------------------------------
	// Rates
	// --------------------------------------------------------
@@ -1305,7 +1308,10 @@
				SEVEN_SIGNS_MSG = Boolean.parseBoolean(byleki.getProperty("Allow7SignsMsg", "True"));
				GM_STARTUP_HASTE = Boolean.parseBoolean(byleki.getProperty("StartupGMHaste", "True"));	
				PK_CLEAN_ID = Integer.parseInt(byleki.getProperty("PKCleanItemID", "4037"));
-				PK_CLEAN_PRICE = Integer.parseInt(byleki.getProperty("PKCleanPrice", "1"));						
+				PK_CLEAN_PRICE = Integer.parseInt(byleki.getProperty("PKCleanPrice", "1"));
+				ALLOW_ADEN_TRANFORM = Boolean.parseBoolean(byleki.getProperty("EnableTransformAden", "False"));
+				TRANSFORM_NPC_ADEN = byleki.getProperty("TransformAdenNPCID", "12564");
+				TRANSFORM_NPC_ADEN_NAME = byleki.getProperty("TransformAdenNPCName", "Sin Eater");			
			}
			catch (Exception e)
			{

 

waiting for feedback.

Credits to me

Link to comment
Share on other sites

  • 4 months later...

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now


  • Posts

    • L2 Insignia High Five 20x MID SERVER FOCUSED ON OLYMPIAD | PVP | AUTOFARM       OPEN BETA TEST SERVER 3 MAY 2024   GRAND OPENING 10 MAY 2024    Rates: 📜 XP/SP 20x | Spoil 15x | Drop 10x | Adena 10x 📜     Server Features: 🔥 No Olf-T Shirt, No big over-enchant, No over-power Donate 🔥 🔥 VIP Gold Color Chat, Unique Olympiad Extra Points Engine, GvG Event 🔥 🔥 Auto-Farm, LoA and DV scheduled PvP Zone, Calendar Daily Reward 🔥 🔥 Castle Instance, Solo Instance, PvP Solo Rift, Dress me system, Adena Boxes 🔥        Website: https://www.l2insignia.com  Discord: https://discord.com/invite/yEgsrHn2hQ      
    • I am selling the essence project which includes versions 388 and 439 that have been running for over 2 years or (447 as custom PVP like Pride). I have a test server for you to test them out. If you are really interested in it then contact my seller at discord: kiwi7106. Price: 4000 Euro P/s: This is a project that I have spent a lot of money and time developing, so if you are not interested in it, please get out of this topic, thank you. P/s 2: If you find the price too expensive, it's best to skip this article and find another project and don't comment negatively on my topic, thank you.
    • Someone ask me for this, it should work on any client that has Kamael race, preview:     Installation - there are two ways to install depending on how you want to use it:   Method 1: If you want to completely replace the original, do:   Copy all lines from your armorgrp to Notepad++, press Ctrl+H, check the "match whole word" option and replace:   kamael.Mkamael_m000_w_ad00   by:   AvengersKamaelWings.Avengers_MKamael_m001_w_ad00   Then replace:   MKamael.Mkamael_m000_t00_w   by:   AvengersKamaelWings.MKamael_m001_t00_w   Now repeat the same process with the female, replace:   kamael.Fkamael_m000_w_ad00   by:   AvengersKamaelWings.Avengers_FKamael_m001_w_ad00   Then replace:   FKamael.Fkamael_m000_t00_w   by:   AvengersKamaelWings.FKamael_m001_t00_w   You're done, paste everything back into File Edit and save!   Method 2: If you only want to replace in specific sets, execute the above process only on the armorgrp of those sets.   Repack by: AvengersTeamBr Password: LadrãoDeFrango      
  • Topics

×
×
  • Create New...