Re: [Circle] Adding Spells

From: Rasdan (thomas@mail.CS.ORST.EDU)
Date: 11/12/96

On Tue, 12 Nov 1996, CircleMud Admin wrote:

> I'm trying to figure out how to add spells. I know I need to add things to
> the spells.c spells.h and spell_parser.c files, but they're a little
> difficult to figure out. I even looked through the Code snippets page
> looking at about where I'd have to add things, but no luck. Is there
> anything like the class.doc file for adding spells to the bpl11?
> 				-Mike

I just recently began my FIRST coding attempt and figured out how to code

To make the spells (offensive, defensive, or modify object), you need to
code that in magic.c. spells.c is only for manual spells such as create
food, etc.

You also need to go into constants.c to add the spell-wear off messages or
you'll get some strange output when spells wear off.

All you need to do in spells.h is define the spell, so:
     #define SPELL_PULSE                   <spell number here>

In spell_parser.c, you need to put in the spell name (located near the top
of the file) and then you need to put in the spello().  All I did here (at
first) was look at the format for the others and duplicate it, changing
the spell name.

And then in class.c, you need to assign the new spells to a particular
class (This is done about half-way through the file).

Doing all this, I have successfully added 28 new spells, and I didn't even
know what I was doing, I just looked through the code until I figured it
out! :)

Anyway, I hope that this helps you.


| Ensure that you have read the CircleMUD Mailing List FAQ: |
|   |

This archive was generated by hypermail 2b30 : 12/18/00 PST