Jump to content
  • 0

[Help]With The Xml of a gm-shop!


DepRessus

Question

Hello guys i wanted to put items on a gm shop +20 !!

for example elegia cuirass +20!!

 

in xml i wrote! :

 

<production id="21919" count="1" enchant="20"/>

 

but it didnt worked.. any ideas?H5 Client

 

Link to comment
Share on other sites

3 answers to this question

Recommended Posts

  • 0

I 've never worked with such clients,but before some months i remember guy on this board sharing an npc with that function(selling +++ weapons),so if you wont get any answer,you should search for it,even if you are not greek.

Link to comment
Share on other sites

  • 0

Working 100%.

 

Core:

Index: /trunk/L2C_TestGameserver/java/com/l2jserver/gameserver/network/serverpackets/MultiSellList.java
===================================================================
--- /trunk/L2C_TestGameserver/java/com/l2jserver/gameserver/network/serverpackets/MultiSellList.java (revision 24)
+++ /trunk/L2C_TestGameserver/java/com/l2jserver/gameserver/network/serverpackets/MultiSellList.java (revision 71)
@@ -119,5 +119,5 @@
                else
                {
-                   writeH(0x00); // enchant level
+                   writeH(ing.getEnchantLevel()); // enchant level by Sirpaypi
                    writeD(0x00); // augment id
                    writeD(0x00); // mana
@@ -154,5 +154,5 @@
                else
                {
-                   writeH(0x00); // enchant level
+                   writeH(ing.getEnchantLevel()); // enchant level
                    writeD(0x00); // augment id
                    writeD(0x00); // mana
Index: /trunk/L2C_TestGameserver/java/com/l2jserver/gameserver/model/multisell/PreparedEntry.java
===================================================================
--- /trunk/L2C_TestGameserver/java/com/l2jserver/gameserver/model/multisell/PreparedEntry.java (revision 24)
+++ /trunk/L2C_TestGameserver/java/com/l2jserver/gameserver/model/multisell/PreparedEntry.java (revision 71)
@@ -72,5 +72,5 @@
        adenaA-beep-t += _taxA-beep-t; // do not forget tax
        if (adenaA-beep-t > 0)
-           _ingredients.add(new Ingredient(ADENA_ID, adenaA-beep-t, false, false));
+           _ingredients.add(new Ingredient(ADENA_ID, adenaA-beep-t,0, false, false));
       
        // now copy products
Index: /trunk/L2C_TestGameserver/java/com/l2jserver/gameserver/model/multisell/Ingredient.java
===================================================================
--- /trunk/L2C_TestGameserver/java/com/l2jserver/gameserver/model/multisell/Ingredient.java (revision 24)
+++ /trunk/L2C_TestGameserver/java/com/l2jserver/gameserver/model/multisell/Ingredient.java (revision 71)
@@ -30,4 +30,5 @@
    private int _itemId;
    private long _itemCount;
+    private int _EnchantmentLevel;
    private boolean _isTaxIngredient, _maintainIngredient;
    
@@ -35,8 +36,9 @@
    private ItemInfo _itemInfo = null;
    
-   public Ingredient(int itemId, long itemCount, boolean isTaxIngredient, boolean maintainIngredient)
+   public Ingredient(int itemId, long itemCount,int EnchantmentLevel, boolean isTaxIngredient, boolean maintainIngredient)
    {
        _itemId = itemId;
        _itemCount = itemCount;
+       _EnchantmentLevel = EnchantmentLevel;
        _isTaxIngredient = isTaxIngredient;
        _maintainIngredient = maintainIngredient;
@@ -80,5 +82,5 @@
    public final int getEnchantLevel()
    {
-       return _itemInfo != null ? _itemInfo.getEnchantLevel() : 0;
+            return _itemInfo == null?_EnchantmentLevel:_itemInfo.getEnchantLevel();
    }
    
Index: /trunk/L2C_TestGameserver/java/com/l2jserver/gameserver/datatables/MultiSell.java
===================================================================
--- /trunk/L2C_TestGameserver/java/com/l2jserver/gameserver/datatables/MultiSell.java (revision 52)
+++ /trunk/L2C_TestGameserver/java/com/l2jserver/gameserver/datatables/MultiSell.java (revision 71)
@@ -270,4 +270,8 @@
            if ("ingredient".equalsIgnoreCase(n.getNodeName()))
            {
+               int enchantmentLevel = 0;
+               if (n.getAttributes().getNamedItem("enchantmentLevel") != null)
+               enchantmentLevel = Integer.parseInt(n.getAttributes().getNamedItem("enchantmentLevel").getNodeValue());
+              
                int id = Integer.parseInt(n.getAttributes().getNamedItem("id").getNodeValue());
                long count = Long.parseLong(n.getAttributes().getNamedItem("count").getNodeValue());
@@ -286,12 +290,16 @@
                    mantainIngredient = false;
               
-               entry.addIngredient(new Ingredient(id, count, isTaxIngredient, mantainIngredient));
+               entry.addIngredient(new Ingredient(id, count, enchantmentLevel, isTaxIngredient, mantainIngredient));
            }
            else if ("production".equalsIgnoreCase(n.getNodeName()))
            {
+               int enchantmentLevel = 0;
+               if (n.getAttributes().getNamedItem("enchantmentLevel") != null)
+               enchantmentLevel = Integer.parseInt(n.getAttributes().getNamedItem("enchantmentLevel").getNodeValue());
+              
                int id = Integer.parseInt(n.getAttributes().getNamedItem("id").getNodeValue());
                long count = Long.parseLong(n.getAttributes().getNamedItem("count").getNodeValue());
               
-               entry.addProduct(new Ingredient(id, count, false, false));
+               entry.addProduct(new Ingredient(id, count, enchantmentLevel, false, false));
            }
        }

 

Datapack:

 

e.g:

<production id="15725" count="1" enchantmentLevel="16" />

Link to comment
Share on other sites

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...