// Copyright (C) 2015 Jérôme Leclercq // This file is part of the "Nazara Development Kit" // For conditions of distribution and use, see copyright notice in Prerequesites.hpp #include #include #include namespace Ndk { inline ParticleGroupComponent::ParticleGroupComponent(unsigned int maxParticleCount, Nz::ParticleLayout layout) : ParticleGroup(maxParticleCount, layout) { } inline ParticleGroupComponent::ParticleGroupComponent(unsigned int maxParticleCount, Nz::ParticleDeclarationConstRef declaration) : ParticleGroup(maxParticleCount, std::move(declaration)) { } inline void ParticleGroupComponent::AddEmitter(Entity* emitter) { NazaraAssert(emitter && emitter->IsValid(), "Invalid entity"); NazaraAssert(emitter->HasComponent(), "Entity must have a NodeComponent"); auto& emitterComponent = emitter->GetComponent(); ParticleGroup::AddEmitter(&emitterComponent); } inline void ParticleGroupComponent::RemoveEmitter(Entity* emitter) { NazaraAssert(emitter && emitter->IsValid(), "Invalid entity"); NazaraAssert(emitter->HasComponent(), "Entity must have a NodeComponent"); auto& emitterComponent = emitter->GetComponent(); ParticleGroup::RemoveEmitter(&emitterComponent); } }