Re: QUESTION: Races & Perm Attributes

From: (pure@SPRINT.COM.AU)
Date: 07/09/97


There has been a thread on this before, so you can check the archives.

What i did was the long way. I did it so that i created a new slot and
called it innate.
I then had #defines RACE_INFRAVISION <num>, #define RACE_FLY <num +1>,
etc etc

i then added these into my class.c file when i do skills and spells. I
do a switch statement on the race, and then setup a few things, like
innates, height, weight, etc. I setbit (RACE_INFRA) and is_affected
(INFRA). In my spells.c (I think? ? was a while ago), i do a check to
make sure that if they cast on a char which has the innate something
like that, then it does a check for RACE_INFRA or whatever the spell
is, and if true, it doesn't update or do something like that. The
reason i did this, was because i list the racial innates somewhere,
and it was easier to do it this way. I could have had it check the
spell and THEN check to see if it was an innate, but this means
whenever the player want's to check their innates, it would have to do
the racial switch statement. My way it only does the switch once (char
creation time). But the downside is there is another long slot.

Jussy


      +-----------------------------------------------------------+
      | 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/08/00 PST