Indie game storeFree gamesFun gamesHorror games
Game developmentAssetsComics
SalesBundles
Jobs
Tags

MPMB to FoundryVTT

Easily move your D&D characters to FoundryVTT · By BlackDragonBE

Errors when trying to import actor with dnd5e system 2.0.3

A topic by RJBPrimal created Mar 19, 2023 Views: 324 Replies: 16
Viewing posts 1 to 11
(1 edit)
  • Bug description: Upon import of exported file into FoundryVTT v10.291, getting an Uncaught (in promise) Error: undefined. I do have some custom content that I have coded in separate JS files, and they don't seem to cause an error in Acrobat upon their import, at least according to the MPMB sheet throwing an error upon import.
  • Application version: 1.1.1
  • PDF version: 13.1.4 - Colorful - A4
  • XFDF link: https://pastebin.com/eM0w4gFC
  • Log File link: https://pastebin.com/r6LPaF2i

Further investigation to this, importing from the app seems to be broken on the dnd5e system version 2.1.5, but works in 2.0.3. Seems like there were more breaking changes between dnd5e system versions 2.0.3 and 2.1.5. Can this be looked at?

Another bug report, not sure if you want it in this thread, just what I've collected today.

  • Bug description: Upon trying to convert a monk with access to SRD material only, the MPMB to FoundryVTT app throws an exception.
  • Application version: 1.1.1
  • PDF version: 13.1.4 - Printer Friendly - Redsign
  • XFDF link: https://pastebin.com/2Sd4t9Nb
  • MPMB 2 FoundryVTT Log File link: https://pastebin.com/4GBj1zgm

For the first issue: 

Looks like the dnd 5e system in FoundryVTT has been updated recently, with some breaking changes to its actor format. I can confirm character imports don't work with MBPMB to FoundryVTT 1.1.1 and dnd5e 2.1.5. I'll look into this, this might take some time depending on the severity of the changes.
As a workaround, use dnd5e 2.0.3 for now.

As for the second issue:

It seems one of the class features isn't formatted as expected:

  • Martial Arts (Monk 1, SRD 26) [1d4]
  • Unarmored Defense (Monk 1, SRD 26)
  • If I wear armor/shield, I lose Unarmored Defense, Martial Arts, and Unarmored Movement

The application expects the format FEATURE (CLASS CLASS_LEVEL, SOURCE SOURCE_PAGE) while the third class feature seems to be a custom one. I'll adjust the class feature logic so it's less strict about the format and can fall back on a simpler way of adding class features if needed. Expect a fix for this in v1.1.2.

I've successfully squashed the class feature bug. You can download the json for Tekken here: https://pastebin.com/gjcKtRHq

This fix will be included in v1.1.2.

I did some more testing with exports and it seems the changes the dnd 5e 2.1.5 were trivial. Even exports made by v1.1.1 of the converter work, even though they throw some errors in the console. 

I've updated the FoundryVTT template file the application uses, this seemed to have fixed the errors. I'll do some more testing before releasing v1.1.2, which should fix both issues mentioned here. 

I've tested an additional 10 characters, including the one you linked in the first post: Braiden 'Brey' Sparrow. The characters seem to be importing fine now. You can get the json for Braiden here: https://pastebin.com/UGnivaur

Keep a look out for v1.1.2, the application should inform you when it's online. I'll try to get it online today.

v1.1.2 is live! Let me know if that fixes your issues.

(1 edit)

Is there an option to select when exporting the JSON to change between 2.0.3 and 2.1.5? I'm still getting an Uncaught (in promise) Error: undefined. Actor5e Model Validation Errors when importing into 2.1.5.

  • Bug description: Upon import of exported file into FoundryVTT v10.291 with dnd5e system version 2.1.5, getting an Uncaught (in promise) Error: undefined. Actor5e Model Validation Errors.

Are you getting those errors after trying to import an actor? I can't reproduce it in my test world.
Can you create an empty world without modules for me and import the character in there? It might be a module issue, but I'm not sure at this point. I'll do some more testing.

(1 edit)

Similar error, as far as I can tell. Log is error @ pastebin.com. Has just the dnd5e version 2.1.5 game module enabled, nothing else, on a freshly created world.

I created a new world as well and I'm now able to reproduce the errors. Seems like the dnd5e system does something to new worlds that causes this. I'll look into it and do some more extensive testing. Once I've found a solution, I'll let you know and create a new release with a fix.

Cheers for that.

A quick update: I found the issue. 

The new version of the dnd5e system hasn't changed its format as far as I can tell, but it does a TON of checks now for missing and empty values which it didn't care about before. This means a lot of changes under the hood of the converter for just about all conversion stages.

I'll have to implement the fix in a few stages:

  1. Add lots of empty strings and null values all over the place as placeholders until the import in Foundry works for a single character.
  2. Create 10+ characters and test if the import works correctly while finetuning and rewriting parts of the converter

As this touches upon most of the converter code, it will take me a while to get the converter to a semi-stable state again and I have a feeling it will introduce some bugs here and there. I'll create a post to warn people not to update to 2.1.5 for now.

Importing the XFDF of the monk into an updated MPMB to FoundryVTT app works, and the 5 characters I exported work in dnd5e version 2.0.3, but not dnd5e version 2.1.5. So I can use that particular version for now until it's looked out.

The new 1.1.3 version of the application should fix all compatibility issues with the new dnd 5e system. Please let me know if it that resolves the issue.

I'll close this issue for now. Let me know if you want to reopen it if the issue still persists.

moved this topic to Issues (closed)