Re: [NEWBIE] Case Values

From: Shane Augustine (
Date: 02/23/99

I think I know what you're talking about.  There's a couple of remort
around that can help you with this.  I think I saw one at

I'm guessing to add extra fields to the player struct like chclass2 and
but you'll have to make checks for both of these everytime you make a check
the 'original' class.  Then you can use nested case statements.  I.E.

switch(class) {
    switch(class2) {
        case CLASS_MAGE:
        switch(class3) {
            case CLASS_CLERIC:
            return a; // Player is a warrior/mage/cleric combo
Of course this could get confusing.  You'd also have to be careful that the
doesn't matter.  I.e. warrior/cleric/thief or thief/warrior/cleric would
return same
value.  I hope that helps.

Kaine LaZaro wrote:

> I'm trying to change how everything in the switch statement works, I'd
> like to be able to use multi-character values ie war mag cle and thi etc
> (I have 34 classes I'll not go on.)
> James aka Kaine
> `Up, Down, Over, and Through, Back arround the Jokes on you!'
>  -- Magic the Gathering
>      +------------------------------------------------------------+
>      | Ensure that you have read the CircleMUD Mailing List FAQ:  |
>      |  |
>      +------------------------------------------------------------+

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

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