Forcing alignment for the Planar Ally spells

Is there a way to force alignment with regards to the Summon Planar Ally family of spells?

A book of dark knowledge from the lower planes that allows for summoning kinda loses its moral ambiguity if the players can use it to summon various celestial allies so I am wondering if there is a way to force the evil result in particular.

have seen that sort of thing handled in spellscripts. Get the aln of the caster and pass a fitting resref to the summon function

you might want to add a Spells.2da entry for what yer doing idk

Thanks Kevl. I will poke at it and see what I can come up with.

1 Like

You’ve probly found this by now, but for the curious:

- in ‘x0_s0_planar’ (spellscript for PlanarAlly, Spells.2da #451)

    switch (GetAlignmentGoodEvil(OBJECT_SELF))
        case ALIGNMENT_EVIL:
            eSummon = EffectSummonCreature("c_summ_succubus",VFX_HIT_SPELL_SUMMON_CREATURE, fDelay);
        case ALIGNMENT_GOOD:
            eSummon = EffectSummonCreature("c_celestialbear", VFX_HIT_SPELL_SUMMON_CREATURE, fDelay);
            eSummon = EffectSummonCreature("c_summ_sylph",VFX_HIT_SPELL_SUMMON_CREATURE, 1.0);
    ApplyEffectAtLocation(DURATION_TYPE_TEMPORARY, eSummon, GetSpellTargetLocation(), fDuration);
1 Like