ace/Source/ACE.Server/Entity/ItemProfile.cs
gmriggs f0e48b2247
refactor vendor code, add support for PropertyInt.Unique on vendors (#3566)
* add CheckUniques to EmoteType.Give

* add CheckUniques to vendor purchases

* refactor vendor code, add support for PropertyInt.Unique on vendors

* update VerifySellItems

* use existing IsValidAmount
2021-09-20 13:45:27 -04:00

25 lines
652 B
C#

namespace ACE.Server.Entity
{
public class ItemProfile
{
// original data struct
public int Amount; // sent as int, not as uint -- needs to be verified > 0
public uint ObjectGuid;
// extended server data
public uint WeenieClassId;
public int? Palette;
public double? Shade;
/// <summary>
/// If false, should be rejected as early as possible
/// </summary>
public bool IsValidAmount => Amount > 0;
public ItemProfile(int amount, uint objectGuid)
{
Amount = amount;
ObjectGuid = objectGuid;
}
}
}