Jump to content

l2jfrozen custom enchant value with scroll custom


Recommended Posts

 

hello I wanted to add a second value of custom enchant value for a custom scroll or donor I tried it but when using the scroll it keeps using the common value of custom enchant value and I don't know how to make it work thanks anyway

 

 

 

 

enchant config:

 

Quote

# The value of enchanting
# For example: If CustomEnchantValue = 5 Sharpening will:
# From 0 till the +5, with +5 to +10, from +10 to +15, etc.
# Total: 15 for three to scroll
# Default: 1 
CustomEnchantValue = 5

CustomDayEnchantValue = 25

CustomNightEnchantValue = 30

 

 

 

 

RequestEnchantItem.java

 

Quote

    private static final int[] BRANCA_DAY_WEAPON_SCROLLS =
    {
        12021
    };
    
    private static final int[] BRANCA_DAY_ARMOR_SCROLLS =
    {
        12020
    };
    
    private static final int[] BRANCA_NIGHT_WEAPON_SCROLLS =
    {
        12023
    };
    
    private static final int[] BRANCA_NIGHT_ARMOR_SCROLLS =
    {
        12022
    };
    
    private static final int[] NORMAL_ARMOR_SCROLLS =
    {
        730,
        948,
        952,
        956,
        960
    };
    
    private static final int[] BLESSED_ARMOR_SCROLLS =
    {
        6570,
        6572,
        6574,
        6576,
        6578
    };
    
    private static final int[] CRYSTAL_ARMOR_SCROLLS =
    {
        732,
        950,
        954,
        958,
        962
    };
    
    private int _objectId;
    
    @Override
    protected void readImpl()
    {
        _objectId = readD();
    }
    
    @Override
    protected void runImpl()
    {
        L2PcInstance activeChar = getClient().getActiveChar();
        
        if (activeChar == null || _objectId == 0)
        {
            return;
        }
        
        if (!getClient().getFloodProtectors().getUseAugItem().tryPerformAction("use enchant item"))
        {
            LOG.info(activeChar.getName() + " tried flood on ITEM enchanter.");
            activeChar.setActiveEnchantItem(null);
            activeChar.sendPacket(ActionFailed.STATIC_PACKET);
            return;
        }
        
        if (activeChar.isSubmitingPin())
        {
            activeChar.sendMessage("Unable to do any action while PIN is not submitted");
            activeChar.sendPacket(ActionFailed.STATIC_PACKET);
            return;
        }
        
        if (activeChar.getActiveTradeList() != null)
        {
            activeChar.cancelActiveTrade();
            activeChar.sendMessage("Your trade canceled.");
            return;
        }
        
        // Fix enchant transactions
        if (activeChar.isProcessingTransaction())
        {
            activeChar.sendPacket(new SystemMessage(SystemMessageId.INAPPROPRIATE_ENCHANT_CONDITION));
            activeChar.setActiveEnchantItem(null);
            return;
        }
        
        if (activeChar.isOnline() == 0)
        {
            activeChar.setActiveEnchantItem(null);
            return;
        }
        
        L2ItemInstance item = activeChar.getInventory().getItemByObjectId(_objectId);
        L2ItemInstance scroll = activeChar.getActiveEnchantItem();
        activeChar.setActiveEnchantItem(null);
        
        if (item == null || scroll == null)
        {
            activeChar.setActiveEnchantItem(null);
            activeChar.sendPacket(SystemMessageId.ENCHANT_SCROLL_CANCELLED);
            activeChar.sendPacket(EnchantResult.CANCELLED);
            return;
        }
        
        handleAugmentScrolls(activeChar, item, scroll);
        
        // can't enchant rods and shadow items
        if (item.getItem().getItemType() == L2WeaponType.ROD || item.isShadowItem())
        {
            activeChar.sendPacket(new SystemMessage(SystemMessageId.INAPPROPRIATE_ENCHANT_CONDITION));
            activeChar.setActiveEnchantItem(null);
            return;
        }
        
        if (!Config.ENCHANT_HERO_WEAPON && item.getItemId() >= 6611 && item.getItemId() <= 6621)
        {
            activeChar.sendPacket(new SystemMessage(SystemMessageId.INAPPROPRIATE_ENCHANT_CONDITION));
            activeChar.setActiveEnchantItem(null);
            return;
        }
        
        if (item.isWear())
        {
            activeChar.setActiveEnchantItem(null);
            Util.handleIllegalPlayerAction(activeChar, "Player " + activeChar.getName() + " tried to enchant a weared Item", IllegalPlayerAction.PUNISH_KICK);
            return;
        }
        
        int itemType2 = item.getItem().getType2();
        boolean enchantItem = false;
        boolean blessedScroll = false;
        boolean crystalScroll = false;
        boolean BrancaDayScroll = false;
        boolean BrancaNightScroll = false;
        int crystalId = 0;
        
        switch (item.getItem().getCrystalType())
        {
            case L2Item.CRYSTAL_A:
                crystalId = 1461;
                switch (scroll.getItemId())
                {
                    case 729:
                    case 731:
                    case 6569:
                        if (itemType2 == L2Item.TYPE2_WEAPON)
                        {
                            enchantItem = true;
                        }
                        break;
                    case 730:
                    case 732:
                    case 6570:
                        if (itemType2 == L2Item.TYPE2_SHIELD_ARMOR || itemType2 == L2Item.TYPE2_ACCESSORY)
                        {
                            enchantItem = true;
                        }
                        break;
                }
                break;
            case L2Item.CRYSTAL_B:
                crystalId = 1460;
                switch (scroll.getItemId())
                {
                    case 947:
                    case 949:
                    case 6571:
                        if (itemType2 == L2Item.TYPE2_WEAPON)
                        {
                            enchantItem = true;
                        }
                        break;
                    case 948:
                    case 950:
                    case 6572:
                        if (itemType2 == L2Item.TYPE2_SHIELD_ARMOR || itemType2 == L2Item.TYPE2_ACCESSORY)
                        {
                            enchantItem = true;
                        }
                        break;
                }
                break;
            case L2Item.CRYSTAL_C:
                crystalId = 1459;
                switch (scroll.getItemId())
                {
                    case 951:
                    case 953:
                    case 6573:
                        if (itemType2 == L2Item.TYPE2_WEAPON)
                        {
                            enchantItem = true;
                        }
                        break;
                    case 952:
                    case 954:
                    case 6574:
                        if (itemType2 == L2Item.TYPE2_SHIELD_ARMOR || itemType2 == L2Item.TYPE2_ACCESSORY)
                        {
                            enchantItem = true;
                        }
                        break;
                }
                break;
            case L2Item.CRYSTAL_D:
                crystalId = 1458;
                switch (scroll.getItemId())
                {
                    case 955:
                    case 957:
                    case 6575:
                        if (itemType2 == L2Item.TYPE2_WEAPON)
                        {
                            enchantItem = true;
                        }
                        break;
                    case 956:
                    case 958:
                    case 6576:
                        if (itemType2 == L2Item.TYPE2_SHIELD_ARMOR || itemType2 == L2Item.TYPE2_ACCESSORY)
                        {
                            enchantItem = true;
                        }
                        break;
                }
                break;
            case L2Item.CRYSTAL_S:
                crystalId = 1462;
                switch (scroll.getItemId())
                {
                    case 959:
                    case 961:
                    case 6577:
                    case 12021:
                    case 12022:
                        if (itemType2 == L2Item.TYPE2_WEAPON)
                        {
                            enchantItem = true;
                        }
                        break;
                    case 960:
                    case 962:
                    case 6578:
                    case 12020:
                    case 12023:
                        if (itemType2 == L2Item.TYPE2_SHIELD_ARMOR || itemType2 == L2Item.TYPE2_ACCESSORY)
                        {
                            enchantItem = true;
                        }
                        break;
                }
                break;
        }
        
        if (!enchantItem)
        {
            return;
        }
        
        // Get the scroll type
        if (scroll.getItemId() >= 6569 && scroll.getItemId() <= 6578)
        {
            blessedScroll = true;
        }
        else if (scroll.getItemId() == 12020 || scroll.getItemId() == 12021)
        {
            BrancaDayScroll = true;
        }
        else if (scroll.getItemId() == 12022 || scroll.getItemId() == 12023)
        {
            BrancaNightScroll = true;
        }
        else
        {
            for (int crystalscroll : CRYSTAL_SCROLLS)
            {
                if (scroll.getItemId() == crystalscroll)
                {
                    crystalScroll = true;
                    break;
                }
            }
            
        }
        
        SystemMessage sm;
        int chance = 0;
        int maxEnchantLevel = 0;
        int minEnchantLevel = 0;
        
        if (item.getItem().getType2() == L2Item.TYPE2_WEAPON)
        {
            if (blessedScroll)
            {
                for (int blessedweaponscroll : BLESSED_WEAPON_SCROLLS)
                {
                    if (scroll.getItemId() == blessedweaponscroll)
                    {
                        if (item.getEnchantLevel() >= Config.BLESS_WEAPON_ENCHANT_LEVEL.size())
                        {
                            chance = Config.BLESS_WEAPON_ENCHANT_LEVEL.get(Config.BLESS_WEAPON_ENCHANT_LEVEL.size());
                        }
                        else
                        {
                            chance = Config.BLESS_WEAPON_ENCHANT_LEVEL.get(item.getEnchantLevel() + 1);
                        }
                        
                        if (Config.CUSTOM_ENCHANT_GRADES_SYSTEM)
                        {
                            switch (item.getItem().getCrystalType())
                            {
                                case L2Item.CRYSTAL_S:
                                    maxEnchantLevel = Config.BLESSED_ENCHANT_MAX_S;
                                    break;
                                case L2Item.CRYSTAL_A:
                                    maxEnchantLevel = Config.BLESSED_ENCHANT_MAX_A;
                                    break;
                                case L2Item.CRYSTAL_B:
                                    maxEnchantLevel = Config.BLESSED_ENCHANT_MAX_B;
                                    break;
                                case L2Item.CRYSTAL_C:
                                    maxEnchantLevel = Config.BLESSED_ENCHANT_MAX_C;
                                    break;
                                case L2Item.CRYSTAL_D:
                                    maxEnchantLevel = Config.BLESSED_ENCHANT_MAX_D;
                                    break;
                            }
                        }
                        
                        if (!Config.CUSTOM_ENCHANT_GRADES_SYSTEM)
                        {
                            maxEnchantLevel = Config.ENCHANT_WEAPON_MAX;
                            break;
                        }
                    }
                }
            }
            
            else if (BrancaDayScroll)
            {
                
                for (int scrollId : BRANCA_DAY_WEAPON_SCROLLS)
                {
                    if (scroll.getItemId() == scrollId)
                    {
                        if (item.getEnchantLevel() >= Config.DONATOR_DAY_WEAPON_ENCHANT_LEVEL.size())
                        {
                            chance = Config.DONATOR_DAY_WEAPON_ENCHANT_LEVEL.get(Config.DONATOR_DAY_WEAPON_ENCHANT_LEVEL.size());
                        }
                        else
                        {
                            chance = Config.DONATOR_DAY_WEAPON_ENCHANT_LEVEL.get(item.getEnchantLevel() + 1);
                        }
                        minEnchantLevel = Config.ENCHANT_DAY_WEAPON_MIN;
                        maxEnchantLevel = Config.ENCHANT_DAY_WEAPON_MAX;
                        break;
                    }
                }
            }
            
            else if (BrancaNightScroll)
            {
                
                for (int scrollId : BRANCA_NIGHT_WEAPON_SCROLLS)
                {
                    if (scroll.getItemId() == scrollId)
                    {
                        if (item.getEnchantLevel() >= Config.DONATOR_NIGHT_WEAPON_ENCHANT_LEVEL.size())
                        {
                            chance = Config.DONATOR_NIGHT_WEAPON_ENCHANT_LEVEL.get(Config.DONATOR_NIGHT_WEAPON_ENCHANT_LEVEL.size());
                        }
                        else
                        {
                            chance = Config.DONATOR_NIGHT_WEAPON_ENCHANT_LEVEL.get(item.getEnchantLevel() + 1);
                        }
                        minEnchantLevel = Config.ENCHANT_NIGHT_WEAPON_MIN;
                        maxEnchantLevel = Config.ENCHANT_NIGHT_WEAPON_MAX;
                        break;
                    }
                }
            }
            
            else if (crystalScroll)
            {
                for (int crystalweaponscroll : CRYSTAL_WEAPON_SCROLLS)
                {
                    if (scroll.getItemId() == crystalweaponscroll)
                    {
                        if (item.getEnchantLevel() >= Config.CRYSTAL_WEAPON_ENCHANT_LEVEL.size())
                        {
                            chance = Config.CRYSTAL_WEAPON_ENCHANT_LEVEL.get(Config.CRYSTAL_WEAPON_ENCHANT_LEVEL.size());
                        }
                        else
                        {
                            chance = Config.CRYSTAL_WEAPON_ENCHANT_LEVEL.get(item.getEnchantLevel() + 1);
                        }
                        
                        minEnchantLevel = Config.CRYSTAL_ENCHANT_MIN;
                        maxEnchantLevel = Config.CRYSTAL_ENCHANT_MAX;
                        
                        break;
                    }
                }
            }
            else
            { // normal scrolls
                for (int normalweaponscroll : NORMAL_WEAPON_SCROLLS)
                {
                    if (scroll.getItemId() == normalweaponscroll)
                    {
                        if (item.getEnchantLevel() >= Config.NORMAL_WEAPON_ENCHANT_LEVEL.size())
                        {
                            chance = Config.NORMAL_WEAPON_ENCHANT_LEVEL.get(Config.NORMAL_WEAPON_ENCHANT_LEVEL.size());
                        }
                        else
                        {
                            chance = Config.NORMAL_WEAPON_ENCHANT_LEVEL.get(item.getEnchantLevel() + 1);
                        }
                        
                        if (Config.CUSTOM_ENCHANT_GRADES_SYSTEM)
                        {
                            switch (item.getItem().getCrystalType())
                            {
                                case L2Item.CRYSTAL_S:
                                    maxEnchantLevel = Config.ENCHANT_MAX_S;
                                    break;
                                case L2Item.CRYSTAL_A:
                                    maxEnchantLevel = Config.ENCHANT_MAX_A;
                                    break;
                                case L2Item.CRYSTAL_B:
                                    maxEnchantLevel = Config.ENCHANT_MAX_B;
                                    break;
                                case L2Item.CRYSTAL_C:
                                    maxEnchantLevel = Config.ENCHANT_MAX_C;
                                    break;
                                case L2Item.CRYSTAL_D:
                                    maxEnchantLevel = Config.ENCHANT_MAX_D;
                                    break;
                            }
                        }
                        
                    }
                    else if (BrancaDayScroll)
                    {
                        
                        for (int scrollId : BRANCA_DAY_ARMOR_SCROLLS)
                        {
                            if (scroll.getItemId() == scrollId)
                            {
                                if (item.getEnchantLevel() >= Config.DONATOR_DAY_ARMOR_ENCHANT_LEVEL.size())
                                {
                                    chance = Config.DONATOR_DAY_ARMOR_ENCHANT_LEVEL.get(Config.DONATOR_DAY_ARMOR_ENCHANT_LEVEL.size());
                                }
                                else
                                {
                                    chance = Config.DONATOR_DAY_ARMOR_ENCHANT_LEVEL.get(item.getEnchantLevel() + 1);
                                }
                                minEnchantLevel = Config.ENCHANT_DAY_ARMOR_MIN;
                                maxEnchantLevel = Config.ENCHANT_DAY_ARMOR_MAX;
                                
                                break;
                            }
                        }
                        
                        if (!Config.CUSTOM_ENCHANT_GRADES_SYSTEM)
                        {
                            maxEnchantLevel = Config.ENCHANT_WEAPON_MAX;
                            break;
                        }
                    }
                }
            }
            
        }
        else if (item.getItem().getType2() == L2Item.TYPE2_SHIELD_ARMOR)
        {
            if (blessedScroll)
            {
                for (int blessedarmorscroll : BLESSED_ARMOR_SCROLLS)
                {
                    if (scroll.getItemId() == blessedarmorscroll)
                    {
                        if (item.getEnchantLevel() >= Config.BLESS_ARMOR_ENCHANT_LEVEL.size())
                        {
                            chance = Config.BLESS_ARMOR_ENCHANT_LEVEL.get(Config.BLESS_ARMOR_ENCHANT_LEVEL.size());
                        }
                        else
                        {
                            chance = Config.BLESS_ARMOR_ENCHANT_LEVEL.get(item.getEnchantLevel() + 1);
                        }
                        
                        if (Config.CUSTOM_ENCHANT_GRADES_SYSTEM)
                        {
                            switch (item.getItem().getCrystalType())
                            {
                                case L2Item.CRYSTAL_S:
                                    maxEnchantLevel = Config.BLESSED_ENCHANT_MAX_S;
                                    break;
                                case L2Item.CRYSTAL_A:
                                    maxEnchantLevel = Config.BLESSED_ENCHANT_MAX_A;
                                    break;
                                case L2Item.CRYSTAL_B:
                                    maxEnchantLevel = Config.BLESSED_ENCHANT_MAX_B;
                                    break;
                                case L2Item.CRYSTAL_C:
                                    maxEnchantLevel = Config.BLESSED_ENCHANT_MAX_C;
                                    break;
                                case L2Item.CRYSTAL_D:
                                    maxEnchantLevel = Config.BLESSED_ENCHANT_MAX_D;
                                    break;
                            }
                        }
                        
                        if (!Config.CUSTOM_ENCHANT_GRADES_SYSTEM)
                        {
                            maxEnchantLevel = Config.ENCHANT_ARMOR_MAX;
                            break;
                        }
                    }
                }
            }
            else if (crystalScroll)
            {
                for (int crystalarmorscroll : CRYSTAL_ARMOR_SCROLLS)
                {
                    if (scroll.getItemId() == crystalarmorscroll)
                    {
                        if (item.getEnchantLevel() >= Config.CRYSTAL_ARMOR_ENCHANT_LEVEL.size())
                        {
                            chance = Config.CRYSTAL_ARMOR_ENCHANT_LEVEL.get(Config.CRYSTAL_ARMOR_ENCHANT_LEVEL.size());
                        }
                        else
                        {
                            chance = Config.CRYSTAL_ARMOR_ENCHANT_LEVEL.get(item.getEnchantLevel() + 1);
                        }
                        
                        minEnchantLevel = Config.CRYSTAL_ENCHANT_MIN;
                        maxEnchantLevel = Config.CRYSTAL_ENCHANT_MAX;
                        
                        break;
                    }
                }
                
            }
            else
            { // normal scrolls
                for (int normalarmorscroll : NORMAL_ARMOR_SCROLLS)
                {
                    if (scroll.getItemId() == normalarmorscroll)
                    {
                        if (item.getEnchantLevel() >= Config.NORMAL_ARMOR_ENCHANT_LEVEL.size())
                        {
                            chance = Config.NORMAL_ARMOR_ENCHANT_LEVEL.get(Config.NORMAL_ARMOR_ENCHANT_LEVEL.size());
                        }
                        else
                        {
                            chance = Config.NORMAL_ARMOR_ENCHANT_LEVEL.get(item.getEnchantLevel() + 1);
                        }
                        
                        if (Config.CUSTOM_ENCHANT_GRADES_SYSTEM)
                        {
                            switch (item.getItem().getCrystalType())
                            {
                                case L2Item.CRYSTAL_S:
                                    maxEnchantLevel = Config.ENCHANT_MAX_S;
                                    break;
                                case L2Item.CRYSTAL_A:
                                    maxEnchantLevel = Config.ENCHANT_MAX_A;
                                    break;
                                case L2Item.CRYSTAL_B:
                                    maxEnchantLevel = Config.ENCHANT_MAX_B;
                                    break;
                                case L2Item.CRYSTAL_C:
                                    maxEnchantLevel = Config.ENCHANT_MAX_C;
                                    break;
                                case L2Item.CRYSTAL_D:
                                    maxEnchantLevel = Config.ENCHANT_MAX_D;
                                    break;
                            }
                        }
                        
                    }
                    else if (BrancaNightScroll)
                    {
                        
                        for (int scrollId : BRANCA_NIGHT_ARMOR_SCROLLS)
                        {
                            if (scroll.getItemId() == scrollId)
                            {
                                if (item.getEnchantLevel() >= Config.DONATOR_NIGHT_ARMOR_ENCHANT_LEVEL.size())
                                {
                                    chance = Config.DONATOR_NIGHT_ARMOR_ENCHANT_LEVEL.get(Config.DONATOR_NIGHT_ARMOR_ENCHANT_LEVEL.size());
                                }
                                else
                                {
                                    chance = Config.DONATOR_NIGHT_ARMOR_ENCHANT_LEVEL.get(item.getEnchantLevel() + 1);
                                }
                                minEnchantLevel = Config.ENCHANT_NIGHT_ARMOR_MIN;
                                maxEnchantLevel = Config.ENCHANT_NIGHT_ARMOR_MAX;
                                
                                break;
                            }
                        }
                        
                        if (!Config.CUSTOM_ENCHANT_GRADES_SYSTEM)
                        {
                            maxEnchantLevel = Config.ENCHANT_ARMOR_MAX;
                            break;
                        }
                    }
                }
                
            }
            
        }
        else if (item.getItem().getType2() == L2Item.TYPE2_ACCESSORY)
        {
            if (blessedScroll)
            {
                
                for (int blessedjewelscroll : BLESSED_ARMOR_SCROLLS)
                {
                    if (scroll.getItemId() == blessedjewelscroll)
                    {
                        if (item.getEnchantLevel() >= Config.BLESS_JEWELRY_ENCHANT_LEVEL.size())
                        {
                            chance = Config.BLESS_JEWELRY_ENCHANT_LEVEL.get(Config.BLESS_JEWELRY_ENCHANT_LEVEL.size());
                        }
                        else
                        {
                            chance = Config.BLESS_JEWELRY_ENCHANT_LEVEL.get(item.getEnchantLevel() + 1);
                        }
                        
                        if (Config.CUSTOM_ENCHANT_GRADES_SYSTEM)
                        {
                            switch (item.getItem().getCrystalType())
                            {
                                case L2Item.CRYSTAL_S:
                                    maxEnchantLevel = Config.BLESSED_ENCHANT_MAX_S;
                                    break;
                                case L2Item.CRYSTAL_A:
                                    maxEnchantLevel = Config.BLESSED_ENCHANT_MAX_A;
                                    break;
                                case L2Item.CRYSTAL_B:
                                    maxEnchantLevel = Config.BLESSED_ENCHANT_MAX_B;
                                    break;
                                case L2Item.CRYSTAL_C:
                                    maxEnchantLevel = Config.BLESSED_ENCHANT_MAX_C;
                                    break;
                                case L2Item.CRYSTAL_D:
                                    maxEnchantLevel = Config.BLESSED_ENCHANT_MAX_D;
                                    break;
                            }
                        }
                        
                        if (!Config.CUSTOM_ENCHANT_GRADES_SYSTEM)
                        {
                            maxEnchantLevel = Config.ENCHANT_JEWELRY_MAX;
                            break;
                        }
                    }
                }
                
            }
            else if (crystalScroll)
            {
                for (int crystaljewelscroll : CRYSTAL_ARMOR_SCROLLS)
                {
                    if (scroll.getItemId() == crystaljewelscroll)
                    {
                        if (item.getEnchantLevel() >= Config.CRYSTAL_JEWELRY_ENCHANT_LEVEL.size())
                        {
                            chance = Config.CRYSTAL_JEWELRY_ENCHANT_LEVEL.get(Config.CRYSTAL_JEWELRY_ENCHANT_LEVEL.size());
                        }
                        else
                        {
                            chance = Config.CRYSTAL_JEWELRY_ENCHANT_LEVEL.get(item.getEnchantLevel() + 1);
                        }
                        
                        minEnchantLevel = Config.CRYSTAL_ENCHANT_MIN;
                        maxEnchantLevel = Config.CRYSTAL_ENCHANT_MAX;
                        
                        break;
                    }
                }
            }
            else
            {
                for (int normaljewelscroll : NORMAL_ARMOR_SCROLLS)
                {
                    if (scroll.getItemId() == normaljewelscroll)
                    {
                        if (item.getEnchantLevel() >= Config.NORMAL_JEWELRY_ENCHANT_LEVEL.size())
                        {
                            chance = Config.NORMAL_JEWELRY_ENCHANT_LEVEL.get(Config.NORMAL_JEWELRY_ENCHANT_LEVEL.size());
                        }
                        else
                        {
                            chance = Config.NORMAL_JEWELRY_ENCHANT_LEVEL.get(item.getEnchantLevel() + 1);
                        }
                        
                        if (Config.CUSTOM_ENCHANT_GRADES_SYSTEM)
                        {
                            switch (item.getItem().getCrystalType())
                            {
                                case L2Item.CRYSTAL_S:
                                    maxEnchantLevel = Config.ENCHANT_MAX_S;
                                    break;
                                case L2Item.CRYSTAL_A:
                                    maxEnchantLevel = Config.ENCHANT_MAX_A;
                                    break;
                                case L2Item.CRYSTAL_B:
                                    maxEnchantLevel = Config.ENCHANT_MAX_B;
                                    break;
                                case L2Item.CRYSTAL_C:
                                    maxEnchantLevel = Config.ENCHANT_MAX_C;
                                    break;
                                case L2Item.CRYSTAL_D:
                                    maxEnchantLevel = Config.ENCHANT_MAX_D;
                                    break;
                            }
                        }
                        
                        if (!Config.CUSTOM_ENCHANT_GRADES_SYSTEM)
                        {
                            maxEnchantLevel = Config.ENCHANT_JEWELRY_MAX;
                            break;
                        }
                    }
                }
            }
            
        }
        
        if ((maxEnchantLevel != 0 && item.getEnchantLevel() >= maxEnchantLevel) || (item.getEnchantLevel()) < minEnchantLevel)
        {
            activeChar.sendPacket(new SystemMessage(SystemMessageId.INAPPROPRIATE_ENCHANT_CONDITION));
            return;
        }
        
        if (Config.SCROLL_STACKABLE)
        {
            scroll = activeChar.getInventory().destroyItem("Enchant", scroll.getObjectId(), 1, activeChar, item);
        }
        else
        {
            scroll = activeChar.getInventory().destroyItem("Enchant", scroll, activeChar, item);
        }
        
        if (scroll == null)
        {
            activeChar.sendPacket(new SystemMessage(SystemMessageId.NOT_ENOUGH_ITEMS));
            Util.handleIllegalPlayerAction(activeChar, "Player " + activeChar.getName() + " tried to enchant with a scroll he doesnt have", Config.DEFAULT_PUNISH);
            return;
        }
        
        if (item.getEnchantLevel() < Config.ENCHANT_SAFE_MAX || item.getItem().getBodyPart() == L2Item.SLOT_FULL_ARMOR && item.getEnchantLevel() < Config.ENCHANT_SAFE_MAX_FULL)
        {
            chance = 100;
        }
        
        int rndValue = Rnd.get(100);
        
        if (Config.ENABLE_DWARF_ENCHANT_BONUS && activeChar.getRace() == Race.dwarf)
        {
            if (activeChar.getLevel() >= Config.DWARF_ENCHANT_MIN_LEVEL)
            {
                rndValue -= Config.DWARF_ENCHANT_BONUS;
            }
        }
        
        Object aChance = item.fireEvent("calcEnchantChance", new Object[chance]);
        if (aChance != null)
        {
            chance = (Integer) aChance;
        }
        
        synchronized (item)
        {
            if (rndValue < chance)
            {
                if (item.getOwnerId() != activeChar.getObjectId())
                {
                    activeChar.sendPacket(new SystemMessage(SystemMessageId.INAPPROPRIATE_ENCHANT_CONDITION));
                    return;
                }
                
                if (item.getLocation() != L2ItemInstance.ItemLocation.INVENTORY && item.getLocation() != L2ItemInstance.ItemLocation.PAPERDOLL)
                {
                    activeChar.sendPacket(new SystemMessage(SystemMessageId.INAPPROPRIATE_ENCHANT_CONDITION));
                    return;
                }
                
                if (item.getEnchantLevel() == 0)
                {
                    sm = new SystemMessage(SystemMessageId.S1_SUCCESSFULLY_ENCHANTED);
                    sm.addItemName(item.getItemId());
                    activeChar.sendPacket(sm);
                }
                else
                {
                    sm = new SystemMessage(SystemMessageId.S1_S2_SUCCESSFULLY_ENCHANTED);
                    sm.addNumber(item.getEnchantLevel());
                    sm.addItemName(item.getItemId());
                    activeChar.sendPacket(sm);
                }
                
                item.setEnchantLevel(item.getEnchantLevel() + Config.CUSTOM_ENCHANT_VALUE);
                item.setEnchantLevel2(item.getEnchantLevel2() + Config.CUSTOM_DAY_ENCHANT_VALUE);
                item.setEnchantLevel3(item.getEnchantLevel3() + Config.CUSTOM_NIGHT_ENCHANT_VALUE);
                item.updateDatabase();
                
                if (activeChar.getAchievement().getCount(item.isWeapon() ? AchType.ENCHANT_WEAPON : AchType.ENCHANT_OTHER) < item.getEnchantLevel())
                {
                    activeChar.getAchievement().increase(item.isWeapon() ? AchType.ENCHANT_WEAPON : AchType.ENCHANT_OTHER, item.getEnchantLevel(), false, false);
                }
                
                activeChar.getAchievement().increase(AchType.ENCHANT_SUCCESS);
            }
            else
            {
                if (crystalScroll)
                {
                    sm = SystemMessage.sendString("Failed in Crystal Enchant. The enchant value of the item became: " + item.getEnchantLevel());
                    activeChar.sendPacket(sm);
                    activeChar.getAchievement().increase(AchType.ENCHANT_FAILED);
                }
                else if (blessedScroll)
                {
                    sm = new SystemMessage(SystemMessageId.BLESSED_ENCHANT_FAILED);
                    activeChar.sendPacket(sm);
                }
                else if (BrancaDayScroll)
                {
                    sm = SystemMessage.sendString("Failed in Custom Enchant. The enchant value of the item become " + Config.DONATOR_ENCHANT_AFTER_BREAK + ".");
                    activeChar.sendPacket(sm);
                }
                else if (BrancaNightScroll)
                {
                    sm = SystemMessage.sendString("Failed in Custom Enchant. The enchant value of the item become " + Config.DONATOR_ENCHANT_AFTER_BREAK + ".");
                    activeChar.sendPacket(sm);
                    
                    activeChar.getAchievement().increase(AchType.ENCHANT_FAILED);
                }
                else
                {
                    if (item.getEnchantLevel() > 0)
                    {
                        sm = new SystemMessage(SystemMessageId.ENCHANTMENT_FAILED_S1_S2_EVAPORATED);
                        sm.addNumber(item.getEnchantLevel());
                        sm.addItemName(item.getItemId());
                        activeChar.sendPacket(sm);
                    }
                    else
                    {
                        sm = new SystemMessage(SystemMessageId.ENCHANTMENT_FAILED_S1_EVAPORATED);
                        sm.addItemName(item.getItemId());
                        activeChar.sendPacket(sm);
                    }
                    activeChar.getAchievement().increase(AchType.ENCHANT_FAILED);
                }
                
                if (!blessedScroll && !crystalScroll && !BrancaDayScroll && !BrancaNightScroll)
                {
                    if (!Config.PROTECT_NORMAL_SCROLLS)
                    {
                        if (item.getEnchantLevel() > 0)
                        {
                            sm = new SystemMessage(SystemMessageId.EQUIPMENT_S1_S2_REMOVED);
                            sm.addNumber(item.getEnchantLevel());
                            sm.addItemName(item.getItemId());
                            activeChar.sendPacket(sm);
                        }
                        else
                        {
                            sm = new SystemMessage(SystemMessageId.S1_DISARMED);
                            sm.addItemName(item.getItemId());
                            activeChar.sendPacket(sm);
                        }
                        
                        if (item.isEquipped())
                        {
                            if (item.isAugmented())
                            {
                                item.getAugmentation().removeBoni(activeChar);
                            }
                            
                            L2ItemInstance[] unequiped = activeChar.getInventory().unEquipItemInSlotAndRecord(item.getEquipSlot());
                            
                            InventoryUpdate iu = new InventoryUpdate();
                            for (L2ItemInstance element : unequiped)
                            {
                                iu.addModifiedItem(element);
                            }
                            activeChar.sendPacket(iu);
                            
                            activeChar.broadcastUserInfo();
                        }
                        
                        int count = item.getCrystalCount() - (item.getItem().getCrystalCount() + 1) / 2;
                        if (count < 1)
                        {
                            count = 1;
                        }
                        
                        if (item.fireEvent("enchantFail", new Object[] {}) != null)
                        {
                            return;
                        }
                        
                        L2ItemInstance destroyItem = activeChar.getInventory().destroyItem("Enchant", item, activeChar, null);
                        if (destroyItem == null)
                        {
                            return;
                        }
                        
                        L2ItemInstance crystals = activeChar.getInventory().addItem("Enchant", crystalId, count, activeChar, destroyItem);
                        
                        sm = new SystemMessage(SystemMessageId.EARNED_S2_S1_S);
                        sm.addItemName(crystals.getItemId());
                        sm.addNumber(count);
                        activeChar.sendPacket(sm);
                        
                        if (!Config.FORCE_INVENTORY_UPDATE)
                        {
                            InventoryUpdate iu = new InventoryUpdate();
                            if (destroyItem.getCount() == 0)
                            {
                                iu.addRemovedItem(destroyItem);
                            }
                            else
                            {
                                iu.addModifiedItem(destroyItem);
                            }
                            iu.addItem(crystals);
                            activeChar.sendPacket(iu);
                        }
                        else
                        {
                            activeChar.sendPacket(new ItemList(activeChar, true));
                        }
                        
                        StatusUpdate su = new StatusUpdate(activeChar.getObjectId());
                        su.addAttribute(StatusUpdate.CUR_LOAD, activeChar.getCurrentLoad());
                        activeChar.sendPacket(su);
                        
                        activeChar.broadcastUserInfo();
                        
                        L2World world = L2World.getInstance();
                        world.removeObject(destroyItem);
                    }
                    else
                    {
                        item.setEnchantLevel(0);
                        item.updateDatabase();
                    }
                }
                else
                {
                    if (blessedScroll)
                    {
                        if (!Config.EXPLLOSIVE_CUSTOM)
                        {
                            item.setEnchantLevel(Config.BREAK_ENCHANT);
                            item.updateDatabase();
                        }
                        else
                        {
                            if (item.getEnchantLevel() >= 9)
                            {
                                item.setEnchantLevel(item.getEnchantLevel() - 5);
                            }
                            else
                            {
                                item.setEnchantLevel(4);
                            }
                            
                            item.updateDatabase();
                        }
                    }
                    else if (crystalScroll)
                    {
                        item.setEnchantLevel(item.getEnchantLevel());
                        item.updateDatabase();
                    }
                    else if (BrancaDayScroll)
                    {
                        item.setEnchantLevel2(Config.BREAK_ENCHANT);
                        item.updateDatabase();
                    }
                    else if (BrancaNightScroll)
                    {
                        item.setEnchantLevel3(Config.BREAK_ENCHANT);
                        item.updateDatabase();
                    }
                }
            }
        }
        
        StatusUpdate su = new StatusUpdate(activeChar.getObjectId());
        su.addAttribute(StatusUpdate.CUR_LOAD, activeChar.getCurrentLoad());
        activeChar.sendPacket(su);
        
        activeChar.sendPacket(new EnchantResult(item.getEnchantLevel()));
        activeChar.sendPacket(new ItemList(activeChar, false));
        activeChar.broadcastUserInfo();
    }
    
    private static void handleAugmentScrolls(L2PcInstance player, L2ItemInstance item, L2ItemInstance scroll)
    {
        // get scroll augment data
        L2AugmentScroll enchant = AugmentScrollData.getInstance().getScroll(scroll);
        if (enchant != null)
        {
            if (item.getItem().getType2() != L2Item.TYPE2_WEAPON)
            {
                player.sendMessage("This scroll can be used only on weapon.");
                player.setActiveEnchantItem(null);
                player.sendPacket(EnchantResult.CANCELLED);
                return;
            }
            
            if (item.getItem().getCrystalType() == L2Item.CRYSTAL_NONE || item.getItem().getCrystalType() == L2Item.CRYSTAL_D || item.getItem().getCrystalType() == L2Item.CRYSTAL_C)
            {
                player.sendMessage("You can't augment this grade item.");
                player.setActiveEnchantItem(null);
                player.sendPacket(EnchantResult.CANCELLED);
                return;
            }
            
            if (item.isHeroItem())
            {
                player.sendMessage("You can't augment hero item " + item.getItemName() + ".");
                player.setActiveEnchantItem(null);
                player.sendPacket(EnchantResult.CANCELLED);
                return;
            }
            
            if (item.isAugmented())
            {
                player.sendMessage("This item is already augmented.");
                player.setActiveEnchantItem(null);
                player.sendPacket(EnchantResult.CANCELLED);
                return;
            }
            
            if (item.getOwnerId() != player.getObjectId())
            {
                player.sendPacket(SystemMessageId.INAPPROPRIATE_ENCHANT_CONDITION);
                player.setActiveEnchantItem(null);
                player.sendPacket(EnchantResult.CANCELLED);
                return;
            }
            
            if (!player.destroyItemByItemId("", enchant.getAugmentScrollId(), 1, null, true))
            {
                return;
            }
            
            // unequip item
            if (item.isEquipped())
            {
                L2ItemInstance[] unequipped = player.getInventory().unEquipItemInSlotAndRecord(item.getLocationSlot());
                InventoryUpdate iu = new InventoryUpdate();
                
                for (L2ItemInstance itm : unequipped)
                {
                    iu.addModifiedItem(itm);
                }
                
                player.sendPacket(iu);
                player.broadcastUserInfo();
            }
            
            int skill = enchant.getAugmentSkillId();
            int level = enchant.getAugmentSkillLv();
            
            final L2Augmentation aug = AugmentationData.getInstance().generateAugmentationWithSkill(item, skill, level);
            item.setAugmentation(aug);
            
            InventoryUpdate iu = new InventoryUpdate();
            iu.addModifiedItem(item);
            player.sendPacket(iu);
            
            StatusUpdate su = new StatusUpdate(player.getObjectId());
            su.addAttribute(StatusUpdate.CUR_LOAD, player.getCurrentLoad());
            player.sendPacket(su);
            
            player.broadcastUserInfo();
            player.sendSkillList();
            player.setActiveEnchantItem(null);
            player.sendPacket(EnchantResult.CANCELLED);
            player.sendMessage("You successfully augmented the weapon.");
            player.sendPacket(new PlaySound("ItemSound3.sys_enchant_success"));
            return;
        }
    }
    
    @Override
    public String getType()
    {
        return "[C] 58 RequestEnchantItem";
    }
}
 

 

 

 

