RunUO Community

This is a sample guest message. Register a free account today to become a member! Once signed in, you'll be able to participate on this site by adding your own topics and posts, as well as connect with other members through your own private inbox!

Resource icon

[2.x] Imbuing [RunUO 2.3] v1.0

No permission to download

Dreamseeker

Sorceror
Optional Files (Overwrite/Merge)
Fishing.cs/Lumberjacking.cs/Mining.cs - Adds harvestable Imbuing resources
ReproductionGump.cs - Small change to allow Plants to give Seeds of Renewal when harvesting seeds from a Plant (1 in 10) - Original file located in "Scripts\Engines\Plants"
BaseCreature.cs - Added Essence drops to Creatures, the Essence type dropped depends on Creature type (i.e -
Daemon types drop [Essence of Achievement] or [Essence of Passion])
 

Attachments

  • Imbuing_ ReadMe.txt
    3.5 KB · Views: 121

Erevan

Sorceror
Is there a reason itemID requires a minimum of 100 skill to identify the potential ingredients? Users should still be able to identify "lesser" ingredients as they level their itemID skill.

You may want to remove references to SF Fishing from Playermobile, just to avoid "what is this?" responses. Although it looks intriguing based on the word "bait".

Also, line 618 Imbuing.cs needs to have a cliloc update. When imbuing a Blessed item, it currently returns a message about "Ninjitsu focus ability". The correct cliloc is 1080438.
 

JEEG84

Sorceror
Hi Dreamseeker, i have tested your Imbuing system and i see an Excellent Work on It !

I have only one little Problem :

If i have a Weapon with "Hit Mana Leech" and i want add "Hit Life Leech" with Imbuing, Hit Mana Leech was Replaced by Hit Life Leech and i cannot have both Props on item with Imbuing.

There is some Bug on your Imbuing System or this is Right ?? Plz Tell Me if you want

Thanks You Great Job !
 

Dreamseeker

Sorceror
I'm afraid it's correct .. There can be only one type of Leech property, same goes for the On Hit groups and some other prop types. I've stuck as close to OSI standards as I could.

if you wanna modify what replaces what, look up lines such as this in the // == Add Attribute == section of - ImbuingC.cs
Code:
if (i_Mod == 26)
{
  it.WeaponAttributes.HitLeechStam = modvalue;
  it.WeaponAttributes.HitLeechHits = 0;
  it.WeaponAttributes.HitLeechMana = 0;
}
and remove the HitLeechHits and HitLeechMana lines to add the property without removing the others.. however without large edits to the script, it wouldn't take account of the other Leeches already imbued when imbuing another Leech prop which would normally be overwritten.. In effect making it possible to imbue more than 5 properties.
 

Dreamseeker

Sorceror
Is there a reason itemID requires a minimum of 100 skill to identify the potential ingredients? Users should still be able to identify "lesser" ingredients as they level their itemID skill.

I might be wrong, but I'm pretty sure it's the Imbuing skill that determines what Ingredient can be unravelled, as it becomes possible to unravel that type of Ingredient, you can identify it also.

- Thx for spotting the Fishing bit.. It must have slipped through, hopefully it doesn't cause any problems (It's for an OSI Rare/Legendary Fish System Clone I made .. might post that up at some point)
- And for finding the dodgy Cliloc too :D


<- Uploaded Imbuing.cs with fixed Cliloc
 

Attachments

  • Imbuing.cs
    52.4 KB · Views: 46

knoxrub

Squire
This imbuing release is very good compared to the original Orb and RunUO versions in the past, it fixes a lot of the exploits and bugs.
Thank you for an excellent system, however I have come across some issues with the functionality.

Issue 1: Around line 1627 you need to add if (i_Mod == 49) { it.ArmorAttributes.MageArmor = 1; }
and may have to add a couple lines for the weight and mod count for mage armor in the base armor section.

Issue 2: The weight on certain mods aren't being calculated correctly. The gump display on the top left corner is all correct
for example 1.0x through 1.5x every mod is correct (except mana leech). But the calculated display weight i_TpropW isn't correct on many mods.
* The fix for this is in ImbuingC.cs line 173 or so double cur_wei = (s_Weight / m_Imax) * m.Imbue_ModInt;
you have to change that formula to double cur_wei = c_i * (c_w / 100);

Issue 3: The formula that determines success chance is way off, I don't have exact figures for you because I changed the formula already.
But its easy enough to test!

Other than that it works great!
 

pileccorp

Sorceror
 
