Adds shieldBonus to Monster entity.
Adds tests for shieldBonus.
This commit is contained in:
@@ -37,7 +37,6 @@ NS_ASSUME_NONNULL_BEGIN
|
||||
@property NSString *truesightDistance;
|
||||
@property NSString *understandsBut;
|
||||
|
||||
@property int shieldBonus;
|
||||
@property int naturalArmorBonus;
|
||||
@property int hitDice;
|
||||
@property int customProficiencyBonus;
|
||||
|
||||
@@ -27,7 +27,6 @@
|
||||
@synthesize hpText;
|
||||
@synthesize isBlind;
|
||||
@synthesize naturalArmorBonus;
|
||||
@synthesize shieldBonus;
|
||||
@synthesize speed;
|
||||
@synthesize swimSpeed;
|
||||
@synthesize telepathy;
|
||||
@@ -95,6 +94,10 @@
|
||||
if (tempNumber != nil && [tempNumber isKindOfClass:[NSNumber class]]) {
|
||||
self.charismaScore = tempNumber.intValue;
|
||||
}
|
||||
tempNumber = [jsonRoot objectForKey:@"shieldBonus"];
|
||||
if (tempNumber != nil && [tempNumber isKindOfClass:[NSNumber class]]) {
|
||||
self.shieldBonus = tempNumber.intValue;
|
||||
}
|
||||
|
||||
return self;
|
||||
}
|
||||
@@ -368,6 +371,7 @@
|
||||
self.charismaScore = monster.charismaScore;
|
||||
self.armorName = monster.armorName;
|
||||
self.otherArmorDescription = monster.otherArmorDescription;
|
||||
self.shieldBonus = monster.shieldBonus;
|
||||
}
|
||||
|
||||
@end
|
||||
|
||||
@@ -9,6 +9,7 @@
|
||||
<attribute name="intelligenceScore" optional="YES" attributeType="Integer 16" defaultValueString="0" usesScalarValueType="YES"/>
|
||||
<attribute name="name" attributeType="String" defaultValueString=""/>
|
||||
<attribute name="otherArmorDescription" optional="YES" attributeType="String" defaultValueString=""/>
|
||||
<attribute name="shieldBonus" optional="YES" attributeType="Integer 16" defaultValueString="0" usesScalarValueType="YES"/>
|
||||
<attribute name="size" attributeType="String" defaultValueString=""/>
|
||||
<attribute name="strengthScore" optional="YES" attributeType="Integer 16" defaultValueString="0" usesScalarValueType="YES"/>
|
||||
<attribute name="subtype" attributeType="String" defaultValueString=""/>
|
||||
@@ -16,6 +17,6 @@
|
||||
<attribute name="wisdomScore" optional="YES" attributeType="Integer 16" defaultValueString="0" usesScalarValueType="YES"/>
|
||||
</entity>
|
||||
<elements>
|
||||
<element name="Monster" positionX="-63" positionY="-18" width="128" height="238"/>
|
||||
<element name="Monster" positionX="-63" positionY="-18" width="128" height="253"/>
|
||||
</elements>
|
||||
</model>
|
||||
Reference in New Issue
Block a user