Jump to content

Recommended Posts

Posted (edited)

Hello, I bring you the l2jdev dungeon event adapted to l2jfrozen for me

 

video test

 

Update Code: https://pastebin.com/Kc61EPNc

 

sql,html: https://www.mediafire.com/file/7z5v60myf9tf1vn/Dungeon.rar/file

 

 

I don't know exactly all the credits but I leave the names of the codes I use, sorry if any are missing

 

Credits: Anarchy, Juvenil Walker, Baggos, mkizub, G1ta0, Forsaiken

Help:melron

 

 

Edited by tensador27
Update code
  • Thanks 1
Posted
2 minutes ago, tensador27 said:

any advice or basic guide to improve it thank you very much in the same way

Simply check if the player is on dungeon before the item creation 

Posted
1 hour ago, melron said:

Simply check if the player is on dungeon before the item creation 

hello add this do you think it would work?

 

	                            if(DungeonManager.getInstance().getDungeonParticipants().contains(activeChar.getObjectId()))
                               {                         	  
   								L2ItemInstance item = activeChar.addItemDungeon("dungeon reward", itemId, count, null, true);
   								item.setEnchantLevel(25);
   								activeChar.getInventory().equipItemAndRecord(item);
   				                PlayerMemo.setVar(activeChar, "delete_temp_item_" + item.getObjectId(), item.getObjectId(), System.currentTimeMillis() + (1000 *60 *60 *5)); 
   								InstanceManager.getInstance().getInstance(0);
   								activeChar.setDungeon(null);						
   								activeChar.teleToLocation(Config.DUNGEON_SPAWN_X, Config.DUNGEON_SPAWN_Y, Config.DUNGEON_SPAWN_Z, Config.DUNGEON_SPAWN_RND);	                  	                            	   
                               }
	                            else 
                               {
                            	 activeChar.sendMessage("No puedes recibir el premio");  
                               }

 

I also put this

 

	                               if(Dungeon.isRegistered(activeChar)) 
                               {                         	  
   								L2ItemInstance item = activeChar.addItemDungeon("dungeon reward", itemId, count, null, true);
   								item.setEnchantLevel(25);
   								activeChar.getInventory().equipItemAndRecord(item);
   				                PlayerMemo.setVar(activeChar, "delete_temp_item_" + item.getObjectId(), item.getObjectId(), System.currentTimeMillis() + (1000 *60 *60 *5)); 
   								InstanceManager.getInstance().getInstance(0);
   								activeChar.setDungeon(null);						
   								activeChar.teleToLocation(Config.DUNGEON_SPAWN_X, Config.DUNGEON_SPAWN_Y, Config.DUNGEON_SPAWN_Z, Config.DUNGEON_SPAWN_RND);	                  	                            	   
                               }




and in the dungeon part I put this
  
	public static boolean isRegistered(L2PcInstance player)
	{
		return DungeonManager.getInstance().getDungeonParticipants().contains(player.getObjectId());
	}  

 

Posted
1 minute ago, Kara said:

Like your ex. 

Are you vulnerable? I divorced you because you were a bitch

11 minutes ago, tensador27 said:

hello add this do you think it would work?

 

 

activeChar.getDungeon() != null

Posted (edited)

@tensador27 with this ThreadPool.java player will not teleported ..you need to use ThreadPoolManager options to work perfectly..i got stacked many times .. What i did :

