Go Back   RunUO - Ultima Online Emulation > RunUO > Script Support

Script Support Get support for modifying RunUO Scripts, or writing your own!

Reply
 
Thread Tools Display Modes
Old 10-15-2005, 05:56 PM   #1 (permalink)
Forum Master
 
Joeku's Avatar
 
Join Date: Feb 2005
Location: ShatteredSosaria.com
Posts: 9,260
Default daat99 OWLTR Ores and Leathers... IT'S A DOOZY!

Okay, I decided to modify daat99's OWLTR to change the names of the new ores and 2 of the leathers... and I have some problems (who would have guessed?!)

Alright, the ores changed fine but for some reason it REFUSES to recognize that I changed the leathers!!! I don't know what to do! I changed the Blaze leather to Daurian leather, and the Frost leather to Anarak leather, in all of the distros (as well as all of daat99's new files that mention them). I was very careful to only change the blaze leather and not the ore. Here are all of the files that I modified in this entire process:
Code:
DefBlacksmithy
DefTinkering
DefTailoring
DefMasonry
BulkMaterialType
OreInfo
Granite
Ore
Ingots
BaseArmor
BaseWeapon
MetalWorkersKey
StoneWorkersKey
TailorsKey
Mining
HarvestSystem
Elementals
LeatherElementals
SmallBOD
SmallBODAcceptGump
SmallSmithBOD
CraftItem
LargeBODAcceptGump
LargeBODGump
ResourceRecipe
RepairDeed
Recipies Lists
OreElementals
Master of The Arts
Hides
Leathers
BaseCreature
Mule
BOB
BOBGump
Masters Knife
Gargoyles Knife
Charged Dye Tub
Bag of Resources
Armor of Crafting
SmallTailorBOD
SmallBODAcceptGump
LargeBOD
ArmorEnums
BulkMaterialType
ProspectorsTool
It's kind of jumbled up, but you get the picture. Now here are my errors:
Quote:
- Error: Scripts\Engines\AI\Creature\BaseCreature.cs: CS0246: (line 1413, column 28) The type or namespace name 'AnarakHides' could not be found (are you missing a using directive or an assembly reference?)
- Error: Scripts\Engines\BulkOrders\Books\BOBGump.cs: CS0117: (line 196, column 12) 'Server.Engines.BulkOrders.BulkMaterialType' does not contain a definition for 'Daurian'
- Error: Scripts\Engines\BulkOrders\SmallBOD.cs: CS0117: (line 193, column 48)'Server.Engines.BulkOrders.BulkMaterialType' does not contain a definition for 'Daurian'
- Error: Scripts\Engines\BulkOrders\SmallBOD.cs: CS0163: (line 173, column 4) Control cannot fall through from one case label ('case 107:') to another
- Error: Scripts\Engines\BulkOrders\SmallBOD.cs: CS0117: (line 196, column 47)'Server.Engines.BulkOrders.BulkMaterialType' does not contain a definition for 'Aranak'
- Error: Scripts\Engines\BulkOrders\SmallBOD.cs: CS0163: (line 173, column 4) Control cannot fall through from one case label ('case 110:') to another
- Error: Scripts\Engines\BulkOrders\SmallSmithBOD.cs: CS0117: (line 130, column 13) 'Server.Engines.BulkOrders.BulkMaterialType' does not contain a definition for 'Aranak'
- Error: Scripts\Engines\BulkOrders\SmallTailorBOD.cs: CS0117: (line 122, column 13) 'Server.Engines.BulkOrders.BulkMaterialType' does not contain a definition for 'BlazeL'
- Error: Scripts\Engines\Craft\DefTailoring.cs: CS0246: (line 303, column 23) The type or namespace name 'AnarakLeather' could not be found (are you missing a using directive or an assembly reference?)
- Error: Scripts\Engines\Craft\DefTinkering.cs: CS0246: (line 409, column 27) The type or namespace name 'AnarakLeather' could not be found (are you missing ausing directive or an assembly reference?)
- Error: Scripts\Items\Armor\BaseArmor.cs: CS0117: (line 1152, column 24) 'Server.Items.ArmorMaterialType' does not contain a definition for 'Aranak'
- Error: Scripts\Misc\OreInfo.cs: CS0117: (line 1014, column 57) 'Server.Items.ArmorMaterialType' does not contain a definition for 'Aranak'
- Error: Scripts\New Scripts\Systems\Daat99s_OWLTR_v2.5\New\BodRewards\ Gargoyles Knife.cs: CS0246: (line 190, column 33) The type or namespace name 'AnarakHides' could not be found (are you missing a using directive or an assembly reference?)
- Error: Scripts\New Scripts\Systems\Daat99s_OWLTR_v2.5\New\BodRewards\ Gargoyles Knife.cs: CS0246: (line 214, column 33) The type or namespace name 'AnarakHides' could not be found (are you missing a using directive or an assembly reference?)
- Error: Scripts\New Scripts\Systems\Daat99s_OWLTR_v2.5\New\BodRewards\ Gargoyles Knife.cs: CS0246: (line 236, column 33) The type or namespace name 'AnarakHides' could not be found (are you missing a using directive or an assembly reference?)
- Error: Scripts\New Scripts\Systems\Daat99s_OWLTR_v2.5\New\BodRewards\ Gargoyles Knife.cs: CS0246: (line 256, column 33) The type or namespace name 'AnarakHides' could not be found (are you missing a using directive or an assembly reference?)
- Error: Scripts\New Scripts\Systems\Daat99s_OWLTR_v2.5\New\BodRewards\ Gargoyles Knife.cs: CS0246: (line 274, column 33) The type or namespace name 'AnarakHides' could not be found (are you missing a using directive or an assembly reference?)
- Error: Scripts\New Scripts\Systems\Daat99s_OWLTR_v2.5\New\BodRewards\ Gargoyles Knife.cs: CS0246: (line 290, column 33) The type or namespace name 'AnarakHides' could not be found (are you missing a using directive or an assembly reference?)
- Error: Scripts\New Scripts\Systems\Daat99s_OWLTR_v2.5\New\BodRewards\ MastersKnife.cs: CS0246: (line 112, column 26) The type or namespace name 'AnarakHides' could not be found (are you missing a using directive or an assembly reference?)
- Error: Scripts\New Scripts\Systems\Daat99s_OWLTR_v2.5\New\Elementals. cs: CS0117: (line 141, column 47) 'Server.Items.CraftResource' does not contain a definition for 'AnarakLeather'
- Error: Scripts\New Scripts\Systems\Daat99s_OWLTR_v2.5\New\LeatherElem entals.cs: CS0117: (line 624, column 50) 'Server.Mobiles.HideType' does not contain a definition for 'Aranak'
- Error: Scripts\New Scripts\Systems\Daat99s_OWLTR_v2.5\New\Master of The Arts.cs: CS0117: (line 301, column 53) 'Server.Items.CraftResource' does not contain a definition for 'AnarakLeather'
- Error: Scripts\New Scripts\Systems\Daat99s_OWLTR_v2.5\New\Mule.cs: CS0246: (line 82, column 19) The type or namespace name 'AnarakLeather' could not be found (are you missing a using directive or an assembly reference?)
I WANT TO CRY!!!
Okay, now here are the scripts that I think might be erroneous...
Hides.cs:
Code:
using System;
using Server.Items;
using Server.Network;

namespace Server.Items
{
	public abstract class BaseHides : Item, ICommodity
	{
		private CraftResource m_Resource;

		[CommandProperty( AccessLevel.GameMaster )]
		public CraftResource Resource
		{
			get{ return m_Resource; }
			set{ m_Resource = value; InvalidateProperties(); }
		}
		
		string ICommodity.Description
		{
			get
			{
				return String.Format( Amount == 1 ? "{0} pile of hides" : "{0} piles of hides", Amount );
			}
		}

		public override void Serialize( GenericWriter writer )
		{
			base.Serialize( writer );

			writer.Write( (int) 1 ); // version

			writer.Write( (int) m_Resource );
		}

		public override void Deserialize( GenericReader reader )
		{
			base.Deserialize( reader );

			int version = reader.ReadInt();

			switch ( version )
			{
				case 1:
				{
					m_Resource = (CraftResource)reader.ReadInt();
					break;
				}
				case 0:
				{
					OreInfo info = new OreInfo( reader.ReadInt(), reader.ReadInt(), reader.ReadString() );

					m_Resource = CraftResources.GetFromOreInfo( info );
					break;
				}
			}
		}

		public BaseHides( CraftResource resource ) : this( resource, 1 )
		{
		}

		public BaseHides( CraftResource resource, int amount ) : base( 0x1079 )
		{
			Stackable = true;
			Weight = 5.0;
			Amount = amount;
			Hue = CraftResources.GetHue( resource );
			m_Resource = resource;
		}

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

		public override void AddNameProperty( ObjectPropertyList list )
		{
			if ( Amount > 1 )
				list.Add( 1050039, "{0}\t#{1}", Amount, 1024216 ); // ~1_NUMBER~ ~2_ITEMNAME~
			else
				list.Add( 1024216 ); // pile of hides
		}

		public override void GetProperties( ObjectPropertyList list )
		{
			base.GetProperties( list );

			if ( !CraftResources.IsStandard( m_Resource ) )
			{
				int num = CraftResources.GetLocalizationNumber( m_Resource );

				if ( num > 0 )
					list.Add( num );
				else
					list.Add( CraftResources.GetName( m_Resource ) );
			}
		}

		public override int LabelNumber
		{
			get
			{
				if ( m_Resource >= CraftResource.SpinedLeather && m_Resource <= CraftResource.EtherealLeather )
					return 1049687 + (int)(m_Resource - CraftResource.SpinedLeather);

				return 1047023;
			}
		}
	}

	[FlipableAttribute( 0x1079, 0x1078 )]
	public class Hides : BaseHides, IScissorable
	{
		[Constructable]
		public Hides() : this( 1 )
		{
		}

		[Constructable]
		public Hides( int amount ) : base( CraftResource.RegularLeather, amount )
		{
			Name = "Regular Hides";
		}

		public Hides( 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();
		}

		public override Item Dupe( int amount )
		{
			return base.Dupe( new Hides( amount ), amount );
		}

		public bool Scissor( Mobile from, Scissors scissors )
		{
			if ( Deleted || !from.CanSee( this ) ) return false;

			base.ScissorHelper( from, new Leather(), 1 );

			return true;
		}
	}

	[FlipableAttribute( 0x1079, 0x1078 )]
	public class SpinedHides : BaseHides, IScissorable
	{
		[Constructable]
		public SpinedHides() : this( 1 )
		{
		}

		[Constructable]
		public SpinedHides( int amount ) : base( CraftResource.SpinedLeather, amount )
		{
			Name = "Spined Hides";
		}

		public SpinedHides( 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();
		}

		public override Item Dupe( int amount )
		{
			return base.Dupe( new SpinedHides( amount ), amount );
		}

		public bool Scissor( Mobile from, Scissors scissors )
		{
			if ( Deleted || !from.CanSee( this ) ) return false;

			base.ScissorHelper( from, new SpinedLeather(), 1 );

			return true;
		}
	}

	[FlipableAttribute( 0x1079, 0x1078 )]
	public class HornedHides : BaseHides, IScissorable
	{
		[Constructable]
		public HornedHides() : this( 1 )
		{
		}

		[Constructable]
		public HornedHides( int amount ) : base( CraftResource.HornedLeather, amount )
		{
			Name = "Horned Hides";
		}

		public HornedHides( 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();
		}

		public override Item Dupe( int amount )
		{
			return base.Dupe( new HornedHides( amount ), amount );
		}

		public bool Scissor( Mobile from, Scissors scissors )
		{
			if ( Deleted || !from.CanSee( this ) ) return false;

			base.ScissorHelper( from, new HornedLeather(), 1 );

			return true;
		}
	}

	[FlipableAttribute( 0x1079, 0x1078 )]
	public class BarbedHides : BaseHides, IScissorable
	{
		[Constructable]
		public BarbedHides() : this( 1 )
		{
		}

		[Constructable]
		public BarbedHides( int amount ) : base( CraftResource.BarbedLeather, amount )
		{
			Name = "Barbed Hides";
		}

		public BarbedHides( 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();
		}

		public override Item Dupe( int amount )
		{
			return base.Dupe( new BarbedHides( amount ), amount );
		}

		public bool Scissor( Mobile from, Scissors scissors )
		{
			if ( Deleted || !from.CanSee( this ) ) return false;

			base.ScissorHelper( from, new BarbedLeather(), 1 );

			return true;
		}
	}

	[FlipableAttribute( 0x1079, 0x1078 )]
	public class PolarHides : BaseHides, IScissorable
	{
		[Constructable]
		public PolarHides() : this( 1 )
		{
		}

		[Constructable]
		public PolarHides( int amount ) : base( CraftResource.PolarLeather, amount )
		{
			Name = "Polar Hides";
		}

		public PolarHides( 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();
		}

		public override Item Dupe( int amount )
		{
			return base.Dupe( new PolarHides( amount ), amount );
		}

		public bool Scissor( Mobile from, Scissors scissors )
		{
			if ( Deleted || !from.CanSee( this ) ) return false;

			base.ScissorHelper( from, new PolarLeather(), 1 );

			return true;
		}
	}
	
	[FlipableAttribute( 0x1079, 0x1078 )]
	public class SyntheticHides : BaseHides, IScissorable
	{
		[Constructable]
		public SyntheticHides() : this( 1 )
		{
		}

		[Constructable]
		public SyntheticHides( int amount ) : base( CraftResource.SyntheticLeather, amount )
		{
			Name = "Synthetic Hides";
		}

		public SyntheticHides( 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();
		}

		public override Item Dupe( int amount )
		{
			return base.Dupe( new SyntheticHides( amount ), amount );
		}

		public bool Scissor( Mobile from, Scissors scissors )
		{
			if ( Deleted || !from.CanSee( this ) ) return false;

			base.ScissorHelper( from, new SyntheticLeather(), 1 );

			return true;
		}
	}

	[FlipableAttribute( 0x1079, 0x1078 )]
	public class DaurianHides : BaseHides, IScissorable
	{
		[Constructable]
		public DaurianHides() : this( 1 )
		{
		}

		[Constructable]
		public DaurianHides( int amount ) : base( CraftResource.DaurianLeather, amount )
		{
			Name = "Daurian Hides";
		}

		public DaurianHides( 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();
		}

		public override Item Dupe( int amount )
		{
			return base.Dupe( new DaurianHides( amount ), amount );
		}

		public bool Scissor( Mobile from, Scissors scissors )
		{
			if ( Deleted || !from.CanSee( this ) ) return false;

			base.ScissorHelper( from, new DaurianLeather(), 1 );

			return true;
		}
	}

	[FlipableAttribute( 0x1079, 0x1078 )]
	public class DaemonicHides : BaseHides, IScissorable
	{
		[Constructable]
		public DaemonicHides() : this( 1 )
		{
		}

		[Constructable]
		public DaemonicHides( int amount ) : base( CraftResource.DaemonicLeather, amount )
		{
			Name = "Daemonic Hides";
		}

		public DaemonicHides( 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();
		}

		public override Item Dupe( int amount )
		{
			return base.Dupe( new DaemonicHides( amount ), amount );
		}

		public bool Scissor( Mobile from, Scissors scissors )
		{
			if ( Deleted || !from.CanSee( this ) ) return false;

			base.ScissorHelper( from, new DaemonicLeather(), 1 );

			return true;
		}
	}

	[FlipableAttribute( 0x1079, 0x1078 )]
	public class ShadowHides : BaseHides, IScissorable
	{
		[Constructable]
		public ShadowHides() : this( 1 )
		{
		}

		[Constructable]
		public ShadowHides( int amount ) : base( CraftResource.ShadowLeather, amount )
		{
			Name = "Shadow Hides";
		}

		public ShadowHides( 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();
		}

		public override Item Dupe( int amount )
		{
			return base.Dupe( new ShadowHides( amount ), amount );
		}

		public bool Scissor( Mobile from, Scissors scissors )
		{
			if ( Deleted || !from.CanSee( this ) ) return false;

			base.ScissorHelper( from, new ShadowLeather(), 1 );

			return true;
		}
	}

	[FlipableAttribute( 0x1079, 0x1078 )]
	public class AranakHides : BaseHides, IScissorable
	{
		[Constructable]
		public AranakHides() : this( 1 )
		{
		}

		[Constructable]
		public AranakHides( int amount ) : base( CraftResource.AranakLeather, amount )
		{
			Name = "Aranak Hides";
		}

		public AranakHides( 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();
		}

		public override Item Dupe( int amount )
		{
			return base.Dupe( new AranakHides( amount ), amount );
		}

		public bool Scissor( Mobile from, Scissors scissors )
		{
			if ( Deleted || !from.CanSee( this ) ) return false;

			base.ScissorHelper( from, new AranakLeather(), 1 );

			return true;
		}
	}

	[FlipableAttribute( 0x1079, 0x1078 )]
	public class EtherealHides : BaseHides, IScissorable
	{
		[Constructable]
		public EtherealHides() : this( 1 )
		{
		}

		[Constructable]
		public EtherealHides( int amount ) : base( CraftResource.EtherealLeather, amount )
		{
			Name = "Ethereal Hides";
		}

		public EtherealHides( 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();
		}

		public override Item Dupe( int amount )
		{
			return base.Dupe( new EtherealHides( amount ), amount );
		}

		public bool Scissor( Mobile from, Scissors scissors )
		{
			if ( Deleted || !from.CanSee( this ) ) return false;

			base.ScissorHelper( from, new EtherealLeather(), 1 );

			return true;
		}
	}
}
Leathers.cs:
Code:
using System;
using Server.Items;
using Server.Network;

namespace Server.Items
{
	public abstract class BaseLeather : Item, ICommodity
	{
		private CraftResource m_Resource;

		[CommandProperty( AccessLevel.GameMaster )]
		public CraftResource Resource
		{
			get{ return m_Resource; }
			set{ m_Resource = value; InvalidateProperties(); }
		}
		
		string ICommodity.Description
		{
			get
			{
				return String.Format( Amount == 1 ? "{0} piece of leather" : "{0} pieces of leather", Amount );
			}
		}

		public override void Serialize( GenericWriter writer )
		{
			base.Serialize( writer );

			writer.Write( (int) 1 ); // version

			writer.Write( (int) m_Resource );
		}

		public override void Deserialize( GenericReader reader )
		{
			base.Deserialize( reader );

			int version = reader.ReadInt();

			switch ( version )
			{
				case 1:
				{
					m_Resource = (CraftResource)reader.ReadInt();
					break;
				}
				case 0:
				{
					OreInfo info = new OreInfo( reader.ReadInt(), reader.ReadInt(), reader.ReadString() );

					m_Resource = CraftResources.GetFromOreInfo( info );
					break;
				}
			}
		}

		public BaseLeather( CraftResource resource ) : this( resource, 1 )
		{
		}

		public BaseLeather( CraftResource resource, int amount ) : base( 0x1081 )
		{
			Stackable = true;
			Weight = 1.0;
			Amount = amount;
			Hue = CraftResources.GetHue( resource );

			m_Resource = resource;
		}

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

		public override void AddNameProperty( ObjectPropertyList list )
		{
			if ( Amount > 1 )
				list.Add( 1050039, "{0}\t#{1}", Amount, 1024199 ); // ~1_NUMBER~ ~2_ITEMNAME~
			else
				list.Add( 1024199 ); // cut leather
		}

		public override void GetProperties( ObjectPropertyList list )
		{
			base.GetProperties( list );

			if ( !CraftResources.IsStandard( m_Resource ) )
			{
				int num = CraftResources.GetLocalizationNumber( m_Resource );

				if ( num > 0 )
					list.Add( num );
				else
					list.Add( CraftResources.GetName( m_Resource ) );
			}
		}

		public override int LabelNumber
		{
			get
			{
				if ( m_Resource >= CraftResource.SpinedLeather && m_Resource <= CraftResource.EtherealLeather )
					return 1049684 + (int)(m_Resource - CraftResource.SpinedLeather);

				return 1047022;
			}
		}
	}

	[FlipableAttribute( 0x1081, 0x1082 )]
	public class Leather : BaseLeather
	{
		[Constructable]
		public Leather() : this( 1 )
		{
		}

		[Constructable]
		public Leather( int amount ) : base( CraftResource.RegularLeather, amount )
		{
			Name = "Regular Leather";
		}

		public Leather( 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();
		}

		public override Item Dupe( int amount )
		{
			return base.Dupe( new Leather( amount ), amount );
		}
	}

	[FlipableAttribute( 0x1081, 0x1082 )]
	public class SpinedLeather : BaseLeather
	{
		[Constructable]
		public SpinedLeather() : this( 1 )
		{
		}

		[Constructable]
		public SpinedLeather( int amount ) : base( CraftResource.SpinedLeather, amount )
		{
			Name = "Spined Leather";
		}

		public SpinedLeather( 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();
		}

		public override Item Dupe( int amount )
		{
			return base.Dupe( new SpinedLeather( amount ), amount );
		}
	}

	[FlipableAttribute( 0x1081, 0x1082 )]
	public class HornedLeather : BaseLeather
	{
		[Constructable]
		public HornedLeather() : this( 1 )
		{
		}

		[Constructable]
		public HornedLeather( int amount ) : base( CraftResource.HornedLeather, amount )
		{
			Name = "Horned Leather";
		}

		public HornedLeather( 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();
		}

		public override Item Dupe( int amount )
		{
			return base.Dupe( new HornedLeather( amount ), amount );
		}
	}

	[FlipableAttribute( 0x1081, 0x1082 )]
	public class BarbedLeather : BaseLeather
	{
		[Constructable]
		public BarbedLeather() : this( 1 )
		{
		}

		[Constructable]
		public BarbedLeather( int amount ) : base( CraftResource.BarbedLeather, amount )
		{
			Name = "Barbed Leather";
		}

		public BarbedLeather( 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();
		}

		public override Item Dupe( int amount )
		{
			return base.Dupe( new BarbedLeather( amount ), amount );
		}
	}

	[FlipableAttribute( 0x1081, 0x1082 )]
	public class PolarLeather : BaseLeather
	{
		[Constructable]
		public PolarLeather() : this( 1 )
		{
		}

		[Constructable]
		public PolarLeather( int amount ) : base( CraftResource.PolarLeather, amount )
		{
			Name = "Polar Leather";
		}

		public PolarLeather( 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();
		}

		public override Item Dupe( int amount )
		{
			return base.Dupe( new PolarLeather( amount ), amount );
		}
	}

	[FlipableAttribute( 0x1081, 0x1082 )]
	public class SyntheticLeather : BaseLeather
	{
		[Constructable]
		public SyntheticLeather() : this( 1 )
		{
		}

