Exemplo n.º 1
0
void ItemPromptUse()
{
    // Grab the current item selected by the user with the mouse
    CItem *pItem = g_Menu.GetSelectedItem();

    // We want to check first to see if the item is equipment or just
    // a normal item.  If it's not a normal item, let's equip it.
    if(pItem->GetItemType() != kItem)
        g_Player.SetEquipment(pItem, pItem->GetItemType());

    // Regardless of if the item is equipment or not, we still need to
    // apply it's stats to the player's stats.
    g_Player.UseItem(pItem);
}
Exemplo n.º 2
0
DWORD mcmGetItemType(HANDLE hObj)
{
	ASSERT(hObj);
	CItem *pItem = (CItem *)hObj;
	return pItem->GetItemType();
}