On Fri, 9 Jan 1998, ;P wrote: > > As some, if not all of you, know that there is a mag-function called > > mag_ingredients or something. I've tried to add a spell in this function, > > but probably I must have put it in the wrong place. > > Where should I put a spell in mag_ingredients? > > > > There must be a switch(spellnum) somewhere, but where? > > Could anybody who have done this help me out and tell me where > > the switch should be placed... > > there isn't one inside the mag_materials..this is just a function that > checks to see if you have the stuff..you would put a call to that in > whatever the normal spell function is..what i mean is, if you are making > a heal spell that requires a rare herb, you'd copy the existing heal, and > put a check inside for the herb..like this: > > case SPELL_HEAL: > hit = 100; > send_to_char("A warm feeling floods your body.\r\n", victim); > break; > > case SPELL_HERB_HEAL: > if (mag_materials(ch, 2104, -1, -1)) > hit = 100; > else return 0; > break; > > this is psuedo-code, but it should give you the idea.. > > > siv Yeah. It works real great :) Thanks. This really makes my Druids more realistic with reagents and other stuff. /Avatar +------------------------------------------------------------+ | 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