Bay 12 Games Forum

Please login or register.

Login with username, password and session length
Advanced search  

Author Topic: Mods as patches rather than complete replacements  (Read 839 times)

Silverionmox

  • Bay Watcher
    • View Profile
Mods as patches rather than complete replacements
« on: March 21, 2012, 11:00:14 am »

Problem: when you make changes in the raws, and a new version arrives, you're in a dilemma: transfer your modified raws and keep your changes but risk to lose Toady's changes, or you have to edit every single change you've ever made in the raws back in, manually.

Suggestion: Instead of using raws as a take-it-or-leave-it whole, allow partial raws. The game will then compare them with the base raw set and fill in if nothing is defined (eg. a new creature), or override the basic raws with the mods (e.g. in the creatures file of the mod, a dog creature is defined with six legs instead of two).

Advantages: Smoother updating with new versions, keep your own cumulative changes to the raws, easier switching and combining of mods.

Disadvantage: slightly longer startup.
Logged
Dwarf Fortress cured my savescumming.

irmo

  • Bay Watcher
    • View Profile
Re: Mods as patches rather than complete replacements
« Reply #1 on: March 21, 2012, 11:38:50 am »

Problem: when you make changes in the raws, and a new version arrives, you're in a dilemma: transfer your modified raws and keep your changes but risk to lose Toady's changes, or you have to edit every single change you've ever made in the raws back in, manually.

Suggestion: Instead of using raws as a take-it-or-leave-it whole, allow partial raws. The game will then compare them with the base raw set and fill in if nothing is defined (eg. a new creature), or override the basic raws with the mods (e.g. in the creatures file of the mod, a dog creature is defined with six legs instead of two).

Advantages: Smoother updating with new versions, keep your own cumulative changes to the raws, easier switching and combining of mods.

Disadvantage: slightly longer startup.

Disadvantage: you can't remove things, because the game will just fill in the default.

If you really want to preserve your mod across releases, can't you create a patch with diff, and then apply it to the new version? There are some very good tools out there for applying a set of changes to a collection of text files.
Logged

blake77

  • Bay Watcher
    • View Profile
Re: Mods as patches rather than complete replacements
« Reply #2 on: March 21, 2012, 12:56:32 pm »

Have you tried dwarf fortress mod manager from here http://www.bay12forums.com/smf/index.php?topic=74828.0
Logged

Radiant_Phoenix

  • Bay Watcher
  • [CREATURE_CLASS:MODDER]
    • View Profile
Re: Mods as patches rather than complete replacements
« Reply #3 on: March 21, 2012, 04:56:25 pm »

Most of my mods involve new raw files, so I don't have much trouble with this.
Logged

NW_Kohaku

  • Bay Watcher
  • [ETHIC:SCIENCE_FOR_FUN: REQUIRED]
    • View Profile
Re: Mods as patches rather than complete replacements
« Reply #4 on: March 21, 2012, 05:11:51 pm »

Most of my mods involve new raw files, so I don't have much trouble with this.

Until recently, you couldn't do that for the item_FOO.txt stuff.  It was fortunately changed in the last few updates. 

This is a trend that should continue, but still has a problem when you are doing things to modify existing elements of the game. 

For example, in my Expanded Glazes mod, I have to delete the old glazing reactions in order to put in my updated versions without having a nonsensical overlap.
Logged
Personally, I like [DF] because after climbing the damned learning cliff, I'm too elitist to consider not liking it.
"And no Frankenstein-esque body part stitching?"
"Not yet"

Improved Farming
Class Warfare

Astramancer

  • Bay Watcher
    • View Profile
Re: Mods as patches rather than complete replacements
« Reply #5 on: March 21, 2012, 09:02:13 pm »

This would also be nice because it would fix the duplicate raws issue (you know, the ones that cause you to have wagon meat and embark as grey slimemen)
Logged