Teardown-Issue-Tracker-Maintainers / Teardown-Issue-Tracker

A public repo for the community to track issues/bugs/feature requests in Teardown.
12 stars 5 forks source link

[Feature] Asset mods - exported content access #15

Closed RavMahov closed 2 years ago

RavMahov commented 3 years ago

Is your feature request related to a problem (if not, explain why you think this feature should be added)? Please describe. There are at least a couple of mods which contain assets (like vox models, prefabs, sometimes sounds). It's a waste of space and pain to copy prefabs (if there are any, as currently people are not motivated enough to pack prefabs into drop-in folders too) and keep them up to date with their workshop versions.

Describe the solution you'd like It would be nice to have another path variable, apart from LEVEL and MOD: EXTERNAL. This path variable would be used as follows (especially in editor): EXTERNAL/unique_mod_identifier/exported/prefab.xml where unique_mod_identifier would either be set in info.txt (preferably Java-like package name) or if from workshop, we already have mod id. This would hopefully limit the vox model spam in editor menu, and to reduce it slightly more, I propose .gitignore-like whitelist or actual ignore list (whitelist preferred, to force people to show actual things that should be exported, not export everything due to lack of knowledge). This way, mega prop pack can whitelist all the vox files (with notable exceptions of vehicle models, which are used in prefabs), and separately, prefabs.

Describe alternatives you've considered If gitignore-like whitelist/ignore list is too tough, each addon could instead use "exported" folder with hardcoded folder names like "vox", "prefab", "snd", "script", "img" (structure inside them is freeform though, so you can have as many categories as you require).

Additional context Prefab instances already support not finding a prefab. It would be perfect if the linked content appeared right after subscribing the addon, like a sort of "Set Bonus" in games. Additionally, workshop already supports "mod dependencies" so you could show which mods are required or at least recommended to use along with another mod, and probably even subscribe them directly.

elboydo commented 3 years ago

I'd quite support this notion. For access, having a global access could be good for spawning stuff in, like setting a mod to instance and it'd be accessible from any mod open to spawning.

Options for limiting that could be opening to enabled only prefabs.

My main potential challenges would be lazy naming/ renaming + scope, so "pickup" may have numerous instances that could make scripted spawning hard. To that perhaps making it folder based, with the following of PREFAB/ | MOD/ | LEVEL/ and hope no clashes occur.

That said, I honestly believe that we will never resolve clashing instance names, so perhaps a PREFAB/MOD/LEVEL listing, with targeted spawning for mod / prefab but accepting that singular PREFAB will hold clashes and instead be open to more generic spawning, like other games. To that end, perhaps opening up access to mods in PREFABS would be fine, but maybe needed dependency coding so if you want to script a vehicle from workshop then you need to use the workshop id?

Perhaps people with experience of implementing this structure would be great as i'm more closed case.

ghost commented 3 years ago

Teardown already has a hyperlink in-game to the Teardown workshop page under manage mods. I don't think it would be too difficult to read the steam workshop id for each mod.

MisterSirCode commented 3 years ago

The problem with this is compatibility... Say only 1 version of a prefab works for your mod, and they update it and it breaks your mod, then you have to go update your mod to accompany the changes. Also, if they break the model / delete it, or delete the mod itself from the workshop... then what? Youd be stuck in a rock in a hard place.

Personally, I think the current prefab system is perfect as is.

tuxedolabs commented 2 years ago

Instance spawning will to some extent solve this since you can spawn instances from other mods, but mod dependencies are generally not encouraged, so it probably won't be a built-in editor feature.