An item's definition: its price, type, who can equip it, its bonuses and unleash, its effects and the action it is used for. More...
#include <game/item.h>
Data Fields | |
| s16 | price |
| coins | |
| u8 | type |
| enum ItemType; 0 for an item that is not equipment | |
| u8 | flags |
| enum ItemFlags | |
| u16 | equipMask |
| one bit per character that can equip it, bit 0 Isaac | |
| u16 | icon |
| indexes gUiIcon_ItemIconPointers | |
| s16 | primaryBonus |
| Attack added while equipped. | |
| s8 | secondaryBonus |
| Defense added while equipped. | |
| u8 | unleashChance |
| in steps of 5 percent | |
| u8 | useType |
| what using it costs (ITEM_USE_), or 0 for nothing | |
| u8 | reserved0d |
| not named by TBS code | |
| u16 | unleashAction |
| the action a weapon unleashes, or 0 | |
| u8 | reserved10 [4] |
| not named by TBS code | |
| s32 | element |
| a weapon's attack element; 4 for none | |
| struct ItemEffect | effects [4] |
| what it does while equipped | |
| u16 | actionId |
| the ability used, or taught as Psynergy | |
| u8 | reserved2a [2] |
| not named by TBS code | |
An item's definition: its price, type, who can equip it, its bonuses and unleash, its effects and the action it is used for.
| s16 ItemDefinition::price |
coins
Definition at line 105 of file item.h.
Referenced by Shop_BuyDone(), Shop_DrawStock(), Shop_RepairPrice(), Shop_SalePrice(), Shop_SelectBuy(), and Shop_SelectBuyNum().
| u8 ItemDefinition::type |
enum ItemType; 0 for an item that is not equipment
Definition at line 106 of file item.h.
Referenced by BattleCommand_BuildPlan(), GomaCaveEntrance_GiveShamansRod(), Inventory_Equip(), Inventory_FindEquipped(), Inventory_GetEquippedDefinition(), Inventory_GetEquippedItem(), InventoryMenu_SortByListOrder(), InventorySnapshot_Save(), Item_ClassifyUseAbility(), Item_ClassifyUseMode(), Item_GetEquipmentGroup(), ItemMenu_BuildCommands(), ItemMenu_DrawEquipPage(), ItemMenu_DrawItemDetails(), Shop_BuyDone(), Shop_ConfirmEquip(), Shop_DrawEquipComparison(), and Shop_RepairItem().
| u8 ItemDefinition::flags |
enum ItemFlags
Definition at line 107 of file item.h.
Referenced by BattleCommand_BuildPlan(), BattleSpoils_RankItem(), BattleUnit_ResetStateByMode(), GomaCaveEntrance_GiveShamansRod(), Inventory_AddItem(), Inventory_CheckDiscard(), Inventory_CountItem(), Inventory_Equip(), ItemIcon_Compose(), ItemMenu_BuildCommands(), ItemMenu_DrawItemDetails(), ItemMenu_RunCommands(), Shop_ConfirmEquip(), Shop_RepairItem(), Shop_SelectBuyNum(), Shop_SelectSellNum(), Shop_SellItem(), and UnitCalc().
| u16 ItemDefinition::equipMask |
one bit per character that can equip it, bit 0 Isaac
Definition at line 108 of file item.h.
Referenced by Item_CanOwnerEquipDirect().
| u16 ItemDefinition::icon |
indexes gUiIcon_ItemIconPointers
Definition at line 109 of file item.h.
Referenced by ItemIcon_Compose(), Shop_DrawUnitItem(), Ui_BuildPatternToSlot(), Ui_PrepareTransferForItem(), and UiGlyph_LoadEntryWithPalette().
| s16 ItemDefinition::primaryBonus |
Attack added while equipped.
Definition at line 110 of file item.h.
Referenced by ItemMenu_DrawItemDetails(), and UnitCalc().
| s8 ItemDefinition::secondaryBonus |
Defense added while equipped.
Definition at line 111 of file item.h.
Referenced by ItemMenu_DrawItemDetails(), and UnitCalc().
| u8 ItemDefinition::unleashChance |
| u8 ItemDefinition::useType |
what using it costs (ITEM_USE_), or 0 for nothing
Definition at line 113 of file item.h.
Referenced by BattleCommand_BuildPlan(), BattleCommand_SelectAutomatic(), BattlePres_RunItem(), GomaCaveEntrance_GiveShamansRod(), Item_ClassifyUseAbility(), Item_ClassifyUseMode(), Item_Use(), ItemMenu_DrawItemDetails(), ItemMenu_TryBreak(), Shop_RepairItem(), and Unit_RefreshPsynergy().
| u16 ItemDefinition::unleashAction |
the action a weapon unleashes, or 0
Definition at line 115 of file item.h.
Referenced by RollWeaponUnleash().
| s32 ItemDefinition::element |
a weapon's attack element; 4 for none
Definition at line 118 of file item.h.
Referenced by Item_GetEquippedElement(), and ItemMenu_DrawEquipPage().
| struct ItemEffect ItemDefinition::effects[4] |
what it does while equipped
Definition at line 119 of file item.h.
Referenced by Equipment_GetUnleashRateBonus(), GameFlag_RefreshLureCap(), ItemMenu_DrawItemDetails(), and UnitCalc().
| u16 ItemDefinition::actionId |
the ability used, or taught as Psynergy
Definition at line 120 of file item.h.
Referenced by Battle_CollectPartyCommands(), BattleCommand_BuildPlan(), BattleCommand_SelectAutomatic(), Field_UseItem(), Item_ClassifyUseAbility(), Item_ClassifyUseMode(), Item_Use(), and Unit_RefreshPsynergy().