Replace magic MINTRS/MAXTRS with a treasure attribute in YAML.
This commit is contained in:
parent
25077d0b4e
commit
c3a2816821
7 changed files with 43 additions and 107 deletions
|
@ -899,7 +899,7 @@ static int throw (FILE *cmdin, struct command_t *command)
|
|||
rspeak(spk);
|
||||
return GO_CLEAROBJ;
|
||||
}
|
||||
if (command->obj >= MINTRS && command->obj <= MAXTRS && AT(TROLL)) {
|
||||
if (object_descriptions[command->obj].is_treasure && AT(TROLL)) {
|
||||
spk = TROLL_SATISFIED;
|
||||
/* Snarf a treasure for the troll. */
|
||||
DROP(command->obj, 0);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue