/
redgpu
/
ezEngine
Обзор
Документация
Войти
/
redgpu
/
ezEngine
Код
Запросы
0
Задачи
Вики
Пакеты
0
Релизы
0
Аналитика
Безопасность
dev
Code/EnginePlugins/ParticlePlugin/Events/ParticleEventReaction_Prefab.h
60 строк
2 KB
Jan Krassnigg
Fixed several public header includes (#1753)
03 янв 2026, 21:23
Не верифицирован
03 янв 2026, 21:23
1a4bcb1
Код
Авторство
О чём код?
#pragma once #include <Core/Physics/SurfaceResourceDescriptor.h> #include <Foundation/Types/RangeView.h> #include <Foundation/Types/SharedPtr.h> #include <ParticlePlugin/Events/ParticleEventReaction.h> using ezPrefabResourceHandle = ezTypedResourceHandle<class ezPrefabResource>; /// Factory for creating prefab spawn reactions. /// /// Configures reactions that instantiate a prefab at the event location. class EZ_PARTICLEPLUGIN_DLL ezParticleEventReactionFactory_Prefab final : public ezParticleEventReactionFactory { EZ_ADD_DYNAMIC_REFLECTION(ezParticleEventReactionFactory_Prefab, ezParticleEventReactionFactory); public: ezParticleEventReactionFactory_Prefab(); virtual const ezRTTI* GetEventReactionType() const override; virtual void CopyReactionProperties(ezParticleEventReaction* pObject, bool bFirstTime) const override; virtual void Save(ezStreamWriter& inout_stream) const override; virtual void Load(ezStreamReader& inout_stream) override; ezString m_sPrefab; ezEnum<ezSurfaceInteractionAlignment> m_Alignment; ////////////////////////////////////////////////////////////////////////// // Exposed Parameters public: // const ezRangeView<const char*, ezUInt32> GetParameters() const; // void SetParameter(const char* szKey, const ezVariant& value); // void RemoveParameter(const char* szKey); // bool GetParameter(const char* szKey, ezVariant& out_value) const; private: // ezSharedPtr<ezParticlePrefabParameters> m_Parameters; }; /// Event reaction that instantiates a prefab. /// /// When triggered, spawns the configured prefab at the event's position and orientation. /// The prefab can be aligned according to the event's direction and normal vectors. class EZ_PARTICLEPLUGIN_DLL ezParticleEventReaction_Prefab final : public ezParticleEventReaction { EZ_ADD_DYNAMIC_REFLECTION(ezParticleEventReaction_Prefab, ezParticleEventReaction); public: ezParticleEventReaction_Prefab(); ~ezParticleEventReaction_Prefab(); ezPrefabResourceHandle m_hPrefab; ezEnum<ezSurfaceInteractionAlignment> m_Alignment; // ezSharedPtr<ezParticlePrefabParameters> m_Parameters; protected: virtual void ProcessEvent(const ezParticleEvent& e) override; };