Beispiel #1
0
void gain_exp_regardless(struct char_data * ch, int gain)
{
  int is_altered = FALSE;
  int num_levels = 0;

  GET_EXP(ch) += gain;
  if (GET_EXP(ch) < 0)
    GET_EXP(ch) = 0;

  if (!IS_NPC(ch)) {
    while (GET_LEVEL(ch) < LVL_IMPL &&
	GET_EXP(ch) >= level_exp(GET_CLASS(ch), GET_LEVEL(ch) + 1)) {
      GET_LEVEL(ch) += 1;
      num_levels++;
      advance_level(ch);
      is_altered = TRUE;
    }

    if (is_altered) {
      sprintf(buf, "%s advanced %d level%s to level %d.",
		GET_NAME(ch), num_levels, num_levels == 1 ? "" : "s",
		GET_LEVEL(ch));
      mudlog(buf, BRF, MAX(LVL_IMMORT, GET_INVIS_LEV(ch)), TRUE);
      if (num_levels == 1)
        send_to_char("You rise a level!\r\n", ch);
      else {
	sprintf(buf, "You rise %d levels!\r\n", num_levels);
	send_to_char(buf, ch);
      }
      set_title(ch, NULL);
      check_autowiz(ch);
    }
  }
}
Beispiel #2
0
void gain_exp (CHAR_DATA * ch, int gain)
{
    char buf[MAX_STRING_LENGTH];

    if (IS_NPC (ch) || ch->level >= LEVEL_HERO)
        return;

    if(gain > 99)
    gain = 99;
    ch->exp += gain;

    while (ch->level < LEVEL_HERO && ch->exp >=
           exp_per_level (ch, ch->pcdata->points) * (ch->level + 1))
    {
        send_to_char ("{GYou raise a level!!  {x", ch);
        ch->level += 1;
        sprintf (buf, "%s gained level %d", ch->name, ch->level);
        log_string (buf);
        sprintf (buf, "$N has attained level %d!", ch->level);
        wiznet (buf, ch, NULL, WIZ_LEVELS, 0, 0);
        advance_level (ch, FALSE);
        save_char_obj (ch);
    }

    return;
}
Beispiel #3
0
// юзается исключительно в act.wizards.cpp в имм командах "advance" и "set exp".
void gain_exp_regardless(CHAR_DATA * ch, int gain)
{
	int is_altered = FALSE;
	int num_levels = 0;

	ch->set_exp(ch->get_exp() + gain);
	if (!IS_NPC(ch))
	{
		if (gain > 0)
		{
			while (GET_LEVEL(ch) < LVL_IMPL && GET_EXP(ch) >= level_exp(ch, GET_LEVEL(ch) + 1))
			{
				ch->set_level(ch->get_level() + 1);
				num_levels++;
				sprintf(buf, "%sВы достигли следующего уровня!%s\r\n",
						CCWHT(ch, C_NRM), CCNRM(ch, C_NRM));
				send_to_char(buf, ch);

				advance_level(ch);
				is_altered = TRUE;
			}

			if (is_altered)
			{
				sprintf(buf, "%s advanced %d level%s to level %d.",
						GET_NAME(ch), num_levels, num_levels == 1 ? "" : "s", GET_LEVEL(ch));
				mudlog(buf, BRF, LVL_IMPL, SYSLOG, TRUE);
			}
		}
		else if (gain < 0)
		{
// Pereplut: глупый участок кода.
//			gain = MAX(-max_exp_loss_pc(ch), gain);	// Cap max exp lost per death
//			GET_EXP(ch) += gain;
//			if (GET_EXP(ch) < 0)
//				GET_EXP(ch) = 0;
			while (GET_LEVEL(ch) > 1 && GET_EXP(ch) < level_exp(ch, GET_LEVEL(ch)))
			{
				ch->set_level(ch->get_level() - 1);
				num_levels++;
				sprintf(buf,
						"%sВы потеряли уровень!%s\r\n",
						CCIRED(ch, C_NRM), CCNRM(ch, C_NRM));
				send_to_char(buf, ch);
				decrease_level(ch);
				is_altered = TRUE;
			}
			if (is_altered)
			{
				sprintf(buf, "%s decreases %d level%s to level %d.",
						GET_NAME(ch), num_levels, num_levels == 1 ? "" : "s", GET_LEVEL(ch));
				mudlog(buf, BRF, LVL_IMPL, SYSLOG, TRUE);
			}
		}

	}
}
Beispiel #4
0
/* Some initializations for characters, including initial skills */
void do_start(struct char_data *ch)
{
  GET_LEVEL(ch) = 1;
  GET_TOT_LEVEL(ch) = 1;
  GET_EXP(ch) = 1;
  GET_CLASS_1(ch) = GET_CLASS(ch);
  GET_MULTIS(ch) = 1;

  set_title(ch, NULL);
  roll_real_abils(ch);

  GET_MAX_HIT(ch)  = 10;
  GET_MAX_MANA(ch) = 100;
  GET_MAX_MOVE(ch) = 100;

  switch (GET_CLASS(ch)) {

  case CLASS_ADEPT:
    break;

  case CLASS_MEDIC:
    break;

  case CLASS_BANDIT:
    SET_SKILL(ch, SKILL_SNEAK, 10);
    SET_SKILL(ch, SKILL_HIDE, 5);
    SET_SKILL(ch, SKILL_STEAL, 15);
    SET_SKILL(ch, SKILL_BACKSTAB, 10);
    SET_SKILL(ch, SKILL_PICK_LOCK, 10);
    SET_SKILL(ch, SKILL_TRACK, 10);
    break;

  case CLASS_SOLDIER:
    break;
  }

  advance_level(ch);

  GET_HIT(ch) = GET_MAX_HIT(ch);
  GET_MANA(ch) = GET_MAX_MANA(ch);
  GET_MOVE(ch) = GET_MAX_MOVE(ch);

  GET_COND(ch, THIRST) = 24;
  GET_COND(ch, HUNGER) = 24;
  GET_COND(ch, DRUNK) = 0;

  if (CONFIG_SITEOK_ALL)
    SET_BIT_AR(PLR_FLAGS(ch), PLR_SITEOK);
}
Beispiel #5
0
void gain_exp(struct char_data * ch, int gain)
{
  int is_altered = FALSE;
  int num_levels = 0;
  char buf[128];

  if (!IS_NPC(ch) && ((GET_LEVEL(ch) < 1 || GET_LEVEL(ch) >= LVL_IMMORT)))
    return;

  if (IS_NPC(ch)) {
    GET_EXP(ch) += gain;
    return;
  }
  if (gain > 0) {
    gain = MIN(max_exp_gain, gain);	/* put a cap on the max gain per kill */
    GET_EXP(ch) += gain;
    while (GET_LEVEL(ch) < LVL_IMMORT &&
	GET_EXP(ch) >= level_exp(GET_CLASS(ch), GET_LEVEL(ch) + 1)) {
      GET_LEVEL(ch) += 1;
      num_levels++;
      advance_level(ch);
      is_altered = TRUE;
    }

    if (is_altered) {
      sprintf(buf, "%s advanced %d level%s to level %d.",
		GET_NAME(ch), num_levels, num_levels == 1 ? "" : "s",
		GET_LEVEL(ch));
      mudlog(buf, BRF, MAX(LVL_IMMORT, GET_INVIS_LEV(ch)), TRUE);
      if (num_levels == 1)
        send_to_char("You rise a level!\r\n", ch);
      else {
	sprintf(buf, "You rise %d levels!\r\n", num_levels);
	send_to_char(buf, ch);
      }
      set_title(ch, NULL);
      check_autowiz(ch);
    }
  } else if (gain < 0) {
    gain = MAX(-max_exp_loss, gain);	/* Cap max exp lost per death */
    GET_EXP(ch) += gain;
    if (GET_EXP(ch) < 0)
      GET_EXP(ch) = 0;
  }
}
Beispiel #6
0
void gen_random_battle(CHAR_DATA *ch)
{
int monsters[10];
int i=0;
CHAR_DATA *leader;
CHAR_DATA *crone;
CHAR_DATA *wch;
int mob_top=0;
char buf[50];
int total=0;
int charcnt = 0;
MOB_INDEX_DATA *pMobIndex;

for (wch = ch->in_room->people; wch != NULL; wch = wch->next_in_room)
charcnt++;

pMobIndex = get_mob_index (number_range(20,30));
leader = create_mobile(pMobIndex);
total = ch->level + number_range(-6,4);

if(total > 100)
total = 99;

for(i=0;i<total;i++)
advance_level(leader,FALSE);

char_to_room (leader, ch->in_room);
charcnt--;

while(charcnt!=0)
{
pMobIndex = get_mob_index (number_range(20,30));
crone = create_mobile(pMobIndex);
total = ch->level + number_range(-6,4);

if(total > 100)
total = 99;

for(i=0;i<total;i++)
advance_level(crone,FALSE);

char_to_room (crone, ch->in_room);
charcnt--;
}

send_to_char("\n\r{c******{RRANDOM BATTLE!!!!{c******{x\n\r",ch);
sprintf(buf,"%s",ch->name);

do_kill(leader,buf);

sprintf(buf,"%d",leader->team);

charcnt += number_range(-2,3);

if(charcnt<1) charcnt = 1;

for (wch = ch->in_room->people; wch != NULL; wch = wch->next_in_room)
{
switch(atoi(buf))
{
case TEAM_BLUE: do_join(wch,"red"); break;
case TEAM_RED: do_join(wch,"blue"); break;
default: do_join(wch,"none"); break;
}
}

for (i=0;i!=charcnt-1;i++)
{

CHAR_DATA *mob;

pMobIndex = get_mob_index (monsters[number_range(0,mob_top-1)]);

if(pMobIndex == NULL)
continue;

mob = create_mobile(pMobIndex);
char_to_room (mob, ch->in_room);

total = ch->level + number_range(-6,4);
for(i=0;i<total;i++)
advance_level(mob,FALSE);

switch(atoi(buf))
{
case TEAM_BLUE: do_join(mob,"blue"); break;
case TEAM_RED: do_join(mob,"red");  break;
default: do_join(mob,"none");  break;
}

mob->in_room->turn=mob;
mob->AttackLeft=1;
mob->MoveLeft=3;
}

}
Beispiel #7
0
void advance_class_level( CHAR_DATA *ch )
{                                                      /* ONLY called for multiclasses */
    int                     level = 0;

    if ( ch->firstexp >= exp_class_level( ch, ch->firstlevel + 1, ch->Class ) ) {   /* Levelled 
                                                                                     */
        ch_printf( ch, "\r\n&WYou have now obtained %s level %d!&D\r\n",
                   class_table[ch->Class]->who_name, ++ch->firstlevel );
        ch->firstexp =
            URANGE( 0, ( ch->firstexp - exp_class_level( ch, ch->firstlevel, ch->Class ) ),
                    ch->firstexp );
        advance_level( ch );
    }

    if ( IS_SECONDCLASS( ch ) && ch->secondexp >= exp_class_level( ch, ch->secondlevel + 1, ch->secondclass ) ) {   /* Again 
                                                                                                                     */
        ch_printf( ch, "\r\n&WYou have now obtained %s level %d!&D\r\n",
                   class_table[ch->secondclass]->who_name, ++ch->secondlevel );
        ch->secondexp =
            URANGE( 0, ( ch->secondexp - exp_class_level( ch, ch->secondlevel, ch->secondclass ) ),
                    ch->secondexp );
        advance_level( ch );
    }

    if ( IS_THIRDCLASS( ch ) && ch->thirdexp >= exp_class_level( ch, ch->thirdlevel + 1, ch->thirdclass ) ) {   /* Made 
                                                                                                                 * a 
                                                                                                                 * level! 
                                                                                                                 */
        ch_printf( ch, "\r\n&WYou have now obtained %s level %d!&D\r\n",
                   class_table[ch->thirdclass]->who_name, ++ch->thirdlevel );
        ch->thirdexp =
            URANGE( 0, ( ch->thirdexp - exp_class_level( ch, ch->thirdlevel, ch->thirdclass ) ),
                    ch->thirdexp );
        advance_level( ch );
    }

    if ( IS_THIRDCLASS( ch ) )
        level = ( ( ch->firstlevel + 1 + ch->secondlevel + ch->thirdlevel ) / 3 );
    else if ( IS_SECONDCLASS( ch ) )
        level = ( ( ch->firstlevel + 1 + ch->secondlevel ) / 2 );
    else
        level = ( ch->firstlevel + 1 );

    if ( level > ch->level ) {                         /* Should have gained! */
        char                    buf[MSL];

        if ( xIS_SET( ch->act, PLR_EXTREME ) ) {
            ch_printf( ch, "&GPlaying 6D EXTREME you gain 5 glory!&D\r\n" );
            ch->quest_curr += 5;
        }

        ch_printf( ch, "\r\n&WYou have now obtained an overall experience level %d!&D\r\n",
                   ++ch->level );
        restore_char( ch );
        send_to_char_color( "&YYou have gained insight in the realms, and have been restored!\r\n",
                            ch );
        snprintf( buf, MSL, "The realms rejoice as %s has just achieved level %d!&D", ch->name,
                  ch->level );
        announce( buf );
        snprintf( buf, MSL, "%24.24s: %s obtained level %d!%s%s&D", ctime( &current_time ),
                  ch->name, ch->level, ( doubleexp ? " (Double)" : "" ),
                  ( happyhouron ? " (HappyHour)" : "" ) );
        append_to_file( PLEVEL_FILE, buf );
    }
}
Beispiel #8
0
void gain_exp(CHAR_DATA * ch, int gain)
{
	int is_altered = FALSE;
	int num_levels = 0;
	char buf[128];

	if (IS_NPC(ch))
	{
		ch->set_exp(ch->get_exp() + gain);
		return;
	}
	else
	{
		ch->dps_add_exp(gain);
		ZoneExpStat::add(zone_table[world[IN_ROOM(ch)]->zone].number, gain);
	}

	if (!IS_NPC(ch) && ((GET_LEVEL(ch) < 1 || GET_LEVEL(ch) >= LVL_IMMORT)))
		return;

	if (gain > 0 && GET_LEVEL(ch) < LVL_IMMORT)
	{
		gain = MIN(max_exp_gain_pc(ch), gain);	// put a cap on the max gain per kill
		ch->set_exp(ch->get_exp() + gain);
		if (GET_EXP(ch) >= level_exp(ch, LVL_IMMORT))
		{
			if (!GET_GOD_FLAG(ch, GF_REMORT) && GET_REMORT(ch) < MAX_REMORT)
			{
				if (Remort::can_remort_now(ch))
				{
					send_to_char(ch, "%sПоздравляем, вы получили право на перевоплощение!%s\r\n",
						CCIGRN(ch, C_NRM), CCNRM(ch, C_NRM));
				}
				else
				{
					send_to_char(ch,
						"%sПоздравляем, вы набрали максимальное количество опыта!\r\n"
						"%s%s\r\n", CCIGRN(ch, C_NRM), Remort::WHERE_TO_REMORT_STR.c_str(), CCNRM(ch, C_NRM));
				}
				SET_GOD_FLAG(ch, GF_REMORT);
			}
		}
		ch->set_exp(MIN(GET_EXP(ch), level_exp(ch, LVL_IMMORT) - 1));
		while (GET_LEVEL(ch) < LVL_IMMORT && GET_EXP(ch) >= level_exp(ch, GET_LEVEL(ch) + 1))
		{
			ch->set_level(ch->get_level() + 1);
			num_levels++;
			sprintf(buf, "%sВы достигли следующего уровня!%s\r\n", CCWHT(ch, C_NRM), CCNRM(ch, C_NRM));
			send_to_char(buf, ch);
			advance_level(ch);
			is_altered = TRUE;
		}

		if (is_altered)
		{
			sprintf(buf, "%s advanced %d level%s to level %d.",
					GET_NAME(ch), num_levels, num_levels == 1 ? "" : "s", GET_LEVEL(ch));
			mudlog(buf, BRF, LVL_IMPL, SYSLOG, TRUE);
		}
	}
	else if (gain < 0 && GET_LEVEL(ch) < LVL_IMMORT)
	{
		gain = MAX(-max_exp_loss_pc(ch), gain);	// Cap max exp lost per death
		ch->set_exp(ch->get_exp() + gain);
		while (GET_LEVEL(ch) > 1 && GET_EXP(ch) < level_exp(ch, GET_LEVEL(ch)))
		{
			ch->set_level(ch->get_level() - 1);
			num_levels++;
			sprintf(buf,
					"%sВы потеряли уровень. Вам должно быть стыдно!%s\r\n",
					CCIRED(ch, C_NRM), CCNRM(ch, C_NRM));
			send_to_char(buf, ch);
			decrease_level(ch);
			is_altered = TRUE;
		}
		if (is_altered)
		{
			sprintf(buf, "%s decreases %d level%s to level %d.",
					GET_NAME(ch), num_levels, num_levels == 1 ? "" : "s", GET_LEVEL(ch));
			mudlog(buf, BRF, LVL_IMPL, SYSLOG, TRUE);
		}
	}
	if ((GET_EXP(ch) < level_exp(ch, LVL_IMMORT) - 1)
		&& GET_GOD_FLAG(ch, GF_REMORT)
		&& gain
		&& (GET_LEVEL(ch) < LVL_IMMORT))
	{
		if (Remort::can_remort_now(ch))
		{
			send_to_char(ch, "%sВы потеряли право на перевоплощение!%s\r\n",
				CCIRED(ch, C_NRM), CCNRM(ch, C_NRM));
		}
		CLR_GOD_FLAG(ch, GF_REMORT);
	}

	char_stat::add_class_exp(GET_CLASS(ch), gain);
	update_clan_exp(ch, gain);
}
Beispiel #9
0
void StartLevels(struct char_data *ch)
{

  if (IS_SET(ch->player.iClass, CLASS_MAGIC_USER)) {
    advance_level(ch, MAGE_LEVEL_IND);
  }

  if (IS_SET(ch->player.iClass, CLASS_SORCERER)) {
    advance_level(ch, SORCERER_LEVEL_IND);
  }
  if (IS_SET(ch->player.iClass, CLASS_CLERIC)) {
    advance_level(ch, CLERIC_LEVEL_IND);
  }
  if (IS_SET(ch->player.iClass, CLASS_WARRIOR)) {
    advance_level(ch, WARRIOR_LEVEL_IND);
  }
  if (IS_SET(ch->player.iClass, CLASS_THIEF)) {
    advance_level(ch, THIEF_LEVEL_IND);
  }
  if (IS_SET(ch->player.iClass, CLASS_DRUID)) {
    advance_level(ch,DRUID_LEVEL_IND);
  }
  if (IS_SET(ch->player.iClass, CLASS_MONK)) {
    advance_level(ch, MONK_LEVEL_IND);
  }
  if (IS_SET(ch->player.iClass, CLASS_BARBARIAN)) {
    advance_level(ch, BARBARIAN_LEVEL_IND);
  }  
  if (IS_SET(ch->player.iClass, CLASS_PALADIN)) {
    advance_level(ch, PALADIN_LEVEL_IND);
  }    
  if (IS_SET(ch->player.iClass, CLASS_RANGER)) {
    advance_level(ch, RANGER_LEVEL_IND);
  }  
  if (IS_SET(ch->player.iClass, CLASS_PSI)) {
    advance_level(ch, PSI_LEVEL_IND);
  }  

}
Beispiel #10
0
/* Some initializations for characters, including initial skills
   If mode == 0, then act as though the character was entering the
   game for the first time.  Otherwise, act as though the character
   is being set to that level.
 */
