Loading ...
Sorry, an error occurred while loading the content.

Re: Possible display bug with magical vestment spell

Expand Messages
  • chackenmueller
    ... as a ... spell as ... the ... for you ... reaches it ... When ... the ... I appreciate the advise but rather than use the hack you specified, I would
    Message 1 of 5 , Jul 27, 2006
    • 0 Attachment
      --- In pcgen@yahoogroups.com, Eddy Anthony <eddyba@...> wrote:
      >
      > On 7/27/06 11:37 AM, "chackenmueller" <chackenmueller@...> wrote:
      >
      > > I have a custom coded class that can use Magical Vestment spell
      as a
      > > first level spell. The spell sheet is displaying the output as a 0
      > > enhancement. I looked at the coding and it is using:
      > > DESC:Armor or shield gains (min(CASTERLEVEL/4,5)) enhancement
      > >
      > > This will normally work just fine for a cleric who gains the
      spell as
      > > a 3rd level spell because of rounding. The problem is at level 1,
      the
      > > 1/4 gives a value of 0.
      >
      > Not a bug since it correctly follows the rules, it's just a hurdle
      for you
      > since you're trying to append a house rule.
      >
      > > I'm not sure what funcation can be used to make that first portion
      > > have a minimum value of 1.
      >
      > Add this to the 1st level line
      >
      > BONUS:CASTERLEVEL|SPELL.Magical Vestment|4|PREVARLT:CL,4
      >
      > This should adjust the caster level to 4 until the PC actually
      reaches it
      > giving you a +1 through 8th level.
      >
      > > Also, when trying to add this spell as a temporary bonus, it lists
      > > the minimum caster level as 5th.
      >
      > As it should since it is coded for a 3rd level spell. But so what?
      When
      > adding it to a PC the caster level is not indicated anywhere, just
      the
      > effect. So just tell it 5th and it will apply the +1.
      > --
      > ~ Eddy Anthony (MoSaT)
      > ~ PCGen BoD, Data Content Second, Doc Chimp
      >

      I appreciate the advise but rather than use the hack you specified, I
      would prefer to .MOD the spell to change the DESC to something more
      inlie with the spell description without making any assumptions. How
      can I get that value to be a minimum of 1? Can I do something like:

      IF((min(CASTERLEVEL/4,5))<1,1,(min(CASTERLEVEL/4,5)))

      Will that work?
    • Tir Gwaith
      ... Dunno, didn t look at it hard. I know you went more complicated than you needed. Just need a max statement in there. DESC:Armor or shield gains
      Message 2 of 5 , Jul 27, 2006
      • 0 Attachment
        > I appreciate the advise but rather than use the hack you specified, I
        > would prefer to .MOD the spell to change the DESC to something more
        > inlie with the spell description without making any assumptions. How
        > can I get that value to be a minimum of 1? Can I do something like:
        >
        > IF((min(CASTERLEVEL/4,5))<1,1,(min(CASTERLEVEL/4,5)))
        >
        > Will that work?

        Dunno, didn't look at it hard. I know you went more complicated than
        you needed. Just need a max statement in there.

        DESC:Armor or shield gains (max(min(CASTERLEVEL/4,5),1)) enhancement

        I like to avoid IF statements whenever possible makes things nicer on
        my brain. :p I got told to avoid IF statements whenever possible back
        in my HS Comp. Sci. class. We got doc'd points on our grades for
        using an IF statement if we could code it another way. Not the ideal
        way for programming, since sometimes a well placed IF will take care
        things with the least amout of processor time, but it did get lazy
        teenagers to actually work on learning and using in later modules the
        complex CASE and other types of code. Side effect is someone like me
        who avoids them at almost any cost.

        --
        Tir Gwaith
        PCGen LST Chimp
      • Jay
        ... I have (min(5,ceil(CASTERLEVEL/4))) in my dataset, and it calculates properly when given as a 1st-level spell -- +1 at 1st- through 4th-level, +2 for 5th-
        Message 3 of 5 , Aug 1, 2006
        • 0 Attachment
          --- In pcgen@yahoogroups.com, "Tir Gwaith" <Tir.Gwaith@...> wrote:
          > Dunno, didn't look at it hard. I know you went more complicated than
          > you needed. Just need a max statement in there.
          >
          > DESC:Armor or shield gains (max(min(CASTERLEVEL/4,5),1)) enhancement

          I have (min(5,ceil(CASTERLEVEL/4))) in my dataset, and it calculates
          properly when given as a 1st-level spell -- +1 at 1st- through
          4th-level, +2 for 5th- through 8th-level, etc. I've had it that way for
          ages, since the Eberron campaign gives Magic Vestment to Artificers as
          a 1st-level infusion.
        Your message has been successfully submitted and would be delivered to recipients shortly.