View Issue Details
ID | Project | Category | View Status | Date Submitted | Last Update |
---|---|---|---|---|---|
0009921 | Dwarf Fortress | Creatures | public | 2016-07-15 12:21 | 2016-08-08 15:04 |
Reporter | Dirst | Assigned To | lethosor | ||
Priority | low | Severity | minor | Reproducibility | always |
Status | acknowledged | Resolution | open | ||
Platform | Windows | OS | Windows | OS Version | 7 |
Product Version | 0.43.05 | ||||
Summary | 0009921: Creature tiles specified by quoted text displayed incorrectly | ||||
Description | Mantis doesn't like special characters, so I will use names rather than glyphs. If a creature's tile is specified by [CREATURE_TILE:'a'] but using any accented letter then it actually appears as character 195 in the loading screen and on the map. Using a numeric code to define the tile works as expected. The problem is consistent when the raw file is encoded at UTF-8. Converting it to what Notepad++ calls "OEM-US" reveals that the string is actually stored as two bytes 195 and 162. | ||||
Steps To Reproduce | Use Notepad++ to mod a creature with [CREATURE_TILE:'a'] but with any accented letter, and spawn it in the arena. | ||||
Additional Information | It's not worth the effort to cram a Unicode parser into the raw parser, but the game could emit something to the error log when a tile string has more than one byte in it. MODDED_CREATURE:Multibyte or Unicode string for creature tile | ||||
Tags | raw file | ||||
|
From what I remember, the raw files are (or used to be) CP437-encoded. Can you try saving with that encoding instead and see if it works? Edit: "latin1" might be equivalent for accented letters, if you don't have a CP437 option. |
|
I realized it was an encoding problem when I tried to use a different accented character and got the same creature tile, so it's entirely on my end but I think it's an easy mistake to make. The choices available in one of the more popular text editors for modding: http://i8.photobucket.com/albums/a28/8gon/Notepadd.png You have to pick "OEM-US" to get it to encode properly, which is not a default or obvious. I think an error message in DF's log would suffice to put most modders on the right track. |
|
I'm having a hard time coming up with a way to tell whether a file mistakenly contains UTF-8 characters or multiple CP437 ones, but I agree that some kind of warning would be more helpful. |
|
That was why I thought it should warn about "Multibyte or Unicode string" where one character is expected (creature tile, workshop tile, plant growth, etc.). |
Date Modified | Username | Field | Change |
---|---|---|---|
2016-07-15 12:21 | Dirst | New Issue | |
2016-07-15 12:25 | Dirst | Tag Attached: raw file | |
2016-07-23 10:54 | lethosor | Note Added: 0035693 | |
2016-07-23 10:54 | lethosor | Assigned To | => lethosor |
2016-07-23 10:54 | lethosor | Status | new => feedback |
2016-07-23 10:55 | lethosor | Note Edited: 0035693 | |
2016-07-24 14:07 | Dirst | Note Added: 0035701 | |
2016-07-24 14:07 | Dirst | Status | feedback => assigned |
2016-07-24 14:08 | Dirst | Note Edited: 0035701 | |
2016-07-28 19:07 | lethosor | Note Added: 0035720 | |
2016-07-28 19:07 | lethosor | Status | assigned => acknowledged |
2016-08-08 15:04 | Dirst | Note Added: 0035769 |