Hmmm... Off the top of my head I would consider using a bitvector to store the spell "groups". GROUP_FIRE, GROUP_COLD, etc. The problem is that you are limited in the number of groups. The good thing is that you could add an entry into the spello that says what group a spell belongs to and us that in an if(IS_SET(bitvector,GROUP_FIRE)) when displaying. OR! you could set up each group as a skill, added an item to the spello that says that the line is a a member of GROUP_BLAH or is a group ID line and then key off of that. When looking up fireball for example, it has GROUP_FIRE in this slot. Look at GET_SKILL(ch,GROUP_FIRE) to see if the char has this group. I like the second option better, it is a bit slower, but is MUCH more expandable. --Angus Nick Stout <cyberman_64@HOTMAIL.COM> on 01/02/99 08:48:41 PM By some odd chance, has anyone revamped the spell and skill system so it allows spells to be learned by practice, but also to be gained in groups? Like for instance... A Warrior starts out with kick, and the usual things. But if he wants magic, he can get another group by "gaining" it, and it raises his exp_to_level. So he gains "Firespells", and he then has fireball, flamebolt, and flamestrike all unpracticed. He can then practice these. Has anyone done this? And if so, would you be willing to share an example of how this was accomplished? I was going to put it under spello() as int group, but i'm not sure if i should put it there, and what good it would really do anyway. If you've done this, i would really appretiate an e-mail to me about how you did this, and how much is involved. Thanks in advance. -CyberMan +------------------------------------------------------------+ | Ensure that you have read the CircleMUD Mailing List FAQ: | | http://qsilver.queensu.ca/~fletchra/Circle/list-faq.html | +------------------------------------------------------------+
This archive was generated by hypermail 2b30 : 12/15/00 PST