Mercurial > hg > early-roguelike
comparison arogue5/monsters.c @ 304:e52a8a7ad4c5
Fix many compiler warnings.
There should only be two changes in behavior:
arogue7/fight.c, arogue7/fight.c: a to-hit bonus is now correctly
applied to characters who are not monks instead of monks who are not
empty-handed.
urogue/fight.c: fixed an interaction with the "debug" macro that could
cause the wrong message to be displayed.
author | John "Elwin" Edwards |
---|---|
date | Wed, 14 Apr 2021 18:55:33 -0400 |
parents | 56e748983fa8 |
children | 28e22fb35989 |
comparison
equal
deleted
inserted
replaced
303:e06ebc407615 | 304:e52a8a7ad4c5 |
---|---|
728 register struct thing *tp; | 728 register struct thing *tp; |
729 register struct linked_list *it; | 729 register struct linked_list *it; |
730 register struct room *trp; | 730 register struct room *trp; |
731 register const char *mname; | 731 register const char *mname; |
732 bool nasty; /* Will the monster "attack"? */ | 732 bool nasty; /* Will the monster "attack"? */ |
733 char ch; | |
734 | 733 |
735 if ((it = find_mons(y, x)) == NULL) { | 734 if ((it = find_mons(y, x)) == NULL) { |
736 msg("Can't find monster in show"); | 735 msg("Can't find monster in show"); |
737 return (NULL); | 736 return (NULL); |
738 } | 737 } |
739 tp = THINGPTR(it); | 738 tp = THINGPTR(it); |
740 ch = tp->t_type; | |
741 | 739 |
742 trp = roomin(&tp->t_pos); /* Current room for monster */ | 740 trp = roomin(&tp->t_pos); /* Current room for monster */ |
743 mname = monsters[tp->t_index].m_name; | 741 mname = monsters[tp->t_index].m_name; |
744 | 742 |
745 /* | 743 /* |