i just downloaded this and put it in from the rar. are all these fixes in the rar, or should i download them and replace? i ignored the fishing thing when merging my files already
 

knoxrub

Squire
Alienza, I can post mine, but you may have to remove some things. I made it so on a failure to imbue, you have a 30% chance to break and unravel that item, you get rewarded the unraveled components. In mine you can imbue 2 hitspells, like fireball and lightning for example. I didn't limit how many hit areas, hit leeches etc. I think my changes would confuse a lot of people so I'll just tell you how to make the success chance work. This formula will work even if you have up to a 10 property count max instead of the default 5.

In ImbuingC.cs around line 194

Code:
// ===== CALCULATE DIFFICULTY =====
            i_Diff = 0;    // = Actual difficulty
            i_Success = 0; // = Display difficulty
          
            double iBonus = 0;
           if (m.Race == Race.Gargoyle) { iBonus += 0; }
            if (m.Race == Race.Human) { iBonus -= 5; }
            if (m.Race == Race.Elf) { iBonus -= 5; }
            if (m.Imb_SFBonus > 0)
                iBonus += 5;
 
            double knoxrub = i_TpropW + cur_wei;
            if (knoxrub > 500)
            {
                i_Diff = ((((i_TpropW + cur_wei) - 500) / 75) * (1)) + (((i_TpropW + cur_wei) - 500) / 64);
                i_Success = (m.Skills[SkillName.Imbuing].Base - (i_Diff + 64)) * 1;
                i_Success = i_Success + iBonus;
                if (i_Success < 0) { i_Success = 0; }
            }
            if (knoxrub <= 500)
            {
                i_Diff = (((i_TpropW + cur_wei) / 22) * (1)) + ((i_TpropW + cur_wei) / 21);
                i_Success = (m.Skills[SkillName.Imbuing].Base - (i_Diff + 17)) * 1;
                i_Success = i_Success + iBonus;
                if (i_Success < 0) { i_Success = 0; }
            }
          
            i_Success = Math.Round(i_Success, 2);
 
            double Succ = i_Success;


Then down on line 1374 or so.

Code:
 // ===== CALCULATE DIFFICULTY =====
                bool m_Success = false;
                i_Diff = 0;    // = Actual difficulty
                i_Success = 0; // = Display difficulty
 
                double iBonus = 0;
                if (m.Race == Race.Gargoyle) { iBonus += 0; }
                if (m.Race == Race.Human) { iBonus -= 5; }
                if (m.Race == Race.Elf) { iBonus -= 5; }
                if (m.Imb_SFBonus > 0)
                iBonus += 5;
 
                double knoxrub = i_TpropW + cur_wei;
                if (knoxrub > 500)
                {
                    i_Diff = ((((i_TpropW + cur_wei) - 500) / 75) * (1)) + (((i_TpropW + cur_wei) - 500) / 64);
                    i_Success = (pm.Skills[SkillName.Imbuing].Base - (i_Diff + 64)) * 1;
                    i_Success = i_Success + iBonus;
                    if (i_Success < 0) { i_Success = 0; }
                }
                if (knoxrub <= 500)
                {
                    i_Diff = (((i_TpropW + cur_wei) / 22) * (1)) + ((i_TpropW + cur_wei) / 21);
                    i_Success = (pm.Skills[SkillName.Imbuing].Base - (i_Diff + 17)) * 1;
                    i_Success = i_Success + iBonus;
                    if (i_Success < 0) { i_Success = 0; }
                }
   
                if (i_Success <= 0) { m_Success = false; }
                else if (i_Success >= 100) { m_Success = true; }
                else if (i_Success >= 95)
                {
                    if (0.95 >= Utility.RandomDouble()) { m_Success = true; }
 
                }
                else if (i_Success >= 90)
                {
                    if (0.90 >= Utility.RandomDouble()) { m_Success = true; }
 
                }
                else if (i_Success >= 85)
                {
                    if (0.85 >= Utility.RandomDouble()) { m_Success = true; }
 
                }
                else if (i_Success >= 80)
                {
                    if (0.80 >= Utility.RandomDouble()) { m_Success = true; }
 
                }
                else if (i_Success >= 75)
                {
                    if (0.75 >= Utility.RandomDouble()) { m_Success = true; }
 
                }
                else if (i_Success >= 70)
                {
                    if (0.70 >= Utility.RandomDouble()) { m_Success = true; }
 
                }
                else if (i_Success >= 65)
                {
                    if (0.65 >= Utility.RandomDouble()) { m_Success = true; }
 
                }
                else if (i_Success >= 60)
                {
                    if (0.60 >= Utility.RandomDouble()) { m_Success = true; }
 
                }
                else if (i_Success >= 55)
                {
                    if (0.55 >= Utility.RandomDouble()) { m_Success = true; }
 
                }
                else if (i_Success >= 50)
                {
                    if (0.50 >= Utility.RandomDouble()) { m_Success = true; }
 
                }
                else if (i_Success >= 45)
                {
                    if (0.45 >= Utility.RandomDouble()) { m_Success = true; }
 
                }
                else if (i_Success >= 40)
                {
                    if (0.40 >= Utility.RandomDouble()) { m_Success = true; }
 
                }
                else if (i_Success >= 35)
                {
                    if (0.35 >= Utility.RandomDouble()) { m_Success = true; }
 
                }
                else if (i_Success >= 30)
                {
                    if (0.30 >= Utility.RandomDouble()) { m_Success = true; }
 
                }
                else if (i_Success >= 25)
                {
                    if (0.25 >= Utility.RandomDouble()) { m_Success = true; }
 
                }
                else if (i_Success >= 20)
                {
                    if (0.20 >= Utility.RandomDouble()) { m_Success = true; }
 
                }
                else if (i_Success >= 15)
                {
                    if (0.15 >= Utility.RandomDouble()) { m_Success = true; }
 
                }
                else if (i_Success >= 10)
                {
                    if (0.10 >= Utility.RandomDouble()) { m_Success = true; }
 
                }
                else if (i_Success >= 5)
                {
                    if (0.05 >= Utility.RandomDouble()) { m_Success = true; }
 
                }
                else if (i_Success > 0)
                {
                    if (0.01 >= Utility.RandomDouble()) { m_Success = true; }
 
                }
                else
                { m_Success = false; }
 
 
                // = SUCCESS - Item is Imbued =
 

