> I was thinking.. maybe we could make all the skills run thru the > same command, much like the 'cast' spell. > > A skill entry could look like this: (in the command list) > > { "bash", POS_FIGHTING, do_skill, 0, SKILL_BASH }, I do the same thing, only on a much greater scale. Basically, I tore out do_cast, got rid of all the skills, and wrote a new function called parse_skill, which happens BEFORE any parsing occurs on the main command list. I got rid of the spell structure, since I figured it was a little bloated and made a new skill structure, of which all spells use. I use one variable for parsing targets and routines, and other stuff like violent. Then I made this information for each skill read in from a file (a different file for each skill) on bootup via an index file. Then get rid of the char *spells[] array since it's no longer needed and modify all relevant functions that use it. It's a lot faster, more efficient, and saves a lot of time when adding skills. Just make all skills use the relevant mag_ functions, since they will work for skills just fine. And lastly, I then made an OLC so that I could edit and create skills on-line. Only entry to code needed is the skill define and the relevant entry in whatever mag_function you need. I know I didn't say much specific, but if you know what you're doing, you should be able to code off of what little I've said :) Rasdan p.s. It's quite an undertaking, I wouldn't recommend it for just anyone to try unless you are VERY familiar with Circle code. =--=--=--=--=--=--=--=--=--=--= I have done so much, with so little, James C. Thomas Jr. for so long, Rasdan That I can do anything Head Coder of Finality! with nothing. =--=--=--=--=--=--=--=--=--=--= Finality is based upon CircleMUD 3.0, check us out: finality.mudservices.com 5555 +------------------------------------------------------------+ | 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/08/00 PST