		[Constructable]
		public SyntheticLeather( int amount ) : base( CraftResource.SyntheticLeather, amount )
		{
			Name = "Synthetic Leather";
		}

		public SyntheticLeather( 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();
		}

		public override Item Dupe( int amount )
		{
			return base.Dupe( new SyntheticLeather( amount ), amount );
		}
	}

	[FlipableAttribute( 0x1081, 0x1082 )]
	public class DaurianLeather : BaseLeather
	{
		[Constructable]
		public DaurianLeather() : this( 1 )
		{
		}

		[Constructable]
		public DaurianLeather( int amount ) : base( CraftResource.DaurianLeather, amount )
		{
			Name = "Daurian Leather";
		}

		public DaurianLeather( 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();
		}

		public override Item Dupe( int amount )
		{
			return base.Dupe( new DaurianLeather( amount ), amount );
		}
	}
	
	[FlipableAttribute( 0x1081, 0x1082 )]
	public class DaemonicLeather : BaseLeather
	{
		[Constructable]
		public DaemonicLeather() : this( 1 )
		{
		}

		[Constructable]
		public DaemonicLeather( int amount ) : base( CraftResource.DaemonicLeather, amount )
		{
			Name = "Daemonic Leather";
		}

		public DaemonicLeather( 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();
		}

		public override Item Dupe( int amount )
		{
			return base.Dupe( new DaemonicLeather( amount ), amount );
		}
	}

	[FlipableAttribute( 0x1081, 0x1082 )]
	public class ShadowLeather : BaseLeather
	{
		[Constructable]
		public ShadowLeather() : this( 1 )
		{
		}

		[Constructable]
		public ShadowLeather( int amount ) : base( CraftResource.ShadowLeather, amount )
		{
			Name = "Shadow Leather";
		}

		public ShadowLeather( 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();
		}

		public override Item Dupe( int amount )
		{
			return base.Dupe( new ShadowLeather( amount ), amount );
		}
	}

	[FlipableAttribute( 0x1081, 0x1082 )]
	public class AranakLeather : BaseLeather
	{
		[Constructable]
		public AranakLeather() : this( 1 )
		{
		}

		[Constructable]
		public AranakLeather( int amount ) : base( CraftResource.AranakLeather, amount )
		{
			Name = "Aranak Leather";
		}

		public AranakLeather( 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();
		}

		public override Item Dupe( int amount )
		{
			return base.Dupe( new AranakLeather( amount ), amount );
		}
	}

	[FlipableAttribute( 0x1081, 0x1082 )]
	public class EtherealLeather : BaseLeather
	{
		[Constructable]
		public EtherealLeather() : this( 1 )
		{
		}

		[Constructable]
		public EtherealLeather( int amount ) : base( CraftResource.EtherealLeather, amount )
		{
			Name = "Ethereal Leather";
		}

		public EtherealLeather( 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();
		}

		public override Item Dupe( int amount )
		{
			return base.Dupe( new EtherealLeather( amount ), amount );
		}
	}
}
OreInfo.cs:
Code:
using System;
using System.Collections;
using Server.daat99;

namespace Server.Items
{
	public enum CraftResource
	{
		None = 0,
		Iron = 1,
		DullCopper,
		ShadowIron,
		Copper,
		Bronze,
		Gold,
		Agapite,
		Verite,
		Valorite,
		Volcanite,
		Syenite,
		Nitriton,
		Quartzite,
		Kyanite,

		RegularLeather = 101,
		SpinedLeather,
		HornedLeather,
		BarbedLeather,
		PolarLeather,
		SyntheticLeather,
		DaurianLeather,
		DaemonicLeather,
		ShadowLeather,
		AranakLeather,
		EtherealLeather,

		RedScales = 201,
		YellowScales,
		BlackScales,
		GreenScales,
		WhiteScales,
		BlueScales,
		CopperScales,
		SilverScales,
		GoldScales,

		Log = 300,
		Pine,
		Ash,
		Mohogany,
		Yew,
		Oak,
		Zircote,
		Ebony,
		Bamboo,
		PurpleHeart,
		Redwood,
		Petrified
	}

	public enum CraftResourceType
	{
		None,
		Metal,
		Leather,
		Scales,
		Wood
	}

	public class CraftAttributeInfo
	{
		private int m_WeaponFireDamage;
		private int m_WeaponColdDamage;
		private int m_WeaponPoisonDamage;
		private int m_WeaponEnergyDamage;
		private int m_WeaponDurability;
		private int m_WeaponLuck;
		private int m_WeaponGoldIncrease;
		private int m_WeaponLowerRequirements;

		private int m_ArmorPhysicalResist;
		private int m_ArmorFireResist;
		private int m_ArmorColdResist;
		private int m_ArmorPoisonResist;
		private int m_ArmorEnergyResist;
		private int m_ArmorDurability;
		private int m_ArmorLuck;
		private int m_ArmorGoldIncrease;
		private int m_ArmorLowerRequirements;

		private int m_RunicMinAttributes;
		private int m_RunicMaxAttributes;
		private int m_RunicMinIntensity;
		private int m_RunicMaxIntensity;

		public int WeaponFireDamage{ get{ return m_WeaponFireDamage; } set{ m_WeaponFireDamage = value; } }
		public int WeaponColdDamage{ get{ return m_WeaponColdDamage; } set{ m_WeaponColdDamage = value; } }
		public int WeaponPoisonDamage{ get{ return m_WeaponPoisonDamage; } set{ m_WeaponPoisonDamage = value; } }
		public int WeaponEnergyDamage{ get{ return m_WeaponEnergyDamage; } set{ m_WeaponEnergyDamage = value; } }
		public int WeaponDurability{ get{ return m_WeaponDurability; } set{ m_WeaponDurability = value; } }
		public int WeaponLuck{ get{ return m_WeaponLuck; } set{ m_WeaponLuck = value; } }
		public int WeaponGoldIncrease{ get{ return m_WeaponGoldIncrease; } set{ m_WeaponGoldIncrease = value; } }
		public int WeaponLowerRequirements{ get{ return m_WeaponLowerRequirements; } set{ m_WeaponLowerRequirements = value; } }

		public int ArmorPhysicalResist{ get{ return m_ArmorPhysicalResist; } set{ m_ArmorPhysicalResist = value; } }
		public int ArmorFireResist{ get{ return m_ArmorFireResist; } set{ m_ArmorFireResist = value; } }
		public int ArmorColdResist{ get{ return m_ArmorColdResist; } set{ m_ArmorColdResist = value; } }
		public int ArmorPoisonResist{ get{ return m_ArmorPoisonResist; } set{ m_ArmorPoisonResist = value; } }
		public int ArmorEnergyResist{ get{ return m_ArmorEnergyResist; } set{ m_ArmorEnergyResist = value; } }
		public int ArmorDurability{ get{ return m_ArmorDurability; } set{ m_ArmorDurability = value; } }
		public int ArmorLuck{ get{ return m_ArmorLuck; } set{ m_ArmorLuck = value; } }
		public int ArmorGoldIncrease{ get{ return m_ArmorGoldIncrease; } set{ m_ArmorGoldIncrease = value; } }
		public int ArmorLowerRequirements{ get{ return m_ArmorLowerRequirements; } set{ m_ArmorLowerRequirements = value; } }

		public int RunicMinAttributes{ get{ return m_RunicMinAttributes; } set{ m_RunicMinAttributes = value; } }
		public int RunicMaxAttributes{ get{ return m_RunicMaxAttributes; } set{ m_RunicMaxAttributes = value; } }
		public int RunicMinIntensity{ get{ return m_RunicMinIntensity; } set{ m_RunicMinIntensity = value; } }
		public int RunicMaxIntensity{ get{ return m_RunicMaxIntensity; } set{ m_RunicMaxIntensity = value; } }

		public CraftAttributeInfo()
		{
		}

		public static readonly CraftAttributeInfo Blank;
		public static readonly CraftAttributeInfo DullCopper, ShadowIron, Copper, Bronze, Golden, Agapite, Verite, Valorite, Volcanite, Syenite, Nitriton, Quartzite, Kyanite;
		public static readonly CraftAttributeInfo Spined, Horned, Barbed, Polar, Synthetic, DaurianL, Daemonic, Shadow, Aranak, Ethereal;
		public static readonly CraftAttributeInfo RedScales, YellowScales, BlackScales, GreenScales, WhiteScales, BlueScales, CopperScales, SilverScales, GoldScales;
		public static readonly CraftAttributeInfo Pine, Ash, Mohogany, Yew, Oak, Zircote, Ebony, Bamboo, PurpleHeart, Redwood, Petrified;

