From 65198a79ac1cef40d2ad3da51879e701b3d8793c Mon Sep 17 00:00:00 2001 From: daedalus Date: Tue, 19 Jan 2010 13:45:00 +0000 Subject: [PATCH] - Pet resurrection gump fixed to work as OSI (http://www.uodemise.com/discussion/showthread.php?t=121055) - Every tamable pet with Poisoning skill can train Poisoning up to 100 skill (http://www.uodemise.com/discussion/showthread.php?t=134817) --- Scripts/Gumps/PetResurrectGump.cs | 10 +--------- Scripts/Items/Skill Items/Misc/Bandage.cs | 11 ++++++++++- Scripts/Mobiles/AI/Creature/BaseCreature.cs | 5 ++++- 3 files changed, 15 insertions(+), 11 deletions(-) diff --git a/Scripts/Gumps/PetResurrectGump.cs b/Scripts/Gumps/PetResurrectGump.cs index 0c874cf9c..717ea22a4 100644 --- a/Scripts/Gumps/PetResurrectGump.cs +++ b/Scripts/Gumps/PetResurrectGump.cs @@ -65,20 +65,12 @@ namespace Server.Gumps m_Pet.FixedEffect( 0x376A, 10, 16 ); m_Pet.ResurrectPet(); - double decreaseAmount; - - if( from == m_Pet.ControlMaster ) - decreaseAmount = 0.1; - else - decreaseAmount = 0.2; - for ( int i = 0; i < m_Pet.Skills.Length; ++i ) //Decrease all skills on pet. - m_Pet.Skills[i].Base -= decreaseAmount; + m_Pet.Skills[i].Base -= 0.2; if( !m_Pet.IsDeadPet && m_HitsScalar > 0 ) m_Pet.Hits = (int)(m_Pet.HitsMax * m_HitsScalar); } - } } } \ No newline at end of file diff --git a/Scripts/Items/Skill Items/Misc/Bandage.cs b/Scripts/Items/Skill Items/Misc/Bandage.cs index 96d60c16a..b41806910 100644 --- a/Scripts/Items/Skill Items/Misc/Bandage.cs +++ b/Scripts/Items/Skill Items/Misc/Bandage.cs @@ -244,7 +244,16 @@ namespace Server.Items { Mobile master = petPatient.ControlMaster; - if ( master != null && master.InRange( petPatient, 3 ) ) + if( master != null && m_Healer == master ) + { + petPatient.ResurrectPet(); + + for ( int i = 0; i < petPatient.Skills.Length; ++i ) + { + petPatient.Skills[i].Base -= 0.1; + } + } + else if ( master != null && master.InRange( petPatient, 3 ) ) { healerNumber = 503255; // You are able to resurrect the creature. diff --git a/Scripts/Mobiles/AI/Creature/BaseCreature.cs b/Scripts/Mobiles/AI/Creature/BaseCreature.cs index 6a6af53b6..7deb415f5 100644 --- a/Scripts/Mobiles/AI/Creature/BaseCreature.cs +++ b/Scripts/Mobiles/AI/Creature/BaseCreature.cs @@ -2623,8 +2623,11 @@ namespace Server.Mobiles if ( m_Paragon ) p = PoisonImpl.IncreaseLevel( p ); - if ( p != null && HitPoisonChance >= Utility.RandomDouble() ) + if ( p != null && HitPoisonChance >= Utility.RandomDouble() ) { defender.ApplyPoison( this, p ); + if ( this.Controlled ) + this.CheckSkill(SkillName.Poisoning, 0, this.Skills[SkillName.Poisoning].Cap); + } if( AutoDispel && defender is BaseCreature && ((BaseCreature)defender).IsDispellable && AutoDispelChance > Utility.RandomDouble() ) Dispel( defender );