Angband.oook.cz
Angband.oook.cz
AboutVariantsLadderForumCompetitionComicScreenshotsFunniesLinks

Go Back   Angband Forums > Angband > Vanilla

Reply
 
Thread Tools Display Modes
Old January 29, 2010, 20:50   #1
Magnate
Angband Devteam member
 
Join Date: May 2007
Location: London, UK
Posts: 5,057
Magnate is on a distinguished road
Send a message via MSN to Magnate Send a message via Yahoo to Magnate
Prefs and savefiles

I'm going to try and solve some long-standing pet peeves with preferences for 3.1.3. I think this means a fairly fundamental review of the whole setup, but I thought I'd gather some views here on what other people want. I'll start with a list of things that need saving somewhere, broken up as logically as I can:

1. current character: name, stats, equipment/inventory/quiver, flavour knowledge, squelch settings, autoinscriptions, macros/keymaps, options, randarts, history/notes
2. current dungeon level: map, monsters, floor items, traps, doors, glyphs, terrain etc. (could also include monster drops if predetermined)
3. current store status: owner, inventory
(current home inventory could go with character or stores)
4. object knowledge: metagame "everseen" status of base objects, egos, artifacts
5a. squelch settings for new characters
5b. autoinscriptions for new characters
5c. macros/keymaps for new characters
6. visual preferences (monster/feature symbols/colours etc.)
7. monster memory
8. hall of fame
9. message history
10. artifact memory (not currently used)
11. store history: buy/sell data for market pricing, owner relationships etc. (not currently used)

Currently the savefile stores 1, 2, 3, 4, 7 and 9. The pref files store 5 & 6, and 8 is separate.

I'm interested in your views on how to store these. My thinking is that the savefile should store a bare minimum, i.e. 1 & 2. I think 4, 7 & 10 should be stored separately as metagame data carried across characters. 5 should be organised on a per-class basis, one pref file per class (does anyone really adjust any of these by race?). 6, 8 and 9 should all be stored separately (does anyone adjust visual prefs by class?).

Stores I leave to MarbleDice, or someone else who's going to work on them. The as-is behaviour is to include 3 in the savefile and ignore 11, but if we're moving towards any kind of market pricing system or fixed inventories, or dungeon stores, or whatever, I think they should be saved separately.

I'll stop there and see what people's initial views are. I'll come back with some more specific ideas for changes to pref files (my remit doesn't really extend to messing with the savefile, but I included it for completeness of thinking). For now, have I captured everything we need to save, and grouped it sensibly?
Magnate is offline   Reply With Quote
Old January 29, 2010, 21:21   #2
Marble Dice
Swordsman
 
Join Date: Jun 2008
Location: Columbia, MO. USA
Posts: 405
Marble Dice is on a distinguished road
Maybe you should add...

12. All non-adult option settings, including life warning, base delay, etc
13. Adult option settings

...to your list?

It would make the most sense to me to have all "game state" information in the save file, with configuration type stuff in a settings file (options, knowledge, etc), and macros/keymaps, squelch, and inscriptions in a per user/class pref file hierarchy. The way I see it, this would mean:

Save file = 1, 2, 3, 9, 11, 13
Settings file = 4, 6, 7, 10, 12
Scores file = 8
Pref files = 5

Last edited by Marble Dice; January 29, 2010 at 21:35.
Marble Dice is offline   Reply With Quote
Old January 29, 2010, 21:32   #3
joelsanda
Apprentice
 
joelsanda's Avatar
 
Join Date: Sep 2007
Location: Rocky Mountains, USA
Posts: 84
joelsanda is on a distinguished road
As long as 3.1.3 can read 3.1.2 savefiles and 3.1.4 can read 3.1.3 savefiles my ranger will be dancing a jig.
joelsanda is offline   Reply With Quote
Old January 30, 2010, 18:57   #4
Magnate
Angband Devteam member
 
Join Date: May 2007
Location: London, UK
Posts: 5,057
Magnate is on a distinguished road
Send a message via MSN to Magnate Send a message via Yahoo to Magnate
More thoughts

Quote:
Originally Posted by Marble Dice View Post
Maybe you should add...

12. All non-adult option settings, including life warning, base delay, etc
13. Adult option settings

...to your list?
Yes, though I'd split them along the lines of

12. All option settings people leave unchanged from game to game
13. Option settings that people change for a different type of game

... these are perhaps equivalent, though I would put the cheat options into 13. I presume "adult" means birth options?
Quote:
It would make the most sense to me to have all "game state" information in the save file, with configuration type stuff in a settings file (options, knowledge, etc), and macros/keymaps, squelch, and inscriptions in a per user/class pref file hierarchy. The way I see it, this would mean:

Save file = 1, 2, 3, 9, 11, 13
Settings file = 4, 6, 7, 10, 12
Scores file = 8
Pref files = 5
Yes, I pretty much agree with this. What I think this means, and really the whole reason I got interested in this in the first place, is that macros, keymaps, squelch settings and autoinscriptions need to prompt the user to "save for this character only" or "save for all {class}s" (or even all chars). Now, rather than make the user remember to save them, my suggestion is that on exit we check whether any of them have changed and prompt at that point: "squelch settings have changed - save for this character only, all {class}s, all characters, or discard changes (t/c/a/d)". Ditto for macros, keymaps and autoinscriptions (four prompts might get tedious - perhaps one prompt for all four, and we can save them all in the same file).

