Bay 12 Games Forum

Dwarf Fortress => DF Modding => Topic started by: zilpin on September 28, 2010, 09:06:01 am

Title: Modding Tool: DF World Tinker 0.34.11.0
Post by: zilpin on September 28, 2010, 09:06:01 am
DFFD dfWorldtinker 0.34.11.x download page (http://dffd.wimbli.com/file.php?id=7604)

Simple command line tool for tinkering with regions after world generation.
At this moment, able to export and import most raw file data.
Able to insert new tags as well. As a result, able to break save games if you're not careful.
Not user friendly, but it works.

Drop in the DF folder, open a command prompt, and run it.

Usage:
Code: [Select]
dfworldtinker <region> <export|import> <file>
Examples:
Code: [Select]
dfworldtinker region1 export -
dfworldtinker 1 export exportfile.txt
dfworldtinker 1 import modifiedfile.txt


All parameters are required.
Regions can either be entered with their full name, or just as their number for convenience.
Entering a single dash for the input/output file reads from or writes to terminal.
If no commands given, enters a very simple interactive mode.
Commands can be reduced to first character.  E.g. "e" for "export"  and "i" for "import".

* Only able to edit non-compressed saved games and regions. See your init file. *

Official Supported DF versions:
34.11

About the Sync command
Broken.  Using this may awaken the Old Ones and lead to the end of humanity.  Don't.

About Interactive Mode
It's a cheap hack, not intended to be user friendly, all it does is bootstrap the command line parameters for you, then process as it would have from the command line.  No plans to make it pretty.

Automatic Backup
The world file is automatically backed up, given an extension with a date and time stamp.  You can find the backups in the save folder.

Limitations
Toady stores entities differently in the save file, so your civilization will not gain new things you add to the raws.  No way around this until I get help from someone who understands the entity data structures.  That sucks, because it means new reactions, items, workshops, etc, can not be added as they once were.
Need help with entity data in save files.

Title: Re: DF World Tinker
Post by: Impending Doom on September 28, 2010, 09:20:45 am
Link or it didn't happen.

And from what I see here, I sincerely hope that it DID happen. :)
Title: Re: DF World Tinker
Post by: Gearheart on September 28, 2010, 09:55:49 am
Love it.
Title: Re: DF World Tinker
Post by: ungulateman on September 28, 2010, 10:59:33 am
This...is brilliant. Thank you for this awesome prgram.
Title: Re: DF World Tinker
Post by: Aramco on September 28, 2010, 02:09:40 pm
Link or it didn't happen.

And from what I see here, I sincerely hope that it DID happen. :)

It's a MOD. You download it to see if it works. I also hope it works, but I am going to find out by downloading it.

EDIT: It will not work. When I click on it, it flashes onto the screen, then goes away.  I am playing 31.14, but you said it worked for that. Why is it not working? (I have a feeling I am just being stupid)
Title: Re: DF World Tinker
Post by: zilpin on September 28, 2010, 03:21:59 pm
It does work, when used as directed.

From the first post:
Quote
Simple command line tool for...
Quote
Drop in the DF folder, open a command prompt , and run it.

Also, note the "Usage:" section and examples.

It flashes and exits because you didn't give it any parameters (double clicking can't).  So it opens, recognizes that it's missing parameters, prints a short help message, then Windows automatically closes the window for you.

Here are some helpful links about the command prompt, courtesy of Google:
http://en.wikipedia.org/wiki/Command_Prompt (http://en.wikipedia.org/wiki/Command_Prompt)
http://www.pcworld.com/article/121786/windows_tips_windows_command_line_puts_you_in_control.html (http://www.pcworld.com/article/121786/windows_tips_windows_command_line_puts_you_in_control.html)
http://commandwindows.com/ (http://commandwindows.com/)
http://www.microsoft.com/resources/documentation/windows/xp/all/proddocs/en-us/ntcmds.mspx?mfr=true (http://www.microsoft.com/resources/documentation/windows/xp/all/proddocs/en-us/ntcmds.mspx?mfr=true)


