TwitchModule.cpp 1.2 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546
  1. /*
  2. * Copyright (c) Contributors to the Open 3D Engine Project.
  3. * For complete copyright and license terms please see the LICENSE at the root of this distribution.
  4. *
  5. * SPDX-License-Identifier: Apache-2.0 OR MIT
  6. *
  7. */
  8. #include <TwitchSystemComponent.h>
  9. #include <AzCore/Module/Module.h>
  10. namespace Twitch
  11. {
  12. class TwitchModule
  13. : public AZ::Module
  14. {
  15. public:
  16. AZ_RTTI(TwitchModule, "{A7BA4662-18FE-4538-8B88-6F66C43AB319}", AZ::Module);
  17. TwitchModule()
  18. : AZ::Module()
  19. {
  20. // Push results of [MyComponent]::CreateDescriptor() into m_descriptors here.
  21. m_descriptors.insert(m_descriptors.end(), {
  22. TwitchSystemComponent::CreateDescriptor(),
  23. });
  24. }
  25. /**
  26. * Add required SystemComponents to the SystemEntity.
  27. */
  28. AZ::ComponentTypeList GetRequiredSystemComponents() const override
  29. {
  30. return AZ::ComponentTypeList{
  31. azrtti_typeid<TwitchSystemComponent>(),
  32. };
  33. }
  34. };
  35. }
  36. #if defined(O3DE_GEM_NAME)
  37. AZ_DECLARE_MODULE_CLASS(AZ_JOIN(Gem_, O3DE_GEM_NAME), Twitch::TwitchModule)
  38. #else
  39. AZ_DECLARE_MODULE_CLASS(Gem_Twitch, Twitch::TwitchModule)
  40. #endif