Skip to content

Commit

Permalink
Fixed bugs with fast healing and hp regen modifiers.
Browse files Browse the repository at this point in the history
If you are riding a mount who is flying or levitating, you benefit from the same for movement purposes.
Fixed blocker flags all defaulting to block east.
Added block evil, neutral and good flags.
Added unstuck command.
Fixed ital strike.
Fixed a problem with spells command when recently gained a level in a non-spellcasting class.
Improved supplyorder rewards and limited them to 10 per real 24 day. Resets at server midnight.
Reduced mobile spell damage.
Fixed a bug with virtual bag item duplicating.
Made the @ symbol on its own line an additional way to save text in the text editor, in additon to /s
Added dragonlance regions.
Reduced duration on ability score paralysis (when an ability scorfe drop below 1)
Reduced duration on all paralysis and stun spells and effects to be more manageable in combat. Many were essentially a death sentence because they lasted so long.
Fixed a number of creature summoning type spells.
Fixed issue with concealing amorpha not being able to target another creature when using sufficient augment psp.
Fixed mountain dwarf (dragonlance) racial strength modifier from +1 to +2.
Adjusted fast travel durations.
Fixed channel energy for inquisitors and blackguards.
  • Loading branch information
GickerLDS committed Oct 30, 2023
1 parent b5ce3dc commit c1724b7
Show file tree
Hide file tree
Showing 30 changed files with 977 additions and 459 deletions.
3 changes: 3 additions & 0 deletions act.h
Original file line number Diff line number Diff line change
Expand Up @@ -640,6 +640,7 @@ ACMD_DECL(do_planarsoul);
ACMD_DECL(do_grand_destiny);
ACMD_DECL(do_evoweb);
ACMD_DECL(do_evobreath);
ACMD_DECL(do_vital_strike);