Maybe at some point I'll make an interactive user interface (like the dfhack tools), but don't hold your breath.
This is just a precursor.  I made it to test my region reverse-engineering, and released it since I figured it may be useful to modders.
My main thrust is a more involved project to perform detailed searching for embark sites.
Title: Re: DF World Tinker
Post by: Wideman on September 28, 2010, 03:54:09 pm
WOAH,

what a funky tool you, have there.

ok for those who dont know how to use it,
ill do a step by step guide.

1. download,
2.copy or cut. into your, DF folder.
3. for win 7 users. Push and hold the Win Key+R
4. type in cmd.
that should open a command prompt window.                     
Spoiler (click to show/hide)
5. go to your DF folder in my case its
C:\Users\Stephen\DF
so the command is, cd C:\Users\Stephen\DF        (used mine as an example)
where my letter C: is refers to the hard drive letter your DF file is located.
6. then type, dfworldtinker.exe 1 export exportfile.txt     push enter                 
Spoiler (click to show/hide)
7. there you go it has been created.... (where 1 is is the region you want to edit)
8. if you have edited the file then you go: dfworldtinker.exe 1 import exportfile.txt
and thats all folks..
Title: Re: DF World Tinker
Post by: Aramco on September 28, 2010, 04:06:22 pm
WOAH,

what a funky tool you, have there.

ok for those who dont know how to use it,
ill do a step by step guide.

1. download,
2.copy or cut. into your, DF folder.
3. for win 7 users. Push and hold the Win Key+R
4. type in cmd.
that should open a command prompt window.
5. go to your DF folder in my case its
C:\Users\Stephen\DF
so the command is, cd C:\Users\Stephen\DF        (used mine as an example)
where my letter C: is refers to the hard drive letter your DF file is located.
6. then type, dfworldtinker.exe 1 export exportfile.txt     push enter
7. there you go it has been created.... (where 1 is is the region you want to edit)
8. if you have edited the file then you go: dfworldtinker.exe 1 import exportfile.txt
and thats all folks..

I tried that, when I got to step 6. It said "'dfworldtinker.exe' is not recognized as an internal or external command operable program or batch file.
Title: Re: DF World Tinker
Post by: Wideman on September 28, 2010, 04:10:26 pm
did you, put the rest of the command line in?
and are you on win7/vista or xp?
Title: Re: DF World Tinker
Post by: Aramco on September 28, 2010, 04:12:12 pm
did you, put the rest of the command line in?
and are you on win7/vista or xp?

Yeah, I put in all in. I am on windows xp.
Title: Re: DF World Tinker
Post by: Wideman on September 28, 2010, 04:15:55 pm
ok, try typing in dfWorldTinker.exe instead of dfworldtinker.exe  (i renamed my one you see)

and the program is in the DF folder with the Dwarffotress.exe?   
Title: Re: DF World Tinker
Post by: Aramco on September 28, 2010, 04:24:41 pm
ok, try typing in dfWorldTinker.exe instead of dfworldtinker.exe  (i renamed my one you see)

Just the capitalization difference? I've already tried that. Unless... Does Dwarf Fortress need to be open at the same time?

Oh, I'm stupid, I did leave some out.

No, wait, now it says 'The system cannot find the path specified' I figured it meant there was a typo somewhere, but I cannot find any.
Title: Re: DF World Tinker
Post by: Wideman on September 28, 2010, 04:26:41 pm
no.. if u look at my original post i have included images.. if you check them, out, and make sure your dfworldtinker.exe file is where mine is is should work..

and to be honest. i dont know how it works after that.. i mean adding the tags. im still trying to work that out
Title: Re: DF World Tinker
Post by: zilpin on September 28, 2010, 08:46:41 pm
Yes, it is a bit light on lacking any documentation.

Tags are dumped raw to output, and are read in raw.

Let's do an example case, like a free coke reaction for the smelter (everybody loves free coke!).

1) Do everything you would normally do when modding a new reaction.  Namely, create the reaction in the reaction_smelter.txt raw file in the region's raw\objects folder.   Something like this:
Quote
[REACTION:FREE_COKE]
[NAME:free coke baby!]
[BUILDING:SMELTER:NONE]
[PRODUCT:100:10:BAR:NO_SUBTYPE:COAL:COKE][PRODUCT_DIMENSION:150]
[SKILL:SMELT]

