Skip to content
LeviMC
English
AutoLightDark
LeviLamina
Loading...
Searching...
No Matches
FoodItemComponentLegacy Class Reference
Inheritance diagram for FoodItemComponentLegacy:

Classes

struct  Effect

Public Types

enum class  OnUseAction : int { None = -1 , ChorusTeleport = 0 , SuspiciousStewEffect = 1 }

Public Member Functions

FoodItemComponentLegacy & operator= (FoodItemComponentLegacy const &)
 FoodItemComponentLegacy (FoodItemComponentLegacy const &)
virtual int getNutrition () const
virtual float getSaturationModifier () const
virtual bool canAlwaysEat () const
virtual::Item const * eatItem (::ItemStack &instance, ::Actor &actor, ::Level &level)
virtual void use (::ItemOnUseResult &result, ::ItemStack &instance, ::Player &player, ::HandSlot handSlot)
virtual::Item const * useTimeDepleted (::ItemUseMethod &itemUseMethod, ::ItemStack const &, ::ItemStack &instance, ::Player &player, ::Level &level)
MCAPI void _applyEatEffects (::ItemStack const &, ::Actor &actor, ::Level &level)
MCAPI ::std::unique_ptr<::CompoundTag > buildNetworkTag () const
MCAPI bool init (::Json::Value const &data, ::MolangVersion)
MCAPI int $getNutrition () const
MCAPI float $getSaturationModifier () const
MCAPI bool $canAlwaysEat () const
MCAPI::Item const * $eatItem (::ItemStack &instance, ::Actor &actor, ::Level &level)
MCAPI void $use (::ItemOnUseResult &result, ::ItemStack &instance, ::Player &player, ::HandSlot handSlot)
MCAPI::Item const * $useTimeDepleted (::ItemUseMethod &itemUseMethod, ::ItemStack const &, ::ItemStack &instance, ::Player &player, ::Level &level)

Static Public Member Functions

static MCAPI ::Json::Value initializeFromNetwork (::CompoundTag const &tag)
static MCAPI void ** $vftable ()
static MCAPI ::std::add_lvalue_reference_t< char const[15]> CAN_ALWAYS_EAT ()
static MCAPI ::std::add_lvalue_reference_t< char const[10]> NUTRITION ()
static MCAPI ::std::add_lvalue_reference_t< char const[20]> SATURATION_MODIFIER ()

Public Attributes

::ll::TypedStorage< 8, 8, ::Item & > mOwner
::ll::TypedStorage< 4, 4, int > mNutrition
::ll::TypedStorage< 4, 4, float > mSaturationModifier
::ll::TypedStorage< 8, 32, ::std::string > mUsingConvertsTo
::ll::TypedStorage< 4, 4, ::FoodItemComponentLegacy::OnUseAction > mOnUseAction
::ll::TypedStorage< 4, 12, ::Vec3 > mOnUseRange
::ll::TypedStorage< 8, 48, ::HashedString > mCooldownCategory
::ll::TypedStorage< 4, 4, int > mCooldownDuration
::ll::TypedStorage< 1, 1, bool > mCanAlwaysEat
::ll::TypedStorage< 8, 24, ::std::vector<::FoodItemComponentLegacy::Effect > > mEffects
::ll::TypedStorage< 8, 24, ::std::vector< uint > > mRemoveEffects

Member Function Documentation

◆ getNutrition()

virtual int FoodItemComponentLegacy::getNutrition ( ) const
virtual

Implements IFoodItemComponent.

◆ getSaturationModifier()

virtual float FoodItemComponentLegacy::getSaturationModifier ( ) const
virtual

Implements IFoodItemComponent.

◆ canAlwaysEat()

virtual bool FoodItemComponentLegacy::canAlwaysEat ( ) const
virtual

Implements IFoodItemComponent.

◆ eatItem()

virtual::Item const * FoodItemComponentLegacy::eatItem ( ::ItemStack & instance,
::Actor & actor,
::Level & level )
virtual

Implements IFoodItemComponent.

◆ use()

virtual void FoodItemComponentLegacy::use ( ::ItemOnUseResult & result,
::ItemStack & instance,
::Player & player,
::HandSlot handSlot )
virtual

Implements IFoodItemComponent.

◆ useTimeDepleted()

virtual::Item const * FoodItemComponentLegacy::useTimeDepleted ( ::ItemUseMethod & itemUseMethod,
::ItemStack const & ,
::ItemStack & instance,
::Player & player,
::Level & level )
virtual

Implements IFoodItemComponent.

◆ _applyEatEffects()

