aboutsummaryrefslogtreecommitdiff
path: root/src/crepe/system/ReplaySystem.h
blob: fb401769d055b218dc08436bd56f6dc715794009 (plain)
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
#pragma once

#include "../manager/ReplayManager.h"

#include "System.h"

namespace crepe {

class ReplaySystem : public System {
public:
	using System::System;

	void fixed_update() override;

private:
	ReplayManager::State last_state = ReplayManager::IDLE;
	void update_recording();
	void update_playing();

	std::unordered_map<std::type_index, bool> system_active_snapshot;
	void playback_begin();
	void playback_end();
};

}