case BUYITEM_MENU:
{
char BuyItem[100];
objmgr.CreateGossipMenuForPlayer(&Menu, pObject->GetGUID(), 1, Plr);
sprintf(BuyItem, "Enter Item Name [%u]", MORPH_COST/DIVIDER);
Menu->AddItem(ICON_WHEEL, BuyItem, BUYITEM_FUNCTION, 1);
Menu->SendTo(Plr);
}break;
case BUYITEM_FUNCTION:
{
QueryResult *BoughtItem = WorldDatabase.Query("Select `Entry` FROM Tiberium_Items where `Name` = '%s'", Code);
if(BoughtItem)
{
Field *Fields = BoughtItem->Fetch();
uint32 BoughtItem = Fields[0].GetUInt32();
Plr->GetItemInterface()->AddItemToFreeSlot(BoughtItem);
Plr->Gossip_Complete();
}
}break;
---------------------------------------------------------------------------------------------------------------------------------------
This is only a tad bit of my script i would rather not post all of it but i am getting this error
---------------------------------------------------------------------------------------------------------------------------------------
1>Compiling...
1>Warper.cpp
1>..\src\GossipScripts\Warper.cpp(142) : error C2664: 'ItemInterface::AddItemToFreeSlot' : cannot convert parameter 1 from 'uint32' to 'Item *'
1> Conversion from integral type to pointer type requires reinterpret_cast, C-style cast or function-style cast
---------------------------------------------------------------------------------------------------------------------------------------
I can't figure it out the function is to type the name of the item into a box and you get the item i got the idea from the aspire stones morpher but i failed like usual.
Im i'm pretty sure i am posting this in the C++ section if this is in EMu Server guides i apologize LOL