TileSetDefinition PreProcessor & added missing PreProcess invocations - #55
TileSetDefinition PreProcessor & added missing PreProcess invocations#55leohilbert wants to merge 9 commits into
Conversation
I haven't looked into the commit yet, but reading this, I'm concerned that this might create some additional performance overhead 😬
I might look into making a new field to LDtkPreprocessor so it has an asset import context just like the postprocessor; that way we can avoid an additional parameter |
Cammin
commented
May 25, 2024
I have a question: Could we have this merge request target a brand-new branch in your fork so I can test it out (and potentially make some minor tweaks) before merging? I'm new to pull requests, I'm not 100% sure how to test something that is targeting the master branch without actually merging it in. |
leohilbert
commented
May 27, 2024
Hi, thanks so much for looking into this! I don't know how often the Project/Tileset Def Jsons are parsed, but I don't think this one reflection call will take a lot of time. Doesn't hurt to check though of course! I also never worked with pullrequests from an external fork into the main repository. |
Cammin
commented
May 27, 2024
Cool, I'll give these a try when I get around to it, thanks for helping 👍 |
Cammin
commented
Dec 11, 2024
Reviewing this again, it seems good. But I still need to get around to cloning your branch and playing with it. I ought to make it my mission soon |
leohilbert
commented
Dec 12, 2024
all good, the workflow of just merging your latest release into this fork and then merging it into my project works fine for me as well :) |
Cammin
commented
May 9, 2026
I appreciate your work here; I somewhat feel like I should rewark how my postprocess works under the hood because it's been hard for me to keep track of how it works when looking back at it haha |
Hi!
Based on our conversation in discord, I spent some time adding a TilesetDefinition PreProcessor and integrating it into my project, to finally replace my custom PreProcessor that I needed to patch in after every update.
While integrating I noticed that the PreProcessors for Level & Project were not always invoked after reading the JSON. This resulted in my adjustments not being executed everywhere (e.g. in the JsonEditorCache). I think the easiest and safest bet is to just always execute it directly after a Level-, Project- or TilesetDefinition-Json is parsed.
I also needed to add the AssetPath of the parsed Json, because I need it :|
Let me know what you think :)