25 lines
560 B
C++
25 lines
560 B
C++
// Copyright (c) 2023 Dominic Masters
|
|
//
|
|
// This software is released under the MIT License.
|
|
// https://opensource.org/licenses/MIT
|
|
|
|
#include "SceneItemComponents.hpp"
|
|
|
|
using namespace Dawn;
|
|
|
|
SceneItemComponents::SceneItemComponents() {
|
|
|
|
}
|
|
|
|
void SceneItemComponents::removeComponent(
|
|
const std::shared_ptr<SceneComponent> component
|
|
) {
|
|
auto it = std::find(components.begin(), components.end(), component);
|
|
if(it == components.end()) return; //Not found?
|
|
it->get()->dispose();
|
|
components.erase(it);
|
|
}
|
|
|
|
SceneItemComponents::~SceneItemComponents() {
|
|
|
|
} |