RunUO Community

This is a sample guest message. Register a free account today to become a member! Once signed in, you'll be able to participate on this site by adding your own topics and posts, as well as connect with other members through your own private inbox!

ACC - Complete Spell System

zzluis12

Sorceror
Now gives me this

Code:
Scripts: One or more scripts failed to compile or no script files were found.
 - Press return to exit, or R to try again.
Scripts: Compiling C# scripts...failed (3 errors, 0 warnings)
Errors:
 + Customs/-=+ 02 Changing/Reagents/DestroyingAngel.cs:
    CS0539: Line 10: 'ICommodity.DescriptionNumber' en la declaración explícita
de la interfaz no es un miembro de interfaz
    CS0535: Line 6: 'Server.Items.DestroyingAngel' no implementa el miembro de i
nterfaz 'Server.Items.ICommodity.Description'
 + Customs/-=+ 02 Changing/Reagents/PetrafiedWood.cs:
    CS0539: Line 10: 'ICommodity.DescriptionNumber' en la declaración explícita
de la interfaz no es un miembro de interfaz
    CS0535: Line 6: 'Server.Items.PetrafiedWood' no implementa el miembro de int
erfaz 'Server.Items.ICommodity.Description'
 + Customs/-=+ 02 Changing/Reagents/SpringWater.cs:
    CS0539: Line 10: 'ICommodity.DescriptionNumber' en la declaración explícita
de la interfaz no es un miembro de interfaz
    CS0535: Line 6: 'Server.Items.SpringWater' no implementa el miembro de inter
faz 'Server.Items.ICommodity.Description'

And these are the files who you told me to edit:

DestroyingAngel.cs
Code:
using System;
using Server;

namespace Server.Items
{
	public class DestroyingAngel : BaseReagent, ICommodity
	{

        int ICommodity.DescriptionNumber { get { return LabelNumber; } }

		[Constructable]
		public DestroyingAngel() : this( 1 )
		{
		}

		[Constructable]
		public DestroyingAngel( int amount ) : base( 0xE1F, amount )
		{
			Hue = 0x290;
			Name = "destroying angel";
		}

		public DestroyingAngel( Serial serial ) : base( serial )
		{
		}

		public override void Serialize( GenericWriter writer )
		{
			base.Serialize( writer );
			writer.Write( (int) 1 ); // version
		}

		public override void Deserialize( GenericReader reader )
		{
			base.Deserialize( reader );
			int version = reader.ReadInt();
		}
	}
}

PetrafiedWood.cs
Code:
using System;
using Server;

namespace Server.Items
{
	public class PetrafiedWood : BaseReagent, ICommodity
	{
        int ICommodity.DescriptionNumber { get { return LabelNumber; } }

		[Constructable]
		public PetrafiedWood() : this( 1 )
		{
		}

		[Constructable]
		public PetrafiedWood( int amount ) : base( 0x97A, amount )
		{
			Hue = 0x46C;
			Name = "petrified wood";
		}

		public PetrafiedWood( Serial serial ) : base( serial )
		{
		}

		public override void Serialize( GenericWriter writer )
		{
			base.Serialize( writer );
			writer.Write( (int) 1 ); // version
		}

		public override void Deserialize( GenericReader reader )
		{
			base.Deserialize( reader );
			int version = reader.ReadInt();
		}
	}
}

SpringWater.cs
Code:
using System;
using Server;

namespace Server.Items
{
	public class SpringWater : BaseReagent, ICommodity
	{

        int ICommodity.DescriptionNumber { get { return LabelNumber; } }

		[Constructable]
		public SpringWater() : this( 1 )
		{
		}

		[Constructable]
		public SpringWater( int amount ) : base( 0xE24, amount )
		{
			Hue = 0x47F;
			Name = "spring water";
		}

		public SpringWater( Serial serial ) : base( serial )
		{
		}

		public override void Serialize( GenericWriter writer )
		{
			base.Serialize( writer );
			writer.Write( (int) 0 ); // version
		}

		public override void Deserialize( GenericReader reader )
		{
			base.Deserialize( reader );
			int version = reader.ReadInt();
		}
	}
}

Otherwise, is there a way to make them to dont requiere regents and bypass it?
 

sec_goat

Squire
I have I working verison of thisr.... I haven't tested, but it compiles.
 

Attachments

  • Complete Spell System.zip
    295.9 KB · Views: 109

zzluis12

Sorceror
Using that i get

Code:
Errors:
 + Customs/Complete Spell System/-=+ 02 Changing/Reagents/DestroyingAngel.cs:
    CS0539: Line 8: 'ICommodity.DescriptionNumber' en la declaración explícita d
e la interfaz no es un miembro de interfaz
    CS0539: Line 9: 'ICommodity.IsDeedable' en la declaración explícita de la in
