PDA

View Full Version : Issues about enabling extension with certain directory structure in ruleset



Ikael
July 19th, 2011, 21:02
I encountered (strange) behavior in extension loading with certain ruleset's directory structure. I have no idea if this is an issue or feature, but it prevents extensions from getting loaded up in the laucher. When ruleset is loading up an error is shown 'ERROR: Could not load included file xxx'. And the xxx file is always one from ruleset itself...

I made few test cases by creating different directory structure and moving 3 files in different levels:
Base.xml includes graphics.xml, which includes next file graphics_frames.xml. In addition there is one file in extension called updated_frames.xml and it's included inside extension.xml.

Test cases are shown below and the difference is that these three files are either inside one folder in ruleset's base directory or not (and extension's file is either inside extension base directory or inside one folder).



base.xml
------------------------------------------------------
<includefile source="graphics/graphics.xml" />

graphics/graphics.xml
------------------------------------------------------
<includefile source="graphics_frames.xml" />

extension.xml
------------------------------------------------------
<includefile source="graphics/updated_frames.xml" />

--> works




base.xml
------------------------------------------------------
<includefile source="graphics/graphics.xml" />

graphics/graphics.xml
------------------------------------------------------
<includefile source="graphics_frames.xml" />

extension.xml
------------------------------------------------------
<includefile source="updated_frames.xml" />

--> works


base.xml
------------------------------------------------------
<includefile source="graphics/graphics.xml" />

graphics/graphics.xml
------------------------------------------------------
<includefile source="graphics/graphics_frames.xml" />

extension.xml
------------------------------------------------------
<includefile source="updated_frames.xml" />

--> ERROR: Could not load included file (graphics_frames.xml)


base.xml
------------------------------------------------------
<includefile source="graphics/graphics.xml" />

graphics/graphics.xml
------------------------------------------------------
<includefile source="graphics/graphics_frames.xml" />

extension.xml
------------------------------------------------------
<includefile source="graphics/updated_frames.xml" />

--> ERROR: Could not load included file (graphics_frames.xml)


base.xml
------------------------------------------------------
<includefile source="graphics.xml" />

graphics.xml
------------------------------------------------------
<includefile source="graphics_frames.xml" />

extension.xml
------------------------------------------------------
<includefile source="graphics/updated_frames.xml" />

--> Works


base.xml
------------------------------------------------------
<includefile source="graphics.xml" />

graphics.xml
------------------------------------------------------
<includefile source="graphics/graphics_frames.xml" />

extension.xml
------------------------------------------------------
<includefile source="graphics/updated_frames.xml" />

--> Works

Anyone else experienced similar behavior? Is it a feature or a bug?

EDIT: I am using FGII v2.8 test release

Moon Wizard
July 20th, 2011, 10:00
This seems to be very similar to what is done with the dungeon theme for the 3.5E ruleset, so I'm not sure why there is a load error. I even use subdirectories in the 3.5E ruleset and dungeon theme in the same manner.

Can you send me an example of an extension for 3.5E or 4E that exhibits this issue? ([email protected])

Thanks,
JPG

Moon Wizard
July 20th, 2011, 23:16
The problem is in the updated_icons.xml file.

It uses includefile tags for both graphics_frames.xml and graphics_radial.xml, but these files are not provided in the extension. This means that FG will use the path defined in the includefile calls to look up these files in the ruleset PAK or folder.

In the cases where the errors are occurring, the includefile tag source values (in updated_icons.xml) do not match the locations of the files in the ruleset. Hence, the errors that you are seeing.

If you will be reusing files from the ruleset, you need to ensure that the includefile tags use the same path as the ruleset.

Regards,
JPG

Moebius
October 24th, 2011, 15:09
Hi GPG

I have downloaded the demo license version and when trying to open the demo campaign with the dungeon theme extension I get the same error. (Its asking for the portrait_graphics...)

So any user using the demo version is not able to use the extension, is this intended or a bug? Can it be fixed somehow?