Advertisement
Guest User

Score

a guest
Dec 15th, 2011
102
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 6.16 KB | None | 0 0
  1. ACMD(do_score)
  2. {
  3.   struct time_info_data playing_time;
  4.  
  5.   if (IS_NPC(ch))
  6.     return;
  7.  
  8.   send_to_char(ch, "------------------------------------------------------------------------------\r\n");
  9.   send_to_char(ch, "%s %s %d\r\n", GET_NAME(ch), GET_TITLE(ch), GET_ALIGNMENT(ch));
  10.   send_to_char(ch, "------------------------------------------------------------------------------\r\n");
  11.   send_to_char(ch, "  Class       : %s \r\n", pc_class_types[(int)GET_CLASS(ch)]);
  12.   send_to_char(ch, "  Level       : %d \r\n", GET_LEVEL(ch));
  13.   send_to_char(ch, "  Experience  : %d \r\n", GET_EXP(ch));
  14.   send_to_char(ch, "  Race        : %s \r\n", pc_race_types[(int)GET_RACE(ch)]);
  15.  
  16.   if (GET_ALIGNMENT(ch) <= 502 && GET_ALIGNMENT(ch) >= 1000)
  17.     send_to_char(ch, "  Alignment   : Chaotic Good \r\n");
  18.   if (GET_ALIGNMENT(ch) <= 102 && GET_ALIGNMENT(ch) >= 501)
  19.     send_to_char(ch, "  Alignment   : Lawful Good \r\n");
  20.   if (GET_ALIGNMENT(ch) <= 101 && GET_ALIGNMENT(ch) >= -101)
  21.     send_to_char(ch, "  Alignment   : Neutral \r\n");
  22.   if (GET_ALIGNMENT(ch) <= -102 && GET_ALIGNMENT(ch) >= -501)
  23.     send_to_char(ch, "  Alignment   : Lawful Evil \r\n");
  24.   if (GET_ALIGNMENT(ch) <= -502 && GET_ALIGNMENT(ch) >= -1000)
  25.     send_to_char(ch, "  Alignment   : Chaotic Evil \r\n");
  26.  
  27.   /* else
  28.   send_to_char(ch, "  Alignment   : %d \r\n", GET_ALIGNMENT(ch));
  29.   */
  30.   send_to_char(ch, "  Deity       : NA \r\n", GET_RACE(ch));
  31.   send_to_char(ch, "------------------------------------------------------------------------------\r\n");
  32.   send_to_char(ch, "  Strength    : %d \r\n", GET_STR(ch));
  33.   send_to_char(ch, "  Dexterity   : %d \r\n", GET_DEX(ch));
  34.   send_to_char(ch, "  Constitution: %d \r\n", GET_CON(ch));
  35.   send_to_char(ch, "  Intelligence: %d \r\n", GET_INT(ch));
  36.   send_to_char(ch, "  Wisdom      : %d \r\n", GET_WIS(ch));
  37.   send_to_char(ch, "  Charisma    : %d \r\n", GET_CHA(ch));
  38.   send_to_char(ch, "------------------------------------------------------------------------------\r\n");
  39.   send_to_char(ch, "  Hit Points  : %d of (%d) \r\n", GET_HIT(ch), GET_MAX_HIT(ch));  
  40.   send_to_char(ch, "  Mana Points : %d of (%d) \r\n", GET_MANA(ch), GET_MAX_MANA(ch));
  41.   send_to_char(ch, "  Comm Points : %d of (%d) \r\n", GET_MOVE(ch), GET_MAX_MOVE(ch));
  42.   send_to_char(ch, "  Gold Coins  : %d \r\n", GET_GOLD(ch));
  43.   send_to_char(ch, "------------------------------------------------------------------------------\r\n");
  44.   playing_time = *real_time_passed((time(0) - ch->player.time.logon) + ch->player.time.played, 0);
  45.   send_to_char(ch, "  Age : %d day%s %d hour%s.\r\n",
  46.      playing_time.day, playing_time.day == 1 ? "" : "s",
  47.      playing_time.hours, playing_time.hours == 1 ? "" : "s");
  48.   send_to_char(ch, "------------------------------------------------------------------------------\r\n");
  49.  
  50.   /*  send_to_char(ch, "Age: %d years old.\r\n", GET_AGE(ch));
  51.  
  52.   if (age(ch)->month == 0 && age(ch)->day == 0)
  53.     send_to_char(ch, "  It's your birthday today.\r\n");
  54.   else
  55.     send_to_char(ch, "\r\n");
  56.  
  57.   send_to_char(ch, "Your armor class is %d/10, and your alignment is %d.\r\n",
  58.       compute_armor_class(ch), GET_ALIGNMENT(ch));
  59. */
  60.  
  61.   if (GET_LEVEL(ch) < LVL_IMMORT)
  62.     send_to_char(ch, "  %d exp to next level.\r\n",
  63.     level_exp(GET_CLASS(ch), GET_LEVEL(ch) + 1) - GET_EXP(ch));
  64.   else
  65.     send_to_char(ch, "  You cannot level anymore.\r\n");
  66.  
  67.  
  68.   send_to_char(ch, "------------------------------------------------------------------------------\r\n");
  69.  
  70.   switch (GET_POS(ch)) {
  71.   case POS_DEAD:
  72.     send_to_char(ch, "  You are DEAD!\r\n");
  73.     break;
  74.   case POS_MORTALLYW:
  75.     send_to_char(ch, "  You are mortally wounded!  You should seek help!\r\n");
  76.     break;
  77.   case POS_INCAP:
  78.     send_to_char(ch, "  You are incapacitated, slowly fading away...\r\n");
  79.     break;
  80.   case POS_STUNNED:
  81.     send_to_char(ch, "  You are stunned!  You can't move!\r\n");
  82.     break;
  83.   case POS_SLEEPING:
  84.     send_to_char(ch, "  You are sleeping.\r\n");
  85.     break;
  86.   case POS_RESTING:
  87.     send_to_char(ch, "  You are resting.\r\n");
  88.     break;
  89.   case POS_SITTING:
  90.     send_to_char(ch, "  You are sitting.\r\n");
  91.     break;
  92.   case POS_FIGHTING:
  93.     send_to_char(ch, "  You are fighting %s.\r\n", FIGHTING(ch) ? PERS(FIGHTING(ch), ch) : "thin air");
  94.     break;
  95.   case POS_STANDING:
  96.     send_to_char(ch, "  You are standing.\r\n");
  97.     break;
  98.   default:
  99.     send_to_char(ch, "  You are floating.\r\n");
  100.     break;
  101.   }
  102.   send_to_char(ch, "------------------------------------------------------------------------------\r\n");
  103.   if (GET_COND(ch, DRUNK) > 10)
  104.     send_to_char(ch, "  You are intoxicated.\r\n");
  105.     else
  106.     send_to_char(ch, "  Beer would be nice.\r\n");
  107.  
  108.   if (GET_COND(ch, FULL) == 0)
  109.     send_to_char(ch, "  You are hungry.\r\n");
  110.     else
  111.     send_to_char(ch, "  You are not hungry.\r\n");
  112.  
  113.   if (GET_COND(ch, THIRST) == 0)
  114.     send_to_char(ch, "  You are thirsty.\r\n");
  115.     else
  116.     send_to_char(ch, "  You are not thirsty\r\n");
  117.  
  118.   send_to_char(ch, "------------------------------------------------------------------------------\r\n");
  119.  
  120.   if (AFF_FLAGGED(ch, AFF_BLIND))
  121.     send_to_char(ch, "  You have been blinded!\r\n");
  122.  
  123.   if (AFF_FLAGGED(ch, AFF_INVISIBLE))
  124.     send_to_char(ch, "  You are invisible.\r\n");
  125.  
  126.   if (AFF_FLAGGED(ch, AFF_DETECT_INVIS))
  127.     send_to_char(ch, "  You are sensitive to the presence of invisible things.\r\n");
  128.  
  129.   if (AFF_FLAGGED(ch, AFF_SANCTUARY))
  130.     send_to_char(ch, "  You are protected by Sanctuary.\r\n");
  131.  
  132.   if (AFF_FLAGGED(ch, AFF_POISON))
  133.     send_to_char(ch, "  You are poisoned!\r\n");
  134.  
  135.   if (AFF_FLAGGED(ch, AFF_CHARM))
  136.     send_to_char(ch, "  You have been charmed!\r\n");
  137.  
  138.   if (affected_by_spell(ch, SPELL_ARMOR))
  139.     send_to_char(ch, " You feel protected.\r\n");
  140.  
  141.   if (AFF_FLAGGED(ch, AFF_INFRAVISION))
  142.     send_to_char(ch, "  You can see in darkness with infravision.\r\n");
  143.  
  144.   if (PRF_FLAGGED(ch, PRF_SUMMONABLE))
  145.     send_to_char(ch, "  You are summonable by other players.\r\n");
  146.  
  147.   if (AFF_FLAGGED(ch, AFF_DETECT_ALIGN))
  148.     send_to_char(ch, "  You see into the hearts of others.\r\n");
  149.  
  150.   if (AFF_FLAGGED(ch, AFF_DETECT_MAGIC))
  151.     send_to_char(ch, "  You are sensitive to the magical nature of things.\r\n");
  152.  
  153. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement