ubentobox
Member
Hey there,
I am trying to get a dishing stump to work as a tool for defAlchemy using this post as an example, but having a few hangups and any help would be appreciated.
- The dishing stump should either not wear out at all or last for several hundred uses.
- Currently it allows the Alchemy gump when standing next to it, however when clicking OK to craft the desired item it still wants the dishing stump in the backpack.
I am trying to get a dishing stump to work as a tool for defAlchemy using this post as an example, but having a few hangups and any help would be appreciated.
- The dishing stump should either not wear out at all or last for several hundred uses.
- Currently it allows the Alchemy gump when standing next to it, however when clicking OK to craft the desired item it still wants the dishing stump in the backpack.
Dishing Stump:
using System;
using Server.Network;
using Server.Engines.Craft;
namespace Server.Items
{
[FlipableAttribute( 0x1865, 0x1866 )]
public class DishingStump : Item
{
public override CraftSystem CraftSystem {get {return DefAlchemy.CraftSystem;} }
public override void OnDoubleClick(Mobile from)
{
if ((from.InRange(this, 2) && from.CanSee(this)) || IsChildOf(from.Backpack) || Parent == from)
{
CraftSystem system = CraftSystem;
int num = system.CanCraft(from, this, null);
{
CraftContext context = system.GetContext(from);
from.SendGump(new CraftGump(from, system, this, null));
}
}
else
{
from.SendMessage("This must be in your pack or 1 tile away for you to use it.");
}
}
[Constructable]
public DishingStump() : base( 0x1865 )
{
Name = "Dishing Stump";
Weight = 10.0;
}
public DishingStump( 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();
}
}
}