replace all : ThreadPool.schedule(
with :ThreadPoolManager.getInstance().scheduleGeneral(

 

and all :  ThreadPool.scheduleAtFixedRate(()

with : ThreadPoolManager.getInstance().scheduleGeneralAtFixedRate(()

 

also you need to add this :
 

com/l2jfrozen/gameserver/model/actor/knownlist/ObjectKnownList.java
===========================================

        @Override
        public void run()
        {
            if (_obj != null)
            {
                _obj.getKnownList().updateKnownObjects();
            }
        }
    }


+    @SuppressWarnings("unchecked")
+    public final <A> Collection<A> getKnownType(Class<A> type)
+    {
+        List<A> result = new ArrayList<>();
+        
+        for (L2Object obj : _knownObjects.values())
+        {
+            if (type.isAssignableFrom(obj.getClass()))
+                result.add((A) obj);
+        }
+        return result;
+    }
+    
+    @SuppressWarnings("unchecked")
+    public final <A> Collection<A> getKnownTypeInRadius(Class<A> type, int radius)
+    {
+        List<A> result = new ArrayList<>();
+        
+        for (L2Object obj : _knownObjects.values())
+        {
+            if (type.isAssignableFrom(obj.getClass()) && Util.checkIfInRange(radius, getActiveObject(), obj, true))
+                result.add((A) obj);
+        }
+        return result;
+    }
}

 

 

also consuming of items on party dungeon needs fix, it first take the itemid and then it tell u ,u need party.https://ibb.co/zb5wbW5

Edited by Irrelevant
  • 3 months later...
Posted (edited)

This code is old and there's a few bugs (like the bypass vulnerability). This was taken from L2Eola files but not the latest files obviously, so you have to find and fix any bugs.

 

The person who tried to adapt this clearly did not bother to read the code or was unable to, therefore whole systems such as player memo have been copied from aCis for a single use (dungeon). Or even ThreadPool class when frozen already has a thread pool implementation.

Instances code is incomplete too and there will be issues for sure.

 

Some other parts of the code are changed too, I suppose it's because you gave credits to 5 other people besides me so some of them must have made the changes.

 

-

 

If you need a proper adaptation don't use this, ask a person that knows what they're doing to adapt this for you.

 

 

 

ALSO this made me physically sick:

  

+           if (_command.startsWith("bp_reward"))
+           {
+               int type = Integer.parseInt(_command.substring(10));
+               int itemId = 0;
+               int count = 1;
+               
+               switch (type)
+               {
+                   case 0:
+                   {
+                       itemId = Config.DUNGEON_ITEM_RENEWAL0;
+                       
+                       break;
+                   }
+                   case 1:
+                   {
+                       itemId = Config.DUNGEON_ITEM_RENEWAL1;
+                       
+                       break;
+                   }
+                   case 2:
+                   {
+                       itemId = Config.DUNGEON_ITEM_RENEWAL2;
+                       
+                       break;
+                   }
+                   case 3:
+                   {
+                       itemId = Config.DUNGEON_ITEM_RENEWAL3;
+                       
+                       break;
+                   }
+                   case 4:
+                   {
+                       itemId = Config.DUNGEON_ITEM_RENEWAL4;
+                       
+                       break;
+                   }
+                   case 5:
+                   {
+                       itemId = Config.DUNGEON_ITEM_RENEWAL5;
+                       
+                       break;
+                   }
+                   case 6:
+                   {
+                       itemId = Config.DUNGEON_ITEM_RENEWAL6;
+                       
+                       break;
+                   }
+                   case 7:
+                   {
+                       itemId = Config.DUNGEON_ITEM_RENEWAL7;
+                       
+                       break;
+                   }
+                   case 8:
+                   {
+                       itemId = Config.DUNGEON_ITEM_RENEWAL8;
+                       
+                       break;
+                   }
+                   case 9:
+                   {
+                       itemId = Config.DUNGEON_ITEM_RENEWAL9;
+                       
+                       break;
+                   }
+                   case 10:
+                   {
+                       itemId = Config.DUNGEON_ITEM_RENEWAL10;
+                       
+                       break;
+                   }
+               }
+               
+               if (itemId == 0)
+               {
+                   System.out.println(activeChar.getName() + " tried to send custom id on dungeon solo rewards.");
+                   return;
+               }
+                               if(activeChar.getDungeon() != null)
+                               {                             
+                                   L2ItemInstance item = activeChar.addItemDungeon("dungeon reward", itemId, count, null, true);
+                                   item.setEnchantLevel(25);
+                                   activeChar.getInventory().equipItemAndRecord(item);
+                                   PlayerMemo.setVar(activeChar, "delete_temp_item_" + item.getObjectId(), item.getObjectId(), System.currentTimeMillis() + (1000 *60 *60 *5)); 
+                                   InstanceManager.getInstance().getInstance(0);
+                                   activeChar.setDungeon(null);                        
+                                   activeChar.teleToLocation(Config.DUNGEON_SPAWN_X, Config.DUNGEON_SPAWN_Y, Config.DUNGEON_SPAWN_Z, Config.DUNGEON_SPAWN_RND);                                                           
+                               }
+                               else 
+                               {
+                                activeChar.sendMessage("No puedes recibir el premio");  
+                               }
+           }

 

 

Edited by An4rchy
Posted
5 hours ago, joseinacio said:

help acis 401

image.png.4ea06f15f401d7555cd0e9883a661c48.png

 

 

ConectionPool.java

add this

 

	private static final CLogger LOGGER = new CLogger(ConnectionPool.class.getName());
+	private static ConnectionPool _instance;	




	public static Connection getConnection() throws SQLException
	{
		return _source.getConnection();
	}

+	public static ConnectionPool getInstance()
+	{
+		if (_instance == null)
+		{
+			_instance = new ConnectionPool();
+		}
+		
+		return _instance;
+	}

 

  • Like 1
  • 4 weeks later...
Posted (edited)
On 6/23/2022 at 3:27 PM, tensador27 said:

 

 

ConectionPool.java

add this

 

	private static final CLogger LOGGER = new CLogger(ConnectionPool.class.getName());
+	private static ConnectionPool _instance;	




	public static Connection getConnection() throws SQLException
	{
		return _source.getConnection();
	}

+	public static ConnectionPool getInstance()
+	{
+		if (_instance == null)
+		{
+			_instance = new ConnectionPool();
+		}
+		
+		return _instance;
+	}

 

help

image.png.88ee713e60a06bb326551add8d728321.png

only on linux this error windows is okimage.png.1d274413ebb8f85f1b8a6a7ea079a73e.png

Edited by joseinacio

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

    • We can help your Telegram group or channel grow fast with real, targeted Telegram members, safely and efficiently.   Our Telegram Member Add service lets you add members to Telegram group or channel from real, active communities — not bots or fakes.   With this Telegram group growth service, you’ll see results within hours, backed by clear reporting and safe automation.   ✅ What We Offer   • Done-for-you Telegram Member Add campaigns (Groups · Channels) • Targeted Telegram members from real, active users • Fast growth — up to 10K members in 24 hours • English-speaking or regional audiences (US · UK · EU) • Fully managed Telegram channel growth service with reports & analytics   💡 Why Choose Us   We don’t use spam or fake accounts. Our process safely adds members to your Telegram group or channel through verified multi-account setups, proxy rotation, and opt-out compliance. This ensures lasting growth and minimizes churn. Every campaign is managed by experts using tested Telegram infrastructure and growth systems. We also recommend combining Member Add with Telegram Mass DM for better engagement and retention after join.   🧩 Works Best For   • Businesses or communities launching new Telegram channels • Crypto, SaaS, and marketing projects needing visibility • Influencers and agencies growing multiple Telegram groups • Anyone seeking a reliable Telegram group growth service with real members 📩 To Get More Information   Telegram : @TeleLoopPulse   Website : https://telegramgrowthstudio.com/telegram-member-add.html
    • well,its SharedCreatureData.h problem.   /* 0398 */ //WCHAR m_sResurrectSpellerName[25];   this variable will cause L2server.exe crash...  
    • Custom High Five server L2insolence will open 2025-10-17 21:00 GMT+2 ! ! ! Web site: http://www.l2insolence.eu All info updates on Discord: https://discord.gg/duMjnj3y9A Last wipe was more then 1 year ago. We have custom skill, farm zones, materials for items to buy. Custom wepons, armor, jewels and more. All items in game have own stats. With custom looks. Glowing etc. Rates XP, SP: 25x Spoil and Drop: 10x Adena: 20x Server Hard Farm Enchantment Safe enchant Weapon: +20099 Safe enchant Armor: +20099 Max enchant Weapon: +20099 Max enchant Armor: +20099 Normal scrolls: 100% Blessed scrolls: 100% You can use scrolls or item enchant NPC to make +++ abd life beter. NPC Buffer There's an NPC buffer in all of our main towns: Aden, Giran and Goddard. It supplies Prophet Buffs, Songs and Dances for a small fee. Include all buff. We have custom self buffs learned with npc with custom stats. Global Gatekeeper GM Shop with normal items and custom ones, vote NPC, Event NPC, item upgrader NPC. Raid Bosses, every zone have its own boss and drops for rare mats. Olympiad The olympiad is ongoing every two weeks. Meaning if you become a hero you will have your hero status for two weeks. And hero have own custom stats on items.
  • 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