2020-09-13 23:37:55 +01:00
|
|
|
#pragma once
|
2018-09-23 00:47:28 +01:00
|
|
|
#ifndef BLOCK_H
|
|
|
|
#define BLOCK_H
|
|
|
|
|
|
|
|
#include <QObject>
|
|
|
|
|
2021-02-18 00:20:14 +00:00
|
|
|
class Block {
|
2018-09-23 00:47:28 +01:00
|
|
|
public:
|
|
|
|
Block();
|
|
|
|
Block(uint16_t);
|
2020-04-27 01:38:20 +01:00
|
|
|
Block(uint16_t tile, uint16_t collision, uint16_t elevation);
|
2021-02-18 00:20:14 +00:00
|
|
|
Block(const Block&);
|
|
|
|
Block& operator=(const Block&);
|
|
|
|
bool operator==(Block) const;
|
|
|
|
bool operator!=(Block) const;
|
|
|
|
uint16_t tile : 10;
|
|
|
|
uint16_t collision : 2;
|
|
|
|
uint16_t elevation : 4;
|
2021-02-14 20:10:03 +00:00
|
|
|
uint16_t rawValue() const;
|
2018-09-23 00:47:28 +01:00
|
|
|
};
|
|
|
|
|
|
|
|
#endif // BLOCK_H
|