		static CraftAttributeInfo()
		{
			Blank = new CraftAttributeInfo();

			bool Uber = false;
			if (Daat99OWLTR.Ops != null)
				Uber = Daat99OWLTR.Ops[0].Setting;
			CraftAttributeInfo dullCopper = DullCopper = new CraftAttributeInfo();

			dullCopper.ArmorPhysicalResist = Uber ? 1 : Utility.Random(2);
			dullCopper.ArmorFireResist = Uber ? 1 : Utility.Random(2);
			dullCopper.ArmorColdResist = Uber ? 1 : Utility.Random(2);
			dullCopper.ArmorPoisonResist = Uber ? 1 : Utility.Random(2);
			dullCopper.ArmorEnergyResist = Uber ? 1 : Utility.Random(2);
			dullCopper.ArmorDurability = 10;
			dullCopper.WeaponDurability = 10;
			dullCopper.ArmorLowerRequirements = 5;
			dullCopper.WeaponLowerRequirements = 5;
			dullCopper.RunicMinAttributes = 1;
			dullCopper.RunicMaxAttributes = Uber ? 2 : 1;
			dullCopper.RunicMinIntensity = Uber ? 5 : 1;
			dullCopper.RunicMaxIntensity = 100;

			CraftAttributeInfo shadowIron = ShadowIron = new CraftAttributeInfo();

			shadowIron.ArmorPhysicalResist = Uber ? 2 : Utility.Random(3);
			shadowIron.ArmorFireResist = Uber ? 1 : Utility.Random(2);
			shadowIron.ArmorColdResist = Uber ? 1 : Utility.Random(2);
			shadowIron.ArmorPoisonResist = Uber ? 1 : Utility.Random(2);
			shadowIron.ArmorEnergyResist = Uber ? 1 : Utility.Random(2);
			shadowIron.ArmorDurability = 20;
			shadowIron.WeaponDurability = 20;
			shadowIron.ArmorLowerRequirements = 10;
			shadowIron.WeaponLowerRequirements = 10;
			shadowIron.WeaponColdDamage = 20;
			shadowIron.RunicMinAttributes = 1;
			shadowIron.RunicMaxAttributes = Uber ? 3 : 2;
			shadowIron.RunicMinIntensity = Uber ? 10 : 5;
			shadowIron.RunicMaxIntensity = 100;

			CraftAttributeInfo copper = Copper = new CraftAttributeInfo();

			copper.ArmorPhysicalResist = Uber ? 2 : Utility.Random(3);
			copper.ArmorFireResist = Uber ? 2 : Utility.Random(3);
			copper.ArmorColdResist = Uber ? 2 : Utility.Random(3);
			copper.ArmorPoisonResist = Uber ? 2 : Utility.Random(3);
			copper.ArmorEnergyResist = Uber ? 2 : Utility.Random(3);
			copper.ArmorDurability = 30;
			copper.WeaponDurability = 30;
			copper.ArmorLowerRequirements = 15;
			copper.WeaponLowerRequirements = 15;
			copper.WeaponPoisonDamage = 10;
			copper.WeaponEnergyDamage = 20;
			copper.RunicMinAttributes = 2;
			copper.RunicMaxAttributes = Uber ? 3 : 2;
			copper.RunicMinIntensity = Uber ? 15 : 10;
			copper.RunicMaxIntensity = 100;

			CraftAttributeInfo bronze = Bronze = new CraftAttributeInfo();

			bronze.ArmorPhysicalResist = Uber ? 2 : Utility.Random(3);
			bronze.ArmorFireResist = Uber ? 3 : Utility.Random(4);
			bronze.ArmorColdResist = Uber ? 2 : Utility.Random(3);
			bronze.ArmorPoisonResist = Uber ? 2 : Utility.Random(3);
			bronze.ArmorEnergyResist = Uber ? 2 : Utility.Random(3);
			bronze.ArmorDurability = 40;
			bronze.WeaponDurability = 40;
			bronze.ArmorLowerRequirements = 20;
			bronze.WeaponLowerRequirements = 20;
			bronze.WeaponFireDamage = 40;
			bronze.RunicMinAttributes = 1;
			bronze.RunicMaxAttributes = Uber ? 4 : 3;
			bronze.RunicMinIntensity = Uber ? 20 : 15;
			bronze.RunicMaxIntensity = 100;

			CraftAttributeInfo golden = Golden = new CraftAttributeInfo();

			golden.ArmorPhysicalResist = Uber ? 3 : Utility.Random(4);
			golden.ArmorFireResist = Uber ? 3 : Utility.Random(4);
			golden.ArmorColdResist = Uber ? 3 : Utility.Random(4);
			golden.ArmorPoisonResist = Uber ? 3 : Utility.Random(4);
			golden.ArmorEnergyResist = Uber ? 3 : Utility.Random(4);
			golden.ArmorDurability = 55;
			golden.WeaponDurability = 55;
			golden.ArmorLowerRequirements = 25;
			golden.WeaponLowerRequirements = 25;
			golden.ArmorLuck = 40;
			golden.WeaponLuck = 40;
			golden.RunicMinAttributes = 2;
			golden.RunicMaxAttributes = Uber ? 4 : 3;
			golden.RunicMinIntensity = Uber ? 25 : 20;
			golden.RunicMaxIntensity = 100;

			CraftAttributeInfo agapite = Agapite = new CraftAttributeInfo();

			agapite.ArmorPhysicalResist = Uber ? 3 : Utility.Random(4);
			agapite.ArmorFireResist = Uber ? 3 : Utility.Random(4);
			agapite.ArmorColdResist = Uber ? 4 : Utility.Random(5);
			agapite.ArmorPoisonResist = Uber ? 3 : Utility.Random(4);
			agapite.ArmorEnergyResist = Uber ? 3 : Utility.Random(4);
			agapite.ArmorDurability = 70;
			agapite.WeaponDurability = 70;
			agapite.ArmorLowerRequirements = 30;
			agapite.WeaponLowerRequirements = 30;
			agapite.WeaponColdDamage = 30;
			agapite.WeaponEnergyDamage = 20;
			agapite.RunicMinAttributes = 3;
			agapite.RunicMaxAttributes = Uber ? 5 : 3;
			agapite.RunicMinIntensity = Uber ? 30 : 25;
			agapite.RunicMaxIntensity = 100;

			CraftAttributeInfo verite = Verite = new CraftAttributeInfo();

			verite.ArmorPhysicalResist = Uber ? 4 : Utility.Random(5);
			verite.ArmorFireResist = Uber ? 4 : Utility.Random(5);
			verite.ArmorColdResist = Uber ? 4 : Utility.Random(5);
			verite.ArmorPoisonResist = Uber ? 4 : Utility.Random(5);
			verite.ArmorEnergyResist = Uber ? 4 : Utility.Random(5);
			verite.ArmorDurability = 85;
			verite.WeaponDurability = 85;
			verite.ArmorLowerRequirements = 40;
			verite.WeaponLowerRequirements = 40;
			verite.WeaponPoisonDamage = 40;
			verite.WeaponEnergyDamage = 20;
			verite.RunicMinAttributes = 2;
			verite.RunicMaxAttributes = Uber ? 5 : 4;
			verite.RunicMinIntensity = Uber ? 40 : 30;
			verite.RunicMaxIntensity = 100;

			CraftAttributeInfo valorite = Valorite = new CraftAttributeInfo();

			valorite.ArmorPhysicalResist = Uber ? 4 : Utility.Random(5);
			valorite.ArmorFireResist = Uber ? 4 : Utility.Random(5);
			valorite.ArmorColdResist = Uber ? 4 : Utility.Random(5);
			valorite.ArmorPoisonResist = Uber ? 5 : Utility.Random(6);
			valorite.ArmorEnergyResist = Uber ? 4 : Utility.Random(5);
			valorite.ArmorDurability = 100;
			valorite.WeaponDurability = 100;
			valorite.ArmorLowerRequirements = 50;
			valorite.WeaponLowerRequirements = 50;
			valorite.WeaponFireDamage = 10;
			valorite.WeaponColdDamage = 20;
			valorite.WeaponPoisonDamage = 10;
			valorite.WeaponEnergyDamage = 20;
			valorite.RunicMinAttributes = 3;
			valorite.RunicMaxAttributes = Uber ? 6 : 4;
			valorite.RunicMinIntensity = Uber ? 50 : 35;
			valorite.RunicMaxIntensity = 100;

			CraftAttributeInfo volcanite = Volcanite = new CraftAttributeInfo();

			volcanite.ArmorPhysicalResist = Uber ? 5 : Utility.Random(6);
			volcanite.ArmorFireResist = Uber ? 5 : Utility.Random(6);
			volcanite.ArmorColdResist = Uber ? 5 : Utility.Random(6);
			volcanite.ArmorPoisonResist = Uber ? 5 : Utility.Random(6);
			volcanite.ArmorEnergyResist = Uber ? 5 : Utility.Random(6);
			volcanite.ArmorDurability = 125;
			volcanite.WeaponDurability = 125;
			volcanite.ArmorLowerRequirements = 60;
			volcanite.WeaponLowerRequirements = 60;
			volcanite.WeaponFireDamage = 100;
			volcanite.RunicMinAttributes = 4;
			volcanite.RunicMaxAttributes = Uber ? 6 : 4;
			volcanite.RunicMinIntensity = Uber ? 60 : 40;
			volcanite.RunicMaxIntensity = 100;

			CraftAttributeInfo syenite = Syenite = new CraftAttributeInfo();

			syenite.ArmorPhysicalResist = Uber ? 5 : Utility.Random(6);
			syenite.ArmorFireResist = Uber ? 5 : Utility.Random(6);
			syenite.ArmorColdResist = Uber ? 5 : Utility.Random(6);
			syenite.ArmorPoisonResist = Uber ? 5 : Utility.Random(6);
			syenite.ArmorEnergyResist = Uber ? 6 : Utility.Random(7);
			syenite.ArmorDurability = 150;
			syenite.WeaponDurability = 150;
			syenite.ArmorLowerRequirements = 70;
			syenite.WeaponLowerRequirements = 70;
			syenite.WeaponColdDamage = 100;
			syenite.RunicMinAttributes = 2;
			syenite.RunicMaxAttributes = Uber ? 7 : 5;
			syenite.RunicMinIntensity = Uber ? 70 : 45;
			syenite.RunicMaxIntensity = 100;
		
			CraftAttributeInfo nitriton = Nitriton = new CraftAttributeInfo();

			nitriton.ArmorPhysicalResist = Uber ? 6 : Utility.Random(7);
			nitriton.ArmorFireResist = Uber ? 6 : Utility.Random(7);
			nitriton.ArmorColdResist = Uber ? 6 : Utility.Random(7);
			nitriton.ArmorPoisonResist = Uber ? 6 : Utility.Random(7);
			nitriton.ArmorEnergyResist = Uber ? 6 : Utility.Random(7);
			nitriton.ArmorDurability = 175;
			nitriton.WeaponDurability = 175;
			nitriton.ArmorLowerRequirements = 80;
			nitriton.WeaponLowerRequirements = 80;
			nitriton.WeaponPoisonDamage = 100;
			nitriton.RunicMinAttributes = 3;
			nitriton.RunicMaxAttributes = Uber ? 7 : 5;
			nitriton.RunicMinIntensity = Uber ? 80 : 50;
			nitriton.RunicMaxIntensity = 100;

			CraftAttributeInfo quartzite = Quartzite = new CraftAttributeInfo();

			quartzite.ArmorPhysicalResist = Uber ? 7 : Utility.Random(8);
			quartzite.ArmorFireResist = Uber ? 7 : Utility.Random(8);
			quartzite.ArmorColdResist = Uber ? 7 : Utility.Random(8);
			quartzite.ArmorPoisonResist = Uber ? 7 : Utility.Random(8);
			quartzite.ArmorEnergyResist = Uber ? 7 : Utility.Random(8);
			quartzite.ArmorDurability = 200;
			quartzite.WeaponDurability = 200;
			quartzite.ArmorLowerRequirements = 90;
			quartzite.WeaponLowerRequirements = 90;
			quartzite.WeaponEnergyDamage = 100;
			quartzite.RunicMinAttributes = 4;
			quartzite.RunicMaxAttributes = Uber ? 8 : 5;
			quartzite.RunicMinIntensity = Uber ? 90 : 55;
			quartzite.RunicMaxIntensity = 100;

			CraftAttributeInfo kyanite = Kyanite = new CraftAttributeInfo();

			kyanite.ArmorPhysicalResist = Uber ? 8 : Utility.Random(9);
			kyanite.ArmorFireResist = Uber ? 8 : Utility.Random(9);
			kyanite.ArmorColdResist = Uber ? 8 : Utility.Random(9);
			kyanite.ArmorPoisonResist = Uber ? 8 : Utility.Random(9);
			kyanite.ArmorEnergyResist = Uber ? 8 : Utility.Random(9);
			kyanite.ArmorDurability = 250;
			kyanite.WeaponDurability = 250;
			kyanite.ArmorLowerRequirements = 100;
			kyanite.WeaponLowerRequirements = 100;
			kyanite.RunicMinAttributes = 5;
			kyanite.RunicMaxAttributes = Uber ? 8 : 5;
			kyanite.RunicMinIntensity = Uber ? 100 : 60;
			kyanite.RunicMaxIntensity = 100;

			CraftAttributeInfo spined = Spined = new CraftAttributeInfo();

			spined.ArmorPhysicalResist = Uber ? 1 : Utility.Random(2);
			spined.ArmorFireResist = Uber ? 1 : Utility.Random(2);
			spined.ArmorColdResist = Uber ? 1 : Utility.Random(2);
			spined.ArmorPoisonResist = Uber ? 1 : Utility.Random(2);
			spined.ArmorEnergyResist = Uber ? 1 : Utility.Random(2);
			spined.ArmorDurability = 25;
			spined.ArmorLowerRequirements = 20;
			spined.ArmorLuck = 40;
			spined.RunicMinAttributes = 1;
			spined.RunicMaxAttributes = Uber ? 2 : 2;
			spined.RunicMinIntensity = 10;
			spined.RunicMaxIntensity = 100;

			CraftAttributeInfo horned = Horned = new CraftAttributeInfo();

			horned.ArmorPhysicalResist = Uber ? 2 : Utility.Random(3);
			horned.ArmorFireResist = Uber ? 2 : Utility.Random(3);
			horned.ArmorColdResist = Uber ? 2 : Utility.Random(3);
			horned.ArmorPoisonResist = Uber ? 2 : Utility.Random(3);
			horned.ArmorEnergyResist = Uber ? 2 : Utility.Random(3);
			horned.ArmorDurability = 50;
			horned.ArmorLowerRequirements = 30;
			horned.RunicMinAttributes = 2;
			horned.RunicMaxAttributes = Uber ? 3 : 2;
			horned.RunicMinIntensity = 20;
			horned.RunicMaxIntensity = 100;

			CraftAttributeInfo barbed = Barbed = new CraftAttributeInfo();

			barbed.ArmorPhysicalResist = Uber ? 3 : Utility.Random(4);
			barbed.ArmorFireResist = Uber ? 3 : Utility.Random(4);
			barbed.ArmorColdResist = Uber ? 3 : Utility.Random(4);
			barbed.ArmorPoisonResist = Uber ? 3 : Utility.Random(4);
			barbed.ArmorEnergyResist = Uber ? 3 : Utility.Random(4);
			barbed.ArmorDurability = 75;
			barbed.ArmorLowerRequirements = 40;
			barbed.RunicMinAttributes = 2;
			barbed.RunicMaxAttributes = Uber ? 4 : 3;
			barbed.RunicMinIntensity = 30;
			barbed.RunicMaxIntensity = 100;

			CraftAttributeInfo polar = Polar = new CraftAttributeInfo();

			polar.ArmorPhysicalResist = Uber ? 4 : Utility.Random(5);
			polar.ArmorFireResist = Uber ? 3 : Utility.Random(4);
			polar.ArmorColdResist = Uber ? 4 : Utility.Random(5);
			polar.ArmorPoisonResist = Uber ? 3 : Utility.Random(4);
			polar.ArmorEnergyResist = Uber ? 4 : Utility.Random(5);
			polar.ArmorDurability = 100;
			polar.ArmorLowerRequirements = 50;
			polar.RunicMinAttributes = 3;
			polar.RunicMaxAttributes = Uber ? 5 : 3;
			polar.RunicMinIntensity = Uber ? 40 : 35;
			polar.RunicMaxIntensity = 100;

			CraftAttributeInfo synthetic = Synthetic = new CraftAttributeInfo();

			synthetic.ArmorPhysicalResist = Uber ? 4 : Utility.Random(5);
			synthetic.ArmorFireResist = Uber ? 4 : Utility.Random(5);
			synthetic.ArmorColdResist = Uber ? 4 : Utility.Random(5);
			synthetic.ArmorPoisonResist = Uber ? 4 : Utility.Random(5);
			synthetic.ArmorEnergyResist = Uber ? 4 : Utility.Random(5);
			synthetic.ArmorLowerRequirements = 60;
			synthetic.ArmorDurability = 125;
			synthetic.RunicMinAttributes = 2;
			synthetic.RunicMaxAttributes = Uber ? 5 : 4;
			synthetic.RunicMinIntensity = Uber ? 50 : 40;
			synthetic.RunicMaxIntensity = 100;
			
			CraftAttributeInfo daurianl = DaurianL = new CraftAttributeInfo();

			daurianl.ArmorPhysicalResist = Uber ? 4 : Utility.Random(5);
			daurianl.ArmorFireResist = Uber ? 5 : Utility.Random(6);
			daurianl.ArmorColdResist = Uber ? 4 : Utility.Random(5);
			daurianl.ArmorPoisonResist = Uber ? 5 : Utility.Random(6);
			daurianl.ArmorEnergyResist = Uber ? 4 : Utility.Random(5);
			daurianl.ArmorLowerRequirements = 60;
			daurianl.ArmorDurability = 125;
			daurianl.RunicMinAttributes = 2;
			daurianl.RunicMaxAttributes = Uber ? 6 : 4;
			daurianl.RunicMinIntensity = Uber ? 60 : 40;
			daurianl.RunicMaxIntensity = 100;

			CraftAttributeInfo daemonic = Daemonic = new CraftAttributeInfo();

			daemonic.ArmorPhysicalResist = Uber ? 5 : Utility.Random(6);
			daemonic.ArmorFireResist = Uber ? 5 : Utility.Random(6);
			daemonic.ArmorColdResist = Uber ? 5 : Utility.Random(6);
			daemonic.ArmorPoisonResist = Uber ? 5 : Utility.Random(6);
			daemonic.ArmorEnergyResist = Uber ? 5 : Utility.Random(6);
			daemonic.ArmorDurability = 150;
			daemonic.ArmorLowerRequirements = 70;
			daemonic.RunicMinAttributes = 3;
			daemonic.RunicMaxAttributes = Uber ? 6 : 4;
			daemonic.RunicMinIntensity = Uber ? 70 : 45;
			daemonic.RunicMaxIntensity = 100;
			
			CraftAttributeInfo shadow = Shadow = new CraftAttributeInfo();

			shadow.ArmorPhysicalResist = Uber ? 6 : Utility.Random(7);
			shadow.ArmorFireResist = Uber ? 6 : Utility.Random(7);
			shadow.ArmorColdResist = Uber ? 6 : Utility.Random(7);
			shadow.ArmorPoisonResist = Uber ? 6 : Utility.Random(7);
			shadow.ArmorEnergyResist = Uber ? 6 : Utility.Random(7);
			shadow.ArmorDurability = 175;
			shadow.ArmorLowerRequirements = 80;
			shadow.RunicMinAttributes = 3;
			shadow.RunicMaxAttributes = Uber ? 7 : 5;
			shadow.RunicMinIntensity = Uber ? 80 : 50;
			shadow.RunicMaxIntensity = 100;
			
			CraftAttributeInfo aranak = Aranak = new CraftAttributeInfo();

			aranak.ArmorPhysicalResist = Uber ? 7 : Utility.Random(8);
			aranak.ArmorFireResist = Uber ? 7 : Utility.Random(8);
			aranak.ArmorColdResist = Uber ? 7 : Utility.Random(8);
			aranak.ArmorPoisonResist = Uber ? 7 : Utility.Random(8);
			aranak.ArmorEnergyResist = Uber ? 7 : Utility.Random(8);
			aranak.ArmorDurability = 200;
			aranak.ArmorLowerRequirements = 90;
			aranak.RunicMinAttributes = 4;
			aranak.RunicMaxAttributes = Uber ? 7 : 5;
			aranak.RunicMinIntensity = Uber ? 90 : 55;
			aranak.RunicMaxIntensity = 100;
			
			CraftAttributeInfo ethereal = Ethereal = new CraftAttributeInfo();

			ethereal.ArmorPhysicalResist = Uber ? 8 : Utility.Random(9);
			ethereal.ArmorFireResist = Uber ? 8 : Utility.Random(9);
			ethereal.ArmorColdResist = Uber ? 8 : Utility.Random(9);
			ethereal.ArmorPoisonResist = Uber ? 8 : Utility.Random(9);
			ethereal.ArmorEnergyResist = Uber ? 8 : Utility.Random(9);
			ethereal.ArmorDurability = 250;
			ethereal.ArmorLowerRequirements = 100;
			ethereal.RunicMinAttributes = 5;
			ethereal.RunicMaxAttributes = Uber ? 8 : 5;
			ethereal.RunicMinIntensity = Uber ? 100 : 60;
			ethereal.RunicMaxIntensity = 100;
			
			CraftAttributeInfo red = RedScales = new CraftAttributeInfo();

			red.ArmorFireResist = 10;
			red.ArmorColdResist = -3;

			CraftAttributeInfo yellow = YellowScales = new CraftAttributeInfo();

			yellow.ArmorPhysicalResist = -3;
			yellow.ArmorLuck = 20;

			CraftAttributeInfo black = BlackScales = new CraftAttributeInfo();

			black.ArmorPhysicalResist = 10;
			black.ArmorEnergyResist = -3;

			CraftAttributeInfo green = GreenScales = new CraftAttributeInfo();

			green.ArmorFireResist = -3;
			green.ArmorPoisonResist = 10;

			CraftAttributeInfo white = WhiteScales = new CraftAttributeInfo();

			white.ArmorPhysicalResist = -3;
			white.ArmorColdResist = 10;

			CraftAttributeInfo blue = BlueScales = new CraftAttributeInfo();

			blue.ArmorPoisonResist = -3;
			blue.ArmorEnergyResist = 10;

			CraftAttributeInfo coppers = CopperScales = new CraftAttributeInfo();

			coppers.ArmorPoisonResist = Uber ? 6 : Utility.Random(7);
			coppers.ArmorPhysicalResist = Uber ? 6 : Utility.Random(7);
			coppers.ArmorEnergyResist = Uber ? 6 : Utility.Random(7);

			CraftAttributeInfo silver = SilverScales = new CraftAttributeInfo();

			silver.ArmorColdResist = Uber ? 7 : Utility.Random(8);
			silver.ArmorEnergyResist = Uber ? 7 : Utility.Random(8);
			silver.ArmorPhysicalResist = Uber ? 7 : Utility.Random(8);

			CraftAttributeInfo gold = GoldScales = new CraftAttributeInfo();

			gold.ArmorPoisonResist = Uber ? 8 : Utility.Random(9);
			gold.ArmorColdResist = Uber ? 8 : Utility.Random(9);
			gold.ArmorPhysicalResist = Uber ? 8 : Utility.Random(9);
			gold.ArmorEnergyResist = Uber ? 8 : Utility.Random(9);
			gold.ArmorFireResist = Uber ? 8 : Utility.Random(9);
			
			CraftAttributeInfo pine = Pine = new CraftAttributeInfo();

			pine.WeaponColdDamage = 20;
			pine.WeaponDurability = 10;
			pine.WeaponLowerRequirements = 5;
			pine.RunicMinAttributes = 1;
			pine.RunicMaxAttributes = Uber ? 2 : 2;
			pine.RunicMinIntensity = Uber ? 10 : 5;
			pine.RunicMaxIntensity = 100;
			
			CraftAttributeInfo ash = Ash = new CraftAttributeInfo();

			ash.WeaponFireDamage = 40;
			ash.WeaponDurability = 25;
			ash.WeaponLowerRequirements = 10;
			ash.RunicMinAttributes = 2;
			ash.RunicMaxAttributes = Uber ? 3 : 2;
			ash.RunicMinIntensity = Uber ? 15 : 10;
			ash.RunicMaxIntensity = 100;
			
			CraftAttributeInfo mohogany = Mohogany = new CraftAttributeInfo();

			mohogany.WeaponPoisonDamage = 10;
			mohogany.WeaponEnergyDamage = 20;
			mohogany.WeaponDurability = 50;
			mohogany.WeaponLowerRequirements = 20;
			mohogany.RunicMinAttributes = 1;
			mohogany.RunicMaxAttributes = Uber ? 4 : 3;
			mohogany.RunicMinIntensity = Uber ? 20 : 15;
			mohogany.RunicMaxIntensity = 100;

			CraftAttributeInfo yew = Yew = new CraftAttributeInfo();

			yew.WeaponColdDamage = 30;
			yew.WeaponEnergyDamage = 20;
			yew.WeaponDurability = 75;
			yew.WeaponLowerRequirements = 30;
			yew.RunicMinAttributes = 2;
			yew.RunicMaxAttributes = Uber ? 5 : 3;
			yew.RunicMinIntensity = Uber ? 30 : 20;
			yew.RunicMaxIntensity = 100;

			CraftAttributeInfo oak = Oak = new CraftAttributeInfo();

			oak.WeaponPoisonDamage = 40;
			oak.WeaponEnergyDamage = 20;
			oak.WeaponDurability = 100;
			oak.WeaponLowerRequirements = 40;
			oak.RunicMinAttributes = 3;
			oak.RunicMaxAttributes = Uber ? 5 : 3;
			oak.RunicMinIntensity = Uber ? 40 : 25;
			oak.RunicMaxIntensity = 100;

			CraftAttributeInfo zircote = Zircote = new CraftAttributeInfo();

			zircote.WeaponDurability = 125;
			zircote.WeaponLowerRequirements = 50;
			zircote.WeaponFireDamage = 25;
			zircote.WeaponColdDamage = 25;
			zircote.WeaponPoisonDamage = 25;
			zircote.WeaponEnergyDamage = 25;
			zircote.RunicMinAttributes = 2;
			zircote.RunicMaxAttributes = Uber ? 6 : 4;
			zircote.RunicMinIntensity = Uber ? 50 : 30;
			zircote.RunicMaxIntensity = 100;

			CraftAttributeInfo ebony = Ebony = new CraftAttributeInfo();

			ebony.WeaponDurability = 150;
			ebony.WeaponLowerRequirements = 60;
			ebony.WeaponColdDamage = 100;
			ebony.RunicMinAttributes = 3;
			ebony.RunicMaxAttributes = Uber ? 6 : 4;
			ebony.RunicMinIntensity = Uber ? 60 : 35;
			ebony.RunicMaxIntensity = 100;
			
			CraftAttributeInfo bamboo = Bamboo = new CraftAttributeInfo();

			bamboo.WeaponDurability = 175;
			bamboo.WeaponLowerRequirements = 70;
			bamboo.WeaponEnergyDamage = 100;
			bamboo.RunicMinAttributes = 4;
			bamboo.RunicMaxAttributes = Uber ? 7 : 4;
			bamboo.RunicMinIntensity = Uber ? 70 : 40;
			bamboo.RunicMaxIntensity = 100;

			CraftAttributeInfo purpleheart = PurpleHeart = new CraftAttributeInfo();

			purpleheart.WeaponDurability = 200;
			purpleheart.WeaponLowerRequirements = 80;
			purpleheart.WeaponFireDamage = 100;
			purpleheart.RunicMinAttributes = 3;
			purpleheart.RunicMaxAttributes = Uber ? 7 : 5;
			purpleheart.RunicMinIntensity = Uber ? 80 : 50;
			purpleheart.RunicMaxIntensity = 100;

			CraftAttributeInfo redwood = Redwood = new CraftAttributeInfo();

			redwood.WeaponDurability = 225;
			redwood.WeaponLowerRequirements = 90;
			redwood.WeaponPoisonDamage = 100;
			redwood.RunicMinAttributes = 4;
			redwood.RunicMaxAttributes = Uber ? 8 : 5;
			redwood.RunicMinIntensity = Uber ? 90 : 55;
			redwood.RunicMaxIntensity = 100;

			CraftAttributeInfo petrified = Petrified = new CraftAttributeInfo();

			petrified.WeaponDurability = 250;
			petrified.WeaponLowerRequirements = 100;
			petrified.RunicMinAttributes = 5;
			petrified.RunicMaxAttributes = Uber ? 8 : 5;
			petrified.RunicMinIntensity = Uber ? 100 : 60;
			petrified.RunicMaxIntensity = 100;
		}
	}

