LeviLamina
Loading...
Searching...
No Matches
SaplingBlock.h
1#pragma once
2
3#include "mc/_HeaderOutputPredefine.h"
4
5// auto generated inclusion list
6#include "mc/world/item/FertilizerType.h"
7#include "mc/world/level/block/FoliageBlock.h"
8
9// auto generated forward declare list
10// clang-format off
11class Actor;
12class Block;
13class BlockPos;
14class BlockSource;
15namespace BlockEvents { class BlockRandomTickEvent; }
16// clang-format on
17
18class SaplingBlock : public ::FoliageBlock {
19public:
20 // member variables
21 // NOLINTBEGIN
22 ::ll::TypedStorage<8, 40, ::std::optional<::std::string>> mSingleSaplingTree;
23 ::ll::TypedStorage<8, 40, ::std::optional<::std::string>> mSingleSaplingTreeWithBeehive;
24 ::ll::TypedStorage<8, 40, ::std::optional<::std::string>> mQuadrupleSaplingTree;
25 // NOLINTEND
26
27public:
28 // prevent constructor by default
29 SaplingBlock();
30
31public:
32 // virtual functions
33 // NOLINTBEGIN
34 virtual bool mayPlace(::BlockSource& region, ::BlockPos const& pos) const /*override*/;
35
36 virtual bool
37 onFertilized(::BlockSource& region, ::BlockPos const& pos, ::Actor* actor, ::FertilizerType fertilizerType) const
38 /*override*/;
39
40 virtual bool canBeFertilized(::BlockSource& region, ::BlockPos const& pos, ::Block const& aboveBlock) const
41 /*override*/;
42 // NOLINTEND
43
44public:
45 // member functions
46 // NOLINTBEGIN
47 MCAPI SaplingBlock(
48 ::std::string const& nameId,
49 int id,
50 ::std::optional<::std::string> singleSaplingTree,
51 ::std::optional<::std::string> singleSaplingTreeWithBeehive,
52 ::std::optional<::std::string> quadrupleSaplingTree
53 );
54
55 MCAPI ::std::optional<::BlockPos>
56 _getQuadrupleSaplingOffset(::BlockSource const& region, ::BlockPos const& pos) const;
57
58 MCAPI void randomTick(::BlockEvents::BlockRandomTickEvent& eventData) const;
59 // NOLINTEND
60
61public:
62 // constructor thunks
63 // NOLINTBEGIN
64 MCAPI void* $ctor(
65 ::std::string const& nameId,
66 int id,
67 ::std::optional<::std::string> singleSaplingTree,
68 ::std::optional<::std::string> singleSaplingTreeWithBeehive,
69 ::std::optional<::std::string> quadrupleSaplingTree
70 );
71 // NOLINTEND
72
73public:
74 // virtual function thunks
75 // NOLINTBEGIN
76 MCFOLD bool $mayPlace(::BlockSource& region, ::BlockPos const& pos) const;
77
78 MCAPI bool
79 $onFertilized(::BlockSource& region, ::BlockPos const& pos, ::Actor* actor, ::FertilizerType fertilizerType) const;
80
81 MCFOLD bool $canBeFertilized(::BlockSource& region, ::BlockPos const& pos, ::Block const& aboveBlock) const;
82
83
84 // NOLINTEND
85};
Definition Actor.h:113
Definition BlockRandomTickEvent.h:16
Definition BlockPos.h:17
Definition BlockSource.h:71
Definition Block.h:41
Definition FoliageBlock.h:21