ProteusRobotEditorModule.cpp 1.4 KB

1234567891011121314151617181920212223242526272829303132333435363738
  1. #include <ProteusRobotModuleInterface.h>
  2. #include "ProteusRobotEditorSystemComponent.h"
  3. namespace ProteusRobot
  4. {
  5. class ProteusRobotEditorModule
  6. : public ProteusRobotModuleInterface
  7. {
  8. public:
  9. AZ_RTTI(ProteusRobotEditorModule, "{F9558D3E-566B-4824-8634-015F21864F5E}", ProteusRobotModuleInterface);
  10. AZ_CLASS_ALLOCATOR(ProteusRobotEditorModule, AZ::SystemAllocator);
  11. ProteusRobotEditorModule()
  12. {
  13. // Push results of [MyComponent]::CreateDescriptor() into m_descriptors here.
  14. // Add ALL components descriptors associated with this gem to m_descriptors.
  15. // This will associate the AzTypeInfo information for the components with the the SerializeContext, BehaviorContext and EditContext.
  16. // This happens through the [MyComponent]::Reflect() function.
  17. m_descriptors.insert(m_descriptors.end(), {
  18. ProteusRobotEditorSystemComponent::CreateDescriptor(),
  19. });
  20. }
  21. /**
  22. * Add required SystemComponents to the SystemEntity.
  23. * Non-SystemComponents should not be added here
  24. */
  25. AZ::ComponentTypeList GetRequiredSystemComponents() const override
  26. {
  27. return AZ::ComponentTypeList {
  28. azrtti_typeid<ProteusRobotEditorSystemComponent>(),
  29. };
  30. }
  31. };
  32. }// namespace ProteusRobot
  33. AZ_DECLARE_MODULE_CLASS(Gem_ProteusRobot, ProteusRobot::ProteusRobotEditorModule)