Wrathgon's rewrite of Plothos' Spell Manager

These are tools and utilities that make it easier to run games. This includes Lib: macro tokens dropped into MapTool to manage the game, a conversion file for CharacterTool to allow use in MapTool, or just about anything else you can think of -- except graphics with macros and anything specific to a particular campaign framework. Those are already covered by the Tilesets subforum and the Links and External Resources forum.

Moderators: dorpond, trevor, Azhrei, giliath, Gamerdude, jay, Mr.Ice

User avatar
aliasmask
RPTools Team
Posts: 9024
Joined: Tue Nov 10, 2009 6:11 pm
Location: Bay Area

Re: Wrathgon's rewrite of Plothos' Spell Manager

Post by aliasmask »

As for feats, I tried using spell penetration and greater spell penetration, but it only counted the spell penetration. I removed spell penetration and the greater works correctly now.

User avatar
aliasmask
RPTools Team
Posts: 9024
Joined: Tue Nov 10, 2009 6:11 pm
Location: Bay Area

Re: Wrathgon's rewrite of Plothos' Spell Manager

Post by aliasmask »

Here's another fix. In "Casted Spell Warp" there are 2 needed changes. First add totalRoll = 0 at the top and then change Area != "0" to areacheck. Here's the full macro in RPedit Notepad++ format. The first 2 lines and last line should be deleted if using normal cut/paste.
||| Casted Spell Warp |||

Code: Select all

@@ @Casted Spell Warp
@PROPS@ fontColor=black;autoExecute=true;fontSize=1.00em;sortBy=;color=cyan;playerEditable=true;applyToSelected=false;group=6 Casting;tooltip=;minWidth=
[h:passed=macro.args]

[h:classviewed=listGet(passed,0)]
[h:spelllevel=listGet(passed,1)]
[h:prep=listGet(passed,2)]
[h:spellname=listGet(passed,3)]
[h:spellcastname=listGet(passed,4)]
[h:SLA=listGet(passed,5)]

[h:tFeatlist=getProperty("PCFeats")]
[h:EH=getLibProperty("EH")]

[h:EH=getLibProperty("EH","Lib:Magic")]
[h:PF=""]
[h, if(EH==3):PF="PF"]
[h:Amod="None"]
[h:incr="None"]
[h:SR=""]
[h:modlist=""]
[h:SRcheck=0)]
[h:school=""]
[h:areacheck=0]
[H:tselect=""]
[H:output=""]
[h:target=""]
[h:spelltargets=""]
[h:spellrange=-1]
[h:SRPBonus=0]
[h:energy=""]
[h:targetlist=""]
[h:save=""]
[h:lvlup=0]
[h:max=0]
[h: DiceRolls=""]
[h: fulltemplate=""]
[h:adding=0]
[h:tnum=0]
[h:show=0]
[H: totalRoll = 0]
[h:Attack="None"]
[macro("Get Object@Lib:Magic"):classviewed]
[h:Type=macro.return]
[h:ClassInfo=getProperty("CasterInfo")]
[h:prepslot=json.contains(Type, "prepSPD")]
[h:control=json.get(Type,"control")]
[h:SPDleft=json.get(Type,"SPDleft")]
[h:check=json.get(SPDleft,spelllevel)]
[h:CL=json.get(Type,"CasterLvl")]
	
[h, if (prep==0  && SLA !="1" || prepslot==1 && SLA !="1" ), CODE:{
	[h,if (check>=1), CODE:{
		[SPDleft=json.set(SPDleft,spelllevel,check-1)][h:show=1]};{
		[input("tjunk|No more slots left of this level, sorry you cant cast this|Out of Spell Slots|LABEL|")]
	}]
	[h, if (EH !=3 || EH==3 && spelllevel>0):Type=json.set(Type,"SPDleft",SPDleft)]
	
};{}]

[h, if (prep>0 && prepslot==0&& SLA !="1" ), CODE:{
	[h: prepared=json.get(Type,"prepared")]
	[h: oldlist=json.get(prepared,spelllevel)]
	[h,if(string(oldlist)==""):oldlist="[]"]
	[h:check=json.contains(oldlist,spellname)]
	[h,if(check==1 && spelllevel>0):oldlist=json.remove(oldlist,json.indexOf(oldlist,spellname))]
	[h:oldlist=json.sort(oldlist)]
	[h: prepared=json.set(prepared,spelllevel,oldlist)]
	[h: Type=json.set(Type,"prepared",prepared)]
	[h:show=1]
};{}]

[h, if (SLA=="1"):show=1]
[h:spellcastname=lower(replace(spellcastname,"-[BSD]",""))]
[h: spellinfo=getLibProperty("SpellCastingInfo"+PF)]

