Home
last modified time | relevance | path

Searched refs:mtmp (Results 1 – 25 of 43) sorted by relevance

12

/openbsd/games/hack/
H A Dhack.mon.c95 for(mtmp = fmon; mtmp; mtmp = mtmp->nmon) in movemon()
109 if(cansee(mtmp->mx,mtmp->my)) in movemon()
116 if(mtmp->mhp > 1) mtmp->mhp--; in movemon()
230 mtmp->mhp < mtmp->mhpmax) in dochug()
318 if(mtmp->mhide && o_at(mtmp->mx,mtmp->my) && rn2(10)) in m_move()
520 newsym(mtmp->mx, mtmp->my); in mpickgold()
685 for(mtmp = fmon; mtmp->nmon != mon; mtmp = mtmp->nmon) ; in relmon()
738 mtmp->mtame ? amonnam(mtmp, "poor") : monnam(mtmp)); in killed()
805 x = mtmp->mx; y = mtmp->my; in killed()
846 for(mtmp = fmon; mtmp; mtmp = mtmp->nmon) in rescham()
[all …]
H A Dhack.mhitu.c118 if(mdat->mlet == ';' && mtmp->minvis && cansee(mtmp->mx,mtmp->my)){ in mhitu()
120 pmon(mtmp); in mhitu()
136 if(!mtmp->cham && !mtmp->mcan && !rn2(13)) { in mhitu()
159 levl[(int)mtmp->mx][(int)mtmp->my].typ == POOL) { in mhitu()
197 buzz(-1,mtmp->mx,mtmp->my,u.ux-mtmp->mx,u.uy-mtmp->my); in mhitu()
220 mondead(mtmp); in mhitu()
257 rloc(mtmp); in mhitu()
264 Monnam(mtmp)); in mhitu()
366 mondead(mtmp); in mhitu()
389 if(mtmp->mhide && mtmp->mundetected) { in hitu()
[all …]
H A Dhack.wizard.c89 for(mtmp = fmon; mtmp; mtmp = mtmp->nmon) in amulet()
94 if(dist(mtmp->mx,mtmp->my) > 2) in amulet()
106 if(mtmp->minvent && mtmp->minvent->olet == AMULET_SYM && in wiz_hit()
127 pmon(mtmp); in wiz_hit()
139 if(hitu(mtmp, d(mtmp->data->damn,mtmp->data->damd)) in wiz_hit()
154 if(mtmp->data->mlet != '1' && mtmp->mcan) in inrange()
166 buzz(-1,mtmp->mx,mtmp->my,sgn(tx),sgn(ty)); in inrange()
224 buzz(-rnd(3),mtmp->mx,mtmp->my,sgn(tx),sgn(ty)); in inrange()
238 for(mtmp = fmon; mtmp; mtmp = mtmp->nmon) { in aggravate()
250 if ((mtmp2 = makemon(PM_WIZARD, mtmp->mx, mtmp->my))) { in clonewiz()
[all …]
H A Dhack.dog.c93 mtmp->mtame = mtmp->mpeaceful = 1; in initedog()
122 rloc(mtmp); in losedogs()
131 for(mtmp = fmon; mtmp; mtmp = mtmp->nmon) in keepdogs()
132 if(dist(mtmp->mx,mtmp->my) < 3 && follower(mtmp) in keepdogs()
133 && !mtmp->msleep && !mtmp->mfroz) { in keepdogs()
210 if(mtmp->mhp > mtmp->mhpmax) in dog_move()
211 mtmp->mhp = mtmp->mhpmax; in dog_move()
236 relobj(mtmp, (int) mtmp->minvis); in dog_move()
471 if(mtmp->mtame || mtmp->mfroz || in tamedog()
475 mtmp->isshk || mtmp->isgd || strchr(" &@12", mtmp->data->mlet)) in tamedog()
[all …]
H A Dhack.steal.c91 rloc(mtmp); in stealgold()
98 rloc(mtmp); in stealgold()
116 for(mtmp = fmon; mtmp; mtmp = mtmp->nmon) in stealarm()
118 if(dist(mtmp->mx,mtmp->my) < 3) { in stealarm()
123 rloc(mtmp); in stealarm()
254 if(show & cansee(mtmp->mx,mtmp->my)) in relobj()
258 if(mtmp->mgold || mtmp->data->mlet == 'L') { in relobj()
261 tmp = (mtmp->mgold > 10000) ? 10000 : mtmp->mgold; in relobj()
262 mkgold((long)(tmp + d(dlevel,30)), mtmp->mx, mtmp->my); in relobj()
263 if(show & cansee(mtmp->mx,mtmp->my)) in relobj()
[all …]
H A Dhack.makemon.c110 fmon = mtmp; in makemon()
114 if(ptr->mlet == 'D') mtmp->mhpmax = mtmp->mhp = 80; in makemon()
115 else if(!ptr->mlevel) mtmp->mhpmax = mtmp->mhp = rnd(4); in makemon()
116 else mtmp->mhpmax = mtmp->mhp = d(ptr->mlevel, 8); in makemon()
117 mtmp->mx = x; in makemon()
118 mtmp->my = y; in makemon()
128 rloc(mtmp); in makemon()
131 mtmp->mhide = mtmp->mundetected = 1; in makemon()
133 if(mtmp->mx && mtmp->my) in makemon()
134 (void) mkobj_at(0, mtmp->mx, mtmp->my); in makemon()
[all …]
H A Dhack.do_name.c126 mtmp = m_at(cx,cy); in do_mname()
127 if(!mtmp){ in do_mname()
135 if(mtmp->mimic){ in do_mname()
154 *mtmp2 = *mtmp; in do_mname()
159 replmon(mtmp,mtmp2); in do_mname()
277 mtmp->mxlth); in xmonnam()
283 if(mtmp->isshk) { in xmonnam()
291 mtmp->data->mname); in xmonnam()
315 char *bp = monnam(mtmp); in Monnam()
324 char *bp = monnam(mtmp); in amonnam()
[all …]
H A Dhack.apply.c156 if(mtmp->mcansee || mtmp->mblinded){ in use_camera()
157 int tmp = dist(mtmp->mx,mtmp->my); in use_camera()
159 if(cansee(mtmp->mx,mtmp->my)) in use_camera()
166 if(tmp < 3) mtmp->mcansee = mtmp->mblinded = 0; in use_camera()
284 return(mtmp); in bchit()
292 while(mtmp) { in use_whistle()
293 if(dist(mtmp->mx,mtmp->my) < u.ulevel*20) { in use_whistle()
299 mtmp = mtmp->nmon; in use_whistle()
309 if(mtmp->mtame) mnexto(mtmp); in use_magic_whistle()
310 mtmp = mtmp->nmon; in use_magic_whistle()
[all …]
H A Dhack.worm.c81 mtmp->wormno = tmp; in getwn()
97 wtmp->wx = mtmp->mx; in initworm()
117 unpmon(mtmp); in worm_move()
124 mtmp->mhpmax += 3; in worm_move()
125 mtmp->mhp += 3; in worm_move()
139 tmp = mtmp->wormno; in worm_nomove()
155 mtmp->wormno = 0; in wormdead()
203 if(mtmp->mx == x && mtmp->my == y) return; /* hit headon */ in cutworm()
212 tmp = mtmp->wormno; in cutworm()
222 *mtmp2 = *mtmp; in cutworm()
[all …]
H A Dhack.fight.c174 if(DIST(mon->mx,mon->my,mtmp->mx,mtmp->my) < 3) in fightm()
331 if(mdat->mlet == 'L' && !mtmp->mfroz && !mtmp->msleep && in attack()
332 !mtmp->mconf && mtmp->mcansee && !rn2(7) && in attack()
334 mtmp->mx != u.ux+u.dx || mtmp->my != u.uy+u.dy)) in attack()
337 if(mtmp->mimic){ in attack()
338 if(!u.ustuck && !mtmp->mflee) u.ustuck = mtmp; in attack()
353 wakeup(mtmp); in attack()
355 if(mtmp->mhide && mtmp->mundetected){ in attack()
359 if((obj = o_at(mtmp->mx,mtmp->my)) && !Blind) in attack()
379 if(mtmp->mfroz) { in attack()
[all …]
H A Dhack.bones.c80 struct monst *mtmp; in savebones() local
107 mtmp->mx = u.ux; in savebones()
108 mtmp->my = u.uy; in savebones()
109 mtmp->msleep = 1; in savebones()
110 (void) strlcpy((char *) mtmp->mextra, plname, mtmp->mxlth); in savebones()
112 for(mtmp = fmon; mtmp; mtmp = mtmp->nmon){ in savebones()
113 mtmp->m_id = 0; in savebones()
114 if(mtmp->mtame) { in savebones()
115 mtmp->mtame = 0; in savebones()
118 mtmp->mlstmv = 0; in savebones()
[all …]
H A Dhack.trap.c207 struct trap *trap = t_at(mtmp->mx, mtmp->my); in mintrap()
216 int in_sight = cansee(mtmp->mx,mtmp->my); in mintrap()
229 Monnam(mtmp)); in mintrap()
245 if(!mtmp->msleep && !mtmp->mfroz) { in mintrap()
249 Monnam(mtmp)); in mintrap()
253 rloc(mtmp); in mintrap()
254 if(in_sight && !cansee(mtmp->mx,mtmp->my)) in mintrap()
256 Monnam(mtmp)); in mintrap()
261 Monnam(mtmp)); in mintrap()
263 mtmp->mhp -= 3; in mintrap()
[all …]
H A Dhack.lev.c166 while(mtmp) { in savemonchn()
167 mtmp2 = mtmp->nmon; in savemonchn()
168 xl = mtmp->mxlth + mtmp->mnamelth; in savemonchn()
171 if(mtmp->minvent) saveobjchn(fd,mtmp->minvent); in savemonchn()
172 free(mtmp); in savemonchn()
173 mtmp = mtmp2; in savemonchn()
243 for(mtmp = fmon; mtmp; mtmp = mtmp2) { in getlev()
246 mtmp2 = mtmp->nmon; in getlev()
248 mondead(mtmp); in getlev()
253 mtmp->mtame = 0; in getlev()
[all …]
H A Dhack.pri.c281 for(mtmp = fmon; mtmp; mtmp = mtmp->nmon) in docrt()
313 for(mtmp = fmon; mtmp; mtmp = mtmp->nmon) in docorner()
314 if(mtmp->mx >= xmin && mtmp->my < ymax) in docorner()
389 if((mtmp = m_at(x,y)) && !mtmp->mhide && in prl()
400 else if(mtmp && (!mtmp->minvis || See_invisible)) { in prl()
597 for(mtmp = fmon; mtmp; mtmp = mtmp->nmon){ in seemons()
599 mtmp->minvis = (u.ustuck != mtmp && in seemons()
603 if(mtmp->wormno) wormsee(mtmp->wormno); in seemons()
731 mstatusline(mtmp) struct monst *mtmp; { variable
734 mtmp->data->mlevel, mtmp->mgold, mtmp->mhp, mtmp->mhpmax,
[all …]
H A Dhack.zap.c89 wakeup(mtmp); in bhitm()
96 if(mtmp->mhp < 1) killed(mtmp); in bhitm()
108 if(mtmp->mhp < 1) killed(mtmp); in bhitm()
117 mtmp->mcan = 1; in bhitm()
120 rloc(mtmp); in bhitm()
261 unstuck(mtmp); in dozap()
262 mnexto(mtmp); in dozap()
341 if(!cansee(mtmp->mx,mtmp->my)) pline("The %s hits it.", str); in hit()
348 if(!cansee(mtmp->mx,mtmp->my)) pline("The %s misses it.",str); in miss()
388 return(mtmp); in bhit()
[all …]
H A Dhack.search.c73 struct monst *mtmp; in findit() local
103 } else if ((mtmp = m_at(zx,zy)) && (mtmp->mimic)) { in findit()
104 seemimic(mtmp); in findit()
116 struct monst *mtmp; in dosearch() local
138 if(mtmp->mimic){ in dosearch()
185 mtmp->msleep = 0; in wakeup()
186 setmangry(mtmp); in wakeup()
187 if(mtmp->mimic) seemimic(mtmp); in wakeup()
194 mtmp->mimic = 0; in seemimic()
196 unpmon(mtmp); in seemimic()
[all …]
H A Dhack.read.c158 struct monst *mtmp; in doread() local
160 for(mtmp = fmon; mtmp; mtmp = mtmp->nmon) in doread()
161 if(cansee(mtmp->mx,mtmp->my)) { in doread()
163 mtmp->mflee = mtmp->mfroz = in doread()
166 mtmp->mflee = 1; in doread()
262 for(mtmp = fmon; mtmp; mtmp = mtmp2){ in doread()
265 mondead(mtmp); in doread()
454 for(mtmp = fmon; mtmp; mtmp = mtmp->nmon) { in doread()
455 if(dist(mtmp->mx,mtmp->my) < 3) { in doread()
456 mtmp->mhp -= num; in doread()
[all …]
H A Dhack.save.c221 struct monst *mtmp; in dorecover() local
223 for(mtmp = fmon; mtmp; mtmp = mtmp->nmon) in dorecover()
227 u.ustuck = mtmp; in dorecover()
263 struct monst *mtmp, *mtmp2; in restmonchn() local
276 mtmp = newmonst(xl); in restmonchn()
277 if(!first) first = mtmp; in restmonchn()
278 else mtmp2->nmon = mtmp; in restmonchn()
280 if(!mtmp->m_id) in restmonchn()
281 mtmp->m_id = flags.ident++; in restmonchn()
284 if(mtmp->minvent) in restmonchn()
[all …]
H A Dhack.shk.c228 struct monst *mtmp; in setpaid() local
236 for(mtmp = fmon; mtmp; mtmp = mtmp->nmon) in setpaid()
239 for(mtmp = fallen_down; mtmp; mtmp = mtmp->nmon) in setpaid()
311 for(mtmp = fmon; mtmp; mtmp = mtmp->nmon) in inshop()
364 struct monst *mtmp; in findshk() local
366 for(mtmp = fmon; mtmp; mtmp = mtmp->nmon) in findshk()
367 if(mtmp->isshk && ESHK(mtmp)->shoproom == roomno in findshk()
641 for(mtmp = fmon; mtmp; mtmp = mtmp->nmon) in bp_to_obj()
644 for(mtmp = fallen_down; mtmp; mtmp = mtmp->nmon) in bp_to_obj()
1131 return( mtmp->mtame || strchr("1TVWZi&, ", mtmp->data->mlet) in follower()
[all …]
H A Dhack.potion.c76 struct monst *mtmp; in dodrink() local
144 for(mtmp = fmon; mtmp; mtmp = mtmp->nmon) in dodrink()
145 if(mtmp->mx > 0) in dodrink()
146 at(mtmp->mx,mtmp->my,mtmp->data->mlet); in dodrink()
440 struct monst *mtmp; in ghost_from_bottle() local
442 if(!(mtmp = makemon(PM_GHOST,u.ux,u.uy))){ in ghost_from_bottle()
446 mnexto(mtmp); in ghost_from_bottle()
H A Dhack.vault.c84 replgd(struct monst *mtmp, struct monst *mtmp2) in replgd() argument
153 struct monst *mtmp; in setgd() local
155 for(mtmp = fmon; mtmp; mtmp = mtmp->nmon) if(mtmp->isgd){ in setgd()
156 guard = mtmp; in setgd()
344 replgd(struct monst *mtmp, struct monst *mtmp2) in replgd() argument
346 if(mtmp == guard) in replgd()
H A Dhack.end.c149 if(mtmp->data->mlet == ' '){ in done_in_by()
152 } else if(mtmp->mnamelth) { in done_in_by()
154 mtmp->data->mname, NAME(mtmp)); in done_in_by()
156 } else if(mtmp->minvis) { in done_in_by()
222 struct monst *mtmp; in done() local
230 mtmp = mydogs; in done()
231 if(mtmp) { in done()
233 while(mtmp) { in done()
236 if(mtmp->mtame) in done()
237 u.urexp += mtmp->mhp; in done()
[all …]
H A Dhack.c151 struct monst *mtmp; in domove() local
544 struct monst *mtmp; in lookaround() local
555 if((mtmp = m_at(x,y)) && !mtmp->mimic && in lookaround()
582 m0 = mtmp ? 1 : 0; in lookaround()
593 if(mtmp) break; /* d */ in lookaround()
638 struct monst *mtmp; in monster_nearby() local
643 if((mtmp = m_at(x,y)) && !mtmp->mimic && !mtmp->mtame && in monster_nearby()
644 !mtmp->mpeaceful && !strchr("Ea", mtmp->data->mlet) && in monster_nearby()
645 !mtmp->mfroz && !mtmp->msleep && /* aplvax!jcn */ in monster_nearby()
830 losehp_m(int n, struct monst *mtmp) in losehp_m() argument
[all …]
H A Dhack.mkmaze.c87 struct monst *mtmp; in makemaz() local
100 if ((mtmp = makemon(&hell_hound, zx, zy))) in makemaz()
101 mtmp->msleep = 1; in makemaz()
102 if ((mtmp = makemon(PM_WIZARD, zx+1, zy))) { in makemaz()
103 mtmp->msleep = 1; in makemaz()
/openbsd/etc/
H A DMakefile.inc46 ${.CURDIR}/../MAKEDEV.man > MAKEDEV.mtmp; then \
49 cp MAKEDEV.mtmp ${DOCDIR}/MAKEDEV.8; \
50 ${NOCLEAN} rm MAKEDEV.mtmp; \
53 diff MAKEDEV.mtmp ${DOCDIR}/MAKEDEV.8 > mdiffout1 || true; \
64 cp MAKEDEV.mtmp ${DOCDIR}/MAKEDEV.8 || true; \
65 ${NOCLEAN} rm MAKEDEV.mtmp; \
68 fi; ${NOCLEAN} rm -f MAKEDEV.mtmp

12