-
Notifications
You must be signed in to change notification settings - Fork 1
/
StreamAtVehicle.h
35 lines (26 loc) · 906 Bytes
/
StreamAtVehicle.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
//
// by Weikton 05.09.23
//
#pragma once
#include "../game/common.h"
#include "LocalStream.h"
#include "Channel.h"
class StreamAtVehicle : public LocalStream {
StreamAtVehicle() = delete;
StreamAtVehicle(const StreamAtVehicle&) = delete;
StreamAtVehicle(StreamAtVehicle&&) = delete;
StreamAtVehicle& operator=(const StreamAtVehicle&) = delete;
StreamAtVehicle& operator=(StreamAtVehicle&&) = delete;
public:
explicit StreamAtVehicle(uint16_t color, std::string name,
float distance, VEHICLEID vehicleId) noexcept;
~StreamAtVehicle() noexcept = default;
public:
void Tick() noexcept override;
private:
void OnChannelCreate(const Channel& channel) noexcept override;
private:
const VEHICLEID vehicleId;
};
using StreamAtVehiclePtr = std::unique_ptr<StreamAtVehicle>;
#define MakeStreamAtVehicle std::make_unique<StreamAtVehicle>