terfaz no es un miembro de interfaz
    CS0535: Line 6: 'Server.Items.DestroyingAngel' no implementa el miembro de i
nterfaz 'Server.Items.ICommodity.Description'
 + Customs/Complete Spell System/-=+ 02 Changing/Reagents/PetrafiedWood.cs:
    CS0539: Line 8: 'ICommodity.DescriptionNumber' en la declaración explícita d
e la interfaz no es un miembro de interfaz
    CS0539: Line 9: 'ICommodity.IsDeedable' en la declaración explícita de la in
terfaz no es un miembro de interfaz
    CS0535: Line 6: 'Server.Items.PetrafiedWood' no implementa el miembro de int
erfaz 'Server.Items.ICommodity.Description'
 + Customs/Complete Spell System/-=+ 02 Changing/Reagents/SpringWater.cs:
    CS0539: Line 8: 'ICommodity.DescriptionNumber' en la declaración explícita d
e la interfaz no es un miembro de interfaz
    CS0539: Line 9: 'ICommodity.IsDeedable' en la declaración explícita de la in
terfaz no es un miembro de interfaz
    CS0535: Line 6: 'Server.Items.SpringWater' no implementa el miembro de inter
faz 'Server.Items.ICommodity.Description'
 + Customs/Complete Spell System/-=+ 03 Systems/Cleric/Spells/HammerOfFaithSpell
.cs:
    CS0115: Line 92: 'Server.ACC.CSS.Systems.Cleric.ClericHammerOfFaithSpell.Ham
merOfFaith.GetDamageTypes(Server.Mobile, out int, out int, out int, out int, out
 int, out int, out int)': no se encontró ningún miembro adecuado que reemplazar
 + Customs/Complete Spell System/-=+ 03 Systems/Ranger/Spells/FireBowSpell.cs:
    CS0115: Line 107: 'Server.ACC.CSS.Systems.Ranger.RangerFireBowSpell.RangerFi
reBow.GetDamageTypes(Server.Mobile, out int, out int, out int, out int, out int,
 out int, out int)': no se encontró ningún miembro adecuado que reemplazar
 + Customs/Complete Spell System/-=+ 03 Systems/Ranger/Spells/IceBowSpell.cs:
    CS0115: Line 105: 'Server.ACC.CSS.Systems.Ranger.RangerIceBowSpell.RangerIce
Bow.GetDamageTypes(Server.Mobile, out int, out int, out int, out int, out int, o
ut int, out int)': no se encontró ningún miembro adecuado que reemplazar
 + Customs/Complete Spell System/-=+ 03 Systems/Ranger/Spells/LightningBowSpell.
cs:
    CS0115: Line 102: 'Server.ACC.CSS.Systems.Ranger.RangerLightningBowSpell.Ran
gerLightningBow.GetDamageTypes(Server.Mobile, out int, out int, out int, out int
, out int, out int, out int)': no se encontró ningún miembro adecuado que reempl
azar
 + Customs/Complete Spell System/-=+ 03 Systems/Ranger/Spells/NoxBowSpell.cs:
    CS0115: Line 109: 'Server.ACC.CSS.Systems.Ranger.RangerNoxBowSpell.RangerNox
Bow.GetDamageTypes(Server.Mobile, out int, out int, out int, out int, out int, o
ut int, out int)': no se encontró ningún miembro adecuado que reemplazar
Scripts: One or more scripts failed to compile or no script files were found.
 - Press return to exit, or R to try again.

I'm using RunUO Rc2.
Is it compatible?, which yours?
 

zzluis12

Sorceror
Can you upload it or tell me where can i find it?, the search thing is not working for me, at last i know, last searches who i've made was all of them no results somehow, about anything.
 

tass23

Page
Where are the spell icons located for ACC? I got ahold of Mysticism for ACC, but all the spell icons are for the Recall spell. I cna't seem to find where to change it to get the right icon.

EDIT: nvm, I found them. Inside each Initializer, for each spell there are two numbers at the end, the first one is the spell icon.
 

tass23

Page
Did anyone figure out the issue with Runebooks not recognizing the CSS? I've been looking at the RunebookGump.cs, here's the section for recalling:
Code:
      case 3: // Recall
      {
      if ( HasSpell( from, 31 ) )
      {
        int xLong = 0, yLat = 0;
        int xMins = 0, yMins = 0;
        bool xEast = false, ySouth = false;
        if ( Sextant.Format( e.Location, e.Map, ref xLong, ref yLat, ref xMins, ref yMins, ref xEast, ref ySouth ) )
        {
        string location = String.Format( "{0}° {1}'{2}, {3}° {4}'{5}", yLat, yMins, ySouth ? "S" : "N", xLong, xMins, xEast ? "E" : "W" );
        from.SendMessage( location );
        }
        m_Book.OnTravel();
        new RecallSpell( from, null, e, null ).Cast();
      }
      }
      else
      {
        from.SendLocalizedMessage( 500015 ); // You do not have that spell!
      }
      m_Book.Openers.Remove( from );
      break;
      }