void
do_start(struct creature *ch, int mode)
{
    void advance_level(struct creature *ch, int8_t keep_internal);
    int8_t new_player = 0;
    int i;
    struct obj_data *implant_save[NUM_WEARS];
    struct obj_data *tattoo_save[NUM_WEARS];

    // remove implant affects
    for (i = 0; i < NUM_WEARS; i++) {
        if (GET_IMPLANT(ch, i))
            implant_save[i] = raw_unequip_char(ch, i, EQUIP_IMPLANT);
        else
            implant_save[i] = NULL;
        if (GET_TATTOO(ch, i))
            tattoo_save[i] = raw_unequip_char(ch, i, EQUIP_TATTOO);
        else
            tattoo_save[i] = NULL;
    }

    if (GET_EXP(ch) == 0 && !IS_REMORT(ch) && !IS_VAMPIRE(ch))
        new_player = true;

    GET_LEVEL(ch) = 1;
    GET_EXP(ch) = 1;

    if (mode)
        roll_real_abils(ch);

    for (i = 1; i <= MAX_SKILLS; i++)
        SET_SKILL(ch, i, 0);

    if (IS_VAMPIRE(ch))
        GET_LIFE_POINTS(ch) = 1;
    else
        GET_LIFE_POINTS(ch) = 3 * (GET_WIS(ch) + GET_CON(ch)) / 40;

    ch->points.max_hit = 20;
    ch->points.max_mana = 100;
    ch->points.max_move = 82;

    if (IS_TABAXI(ch)) {
        SET_SKILL(ch, SKILL_CLAW, LEARNED(ch));
        SET_SKILL(ch, SKILL_BITE, LEARNED(ch));
    }
    if (IS_ELF(ch)) {
        SET_SKILL(ch, SKILL_ARCHERY, LEARNED(ch));
    }

    switch (GET_CLASS(ch)) {
    case CLASS_MAGIC_USER:
        SET_SKILL(ch, SKILL_PUNCH, 10);
        break;
    case CLASS_CLERIC:
        SET_SKILL(ch, SKILL_PUNCH, 10);
        break;
    case CLASS_THIEF:
        SET_SKILL(ch, SKILL_PUNCH, 15);
        SET_SKILL(ch, SKILL_SNEAK, 10);
        SET_SKILL(ch, SKILL_HIDE, 5);
        SET_SKILL(ch, SKILL_STEAL, 15);
        break;
    case CLASS_WARRIOR:
        SET_SKILL(ch, SKILL_PUNCH, 20);
        break;
    case CLASS_BARB:
        SET_SKILL(ch, SKILL_PUNCH, 15);
        break;
    case CLASS_PSIONIC:
        SET_SKILL(ch, SKILL_PUNCH, 10);
        break;
    case CLASS_PHYSIC:
        SET_SKILL(ch, SKILL_PUNCH, 10);
        break;
    case CLASS_CYBORG:
        SET_SKILL(ch, SKILL_PUNCH, 10);
        break;
    case CLASS_KNIGHT:
        SET_SKILL(ch, SKILL_PUNCH, 20);
        break;
    case CLASS_RANGER:
        SET_SKILL(ch, SKILL_PUNCH, 15);
        GET_MAX_MOVE(ch) += dice(4, 9);
        break;
    case CLASS_MONK:
        SET_SKILL(ch, SKILL_PUNCH, 20);
        break;
    case CLASS_MERCENARY:
        SET_SKILL(ch, SKILL_PUNCH, 20);
    case CLASS_BARD:
        SET_SKILL(ch, SKILL_PUNCH, 25);
        SET_SKILL(ch, SKILL_ARCHERY, 25);
        break;

    }

    if (new_player) {
        if (PAST_CLASS(GET_CLASS(ch))) {
            deposit_past_bank(ch->desc->account,
                8192 + number(256, 2048) + GET_INT(ch) + GET_WIS(ch));
            ch->points.gold =
                8192 + number(256, 2048) + GET_INT(ch) + GET_WIS(ch);
        } else if (FUTURE_CLASS(GET_CLASS(ch))) {
            deposit_future_bank(ch->desc->account,
                8192 + number(256, 2048) + GET_INT(ch) + GET_WIS(ch));
            ch->points.cash =
                8192 + number(256, 2048) + GET_INT(ch) + GET_WIS(ch);
        }

        // New players do not start with the gown at this point
        // This has been left in for reference for generic newbie starting gear for the future.
        // New players start with a hospital gown and items most dear to them
        /*
        struct obj_data *gown = read_object(33800);
        if (gown != NULL) {
            equip_char(ch, gown, WEAR_ABOUT, EQUIP_WORN);
        }
        */

        // Good clerics start with a holy symbol on neck
        if ((GET_CLASS(ch) == CLASS_CLERIC) && IS_GOOD(ch)) {
            struct obj_data *talisman = read_object(1280);
            if (talisman != NULL) {
                equip_char(ch, talisman, WEAR_NECK_1, EQUIP_WORN);
            }
        }

        // Evil clerics start with a holy symbol on hold
        if ((GET_CLASS(ch) == CLASS_CLERIC) && IS_EVIL(ch)) {
            struct obj_data *symbol = read_object(1260);
            if (symbol != NULL) {
                equip_char(ch, symbol, WEAR_HOLD, EQUIP_WORN);
            }
        }

        // Good knights start with a holy symbol on finger
        if ((GET_CLASS(ch) == CLASS_KNIGHT) && IS_GOOD(ch)) {
            struct obj_data *ring = read_object(1287);
            if (ring != NULL) {
                equip_char(ch, ring, WEAR_FINGER_L, EQUIP_WORN);
            }
        }

        // Evil knights start with a holy symbol on neck
        if ((GET_CLASS(ch) == CLASS_KNIGHT) && IS_EVIL(ch)) {
            struct obj_data *pendant = read_object(1270);
            if (pendant != NULL) {
                equip_char(ch, pendant, WEAR_NECK_1, EQUIP_WORN);
            }
        }

        // Bards start with a percussion instrument held, and stringed in inventory
        if (GET_CLASS(ch) == CLASS_BARD) {
            struct obj_data *lute = read_object(3218);
            if (lute != NULL) {
                obj_to_char(lute, ch);
            }
        }
   
        set_title(ch, "the complete newbie");
    }

    advance_level(ch, 0);

    GET_MAX_MOVE(ch) += GET_CON(ch);

    GET_HIT(ch) = GET_MAX_HIT(ch);
    GET_MANA(ch) = GET_MAX_MANA(ch);
    GET_MOVE(ch) = GET_MAX_MOVE(ch);

    GET_COND(ch, THIRST) = 24;
    GET_COND(ch, FULL) = 24;
    GET_COND(ch, DRUNK) = 0;

    if (new_player) {
        ch->player.time.played = 0;
        ch->player.time.logon = time(NULL);
    }

    for (i = 0; i < NUM_WEARS; i++) {
        if (implant_save[i])
            equip_char(ch, implant_save[i], i, EQUIP_IMPLANT);
        if (tattoo_save[i])
            equip_char(ch, tattoo_save[i], i, EQUIP_TATTOO);
    }
}