Function:
This script is intended as a flexible extension-mod for magicka calculation for scripted/automatized spellcasting.
It is of use if you want to cast spells by a script using the commands below since they don't include the calcualtion of magicka costs:
- Cast or Remotecast
- DoCombatApplySpell
(- Maybe ApplySpell)
(- Since AI-Packages (no longer) consider magicka costs it might be of help there as well)
Formula to gain the absolute "Magicka Costs":
Spoiler
It basically calculates (precisly!) the absolut magicka costs based on this formula:
spell cost = base cost * skill multiplier * perk multiplier * equipment multiplier * dual cast multiplier
(http://www.uesp.net/wiki/Skyrim:Magic_Overview#Spell_Cost)
It basically calculates (precisly!) the absolut magicka costs based on this formula:
spell cost = base cost * skill multiplier * perk multiplier * equipment multiplier * dual cast multiplier
(http://www.uesp.net/wiki/Skyrim:Magic_Overview#Spell_Cost)
Detection happens for now by just equipping the spell in either hands. The corresponding spellcosts are directly calculated and transfered to the global variable.
An additonal advantage of this script is (if you stick to the basic effects for damaging your magicka which were defined in the CK by Bethesda) you can inlcude in your scripted casts not just the magicka costs of all vanilla spells but also your manually defined ones (assumingly ALL MANUALLY CREATED).
Using the script as a modder:
The input of spells which should be taken into account is done via a FormList, the Output (= the absolut spellcosts of the equipped spell) for each seperate hand, is stored in a Globalvariable. As such adding new spells is a matter of a few minutes and doesnt need scripting at all.
Fetching the absolute spellcosts is done by just reading out the globalvariable for the specific hand in which the spell is equipped.
What you can expect in the near future:
Well, a first release

I will extend it to the point at which you can calculate the absolute magicka costs of a specific spell by writing an explicit identifier to a Globalvariable so you dont need to equip the spell.
As a sidekick you can also expect that manually defined perks with an impact on the perk-multiplier can be defined and used similar to manually defined spells. Sadly this will be limited to runtime-static-conditional perks since I dont see a possibility to include perks like "mag red if you have exclusivly this weapon equipped or that bug crawling up your back" without additionally scripting.
The script is already finished but has some fragements of my own first attempt of a perk-mod inside and thus needs to be cleaned and a few minor tweaks have to be applied. As such the mod is not yet released but will be within the next days after I did all the formal stuff .
(setup a page, do the last adjustments, presenting a video showing the possibilities and so on).
I will release the mod exclusivly on Nexus.
Dont forget:
THIS IS A WIP AND DUE TO A LACK OF EXTENSIVE TESTING STILL A BETA!
......if bethesda now releases commands with this function I will shoot them.
