More casting fixes

This commit is contained in:
Kamron Batman 2018-09-11 18:59:11 -07:00
parent f211efc3bd
commit 20a80ea2f3
40 changed files with 125 additions and 211 deletions

View file

@ -74,12 +74,10 @@ namespace Server.Mobiles
if ( m == this || !CanBeHarmful( m, false ) || ( Core.AOS && !InLOS( m ) ) )
continue;
if ( m is BaseCreature )
if ( m is BaseCreature bc )
{
BaseCreature bc = (BaseCreature)m;
if ( bc.Controlled || bc.Summoned || bc.Team != Team )
list.Add( m );
list.Add( bc );
}
else if ( m.Player )
{