Skip to content

Commit

Permalink
More coverage
Browse files Browse the repository at this point in the history
  • Loading branch information
kupka committed Sep 30, 2024
1 parent ebbc660 commit ef14ea3
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions libsrd5/ogl/Monsters_B.cs
Original file line number Diff line number Diff line change
Expand Up @@ -94,8 +94,7 @@ public static Attack BeardedDevilBeard {
}
public static readonly AttackEffect BeardedDevilGlaiveEffect = delegate (Combattant attacker, Combattant target) {
// do not affect undead and constructs
if (target is Monster) {
Monster monster = (Monster)target;
if (target is Monster monster) {
if (monster.Type == Monsters.Type.UNDEAD || monster.Type == Monsters.Type.CONSTRUCT) return;
}
if (target.DC(BeardedDevilGlaive, 12, AbilityType.CONSTITUTION)) return;
Expand Down Expand Up @@ -151,8 +150,7 @@ public static Attack BlackDragonWyrmlingBite {
}
}
public static readonly AttackEffect BlackPuddingPseudopodEffect = delegate (Combattant attacker, Combattant target) {
if (target is CharacterSheet) {
CharacterSheet sheet = (CharacterSheet)target;
if (target is CharacterSheet sheet) {
Armor armor = sheet.Inventory.Armor;
// permanently reduce armor ac by 1 if armor isn't magical. armor is destroyed if reduced to 10 or below by this.
if (armor == null || armor.HasProperty(ArmorProperty.MAGIC)) return;
Expand Down

0 comments on commit ef14ea3

Please sign in to comment.