	public class CraftResourceInfo
	{
		private int m_Hue;
		private int m_Number;
		private string m_Name;
		private CraftAttributeInfo m_AttributeInfo;
		private CraftResource m_Resource;
		private Type[] m_ResourceTypes;

		public int Hue{ get{ return m_Hue; } }
		public int Number{ get{ return m_Number; } }
		public string Name{ get{ return m_Name; } }
		public CraftAttributeInfo AttributeInfo{ get{ return m_AttributeInfo; } }
		public CraftResource Resource{ get{ return m_Resource; } }
		public Type[] ResourceTypes{ get{ return m_ResourceTypes; } }

		public CraftResourceInfo( int hue, int number, string name, CraftAttributeInfo attributeInfo, CraftResource resource, params Type[] resourceTypes )
		{
			m_Hue = hue;
			m_Number = number;
			m_Name = name;
			m_AttributeInfo = attributeInfo;
			m_Resource = resource;
			m_ResourceTypes = resourceTypes;

			for ( int i = 0; i < resourceTypes.Length; ++i )
				CraftResources.RegisterType( resourceTypes[i], resource );
		}
	}

	public class CraftResources
	{
		private static CraftResourceInfo[] m_MetalInfo = new CraftResourceInfo[]
			{
				new CraftResourceInfo( 0x000, 1053109,	"Iron",			CraftAttributeInfo.Blank,		CraftResource.Iron,				typeof( IronIngot ),		typeof( IronOre ),			typeof( Granite ) ),
				new CraftResourceInfo( 0x973, 1053108,	"Dull Copper",	CraftAttributeInfo.DullCopper,	CraftResource.DullCopper,		typeof( DullCopperIngot ),	typeof( DullCopperOre ),	typeof( DullCopperGranite ) ),
				new CraftResourceInfo( 0x966, 1053107,	"Shadow Iron",	CraftAttributeInfo.ShadowIron,	CraftResource.ShadowIron,		typeof( ShadowIronIngot ),	typeof( ShadowIronOre ),	typeof( ShadowIronGranite ) ),
				new CraftResourceInfo( 0x96D, 1053106,	"Copper",		CraftAttributeInfo.Copper,		CraftResource.Copper,			typeof( CopperIngot ),		typeof( CopperOre ),		typeof( CopperGranite ) ),
				new CraftResourceInfo( 0x972, 1053105,	"Bronze",		CraftAttributeInfo.Bronze,		CraftResource.Bronze,			typeof( BronzeIngot ),		typeof( BronzeOre ),		typeof( BronzeGranite ) ),
				new CraftResourceInfo( 0x8A5, 1053104,	"Gold",			CraftAttributeInfo.Golden,		CraftResource.Gold,				typeof( GoldIngot ),		typeof( GoldOre ),			typeof( GoldGranite ) ),
				new CraftResourceInfo( 0x979, 1053103,	"Agapite",		CraftAttributeInfo.Agapite,		CraftResource.Agapite,			typeof( AgapiteIngot ),		typeof( AgapiteOre ),		typeof( AgapiteGranite ) ),
				new CraftResourceInfo( 0x89F, 1053102,	"Verite",		CraftAttributeInfo.Verite,		CraftResource.Verite,			typeof( VeriteIngot ),		typeof( VeriteOre ),		typeof( VeriteGranite ) ),
				new CraftResourceInfo( 0x8AB, 1053101,	"Valorite",		CraftAttributeInfo.Valorite,	CraftResource.Valorite,			typeof( ValoriteIngot ),	typeof( ValoriteOre ),		typeof( ValoriteGranite ) ),
				new CraftResourceInfo( 1161,	0,		"Volcanite",		CraftAttributeInfo.Volcanite,		CraftResource.Volcanite,			typeof( VolcaniteIngot ),		typeof( VolcaniteOre ),			typeof( VolcaniteGranite ) ),
				new CraftResourceInfo( 1152,	0,		"Syenite",			CraftAttributeInfo.Syenite,			CraftResource.Syenite,				typeof( SyeniteIngot ),			typeof( SyeniteOre ),			typeof( SyeniteGranite ) ),
				new CraftResourceInfo( 1272,	0,		"Nitriton",		CraftAttributeInfo.Nitriton,		CraftResource.Nitriton,			typeof( NitritonIngot ),		typeof( NitritonOre ),			typeof( NitritonGranite ) ),
				new CraftResourceInfo( 1278,	0,		"Quartzite",		CraftAttributeInfo.Quartzite,	CraftResource.Quartzite,			typeof( QuartziteIngot ),	typeof( QuartziteOre ),		typeof( QuartziteGranite ) ),
				new CraftResourceInfo( 1153,	0,		"Kyanite",		CraftAttributeInfo.Kyanite,	CraftResource.Kyanite,			typeof( KyaniteIngot ),	typeof( KyaniteOre ),		typeof( KyaniteGranite ) ),
			};

