Angband.oook.cz
Angband.oook.cz
AboutVariantsLadderForumCompetitionComicScreenshotsFunniesLinks

Go Back   Angband Forums > Angband > Vanilla

Reply
 
Thread Tools Display Modes
Old September 16, 2010, 22:31   #1
krugar
Apprentice
 
krugar's Avatar
 
Join Date: Sep 2010
Location: Portugal
Age: 53
Posts: 76
krugar is on a distinguished road
How to set visuals permanently?

I've made changes to some of the visuals under Feature Knowledge ('~' menu). Then I proceeded to dump the feature attr/chars (option 'v on the '=' menu).

How can I have Angband use these new preferences when loading up? The dump was saved as feature.prf. I don't want to name it after my character (neither I could since there exists already a file with that name) or after race since I intend it to be in effect for all games.
krugar is offline   Reply With Quote
Old September 17, 2010, 09:27   #2
Hajo
Adept
 
Hajo's Avatar
 
Join Date: Aug 2010
Posts: 142
Hajo is on a distinguished road
I have doubts that this is the official way, but it might work. I think that pref/font-xxx.prf always will be loaded, for both graphical and text modes.

You can edit font-xxx.prf and add a line like this:

Code:
%:feature.prf
This should load your feature.prf file.
__________________
I have a project problem? I have no project problem. I start a project, I work on it, it fails. No problem
Hajo is offline   Reply With Quote
Old September 17, 2010, 14:07   #3
krugar
Apprentice
 
krugar's Avatar
 
Join Date: Sep 2010
Location: Portugal
Age: 53
Posts: 76
krugar is on a distinguished road
Thank you, Hajo.

That prompt me in the right direction and to investigate a little further. Not sure either if this is a recommended method. But it worked perfectly.

Created a new file font.prf in the game's user directory and inserted there the alterations. This will load last and override the default settings where needed. It can also guarantee higher compatibility with new versions without having to make the change again every time one is made available. I guess I could also use part of the existing code in pref/font.prf just so I could be more selective of which interface to make the changes for, but I'm not concerned with that.

I think I'm finally getting the gist of Angband's configuration.
Only thing missing is where do I find the color mappings for the font*.prf family of files?
krugar is offline   Reply With Quote
Old September 17, 2010, 14:16   #4
Hajo
Adept
 
Hajo's Avatar
 
Join Date: Aug 2010
Posts: 142
Hajo is on a distinguished road
The font.prf in the user directory is better. I didn't know that such would work, so I learned something, too

I found this table with color indices (used in the pref files) and the color codes (used in the object/monster files)

Code:
/*
 * Angband "attributes" (with symbols, and base (R,G,B) codes)
 *
 * The "(R,G,B)" codes are given in "fourths" of the "maximal" value,
 * and should "gamma corrected" on most (non-Macintosh) machines.
 */
#define TERM_DARK		0	/* 'd' */	/* 0,0,0 */
#define TERM_WHITE		1	/* 'w' */	/* 4,4,4 */
#define TERM_SLATE		2	/* 's' */	/* 2,2,2 */
#define TERM_ORANGE		3	/* 'o' */	/* 4,2,0 */
#define TERM_RED		4	/* 'r' */	/* 3,0,0 */
#define TERM_GREEN		5	/* 'g' */	/* 0,2,1 */
#define TERM_BLUE		6	/* 'b' */	/* 0,0,4 */
#define TERM_UMBER		7	/* 'u' */	/* 2,1,0 */
#define TERM_L_DARK		8	/* 'D' */	/* 1,1,1 */
#define TERM_L_WHITE	9	/* 'W' */	/* 3,3,3 */
#define TERM_L_PURPLE	10	/* 'P' */	/* ??? */
#define TERM_YELLOW		11	/* 'y' */	/* 4,4,0 */
#define TERM_L_RED		12	/* 'R' */	/* 4,0,0 */
#define TERM_L_GREEN	13	/* 'G' */	/* 0,4,0 */
#define TERM_L_BLUE		14	/* 'B' */	/* 0,4,4 */
#define TERM_L_UMBER	15	/* 'U' */	/* 3,2,1 */

#define TERM_PURPLE     16	/* 'p' */
#define TERM_VIOLET     17	/* 'v' */
#define TERM_TEAL       18	/* 't' */
#define TERM_MUD        19	/* 'm' */
#define TERM_L_YELLOW   20	/* 'Y' */
#define TERM_MAGENTA    21	/* 'i' */
#define TERM_L_TEAL     22	/* 'T' */
#define TERM_L_VIOLET   23	/* 'V' */
#define TERM_L_PINK     24	/* 'I' */
#define TERM_MUSTARD    25	/* 'M' */
#define TERM_BLUE_SLATE 26	/* 'z' */
#define TERM_DEEP_L_BLUE 27	/* 'Z' */
__________________
I have a project problem? I have no project problem. I start a project, I work on it, it fails. No problem
Hajo is offline   Reply With Quote
Old September 17, 2010, 14:23   #5
krugar
Apprentice
 
krugar's Avatar
 
Join Date: Sep 2010
Location: Portugal
Age: 53
Posts: 76
krugar is on a distinguished road
Ah! Perfect. Silly me, I seem to remember seeing that sometime ago too. On a source file, I think. Or maybe one of the configuration files. I shall look into it later tonight. It should be just a matter of converting to hexadecimal, I suppose.

Thanks again, Hajo.
krugar is offline   Reply With Quote
Old September 17, 2010, 14:58   #6
Hajo
Adept
 
Hajo's Avatar
 
Join Date: Aug 2010
Posts: 142
Hajo is on a distinguished road
You're welcome. This table was from src/defines.h, but some of the file headers in edit/*.txt do have similar information.
__________________
I have a project problem? I have no project problem. I start a project, I work on it, it fails. No problem
Hajo is offline   Reply With Quote
Reply


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
Idea's for a revised set of prayer books fyonn Vanilla 44 May 12, 2010 23:14
Visuals and Savefiles Narvius Vanilla 2 January 20, 2009 20:05
Thread limit. How to set? Timo Pietilä Oook! 2 April 26, 2007 18:38


All times are GMT +1. The time now is 19:34.


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