Add it to the end of the file.

Like  normal, add the tag to the entity_default.txt file, for example:
Quote
[PERMITTED_REACTION:FREE_COKE]

If you don't understand that so far, go look at the other reaction modding threads.


Now the free coke is supported in your save game's raws, but it doesn't exist in the world, so loading the game will ignore it.
Now's when you edit the exported file from dfworldtinker.
Search for the ====reaction====
That is how I delimit and identify the different sections.
You should see a list of all the reactions in the game.  Simply add a new line with:
Quote
FREE_COKE
It must be on it's own line, it must come after the existing reactions, and it must be in all capital letters.
Save the file, and run the import command for your region and the edited file.

First the program makes a backup of your world file, which can get big, so pay attention to it.
If everything works, inside the game the smelter will now be able to create free coke.


Some notes on importing:
When re-importing a file, note that the sections must come in the order expected, must be exactly what you want added, and the tags themselves must be in the correct order, or strange things will happen.  If, for example, you swap the DIAMOND_RED line with the SAND_RED line, every layer of red sand in the world will be replaced with red diamond, and vice versa.  Not only that, but every bag of red sand will transmute to bags of red diamond powder, every red diamond gem will transmute to red sand gem.  This is, obviously undesired and unstable.  I only intend the tool for adding tags for modding a running game... but you are free to use it as you like.

After all, a solid raw adamantine mountain where there used to be boring granite does sound kind of cool, doesn't it?
...
Spoiler (click to show/hide)
...
note how it still has all the veins in it.


Clear as mudstone?

Title: Re: DF World Tinker
Post by: Artanis00 on September 29, 2010, 02:58:22 am
I'm either doing something wrong, or 0.31.10 linux saves don't work:

Code: [Select]
wine tinker.exe region4 export - > region4
Reading Region region4 at .\data\save\region4\world.sav
Error: world file version unsupported: 25.5

Also, linux version?
Title: Re: DF World Tinker
Post by: Wideman on September 29, 2010, 10:01:52 am
im just taking a wild stab in the dark as to be frank.. i really dont like linux (im not slamming it or w/e)   but it could be because of your arrow.
try like this
wine dfworldtinker 4 export exportfile.txt


oh and thanks for the enlightenment on the TAGs  as i couldnt wrap my head around it, and was trying to make my Black sand into Platinum XD


Title: Re: DF World Tinker
Post by: Aramco on September 29, 2010, 01:47:53 pm
So, if I replace the thing that says SANDY_CLAY_LOAM with RAW_ADAMANTINE, all of my sandy clay loam will become adamantine?

EDIT: Hmmm... Every tile of soil on my map flashed between every stone, mineral, and gem type in the game. Why?

Spoiler (click to show/hide)
Title: Re: DF World Tinker
Post by: Artanis00 on September 29, 2010, 02:22:12 pm
im just taking a wild stab in the dark as to be frank.. i really dont like linux (im not slamming it or w/e)   but it could be because of your arrow.
try like this
wine dfworldtinker 4 export exportfile.txt

It's not the output redirection--that has no effect on programs--but I gave it a shot anyway:

Code: [Select]
wine tinker.exe region4 export region4.txt
Reading Region region4 at .\data\save\region4\world.sav
Error: world file version unsupported: 25.5
Title: Re: DF World Tinker
Post by: Wideman on September 29, 2010, 02:37:08 pm
@Artanis00 umm are you using version, .14 thats all ive tested it on :/ but it supposedly woks all the way to 31.05
oh and armaco. i really cant understand ascii graphics sorry, but i think it might be because you have changed them around wrongly in the file. if you can send me your save and what your trying to do in an email and ill try it for you :) best i can do for you.
Title: Re: DF World Tinker
Post by: zilpin on September 29, 2010, 05:21:32 pm
@Aramco::
This give you raw, no-safety, no-limits editing of the files data.  When you replaced the sandy clay entry with with adamantine, there became two entries for adamantine in the list.  DF got all kinds of screwy.  You need to swap the two entries, thereby replacing all the adamantine veins with sandy clay (makes HFS not so fun).  Remember, that's just playing around.  The real intent is to add new tags to the save game's reactions and workshops sections, so that you can play mods without re-gen.  Eveything else is just left in to let anyone experiment.


