SimulationManagerEditor.cpp 2.3 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768
  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 "SimulationManagerEditor.h"
  9. #include <AzCore/Serialization/SerializeContext.h>
  10. #include <SimulationInterfaces/SimulationInterfacesTypeIds.h>
  11. namespace SimulationInterfaces
  12. {
  13. AZ_COMPONENT_IMPL(SimulationManagerEditor, "SimulationMangerEditor", SimulationManagerEditorTypeId, BaseSystemComponent);
  14. void SimulationManagerEditor::Reflect(AZ::ReflectContext* context)
  15. {
  16. if (auto serializeContext = azrtti_cast<AZ::SerializeContext*>(context))
  17. {
  18. serializeContext->Class<SimulationManagerEditor, SimulationManager>()->Version(0);
  19. }
  20. }
  21. SimulationManagerEditor::SimulationManagerEditor() = default;
  22. SimulationManagerEditor::~SimulationManagerEditor() = default;
  23. void SimulationManagerEditor::GetProvidedServices(AZ::ComponentDescriptor::DependencyArrayType& provided)
  24. {
  25. BaseSystemComponent::GetProvidedServices(provided);
  26. provided.push_back(AZ_CRC_CE("SimulationManagerEditorService"));
  27. }
  28. void SimulationManagerEditor::GetIncompatibleServices(AZ::ComponentDescriptor::DependencyArrayType& incompatible)
  29. {
  30. BaseSystemComponent::GetIncompatibleServices(incompatible);
  31. incompatible.push_back(AZ_CRC_CE("SimulationManagerEditorService"));
  32. }
  33. void SimulationManagerEditor::GetRequiredServices([[maybe_unused]] AZ::ComponentDescriptor::DependencyArrayType& required)
  34. {
  35. BaseSystemComponent::GetRequiredServices(required);
  36. }
  37. void SimulationManagerEditor::GetDependentServices([[maybe_unused]] AZ::ComponentDescriptor::DependencyArrayType& dependent)
  38. {
  39. BaseSystemComponent::GetDependentServices(dependent);
  40. }
  41. void SimulationManagerEditor::Init()
  42. {
  43. BaseSystemComponent::Init();
  44. }
  45. void SimulationManagerEditor::Activate()
  46. {
  47. BaseSystemComponent::Activate();
  48. AzToolsFramework::EditorEvents::Bus::Handler::BusConnect();
  49. }
  50. void SimulationManagerEditor::Deactivate()
  51. {
  52. AzToolsFramework::EditorEvents::Bus::Handler::BusDisconnect();
  53. BaseSystemComponent::Deactivate();
  54. }
  55. } // namespace SimulationInterfaces