So I think this is not so much about rewriting pref file handling (though the format could be improved), it's about improving the macro interface. Squelch settings and autoinscriptions are both shown in the knowledge menu - I think the macro/keymap interface needs to list the current macros & keymaps, so you can easily modify or delete them. You also need to know which pref file a particular setting comes from: global (user.prf), your personal (chrisc.prf), this class (ranger.prf) or this char (Explorington.prf) - so that you can save changes to the correct file.

My other thought is that the settings file probably needs to be in plain text, like pref files. Yes this means people can cheat and hack their monster memory (or whatever), but I think editability outweighs that.

Anyone have any views on any of this?
Magnate is offline   Reply With Quote
Old January 30, 2010, 19:15   #5
Pete Mack
Prophet
 
Join Date: Apr 2007
Location: Seattle, WA
Posts: 5,327
Donated: $40
Pete Mack is on a distinguished road
macros cannot be saved in a save file, though keymaps can.
macros are OS-dependent; you really don't want to create a bogus macro from Linux on Windows, etc.
Pete Mack is offline   Reply With Quote
Old January 30, 2010, 20:29   #6
Marble Dice
Swordsman
 
Join Date: Jun 2008
Location: Columbia, MO. USA
Posts: 405
Marble Dice is on a distinguished road
Quote:
Originally Posted by Magnate View Post
I presume "adult" means birth options?
Well, if you want to get technical, birth options are the options you can change in the = menu. Adult options are fixed at character birth, based on your birth options. You can change birth options any time, but they have no effect on your game - other than to set the adult options for a new character, which in turn affect that character throughout its lifetime. So birth options are a setting, but adult/cheat options would probably be in the savefile (since they do affect game state).

Quote:
Originally Posted by Magnate View Post
My other thought is that the settings file probably needs to be in plain text, like pref files. Yes this means people can cheat and hack their monster memory (or whatever), but I think editability outweighs that.
That's no sweat off my back, people already have an option to cheat for complete knowledge - and and option to cheat for complete knowledge without flagging their character, but it requires they generate or reference spoiler files. You could also split the settings file into two, along these lines:

Save file = 1, 2, 3, 9, 11, 13
Knowledge file = 4, 7, 10
Settings file = 6, 12
Scores file = 8
Pref files = 5

Knowledge and settings have the same scope (both are per-user files), but might behave differently enough to warrant it - knowledge tends only to get added to, and has no direct need of a non-binary format. Settings should be in plain text and easy to edit, and it might get changed periodically at the player's whim.
Marble Dice is offline   Reply With Quote
Old January 31, 2010, 10:22   #7
fph
Knight
 
Join Date: Apr 2009
Location: Berlin / Italy
Posts: 768
fph is on a distinguished road
Just a small usability glitch. I think the two names "settings file" and "pref file" are too similar and do not convey meaning to the final user.
I suggest this renaming:
-save file -> character settings "CharacterName.angband" (yes, we do need an Angband-specific extension)
-knowledge/settings file -> player settings, "player.prf"
-high scores -> global settings, "global.prf" (or highscores.prf is ok if they only include those)
-pref files -> class settings, "warrior.prf", "mage.prf", ...
fph is offline   Reply With Quote
Old January 31, 2010, 19:19   #8
bio_hazard
Knight
 
bio_hazard's Avatar
 
Join Date: Dec 2008
Posts: 614
bio_hazard is on a distinguished road
What about the term windows? I keep having to set them up every time I launch the game, which is kind of annoying.

Also, having some canned, pre-installed options for things like squelching might be nice. If there are common settings that lots of players use, maybe they could be included.
bio_hazard is offline   Reply With Quote
Old January 31, 2010, 22:10   #9
Magnate
Angband Devteam member
 
Join Date: May 2007
Location: London, UK
Posts: 5,057
Magnate is on a distinguished road
Send a message via MSN to Magnate Send a message via Yahoo to Magnate
Quote:
Originally Posted by bio_hazard View Post
What about the term windows? I keep having to set them up every time I launch the game, which is kind of annoying.

Also, having some canned, pre-installed options for things like squelching might be nice. If there are common settings that lots of players use, maybe they could be included.
Agreed.

Term window management is port-specific: which port do you use?
Magnate is offline   Reply With Quote
Old January 31, 2010, 23:24   #10
takkaria
Veteran
 
takkaria's Avatar
 
Join Date: Apr 2007
Posts: 1,930
Donated: $40
takkaria is on a distinguished road
Quote:
Originally Posted by Marble Dice View Post
Save file = 1, 2, 3, 9, 11, 13
Knowledge file = 4, 7, 10
Settings file = 6, 12
Scores file = 8
Pref files = 5
These are the groupings I agree with, though I don't understand why preferences and settings are separate. The knowledge file should be stored as a binary, mostly for efficiency reasons (storing bitflags in ASCII is pointlessly verbose when there are cheat options), and also because there's no reason to edit it.
__________________
takkaria whispers something about options. -more-
takkaria 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
Color prefs Pete Mack Vanilla 4 January 25, 2010 19:33
Where are windows and graphic prefs stored? Mondkalb Vanilla 0 May 30, 2009 08:23
Obliterating k_idx from the savefiles and object.txt zaimoni Development 0 April 30, 2009 01:37
Visuals and Savefiles Narvius Vanilla 2 January 20, 2009 20:05
Linux/Unix users: Where should savefiles be stored? takkaria Vanilla 34 November 3, 2007 11:36


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


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