Revert "fixes a bunch of warnings"

This reverts commit d4d85b663f.
This commit is contained in:
Paul
2021-12-20 15:20:27 +01:00
parent 7757b94333
commit 97e47178d7
68 changed files with 168 additions and 113 deletions

View File

@@ -10,10 +10,14 @@ namespace Content.Server.AI.Utility.Considerations.Combat.Melee
{
protected override float GetScore(Blackboard context)
{
return IoCManager.Resolve<IEntityManager>()
.HasComponent<MeleeWeaponComponent>(context.GetState<EquippedEntityState>().GetValue())
? 1.0f
: 0.0f;
var equipped = context.GetState<EquippedEntityState>().GetValue();
if (equipped == null)
{
return 0.0f;
}
return IoCManager.Resolve<IEntityManager>().HasComponent<MeleeWeaponComponent>(equipped) ? 1.0f : 0.0f;
}
}
}