MCAPI void FoodItemComponentLegacy::_applyEatEffects ( ::ItemStack const & ,
::Actor & actor,
::Level & level )
Attention
This function is not yet publicly available. To request access: reference this function in your code and attempt to link. The linker will report the exact symbol name. Submit a access request at https://github.com/LiteLDev/mcapi-requests/issues/new including the full symbol name.

◆ buildNetworkTag()

MCAPI ::std::unique_ptr<::CompoundTag > FoodItemComponentLegacy::buildNetworkTag ( ) const
Attention
This function is not yet publicly available. To request access: reference this function in your code and attempt to link. The linker will report the exact symbol name. Submit a access request at https://github.com/LiteLDev/mcapi-requests/issues/new including the full symbol name.

◆ init()

MCAPI bool FoodItemComponentLegacy::init ( ::Json::Value const & data,
::MolangVersion  )
Attention
This function is not yet publicly available. To request access: reference this function in your code and attempt to link. The linker will report the exact symbol name. Submit a access request at https://github.com/LiteLDev/mcapi-requests/issues/new including the full symbol name.

◆ initializeFromNetwork()

MCAPI ::Json::Value FoodItemComponentLegacy::initializeFromNetwork ( ::CompoundTag const & tag)
static
Attention
This function is not yet publicly available. To request access: reference this function in your code and attempt to link. The linker will report the exact symbol name. Submit a access request at https://github.com/LiteLDev/mcapi-requests/issues/new including the full symbol name.

◆ $getNutrition()

MCAPI int FoodItemComponentLegacy::$getNutrition ( ) const
Attention
This function is not yet publicly available. To request access: reference this function in your code and attempt to link. The linker will report the exact symbol name. Submit a access request at https://github.com/LiteLDev/mcapi-requests/issues/new including the full symbol name.

◆ $getSaturationModifier()

MCAPI float FoodItemComponentLegacy::$getSaturationModifier ( ) const
Attention
This function is not yet publicly available. To request access: reference this function in your code and attempt to link. The linker will report the exact symbol name. Submit a access request at https://github.com/LiteLDev/mcapi-requests/issues/new including the full symbol name.

◆ $canAlwaysEat()

MCAPI bool FoodItemComponentLegacy::$canAlwaysEat ( ) const
Attention
This function is not yet publicly available. To request access: reference this function in your code and attempt to link. The linker will report the exact symbol name. Submit a access request at https://github.com/LiteLDev/mcapi-requests/issues/new including the full symbol name.

◆ $useTimeDepleted()

MCAPI::Item const * FoodItemComponentLegacy::$useTimeDepleted ( ::ItemUseMethod & itemUseMethod,
::ItemStack const & ,
::ItemStack & instance,
::Player & player,
::Level & level )
Attention
This function is not yet publicly available. To request access: reference this function in your code and attempt to link. The linker will report the exact symbol name. Submit a access request at https://github.com/LiteLDev/mcapi-requests/issues/new including the full symbol name.

◆ $vftable()

MCAPI void ** FoodItemComponentLegacy::$vftable ( )
static
Attention
This function is not yet publicly available. To request access: reference this function in your code and attempt to link. The linker will report the exact symbol name. Submit a access request at https://github.com/LiteLDev/mcapi-requests/issues/new including the full symbol name.

◆ CAN_ALWAYS_EAT()

MCAPI ::std::add_lvalue_reference_t< char const [15]> IFoodItemComponent::CAN_ALWAYS_EAT ( )
staticinherited
Attention
This function is not yet publicly available. To request access: reference this function in your code and attempt to link. The linker will report the exact symbol name. Submit a access request at https://github.com/LiteLDev/mcapi-requests/issues/new including the full symbol name.

◆ NUTRITION()

MCAPI ::std::add_lvalue_reference_t< char const [10]> IFoodItemComponent::NUTRITION ( )
staticinherited
Attention
This function is not yet publicly available. To request access: reference this function in your code and attempt to link. The linker will report the exact symbol name. Submit a access request at https://github.com/LiteLDev/mcapi-requests/issues/new including the full symbol name.

◆ SATURATION_MODIFIER()

MCAPI ::std::add_lvalue_reference_t< char const [20]> IFoodItemComponent::SATURATION_MODIFIER ( )
staticinherited
Attention
This function is not yet publicly available. To request access: reference this function in your code and attempt to link. The linker will report the exact symbol name. Submit a access request at https://github.com/LiteLDev/mcapi-requests/issues/new including the full symbol name.

The documentation for this class was generated from the following file: