Re: [CODE] Multiple applies on skills?

From: Sean Holt-Carden (mordist@home.com)
Date: 10/23/00


Uhm, I think ya need to do something more along these lines :

struct affected_type af, af2;

// First, zero out the Affs :
af.type = 0;
af.location = APPLY_NONE;
af.bitvector = 0;
af.modifier = 0;
af.duration = 0;

af2.type = 0;
af2.location = APPLY_NONE;
af2.bitvector = 0;
af2.modifier = 0;
af2.duration = 0;

// Then later where it was before :
af.type = SKILL_RAGE;
af.location = APPLY_DAMROLL;
af.bitvector = 0;
af.modifier = GET_LEVEL(ch) / 3;
af.duration = GET_LEVEL(ch) / 2;

af2.type = SKILL_RAGE;
af2.location = APPLY_AC;
af2.bitvector = 0;
af2.modifier = 50;
af2.duration = GET_LEVEL(ch) / 2;

// Then when all is said and done :
add af2 to a new affect_join (maybe modify) can't remember exactly off hand)
that was called with af.

Hope this helps somewhat and you can understand it ;)

Sean

Kron wrote:

> Hi again,
>   I'm running circlemud 30 bpl14 and I'm having a hard time getting multiple applies on skills. I have a skill that I want to affect damroll and armor class. Right now it looks like this:
>
>     af.type = SKILL_RAGE;
>     af.location = APPLY_DAMROLL;
>     af.location = APPLY_AC;
>     af.bitvector[0] = 0;
>     af.bitvector[1] = 0;
>     af.bitvector[2] = 0;
>     af.bitvector[3] = 0;
>     af.modifier = GET_LEVEL(ch)/3;
>     af.modifier = +50;
>     af.duration = GET_LEVEL(ch)/2;
>
> And only the +50 gets added to the armor class. Any ideas on what I need to do to make both applies work?
> Thanks,
> Kronakus
>
>      +------------------------------------------------------------+
>      | Ensure that you have read the CircleMUD Mailing List FAQ:  |
>      |  http://qsilver.queensu.ca/~fletchra/Circle/list-faq.html  |
>      +------------------------------------------------------------+


     +------------------------------------------------------------+
     | 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 : 04/10/01 PDT