@Artanis00::
I uploaded a new version to DFFD.  It now has a 'force' variant for both commands, to let you circumvent any warnings/errors.  Give it a try.
I come from a unix background, but I don't have a linux development machine right now, and I have not been impressed with DF linux versions in the past.  Not impossible, my in-progress world viewing tool is intended to be cross platform from the start.
This thing is just a cheap hack that I shared.

Title: Re: DF World Tinker
Post by: Aramco on September 29, 2010, 07:19:59 pm
@Aramco::
This give you raw, no-safety, no-limits editing of the files data.  When you replaced the sandy clay entry with with adamantine, there became two entries for adamantine in the list.  DF got all kinds of screwy.  You need to swap the two entries, thereby replacing all the adamantine veins with sandy clay (makes HFS not so fun).  Remember, that's just playing around.  The real intent is to add new tags to the save game's reactions and workshops sections, so that you can play mods without re-gen.  Eveything else is just left in to let anyone experiment.


@Artanis00::
I uploaded a new version to DFFD.  It now has a 'force' variant for both commands, to let you circumvent any warnings/errors.  Give it a try.
I come from a unix background, but I don't have a linux development machine right now, and I have not been impressed with DF linux versions in the past.  Not impossible, my in-progress world viewing tool is intended to be cross platform from the start.
This thing is just a cheap hack that I shared.

I just wanted to see how awesome I could make the game. I proceeded to remove all inorganic tags from the list. Every stone and soil tile on the map became 'rock'.  Thanks for the assist, though.
Title: Re: DF World Tinker
Post by: Artanis00 on September 30, 2010, 02:03:02 am
I uploaded a new version to DFFD.  It now has a 'force' variant for both commands, to let you circumvent any warnings/errors.  Give it a try.
I come from a unix background, but I don't have a linux development machine right now, and I have not been impressed with DF linux versions in the past.  Not impossible, my in-progress world viewing tool is intended to be cross platform from the start.
This thing is just a cheap hack that I shared.

The forceexport command works on 0.31.10 linux saves, as does forceimport--though I only swapped microcline and adamantine (!)--and confirmed that the switch took place.

... And then swapped microcline for sweet pods, just for kicks (crashed, obv.)

Also, don't sell yourself short. This is a sweet hack.
Title: Re: DF World Tinker
Post by: Deon on September 30, 2010, 02:09:26 am
So, if I replace the thing that says SANDY_CLAY_LOAM with RAW_ADAMANTINE, all of my sandy clay loam will become adamantine?

EDIT: Hmmm... Every tile of soil on my map flashed between every stone, mineral, and gem type in the game. Why?

Spoiler (click to show/hide)
Yeah, it's a duplicate entry bug, you can make it by yourself by wrong raws in slightly modded df too.

It's a great tool, thank you very much!
Title: Re: DF World Tinker
Post by: Aramco on September 30, 2010, 02:45:32 pm
I have a suggestion-- make a way for people to tell which world the export file is from by the text files name. As it is, they'd all be named the same thing and it would be a mess. Just change exportfile.txt to exportfile1.txt for world one, or exportfile2.txt for world two.
Title: Re: DF World Tinker
Post by: Wideman on September 30, 2010, 03:48:16 pm
you can do that armaco........
type in
dfworldtinker.exe 1 export export1.txt
or
dfworldtinker.exe 2 export export2.txt

etc...
Title: Re: DF World Tinker
Post by: Aramco on September 30, 2010, 04:48:34 pm
you can do that armaco........
type in
dfworldtinker.exe 1 export export1.txt
or
dfworldtinker.exe 2 export export2.txt

etc...

Oh. I was unaware.
Title: Re: DF World Tinker
Post by: Wideman on October 01, 2010, 03:09:29 pm
no worries man,
Title: Re: DF World Tinker
Post by: zilpin on October 03, 2010, 11:19:39 am
new version released.
see first post.
Title: Re: DF World Tinker
Post by: zilpin on October 03, 2010, 04:10:43 pm
Tested sync with 31.15 and the higher learning mod.

