Aller au contenu

Photo

DC for spells cast from items


  • Veuillez vous connecter pour répondre
4 réponses à ce sujet

#1
Terrorble

Terrorble
  • Members
  • 194 messages
How are DCs calculated for spells cast from items?  scroll, wand, staff,...  Or, where does GetSpellSaveDC() pull that information from?

I cast my lightning bolt from a staff and it says the DC is 16.  It doesn't account for focus feats or caster ability score, levels, item level, etc.

Before I manually edit the spell scripts to make my own DCs, I thought I'd see about using what is already there.

#2
FunkySwerve

FunkySwerve
  • Members
  • 1 308 messages
You have to manually edit the scripts. The simplest way is to do a mass find/replace on all scripts, or, if you want to spend more time, all spellcripts, and inject an #include line for your own custom include. This, by itself, is relatively simple with a text editor worth its salt, but it's still time-consuming.

From there, you can then write your own custom functions, and determine dc however you like. If you need more to go on, I can post our custom spells include, in which we set up a spell info struct which we run before every spell, to collect data. And yes, doing that meant rewriting every spellscript. You might find a simpler way via the unofficial 'patch', but I'm not sure, not having used it.

Funky

#3
Squatting Monk

Squatting Monk
  • Members
  • 446 messages
GetSpellSaveDC()'s formula is 10 + spell level + relevant ability modifier. It also adds modifiers from things like spell focus. I can't find any info on the various wikis as to whether it works any differently for spells cast by items.

#4
Shadooow

Shadooow
  • Members
  • 4 472 messages

FunkySwerve wrote...
. You might find a simpler way via the unofficial 'patch', but I'm not sure, not having used it.

Funky

yes, CP allows to override DC and caster level or any item to specific value. Also possible to add metamagic into the spell.

its explained in documentation, link in my signature

Modifié par ShaDoOoW, 27 janvier 2013 - 01:53 .


#5
Terrorble

Terrorble
  • Members
  • 194 messages
Thanks for the quick replies.
I downloaded the CP and am looking through that.

I've had my hands in most spells before, so if I have to take a couple hours and replace GetSpellSaveDC() with my own function when casting from an item, I might go that route.