Пример #1
0
void showknownspells(int first, int last)
{
    int i,printed=FALSE;

    menuclear();
    menuprint("\nPossible Spells:\n");
    for (i = first; i <= last; i++)
        if (Spells[spell_ids[i]].known) {
            printed = TRUE;
            menuprint(spell_names[i]);
            menuprint(" (");
            menunumprint(Spells[spell_ids[i]].powerdrain);
            menuprint(" mana)");
            menuprint("\n");
        }
    if (! printed)
        menuprint("\nNo spells match that prefix!");
    showmenu();
}
Пример #2
0
void knowledge(int blessing)
{
  if (blessing < 0)
    mprint("You feel ignorant.");
  else {
    mprint("You feel knowledgeable!");
    menuclear();
    menuprint("Current Point Total: ");
    menulongprint(calc_points());
    menuprint("\nAlignment:");
    if (Player.alignment == 0)
      menuprint("Neutral, embodying the Cosmic Balance");
    else if (abs(Player.alignment) < 10)
      menuprint("Neutral, tending toward ");
    else if (abs(Player.alignment) < 50)
      menuprint("Neutral-");
    else if (abs(Player.alignment) < 100) ;
    else if (abs(Player.alignment) < 200)
      menuprint("Servant of ");
    else if (abs(Player.alignment) < 400)
      menuprint("Master of ");
    else if (abs(Player.alignment) < 800)
      menuprint("The Essence of ");
    else menuprint("The Ultimate Avatar of ");
    if (Player.alignment < 0) menuprint("Chaos\n");
    else if (Player.alignment > 0) menuprint("Law\n");
    showmenu();
    morewait();
    menuclear();
    menuprint("Current stati:\n");
    if (Player.status[BLINDED])
      menuprint("Blinded\n");
    if (Player.status[SLOWED])
      menuprint("Slowed\n");
#ifdef DEBUG
    if (Player.status[SLOWED])
      fprintf(DG_debug_log, "Slowed is %d\n", Player.status[SLOWED] );
#endif
    if (Player.status[HASTED])
      menuprint("Hasted\n");
    if (Player.status[DISPLACED])
      menuprint("Displaced\n");
    if (Player.status[SLEPT])
      menuprint("Slept\n");
    if (Player.status[DISEASED])
      menuprint("Diseased\n");
    if (Player.status[POISONED])
      menuprint("Poisoned\n");
    if (Player.status[BREATHING])
      menuprint("Breathing\n");
    if (Player.status[INVISIBLE])
      menuprint("Invisible\n");
    if (Player.status[REGENERATING])
      menuprint("Regenerating\n");
    if (Player.status[VULNERABLE])
      menuprint("Vulnerable\n");
    if (Player.status[BERSERK])
      menuprint("Berserk\n");
    if (Player.status[IMMOBILE])
      menuprint("Immobile\n");
    if (Player.status[ALERT])
      menuprint("Alert\n");
    if (Player.status[AFRAID])
      menuprint("Afraid\n");
    if (Player.status[ACCURATE])
      menuprint("Accurate\n");
    if (Player.status[HERO])
      menuprint("Heroic\n");
    if (Player.status[LEVITATING])
      menuprint("Levitating\n");
    if (Player.status[TRUESIGHT]) /* FIXED! 12/30/98 DG */
      menuprint("Sharp\n");
    if (Player.status[SHADOWFORM])
      menuprint("Shadowy\n");
    if (Player.status[ILLUMINATION])
      menuprint("Glowing\n");
    if (Player.status[DEFLECTION])
      menuprint("Buffered\n");
    if (Player.status[RETURNING])
      menuprint("Returning\n");
    showmenu();
    morewait();
    menuclear();
    menuprint("Immunities:\n");
    if (p_immune(NORMAL_DAMAGE))
      menuprint("Normal Damage\n");
    if (p_immune(FLAME))
      menuprint("Flame\n");
    if (p_immune(ELECTRICITY))
      menuprint("Electricity\n");
    if (p_immune(COLD))
      menuprint("Cold\n");
    if (p_immune(POISON))
      menuprint("Poison\n");
    if (p_immune(ACID))
      menuprint("Acid\n");
    if (p_immune(FEAR))
      menuprint("Fear\n");
    if (p_immune(SLEEP))
      menuprint("Sleep\n");
    if (p_immune(NEGENERGY))
      menuprint("Negative Energies\n");
    if (p_immune(THEFT))
      menuprint("Theft\n");
    if (p_immune(GAZE))
      menuprint("Gaze\n");
    if (p_immune(INFECTION))
      menuprint("Infection\n");
    showmenu();
    morewait();
    menuclear();
    menuprint("Ranks:\n");
    switch(Player.rank[LEGION]) {
    case COMMANDANT:
      menuprint("Commandant of the Legion"); 
      break;
    case COLONEL:    
      menuprint("Colonel of the Legion");
      break;
    case FORCE_LEADER:
      menuprint("Force Leader of the Legion");
      break;
    case CENTURION:
      menuprint("Centurion of the Legion");
      break;
    case LEGIONAIRE:
      menuprint("Legionaire");
      break;
    }
    if (Player.rank[LEGION] > 0) {
      menuprint(" (");
      menunumprint(Player.guildxp[LEGION]);
      menuprint(" XP).\n");
    }
    switch(Player.rank[ARENA]) {
    case -1:
      menuprint("Ex-gladiator\n");
      break;
    case CHAMPION:
      menuprint("Gladiator Champion");
      break;
    case GLADIATOR:    
      menuprint("Gladiator of the Arena");
      break;
    case RETIARIUS:
      menuprint("Retiarius of the Arena");
      break;
    case BESTIARIUS:
      menuprint("Bestiarius of the Arena");
      break;
    case TRAINEE:
      menuprint("Gladiator Trainee of the Arena");
      break;
    }
    if (Player.rank[ARENA] > 0) {
      menuprint(" (Opponent ");
      menunumprint(Arena_Opponent);
      menuprint(")\n");
    }
    switch(Player.rank[COLLEGE]) {
    case ARCHMAGE:
      menuprint("Archmage of the Collegium Magii");
      break;
    case MAGE:
      menuprint("Collegium Magii: Mage");
      break;
    case PRECEPTOR:
      menuprint("Collegium Magii: Preceptor");
      break;
    case STUDENT:
      menuprint("Collegium Magii: Student");
      break;
    case NOVICE:
      menuprint("Collegium Magii: Novice");
      break;
    }
    if (Player.rank[COLLEGE] > 0) {
      menuprint(" (");
      menunumprint(Player.guildxp[COLLEGE]);
      menuprint(" XP).\n");
    }
    switch(Player.rank[NOBILITY]) {
    case DUKE:
      menuprint("Duke of Rampart");
      break;
    case LORD:
      menuprint("Peer of the Realm");
      break;
    case KNIGHT:
      menuprint("Order of the Knights of Rampart");
      break;
    case ESQUIRE:
      menuprint("Squire of Rampart");
      break;
    case COMMONER:
      menuprint("Commoner");
      break;
    default:
      menuprint("Lowly Commoner\n");
      break;
    }
    if (Player.rank[NOBILITY] > 1) {
      menuprint(" (");
      menunumprint(Player.rank[NOBILITY] - 1);
      menuprint(ordinal(Player.rank[NOBILITY] - 1));
      menuprint(" Quest Completed)\n");
    }
    else if (Player.rank[NOBILITY] == 1) {
      menuprint(" (1st Quest Undertaken)\n");
    }
    switch(Player.rank[CIRCLE]) {
    case -1:
      menuprint("Former member of the Circle.\n");
      break;
    case PRIME:
      menuprint("Prime Sorceror of the Inner Circle");
      break;
    case HIGHSORCEROR:
      menuprint("High Sorceror of the Inner Circle");
      break;
    case SORCEROR:
      menuprint("Member of the Circle of Sorcerors");
      break;
    case ENCHANTER:
      menuprint("Member of the Circle of Enchanters");
      break;
    case INITIATE:
      menuprint("Member of the Circle of Initiates");
      break;
    }
    if (Player.rank[CIRCLE] > 0) {
      menuprint(" (");
      menunumprint(Player.guildxp[CIRCLE]);
      menuprint(" XP).\n");
    }
    switch(Player.rank[ORDER]) {
    case -1:
      menuprint("Washout from the Order of Paladins\n");
      break;
    case JUSTICIAR:
      menuprint("Justiciar of the Order of Paladins");
      break;
    case PALADIN:
      menuprint("Paladin of the Order");
      break;
    case CHEVALIER:
      menuprint("Chevalier of the Order");
      break;
    case GUARDIAN:
      menuprint("Guardian of the Order");
      break;
    case GALLANT:
      menuprint("Gallant of the Order");
      break;
    }
    if (Player.rank[ORDER] > 0) {
      menuprint(" (");
      menunumprint(Player.guildxp[ORDER]);
      menuprint(" XP).\n");
    }
    switch(Player.rank[THIEVES]) {
    case SHADOWLORD:
      menuprint("Guild of Thieves: Shadowlord");
      break;
    case TMASTER:
      menuprint("Guild of Thieves: Master Thief");
      break;
    case THIEF:
      menuprint("Guild of Thieves: Thief");
      break;
    case ATHIEF:
      menuprint("Guild of Thieves: Apprentice Thief");
      break;
    case TMEMBER:
      menuprint("Guild of Thieves: Candidate Member");
      break;
    }
    if (Player.rank[THIEVES] > 0) {
      menuprint(" (");
      menunumprint(Player.guildxp[THIEVES]);
      menuprint(" XP).\n");
    }
    switch(Player.rank[PRIESTHOOD]) {
      case LAY:
        menuprint("A lay devotee of ");
	break;
      case ACOLYTE:
        menuprint("An Acolyte of ");
	break;
      case PRIEST:
        menuprint("A Priest of ");
	break;
      case SPRIEST:
        menuprint("A Senior Priest of ");
	break;
      case HIGHPRIEST:
        menuprint("The High Priest of ");
	break;
      }
    switch(Player.patron) {
      case ODIN:
        menuprint("Odin");
	break;
      case SET:
        menuprint("Set");
	break;
      case ATHENA:
        menuprint("Athena");
	break;
      case HECATE:
        menuprint("Hecate");
	break;
      case DRUID:
        menuprint("Druidism");
	break;
      case DESTINY:
        menuprint("the Lords of Destiny");
	break;
    }
    if (Player.rank[PRIESTHOOD] > 0) {
      menuprint(" (");
      menunumprint(Player.guildxp[PRIESTHOOD]);
      menuprint(" XP).\n");
    }
#ifdef INCLUDE_MONKS
    switch(Player.rank[MONKS]) {
    case MONK_GRANDMASTER:
      menuprint("Tholian Monks: Grandmaster");
      break;
    case MONK_MASTER_TEARS:
      menuprint("Tholian Monks: Master of Tears");
      break;
    case MONK_MASTER_PAINS:
      menuprint("Tholian Monks: Master of Pain");
      break;
    case MONK_MASTER_SIGHS:
      menuprint("Tholian Monks: Master of Sighs");
      break;
    case MONK_MASTER:
      menuprint("Tholian Monks: Master");
      break;
    case MONK_MONK:
      menuprint("Tholian Monks: Monk");
      break;
    case MONK_TRAINEE:
      menuprint("Tholian Monks: Trainee");
      break;
    }
    if (Player.rank[MONKS] > 0) {
      menuprint(" (");
      menunumprint(Player.guildxp[MONKS]);
      menuprint(" XP).\n");
    }
#endif
    if (Player.rank[ADEPT] > 0) 
      menuprint("**************\n*Omegan Adept*\n**************\n");
    showmenu();
    morewait();
    xredraw();
  }
}