Struct WfItemDef

ClassList > WfItemDef

Public Attributes

Type Name
const char * UISpriteName
sprite shown in UI menus
bool bCanUseItem
CAN this item be used at all?
bool bSoundEffectOnPickup
do we play a sound effect when we pick it up
OnPushGameLayerItemFnItemFn onGameLayerPop
called when the game layer is popped.
OnPushGameLayerItemFnItemFn onGameLayerPush
called when the game layer is pushed.
OnMakeItemCurrentFn onMakeCurrent
the item is selected for use
OnStopBeingCurrentItemFn onStopBeingCurrent
player switches to another item in their inventory
TryEquipFn onTryEquip
This isn't used yet, it is for when the player will try to equip a wearable item in their inventory menu.
enum WfActionAnimation onUseAnimation
The animation applied to the player when the item is used.
OnUseItemFn onUseItem
The player tries to use the item while playing.
void * pUserData
pretty much pointless
const char * pickupSpriteName
the name of the sprite for the item as it appears in the world as an object that can be picked up
struct ZZFXSound zzfxPickup
zzfx sound effect to play (will be union with a wav sound effect in future)

Public Attributes Documentation

variable UISpriteName

sprite shown in UI menus

const char* WfItemDef::UISpriteName;

variable bCanUseItem

CAN this item be used at all?

bool WfItemDef::bCanUseItem;

variable bSoundEffectOnPickup

do we play a sound effect when we pick it up

bool WfItemDef::bSoundEffectOnPickup;

variable onGameLayerPop

called when the game layer is popped.

OnPushGameLayerItemFnItemFn WfItemDef::onGameLayerPop;

variable onGameLayerPush

called when the game layer is pushed.

OnPushGameLayerItemFnItemFn WfItemDef::onGameLayerPush;

variable onMakeCurrent

the item is selected for use

OnMakeItemCurrentFn WfItemDef::onMakeCurrent;

variable onStopBeingCurrent

player switches to another item in their inventory

OnStopBeingCurrentItemFn WfItemDef::onStopBeingCurrent;

variable onTryEquip

This isn't used yet, it is for when the player will try to equip a wearable item in their inventory menu.

TryEquipFn WfItemDef::onTryEquip;

variable onUseAnimation

The animation applied to the player when the item is used.

enum WfActionAnimation WfItemDef::onUseAnimation;

variable onUseItem

The player tries to use the item while playing.

OnUseItemFn WfItemDef::onUseItem;

variable pUserData

pretty much pointless

void* WfItemDef::pUserData;

variable pickupSpriteName

the name of the sprite for the item as it appears in the world as an object that can be picked up

const char* WfItemDef::pickupSpriteName;

variable zzfxPickup

zzfx sound effect to play (will be union with a wav sound effect in future)

struct ZZFXSound WfItemDef::zzfxPickup;


The documentation for this class was generated from the following file /home/runner/work/2DFarmingRPG/2DFarmingRPG/Stardew/game/include/WfItem.h