version 1.14 | | version 1.15 |
---|
| | |
/* check_recipe() - makes sure we actually have the requested artifact | | /* check_recipe() - makes sure we actually have the requested artifact |
* and archetype. */ | | * and archetype. */ |
| | |
static int check_recipe(recipe *rp) { | | static int check_recipe(const recipe *rp) { |
size_t i; | | size_t i; |
int result; | | int result; |
| | |
| | |
/* Find a treasure with a matching name. The 'depth' parameter is | | /* Find a treasure with a matching name. The 'depth' parameter is |
* only there to prevent infinite loops in treasure lists (a list | | * only there to prevent infinite loops in treasure lists (a list |
* referencing another list pointing back to the first one). */ | | * referencing another list pointing back to the first one). */ |
archetype *find_treasure_by_name (treasure *t, const char *name, int depth) | | archetype *find_treasure_by_name (const treasure *t, const char *name, int depth) |
{ | | { |
treasurelist *tl; | | treasurelist *tl; |
archetype *at; | | archetype *at; |
| | |
return val*mult; | | return val*mult; |
} | | } |
| | |
artifact * locate_recipe_artifact(recipe *rp, size_t idx) { | | artifact * locate_recipe_artifact(const recipe *rp, size_t idx) { |
object *item=get_archetype(rp->arch_name[idx]); | | object *item=get_archetype(rp->arch_name[idx]); |
artifactlist *at=NULL; | | artifactlist *at=NULL; |
artifact *art=NULL; | | artifact *art=NULL; |