monsters.
git-svn-id: https://crawl-ref.svn.sourceforge.net/svnroot/crawl-ref/trunk@582 c06c8d41-db1a-0410-9941-cceddc491573
ODNAIEJW732NG7USKQKCIP4R4DAEYXXJQX6LY7TIN32NKE75454QC case 'C':targChosen = true;mx = you.x_pos + cx - VIEW_CX;my = you.y_pos + cy - VIEW_CY;if (!in_bounds(mx, my))break;if (mgrd[mx][my] != NON_MONSTER){mprf("%s won't like that.",ptr_monam(&menv[mgrd[mx][my]], DESC_CAP_A));break;}create_spec_monster_name(mx, my);viewwindow(true, false);break;case 'D':targChosen = true;mx = you.x_pos + cx - VIEW_CX;my = you.y_pos + cy - VIEW_CY;if (!in_bounds(mx, my))break;mid = mgrd[mx][my];if (mid == NON_MONSTER)break;monster_die(&menv[mid], KILL_RESET, 0);viewwindow(true, false);break;
inline static void monster_warning(activity_interrupt_type ai,const activity_interrupt_data &at,int atype){if ( ai == AI_SEE_MONSTER && is_run_delay(atype) ){const monsters* mon = static_cast<const monsters*>(at.data);#ifndef DEBUG_DIAGNOSTICSmprf(MSGCH_WARN, "%s comes into view.", ptr_monam(mon, DESC_CAP_A));#elsemprf(MSGCH_WARN,"%s in view: (%d,%d), see_grid: %s",ptr_monam(mon, DESC_PLAIN),mon->x, mon->y,see_grid(mon->x, mon->y)? "yes" : "no");#endif}}
create_monster(mon, 0, BEH_SLEEP,you.x_pos, you.y_pos, MHITNOT, 250, false);
const bool force_place = x != -1 && y != -1;if (x == -1)x = you.x_pos;if (y == -1)y = you.y_pos;create_monster(mon, 0, BEH_SLEEP, x, y,MHITNOT, 250, false, force_place);