		private static CraftResourceInfo[] m_ScaleInfo = new CraftResourceInfo[]
			{
				new CraftResourceInfo( 0x66D, 1053129,	"Red Scales",		CraftAttributeInfo.RedScales,		CraftResource.RedScales,		typeof( RedScales ) ),
				new CraftResourceInfo( 54,    1053130,	"Yellow Scales",	CraftAttributeInfo.YellowScales,	CraftResource.YellowScales,		typeof( YellowScales ) ),
				new CraftResourceInfo( 0x455, 1053131,	"Black Scales",		CraftAttributeInfo.BlackScales,		CraftResource.BlackScales,		typeof( BlackScales ) ),
				new CraftResourceInfo( 0x851, 1053132,	"Green Scales",		CraftAttributeInfo.GreenScales,		CraftResource.GreenScales,		typeof( GreenScales ) ),
				new CraftResourceInfo( 1153,  1053133,	"White Scales",		CraftAttributeInfo.WhiteScales,		CraftResource.WhiteScales,		typeof( WhiteScales ) ),
				new CraftResourceInfo( 0x8B0, 1053134,	"Blue Scales",		CraftAttributeInfo.BlueScales,		CraftResource.BlueScales,		typeof( BlueScales ) ),
				new CraftResourceInfo( 0x96D,	0,		"Copper Scales",	CraftAttributeInfo.CopperScales,	CraftResource.CopperScales,		typeof( CopperScales ) ),
				new CraftResourceInfo( 0x8FD,	0,		"Silver Scales",	CraftAttributeInfo.SilverScales,	CraftResource.SilverScales,		typeof( SilverScales ) ),
				new CraftResourceInfo( 49,  	0,		"Gold Scales",		CraftAttributeInfo.GoldScales,		CraftResource.GoldScales,		typeof( GoldScales ) ),
			};

		private static CraftResourceInfo[] m_LeatherInfo = new CraftResourceInfo[]
			{
				new CraftResourceInfo( 0x000, 1049353,		"Normal",		CraftAttributeInfo.Blank,			CraftResource.RegularLeather,	typeof( Leather ),			typeof( Hides ) ),
				new CraftResourceInfo( 0x8ac, 1049354,		"Spined",		CraftAttributeInfo.Spined,			CraftResource.SpinedLeather,	typeof( SpinedLeather ),	typeof( SpinedHides ) ),
				new CraftResourceInfo( 0x845, 1049355,		"Horned",		CraftAttributeInfo.Horned,			CraftResource.HornedLeather,	typeof( HornedLeather ),	typeof( HornedHides ) ),
				new CraftResourceInfo( 0x1C1, 1049356,		"Barbed",		CraftAttributeInfo.Barbed,			CraftResource.BarbedLeather,	typeof( BarbedLeather ),	typeof( BarbedHides ) ),
				new CraftResourceInfo( 1150,	0,			"Polar",		CraftAttributeInfo.Polar,			CraftResource.PolarLeather,		typeof( PolarLeather ),		typeof( PolarHides ) ),
				new CraftResourceInfo( 1023,	0,			"Synthetic",	CraftAttributeInfo.Synthetic,		CraftResource.SyntheticLeather,	typeof( SyntheticLeather ),	typeof( SyntheticHides ) ),
				new CraftResourceInfo( 1260,	0,			"Daurian",		CraftAttributeInfo.DaurianL,			CraftResource.DaurianLeather,		typeof( DaurianLeather ),		typeof( DaurianHides ) ),
				new CraftResourceInfo( 32,		0,			"Daemonic",		CraftAttributeInfo.Daemonic,		CraftResource.DaemonicLeather,	typeof( DaemonicLeather ),	typeof( DaemonicHides ) ),
				new CraftResourceInfo( 0x966,	0,			"Shadow",		CraftAttributeInfo.Shadow,			CraftResource.ShadowLeather,	typeof( ShadowLeather ),	typeof( ShadowHides ) ),
				new CraftResourceInfo( 93,		0,			"Aranak",		CraftAttributeInfo.Aranak,			CraftResource.AranakLeather,		typeof( AranakLeather ),		typeof( AranakHides ) ),
				new CraftResourceInfo( 1159,	0,			"Ethereal",		CraftAttributeInfo.Ethereal,		CraftResource.EtherealLeather,	typeof( EtherealLeather ),	typeof( EtherealHides ) ),
		};

		private static CraftResourceInfo[] m_AOSLeatherInfo = new CraftResourceInfo[]
			{
				new CraftResourceInfo( 0x000, 1049353,		"Normal",		CraftAttributeInfo.Blank,			CraftResource.RegularLeather,	typeof( Leather ),			typeof( Hides ) ),
				new CraftResourceInfo( 0x8ac, 1049354,		"Spined",		CraftAttributeInfo.Spined,			CraftResource.SpinedLeather,	typeof( SpinedLeather ),	typeof( SpinedHides ) ),
				new CraftResourceInfo( 0x845, 1049355, 		"Horned",		CraftAttributeInfo.Horned,			CraftResource.HornedLeather,	typeof( HornedLeather ),	typeof( HornedHides ) ),
				new CraftResourceInfo( 0x851, 1049356,		"Barbed",		CraftAttributeInfo.Barbed,			CraftResource.BarbedLeather,	typeof( BarbedLeather ),	typeof( BarbedHides ) ),
				new CraftResourceInfo( 1150,	0,			"Polar",		CraftAttributeInfo.Polar,			CraftResource.PolarLeather,		typeof( PolarLeather ),		typeof( PolarHides ) ),
				new CraftResourceInfo( 1023,	0,			"Synthetic",	CraftAttributeInfo.Synthetic,		CraftResource.SyntheticLeather,	typeof( SyntheticLeather ),	typeof( SyntheticHides ) ),
				new CraftResourceInfo( 1260,	0,			"Daurian",		CraftAttributeInfo.DaurianL,			CraftResource.DaurianLeather,		typeof( DaurianLeather ),		typeof( DaurianHides ) ),
				new CraftResourceInfo( 32,		0,			"Daemonic",		CraftAttributeInfo.Daemonic,		CraftResource.DaemonicLeather,	typeof( DaemonicLeather ),	typeof( DaemonicHides ) ),
				new CraftResourceInfo( 0x966,	0,			"Shadow",		CraftAttributeInfo.Shadow,			CraftResource.ShadowLeather,	typeof( ShadowLeather ),	typeof( ShadowHides ) ),
				new CraftResourceInfo( 93,		0,			"Aranak",		CraftAttributeInfo.Aranak,			CraftResource.AranakLeather,		typeof( AranakLeather ),		typeof( AranakHides ) ),
				new CraftResourceInfo( 1159,	0,			"Ethereal",		CraftAttributeInfo.Ethereal,		CraftResource.EtherealLeather,	typeof( EtherealLeather ),	typeof( EtherealHides ) ),
		};
		private static CraftResourceInfo[] m_WoodInfo = new CraftResourceInfo[]
			{
				new CraftResourceInfo( 0, 0,	"Log",			CraftAttributeInfo.Blank,		CraftResource.Log,			typeof( Log ) ),
				new CraftResourceInfo( 1262, 0,	"Pine",			CraftAttributeInfo.Pine,		CraftResource.Pine,			typeof( PineLog ) ),
				new CraftResourceInfo( 961,  0,	"Ash",			CraftAttributeInfo.Ash,			CraftResource.Ash,			typeof( AshLog ) ),
				new CraftResourceInfo( 355,  0,	"Mohogany",		CraftAttributeInfo.Mohogany,	CraftResource.Mohogany,		typeof( MohoganyLog ) ),
				new CraftResourceInfo( 1281, 0, "Yew",			CraftAttributeInfo.Yew,			CraftResource.Yew,			typeof( YewLog ) ),
				new CraftResourceInfo( 488,  0, "Oak",			CraftAttributeInfo.Oak,			CraftResource.Oak,			typeof( OakLog ) ),
				new CraftResourceInfo( 1271, 0, "Zircote",		CraftAttributeInfo.Zircote,		CraftResource.Zircote,		typeof( ZircoteLog ) ),
				new CraftResourceInfo( 43,   0, "Ebony",		CraftAttributeInfo.Ebony,		CraftResource.Ebony,		typeof( EbonyLog ) ),
				new CraftResourceInfo( 1152, 0,	"Bamboo",		CraftAttributeInfo.Bamboo,		CraftResource.Bamboo,		typeof( BambooLog ) ),
				new CraftResourceInfo( 114,  0, "PurpleHeart",	CraftAttributeInfo.PurpleHeart,	CraftResource.PurpleHeart,	typeof( PurpleHeartLog ) ),
				new CraftResourceInfo( 37,   0,	"Redwood",		CraftAttributeInfo.Redwood,		CraftResource.Redwood,		typeof( RedwoodLog ) ),
				new CraftResourceInfo( 1153, 0, "Petrified",	CraftAttributeInfo.Petrified,	CraftResource.Petrified,	typeof( PetrifiedLog ) ),
		};

		/// <summary>
		/// Returns true if '<paramref name="resource"/>' is None, Iron, or RegularLeather. False if otherwise.
		/// </summary>
		public static bool IsStandard( CraftResource resource )
		{
			return ( resource == CraftResource.None || resource == CraftResource.Iron || resource == CraftResource.RegularLeather );
		}

		private static Hashtable m_TypeTable;

		/// <summary>
		/// Registers that '<paramref name="resourceType"/>' uses '<paramref name="resource"/>' so that it can later be queried by <see cref="CraftResources.GetFromType"/>
		/// </summary>
		public static void RegisterType( Type resourceType, CraftResource resource )
		{
			if ( m_TypeTable == null )
				m_TypeTable = new Hashtable();

			m_TypeTable[resourceType] = resource;
		}

		/// <summary>
		/// Returns the <see cref="CraftResource"/> value for which '<paramref name="resourceType"/>' uses -or- CraftResource.None if an unregistered type was specified.
		/// </summary>
		public static CraftResource GetFromType( Type resourceType )
		{
			if ( m_TypeTable == null )
				return CraftResource.None;

			object obj = m_TypeTable[resourceType];

			if ( !(obj is CraftResource) )
				return CraftResource.None;

			return (CraftResource)obj;
		}

		/// <summary>
		/// Returns a <see cref="CraftResourceInfo"/> instance describing '<paramref name="resource"/>' -or- null if an invalid resource was specified.
		/// </summary>
		public static CraftResourceInfo GetInfo( CraftResource resource )
		{
			CraftResourceInfo[] list = null;

			switch ( GetType( resource ) )
			{
				case CraftResourceType.Metal: list = m_MetalInfo; break;
				case CraftResourceType.Leather: list = Core.AOS ? m_AOSLeatherInfo : m_LeatherInfo; break;
				case CraftResourceType.Scales: list = m_ScaleInfo; break;
				case CraftResourceType.Wood: list = m_WoodInfo; break;
			}

			if ( list != null )
			{
				int index = GetIndex( resource );

				if ( index >= 0 && index < list.Length )
					return list[index];
			}

			return null;
		}

		/// <summary>
		/// Returns a <see cref="CraftResourceType"/> value indiciating the type of '<paramref name="resource"/>'.
		/// </summary>
		public static CraftResourceType GetType( CraftResource resource )
		{
			if ( resource >= CraftResource.Iron && resource <= CraftResource.Kyanite )
				return CraftResourceType.Metal;

			if ( resource >= CraftResource.RegularLeather && resource <= CraftResource.EtherealLeather )
				return CraftResourceType.Leather;

			if ( resource >= CraftResource.RedScales && resource <= CraftResource.GoldScales )
				return CraftResourceType.Scales;

			if ( resource >= CraftResource.Log && resource <= CraftResource.Petrified )
				return CraftResourceType.Wood;

			return CraftResourceType.None;
		}

		/// <summary>
		/// Returns the first <see cref="CraftResource"/> in the series of resources for which '<paramref name="resource"/>' belongs.
		/// </summary>
		public static CraftResource GetStart( CraftResource resource )
		{
			switch ( GetType( resource ) )
			{
				case CraftResourceType.Metal: return CraftResource.Iron;
				case CraftResourceType.Leather: return CraftResource.RegularLeather;
				case CraftResourceType.Wood: return CraftResource.Log;
				case CraftResourceType.Scales: return CraftResource.RedScales;
			}

			return CraftResource.None;
		}

		/// <summary>
		/// Returns the index of '<paramref name="resource"/>' in the seriest of resources for which it belongs.
		/// </summary>
		public static int GetIndex( CraftResource resource )
		{
			CraftResource start = GetStart( resource );

			if ( start == CraftResource.None )
				return 0;

			return (int)(resource - start);
		}

		/// <summary>
		/// Returns the <see cref="CraftResourceInfo.Number"/> property of '<paramref name="resource"/>' -or- 0 if an invalid resource was specified.
		/// </summary>
		public static int GetLocalizationNumber( CraftResource resource )
		{
			CraftResourceInfo info = GetInfo( resource );

			return ( info == null ? 0 : info.Number );
		}

		/// <summary>
		/// Returns the <see cref="CraftResourceInfo.Hue"/> property of '<paramref name="resource"/>' -or- 0 if an invalid resource was specified.
		/// </summary>
		public static int GetHue( CraftResource resource )
		{
			CraftResourceInfo info = GetInfo( resource );

			return ( info == null ? 0 : info.Hue );
		}

		/// <summary>
		/// Returns the <see cref="CraftResourceInfo.Name"/> property of '<paramref name="resource"/>' -or- an empty string if the resource specified was invalid.
		/// </summary>
		public static string GetName( CraftResource resource )
		{
			CraftResourceInfo info = GetInfo( resource );

			return ( info == null ? String.Empty : info.Name );
		}

		/// <summary>
		/// Returns the <see cref="CraftResource"/> value which represents '<paramref name="info"/>' -or- CraftResource.None if unable to convert.
		/// </summary>
		public static CraftResource GetFromOreInfo( OreInfo info )
		{
			if ( info.Name.IndexOf( "Spined" ) >= 0 )
				return CraftResource.SpinedLeather;
			else if ( info.Name.IndexOf( "Horned" ) >= 0 )
				return CraftResource.HornedLeather;
			else if ( info.Name.IndexOf( "Barbed" ) >= 0 )
				return CraftResource.BarbedLeather;
			else if ( info.Name.IndexOf( "Polar" ) >= 0 )
				return CraftResource.PolarLeather;
			else if ( info.Name.IndexOf( "Synthetic" ) >= 0 )
				return CraftResource.SyntheticLeather;
			else if ( info.Name.IndexOf( "Daurian" ) >= 0 )
				return CraftResource.DaurianLeather;
			else if ( info.Name.IndexOf( "Daemonic" ) >= 0 )
				return CraftResource.DaemonicLeather;
			else if ( info.Name.IndexOf( "Shadow" ) >= 0 )
				return CraftResource.ShadowLeather;
			else if ( info.Name.IndexOf( "Aranak" ) >= 0 )
				return CraftResource.AranakLeather;
			else if ( info.Name.IndexOf( "Ethereal" ) >= 0 )
				return CraftResource.EtherealLeather;
			else if ( info.Name.IndexOf( "Leather" ) >= 0 )
				return CraftResource.RegularLeather;

			if ( info.Level == 0 )
				return CraftResource.Iron;
			else if ( info.Level == 1 )
				return CraftResource.DullCopper;
			else if ( info.Level == 2 )
				return CraftResource.ShadowIron;
			else if ( info.Level == 3 )
				return CraftResource.Copper;
			else if ( info.Level == 4 )
				return CraftResource.Bronze;
			else if ( info.Level == 5 )
				return CraftResource.Gold;
			else if ( info.Level == 6 )
				return CraftResource.Agapite;
			else if ( info.Level == 7 )
				return CraftResource.Verite;
			else if ( info.Level == 8 )
				return CraftResource.Valorite;
			else if ( info.Level == 9 )
				return CraftResource.Volcanite;
			else if ( info.Level == 10 )
				return CraftResource.Syenite;
			else if ( info.Level == 11 )
				return CraftResource.Nitriton;
			else if ( info.Level == 12 )
				return CraftResource.Quartzite;
			else if ( info.Level == 13 )
				return CraftResource.Kyanite;

			else if ( info.Level == 300 )
				return CraftResource.Log;
			else if ( info.Level == 301 )
				return CraftResource.Pine;
			else if ( info.Level == 302 )
				return CraftResource.Ash;
			else if ( info.Level == 303 )
				return CraftResource.Mohogany;
			else if ( info.Level == 304 )
				return CraftResource.Yew;
			else if ( info.Level == 305 )
				return CraftResource.Oak;
			else if ( info.Level == 306 )
				return CraftResource.Zircote;
			else if ( info.Level == 307 )
				return CraftResource.Ebony;
			else if ( info.Level == 308 )
				return CraftResource.Bamboo;
			else if ( info.Level == 309 )
				return CraftResource.PurpleHeart;
			else if ( info.Level == 310 )
				return CraftResource.Redwood;
			else if ( info.Level == 311 )
				return CraftResource.Petrified;
						
			return CraftResource.None;
		}

		/// <summary>
		/// Returns the <see cref="CraftResource"/> value which represents '<paramref name="info"/>', using '<paramref name="material"/>' to help resolve leather OreInfo instances.
		/// </summary>
		public static CraftResource GetFromOreInfo( OreInfo info, ArmorMaterialType material )
		{
			if ( material == ArmorMaterialType.Studded || material == ArmorMaterialType.Leather || material == ArmorMaterialType.Spined ||
				material == ArmorMaterialType.Horned || material == ArmorMaterialType.Barbed || material == ArmorMaterialType.Polar || 
				material == ArmorMaterialType.Synthetic || material == ArmorMaterialType.DaurianL || material == ArmorMaterialType.Daemonic ||
				material == ArmorMaterialType.Shadow || material == ArmorMaterialType.Aranak || material == ArmorMaterialType.Ethereal )
			{
				if ( info.Level == 0 )
					return CraftResource.RegularLeather;
				else if ( info.Level == 1 )
					return CraftResource.SpinedLeather;
				else if ( info.Level == 2 )
					return CraftResource.HornedLeather;
				else if ( info.Level == 3 )
					return CraftResource.BarbedLeather;
				else if ( info.Level == 4 )
					return CraftResource.PolarLeather;
				else if ( info.Level == 5 )
					return CraftResource.SyntheticLeather;
				else if ( info.Level == 6 )
					return CraftResource.DaurianLeather;
				else if ( info.Level == 7 )
					return CraftResource.DaemonicLeather;
				else if ( info.Level == 8 )
					return CraftResource.ShadowLeather;
				else if ( info.Level == 9 )
					return CraftResource.AranakLeather;
				else if ( info.Level == 10 )
					return CraftResource.EtherealLeather;

				return CraftResource.None;
			}

			return GetFromOreInfo( info );
		}
	}

	// NOTE: This class is only for compatability with very old RunUO versions.
	// No changes to it should be required for custom resources.
	public class OreInfo
	{
		public static readonly OreInfo Iron			= new OreInfo( 0, 0x000, "Iron" );
		public static readonly OreInfo DullCopper	= new OreInfo( 1, 0x973, "Dull Copper" );
		public static readonly OreInfo ShadowIron	= new OreInfo( 2, 0x966, "Shadow Iron" );
		public static readonly OreInfo Copper		= new OreInfo( 3, 0x96D, "Copper" );
		public static readonly OreInfo Bronze		= new OreInfo( 4, 0x972, "Bronze" );
		public static readonly OreInfo Gold			= new OreInfo( 5, 0x8A5, "Gold" );
		public static readonly OreInfo Agapite		= new OreInfo( 6, 0x979, "Agapite" );
		public static readonly OreInfo Verite		= new OreInfo( 7, 0x89F, "Verite" );
		public static readonly OreInfo Valorite		= new OreInfo( 8, 0x8AB, "Valorite" );
		public static readonly OreInfo Volcanite		= new OreInfo( 9, 1161,  "Volcanite" );
		public static readonly OreInfo Syenite			= new OreInfo( 10, 1152, "Syenite" );
		public static readonly OreInfo Nitriton		= new OreInfo( 11, 1272, "Nitriton" );
		public static readonly OreInfo Quartzite		= new OreInfo( 12, 1278, "Quartzite" );
		public static readonly OreInfo Kyanite		= new OreInfo( 13, 1153, "Kyanite" );
		public static readonly OreInfo Log			= new OreInfo( 300, 0, "Log" );
		public static readonly OreInfo Pine			= new OreInfo( 301, 1262, "Pine" );
		public static readonly OreInfo Ash	 		= new OreInfo( 302, 961, "Ash" );
		public static readonly OreInfo Mohogany     = new OreInfo( 303, 355, "Mohogany" );
		public static readonly OreInfo Yew        	= new OreInfo( 304, 1281, "Yew" );
		public static readonly OreInfo Oak        	= new OreInfo( 305, 488, "Oak" );
		public static readonly OreInfo Zircote     	= new OreInfo( 306, 1271, "Zircote" );
		public static readonly OreInfo Ebony        = new OreInfo( 307, 43, "Ebony" );
		public static readonly OreInfo Bamboo      	= new OreInfo( 308, 1152, "Bamboo" );
		public static readonly OreInfo PurpleHeart 	= new OreInfo( 309, 114, "PurpleHeart" );
		public static readonly OreInfo Redwood     	= new OreInfo( 310, 37, "Redwood" );
		public static readonly OreInfo Petrified    = new OreInfo( 311, 1153, "Petrified" );

		private int m_Level;
		private int m_Hue;
		private string m_Name;

		public OreInfo( int level, int hue, string name )
		{
			m_Level = level;
			m_Hue = hue;
			m_Name = name;
		}

		public int Level
		{
			get
			{
				return m_Level;
			}
		}

		public int Hue
		{
			get
			{
				return m_Hue;
			}
		}

		public string Name
		{
			get
			{
				return m_Name;
			}
		}
	}
}
BulkMaterialType.cs:
Code:
using System;
using Server;
using Server.Items;

namespace Server.Engines.BulkOrders
{
	public enum BulkMaterialType
	{
		None,
		DullCopper,
		ShadowIron,
		Copper,
		Bronze,
		Gold,
		Agapite,
		Verite,
		Valorite,
		Volcanite,
		Syenite,
		Nitriton,
		Quartzite,
		Kyanite,
		Spined,
		Horned,
		Barbed,
		Polar,
		Synthetic,
		DaurianL,
		Daemonic,
		Shadow,
		Anarak,
		Ethereal,
		Pine,
		Ash,
		Mohogany,
		Yew,
		Oak,
		Zircote,
		Ebony,
		Bamboo,
		PurpleHeart,
		Redwood,
		Petrified
	}

	public enum BulkGenericType
	{
		Iron,
		Cloth,
		Leather,
		Wood
	}

	public class BGTClassifier
	{
		public static BulkGenericType Classify( BODType deedType, Type itemType )
		{
			if ( deedType == BODType.Tailor )
			{
				if ( itemType == null || itemType.IsSubclassOf( typeof( BaseArmor ) ) || itemType.IsSubclassOf( typeof( BaseShoes ) ) )
					return BulkGenericType.Leather;

				return BulkGenericType.Cloth;
			}
			else if ( deedType == BODType.Fletcher )
				return BulkGenericType.Wood;

			return BulkGenericType.Iron;
		}
	}
}
I don't understand this!!! I checked ALL of daat99's distro scripts, and ALL of the scripts that I edited (in that list), and they all have NO references to the replaced leathers (Blaze and Frost) and ONLY references to the new leathers (Daurian and Anarak). WHAT DO I DO!? Please help!!!
Joeku is offline   Reply With Quote
Old 10-15-2005, 06:14 PM   #2 (permalink)
Account Terminated
 
Join Date: Sep 2002
Age: 26
Posts: 3,846
Send a message via ICQ to Phantom Send a message via AIM to Phantom Send a message via MSN to Phantom
Default

I don't know what to say, you missed something, otherwise it would work.
Phantom is offline   Reply With Quote
Old 10-15-2005, 06:29 PM   #3 (permalink)
 
Join Date: Aug 2004
Age: 30
Posts: 546
Default

Quote:
Originally Posted by Joeku
I don't understand this!!! I checked ALL of daat99's distro scripts, and ALL of the scripts that I edited (in that list), and they all have NO references to the replaced leathers (Blaze and Frost) and ONLY references to the new leathers (Daurian and Anarak). WHAT DO I DO!? Please help!!!
'Server.Engines.BulkOrders.BulkMaterialType' does not contain a definition for 'BlazeL'
- Error: Scripts\Engines\Craft\DefTailoring.cs: CS0246: (line 303, column 23) The type or namespace

That error tells me you possibly missed removing some code or changing it.
Memnoch is offline   Reply With Quote
Old 10-15-2005, 07:09 PM   #4 (permalink)
RunUO Forum Moderator
 
daat99's Avatar
 
Join Date: Dec 2004
Location: Israel
Age: 27
Posts: 8,163
Send a message via ICQ to daat99 Send a message via AIM to daat99
Default

To add to what memnoch said:
Quote:
- Error: Scripts\Engines\BulkOrders\Books\BOBGump.cs: CS0117: (line 196, column 12) 'Server.Engines.BulkOrders.BulkMaterialType' does not contain a definition for 'Daurian'
Take a look at your bulk material list, you don't have the new leather name in there.

P.S.
I bet that most of those problems are exactly the same as the bulkmaterial error.
__________________
I always try to help
Sometimes, I don't know how....

My Web Page
Forum Rules
-------------------------------------------------------------
Extensive OWLTR System | Token System | World Teleporters
-------------------------------------------------------------
daat99 is offline   Reply With Quote
Old 10-15-2005, 10:37 PM   #5 (permalink)
Forum Master
 
Joeku's Avatar
 
Join Date: Feb 2005
Location: ShatteredSosaria.com
Posts: 9,260
Default

OMG... wow EVERY SINGLE one of those was a spelling error! I feel like kicking myself now... I spent 3 hours trying to fix that!!! Thank you all for putting up with my stupidity

Stupid Anarak looks just like Aranak
Joeku is offline   Reply With Quote
Reply

Bookmarks


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off