Sotho Tal Ker's BaseHat treasure fix (http://runuo.com/forums/showthread.php?t=76341).
Thanks to Carmina for submitting the patches.
This commit is contained in:
zippy 2006-11-14 02:43:42 +00:00
parent a2be513b24
commit f74af73c5a
4 changed files with 55 additions and 7 deletions

View file

@ -642,7 +642,23 @@ namespace Server.Items
DropItem( item ); DropItem( item );
} }
else if ( item is BaseJewel ) else if( item is BaseHat )
{
BaseHat hat = (BaseHat)item;
if( Core.AOS )
{
int attributeCount;
int min, max;
GetRandomAOSStats( out attributeCount, out min, out max );
BaseRunicTool.ApplyAttributesTo( hat, attributeCount, min, max );
}
DropItem( item );
}
else if( item is BaseJewel )
{ {
int attributeCount; int attributeCount;
int min, max; int min, max;

View file

@ -153,7 +153,23 @@ namespace Server.Items
DropItem( item ); DropItem( item );
} }
else if ( item is BaseJewel ) else if( item is BaseHat )
{
BaseHat hat = (BaseHat)item;
if( Core.AOS )
{
int attributeCount;
int min, max;
GetRandomAOSStats( out attributeCount, out min, out max );
BaseRunicTool.ApplyAttributesTo( hat, attributeCount, min, max );
}
DropItem( item );
}
else if( item is BaseJewel )
{ {
int attributeCount; int attributeCount;
int min, max; int min, max;

View file

@ -190,7 +190,23 @@ namespace Server.Items
cont.DropItem( item ); cont.DropItem( item );
} }
else if ( item is BaseJewel ) else if( item is BaseHat )
{
BaseHat hat = (BaseHat)item;
if( Core.AOS )
{
int attributeCount;
int min, max;
GetRandomAOSStats( out attributeCount, out min, out max );
BaseRunicTool.ApplyAttributesTo( hat, attributeCount, min, max );
}
cont.DropItem( item );
}
else if( item is BaseJewel )
{ {
int attributeCount; int attributeCount;
int min, max; int min, max;

View file

@ -104,7 +104,7 @@ namespace Server.Mobiles
private void DoCounter( Mobile attacker ) private void DoCounter( Mobile attacker )
{ {
if ( this.Map == null && attacker is BaseCreature && ((BaseCreature)attacker).BardProvoked ) if ( this.Map == null || ( attacker is BaseCreature && ((BaseCreature)attacker).BardProvoked ) )
return; return;
if ( 0.2 > Utility.RandomDouble() ) if ( 0.2 > Utility.RandomDouble() )