0ADMods / terra_magna

Terra Magna - an 0 A.D. extension.
http://www.wildfiregames.com/forum
GNU General Public License v2.0
29 stars 17 forks source link

HanChina-standalone? #62

Closed udeved closed 4 years ago

udeved commented 6 years ago

Hello,

I have read on the 0ad forum a discussion if civ mods should be split out to single git repos. I did that for HanChina, I could simply push it and transfer ownership of the repo to OadMods org if you are interested. I find the idea nice to have modular civs each in its own git repo, I think it has lot of good reasons to do that.

PS : https://en.wikipedia.org/wiki/Sino-Roman_relations

even though wikipedia is not a good source, it gives a small idea that ancient world wasn't as small as we think it was.

tomasmatys commented 6 years ago

yes, you could do that if ever we will include Han Chinese into the main distribution it would be needed indeed. But @StanleySweet @niektb @AlexanderVzla @wackyserious what are your opinions on this? @udeved Btw also feel free to look at other tasks listed in issues in each mod if you are interested we definitely need more helpers (we also have other interesting repositories to look at).

StanleySweet commented 6 years ago

If you already did the work, I don't see a reason not to use it. There is one issue with one mod per faction. It causes fragmentation, and require more maintenance on our end to update, publish and release announcements.

udeved commented 6 years ago

@tomasmatys

I am afraid, I am so fully busy with our artix linux distribution, modding a little usually comes when I play a quick game for fun. We are also short and always in need for devs. ;)

Regarding self contained civ mods, I find it very manageable in terms of version control and to keep track what files a mod brings with it, instead of a big git repo with tons of stuff. git repos tend to drastically grow in size with art related files.

@StanleySweet

You could cure the fragmentation in so far as to use git-subrepo eventually, which is better than git subtree or terrible git submodules. You can sort of emulate svn branch behavior with it.

Its just my view, but working in dedicated repos should give additional focus for releases, open tasks, ToDos etc... and you can direct manpower where its needed in terms of civs maintaining it brings one civ a a time that can be tested without much other changes to the game like the bigger mods do.

StanleySweet commented 6 years ago

I wasn't talking about git fragmentation. I was talking about mod fragmentation. It's fine as long as you only play single player, but when you want to play multiplayer with friends, you have to make sure they have the same mods as you do, loaded in the same order. For two mods it's easy, but when a single mod has 10+ mods, it gets harder to download and load.

Also, for each mod release, for performance, and download size reasons, I have to package mods, (convert textures to DDS, and the XML to XMB) and that's a long process, even though it's automated. Then you have to check that nothing broke and repackage with fixes if it did :)

udeved commented 6 years ago

@StanleySweet

Wouldn't standalone civ mods reduce size of the mods anyway?

In my naivety without having looked at the engine, network component or modio support, couldn't a logic simply check on modio for mod parity for multiplayer? Check mod.json files in essence and compare versions?

StanleySweet commented 6 years ago

Wouldn't standalone civ mods reduce size of the mods anyway?

Indeed, but it would also make the packaging process longer for the mod developers.

In my naivety without having looked at the engine, network component or modio support, couldn't a logic simply check on modio for mod parity for multiplayer? Check mod.json files in essence and compare versions?

That's already the case, but you have to reload the game each time to reload mods. So you wouldn't be able to join, and that would be an issue, because most people wouldn't understand what's going on, and end up disabling all mods...

udeved commented 6 years ago

Couldn't you make the default civs not selectable in the mod box if they were standalone, just filter them away? Say predefined civs that are standalone, but can't be enabled or disabled. I just think that community contributions would profit from such setup, especially if you are as we are short in manpower and eyes community contributions.

StanleySweet commented 6 years ago

To get the civilization added to the civilization list, you have to download and enable the mod. We can't add them to the main game, and expect people to have them. People want to be able to use the civilization they want, so we would be butchering the multiplayer, by restricting mods on the platform don't you think ? Also it requires a fair amount of changes upstream, and development is currently frozen. Not to mention there is nobody to code that :) If mods like Delenda_est do no use dependencies on terra_magna, that's on them :)

udeved commented 6 years ago

You misunderstood, I was more thinking loud. I was more talking about have all vanilla civs self contained in a mod, so the core engine provides only shared data. It would not change much in the mechanics for multiplayer or so, you would just have to filter them away in the mod selection. My idea was to reduce the giant public mod in size, split out the civs. It would then be a matter of defining a json file or so with vanilla civs the game provides.

StanleySweet commented 6 years ago

I plan to move out the main game civs to a mod folder either called 0AD or empires_ascendant, and leave the terrain textures maps etc out of it.

udeved commented 6 years ago

@StanleySweet

dunno how much changes it would take in how mods are loaded, but have you thought about making it even more modular? each civ its own mod, ie *.zip file?

StanleySweet commented 6 years ago

Mods are loaded as a virtual folder, so all the files are treated as the same folder, the latest mod loaded overwriting all the previous mods containing files with the same names.

If I create one mod per civilization, I will have a dependency hell because they reuse the same resources, some have the same buildings etc. Then people disabling civs won't be able to play without errors, and that's the same issue for multiplayer.

