I had a lot of trouble getting portal to work (after a while I got a spell working, but I wanted an object also). This is how you can have both. (Modified Snippet) Here is what needs to be changed. In spells.c, ASPELL(do_gate) /* create the portal */ portal = read_object(PORTAL_OBJ, VIRTUAL); - GET_OBJ_VAL(portal, 0) = victim->in_room; + GET_OBJ_VAL(portal, 0) = world[victim->in_room].number; GET_OBJ_TIMER(portal) = (GET_LEVEL(ch) / 10); CREATE(new_descr, struct extra_descr_data, 1); new_descr->keyword = str_dup("portal gate gateway"); sprintf(buf, "You can barely make out %s.", world[victim->in_room].name); new_descr->description = str_dup(buf); new_descr->next = portal->ex_description; portal->ex_description = new_descr; obj_to_room(portal, ch->in_room); act("$n conjures a portal out of thin air.", TRUE, ch, 0, 0, TO_ROOM); tportal = read_object(PORTAL_OBJ, VIRTUAL); - GET_OBJ_VAL(tportal, 0) = ch->in_room; + GET_OBJ_VAL(tportal, 0) = world[ch->in_room].number; GET_OBJ_TIMER(tportal) = (int) (GET_LEVEL(ch) / 10); CREATE(new_tdescr, struct extra_descr_data, 1); new_tdescr->keyword = str_dup("portal gate gateway"); sprintf(buf, "You can barely make out %s.", world[ch->in_room].name); new_tdescr->description = str_dup(buf); new_tdescr->next = tportal->ex_description; Add a case for ITEM_PORTAL into the value menus (search for CASE_FOUNTAIN), and make it so that it records a room number. If you have problems on this or want clarification, contact me, and I will write a complete set of instructsions. -Bel +------------------------------------------------------------+ | Ensure that you have read the CircleMUD Mailing List FAQ: | | http://democracy.queensu.ca/~fletcher/Circle/list-faq.html | +------------------------------------------------------------+
This archive was generated by hypermail 2b30 : 12/15/00 PST