2021-12-27 19:41:25 +01:00
|
|
|
#pragma once
|
|
|
|
|
2022-01-18 04:15:59 +01:00
|
|
|
#include "core/time.h"
|
2021-12-27 19:41:25 +01:00
|
|
|
#include "classicmode/classicactions.h"
|
|
|
|
|
2022-01-18 04:15:59 +01:00
|
|
|
#include <memory>
|
|
|
|
#include <vector>
|
|
|
|
|
2021-12-28 19:04:50 +01:00
|
|
|
struct ArrowElement;
|
2022-02-06 02:33:09 +01:00
|
|
|
struct MockElement;
|
2021-12-27 19:41:25 +01:00
|
|
|
|
2021-12-28 19:04:50 +01:00
|
|
|
class ClassicGraphicsManager : public std::enable_shared_from_this<ClassicGraphicsManager>
|
2021-12-27 19:41:25 +01:00
|
|
|
{
|
|
|
|
public:
|
|
|
|
virtual ~ClassicGraphicsManager() = default;
|
2022-01-18 04:15:59 +01:00
|
|
|
explicit ClassicGraphicsManager(const kku::microsec& visibility_offset) :
|
2021-12-27 19:41:25 +01:00
|
|
|
_visibility_offset(visibility_offset)
|
|
|
|
{}
|
|
|
|
|
2022-02-06 02:33:09 +01:00
|
|
|
virtual void input(kku::GameEvent&& input) = 0;
|
|
|
|
|
2021-12-28 19:04:50 +01:00
|
|
|
virtual void display(const std::vector<ArrowElement>& elements) const = 0;
|
2021-12-29 15:59:18 +01:00
|
|
|
virtual void setGraphics(std::vector<ArrowElement>& elements, kku::TimeRange&& range) = 0;
|
2022-02-16 20:20:13 +01:00
|
|
|
virtual void removeGraphics(std::vector<ArrowElement>& elements) = 0;
|
2021-12-28 19:04:50 +01:00
|
|
|
|
2022-02-06 02:33:09 +01:00
|
|
|
virtual void display(const std::vector<MockElement>& elements) const = 0;
|
|
|
|
virtual void setGraphics(std::vector<MockElement>& elements, kku::TimeRange&& range) = 0;
|
2022-02-16 20:20:13 +01:00
|
|
|
virtual void removeGraphics(std::vector<MockElement>& elements) = 0;
|
2022-02-06 02:33:09 +01:00
|
|
|
|
2021-12-28 19:04:50 +01:00
|
|
|
virtual void display() const = 0;
|
2021-12-29 15:59:18 +01:00
|
|
|
virtual void update(const kku::microsec& offset) = 0;
|
2021-12-27 19:41:25 +01:00
|
|
|
|
|
|
|
protected:
|
2021-12-29 15:59:18 +01:00
|
|
|
kku::microsec _visibility_offset;
|
2021-12-27 19:41:25 +01:00
|
|
|
};
|