jbhaywood / 5e-statblock-importer

A module for FoundryVTT that creates a new actor from any 5e monster or NPC statblock.
MIT License
18 stars 12 forks source link

Import Error #105

Open JPMeehan opened 5 months ago

JPMeehan commented 5 months ago

Not sure exactly where the error was, but this statblock caused an error

Nekrobold
Small Humanoid (Kobold), Any Non-Good Alignment
Armor Class 12 (15 with mage armor)
Hit Points 45 (10d6 + 10)
Speed 30 ft.
STR DEX CON INT WIS CHA
10 (+0) 14 (+2) 12 (+1) 18 (+4) 10 (+0) 12 (+1)
Saving Throws Int +6, Cha +3
Skills Arcana +6
Senses darkvision 60 ft., passive Perception 10
Languages Common, Draconic
CR 4 Artillery (1,100 XP) Proficiency Bonus +2
Been Busy. The nekrobold starts combat with mage armor cast on them
and with three nekrobold’s skeletons within 15 feet of them, under their
control.
Actions
Tainted Magic Missiles (2nd-Level Spell). The nekrobold creates four
shadowy darts of necrotic energy. Each dart hits a creature of their choice
that they can see within 120 feet. A dart deals 4 (1d4 + 2) necrotic damage
to its target. The darts all strike simultaneously, and they can direct them
to hit one target or several. An effect that negates the magic missile spell
also negates this spell.
Corrupted Charge. The nekrobold orders each skeleton under their control
to move up to double their movement speed and make a melee weapon
attack. If an attack hits, it deals an extra 5 (2d4) necrotic damage.
Detonate (1/Day). The nekrobold orders a skeleton under their control to
move up to their movement speed and detonate into a cloud of bone
fragments and necrotic energy. Each creature within 10 feet of that
skeleton must make a DC 14 Dexterity saving throw. A target takes 14
(4d6) piercing damage and 7 (2d6) necrotic damage on a failed save, or half
as much damage on a successful one. The skeleton dies.
Bonus Actions
Raise Skeleton. The nekrobold summons a nekrobold’s skeleton in an
unoccupied space with 15 feet. The nekrobold can only use this bonus
action if there are less than 3 nekrobold’s skeletons under their control.
JPMeehan commented 5 months ago

Just deleting lines at random, the issue appears to be "The skeleton dies."

Kirsham commented 4 months ago

I have encountered a similar issue when the statblock contains very short sentences. I believe the parser interprets short sentences followed by a period as the name of an action, bonus action or reaction, which in this case is not correct. You didn't provide any description of how the import failed, but for me what happened was that it would create a new action/bonus action/reaction with the short phrase as the name of the action, then try to fill in whatever comes next as the description of the action.

A simple workaround is to just add a random string of words to make the short phrase longer, then manually remove these after importing.