| 4127 | } |
| 4128 | |
| 4129 | void |
| 4130 | end_running(boolean and_travel) |
| 4131 | { |
| 4132 | /* moveloop() suppresses time_botl when context.run is non-zero; when |
| 4133 | running stops, update 'time' even if other botl status is unchanged */ |
| 4134 | if (svc.context.run) { |
| 4135 | svc.context.run = 0; |
| 4136 | if (flags.time) |
| 4137 | disp.time_botl = TRUE; |
| 4138 | /* classify_terrain() suppresses setting disp.botl when |
| 4139 | running; after that, it can no longer compare current terrain |
| 4140 | against iflaga.terrain_typ to detect a change, so recompute */ |
| 4141 | if (flags.terrainstatus) { |
| 4142 | iflags.terrain_typ = MAX_TYPE; /* "none of the above" value */ |
| 4143 | classify_terrain(); |
| 4144 | } |
| 4145 | } |
| 4146 | |
| 4147 | /* 'context.mv' isn't travel but callers who want to end travel |
| 4148 | all clear it too */ |
| 4149 | if (and_travel) |
| 4150 | svc.context.travel = svc.context.travel1 = svc.context.mv = 0; |
| 4151 | if (gt.travelmap) { |
| 4152 | selection_free(gt.travelmap, TRUE); |
| 4153 | gt.travelmap = NULL; |
| 4154 | } |
| 4155 | /* cancel multi */ |
| 4156 | if (gm.multi > 0) |
| 4157 | gm.multi = 0; |
| 4158 | } |
| 4159 | |
| 4160 | void |
| 4161 | nomul(int nval) |