Now, I figured it would be simple enough to duplicate the IF section and change the number to the CSS.Mage RecallSpell number, 2271, but that's not working. Here is the entire recall section with the attempted addition of CSS.Mage:
Code:
      case 3: // Recall
      {
      if ( HasSpell( from, 31 ) )
      {
        int xLong = 0, yLat = 0;
        int xMins = 0, yMins = 0;
        bool xEast = false, ySouth = false;
        if ( Sextant.Format( e.Location, e.Map, ref xLong, ref yLat, ref xMins, ref yMins, ref xEast, ref ySouth ) )
        {
        string location = String.Format( "{0}° {1}'{2}, {3}° {4}'{5}", yLat, yMins, ySouth ? "S" : "N", xLong, xMins, xEast ? "E" : "W" );
        from.SendMessage( location );
        }
        m_Book.OnTravel();
        new RecallSpell( from, null, e, null ).Cast();
      }
      if ( HasSpell( from, 2271 ) )
      {
        int xLong = 0, yLat = 0;
        int xMins = 0, yMins = 0;
        bool xEast = false, ySouth = false;
        if ( Sextant.Format( e.Location, e.Map, ref xLong, ref yLat, ref xMins, ref yMins, ref xEast, ref ySouth ) )
        {
        string location = String.Format( "{0}° {1}'{2}, {3}° {4}'{5}", yLat, yMins, ySouth ? "S" : "N", xLong, xMins, xEast ? "E" : "W" );
        from.SendMessage( location );
        }
        m_Book.OnTravel();
        new RecallSpell( from, null, e, null ).Cast();
      }
      else
      {
        from.SendLocalizedMessage( 500015 ); // You do not have that spell!
      }
      m_Book.Openers.Remove( from );
      break;
      }
This compiles, but does nothing. When you click on a location to recall, it says "You do not have that spell!" What am I missing here?
 

tass23

Page
I've tried everything I can think of in pulling the spell number from CSS, but it's not recognizing it. Currently, the down and dirty fix is to have players use the original mage spellbook and keep it in a bag inside their backpack. They still get the message "You do not have that spell!", but the recall, gate, or sacred journey casts anyway, but it's not the CSS version that's casting.
 

A_Li_N

Knight
I've tried everything I can think of in pulling the spell number from CSS, but it's not recognizing it. Currently, the down and dirty fix is to have players use the original mage spellbook and keep it in a bag inside their backpack. They still get the message "You do not have that spell!", but the recall, gate, or sacred journey casts anyway, but it's not the CSS version that's casting.
This system was created in a way as to not modify the default scripts. As such, the default scripts like the RuneBookGump are not aware of it. In the simplest of terms, the default runebook won't work with these spells...and I do not believe I've created a runebook for the system.
In order to get the runebookgump to be aware of these other systems, you would have to write code to return a CSpellbook and check if it has the requested spell.
Something along the lines of:
Code:
case 3: // Recall
{
    if (HasSpell(from, 31) ||
        Server.ACC.CSS.CSpellbook.MobileHasSpell(from, ACC.CSS.School.Magery, typeof(RecallSpell)))
    {.......
        break;
    }
case 4: // Gate
{
    if (HasSpell(from, 51) ||
         Server.ACC.CSS.CSpellbook.MobileHasSpell(from, ACC.CSS.School.Magery, typeof(GateTravelSpell)))
    {.......
        break;
    }
case 5: // Sacred Journey
{
    if (Core.AOS)
    {
        if (HasSpell(from, 209) ||
             Server.ACC.CSS.CSpellbook.MobileHasSpell(from, ACC.CSS.School.Magery, typeof(SacredJourneySpell)))
        {......
 

tass23

Page
Okay, awesome A Li N, thanks :)
I thought I was gonna go crazy working on this one. I thought it was simple enough to add just the spell number from CSS like it is from the distros, thanks again man! :D
 

tass23

Page
It all works Maczar. Just make sure you download all the other components too. Look at the first page of this post.
 

troyboy731

Sorceror
I have runuo svn 2.1 611 and put this system in and when i try to use a few spells it says that "i do not have this spell" so far every spell does that. i've only tried 7 of them over 2 books. what have I overlooked. Thanks. UPDA TE: well i feel newb. the damn books were in another bag the whole time lol.. thanks anyway. btw very nice system.
 
Top