[h, if (json.contains(spellinfo,spellcastname)==1 || tnum==1), CODE:{
	[h:spell=json.get(spellinfo,spellcastname)]
	[h,if (json.contains(spell,"Dice")==1):dice=json.get(spell,"Dice")]
	[h,if (json.contains(spell,"Increase")==1):incr=json.get(spell,"Increase")]
	[h,if (json.contains(spell,"Maxdmg")==1):max=json.get(spell,"Maxdmg")]
	[h,if (json.contains(spell,"Energy")==1):energy=json.get(spell,"Energy")]
	[h,if (json.contains(spell,"Effect")==1):Effect=json.get(spell,"Effect")]
	[h,if (json.contains(spell,"Attack")==1):Attack=json.get(spell,"Attack")]
	[h,if (json.contains(spell,"ActiveMod")==1):Amod=json.get(spell,"ActiveMod")]
	[h:areacheck=json.contains(spell,"Area")]
	[h,if (areacheck==1):Area=json.get(spell,"Area")]
	[h,if (json.contains(spell,"Lvlup")==1):lvlup=json.get(spell,"Lvlup")]
	[h, if (lvlup==0):spellcast=0;spellcast=floor(CL/lvlup)]
	[h, if (spellcast>max && max !=0):spellcast=max]
	[h,if (json.contains(spell,"Range")==1):spellrange=lower(json.get(spell,"Range"));spellrange=0]
	[h:school=lower(json.get(spell,"School"))]
	[h,if (json.contains(spell,"Target")==1):target=json.get(spell,"Target")]
	[h,if (json.contains(spell,"Template")==1):fulltemplate=json.get(spell,"Template")]
	[h,if (json.contains(spell,"Subschool")==1):Subschool=json.get(spell,"Subschool")]
	[h,if (json.contains(spell,"Template")==1):Template=json.get(spell,"Template")]
	[h,if (json.contains(spell,"Duration")==1):Duration=json.get(spell,"Duration")]
	[h,if (json.contains(spell,"Spell Resistance")==1):SR=lower(json.get(spell,"Spell Resistance"));SR=0]
	[h:save=json.get(spell,"Saving Throw")]
	[h, if (endsWith(spellrange,"ft.")==1):spellrange=number(lower(replace(spellrange,"ft.","")))]
	[h,switch(spellrange):
		case "medium": spellrange=20+(2*CL);
		case "close": spellrange=5+(floor(2/CL));
		case "long": spellrange=80+(8*CL);
		case "touch": spellrange=2;
		case "personal": spellrange=0;
		default:spellrange=floor(spellrange/5)]

	[H: totalRoll = 0 ]
	[h, if (EH==1), CODE:{
		[h:Rarity=json.get(spell,"Rarity")]
		[h:Difficulty=json.get(spell,"Difficulty")]
	};{}]
	
	[h, if (isNumber(incr)==1), CODE:{
		[h:totalRoll=eval(dice)+(spellcast*incr)]
		[H: ToolTipOutput = dice+"+"+spellcast*incr ]
	};{	[macro("diceRollReport@Lib:magic"):(spellcast-1)+","+incr ]
		[h, if(incr!="None"):diceRollArray=json.toList(macro.return);diceRollArray=""]
		[h, if(incr!="None"):diceRollArray=listAppend(diceRollArray,eval(dice))]
		[H, FOREACH( i, diceRollArray ): totalRoll =totalRoll+ i  ]
		[h, if(incr!="None"):DiceRolls = diceRollArray;DiceRolls="" ] 
	}]	
	[h:output=strformat("<BR>The spell does %d  of %s.<BR>",totalRoll,energy)]	
};{}]

[h:rangeobj=json.set("{}","upto",spellrange,"distancePerCell",0)]
[h:cond = json.set("{}",  "range", rangeobj,"visible",1)]
[h, if (spellrange==0):spelltargets=token.name; targetlist=getTokenNames(",",cond)]

[h, if (areacheck), CODE:{
	[while (tselect!="None"), CODE:{
		[H: success = input("tselect|None," + targetlist + "|Choose targets of spell. Choose None when finish|LIST|value=string select=1")]	[h:abort(success)]	
		[h: remove=listFind(targetlist,tselect)]
		[h: targetlist=listDelete(targetlist,remove)]
		[h,if (tselect!="None"):spelltargets=listAppend(spelltargets,tselect)]
	}]
	[h:tempenergy=replace(energy, "energy type.","")]

	[h, if (fulltemplate!=""),CODE:{
		[MACRO("TemplateInfo@Lib:cifTemplates"):token.name+","+fulltemplate+"," +spellcastname+","+spellrange+","+Area]
	};{}]
};{
	[h, if (spellrange!=0),CODE:{
		[h: success = input("tselect|None," + targetlist + "|Choose target of spell. Choose None when finish|LIST|value=string select=1")][h:abort(success)]
		[h,if (tselect!="None"):spelltargets=listAppend(spelltargets,tselect)]
		};{}]
	[h, if (spellrange==-1):spelltargets="Info not in Database"]
}]

[h, if(energy=="Healing energy type."):HPType=0;HPType=1]

[h:StatBonus=floor((eval(control)-10)/2)]
[h, if (json.contains(tFeatlist,"combat casting")==1):bonus=4;bonus=0]
[h, if (json.contains(tFeatlist,"spell focus("+school+")")==1):DCbonus=1;DCbonus=0]
[h, if (json.contains(tFeatlist,"greater spell focus("+school+")")==1):DCbonus=2]
[h, if (json.contains(tFeatlist,"greater spell penetration")==1):SRPBonus=4]
[h, if (json.contains(tFeatlist,"spell penetration")==1):SRPBonus=2]
[h:DC=15 + number(spelllevel)+DCbonus+StatBonus]
[h:SaveDC=10+number(spelllevel)+StatBonus]
[h:SRcheck=startsWith(SR,"no")]
[h, if (SRcheck==0):SRcheck=startsWith(SR,"No")]

[h, if (save!="none" || save !="None"):save= save+" Save DC:<B> "+SaveDC+"</b>";save=" Save: None"]
[H, IF(isFunctionDefined("searchSpellLink")), code: { [H: spellNameLink = searchSpellLink(spellcastname)] };{[spellNameLink = spellcastname]}]

[r, if (show==1), CODE:{

	[r: macroLink("Click on token then click here to apply spell effects!<BR> ", "HPChange@Lib:libDnD35Pathfinder", "gm-self","Page=Main" + ";HPType="+HPType+";HPAmount="+totalRoll+ 
";DoInput=0","selected")] 

	[r: token.name+" casts <B>"+spellNameLink+"</b><BR> Spellcraft DC to ID:<B> "+DC+"</B> "+save+"</B><BR>Targets: <B> "+spelltargets+"</b>"]
	[r, if ( SRcheck==0), CODE:{
		[r:"<BR> Spell Resistance roll: "]
		[T:1d20+CL+SRPBonus]
	};{
		[r:"<BR> Spell Resistance roll: None "]
	}]

	[r, if (EH==3), CODE:{
		[r:"<BR> Concentration roll: "]
		[T:1d20+CL+bonus+StatBonus]
	};{}]

	[r,if(incr !="None" && EH==3), CODE:{
		[T(output): DiceRolls ]
	};{}]	
	[r:"Spell Failure Roll: "]
	[T:1d100]<BR>	
	[r, if (Attack!="None"), CODE:{
		[MACRO("Attack@Lib:libDnD35Pathfinder"): "" ]
	};{}]

};{}]
[h: ClassInfo=json.set(ClassInfo,classviewed,Type)]
[h: setProperty("CasterInfo",ClassInfo)]

[macro("Spell Cast@Lib:Magic"):classviewed+","+spelllevel+","+prep]

!!
Errors fixed:
Invalid condition in IF(Area !="0") roll option.       Statement options (if any): h, if (Area !="0"), CODE       Statement Body (first 200 characters): { [while (tselect!="None"), CODE:{ [H: success = input("tselect|None," + targetlist + "|Choose targets of spell. Choose None when finish|LIST|value=string select=1")] [h:abort(success)] [h: rem
and
Unresolved value "Totalroll".

neofax
Great Wyrm
Posts: 1694
Joined: Tue May 26, 2009 8:51 pm
Location: Philadelphia, PA
Contact:

Re: Wrathgon's rewrite of Plothos' Spell Manager

Post by neofax »

I am having a problem getting all spells to show for the Witch class. Here is the Spells JSON:

Code: Select all

"Witch":[10, ["Bleed","Dancing Lights","Daze","Detect Magic","Detect Poison","Guidance","Light","Mending","Message","Putrefy Food and Drink","Read Magic","Resistance","Spark","Stabilize","Touch of Fatigue"], ["Beguiling Gift","Burning Hands","Cause Fear","Charm Person","Chill Touch","Command","Comprehend Languages","Cure Light Wounds","Dancing Lantern","Detect Secret Doors","Enlarge Person","Hypnotism","Identify","Ill Omen","Infernal Healing","Inflict Light Wounds","Mage Armor","Mask Dweomer","Mount","Obscuring Mist","Ray of Enfeeblement","Reduce Person","Sleep","Summon Monster I","Unbreakable Heart","Unseen Servant"], ["Alter Self","Augury","Blindness_Deafness","Burning Gaze","Cure Moderate Wounds","Daze Monster","Death Knell","Delay Poison","Detect Thoughts","Disfiguring Touch","Enthrall","False Life","Feast of Ashes","Fester","Find Traps","Fog Cloud","Gentle Repose","Glide","Glitterdust","Hidden Speech","Hold Person","Inflict Moderate Wounds","Levitate","Perceive Cues","Pox Pustules","Scare","See Invisibility","Spectral Hand","Status","Summon Monster II","Summon Swarm","Touch of Idiocy","Vomit Swarm","Web","Zone of Truth"], ["Arcane Sight","Bestow Curse","Clairaudience_Clairvoyance","Cup of Dust","Deep Slumber","Dispel Magic","Fly","Glyph of Warding","Guiding Star","Harrowing","Heroism","Lightning Bolt","Locate Object","Lover's Vengeance","Nature's Exile","Pain Strike","Rage","Ray of Exhaustion","Remove Blindness_Deafness","Remove Curse","Remove Disease","Screech","Seek Thoughts","Sepia Snake Sigil","Share Senses","Sleet Storm","Speak with Dead","Stinking Cloud","Suggestion","Summon Monster III","Tongues","Twilight Knife","Vampiric touch","Vermin Shape I","Vermin Shape I","Water Walk","Waters of Lamashtu"], ["Arcane Eye","Black Tentacles","Charm Monster","Confusion","Crushing Despair","Cure Serious Wounds","Death Ward","Detect Scrying","Dimension Door","Discern Lies","Divination","Enervation","Fear","Geas Lesser","Ice Storm","Infernal Healing Greater","Inflict Serious Wounds","Locate Creature","Minor Creation","Moonstruck","Neutralize Poison","Phantasmal Killer","Poison","Scrying","Secure Shelter","Sleepwalk","Solid Fog","Spite","Summon Monster IV","Threefold Aspect","Vermin Shape II","Vermin Shape II","Wandering Star Motes"], ["Baleful Polymorph","Banish Seeming","Blight","Break Enchantment","Cloudkill","Contact Other Plane","Cure Critical Wounds","Dominate Person","Feeblemind","Hold Monster","Inflict Critical Wounds","Magic Jar","Major Creation","Mark of Justice","Mind Fog","Overland Flight","Pain Strike Mass","Prying Eyes","Reincarnate","Rest Eternal","Secret Chest","Suffocation","Summon Monster V","Symbol of Pain","Symbol of Sleep","Telepathic Bond","Teleport","Waves of Fatigue"], ["Analyze Dweomer","Animate Objects","Cloak of Dreams","Cone of Cold","Cure Light Wounds Mass","Dispel Magic Greater","Eyebite","Fester Mass","Find the Path","Flesh to Stone","Geas Quest","Guards and Wards","Heroism Greater","Inflict Light Wounds Mass","Legend Lore","Raise Dead","Slay Living","Stone to Flesh","Suggestion Mass","Summon Monster VI","Swarm Skin","Symbol of Fear","Symbol of Persuasion","Transformation","True Seeing","Unwilling Shield"], ["Arcane Sight Greater","Chain Lightning","Control Weather","Cure Moderate Wounds Mass","Harm","Heal","Hold Person Mass","Inflict Moderate Wounds Mass","Insanity","Instant Summons","Phase Door","Plane Shift","Power Word Blind","Regenerate","Scrying Greater","Summon Monster VII","Symbol of Stunning","Symbol of Weakness","Teleport Greater","Teleport Object","Vision of Lamashtu","Vision","Waves of Exhaustion"], ["Antipathy","Charm Monster Mass","Clone","Cure Serious Wounds Mass","Demand","Destruction","Discern Location","Horrid Wilting","Inflict Serious Wounds Mass","Irresistible Dance","Maze","Mind Blank","Moment of Prescience","Power Word Stun","Prying Eyes Greater","Resurrection","Stormbolts","Summon Monster VIII","Symbol of Death","Symbol of Insanity","Sympathy","Trap the Soul"], ["Astral Projection","Cure Critical Wounds Mass","Dominate Monster","Elemental Swarm","Foresight","Hold Monster Mass","Inflict Critical Wounds Mass","Interplanetary Teleport","Power Word Kill","Refuge","Soul Bind","Storm of Vengeance","Suffocation Mass","Summon Monster IX","Teleportation Circle","Wail of the Banshee"]],
And ClassDetail:

Code: Select all

"Witch_PF":{"abbr":"Wit","control":"Intelligence","prep":1,"CasterLvL":"Full","Slots":0,"SpellList":"Witch","CasterType":"Arcane","Channelling":0,"KnowAll":0,"SchoolFlag":0,"DomainFlag":0,"maxlvl":[1,1,2,2,3,3,4,4,5,5,6,6,7,7,8,8,9,9,9,9],"baseSPD":[[3,1,0,0,0,0,0,0,0,0],[4,2,0,0,0,0,0,0,0,0],[4,2,1,0,0,0,0,0,0,0],[4,3,2,0,0,0,0,0,0,0],[4,3,2,1,0,0,0,0,0,0],[4,3,3,2,0,0,0,0,0,0],[4,4,3,2,1,0,0,0,0,0],[4,4,3,3,2,0,0,0,0,0],[4,4,4,3,2,1,0,0,0,0],[4,4,4,3,3,2,0,0,0,0],[4,4,4,4,3,2,1,0,0,0],[4,4,4,4,3,3,2,0,0,0],[4,4,4,4,4,3,2,1,0,0],[4,4,4,4,4,3,3,2,0,0],[4,4,4,4,4,4,3,2,1,0],[4,4,4,4,4,4,3,3,2,0],[4,4,4,4,4,4,4,3,2,1],[4,4,4,4,4,4,4,3,3,2],[4,4,4,4,4,4,4,4,3,3],[4,4,4,4,4,4,4,4,4,4]]},
When I go to add Burning Hands to his Known Spells, it is not in the list.

User avatar
Threeshades
Kobold
Posts: 10
Joined: Tue Mar 29, 2011 8:27 am

Re: Wrathgon's rewrite of Plothos' Spell Manager

Post by Threeshades »

Hey I also encountered some problems recently with the Witch spell list (among others)

In short it doesn't work at all for me, if I set up a class with the witch spell list and try to learn spells for a token i get this error message:
java.lang.IndexOutOfBoundsException: Index: 2, Size: 2 Fehler beim Ausführen des Ausdrucks learnlvl=json.get(CLSlist,spelllevel+1).

Also I can't set up new spell lists. I can enter a name choose wether or not to copy another spell-list (i choose no, because I want to make a new one) and set the maximum spell level (in this case I tried 9) and I only got this nmessage afterwards:
java.lang.IndexOutOfBoundsException: Index: 0, Size: 0 Fehler beim Ausführen des Ausdrucks levelspell=json.set(levelspell,0,max).
These problems seem to only extend to the APG class spell lists to creating new spell lists. The core classes and new classes with core class spell lists work fine.



Something else i noticed is if i click on config_library on the aliasmask library token and set it to pathfinder, click okay, wait for it to process, close the message window and click config_library again, it will be set back to 3.5 again.



Also why is there no adept class by default already? These are my two problems currently, making Witches work for a PC and Adepts for an NPC (and probably many more along the way)
Last edited by Threeshades on Fri May 06, 2011 2:25 pm, edited 1 time in total.

User avatar
Threeshades
Kobold
Posts: 10
Joined: Tue Mar 29, 2011 8:27 am

Re: Wrathgon's rewrite of Plothos' Spell Manager

Post by Threeshades »

I want to start the campaign on sunday. Any help would be greatly appreciated.

I think at least the Witch problem would be solved if I just could set the Spell Library token to Pathfinder and it would stick with it. But I dont know how. Please I really need help, guys. :(

User avatar
aliasmask
RPTools Team
Posts: 9024
Joined: Tue Nov 10, 2009 6:11 pm
Location: Bay Area

Re: Wrathgon's rewrite of Plothos' Spell Manager

Post by aliasmask »

Easiest way is to go to my signature, download the AliasSpellLib_dnd35_pathfinder_v1.2_PFPreload.rptok file and replace the Lib:AliasSpellLib. No need to configure anything.

User avatar
Threeshades
Kobold
Posts: 10
Joined: Tue Mar 29, 2011 8:27 am

Re: Wrathgon's rewrite of Plothos' Spell Manager

Post by Threeshades »

aliasmask wrote:Easiest way is to go to my signature, download the AliasSpellLib_dnd35_pathfinder_v1.2_PFPreload.rptok file and replace the Lib:AliasSpellLib. No need to configure anything.
Thanks I did it, but unfortunately it fixed neither problem. It still doesn't load the witch spell list and it still doenst let me create spell lists, the error messages are the same.

User avatar
aliasmask
RPTools Team
Posts: 9024
Joined: Tue Nov 10, 2009 6:11 pm
Location: Bay Area

Re: Wrathgon's rewrite of Plothos' Spell Manager

Post by aliasmask »

I was just referring to the problem with a property not saying pathfinder in the lib. The other errors are related only to wrathgon's lib.

The errors you list mention the index being out of bounds. Could be a bad json or something or data within. Depending on what is processing it. For example, I don't know if "Lover's Vengeance" will break his code because of the '. The spells in APG are not in the spell lib yet and they will not have links.

neofax
Great Wyrm
Posts: 1694
Joined: Tue May 26, 2009 8:51 pm
Location: Philadelphia, PA
Contact:

Re: Wrathgon's rewrite of Plothos' Spell Manager

Post by neofax »

@aliasmask: The JSON is fine as I personally made the spell list for the Pathfinder Witch and ran it thru JSONLint. Something in Wrathgon's program chokes on the witch and skips spells. I haven't had the time to try to fix it as I only needed it for a PFS game and I decided to just say what spell I was casting and manually figure out the DC's and such. However, I would like to get it fixed. Also, if you could explain to me how to add the APG spells to your Library, I could make the JSON arrays for it.

User avatar
aliasmask
RPTools Team
Posts: 9024
Joined: Tue Nov 10, 2009 6:11 pm
Location: Bay Area

Re: Wrathgon's rewrite of Plothos' Spell Manager

Post by aliasmask »

Adding the spells is easy, but adding the index is not. You can see the json format in the Descriptions table. The first line has one of the indexes. SpellIndex has a list of the various spell lists those spells appear in reference by the index number in the Descriptions table. If you build your own table with the APG spells following the json format of Descriptions, I have code to parse and build the index tables. You won't need to make the 0 index. That index of spells from the Descriptions table is not needed anymore.

Today, I'm otherwise preoccupied, but I'll take a look at my newer spell lib. I had grand plans for it, but I'll just stick with getting it the way it works now except with the ability to add new spells. I already did most of the work, I just need to finish it up. I've been in a programming slump recently not really wanting to program.

neofax
Great Wyrm
Posts: 1694
Joined: Tue May 26, 2009 8:51 pm
Location: Philadelphia, PA
Contact:

Re: Wrathgon's rewrite of Plothos' Spell Manager

Post by neofax »

I finally got around to fixing most of the problems I have been having. I will be attaching a new Lib:Magic that everyone using Wrathgon's Spell Manager can use with some minor changes to the Campaign Properties. I have all of the spells included up to 6/22/2011 and will soon have them rolling the proper damage and such. You will need to overwrite your campaign property for SpellPedia with the below:

Code: Select all

Assassin1:(None)
Assassin2:(None)
Assassin3:(None)
Assassin4:(None)
AMSL
ASPD1
ASPD2
ASPD3
ASPD4
ASPD5
ASPD6
ASPD7
ASPD8
ASPD9
ASPD10
AKnow1
AKnow2
AKnow3
AKnow4
AKnow5
AKnow6
AKnow7
AKnow8
AKnow9
AKnow10
Bard0:(None)
Bard1:(None)
Bard2:(None)
Bard3:(None)
Bard4:(None)
Bard5:(None)
Bard6:(None)
BMSL
BSPD1
BSPD2
BSPD3
BSPD4
BSPD5
BSPD6
BSPD7
BSPD8
BSPD9
BSPD10
BSPD11
BSPD12
BSPD13
BSPD14
BSPD15
BSPD16
BSPD17
BSPD18
BSPD19
BSPD20
BKnow1
BKnow2
BKnow3
BKnow4
BKnow5
BKnow6
BKnow7
BKnow8
BKnow9
BKnow10
BKnow11
BKnow12
BKnow13
BKnow14
BKnow15
BKnow16
BKnow17
BKnow18
BKnow19
BKnow20
Blackguard1:(None)
Blackguard2:(None)
Blackguard3:(None)
Blackguard4:(None)
BGMSL
BGSPD1
BGSPD2
BGSPD3
BGSPD4
BGSPD5
BGSPD6
BGSPD7
BGSPD8
BGSPD9
BGSPD10
Cleric0:(None)
Cleric1:(None)
Cleric2:(None)
Cleric3:(None)
Cleric4:(None)
Cleric5:(None)
Cleric6:(None)
Cleric7:(None)
Cleric8:(None)
Cleric9:(None)
CMSL
CSPD1
CSPD2
CSPD3
CSPD4
CSPD5
CSPD6
CSPD7
CSPD8
CSPD9
CSPD10
CSPD11
CSPD12
CSPD13
CSPD14
CSPD15
CSPD16
CSPD17
CSPD18
CSPD19
CSPD20
Druid0:(None)
Druid1:(None)
Druid2:(None)
Druid3:(None)
Druid4:(None)
Druid5:(None)
Druid6:(None)
Druid7:(None)
Druid8:(None)
Druid9:(None)
DMSL
DSPD1
DSPD2
DSPD3
DSPD4
DSPD5
DSPD6
DSPD7
DSPD8
DSPD9
DSPD10
DSPD11
DSPD12
DSPD13
DSPD14
DSPD15
DSPD16
DSPD17
DSPD18
DSPD19
DSPD20
Paladin1:(None)
Paladin2:(None)
Paladin3:(None)
Paladin4:(None)
PMSL
PSPD1
PSPD2
PSPD3
PSPD4
PSPD5
PSPD6
PSPD7
PSPD8
PSPD9
PSPD10
PSPD11
PSPD12
PSPD13
PSPD14
PSPD15
PSPD16
PSPD17
PSPD18
PSPD19
PSPD20
Ranger1:(None)
Ranger2:(None)
Ranger3:(None)
Ranger4:(None)
RMSL
RSPD1
RSPD2
RSPD3
RSPD4
RSPD5
RSPD6
RSPD7
RSPD8
RSPD9
RSPD10
RSPD11
RSPD12
RSPD13
RSPD14
RSPD15
RSPD16
RSPD17
RSPD18
RSPD19
RSPD20
Sorcerer0:(None)
Sorcerer1:(None)
Sorcerer2:(None)
Sorcerer3:(None)
Sorcerer4:(None)
Sorcerer5:(None)
Sorcerer6:(None)
Sorcerer7:(None)
Sorcerer8:(None)
Sorcerer9:(None)
SMSL
SSPD1
SSPD2
SSPD3
SSPD4
SSPD5
SSPD6
SSPD7
SSPD8
SSPD9
SSPD10
SSPD11
SSPD12
SSPD13
SSPD14
SSPD15
SSPD16
SSPD17
SSPD18
SSPD19
SSPD20
SKnow1
SKnow2
SKnow3
SKnow4
SKnow5
SKnow6
SKnow7
SKnow8
SKnow9
SKnow10
SKnow11
SKnow12
SKnow13
SKnow14
SKnow15
SKnow16
SKnow17
SKnow18
SKnow19
SKnow20
Wizard0:(None)
Wizard1:(None)
Wizard2:(None)
Wizard3:(None)
Wizard4:(None)
Wizard5:(None)
Wizard6:(None)
Wizard7:(None)
Wizard8:(None)
Wizard9:(None)
WMSL
WSPD1
WSPD2
WSPD3
WSPD4
WSPD5
WSPD6
WSPD7
WSPD8
WSPD9
WSPD10
WSPD11
WSPD12
WSPD13
WSPD14
WSPD15
WSPD16
WSPD17
WSPD18
WSPD19
WSPD20
AirDom
AirDomPowers
AnimalDom
AnimalDomPowers
ArtificeDom
ArtificeDomPowers
ChaosDom
ChaosDomPowers
CharmDom
CharmDomPowers
CommunityDom
CommunityDomPowers
DarknessDom
DarknessDomPowers
DeathDom
DeathDomPowers
DestructionDom
DestructionDomPowers
EarthDom
EarthDomPowers
EvilDom
EvilDomPowers
FireDom
FireDomPowers
GloryDom
GloryDomPowers
GoodDom
GoodDomPowers
HealingDom
HealingDomPowers
KnowledgeDom
KnowledgeDomPowers
LawDom
LawDomPowers
LiberationDom
LiberationDomPowers
LuckDom
LuckDomPowers
MadnessDom
MadnessDomPowers
MagicDom
MagicDomPowers
NobilityDom
NobilityDomPowers
PlantDom
PlantDomPowers
ProtectionDom
ProtectionDomPowers
ReposeDom
ReposeDomPowers
RuneDom
RuneDomPowers
StrengthDom
StrengthDomPowers
SunDom
SunDomPowers
TravelDom
TravelDomPowers
TrickeryDom
TrickeryDomPowers
WarDom
WarDomPowers
WaterDom
WaterDomPowers
WeatherDom
WeatherDomPowers
SchoolList
Abjuration
Conjuration
Divination
Enchantment
Evocation
Illusion
Necromancy
Transmutation
Universal
WizardSchoolList
AbjurationPowers
ConjurationPowers
DivinationPowers
EnchantmentPowers
EvocationPowers
IllusionPowers
NecromancyPowers
TransmutationPowers
UniversalPowers
BloodlineList
BloodlineListPF
AberrantPowers
AberrantSpells
AbyssalPowers
AbyssalSpells
ArcanePowers
ArcaneSpells
CelestialPowers
CelestialSpells
DestinedPowers
DestinedSpells
DraconicPowers
DraconicSpells
ElementalPowers
ElementalSpells
FeyPowers
FeySpells
InfernalPowers
InfernalSpells
UndeadPowers
UndeadSpells
---|Plothos and Wrathgon |---
DomainList
DomainListPF
---|Wrathgon|---
SchoolSpells
SchoolSpellsPF
Spells
SpellsPF
ClassDetail
ClassDetailPF
SLATemplate
SLATemplatePF
PF
SpellCastingInfo
SpellCastingInfoPF
EH
Once this is done, just drop the Lib:Magic token on the map and rename your old version to Lib:Magic-Old. If you experience any errors please post here with what you were doing and a copy of the token as well as the exact error on the screen.
Attachments
Lib_Magic-11GV2.rptok
Improved version of Wrathgon's Spell Manager. Please thank him and Plothos for the original so I could break my teeth learning JSON's. I plan to rewrite this after everyone has provided me with all the problems as I want to make it way faster.
(160.79 KiB) Downloaded 100 times

User avatar
aliasmask
RPTools Team
Posts: 9024
Joined: Tue Nov 10, 2009 6:11 pm
Location: Bay Area

Re: Wrathgon's rewrite of Plothos' Spell Manager

Post by aliasmask »

Found a typo throughout the code: "Add Spell To Databaase@Lib:Magic"

I'm taking a look at this again to make sure I don't get any errors. I think I will re-add my mod that formats some of the lists in a nicer manner too. I also have a new method to speed up the output for some of the larger lists as well.

edit: Yeah, that whole section was broken, but it was an easy fix. I'll post it later.
edit: Class detail was off for sorcerer at level 6 known spells

User avatar
aliasmask
RPTools Team
Posts: 9024
Joined: Tue Nov 10, 2009 6:11 pm
Location: Bay Area

Re: Wrathgon's rewrite of Plothos' Spell Manager

Post by aliasmask »

Okay, here is my update. I've been optimizing for 3.5 and a sorcerer, so if there are any other errors let me know. Be as detailed as you can so I can reproduce error.
/// Fixes and Updates \\\

Code: Select all

Bug fixes & Updates
* Corrected typo with macro name
* Updated macro argument to json (because macro required it)
* Fixed input with wrong parameter
* Fixed typo with function name
* Added option for Martial Arcanist to use BAB for spellcaster DC
* Got rid of damage popup for spells not in db
* Fixed Stat Bonus to use ChaB, IntB or WisB instead of stat because of framework mods.
* Fixed targeting with empty list
* Changed spell casting format a little and fixed Spell capitalization for missing spell ref spells.
* Added Concentration check for 3.5 using SkillsJ data
* Fixed formula for Spellcraft DC
* Changed token image to wrinkled paper overlay
So, you should be able to add spells to the db now. Also, fewer annoying non-relevant popups when casting a spell. Output filtered and reformatted slightly. Again, I only optimized for 3.5 sorcerer, so I may need to duplicate some work for other classes. This token is definitely a Frankenstein's monster of patchwork, but less errors is good.
Attachments
Lib.Spell_database 3.5preload.rptok
MT v1.3b86 3.5 Preload spells - Spell Manager Version
(261.91 KiB) Downloaded 89 times
Lib.Magic 3.5 11GV2.a.rptok
MT v1.3b86
(415.28 KiB) Downloaded 108 times

neofax
Great Wyrm
Posts: 1694
Joined: Tue May 26, 2009 8:51 pm
Location: Philadelphia, PA
Contact:

Re: Wrathgon's rewrite of Plothos' Spell Manager

Post by neofax »

Thanks for making the changes! Now though I get asked for clpowlvl and calc when casting certain spells and when selecting cast.

User avatar
aliasmask
RPTools Team
Posts: 9024
Joined: Tue Nov 10, 2009 6:11 pm
Location: Bay Area

Re: Wrathgon's rewrite of Plothos' Spell Manager

Post by aliasmask »

neofax wrote:Thanks for making the changes! Now though I get asked for clpowlvl and calc when casting certain spells and when selecting cast.
Can you send me your token and I'll take a look tonight. Are you running PF or 3.5? I set EH to 0 for 3.5, so maybe if you cast a spell not in 3.5 you get that error? You can change EH to 3 and it may fix it.

Post Reply

Return to “Drop-In Macro Resources”