Edited by tensador27
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.



  • Posts

    • Painless Abortion Pills A b o r t i o n P i l l s NAME AND PRICE WhatsApp/call +971552965071 Cytotec Pills in Sharjah. Legal Abortion From 1-27 Weeks | Safe Abortion Pills For Sale +27632505360. CALL OR WHATSAPP US NOW : SCHONE  +27632505360 treatment at home Al Ain Al *Satwa* +971552965071_____________________Ajman MA +971552965071 *Price Abortion Pill* in Abu Dhabi *Satwa* ABORTION PILLS FOR SALE IN Dubai mifepristone cost In Ajman +27632505360 Abortion Pill99/Cytotec in Satwa JVC/ Al ain/ Ajman/ Ras Al Khaimah/ UAE mifepristone cost In Ajman Al Aziziyah +971552965071 ________ABORTION PILLS FOR SALE IN DUBAI ABORTION PILLS FOR SALE IN ABU DHABI ABORTION PILLS FOR SALE IN SHARJAH ABORTIaON In the Middle East countries such as UAE( Abu Dhabi, Dubai, Sharjah, Ajman, Umm Al-Quwain, and Fujairah), Kuwait, Qatar, etc., the laws and regulations are based on Islam. Islam forbids killing a life. Islam considers that an individual will have a life after he has attained a soul. It is believed that the fetus attains the soul after 120 days of fertilization. The four schools of thought: Hanafi, Shafi, Hanbali, and Maliki, have different views regarding the abortion of pregnancy. According to the Hanafi school, it is believed that the fetus attains the soul after 120 days of gestation. In contrast, the Maliki school believes that the fetus is ensouled at the point of conception, so abortion is not allowed at any stage of pregnancy. The Shafi school believes that the fetus is ensouled at 80 days, so abortion is only allowed until 80 days. The Hanbali school believes that the fetus attains the soul at 40 days. Some scholars believe that the child of rape is also legitimate, so it is a sin to kill a child. Pregnant mothers have to face a lot of difficulties if they want to abort their child. A woman cannot terminate an unplanned or unwanted pregnancy unless the health of the woman is in danger. The laws of the UAE permit abortion before 120 days of conception. Article 340 of the UAE Penal Code mentions that any woman who undergoes an abortion will be detained for a maximum of one year period and/or fine not exceeding ten thousand dirhams. Safe abortion methods for various stages of pregnancy: UAE Sharjah Dubai Abu Dhabi · Ajmān · Al Ain · Al Awdah · Al Fahlayn · Al Fulayyah · Al Fara' · Al Ghabah COD/ COP Call/WhatsApp+27632505360 ASAP 1. Early Pregnancy (Up to 9 Weeks): • Medical Abortion (Abortion Pill): A combination of medications, typically mifepristone followed by misoprostol, is used to induce a miscarriage. Mifepristone is taken at a healthcare provider's office, followed by misoprostol taken at home. This method is effective up to 9 weeks of pregnancy. • Aspiration (Suction) Abortion: A surgical procedure where a gentle suction is used to remove the pregnancy tissue from the uterus. This method is commonly used for pregnancies up to 9 weeks. 2. First Trimester (Up to 12 Weeks): • Medical Abortion: The abortion pill regimen may continue to be an option up to 12 weeks of pregnancy. • Aspiration Abortion: Suction abortion remains a safe and common method during the first trimester. 3. Second Trimester (13-24 Weeks): • Aspiration Abortion: Suction abortion may still be an option in the early second trimester, although the procedure may be slightly different from the first trimester. • Dilation and Evacuation (D&E): A surgical procedure where the cervix is dilated, and suction and medical instruments are used to remove the pregnancy tissue. This method is commonly used in the second trimester. 4. Late Second Trimester (After 24 Weeks): • Induction Abortion: In cases of medical necessity or severe fetal anomalies, an induction abortion may be considered. It involves inducing labor to deliver the fetus and pregnancy tissue. It's important to emphasize that abortion decisions are personal and medical in nature. A healthcare provider should be consulted to discuss the available options, risks, benefits, and considerations based on the specific circumstances of the individual. If you or someone you know is considering an abortion, seeking guidance from a qualified healthcare provider, gynecologist, or abortion clinic is crucial to ensure a safe and informed decision-making process.
    • Mtp-Kit Prices »Abu Dhabi Abortion Pills In Abu Dhabi,Dhabi/Alain/Sharjah/RAK city Dubai Al Quoz Muteena Al Nadha Al Khail Al Khan Al Warqa Al Ain Ajman Deira Sonapur Bur Dubai  Umm Al Quawain Al Qusisio Al Qusais Metro station Dubai Deira UAE Al Mafraq Abu Dhabi Jumeirah 1  Jumeirah Dubai Al satwa Dubai Jebel Ali Dubai Al Qusais Sports city Dubai Al Barsha Ogun State Downtown Dubai Arabian Ranches 2 Umm suqeim Al Barari Business Bay Dubai Dubai Marina Palm Jumeirah Al khabisi Ashare DIFC Al Safa Dubai Media CIty Al Qusais Metro station Dubai Deira UAE Al Mafraq Abu Dhabi Jumeirah 1  Jumeirah Dubai Al satwa Dubai Jebel Ali Dubai Al Qusais Sports city Dubai Al Barsha Ogun State Downtown Dubai Arabian Ranches 2 Umm suqeim Al Barari Business Bay Dubai Dubai Marina Palm Jumeirah Al khabisi Ashare DIFC Al Safa Dubai Media CIty  Legal Abortion From 1-27 Weeks | Safe Abortion Pills For Sale +27632505360. CALL OR WHATSAPP US NOW : SCHONE  +27632505360 treatment at home Al Ain Al *Satwa* +971552965071_____________________Ajman MA +971552965071 *Price Abortion Pill* in Abu Dhabi *Satwa* ABORTION PILLS FOR SALE IN Dubai mifepristone cost In Ajman +27632505360 Abortion Pill99/Cytotec in Satwa JVC/ Al ain/ Ajman/ Ras Al Khaimah/ UAE mifepristone cost In Ajman Al Aziziyah +971552965071 ________ABORTION PILLS FOR SALE IN DUBAI ABORTION PILLS FOR SALE IN ABU DHABI ABORTION PILLS FOR SALE IN SHARJAH ABORTIaON In the Middle East countries such as UAE( Abu Dhabi, Dubai, Sharjah, Ajman, Umm Al-Quwain, and Fujairah), Kuwait, Qatar, etc., the laws and regulations are based on Islam. Islam forbids killing a life. Islam considers that an individual will have a life after he has attained a soul. It is believed that the fetus attains the soul after 120 days of fertilization. The four schools of thought: Hanafi, Shafi, Hanbali, and Maliki, have different views regarding the abortion of pregnancy. According to the Hanafi school, it is believed that the fetus attains the soul after 120 days of gestation. In contrast, the Maliki school believes that the fetus is ensouled at the point of conception, so abortion is not allowed at any stage of pregnancy. The Shafi school believes that the fetus is ensouled at 80 days, so abortion is only allowed until 80 days. The Hanbali school believes that the fetus attains the soul at 40 days. Some scholars believe that the child of rape is also legitimate, so it is a sin to kill a child. Pregnant mothers have to face a lot of difficulties if they want to abort their child. A woman cannot terminate an unplanned or unwanted pregnancy unless the health of the woman is in danger. The laws of the UAE permit abortion before 120 days of conception. Article 340 of the UAE Penal Code mentions that any woman who undergoes an abortion will be detained for a maximum of one year period and/or fine not exceeding ten thousand dirhams. Safe abortion methods for various stages of pregnancy: UAE Sharjah Dubai Abu Dhabi · Ajmān · Al Ain · Al Awdah · Al Fahlayn · Al Fulayyah · Al Fara' · Al Ghabah COD/ COP Call/WhatsApp+27632505360 ASAP 1. Early Pregnancy (Up to 9 Weeks): • Medical Abortion (Abortion Pill): A combination of medications, typically mifepristone followed by misoprostol, is used to induce a miscarriage. Mifepristone is taken at a healthcare provider's office, followed by misoprostol taken at home. This method is effective up to 9 weeks of pregnancy. • Aspiration (Suction) Abortion: A surgical procedure where a gentle suction is used to remove the pregnancy tissue from the uterus. This method is commonly used for pregnancies up to 9 weeks. 2. First Trimester (Up to 12 Weeks): • Medical Abortion: The abortion pill regimen may continue to be an option up to 12 weeks of pregnancy. • Aspiration Abortion: Suction abortion remains a safe and common method during the first trimester. 3. Second Trimester (13-24 Weeks): • Aspiration Abortion: Suction abortion may still be an option in the early second trimester, although the procedure may be slightly different from the first trimester. • Dilation and Evacuation (D&E): A surgical procedure where the cervix is dilated, and suction and medical instruments are used to remove the pregnancy tissue. This method is commonly used in the second trimester. 4. Late Second Trimester (After 24 Weeks): • Induction Abortion: In cases of medical necessity or severe fetal anomalies, an induction abortion may be considered. It involves inducing labor to deliver the fetus and pregnancy tissue. It's important to emphasize that abortion decisions are personal and medical in nature. A healthcare provider should be consulted to discuss the available options, risks, benefits, and considerations based on the specific circumstances of the individual. If you or someone you know is considering an abortion, seeking guidance from a qualified healthcare provider, gynecologist, or abortion clinic is crucial to ensure a safe and informed decision-making process.
    • ( Al Twar)][@][( +971552965071 )][ Cytotec Pills in Sharjah, Abu Dhabi/Al ain Deira, Dubai Mall, Dubai Al Quoz Muteena Al Nadha  A 30% DISCOUNT ABORTION +27632505360 CLINIC IN SHARJAH, DUBAI, UAE // QATAR, DOHA, SAUDI ARABIA BAHRAIN, LEGAL & PAIN FREE // SAFE IN , KUWAIT, OMAN, MANAMA//+27632505360 v Al Nahda Women’s Clinic+27632505360 Medical abortion is a term applied to an abortion brought about by medication taken to induce it. This can be accomplished with a variety of medications given either as a single pill or a series of pills and it much safer than surgical abortions. Contact Us To Make An Appointment! On  Abortion pills RU486 (Mifepristone) and Cytotec (Misoprostol) came into use in the early 1990s. RU486 alone or with Cytotec give excellent results when used correctly. RU486 is available only in few countries. In Singapore, the HSA has not approved the use of RU486. Even Cytotec is not licensed for abortion. Studies have confirmed the use of Cytotec before standard abortion procedures have improved safety (that is, less complication) and reduced procedure discomfort. Injudicious use of Cytotec has however resulted in serious side effects to the pregnant women with few deaths reported. These women include those who have already given birth to three or more children, who have not passed their PSLE or have no secondary education, and who are non-Singaporean. Minimizing Abortion Complication Every surgical procedure has its complication. Abortion or termination of pregnancy is no exception. The reason to legalize abortion was to prevent the serious complications that a ccompany back-street abortions. Gynecologists receive extensive training surgery of the womb and when it is performed in the right set-up, the risk of the procedure is substantially reduced. Injury to Womb When TOP is performed, the neck of the womb has to be progressively dilated to a diameter that allows the smallest appropriate vacurette to be used. If the neck is dilated less than adequate, subsequent insertion of other instruments will be difficult and increased the risk the uterus being pierced through by the instruments. Perforating the uterus does no permanent harm to the uterus but additional steps have to be taken to ensure that other abdominal organs are not injured by the event. 
    • Legal Abortion From 1-27 Weeks | Safe Abortion Pills For Sale +27632505360. CALL OR WHATSAPP US NOW : SCHONE  +27632505360 treatment at home Al Ain Al *Satwa* +971552965071_____________________Ajman MA +971552965071 *Price Abortion Pill* in Abu Dhabi *Satwa* ABORTION PILLS FOR SALE IN Dubai mifepristone cost In Ajman +27632505360 Abortion Pill99/Cytotec in Satwa JVC/ Al ain/ Ajman/ Ras Al Khaimah/ UAE mifepristone cost In Ajman Al Aziziyah +971552965071 ________ABORTION PILLS FOR SALE IN DUBAI ABORTION PILLS FOR SALE IN ABU DHABI ABORTION PILLS FOR SALE IN SHARJAH ABORTIaON In the Middle East countries such as UAE( Abu Dhabi, Dubai, Sharjah, Ajman, Umm Al-Quwain, and Fujairah), Kuwait, Qatar, etc., the laws and regulations are based on Islam. Islam forbids killing a life. Islam considers that an individual will have a life after he has attained a soul. It is believed that the fetus attains the soul after 120 days of fertilization. The four schools of thought: Hanafi, Shafi, Hanbali, and Maliki, have different views regarding the abortion of pregnancy. According to the Hanafi school, it is believed that the fetus attains the soul after 120 days of gestation. In contrast, the Maliki school believes that the fetus is ensouled at the point of conception, so abortion is not allowed at any stage of pregnancy. The Shafi school believes that the fetus is ensouled at 80 days, so abortion is only allowed until 80 days. The Hanbali school believes that the fetus attains the soul at 40 days. Some scholars believe that the child of rape is also legitimate, so it is a sin to kill a child. Pregnant mothers have to face a lot of difficulties if they want to abort their child. A woman cannot terminate an unplanned or unwanted pregnancy unless the health of the woman is in danger. The laws of the UAE permit abortion before 120 days of conception. Article 340 of the UAE Penal Code mentions that any woman who undergoes an abortion will be detained for a maximum of one year period and/or fine not exceeding ten thousand dirhams. Safe abortion methods for various stages of pregnancy: UAE Sharjah Dubai Abu Dhabi · Ajmān · Al Ain · Al Awdah · Al Fahlayn · Al Fulayyah · Al Fara' · Al Ghabah COD/ COP Call/WhatsApp+27632505360 ASAP 1. Early Pregnancy (Up to 9 Weeks): • Medical Abortion (Abortion Pill): A combination of medications, typically mifepristone followed by misoprostol, is used to induce a miscarriage. Mifepristone is taken at a healthcare provider's office, followed by misoprostol taken at home. This method is effective up to 9 weeks of pregnancy. • Aspiration (Suction) Abortion: A surgical procedure where a gentle suction is used to remove the pregnancy tissue from the uterus. This method is commonly used for pregnancies up to 9 weeks. 2. First Trimester (Up to 12 Weeks): • Medical Abortion: The abortion pill regimen may continue to be an option up to 12 weeks of pregnancy. • Aspiration Abortion: Suction abortion remains a safe and common method during the first trimester. 3. Second Trimester (13-24 Weeks): • Aspiration Abortion: Suction abortion may still be an option in the early second trimester, although the procedure may be slightly different from the first trimester. • Dilation and Evacuation (D&E): A surgical procedure where the cervix is dilated, and suction and medical instruments are used to remove the pregnancy tissue. This method is commonly used in the second trimester. 4. Late Second Trimester (After 24 Weeks): • Induction Abortion: In cases of medical necessity or severe fetal anomalies, an induction abortion may be considered. It involves inducing labor to deliver the fetus and pregnancy tissue. It's important to emphasize that abortion decisions are personal and medical in nature. A healthcare provider should be consulted to discuss the available options, risks, benefits, and considerations based on the specific circumstances of the individual. If you or someone you know is considering an abortion, seeking guidance from a qualified healthcare provider, gynecologist, or abortion clinic is crucial to ensure a safe and informed decision-making process.
    • IN DUBAI ?W,A+971552965071//<<>? 𝙡𝙚𝙜𝙞𝙩 𝙖𝙣𝙙 𝙩𝙧𝙪𝙨𝙩𝙚𝙙 𝙨𝙚𝙡𝙡𝙚𝙧 • 24HRS 𝙝𝙞𝙜𝙝 𝙨𝙪𝙘𝙘𝙚𝙨𝙨 𝙧𝙖𝙩𝙚 𝙢𝙚𝙙𝙞𝙘𝙞𝙣𝙚𝙨 UAE OMAN,QATAR, BAHRAIN,SAUDI ARABIA,SHARJAH  A 30% DISCOUNT ABORTION +27632505360 CLINIC IN SHARJAH, DUBAI, UAE // QATAR, DOHA, SAUDI ARABIA BAHRAIN, LEGAL & PAIN FREE // SAFE IN , KUWAIT, OMAN, MANAMA//+27632505360 v Al Nahda Women’s Clinic+27632505360 Medical abortion is a term applied to an abortion brought about by medication taken to induce it. This can be accomplished with a variety of medications given either as a single pill or a series of pills and it much safer than surgical abortions. Contact Us To Make An Appointment! On +27632505360 Abortion pills RU486 (Mifepristone) and Cytotec (Misoprostol) came into use in the early 1990s. RU486 alone or with Cytotec give excellent results when used correctly. RU486 is available only in few countries. In Singapore, the HSA has not approved the use of RU486. Even Cytotec is not licensed for abortion. Studies have confirmed the use of Cytotec before standard abortion procedures have improved safety (that is, less complication) and reduced procedure discomfort. Injudicious use of Cytotec has however resulted in serious side effects to the pregnant women with few deaths reported. These women include those who have already given birth to three or more children, who have not passed their PSLE or have no secondary education, and who are non-Singaporean. Minimizing Abortion Complication Every surgical procedure has its complication. Abortion or termination of pregnancy is no exception. The reason to legalize abortion was to prevent the serious complications that a ccompany back-street abortions. Gynecologists receive extensive training surgery of the womb and when it is performed in the right set-up, the risk of the procedure is substantially reduced. Injury to Womb When TOP is performed, the neck of the womb has to be progressively dilated to a diameter that allows the smallest appropriate vacurette to be used. If the neck is dilated less than adequate, subsequent insertion of other instruments will be difficult and increased the risk the uterus being pierced through by the instruments. Perforating the uterus does no permanent harm to the uterus but additional steps have to be taken to ensure that other abdominal organs are not injured by the event. 
  • Topics

×
×
  • Create New...