Re: Iedit and OasisOLC bugs.

From: Erwin (Mystikarc@softhome.net)
Date: 01/18/01


> > (http://post.queensu.ca/cgi-bin/listserv/wa?A2=ind0007&L=circle&P=R11650)
> > might be helpful....

  I looked at that link, and followed some advice, beyond me I can't figure out
the problem. Il follow some advice, but I will post the code to see if anyone
sees any difference (or updateS do the olc for bpl17?) that I may have missed.

-----------------------
/* this is all iedit stuff */
void iedit_setup_existing(struct descriptor_data *d,
  struct obj_data *real_num) {
  struct obj_data *obj=NULL;

  OLC_IEDIT(d) = real_num;
  CREATE(obj, struct obj_data, 1);
  clear_object(obj);
  copy_object(obj,real_num);

  OLC_OBJ(d) = obj;
  OLC_IEDIT(d) = real_num;
  OLC_VAL(d) = 0;
  oedit_disp_menu(d);
}


ACMD(do_iedit) {
  struct obj_data *k;
  int found=0;
  int tmp;
  extern struct room_data *world;

  one_argument(argument, arg);

  if(!*arg || !*argument) {
    send_to_char("You must supply an object name.\r\n",ch);
  }

  if ((k = get_object_in_equip_vis(ch, arg, ch->equipment, &tmp))) {
    found=1;
  } else if ((k = get_obj_in_list_vis(ch, arg, ch->carrying))) {
    found=1;
  } else if ((k = get_obj_in_list_vis(ch, arg,
        world[ch->in_room].contents))) {
    found =1;
  } else if ((k = get_obj_vis(ch, arg))) {
    found=1;
  }

  if (!found) {
    send_to_char("Couldn't find that object. Sorry.\r\n",ch);
    return;
  }

                /* set up here */
  CREATE(OLC(ch->desc), struct oasis_olc_data, 1);
  SET_BIT(GET_OBJ_EXTRA(k), ITEM_UNIQUE_SAVE);

  SET_BIT(PLR_FLAGS(ch), PLR_WRITING);
  iedit_setup_existing(ch->desc,k);
  OLC_VAL(ch->desc) = 0;

  act("$n starts using OLC.", TRUE, ch, 0, 0, TO_ROOM);

  STATE(ch->desc) = CON_IEDIT;

  return;
}
-----------------------

--
   +---------------------------------------------------------------+
   | FAQ: http://qsilver.queensu.ca/~fletchra/Circle/list-faq.html |
   | Archives: http://post.queensu.ca/listserv/wwwarch/circle.html |
   +---------------------------------------------------------------+



This archive was generated by hypermail 2b30 : 12/03/01 PST