Fixes implicit ternary expressions
This commit is contained in:
parent
c85b0a740c
commit
ff26dfa375
345 changed files with 1905 additions and 2336 deletions
|
|
@ -58,7 +58,7 @@ namespace Server.SkillHandlers
|
|||
}
|
||||
|
||||
from.PlaySound( 0x241 );
|
||||
|
||||
|
||||
if ( from.CheckTargetSkill( SkillName.RemoveTrap, targ, targ.TrapPower, targ.TrapPower + 30 ) )
|
||||
{
|
||||
targ.TrapPower = 0;
|
||||
|
|
@ -76,7 +76,7 @@ namespace Server.SkillHandlers
|
|||
BaseFactionTrap trap = (BaseFactionTrap) targeted;
|
||||
Faction faction = Faction.Find( from );
|
||||
|
||||
FactionTrapRemovalKit kit = ( from.Backpack == null ? null : from.Backpack.FindItemByType( typeof( FactionTrapRemovalKit ) ) as FactionTrapRemovalKit );
|
||||
FactionTrapRemovalKit kit = @from.Backpack?.FindItemByType( typeof( FactionTrapRemovalKit ) ) as FactionTrapRemovalKit;
|
||||
|
||||
bool isOwner = ( trap.Placer == from || ( trap.Faction != null && trap.Faction.IsCommander( from ) ) );
|
||||
|
||||
|
|
@ -114,7 +114,7 @@ namespace Server.SkillHandlers
|
|||
}
|
||||
|
||||
if ( !isOwner )
|
||||
kit?.ConsumeCharge( @from );
|
||||
kit?.ConsumeCharge( from );
|
||||
}
|
||||
}
|
||||
else
|
||||
|
|
@ -124,4 +124,4 @@ namespace Server.SkillHandlers
|
|||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue