static char * mage_s(int n) { int a; if (!is_magician(n) || char_hide_mage(n)) return ""; a = max_eff_aura(n); if (a <= 5) return ""; if (a <= 10) return ", conjurer"; if (a <= 15) return ", mage"; if (a <= 20) return ", wizard"; if (a <= 30) return ", sorcerer"; if (a <= 40) return ", 6th black circle"; if (a <= 50) return ", 5th black circle"; if (a <= 60) return ", 4th black circle"; if (a <= 70) return ", 3rd black circle"; if (a <= 80) return ", 2nd black circle"; return ", master of the black arts"; }
int d_view_aura(struct command *c) { int n; int level; int first = TRUE; int aura = c->a; int where = c->d; char *s; int has_detect; int learned; char *source; if (!is_loc_or_ship(where)) { wout(c->who, "%s is no longer a valid location.", box_code(where)); return FALSE; } if (!charge_aura(c->who, aura)) return FALSE; loop_char_here(where, n) { if (is_magician(n)) { /* * Does the viewed magician have Detect ability scry? */ level = char_cur_aura(n); if (aura <= char_abil_shroud(n)) { s = "???"; learned = FALSE; } else { s = sout("%d", level); learned = TRUE; } wout(c->who, "%s, current aura: %s", box_name(n), s); first = FALSE; has_detect = has_skill(n, sk_detect_abil); if (has_detect > exp_novice) source = box_name(c->who); else source = "Someone"; if (has_detect) wout(n, "%s cast View aura here.", source); if (has_detect > exp_journeyman) { if (learned) wout(n, "Our current aura rating was learned."); else wout(n, "Our current aura rating was " "not revealed."); } } } next_char_here; if (first) { wout(c->who, "No mages are seen here."); log_output(LOG_CODE, "d_view_aura: not a mage?\n"); } return TRUE; }