1
0
mirror of https://github.com/luanti-org/minetestmapper.git synced 2025-10-07 06:15:20 +02:00

General code cleanups/maintenance

This commit is contained in:
sfan5
2022-02-09 22:46:07 +01:00
parent b491dd375a
commit e4bf375ac7
17 changed files with 137 additions and 148 deletions

View File

@@ -2,13 +2,16 @@
#include <climits>
#include <cstdint>
#include "config.h"
#define BLOCK_SIZE 16
struct PixelAttribute {
PixelAttribute(): height(INT16_MIN), thickness(0) {};
PixelAttribute() : height(INT16_MIN), thickness(0) {};
int16_t height;
uint8_t thickness;
inline bool valid_height() {
inline bool valid_height() const {
return height != INT16_MIN;
}
};
@@ -18,8 +21,10 @@ class PixelAttributes
public:
PixelAttributes();
virtual ~PixelAttributes();
void setWidth(int width);
void scroll();
inline PixelAttribute &attribute(int z, int x) {
return m_pixelAttributes[z + 1][x + 1];
};