Angband.oook.cz
Angband.oook.cz
AboutVariantsLadderForumCompetitionComicScreenshotsFunniesLinks

Go Back   Angband Forums > Angband > Vanilla

Reply
 
Thread Tools Display Modes
Old October 19, 2022, 05:14   #1
danbang
Rookie
 
Join Date: Oct 2022
Posts: 8
danbang is on a distinguished road
Question How do I change which symbol means what? eg. Open Floor to be displayed as a dot

After changing the font, my Angband (v3.5.1 for Kubuntu Linux 20.04) displays open floor tiles as a square with a dotted outline, the symbol for "this font undefined for this character", rather than the little dot. This is a problem because an empty room will seem filled with squares, rather than being obviously empty. Sometimes I don't notice monsters if their symbol is similar to an empty square, such as a gray capital C or capital O.

I want to change the symbol for "open floor" to another character more suitable for my choice of font. How do I do this?

A web search reveals that this is possible but doesn't give info specific enough that I can do it. There is mention of a "user prefs file" which I am supposed to find in the "lib/customize/" folder, namely "pref.prf", but I can't find these files anywhere. Does that mean I need to create my own "lib/customize/" directory? Do I put this under ~/.angband/Angband ? (as in ~/.angband/Angband/lib/customize ?)

There is no mention of the format of the pref.prf file. If I am to create my own, how do I specify that I want to change Open Floor Tile to 0xB7? (I can't tell what the current character is, but I think it's 0x1F.)

Thanks for any help you can give.

Dan Bang
danbang is offline   Reply With Quote
Old October 19, 2022, 09:17   #2
Werbaer
Adept
 
Join Date: Aug 2014
Posts: 181
Werbaer is on a distinguished road
Quote:
Originally Posted by danbang View Post
There is mention of a "user prefs file" which I am supposed to find in the "lib/customize/" folder, namely "pref.prf", but I can't find these files anywhere. Does that mean I need to create my own "lib/customize/" directory? Do I put this under ~/.angband/Angband ? (as in ~/.angband/Angband/lib/customize ?)
Dan Bang
You need to edit the file "terrain.txt".
It's either in lib/edit or lib/gamedata (don't know which path in your version).
Werbaer is offline   Reply With Quote
Old October 19, 2022, 11:30   #3
danbang
Rookie
 
Join Date: Oct 2022
Posts: 8
danbang is on a distinguished road
Quote:
Originally Posted by Werbaer View Post
You need to edit the file "terrain.txt".
It's either in lib/edit or lib/gamedata (don't know which path in your version).
Thank you for your reply. This is the second time I've come across reference to directory "lib/(something)" such as lib/customize, lib/edit, or lib/gamedata.

Where do I find this lib/ directory? I've looked under ~/.angband/Angband, under /var/games/angband, under /lib (there is no /lib/customize, /lib/edit, or /lib/gamedata as an absolute path, and the files under /lib do not seem to be related to Angband), nor under /usr/lib.

Thanks for any help you can give.

Dan Bang
danbang is offline   Reply With Quote
Old October 19, 2022, 12:06   #4
danbang
Rookie
 
Join Date: Oct 2022
Posts: 8
danbang is on a distinguished road
Quote:
Originally Posted by danbang View Post
Where do I find this lib/ directory? I've looked under ~/.angband/Angband, under /var/games/angband, under /lib (there is no /lib/customize, /lib/edit, or /lib/gamedata as an absolute path, and the files under /lib do not seem to be related to Angband), nor under /usr/lib.
I was able to answer my own question, but am posting it here so others might benefit.

The answer is: I have to know where my own angband is installed. In my case of Ubuntu 20.04, I used the command "apt-file list angband" to see where the files were installed in my Angband 3.5.1. It turns out that it was under /etc/angband (I would never have guessed), and there are the directories /etc/angband/edit and /etc/angband/prefs (there is no /etc/angband/lib or any subdirectories under it).

In any case, I was able to find /etc/angband/edit/terrain.txt ; however, the symbol for an Open Floor was just a "." (the period/full stop), which is what I already wanted, but that was not what was displayed on my screen, so I looked for some other setting that would override this.

I did eventually find the file /etc/angband/prefs/font-x11.prf which showed exactly what I had predicted:
Code:
# open floor
F:1:all:0x01:0x1F
# invisible trap
F:2:all:0x01:0x1F
I changed the 0x1F, which shows as a central dot in the crummy fixed fonts but a dotted square in the beautiful fonts that I like, to 0xB7 which is a better-defined character (0x1F is not supposed to be a printable character), as follows:
Code:
# open floor
F:1:all:0x01:0xB7
# invisible trap
F:2:all:0x01:0xB7
I used the file font-x11.prf as it seems to apply to my system, but I also see font-sdl.prf and font-win.prf which might apply to other systems that use, presumably, Windows or SDL. I also see font-xxx.prf but that seems to be something else entirely.

Anyway: success! Now the dungeon map displays correctly. Just wanted to share with others.

Dan Bang
danbang is offline   Reply With Quote
Old October 19, 2022, 14:35   #5
backwardsEric
Swordsman
 
Join Date: Aug 2019
Posts: 436
backwardsEric is on a distinguished road
What you did changed it for all users on the system, which is fine, but if you wanted to change it only for the current user's account (or you don't have super-user access and can't change the system-wide installation) you could have put the changes you wanted to make to font-x11.prf in ~/.angband/Angband/font-x11.prf (~/.angband/Angband is the "user directory" for a typical Angband installation on Linux or other Unix-like systems other than macOS).

The symbols for monsters, objects, and terrain can also be edited in-game. When a character is loaded use '~' to bring up the knowledge menus. Go into the appropriate category, i.e. "object knowledge", "monster knowledge", or "feature knowledge". Then select the thing to change and press 'v' to allow selection of the new symbol. When done with the changes, use '=' to bring up the options menu and then use the "Save visuals" option to save the symbols to a preference file. By default it will save them to <name of current character>.prf in the "user directory" which would only affect characters with that name. You could change the name to user.prf (affects all characters for the account) or font-<frontend-name>.prf (where <frontend-name> is x11, sdl, gcu, ...) to affect the appearance when using a particular front end.
backwardsEric is offline   Reply With Quote
Old October 21, 2022, 01:27   #6
sffp
Swordsman
 
Join Date: Apr 2020
Location: DC Area
Posts: 434
sffp is on a distinguished road
I gotta know - what font is it you lkike
sffp is offline   Reply With Quote
Reply

Tags
display, symbols


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Changing symbol for items/monsters mibert Sil 2 June 29, 2016 13:54
Nexus means -ve stat Muscleguy Vanilla 12 April 28, 2015 19:14
What does this diamond symbol represent? reed Vanilla 3 May 25, 2014 15:32
3.3.0 Treasure not displayed Dranken Vanilla 4 August 31, 2011 19:24
3.0.9 feature/item symbol change Hariolor Vanilla 8 October 20, 2008 04:52


All times are GMT +1. The time now is 18:07.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2023, vBulletin Solutions Inc.