Re: [CODE] Objects

From: Mike Breuer (mbreuer@new.rr.com)
Date: 09/16/01


If it were me, I would probably make a custom item type for it, which is a
bit of work for a beginner.  Most of the handling is done in spell_parser.c,
mag_objectmagic().  I haven't looked, but you probably should check the ftp
site for similar code, if for no other reason than to get an idea of all of
the places you need to make modifications.

I suppose if you just want a hack to make it work, you could do something
like:

if (obj != NULL && GET_OBJ_VNUM(obj) == <vnum of your amulet>)
  extract_obj(obj);

as the last line of "case ITEM_WAND:" in the aformentioned function.  I
consider that rather ugly, though...use it at your own peril.

Mike

--
   +---------------------------------------------------------------+
   | 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/06/01 PST