Sets a default parameter for OnHit. More casting cleanup.
This commit is contained in:
parent
74f498c1c8
commit
d6c0bf2d4c
96 changed files with 350 additions and 579 deletions
|
|
@ -199,9 +199,8 @@ namespace Server.Items
|
|||
{
|
||||
MessageHelper.SendLocalizedMessageTo( m_Bag, from, 1042544, 0x59 ); // This item is out of charges.
|
||||
}
|
||||
else if ( targeted is Item )
|
||||
else if ( targeted is Item item )
|
||||
{
|
||||
Item item = (Item)targeted;
|
||||
int reqCharges = (int)Math.Max( 1, Math.Ceiling( item.TotalWeight / 10.0 ) );
|
||||
|
||||
if ( !item.IsChildOf( from.Backpack ) )
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue