DragnMaw
Member
I have been trying to setup a new spell school on my server. I've script checked against ACCs way of doing it, and the base servers way of doing it, and decided to go with the couple of core edits I would need. I have the Spellbook created and Constructable in game, along with a Spell Scroll (Just doing 1 spell for now for proof of concept). The Spell Scroll successfully casts the spell, but the Spellbook shows it as a Bad Spell if added to the Spellbook.
I modified Spellbook.cs to include in the SpellbookType enum my custom spell school, and Added GetTypeForSpell(int spellID)
else if (spellID >= 900 && spellID < 916)
{
return SpellbookType.AdvancedSpells;
}
public static Spellbook FindAdvancedSpells(Mobile from)
{
return Find(from, -1, SpellbookType.AdvancedSpells);
}
and I've added AdvancedSpells to m_CircleNames in SpellRegistry.cs
and I've added Register(900, typeof(AdvancedSpells.DeathVortexSpell)); to Initializer.cs
Does anyone know what I am missing to allow the New Spellbook to be filled by the Spells with ID 900-915 (16 spells). If you need any parts of the code, feel free to ask. I just didn't want to upload that many files / places.
Minor update: I managed to get the spell to add to the book, and updated spell count, still with the name Bad Spell, but it is castable out of the Spellbook.
I modified Spellbook.cs to include in the SpellbookType enum my custom spell school, and Added GetTypeForSpell(int spellID)
else if (spellID >= 900 && spellID < 916)
{
return SpellbookType.AdvancedSpells;
}
public static Spellbook FindAdvancedSpells(Mobile from)
{
return Find(from, -1, SpellbookType.AdvancedSpells);
}
and I've added AdvancedSpells to m_CircleNames in SpellRegistry.cs
and I've added Register(900, typeof(AdvancedSpells.DeathVortexSpell)); to Initializer.cs
Does anyone know what I am missing to allow the New Spellbook to be filled by the Spells with ID 900-915 (16 spells). If you need any parts of the code, feel free to ask. I just didn't want to upload that many files / places.
Post automatically merged:
Minor update: I managed to get the spell to add to the book, and updated spell count, still with the name Bad Spell, but it is castable out of the Spellbook.
Last edited: