1
Fork 0
mirror of https://github.com/SapphireServer/Sapphire.git synced 2025-05-09 04:07:46 +00:00
sapphire/src/world/Manager/ShopMgr.h

20 lines
No EOL
592 B
C++

#pragma once
#include "ForwardsZone.h"
namespace Sapphire::World::Manager
{
class ShopMgr
{
private:
std::unordered_map< uint32_t, std::array< uint32_t, 40 > > m_shopItemPrices;
void cacheShop( uint32_t shopId );
public:
ShopMgr() = default;
uint32_t getShopItemPrices( uint32_t shopId, uint8_t index );
bool purchaseGilShopItem( Sapphire::Entity::Player& player, uint32_t shopId, uint16_t itemId, uint32_t quantity );
bool sellGilShopItem( Sapphire::Entity::Player & player, uint16_t container, uint8_t fromSlot, uint16_t item, uint32_t quantity );
};
}