Hi, I have an issue where I have added an item to the store module data/modules/scripts/gamestore/gamestore.lua - i am able to buy it and the process goes through, however the item does not appear in my store inbox. Here is some of the script
The item not working is the Addon doll
here is also the code i found relating to this in the data/modules/scripts/gamestore/init.lua
Does anybody have any idea what I am doing wrong here? Please help as I am pulling my hair out of head right now!
The item not working is the Addon doll
Lua:
-- Extras Services
{
icons = { "Category_ExtraServices.png" },
name = "Extra Services",
parent = "Extras",
rookgaard = true,
state = GameStore.States.STATE_NONE,
offers = {
{
icons = { "Temple_Teleport.png" },
name = "Addon doll",
price = 10,
itemType = 32594,
count = 1,
description = "Will give you a complete outfit. Use !addon command followed by outfit name eg. !outfit warrior.",
type = GameStore.OfferTypes.OFFER_TYPE_ITEM,
},
{
icons = { "Name_Change.png" },
name = "Character Name Change",
price = 250,
id = 65002,
description = "<i>Tired of your current character name? Purchase a new one!</i>\n\n{character}\n{info} relog required after purchase to finalise the name change",
type = GameStore.OfferTypes.OFFER_TYPE_NAMECHANGE,
},
{
icons = { "Sex_Change.png" },
name = "Character Sex Change",
price = 120,
id = 65003,
description = "<i>Turns your female character into a male one - or vice versa.</i>\n\n{character}\n{activated}\n{info} you will keep all outfits you have purchased or earned in quest",
type = GameStore.OfferTypes.OFFER_TYPE_SEXCHANGE,
},
},
},
here is also the code i found relating to this in the data/modules/scripts/gamestore/init.lua
Lua:
function GameStore.processItemPurchase(player, offerId, offerCount)
if player:getFreeCapacity() < ItemType(offerId):getWeight(offerCount) then
return error({ code = 0, message = "Please make sure you have free capacity to hold this item."})
end
local inbox = player:getSlotItem(CONST_SLOT_STORE_INBOX)
if inbox and inbox:getEmptySlots() > offerCount then
for t = 1, offerCount do
inbox:addItem(offerId, offerCount or 1)
end
else
return error({ code = 0, message = "Please make sure you have free slots in your store inbox."})
end
end
Does anybody have any idea what I am doing wrong here? Please help as I am pulling my hair out of head right now!
Last edited: