Crossfire Mailing List Archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Bug fix.
- To: crossfire (at) ifi.uio.no
- Subject: Bug fix.
- From: Moonchilde <>
- Date: Fri, 25 Sep 1992 17:34:43 -0400 (EDT)
- Sender: "Joseph L. Traub" <>
If a player type 'a' when he had nothing in his inventory, the game would
seg fault. This patch fixes that problem. It is diffed against .87.8
------cut here-----------------------------------cut here---------------
*** input.c.old Fri Sep 25 17:23:22 1992
--- input.c Fri Sep 25 17:26:08 1992
***************
*** 1608,1616 ****
op->contr->count_left=0;
break;
case 'a':
! if(!apply(op,op->inv)) {
! sprintf(buf,"I don't know how to apply the %s.",query_name(op->inv));
! draw_info(op,buf);
}
break;
case 'A':
--- 1608,1620 ----
op->contr->count_left=0;
break;
case 'a':
! if(op->inv) {
! if(!apply(op,op->inv)) {
! sprintf(buf,"I don't know how to apply the %s.",query_name(op->inv));
! draw_info(op,buf);
! }
! } else {
! draw_info(op, "You have nothing to apply!");
}
break;
case 'A':
-------------------------------------------------------------------------
Practice random kindness and senseless acts of beauty --Anonymous
Argue for your limitations and sure enough they're yours --Richard Bach
Isn't humanity egocentric? Whenever we talk, we say "Here's my two cents
worth," but we only offer "a penny for your thoughts." --
Moonchilde/Amythyst/JT Traub ---