doneif (isgizmo <> 0)
this actually breaks the entire script. It always seems to make it fail. EDIT: changed the spell string that we're using for the top foreach loop to spell = "thingid." & id&" & Helper.CustomItem" |
Easy Metamagic eval
So popping in the tag on the Metamagic feat and testing it out worked. As usual I put my timing in Final with a huge number.
First - Grab the metamagic feat chosen Second - Grab customized spells Third - Grab customized spell's level Fourth - Grab the original spell's level Fifth- Is our metamagic feat there? ->increment level reduction sixth - overhead. var Lvl as number var LvlRed as number var MMg as string var nlvl as number var BLvl as number doneif (field[fChosen].ischosen = 0) MMg = field[fChosen].chosen.field[mmAbbr].text foreach pick in hero where "NeedHelper.CustomSpl" ~Grab current level of the customized spell Lvl = eachpick.field[sLevel].value LvlRed=0 ~Need the level of the base spell; I anticipate that this foreach ~will only find one thing. foreach pick in eachpick.gizmo from BaseSpell BLvl=eachpick.field[sLevel].value nexteach ~Look for the metamagic chosen within the gizmos foreach pick in eachpick.gizmo from BaseMetamg if (compare(eachpick.field[mmAbbr].text,MMg) = 0) then LvlRed += 1 endif nexteach nlvl=maximum(Lvl-LvlRed,BLvl) perform eachpick.delete[sLevel.?] ~Set the field. eachpick.field[sLevel].value=nlvl ~Set the correct tag if (eachpick.field[sLevel].value = 0) then perform eachpick.assign[sLevel.0] elseif (eachpick.field[sLevel].value = 1) then perform eachpick.assign[sLevel.1] elseif (eachpick.field[sLevel].value = 2) then perform eachpick.assign[sLevel.2] elseif (eachpick.field[sLevel].value = 3) then perform eachpick.assign[sLevel.3] elseif (eachpick.field[sLevel].value = 4) then perform eachpick.assign[sLevel.4] elseif (eachpick.field[sLevel].value = 5) then perform eachpick.assign[sLevel.5] elseif (eachpick.field[sLevel].value = 6) then perform eachpick.assign[sLevel.6] elseif (eachpick.field[sLevel].value = 7) then perform eachpick.assign[sLevel.7] elseif (eachpick.field[sLevel].value = 8) then perform eachpick.assign[sLevel.8] else perform eachpick.assign[sLevel.9] endif nexteach |
Quote:
And thanks for the Easy Metamagic script. Looks good. |
The timing has to be adjusted to get all the levels to change correctly:
Pre-levels 5000 works Oh and the custom metamagic items are throwing: Live state of gizmo 'CustSpell' is being tested before live state of parent pick 'sCustomSpl' is resolved |
Quote:
|
I did:
Final Phase 30000 if (hero.pickexists[fRepeatSpl] <>0) then perform assign[User.EasyMM] endif and added the User Tags via the gui button and made sure to replace the stock metamagic item... it is working for me, except for the error. |
Quote:
Note: I am seeing the error now. Update: Reload the code (ctrl-r) and the error goes away. |
Hey Sendric, we just kicked those feats' ass.
|
Quote:
|
You guys just might have solved my years-old quandary about how to code the Forgotten Realms PrC Incantatrix' capstone power, which I had tried to script years ago but was told then that it probably couldn't be done without shenanigans such as rescripting the entire metamagic feats.
Kudos for that! Please try to craft your system so that said PrC could use it as well. Thanks. *the power in question reduces the cost of all metamagic used by the character by 1 level, without bringing it lower than 1 |
All times are GMT -8. The time now is 03:12 PM. |
Powered by vBulletin® - Copyright ©2000 - 2024, vBulletin Solutions, Inc.
wolflair.com copyright ©1998-2016 Lone Wolf Development, Inc. View our Privacy Policy here.