From: Herious This is a short snippet to allow players to mine jewels to sell in a store or else use for something else. My intention with this snippet is to eventaully add the ability to make wepaons from things mined. It requires the addition of an item (ITEM_PICK), and a room flag (ROOM_MINE). the snippet is fairly easy so I dont require any credit for it. My philosphy on that is how would I know that you actually used my snippet anyhow and if you credited everyone that helped you with your mud then your credits file would look like a movie credits. ;) So without further wait: ACMD(do_mine) { struct obj_data *pick; struct obj_data *jewel; int percent, j_num; if (!(pick = GET_EQ(ch, WEAR_HOLD)) || (GET_OBJ_TYPE(pick) != ITEM_PICK)) { send_to_char(ch, "You need to be holding a mining pick first.\r\n"); return; } if (ROOM_FLAGGED(ch->in_room, ROOM_MINE)) { percent = rand_number(1, 10); if (percent <= 5) { /* 50% chance */ send_to_char(ch, "You dig and dig and seem get nowhere.\r\n"); return; } j_num = rand_number(1250, 1260); /* my vnums for the objs mined */ jewel = read_object(j_num, VIRTUAL); send_to_char(ch, "You dig up a %s.\r\n", jewel->short_description); act("$n digs up what looks like a $p!\r\n", FALSE, ch, jewel, 0, TO_ROOM); obj_to_char(jewel, ch); return; } else { send_to_char(ch, "This really isn't a good place to start mining.\r\n"); return; } }