On Fri, 22 Nov 1996, Guilbault, Brian wrote: > >Here is my problem, I don't care if they sac a corpse, but i would like > >to stop them from sacrificing a container of any type if it has something > >in it, and i cant seem to find a clear example of this anywhere. > >(tried to muddle through do put and do get and ended up in convulsions, > >need a little more practice for those) If some one could point me to a > >more clear example, or tell me what little thing I am missing, I would be > >most appreciative. > > Someone correct me if I'm wrong, but couldn't you just do something like > this, assuming the object you are trying to sacrifice is "obj": > > if (GET_OBJ_TYPE == ITEM_CONTAINER && obj->contains) { > send_to_char("You can't junk a full container.\r\n", ch); > return; > } > > I think that will work for you. Not really. He wants them to be able to sacrafice a corpse but not a container item (bag, etc.) So, the logical answer is to check if it's a corpse. A corpse is a container with v4 set to 1 (I think I am right here, but you can check fight.c in make_corpse()). -- Daniel Koepke dkoepke@california.com Forgive me father, for I am sin. +-----------------------------------------------------------+ | Ensure that you have read the CircleMUD Mailing List FAQ: | | http://cspo.queensu.ca/~fletcher/Circle/list_faq.html | +-----------------------------------------------------------+
This archive was generated by hypermail 2b30 : 12/18/00 PST