From bea3ee6dd0d0702bcca9909dd2cc0ca597138bbf Mon Sep 17 00:00:00 2001 From: lsemp3d <58790905+lsemp3d@users.noreply.github.com> Date: Mon, 18 Oct 2021 10:54:56 -0700 Subject: [PATCH] Removed outdated and unused ScriptCanvas files Signed-off-by: lsemp3d <58790905+lsemp3d@users.noreply.github.com> --- .../ScriptCanvas/Libraries/Time/DateTime.cpp | 81 ------------------ .../ScriptCanvas/Libraries/Time/DateTime.h | 82 ------------------- 2 files changed, 163 deletions(-) delete mode 100644 Gems/ScriptCanvas/Code/Include/ScriptCanvas/Libraries/Time/DateTime.cpp delete mode 100644 Gems/ScriptCanvas/Code/Include/ScriptCanvas/Libraries/Time/DateTime.h diff --git a/Gems/ScriptCanvas/Code/Include/ScriptCanvas/Libraries/Time/DateTime.cpp b/Gems/ScriptCanvas/Code/Include/ScriptCanvas/Libraries/Time/DateTime.cpp deleted file mode 100644 index 92c9448503..0000000000 --- a/Gems/ScriptCanvas/Code/Include/ScriptCanvas/Libraries/Time/DateTime.cpp +++ /dev/null @@ -1,81 +0,0 @@ -/* - * Copyright (c) Contributors to the Open 3D Engine Project. - * For complete copyright and license terms please see the LICENSE at the root of this distribution. - * - * SPDX-License-Identifier: Apache-2.0 OR MIT - * - */ - -#include "DateTime.h" - -namespace ScriptCanvas -{ - namespace Nodes - { - namespace Time - { - /////////////// - // DateTime - /////////////// - - DateTime::DateTime() - : Node() - , m_tickCounter(0) - , m_tickOrder(AZ::TICK_DEFAULT) - { - } - - void DateTime::OnDeactivate() - { - AZ::TickBus::Handler::BusDisconnect(); - AZ::SystemTickBus::Handler::BusDisconnect(); - } - - void DateTime::OnInputSignal(const SlotId&) - { - m_tickCounter = DateTimeProperty::GetTicks(this); - - if (m_tickCounter >= 0) - { - if (!AZ::SystemTickBus::Handler::BusIsConnected()) - { - AZ::SystemTickBus::Handler::BusConnect(); - } - } - } - - void DateTime::OnSystemTick() - { - AZ::SystemTickBus::Handler::BusDisconnect(); - - if (!AZ::TickBus::Handler::BusIsConnected()) - { - AZ::TickBus::Handler::BusDisconnect(); - } - - m_tickOrder = DateTimeProperty::GetTickOrder(this); - AZ::TickBus::Handler::BusConnect(); - } - - void DateTime::OnTick(float deltaTime, AZ::ScriptTimePoint timePoint) - { - --m_tickCounter; - - if (m_tickCounter <= 0) - { - const SlotId outSlot = DateTimeProperty::GetOutSlotId(this); - - SignalOutput(outSlot); - AZ::TickBus::Handler::BusDisconnect(); - } - } - - int DateTime::GetTickOrder() - { - return m_tickOrder; - } - } - } -} - -#include diff --git a/Gems/ScriptCanvas/Code/Include/ScriptCanvas/Libraries/Time/DateTime.h b/Gems/ScriptCanvas/Code/Include/ScriptCanvas/Libraries/Time/DateTime.h deleted file mode 100644 index c5faa3d7a5..0000000000 --- a/Gems/ScriptCanvas/Code/Include/ScriptCanvas/Libraries/Time/DateTime.h +++ /dev/null @@ -1,82 +0,0 @@ -/* - * Copyright (c) Contributors to the Open 3D Engine Project. - * For complete copyright and license terms please see the LICENSE at the root of this distribution. - * - * SPDX-License-Identifier: Apache-2.0 OR MIT - * - */ - -#pragma once - -#include -#include - -#include - -#include - -#include - -#include - -namespace ScriptCanvas -{ - namespace Nodes - { - namespace Time - { - class DateTime - : public Node - , AZ::TickBus::Handler - , AZ::SystemTickBus::Handler - { - ScriptCanvas_Node(DateTime, - ScriptCanvas_Node::Name("Date Time") - ScriptCanvas_Node::Uuid("") - ScriptCanvas_Node::Description("") - ); - public: - DateTime(); - - void OnDeactivate() override; - void OnInputSignal(const SlotId&) override; - - // SystemTickBus - void OnSystemTick() override; - //// - - // TickBus - void OnTick(float deltaTime, AZ::ScriptTimePoint timePoint) override; - int GetTickOrder() override; - //// - - protected: - - // Inputs - ScriptCanvas_In(ScriptCanvas_In::Name("In", "When signaled, execution is delayed at this node for the specified amount of frames.") - ScriptCanvas_In::Contracts({ DisallowReentrantExecutionContract })); - - // Outputs - ScriptCanvas_OutLatent(ScriptCanvas_OutLatent::Name("Out", "Signaled after waiting for the specified amount of frames.")); - - // Data - ScriptCanvas_PropertyWithDefaults(int, 1, - ScriptCanvas_Property::Name("Ticks", "The amount of ticks that need to occur before exeuction triggers") - ScriptCanvas_Property::Input - ScriptCanvas_Property::Default - ); - - ScriptCanvas_PropertyWithDefaults(int, static_cast(AZ::TICK_DEFAULT), - ScriptCanvas_Property::Name("Tick Order", "Where in the Tick Order this delay should happen") - ScriptCanvas_Property::Input - ScriptCanvas_Property::Default - ); - - private: - int m_tickCounter; - int m_tickOrder; - }; - - } - } -}