Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Runtime AutoRules #47

Open
lhyqy5 opened this issue Apr 2, 2023 · 4 comments
Open

Runtime AutoRules #47

lhyqy5 opened this issue Apr 2, 2023 · 4 comments

Comments

@lhyqy5
Copy link

lhyqy5 commented Apr 2, 2023

I want to change the tileset at runtime, such as changing the grass to dirt, is there a way to automatically change the neighbor tileset according to the autorules? Or any function I can call to get neighbor tilesets definition from my current changed one.

@Cammin
Copy link
Owner

Cammin commented Apr 4, 2023

Currently, the importer does not calculate any rules, and builds tiles based on what LDtk puts together in the json's layer instances. Though it would be awesome for certain genres of games to have tiles that allow some kind of rules convention in runtime (ala destructible terrain games like Terraria), but it's a low priority for me at the moment. Not off the table though 🙂

@colinwilcox
Copy link

One of the loaders listed on the LDtk site is this C++ one that does exactly that. Very interesting.
https://github.com/AnomalousUnderdog/ldtkimport

@max-critcrew
Copy link

@colinwilcox Would it work to somehow manually combine this with LDtkToUnity? Have you or someone else tried this?
We absolutely want/need runtime editing for LDtk and are currently wondering how we'll do it! :)

@colinwilcox
Copy link

@max-critcrew I haven't tried it myself, in fact I've stopped using Unity, but I don't see why it couldn't be done. It only solves one part of the problem which is the rules application though, so you'd still have a lot of work to do to make your in-game editor complete.

@Cammin Cammin changed the title Is there a way to change the tileset at runtime and make autorules work Runtime AutoRules May 6, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants