using Fantasy;
namespace Fantasy;
[AttributeUsage(AttributeTargets.Class, AllowMultiple = true,Inherited = false)]
public sealed class ItemUseAttribute : Attribute
{
public ItemUseEffect Type { get; }
public ItemUseAttribute(ItemUseEffect type)
{
Type = type;
}
}
public interface IItemUse
{
///
/// 正常的情况下,应该是使用Unit,因为这个代表的是某一个单位。
/// 由于课程中没有这个Unit,所以暂时用Account来代替。
///
///
///
///
///
uint CanUse(Account account, ItemConfig config, ref int count);
///
/// 使用物品的逻辑。
///
///
///
///
void Use(Account account, ItemConfig config, ref int count);
}