knoxrub

Squire
Yes I use it. In playermobile around line 3210 replace the SF imbuing region with this.
Code:
        #region SF Imbuing
        private object m_Imbue_Item;
        private int m_Imbue_Iref, m_Imbue_Mod, m_Imbue_ModInt, m_Imbue_ModVal;
        private int m_Imbue_IWmax, m_Imb_SFBonus, m_ImbMenu_Cat, m_ImbMenu_ModInc;
 
        public object Imbue_Item { get { return m_Imbue_Item; } set { m_Imbue_Item = value; InvalidateProperties(); } }
        public int Imbue_Mod { get { return m_Imbue_Mod; } set { m_Imbue_Mod = value; InvalidateProperties(); } }
        public int Imbue_ModInt { get { return m_Imbue_ModInt; } set { m_Imbue_ModInt = value; InvalidateProperties(); } }
        public int Imbue_ModVal { get { return m_Imbue_ModVal; } set { m_Imbue_ModVal = value; InvalidateProperties(); } }
        public int Imbue_SFBonus { get { return m_Imb_SFBonus; } set { m_Imb_SFBonus = value; InvalidateProperties(); } }
        public int ImbMenu_Cat { get { return m_ImbMenu_Cat; } set { m_ImbMenu_Cat = value; InvalidateProperties(); } }
        public int ImbMenu_ModInc { get { return m_ImbMenu_ModInc; } set { m_ImbMenu_ModInc = value; InvalidateProperties(); } }
        public int Imbue_IWmax { get { return m_Imbue_IWmax; } set { m_Imbue_IWmax = value; InvalidateProperties(); } }
        #endregion
 
PileCorp..


This is because he posted his playermobile with other customs that you probably don't have. Looks like the only thing you need to add is the Imbuing specific parts of his playermobile.
Beyond Compare is great for doing that easily.



Hope that helps you.
 

Dian

Sorceror
It looks like you are missing some scripts. I think you need the ML (Mondains Legacy) package for the imbuing to work. The ML package contains the BaseQuest and I believe the other files that are listed in your error log.

Or you are using a playermobile file that is setup for the ML package..
 

magikato

Squire
It looks like you are missing some scripts. I think you need the ML (Mondains Legacy) package for the imbuing to work. The ML package contains the BaseQuest and I believe the other files that are listed in your error log.

Or you are using a playermobile file that is setup for the ML package..
first off Thank you for you prompt reply Both of you ,im using the playermobile that came with the imbuing dl and removed the old playermobile script to a holding file and what ml package are you talking about where can i dl it Thank you
 
Top