/*****************************************************************************
* Begin Functions and defines for act.other.c
Expand Down Expand Up @@ -795,6 +796,7 @@ ACMDCHECK(can_tinker);
ACMD_DECL(do_tinker);
ACMD_DECL(do_eldritch);
ACMD_DECL(do_borrow);
ACMD_DECL(do_unstuck);

/*****************************************************************************
* Begin Functions and defines for act.social.c
Expand Down Expand Up @@ -969,6 +971,7 @@ ACMD_DECL(do_dragonmagic);
ACMD_DECL(do_resetpassword);
ACMD_DECL(do_holyweapon);
ACMD_DECL(do_award);
ACMD_DECL(do_show_blockers);

// encounters.c
ACMD_DECL(do_encounterinfo);
Expand Down
18 changes: 13 additions & 5 deletions act.informative.c
Original file line number Diff line number Diff line change
Expand Up @@ -1262,7 +1262,7 @@ void look_at_room(struct char_data *ch, int ignore_brief)
snprintf(buf, sizeof(buf),
"This large passenger ship has been built with reasonably good comforts given the limited space on board.\r\n"
"The wind fills the sails as it pushes the vessel along to your destination. The sway of the sea is steady\r\n"
"and rythemic, and you find you sea legs quickly. Judging by how far you've gone so far you should arrive in\r\n"
"and rhythmic, and you find you sea legs quickly. Judging by how far you've gone so far you should arrive in\r\n"
"about %d minutes and %d seconds to your destination: %s.\r\n",
ch->player_specials->travel_timer / 60, ch->player_specials->travel_timer % 60, sailing_locales[ch->player_specials->travel_locale][0]);
rm->description = strdup(buf);
Expand Down Expand Up @@ -3122,6 +3122,11 @@ ACMD(do_defenses)
send_to_char(ch, "\tC");
draw_line(ch, line_length, '-', '-');
send_to_char(ch, "\tn\r\nNote that AC caps at %d, but having over %d is beneficial due to position changes and debuffs.\r\n", CONFIG_PLAYER_AC_CAP, CONFIG_PLAYER_AC_CAP);
text_line(ch, "\tYFast Healing\tC", line_length, '-', '-');
send_to_char(ch, "Fast Healing Amount: %d\r\n", get_fast_healing_amount(ch));
send_to_char(ch, "\tC");
draw_line(ch, line_length, '-', '-');
send_to_char(ch, "\tn");
}

/*
Expand Down Expand Up @@ -3555,7 +3560,7 @@ void show_bags_summary(struct char_data *ch)
ACMD(do_bags)
{
char arg[MEDIUM_STRING] = {'\0'};
char bagname[MEDIUM_STRING] = {'\0'};
// char bagname[MEDIUM_STRING] = {'\0'};
int bagnum = 0, i = 0;

one_argument(argument, arg, sizeof(arg));
Expand Down Expand Up @@ -3588,10 +3593,13 @@ ACMD(do_bags)
return;
}

if (GET_BAG_NAME(ch, i) != NULL)
snprintf(bagname, sizeof(bagname), " '%s'", GET_BAG_NAME(ch, i));
// if (GET_BAG_NAME(ch, i) != NULL)
// snprintf(bagname, sizeof(bagname), " '%s'", GET_BAG_NAME(ch, i));
// else
// snprintf(bagname, sizeof(bagname), " 'bag%d'", bagnum);

send_to_char(ch, "Your bag #%d%s contains:\r\n", bagnum, GET_BAG_NAME(ch, i) != NULL ? bagname : "");
// send_to_char(ch, "Your bag #%d%s contains:\r\n", bagnum, GET_BAG_NAME(ch, i) != NULL ? bagname : "");
send_to_char(ch, "Your bag #%d contains:\r\n", bagnum);

switch (bagnum)
{
Expand Down
125 changes: 110 additions & 15 deletions act.movement.c
Original file line number Diff line number Diff line change
Expand Up @@ -386,6 +386,14 @@ int has_boat(struct char_data *ch, room_rnum going_to)
AFF_FLAGGED(ch, AFF_LEVITATE))
return (1);

if (RIDING(ch))
{
if (AFF_FLAGGED(RIDING(ch), AFF_WATERWALK))
return TRUE;
if (AFF_FLAGGED(RIDING(ch), AFF_LEVITATE))
return TRUE;
}

/* non-wearable boats in inventory will do it */
for (obj = ch->carrying; obj; obj = obj->next_content)
if (GET_OBJ_TYPE(obj) == ITEM_BOAT && (find_eq_pos(ch, obj, NULL) < 0))
Expand Down Expand Up @@ -1065,21 +1073,21 @@ int do_simple_move(struct char_data *ch, int dir, int need_specials_check)
block = TRUE;
else if (dir == EAST && MOB_FLAGGED(mob, MOB_BLOCK_E))
block = TRUE;
else if (dir == SOUTH && MOB_FLAGGED(mob, MOB_BLOCK_E))
else if (dir == SOUTH && MOB_FLAGGED(mob, MOB_BLOCK_S))
block = TRUE;
else if (dir == WEST && MOB_FLAGGED(mob, MOB_BLOCK_E))
else if (dir == WEST && MOB_FLAGGED(mob, MOB_BLOCK_W))
block = TRUE;
else if (dir == NORTHEAST && MOB_FLAGGED(mob, MOB_BLOCK_E))
else if (dir == NORTHEAST && MOB_FLAGGED(mob, MOB_BLOCK_NE))
block = TRUE;
else if (dir == SOUTHEAST && MOB_FLAGGED(mob, MOB_BLOCK_E))
else if (dir == SOUTHEAST && MOB_FLAGGED(mob, MOB_BLOCK_SE))
block = TRUE;
else if (dir == SOUTHWEST && MOB_FLAGGED(mob, MOB_BLOCK_E))
else if (dir == SOUTHWEST && MOB_FLAGGED(mob, MOB_BLOCK_SW))
block = TRUE;
else if (dir == NORTHWEST && MOB_FLAGGED(mob, MOB_BLOCK_E))
else if (dir == NORTHWEST && MOB_FLAGGED(mob, MOB_BLOCK_NW))
block = TRUE;
else if (dir == UP && MOB_FLAGGED(mob, MOB_BLOCK_E))
else if (dir == UP && MOB_FLAGGED(mob, MOB_BLOCK_U))
block = TRUE;
else if (dir == DOWN && MOB_FLAGGED(mob, MOB_BLOCK_E))
else if (dir == DOWN && MOB_FLAGGED(mob, MOB_BLOCK_D))
block = TRUE;

if (block && MOB_FLAGGED(mob, MOB_BLOCK_RACE) && GET_RACE(ch) == GET_RACE(mob))
Expand All @@ -1096,18 +1104,23 @@ int do_simple_move(struct char_data *ch, int dir, int need_specials_check)
block = FALSE;
if (block && MOB_FLAGGED(mob, MOB_BLOCK_ALIGN) && IS_NEUTRAL(ch) > IS_NEUTRAL(mob))
block = FALSE;
if (block && MOB_FLAGGED(mob, MOB_BLOCK_EVIL) && (IS_NEUTRAL(ch) || IS_GOOD(ch)))
block = FALSE;
if (block && MOB_FLAGGED(mob, MOB_BLOCK_NEUTRAL) && (IS_EVIL(ch) || IS_GOOD(ch)))
block = FALSE;
if (block && MOB_FLAGGED(mob, MOB_BLOCK_GOOD) && (IS_NEUTRAL(ch) || IS_EVIL(ch)))
block = FALSE;

if (block)
break;
}

