-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathai_txt.html
338 lines (247 loc) · 10.4 KB
/
ai_txt.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
<html>
<head>
<title>AI.TXT File Format</title>
<link rel="stylesheet" href="style.css" type="text/css" />
</head>
<body>
<h1>AI.TXT</h1>
<div style="width: 1200px; margin: auto;">
<p>The file consists of a description of combat parameters for the player and all NPC classes in the game. Descriptions are separated from one another with an empty line. Each description consists of the (unique) name of the class and settings. Below is a list of parameters in alphabetical order, which is how they are always written in the file. "string" means that the value should be text; "N" indicates a numeric value; and "mixed" can be either.</p>
<p>There seems to be a mismatch between some of the string values used and what the engine actually looks for. Potentially incorrect values are indicated with a (*).</p>
<h3>[Class Name]</h3>
<p>This option must be specified first. For example, [Enclave Patrol], [Fighting Mantis] or [Arroyo Villager]. The player is the class named Player AI. Every party member must have the following classes:</p>
<pre>[PARTY NAME BERSERK]
[PARTY NAME AGGRESSIVE]
[PARTY NAME DEFENSIVE]
[PARTY NAME COWARD]
[PARTY NAME CUSTOM]
</pre>
<p>Here NAME is the name of a member of the team, such as: DOC, LENNY, GORIS, etc. </p>
<p>NOTE: The combat ai-mode types for party members must always be in the above shown order, and the character must always start out in the CUSTOM-mode, otherwise the game will not be able to correctly detect the set ai-mode.</p>
<h3>aggression = N</h3>
<p>The chance of aggressive behavior by the NPC in combat. Measured as a percentage. Valid values are: 0-100.</p>
<h3>area_attack_mode = string</h3>
<p>Conditions for burst-fire. Existing values, the internal numeric representation, and the text used for setting custom behavior in-game:</p>
<pre>
no_pref* -1 "Not Applicable."
always 0 "Always!"
sometimes 1 "Sometimes, don't worry about hitting me"
be_sure 2 "Be sure you won't hit me"
be_careful 3 "Be careful not to hit me"
be_absolutely_sure 4 "Be absolutely sure you won't hit me"
</pre>
<p>'no_pref' is used by Cyberdog and Goris, and has a line in custom.msg, but is not checked for by the engine.</p>
<p>For party members, these options must be defined in the party.txt file.</p>
<h3>combat float</h3>
attack_end = N
attack_start = N
Combat floats said when attacking. At the beginning of the attack, a random number between the two values is chosen. Then the appropriate line number from master.dat/text/english/game/combatai.msg is displayed.
<h3>attack_who = string</h3>
Who the NPC should attack. Existing values:
<pre>
whomever_attacking_me 0 "Whomever is attacking me"
strongest 1 "The strongest"
weakest 2 "The weakest"
whomever 3 "Whomever you want"
closest 4 "Whomever is closest"
</pre>
<p>For party members, these options must be defined in the party.txt file.</p>
<h3>best_weapon = string</h3>
<p>Preferred weapon types. This option does not exist for all NPCs. Available values:</p>
<pre>
no_pref 0 "None"
melee 1 "Melee"
melee_over_ranged 2 "Melee then ranged"
ranged_over_melee 3 "Ranged then melee"
ranged 4 "Ranged"
unarmed 5 "Unarmed"
unarmed_over_thrown ? (Spore Plant)
random ?
never* ? (Deathclaw)
</pre>
<p>For party members, these options must be defined in the party.txt file.</p>
<h3>body_type = string</h3>
<p>Defines the block of messages that critters say in response to being hit. The blocks are from master.dat/data/AIBDYMSG.TXT, which in turn refers to lines in combatai.msg . Existing values (examples of critters that use them in parens):</p>
<pre>
None
Primitive
Wimpy Person (Whimpy, Coward ...)
Punk (SF)
Berserk Person (Kamakazi. ..)
Tough Person (Bounty Hunter, Caravan Driver ...)
Boxer
Normal Person
Robot
Junkie (Crazy Addict)
Elron (Habologisty)
Ghoul
Kaga
Raider (Khan)
Raider (Non-Khan)
Gangster (Mobsters)
Shi
Super Mutant (Master Army)
Goris
Miron
Marcus
Lenny
Cassidy
Robo Brain (Hum / Cyb)
Sulik
</pre>
<h3>called_freq = N</h3>
<p>Sets the probability of using an aimed attack, which is calculated as 1/N. Cannot be zero.</p>
<h3>chance = N</h3>
The likelihood of any message. Measured as a percentage. Valid values are: 0-100.
<h3>chem_primary_desire = N</h3>
<p>Preference for drug use. PIDs of items, or -1 if there is no preference. If you want to specify multiple types of drugs, they are listed separated by commas (e.g., 284,81,103). Strangely, most critters use 81 (Iguana-on-a-stick, whole).</p>
<h3>chem_use = string</h3>
<p>NPC drug use in combat. Existing values:</p>
<pre>
clean 0 "I'm clean"
stims_when_hurt_little 1 "Stimpacks when hurt a bit"
stims_when_hurt_lots 2 "Stimpacks when hurt a lot"
sometimes 3 "Any drug some of the time"
anytime 4 "Any drug any time"
always ?
</pre>
<p>For party members, these options must be defined in the party.txt file.</p>
<h3>color = N</h3>
<p>Perhaps the font color used for combat floats. It is 58 for all critter types.</p>
<h3>disposition = mixed</h3>
<p>Determines NPC behavior during a battle. Existing values:</p>
<pre>
-1*
none
custom
coward
defensive
aggressive
berserk
</pre>
<h3>distance = string</h3>
<p>The distance between the NPC and its enemy, managing battle tactics. Existing values:</p>
<pre>
stay_close 0 "Stay close to me"
charge 1 "Charge!"
snipe 2 "Snipe the enemy"
on_your_own 3 "On your own"
stay 4 "Stay where you are"
random* ? (listed only for Mobsters and Tough Khan)
</pre>
<p>For party members, these options must be defined in the party.txt file.</p>
<h3>font = N</h3>
<p>Perhaps, the font used for combat floats. Value in the US version of the game is 101. In other versions 102, 103, and 104 are used.</p>
<h3>general_type = string</h3>
<p>Defines the block of combat taunts that the critter periodically shouts during a battle (attack, retreat, miss). The blocks are in master.dat/data/AIGENMSG.TXT, and refer to lines in combatai.msg . Existing values:</p>
<pre>
Badger
Berserk Person
Bounty Hunter
Boxer
Cassidy
Chip
Crazed Robot
Cyberdog
Dragon (The)
Elron Guards
Gangster
Ghoul
Goris
Guard (Normal)
Guard (Tough)
Junkie
Kaga (1)
Lenny
Lo Pan
Marcus
Myron
None
Normal Person
OZ - 7
OZ - 9
Primitive
Raider
Raider Captain
Raider Mercs
Rat God
Robot
Ryan
Shi Guards
Sulik
Super Mutant (Master Army)
The Brain
Tough Person
Wimpy Person
</pre>
<h3>hit_eyes_end = N</h3>
<h3>hit_eyes_start = N</h3>
<h3>hit_groin_end = N</h3>
<h3>hit_groin_start = N</h3>
<h3>hit_head_end = N</h3>
<h3>hit_head_start = N</h3>
<h3>hit_left_arm_end = N</h3>
<h3>hit_left_arm_start = N</h3>
<h3>hit_left_leg_end = N</h3>
<h3>hit_left_leg_start = N</h3>
<h3>hit_right_arm_end = N</h3>
<h3>hit_right_arm_start = N</h3>
<h3>hit_right_leg_end = N</h3>
<h3>hit_right_leg_start = N</h3>
<h3>hit_torso_end = N</h3>
<h3>hit_torso_start = N</h3>
<p>NPC messages when hit in the eyes, groin, head, left arm, left leg, right arm, right leg and torso, respectively. For details, see the description of attack_end.</p>
<h3>hurt_too_much = string</h3>
<p>Indicates the condition in which the NPC starts running away. Multiple conditions are separated by commas.</p>
<pre>
blind 40
crippled 3c
crippled_arms 30
crippled_legs 0c
</pre>
<p>'crippled' is equivalent to 'crippled_arms, crippled_legs'</p>
<p>For party members, these options must be defined in the party.txt file.</p>
<h3>max_dist = N</h3>
The maximum distance from the player where the NPC is hostile. Measured in hexes.
<h3>min_hp = N</h3>
The minimum number of hit points, at which the NPC starts running away.
<h3>min_to_hit = N</h3>
The NPC will attack only if it has at least this high a chance (percentage) of hitting its target.
<h3>miss_end = N</h3>
<h3>miss_start = N</h3>
NPC combat taunts when missing a target. For details, see the description of attack_end.
<h3>move_end = N</h3>
<h3>move_start = N</h3>
Combat taunts used when moving to attack (i.e., when not yet in range of the enemy, but already hostile) For details, see description of attack_end.
<h3>outline_color = N</h3>
Maybe the color used for target highlighting. For all NPC classes, it is 55.
<h3>packet_num = N</h3>
Number of the AI package. Never change it! If the new AI package you indicate packet_num, which already exists, then when you click on the AI button in the Mapper (in critter properties), it closes the window. When you create a new AI package, the value of packet_num must be consecutive. In AI.TXT there are 187 values for packet_num, from 0 to 186 inclusive. If you want to add a new package, it should have packet_num 187, the next added package 188, and so on. If packet_num is not followed consecutively, for example, 188 immediately after 186, the mapper will close.
<h3>run_away_mode = string</h3>
<p>Condition when the NPC will run away. Existing values (second column is minimum amount of damage taken, as a percentage of max HP):</p>
<pre>
coward 0% 0 "Abject coward"
finger_hurts 25% 1 "Your finger hurts"
bleeding 40% 2 "You're bleeding a bit"
not_feeling_good 60% 3 "Not feeling good"
tourniquet 75% 4 "You need a tourniquet"
never 100% 5 "Never!"
none 0% 6 "None"
</pre>
<p>For party members, these options must be defined in the party.txt file.</p>
<h3>run_end = N</h3>
<h3>run_start = N</h3>
<p>Combat floats used when running away. For details, see the description of attack_end.</p>
<h3>secondary_freq = N</h3>
<p>Similar to called_freq. Sets the probability of using a secondary (i.e., burst) attack mode, which is calculated as 1/N. Cannot be zero. Only used when area_attack_mode is 'sometimes' or 'no_pref'.</p>
<hr/>
<h2 style="text-align: left;">History</h2>
<p>
2019-12-15 - Updated information about party members.<br/>
2019-12-14 - Ported from <a href="https://falloutmods.fandom.com/wiki/AI.TXT_File_Format">https://falloutmods.fandom.com/wiki/AI.TXT_File_Format</a> by <a href="https://github.com/ghost2238">ghost</a><br/>
2007 - <a href="https://www.nma-fallout.com/threads/teamx-documents-russian-to-english-translation.179561/">Translated by Kanhef</a><br/>
1999-12-27 - Written by Serge of Team-X (ai_txt_format.htm)
</p>
</div>
</body>
</html>