Able to add Dwarven Higher Learning (http://bay12forums.com/smf/index.php?topic=60853.0) to the raws, and successfully add them to a 31.15 game 1 season after embark.  Everything working as far as that goes.

After successful sync, this is the approx output you should see from dfworldtinker run in interactive mode:
Spoiler (click to show/hide)


[Edit]
Also verified with 31.16
Title: Re: DF World Tinker
Post by: Vattic on October 03, 2010, 06:34:58 pm
I just wanted to say this is really awesome. Thanks for a great tool :D.
Title: Re: DF World Tinker
Post by: zilpin on October 14, 2010, 03:34:24 pm

Here's my current tested list.
Verified = and I've played the modified map long enough to feel comfortable that it won't create any long term problems.
Experimental = appears to be working, with no side effects, but hasn't been used long enough to be considered stable.
Bugged = known to cause bugs.
Unstable = technically works, but in practice is very difficult and usually causes problems
Unknown = not tested at all.

These all refer to adding tags using sync.

Verified:
Workshops
Reactions
Materials (all)
Items (all)
Plants

Experimental:
Words
Languages

Bugged:
(none)

Unstable:
Body Templates
Creatures

Unknown:
Material Templates
Entities (civilisations)


Of course, adding stone types or plant types doesn't make them magically appear all over the world.  Adding stone types is only useful if you have a reaction which creates them.  Don't know if add plants might show up in the wild for the correct biome (haven't seen it yet).

Creatures can be added fine, though they won't exist in populations or ever show up.
Body templates are tricky, since all the creatures already existing in the game will expect a particular structure to exist for the body.  Basically, anything which would crash a game from editing the raws can still crash the game.

If a new material template is added, and used by a new material, that should be OK, but untested.



Title: Re: DF World Tinker
Post by: Symbiode on October 14, 2010, 07:43:40 pm
I just wanted to comment on how awesome this tool is, I played with it a bit when you first posted about it and loved what it could do. This is going to save me a ton of time when the new adventure stuff comes out and I mod some more reactions, it was a pain having to regen 4,000 times trying to test the reactions and get them just right. Thank you for making thing and making it available!
Title: Re: DF World Tinker
Post by: Artanis00 on October 31, 2010, 02:49:32 pm
Interesting thing I just noticed: when you switch a layer with sand (e.g.: sandy clay loam for red sand) you will get bags of sandy clay loam in caravans. I assume this is because the game tracks which layers in sites are sand, so when you swap the two, the game starts putting the new layer material in bags (and existing bags would probably switch as well).
Title: Re: DF World Tinker
Post by: Halnoth on November 01, 2010, 03:19:20 am
Interesting thing I just noticed: when you switch a layer with sand (e.g.: sandy clay loam for red sand) you will get bags of sandy clay loam in caravans. I assume this is because the game tracks which layers in sites are sand, so when you swap the two, the game starts putting the new layer material in bags (and existing bags would probably switch as well).

This also happens when you simply add the sand token to all of the soil layers, before gen of course. I do that so I don't have to take hours to find the perfect site. The side effect is you get merchants bringing bags of peat and so forth.
Title: Re: DF World Tinker
Post by: Artanis00 on November 01, 2010, 05:41:18 am
Interesting thing I just noticed: when you switch a layer with sand (e.g.: sandy clay loam for red sand) you will get bags of sandy clay loam in caravans. I assume this is because the game tracks which layers in sites are sand, so when you swap the two, the game starts putting the new layer material in bags (and existing bags would probably switch as well).

This also happens when you simply add the sand token to all of the soil layers, before gen of course. I do that so I don't have to take hours to find the perfect site. The side effect is you get merchants bringing bags of peat and so forth.

The difference is that in that situation, both types are collectible on site and usable for glassmaking, while in the case of swapping the two types the non-sand type is useless for everythi--oh hey, a cheap bag.
Title: Re: DF World Tinker
Post by: zilpin on November 01, 2010, 01:10:59 pm

Primary intent of the tool at this point is the 'sync' command.

Unregulated export/import will cause all kinds of craziness, but on rare occasion may be useful.
Particularly for editing Demons, Forgotten Beasts, and Titans.
Title: Re: DF World Tinker
Post by: Altaree on December 09, 2010, 03:24:23 pm
any hope for a .18 version?
Title: Re: DF World Tinker
Post by: zilpin on December 10, 2010, 12:42:53 pm
any hope for a .18 version?

It does work with .18
Title: Re: DF World Tinker
Post by: Voldine on December 24, 2010, 02:13:28 pm
So, how about a basic guide for those of us that have never done this before? Other than how to open the editor.

You know, like what the heck we're supposed to do? What commands work, basic options, syntax?

Kinda hard to 'tinker' with something when there's absolutely no documentation on how you access the stuff to tinker with it.

Would make so much more sense to include at least a basic tutorial on HOW TO USE YOUR PROGRAM in the thread that allows us to download it.
Title: Re: DF World Tinker
Post by: Symbiode on December 24, 2010, 03:54:15 pm
The instructions for use are clearly stated in the first post. If you cannot determine how to use this with the information given, this tool is not for you.
Title: Re: DF World Tinker
Post by: Voldine on December 24, 2010, 05:21:48 pm
The instructions for use are clearly stated in the first post. If you cannot determine how to use this with the information given, this tool is not for you.

Then point me to a single place that actually has info on how to use this for its intended purpose? Point me to a single place where it tells you how to use it to actually access the raw data? Perhaps point out a place on this forum where there is a tutorial on how to access and modify the raw data with this tool?

No, instead you're snarky and instantly assume that I didn't read the first post despite being clear in my post that I was able to open the utility, but there's no info on how to proceed from there anywhere.
Title: Re: DF World Tinker
Post by: Symbiode on December 24, 2010, 05:35:44 pm
Sorry about that, your post seemed a little rude and demanding with the caps, rubbed me the wrong way. If you run the tool via a command prompt with the export option as shown in the initial post, it will create a large text file that contains the complete raws for that save. You can then edit this file and apply it back to the save with the import command line flag. If you want more information about how to modify the raws, magmawiki has a great molding section that explains the tags and options available.
Title: Re: DF World Tinker
Post by: zilpin on December 26, 2010, 05:17:05 pm
There is no step-by-step guide, none planned, none intended.  dfWorldTinker's use is self evident to the scarred, !burned!, maimed, mutated, battle-hardened wretches called "DF modders".

When I get world.dat documentation, you get documentation.  Until then, I will be preoccupied with reverse-engineering world.save file.

This is a low-level, direct edit of your savegame.  No training wheels.  It is really targeted at people who have a pretty solid foundation for modding DF, understand DF's file system structure, and already understand how to tinker raws with DF's settings, data files, etc, but want the ability to tinker without genning a new world.  It lets you slice at your save with a scalpel or hack at it with a Battle Axe, as you like.


Based on Voldine's first post, I'll assume his intended purpose is to mod the raws to add something (workshop? material?), then sync them into an existing embark.
First of all, make sure that DF savegame compression is turned off.  If it was not, you will have to change the setting, open the embark, resave.  If you don't know what «init.txt» is, then go research it in the forums and on MagmaWiki (http://df.magmawiki.com/index.php/DF2010:Init.txt).

Then, edit the raws of the savegame.  Not the DF raws, the savegame raws.  There is no validation.  If you make a mistake, only DF can tell you.  Tersely.  The DF world save file stores the object tags of entries in the raw file, but does not store the entire contents of the raws.  DFWorldTinker lets you get around this limitation, by injecting new tags into the world save file, so that DF will load their full data from the savegame raws which corresponds to the savegame.  If this is sounds like the gnomish gibberish, consult MagmaWiki (http://df.magmawiki.com/index.php/Raw).

Run dfworldtinker from the DF folder.  The interactive menu is simple; enter the region folder's name or number, then the «sync» command, then follow instructions.

Status will scroll by the screen, showing any new tags that were added.  Once a tag is added to a savegame, it is impractical to ever remove it.  The game world file will automatically be backed up (name given by the program), so that you can manually restore.  Keep in mind that any bugs introduced by editing the raw files will naturally require restoring those independently.


In short, this is a Hole Hawg (http://www.team.net/mjb/hawg.html) style tool.

(excerpt from IN THE BEGINNING WAS THE COMMAND LINE (http://www.nealstephenson.com/command/))

Title: Re: DF World Tinker
Post by: Inari on January 21, 2011, 04:38:27 pm
I'm annoyed by the fact that goblin corpses (probably) never rot down to bones anymore, and am looking for a way to overcome this.

It's been suggested (http://www.bay12forums.com/smf/index.php?topic=75562.0) to me that modifying Dwarven ethics to allow consumption of the corpses of sentient beings will allow them to be butchered, and it's been further suggested that I might be able to use World Tinker to enable me to make the mod mid-game, without the need to generate a fresh world.

I'm stumped as to how to do this.  I can follow the above instructions as to how to add a tag, but I'm unsure how to modify one, or even if that's possible.  My attempts so far have either failed to produce the intended results, or caused the game to crash.

Can anyone help?
Title: Re: DF World Tinker
Post by: Sphalerite on January 21, 2011, 05:43:29 pm
I am fairly certain you cannot do that with this program.  I haven't used it myself, but I've been doing my own research into editing the DF save game files.  Procedurally generated creatures (forgotten beasts, demons, titans, bogeymen, etc) are stored in the safe file as plaintext.  Certain information which applies to the entire game such as reactions, materials, symbols, tissues, and other such stuff, is also stored as plaintext in a fairly easily editable form.  Civilization ethics information is not.  Civilizations are created when the world is created, and that is the only time their ethics tags are loaded from the raw files.  After that they are stored in a highly complex form whose format I am still far from deciphering, and which probably can't be changed without a very thorough understanding of the format of that part of the file.
Title: Re: DF World Tinker
Post by: Inari on January 22, 2011, 02:51:33 am
Thanks for the information, Sphalerite, I'll cease my attempts to do the impossible.
Title: Re: DF World Tinker
Post by: Thundercraft on June 14, 2011, 03:56:45 am
It seems the last release of DF World Tinker was for v0.31.16.
Has anyone tried to use this with something more recent?

I'm trying to help update the Community Mods and utilities list (http://www.bay12forums.com/smf/index.php?topic=28829.0), which currently lists a number of outdated mods and utilities that do not work with recent DF versions.
I need to ask: Is an update of DF World Tinker in the works?  Is it something considered? ???
Title: Re: DF World Tinker
Post by: Eldrick Tobin on June 14, 2011, 10:30:57 am
It seems the last release of DF World Tinker was for v0.31.16.
Has anyone tried to use this with something more recent?

I'm trying to help update the Community Mods and utilities list (http://www.bay12forums.com/smf/index.php?topic=28829.0), which currently lists a number of outdated mods and utilities that do not work with recent DF versions.
I need to ask: Is an update of DF World Tinker in the works?  Is it something considered? ???

It works just fine. The save file format itself has not had an update just yet.
Title: Re: DF World Tinker
Post by: zilpin on June 15, 2011, 09:02:13 am
I need to ask: Is an update of DF World Tinker in the works?  Is it something considered? ???

It works for most tasks with 31.25.
There are so many open bugs in DF right now, and Toady keeps adding new features (and bugs) instead of fixing them, so updating it seems like wasted effort.
I'll likely abandon it, putting time toward the more thorough dfWorldDat  (http://www.bay12forums.com/smf/index.php?topic=86417.msg2340121#msg2340121)project instead...
...which no one else has shown any interest in.
Title: Re: DF World Tinker
Post by: Grax on February 28, 2013, 11:12:17 am
Is there any chance to get a supoprt for newer versions?
Title: Re: DF World Tinker
Post by: zilpin on March 08, 2013, 07:26:29 pm
-
Title: Re: DF World Tinker
Post by: zilpin on April 02, 2013, 09:36:57 pm
Due to most courteous requests PM'ed my way, updating.
Now able to do an export on 34.11.  Next is import, then sync.
If anyone wants incremental releases, PM me.

[edit]
Import seems to work.
Moving on to sync, which will take longer.
PM for early obtainment (i.e. to test).

If there is public interest I will spend more time this weekend.
If not, I won't.
Title: Re: DF World Tinker
Post by: Spiderking50 on April 09, 2013, 11:01:22 pm
I am the public interest. (Lol). :P

But really if this is what I think it is (Although i can't really tell because the info post that's typically the first post or about that has been deleted.) then there is definite interest beyond just me.
Title: Re: DF World Tinker
Post by: Grax on April 09, 2013, 11:06:18 pm
I vote for "spending more time this weekend".  :D
Title: Re: DF World Tinker
Post by: zilpin on April 25, 2013, 10:29:02 pm
Import was bugged for a long time.
Sync is proving difficult with all the new raw files.
Released current export/import version for now.
Title: Re: Modding Tool: DF World Tinker 0.34.11.0
Post by: zilpin on May 04, 2013, 04:51:57 pm
Need help with the entity data structure in the save file, so that importing anything is useful again.
Anyone who can find their way around a hex editor, any hex editor.

If we get this solved, testing mods will get much quicker and easier, since you'll be able to try out mods on existing embarks again.

Right now, if you import workshops (or anything else) into an existing fortress, there is no way for you dwarfs to use it because the civilization entity does not have the new asset.  DF does not re-read the entity_default.txt raw on save load (which is annoying), so we'll have to either 1) figure out the data structure in the save file, and modify it; or  2) get a dfhack plugin to give the new assets to the entity you are playing.

I just don't have the time to reverse engineer the binary save file like I once did.
Need some community help to figure out the entity binary structure in world.dat and world.sav
Title: Re: Modding Tool: DF World Tinker 0.34.11.0
Post by: Porpoisepower on May 15, 2013, 12:36:07 pm
Is the link broken?
Title: Re: Modding Tool: DF World Tinker 0.34.11.0
Post by: zilpin on May 25, 2013, 06:12:34 am
No.  Maybe DFFD was down for maintenance when you tried.
Title: Re: Modding Tool: DF World Tinker 0.34.11.0
Post by: TheFlame52 on May 23, 2014, 05:22:53 pm
I'm having a problem running it from the file itself.
(http://i.imgur.com/kxunhjn.png)
But the world is uncompressed. There is a world.sav in the folder. What gives?
Title: Re: Modding Tool: DF World Tinker 0.34.11.0
Post by: Meph on May 23, 2014, 05:25:38 pm
Open the init/d_init in data/init and set save compression to No and gen a new world.
Title: Re: Modding Tool: DF World Tinker 0.34.11.0
Post by: TheFlame52 on May 23, 2014, 06:50:37 pm
I set save compression to no. Then I genned a new world. That world is region3. It doesn't work and I have no idea why, as I am doing everything right it seems.
Title: Re: Modding Tool: DF World Tinker 0.34.11.0
Post by: TheFlame52 on May 25, 2014, 03:32:14 pm
Nevermind, I fixed it. I abandoned a fort I already had and extracted from that. I have no idea why the first one didn't work.
Title: Re: Modding Tool: DF World Tinker 0.34.11.0
Post by: amras0000 on June 21, 2015, 07:10:54 pm
So it's 2015. 0.40 is out, and I've been looking for a tool to let me change data on historical figures, add or remove them, etc. Unfortunately, looks like World Tinker's functionality broke with the update (I'm getting "Could not read world name"). I would love to have this continue working, so an update would be ideal, but if you don't want to continue supporting a script you wrote in 2011 - I don't blame you - could you at least provide the source code?
Title: Re: Modding Tool: DF World Tinker 0.34.11.0
Post by: Spiderking50 on June 21, 2015, 09:35:57 pm
@ amras0000

Everyone else's profile says bay watcher beneath their name. Why/how does yours say escaped lunatic?
Title: Re: Modding Tool: DF World Tinker 0.34.11.0
Post by: amras0000 on June 21, 2015, 11:27:31 pm
The gods have called upon me to bring justice to the world. The others thought I was mad and they locked me away, taking my axe, and my basalt sock. But they did not guard me well, and their chains were weak to the powers of the ancients. I rode off on a raven's back and abandoned my fortress for pastures purple.
I only made this account today, and the post you see above is my only one so far. I'd imagine that has something to do with it.