| 350 | }; |
| 351 | |
| 352 | staticfn void |
| 353 | levitation_dialogue(void) |
| 354 | { |
| 355 | /* -1 because the last message comes via float_down() */ |
| 356 | long i = (((HLevitation & TIMEOUT) - 1L) / 2L); |
| 357 | |
| 358 | if (ELevitation) |
| 359 | return; |
| 360 | |
| 361 | if (!ACCESSIBLE(levl[u.ux][u.uy].typ) |
| 362 | && !is_pool_or_lava(u.ux,u.uy)) |
| 363 | return; |
| 364 | |
| 365 | if (((HLevitation & TIMEOUT) % 2L) && i > 0L && i <= SIZE(levi_texts)) { |
| 366 | const char *s = levi_texts[SIZE(levi_texts) - i]; |
| 367 | |
| 368 | if (strchr(s, '%')) { |
| 369 | boolean danger = (is_pool_or_lava(u.ux, u.uy) |
| 370 | && !Is_waterlevel(&u.uz)); |
| 371 | |
| 372 | urgent_pline(s, danger ? "over" : "in", |
| 373 | danger ? surface(u.ux, u.uy) : "air"); |
| 374 | } else |
| 375 | pline1(s); |
| 376 | stop_occupation(); |
| 377 | } |
| 378 | } |
| 379 | |
| 380 | static NEARDATA const char *const slime_texts[] = { |
| 381 | "You are turning a little %s.", /* 5 */ |
no test coverage detected