oops.. someone pointed out it would just put the skill at the number
between 1 and 5.. well, I fixed it.. I hope.. :P ehre it is
void improve_skill(struct char_data *ch, int skill)
{
int percent = GET_SKILL(ch, skill);
char skillbuf[MAX_STRING_LENGTH];
if (number(1, 200) > GET_WIS(ch) + GET_INT(ch))
return;
if (percent >= 100 || percent <= 0)
return;
percent += number(1, 5);
/* ^ */
/* \____________ added that +.. :P */
SET_SKILL(ch, skill, percent);
if (percent >= 4)
sprintf(skillbuf, "You feel your skill in %s improving.", skill);
}
enjoy that.. =) hope it actually works this time.. and tell me if you
find anything wrong..
Nashak Brian Williams The Realms of Luminari
nashak@darkstr.com bmw@efn.org darkstr.com 6969
This archive was generated by hypermail 2b30 : 12/07/00 PST