Once you click "Ok" on the vending dialog nothing happens. I'm fairly sure(101%) that vending is fully coded inside the source just cant seem to find the problem.
here is my StartVending() method:
Code:
public bool StartVending(uint lParam) { if (m_IsVending) return false; Dictionary<uint, INpc> npcs; if (Kernel.Npcs.TryGetValue(Owner.Entity.MapID, out npcs)) { ushort vendx = (ushort)(Owner.Entity.X - 2); ushort vendy = Owner.Entity.Y; foreach (INpc npc in npcs.Values) { if (npc.X == vendx && npc.Y == vendy && !npc.IsVendor) { m_VendorNpc = npc; m_VendorNpc.ConvertToVendor(Owner.Entity.Name); m_VendorNpc.UID = lParam; PacketKernel.SendRangedPacket(1036, vendx, vendy, ((NpcSpawnPacket)m_VendorNpc).Packet); VendingItems = new Dictionary<uint, VendingItem>(); m_IsVending = true; break; } } } return m_IsVending; }