// this is removed until we can fix blocker mobs
// if (block && !IS_NPC(ch) && !PRF_FLAGGED(ch, PRF_NOHASSLE))
// {
// act("$N blocks your from travelling in that direction.", FALSE, ch, 0, mob, TO_CHAR);
// act("$n tries to leave the room, but $N blocks $m from travelling in their direction.", FALSE, ch, 0, mob, TO_ROOM);
// return 0;
// }
if (block && !IS_NPC(ch) && !PRF_FLAGGED(ch, PRF_NOHASSLE))
{
act("$N blocks your from travelling in that direction.", FALSE, ch, 0, mob, TO_CHAR);
act("$n tries to leave the room, but $N blocks $m from travelling in their direction.", FALSE, ch, 0, mob, TO_ROOM);
return 0;
}

// acrobatics check

Expand Down Expand Up @@ -4025,6 +4038,88 @@ ACMD(do_transposition)
USE_STANDARD_ACTION(ch);
}

ACMD(do_unstuck)
{
char arg1[200];
char *confirm;
int exp = 0, gold = 0;

exp = GET_LEVEL(ch) * GET_LEVEL(ch) * 500;
gold = GET_LEVEL(ch) * GET_LEVEL(ch) * 5;

if (GET_LEVEL(ch) <= 5)
exp = gold = 0;
else if (GET_LEVEL(ch) <= 10)
{ exp /= 4; gold /= 4; }
else if (GET_LEVEL(ch) <= 20)
{ exp /= 2; gold /= 2; }

if (ch->player_specials->unstuck == NULL)
{
ch->player_specials->unstuck = confirm = randstring(6);
}
else
{
confirm = ch->player_specials->unstuck;
}

one_argument(argument, arg1, sizeof(arg1));

if (!*arg1)
{
send_to_char(ch, "Please enter 'unstuck %s' to confirm your desire to become unstuck.\r\n"
"You will be transported to the MUD start room", confirm);
if (exp > 0)
send_to_char(ch, ", and it will cost you %d experience points and %d coins", exp, gold);
send_to_char(ch, ".\r\n");
return;
}
if (strcmp(arg1, ch->player_specials->unstuck))
{
send_to_char(ch, "Please enter 'unstuck %s' to confirm your desire to become unstuck.\r\n"
"You will be transported to the MUD start room", confirm);
if (exp > 0)
send_to_char(ch, ", and it will cost you %d experience points and %d coins", exp, gold);
send_to_char(ch, ".\r\n");
return;
}
else
{
GET_EXP(ch) -= exp;
send_to_char(ch, "You lose %d experience points.\r\n", exp);
if (GET_GOLD(ch) < gold)
{
gold -= GET_GOLD(ch);
send_to_char(ch, "You lose %d gold ", gold);
GET_GOLD(ch) = 0;
if (GET_BANK_GOLD(ch) < gold)
{
gold = GET_BANK_GOLD(ch);
send_to_char(ch, "and %d bank gold.\r\n", gold);
GET_BANK_GOLD(ch) = 0;
}
else
{
GET_BANK_GOLD(ch) -= gold;
send_to_char(ch, "and %d bank gold.\r\n", gold);
}
}
else
{
GET_GOLD(ch) -= gold;
send_to_char(ch, "You lose %d gold.\r\n", gold);
}
}
act("$n disappears.", TRUE, ch, 0, 0, TO_ROOM);
char_from_room(ch);
char_to_room(ch, real_room(16500));
act("$n appears in the middle of the room.", TRUE, ch, 0, 0, TO_ROOM);
look_at_room(ch, 0);
entry_memory_mtrigger(ch);
greet_mtrigger(ch, -1);
greet_memory_mtrigger(ch);
}

/* undefines */
#undef PRISONER_KEY_1
#undef PRISONER_KEY_2
Expand Down
22 changes: 22 additions & 0 deletions act.offensive.c
Original file line number Diff line number Diff line change
Expand Up @@ -9884,6 +9884,28 @@ ACMD(do_evobreath)
USE_STANDARD_ACTION(ch);
}

ACMD(do_vital_strike)
{
if (!HAS_FEAT(ch, FEAT_VITAL_STRIKE))
{
send_to_char(ch, "You do not know how to perform a vital strike.\r\n");
return;
}

if (VITAL_STRIKING(ch))
{
VITAL_STRIKING(ch) = FALSE;
act("You cease concentrating your attacks into a single vital strike!", TRUE, ch, 0, 0, TO_CHAR);
}
else
{
USE_FULL_ROUND_ACTION(ch);
VITAL_STRIKING(ch) = TRUE;
act("You concentrate your attacks into a single vital strike!", TRUE, ch, 0, 0, TO_CHAR);
}

}

