version 1.77 | | version 1.78 |
---|
| | |
/* | | /* |
* static char *rcsid_living_c = | | * static char *rcsid_living_c = |
* "$Id: living.c,v 1.77 2006/03/07 18:46:23 cavesomething Exp $"; | | * "$Id: living.c,v 1.78 2006/04/06 21:18:34 tchize Exp $"; |
*/ | | */ |
| | |
/* | | /* |
| | |
object *give_skill_by_name(object *op, const char *skill_name) | | object *give_skill_by_name(object *op, const char *skill_name) |
{ | | { |
object *skill_obj; | | object *skill_obj; |
| | archetype *skill_arch; |
| | |
skill_obj = get_archetype_by_skill_name(skill_name, SKILL); | | skill_arch = get_archetype_by_skill_name(skill_name, SKILL); |
if (!skill_obj) { | | if (!skill_arch) { |
LOG(llevError, "add_player_exp: couldn't find skill %s\n", skill_name); | | LOG(llevError, "add_player_exp: couldn't find skill %s\n", skill_name); |
return NULL; | | return NULL; |
} | | } |
| | skill_obj = arch_to_object(skill_arch); |
| | if (!skill_obj) { |
| | LOG(llevError, "add_player_exp: couldn't instanciate skill %s\n", skill_name); |
| | return NULL; |
| | } |
/* clear the flag - exp goes into this bucket, but player | | /* clear the flag - exp goes into this bucket, but player |
* still doesn't know it. | | * still doesn't know it. |
*/ | | */ |