Skip to content
LeviMC
English
AutoLightDark
LeviLamina
Loading...
Searching...
No Matches
Facing.h
1#pragma once
2
3#include "mc/_HeaderOutputPredefine.h"
4
5// auto generated inclusion list
6#include "mc/legacy/facing/Name.h"
7#include "mc/legacy/facing/Rotation.h"
8
9// auto generated forward declare list
10// clang-format off
11class BlockPos;
12class Matrix;
13class Random;
14class Vec2;
15class Vec3;
16namespace Facing { class StringMap; }
17// clang-format on
18
19namespace Facing {
20// functions
21// NOLINTBEGIN
22MCNAPI uchar computeRotatedFacingID(::Matrix const& transformMatrix, uchar originalFacingID);
23
24MCNAPI uchar fromVec3(::Vec3 const& dir);
25
26MCNAPI ::std::vector<uchar>
27getMostPrioritizedFacingDirection(::Vec2 const& viewVector, uchar clickedFace, bool isReplacingABlock);
28
29MCNAPI ::std::array<uchar, 6> getMostPrioritizedFacingDirectionFromViewVector(::Vec2 const& viewVector);
30
31MCNAPI ::glm::mat3x3 getRotationMatrix(uchar facing, ::Facing::Rotation rotation);
32
33MCNAPI ::std::array<uchar, 6> getShuffledDirections(::Random& random);
34
35MCNAPI uchar rotateFaceAroundGivenFace(uchar faceToRotate, uchar faceToRotateAround, ::Facing::Rotation rotation);
36// NOLINTEND
37
38// static variables
39// NOLINTBEGIN
40MCNAPI ::std::array<::std::array<uchar, 5>, 6> const& ALL_EXCEPT();
41
42MCNAPI ::std::array<uchar, 6> const& ALL_FACES();
43
44MCNAPI ::std::array<::Facing::Name, 4> const& BY2DDATA();
45
46MCAPI ::std::array<::BlockPos, 6> const& DIRECTION();
47
48MCNAPI ::std::array<::Facing::Name, 6> const& DIRECTIONS();
49
50MCNAPI ::std::array<uchar, 6> const& FACINGMASK();
51
52MCNAPI ::Facing::StringMap const& FROM_STRING_MAP();
53
54MCNAPI ::std::array<::Vec3, 6> const& NORMAL();
55
56MCAPI ::std::add_lvalue_reference_t<uchar const[]> OPPOSITE_FACING();
57
58MCAPI ::std::array<schar, 6> const& STEP_X();
59
60MCAPI ::std::array<schar, 6> const& STEP_Y();
61
62MCAPI ::std::array<schar, 6> const& STEP_Z();
63
64MCNAPI ::std::array<::std::string_view, 6> const& TO_STRING_ARR();
65// NOLINTEND
66
67} // namespace Facing
Definition BlockPos.h:14
Definition StringMap.h:7
Definition Matrix.h:10
Definition Random.h:10
Definition Vec2.h:5
Definition Vec3.h:10