aboutsummaryrefslogtreecommitdiff
path: root/game/prefab/ZapperPoolSubScene.h
blob: 25328eeed09cb27b54fe88cec7c6afca3443b0f0 (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
27
#pragma once

#include <vector>

#include <crepe/api/Scene.h>
#include <crepe/api/GameObject.h>
#include <crepe/api/Event.h>
#include <crepe/util/OptionalRef.h>

#include "ZapperObject.h"

class CreateZapperEvent : public crepe::Event {};

class ZapperPoolSubScene {
public:
	ZapperPoolSubScene(crepe::Scene & scene);

private:
	crepe::GameObject controller;
	std::vector<ZapperObject> zappers;

private:
	static constexpr size_t POOL_SIZE = 4;

public:
	crepe::OptionalRef<ZapperObject> get_next_zapper();
};