Bay 12 Games Forum

Please login or register.

Login with username, password and session length
Advanced search  

Author Topic: [Solved] DF through SSH missing glyphs  (Read 532 times)

pepi55

  • Escaped Lunatic
    • View Profile
[Solved] DF through SSH missing glyphs
« on: January 04, 2021, 03:40:56 pm »

Hello,

There is this weird issue I keep getting whenever I try to play DF over SSH... I test the glyphs using curl http://www.orenwatson.be/cp437.htm in the terminal and everything shows up correctly in the terminal (also when SSH'ing to the server).


When running DF however, it stops displaying about half the characters. This is just running the intro video:




This only happens when I connect from ARM devices. Not entirely sure if that is the cause for this but I have tried:
x64 Linux laptop (works)
x64 Windows laptop (works)
x64 Windows desktop (works)
Android phone (Termius,JuiceSSH) (doesnt work)
RPi 400 (doesnt work)

Where "works" means that all tiles are rendered, gameplay is flawless and "doesnt work" means that I get the aforementioned issue.

I run DF on an x64 headless linux server (no Xserver, just plain old TTY). Curiously, on the server itself, the same thing happens. On it when I connect a monitor, curl works and DF doesnt show everything.

Does anyone have any idea what is happening and how I can "fix" it to work on my phone/rpi too?

Additional info: starting a game works fine but as you might expect, characters are missing and everything is unclear.

Thanks in advance
« Last Edit: January 04, 2021, 07:59:41 pm by pepi55 »
Logged

Quietust

  • Bay Watcher
  • Does not suffer fools gladly
    • View Profile
    • QMT Productions
Re: DF through SSH missing glyphs
« Reply #1 on: January 04, 2021, 04:07:55 pm »

Dwarf Fortress's TEXT mode doesn't actually use CP437 - it uses UTF-8 with a lookup table (at the end of "g_src/basics.cpp").
Make sure your session's locale is set to something appropriate (e.g. en_US.UTF-8) and that your SSH client is also configured appropriately.
Logged
P.S. If you don't get this note, let me know and I'll write you another.
It's amazing how dwarves can make a stack of bones completely waterproof and magmaproof.
It's amazing how they can make an entire floodgate out of the bones of 2 cats.

pepi55

  • Escaped Lunatic
    • View Profile
Re: DF through SSH missing glyphs
« Reply #2 on: January 04, 2021, 05:28:30 pm »

Thanks for the info. That actually helps since I was expecting it to use cp437.

With session's locale I assume you mean the locale of the client (the one connecting)? Or are you exclusively talking about the SSH session?
Also, do you happen to know what needs to be configured for the SSH client to work?

Thanks again
Logged

pepi55

  • Escaped Lunatic
    • View Profile
Re: DF through SSH missing glyphs
« Reply #3 on: January 04, 2021, 07:58:59 pm »

Solved! It was indeed the locale causing issues. When logging in through the working computers the locale is set on login. The not working machines didnt do that and the server kept its "POSIX" locale instead of the needed utf-8 locale.

So setting the server's locale to anything utf-8 solved my problem! Thanks for the help
Logged