PDA

View Full Version : Can't get modules to show up in library



Vishera
February 5th, 2016, 19:55
So I had a working module, I renamed it to .zip, unzipped it. I added a small section and then re-zipped/renamed to .mod and put it back in the folder using a different name (so I can differentiate the new one) and it doesn't show up. I tried restarting FG to no avail.

Trenloe
February 5th, 2016, 19:57
Most common issue is that the re-Zipping of the module is done from outside of the directory and not from within the directory. Enter the directory where the definition.xml, db.xml etc. files are, select all of those files (and any subdirectories) and ZIP from there.

Vishera
February 5th, 2016, 20:06
Trenloe, what would we do without you. I forgot when I Unzipped it, it went into it's own directory.. then I zipped that directory rather than the root files.. duuh.. thanks!

Zacchaeus
February 5th, 2016, 20:09
Trenloe, what would we do without you.

It would, indeed, be a poorer place.

Vishera
February 5th, 2016, 20:12
Well now it's at least trying to read it but I got an error

Database Error: A XML parse error occurred processing file 5E Players Handbook:common.xml - Error on line 25271: Error reading end tag.

line 25271 is the first line of my table. Can tables not read <b> and </b> syntaxes?

Vishera
February 5th, 2016, 20:23
oh I think I know what I did wrong.. I used <th> instead of <td>

Trenloe
February 5th, 2016, 20:25
Well now it's at least trying to read it but I got an error

Database Error: A XML parse error occurred processing file 5E Players Handbook:common.xml - Error on line 25271: Error reading end tag.

line 25271 is the first line of my table. Can tables not read <b> and </b> syntaxes?
It isn't even getting that far - this is a base XML issue, not an FG data issue (at this point). There is some tag that doesn't have a corresponding end tag within the XML structure. Opening in an editor that supports XML syntax checking might help identify the issue, or at least if there is still an XML syntax error. Notepad++ with the XML plugin can do this.

Vishera
February 5th, 2016, 20:28
k so I fixed that, but on another line its having trouble reading the /gunslinger tag at the end of the entry.. I'm at a loss

Vishera
February 5th, 2016, 20:53
do modules have to have the <root version="#.#"> tag? or would it run without declaring the root version?

Zacchaeus
February 5th, 2016, 21:00
I'm not an expert on such matters but every module db that I've looked at had a root thingie at the top.

Vishera
February 5th, 2016, 21:01
this is driving me nuts, all I did was add an entry to the PHB and now it wont work. I didn't change any of the existing tags or anything.

Trenloe
February 5th, 2016, 21:05
See the ruleset application compatibility section here: https://www.fantasygrounds.com/refdoc/ Modules don't *have* to have the version number, but it's probably a good idea to use the latest compatibility version number you have developed your module against (in this case, 3.0) just in case there might be some future module specific change in FG code that might rely on version compatibility.

Trenloe
February 5th, 2016, 21:06
this is driving me nuts, all I did was add an entry to the PHB and now it wont work. I didn't change any of the existing tags or anything.
PM me a link to your XML, I'll have a quick look.

Vishera
February 5th, 2016, 21:09
you want the entire module file? Pastebin?

Trenloe
February 5th, 2016, 21:11
you want the entire module file? Pastebin?
That would be best - so I can recreate your complete issue.

Vishera
February 5th, 2016, 21:14
I can't fit it all on pastebin. Ill upload the mod file to my dropbox and PM you the link

Trenloe
February 5th, 2016, 21:25
You accidentally deleted the </text> at the end of the formattedtext data in the gunslinger section.

Trenloe
February 5th, 2016, 21:28
The way I troubleshoot XML issues is to copy out the section that I've been working on into a blank file within Notepad++ (free - available here: https://notepad-plus-plus.org/) then use the XML plugin to check XML syntax. If the error is not obvious (if you're missing a close tag, the line number for the error may be different to where the error is) I remove sections at a time to try to isolate the text that is causing the issue.

Vishera
February 5th, 2016, 21:37
I am using notepad ++ (it loves to keep freezing up for a small 3mb file) and the XML tools are giving me different errors than FG. the XML tool in N++ says

XML Parsing Error at line 64389
Premature end of data in tag root line 3

Vishera
February 5th, 2016, 21:40
okay so after adding the </text> it loads without error gunslinger image wont load but not a huge deal..

Vishera
February 5th, 2016, 21:48
update: I moved the </text> tag to the end of the gunslinger entry and it works perfect, just cant get the image or link to show up but thats not a huge deal. thanks!

Trenloe
February 5th, 2016, 21:56
Your gunslinger image doesn't have a unique XML tag - it's using the same one as the IMP: <img_imp_jpg>

Vishera
February 5th, 2016, 22:30
Your gunslinger image doesn't have a unique XML tag - it's using the same one as the IMP: <img_imp_jpg>
I changed it to:

<img_gunslinger_jpg>
<locked type="number">1</locked>
<name type="string">Gunslinger</name>
<image type="image">
<bitmap type="string">images/Gunslinger.jpg</bitmap>
</image>
</img_gunslinger_jpg>
and it doesn't show

Trenloe
February 5th, 2016, 22:40
Have you looked in the Maps/Image campaign data list for the module? Because that where adding an image to the <image> section will appear.

If you want to see it somewhere else you'll need to reference it via an link to the image entry (in a formattedtext control) or add a librarylink entry for it to the <lists> - <imagewindow> section to show in the library.