OSDN Git Service

Revert ef43e5d32 [Change] 変愚蛮怒名義を馬鹿馬鹿蛮怒名義に変更. / Change naming from Hengband to Bakaba...
[hengband/hengband.git] / lib / help / editor.txt
1 [[[[G|=== Auto-Picker/Destroyer Editor ===
2
3 Please choose one of the following online help files:
4
5     (a) The Basics of Auto-picker Editor      (#Editor)            
6     (b) Cut and Paste                         (#CutAndPaste)       
7     (c) Register to Auto-picker               (#RegisterName)      
8     (d) Insert Name from your Inventory       (#InsertObjectName)  
9     (e) Insert Fixed Keyword                  (#InsertKeyword)     
10     (f) Change Multiple Lines at Once         (#MultiLines)        
11     (g) Conditionals                          (#Conditionals)      
12     (h) Auto Register an Item without Editor  (#AutoRegister)      
13
14     (i) Format of Auto-picker/destroyer       (#AutopickFormat)      
15     (j) Format of Conditionals                (#ConditionFormat)     
16     (k) Sample Preference File                (lib/pref/pickpref.prf)
17
18 ***** [a] editor.txt#Editor
19 ***** [b] editor.txt#CutAndPaste
20 ***** [c] editor.txt#RegisterName
21 ***** [d] editor.txt#InsertObjectName
22 ***** [e] editor.txt#InsertKeyword
23 ***** [f] editor.txt#MultiLines
24 ***** [g] editor.txt#Conditionals
25 ***** [h] editor.txt#AutoRegister
26 ***** [i] editor.txt#AutopickFormat
27 ***** [j] editor.txt#ConditionFormat
28 ***** [k] ../pref/pickpref.prf
29
30 ***** <Editor>
31 [[[[G|--- The Basics of Auto-picker Editor ---
32
33 The "auto-picker editor" is a special text editor to write preferences
34 for auto-picker/destroyer.
35
36 To open the editor, you can press the _ key in the game or choose
37 "(P) Auto-picker/destroyer editor" in the options panel (=).
38
39 Like normal text editor, you can move the cursor by Left, Right, Up,
40 Down arrow keys, and Home, End, PageUp, and PageDown keys.  And any
41 letter keys pressed are written as a text.
42
43 Press ^W to finish the edito.  All changes will be saved automatically.
44 Or press ^Q to quit and discard all changes.
45
46 Press ESC to open a command menu.
47 +---------------------------+
48 | a) Help                   |
49 | b) Quit without save   ^Q |
50 | c) Save & Quit         ^W |
51 | d) Revert all changes  ^Z |
52 | e) Edit                 > |
53 | f) Search               > |
54 | g) Move cursor          > |
55 | h) Insert...            > |
56 | i) Adjective (general)  > |
57 | j) Adjective (special)  > |
58 | k) Keywords (noun)      > |
59 | l) Command letter       > |
60 +---------------------------+
61 Press a-l to choose a command or open a sub-menu.  Also you can press
62 ^Q, ^Z, etc. to use commands without opening this menu.
63
64
65 ***** <CutAndPaste>
66 [[[[G|--- Cur and Paste
67
68 Cut and Paste are useful when you want to write many similer lines, or
69 want to swap lines.
70 Open submenu "e) Edit >",
71 +-------------------------+
72 | a) Cut               ^X |
73 | b) Copy              ^C |
74 | c) Paste             ^V |
75 | d) Select block      ^G |
76 | e) Kill rest of line ^K |
77 | f) Delete character  ^D |
78 | g) Backspace         ^H |
79 | h) Return            ^J |
80 | i) Return            ^M |
81 +-------------------------+
82
83 You can select a segment of the text using shift key + arrow keys.
84 Selected text will be displayed in yellow.  You can press ^X to cut
85 the selected text, or press ^C to copy the selected text to the
86 clipboard.  Contents of the clipboard will be pasted on pressing ^V.
87
88 Note that it's possible that Hengband cannot recognize shift+arrow
89 keys on a minor environment.  In that case, you can press ^G and then
90 move cursor to select text.
91
92
93 ***** <RegisterName>
94 [[[[G|--- Register to Auto-picker ---
95
96 ***** <InsertObjectName>
97 [[[[G|--- Insert Name from your Inventory ---
98
99 ***** <InsertKeyword>
100 [[[[G|--- Insert Fixed Keyword ---
101
102 ***** <MultiLines>
103 [[[[G|--- Change Multiple Lines at Once ---
104
105 ***** <Conditionals>
106 [[[[G|--- Conditionals ---
107
108 ***** <AutoRegister>
109 [[[[G|--- Auto Register an Item without Editor ---
110
111 ***** <AutopickFormat>
112 [[[[G|--- Format of Auto-picker/destroyer ---
113
114 Hengband can automatically pick up or destroy specified objects when
115 you write objects name in the file "pickpref.prf" or
116 "pickpref-<<playername>>.prf" in the user directory, this will be
117 ~/.angband/Hengband/ for UNIX, or Hengband\lib\user\ for other
118 operating systems.
119
120 The game will read the file "pickpref-<<playername>>.prf" first and
121 then read the file "pickpref.prf".  The first-read file takes
122 priority.
123
124 You may use the '$' command within the game to reread auto-picker
125 files.
126
127 Notes:
128 Maximum number of active lines is 1009.
129 A line with a header '#' is a comment.
130
131 --- Editing the file ---
132
133 Command letter:
134
135       Each line determines the actions taken when you step over a kind
136   of object.  Starting a line with '!' indicates that you wish to
137   destroy this kind of object.  Starting a line with '~' indicates
138   that you wish to leave this kind of object on the floor.  Starting a
139   line with ';' indicates that you wish to force the game to ask you
140   if you want to pick the item up or not.  Otherwise, your character
141   will automatically attempt to pick up the object.
142        There is an additional command letter '('.  It indicates that
143   you don't wish this item to be displayed in full map. see below.
144
145   Notes:
146   If you want to disable the effect of the '!' indicator temporally,
147   use 'always_pickup' option.
148
149
150 Keywords:
151        After the command letter may come one or more keywords.  They are:
152
153   all               : All items match.
154   collecting        : Matches if you already have that same item.
155   unaware           : Items with unknown effects match.
156   unidentified      : Unidentified items match.
157   identified        : Identified items match.
158   *identified*      : *Identified* items match.
159   dice boosted      : Weapons with boosted damage dice match.
160   more than N dice  : Weapons with dice (dd * ds) better than +N match.
161   more bonus than N : Items which has more magical bonus than (+N) match.
162   worthless         : Items which you cannot sell match.
163   artifact          : Artifacts items match.
164   ego               : Ego items match.
165   good              : {good} items match.
166   nameless          : Non ego/non artifact items match.
167   average           : {average} items match.
168   rare              : Rare equipment such as Dragon armor etc. match.
169   common            : Any equipments except 'rare' equipment match.
170   wanted            : Wanted monster's corpses or skeletons match.
171   unique monster's  : Unique monster's corpses, skeletons or statues match.
172   human             : Human corpses or skeletons match.
173   unreadable        : Spellbooks other than those you can read match.
174   first realm's     : Your first magic realm's spellbooks match.
175   second realm's    : Your second magic realm's spellbooks match.
176   first             : First one of four spellbooks in each realm match.
177   second            : Second one of four spellbooks in each realm match.
178   third             : Third one of four spellbooks in each realm match.
179   fourth            : Fourth one of four spellbooks in each realm match.
180
181   items             : All items match. Use it with an adjective for 
182                       readability (i.e. "unaware items").
183   weapons           : All weapons including missile weapons match.
184   armors            : Any piece of armor (helm, cloak, body armor, shield,
185                       gloves, or boots) matches.
186   missiles          : Arrows, bolts, and shots match.
187   magical devices   : Wands, staffs, rods and scrolls match.
188   lights            : Light sources match.
189   junks             : Junk items like Shard of Pottery or etc. match.
190   corpses or skeletons : Corpses or skeletons of monsters match.
191   spellbooks        : All books match.
192   favorite weapons  : Weapons suitable for your class (for Priest, Monk,
193                       BeastMaster, ForceTrainer, Cavalry, and Ninja)
194
195   You may also use keywords which match specified kinds of equipment:
196   weapons, armors, missiles, magical devices, lights, junks, spellbooks, 
197   hafted weapons, shields, bows, rings, amulets, suits, cloaks, helms, 
198   gloves, boots.
199
200
201 Character strings:
202        After the keywords, you may write a character string. Only items 
203   whose name contains this character string as part of their name match. 
204   Upper or lower case makes no difference.
205        You must insert a ':' between your special keywords and character 
206   string, if both exist in one line.
207
208 Force start-of-line matching:
209   If the first character in a character string is '^', then the 
210   character string must match the beginning of a line.
211
212 !Mace           // Destroy Maces and Lead-Filled Maces.
213 !^Mace          // Destroy only Maces.
214
215
216 Examples:
217
218 !worthless items
219 Meaning:  "destroy all items that are worthless"
220
221 unaware potion
222 Meaning:  "pick up all unaware potions"
223
224 ~unidentified lites
225 Meaning:  "leave all unidentified light sources on the ground"
226
227 unidentified more than 25 dice weapons
228 Meaning:  "pick up all weapons with dice that total more than 25.  A 
229      weapon that is 2d13 qualifies, a weapon that is 5d5 does not."
230
231 Acquirement
232 Meaning:  "pick up anything that includes in its name the word 
233 'Acquirement'"
234
235 potion of Experience
236 Meaning:  "pick up anything named 'potion of experience'"
237
238 Lights:stone
239 Meaning:  "Pick up light sources named stone"
240
241 gloves:slaying
242 Meaning:  "Pick up gauntlets of slaying. Not rings of slaying."
243
244
245 Special Notes:
246
247   Lines will be evaluated in order, and first matched line will be 
248   applied. So you can write names of specific excellent items to pick 
249   up, followed by a general item name with '!' to destroy useless items.
250
251   ! Tips
252   !     In full map command ('M'), you can press M, N, K, or D to 
253   ! display locations of items for auto-pickup, leaving, auto-destroy 
254   ! or both auto-pickup and leaving.
255   !     Additional command letter '(' prevents this display.
256   !
257
258   If you begin the last string in a line with '#', this string will
259   be automatically inscribed on the item.
260
261
262   Strict syntax of each line is below.
263   
264   [! ~ ; (]
265   [[all] [collecting]
266    [unaware] [unidentified] [identified] [*identified*] 
267    [artifact] [ego] [good] [nameless] [average]
268    [worthless] [rare] [common]
269    [dice boosted] [more than N dice] [more bonus than N] 
270    [wanted] [unique monster's] [human] [unreadable] 
271    [first realm's] [second realm's] [first] [second] [third] [fourth] 
272    [items | weapons | favorite weapons | armors | missiles |
273     magical devices | lights | junks | corpses or skeletons | spellbooks |
274     hafted weapons | shields | bows | rings | amulets | suits | cloaks |
275     helms | gloves | boots] :]
276   [[^]part-of-item-name] [#auto-inscription-string]
277
278
279 ***** <ConditionFormat>
280 [[[[G|--- Format of Conditionals ---
281
282   The lines of pickpref.prf can be disabled/enabled using 
283   conditional expressions. 
284   The syntax is the same as that of other preference files.
285
286   - usage of condition expressions
287     ?:expr
288       If result of expr is "0", all lines below are disabled.
289       If result of expr is "1", all lines below are enabled.
290       Caution:It cannot be nested.
291
292   - usage to include other file
293     %:filename
294       Read a file named 'filename' as a new pick-pref file. The file 
295       must be in the user directory.
296
297   - usage of operators
298     [EQU arg1 arg2 ...]
299       If all args are the same as arg1, returns "1", or else returns "0".
300     [IOR arg1 arg2 ...]
301     [AND arg1 arg2 ...]
302       IOR evaluates and returns all args' logical OR. IAND is logical AND.
303     [NOT arg]
304       Returns "0" if arg is "1", or else returns "1"
305     [LEQ arg1 arg2 ...]
306     [GEQ arg1 arg2 ...]
307       Compare args as string. LEQ returns "1" if (arg1 <= arg2 <= ...) ,
308       GEQ returns "1" if (arg1 >= arg2 >= ...) otherwise returns "0".
309
310   - Special variables
311     $RACE
312      Returns name of player race. One of below:
313       Human, Half-Elf, Elf, Hobbit, Gnome, Dwarf, Half-Orc,
314       Half-Troll, Amberite, High-Elf, Barbarian, Half-Ogre,
315       Half-Giant, Half-Titan, Cyclops, Yeek, Klackon, Kobold,
316       Nibelung, Dark-Elf, Draconian, Mindflayer, Imp, Golem,
317       Skeleton, Zombie, Vampire, Spectre, Sprite, Beastman, Ent,
318       Archon, Balrog, Dunadan, Shadow-Fairy, Kutar, Android,
319
320     $CLASS
321      Returns name of player class. One of below:
322       Warrior, Mage, Priest, Rogue, Ranger, Paladin,
323       Warrior-Mage, Chaos-Warrior, Monk, Mindcrafter, High-Mage,
324       Tourist, Imitator, BeastMaster, Sorcerer, Archer,
325       Magic-Eater, Bard, Red-Mage, Samurai, ForceTrainer,
326       Blue-Mage, Cavalry, Berserker, Weaponsmith, Mirror-Master,
327       Ninja, Sniper
328
329     $PLAYER
330      Returns player name.
331     $REALM1
332      Returns player's first magic realm
333       none, Life, Sorcery, Nature, Chaos, Death, Trump Arcane,
334       Craft, Daemon, Crusade, Music, Kendo, Hex
335     $REALM2
336      Returns player's second magic realm
337     $LEVEL
338      Returns player level as two-character string.
339       Ex. "01","09","10","50" etc.
340     $MONEY
341      Returns player money as 9 character string.
342       Ex. "000012345" etc.