udeved commented 6 years ago

Thats why I thought that if it was modular, the vanilla civs should not show as a selectable mod. anyway, I don't want to steal your time.

as it stands, the HanChina mod is uncompress about 144MB currently, and I am sure it can be further reduced, some dds and dae files and icons can likely be deleted. If I push this in a new repo, do you prefer i don't add any artwork to be readded or whatever? Ie just data, maps etc?

StanleySweet commented 6 years ago

Thats why I thought that if it was modular, the vanilla civs should not show as a selectable mod. anyway, I don't want to steal your time.

That's what's done for the base mod :) I'm not sure I get the reason of doing that for the Vanilla in that case. Official team members wouldn't gain time of having thirteen folders with the same tree. Or did I miss something ?

as it stands, the HanChina mod is uncompress about 144MB currently, and I am sure it can be further reduced, some dds and dae files and icons can likely be deleted. If I push this in a new repo, do you prefer i don't add any artwork to be readded or whatever? Ie just data, maps etc?

It's up to you. There is a script which tweaked correctly might tell you what files are unused. It's in the game's source/tools/ folder and called checkrefs.pl.

udeved commented 6 years ago

Alright, 121 MB, I removed rice, willow and cherry tree plus the defunct scenarios that use them.

https://github.com/udeved/HanChina

@StanleySweet

Reason would be small dedicated work on one faction, effectively, the game would treat vanilla civs the same as any additional mod civ by community, just that the vanilla civs would not be selectable in mod box. My thought would be to create a json file than actually just contains the civ IDs and names whatever to be vanilla.

StanleySweet commented 6 years ago

Reason would be small dedicated work on one faction, effectively, the game would treat vanilla civs the same as any additional mod civ by community, just that the vanilla civs would not be selectable in mod box. My thought would be to create a json file than actually just contains the civ IDs and names whatever to be vanilla.

There is already such a file it's called chin.json, athen.json etc :)

But having them seperated in vanilla makes it harder to manage, you have to create new folder, a higher risk of files not being consistent because each folder is different. It might be easier to find files, but we already have prefixes for that.

udeved commented 6 years ago

Two small questions @StanleySweet

In terra magna, there are helmet props, and a helmet/new folder. Do you know of the dae files are equal? They exist in standard helmets as well.

Regarding music, is there license issues to include the two ogg files defined in chin.json?

udeved commented 6 years ago

There is already such a file it's called chin.json, athen.json etc :)

Right, but any additional mod installs the json there as well. In terms of code, you would have to define a set of vanilla civs and match them against the $civ.json name. Its basically implementation details, but a simply key-value table could do the trick, which hasn't have to be a file, could be done in code purely. The thought is:

civ        vanilla
Rome       true
China      false
Gauls      true

Easy to set vanilla civs, a switch could also be implemented in civ.json directly vanilla: <boolean>.

StanleySweet commented 6 years ago

In terra magna, there are helmet props, and a helmet/new folder. Do you know of the dae files are equal? They exist in standard helmets as well.

No they are not. Some are for the old unit meshes, and the other for the new ones.

Regarding music, is there license issues to include the two ogg files defined in chin.json?

Depends on the music license :)

Easy to set vanilla civs, a switch could also be implemented in civ.json directly vanilla: <boolean>.

Sounds good in practise, but someone might install a mod that overwrite that file. Also, that file is not really mod friendly, because mods might want to add civs to it, and two mods would then have two different files.

udeved commented 6 years ago

@StanleySweet

Regarding the art new files, can I simply use them for all units, ie make the new ones default? will that work or does it produces glitches or so? I am not very experienced with modeling, animations etc, I can just make use of them :)

PS: I'd like to transfer a clean repo without many redundant files.

udeved commented 6 years ago

The music in question is:

StanleySweet commented 6 years ago

Regarding the art new files, can I simply use them for all units, ie make the new ones default? will that work or does it produces glitches or so?

Might glitch if at least one model requires them. Basically the old head used to be bigger.

PS: I'd like to transfer a clean repo without many redundant files.

That's a good goal

The music in question is:

* Omri Lahav - Hill of Sorrows.ogg

* Omri Lahav - Red Dawn.ogg

Should be fine as it's CC-BY-SA 3.0 Omri is our Sound Department lead.

udeved commented 6 years ago

Might glitch if at least one model requires them. Basically the old head used to be bigger.

Is there a way to find out what model requires old files? Is that somwhere changeable besides the obvious path in the xml data? Some dae or something? Or do this only work in blender or whatever is used? I don't have much time to test and swap around these files, I'd make the new one default and leave it up to the arts wizzards to fix whatever glitches occur. to avoid pushing the old files.

udeved commented 6 years ago

@StanleySweet

In order to transfer ownership, I would need temporary privs to create a repo on 0ADMods.

You don’t have the permission to create repositories on 0ADMods

StanleySweet commented 5 years ago

@udeved I'm sorry I missed your message. You should have received an invite :)

udeved commented 5 years ago

@StanleySweet

Ok, I try the transfer again ;)

StanleySweet commented 4 years ago

Transition has been done, only thing remaining now is deleting the files from this mod