TEdit / Terraria-Map-Editor

TEdit - Terraria Map Editor - TEdit is a stand alone, open source map editor for Terraria. It lets you edit maps just like (almost) paint! It also lets you change world settings (time, bosses downed etc), edit chests and change sign, make epic dungeons, castles, cities, and add rewards for your adventurers!
https://docs.binaryconstruct.com/
Other
1.57k stars 340 forks source link

[Extended Feature] Mod Support? #1075

Open BinaryConstruct opened 6 years ago

BinaryConstruct commented 6 years ago

This might be a big project, but here goes:

High Level Goals (to start):

Known Mod Loaders for planned support (and reference code/documentation)

Jofairden commented 6 years ago

Hi, TML dev here. For a start, it would be nice if it just 'supported' modded things. I guess this would namely include ModItem, ModTile, ModNPC.. etc. For actual mod data, you would have to learn a bit how it is setup if you haven't. What you could do is ask players for their TML files (.tplr, .twld) which contains mod data. You can open these up in NBTExplorer and take a look at the contents. (the mod data is stored as a Node-Binary-Tree) I think just supporting to see (read: not crash or malfunction) modded stuff would be a great start, actually editing might be another thing you could leave on the table for now. I am actually not sure how easy or hard it would be to render things, as the files are obviously not part of the main files. Probably one way would be to have users load the .tmod files during use, because they hold the resources.

BinaryConstruct commented 6 years ago

Thanks for the input. Are the .twld files used in conjunction with the regular .wld files or are they stand alone?

Jofairden commented 6 years ago

For TML, they are obviously both used. The .twld (same for .tplr) contains all the modded data. For example for a tile, it might have stored some 'state', which could for example alter how the tile appears (drawn) However, it wouldn't be required to load the .twld, except if you wouldn't you simply wouldn't have the mod data that was present. Often mods save quite a bit of stuff, so you'd want to try and always load them if possible. Sometimes mods save things badly, and can result in corrupted .twld or .tplr files, at that point you'd have to delete the files (or somehow manage to restore them) in order to play with that character or world. For your checklist, I'd vote these as a start:

ghost commented 2 years ago

Is this still planning to be looked at as a feature?

BinaryConstruct commented 2 years ago

Yes, however there are some major technical hurdles, such as each individual mod can change the way the world is loaded.