LeviLamina
Loading...
Searching...
No Matches
IConstBlockSource.h
1#pragma once
2
3#include "mc/_HeaderOutputPredefine.h"
4
5// auto generated inclusion list
6#include "mc/deps/core/utility/AutomaticID.h"
7#include "mc/deps/core/utility/optional_ref.h"
8#include "mc/world/level/material/MaterialType.h"
9
10// auto generated forward declare list
11// clang-format off
12class AABB;
13class Block;
14class BlockActor;
15class BlockPos;
16class Dimension;
18class LevelChunk;
19class Material;
20class Vec3;
21struct Bounds;
22namespace BlockSourceVisitor { struct CollisionShape; }
23// clang-format on
24
26public:
27 // virtual functions
28 // NOLINTBEGIN
29 virtual ~IConstBlockSource() = default;
30
31 virtual ::Block const& getBlock(::BlockPos const&) const = 0;
32
33 virtual ::Block const& getBlock(::BlockPos const&, uint) const = 0;
34
35 virtual ::BlockActor const* getBlockEntity(::BlockPos const&) const = 0;
36
37 virtual ::Block const& getExtraBlock(::BlockPos const&) const = 0;
38
39 virtual ::Block const& getLiquidBlock(::BlockPos const&) const = 0;
40
41 virtual bool hasBlock(::BlockPos const&) const = 0;
42
43 virtual bool containsAnyLiquid(::AABB const&) const = 0;
44
45 virtual bool containsMaterial(::AABB const&, ::MaterialType) const = 0;
46
47 virtual bool isInWall(::Vec3 const&) const = 0;
48
49 virtual bool isUnderWater(::BlockPos const&, ::Block const&) const = 0;
50
51 virtual ::Material const& getMaterial(::BlockPos const&) const = 0;
52
53 virtual ::Material const& getMaterial(int, int, int) const = 0;
54
55 virtual bool hasBorderBlock(::BlockPos const) const = 0;
56
57 virtual bool hasChunksAt(::Bounds const&, bool) const = 0;
58
59 virtual bool hasChunksAt(::BlockPos const&, int, bool) const = 0;
60
61 virtual bool hasChunksAt(::AABB const&, bool) const = 0;
62
63 virtual ::DimensionType getDimensionId() const = 0;
64
65 virtual bool shouldFireEvents(::LevelChunk const&) const = 0;
66
67 virtual void fetchAABBs(::std::vector<::AABB>&, ::AABB const&, bool) const = 0;
68
69 virtual void fetchCollisionShapes(
70 ::std::vector<::AABB>&,
71 ::AABB const&,
72 bool,
74 ::std::vector<::AABB>*
75 ) const = 0;
76
77 virtual void fetchCollisionShapesAndBlocks(
78 ::std::vector<::BlockSourceVisitor::CollisionShape>&,
79 ::AABB const&,
80 bool,
82 ::std::vector<::AABB>*
83 ) const = 0;
84
85 virtual ::AABB
86 getTallestCollisionShape(::AABB const&, float*, bool, ::optional_ref<::GetCollisionShapeInterface const>) const = 0;
87
88 virtual float getBrightness(::BlockPos const&) const = 0;
89 // NOLINTEND
90
91public:
92 // virtual function thunks
93 // NOLINTBEGIN
94
95 // NOLINTEND
96};
Definition AABB.h:18
Definition BlockActor.h:32
Definition BlockPos.h:19
Definition Block.h:43
Definition Dimension.h:85
Definition GetCollisionShapeInterface.h:13
Definition IConstBlockSource.h:25
Definition LevelChunk.h:79
Definition Material.h:8
Definition Vec3.h:10
Definition optional_ref.h:10
Definition CollisionShape.h:16
Definition Bounds.h:8