aboutsummaryrefslogtreecommitdiff
path: root/src/crepe/api/GameObject.hpp
blob: a6b45b0a41c0d0ff78cae27a6e3b52a1472d449d (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
#pragma once

#include "../manager/ComponentManager.h"

#include "GameObject.h"

namespace crepe {

template <typename T, typename... Args>
T & GameObject::add_component(Args &&... args) {
	ComponentManager & mgr = this->component_manager;
	return mgr.add_component<T>(this->id, std::forward<Args>(args)...);
}

} // namespace crepe