#ifndef URANIUM_REFINERY_HPP_
#define URANIUM_REFINERY_HPP_

#include <Block/SpriteBlock/MultiBlock/MultiBlock.hpp>
#include <Block/MachineBlockMixin.hpp>
#include <Machine/MUraniumRefinery/MUraniumRefinery.hpp>

class UraniumRefinery : public MultiBlock, public MachineBlockMixin<MUraniumRefinery>
{
public:
    /*
        #        Uranium Refinery Meta Byte
        +-------+---+---+---+---+---+---+---+---+
        | Bit   | 7 | 6 | 5 | 4 | 3 | 2 | 1 | 0 |
        +-------+---+---+---+---+---+---+---+---+
        | Field |   |   |   |   |   | A | orient|
        +-------+---+---+---+---+---+---+---+---+

        orient
            The orientation of the multi-block structure.
        
        A
            If set, the refinery is on.
    */

    static constexpr uint8_t metaActive = (1 << 2);

    UraniumRefinery(std::string name);

    virtual void getHarvestedStacks(LocalWorld &world, glm::ivec3 pos, std::vector<ItemStack> &stacks) override;
    virtual void onInteract(LocalWorld &world, Player &player, glm::ivec3 pos, Side side, const RGBABytes &collisionKey) override;
    virtual glm::vec3 getLightColor(uint8_t meta) override;
    virtual glm::ivec3 getLightOffset(uint8_t meta) override;
    virtual Sound& getBackgroundSound(uint8_t meta) override;
    virtual void onRemoved(LocalWorld &world, Chunk &chunk, glm::ivec3 pos, uint8_t meta) override;
};

#endif