/* cleanup! */
#undef RAGE_AFFECTS
#undef D_STANCE_AFFECTS
Expand Down
99 changes: 50 additions & 49 deletions act.other.c
Original file line number Diff line number Diff line change
Expand Up @@ -5386,7 +5386,7 @@ ACMD(do_spells)
}
else
{
if (get_number_of_spellcasting_classes(ch) == 1 && GET_LEVEL(ch) < LVL_IMMORT)
if (get_number_of_spellcasting_classes(ch) == 1 && GET_LEVEL(ch) < LVL_IMMORT && IS_SPELLCASTER_CLASS(GET_CLASS(ch)))
class = GET_CLASS(ch);
else if (subcmd == SCMD_CONCOCT)
class = CLASS_ALCHEMIST;
Expand Down Expand Up @@ -8348,15 +8348,14 @@ ACMDU(do_fiendishboon)

#define NOBUFF_MSG "buff add (spell/power name) - Add a spell or power to your buff list.\r\n" \
"buff remove (spell/power name) - Remove a spell or power from your buff list\r\n" \
"buff (augment amount) (psionic power name) - Assign extra psp to augment a buff power\r\n" \
"buff list - Will show you the spells and powers in your list\r\n" \
"buff perform - Will begin buffing you with your buff list\r\n" \
"buff cancel - Will can any buffing action in process.\r\n"

ACMD(do_buff)
{
char arg1[200], arg2[200];
int spellnum = 0, i = 0, aug = 0;
int spellnum = 0, i = 0;
int is_spell = true; // true if it's a spell, false if it's a psionic power
bool found = false;
struct char_data *target;
Expand Down Expand Up @@ -8429,51 +8428,52 @@ ACMD(do_buff)
}
}

if (isdigit(*arg1))
{

send_to_char(ch, "Buffing with psionics is not possible right now due to a serious, yet unresolved bug.\r\n");
return;

// Assign augment psp to specified psionic power.

if (!*arg2)
{
send_to_char(ch, "Please specify the psionic power buff you wish to assign augment psp to.\r\n");
return;
}

if (is_spell)
{
send_to_char(ch, "You can only assign augment psp to a psionic power.\r\n");
return;
}

aug = atoi(arg1);

if (aug < 0)
{
send_to_char(ch, "Please specify the amount of psp you wish to use to augment this psionnic buff.\r\n");
return;
}

for (i = 0; i < MAX_BUFFS; i++)
{
if (GET_BUFF(ch, i, 0) == spellnum)
{
found = true;
break;
}
}
if (!found)
{
send_to_char(ch, "You do not have any spells or powers in your buff list.\r\n");
return;
}
GET_BUFF(ch, i, 1) = aug;
send_to_char(ch, "You assign %d augment psp to '%s'.\r\n", aug, spell_info[spellnum].name);
}
else if (is_abbrev(arg1, "add"))
// if (isdigit(*arg1))
// {

// send_to_char(ch, "Buffing with psionics is not possible right now due to a serious, yet unresolved bug.\r\n");
// return;

// // Assign augment psp to specified psionic power.

// if (!*arg2)
// {
// send_to_char(ch, "Please specify the psionic power buff you wish to assign augment psp to.\r\n");
// return;
// }

// if (is_spell)
// {
// send_to_char(ch, "You can only assign augment psp to a psionic power.\r\n");
// return;
// }

// aug = atoi(arg1);

// if (aug < 0)
// {
// send_to_char(ch, "Please specify the amount of psp you wish to use to augment this psionnic buff.\r\n");
// return;
// }

// for (i = 0; i < MAX_BUFFS; i++)
// {
// if (GET_BUFF(ch, i, 0) == spellnum)
// {
// found = true;
// break;
// }
// }
// if (!found)
// {
// send_to_char(ch, "You do not have any spells or powers in your buff list.\r\n");
// return;
// }
// GET_BUFF(ch, i, 1) = aug;
// send_to_char(ch, "You assign %d augment psp to '%s'.\r\n", aug, spell_info[spellnum].name);
// }
// else
if (is_abbrev(arg1, "add"))
{
// Add a spell/power to buff list.
for (i = 0; i < MAX_BUFFS; i++)
Expand Down Expand Up @@ -8531,7 +8531,8 @@ ACMD(do_buff)
}
else
{
send_to_char(ch, "-- %-25s %d augment psp\r\n", spell_info[GET_BUFF(ch, i, 0)].name, GET_BUFF(ch, i, 1));
// send_to_char(ch, "-- %-25s %d augment psp\r\n", spell_info[GET_BUFF(ch, i, 0)].name, GET_BUFF(ch, i, 1));
send_to_char(ch, "-- %-25s %s\r\n", spell_info[GET_BUFF(ch, i, 0)].name, PRF_FLAGGED(ch, PRF_AUGMENT_BUFFS) ? "*augmented*" : "");
}
}
}
Expand Down
Loading

0 comments on commit c1724b7

Please sign in to comment.