- Posts: 328
- Karma: 1
- Thank you received: 70
Cedit and Player Corpses
- WhiskyTest
-
Topic Author
- Offline
- Platinum Boarder
-
The changes focus on corpse retrieval, and what happens to players items.
Update the settings using the cedit Gameplay menu, options T and U.
Corpse Creation Level
Set the level players have to reach before their equipment is transferred into their corpse upon death.
Intended to save new players from corpse retrieval while they are still acclimatizing to your MUD.
Corpse Decay Behavior
Define what happens when the corpse decomposes.
Default: the corpse is removed and all items are dropped into the room
Donate: the corpse is removed and all items are donated into a random donation room
Delete: the corpse and all objects are deleted from the game
Expandable so you can add your own ideas
diff -BbuprN -x '*.o' "tbamud-master (1)/tbamud-master/src/cedit.c" tbamud-master/src/cedit.c
--- "tbamud-master (1)/tbamud-master/src/cedit.c" 2018-01-28 15:49:00.000000000 +0000
+++ tbamud-master/src/cedit.c 2018-12-09 10:00:55.505968500 +0000
@@ -88,6 +88,8 @@ static void cedit_setup(struct descripto
OLC_CONFIG(d)->play.max_exp_loss = CONFIG_MAX_EXP_LOSS;
OLC_CONFIG(d)->play.max_npc_corpse_time = CONFIG_MAX_NPC_CORPSE_TIME;
OLC_CONFIG(d)->play.max_pc_corpse_time = CONFIG_MAX_PC_CORPSE_TIME;
+ OLC_CONFIG(d)->play.corpse_decay_behavior = CONFIG_CORPSE_DECAY;
+ OLC_CONFIG(d)->play.corpse_create_level = CONFIG_CORPSE_LEVEL;
OLC_CONFIG(d)->play.idle_void = CONFIG_IDLE_VOID;
OLC_CONFIG(d)->play.idle_rent_time = CONFIG_IDLE_RENT_TIME;
OLC_CONFIG(d)->play.idle_max_level = CONFIG_IDLE_MAX_LEVEL;
/* Crash Saves */
OLC_CONFIG(d)->csd.free_rent = CONFIG_FREE_RENT;
@@ -192,6 +195,8 @@ static void cedit_save_internally(struct
CONFIG_MAX_EXP_LOSS = OLC_CONFIG(d)->play.max_exp_loss;
CONFIG_MAX_NPC_CORPSE_TIME = OLC_CONFIG(d)->play.max_npc_corpse_time;
CONFIG_MAX_PC_CORPSE_TIME = OLC_CONFIG(d)->play.max_pc_corpse_time;
+ CONFIG_CORPSE_DECAY = OLC_CONFIG(d)->play.corpse_decay_behavior;
+ CONFIG_CORPSE_LEVEL = OLC_CONFIG(d)->play.corpse_create_level;
CONFIG_IDLE_VOID = OLC_CONFIG(d)->play.idle_void;
CONFIG_IDLE_RENT_TIME = OLC_CONFIG(d)->play.idle_rent_time;
CONFIG_IDLE_MAX_LEVEL = OLC_CONFIG(d)->play.idle_max_level;
/* Crash Saves */
CONFIG_FREE_RENT = OLC_CONFIG(d)->csd.free_rent;
@@ -356,6 +362,10 @@ int save_config( IDXTYPE nowhere )
"max_npc_corpse_time = %d\n\n", CONFIG_MAX_NPC_CORPSE_TIME);
fprintf(fl, "* Number of tics before PC corpses decompose.\n"
"max_pc_corpse_time = %d\n\n", CONFIG_MAX_PC_CORPSE_TIME);
+ fprintf(fl, "* Minimum PC level when items are left in a corpse.\n"
+ "corpse_create_level = %d\n\n", CONFIG_CORPSE_LEVEL);
+ fprintf(fl, "* What happens to items when a PC corpse decays.\n"
+ "corpse_decay_behavior = %d\n\n", CONFIG_CORPSE_DECAY);
fprintf(fl, "* Number of tics before a PC is sent to the void.\n"
"idle_void = %d\n\n", CONFIG_IDLE_VOID);
fprintf(fl, "* Number of tics before a PC is autorented.\n"
strcpy(buf, CONFIG_OK);
@@ -625,6 +637,8 @@ static void cedit_disp_game_play_options
"%sG%s) Maximum Experience Loss : %s%d\r\n"
"%sH%s) Max Time for NPC Corpse : %s%d\r\n"
"%sI%s) Max Time for PC Corpse : %s%d\r\n"
+ "%sT%s) PC level corpse retrieval begins at : %s%d\r\n"
+ "%sU%s) Corpse decay behavior : %s%d\r\n"
"%sJ%s) Tics before PC sent to void : %s%d\r\n"
"%sK%s) Tics before PC is autosaved : %s%d\r\n"
"%sL%s) Level Immune To IDLE : %s%d\r\n"
@@ -653,7 +668,8 @@ static void cedit_disp_game_play_options
grn, nrm, cyn, OLC_CONFIG(d)->play.max_exp_loss,
grn, nrm, cyn, OLC_CONFIG(d)->play.max_npc_corpse_time,
grn, nrm, cyn, OLC_CONFIG(d)->play.max_pc_corpse_time,
-
+ grn, nrm, cyn, OLC_CONFIG(d)->play.corpse_create_level,
+ grn, nrm, cyn, OLC_CONFIG(d)->play.corpse_decay_behavior,
grn, nrm, cyn, OLC_CONFIG(d)->play.idle_void,
grn, nrm, cyn, OLC_CONFIG(d)->play.idle_rent_time,
grn, nrm, cyn, OLC_CONFIG(d)->play.idle_max_level,
@@ -981,6 +997,22 @@ void cedit_parse(struct descriptor_data
TOGGLE_VAR(OLC_CONFIG(d)->play.no_mort_to_immort);
break;
+ case 't':
+ case 'T':
+ write_to_output(d, "Enter the level at which PCs begin corpse retrieval :\r\n");
+ OLC_MODE(d) = CEDIT_CORPSE_CREATE_LEVEL;
+ return;
+
+ case 'u':
+ case 'U':
+ write_to_output(d, "Select behavior of items upon PC corpse decomposition\r\n");
+ write_to_output(d, "0) Default: items are left in the room\r\n");
+ write_to_output(d, "1) Items are donated to random donation rooms\r\n");
+ write_to_output(d, "2) Items are purged\r\n");
+ write_to_output(d, "Enter choice: ");
+ OLC_MODE(d) = CEDIT_CORPSE_DECAY_BEHAVIOR;
+ return;
+
case '1':
write_to_output(d, "Enter the OK message : ");
OLC_MODE(d) = CEDIT_OK;
@@ -1379,6 +1418,28 @@ void cedit_parse(struct descriptor_data
}
break;
+ case CEDIT_CORPSE_CREATE_LEVEL:
+ if (!*arg) {
+ write_to_output(d,
+ "That is an invalid choice!\r\n"
+ "Enter the level PCs need to begin retrieving corpses : ");
+ } else {
+ OLC_CONFIG(d)->play.corpse_create_level = atoi(arg);
+ cedit_disp_game_play_options(d);
+ }
+ break;
+
+ case CEDIT_CORPSE_DECAY_BEHAVIOR:
+ if (!*arg) {
+ write_to_output(d,
+ "That is an invalid choice!\r\n"
+ "Enter the decay behavior : ");
+ } else {
+ OLC_CONFIG(d)->play.corpse_decay_behavior = atoi(arg);
+ cedit_disp_game_play_options(d);
+ }
+ break;
+
case CEDIT_IDLE_VOID:
if (!*arg) {
write_to_output(d,
diff -BbuprN -x '*.o' "tbamud-master (1)/tbamud-master/src/config.c" tbamud-master/src/config.c
--- "tbamud-master (1)/tbamud-master/src/config.c" 2018-01-28 15:49:00.000000000 +0000
+++ tbamud-master/src/config.c 2018-12-09 09:53:26.257434600 +0000
@@ -67,6 +67,13 @@ int max_exp_loss = 500000; /* max losabl
int max_npc_corpse_time = 5;
int max_pc_corpse_time = 10;
+/* Minimum level for PCs to lose items into corpses upon death */
+int corpse_create_level = 0;
+
+/* Behavior of items in decaying corpses */
+int corpse_decay_behavior = CONFIG_DEFAULT_DECAY;
+
+
/* How many ticks before a player is sent to the void or idle-rented. */
int idle_void = 8;
int idle_rent_time = 48;
diff -BbuprN -x '*.o' "tbamud-master (1)/tbamud-master/src/config.h" tbamud-master/src/config.h
--- "tbamud-master (1)/tbamud-master/src/config.h" 2018-01-28 15:49:00.000000000 +0000
+++ tbamud-master/src/config.h 2018-12-09 09:53:26.288676500 +0000
@@ -24,6 +25,8 @@ extern int max_exp_gain;
extern int max_exp_loss;
extern int max_npc_corpse_time;
extern int max_pc_corpse_time;
+extern int corpse_create_level;
+extern int corpse_decay_behavior;
extern int idle_void;
extern int idle_rent_time;
extern int idle_max_level;
diff -BbuprN -x '*.o' "tbamud-master (1)/tbamud-master/src/db.c" tbamud-master/src/db.c
--- "tbamud-master (1)/tbamud-master/src/db.c" 2018-01-28 15:49:00.000000000 +0000
+++ tbamud-master/src/db.c 2018-12-09 09:53:26.241813900 +0000
@@ -3777,6 +3778,8 @@ static void load_default_config( void )
CONFIG_MAX_EXP_LOSS = max_exp_loss;
CONFIG_MAX_NPC_CORPSE_TIME = max_npc_corpse_time;
CONFIG_MAX_PC_CORPSE_TIME = max_pc_corpse_time;
+ CONFIG_CORPSE_DECAY = corpse_decay_behavior;
+ CONFIG_CORPSE_LEVEL = corpse_create_level;
CONFIG_IDLE_VOID = idle_void;
CONFIG_IDLE_RENT_TIME = idle_rent_time;
CONFIG_IDLE_MAX_LEVEL = idle_max_level;
@@ -3882,6 +3885,12 @@ void load_config( void )
case 'c':
if (!str_cmp(tag, "crash_file_timeout"))
CONFIG_CRASH_TIMEOUT = num;
+ else if (!str_cmp(tag, "corpse_create_level"))
+ CONFIG_CORPSE_LEVEL = num;
+ else if (!str_cmp(tag, "corpse_decay_behavior"))
+ CONFIG_CORPSE_DECAY = num;
break;
case 'd':
diff -BbuprN -x '*.o' "tbamud-master (1)/tbamud-master/src/fight.c" tbamud-master/src/fight.c
--- "tbamud-master (1)/tbamud-master/src/fight.c" 2018-01-28 15:49:00.000000000 +0000
+++ tbamud-master/src/fight.c 2018-12-09 10:51:32.935668500 +0000
@@ -189,7 +189,9 @@ static void make_corpse(struct char_data
SET_BIT_AR(GET_OBJ_WEAR(corpse), ITEM_WEAR_TAKE);
SET_BIT_AR(GET_OBJ_EXTRA(corpse), ITEM_NODONATE);
GET_OBJ_VAL(corpse, 0) = 0; /* You can't store stuff in a corpse */
- GET_OBJ_VAL(corpse, 3) = 1; /* corpse identifier */
+
+ GET_OBJ_VAL(corpse, 3) = IS_NPC(ch) ? NPC_CORPSE : PC_CORPSE; /* corpse identifier */
+
GET_OBJ_WEIGHT(corpse) = GET_WEIGHT(ch) + IS_CARRYING_W(ch);
GET_OBJ_RENT(corpse) = 100000;
if (IS_NPC(ch))
@@ -197,6 +199,10 @@ static void make_corpse(struct char_data
else
GET_OBJ_TIMER(corpse) = CONFIG_MAX_PC_CORPSE_TIME;
+ /* Begin item transferal */
+ if (!IS_NPC(ch) && (GET_LEVEL(ch) < CONFIG_CORPSE_LEVEL)) {
+ Crash_rentsave(ch, 0);
+ } else {
/* transfer character's inventory to the corpse */
corpse->contains = ch->carrying;
for (o = corpse->contains; o != NULL; o = o->next_content)
@@ -226,7 +232,8 @@ static void make_corpse(struct char_data
ch->carrying = NULL;
IS_CARRYING_N(ch) = 0;
IS_CARRYING_W(ch) = 0;
-
+ }
+ /* End item transferal */
obj_to_room(corpse, IN_ROOM(ch));
}
diff -BbuprN -x '*.o' "tbamud-master (1)/tbamud-master/src/limits.c" tbamud-master/src/limits.c
--- "tbamud-master (1)/tbamud-master/src/limits.c" 2018-01-28 15:49:00.000000000 +0000
+++ tbamud-master/src/limits.c 2018-12-09 10:21:00.849934600 +0000
@@ -373,12 +373,75 @@ static void check_idling(struct char_dat
}
}
}
+/* Deletes corpse object and leaves all contents in the room
++ * CONFIG_DEFAULT_DECAY
++ **/
+void corpse_decay_default(struct obj_data *j)
+{
+ struct obj_data *jj, *next_thing2;
+ for (jj = j->contains; jj; jj = next_thing2) {
+ next_thing2 = jj->next_content; /* Next in inventory */
+ obj_from_obj(jj);
+
+ if (j->in_obj)
+ obj_to_obj(jj, j->in_obj);
+ else if (j->carried_by)
+ obj_to_room(jj, IN_ROOM(j->carried_by));
+ else if (IN_ROOM(j) != NOWHERE)
+ obj_to_room(jj, IN_ROOM(j));
+ else
+ core_dump();
+ }
+ extract_obj(j);
+}
+
+/* Donates all objects from corpse
+ * CONFIG_DONATION_DECAY
+ * CONFIG_PROTECTED_DONATION_DECAY
+ */
+void corpse_decay_donate(struct obj_data *j)
{
+ room_rnum RDR = 0;
+ int num_don_rooms;
+ struct obj_data *jj, *next_thing2;
+
+ num_don_rooms = (CONFIG_DON_ROOM_1 != NOWHERE) +
+ (CONFIG_DON_ROOM_2 != NOWHERE) +
+ (CONFIG_DON_ROOM_3 != NOWHERE);
+
+ switch (rand_number(1, num_don_rooms)) {
+ case 1:
+ RDR = real_room(CONFIG_DON_ROOM_1);
+ break;
+ case 2:
+ RDR = real_room(CONFIG_DON_ROOM_2);
+ break;
+ case 3:
+ default:
+ RDR = real_room(CONFIG_DON_ROOM_3);
+ break;
+
+ }
+ if (RDR == NOWHERE) {
+ mudlog(BRF, LVL_IMPL, TRUE, "SYSERR: No valid donation room configured, corpse_decay_donate()");
+ RDR = j->in_room;
+ }
+
+ for (jj = j->contains; jj; jj = next_thing2) {
+ next_thing2 = jj->next_content; /* Next in inventory */
+ obj_from_obj(jj);
+ obj_to_room(jj, RDR);
+ act("$p suddenly appears in a puff a smoke!", FALSE, 0, jj, 0, TO_ROOM);
+ }
+
+ extract_obj(j);
+}
+
/* Update PCs, NPCs, and objects */
void point_update(void) {
struct char_data *i, *next_char;
- struct obj_data *j, *next_thing, *jj, *next_thing2;
+ struct obj_data *j, *next_thing;
/* characters */
for (i = character_list; i; i = next_char) {
@@ -432,35 +495,37 @@ void point_update(void)
act("A quivering horde of maggots consumes $p.",
TRUE, world[IN_ROOM(j)].people, j, 0, TO_CHAR);
}
- for (jj = j->contains; jj; jj = next_thing2) {
- next_thing2 = jj->next_content; /* Next in inventory */
- obj_from_obj(jj);
-
- if (j->in_obj)
- obj_to_obj(jj, j->in_obj);
- else if (j->carried_by)
- obj_to_room(jj, IN_ROOM(j->carried_by));
- else if (IN_ROOM(j) != NOWHERE)
- obj_to_room(jj, IN_ROOM(j));
- else
- core_dump();
- }
- extract_obj(j);
- }
- }
+ if (IS_PC_CORPSE(j)) {
+ switch (CONFIG_CORPSE_DECAY) {
+ case CONFIG_DONATION_DECAY:
+ corpse_decay_donate(j);
+ break;
+ case CONFIG_PURGE_DECAY:
+ extract_obj(j);
+ break;
+ case CONFIG_DEFAULT_DECAY:
+ default:
+ corpse_decay_default(j);
+ break;
+ }
+ } else
+ corpse_decay_default(j);
+
+ }
/* If the timer is set, count it down and at 0, try the trigger
diff -BbuprN -x '*.o' "tbamud-master (1)/tbamud-master/src/oasis.h" tbamud-master/src/oasis.h
--- "tbamud-master (1)/tbamud-master/src/oasis.h" 2018-01-28 15:49:00.000000000 +0000
+++ tbamud-master/src/oasis.h 2018-12-09 09:53:26.288676500 +0000
@@ -380,6 +380,9 @@ extern const char *nrm, *grn, *cyn, *yel
#define CEDIT_MAP_SIZE 55
#define CEDIT_MINIMAP_SIZE 56
#define CEDIT_DEBUG_MODE 57
+#define CEDIT_CORPSE_CREATE_LEVEL 58
+#define CEDIT_CORPSE_DECAY_BEHAVIOR 59
/* Hedit Submodes of connectedness. */
#define HEDIT_CONFIRM_SAVESTRING 0
diff -BbuprN -x '*.o' "tbamud-master (1)/tbamud-master/src/structs.h" tbamud-master/src/structs.h
--- "tbamud-master (1)/tbamud-master/src/structs.h" 2018-01-28 15:49:00.000000000 +0000
+++ tbamud-master/src/structs.h 2018-12-09 10:15:24.923320200 +0000
@@ -427,6 +428,10 @@
/** Total number of item flags */
#define NUM_ITEM_FLAGS 18
+/* Corpse identifiers */
+#define PC_CORPSE 1
+#define NPC_CORPSE 2
+
/* Modifier constants used with obj affects ('A' fields) */
#define APPLY_NONE 0 /**< No effect */
#define APPLY_STR 1 /**< Apply to strength */
@@ -1298,6 +1303,8 @@ struct game_data
int max_exp_loss; /**< Maximum experience losable per death.*/
int max_npc_corpse_time; /**< Num tics before NPC corpses decompose*/
int max_pc_corpse_time; /**< Num tics before PC corpse decomposes.*/
+ int corpse_decay_behavior; /**< Corpse decay behavior settings */
+ int corpse_create_level; /**< Minimum PC level before items are transferred to their corpse */
int idle_void; /**< Num tics before PC sent to void(idle)*/
int idle_rent_time; /**< Num tics before PC is autorented. */
int idle_max_level; /**< Level of players immune to idle. */
diff -BbuprN -x '*.o' "tbamud-master (1)/tbamud-master/src/utils.h" tbamud-master/src/utils.h
--- "tbamud-master (1)/tbamud-master/src/utils.h" 2018-01-28 15:49:00.000000000 +0000
+++ tbamud-master/src/utils.h 2018-12-09 10:15:24.916338900 +0000
@@ -18,6 +18,9 @@
#ifndef _UTILS_H_ /* Begin header file protection */
#define _UTILS_H_
+#include "structs.h"
+
+
/** Definition of the action command, for the do_ series of in game functions.
* This macro is placed here (for now) because it's too general of a macro
* to be first defined in interpreter.h. The reason for using a macro is
@@ -728,7 +731,11 @@ do
/** Defines if an obj is a corpse. */
#define IS_CORPSE(obj) (GET_OBJ_TYPE(obj) == ITEM_CONTAINER && \
- GET_OBJ_VAL((obj), 3) == 1)
+ GET_OBJ_VAL((obj), 3) > 0)
+
+/** Defines if an obj is a players corpse. */
+#define IS_PC_CORPSE(obj) (GET_OBJ_TYPE(obj) == ITEM_CONTAINER && \
+ GET_OBJ_VAL((obj), 3) == PC_CORPSE)
/** Can the obj be worn on body part? */
#define CAN_WEAR(obj, part) OBJWEAR_FLAGGED((obj), (part))
@@ -953,6 +960,18 @@ do
#define CONFIG_MAX_NPC_CORPSE_TIME config_info.play.max_npc_corpse_time
/** How long will pc corpses last before decomposing? */
#define CONFIG_MAX_PC_CORPSE_TIME config_info.play.max_pc_corpse_time
+
+/** Behavior of corpses at decay time */
+#define CONFIG_CORPSE_DECAY config_info.play.corpse_decay_behavior
+
+/* Corpse decay defines */
+#define CONFIG_DEFAULT_DECAY 0 /* Default: items are left in the room */
+#define CONFIG_DONATION_DECAY 1 /* Items are sent to random donation rooms */
+#define CONFIG_PURGE_DECAY 2 /* Items are purged */
+
+/** What level must a PC be before subject to corpse creation */
+#define CONFIG_CORPSE_LEVEL config_info.play.corpse_create_level
+
/** How long can a pc be idled before being pulled into the void? */
#define CONFIG_IDLE_VOID config_info.play.idle_void
/** How long until the idle pc is force rented? */
Please Log in or Create an account to join the conversation.
- Chime
-
- Offline
- Senior Boarder
-
- Posts: 43
- Thank you received: 9
Please Log in or Create an account to join the conversation.
- WhiskyTest
-
Topic Author
- Offline
- Platinum Boarder
-
- Posts: 328
- Karma: 1
- Thank you received: 70
And a bug correction, thanks to Vivienne:
case 'u':
case 'U':
write_to_output(d, "Select behavior of items upon PC corpse decomposition\r\n");
write_to_output(d, "0) Default: items are left in the room\r\n");
write_to_output(d, "1) Items are donated randomly\r\n");
write_to_output(d, "2) Items are purged\r\n");
write_to_output(d, "Enter choice: ");
OLC_MODE(d) = CEDIT_CORPSE_DECAY_BEHAVIOR;
return;
Please Log in or Create an account to join the conversation.
- Sascha
-
- Offline
- Gold Boarder
-
Will you stand against the coming Storm? After the Breaking: STORMRIDERS MUD - atbmud.dune.net port 4000
Please Log in or Create an account to join the conversation.
- Sascha
-
- Offline
- Gold Boarder
-
Will you stand against the coming Storm? After the Breaking: STORMRIDERS MUD - atbmud.dune.net port 4000
Please Log in or Create an account to join the conversation.
- Sascha
-
- Offline
- Gold Boarder
-
Will you stand against the coming Storm? After the Breaking: STORMRIDERS MUD - atbmud.dune.net port 4000
Please Log in or Create an account to join the conversation.
- WhiskyTest
-
Topic Author
- Offline
- Platinum Boarder
-
- Posts: 328
- Karma: 1
- Thank you received: 70
Please Log in or Create an account to join the conversation.
- Sascha
-
- Offline
- Gold Boarder
-
[ 3715] The Lair of the Rat King [ DARK INDOORS * ] [ Inside ]
A part of the sewer tunnels has been blockaded by a morass of junk and litter.
In the far corner is a huge nest made of trash and old bleached bones.
Glittering objects litter the nest, interspersed with foul bits and pieces of
refuse. There are deep claw marks in the stone floor, and there are splashes of
something rusty on the lower parts of the tunnel walls.
[ Exits: n ]
[65535] The corpse of the big rat is lying here.
[3700] [T862] A pile of glittering objects has been gathered here.
[3713] A piece of fungus grows with an eerie light.
[3702] [T3703] A huge rat lashes its tail as you approach.
[3703] [TRIGS] The Rat King is standing here.
i1 510hp 110mn 92mv>
l king
At first look this creature is the largest rat ever seen. Its body is covered
in mottled fur and its beady eyes glitter with malice. On second look the fur
is actually clothing made from bits and pieces of animal skins, but the malice
in the man's eyes is very real.
The Rat King is in excellent condition.
The Rat King is using:
<worn on body> [3714] a fur shirt
<worn on head> [3719] a crown of twisted scrap metal
<worn on legs> [3715] some fur-covered leggings
<worn on feet> [3716] a pair of fur-trimmed boots
<worn on hands> [3717] a pair of claw-tipped fur gloves
<worn about waist> [3718] a beltpouch
<wielded> [431] a silver-chased dagger
You attempt to peek at its inventory:
Nothing.
i1 510hp 110mn 92mv>
k king
You chop it to pieces! Ah! The blood!
Your blood freezes as you hear the Rat King's death cry.
i1 510hp 110mn 92mv>
The protector rat stops following the Rat King.
i1 510hp 110mn 92mv>
l
[ 3715] The Lair of the Rat King [ DARK INDOORS * ] [ Inside ]
A part of the sewer tunnels has been blockaded by a morass of junk and litter.
In the far corner is a huge nest made of trash and old bleached bones.
Glittering objects litter the nest, interspersed with foul bits and pieces of
refuse. There are deep claw marks in the stone floor, and there are splashes of
something rusty on the lower parts of the tunnel walls.
[ Exits: n ]
[431] A sharp dagger with a silver-chased hilt glints in the light.
[3718] A beltpouch is here.
[3717] A pair of furry gloves tipped with sharp claws have been left here.
[3716] A pair of boots trimmed with fur stand together.
[3715] A scant length of fur is folded here.
[3719] Some shiny scrap metal has been twisted together into a band.
[3714] A shirt made of animal fur lies in a pile.
[65535] The corpse of the Rat King is lying here.
[65535] The corpse of the big rat is lying here.
[3700] [T862] A pile of glittering objects has been gathered here.
[3713] A piece of fungus grows with an eerie light.
[3702] [T3703] A huge rat lashes its tail as you approach.
i1 510hp 110mn 92mv>
Will you stand against the coming Storm? After the Breaking: STORMRIDERS MUD - atbmud.dune.net port 4000
Please Log in or Create an account to join the conversation.
- WhiskyTest
-
Topic Author
- Offline
- Platinum Boarder
-
- Posts: 328
- Karma: 1
- Thank you received: 70
I need to have a closer look at this when I get home, but for a quick fix try this:
in fight.c, make this change
+ /* Begin item transferal */
+ if (IS_NPC(ch) || (!IS_NPC(ch) && GET_LEVEL(ch) > CONFIG_CORPSE_LEVEL)) {
/* transfer character's inventory to the corpse */
corpse->contains = ch->carrying;
for (o = corpse->contains; o != NULL; o = o->next_content)
I realize now that mob corpses will also be subject to the decay rules - was this what you wanted? Or only player corpse contents should get donated etc?..
Please Log in or Create an account to join the conversation.
- Sascha
-
- Offline
- Gold Boarder
-
Will you stand against the coming Storm? After the Breaking: STORMRIDERS MUD - atbmud.dune.net port 4000
Please Log in or Create an account to join the conversation.
- WhiskyTest
-
Topic Author
- Offline
- Platinum Boarder
-
- Posts: 328
- Karma: 1
- Thank you received: 70
Sorry I didn't catch this earlier it's kind of obvious now!..
Please Log in or Create an account to join the conversation.
- WhiskyTest
-
Topic Author
- Offline
- Platinum Boarder
-
- Posts: 328
- Karma: 1
- Thank you received: 70
1) Mobs no longer affected by the decay behaviors
2) Players below the corpse retrieval level are now crash-saved upon being killed to correctly retain their equipment before extraction
Thanks Viv for highlighting these!
Happy to help if you need a hand updating your existing code
Please Log in or Create an account to join the conversation.
- Sascha
-
- Offline
- Gold Boarder
-
mudlog(BRF, MAX(LVL_IMMORT, GET_INVIS_LEV(d->character)), TRUE, "Failure to AddRecentPlayer (returned FALSE).");
}
break;
-
+ }
case CON_RMOTD: /* read CR after printing motd */
write_to_output(d, "%s", CONFIG_MENU);
if (IS_HAPPYHOUR > 0){
Will you stand against the coming Storm? After the Breaking: STORMRIDERS MUD - atbmud.dune.net port 4000
Please Log in or Create an account to join the conversation.
- WhiskyTest
-
Topic Author
- Offline
- Platinum Boarder
-
- Posts: 328
- Karma: 1
- Thank you received: 70
Fortunately for this one, just ignore the pieces from interpreter.c.
I've updated the patch and spoiler.
The reason (if you're interested) is when I made the diff, it wasn't over a fresh copy of tba so I manually went through and deleted the parts irrelevant to the corpse snippet. As it turns out it would have been quicker to start over haha.. .. .
..
.
That's what you get when you try and take short cuts :D
Please Log in or Create an account to join the conversation.