Skip to content
This repository has been archived by the owner on Aug 4, 2023. It is now read-only.

Files included with <Include> should not through "failed to get original file" error #164

Closed
jakobharder opened this issue Sep 13, 2022 · 3 comments

Comments

@jakobharder
Copy link
Contributor

A file included with <Include> is not meant to be applied to any original file on its own, hence the following error doesn't make sense in that case.

Failed to get original game file data\config\export\main\asset\assets-cheese.xml

@jakobharder
Copy link
Contributor Author

Options I currently see:

  • Recommend to name files as *.include to avoid the error. They would end up in the game file system, but are harmless.
  • Add e.g. *.include.xml as a filtered type
  • Pre-load all *.xml first, mark mentioned includes as not applicable and then do the real load. This one has additional complexity due to caching
  • Add an attribute to ModOps

My preference out of those is *.include.xml. Simple and fast. The attribute is not bad either.

@xforce
Copy link
Owner

xforce commented Sep 13, 2022

Doing *.include.xml is probably the best path here. That should be relatively simple and I don't see it ever clashing with game paths, so we could probably also just check whether the game path exists and give that a higher priority just in case, maybe.

xforce added a commit that referenced this issue Sep 17, 2022
`Include` is now relative to the root file
`*.include.xml` files are now excluded from Game Path lookup, this is the preferred name for included files
Proper support for 'nested' includes

Closes #113, Closes #164
@xforce
Copy link
Owner

xforce commented Sep 17, 2022

Fixed in 2b4bac3

@xforce xforce closed this as completed Sep 17, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants