Bay 12 Games Forum

Please login or register.

Login with username, password and session length
Advanced search  

Author Topic: Dwarf Fortress Language Creation Script  (Read 2092 times)

Tecknojock

  • Bay Watcher
    • View Profile
Dwarf Fortress Language Creation Script
« on: January 21, 2012, 06:47:03 pm »

Dwarf Fortress Language Creation Script

This script simplifies the creation of new language files.

This script can:
  • Generate a dictionary file from language_DWARF.txt which can then be uploaded to a service like Google Translation Tookit and converted into another language.
  • This new dictionary can be fed back into the script to generate a new language file.

Important notes:
  • The script uses AutoIt to run
  • Only ANSI is supported languages like Chinese or Arabic will have to be latinized first.

To use you will have to edit a couple variables located within the file (notepad works):
Code: [Select]
;Point this entry to your raw/object folder.  language_DWARF.txt and your wordlist must be located here
$dir =  "H:\LazyNewbPack[0.31.25][V9.3]\Dwarf Fortress v0.31.25\raw\objects\"

;The name of your translated dictionary file.  NOTE: Make first word of this file is the sixth line
$dict = "language_WORDLIST.txt"

$newdict = false ; Set this to true if you want to generate a new untranslated dictionary file
$languageName = "Klingon" ; Must be a string, case insensitive.

$KeepUntranslated = true ; When true untranslated words will be kept.

$removeWS = 1 ; Flags:
; 0 : Disable whitespace removal
; Note: I HAVE NOT TESTED IF DF SUPPORTS WS IN LANGUAGE FILES
; 1 : Combine words to remove white space
; X where X is a NEGATIVE NUMBER: trim everything to the left of X whitespace counting from the right
;Eg input phrase is "I have a dog"
;0 returns "I have a dog"
;1 returns "Ihaveadog"
;-1 returns "dog"
;-2 returns "adog"
;ect...

Download Here

Feel Free to ask any questions.
« Last Edit: January 22, 2012, 11:38:02 am by Tecknojock »
Logged

Dsarker

  • Bay Watcher
  • Ἱησους Χριστος Θεου Υἱος Σωτηρ
    • View Profile
Re: Dwarf Fortress Language Creation Script
« Reply #1 on: January 21, 2012, 08:02:10 pm »

Keeping track of this.
Logged
Quote from: NewsMuffin
Dsarker is the trolliest Catholic
Quote
[Dsarker is] a good for nothing troll.
You do not convince me. You rationalize your actions and because the result is favorable you become right.
"There are times, Sember, when I could believe your mother had a secret lover. Looking at you makes me wonder if it was one of my goats."

thetyler101

  • Bay Watcher
  • [SKULKING]
    • View Profile
Re: Dwarf Fortress Language Creation Script
« Reply #2 on: January 22, 2012, 09:31:14 am »

I think the download link is broken.   :'(
Logged

Give that bitch some stone crafts, bitches love stone crafts.

Tecknojock

  • Bay Watcher
    • View Profile
Re: Dwarf Fortress Language Creation Script
« Reply #3 on: January 22, 2012, 11:39:09 am »

Yep, it was.  It's been fixed.  I really should of checked my links after posting it  :P
Thanks for notifying me.
« Last Edit: January 22, 2012, 11:43:18 am by Tecknojock »
Logged

Trapezohedron

  • Bay Watcher
  • No longer exists here.
    • View Profile
Re: Dwarf Fortress Language Creation Script
« Reply #4 on: January 22, 2012, 12:06:19 pm »

Logged
Thank you for all the fish. It was a good run.

Kaelem Gaen

  • Bay Watcher
  • And then it appeared the most terrifying creature
    • View Profile
Re: Dwarf Fortress Language Creation Script
« Reply #5 on: January 23, 2012, 09:13:16 pm »

Looks interesting, does this mean (assuming Dwarven uses English grammar) we can start talking in Dwarven or other languages?

In case I'm being foolish, is this similar to DFlang instead?
« Last Edit: January 23, 2012, 09:17:37 pm by Kaelem Gaen »
Logged

Tecknojock

  • Bay Watcher
    • View Profile
Re: Dwarf Fortress Language Creation Script
« Reply #6 on: January 24, 2012, 11:21:24 am »

It might be, what's DFlang?  If it is, I feel kind of foolish not looking a little harder before spending time writing this for myself.

Seems that it is. That one is probably better in that it will generate similar words from a list.

This one just dumps the language file and expects you to run it through a translation service, so you will have real foreign words instead of foreign sounding words.

I wish I would have looked a little harder before writing this to deal with all the languages I was creating.

If you  really want it, I could write the former.
« Last Edit: January 24, 2012, 11:44:46 am by Tecknojock »
Logged

Dsarker

  • Bay Watcher
  • Ἱησους Χριστος Θεου Υἱος Σωτηρ
    • View Profile
Re: Dwarf Fortress Language Creation Script
« Reply #7 on: January 24, 2012, 04:33:32 pm »

I prefer this one.
Logged
Quote from: NewsMuffin
Dsarker is the trolliest Catholic
Quote
[Dsarker is] a good for nothing troll.
You do not convince me. You rationalize your actions and because the result is favorable you become right.
"There are times, Sember, when I could believe your mother had a secret lover. Looking at you makes me wonder if it was one of my goats."