If you're like me and you die alot, I hate moving all the spell books to find my rings, and bracelets, etc. Well, I made a small change to Spellbook.cs to eliminate this, kinda. Allow me to explain. When a cast is requested, Spellbook.cs looks through all of your spellbooks in your pack and sees what spells you have. Of course, the book has to exist in your pack, and the spell has to exist in your book, obviously. With this small change to Spellbook.cs, it will assume you have all spells and attempt to cast it. Therefore, no need to have the book in your pack. Make sense? Well, here it is:
Just replace:
Code:
private static void EventSink_CastSpellRequest( CastSpellRequestEventArgs e )
{
Mobile from = e.Mobile;
if ( !Multis.DesignContext.Check( from ) )
return; // They are customizing
Spellbook book = e.Spellbook as Spellbook;
int spellID = e.SpellID;
if ( book == null || !book.HasSpell( spellID ) )
book = Find( from, spellID );
if ( book != null && book.HasSpell( spellID ) )
{
Spell spell = SpellRegistry.NewSpell( spellID, from, null );
if ( spell != null )
spell.Cast();
else
from.SendLocalizedMessage( 502345 ); // This spell has been temporarily disabled.
}
else
{
from.SendLocalizedMessage( 500015 ); // You do not have that spell!
}
}
WITH:
Code:
//Edit To Eliminate SpellBooks
private static void EventSink_CastSpellRequest( CastSpellRequestEventArgs e )
{
Mobile from = e.Mobile;
if ( !Multis.DesignContext.Check( from ) )
return; // They are customizing
int spellID = e.SpellID;
Spell spell = SpellRegistry.NewSpell( spellID, from, null );
if ( spell != null )
spell.Cast();
else
from.SendLocalizedMessage( 502345 ); // This spell has been temporarily disabled.
}
//End Edit To Eliminate SpellBooks