mirror of
https://github.com/luanti-org/luanti.git
synced 2025-10-14 17:15:21 +02:00
Use a enum for tile rotation
This commit is contained in:
@@ -295,6 +295,19 @@ struct TileLayer
|
||||
u8 scale = 1;
|
||||
};
|
||||
|
||||
enum class TileRotation: u8 {
|
||||
None,
|
||||
R90,
|
||||
R180,
|
||||
R270,
|
||||
FXR90,
|
||||
FXR270,
|
||||
FYR90,
|
||||
FYR270,
|
||||
FX,
|
||||
FY,
|
||||
};
|
||||
|
||||
/*!
|
||||
* Defines a face of a node. May have up to two layers.
|
||||
*/
|
||||
@@ -305,7 +318,7 @@ struct TileSpec
|
||||
//! If true, the tile rotation is ignored.
|
||||
bool world_aligned = false;
|
||||
//! Tile rotation.
|
||||
u8 rotation = 0;
|
||||
TileRotation rotation = TileRotation::None;
|
||||
//! This much light does the tile emit.
|
||||
u8 emissive_light = 0;
|
||||
//! The first is base texture, the second is overlay.
|
||||
|
Reference in New Issue
Block a user