From bdf81a5e9cbd04207963bc56937a5ddb1948bf07 Mon Sep 17 00:00:00 2001 From: Adam Ramberg Date: Sun, 17 Mar 2019 23:43:20 +0100 Subject: [PATCH] Squashed commit of the following: commit 847eff037204d841546c0da772d2f341f9cf1e25 Author: Adam Ramberg Date: Sun Mar 17 22:09:38 2019 +0100 #17 - Serializable not needed for ScriptableObject commit 593b275e6394b9d589de8a7a20375145dfc4aa84 Author: Adam Ramberg Date: Sun Mar 17 21:59:33 2019 +0100 18 - IGameEvent RegisterListener commit 40443ce9bd4b1c339aaf19cfcb119f2336608dae Author: Adam Ramberg Date: Fri Mar 8 16:35:04 2019 +0100 Remove some more warnings commit bd453110ac51a6ebe3d54368fcb039bdbe52e278 Author: Adam Ramberg Date: Fri Mar 8 16:33:30 2019 +0100 Update README commit 90977b853a047c84efb5311768a09f4e8a1165b2 Author: Adam Ramberg Date: Fri Mar 8 16:31:45 2019 +0100 Initialize to null to get rid off warnings commit 38b7f5c4ede195aa7198f567801c9cbeedc9b6f6 Author: Adam Ramberg Date: Fri Mar 8 16:15:53 2019 +0100 More fixes to enable local unity project commit 404e1cbf88ed4431c61d3ece074e838e74ac5141 Author: Adam Ramberg Date: Fri Mar 8 16:12:37 2019 +0100 Remove duplicated asmdef commit 5734300684e8a16553f213157cad1b4722b7cb7f Author: Adam Ramberg Date: Fri Mar 8 16:09:46 2019 +0100 Change files to include commit d1e42b119a6bc1577b1792459fa298e063652337 Author: Adam Ramberg Date: Fri Mar 8 16:05:56 2019 +0100 Added root package json commit 1709a0347147d74460f653182bbaf8d15eb6154e Author: Adam Ramberg Date: Fri Mar 8 15:30:44 2019 +0100 #16 - Add test and examples Unity project commit a3ea1a133bf6727e011ba85c64569db45302e487 Author: Adam Ramberg Date: Fri Mar 8 13:12:02 2019 +0100 #13 - Make usage of UPM (package manager) commit 492a30e905f6cf3f5899cb7080ef2bda73110f00 Author: Adam Ramberg Date: Fri Mar 8 11:28:56 2019 +0100 Added extensions + code formatting fixes commit 709949a1016c236cfd363cf25392fedfd8d083ca Author: Oliver Biwer Date: Fri Mar 8 10:16:45 2019 +0100 More AtomicTags changes (#15) * - added assembly defintions, and unit tests - improved AtomicTags in regards of #8, #9 and #10 * Fixes #11 - Added Equality Members (inclusive HashCode) for ScriptableObjectVariableBase * removed Rider Plugins from git * Further AtomicTag optimization commit ae6584c879f182e727fe0a8d0aff4b0715829914 Author: Adam Ramberg Date: Fri Mar 8 10:08:36 2019 +0100 Editor config commit 197d7067608600e4e2d13dc42db909ee8f8c75df Author: Adam Ramberg Date: Fri Mar 8 09:23:12 2019 +0100 Added editor config file commit 53d6adc07bbc2967c12c17227a1c31d9f1cfba77 Author: Oliver Biwer Date: Tue Mar 5 22:57:47 2019 +0100 More efficient AtomicTags (#12) * - added assembly defintions, and unit tests - improved AtomicTags in regards of #8, #9 and #10 * Fixes #11 - Added Equality Members (inclusive HashCode) for ScriptableObjectVariableBase * removed Rider Plugins from git commit 81209d83b5195300d4c2d54411cff3c7983f0d97 Author: Adam Ramberg Date: Wed Dec 12 20:54:17 2018 +0100 Added MonoHooks + ColliderType + bug fixes commit c6b240cebbdc410341fb05204235842df5da9d73 Author: Adam Ramberg Date: Sat Dec 1 00:23:10 2018 +0100 Experimenting with adding UI state management commit dfd70a8944acbeabe5feba1cf6cff2be6802c470 Author: Adam Ramberg Date: Fri Nov 30 23:10:21 2018 +0100 Issue #6 - AtomicTags commit 8907763227f4d4c2a32c5684e7caa4d4a082eb16 Author: Adam Ramberg Date: Fri Nov 30 22:42:29 2018 +0100 First commit of v1.0.0 --- .editorconfig | 16 + .gitignore | 3 + Assets/UnityAtoms/Constants/BoolConstant.cs | 9 - Assets/UnityAtoms/Constants/ColorConstant.cs | 9 - Assets/UnityAtoms/Constants/FloatConstant.cs | 9 - Assets/UnityAtoms/Constants/IntConstant.cs | 9 - Assets/UnityAtoms/Constants/StringConstant.cs | 9 - .../UnityAtoms/Constants/Vector2Constant.cs | 9 - .../UnityAtoms/Constants/Vector3Constant.cs | 9 - .../Examples/Intro/Scenes/Intro.unity | 723 -------- .../Examples/Intro/Scripts/Harmful.cs | 17 - .../Examples/Intro/Scripts/HealthBar.cs | 17 - Assets/UnityAtoms/GameActions.meta | 8 - .../UnityAtoms/GameActions/ChangeScene.meta | 8 - .../Collider2DGameObjectEventAction.cs | 6 - .../GameActions/SetVariableValue.meta | 8 - .../SetVariableValue/SetBoolVariableValue.cs | 10 - .../SetVariableValue/SetColorVariableValue.cs | 10 - .../SetVariableValue/SetFloatVariableValue.cs | 10 - .../SetGameObjectVariableValue.cs | 11 - .../SetVariableValue/SetIntVariableValue.cs | 10 - .../SetVector3VariableValue.cs | 11 - Assets/UnityAtoms/GameEventListeners.meta | 8 - Assets/UnityAtoms/GameEvents.meta | 8 - Assets/UnityAtoms/GameEvents/BoolBoolEvent.cs | 9 - Assets/UnityAtoms/GameEvents/BoolEvent.cs | 9 - .../UnityAtoms/GameEvents/Collider2DEvent.cs | 9 - .../GameEvents/Collider2DGameObjectEvent.cs | 10 - .../UnityAtoms/GameEvents/ColorColorEvent.cs | 9 - Assets/UnityAtoms/GameEvents/ColorEvent.cs | 9 - .../GameEvents/CreateEventOnAwake.meta | 8 - .../CreateCollider2DEventOnAwake.cs | 19 - Assets/UnityAtoms/GameEvents/FloatEvent.cs | 9 - .../UnityAtoms/GameEvents/FloatFloatEvent.cs | 9 - .../GameEvents/GameObjectCollider2DEvent.cs | 10 - .../UnityAtoms/GameEvents/GameObjectEvent.cs | 9 - .../GameEvents/GameObjectGameObjectEvent.cs | 10 - Assets/UnityAtoms/GameEvents/IntEvent.cs | 9 - Assets/UnityAtoms/GameEvents/IntIntEvent.cs | 9 - Assets/UnityAtoms/GameEvents/Vector2Event.cs | 9 - .../GameEvents/Vector2Vector2Event.cs | 9 - Assets/UnityAtoms/GameEvents/Vector3Event.cs | 9 - .../GameEvents/Vector3Vector3Event.cs | 10 - .../GameEvents/VoidGameObjectEvent.cs | 10 - .../GameFunctions/GetUnusedGameObject.meta | 8 - .../GetUnusedGameObject.cs | 44 - Assets/UnityAtoms/Lists.meta | 8 - Assets/UnityAtoms/Lists/BoolList.cs | 9 - Assets/UnityAtoms/Lists/Collider2DList.cs | 9 - Assets/UnityAtoms/Lists/ColorList.cs | 9 - Assets/UnityAtoms/Lists/FloatList.cs | 9 - Assets/UnityAtoms/Lists/GameObjectList.cs | 10 - Assets/UnityAtoms/Lists/IntList.cs | 9 - Assets/UnityAtoms/Lists/Vector2List.cs | 9 - Assets/UnityAtoms/Lists/Vector3List.cs | 9 - Assets/UnityAtoms/References.meta | 8 - Assets/UnityAtoms/References/Editor.meta | 8 - Assets/UnityAtoms/UnityEvents.meta | 8 - Assets/UnityAtoms/UnityEvents/UnityEvents.cs | 31 - Assets/UnityAtoms/Variables.meta | 8 - Assets/UnityAtoms/Variables/BoolVariable.cs | 9 - .../Variables/GameObjectVariable.cs | 13 - .../Variables/ScriptableObjectVariableBase.cs | 17 - Assets/UnityAtoms/Variables/Utils.meta | 8 - .../Variables/Utils/VariableUtils.cs | 15 - .../Variables/Utils/VariableUtils.cs.meta | 11 - LICENSE.meta | 7 + Packages/manifest.json | 39 - ProjectSettings/ProjectVersion.txt | 1 - README.md | 13 +- README.md.meta | 7 + Assets/UnityAtoms.meta => Source.meta | 2 +- .../Constants.meta => Source/AtomicTags.meta | 2 +- Source/AtomicTags/AtomicTags.cs | 175 ++ Source/AtomicTags/AtomicTags.cs.meta | 3 + Source/AtomicTags/ReadOnlyList.cs | 36 + Source/AtomicTags/ReadOnlyList.cs.meta | 3 + .../AtomicUI.meta | 2 +- Source/AtomicUI/UIContainer.cs | 56 + .../AtomicUI/UIContainer.cs.meta | 2 +- .../Base.meta | 2 +- Source/Base/ConditionalGameActionHelper.cs | 150 ++ .../Base/ConditionalGameActionHelper.cs.meta | 2 +- .../Base}/CreateOnAwake.meta | 2 +- .../Base/CreateOnAwake}/CreateEventOnAwake.cs | 6 +- .../CreateOnAwake}/CreateEventOnAwake.cs.meta | 2 +- .../Base/CreateOnAwake}/CreateListOnAwake.cs | 12 +- .../CreateOnAwake}/CreateListOnAwake.cs.meta | 2 +- .../CreateOnAwake}/CreateVariableOnAwake.cs | 13 +- .../CreateVariableOnAwake.cs.meta | 2 +- .../GameEvents => Source/Base}/GameEvent.cs | 4 +- .../Base}/GameEvent.cs.meta | 2 +- .../Base}/GameEventListener.cs | 10 +- .../Base}/GameEventListener.cs.meta | 2 +- .../GameEvents => Source/Base}/IGameEvent.cs | 4 +- .../Base}/IGameEvent.cs.meta | 2 +- .../Base}/IGameEventListener.cs | 0 .../Base}/IGameEventListener.cs.meta | 2 +- .../Base}/ScriptableObjectGameAction.cs | 5 - .../Base}/ScriptableObjectGameAction.cs.meta | 2 +- .../Base}/ScriptableObjectList.cs | 3 +- .../Base}/ScriptableObjectList.cs.meta | 2 +- .../Base}/ScriptableObjectReference.cs | 0 .../Base}/ScriptableObjectReference.cs.meta | 2 +- .../Base}/SetVariableValue.cs | 6 +- .../Base}/SetVariableValue.cs.meta | 2 +- Source/Base/Variable.meta | 8 + .../EquatableScriptableObjectVariable.cs | 2 +- .../EquatableScriptableObjectVariable.cs.meta | 2 +- .../Base/Variable}/IWithApplyChange.cs | 0 .../Base/Variable}/IWithApplyChange.cs.meta | 2 +- .../Base/Variable}/IWithOldValue.cs | 0 .../Base/Variable}/IWithOldValue.cs.meta | 2 +- .../Base/Variable}/IWithValue.cs | 0 .../Base/Variable}/IWithValue.cs.meta | 2 +- .../Variable}/ScriptableObjectVariable.cs | 6 + .../ScriptableObjectVariable.cs.meta | 2 +- .../Variable/ScriptableObjectVariableBase.cs | 37 + .../ScriptableObjectVariableBase.cs.meta | 2 +- Source/Bool.meta | 8 + .../GameActions => Source/Bool}/BoolAction.cs | 0 .../Bool}/BoolAction.cs.meta | 2 +- Source/Bool/BoolBoolEvent.cs | 8 + .../Bool}/BoolBoolEvent.cs.meta | 2 +- Source/Bool/BoolConstant.cs | 7 + .../Bool}/BoolConstant.cs.meta | 0 Source/Bool/BoolEvent.cs | 8 + .../Bool}/BoolEvent.cs.meta | 2 +- Source/Bool/BoolList.cs | 7 + .../Lists => Source/Bool}/BoolList.cs.meta | 2 +- .../Bool}/BoolListener.cs | 5 - .../Bool}/BoolListener.cs.meta | 2 +- .../Bool}/BoolReference.cs | 0 .../Bool}/BoolReference.cs.meta | 2 +- Source/Bool/BoolVariable.cs | 7 + .../Bool}/BoolVariable.cs.meta | 2 +- Source/Bool/ConditionalBoolAction.cs | 20 + .../Bool/ConditionalBoolAction.cs.meta | 2 +- Source/Bool/SetBoolVariableValue.cs | 7 + .../Bool}/SetBoolVariableValue.cs.meta | 2 +- Source/Bool/UnityBoolEvent.cs | 8 + .../Bool/UnityBoolEvent.cs.meta | 2 +- Source/Collider.meta | 8 + Source/Collider/ColliderEvent.cs | 7 + Source/Collider/ColliderEvent.cs.meta | 11 + Source/Collider/ColliderGameObjectAction.cs | 6 + .../Collider/ColliderGameObjectAction.cs.meta | 11 + Source/Collider/ColliderGameObjectEvent.cs | 8 + .../Collider/ColliderGameObjectEvent.cs.meta | 11 + Source/Collider/ColliderGameObjectListener.cs | 6 + .../ColliderGameObjectListener.cs.meta | 11 + .../Collider/UnityColliderGameObjectEvent.cs | 9 + .../UnityColliderGameObjectEvent.cs.meta | 11 + Source/Collider2D.meta | 8 + .../Collider2D}/Collider2DAction.cs | 0 .../Collider2D}/Collider2DAction.cs.meta | 2 +- Source/Collider2D/Collider2DEvent.cs | 7 + .../Collider2D}/Collider2DEvent.cs.meta | 2 +- .../Collider2D}/Collider2DEventAction.cs | 0 .../Collider2D}/Collider2DEventAction.cs.meta | 2 +- .../Collider2D}/Collider2DGameObjectAction.cs | 0 .../Collider2DGameObjectAction.cs.meta | 2 +- .../Collider2D/Collider2DGameObjectEvent.cs | 8 + .../Collider2DGameObjectEvent.cs.meta | 2 +- .../Collider2DGameObjectListener.cs | 2 - .../Collider2DGameObjectListener.cs.meta | 2 +- Source/Collider2D/Collider2DList.cs | 7 + .../Collider2D}/Collider2DList.cs.meta | 2 +- .../Collider2D}/Collider2DListAction.cs | 0 .../Collider2D}/Collider2DListAction.cs.meta | 2 +- .../Collider2DListGameObjectAction.cs | 0 .../Collider2DListGameObjectAction.cs.meta | 2 +- .../Collider2D}/Collider2DListener.cs | 3 - .../Collider2D}/Collider2DListener.cs.meta | 2 +- .../CreateCollider2DEventOnAwake.cs | 14 + .../CreateCollider2DEventOnAwake.cs.meta | 2 +- .../CreateCollider2DListOnAwake.cs | 0 .../CreateCollider2DListOnAwake.cs.meta | 2 +- Source/Collider2D/UnityCollider2DEvent.cs | 9 + .../Collider2D/UnityCollider2DEvent.cs.meta | 11 + .../UnityCollider2DGameObjectEvent.cs | 9 + .../UnityCollider2DGameObjectEvent.cs.meta | 11 + Source/Color.meta | 8 + .../Color}/ColorAction.cs | 0 .../Color}/ColorAction.cs.meta | 2 +- Source/Color/ColorColorEvent.cs | 8 + .../Color}/ColorColorEvent.cs.meta | 2 +- Source/Color/ColorConstant.cs | 7 + .../Color}/ColorConstant.cs.meta | 0 Source/Color/ColorEvent.cs | 8 + .../Color}/ColorEvent.cs.meta | 2 +- Source/Color/ColorList.cs | 7 + .../Lists => Source/Color}/ColorList.cs.meta | 2 +- .../Color}/ColorListener.cs | 3 - .../Color}/ColorListener.cs.meta | 2 +- .../Color}/ColorReference.cs | 0 .../Color}/ColorReference.cs.meta | 2 +- .../Color}/ColorVariable.cs | 2 +- .../Color}/ColorVariable.cs.meta | 2 +- Source/Color/ConditionalColorAction.cs | 20 + Source/Color/ConditionalColorAction.cs.meta | 11 + Source/Color/SetColorVariableValue.cs | 7 + .../Color}/SetColorVariableValue.cs.meta | 2 +- Source/Color/UnityColorEvent.cs | 9 + Source/Color/UnityColorEvent.cs.meta | 11 + .../GameEvents => Source}/Editor.meta | 2 +- .../Editor/GameEventEditor.cs | 0 .../Editor/GameEventEditor.cs.meta | 2 +- .../Editor/ReferenceDrawer.cs | 3 + .../Editor/ReferenceDrawer.cs.meta | 2 +- Source/Editor/UnityAtomsEditor.asmdef | 16 + Source/Editor/UnityAtomsEditor.asmdef.meta | 7 + {Assets/UnityAtoms => Source}/Extensions.meta | 2 +- Source/Extensions/ArrayExtensions.cs | 19 + Source/Extensions/ArrayExtensions.cs.meta | 11 + Source/Extensions/CameraExtensions.cs | 17 + Source/Extensions/CameraExtensions.cs.meta | 11 + Source/Extensions/GameObjectExtensions.cs | 82 + .../Extensions/GameObjectExtensions.cs.meta | 11 + Source/Extensions/ListExtensions.cs | 177 ++ Source/Extensions/ListExtensions.cs.meta | 11 + Source/Extensions/MonoBehaviourExtensions.cs | 46 + .../MonoBehaviourExtensions.cs.meta | 11 + Source/Extensions/TransformExtensions.cs | 130 ++ Source/Extensions/TransformExtensions.cs.meta | 11 + .../Extensions/Vector2Extensions.cs | 2 +- .../Extensions/Vector2Extensions.cs.meta | 2 +- .../Extensions/Vector3Extensions.cs | 12 +- .../Extensions/Vector3Extensions.cs.meta | 2 +- Source/Float.meta | 8 + Source/Float/ConditionalFloatAction.cs | 20 + Source/Float/ConditionalFloatAction.cs.meta | 11 + .../Float}/FloatAction.cs | 0 .../Float}/FloatAction.cs.meta | 2 +- Source/Float/FloatConstant.cs | 7 + .../Float}/FloatConstant.cs.meta | 2 +- Source/Float/FloatEvent.cs | 7 + .../Float}/FloatEvent.cs.meta | 2 +- Source/Float/FloatFloatEvent.cs | 8 + .../Float}/FloatFloatEvent.cs.meta | 2 +- Source/Float/FloatList.cs | 7 + .../Lists => Source/Float}/FloatList.cs.meta | 2 +- .../Float}/FloatListener.cs | 5 - .../Float}/FloatListener.cs.meta | 2 +- .../Float}/FloatReference.cs | 0 .../Float}/FloatReference.cs.meta | 2 +- .../Float}/FloatVariable.cs | 5 +- .../Float}/FloatVariable.cs.meta | 2 +- Source/Float/SetFloatVariableValue.cs | 7 + .../Float}/SetFloatVariableValue.cs.meta | 2 +- Source/Float/UnityFloatEvent.cs | 8 + Source/Float/UnityFloatEvent.cs.meta | 11 + .../UnityAtoms => Source}/GameFunctions.meta | 2 +- Source/GameFunctions/BoolBoolFunction.cs | 6 + Source/GameFunctions/BoolBoolFunction.cs.meta | 11 + Source/GameFunctions/BoolColorFunction.cs | 6 + .../GameFunctions/BoolColorFunction.cs.meta | 11 + Source/GameFunctions/BoolFloatFunction.cs | 6 + .../GameFunctions/BoolFloatFunction.cs.meta | 11 + .../GameFunctions/BoolFunction.cs | 0 .../GameFunctions/BoolFunction.cs.meta | 0 .../GameFunctions/BoolGameObjectFunction.cs | 0 .../BoolGameObjectFunction.cs.meta | 0 Source/GameFunctions/BoolIntFunction.cs | 6 + Source/GameFunctions/BoolIntFunction.cs.meta | 11 + Source/GameFunctions/BoolVector2Function.cs | 6 + .../GameFunctions/BoolVector2Function.cs.meta | 11 + Source/GameFunctions/BoolVector3Function.cs | 6 + .../GameFunctions/BoolVector3Function.cs.meta | 11 + Source/GameFunctions/BoolVoidFunction.cs | 6 + Source/GameFunctions/BoolVoidFunction.cs.meta | 11 + .../GameFunctions/GameObjectFunction.cs | 0 .../GameFunctions/GameObjectFunction.cs.meta | 0 .../GameObjectGameObjectFunction.cs | 0 .../GameObjectGameObjectFunction.cs.meta | 0 .../GameObjectVector3QuaternionFunction.cs | 0 ...ameObjectVector3QuaternionFunction.cs.meta | 0 .../GameFunctions/IntFunction.cs | 0 .../GameFunctions/IntFunction.cs.meta | 0 .../GameFunctions/ScriptableObjectFunction.cs | 0 .../ScriptableObjectFunction.cs.meta | 0 Source/GameObject.meta | 8 + .../GameObject}/GameObjectAction.cs | 0 .../GameObject}/GameObjectAction.cs.meta | 2 +- Source/GameObject/GameObjectEvent.cs | 8 + .../GameObject}/GameObjectEvent.cs.meta | 2 +- .../GameObject/GameObjectGameObjectEvent.cs | 8 + .../GameObjectGameObjectEvent.cs.meta | 2 +- Source/GameObject/GameObjectList.cs | 8 + .../GameObject}/GameObjectList.cs.meta | 2 +- .../GameObject}/GameObjectListAction.cs | 0 .../GameObject}/GameObjectListAction.cs.meta | 2 +- .../GameObject}/GameObjectListener.cs | 3 - .../GameObject}/GameObjectListener.cs.meta | 2 +- .../GameObject}/GameObjectReference.cs | 0 .../GameObject}/GameObjectReference.cs.meta | 2 +- Source/GameObject/GameObjectVariable.cs | 13 + .../GameObject}/GameObjectVariable.cs.meta | 2 +- Source/GameObject/GetUnusedGameObject.cs | 33 + .../GameObject}/GetUnusedGameObject.cs.meta | 2 +- .../GameObject/SetGameObjectVariableValue.cs | 7 + .../SetGameObjectVariableValue.cs.meta | 2 +- Source/GameObject/UnityGameObjectEvent.cs | 9 + .../GameObject/UnityGameObjectEvent.cs.meta | 11 + Source/Int.meta | 8 + Source/Int/ConditionalIntAction.cs | 20 + Source/Int/ConditionalIntAction.cs.meta | 11 + .../GameActions => Source/Int}/IntAction.cs | 0 .../Int}/IntAction.cs.meta | 2 +- Source/Int/IntConstant.cs | 7 + .../Int}/IntConstant.cs.meta | 2 +- Source/Int/IntEvent.cs | 7 + .../Int}/IntEvent.cs.meta | 2 +- Source/Int/IntIntEvent.cs | 8 + .../Int}/IntIntEvent.cs.meta | 2 +- Source/Int/IntList.cs | 7 + .../Lists => Source/Int}/IntList.cs.meta | 2 +- .../Int}/IntListener.cs | 5 - .../Int}/IntListener.cs.meta | 2 +- .../References => Source/Int}/IntReference.cs | 0 .../Int}/IntReference.cs.meta | 2 +- .../Variables => Source/Int}/IntVariable.cs | 5 +- .../Int}/IntVariable.cs.meta | 2 +- Source/Int/SetIntVariableValue.cs | 7 + .../Int}/SetIntVariableValue.cs.meta | 2 +- Source/Int/UnityIntEvent.cs | 8 + Source/Int/UnityIntEvent.cs.meta | 11 + Source/Mobile.meta | 8 + Source/Mobile/TouchUserInput.meta | 8 + .../BoolTouchUserInputFunction.cs | 5 + .../BoolTouchUserInputFunction.cs.meta | 11 + .../ConditionalTouchUserInputAction.cs | 21 + .../ConditionalTouchUserInputAction.cs.meta | 11 + Source/Mobile/TouchUserInput/DetectTap.cs | 102 ++ .../Mobile/TouchUserInput/DetectTap.cs.meta | 11 + .../Mobile/TouchUserInput/TouchUserInput.cs | 38 + .../TouchUserInput/TouchUserInput.cs.meta | 11 + .../TouchUserInput/TouchUserInputAction.cs | 4 + .../TouchUserInputAction.cs.meta | 11 + .../TouchUserInput/TouchUserInputGameEvent.cs | 7 + .../TouchUserInputGameEvent.cs.meta | 11 + .../TouchUserInput/TouchUserInputListener.cs | 5 + .../TouchUserInputListener.cs.meta | 11 + .../TouchUserInputTouchUserInputAction.cs | 4 + ...TouchUserInputTouchUserInputAction.cs.meta | 11 + .../TouchUserInputTouchUserInputGameEvent.cs | 7 + ...chUserInputTouchUserInputGameEvent.cs.meta | 11 + .../TouchUserInputTouchUserInputListener.cs | 5 + ...uchUserInputTouchUserInputListener.cs.meta | 11 + .../TouchUserInput/TouchUserInputVariable.cs | 38 + .../TouchUserInputVariable.cs.meta | 11 + .../UnityTouchUserInputEvent.cs | 12 + .../UnityTouchUserInputEvent.cs.meta | 11 + .../TouchUserInput/UpdateTouchUserInput.cs | 68 + .../UpdateTouchUserInput.cs.meta | 11 + Source/Molecules.meta | 8 + Source/Molecules/Timer.meta | 8 + Source/Molecules/Timer/StartTimer.cs | 16 + Source/Molecules/Timer/StartTimer.cs.meta | 11 + Source/Molecules/Timer/StopTimer.cs | 16 + Source/Molecules/Timer/StopTimer.cs.meta | 11 + Source/Molecules/Timer/Timer.cs | 33 + Source/Molecules/Timer/Timer.cs.meta | 11 + Source/Molecules/Timer/UpdateTimer.cs | 21 + Source/Molecules/Timer/UpdateTimer.cs.meta | 11 + {Assets/UnityAtoms => Source}/MonoHooks.meta | 2 +- .../MonoHooks/Collider2DHook.cs | 0 .../MonoHooks/Collider2DHook.cs.meta | 0 Source/MonoHooks/ColliderHook.cs | 6 + Source/MonoHooks/ColliderHook.cs.meta | 11 + .../MonoHooks/MonoHook.cs | 0 .../MonoHooks/MonoHook.cs.meta | 0 .../MonoHooks/OnAwakeHook.cs | 8 +- .../MonoHooks/OnAwakeHook.cs.meta | 0 Source/MonoHooks/OnButtonClickHook.cs | 23 + Source/MonoHooks/OnButtonClickHook.cs.meta | 11 + .../MonoHooks/OnDestroyHook.cs | 0 .../MonoHooks/OnDestroyHook.cs.meta | 0 .../MonoHooks/OnFixedUpdateHook.cs | 0 .../MonoHooks/OnFixedUpdateHook.cs.meta | 2 +- .../MonoHooks/OnLateUpdateHook.cs | 0 .../MonoHooks/OnLateUpdateHook.cs.meta | 2 +- Source/MonoHooks/OnPointerDownHook.cs | 13 + Source/MonoHooks/OnPointerDownHook.cs.meta | 11 + .../MonoHooks/OnStartHook.cs | 0 .../MonoHooks/OnStartHook.cs.meta | 0 .../MonoHooks/OnTriggerEnter2DHook.cs | 2 +- .../MonoHooks/OnTriggerEnter2DHook.cs.meta | 0 Source/MonoHooks/OnTriggerEnterHook.cs | 12 + Source/MonoHooks/OnTriggerEnterHook.cs.meta | 11 + .../MonoHooks/OnTriggerExit2DHook.cs | 0 .../MonoHooks/OnTriggerExit2DHook.cs.meta | 0 .../MonoHooks/OnTriggerStay2DHook.cs | 0 .../MonoHooks/OnTriggerStay2DHook.cs.meta | 0 Source/MonoHooks/OnTriggerStayHook.cs | 12 + Source/MonoHooks/OnTriggerStayHook.cs.meta | 11 + .../MonoHooks/OnUpdateHook.cs | 0 .../MonoHooks/OnUpdateHook.cs.meta | 2 +- .../MonoHooks/VoidHook.cs | 0 .../MonoHooks/VoidHook.cs.meta | 0 Source/SceneManagement.meta | 8 + .../SceneManagement}/ChangeScene.cs | 42 +- .../SceneManagement}/ChangeScene.cs.meta | 2 +- Source/String.meta | 8 + Source/String/CreateStringVariableOnAwake.cs | 10 + .../CreateStringVariableOnAwake.cs.meta | 11 + Source/String/SetStringVariableValue.cs | 7 + Source/String/SetStringVariableValue.cs.meta | 11 + Source/String/StringAction.cs | 4 + Source/String/StringAction.cs.meta | 11 + Source/String/StringConstant.cs | 7 + .../String}/StringConstant.cs.meta | 2 +- Source/String/StringEvent.cs | 8 + Source/String/StringEvent.cs.meta | 11 + Source/String/StringList.cs | 7 + Source/String/StringList.cs.meta | 11 + Source/String/StringListener.cs | 6 + Source/String/StringListener.cs.meta | 11 + Source/String/StringReference.cs | 8 + Source/String/StringReference.cs.meta | 11 + Source/String/StringStringAction.cs | 4 + Source/String/StringStringAction.cs.meta | 11 + Source/String/StringStringEvent.cs | 8 + Source/String/StringStringEvent.cs.meta | 11 + Source/String/StringStringListener.cs | 6 + Source/String/StringStringListener.cs.meta | 11 + Source/String/StringVariable.cs | 7 + Source/String/StringVariable.cs.meta | 11 + Source/String/StringVariableAction.cs | 4 + Source/String/StringVariableAction.cs.meta | 11 + .../String/StringVariableGameObjectAction.cs | 6 + .../StringVariableGameObjectAction.cs.meta | 11 + Source/String/UnityStringEvent.cs | 11 + Source/String/UnityStringEvent.cs.meta | 11 + Source/UnityAtoms.asmdef | 3 + Source/UnityAtoms.asmdef.meta | 7 + {Assets/UnityAtoms => Source}/Utils.meta | 2 +- Source/Utils/CreateAssetMenuUtils.cs | 19 + Source/Utils/CreateAssetMenuUtils.cs.meta | 11 + .../Utils/DynamicAtoms.cs | 0 .../Utils/DynamicAtoms.cs.meta | 0 .../Utils/Vector2Utils.cs | 4 +- .../Utils/Vector2Utils.cs.meta | 0 Source/Vector2.meta | 8 + Source/Vector2/ConditionalVector2Action.cs | 20 + .../Vector2/ConditionalVector2Action.cs.meta | 11 + .../Vector2}/SetVector2VariableValue.cs | 3 +- .../Vector2}/SetVector2VariableValue.cs.meta | 2 +- Source/Vector2/UnityVector2Event.cs | 9 + Source/Vector2/UnityVector2Event.cs.meta | 11 + .../Vector2}/Vector2Action.cs | 0 .../Vector2}/Vector2Action.cs.meta | 2 +- Source/Vector2/Vector2Constant.cs | 7 + .../Vector2}/Vector2Constant.cs.meta | 2 +- Source/Vector2/Vector2Event.cs | 7 + .../Vector2}/Vector2Event.cs.meta | 2 +- Source/Vector2/Vector2List.cs | 7 + .../Vector2}/Vector2List.cs.meta | 2 +- .../Vector2}/Vector2Listener.cs | 3 - .../Vector2}/Vector2Listener.cs.meta | 2 +- .../Vector2}/Vector2Reference.cs | 0 .../Vector2}/Vector2Reference.cs.meta | 2 +- .../Vector2}/Vector2Variable.cs | 2 +- .../Vector2}/Vector2Variable.cs.meta | 2 +- Source/Vector2/Vector2Vector2Event.cs | 8 + .../Vector2}/Vector2Vector2Event.cs.meta | 2 +- Source/Vector3.meta | 8 + Source/Vector3/ConditionalVector3Action.cs | 20 + .../Vector3/ConditionalVector3Action.cs.meta | 11 + Source/Vector3/SetVector3VariableValue.cs | 7 + .../Vector3}/SetVector3VariableValue.cs.meta | 2 +- Source/Vector3/UnityVector3Event.cs | 9 + Source/Vector3/UnityVector3Event.cs.meta | 11 + .../Vector3}/Vector3Action.cs | 0 .../Vector3}/Vector3Action.cs.meta | 2 +- Source/Vector3/Vector3Constant.cs | 7 + .../Vector3}/Vector3Constant.cs.meta | 2 +- Source/Vector3/Vector3Event.cs | 7 + .../Vector3}/Vector3Event.cs.meta | 2 +- Source/Vector3/Vector3List.cs | 7 + .../Vector3}/Vector3List.cs.meta | 2 +- .../Vector3}/Vector3Listener.cs | 3 - .../Vector3}/Vector3Listener.cs.meta | 2 +- .../Vector3}/Vector3Reference.cs | 0 .../Vector3}/Vector3Reference.cs.meta | 2 +- .../Vector3}/Vector3Variable.cs | 2 +- .../Vector3}/Vector3Variable.cs.meta | 2 +- Source/Vector3/Vector3Vector3Event.cs | 8 + .../Vector3}/Vector3Vector3Event.cs.meta | 2 +- Source/Void.meta | 8 + Source/Void/ConditionalVoidAction.cs | 20 + Source/Void/ConditionalVoidAction.cs.meta | 11 + Source/Void/UnityVoidEvent.cs | 8 + Source/Void/UnityVoidEvent.cs.meta | 11 + Source/Void/UnityVoidGameObjectEvent.cs | 9 + Source/Void/UnityVoidGameObjectEvent.cs.meta | 11 + .../GameEvents => Source/Void}/Void.cs | 0 .../GameEvents => Source/Void}/Void.cs.meta | 2 +- .../GameActions => Source/Void}/VoidAction.cs | 0 .../Void}/VoidAction.cs.meta | 2 +- .../GameEvents => Source/Void}/VoidEvent.cs | 2 +- .../Void}/VoidEvent.cs.meta | 2 +- .../Void}/VoidGameObjectAction.cs | 0 .../Void}/VoidGameObjectAction.cs.meta | 2 +- Source/Void/VoidGameObjectEvent.cs | 7 + .../Void}/VoidGameObjectEvent.cs.meta | 2 +- .../Void}/VoidGameObjectListener.cs | 1 - .../Void}/VoidGameObjectListener.cs.meta | 2 +- .../Void}/VoidListener.cs | 5 - .../Void}/VoidListener.cs.meta | 2 +- Source/package.json | 12 + Source/package.json.meta | 7 + UnityAtomsTestsAndExamples.meta | 8 + UnityAtomsTestsAndExamples/.gitignore | 40 + .../Assembly-CSharp.csproj.meta | 7 + UnityAtomsTestsAndExamples/Assets.meta | 8 + .../Assets}/Examples.meta | 2 +- .../Assets}/Examples/Intro.meta | 2 +- .../Assets}/Examples/Intro/GameObjects.meta | 2 +- .../Examples/Intro/GameObjects/Harmful.meta | 2 +- .../Harmful/DecreasePlayersHealth.asset | 15 + .../Harmful/DecreasePlayersHealth.asset.meta | 2 +- .../Harmful/DecreasePlayersHealth.cs | 43 +- .../Harmful/DecreasePlayersHealth.cs.meta | 2 +- .../Intro/GameObjects/Harmful/Harmful.prefab | 150 +- .../GameObjects/Harmful/Harmful.prefab.meta | 7 + .../Harmful/HarmfulTriggerEvent.asset | 2 +- .../Harmful/HarmfulTriggerEvent.asset.meta | 2 +- .../Intro/GameObjects/HealthListener.meta | 2 +- .../HealthListener/HealthListener.prefab | 32 +- .../HealthListener/HealthListener.prefab.meta | 7 + .../HealthListener/HealthLogger.meta | 2 +- .../HealthLogger/HealthLogger.asset | 14 + .../HealthLogger/HealthLogger.asset.meta | 2 +- .../HealthLogger/HealthLogger.cs | 2 +- .../HealthLogger/HealthLogger.cs.meta | 2 +- .../Intro/GameObjects/OnLevelStart.meta | 2 +- .../OnLevelStart/OnLevelStart.asset | 2 +- .../OnLevelStart/OnLevelStart.asset.meta | 2 +- .../OnLevelStart/OnLevelStart.prefab | 65 +- .../OnLevelStart/OnLevelStart.prefab.meta | 7 + .../OnLevelStart/SetPlayerHealth.asset | 7 +- .../OnLevelStart/SetPlayerHealth.asset.meta | 2 +- .../Assets}/Examples/Intro/Scenes.meta | 2 +- .../Assets/Examples/Intro/Scenes/Intro.unity | 1515 +++++++++++++++++ .../Examples/Intro/Scenes/Intro.unity.meta | 2 +- .../Assets}/Examples/Intro/Scripts.meta | 2 +- .../Examples/Intro/Scripts/HealthBar.cs | 14 + .../Examples/Intro/Scripts/HealthBar.cs.meta | 2 +- .../Examples/Intro/Scripts/PlayerHealth.cs | 0 .../Intro/Scripts/PlayerHealth.cs.meta | 2 +- .../Examples/Intro/Scripts/PlayerMove.cs | 0 .../Examples/Intro/Scripts/PlayerMove.cs.meta | 2 +- .../Examples/Intro/SharedConstants.meta | 2 +- .../Intro/SharedConstants/MaxHealth.asset | 2 +- .../SharedConstants/MaxHealth.asset.meta | 2 +- .../Intro/SharedConstants/TagPlayer.asset | 2 +- .../SharedConstants/TagPlayer.asset.meta | 2 +- .../Intro/SharedConstants/UIState_First.asset | 7 +- .../SharedConstants/UIState_First.asset.meta | 4 +- .../SharedConstants/UIState_Second.asset | 16 + .../SharedConstants/UIState_Second.asset.meta | 4 +- .../Assets}/Examples/Intro/SharedState.meta | 2 +- .../Examples/Intro/SharedState/Health.asset | 11 +- .../Intro/SharedState/Health.asset.meta | 2 +- .../SharedState/HealthChangedEvent.asset | 2 +- .../SharedState/HealthChangedEvent.asset.meta | 2 +- .../Examples/Intro/SharedState/UIState.asset | 19 + .../Intro/SharedState/UIState.asset.meta | 4 +- .../Intro/SharedState/UIStateChanged.asset | 4 +- .../SharedState/UIStateChanged.asset.meta | 8 + .../Assets}/Examples/Intro/Sprites.meta | 2 +- .../Assets}/Examples/Intro/Sprites/Square.png | Bin .../Examples/Intro/Sprites/Square.png.meta | 4 +- .../Assets/Examples/Intro/UI.meta | 8 + .../Assets/Examples/Intro/UI/Button1.meta | 8 + .../Intro/UI/Button1/OnButton1Clicked.asset | 13 + .../UI/Button1/OnButton1Clicked.asset.meta | 8 + .../Intro/UI/Button1/SetUIStateFirst.asset | 19 + .../UI/Button1/SetUIStateFirst.asset.meta | 8 + .../Assets/Examples/Intro/UI/Button2.meta | 8 + .../Intro/UI/Button2/OnButton2Clicked.asset | 13 + .../UI/Button2/OnButton2Clicked.asset.meta | 8 + .../Intro/UI/Button2/SetUIStateSecond.asset | 19 + .../UI/Button2/SetUIStateSecond.asset.meta | 8 + UnityAtomsTestsAndExamples/Assets/Tests.meta | 8 + .../Assets/Tests/AtomicTagTests.cs | 153 ++ .../Assets/Tests/AtomicTagTests.cs.meta | 11 + .../Assets/Tests/ScriptableObjectBaseTest.cs | 35 + .../Tests/ScriptableObjectBaseTest.cs.meta | 11 + .../Assets/Tests/Tests.asmdef | 16 + .../Assets/Tests/Tests.asmdef.meta | 7 + UnityAtomsTestsAndExamples/Library.meta | 8 + UnityAtomsTestsAndExamples/Logs.meta | 8 + .../Logs/Packages-Update.log | 43 + .../Logs/Packages-Update.log.meta | 7 + UnityAtomsTestsAndExamples/Packages.meta | 8 + .../Packages/manifest.json | 11 + .../Packages/manifest.json.meta | 7 + .../ProjectSettings.meta | 8 + .../ProjectSettings}/AudioManager.asset | 0 .../ProjectSettings/AudioManager.asset.meta | 8 + .../ClusterInputManager.asset | 0 .../ClusterInputManager.asset.meta | 8 + .../ProjectSettings}/DynamicsManager.asset | 5 +- .../DynamicsManager.asset.meta | 8 + .../EditorBuildSettings.asset | 0 .../EditorBuildSettings.asset.meta | 8 + .../ProjectSettings}/EditorSettings.asset | 0 .../ProjectSettings/EditorSettings.asset.meta | 8 + .../ProjectSettings}/GraphicsSettings.asset | 3 +- .../GraphicsSettings.asset.meta | 8 + .../ProjectSettings}/InputManager.asset | 0 .../ProjectSettings/InputManager.asset.meta | 8 + .../ProjectSettings}/NavMeshAreas.asset | 0 .../ProjectSettings/NavMeshAreas.asset.meta | 8 + .../ProjectSettings}/NetworkManager.asset | 0 .../ProjectSettings/NetworkManager.asset.meta | 8 + .../ProjectSettings}/Physics2DSettings.asset | 5 +- .../Physics2DSettings.asset.meta | 8 + .../ProjectSettings}/PresetManager.asset | 0 .../ProjectSettings/PresetManager.asset.meta | 8 + .../ProjectSettings}/ProjectSettings.asset | 131 +- .../ProjectSettings.asset.meta | 8 + .../ProjectSettings/ProjectVersion.txt | 1 + .../ProjectSettings/ProjectVersion.txt.meta | 7 + .../ProjectSettings}/QualitySettings.asset | 12 +- .../QualitySettings.asset.meta | 8 + .../ProjectSettings}/TagManager.asset | 0 .../ProjectSettings/TagManager.asset.meta | 8 + .../ProjectSettings}/TimeManager.asset | 0 .../ProjectSettings/TimeManager.asset.meta | 8 + .../UnityConnectSettings.asset | 14 +- .../UnityConnectSettings.asset.meta | 8 + .../ProjectSettings/VFXManager.asset | 11 + .../ProjectSettings/VFXManager.asset.meta | 8 + UnityAtomsTestsAndExamples/Temp.meta | 8 + UnityAtomsTestsAndExamples/Tests.csproj.meta | 7 + .../UnityAtoms.csproj.meta | 7 + .../UnityAtomsEditor.csproj.meta | 7 + .../UnityAtomsTestsAndExamples.sln.meta | 7 + UnityAtomsTestsAndExamples/obj.meta | 8 + UnityAtomsTestsAndExamples/package.json.meta | 7 + omnisharp.json | 6 + omnisharp.json.meta | 7 + package.json | 24 + package.json.meta | 7 + 647 files changed, 6059 insertions(+), 1971 deletions(-) create mode 100644 .editorconfig delete mode 100644 Assets/UnityAtoms/Constants/BoolConstant.cs delete mode 100644 Assets/UnityAtoms/Constants/ColorConstant.cs delete mode 100644 Assets/UnityAtoms/Constants/FloatConstant.cs delete mode 100644 Assets/UnityAtoms/Constants/IntConstant.cs delete mode 100644 Assets/UnityAtoms/Constants/StringConstant.cs delete mode 100644 Assets/UnityAtoms/Constants/Vector2Constant.cs delete mode 100644 Assets/UnityAtoms/Constants/Vector3Constant.cs delete mode 100644 Assets/UnityAtoms/Examples/Intro/Scenes/Intro.unity delete mode 100644 Assets/UnityAtoms/Examples/Intro/Scripts/Harmful.cs delete mode 100644 Assets/UnityAtoms/Examples/Intro/Scripts/HealthBar.cs delete mode 100644 Assets/UnityAtoms/GameActions.meta delete mode 100644 Assets/UnityAtoms/GameActions/ChangeScene.meta delete mode 100644 Assets/UnityAtoms/GameActions/Collider2DGameObjectEventAction.cs delete mode 100644 Assets/UnityAtoms/GameActions/SetVariableValue.meta delete mode 100644 Assets/UnityAtoms/GameActions/SetVariableValue/SetBoolVariableValue.cs delete mode 100644 Assets/UnityAtoms/GameActions/SetVariableValue/SetColorVariableValue.cs delete mode 100644 Assets/UnityAtoms/GameActions/SetVariableValue/SetFloatVariableValue.cs delete mode 100644 Assets/UnityAtoms/GameActions/SetVariableValue/SetGameObjectVariableValue.cs delete mode 100644 Assets/UnityAtoms/GameActions/SetVariableValue/SetIntVariableValue.cs delete mode 100644 Assets/UnityAtoms/GameActions/SetVariableValue/SetVector3VariableValue.cs delete mode 100644 Assets/UnityAtoms/GameEventListeners.meta delete mode 100644 Assets/UnityAtoms/GameEvents.meta delete mode 100644 Assets/UnityAtoms/GameEvents/BoolBoolEvent.cs delete mode 100644 Assets/UnityAtoms/GameEvents/BoolEvent.cs delete mode 100644 Assets/UnityAtoms/GameEvents/Collider2DEvent.cs delete mode 100644 Assets/UnityAtoms/GameEvents/Collider2DGameObjectEvent.cs delete mode 100644 Assets/UnityAtoms/GameEvents/ColorColorEvent.cs delete mode 100644 Assets/UnityAtoms/GameEvents/ColorEvent.cs delete mode 100644 Assets/UnityAtoms/GameEvents/CreateEventOnAwake.meta delete mode 100644 Assets/UnityAtoms/GameEvents/CreateEventOnAwake/CreateCollider2DEventOnAwake.cs delete mode 100644 Assets/UnityAtoms/GameEvents/FloatEvent.cs delete mode 100644 Assets/UnityAtoms/GameEvents/FloatFloatEvent.cs delete mode 100644 Assets/UnityAtoms/GameEvents/GameObjectCollider2DEvent.cs delete mode 100644 Assets/UnityAtoms/GameEvents/GameObjectEvent.cs delete mode 100644 Assets/UnityAtoms/GameEvents/GameObjectGameObjectEvent.cs delete mode 100644 Assets/UnityAtoms/GameEvents/IntEvent.cs delete mode 100644 Assets/UnityAtoms/GameEvents/IntIntEvent.cs delete mode 100644 Assets/UnityAtoms/GameEvents/Vector2Event.cs delete mode 100644 Assets/UnityAtoms/GameEvents/Vector2Vector2Event.cs delete mode 100644 Assets/UnityAtoms/GameEvents/Vector3Event.cs delete mode 100644 Assets/UnityAtoms/GameEvents/Vector3Vector3Event.cs delete mode 100644 Assets/UnityAtoms/GameEvents/VoidGameObjectEvent.cs delete mode 100644 Assets/UnityAtoms/GameFunctions/GetUnusedGameObject.meta delete mode 100644 Assets/UnityAtoms/GameFunctions/GetUnusedGameObject/GetUnusedGameObject.cs delete mode 100644 Assets/UnityAtoms/Lists.meta delete mode 100644 Assets/UnityAtoms/Lists/BoolList.cs delete mode 100644 Assets/UnityAtoms/Lists/Collider2DList.cs delete mode 100644 Assets/UnityAtoms/Lists/ColorList.cs delete mode 100644 Assets/UnityAtoms/Lists/FloatList.cs delete mode 100644 Assets/UnityAtoms/Lists/GameObjectList.cs delete mode 100644 Assets/UnityAtoms/Lists/IntList.cs delete mode 100644 Assets/UnityAtoms/Lists/Vector2List.cs delete mode 100644 Assets/UnityAtoms/Lists/Vector3List.cs delete mode 100644 Assets/UnityAtoms/References.meta delete mode 100644 Assets/UnityAtoms/References/Editor.meta delete mode 100644 Assets/UnityAtoms/UnityEvents.meta delete mode 100644 Assets/UnityAtoms/UnityEvents/UnityEvents.cs delete mode 100644 Assets/UnityAtoms/Variables.meta delete mode 100644 Assets/UnityAtoms/Variables/BoolVariable.cs delete mode 100644 Assets/UnityAtoms/Variables/GameObjectVariable.cs delete mode 100644 Assets/UnityAtoms/Variables/ScriptableObjectVariableBase.cs delete mode 100644 Assets/UnityAtoms/Variables/Utils.meta delete mode 100644 Assets/UnityAtoms/Variables/Utils/VariableUtils.cs delete mode 100644 Assets/UnityAtoms/Variables/Utils/VariableUtils.cs.meta create mode 100644 LICENSE.meta delete mode 100644 Packages/manifest.json delete mode 100644 ProjectSettings/ProjectVersion.txt create mode 100644 README.md.meta rename Assets/UnityAtoms.meta => Source.meta (77%) rename Assets/UnityAtoms/Constants.meta => Source/AtomicTags.meta (77%) create mode 100644 Source/AtomicTags/AtomicTags.cs create mode 100644 Source/AtomicTags/AtomicTags.cs.meta create mode 100644 Source/AtomicTags/ReadOnlyList.cs create mode 100644 Source/AtomicTags/ReadOnlyList.cs.meta rename Assets/UnityAtoms/CreateOnAwake/CreateListOnAwake.meta => Source/AtomicUI.meta (77%) create mode 100644 Source/AtomicUI/UIContainer.cs rename Assets/UnityAtoms/Examples/Intro/Scripts/Harmful.cs.meta => Source/AtomicUI/UIContainer.cs.meta (83%) rename Assets/UnityAtoms/CreateOnAwake/CreateVariableOnAwake.meta => Source/Base.meta (77%) create mode 100644 Source/Base/ConditionalGameActionHelper.cs rename Assets/UnityAtoms/GameActions/Collider2DGameObjectEventAction.cs.meta => Source/Base/ConditionalGameActionHelper.cs.meta (83%) rename {Assets/UnityAtoms => Source/Base}/CreateOnAwake.meta (77%) rename {Assets/UnityAtoms/GameEvents/CreateEventOnAwake => Source/Base/CreateOnAwake}/CreateEventOnAwake.cs (95%) rename {Assets/UnityAtoms/GameEvents/CreateEventOnAwake => Source/Base/CreateOnAwake}/CreateEventOnAwake.cs.meta (83%) rename {Assets/UnityAtoms/CreateOnAwake/CreateListOnAwake => Source/Base/CreateOnAwake}/CreateListOnAwake.cs (89%) rename {Assets/UnityAtoms/CreateOnAwake/CreateListOnAwake => Source/Base/CreateOnAwake}/CreateListOnAwake.cs.meta (83%) rename {Assets/UnityAtoms/CreateOnAwake/CreateVariableOnAwake => Source/Base/CreateOnAwake}/CreateVariableOnAwake.cs (84%) rename {Assets/UnityAtoms/CreateOnAwake/CreateVariableOnAwake => Source/Base/CreateOnAwake}/CreateVariableOnAwake.cs.meta (83%) rename {Assets/UnityAtoms/GameEvents => Source/Base}/GameEvent.cs (97%) rename {Assets/UnityAtoms/GameEvents => Source/Base}/GameEvent.cs.meta (83%) rename {Assets/UnityAtoms/GameEventListeners => Source/Base}/GameEventListener.cs (92%) rename {Assets/UnityAtoms/GameEventListeners => Source/Base}/GameEventListener.cs.meta (83%) rename {Assets/UnityAtoms/GameEvents => Source/Base}/IGameEvent.cs (69%) rename {Assets/UnityAtoms/GameEvents => Source/Base}/IGameEvent.cs.meta (83%) rename {Assets/UnityAtoms/GameEventListeners => Source/Base}/IGameEventListener.cs (100%) rename {Assets/UnityAtoms/GameEventListeners => Source/Base}/IGameEventListener.cs.meta (83%) rename {Assets/UnityAtoms/GameActions => Source/Base}/ScriptableObjectGameAction.cs (88%) rename {Assets/UnityAtoms/GameActions => Source/Base}/ScriptableObjectGameAction.cs.meta (83%) rename {Assets/UnityAtoms/Lists => Source/Base}/ScriptableObjectList.cs (98%) rename {Assets/UnityAtoms/Lists => Source/Base}/ScriptableObjectList.cs.meta (83%) rename {Assets/UnityAtoms/References => Source/Base}/ScriptableObjectReference.cs (100%) rename {Assets/UnityAtoms/References => Source/Base}/ScriptableObjectReference.cs.meta (83%) rename {Assets/UnityAtoms/GameActions/SetVariableValue => Source/Base}/SetVariableValue.cs (85%) rename {Assets/UnityAtoms/GameActions/SetVariableValue => Source/Base}/SetVariableValue.cs.meta (83%) create mode 100644 Source/Base/Variable.meta rename {Assets/UnityAtoms/Variables => Source/Base/Variable}/EquatableScriptableObjectVariable.cs (81%) rename {Assets/UnityAtoms/Variables => Source/Base/Variable}/EquatableScriptableObjectVariable.cs.meta (83%) rename {Assets/UnityAtoms/Variables => Source/Base/Variable}/IWithApplyChange.cs (100%) rename {Assets/UnityAtoms/Variables => Source/Base/Variable}/IWithApplyChange.cs.meta (83%) rename {Assets/UnityAtoms/Variables => Source/Base/Variable}/IWithOldValue.cs (100%) rename {Assets/UnityAtoms/Variables => Source/Base/Variable}/IWithOldValue.cs.meta (83%) rename {Assets/UnityAtoms/Variables => Source/Base/Variable}/IWithValue.cs (100%) rename {Assets/UnityAtoms/Variables => Source/Base/Variable}/IWithValue.cs.meta (83%) rename {Assets/UnityAtoms/Variables => Source/Base/Variable}/ScriptableObjectVariable.cs (89%) rename {Assets/UnityAtoms/Variables => Source/Base/Variable}/ScriptableObjectVariable.cs.meta (83%) create mode 100644 Source/Base/Variable/ScriptableObjectVariableBase.cs rename {Assets/UnityAtoms/Variables => Source/Base/Variable}/ScriptableObjectVariableBase.cs.meta (83%) create mode 100644 Source/Bool.meta rename {Assets/UnityAtoms/GameActions => Source/Bool}/BoolAction.cs (100%) rename {Assets/UnityAtoms/GameActions => Source/Bool}/BoolAction.cs.meta (83%) create mode 100644 Source/Bool/BoolBoolEvent.cs rename {Assets/UnityAtoms/GameEvents => Source/Bool}/BoolBoolEvent.cs.meta (83%) create mode 100644 Source/Bool/BoolConstant.cs rename {Assets/UnityAtoms/Constants => Source/Bool}/BoolConstant.cs.meta (100%) create mode 100644 Source/Bool/BoolEvent.cs rename {Assets/UnityAtoms/GameEvents => Source/Bool}/BoolEvent.cs.meta (83%) create mode 100644 Source/Bool/BoolList.cs rename {Assets/UnityAtoms/Lists => Source/Bool}/BoolList.cs.meta (83%) rename {Assets/UnityAtoms/GameEventListeners => Source/Bool}/BoolListener.cs (56%) rename {Assets/UnityAtoms/GameEventListeners => Source/Bool}/BoolListener.cs.meta (83%) rename {Assets/UnityAtoms/References => Source/Bool}/BoolReference.cs (100%) rename {Assets/UnityAtoms/References => Source/Bool}/BoolReference.cs.meta (83%) create mode 100644 Source/Bool/BoolVariable.cs rename {Assets/UnityAtoms/Variables => Source/Bool}/BoolVariable.cs.meta (83%) create mode 100644 Source/Bool/ConditionalBoolAction.cs rename Assets/UnityAtoms/GameEvents/GameObjectCollider2DEvent.cs.meta => Source/Bool/ConditionalBoolAction.cs.meta (83%) create mode 100644 Source/Bool/SetBoolVariableValue.cs rename {Assets/UnityAtoms/GameActions/SetVariableValue => Source/Bool}/SetBoolVariableValue.cs.meta (83%) create mode 100644 Source/Bool/UnityBoolEvent.cs rename Assets/UnityAtoms/UnityEvents/UnityEvents.cs.meta => Source/Bool/UnityBoolEvent.cs.meta (83%) create mode 100644 Source/Collider.meta create mode 100644 Source/Collider/ColliderEvent.cs create mode 100644 Source/Collider/ColliderEvent.cs.meta create mode 100644 Source/Collider/ColliderGameObjectAction.cs create mode 100644 Source/Collider/ColliderGameObjectAction.cs.meta create mode 100644 Source/Collider/ColliderGameObjectEvent.cs create mode 100644 Source/Collider/ColliderGameObjectEvent.cs.meta create mode 100644 Source/Collider/ColliderGameObjectListener.cs create mode 100644 Source/Collider/ColliderGameObjectListener.cs.meta create mode 100644 Source/Collider/UnityColliderGameObjectEvent.cs create mode 100644 Source/Collider/UnityColliderGameObjectEvent.cs.meta create mode 100644 Source/Collider2D.meta rename {Assets/UnityAtoms/GameActions => Source/Collider2D}/Collider2DAction.cs (100%) rename {Assets/UnityAtoms/GameActions => Source/Collider2D}/Collider2DAction.cs.meta (83%) create mode 100644 Source/Collider2D/Collider2DEvent.cs rename {Assets/UnityAtoms/GameEvents => Source/Collider2D}/Collider2DEvent.cs.meta (83%) rename {Assets/UnityAtoms/GameActions => Source/Collider2D}/Collider2DEventAction.cs (100%) rename {Assets/UnityAtoms/GameActions => Source/Collider2D}/Collider2DEventAction.cs.meta (83%) rename {Assets/UnityAtoms/GameActions => Source/Collider2D}/Collider2DGameObjectAction.cs (100%) rename {Assets/UnityAtoms/GameActions => Source/Collider2D}/Collider2DGameObjectAction.cs.meta (83%) create mode 100644 Source/Collider2D/Collider2DGameObjectEvent.cs rename {Assets/UnityAtoms/GameEvents => Source/Collider2D}/Collider2DGameObjectEvent.cs.meta (83%) rename {Assets/UnityAtoms/GameEventListeners => Source/Collider2D}/Collider2DGameObjectListener.cs (82%) rename {Assets/UnityAtoms/GameEventListeners => Source/Collider2D}/Collider2DGameObjectListener.cs.meta (83%) create mode 100644 Source/Collider2D/Collider2DList.cs rename {Assets/UnityAtoms/Lists => Source/Collider2D}/Collider2DList.cs.meta (83%) rename {Assets/UnityAtoms/GameActions => Source/Collider2D}/Collider2DListAction.cs (100%) rename {Assets/UnityAtoms/GameActions => Source/Collider2D}/Collider2DListAction.cs.meta (83%) rename {Assets/UnityAtoms/GameActions => Source/Collider2D}/Collider2DListGameObjectAction.cs (100%) rename {Assets/UnityAtoms/GameActions => Source/Collider2D}/Collider2DListGameObjectAction.cs.meta (83%) rename {Assets/UnityAtoms/GameEventListeners => Source/Collider2D}/Collider2DListener.cs (70%) rename {Assets/UnityAtoms/GameEventListeners => Source/Collider2D}/Collider2DListener.cs.meta (83%) create mode 100644 Source/Collider2D/CreateCollider2DEventOnAwake.cs rename {Assets/UnityAtoms/GameEvents/CreateEventOnAwake => Source/Collider2D}/CreateCollider2DEventOnAwake.cs.meta (83%) rename {Assets/UnityAtoms/CreateOnAwake/CreateListOnAwake => Source/Collider2D}/CreateCollider2DListOnAwake.cs (100%) rename {Assets/UnityAtoms/CreateOnAwake/CreateListOnAwake => Source/Collider2D}/CreateCollider2DListOnAwake.cs.meta (83%) create mode 100644 Source/Collider2D/UnityCollider2DEvent.cs create mode 100644 Source/Collider2D/UnityCollider2DEvent.cs.meta create mode 100644 Source/Collider2D/UnityCollider2DGameObjectEvent.cs create mode 100644 Source/Collider2D/UnityCollider2DGameObjectEvent.cs.meta create mode 100644 Source/Color.meta rename {Assets/UnityAtoms/GameActions => Source/Color}/ColorAction.cs (100%) rename {Assets/UnityAtoms/GameActions => Source/Color}/ColorAction.cs.meta (83%) create mode 100644 Source/Color/ColorColorEvent.cs rename {Assets/UnityAtoms/GameEvents => Source/Color}/ColorColorEvent.cs.meta (83%) create mode 100644 Source/Color/ColorConstant.cs rename {Assets/UnityAtoms/Constants => Source/Color}/ColorConstant.cs.meta (100%) create mode 100644 Source/Color/ColorEvent.cs rename {Assets/UnityAtoms/GameEvents => Source/Color}/ColorEvent.cs.meta (83%) create mode 100644 Source/Color/ColorList.cs rename {Assets/UnityAtoms/Lists => Source/Color}/ColorList.cs.meta (83%) rename {Assets/UnityAtoms/GameEventListeners => Source/Color}/ColorListener.cs (66%) rename {Assets/UnityAtoms/GameEventListeners => Source/Color}/ColorListener.cs.meta (83%) rename {Assets/UnityAtoms/References => Source/Color}/ColorReference.cs (100%) rename {Assets/UnityAtoms/References => Source/Color}/ColorReference.cs.meta (83%) rename {Assets/UnityAtoms/Variables => Source/Color}/ColorVariable.cs (67%) rename {Assets/UnityAtoms/Variables => Source/Color}/ColorVariable.cs.meta (83%) create mode 100644 Source/Color/ConditionalColorAction.cs create mode 100644 Source/Color/ConditionalColorAction.cs.meta create mode 100644 Source/Color/SetColorVariableValue.cs rename {Assets/UnityAtoms/GameActions/SetVariableValue => Source/Color}/SetColorVariableValue.cs.meta (83%) create mode 100644 Source/Color/UnityColorEvent.cs create mode 100644 Source/Color/UnityColorEvent.cs.meta rename {Assets/UnityAtoms/GameEvents => Source}/Editor.meta (77%) rename {Assets/UnityAtoms/GameEvents => Source}/Editor/GameEventEditor.cs (100%) rename {Assets/UnityAtoms/GameEvents => Source}/Editor/GameEventEditor.cs.meta (83%) rename {Assets/UnityAtoms/References => Source}/Editor/ReferenceDrawer.cs (95%) rename {Assets/UnityAtoms/References => Source}/Editor/ReferenceDrawer.cs.meta (83%) create mode 100644 Source/Editor/UnityAtomsEditor.asmdef create mode 100644 Source/Editor/UnityAtomsEditor.asmdef.meta rename {Assets/UnityAtoms => Source}/Extensions.meta (77%) create mode 100644 Source/Extensions/ArrayExtensions.cs create mode 100644 Source/Extensions/ArrayExtensions.cs.meta create mode 100644 Source/Extensions/CameraExtensions.cs create mode 100644 Source/Extensions/CameraExtensions.cs.meta create mode 100644 Source/Extensions/GameObjectExtensions.cs create mode 100644 Source/Extensions/GameObjectExtensions.cs.meta create mode 100644 Source/Extensions/ListExtensions.cs create mode 100644 Source/Extensions/ListExtensions.cs.meta create mode 100644 Source/Extensions/MonoBehaviourExtensions.cs create mode 100644 Source/Extensions/MonoBehaviourExtensions.cs.meta create mode 100644 Source/Extensions/TransformExtensions.cs create mode 100644 Source/Extensions/TransformExtensions.cs.meta rename {Assets/UnityAtoms => Source}/Extensions/Vector2Extensions.cs (94%) rename {Assets/UnityAtoms => Source}/Extensions/Vector2Extensions.cs.meta (83%) rename {Assets/UnityAtoms => Source}/Extensions/Vector3Extensions.cs (53%) rename {Assets/UnityAtoms => Source}/Extensions/Vector3Extensions.cs.meta (83%) create mode 100644 Source/Float.meta create mode 100644 Source/Float/ConditionalFloatAction.cs create mode 100644 Source/Float/ConditionalFloatAction.cs.meta rename {Assets/UnityAtoms/GameActions => Source/Float}/FloatAction.cs (100%) rename {Assets/UnityAtoms/GameActions => Source/Float}/FloatAction.cs.meta (83%) create mode 100644 Source/Float/FloatConstant.cs rename {Assets/UnityAtoms/Constants => Source/Float}/FloatConstant.cs.meta (83%) create mode 100644 Source/Float/FloatEvent.cs rename {Assets/UnityAtoms/GameEvents => Source/Float}/FloatEvent.cs.meta (83%) create mode 100644 Source/Float/FloatFloatEvent.cs rename {Assets/UnityAtoms/GameEvents => Source/Float}/FloatFloatEvent.cs.meta (83%) create mode 100644 Source/Float/FloatList.cs rename {Assets/UnityAtoms/Lists => Source/Float}/FloatList.cs.meta (83%) rename {Assets/UnityAtoms/GameEventListeners => Source/Float}/FloatListener.cs (57%) rename {Assets/UnityAtoms/GameEventListeners => Source/Float}/FloatListener.cs.meta (83%) rename {Assets/UnityAtoms/References => Source/Float}/FloatReference.cs (100%) rename {Assets/UnityAtoms/References => Source/Float}/FloatReference.cs.meta (83%) rename {Assets/UnityAtoms/Variables => Source/Float}/FloatVariable.cs (64%) rename {Assets/UnityAtoms/Variables => Source/Float}/FloatVariable.cs.meta (83%) create mode 100644 Source/Float/SetFloatVariableValue.cs rename {Assets/UnityAtoms/GameActions/SetVariableValue => Source/Float}/SetFloatVariableValue.cs.meta (83%) create mode 100644 Source/Float/UnityFloatEvent.cs create mode 100644 Source/Float/UnityFloatEvent.cs.meta rename {Assets/UnityAtoms => Source}/GameFunctions.meta (77%) create mode 100644 Source/GameFunctions/BoolBoolFunction.cs create mode 100644 Source/GameFunctions/BoolBoolFunction.cs.meta create mode 100644 Source/GameFunctions/BoolColorFunction.cs create mode 100644 Source/GameFunctions/BoolColorFunction.cs.meta create mode 100644 Source/GameFunctions/BoolFloatFunction.cs create mode 100644 Source/GameFunctions/BoolFloatFunction.cs.meta rename {Assets/UnityAtoms => Source}/GameFunctions/BoolFunction.cs (100%) rename {Assets/UnityAtoms => Source}/GameFunctions/BoolFunction.cs.meta (100%) rename {Assets/UnityAtoms => Source}/GameFunctions/BoolGameObjectFunction.cs (100%) rename {Assets/UnityAtoms => Source}/GameFunctions/BoolGameObjectFunction.cs.meta (100%) create mode 100644 Source/GameFunctions/BoolIntFunction.cs create mode 100644 Source/GameFunctions/BoolIntFunction.cs.meta create mode 100644 Source/GameFunctions/BoolVector2Function.cs create mode 100644 Source/GameFunctions/BoolVector2Function.cs.meta create mode 100644 Source/GameFunctions/BoolVector3Function.cs create mode 100644 Source/GameFunctions/BoolVector3Function.cs.meta create mode 100644 Source/GameFunctions/BoolVoidFunction.cs create mode 100644 Source/GameFunctions/BoolVoidFunction.cs.meta rename {Assets/UnityAtoms => Source}/GameFunctions/GameObjectFunction.cs (100%) rename {Assets/UnityAtoms => Source}/GameFunctions/GameObjectFunction.cs.meta (100%) rename {Assets/UnityAtoms => Source}/GameFunctions/GameObjectGameObjectFunction.cs (100%) rename {Assets/UnityAtoms => Source}/GameFunctions/GameObjectGameObjectFunction.cs.meta (100%) rename {Assets/UnityAtoms => Source}/GameFunctions/GameObjectVector3QuaternionFunction.cs (100%) rename {Assets/UnityAtoms => Source}/GameFunctions/GameObjectVector3QuaternionFunction.cs.meta (100%) rename {Assets/UnityAtoms => Source}/GameFunctions/IntFunction.cs (100%) rename {Assets/UnityAtoms => Source}/GameFunctions/IntFunction.cs.meta (100%) rename {Assets/UnityAtoms => Source}/GameFunctions/ScriptableObjectFunction.cs (100%) rename {Assets/UnityAtoms => Source}/GameFunctions/ScriptableObjectFunction.cs.meta (100%) create mode 100644 Source/GameObject.meta rename {Assets/UnityAtoms/GameActions => Source/GameObject}/GameObjectAction.cs (100%) rename {Assets/UnityAtoms/GameActions => Source/GameObject}/GameObjectAction.cs.meta (83%) create mode 100644 Source/GameObject/GameObjectEvent.cs rename {Assets/UnityAtoms/GameEvents => Source/GameObject}/GameObjectEvent.cs.meta (83%) create mode 100644 Source/GameObject/GameObjectGameObjectEvent.cs rename {Assets/UnityAtoms/GameEvents => Source/GameObject}/GameObjectGameObjectEvent.cs.meta (83%) create mode 100644 Source/GameObject/GameObjectList.cs rename {Assets/UnityAtoms/Lists => Source/GameObject}/GameObjectList.cs.meta (83%) rename {Assets/UnityAtoms/GameActions => Source/GameObject}/GameObjectListAction.cs (100%) rename {Assets/UnityAtoms/GameActions => Source/GameObject}/GameObjectListAction.cs.meta (83%) rename {Assets/UnityAtoms/GameEventListeners => Source/GameObject}/GameObjectListener.cs (70%) rename {Assets/UnityAtoms/GameEventListeners => Source/GameObject}/GameObjectListener.cs.meta (83%) rename {Assets/UnityAtoms/References => Source/GameObject}/GameObjectReference.cs (100%) rename {Assets/UnityAtoms/References => Source/GameObject}/GameObjectReference.cs.meta (83%) create mode 100644 Source/GameObject/GameObjectVariable.cs rename {Assets/UnityAtoms/Variables => Source/GameObject}/GameObjectVariable.cs.meta (83%) create mode 100644 Source/GameObject/GetUnusedGameObject.cs rename {Assets/UnityAtoms/GameFunctions/GetUnusedGameObject => Source/GameObject}/GetUnusedGameObject.cs.meta (83%) create mode 100644 Source/GameObject/SetGameObjectVariableValue.cs rename {Assets/UnityAtoms/GameActions/SetVariableValue => Source/GameObject}/SetGameObjectVariableValue.cs.meta (83%) create mode 100644 Source/GameObject/UnityGameObjectEvent.cs create mode 100644 Source/GameObject/UnityGameObjectEvent.cs.meta create mode 100644 Source/Int.meta create mode 100644 Source/Int/ConditionalIntAction.cs create mode 100644 Source/Int/ConditionalIntAction.cs.meta rename {Assets/UnityAtoms/GameActions => Source/Int}/IntAction.cs (100%) rename {Assets/UnityAtoms/GameActions => Source/Int}/IntAction.cs.meta (83%) create mode 100644 Source/Int/IntConstant.cs rename {Assets/UnityAtoms/Constants => Source/Int}/IntConstant.cs.meta (83%) create mode 100644 Source/Int/IntEvent.cs rename {Assets/UnityAtoms/GameEvents => Source/Int}/IntEvent.cs.meta (83%) create mode 100644 Source/Int/IntIntEvent.cs rename {Assets/UnityAtoms/GameEvents => Source/Int}/IntIntEvent.cs.meta (83%) create mode 100644 Source/Int/IntList.cs rename {Assets/UnityAtoms/Lists => Source/Int}/IntList.cs.meta (83%) rename {Assets/UnityAtoms/GameEventListeners => Source/Int}/IntListener.cs (55%) rename {Assets/UnityAtoms/GameEventListeners => Source/Int}/IntListener.cs.meta (83%) rename {Assets/UnityAtoms/References => Source/Int}/IntReference.cs (100%) rename {Assets/UnityAtoms/References => Source/Int}/IntReference.cs.meta (83%) rename {Assets/UnityAtoms/Variables => Source/Int}/IntVariable.cs (66%) rename {Assets/UnityAtoms/Variables => Source/Int}/IntVariable.cs.meta (83%) create mode 100644 Source/Int/SetIntVariableValue.cs rename {Assets/UnityAtoms/GameActions/SetVariableValue => Source/Int}/SetIntVariableValue.cs.meta (83%) create mode 100644 Source/Int/UnityIntEvent.cs create mode 100644 Source/Int/UnityIntEvent.cs.meta create mode 100644 Source/Mobile.meta create mode 100644 Source/Mobile/TouchUserInput.meta create mode 100644 Source/Mobile/TouchUserInput/BoolTouchUserInputFunction.cs create mode 100644 Source/Mobile/TouchUserInput/BoolTouchUserInputFunction.cs.meta create mode 100644 Source/Mobile/TouchUserInput/ConditionalTouchUserInputAction.cs create mode 100644 Source/Mobile/TouchUserInput/ConditionalTouchUserInputAction.cs.meta create mode 100644 Source/Mobile/TouchUserInput/DetectTap.cs create mode 100644 Source/Mobile/TouchUserInput/DetectTap.cs.meta create mode 100644 Source/Mobile/TouchUserInput/TouchUserInput.cs create mode 100644 Source/Mobile/TouchUserInput/TouchUserInput.cs.meta create mode 100644 Source/Mobile/TouchUserInput/TouchUserInputAction.cs create mode 100644 Source/Mobile/TouchUserInput/TouchUserInputAction.cs.meta create mode 100644 Source/Mobile/TouchUserInput/TouchUserInputGameEvent.cs create mode 100644 Source/Mobile/TouchUserInput/TouchUserInputGameEvent.cs.meta create mode 100644 Source/Mobile/TouchUserInput/TouchUserInputListener.cs create mode 100644 Source/Mobile/TouchUserInput/TouchUserInputListener.cs.meta create mode 100644 Source/Mobile/TouchUserInput/TouchUserInputTouchUserInputAction.cs create mode 100644 Source/Mobile/TouchUserInput/TouchUserInputTouchUserInputAction.cs.meta create mode 100644 Source/Mobile/TouchUserInput/TouchUserInputTouchUserInputGameEvent.cs create mode 100644 Source/Mobile/TouchUserInput/TouchUserInputTouchUserInputGameEvent.cs.meta create mode 100644 Source/Mobile/TouchUserInput/TouchUserInputTouchUserInputListener.cs create mode 100644 Source/Mobile/TouchUserInput/TouchUserInputTouchUserInputListener.cs.meta create mode 100644 Source/Mobile/TouchUserInput/TouchUserInputVariable.cs create mode 100644 Source/Mobile/TouchUserInput/TouchUserInputVariable.cs.meta create mode 100644 Source/Mobile/TouchUserInput/UnityTouchUserInputEvent.cs create mode 100644 Source/Mobile/TouchUserInput/UnityTouchUserInputEvent.cs.meta create mode 100644 Source/Mobile/TouchUserInput/UpdateTouchUserInput.cs create mode 100644 Source/Mobile/TouchUserInput/UpdateTouchUserInput.cs.meta create mode 100644 Source/Molecules.meta create mode 100644 Source/Molecules/Timer.meta create mode 100644 Source/Molecules/Timer/StartTimer.cs create mode 100644 Source/Molecules/Timer/StartTimer.cs.meta create mode 100644 Source/Molecules/Timer/StopTimer.cs create mode 100644 Source/Molecules/Timer/StopTimer.cs.meta create mode 100644 Source/Molecules/Timer/Timer.cs create mode 100644 Source/Molecules/Timer/Timer.cs.meta create mode 100644 Source/Molecules/Timer/UpdateTimer.cs create mode 100644 Source/Molecules/Timer/UpdateTimer.cs.meta rename {Assets/UnityAtoms => Source}/MonoHooks.meta (77%) rename {Assets/UnityAtoms => Source}/MonoHooks/Collider2DHook.cs (100%) rename {Assets/UnityAtoms => Source}/MonoHooks/Collider2DHook.cs.meta (100%) create mode 100644 Source/MonoHooks/ColliderHook.cs create mode 100644 Source/MonoHooks/ColliderHook.cs.meta rename {Assets/UnityAtoms => Source}/MonoHooks/MonoHook.cs (100%) rename {Assets/UnityAtoms => Source}/MonoHooks/MonoHook.cs.meta (100%) rename {Assets/UnityAtoms => Source}/MonoHooks/OnAwakeHook.cs (77%) rename {Assets/UnityAtoms => Source}/MonoHooks/OnAwakeHook.cs.meta (100%) create mode 100644 Source/MonoHooks/OnButtonClickHook.cs create mode 100644 Source/MonoHooks/OnButtonClickHook.cs.meta rename {Assets/UnityAtoms => Source}/MonoHooks/OnDestroyHook.cs (100%) rename {Assets/UnityAtoms => Source}/MonoHooks/OnDestroyHook.cs.meta (100%) rename {Assets/UnityAtoms => Source}/MonoHooks/OnFixedUpdateHook.cs (100%) rename {Assets/UnityAtoms => Source}/MonoHooks/OnFixedUpdateHook.cs.meta (83%) rename {Assets/UnityAtoms => Source}/MonoHooks/OnLateUpdateHook.cs (100%) rename {Assets/UnityAtoms => Source}/MonoHooks/OnLateUpdateHook.cs.meta (83%) create mode 100644 Source/MonoHooks/OnPointerDownHook.cs create mode 100644 Source/MonoHooks/OnPointerDownHook.cs.meta rename {Assets/UnityAtoms => Source}/MonoHooks/OnStartHook.cs (100%) rename {Assets/UnityAtoms => Source}/MonoHooks/OnStartHook.cs.meta (100%) rename {Assets/UnityAtoms => Source}/MonoHooks/OnTriggerEnter2DHook.cs (99%) rename {Assets/UnityAtoms => Source}/MonoHooks/OnTriggerEnter2DHook.cs.meta (100%) create mode 100644 Source/MonoHooks/OnTriggerEnterHook.cs create mode 100644 Source/MonoHooks/OnTriggerEnterHook.cs.meta rename {Assets/UnityAtoms => Source}/MonoHooks/OnTriggerExit2DHook.cs (100%) rename {Assets/UnityAtoms => Source}/MonoHooks/OnTriggerExit2DHook.cs.meta (100%) rename {Assets/UnityAtoms => Source}/MonoHooks/OnTriggerStay2DHook.cs (100%) rename {Assets/UnityAtoms => Source}/MonoHooks/OnTriggerStay2DHook.cs.meta (100%) create mode 100644 Source/MonoHooks/OnTriggerStayHook.cs create mode 100644 Source/MonoHooks/OnTriggerStayHook.cs.meta rename {Assets/UnityAtoms => Source}/MonoHooks/OnUpdateHook.cs (100%) rename {Assets/UnityAtoms => Source}/MonoHooks/OnUpdateHook.cs.meta (83%) rename {Assets/UnityAtoms => Source}/MonoHooks/VoidHook.cs (100%) rename {Assets/UnityAtoms => Source}/MonoHooks/VoidHook.cs.meta (100%) create mode 100644 Source/SceneManagement.meta rename {Assets/UnityAtoms/GameActions/ChangeScene => Source/SceneManagement}/ChangeScene.cs (58%) rename {Assets/UnityAtoms/GameActions/ChangeScene => Source/SceneManagement}/ChangeScene.cs.meta (83%) create mode 100644 Source/String.meta create mode 100644 Source/String/CreateStringVariableOnAwake.cs create mode 100644 Source/String/CreateStringVariableOnAwake.cs.meta create mode 100644 Source/String/SetStringVariableValue.cs create mode 100644 Source/String/SetStringVariableValue.cs.meta create mode 100644 Source/String/StringAction.cs create mode 100644 Source/String/StringAction.cs.meta create mode 100644 Source/String/StringConstant.cs rename {Assets/UnityAtoms/Constants => Source/String}/StringConstant.cs.meta (83%) create mode 100644 Source/String/StringEvent.cs create mode 100644 Source/String/StringEvent.cs.meta create mode 100644 Source/String/StringList.cs create mode 100644 Source/String/StringList.cs.meta create mode 100644 Source/String/StringListener.cs create mode 100644 Source/String/StringListener.cs.meta create mode 100644 Source/String/StringReference.cs create mode 100644 Source/String/StringReference.cs.meta create mode 100644 Source/String/StringStringAction.cs create mode 100644 Source/String/StringStringAction.cs.meta create mode 100644 Source/String/StringStringEvent.cs create mode 100644 Source/String/StringStringEvent.cs.meta create mode 100644 Source/String/StringStringListener.cs create mode 100644 Source/String/StringStringListener.cs.meta create mode 100644 Source/String/StringVariable.cs create mode 100644 Source/String/StringVariable.cs.meta create mode 100644 Source/String/StringVariableAction.cs create mode 100644 Source/String/StringVariableAction.cs.meta create mode 100644 Source/String/StringVariableGameObjectAction.cs create mode 100644 Source/String/StringVariableGameObjectAction.cs.meta create mode 100644 Source/String/UnityStringEvent.cs create mode 100644 Source/String/UnityStringEvent.cs.meta create mode 100644 Source/UnityAtoms.asmdef create mode 100644 Source/UnityAtoms.asmdef.meta rename {Assets/UnityAtoms => Source}/Utils.meta (77%) create mode 100644 Source/Utils/CreateAssetMenuUtils.cs create mode 100644 Source/Utils/CreateAssetMenuUtils.cs.meta rename {Assets/UnityAtoms => Source}/Utils/DynamicAtoms.cs (100%) rename {Assets/UnityAtoms => Source}/Utils/DynamicAtoms.cs.meta (100%) rename {Assets/UnityAtoms => Source}/Utils/Vector2Utils.cs (87%) rename {Assets/UnityAtoms => Source}/Utils/Vector2Utils.cs.meta (100%) create mode 100644 Source/Vector2.meta create mode 100644 Source/Vector2/ConditionalVector2Action.cs create mode 100644 Source/Vector2/ConditionalVector2Action.cs.meta rename {Assets/UnityAtoms/GameActions/SetVariableValue => Source/Vector2}/SetVector2VariableValue.cs (53%) rename {Assets/UnityAtoms/GameActions/SetVariableValue => Source/Vector2}/SetVector2VariableValue.cs.meta (83%) create mode 100644 Source/Vector2/UnityVector2Event.cs create mode 100644 Source/Vector2/UnityVector2Event.cs.meta rename {Assets/UnityAtoms/GameActions => Source/Vector2}/Vector2Action.cs (100%) rename {Assets/UnityAtoms/GameActions => Source/Vector2}/Vector2Action.cs.meta (83%) create mode 100644 Source/Vector2/Vector2Constant.cs rename {Assets/UnityAtoms/Constants => Source/Vector2}/Vector2Constant.cs.meta (83%) create mode 100644 Source/Vector2/Vector2Event.cs rename {Assets/UnityAtoms/GameEvents => Source/Vector2}/Vector2Event.cs.meta (83%) create mode 100644 Source/Vector2/Vector2List.cs rename {Assets/UnityAtoms/Lists => Source/Vector2}/Vector2List.cs.meta (83%) rename {Assets/UnityAtoms/GameEventListeners => Source/Vector2}/Vector2Listener.cs (68%) rename {Assets/UnityAtoms/GameEventListeners => Source/Vector2}/Vector2Listener.cs.meta (83%) rename {Assets/UnityAtoms/References => Source/Vector2}/Vector2Reference.cs (100%) rename {Assets/UnityAtoms/References => Source/Vector2}/Vector2Reference.cs.meta (83%) rename {Assets/UnityAtoms/Variables => Source/Vector2}/Vector2Variable.cs (67%) rename {Assets/UnityAtoms/Variables => Source/Vector2}/Vector2Variable.cs.meta (83%) create mode 100644 Source/Vector2/Vector2Vector2Event.cs rename {Assets/UnityAtoms/GameEvents => Source/Vector2}/Vector2Vector2Event.cs.meta (83%) create mode 100644 Source/Vector3.meta create mode 100644 Source/Vector3/ConditionalVector3Action.cs create mode 100644 Source/Vector3/ConditionalVector3Action.cs.meta create mode 100644 Source/Vector3/SetVector3VariableValue.cs rename {Assets/UnityAtoms/GameActions/SetVariableValue => Source/Vector3}/SetVector3VariableValue.cs.meta (83%) create mode 100644 Source/Vector3/UnityVector3Event.cs create mode 100644 Source/Vector3/UnityVector3Event.cs.meta rename {Assets/UnityAtoms/GameActions => Source/Vector3}/Vector3Action.cs (100%) rename {Assets/UnityAtoms/GameActions => Source/Vector3}/Vector3Action.cs.meta (83%) create mode 100644 Source/Vector3/Vector3Constant.cs rename {Assets/UnityAtoms/Constants => Source/Vector3}/Vector3Constant.cs.meta (83%) create mode 100644 Source/Vector3/Vector3Event.cs rename {Assets/UnityAtoms/GameEvents => Source/Vector3}/Vector3Event.cs.meta (83%) create mode 100644 Source/Vector3/Vector3List.cs rename {Assets/UnityAtoms/Lists => Source/Vector3}/Vector3List.cs.meta (83%) rename {Assets/UnityAtoms/GameEventListeners => Source/Vector3}/Vector3Listener.cs (68%) rename {Assets/UnityAtoms/GameEventListeners => Source/Vector3}/Vector3Listener.cs.meta (83%) rename {Assets/UnityAtoms/References => Source/Vector3}/Vector3Reference.cs (100%) rename {Assets/UnityAtoms/References => Source/Vector3}/Vector3Reference.cs.meta (83%) rename {Assets/UnityAtoms/Variables => Source/Vector3}/Vector3Variable.cs (67%) rename {Assets/UnityAtoms/Variables => Source/Vector3}/Vector3Variable.cs.meta (83%) create mode 100644 Source/Vector3/Vector3Vector3Event.cs rename {Assets/UnityAtoms/GameEvents => Source/Vector3}/Vector3Vector3Event.cs.meta (83%) create mode 100644 Source/Void.meta create mode 100644 Source/Void/ConditionalVoidAction.cs create mode 100644 Source/Void/ConditionalVoidAction.cs.meta create mode 100644 Source/Void/UnityVoidEvent.cs create mode 100644 Source/Void/UnityVoidEvent.cs.meta create mode 100644 Source/Void/UnityVoidGameObjectEvent.cs create mode 100644 Source/Void/UnityVoidGameObjectEvent.cs.meta rename {Assets/UnityAtoms/GameEvents => Source/Void}/Void.cs (100%) rename {Assets/UnityAtoms/GameEvents => Source/Void}/Void.cs.meta (83%) rename {Assets/UnityAtoms/GameActions => Source/Void}/VoidAction.cs (100%) rename {Assets/UnityAtoms/GameActions => Source/Void}/VoidAction.cs.meta (83%) rename {Assets/UnityAtoms/GameEvents => Source/Void}/VoidEvent.cs (59%) rename {Assets/UnityAtoms/GameEvents => Source/Void}/VoidEvent.cs.meta (83%) rename {Assets/UnityAtoms/GameActions => Source/Void}/VoidGameObjectAction.cs (100%) rename {Assets/UnityAtoms/GameActions => Source/Void}/VoidGameObjectAction.cs.meta (83%) create mode 100644 Source/Void/VoidGameObjectEvent.cs rename {Assets/UnityAtoms/GameEvents => Source/Void}/VoidGameObjectEvent.cs.meta (83%) rename {Assets/UnityAtoms/GameEventListeners => Source/Void}/VoidGameObjectListener.cs (93%) rename {Assets/UnityAtoms/GameEventListeners => Source/Void}/VoidGameObjectListener.cs.meta (83%) rename {Assets/UnityAtoms/GameEventListeners => Source/Void}/VoidListener.cs (56%) rename {Assets/UnityAtoms/GameEventListeners => Source/Void}/VoidListener.cs.meta (83%) create mode 100644 Source/package.json create mode 100644 Source/package.json.meta create mode 100644 UnityAtomsTestsAndExamples.meta create mode 100644 UnityAtomsTestsAndExamples/.gitignore create mode 100644 UnityAtomsTestsAndExamples/Assembly-CSharp.csproj.meta create mode 100644 UnityAtomsTestsAndExamples/Assets.meta rename {Assets/UnityAtoms => UnityAtomsTestsAndExamples/Assets}/Examples.meta (77%) rename {Assets/UnityAtoms => UnityAtomsTestsAndExamples/Assets}/Examples/Intro.meta (77%) rename {Assets/UnityAtoms => UnityAtomsTestsAndExamples/Assets}/Examples/Intro/GameObjects.meta (77%) rename {Assets/UnityAtoms => UnityAtomsTestsAndExamples/Assets}/Examples/Intro/GameObjects/Harmful.meta (77%) create mode 100644 UnityAtomsTestsAndExamples/Assets/Examples/Intro/GameObjects/Harmful/DecreasePlayersHealth.asset rename {Assets/UnityAtoms => UnityAtomsTestsAndExamples/Assets}/Examples/Intro/GameObjects/Harmful/DecreasePlayersHealth.asset.meta (79%) rename {Assets/UnityAtoms => UnityAtomsTestsAndExamples/Assets}/Examples/Intro/GameObjects/Harmful/DecreasePlayersHealth.cs (63%) rename {Assets/UnityAtoms => UnityAtomsTestsAndExamples/Assets}/Examples/Intro/GameObjects/Harmful/DecreasePlayersHealth.cs.meta (83%) rename {Assets/UnityAtoms => UnityAtomsTestsAndExamples/Assets}/Examples/Intro/GameObjects/Harmful/Harmful.prefab (73%) create mode 100644 UnityAtomsTestsAndExamples/Assets/Examples/Intro/GameObjects/Harmful/Harmful.prefab.meta rename {Assets/UnityAtoms => UnityAtomsTestsAndExamples/Assets}/Examples/Intro/GameObjects/Harmful/HarmfulTriggerEvent.asset (78%) rename {Assets/UnityAtoms => UnityAtomsTestsAndExamples/Assets}/Examples/Intro/GameObjects/Harmful/HarmfulTriggerEvent.asset.meta (79%) rename {Assets/UnityAtoms => UnityAtomsTestsAndExamples/Assets}/Examples/Intro/GameObjects/HealthListener.meta (77%) rename {Assets/UnityAtoms => UnityAtomsTestsAndExamples/Assets}/Examples/Intro/GameObjects/HealthListener/HealthListener.prefab (65%) create mode 100644 UnityAtomsTestsAndExamples/Assets/Examples/Intro/GameObjects/HealthListener/HealthListener.prefab.meta rename {Assets/UnityAtoms => UnityAtomsTestsAndExamples/Assets}/Examples/Intro/GameObjects/HealthListener/HealthLogger.meta (77%) create mode 100644 UnityAtomsTestsAndExamples/Assets/Examples/Intro/GameObjects/HealthListener/HealthLogger/HealthLogger.asset rename {Assets/UnityAtoms => UnityAtomsTestsAndExamples/Assets}/Examples/Intro/GameObjects/HealthListener/HealthLogger/HealthLogger.asset.meta (79%) rename {Assets/UnityAtoms => UnityAtomsTestsAndExamples/Assets}/Examples/Intro/GameObjects/HealthListener/HealthLogger/HealthLogger.cs (67%) rename {Assets/UnityAtoms => UnityAtomsTestsAndExamples/Assets}/Examples/Intro/GameObjects/HealthListener/HealthLogger/HealthLogger.cs.meta (83%) rename {Assets/UnityAtoms => UnityAtomsTestsAndExamples/Assets}/Examples/Intro/GameObjects/OnLevelStart.meta (77%) rename {Assets/UnityAtoms => UnityAtomsTestsAndExamples/Assets}/Examples/Intro/GameObjects/OnLevelStart/OnLevelStart.asset (78%) rename {Assets/UnityAtoms => UnityAtomsTestsAndExamples/Assets}/Examples/Intro/GameObjects/OnLevelStart/OnLevelStart.asset.meta (79%) rename {Assets/UnityAtoms => UnityAtomsTestsAndExamples/Assets}/Examples/Intro/GameObjects/OnLevelStart/OnLevelStart.prefab (62%) create mode 100644 UnityAtomsTestsAndExamples/Assets/Examples/Intro/GameObjects/OnLevelStart/OnLevelStart.prefab.meta rename {Assets/UnityAtoms => UnityAtomsTestsAndExamples/Assets}/Examples/Intro/GameObjects/OnLevelStart/SetPlayerHealth.asset (60%) rename {Assets/UnityAtoms => UnityAtomsTestsAndExamples/Assets}/Examples/Intro/GameObjects/OnLevelStart/SetPlayerHealth.asset.meta (79%) rename {Assets/UnityAtoms => UnityAtomsTestsAndExamples/Assets}/Examples/Intro/Scenes.meta (77%) create mode 100644 UnityAtomsTestsAndExamples/Assets/Examples/Intro/Scenes/Intro.unity rename {Assets/UnityAtoms => UnityAtomsTestsAndExamples/Assets}/Examples/Intro/Scenes/Intro.unity.meta (74%) rename {Assets/UnityAtoms => UnityAtomsTestsAndExamples/Assets}/Examples/Intro/Scripts.meta (77%) create mode 100644 UnityAtomsTestsAndExamples/Assets/Examples/Intro/Scripts/HealthBar.cs rename {Assets/UnityAtoms => UnityAtomsTestsAndExamples/Assets}/Examples/Intro/Scripts/HealthBar.cs.meta (83%) rename {Assets/UnityAtoms => UnityAtomsTestsAndExamples/Assets}/Examples/Intro/Scripts/PlayerHealth.cs (100%) rename {Assets/UnityAtoms => UnityAtomsTestsAndExamples/Assets}/Examples/Intro/Scripts/PlayerHealth.cs.meta (83%) rename {Assets/UnityAtoms => UnityAtomsTestsAndExamples/Assets}/Examples/Intro/Scripts/PlayerMove.cs (100%) rename {Assets/UnityAtoms => UnityAtomsTestsAndExamples/Assets}/Examples/Intro/Scripts/PlayerMove.cs.meta (83%) rename {Assets/UnityAtoms => UnityAtomsTestsAndExamples/Assets}/Examples/Intro/SharedConstants.meta (77%) rename {Assets/UnityAtoms => UnityAtomsTestsAndExamples/Assets}/Examples/Intro/SharedConstants/MaxHealth.asset (80%) rename {Assets/UnityAtoms => UnityAtomsTestsAndExamples/Assets}/Examples/Intro/SharedConstants/MaxHealth.asset.meta (79%) rename {Assets/UnityAtoms => UnityAtomsTestsAndExamples/Assets}/Examples/Intro/SharedConstants/TagPlayer.asset (80%) rename {Assets/UnityAtoms => UnityAtomsTestsAndExamples/Assets}/Examples/Intro/SharedConstants/TagPlayer.asset.meta (79%) rename Assets/UnityAtoms/Examples/Intro/GameObjects/Harmful/DecreasePlayersHealth.asset => UnityAtomsTestsAndExamples/Assets/Examples/Intro/SharedConstants/UIState_First.asset (58%) rename Assets/UnityAtoms/Examples/Intro/GameObjects/Harmful/Harmful.prefab.meta => UnityAtomsTestsAndExamples/Assets/Examples/Intro/SharedConstants/UIState_First.asset.meta (63%) create mode 100644 UnityAtomsTestsAndExamples/Assets/Examples/Intro/SharedConstants/UIState_Second.asset rename Assets/UnityAtoms/Examples/Intro/GameObjects/HealthListener/HealthListener.prefab.meta => UnityAtomsTestsAndExamples/Assets/Examples/Intro/SharedConstants/UIState_Second.asset.meta (63%) rename {Assets/UnityAtoms => UnityAtomsTestsAndExamples/Assets}/Examples/Intro/SharedState.meta (77%) rename {Assets/UnityAtoms => UnityAtomsTestsAndExamples/Assets}/Examples/Intro/SharedState/Health.asset (55%) rename {Assets/UnityAtoms => UnityAtomsTestsAndExamples/Assets}/Examples/Intro/SharedState/Health.asset.meta (79%) rename {Assets/UnityAtoms => UnityAtomsTestsAndExamples/Assets}/Examples/Intro/SharedState/HealthChangedEvent.asset (78%) rename {Assets/UnityAtoms => UnityAtomsTestsAndExamples/Assets}/Examples/Intro/SharedState/HealthChangedEvent.asset.meta (79%) create mode 100644 UnityAtomsTestsAndExamples/Assets/Examples/Intro/SharedState/UIState.asset rename Assets/UnityAtoms/Examples/Intro/GameObjects/OnLevelStart/OnLevelStart.prefab.meta => UnityAtomsTestsAndExamples/Assets/Examples/Intro/SharedState/UIState.asset.meta (63%) rename Assets/UnityAtoms/Examples/Intro/GameObjects/HealthListener/HealthLogger/HealthLogger.asset => UnityAtomsTestsAndExamples/Assets/Examples/Intro/SharedState/UIStateChanged.asset (71%) create mode 100644 UnityAtomsTestsAndExamples/Assets/Examples/Intro/SharedState/UIStateChanged.asset.meta rename {Assets/UnityAtoms => UnityAtomsTestsAndExamples/Assets}/Examples/Intro/Sprites.meta (77%) rename {Assets/UnityAtoms => UnityAtomsTestsAndExamples/Assets}/Examples/Intro/Sprites/Square.png (100%) rename {Assets/UnityAtoms => UnityAtomsTestsAndExamples/Assets}/Examples/Intro/Sprites/Square.png.meta (97%) create mode 100644 UnityAtomsTestsAndExamples/Assets/Examples/Intro/UI.meta create mode 100644 UnityAtomsTestsAndExamples/Assets/Examples/Intro/UI/Button1.meta create mode 100644 UnityAtomsTestsAndExamples/Assets/Examples/Intro/UI/Button1/OnButton1Clicked.asset create mode 100644 UnityAtomsTestsAndExamples/Assets/Examples/Intro/UI/Button1/OnButton1Clicked.asset.meta create mode 100644 UnityAtomsTestsAndExamples/Assets/Examples/Intro/UI/Button1/SetUIStateFirst.asset create mode 100644 UnityAtomsTestsAndExamples/Assets/Examples/Intro/UI/Button1/SetUIStateFirst.asset.meta create mode 100644 UnityAtomsTestsAndExamples/Assets/Examples/Intro/UI/Button2.meta create mode 100644 UnityAtomsTestsAndExamples/Assets/Examples/Intro/UI/Button2/OnButton2Clicked.asset create mode 100644 UnityAtomsTestsAndExamples/Assets/Examples/Intro/UI/Button2/OnButton2Clicked.asset.meta create mode 100644 UnityAtomsTestsAndExamples/Assets/Examples/Intro/UI/Button2/SetUIStateSecond.asset create mode 100644 UnityAtomsTestsAndExamples/Assets/Examples/Intro/UI/Button2/SetUIStateSecond.asset.meta create mode 100644 UnityAtomsTestsAndExamples/Assets/Tests.meta create mode 100644 UnityAtomsTestsAndExamples/Assets/Tests/AtomicTagTests.cs create mode 100644 UnityAtomsTestsAndExamples/Assets/Tests/AtomicTagTests.cs.meta create mode 100644 UnityAtomsTestsAndExamples/Assets/Tests/ScriptableObjectBaseTest.cs create mode 100644 UnityAtomsTestsAndExamples/Assets/Tests/ScriptableObjectBaseTest.cs.meta create mode 100644 UnityAtomsTestsAndExamples/Assets/Tests/Tests.asmdef create mode 100644 UnityAtomsTestsAndExamples/Assets/Tests/Tests.asmdef.meta create mode 100644 UnityAtomsTestsAndExamples/Library.meta create mode 100644 UnityAtomsTestsAndExamples/Logs.meta create mode 100644 UnityAtomsTestsAndExamples/Logs/Packages-Update.log create mode 100644 UnityAtomsTestsAndExamples/Logs/Packages-Update.log.meta create mode 100644 UnityAtomsTestsAndExamples/Packages.meta create mode 100644 UnityAtomsTestsAndExamples/Packages/manifest.json create mode 100644 UnityAtomsTestsAndExamples/Packages/manifest.json.meta create mode 100644 UnityAtomsTestsAndExamples/ProjectSettings.meta rename {ProjectSettings => UnityAtomsTestsAndExamples/ProjectSettings}/AudioManager.asset (100%) create mode 100644 UnityAtomsTestsAndExamples/ProjectSettings/AudioManager.asset.meta rename {ProjectSettings => UnityAtomsTestsAndExamples/ProjectSettings}/ClusterInputManager.asset (100%) create mode 100644 UnityAtomsTestsAndExamples/ProjectSettings/ClusterInputManager.asset.meta rename {ProjectSettings => UnityAtomsTestsAndExamples/ProjectSettings}/DynamicsManager.asset (92%) create mode 100644 UnityAtomsTestsAndExamples/ProjectSettings/DynamicsManager.asset.meta rename {ProjectSettings => UnityAtomsTestsAndExamples/ProjectSettings}/EditorBuildSettings.asset (100%) create mode 100644 UnityAtomsTestsAndExamples/ProjectSettings/EditorBuildSettings.asset.meta rename {ProjectSettings => UnityAtomsTestsAndExamples/ProjectSettings}/EditorSettings.asset (100%) create mode 100644 UnityAtomsTestsAndExamples/ProjectSettings/EditorSettings.asset.meta rename {ProjectSettings => UnityAtomsTestsAndExamples/ProjectSettings}/GraphicsSettings.asset (93%) create mode 100644 UnityAtomsTestsAndExamples/ProjectSettings/GraphicsSettings.asset.meta rename {ProjectSettings => UnityAtomsTestsAndExamples/ProjectSettings}/InputManager.asset (100%) create mode 100644 UnityAtomsTestsAndExamples/ProjectSettings/InputManager.asset.meta rename {ProjectSettings => UnityAtomsTestsAndExamples/ProjectSettings}/NavMeshAreas.asset (100%) create mode 100644 UnityAtomsTestsAndExamples/ProjectSettings/NavMeshAreas.asset.meta rename {ProjectSettings => UnityAtomsTestsAndExamples/ProjectSettings}/NetworkManager.asset (100%) create mode 100644 UnityAtomsTestsAndExamples/ProjectSettings/NetworkManager.asset.meta rename {ProjectSettings => UnityAtomsTestsAndExamples/ProjectSettings}/Physics2DSettings.asset (96%) create mode 100644 UnityAtomsTestsAndExamples/ProjectSettings/Physics2DSettings.asset.meta rename {ProjectSettings => UnityAtomsTestsAndExamples/ProjectSettings}/PresetManager.asset (100%) create mode 100644 UnityAtomsTestsAndExamples/ProjectSettings/PresetManager.asset.meta rename {ProjectSettings => UnityAtomsTestsAndExamples/ProjectSettings}/ProjectSettings.asset (88%) create mode 100644 UnityAtomsTestsAndExamples/ProjectSettings/ProjectSettings.asset.meta create mode 100644 UnityAtomsTestsAndExamples/ProjectSettings/ProjectVersion.txt create mode 100644 UnityAtomsTestsAndExamples/ProjectSettings/ProjectVersion.txt.meta rename {ProjectSettings => UnityAtomsTestsAndExamples/ProjectSettings}/QualitySettings.asset (92%) create mode 100644 UnityAtomsTestsAndExamples/ProjectSettings/QualitySettings.asset.meta rename {ProjectSettings => UnityAtomsTestsAndExamples/ProjectSettings}/TagManager.asset (100%) create mode 100644 UnityAtomsTestsAndExamples/ProjectSettings/TagManager.asset.meta rename {ProjectSettings => UnityAtomsTestsAndExamples/ProjectSettings}/TimeManager.asset (100%) create mode 100644 UnityAtomsTestsAndExamples/ProjectSettings/TimeManager.asset.meta rename {ProjectSettings => UnityAtomsTestsAndExamples/ProjectSettings}/UnityConnectSettings.asset (68%) create mode 100644 UnityAtomsTestsAndExamples/ProjectSettings/UnityConnectSettings.asset.meta create mode 100644 UnityAtomsTestsAndExamples/ProjectSettings/VFXManager.asset create mode 100644 UnityAtomsTestsAndExamples/ProjectSettings/VFXManager.asset.meta create mode 100644 UnityAtomsTestsAndExamples/Temp.meta create mode 100644 UnityAtomsTestsAndExamples/Tests.csproj.meta create mode 100644 UnityAtomsTestsAndExamples/UnityAtoms.csproj.meta create mode 100644 UnityAtomsTestsAndExamples/UnityAtomsEditor.csproj.meta create mode 100644 UnityAtomsTestsAndExamples/UnityAtomsTestsAndExamples.sln.meta create mode 100644 UnityAtomsTestsAndExamples/obj.meta create mode 100644 UnityAtomsTestsAndExamples/package.json.meta create mode 100644 omnisharp.json create mode 100644 omnisharp.json.meta create mode 100644 package.json create mode 100644 package.json.meta diff --git a/.editorconfig b/.editorconfig new file mode 100644 index 00000000..af8350d1 --- /dev/null +++ b/.editorconfig @@ -0,0 +1,16 @@ +root = true + +[*] +indent_style = space +indent_size = 4 +end_of_line = lf +charset = utf-8 +trim_trailing_whitespace = true +insert_final_newline = true + +[*.md] +trim_trailing_whitespace = false + +[*.json] +trim_trailing_whitespace = false +insert_final_newline = false diff --git a/.gitignore b/.gitignore index 14d91090..ddadb081 100644 --- a/.gitignore +++ b/.gitignore @@ -7,6 +7,9 @@ # Visual Studio 2015 cache directory /.vs/ +/.idea/ + +/Assets/Plugins/Editor/JetBrains* # Autogenerated VS/MD/Consulo solution and project files ExportedObj/ diff --git a/Assets/UnityAtoms/Constants/BoolConstant.cs b/Assets/UnityAtoms/Constants/BoolConstant.cs deleted file mode 100644 index 2f5cea58..00000000 --- a/Assets/UnityAtoms/Constants/BoolConstant.cs +++ /dev/null @@ -1,9 +0,0 @@ -using UnityEngine; - -namespace UnityAtoms -{ - [CreateAssetMenu(menuName = "Unity Atoms/Constants/Bool", fileName = "BoolConstant", order = 2)] - public class BoolConstant : ScriptableObjectVariableBase - { - } -} \ No newline at end of file diff --git a/Assets/UnityAtoms/Constants/ColorConstant.cs b/Assets/UnityAtoms/Constants/ColorConstant.cs deleted file mode 100644 index 28c0e54b..00000000 --- a/Assets/UnityAtoms/Constants/ColorConstant.cs +++ /dev/null @@ -1,9 +0,0 @@ -using UnityEngine; - -namespace UnityAtoms -{ - [CreateAssetMenu(menuName = "Unity Atoms/Constants/Color", fileName = "ColorConstant", order = 4)] - public class ColorConstant : ScriptableObjectVariableBase - { - } -} \ No newline at end of file diff --git a/Assets/UnityAtoms/Constants/FloatConstant.cs b/Assets/UnityAtoms/Constants/FloatConstant.cs deleted file mode 100644 index a521b36b..00000000 --- a/Assets/UnityAtoms/Constants/FloatConstant.cs +++ /dev/null @@ -1,9 +0,0 @@ -using UnityEngine; - -namespace UnityAtoms -{ - [CreateAssetMenu(menuName = "Unity Atoms/Constants/Float", fileName = "FloatConstant", order = 1)] - public class FloatConstant : ScriptableObjectVariableBase - { - } -} \ No newline at end of file diff --git a/Assets/UnityAtoms/Constants/IntConstant.cs b/Assets/UnityAtoms/Constants/IntConstant.cs deleted file mode 100644 index 4a99f987..00000000 --- a/Assets/UnityAtoms/Constants/IntConstant.cs +++ /dev/null @@ -1,9 +0,0 @@ -using UnityEngine; - -namespace UnityAtoms -{ - [CreateAssetMenu(menuName = "Unity Atoms/Constants/Int", fileName = "IntConstant", order = 0)] - public class IntConstant : ScriptableObjectVariableBase - { - } -} \ No newline at end of file diff --git a/Assets/UnityAtoms/Constants/StringConstant.cs b/Assets/UnityAtoms/Constants/StringConstant.cs deleted file mode 100644 index 98dbca94..00000000 --- a/Assets/UnityAtoms/Constants/StringConstant.cs +++ /dev/null @@ -1,9 +0,0 @@ -using UnityEngine; - -namespace UnityAtoms -{ - [CreateAssetMenu(menuName = "Unity Atoms/Constants/String", fileName = "StringConstant", order = 3)] - public class StringConstant : ScriptableObjectVariableBase - { - } -} \ No newline at end of file diff --git a/Assets/UnityAtoms/Constants/Vector2Constant.cs b/Assets/UnityAtoms/Constants/Vector2Constant.cs deleted file mode 100644 index 57c91d6c..00000000 --- a/Assets/UnityAtoms/Constants/Vector2Constant.cs +++ /dev/null @@ -1,9 +0,0 @@ -using UnityEngine; - -namespace UnityAtoms -{ - [CreateAssetMenu(menuName = "Unity Atoms/Constants/Vector2", fileName = "Vector2Constant", order = 5)] - public class Vector2Constant : ScriptableObjectVariableBase - { - } -} \ No newline at end of file diff --git a/Assets/UnityAtoms/Constants/Vector3Constant.cs b/Assets/UnityAtoms/Constants/Vector3Constant.cs deleted file mode 100644 index dc1f1034..00000000 --- a/Assets/UnityAtoms/Constants/Vector3Constant.cs +++ /dev/null @@ -1,9 +0,0 @@ -using UnityEngine; - -namespace UnityAtoms -{ - [CreateAssetMenu(menuName = "Unity Atoms/Constants/Vector3", fileName = "Vector3Constant", order = 6)] - public class Vector3Constant : ScriptableObjectVariableBase - { - } -} \ No newline at end of file diff --git a/Assets/UnityAtoms/Examples/Intro/Scenes/Intro.unity b/Assets/UnityAtoms/Examples/Intro/Scenes/Intro.unity deleted file mode 100644 index 632fbdea..00000000 --- a/Assets/UnityAtoms/Examples/Intro/Scenes/Intro.unity +++ /dev/null @@ -1,723 +0,0 @@ -%YAML 1.1 -%TAG !u! tag:unity3d.com,2011: ---- !u!29 &1 -OcclusionCullingSettings: - m_ObjectHideFlags: 0 - serializedVersion: 2 - m_OcclusionBakeSettings: - smallestOccluder: 5 - smallestHole: 0.25 - backfaceThreshold: 100 - m_SceneGUID: 00000000000000000000000000000000 - m_OcclusionCullingData: {fileID: 0} ---- !u!104 &2 -RenderSettings: - m_ObjectHideFlags: 0 - serializedVersion: 9 - m_Fog: 0 - m_FogColor: {r: 0.5, g: 0.5, b: 0.5, a: 1} - m_FogMode: 3 - m_FogDensity: 0.01 - m_LinearFogStart: 0 - m_LinearFogEnd: 300 - m_AmbientSkyColor: {r: 0.212, g: 0.227, b: 0.259, a: 1} - m_AmbientEquatorColor: {r: 0.114, g: 0.125, b: 0.133, a: 1} - m_AmbientGroundColor: {r: 0.047, g: 0.043, b: 0.035, a: 1} - m_AmbientIntensity: 1 - m_AmbientMode: 3 - m_SubtractiveShadowColor: {r: 0.42, g: 0.478, b: 0.627, a: 1} - m_SkyboxMaterial: {fileID: 0} - m_HaloStrength: 0.5 - m_FlareStrength: 1 - m_FlareFadeSpeed: 3 - m_HaloTexture: {fileID: 0} - m_SpotCookie: {fileID: 10001, guid: 0000000000000000e000000000000000, type: 0} - m_DefaultReflectionMode: 0 - m_DefaultReflectionResolution: 128 - m_ReflectionBounces: 1 - m_ReflectionIntensity: 1 - m_CustomReflection: {fileID: 0} - m_Sun: {fileID: 0} - m_IndirectSpecularColor: {r: 0, g: 0, b: 0, a: 1} - m_UseRadianceAmbientProbe: 0 ---- !u!157 &3 -LightmapSettings: - m_ObjectHideFlags: 0 - serializedVersion: 11 - m_GIWorkflowMode: 1 - m_GISettings: - serializedVersion: 2 - m_BounceScale: 1 - m_IndirectOutputScale: 1 - m_AlbedoBoost: 1 - m_TemporalCoherenceThreshold: 1 - m_EnvironmentLightingMode: 0 - m_EnableBakedLightmaps: 0 - m_EnableRealtimeLightmaps: 0 - m_LightmapEditorSettings: - serializedVersion: 10 - m_Resolution: 2 - m_BakeResolution: 40 - m_AtlasSize: 1024 - m_AO: 0 - m_AOMaxDistance: 1 - m_CompAOExponent: 1 - m_CompAOExponentDirect: 0 - m_Padding: 2 - m_LightmapParameters: {fileID: 0} - m_LightmapsBakeMode: 1 - m_TextureCompression: 1 - m_FinalGather: 0 - m_FinalGatherFiltering: 1 - m_FinalGatherRayCount: 256 - m_ReflectionCompression: 2 - m_MixedBakeMode: 2 - m_BakeBackend: 0 - m_PVRSampling: 1 - m_PVRDirectSampleCount: 32 - m_PVRSampleCount: 500 - m_PVRBounces: 2 - m_PVRFilterTypeDirect: 0 - m_PVRFilterTypeIndirect: 0 - m_PVRFilterTypeAO: 0 - m_PVRFilteringMode: 1 - m_PVRCulling: 1 - m_PVRFilteringGaussRadiusDirect: 1 - m_PVRFilteringGaussRadiusIndirect: 5 - m_PVRFilteringGaussRadiusAO: 2 - m_PVRFilteringAtrousPositionSigmaDirect: 0.5 - m_PVRFilteringAtrousPositionSigmaIndirect: 2 - m_PVRFilteringAtrousPositionSigmaAO: 1 - m_ShowResolutionOverlay: 1 - m_LightingDataAsset: {fileID: 0} - m_UseShadowmask: 1 ---- !u!196 &4 -NavMeshSettings: - serializedVersion: 2 - m_ObjectHideFlags: 0 - m_BuildSettings: - serializedVersion: 2 - agentTypeID: 0 - agentRadius: 0.5 - agentHeight: 2 - agentSlope: 45 - agentClimb: 0.4 - ledgeDropHeight: 0 - maxJumpAcrossDistance: 0 - minRegionArea: 2 - manualCellSize: 0 - cellSize: 0.16666667 - manualTileSize: 0 - tileSize: 256 - accuratePlacement: 0 - debug: - m_Flags: 0 - m_NavMeshData: {fileID: 0} ---- !u!1 &145633446 -GameObject: - m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInternal: {fileID: 0} - serializedVersion: 6 - m_Component: - - component: {fileID: 145633447} - - component: {fileID: 145633450} - - component: {fileID: 145633449} - - component: {fileID: 145633448} - m_Layer: 5 - m_Name: HealthBar - m_TagString: Untagged - m_Icon: {fileID: 0} - m_NavMeshLayer: 0 - m_StaticEditorFlags: 0 - m_IsActive: 1 ---- !u!224 &145633447 -RectTransform: - m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInternal: {fileID: 0} - m_GameObject: {fileID: 145633446} - m_LocalRotation: {x: -0, y: -0, z: -0, w: 1} - m_LocalPosition: {x: 0, y: 0, z: 0} - m_LocalScale: {x: 1, y: 1, z: 1} - m_Children: [] - m_Father: {fileID: 1244410474} - m_RootOrder: 0 - m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} - m_AnchorMin: {x: 0, y: 1} - m_AnchorMax: {x: 0, y: 1} - m_AnchoredPosition: {x: 60, y: -20} - m_SizeDelta: {x: 100, y: 20} - m_Pivot: {x: 0.5, y: 0.5} ---- !u!114 &145633448 -MonoBehaviour: - m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInternal: {fileID: 0} - m_GameObject: {fileID: 145633446} - m_Enabled: 1 - m_EditorHideFlags: 0 - m_Script: {fileID: 11500000, guid: 735df585b0f8f48d1bac1ee2a282d5c1, type: 3} - m_Name: - m_EditorClassIdentifier: - MaxHealth: {fileID: 11400000, guid: 2f9770eeac092421e9baaf44c1855c4a, type: 2} ---- !u!114 &145633449 -MonoBehaviour: - m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInternal: {fileID: 0} - m_GameObject: {fileID: 145633446} - m_Enabled: 1 - m_EditorHideFlags: 0 - m_Script: {fileID: -765806418, guid: f70555f144d8491a825f0804e09c671c, type: 3} - m_Name: - m_EditorClassIdentifier: - m_Material: {fileID: 0} - m_Color: {r: 0.6132076, g: 0, b: 0, a: 1} - m_RaycastTarget: 1 - m_OnCullStateChanged: - m_PersistentCalls: - m_Calls: [] - m_TypeName: UnityEngine.UI.MaskableGraphic+CullStateChangedEvent, UnityEngine.UI, - Version=1.0.0.0, Culture=neutral, PublicKeyToken=null - m_Sprite: {fileID: 21300000, guid: ca71068637cec4e8fa7c6e9f8940c066, type: 3} - m_Type: 3 - m_PreserveAspect: 0 - m_FillCenter: 1 - m_FillMethod: 0 - m_FillAmount: 1 - m_FillClockwise: 1 - m_FillOrigin: 0 ---- !u!222 &145633450 -CanvasRenderer: - m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInternal: {fileID: 0} - m_GameObject: {fileID: 145633446} - m_CullTransparentMesh: 0 ---- !u!1001 &346110327 -Prefab: - m_ObjectHideFlags: 0 - serializedVersion: 2 - m_Modification: - m_TransformParent: {fileID: 0} - m_Modifications: - - target: {fileID: 4325993638842916, guid: 3d318425ce2be41d0aafdee4b3520b8a, type: 2} - propertyPath: m_LocalPosition.x - value: 0 - objectReference: {fileID: 0} - - target: {fileID: 4325993638842916, guid: 3d318425ce2be41d0aafdee4b3520b8a, type: 2} - propertyPath: m_LocalPosition.y - value: 0 - objectReference: {fileID: 0} - - target: {fileID: 4325993638842916, guid: 3d318425ce2be41d0aafdee4b3520b8a, type: 2} - propertyPath: m_LocalPosition.z - value: 0 - objectReference: {fileID: 0} - - target: {fileID: 4325993638842916, guid: 3d318425ce2be41d0aafdee4b3520b8a, type: 2} - propertyPath: m_LocalRotation.x - value: 0 - objectReference: {fileID: 0} - - target: {fileID: 4325993638842916, guid: 3d318425ce2be41d0aafdee4b3520b8a, type: 2} - propertyPath: m_LocalRotation.y - value: 0 - objectReference: {fileID: 0} - - target: {fileID: 4325993638842916, guid: 3d318425ce2be41d0aafdee4b3520b8a, type: 2} - propertyPath: m_LocalRotation.z - value: 0 - objectReference: {fileID: 0} - - target: {fileID: 4325993638842916, guid: 3d318425ce2be41d0aafdee4b3520b8a, type: 2} - propertyPath: m_LocalRotation.w - value: 1 - objectReference: {fileID: 0} - - target: {fileID: 4325993638842916, guid: 3d318425ce2be41d0aafdee4b3520b8a, type: 2} - propertyPath: m_RootOrder - value: 5 - objectReference: {fileID: 0} - m_RemovedComponents: [] - m_SourcePrefab: {fileID: 100100000, guid: 3d318425ce2be41d0aafdee4b3520b8a, type: 2} - m_IsPrefabAsset: 0 ---- !u!1001 &475590110 -Prefab: - m_ObjectHideFlags: 0 - serializedVersion: 2 - m_Modification: - m_TransformParent: {fileID: 0} - m_Modifications: - - target: {fileID: 4748691630159618, guid: 9cab105cfb93a49c3ad899cee2e3dd5e, type: 2} - propertyPath: m_LocalPosition.x - value: 0 - objectReference: {fileID: 0} - - target: {fileID: 4748691630159618, guid: 9cab105cfb93a49c3ad899cee2e3dd5e, type: 2} - propertyPath: m_LocalPosition.y - value: 0 - objectReference: {fileID: 0} - - target: {fileID: 4748691630159618, guid: 9cab105cfb93a49c3ad899cee2e3dd5e, type: 2} - propertyPath: m_LocalPosition.z - value: 0 - objectReference: {fileID: 0} - - target: {fileID: 4748691630159618, guid: 9cab105cfb93a49c3ad899cee2e3dd5e, type: 2} - propertyPath: m_LocalRotation.x - value: 0 - objectReference: {fileID: 0} - - target: {fileID: 4748691630159618, guid: 9cab105cfb93a49c3ad899cee2e3dd5e, type: 2} - propertyPath: m_LocalRotation.y - value: 0 - objectReference: {fileID: 0} - - target: {fileID: 4748691630159618, guid: 9cab105cfb93a49c3ad899cee2e3dd5e, type: 2} - propertyPath: m_LocalRotation.z - value: 0 - objectReference: {fileID: 0} - - target: {fileID: 4748691630159618, guid: 9cab105cfb93a49c3ad899cee2e3dd5e, type: 2} - propertyPath: m_LocalRotation.w - value: 1 - objectReference: {fileID: 0} - - target: {fileID: 4748691630159618, guid: 9cab105cfb93a49c3ad899cee2e3dd5e, type: 2} - propertyPath: m_RootOrder - value: 4 - objectReference: {fileID: 0} - - target: {fileID: 114212381404589792, guid: 9cab105cfb93a49c3ad899cee2e3dd5e, - type: 2} - propertyPath: UnityEventResponse.m_PersistentCalls.m_Calls.Array.data[0].m_Target - value: - objectReference: {fileID: 145633448} - m_RemovedComponents: [] - m_SourcePrefab: {fileID: 100100000, guid: 9cab105cfb93a49c3ad899cee2e3dd5e, type: 2} - m_IsPrefabAsset: 0 ---- !u!1 &519420028 -GameObject: - m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInternal: {fileID: 0} - serializedVersion: 6 - m_Component: - - component: {fileID: 519420032} - - component: {fileID: 519420031} - - component: {fileID: 519420029} - m_Layer: 0 - m_Name: Main Camera - m_TagString: MainCamera - m_Icon: {fileID: 0} - m_NavMeshLayer: 0 - m_StaticEditorFlags: 0 - m_IsActive: 1 ---- !u!81 &519420029 -AudioListener: - m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInternal: {fileID: 0} - m_GameObject: {fileID: 519420028} - m_Enabled: 1 ---- !u!20 &519420031 -Camera: - m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInternal: {fileID: 0} - m_GameObject: {fileID: 519420028} - m_Enabled: 1 - serializedVersion: 2 - m_ClearFlags: 2 - m_BackGroundColor: {r: 0.38625848, g: 0.5283019, b: 0.49624482, a: 0} - m_projectionMatrixMode: 1 - m_SensorSize: {x: 36, y: 24} - m_LensShift: {x: 0, y: 0} - m_FocalLength: 50 - m_NormalizedViewPortRect: - serializedVersion: 2 - x: 0 - y: 0 - width: 1 - height: 1 - near clip plane: 0.3 - far clip plane: 1000 - field of view: 60 - orthographic: 1 - orthographic size: 5 - m_Depth: -1 - m_CullingMask: - serializedVersion: 2 - m_Bits: 4294967295 - m_RenderingPath: -1 - m_TargetTexture: {fileID: 0} - m_TargetDisplay: 0 - m_TargetEye: 0 - m_HDR: 1 - m_AllowMSAA: 0 - m_AllowDynamicResolution: 0 - m_ForceIntoRT: 0 - m_OcclusionCulling: 0 - m_StereoConvergence: 10 - m_StereoSeparation: 0.022 ---- !u!4 &519420032 -Transform: - m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInternal: {fileID: 0} - m_GameObject: {fileID: 519420028} - m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} - m_LocalPosition: {x: 0, y: 0, z: -10} - m_LocalScale: {x: 1, y: 1, z: 1} - m_Children: [] - m_Father: {fileID: 0} - m_RootOrder: 0 - m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} ---- !u!1 &854994178 -GameObject: - m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInternal: {fileID: 0} - serializedVersion: 6 - m_Component: - - component: {fileID: 854994180} - - component: {fileID: 854994181} - - component: {fileID: 854994183} - - component: {fileID: 854994182} - - component: {fileID: 854994179} - - component: {fileID: 854994184} - m_Layer: 0 - m_Name: Player - m_TagString: Player - m_Icon: {fileID: 0} - m_NavMeshLayer: 0 - m_StaticEditorFlags: 0 - m_IsActive: 1 ---- !u!114 &854994179 -MonoBehaviour: - m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInternal: {fileID: 0} - m_GameObject: {fileID: 854994178} - m_Enabled: 1 - m_EditorHideFlags: 0 - m_Script: {fileID: 11500000, guid: 66910caffeb0c4be695e51147ed1d9fa, type: 3} - m_Name: - m_EditorClassIdentifier: - Health: {fileID: 11400000, guid: ddc5fdadda50b4c0698b0ba7e9f9e746, type: 2} ---- !u!4 &854994180 -Transform: - m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInternal: {fileID: 0} - m_GameObject: {fileID: 854994178} - m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} - m_LocalPosition: {x: 0, y: 0, z: 0} - m_LocalScale: {x: 0.5, y: 0.5, z: 0.5} - m_Children: [] - m_Father: {fileID: 0} - m_RootOrder: 1 - m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} ---- !u!212 &854994181 -SpriteRenderer: - m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInternal: {fileID: 0} - m_GameObject: {fileID: 854994178} - m_Enabled: 1 - m_CastShadows: 0 - m_ReceiveShadows: 0 - m_DynamicOccludee: 1 - m_MotionVectors: 1 - m_LightProbeUsage: 1 - m_ReflectionProbeUsage: 1 - m_RenderingLayerMask: 4294967295 - m_Materials: - - {fileID: 10754, guid: 0000000000000000f000000000000000, type: 0} - m_StaticBatchInfo: - firstSubMesh: 0 - subMeshCount: 0 - m_StaticBatchRoot: {fileID: 0} - m_ProbeAnchor: {fileID: 0} - m_LightProbeVolumeOverride: {fileID: 0} - m_ScaleInLightmap: 1 - m_PreserveUVs: 0 - m_IgnoreNormalsForChartDetection: 0 - m_ImportantGI: 0 - m_StitchLightmapSeams: 0 - m_SelectedEditorRenderState: 0 - m_MinimumChartSize: 4 - m_AutoUVMaxDistance: 0.5 - m_AutoUVMaxAngle: 89 - m_LightmapParameters: {fileID: 0} - m_SortingLayerID: 0 - m_SortingLayer: 0 - m_SortingOrder: 0 - m_Sprite: {fileID: 21300000, guid: ca71068637cec4e8fa7c6e9f8940c066, type: 3} - m_Color: {r: 1, g: 1, b: 1, a: 1} - m_FlipX: 0 - m_FlipY: 0 - m_DrawMode: 0 - m_Size: {x: 1, y: 1} - m_AdaptiveModeThreshold: 0.5 - m_SpriteTileMode: 0 - m_WasSpriteAssigned: 1 - m_MaskInteraction: 0 - m_SpriteSortPoint: 0 ---- !u!61 &854994182 -BoxCollider2D: - m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInternal: {fileID: 0} - m_GameObject: {fileID: 854994178} - m_Enabled: 1 - m_Density: 1 - m_Material: {fileID: 0} - m_IsTrigger: 0 - m_UsedByEffector: 0 - m_UsedByComposite: 0 - m_Offset: {x: 0, y: 0} - m_SpriteTilingProperty: - border: {x: 0, y: 0, z: 0, w: 0} - pivot: {x: 0.5, y: 0.5} - oldSize: {x: 1, y: 1} - newSize: {x: 1, y: 1} - adaptiveTilingThreshold: 0.5 - drawMode: 0 - adaptiveTiling: 0 - m_AutoTiling: 0 - serializedVersion: 2 - m_Size: {x: 1, y: 1} - m_EdgeRadius: 0 ---- !u!50 &854994183 -Rigidbody2D: - serializedVersion: 4 - m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInternal: {fileID: 0} - m_GameObject: {fileID: 854994178} - m_BodyType: 1 - m_Simulated: 1 - m_UseFullKinematicContacts: 0 - m_UseAutoMass: 0 - m_Mass: 1 - m_LinearDrag: 0 - m_AngularDrag: 0.05 - m_GravityScale: 1 - m_Material: {fileID: 0} - m_Interpolate: 0 - m_SleepingMode: 1 - m_CollisionDetection: 0 - m_Constraints: 0 ---- !u!114 &854994184 -MonoBehaviour: - m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInternal: {fileID: 0} - m_GameObject: {fileID: 854994178} - m_Enabled: 1 - m_EditorHideFlags: 0 - m_Script: {fileID: 11500000, guid: b994f74f11b564875b8eb8c828ed594e, type: 3} - m_Name: - m_EditorClassIdentifier: ---- !u!1 &1067648696 -GameObject: - m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInternal: {fileID: 0} - serializedVersion: 6 - m_Component: - - component: {fileID: 1067648699} - - component: {fileID: 1067648698} - - component: {fileID: 1067648697} - m_Layer: 0 - m_Name: EventSystem - m_TagString: Untagged - m_Icon: {fileID: 0} - m_NavMeshLayer: 0 - m_StaticEditorFlags: 0 - m_IsActive: 1 ---- !u!114 &1067648697 -MonoBehaviour: - m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInternal: {fileID: 0} - m_GameObject: {fileID: 1067648696} - m_Enabled: 1 - m_EditorHideFlags: 0 - m_Script: {fileID: 1077351063, guid: f70555f144d8491a825f0804e09c671c, type: 3} - m_Name: - m_EditorClassIdentifier: - m_HorizontalAxis: Horizontal - m_VerticalAxis: Vertical - m_SubmitButton: Submit - m_CancelButton: Cancel - m_InputActionsPerSecond: 10 - m_RepeatDelay: 0.5 - m_ForceModuleActive: 0 ---- !u!114 &1067648698 -MonoBehaviour: - m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInternal: {fileID: 0} - m_GameObject: {fileID: 1067648696} - m_Enabled: 1 - m_EditorHideFlags: 0 - m_Script: {fileID: -619905303, guid: f70555f144d8491a825f0804e09c671c, type: 3} - m_Name: - m_EditorClassIdentifier: - m_FirstSelected: {fileID: 0} - m_sendNavigationEvents: 1 - m_DragThreshold: 10 ---- !u!4 &1067648699 -Transform: - m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInternal: {fileID: 0} - m_GameObject: {fileID: 1067648696} - m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} - m_LocalPosition: {x: 0, y: 0, z: 0} - m_LocalScale: {x: 1, y: 1, z: 1} - m_Children: [] - m_Father: {fileID: 0} - m_RootOrder: 3 - m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} ---- !u!1 &1244410470 -GameObject: - m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInternal: {fileID: 0} - serializedVersion: 6 - m_Component: - - component: {fileID: 1244410474} - - component: {fileID: 1244410473} - - component: {fileID: 1244410472} - - component: {fileID: 1244410471} - m_Layer: 5 - m_Name: Canvas - m_TagString: Untagged - m_Icon: {fileID: 0} - m_NavMeshLayer: 0 - m_StaticEditorFlags: 0 - m_IsActive: 1 ---- !u!114 &1244410471 -MonoBehaviour: - m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInternal: {fileID: 0} - m_GameObject: {fileID: 1244410470} - m_Enabled: 1 - m_EditorHideFlags: 0 - m_Script: {fileID: 1301386320, guid: f70555f144d8491a825f0804e09c671c, type: 3} - m_Name: - m_EditorClassIdentifier: - m_IgnoreReversedGraphics: 1 - m_BlockingObjects: 0 - m_BlockingMask: - serializedVersion: 2 - m_Bits: 4294967295 ---- !u!114 &1244410472 -MonoBehaviour: - m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInternal: {fileID: 0} - m_GameObject: {fileID: 1244410470} - m_Enabled: 1 - m_EditorHideFlags: 0 - m_Script: {fileID: 1980459831, guid: f70555f144d8491a825f0804e09c671c, type: 3} - m_Name: - m_EditorClassIdentifier: - m_UiScaleMode: 0 - m_ReferencePixelsPerUnit: 100 - m_ScaleFactor: 1 - m_ReferenceResolution: {x: 800, y: 600} - m_ScreenMatchMode: 0 - m_MatchWidthOrHeight: 0 - m_PhysicalUnit: 3 - m_FallbackScreenDPI: 96 - m_DefaultSpriteDPI: 96 - m_DynamicPixelsPerUnit: 1 ---- !u!223 &1244410473 -Canvas: - m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInternal: {fileID: 0} - m_GameObject: {fileID: 1244410470} - m_Enabled: 1 - serializedVersion: 3 - m_RenderMode: 0 - m_Camera: {fileID: 0} - m_PlaneDistance: 100 - m_PixelPerfect: 0 - m_ReceivesEvents: 1 - m_OverrideSorting: 0 - m_OverridePixelPerfect: 0 - m_SortingBucketNormalizedSize: 0 - m_AdditionalShaderChannelsFlag: 0 - m_SortingLayerID: 0 - m_SortingOrder: 0 - m_TargetDisplay: 0 ---- !u!224 &1244410474 -RectTransform: - m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInternal: {fileID: 0} - m_GameObject: {fileID: 1244410470} - m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} - m_LocalPosition: {x: 0, y: 0, z: 0} - m_LocalScale: {x: 0, y: 0, z: 0} - m_Children: - - {fileID: 145633447} - m_Father: {fileID: 0} - m_RootOrder: 2 - m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} - m_AnchorMin: {x: 0, y: 0} - m_AnchorMax: {x: 0, y: 0} - m_AnchoredPosition: {x: 0, y: 0} - m_SizeDelta: {x: 0, y: 0} - m_Pivot: {x: 0, y: 0} ---- !u!1001 &1433015640 -Prefab: - m_ObjectHideFlags: 0 - serializedVersion: 2 - m_Modification: - m_TransformParent: {fileID: 0} - m_Modifications: - - target: {fileID: 4014875790597442, guid: d53b0d84c22b5424cae4a9b272042504, type: 2} - propertyPath: m_LocalPosition.x - value: 2.535 - objectReference: {fileID: 0} - - target: {fileID: 4014875790597442, guid: d53b0d84c22b5424cae4a9b272042504, type: 2} - propertyPath: m_LocalPosition.y - value: 0 - objectReference: {fileID: 0} - - target: {fileID: 4014875790597442, guid: d53b0d84c22b5424cae4a9b272042504, type: 2} - propertyPath: m_LocalPosition.z - value: 0 - objectReference: {fileID: 0} - - target: {fileID: 4014875790597442, guid: d53b0d84c22b5424cae4a9b272042504, type: 2} - propertyPath: m_LocalRotation.x - value: 0 - objectReference: {fileID: 0} - - target: {fileID: 4014875790597442, guid: d53b0d84c22b5424cae4a9b272042504, type: 2} - propertyPath: m_LocalRotation.y - value: 0 - objectReference: {fileID: 0} - - target: {fileID: 4014875790597442, guid: d53b0d84c22b5424cae4a9b272042504, type: 2} - propertyPath: m_LocalRotation.z - value: 0 - objectReference: {fileID: 0} - - target: {fileID: 4014875790597442, guid: d53b0d84c22b5424cae4a9b272042504, type: 2} - propertyPath: m_LocalRotation.w - value: 1 - objectReference: {fileID: 0} - - target: {fileID: 4014875790597442, guid: d53b0d84c22b5424cae4a9b272042504, type: 2} - propertyPath: m_RootOrder - value: 6 - objectReference: {fileID: 0} - - target: {fileID: 212802685174810290, guid: d53b0d84c22b5424cae4a9b272042504, - type: 2} - propertyPath: m_Color.r - value: 1 - objectReference: {fileID: 0} - - target: {fileID: 212802685174810290, guid: d53b0d84c22b5424cae4a9b272042504, - type: 2} - propertyPath: m_Color.g - value: 0.93066514 - objectReference: {fileID: 0} - - target: {fileID: 212802685174810290, guid: d53b0d84c22b5424cae4a9b272042504, - type: 2} - propertyPath: m_Color.b - value: 0.5330188 - objectReference: {fileID: 0} - m_RemovedComponents: [] - m_SourcePrefab: {fileID: 100100000, guid: d53b0d84c22b5424cae4a9b272042504, type: 2} - m_IsPrefabAsset: 0 diff --git a/Assets/UnityAtoms/Examples/Intro/Scripts/Harmful.cs b/Assets/UnityAtoms/Examples/Intro/Scripts/Harmful.cs deleted file mode 100644 index 99f6c2ec..00000000 --- a/Assets/UnityAtoms/Examples/Intro/Scripts/Harmful.cs +++ /dev/null @@ -1,17 +0,0 @@ -using UnityEngine; -using UnityEngine.UI; -using UnityAtoms; - -namespace UnityAtoms.Examples -{ - public class Harmful : MonoBehaviour - { - void OnTriggerEnter2D(Collider2D collider) - { - if (collider.tag == "Player") - { - collider.GetComponent().Health.Value -= 10; - } - } - } -} \ No newline at end of file diff --git a/Assets/UnityAtoms/Examples/Intro/Scripts/HealthBar.cs b/Assets/UnityAtoms/Examples/Intro/Scripts/HealthBar.cs deleted file mode 100644 index 84995c6d..00000000 --- a/Assets/UnityAtoms/Examples/Intro/Scripts/HealthBar.cs +++ /dev/null @@ -1,17 +0,0 @@ -using UnityEngine; -using UnityEngine.UI; -using UnityAtoms; - -namespace UnityAtoms.Examples -{ - public class HealthBar : MonoBehaviour - { - [SerializeField] - private IntConstant MaxHealth; - - public void HealthChanged(int health) - { - GetComponent().fillAmount = 1.0f * health / MaxHealth.Value; - } - } -} \ No newline at end of file diff --git a/Assets/UnityAtoms/GameActions.meta b/Assets/UnityAtoms/GameActions.meta deleted file mode 100644 index 66d513dc..00000000 --- a/Assets/UnityAtoms/GameActions.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2 -guid: ae80c11fe46534d49a5ade3f3223b22a -folderAsset: yes -DefaultImporter: - externalObjects: {} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Assets/UnityAtoms/GameActions/ChangeScene.meta b/Assets/UnityAtoms/GameActions/ChangeScene.meta deleted file mode 100644 index 91cf3b3f..00000000 --- a/Assets/UnityAtoms/GameActions/ChangeScene.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2 -guid: b0a2bb436fed1413fbdffbbdf7714a72 -folderAsset: yes -DefaultImporter: - externalObjects: {} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Assets/UnityAtoms/GameActions/Collider2DGameObjectEventAction.cs b/Assets/UnityAtoms/GameActions/Collider2DGameObjectEventAction.cs deleted file mode 100644 index 11908929..00000000 --- a/Assets/UnityAtoms/GameActions/Collider2DGameObjectEventAction.cs +++ /dev/null @@ -1,6 +0,0 @@ -using UnityEngine; - -namespace UnityAtoms -{ - public abstract class Collider2DGameObjectEventAction : GameAction { } -} \ No newline at end of file diff --git a/Assets/UnityAtoms/GameActions/SetVariableValue.meta b/Assets/UnityAtoms/GameActions/SetVariableValue.meta deleted file mode 100644 index 1464a362..00000000 --- a/Assets/UnityAtoms/GameActions/SetVariableValue.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2 -guid: e1c9856ef98eb420c9d483b73e3ec610 -folderAsset: yes -DefaultImporter: - externalObjects: {} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Assets/UnityAtoms/GameActions/SetVariableValue/SetBoolVariableValue.cs b/Assets/UnityAtoms/GameActions/SetVariableValue/SetBoolVariableValue.cs deleted file mode 100644 index d09da798..00000000 --- a/Assets/UnityAtoms/GameActions/SetVariableValue/SetBoolVariableValue.cs +++ /dev/null @@ -1,10 +0,0 @@ -using UnityEngine; - -namespace UnityAtoms -{ - [CreateAssetMenu(menuName = "Unity Atoms/Game Actions/Set Variable Value/Bool", - fileName = "SetBoolVariableValueAction", order = 2)] - public class SetBoolVariableValue : SetVariableValue - { - } -} \ No newline at end of file diff --git a/Assets/UnityAtoms/GameActions/SetVariableValue/SetColorVariableValue.cs b/Assets/UnityAtoms/GameActions/SetVariableValue/SetColorVariableValue.cs deleted file mode 100644 index f1210aba..00000000 --- a/Assets/UnityAtoms/GameActions/SetVariableValue/SetColorVariableValue.cs +++ /dev/null @@ -1,10 +0,0 @@ -using UnityEngine; - -namespace UnityAtoms -{ - [CreateAssetMenu(menuName = "Unity Atoms/Game Actions/Set Variable Value/Color", - fileName = "SetColorVariableValueAction", order = 3)] - public class SetColorVariableValue : SetVariableValue - { - } -} \ No newline at end of file diff --git a/Assets/UnityAtoms/GameActions/SetVariableValue/SetFloatVariableValue.cs b/Assets/UnityAtoms/GameActions/SetVariableValue/SetFloatVariableValue.cs deleted file mode 100644 index ddf39a35..00000000 --- a/Assets/UnityAtoms/GameActions/SetVariableValue/SetFloatVariableValue.cs +++ /dev/null @@ -1,10 +0,0 @@ -using UnityEngine; - -namespace UnityAtoms -{ - [CreateAssetMenu(menuName = "Unity Atoms/Game Actions/Set Variable Value/Float", - fileName = "SetFloatVariableValueAction", order = 1)] - public class SetFloatVariableValue : SetVariableValue - { - } -} \ No newline at end of file diff --git a/Assets/UnityAtoms/GameActions/SetVariableValue/SetGameObjectVariableValue.cs b/Assets/UnityAtoms/GameActions/SetVariableValue/SetGameObjectVariableValue.cs deleted file mode 100644 index 7e4986ce..00000000 --- a/Assets/UnityAtoms/GameActions/SetVariableValue/SetGameObjectVariableValue.cs +++ /dev/null @@ -1,11 +0,0 @@ -using UnityEngine; - -namespace UnityAtoms -{ - [CreateAssetMenu(menuName = "Unity Atoms/Game Actions/Set Variable Value/GameObject", - fileName = "SetGameObjectVariableValueAction", order = 6)] - public class SetGameObjectVariableValue : SetVariableValue - { - } -} \ No newline at end of file diff --git a/Assets/UnityAtoms/GameActions/SetVariableValue/SetIntVariableValue.cs b/Assets/UnityAtoms/GameActions/SetVariableValue/SetIntVariableValue.cs deleted file mode 100644 index 60a49c71..00000000 --- a/Assets/UnityAtoms/GameActions/SetVariableValue/SetIntVariableValue.cs +++ /dev/null @@ -1,10 +0,0 @@ -using UnityEngine; - -namespace UnityAtoms -{ - [CreateAssetMenu(menuName = "Unity Atoms/Game Actions/Set Variable Value/Int", - fileName = "SetIntVariableValueAction", order = 0)] - public class SetIntVariableValue : SetVariableValue - { - } -} \ No newline at end of file diff --git a/Assets/UnityAtoms/GameActions/SetVariableValue/SetVector3VariableValue.cs b/Assets/UnityAtoms/GameActions/SetVariableValue/SetVector3VariableValue.cs deleted file mode 100644 index 2b5e6720..00000000 --- a/Assets/UnityAtoms/GameActions/SetVariableValue/SetVector3VariableValue.cs +++ /dev/null @@ -1,11 +0,0 @@ -using UnityEngine; - -namespace UnityAtoms -{ - [CreateAssetMenu(menuName = "Unity Atoms/Game Actions/Set Variable Value/Vector3", - fileName = "SetVector3VariableValueAction", order = 5)] - public class SetVector3VariableValue : SetVariableValue - { - } -} \ No newline at end of file diff --git a/Assets/UnityAtoms/GameEventListeners.meta b/Assets/UnityAtoms/GameEventListeners.meta deleted file mode 100644 index f1a2adc1..00000000 --- a/Assets/UnityAtoms/GameEventListeners.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2 -guid: b6931a91a73da4b52a887f290260d402 -folderAsset: yes -DefaultImporter: - externalObjects: {} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Assets/UnityAtoms/GameEvents.meta b/Assets/UnityAtoms/GameEvents.meta deleted file mode 100644 index dd50b768..00000000 --- a/Assets/UnityAtoms/GameEvents.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2 -guid: f81562da9bcee48729913ada71c0862a -folderAsset: yes -DefaultImporter: - externalObjects: {} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Assets/UnityAtoms/GameEvents/BoolBoolEvent.cs b/Assets/UnityAtoms/GameEvents/BoolBoolEvent.cs deleted file mode 100644 index c37019bb..00000000 --- a/Assets/UnityAtoms/GameEvents/BoolBoolEvent.cs +++ /dev/null @@ -1,9 +0,0 @@ -using UnityEngine; - -namespace UnityAtoms -{ - [CreateAssetMenu(menuName = "Unity Atoms/Game Events/Bool Bool", fileName = "BoolBoolEvent", order = 5)] - public class BoolBoolEvent : GameEvent - { - } -} \ No newline at end of file diff --git a/Assets/UnityAtoms/GameEvents/BoolEvent.cs b/Assets/UnityAtoms/GameEvents/BoolEvent.cs deleted file mode 100644 index 95882423..00000000 --- a/Assets/UnityAtoms/GameEvents/BoolEvent.cs +++ /dev/null @@ -1,9 +0,0 @@ -using UnityEngine; - -namespace UnityAtoms -{ - [CreateAssetMenu(menuName = "Unity Atoms/Game Events/Bool", fileName = "BoolEvent", order = 4)] - public class BoolEvent : GameEvent - { - } -} \ No newline at end of file diff --git a/Assets/UnityAtoms/GameEvents/Collider2DEvent.cs b/Assets/UnityAtoms/GameEvents/Collider2DEvent.cs deleted file mode 100644 index a714f9de..00000000 --- a/Assets/UnityAtoms/GameEvents/Collider2DEvent.cs +++ /dev/null @@ -1,9 +0,0 @@ -using UnityEngine; - -namespace UnityAtoms -{ - [CreateAssetMenu(menuName = "Unity Atoms/Game Events/Collider2D", fileName = "Collider2DEvent", order = 12)] - public class Collider2DEvent : GameEvent - { - } -} \ No newline at end of file diff --git a/Assets/UnityAtoms/GameEvents/Collider2DGameObjectEvent.cs b/Assets/UnityAtoms/GameEvents/Collider2DGameObjectEvent.cs deleted file mode 100644 index 0ecc8484..00000000 --- a/Assets/UnityAtoms/GameEvents/Collider2DGameObjectEvent.cs +++ /dev/null @@ -1,10 +0,0 @@ -using UnityEngine; - -namespace UnityAtoms -{ - [CreateAssetMenu(menuName = "Unity Atoms/Game Events/Collider2D GameObject", fileName = "Collider2DGameObjectEvent", - order = 13)] - public class Collider2DGameObjectEvent : GameEvent - { - } -} \ No newline at end of file diff --git a/Assets/UnityAtoms/GameEvents/ColorColorEvent.cs b/Assets/UnityAtoms/GameEvents/ColorColorEvent.cs deleted file mode 100644 index e1e88e56..00000000 --- a/Assets/UnityAtoms/GameEvents/ColorColorEvent.cs +++ /dev/null @@ -1,9 +0,0 @@ -using UnityEngine; - -namespace UnityAtoms -{ - [CreateAssetMenu(menuName = "Unity Atoms/Game Events/Color Color", fileName = "ColorColorEvent", order = 7)] - public class ColorColorEvent : GameEvent - { - } -} \ No newline at end of file diff --git a/Assets/UnityAtoms/GameEvents/ColorEvent.cs b/Assets/UnityAtoms/GameEvents/ColorEvent.cs deleted file mode 100644 index e1bf1ab3..00000000 --- a/Assets/UnityAtoms/GameEvents/ColorEvent.cs +++ /dev/null @@ -1,9 +0,0 @@ -using UnityEngine; - -namespace UnityAtoms -{ - [CreateAssetMenu(menuName = "Unity Atoms/Game Events/Color", fileName = "ColorEvent", order = 6)] - public class ColorEvent : GameEvent - { - } -} \ No newline at end of file diff --git a/Assets/UnityAtoms/GameEvents/CreateEventOnAwake.meta b/Assets/UnityAtoms/GameEvents/CreateEventOnAwake.meta deleted file mode 100644 index 5067d611..00000000 --- a/Assets/UnityAtoms/GameEvents/CreateEventOnAwake.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2 -guid: 24d1bfb3b963c4391b650eded4dfb801 -folderAsset: yes -DefaultImporter: - externalObjects: {} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Assets/UnityAtoms/GameEvents/CreateEventOnAwake/CreateCollider2DEventOnAwake.cs b/Assets/UnityAtoms/GameEvents/CreateEventOnAwake/CreateCollider2DEventOnAwake.cs deleted file mode 100644 index 2c0f9366..00000000 --- a/Assets/UnityAtoms/GameEvents/CreateEventOnAwake/CreateCollider2DEventOnAwake.cs +++ /dev/null @@ -1,19 +0,0 @@ - -using UnityEngine; - -namespace UnityAtoms -{ - // public class CreateEventOnAwake : MonoBehaviour - // where E1 : GameEvent where E2 : GameEvent - // where L1 : GameEventListener where L2 : GameEventListener - // where GA1 : GameAction where GA2 : GameAction - // where UER1 : UnityEvent where UER2 : UnityEvent - public class CreateCollider2DEventOnAwake : CreateEventOnAwake< - Collider2D, Collider2DEvent, Collider2DGameObjectEvent, - Collider2DListener, Collider2DGameObjectListener, - Collider2DAction, Collider2DGameObjectAction, - UnityCollider2DEvent, UnityCollider2DGameObjectEvent, - Collider2DHook - > - { } -} \ No newline at end of file diff --git a/Assets/UnityAtoms/GameEvents/FloatEvent.cs b/Assets/UnityAtoms/GameEvents/FloatEvent.cs deleted file mode 100644 index 169b044a..00000000 --- a/Assets/UnityAtoms/GameEvents/FloatEvent.cs +++ /dev/null @@ -1,9 +0,0 @@ -using UnityEngine; - -namespace UnityAtoms -{ - [CreateAssetMenu(menuName = "Unity Atoms/Game Events/Float", fileName = "FloatEvent", order = 2)] - public class FloatEvent : GameEvent - { - } -} \ No newline at end of file diff --git a/Assets/UnityAtoms/GameEvents/FloatFloatEvent.cs b/Assets/UnityAtoms/GameEvents/FloatFloatEvent.cs deleted file mode 100644 index e8d6f06f..00000000 --- a/Assets/UnityAtoms/GameEvents/FloatFloatEvent.cs +++ /dev/null @@ -1,9 +0,0 @@ -using UnityEngine; - -namespace UnityAtoms -{ - [CreateAssetMenu(menuName = "Unity Atoms/Game Events/Float Float", fileName = "FloatFloatEvent", order = 3)] - public class FloatFloatEvent : GameEvent - { - } -} \ No newline at end of file diff --git a/Assets/UnityAtoms/GameEvents/GameObjectCollider2DEvent.cs b/Assets/UnityAtoms/GameEvents/GameObjectCollider2DEvent.cs deleted file mode 100644 index 6f823c00..00000000 --- a/Assets/UnityAtoms/GameEvents/GameObjectCollider2DEvent.cs +++ /dev/null @@ -1,10 +0,0 @@ -using UnityEngine; - -namespace UnityAtoms -{ - [CreateAssetMenu(menuName = "Unity Atoms/Game Events/GameObject Collider2D", fileName = "GameObjectCollider2DEvent", - order = 15)] - public class GameObjectCollider2DEvent : GameEvent - { - } -} \ No newline at end of file diff --git a/Assets/UnityAtoms/GameEvents/GameObjectEvent.cs b/Assets/UnityAtoms/GameEvents/GameObjectEvent.cs deleted file mode 100644 index e4280833..00000000 --- a/Assets/UnityAtoms/GameEvents/GameObjectEvent.cs +++ /dev/null @@ -1,9 +0,0 @@ -using UnityEngine; - -namespace UnityAtoms -{ - [CreateAssetMenu(menuName = "Unity Atoms/Game Events/GameObject", fileName = "GameObjectEvent", order = 14)] - public class GameObjectEvent : GameEvent - { - } -} \ No newline at end of file diff --git a/Assets/UnityAtoms/GameEvents/GameObjectGameObjectEvent.cs b/Assets/UnityAtoms/GameEvents/GameObjectGameObjectEvent.cs deleted file mode 100644 index 6b04e237..00000000 --- a/Assets/UnityAtoms/GameEvents/GameObjectGameObjectEvent.cs +++ /dev/null @@ -1,10 +0,0 @@ -using UnityEngine; - -namespace UnityAtoms -{ - [CreateAssetMenu(menuName = "Unity Atoms/Game Events/GameObject GameObject", fileName = "GameObjectGameObjectEvent", - order = 16)] - public class GameObjectGameObjectEvent : GameEvent - { - } -} \ No newline at end of file diff --git a/Assets/UnityAtoms/GameEvents/IntEvent.cs b/Assets/UnityAtoms/GameEvents/IntEvent.cs deleted file mode 100644 index c5afb20d..00000000 --- a/Assets/UnityAtoms/GameEvents/IntEvent.cs +++ /dev/null @@ -1,9 +0,0 @@ -using UnityEngine; - -namespace UnityAtoms -{ - [CreateAssetMenu(menuName = "Unity Atoms/Game Events/Int", fileName = "IntEvent", order = 0)] - public class IntEvent : GameEvent - { - } -} \ No newline at end of file diff --git a/Assets/UnityAtoms/GameEvents/IntIntEvent.cs b/Assets/UnityAtoms/GameEvents/IntIntEvent.cs deleted file mode 100644 index 27ad2629..00000000 --- a/Assets/UnityAtoms/GameEvents/IntIntEvent.cs +++ /dev/null @@ -1,9 +0,0 @@ -using UnityEngine; - -namespace UnityAtoms -{ - [CreateAssetMenu(menuName = "Unity Atoms/Game Events/Int Int", fileName = "IntIntEvent", order = 1)] - public class IntIntEvent : GameEvent - { - } -} \ No newline at end of file diff --git a/Assets/UnityAtoms/GameEvents/Vector2Event.cs b/Assets/UnityAtoms/GameEvents/Vector2Event.cs deleted file mode 100644 index c3efe089..00000000 --- a/Assets/UnityAtoms/GameEvents/Vector2Event.cs +++ /dev/null @@ -1,9 +0,0 @@ -using UnityEngine; - -namespace UnityAtoms -{ - [CreateAssetMenu(menuName = "Unity Atoms/Game Events/Vector2", fileName = "Vector2Event", order = 8)] - public class Vector2Event : GameEvent - { - } -} \ No newline at end of file diff --git a/Assets/UnityAtoms/GameEvents/Vector2Vector2Event.cs b/Assets/UnityAtoms/GameEvents/Vector2Vector2Event.cs deleted file mode 100644 index d451d0c5..00000000 --- a/Assets/UnityAtoms/GameEvents/Vector2Vector2Event.cs +++ /dev/null @@ -1,9 +0,0 @@ -using UnityEngine; - -namespace UnityAtoms -{ - [CreateAssetMenu(menuName = "Unity Atoms/Game Events/Vector2 Vector2", fileName = "Vector2Vector2Event", order = 9)] - public class Vector2Vector2Event : GameEvent - { - } -} \ No newline at end of file diff --git a/Assets/UnityAtoms/GameEvents/Vector3Event.cs b/Assets/UnityAtoms/GameEvents/Vector3Event.cs deleted file mode 100644 index 1450f2be..00000000 --- a/Assets/UnityAtoms/GameEvents/Vector3Event.cs +++ /dev/null @@ -1,9 +0,0 @@ -using UnityEngine; - -namespace UnityAtoms -{ - [CreateAssetMenu(menuName = "Unity Atoms/Game Events/Vector3", fileName = "Vector3Event", order = 10)] - public class Vector3Event : GameEvent - { - } -} \ No newline at end of file diff --git a/Assets/UnityAtoms/GameEvents/Vector3Vector3Event.cs b/Assets/UnityAtoms/GameEvents/Vector3Vector3Event.cs deleted file mode 100644 index 85649a45..00000000 --- a/Assets/UnityAtoms/GameEvents/Vector3Vector3Event.cs +++ /dev/null @@ -1,10 +0,0 @@ -using UnityEngine; - -namespace UnityAtoms -{ - [CreateAssetMenu(menuName = "Unity Atoms/Game Events/Vector3 Vector3", fileName = "Vector3Vector3Event", - order = 11)] - public class Vector3Vector3Event : GameEvent - { - } -} \ No newline at end of file diff --git a/Assets/UnityAtoms/GameEvents/VoidGameObjectEvent.cs b/Assets/UnityAtoms/GameEvents/VoidGameObjectEvent.cs deleted file mode 100644 index d277008d..00000000 --- a/Assets/UnityAtoms/GameEvents/VoidGameObjectEvent.cs +++ /dev/null @@ -1,10 +0,0 @@ -using UnityEngine; - -namespace UnityAtoms -{ - [CreateAssetMenu(menuName = "Unity Atoms/Game Events/Void GameObject", fileName = "VoidGameObjectEvent", - order = 101)] - public class VoidGameObjectEvent : GameEvent - { - } -} \ No newline at end of file diff --git a/Assets/UnityAtoms/GameFunctions/GetUnusedGameObject.meta b/Assets/UnityAtoms/GameFunctions/GetUnusedGameObject.meta deleted file mode 100644 index c67ac581..00000000 --- a/Assets/UnityAtoms/GameFunctions/GetUnusedGameObject.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2 -guid: 66a9ae44edb6e4513b0140745b09f0a2 -folderAsset: yes -DefaultImporter: - externalObjects: {} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Assets/UnityAtoms/GameFunctions/GetUnusedGameObject/GetUnusedGameObject.cs b/Assets/UnityAtoms/GameFunctions/GetUnusedGameObject/GetUnusedGameObject.cs deleted file mode 100644 index 8a28a79d..00000000 --- a/Assets/UnityAtoms/GameFunctions/GetUnusedGameObject/GetUnusedGameObject.cs +++ /dev/null @@ -1,44 +0,0 @@ -using System.Collections; -using System.Collections.Generic; -using UnityEngine; - -namespace UnityAtoms -{ - /* Gets an unused GameObject from the GameObjectList. If an GameObject is used or not is determined by IsUsed GameFunction. - * If no unused GameObject is found a new one is instantiated and added to the GameObjectList. - */ - [CreateAssetMenu(menuName = "Unity Atoms/Game Functions/Get Unused GameObject")] - public class GetUnusedGameObject : GameObjectVector3QuaternionFunction - { - [SerializeField] - private GameObjectList List; - - [SerializeField] - private GameObject Prefab; - - [SerializeField] - private BoolGameObjectFunction IsUsed; - - public override GameObject Call(Vector3 position, Quaternion quaternion) - { - if (IsUsed == null) - { - Debug.LogWarning("IsUsed must be defined!"); - } - - for (int i = 0; i < List.Count; ++i) - { - if (!IsUsed.Call(List[i])) - { - List[i].transform.position = position; - List[i].transform.rotation = quaternion; - return List[i]; - } - } - - var newGameObject = Instantiate(Prefab, position, quaternion); - List.Add(newGameObject); - return newGameObject; - } - } -} \ No newline at end of file diff --git a/Assets/UnityAtoms/Lists.meta b/Assets/UnityAtoms/Lists.meta deleted file mode 100644 index 31172ee1..00000000 --- a/Assets/UnityAtoms/Lists.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2 -guid: 2e9e7b58ea92246bba58fc3707b36295 -folderAsset: yes -DefaultImporter: - externalObjects: {} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Assets/UnityAtoms/Lists/BoolList.cs b/Assets/UnityAtoms/Lists/BoolList.cs deleted file mode 100644 index 74e5074d..00000000 --- a/Assets/UnityAtoms/Lists/BoolList.cs +++ /dev/null @@ -1,9 +0,0 @@ -using UnityEngine; - -namespace UnityAtoms -{ - [CreateAssetMenu(menuName = "Unity Atoms/Lists/Bool", fileName = "BoolList", order = 2)] - public class BoolList : ScriptableObjectList - { - } -} \ No newline at end of file diff --git a/Assets/UnityAtoms/Lists/Collider2DList.cs b/Assets/UnityAtoms/Lists/Collider2DList.cs deleted file mode 100644 index e6539872..00000000 --- a/Assets/UnityAtoms/Lists/Collider2DList.cs +++ /dev/null @@ -1,9 +0,0 @@ -using UnityEngine; - -namespace UnityAtoms -{ - [CreateAssetMenu(menuName = "Unity Atoms/Lists/Collider2D", fileName = "Collider2DList", order = 6)] - public class Collider2DList : ScriptableObjectList - { - } -} \ No newline at end of file diff --git a/Assets/UnityAtoms/Lists/ColorList.cs b/Assets/UnityAtoms/Lists/ColorList.cs deleted file mode 100644 index ffa4389b..00000000 --- a/Assets/UnityAtoms/Lists/ColorList.cs +++ /dev/null @@ -1,9 +0,0 @@ -using UnityEngine; - -namespace UnityAtoms -{ - [CreateAssetMenu(menuName = "Unity Atoms/Lists/Color", fileName = "ColorList", order = 3)] - public class ColorList : ScriptableObjectList - { - } -} \ No newline at end of file diff --git a/Assets/UnityAtoms/Lists/FloatList.cs b/Assets/UnityAtoms/Lists/FloatList.cs deleted file mode 100644 index e2efe3c4..00000000 --- a/Assets/UnityAtoms/Lists/FloatList.cs +++ /dev/null @@ -1,9 +0,0 @@ -using UnityEngine; - -namespace UnityAtoms -{ - [CreateAssetMenu(menuName = "Unity Atoms/Lists/Float", fileName = "FloatList", order = 1)] - public class FloatList : ScriptableObjectList - { - } -} \ No newline at end of file diff --git a/Assets/UnityAtoms/Lists/GameObjectList.cs b/Assets/UnityAtoms/Lists/GameObjectList.cs deleted file mode 100644 index 30e95ee7..00000000 --- a/Assets/UnityAtoms/Lists/GameObjectList.cs +++ /dev/null @@ -1,10 +0,0 @@ -using System; -using UnityEngine; - -namespace UnityAtoms -{ - [CreateAssetMenu(menuName = "Unity Atoms/Lists/GameObject", fileName = "GameObjectList", order = 7)] - public class GameObjectList : ScriptableObjectList - { - } -} \ No newline at end of file diff --git a/Assets/UnityAtoms/Lists/IntList.cs b/Assets/UnityAtoms/Lists/IntList.cs deleted file mode 100644 index 21ef26d1..00000000 --- a/Assets/UnityAtoms/Lists/IntList.cs +++ /dev/null @@ -1,9 +0,0 @@ -using UnityEngine; - -namespace UnityAtoms -{ - [CreateAssetMenu(menuName = "Unity Atoms/Lists/Int", fileName = "IntList", order = 0)] - public class IntList : ScriptableObjectList - { - } -} \ No newline at end of file diff --git a/Assets/UnityAtoms/Lists/Vector2List.cs b/Assets/UnityAtoms/Lists/Vector2List.cs deleted file mode 100644 index 491491b9..00000000 --- a/Assets/UnityAtoms/Lists/Vector2List.cs +++ /dev/null @@ -1,9 +0,0 @@ -using UnityEngine; - -namespace UnityAtoms -{ - [CreateAssetMenu(menuName = "Unity Atoms/Lists/Vector2", fileName = "Vector2List", order = 4)] - public class Vector2List : ScriptableObjectList - { - } -} \ No newline at end of file diff --git a/Assets/UnityAtoms/Lists/Vector3List.cs b/Assets/UnityAtoms/Lists/Vector3List.cs deleted file mode 100644 index b097e7cc..00000000 --- a/Assets/UnityAtoms/Lists/Vector3List.cs +++ /dev/null @@ -1,9 +0,0 @@ -using UnityEngine; - -namespace UnityAtoms -{ - [CreateAssetMenu(menuName = "Unity Atoms/Lists/Vector3", fileName = "Vector3List", order = 5)] - public class Vector3List : ScriptableObjectList - { - } -} \ No newline at end of file diff --git a/Assets/UnityAtoms/References.meta b/Assets/UnityAtoms/References.meta deleted file mode 100644 index a4068466..00000000 --- a/Assets/UnityAtoms/References.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2 -guid: 7542f0701f65b4ba4a712d2fe7a7d1b0 -folderAsset: yes -DefaultImporter: - externalObjects: {} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Assets/UnityAtoms/References/Editor.meta b/Assets/UnityAtoms/References/Editor.meta deleted file mode 100644 index e2f09684..00000000 --- a/Assets/UnityAtoms/References/Editor.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2 -guid: 465af7166dc584352abfbd4465361711 -folderAsset: yes -DefaultImporter: - externalObjects: {} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Assets/UnityAtoms/UnityEvents.meta b/Assets/UnityAtoms/UnityEvents.meta deleted file mode 100644 index 5c681747..00000000 --- a/Assets/UnityAtoms/UnityEvents.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2 -guid: ef08246e8e69e4bac85d0a3e5c564a98 -folderAsset: yes -DefaultImporter: - externalObjects: {} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Assets/UnityAtoms/UnityEvents/UnityEvents.cs b/Assets/UnityAtoms/UnityEvents/UnityEvents.cs deleted file mode 100644 index fa3e3dbc..00000000 --- a/Assets/UnityAtoms/UnityEvents/UnityEvents.cs +++ /dev/null @@ -1,31 +0,0 @@ -using System; -using UnityEngine.Events; -using UnityEngine; - -namespace UnityAtoms -{ - [Serializable] - public class UnityBoolEvent : UnityEvent { } - [Serializable] - public class UnityCollider2DEvent : UnityEvent { } - [Serializable] - public class UnityColorEvent : UnityEvent { } - [Serializable] - public class UnityFloatEvent : UnityEvent { } - [Serializable] - public class UnityGameObjectEvent : UnityEvent { } - [Serializable] - public class UnityIntEvent : UnityEvent { } - [Serializable] - public class UnityVector2Event : UnityEvent { } - [Serializable] - public class UnityVector3Event : UnityEvent { } - [Serializable] - public class UnityVoidEvent : UnityEvent { } - - - [Serializable] - public class UnityCollider2DGameObjectEvent : UnityEvent { } - [Serializable] - public class UnityVoidGameObjectEvent : UnityEvent { } -} \ No newline at end of file diff --git a/Assets/UnityAtoms/Variables.meta b/Assets/UnityAtoms/Variables.meta deleted file mode 100644 index ccd29697..00000000 --- a/Assets/UnityAtoms/Variables.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2 -guid: 5b256372890954b0fa50606ced479496 -folderAsset: yes -DefaultImporter: - externalObjects: {} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Assets/UnityAtoms/Variables/BoolVariable.cs b/Assets/UnityAtoms/Variables/BoolVariable.cs deleted file mode 100644 index bde2d6fe..00000000 --- a/Assets/UnityAtoms/Variables/BoolVariable.cs +++ /dev/null @@ -1,9 +0,0 @@ -using UnityEngine; - -namespace UnityAtoms -{ - [CreateAssetMenu(menuName = "Unity Atoms/Variables/Bool", fileName = "BoolVariable", order = 2)] - public class BoolVariable : EquatableScriptableObjectVariable - { - } -} \ No newline at end of file diff --git a/Assets/UnityAtoms/Variables/GameObjectVariable.cs b/Assets/UnityAtoms/Variables/GameObjectVariable.cs deleted file mode 100644 index 5c107396..00000000 --- a/Assets/UnityAtoms/Variables/GameObjectVariable.cs +++ /dev/null @@ -1,13 +0,0 @@ -using UnityEngine; - -namespace UnityAtoms -{ - [CreateAssetMenu(menuName = "Unity Atoms/Variables/GameObject", fileName = "GameObjectVariable", order = 6)] - public class GameObjectVariable : ScriptableObjectVariable - { - protected override bool AreEqual(GameObject first, GameObject second) - { - return first.GetInstanceID() == second.GetInstanceID(); - } - } -} \ No newline at end of file diff --git a/Assets/UnityAtoms/Variables/ScriptableObjectVariableBase.cs b/Assets/UnityAtoms/Variables/ScriptableObjectVariableBase.cs deleted file mode 100644 index c986c60d..00000000 --- a/Assets/UnityAtoms/Variables/ScriptableObjectVariableBase.cs +++ /dev/null @@ -1,17 +0,0 @@ -using System; -using System.Collections.Generic; -using UnityEngine; - -namespace UnityAtoms -{ - public abstract class ScriptableObjectVariableBase : ScriptableObject, IWithValue - { - [Multiline] - public string DeveloperDescription = ""; - - public virtual T Value { get { return value; } set { } } - - [SerializeField] - protected T value; - } -} \ No newline at end of file diff --git a/Assets/UnityAtoms/Variables/Utils.meta b/Assets/UnityAtoms/Variables/Utils.meta deleted file mode 100644 index 2600d1fe..00000000 --- a/Assets/UnityAtoms/Variables/Utils.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2 -guid: 9693935f2160243b89477918a91c32d3 -folderAsset: yes -DefaultImporter: - externalObjects: {} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Assets/UnityAtoms/Variables/Utils/VariableUtils.cs b/Assets/UnityAtoms/Variables/Utils/VariableUtils.cs deleted file mode 100644 index 6c986356..00000000 --- a/Assets/UnityAtoms/Variables/Utils/VariableUtils.cs +++ /dev/null @@ -1,15 +0,0 @@ -using UnityEngine; - -namespace UnityAtoms -{ - public static class VariableUtils - { - public static V CreateVariable(bool createChangedEvent = true, bool createChangedWithHistoryEvent = false) where V : ScriptableObjectVariable where E1 : GameEvent where E2 : GameEvent - { - var sov = ScriptableObject.CreateInstance(); - sov.Changed = createChangedEvent ? ScriptableObject.CreateInstance() : null; - sov.ChangedWithHistory = createChangedWithHistoryEvent ? ScriptableObject.CreateInstance() : null; - return sov; - } - } -} diff --git a/Assets/UnityAtoms/Variables/Utils/VariableUtils.cs.meta b/Assets/UnityAtoms/Variables/Utils/VariableUtils.cs.meta deleted file mode 100644 index 740bb1ac..00000000 --- a/Assets/UnityAtoms/Variables/Utils/VariableUtils.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: e5b3fa20aa7fc4601bd91447112f4454 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/LICENSE.meta b/LICENSE.meta new file mode 100644 index 00000000..b9dd045e --- /dev/null +++ b/LICENSE.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: 9c9e51f1e8f7a41ef9d9c41983521433 +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Packages/manifest.json b/Packages/manifest.json deleted file mode 100644 index 1342d0a7..00000000 --- a/Packages/manifest.json +++ /dev/null @@ -1,39 +0,0 @@ -{ - "dependencies": { - "com.unity.ads": "2.0.8", - "com.unity.analytics": "2.0.16", - "com.unity.package-manager-ui": "1.9.11", - "com.unity.purchasing": "2.0.3", - "com.unity.textmeshpro": "1.2.4", - "com.unity.modules.ai": "1.0.0", - "com.unity.modules.animation": "1.0.0", - "com.unity.modules.assetbundle": "1.0.0", - "com.unity.modules.audio": "1.0.0", - "com.unity.modules.cloth": "1.0.0", - "com.unity.modules.director": "1.0.0", - "com.unity.modules.imageconversion": "1.0.0", - "com.unity.modules.imgui": "1.0.0", - "com.unity.modules.jsonserialize": "1.0.0", - "com.unity.modules.particlesystem": "1.0.0", - "com.unity.modules.physics": "1.0.0", - "com.unity.modules.physics2d": "1.0.0", - "com.unity.modules.screencapture": "1.0.0", - "com.unity.modules.terrain": "1.0.0", - "com.unity.modules.terrainphysics": "1.0.0", - "com.unity.modules.tilemap": "1.0.0", - "com.unity.modules.ui": "1.0.0", - "com.unity.modules.uielements": "1.0.0", - "com.unity.modules.umbra": "1.0.0", - "com.unity.modules.unityanalytics": "1.0.0", - "com.unity.modules.unitywebrequest": "1.0.0", - "com.unity.modules.unitywebrequestassetbundle": "1.0.0", - "com.unity.modules.unitywebrequestaudio": "1.0.0", - "com.unity.modules.unitywebrequesttexture": "1.0.0", - "com.unity.modules.unitywebrequestwww": "1.0.0", - "com.unity.modules.vehicles": "1.0.0", - "com.unity.modules.video": "1.0.0", - "com.unity.modules.vr": "1.0.0", - "com.unity.modules.wind": "1.0.0", - "com.unity.modules.xr": "1.0.0" - } -} diff --git a/ProjectSettings/ProjectVersion.txt b/ProjectSettings/ProjectVersion.txt deleted file mode 100644 index f1fda1a8..00000000 --- a/ProjectSettings/ProjectVersion.txt +++ /dev/null @@ -1 +0,0 @@ -m_EditorVersion: 2018.2.14f1 diff --git a/README.md b/README.md index 7281081a..bb946e49 100644 --- a/README.md +++ b/README.md @@ -19,6 +19,17 @@ Unity Atoms is an open source library that aims to make your game code: ## Introduction Before you start looking into this library you should watch the video above ☝️ and read [this](https://unity3d.com/how-to/architect-with-scriptable-objects) article on how to architect your game with Scriptable Objects. +## Installation 2018.3+ +Go to your projects `Packages/manifest.json` and add this: + + "dependencies": { + ... + "com.mambojambostudios.unity-atoms": "https://github.com/AdamRamberg/unity-atoms.git#v1.0.0", + ... + } + +This will make the Unity packagemager install it. + ## Usage Unity Atoms is an event based system that encourages the game to be as data-driven as possible. The 4 most fundamental pieces (atoms) of Unity Atoms are: - Variables @@ -72,4 +83,4 @@ When you start thinking about this pattern you will realize that everything can Examples will soon be added to this project. ## Contribution -Would ❤️ if you would like to contribute to the project. Post me a message if you want to become a contributer. \ No newline at end of file +Would ❤️ if you would like to contribute to the project. Post me a message if you want to become a contributer. diff --git a/README.md.meta b/README.md.meta new file mode 100644 index 00000000..827a064d --- /dev/null +++ b/README.md.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: b4d690cccba4848f78a3f842bf611d1a +TextScriptImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/UnityAtoms.meta b/Source.meta similarity index 77% rename from Assets/UnityAtoms.meta rename to Source.meta index 66de91bb..7de6ba54 100644 --- a/Assets/UnityAtoms.meta +++ b/Source.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: efcad9197646b4edea139b64e41bad22 +guid: 801798f80823c4da4a3c7f50885855f2 folderAsset: yes DefaultImporter: externalObjects: {} diff --git a/Assets/UnityAtoms/Constants.meta b/Source/AtomicTags.meta similarity index 77% rename from Assets/UnityAtoms/Constants.meta rename to Source/AtomicTags.meta index c77f5a8b..1d34ce35 100644 --- a/Assets/UnityAtoms/Constants.meta +++ b/Source/AtomicTags.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 5a005666929044374a4cce42e2137dc8 +guid: b728251faa7854a7f83e071244410591 folderAsset: yes DefaultImporter: externalObjects: {} diff --git a/Source/AtomicTags/AtomicTags.cs b/Source/AtomicTags/AtomicTags.cs new file mode 100644 index 00000000..6032f201 --- /dev/null +++ b/Source/AtomicTags/AtomicTags.cs @@ -0,0 +1,175 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Reflection; +#if UNITY_EDITOR +using UnityEditor; +#endif +using UnityEngine; + +namespace UnityAtoms +{ + public class AtomicTags : MonoBehaviour, ISerializationCallbackReceiver + { + + public ReadOnlyList Tags { get; private set; } + private SortedList sortedTags = new SortedList(); + private static Dictionary> taggedGOs = new Dictionary>(); + private static Dictionary instances = new Dictionary(); + + #region Serialization + public List _tags = new List(); + public void OnBeforeSerialize() + { +#if UNITY_EDITOR + if(!EditorApplication.isPlaying + && !EditorApplication.isUpdating + && !EditorApplication.isCompiling) return; +#endif + _tags.Clear(); + foreach (var kvp in sortedTags) + { + _tags.Add(kvp.Value); + } + } + + public void OnAfterDeserialize() + { + sortedTags = new SortedList(); + + for (int i = 0; i != _tags.Count; i++) + { + if (_tags[i] == null || _tags[i].Value == null) continue; + if (sortedTags.ContainsKey(_tags[i].Value)) continue; + sortedTags.Add(_tags[i].Value, _tags[i]); + } + } + #endregion + + private void OnValidate() + { + OnAfterDeserialize(); // removes double values and nulls + _tags = sortedTags.Values.ToList(); +#if UNITY_EDITOR + // this null value is just for easier editing and could also be archived with an custom inspector + if(!EditorApplication.isPlaying){ _tags.Add(null); } +#endif + } + + #region Lifecycle + + private void Awake() + { + Tags = new ReadOnlyList(sortedTags.Values); + } + + private void OnEnable() + { + if (!instances.ContainsKey(this.gameObject)) instances.Add(this.gameObject, this); + foreach (var stringConstant in Tags) + { + if (stringConstant == null) continue; + var tag = stringConstant.Value; + if (!taggedGOs.ContainsKey(tag)) taggedGOs.Add(tag, new List()); + taggedGOs[tag].Add(this.gameObject); + }; + } + + private void OnDisable() + { + if (instances.ContainsKey(this.gameObject)) instances.Remove(this.gameObject); + foreach (var stringConstant in Tags) + { + if (stringConstant == null) continue; + var tag = stringConstant.Value; + if (taggedGOs.ContainsKey(tag)) taggedGOs[tag].Remove(this.gameObject); + }; + } + + #endregion + + public bool HasTag(string tag) + { + if (tag == null) return false; + return sortedTags.ContainsKey(tag); + } + + public void AddTag(StringConstant tag) + { + if (tag == null || tag.Value == null) return; + if (sortedTags.ContainsKey(tag.Value)) return; + sortedTags.Add(tag.Value, tag); + + Tags = new ReadOnlyList(sortedTags.Values); + + // Update static accessors: + if (!taggedGOs.ContainsKey(tag.Value)) taggedGOs.Add(tag.Value, new List()); + taggedGOs[tag.Value].Add(this.gameObject); + } + + public void RemoveTag(string tag) + { + if (tag == null) return; + if (sortedTags.ContainsKey(tag)) return; + sortedTags.Remove(tag); + + Tags = new ReadOnlyList(sortedTags.Values); + + // Update static accessors: + if (!taggedGOs.ContainsKey(tag)) return; // this should never happen + taggedGOs[tag].Remove(this.gameObject); + } + + public static GameObject FindByTag(string tag) + { + if (!taggedGOs.ContainsKey(tag)) return null; + return taggedGOs[tag][0]; + } + + public static GameObject[] FindAllByTag(string tag) + { + if (!taggedGOs.ContainsKey(tag)) return null; + return taggedGOs[tag].ToArray(); + } + + public static void FindAllByTagNoAlloc(string tag, List output) + { + output.Clear(); + if (!taggedGOs.ContainsKey(tag)) return; + for (var i = 0; i < taggedGOs[tag].Count; ++i) + { + output.Add(taggedGOs[tag][i]); + } + } + + /// + /// Faster alternative to go.GetComponent<AtomicTags>() since they are already cached in a dictionary + /// + /// + /// - null if the GameObject does not have AtomicTags or they (or the GO) are disabled + /// - the AtomicTag component + /// + public static AtomicTags GetForGameObject(GameObject go) + { + if (!instances.ContainsKey(go)) return null; + return instances[go]; + } + + /// + /// Retrieves all AtomicTags for a given GameObject + /// + /// + /// - null if the GameObject does not have AtomicTags or they (or the GO) are disabled + /// - an readonly list of strings containing the tags + /// - should be faster than go.GetComponent<AtomicTags>().tags + /// + public static ReadOnlyList GetAtomicTags(GameObject go) + { + if (!instances.ContainsKey(go)) return null; + var atomicTags = instances[go]; + return atomicTags.Tags; + } + + + } +} diff --git a/Source/AtomicTags/AtomicTags.cs.meta b/Source/AtomicTags/AtomicTags.cs.meta new file mode 100644 index 00000000..4c017696 --- /dev/null +++ b/Source/AtomicTags/AtomicTags.cs.meta @@ -0,0 +1,3 @@ +fileFormatVersion: 2 +guid: 3570dca9cf8f40ac9731ef4082c9a4ef +timeCreated: 1551964650 \ No newline at end of file diff --git a/Source/AtomicTags/ReadOnlyList.cs b/Source/AtomicTags/ReadOnlyList.cs new file mode 100644 index 00000000..6c70e722 --- /dev/null +++ b/Source/AtomicTags/ReadOnlyList.cs @@ -0,0 +1,36 @@ +using System; +using System.Collections; + using System.Collections.Generic; + + namespace UnityAtoms { + /// + /// This is basically an IList without everything that could mutate the list + /// + public class ReadOnlyList : IEnumerable, IEnumerable { + private readonly IList referenceList; + + public ReadOnlyList(IList referenceList) { this.referenceList = referenceList; } + + public IEnumerator GetEnumerator() { return referenceList.GetEnumerator(); } + + IEnumerator IEnumerable.GetEnumerator() { return GetEnumerator(); } + + public bool Contains(T item) { return referenceList.Contains(item); } + public int IndexOf(T item) { return referenceList.IndexOf(item); } + + public void CopyTo(T[] array, int arrayIndex) { referenceList.CopyTo(array, arrayIndex); } + + public int Count { + get { return referenceList.Count; } + } + + public bool IsReadOnly { + get { return true; } + } + + public T this[int index] { + get { return referenceList[index]; } + } + } + + } \ No newline at end of file diff --git a/Source/AtomicTags/ReadOnlyList.cs.meta b/Source/AtomicTags/ReadOnlyList.cs.meta new file mode 100644 index 00000000..d175dc3b --- /dev/null +++ b/Source/AtomicTags/ReadOnlyList.cs.meta @@ -0,0 +1,3 @@ +fileFormatVersion: 2 +guid: 2b6227512dd049558deecbd5b25077a2 +timeCreated: 1551963502 \ No newline at end of file diff --git a/Assets/UnityAtoms/CreateOnAwake/CreateListOnAwake.meta b/Source/AtomicUI.meta similarity index 77% rename from Assets/UnityAtoms/CreateOnAwake/CreateListOnAwake.meta rename to Source/AtomicUI.meta index 1cd21407..e0bd6670 100644 --- a/Assets/UnityAtoms/CreateOnAwake/CreateListOnAwake.meta +++ b/Source/AtomicUI.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: f7bf490017eec4167b9746660c081299 +guid: 4944b67afb22a4fd69f3d5af34cb6475 folderAsset: yes DefaultImporter: externalObjects: {} diff --git a/Source/AtomicUI/UIContainer.cs b/Source/AtomicUI/UIContainer.cs new file mode 100644 index 00000000..85b05e28 --- /dev/null +++ b/Source/AtomicUI/UIContainer.cs @@ -0,0 +1,56 @@ +using System.Collections; +using System.Collections.Generic; +using UnityEngine; + +namespace UnityAtoms.UI +{ + public class UIContainer : MonoBehaviour, IGameEventListener + { + [SerializeField] + private StringVariable UIStateVariable = null; + [SerializeField] + private List VisibleForStates = null; + + void Start() + { + StateNameChanged(UIStateVariable.Value); + } + + public void OnEventRaised(string stateName) + { + StateNameChanged(stateName); + } + + private void StateNameChanged(string stateName) + { + if (VisibleForStates.Exists((state) => state.Value == stateName)) + { + GetComponent().alpha = 1f; + GetComponent().blocksRaycasts = true; + GetComponent().interactable = true; + } + else + { + GetComponent().alpha = 0f; + GetComponent().blocksRaycasts = false; + GetComponent().interactable = false; + } + } + + private void Awake() + { + if (UIStateVariable.Changed != null) + { + UIStateVariable.Changed.RegisterListener(this); + } + } + + private void OnDestroy() + { + if (UIStateVariable.Changed != null) + { + UIStateVariable.Changed.UnregisterListener(this); + } + } + } +} diff --git a/Assets/UnityAtoms/Examples/Intro/Scripts/Harmful.cs.meta b/Source/AtomicUI/UIContainer.cs.meta similarity index 83% rename from Assets/UnityAtoms/Examples/Intro/Scripts/Harmful.cs.meta rename to Source/AtomicUI/UIContainer.cs.meta index 016380c5..721cdf13 100644 --- a/Assets/UnityAtoms/Examples/Intro/Scripts/Harmful.cs.meta +++ b/Source/AtomicUI/UIContainer.cs.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: b97da5e1105ef486696939996e891752 +guid: bced320f87ec14de98a51ee9c0ebb03e MonoImporter: externalObjects: {} serializedVersion: 2 diff --git a/Assets/UnityAtoms/CreateOnAwake/CreateVariableOnAwake.meta b/Source/Base.meta similarity index 77% rename from Assets/UnityAtoms/CreateOnAwake/CreateVariableOnAwake.meta rename to Source/Base.meta index 3b8401c0..1e49420b 100644 --- a/Assets/UnityAtoms/CreateOnAwake/CreateVariableOnAwake.meta +++ b/Source/Base.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 233fa789c93e44857a7192edddaa550b +guid: 53751a37e99fb4c01823ad15345cf19a folderAsset: yes DefaultImporter: externalObjects: {} diff --git a/Source/Base/ConditionalGameActionHelper.cs b/Source/Base/ConditionalGameActionHelper.cs new file mode 100644 index 00000000..49c69446 --- /dev/null +++ b/Source/Base/ConditionalGameActionHelper.cs @@ -0,0 +1,150 @@ +using System; +using UnityEngine; + +namespace UnityAtoms +{ + public class ConditionalGameActionHelper where GA : GameAction where C : GameFunction + { + [SerializeField] + private C Condition = null; + [SerializeField] + private GA Action = null; + [SerializeField] + private VoidAction VoidAction = null; + + [SerializeField] + private GA ElseAction = null; + [SerializeField] + private VoidAction ElseVoidAction = null; + + public void Do(T1 t1) + { + if (Condition == null || Condition.Call(t1)) + { + if (Action != null) { Action.Do(t1); } + if (VoidAction != null) { VoidAction.Do(); } + } + else + { + if (ElseAction != null) { ElseAction.Do(t1); } + if (ElseVoidAction != null) { ElseVoidAction.Do(); } + } + } + } + + public class ConditionalGameActionHelper where GA : GameAction where C : GameFunction + { + [SerializeField] + private C Condition = null; + [SerializeField] + private GA Action = null; + [SerializeField] + private VoidAction VoidAction = null; + + [SerializeField] + private GA ElseAction = null; + [SerializeField] + private VoidAction ElseVoidAction = null; + + public void Do(T1 t1, T2 t2) + { + if (Condition == null || Condition.Call(t1, t2)) + { + if (Action != null) { Action.Do(t1, t2); } + if (VoidAction != null) { VoidAction.Do(); } + } + else + { + if (ElseAction != null) { ElseAction.Do(t1, t2); } + if (ElseVoidAction != null) { ElseVoidAction.Do(); } + } + } + } + + public class ConditionalGameActionHelper where GA : GameAction where C : GameFunction + { + [SerializeField] + private C Condition = null; + [SerializeField] + private GA Action = null; + [SerializeField] + private VoidAction VoidAction = null; + + [SerializeField] + private GA ElseAction = null; + [SerializeField] + private VoidAction ElseVoidAction = null; + + public void Do(T1 t1, T2 t2, T3 t3) + { + if (Condition == null || Condition.Call(t1, t2, t3)) + { + if (Action != null) { Action.Do(t1, t2, t3); } + if (VoidAction != null) { VoidAction.Do(); } + } + else + { + if (ElseAction != null) { ElseAction.Do(t1, t2, t3); } + if (ElseVoidAction != null) { ElseVoidAction.Do(); } + } + } + } + + public class ConditionalGameActionHelper where GA : GameAction where C : GameFunction + { + [SerializeField] + private C Condition = null; + [SerializeField] + private GA Action = null; + [SerializeField] + private VoidAction VoidAction = null; + + [SerializeField] + private GA ElseAction = null; + [SerializeField] + private VoidAction ElseVoidAction = null; + + public void Do(T1 t1, T2 t2, T3 t3, T4 t4) + { + if (Condition == null || Condition.Call(t1, t2, t3, t4)) + { + if (Action != null) { Action.Do(t1, t2, t3, t4); } + if (VoidAction != null) { VoidAction.Do(); } + } + else + { + if (ElseAction != null) { ElseAction.Do(t1, t2, t3, t4); } + if (ElseVoidAction != null) { ElseVoidAction.Do(); } + } + } + } + + public class ConditionalGameActionHelper where GA : GameAction where C : GameFunction + { + [SerializeField] + private C Condition = null; + [SerializeField] + private GA Action = null; + [SerializeField] + private VoidAction VoidAction = null; + + [SerializeField] + private GA ElseAction = null; + [SerializeField] + private VoidAction ElseVoidAction = null; + + public void Do(T1 t1, T2 t2, T3 t3, T4 t4, T5 t5) + { + if (Condition == null || Condition.Call(t1, t2, t3, t4, t5)) + { + if (Action != null) { Action.Do(t1, t2, t3, t4, t5); } + if (VoidAction != null) { VoidAction.Do(); } + } + else + { + if (ElseAction != null) { ElseAction.Do(t1, t2, t3, t4, t5); } + if (ElseVoidAction != null) { ElseVoidAction.Do(); } + } + } + } +} diff --git a/Assets/UnityAtoms/GameActions/Collider2DGameObjectEventAction.cs.meta b/Source/Base/ConditionalGameActionHelper.cs.meta similarity index 83% rename from Assets/UnityAtoms/GameActions/Collider2DGameObjectEventAction.cs.meta rename to Source/Base/ConditionalGameActionHelper.cs.meta index 4b609a98..ea32c847 100644 --- a/Assets/UnityAtoms/GameActions/Collider2DGameObjectEventAction.cs.meta +++ b/Source/Base/ConditionalGameActionHelper.cs.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 9b3c2d8fb96d74c1aaa60e68c552de82 +guid: d0684d90d32fd43bc8c9ee0cb3ad3b2e MonoImporter: externalObjects: {} serializedVersion: 2 diff --git a/Assets/UnityAtoms/CreateOnAwake.meta b/Source/Base/CreateOnAwake.meta similarity index 77% rename from Assets/UnityAtoms/CreateOnAwake.meta rename to Source/Base/CreateOnAwake.meta index 7780b939..faf00828 100644 --- a/Assets/UnityAtoms/CreateOnAwake.meta +++ b/Source/Base/CreateOnAwake.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 055205c364e382049bcbe7b60bdada76 +guid: 9ba1098daa1e349bca3ab3caff9db210 folderAsset: yes DefaultImporter: externalObjects: {} diff --git a/Assets/UnityAtoms/GameEvents/CreateEventOnAwake/CreateEventOnAwake.cs b/Source/Base/CreateOnAwake/CreateEventOnAwake.cs similarity index 95% rename from Assets/UnityAtoms/GameEvents/CreateEventOnAwake/CreateEventOnAwake.cs rename to Source/Base/CreateOnAwake/CreateEventOnAwake.cs index ca338f9c..909a9e5f 100644 --- a/Assets/UnityAtoms/GameEvents/CreateEventOnAwake/CreateEventOnAwake.cs +++ b/Source/Base/CreateOnAwake/CreateEventOnAwake.cs @@ -15,8 +15,8 @@ namespace UnityAtoms public bool CreateEventWithGameObject = false; public List MonoHooks; - public L1 Listener; - public L2 ListenerWithGameObject; + public L1 Listener = null; + public L2 ListenerWithGameObject = null; void Awake() { @@ -49,4 +49,4 @@ namespace UnityAtoms } } } -} \ No newline at end of file +} diff --git a/Assets/UnityAtoms/GameEvents/CreateEventOnAwake/CreateEventOnAwake.cs.meta b/Source/Base/CreateOnAwake/CreateEventOnAwake.cs.meta similarity index 83% rename from Assets/UnityAtoms/GameEvents/CreateEventOnAwake/CreateEventOnAwake.cs.meta rename to Source/Base/CreateOnAwake/CreateEventOnAwake.cs.meta index 510a4f30..6353dfde 100644 --- a/Assets/UnityAtoms/GameEvents/CreateEventOnAwake/CreateEventOnAwake.cs.meta +++ b/Source/Base/CreateOnAwake/CreateEventOnAwake.cs.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 58caff4cec6bc4978863fcc5b9f857e4 +guid: 91a10c8e706c64681971121dd35a11ab MonoImporter: externalObjects: {} serializedVersion: 2 diff --git a/Assets/UnityAtoms/CreateOnAwake/CreateListOnAwake/CreateListOnAwake.cs b/Source/Base/CreateOnAwake/CreateListOnAwake.cs similarity index 89% rename from Assets/UnityAtoms/CreateOnAwake/CreateListOnAwake/CreateListOnAwake.cs rename to Source/Base/CreateOnAwake/CreateListOnAwake.cs index c39bd330..81f44ab5 100644 --- a/Assets/UnityAtoms/CreateOnAwake/CreateListOnAwake/CreateListOnAwake.cs +++ b/Source/Base/CreateOnAwake/CreateListOnAwake.cs @@ -21,16 +21,16 @@ namespace UnityAtoms private bool CreateClearedEvent = false; [SerializeField] - private TEL AddedListener; + private TEL AddedListener = null; [SerializeField] - private TEL RemovedListener; + private TEL RemovedListener = null; [SerializeField] - private VoidListener ClearedListener; + private VoidListener ClearedListener = null; [SerializeField] - private GA1 OnListCreate; + private GA1 OnListCreate = null; [SerializeField] - private GA2 OnListCreateWithGO; + private GA2 OnListCreateWithGO = null; void Awake() { @@ -65,4 +65,4 @@ namespace UnityAtoms if (OnListCreateWithGO != null) { OnListCreateWithGO.Do(list, gameObject); } } } -} \ No newline at end of file +} diff --git a/Assets/UnityAtoms/CreateOnAwake/CreateListOnAwake/CreateListOnAwake.cs.meta b/Source/Base/CreateOnAwake/CreateListOnAwake.cs.meta similarity index 83% rename from Assets/UnityAtoms/CreateOnAwake/CreateListOnAwake/CreateListOnAwake.cs.meta rename to Source/Base/CreateOnAwake/CreateListOnAwake.cs.meta index ed41efbf..3d4612ed 100644 --- a/Assets/UnityAtoms/CreateOnAwake/CreateListOnAwake/CreateListOnAwake.cs.meta +++ b/Source/Base/CreateOnAwake/CreateListOnAwake.cs.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 8221d8181949e42a39b92731d7ad8025 +guid: fe6b3aa24d97c499db1d8af50cdf5c80 MonoImporter: externalObjects: {} serializedVersion: 2 diff --git a/Assets/UnityAtoms/CreateOnAwake/CreateVariableOnAwake/CreateVariableOnAwake.cs b/Source/Base/CreateOnAwake/CreateVariableOnAwake.cs similarity index 84% rename from Assets/UnityAtoms/CreateOnAwake/CreateVariableOnAwake/CreateVariableOnAwake.cs rename to Source/Base/CreateOnAwake/CreateVariableOnAwake.cs index b0824c9b..22a2cc05 100644 --- a/Assets/UnityAtoms/CreateOnAwake/CreateVariableOnAwake/CreateVariableOnAwake.cs +++ b/Source/Base/CreateOnAwake/CreateVariableOnAwake.cs @@ -2,6 +2,7 @@ using System.Collections.Generic; using UnityEngine; using UnityEngine.Events; +using UnityAtoms.Utils; namespace UnityAtoms { @@ -18,18 +19,18 @@ namespace UnityAtoms private bool CreateChangedWithHistoryEvent = false; [SerializeField] - private L1 Listener; + private L1 Listener = null; [SerializeField] - private L2 ListenerWithHistory; + private L2 ListenerWithHistory = null; [SerializeField] - private GA3 OnVariableCreate; + private GA3 OnVariableCreate = null; [SerializeField] - private GA4 OnVariableCreateWithGO; + private GA4 OnVariableCreateWithGO = null; void Awake() { - var variable = VariableUtils.CreateVariable(CreateChangedEvent, CreateChangedWithHistoryEvent); + var variable = DynamicAtoms.CreateVariable(CreateChangedEvent, CreateChangedWithHistoryEvent); if (variable.Changed != null) { @@ -51,4 +52,4 @@ namespace UnityAtoms if (OnVariableCreateWithGO != null) { OnVariableCreateWithGO.Do(variable, gameObject); } } } -} \ No newline at end of file +} diff --git a/Assets/UnityAtoms/CreateOnAwake/CreateVariableOnAwake/CreateVariableOnAwake.cs.meta b/Source/Base/CreateOnAwake/CreateVariableOnAwake.cs.meta similarity index 83% rename from Assets/UnityAtoms/CreateOnAwake/CreateVariableOnAwake/CreateVariableOnAwake.cs.meta rename to Source/Base/CreateOnAwake/CreateVariableOnAwake.cs.meta index 5692f759..299ac7f4 100644 --- a/Assets/UnityAtoms/CreateOnAwake/CreateVariableOnAwake/CreateVariableOnAwake.cs.meta +++ b/Source/Base/CreateOnAwake/CreateVariableOnAwake.cs.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 9409dd866fe734c02aeb4bd09615b418 +guid: f3031e0f8e0434570aacbb29265f0ad8 MonoImporter: externalObjects: {} serializedVersion: 2 diff --git a/Assets/UnityAtoms/GameEvents/GameEvent.cs b/Source/Base/GameEvent.cs similarity index 97% rename from Assets/UnityAtoms/GameEvents/GameEvent.cs rename to Source/Base/GameEvent.cs index c42ee85d..7b4db30a 100644 --- a/Assets/UnityAtoms/GameEvents/GameEvent.cs +++ b/Source/Base/GameEvent.cs @@ -4,7 +4,6 @@ using UnityEngine; namespace UnityAtoms { - [Serializable] public abstract class GameEvent : ScriptableObject, IGameEvent { private readonly List> eventListeners = new List>(); @@ -28,7 +27,6 @@ namespace UnityAtoms } } - [Serializable] public abstract class GameEvent : ScriptableObject, IGameEvent { private readonly List> eventListeners = new List>(); @@ -51,4 +49,4 @@ namespace UnityAtoms eventListeners.Remove(listener); } } -} \ No newline at end of file +} diff --git a/Assets/UnityAtoms/GameEvents/GameEvent.cs.meta b/Source/Base/GameEvent.cs.meta similarity index 83% rename from Assets/UnityAtoms/GameEvents/GameEvent.cs.meta rename to Source/Base/GameEvent.cs.meta index cc704bc9..d2826bad 100644 --- a/Assets/UnityAtoms/GameEvents/GameEvent.cs.meta +++ b/Source/Base/GameEvent.cs.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: f64ad222c1e1b42f2bac1aff9fc2c23a +guid: 190ded37f2e6348eeb660a9ce19704a9 MonoImporter: externalObjects: {} serializedVersion: 2 diff --git a/Assets/UnityAtoms/GameEventListeners/GameEventListener.cs b/Source/Base/GameEventListener.cs similarity index 92% rename from Assets/UnityAtoms/GameEventListeners/GameEventListener.cs rename to Source/Base/GameEventListener.cs index dc933159..6d5195ff 100644 --- a/Assets/UnityAtoms/GameEventListeners/GameEventListener.cs +++ b/Source/Base/GameEventListener.cs @@ -7,12 +7,12 @@ namespace UnityAtoms public abstract class GameEventListener : MonoBehaviour, IGameEventListener where GA : GameAction where E : GameEvent where UER : UnityEvent { [SerializeField] - private E Event; + private E Event = null; public E GameEvent { get { return Event; } set { Event = value; } } [SerializeField] - private UER UnityEventResponse; + private UER UnityEventResponse = null; [SerializeField] private List GameActionResponses = new List(); @@ -41,12 +41,12 @@ namespace UnityAtoms public abstract class GameEventListener : MonoBehaviour, IGameEventListener where GA : GameAction where E : GameEvent where UER : UnityEvent { [SerializeField] - private E Event; + private E Event = null; public E GameEvent { get { return Event; } set { Event = value; } } [SerializeField] - private UER UnityEventResponse; + private UER UnityEventResponse = null; [SerializeField] private List GameActionResponses = new List(); @@ -72,4 +72,4 @@ namespace UnityAtoms } } } -} \ No newline at end of file +} diff --git a/Assets/UnityAtoms/GameEventListeners/GameEventListener.cs.meta b/Source/Base/GameEventListener.cs.meta similarity index 83% rename from Assets/UnityAtoms/GameEventListeners/GameEventListener.cs.meta rename to Source/Base/GameEventListener.cs.meta index 1aa7f631..7e783b01 100644 --- a/Assets/UnityAtoms/GameEventListeners/GameEventListener.cs.meta +++ b/Source/Base/GameEventListener.cs.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 000f07bf50da14864b79d6283216c146 +guid: 692bce22c22984a83966ed4ae5332340 MonoImporter: externalObjects: {} serializedVersion: 2 diff --git a/Assets/UnityAtoms/GameEvents/IGameEvent.cs b/Source/Base/IGameEvent.cs similarity index 69% rename from Assets/UnityAtoms/GameEvents/IGameEvent.cs rename to Source/Base/IGameEvent.cs index 63e5cea1..1a812974 100644 --- a/Assets/UnityAtoms/GameEvents/IGameEvent.cs +++ b/Source/Base/IGameEvent.cs @@ -11,5 +11,7 @@ namespace UnityAtoms public interface IGameEvent { void Raise(T1 newItem, T2 oldItem); + void RegisterListener(IGameEventListener listener); + void UnregisterListener(IGameEventListener listener); } -} \ No newline at end of file +} diff --git a/Assets/UnityAtoms/GameEvents/IGameEvent.cs.meta b/Source/Base/IGameEvent.cs.meta similarity index 83% rename from Assets/UnityAtoms/GameEvents/IGameEvent.cs.meta rename to Source/Base/IGameEvent.cs.meta index 3a838754..b087a43e 100644 --- a/Assets/UnityAtoms/GameEvents/IGameEvent.cs.meta +++ b/Source/Base/IGameEvent.cs.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 0a9aba6294e804634bb6530ddc71f5a3 +guid: 312891f88a60e4f43ac11385b45afbe1 MonoImporter: externalObjects: {} serializedVersion: 2 diff --git a/Assets/UnityAtoms/GameEventListeners/IGameEventListener.cs b/Source/Base/IGameEventListener.cs similarity index 100% rename from Assets/UnityAtoms/GameEventListeners/IGameEventListener.cs rename to Source/Base/IGameEventListener.cs diff --git a/Assets/UnityAtoms/GameEventListeners/IGameEventListener.cs.meta b/Source/Base/IGameEventListener.cs.meta similarity index 83% rename from Assets/UnityAtoms/GameEventListeners/IGameEventListener.cs.meta rename to Source/Base/IGameEventListener.cs.meta index 0dfe9ca8..ab91a326 100644 --- a/Assets/UnityAtoms/GameEventListeners/IGameEventListener.cs.meta +++ b/Source/Base/IGameEventListener.cs.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: ea2dd93fc28a54471be8efc91f5cd111 +guid: 4c55e35a7a69848bc95f9c296a808cc6 MonoImporter: externalObjects: {} serializedVersion: 2 diff --git a/Assets/UnityAtoms/GameActions/ScriptableObjectGameAction.cs b/Source/Base/ScriptableObjectGameAction.cs similarity index 88% rename from Assets/UnityAtoms/GameActions/ScriptableObjectGameAction.cs rename to Source/Base/ScriptableObjectGameAction.cs index 6643fcf2..6b0182fa 100644 --- a/Assets/UnityAtoms/GameActions/ScriptableObjectGameAction.cs +++ b/Source/Base/ScriptableObjectGameAction.cs @@ -4,11 +4,6 @@ using UnityEngine; namespace UnityAtoms { - public abstract class GameAction : ScriptableObject - { - public abstract void Do(); - } - public abstract class GameAction : ScriptableObject { public abstract void Do(T1 t1); diff --git a/Assets/UnityAtoms/GameActions/ScriptableObjectGameAction.cs.meta b/Source/Base/ScriptableObjectGameAction.cs.meta similarity index 83% rename from Assets/UnityAtoms/GameActions/ScriptableObjectGameAction.cs.meta rename to Source/Base/ScriptableObjectGameAction.cs.meta index fdf5b244..7c55558a 100644 --- a/Assets/UnityAtoms/GameActions/ScriptableObjectGameAction.cs.meta +++ b/Source/Base/ScriptableObjectGameAction.cs.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 36ac910c3225e4df095bd8b94a9ea5b7 +guid: d07e5a9e49aea43f4818809f4048d7b5 MonoImporter: externalObjects: {} serializedVersion: 2 diff --git a/Assets/UnityAtoms/Lists/ScriptableObjectList.cs b/Source/Base/ScriptableObjectList.cs similarity index 98% rename from Assets/UnityAtoms/Lists/ScriptableObjectList.cs rename to Source/Base/ScriptableObjectList.cs index 215d99a0..34080e82 100644 --- a/Assets/UnityAtoms/Lists/ScriptableObjectList.cs +++ b/Source/Base/ScriptableObjectList.cs @@ -4,7 +4,6 @@ using UnityEngine; namespace UnityAtoms { - [Serializable] public abstract class ScriptableObjectList : ScriptableObject where E : GameEvent { [SerializeField] @@ -77,4 +76,4 @@ namespace UnityAtoms } } -} \ No newline at end of file +} diff --git a/Assets/UnityAtoms/Lists/ScriptableObjectList.cs.meta b/Source/Base/ScriptableObjectList.cs.meta similarity index 83% rename from Assets/UnityAtoms/Lists/ScriptableObjectList.cs.meta rename to Source/Base/ScriptableObjectList.cs.meta index b5b0d309..8b303774 100644 --- a/Assets/UnityAtoms/Lists/ScriptableObjectList.cs.meta +++ b/Source/Base/ScriptableObjectList.cs.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 06c96d546fe9646a49736bdd95f9d490 +guid: ea34cef4340fc48fc9efe5bafc4bb584 MonoImporter: externalObjects: {} serializedVersion: 2 diff --git a/Assets/UnityAtoms/References/ScriptableObjectReference.cs b/Source/Base/ScriptableObjectReference.cs similarity index 100% rename from Assets/UnityAtoms/References/ScriptableObjectReference.cs rename to Source/Base/ScriptableObjectReference.cs diff --git a/Assets/UnityAtoms/References/ScriptableObjectReference.cs.meta b/Source/Base/ScriptableObjectReference.cs.meta similarity index 83% rename from Assets/UnityAtoms/References/ScriptableObjectReference.cs.meta rename to Source/Base/ScriptableObjectReference.cs.meta index 29878467..ab948a19 100644 --- a/Assets/UnityAtoms/References/ScriptableObjectReference.cs.meta +++ b/Source/Base/ScriptableObjectReference.cs.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 5342bfaa58e6d41c5a71411325aebbf8 +guid: 514b1f222587d48958ff910268e92f23 MonoImporter: externalObjects: {} serializedVersion: 2 diff --git a/Assets/UnityAtoms/GameActions/SetVariableValue/SetVariableValue.cs b/Source/Base/SetVariableValue.cs similarity index 85% rename from Assets/UnityAtoms/GameActions/SetVariableValue/SetVariableValue.cs rename to Source/Base/SetVariableValue.cs index 8b2bcc49..3ba04c1d 100644 --- a/Assets/UnityAtoms/GameActions/SetVariableValue/SetVariableValue.cs +++ b/Source/Base/SetVariableValue.cs @@ -5,14 +5,14 @@ namespace UnityAtoms public abstract class SetVariableValue : VoidAction where E1 : GameEvent where E2 : GameEvent where V : ScriptableObjectVariable where R : ScriptableObjectReference { [SerializeField] - private V Variable; + private V Variable = null; [SerializeField] - private R Value; + private R Value = null; public override void Do() { Variable.Value = Value.Value; } } -} \ No newline at end of file +} diff --git a/Assets/UnityAtoms/GameActions/SetVariableValue/SetVariableValue.cs.meta b/Source/Base/SetVariableValue.cs.meta similarity index 83% rename from Assets/UnityAtoms/GameActions/SetVariableValue/SetVariableValue.cs.meta rename to Source/Base/SetVariableValue.cs.meta index 2d8f1709..5c19beef 100644 --- a/Assets/UnityAtoms/GameActions/SetVariableValue/SetVariableValue.cs.meta +++ b/Source/Base/SetVariableValue.cs.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 8ca3cfc9cbb4b4a50ac810892cde9d5b +guid: d49d42bd51fa5493e8f950fc5fde2a81 MonoImporter: externalObjects: {} serializedVersion: 2 diff --git a/Source/Base/Variable.meta b/Source/Base/Variable.meta new file mode 100644 index 00000000..2f1b6a6c --- /dev/null +++ b/Source/Base/Variable.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 75c46bcba8d6d43c082c06154e865008 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/UnityAtoms/Variables/EquatableScriptableObjectVariable.cs b/Source/Base/Variable/EquatableScriptableObjectVariable.cs similarity index 81% rename from Assets/UnityAtoms/Variables/EquatableScriptableObjectVariable.cs rename to Source/Base/Variable/EquatableScriptableObjectVariable.cs index fa9280f6..ff10257e 100644 --- a/Assets/UnityAtoms/Variables/EquatableScriptableObjectVariable.cs +++ b/Source/Base/Variable/EquatableScriptableObjectVariable.cs @@ -8,7 +8,7 @@ namespace UnityAtoms { protected override bool AreEqual(T t1, T t2) { - return t1.Equals(t2); + return (t1 == null && t2 == null) || (t1 != null && t1.Equals(t2)); } } } \ No newline at end of file diff --git a/Assets/UnityAtoms/Variables/EquatableScriptableObjectVariable.cs.meta b/Source/Base/Variable/EquatableScriptableObjectVariable.cs.meta similarity index 83% rename from Assets/UnityAtoms/Variables/EquatableScriptableObjectVariable.cs.meta rename to Source/Base/Variable/EquatableScriptableObjectVariable.cs.meta index a30c2f4d..f7b2baa9 100644 --- a/Assets/UnityAtoms/Variables/EquatableScriptableObjectVariable.cs.meta +++ b/Source/Base/Variable/EquatableScriptableObjectVariable.cs.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: cee8340e97d5e4cd3b070d91cf0f2547 +guid: 71539ffefa66f4ad0a7f2f18a23f075f MonoImporter: externalObjects: {} serializedVersion: 2 diff --git a/Assets/UnityAtoms/Variables/IWithApplyChange.cs b/Source/Base/Variable/IWithApplyChange.cs similarity index 100% rename from Assets/UnityAtoms/Variables/IWithApplyChange.cs rename to Source/Base/Variable/IWithApplyChange.cs diff --git a/Assets/UnityAtoms/Variables/IWithApplyChange.cs.meta b/Source/Base/Variable/IWithApplyChange.cs.meta similarity index 83% rename from Assets/UnityAtoms/Variables/IWithApplyChange.cs.meta rename to Source/Base/Variable/IWithApplyChange.cs.meta index 2a4fec02..c27aad42 100644 --- a/Assets/UnityAtoms/Variables/IWithApplyChange.cs.meta +++ b/Source/Base/Variable/IWithApplyChange.cs.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 6abd8d4cfa6d145149c1b44ae0be4fd6 +guid: 70654bdb562214eca9cecc4121d7bb42 MonoImporter: externalObjects: {} serializedVersion: 2 diff --git a/Assets/UnityAtoms/Variables/IWithOldValue.cs b/Source/Base/Variable/IWithOldValue.cs similarity index 100% rename from Assets/UnityAtoms/Variables/IWithOldValue.cs rename to Source/Base/Variable/IWithOldValue.cs diff --git a/Assets/UnityAtoms/Variables/IWithOldValue.cs.meta b/Source/Base/Variable/IWithOldValue.cs.meta similarity index 83% rename from Assets/UnityAtoms/Variables/IWithOldValue.cs.meta rename to Source/Base/Variable/IWithOldValue.cs.meta index 254c0d37..91b7bcaa 100644 --- a/Assets/UnityAtoms/Variables/IWithOldValue.cs.meta +++ b/Source/Base/Variable/IWithOldValue.cs.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: e17976967053642e8af57067fce38eb9 +guid: fff14b939e7774b2eafee84035d526dd MonoImporter: externalObjects: {} serializedVersion: 2 diff --git a/Assets/UnityAtoms/Variables/IWithValue.cs b/Source/Base/Variable/IWithValue.cs similarity index 100% rename from Assets/UnityAtoms/Variables/IWithValue.cs rename to Source/Base/Variable/IWithValue.cs diff --git a/Assets/UnityAtoms/Variables/IWithValue.cs.meta b/Source/Base/Variable/IWithValue.cs.meta similarity index 83% rename from Assets/UnityAtoms/Variables/IWithValue.cs.meta rename to Source/Base/Variable/IWithValue.cs.meta index b5a475f5..eb840677 100644 --- a/Assets/UnityAtoms/Variables/IWithValue.cs.meta +++ b/Source/Base/Variable/IWithValue.cs.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 955e787ba05bc434bae2c6fc2ddb4a57 +guid: 4cb59e06d6d324a25aac6e133b51d615 MonoImporter: externalObjects: {} serializedVersion: 2 diff --git a/Assets/UnityAtoms/Variables/ScriptableObjectVariable.cs b/Source/Base/Variable/ScriptableObjectVariable.cs similarity index 89% rename from Assets/UnityAtoms/Variables/ScriptableObjectVariable.cs rename to Source/Base/Variable/ScriptableObjectVariable.cs index 10bfa559..9fc1969e 100644 --- a/Assets/UnityAtoms/Variables/ScriptableObjectVariable.cs +++ b/Source/Base/Variable/ScriptableObjectVariable.cs @@ -18,6 +18,12 @@ namespace UnityAtoms protected abstract bool AreEqual(T first, T second); + private void OnEnable() + { + if (Changed == null) return; + Changed.Raise(Value); + } + public bool SetValue(T value) { if (!AreEqual(this.value, value)) diff --git a/Assets/UnityAtoms/Variables/ScriptableObjectVariable.cs.meta b/Source/Base/Variable/ScriptableObjectVariable.cs.meta similarity index 83% rename from Assets/UnityAtoms/Variables/ScriptableObjectVariable.cs.meta rename to Source/Base/Variable/ScriptableObjectVariable.cs.meta index eac5ef74..e12b780d 100644 --- a/Assets/UnityAtoms/Variables/ScriptableObjectVariable.cs.meta +++ b/Source/Base/Variable/ScriptableObjectVariable.cs.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: c0dcb69682ca34157a94786e7dec3a69 +guid: 3fc5ba68d557d480085a98ea7eb4a847 MonoImporter: externalObjects: {} serializedVersion: 2 diff --git a/Source/Base/Variable/ScriptableObjectVariableBase.cs b/Source/Base/Variable/ScriptableObjectVariableBase.cs new file mode 100644 index 00000000..422e4824 --- /dev/null +++ b/Source/Base/Variable/ScriptableObjectVariableBase.cs @@ -0,0 +1,37 @@ +using System; +using System.Collections.Generic; +using UnityEngine; + +namespace UnityAtoms +{ + public abstract class ScriptableObjectVariableBase : ScriptableObject, IWithValue + { + [Multiline] + public string DeveloperDescription = ""; + + public virtual T Value { get { return value; } set { throw new NotImplementedException(); } } + + [SerializeField] + protected T value; + + protected bool Equals(ScriptableObjectVariableBase other) { + return EqualityComparer.Default.Equals(value, other.value); + } + + public override bool Equals(object obj) { + if (ReferenceEquals(null, obj)) return false; + if (ReferenceEquals(this, obj)) return true; + if (obj.GetType() != this.GetType()) return false; + return Equals((ScriptableObjectVariableBase) obj); + } + + public override int GetHashCode() { + unchecked { + return EqualityComparer.Default.GetHashCode(value); + } + } + + public static bool operator ==(ScriptableObjectVariableBase left, ScriptableObjectVariableBase right) { return Equals(left, right); } + public static bool operator !=(ScriptableObjectVariableBase left, ScriptableObjectVariableBase right) { return !Equals(left, right); } + } +} \ No newline at end of file diff --git a/Assets/UnityAtoms/Variables/ScriptableObjectVariableBase.cs.meta b/Source/Base/Variable/ScriptableObjectVariableBase.cs.meta similarity index 83% rename from Assets/UnityAtoms/Variables/ScriptableObjectVariableBase.cs.meta rename to Source/Base/Variable/ScriptableObjectVariableBase.cs.meta index d017af70..8762edb0 100644 --- a/Assets/UnityAtoms/Variables/ScriptableObjectVariableBase.cs.meta +++ b/Source/Base/Variable/ScriptableObjectVariableBase.cs.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: dcf63c23be39143f6a83611fe5491361 +guid: c54f55b3c630e4bf78c7be07fed50fe0 MonoImporter: externalObjects: {} serializedVersion: 2 diff --git a/Source/Bool.meta b/Source/Bool.meta new file mode 100644 index 00000000..7f332805 --- /dev/null +++ b/Source/Bool.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 2b6bbff6db4e347d782f1382624e32ec +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/UnityAtoms/GameActions/BoolAction.cs b/Source/Bool/BoolAction.cs similarity index 100% rename from Assets/UnityAtoms/GameActions/BoolAction.cs rename to Source/Bool/BoolAction.cs diff --git a/Assets/UnityAtoms/GameActions/BoolAction.cs.meta b/Source/Bool/BoolAction.cs.meta similarity index 83% rename from Assets/UnityAtoms/GameActions/BoolAction.cs.meta rename to Source/Bool/BoolAction.cs.meta index a1b8c9b5..f56166f8 100644 --- a/Assets/UnityAtoms/GameActions/BoolAction.cs.meta +++ b/Source/Bool/BoolAction.cs.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: ef57afbf1dd624182b94670d16bc8fc7 +guid: f746897c923ae4ffd9d7c38309605217 MonoImporter: externalObjects: {} serializedVersion: 2 diff --git a/Source/Bool/BoolBoolEvent.cs b/Source/Bool/BoolBoolEvent.cs new file mode 100644 index 00000000..14966231 --- /dev/null +++ b/Source/Bool/BoolBoolEvent.cs @@ -0,0 +1,8 @@ +using UnityEngine; + +namespace UnityAtoms +{ + + [CreateAssetMenu(menuName = "Unity Atoms/Bool/Event x 2", fileName = "BoolBoolEvent", order = CreateAssetMenuUtils.Order.EVENTx2)] + public class BoolBoolEvent : GameEvent { } +} \ No newline at end of file diff --git a/Assets/UnityAtoms/GameEvents/BoolBoolEvent.cs.meta b/Source/Bool/BoolBoolEvent.cs.meta similarity index 83% rename from Assets/UnityAtoms/GameEvents/BoolBoolEvent.cs.meta rename to Source/Bool/BoolBoolEvent.cs.meta index 5dfb3abb..76e8bf97 100644 --- a/Assets/UnityAtoms/GameEvents/BoolBoolEvent.cs.meta +++ b/Source/Bool/BoolBoolEvent.cs.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 10942683d8ff9455aada9fffe9607f38 +guid: 0fb2a8248c41a4b3686508f8d16017f8 MonoImporter: externalObjects: {} serializedVersion: 2 diff --git a/Source/Bool/BoolConstant.cs b/Source/Bool/BoolConstant.cs new file mode 100644 index 00000000..eb2a192e --- /dev/null +++ b/Source/Bool/BoolConstant.cs @@ -0,0 +1,7 @@ +using UnityEngine; + +namespace UnityAtoms +{ + [CreateAssetMenu(menuName = "Unity Atoms/Bool/Constant", fileName = "BoolConstant", order = CreateAssetMenuUtils.Order.CONSTANT)] + public class BoolConstant : ScriptableObjectVariableBase { } +} \ No newline at end of file diff --git a/Assets/UnityAtoms/Constants/BoolConstant.cs.meta b/Source/Bool/BoolConstant.cs.meta similarity index 100% rename from Assets/UnityAtoms/Constants/BoolConstant.cs.meta rename to Source/Bool/BoolConstant.cs.meta diff --git a/Source/Bool/BoolEvent.cs b/Source/Bool/BoolEvent.cs new file mode 100644 index 00000000..7292bd2b --- /dev/null +++ b/Source/Bool/BoolEvent.cs @@ -0,0 +1,8 @@ +using UnityEngine; + +namespace UnityAtoms +{ + + [CreateAssetMenu(menuName = "Unity Atoms/Bool/Event", fileName = "BoolEvent", order = CreateAssetMenuUtils.Order.EVENT)] + public class BoolEvent : GameEvent { } +} \ No newline at end of file diff --git a/Assets/UnityAtoms/GameEvents/BoolEvent.cs.meta b/Source/Bool/BoolEvent.cs.meta similarity index 83% rename from Assets/UnityAtoms/GameEvents/BoolEvent.cs.meta rename to Source/Bool/BoolEvent.cs.meta index 35ad19c9..c084adde 100644 --- a/Assets/UnityAtoms/GameEvents/BoolEvent.cs.meta +++ b/Source/Bool/BoolEvent.cs.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 60a4d62820cb849339f957c2918b6a15 +guid: 1655f7ad1e424459dba2829e66ffa517 MonoImporter: externalObjects: {} serializedVersion: 2 diff --git a/Source/Bool/BoolList.cs b/Source/Bool/BoolList.cs new file mode 100644 index 00000000..9962e843 --- /dev/null +++ b/Source/Bool/BoolList.cs @@ -0,0 +1,7 @@ +using UnityEngine; + +namespace UnityAtoms +{ + [CreateAssetMenu(menuName = "Unity Atoms/Bool/List", fileName = "BoolList", order = CreateAssetMenuUtils.Order.LIST)] + public class BoolList : ScriptableObjectList { } +} \ No newline at end of file diff --git a/Assets/UnityAtoms/Lists/BoolList.cs.meta b/Source/Bool/BoolList.cs.meta similarity index 83% rename from Assets/UnityAtoms/Lists/BoolList.cs.meta rename to Source/Bool/BoolList.cs.meta index f758bb3c..b950cefa 100644 --- a/Assets/UnityAtoms/Lists/BoolList.cs.meta +++ b/Source/Bool/BoolList.cs.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: efc4eddb4e49543ecb92d6a2ead90f85 +guid: 2d0df3debbda749a9b3e28fa608ca565 MonoImporter: externalObjects: {} serializedVersion: 2 diff --git a/Assets/UnityAtoms/GameEventListeners/BoolListener.cs b/Source/Bool/BoolListener.cs similarity index 56% rename from Assets/UnityAtoms/GameEventListeners/BoolListener.cs rename to Source/Bool/BoolListener.cs index ce741929..4936f473 100644 --- a/Assets/UnityAtoms/GameEventListeners/BoolListener.cs +++ b/Source/Bool/BoolListener.cs @@ -1,8 +1,3 @@ -using System; -using System.Collections.Generic; -using UnityEngine.Events; -using UnityEngine; - namespace UnityAtoms { public class BoolListener : GameEventListener { } diff --git a/Assets/UnityAtoms/GameEventListeners/BoolListener.cs.meta b/Source/Bool/BoolListener.cs.meta similarity index 83% rename from Assets/UnityAtoms/GameEventListeners/BoolListener.cs.meta rename to Source/Bool/BoolListener.cs.meta index b361b0da..c10d6417 100644 --- a/Assets/UnityAtoms/GameEventListeners/BoolListener.cs.meta +++ b/Source/Bool/BoolListener.cs.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: dfb9d99d0bd5c4ba3b0a5ae85d126de7 +guid: b599e4a6576e24744a721cc20ce14578 MonoImporter: externalObjects: {} serializedVersion: 2 diff --git a/Assets/UnityAtoms/References/BoolReference.cs b/Source/Bool/BoolReference.cs similarity index 100% rename from Assets/UnityAtoms/References/BoolReference.cs rename to Source/Bool/BoolReference.cs diff --git a/Assets/UnityAtoms/References/BoolReference.cs.meta b/Source/Bool/BoolReference.cs.meta similarity index 83% rename from Assets/UnityAtoms/References/BoolReference.cs.meta rename to Source/Bool/BoolReference.cs.meta index 99cf610f..31f97efc 100644 --- a/Assets/UnityAtoms/References/BoolReference.cs.meta +++ b/Source/Bool/BoolReference.cs.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 154a9bd5071ae4540908e266ca9bc43b +guid: 59b4e869ea3474424a6ba7c99af65b45 MonoImporter: externalObjects: {} serializedVersion: 2 diff --git a/Source/Bool/BoolVariable.cs b/Source/Bool/BoolVariable.cs new file mode 100644 index 00000000..1a004928 --- /dev/null +++ b/Source/Bool/BoolVariable.cs @@ -0,0 +1,7 @@ +using UnityEngine; + +namespace UnityAtoms +{ + [CreateAssetMenu(menuName = "Unity Atoms/Bool/Variable", fileName = "BoolVariable", order = CreateAssetMenuUtils.Order.VARIABLE)] + public class BoolVariable : EquatableScriptableObjectVariable { } +} \ No newline at end of file diff --git a/Assets/UnityAtoms/Variables/BoolVariable.cs.meta b/Source/Bool/BoolVariable.cs.meta similarity index 83% rename from Assets/UnityAtoms/Variables/BoolVariable.cs.meta rename to Source/Bool/BoolVariable.cs.meta index d58f6d1f..5c6b078a 100644 --- a/Assets/UnityAtoms/Variables/BoolVariable.cs.meta +++ b/Source/Bool/BoolVariable.cs.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 34cff86f50dad4ad680ac0d15bf7292c +guid: 320ccd2dc511d4d1b9d768f703fd3bb8 MonoImporter: externalObjects: {} serializedVersion: 2 diff --git a/Source/Bool/ConditionalBoolAction.cs b/Source/Bool/ConditionalBoolAction.cs new file mode 100644 index 00000000..2f7768e6 --- /dev/null +++ b/Source/Bool/ConditionalBoolAction.cs @@ -0,0 +1,20 @@ +using System; +using UnityEngine; + +namespace UnityAtoms +{ + [Serializable] + public class ConditionalBoolGameActionHelper : ConditionalGameActionHelper { } + + [CreateAssetMenu(menuName = "Unity Atoms/Bool/Conditional", fileName = "ConditionalBoolAction", order = CreateAssetMenuUtils.Order.CONDITIONAL)] + public class ConditionalBoolAction : BoolAction + { + [SerializeField] + private ConditionalBoolGameActionHelper Conditional = null; + + public override void Do(bool t1) + { + Conditional.Do(t1); + } + } +} diff --git a/Assets/UnityAtoms/GameEvents/GameObjectCollider2DEvent.cs.meta b/Source/Bool/ConditionalBoolAction.cs.meta similarity index 83% rename from Assets/UnityAtoms/GameEvents/GameObjectCollider2DEvent.cs.meta rename to Source/Bool/ConditionalBoolAction.cs.meta index 9b16b69b..e463486c 100644 --- a/Assets/UnityAtoms/GameEvents/GameObjectCollider2DEvent.cs.meta +++ b/Source/Bool/ConditionalBoolAction.cs.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 2a4bc72b9ab9d4e729490e511be0ea82 +guid: f5f5dd758661f46c8884e50a7721ed95 MonoImporter: externalObjects: {} serializedVersion: 2 diff --git a/Source/Bool/SetBoolVariableValue.cs b/Source/Bool/SetBoolVariableValue.cs new file mode 100644 index 00000000..15e73c36 --- /dev/null +++ b/Source/Bool/SetBoolVariableValue.cs @@ -0,0 +1,7 @@ +using UnityEngine; + +namespace UnityAtoms +{ + [CreateAssetMenu(menuName = "Unity Atoms/Bool/Set Variable", fileName = "SetBoolVariableValueAction", order = CreateAssetMenuUtils.Order.SET_VARIABLE)] + public class SetBoolVariableValue : SetVariableValue { } +} \ No newline at end of file diff --git a/Assets/UnityAtoms/GameActions/SetVariableValue/SetBoolVariableValue.cs.meta b/Source/Bool/SetBoolVariableValue.cs.meta similarity index 83% rename from Assets/UnityAtoms/GameActions/SetVariableValue/SetBoolVariableValue.cs.meta rename to Source/Bool/SetBoolVariableValue.cs.meta index 854634c3..5448a382 100644 --- a/Assets/UnityAtoms/GameActions/SetVariableValue/SetBoolVariableValue.cs.meta +++ b/Source/Bool/SetBoolVariableValue.cs.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 53e0bc832129f428f9ab1436e9ce5ea9 +guid: 51b1e6f2d3fa14f2ea62f8eabfe21817 MonoImporter: externalObjects: {} serializedVersion: 2 diff --git a/Source/Bool/UnityBoolEvent.cs b/Source/Bool/UnityBoolEvent.cs new file mode 100644 index 00000000..54e2b586 --- /dev/null +++ b/Source/Bool/UnityBoolEvent.cs @@ -0,0 +1,8 @@ +using System; +using UnityEngine.Events; + +namespace UnityAtoms +{ + [Serializable] + public class UnityBoolEvent : UnityEvent { } +} \ No newline at end of file diff --git a/Assets/UnityAtoms/UnityEvents/UnityEvents.cs.meta b/Source/Bool/UnityBoolEvent.cs.meta similarity index 83% rename from Assets/UnityAtoms/UnityEvents/UnityEvents.cs.meta rename to Source/Bool/UnityBoolEvent.cs.meta index a63d1201..c48152ac 100644 --- a/Assets/UnityAtoms/UnityEvents/UnityEvents.cs.meta +++ b/Source/Bool/UnityBoolEvent.cs.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 4c7c89c3445404aadb61c2d318d28d5f +guid: cc832ac33e7ac451994b5cfae64e7623 MonoImporter: externalObjects: {} serializedVersion: 2 diff --git a/Source/Collider.meta b/Source/Collider.meta new file mode 100644 index 00000000..2ae2cf05 --- /dev/null +++ b/Source/Collider.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 277cfcedf1cf442b6993c43ec19f9547 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Source/Collider/ColliderEvent.cs b/Source/Collider/ColliderEvent.cs new file mode 100644 index 00000000..1220c04e --- /dev/null +++ b/Source/Collider/ColliderEvent.cs @@ -0,0 +1,7 @@ +using UnityEngine; + +namespace UnityAtoms +{ + [CreateAssetMenu(menuName = "Unity Atoms/Collider/Event", fileName = "ColliderEvent", order = CreateAssetMenuUtils.Order.EVENT)] + public class ColliderEvent : GameEvent { } +} \ No newline at end of file diff --git a/Source/Collider/ColliderEvent.cs.meta b/Source/Collider/ColliderEvent.cs.meta new file mode 100644 index 00000000..8edef138 --- /dev/null +++ b/Source/Collider/ColliderEvent.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 9a0a99be4f0e5466e85ab5428c8b4c22 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Source/Collider/ColliderGameObjectAction.cs b/Source/Collider/ColliderGameObjectAction.cs new file mode 100644 index 00000000..75ac63a6 --- /dev/null +++ b/Source/Collider/ColliderGameObjectAction.cs @@ -0,0 +1,6 @@ +using UnityEngine; + +namespace UnityAtoms +{ + public abstract class ColliderGameObjectAction : GameAction { } +} \ No newline at end of file diff --git a/Source/Collider/ColliderGameObjectAction.cs.meta b/Source/Collider/ColliderGameObjectAction.cs.meta new file mode 100644 index 00000000..5e29bab4 --- /dev/null +++ b/Source/Collider/ColliderGameObjectAction.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: b93e5af67c0004a378b9efbea3b2cae2 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Source/Collider/ColliderGameObjectEvent.cs b/Source/Collider/ColliderGameObjectEvent.cs new file mode 100644 index 00000000..29a6abc2 --- /dev/null +++ b/Source/Collider/ColliderGameObjectEvent.cs @@ -0,0 +1,8 @@ +using UnityEngine; + +namespace UnityAtoms +{ + + [CreateAssetMenu(menuName = "Unity Atoms/Collider/Event with GameObject", fileName = "ColliderGameObjectEvent", order = CreateAssetMenuUtils.Order.EVENT_WITH_GO)] + public class ColliderGameObjectEvent : GameEvent { } +} \ No newline at end of file diff --git a/Source/Collider/ColliderGameObjectEvent.cs.meta b/Source/Collider/ColliderGameObjectEvent.cs.meta new file mode 100644 index 00000000..b2e2c9e6 --- /dev/null +++ b/Source/Collider/ColliderGameObjectEvent.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 97acb23837b164301851f57d79bc7731 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Source/Collider/ColliderGameObjectListener.cs b/Source/Collider/ColliderGameObjectListener.cs new file mode 100644 index 00000000..d90880ef --- /dev/null +++ b/Source/Collider/ColliderGameObjectListener.cs @@ -0,0 +1,6 @@ +using UnityEngine; + +namespace UnityAtoms +{ + public class ColliderGameObjectListener : GameEventListener { } +} diff --git a/Source/Collider/ColliderGameObjectListener.cs.meta b/Source/Collider/ColliderGameObjectListener.cs.meta new file mode 100644 index 00000000..ca5fba2e --- /dev/null +++ b/Source/Collider/ColliderGameObjectListener.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 777a7f3042ff1464d939cac8b14987bb +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Source/Collider/UnityColliderGameObjectEvent.cs b/Source/Collider/UnityColliderGameObjectEvent.cs new file mode 100644 index 00000000..62243eb8 --- /dev/null +++ b/Source/Collider/UnityColliderGameObjectEvent.cs @@ -0,0 +1,9 @@ +using System; +using UnityEngine.Events; +using UnityEngine; + +namespace UnityAtoms +{ + [Serializable] + public class UnityColliderGameObjectEvent : UnityEvent { } +} \ No newline at end of file diff --git a/Source/Collider/UnityColliderGameObjectEvent.cs.meta b/Source/Collider/UnityColliderGameObjectEvent.cs.meta new file mode 100644 index 00000000..4ba3481b --- /dev/null +++ b/Source/Collider/UnityColliderGameObjectEvent.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 228a51df221d041fb8c3075c0a7c6ff5 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Source/Collider2D.meta b/Source/Collider2D.meta new file mode 100644 index 00000000..2f453c0e --- /dev/null +++ b/Source/Collider2D.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: fd99b36e3a2ce4d2987ff142cb44a500 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/UnityAtoms/GameActions/Collider2DAction.cs b/Source/Collider2D/Collider2DAction.cs similarity index 100% rename from Assets/UnityAtoms/GameActions/Collider2DAction.cs rename to Source/Collider2D/Collider2DAction.cs diff --git a/Assets/UnityAtoms/GameActions/Collider2DAction.cs.meta b/Source/Collider2D/Collider2DAction.cs.meta similarity index 83% rename from Assets/UnityAtoms/GameActions/Collider2DAction.cs.meta rename to Source/Collider2D/Collider2DAction.cs.meta index 9b3ae034..a947b92b 100644 --- a/Assets/UnityAtoms/GameActions/Collider2DAction.cs.meta +++ b/Source/Collider2D/Collider2DAction.cs.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 8f1fb8cb50d164aea9d6925ddffdd487 +guid: 03b6dd870d17c400c8c162cd3b49ab35 MonoImporter: externalObjects: {} serializedVersion: 2 diff --git a/Source/Collider2D/Collider2DEvent.cs b/Source/Collider2D/Collider2DEvent.cs new file mode 100644 index 00000000..13c91f3b --- /dev/null +++ b/Source/Collider2D/Collider2DEvent.cs @@ -0,0 +1,7 @@ +using UnityEngine; + +namespace UnityAtoms +{ + [CreateAssetMenu(menuName = "Unity Atoms/Collider2D/Event", fileName = "Collider2DEvent", order = CreateAssetMenuUtils.Order.EVENT)] + public class Collider2DEvent : GameEvent { } +} \ No newline at end of file diff --git a/Assets/UnityAtoms/GameEvents/Collider2DEvent.cs.meta b/Source/Collider2D/Collider2DEvent.cs.meta similarity index 83% rename from Assets/UnityAtoms/GameEvents/Collider2DEvent.cs.meta rename to Source/Collider2D/Collider2DEvent.cs.meta index 4c093c26..0a595907 100644 --- a/Assets/UnityAtoms/GameEvents/Collider2DEvent.cs.meta +++ b/Source/Collider2D/Collider2DEvent.cs.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: aea4b076fcc20470fbbe626354b90f5f +guid: ece6d17834c7b4bbfa9fd56ab4864a6d MonoImporter: externalObjects: {} serializedVersion: 2 diff --git a/Assets/UnityAtoms/GameActions/Collider2DEventAction.cs b/Source/Collider2D/Collider2DEventAction.cs similarity index 100% rename from Assets/UnityAtoms/GameActions/Collider2DEventAction.cs rename to Source/Collider2D/Collider2DEventAction.cs diff --git a/Assets/UnityAtoms/GameActions/Collider2DEventAction.cs.meta b/Source/Collider2D/Collider2DEventAction.cs.meta similarity index 83% rename from Assets/UnityAtoms/GameActions/Collider2DEventAction.cs.meta rename to Source/Collider2D/Collider2DEventAction.cs.meta index 074cbb0e..eaa5733b 100644 --- a/Assets/UnityAtoms/GameActions/Collider2DEventAction.cs.meta +++ b/Source/Collider2D/Collider2DEventAction.cs.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 1d4b42e2c0b244137ad88785678382ad +guid: d36b9a0a7bf994dc894c1d1b6e8c6546 MonoImporter: externalObjects: {} serializedVersion: 2 diff --git a/Assets/UnityAtoms/GameActions/Collider2DGameObjectAction.cs b/Source/Collider2D/Collider2DGameObjectAction.cs similarity index 100% rename from Assets/UnityAtoms/GameActions/Collider2DGameObjectAction.cs rename to Source/Collider2D/Collider2DGameObjectAction.cs diff --git a/Assets/UnityAtoms/GameActions/Collider2DGameObjectAction.cs.meta b/Source/Collider2D/Collider2DGameObjectAction.cs.meta similarity index 83% rename from Assets/UnityAtoms/GameActions/Collider2DGameObjectAction.cs.meta rename to Source/Collider2D/Collider2DGameObjectAction.cs.meta index 0cf2b71b..6445c869 100644 --- a/Assets/UnityAtoms/GameActions/Collider2DGameObjectAction.cs.meta +++ b/Source/Collider2D/Collider2DGameObjectAction.cs.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 6bb9390c39976416e8aa3d428b7e9698 +guid: 9765caddd44cb41718b85ffe715b8cc2 MonoImporter: externalObjects: {} serializedVersion: 2 diff --git a/Source/Collider2D/Collider2DGameObjectEvent.cs b/Source/Collider2D/Collider2DGameObjectEvent.cs new file mode 100644 index 00000000..a2aa2760 --- /dev/null +++ b/Source/Collider2D/Collider2DGameObjectEvent.cs @@ -0,0 +1,8 @@ +using UnityEngine; + +namespace UnityAtoms +{ + + [CreateAssetMenu(menuName = "Unity Atoms/Collider2D/Event with GameObject", fileName = "Collider2DGameObjectEvent", order = CreateAssetMenuUtils.Order.EVENT_WITH_GO)] + public class Collider2DGameObjectEvent : GameEvent { } +} \ No newline at end of file diff --git a/Assets/UnityAtoms/GameEvents/Collider2DGameObjectEvent.cs.meta b/Source/Collider2D/Collider2DGameObjectEvent.cs.meta similarity index 83% rename from Assets/UnityAtoms/GameEvents/Collider2DGameObjectEvent.cs.meta rename to Source/Collider2D/Collider2DGameObjectEvent.cs.meta index 6504b040..eb7cb741 100644 --- a/Assets/UnityAtoms/GameEvents/Collider2DGameObjectEvent.cs.meta +++ b/Source/Collider2D/Collider2DGameObjectEvent.cs.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: cc83d7261fcc443a9adeb2348cc3909b +guid: fbfede7efef57429a927e19503e46bbd MonoImporter: externalObjects: {} serializedVersion: 2 diff --git a/Assets/UnityAtoms/GameEventListeners/Collider2DGameObjectListener.cs b/Source/Collider2D/Collider2DGameObjectListener.cs similarity index 82% rename from Assets/UnityAtoms/GameEventListeners/Collider2DGameObjectListener.cs rename to Source/Collider2D/Collider2DGameObjectListener.cs index 5c928649..35b5202a 100644 --- a/Assets/UnityAtoms/GameEventListeners/Collider2DGameObjectListener.cs +++ b/Source/Collider2D/Collider2DGameObjectListener.cs @@ -1,5 +1,3 @@ -using System; -using System.Collections.Generic; using UnityEngine; namespace UnityAtoms diff --git a/Assets/UnityAtoms/GameEventListeners/Collider2DGameObjectListener.cs.meta b/Source/Collider2D/Collider2DGameObjectListener.cs.meta similarity index 83% rename from Assets/UnityAtoms/GameEventListeners/Collider2DGameObjectListener.cs.meta rename to Source/Collider2D/Collider2DGameObjectListener.cs.meta index bb877681..8187e180 100644 --- a/Assets/UnityAtoms/GameEventListeners/Collider2DGameObjectListener.cs.meta +++ b/Source/Collider2D/Collider2DGameObjectListener.cs.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: e4e363ffbd7034feab35a82bfc193a56 +guid: 1ac7589a5aeb54ba199556e54f5722dc MonoImporter: externalObjects: {} serializedVersion: 2 diff --git a/Source/Collider2D/Collider2DList.cs b/Source/Collider2D/Collider2DList.cs new file mode 100644 index 00000000..6299b0f1 --- /dev/null +++ b/Source/Collider2D/Collider2DList.cs @@ -0,0 +1,7 @@ +using UnityEngine; + +namespace UnityAtoms +{ + [CreateAssetMenu(menuName = "Unity Atoms/Collider2D/List", fileName = "Collider2DList", order = CreateAssetMenuUtils.Order.LIST)] + public class Collider2DList : ScriptableObjectList { } +} \ No newline at end of file diff --git a/Assets/UnityAtoms/Lists/Collider2DList.cs.meta b/Source/Collider2D/Collider2DList.cs.meta similarity index 83% rename from Assets/UnityAtoms/Lists/Collider2DList.cs.meta rename to Source/Collider2D/Collider2DList.cs.meta index cb91c88e..65fe0767 100644 --- a/Assets/UnityAtoms/Lists/Collider2DList.cs.meta +++ b/Source/Collider2D/Collider2DList.cs.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 115f51619a9046d48ab91c3d6a5be40e +guid: 5d73d59fc0ccd4db597decab9e4542ee MonoImporter: externalObjects: {} serializedVersion: 2 diff --git a/Assets/UnityAtoms/GameActions/Collider2DListAction.cs b/Source/Collider2D/Collider2DListAction.cs similarity index 100% rename from Assets/UnityAtoms/GameActions/Collider2DListAction.cs rename to Source/Collider2D/Collider2DListAction.cs diff --git a/Assets/UnityAtoms/GameActions/Collider2DListAction.cs.meta b/Source/Collider2D/Collider2DListAction.cs.meta similarity index 83% rename from Assets/UnityAtoms/GameActions/Collider2DListAction.cs.meta rename to Source/Collider2D/Collider2DListAction.cs.meta index b82e503c..28fb235e 100644 --- a/Assets/UnityAtoms/GameActions/Collider2DListAction.cs.meta +++ b/Source/Collider2D/Collider2DListAction.cs.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 3a31a3e519a634982a763c62a47580e4 +guid: 9b436b1522f924520b0bff1c6607b348 MonoImporter: externalObjects: {} serializedVersion: 2 diff --git a/Assets/UnityAtoms/GameActions/Collider2DListGameObjectAction.cs b/Source/Collider2D/Collider2DListGameObjectAction.cs similarity index 100% rename from Assets/UnityAtoms/GameActions/Collider2DListGameObjectAction.cs rename to Source/Collider2D/Collider2DListGameObjectAction.cs diff --git a/Assets/UnityAtoms/GameActions/Collider2DListGameObjectAction.cs.meta b/Source/Collider2D/Collider2DListGameObjectAction.cs.meta similarity index 83% rename from Assets/UnityAtoms/GameActions/Collider2DListGameObjectAction.cs.meta rename to Source/Collider2D/Collider2DListGameObjectAction.cs.meta index cb7e82a1..5ccffd83 100644 --- a/Assets/UnityAtoms/GameActions/Collider2DListGameObjectAction.cs.meta +++ b/Source/Collider2D/Collider2DListGameObjectAction.cs.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: fcfe4e64689e9416282270d1d7748fcd +guid: b663a82a4c3bc4788a12cc29394b991f MonoImporter: externalObjects: {} serializedVersion: 2 diff --git a/Assets/UnityAtoms/GameEventListeners/Collider2DListener.cs b/Source/Collider2D/Collider2DListener.cs similarity index 70% rename from Assets/UnityAtoms/GameEventListeners/Collider2DListener.cs rename to Source/Collider2D/Collider2DListener.cs index f56adeec..84e40f4f 100644 --- a/Assets/UnityAtoms/GameEventListeners/Collider2DListener.cs +++ b/Source/Collider2D/Collider2DListener.cs @@ -1,7 +1,4 @@ -using System; -using System.Collections.Generic; using UnityEngine; -using UnityEngine.Events; namespace UnityAtoms { diff --git a/Assets/UnityAtoms/GameEventListeners/Collider2DListener.cs.meta b/Source/Collider2D/Collider2DListener.cs.meta similarity index 83% rename from Assets/UnityAtoms/GameEventListeners/Collider2DListener.cs.meta rename to Source/Collider2D/Collider2DListener.cs.meta index 0241a7b9..a7ca764b 100644 --- a/Assets/UnityAtoms/GameEventListeners/Collider2DListener.cs.meta +++ b/Source/Collider2D/Collider2DListener.cs.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: b66f39837a85c44548ae3d7bce0ba9f5 +guid: 97e00e9acb6f645bdaf444077c20a48b MonoImporter: externalObjects: {} serializedVersion: 2 diff --git a/Source/Collider2D/CreateCollider2DEventOnAwake.cs b/Source/Collider2D/CreateCollider2DEventOnAwake.cs new file mode 100644 index 00000000..1853059b --- /dev/null +++ b/Source/Collider2D/CreateCollider2DEventOnAwake.cs @@ -0,0 +1,14 @@ + +using UnityEngine; + +namespace UnityAtoms +{ + public class CreateCollider2DEventOnAwake : CreateEventOnAwake< + Collider2D, Collider2DEvent, Collider2DGameObjectEvent, + Collider2DListener, Collider2DGameObjectListener, + Collider2DAction, Collider2DGameObjectAction, + UnityCollider2DEvent, UnityCollider2DGameObjectEvent, + Collider2DHook + > + { } +} \ No newline at end of file diff --git a/Assets/UnityAtoms/GameEvents/CreateEventOnAwake/CreateCollider2DEventOnAwake.cs.meta b/Source/Collider2D/CreateCollider2DEventOnAwake.cs.meta similarity index 83% rename from Assets/UnityAtoms/GameEvents/CreateEventOnAwake/CreateCollider2DEventOnAwake.cs.meta rename to Source/Collider2D/CreateCollider2DEventOnAwake.cs.meta index 4f7e4f5c..381d8b45 100644 --- a/Assets/UnityAtoms/GameEvents/CreateEventOnAwake/CreateCollider2DEventOnAwake.cs.meta +++ b/Source/Collider2D/CreateCollider2DEventOnAwake.cs.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: c1b98df2a26694f2a9d785c121d4c4ec +guid: aa8c0abc0f2a24d8b8556d3535ac46e9 MonoImporter: externalObjects: {} serializedVersion: 2 diff --git a/Assets/UnityAtoms/CreateOnAwake/CreateListOnAwake/CreateCollider2DListOnAwake.cs b/Source/Collider2D/CreateCollider2DListOnAwake.cs similarity index 100% rename from Assets/UnityAtoms/CreateOnAwake/CreateListOnAwake/CreateCollider2DListOnAwake.cs rename to Source/Collider2D/CreateCollider2DListOnAwake.cs diff --git a/Assets/UnityAtoms/CreateOnAwake/CreateListOnAwake/CreateCollider2DListOnAwake.cs.meta b/Source/Collider2D/CreateCollider2DListOnAwake.cs.meta similarity index 83% rename from Assets/UnityAtoms/CreateOnAwake/CreateListOnAwake/CreateCollider2DListOnAwake.cs.meta rename to Source/Collider2D/CreateCollider2DListOnAwake.cs.meta index 20ba7cd4..67dcd246 100644 --- a/Assets/UnityAtoms/CreateOnAwake/CreateListOnAwake/CreateCollider2DListOnAwake.cs.meta +++ b/Source/Collider2D/CreateCollider2DListOnAwake.cs.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 09c7646f6a6db4daf8ebcdb3cac4da20 +guid: 204de4afcc51a4c03a82322dc4e4be1e MonoImporter: externalObjects: {} serializedVersion: 2 diff --git a/Source/Collider2D/UnityCollider2DEvent.cs b/Source/Collider2D/UnityCollider2DEvent.cs new file mode 100644 index 00000000..154a17f2 --- /dev/null +++ b/Source/Collider2D/UnityCollider2DEvent.cs @@ -0,0 +1,9 @@ +using System; +using UnityEngine.Events; +using UnityEngine; + +namespace UnityAtoms +{ + [Serializable] + public class UnityCollider2DEvent : UnityEvent { } +} \ No newline at end of file diff --git a/Source/Collider2D/UnityCollider2DEvent.cs.meta b/Source/Collider2D/UnityCollider2DEvent.cs.meta new file mode 100644 index 00000000..f627e470 --- /dev/null +++ b/Source/Collider2D/UnityCollider2DEvent.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 188317f32e8ea44f1a4f0c4267668d89 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Source/Collider2D/UnityCollider2DGameObjectEvent.cs b/Source/Collider2D/UnityCollider2DGameObjectEvent.cs new file mode 100644 index 00000000..0710ac21 --- /dev/null +++ b/Source/Collider2D/UnityCollider2DGameObjectEvent.cs @@ -0,0 +1,9 @@ +using System; +using UnityEngine.Events; +using UnityEngine; + +namespace UnityAtoms +{ + [Serializable] + public class UnityCollider2DGameObjectEvent : UnityEvent { } +} \ No newline at end of file diff --git a/Source/Collider2D/UnityCollider2DGameObjectEvent.cs.meta b/Source/Collider2D/UnityCollider2DGameObjectEvent.cs.meta new file mode 100644 index 00000000..ef69b618 --- /dev/null +++ b/Source/Collider2D/UnityCollider2DGameObjectEvent.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: f7bff70feb3bf498b824ae0553aebacd +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Source/Color.meta b/Source/Color.meta new file mode 100644 index 00000000..60f36964 --- /dev/null +++ b/Source/Color.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: c7637413b02b64e268412604adc264c7 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/UnityAtoms/GameActions/ColorAction.cs b/Source/Color/ColorAction.cs similarity index 100% rename from Assets/UnityAtoms/GameActions/ColorAction.cs rename to Source/Color/ColorAction.cs diff --git a/Assets/UnityAtoms/GameActions/ColorAction.cs.meta b/Source/Color/ColorAction.cs.meta similarity index 83% rename from Assets/UnityAtoms/GameActions/ColorAction.cs.meta rename to Source/Color/ColorAction.cs.meta index c86ddc7b..f9e1bb1f 100644 --- a/Assets/UnityAtoms/GameActions/ColorAction.cs.meta +++ b/Source/Color/ColorAction.cs.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: cd4db781cde534e1dabc5e346891c488 +guid: d2de52a4d71324a8aac59bf607b42a59 MonoImporter: externalObjects: {} serializedVersion: 2 diff --git a/Source/Color/ColorColorEvent.cs b/Source/Color/ColorColorEvent.cs new file mode 100644 index 00000000..ec67e736 --- /dev/null +++ b/Source/Color/ColorColorEvent.cs @@ -0,0 +1,8 @@ +using UnityEngine; + +namespace UnityAtoms +{ + + [CreateAssetMenu(menuName = "Unity Atoms/Color/Event x 2", fileName = "ColorColorEvent", order = CreateAssetMenuUtils.Order.EVENTx2)] + public class ColorColorEvent : GameEvent { } +} \ No newline at end of file diff --git a/Assets/UnityAtoms/GameEvents/ColorColorEvent.cs.meta b/Source/Color/ColorColorEvent.cs.meta similarity index 83% rename from Assets/UnityAtoms/GameEvents/ColorColorEvent.cs.meta rename to Source/Color/ColorColorEvent.cs.meta index f2346d0a..1eeb7b66 100644 --- a/Assets/UnityAtoms/GameEvents/ColorColorEvent.cs.meta +++ b/Source/Color/ColorColorEvent.cs.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: aedf7a57d9122475ebc0656da4be6555 +guid: 9fd7336c014a84f018f55cc1ab3b6174 MonoImporter: externalObjects: {} serializedVersion: 2 diff --git a/Source/Color/ColorConstant.cs b/Source/Color/ColorConstant.cs new file mode 100644 index 00000000..d6da475d --- /dev/null +++ b/Source/Color/ColorConstant.cs @@ -0,0 +1,7 @@ +using UnityEngine; + +namespace UnityAtoms +{ + [CreateAssetMenu(menuName = "Unity Atoms/Color/Constant", fileName = "ColorConstant", order = CreateAssetMenuUtils.Order.CONSTANT)] + public class ColorConstant : ScriptableObjectVariableBase { } +} \ No newline at end of file diff --git a/Assets/UnityAtoms/Constants/ColorConstant.cs.meta b/Source/Color/ColorConstant.cs.meta similarity index 100% rename from Assets/UnityAtoms/Constants/ColorConstant.cs.meta rename to Source/Color/ColorConstant.cs.meta diff --git a/Source/Color/ColorEvent.cs b/Source/Color/ColorEvent.cs new file mode 100644 index 00000000..e195c65c --- /dev/null +++ b/Source/Color/ColorEvent.cs @@ -0,0 +1,8 @@ +using UnityEngine; + +namespace UnityAtoms +{ + + [CreateAssetMenu(menuName = "Unity Atoms/Color/Event", fileName = "ColorEvent", order = CreateAssetMenuUtils.Order.EVENT)] + public class ColorEvent : GameEvent { } +} \ No newline at end of file diff --git a/Assets/UnityAtoms/GameEvents/ColorEvent.cs.meta b/Source/Color/ColorEvent.cs.meta similarity index 83% rename from Assets/UnityAtoms/GameEvents/ColorEvent.cs.meta rename to Source/Color/ColorEvent.cs.meta index 6796ffb1..5590fba7 100644 --- a/Assets/UnityAtoms/GameEvents/ColorEvent.cs.meta +++ b/Source/Color/ColorEvent.cs.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: b64f5099614e542369dd8afa8419b92f +guid: 90a1b915f134248ce993c320d88eddc3 MonoImporter: externalObjects: {} serializedVersion: 2 diff --git a/Source/Color/ColorList.cs b/Source/Color/ColorList.cs new file mode 100644 index 00000000..58febcc1 --- /dev/null +++ b/Source/Color/ColorList.cs @@ -0,0 +1,7 @@ +using UnityEngine; + +namespace UnityAtoms +{ + [CreateAssetMenu(menuName = "Unity Atoms/Color/List", fileName = "ColorList", order = CreateAssetMenuUtils.Order.LIST)] + public class ColorList : ScriptableObjectList { } +} \ No newline at end of file diff --git a/Assets/UnityAtoms/Lists/ColorList.cs.meta b/Source/Color/ColorList.cs.meta similarity index 83% rename from Assets/UnityAtoms/Lists/ColorList.cs.meta rename to Source/Color/ColorList.cs.meta index 9528ab4d..e239196a 100644 --- a/Assets/UnityAtoms/Lists/ColorList.cs.meta +++ b/Source/Color/ColorList.cs.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 451dacb43016a4dd8927a7ee650e489f +guid: 2168682f0cc504a9ea7f0d9474757f43 MonoImporter: externalObjects: {} serializedVersion: 2 diff --git a/Assets/UnityAtoms/GameEventListeners/ColorListener.cs b/Source/Color/ColorListener.cs similarity index 66% rename from Assets/UnityAtoms/GameEventListeners/ColorListener.cs rename to Source/Color/ColorListener.cs index 1923cf2a..93a1e393 100644 --- a/Assets/UnityAtoms/GameEventListeners/ColorListener.cs +++ b/Source/Color/ColorListener.cs @@ -1,7 +1,4 @@ -using System; -using System.Collections.Generic; using UnityEngine; -using UnityEngine.Events; namespace UnityAtoms { diff --git a/Assets/UnityAtoms/GameEventListeners/ColorListener.cs.meta b/Source/Color/ColorListener.cs.meta similarity index 83% rename from Assets/UnityAtoms/GameEventListeners/ColorListener.cs.meta rename to Source/Color/ColorListener.cs.meta index 63a8c386..6f0d04cc 100644 --- a/Assets/UnityAtoms/GameEventListeners/ColorListener.cs.meta +++ b/Source/Color/ColorListener.cs.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: ccfe22d2098fd4d7d84085b658196c02 +guid: 9e96464365d5c4ed2b79259b265072fb MonoImporter: externalObjects: {} serializedVersion: 2 diff --git a/Assets/UnityAtoms/References/ColorReference.cs b/Source/Color/ColorReference.cs similarity index 100% rename from Assets/UnityAtoms/References/ColorReference.cs rename to Source/Color/ColorReference.cs diff --git a/Assets/UnityAtoms/References/ColorReference.cs.meta b/Source/Color/ColorReference.cs.meta similarity index 83% rename from Assets/UnityAtoms/References/ColorReference.cs.meta rename to Source/Color/ColorReference.cs.meta index d69b8ac4..2abd1d3c 100644 --- a/Assets/UnityAtoms/References/ColorReference.cs.meta +++ b/Source/Color/ColorReference.cs.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: a0f3015e5b3e142588ac7380b4206117 +guid: e3645f64e0ca84be0ad77c326ea0ab61 MonoImporter: externalObjects: {} serializedVersion: 2 diff --git a/Assets/UnityAtoms/Variables/ColorVariable.cs b/Source/Color/ColorVariable.cs similarity index 67% rename from Assets/UnityAtoms/Variables/ColorVariable.cs rename to Source/Color/ColorVariable.cs index a3724fec..2f00da01 100644 --- a/Assets/UnityAtoms/Variables/ColorVariable.cs +++ b/Source/Color/ColorVariable.cs @@ -2,7 +2,7 @@ using UnityEngine; namespace UnityAtoms { - [CreateAssetMenu(menuName = "Unity Atoms/Variables/Color", fileName = "ColorVariable", order = 3)] + [CreateAssetMenu(menuName = "Unity Atoms/Color/Variable", fileName = "ColorVariable", order = CreateAssetMenuUtils.Order.VARIABLE)] public class ColorVariable : ScriptableObjectVariable { protected override bool AreEqual(Color first, Color second) diff --git a/Assets/UnityAtoms/Variables/ColorVariable.cs.meta b/Source/Color/ColorVariable.cs.meta similarity index 83% rename from Assets/UnityAtoms/Variables/ColorVariable.cs.meta rename to Source/Color/ColorVariable.cs.meta index fcb75011..45b98b40 100644 --- a/Assets/UnityAtoms/Variables/ColorVariable.cs.meta +++ b/Source/Color/ColorVariable.cs.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: a8e2ddf9d871b4d2298f5c10514ca8f0 +guid: 7b23140f6d79649b4895e80b920d9d62 MonoImporter: externalObjects: {} serializedVersion: 2 diff --git a/Source/Color/ConditionalColorAction.cs b/Source/Color/ConditionalColorAction.cs new file mode 100644 index 00000000..8f95db51 --- /dev/null +++ b/Source/Color/ConditionalColorAction.cs @@ -0,0 +1,20 @@ +using System; +using UnityEngine; + +namespace UnityAtoms +{ + [Serializable] + public class ConditionalColorGameActionHelper : ConditionalGameActionHelper { } + + [CreateAssetMenu(menuName = "Unity Atoms/Color/Conditional", fileName = "ConditionalColorAction", order = CreateAssetMenuUtils.Order.CONDITIONAL)] + public class ConditionalColorAction : ColorAction + { + [SerializeField] + private ConditionalColorGameActionHelper Conditional = null; + + public override void Do(Color t1) + { + Conditional.Do(t1); + } + } +} diff --git a/Source/Color/ConditionalColorAction.cs.meta b/Source/Color/ConditionalColorAction.cs.meta new file mode 100644 index 00000000..787996cc --- /dev/null +++ b/Source/Color/ConditionalColorAction.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 7100b8de507ba4c7990d9e11bb1d3133 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Source/Color/SetColorVariableValue.cs b/Source/Color/SetColorVariableValue.cs new file mode 100644 index 00000000..468edb41 --- /dev/null +++ b/Source/Color/SetColorVariableValue.cs @@ -0,0 +1,7 @@ +using UnityEngine; + +namespace UnityAtoms +{ + [CreateAssetMenu(menuName = "Unity Atoms/Color/Set Variable", fileName = "SetColorVariableValueAction", order = CreateAssetMenuUtils.Order.SET_VARIABLE)] + public class SetColorVariableValue : SetVariableValue { } +} \ No newline at end of file diff --git a/Assets/UnityAtoms/GameActions/SetVariableValue/SetColorVariableValue.cs.meta b/Source/Color/SetColorVariableValue.cs.meta similarity index 83% rename from Assets/UnityAtoms/GameActions/SetVariableValue/SetColorVariableValue.cs.meta rename to Source/Color/SetColorVariableValue.cs.meta index 94b9453f..739f8dba 100644 --- a/Assets/UnityAtoms/GameActions/SetVariableValue/SetColorVariableValue.cs.meta +++ b/Source/Color/SetColorVariableValue.cs.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 33f219d19f32c495695120296bf9172f +guid: f75efaa74c1bf4436834ff3a8d076198 MonoImporter: externalObjects: {} serializedVersion: 2 diff --git a/Source/Color/UnityColorEvent.cs b/Source/Color/UnityColorEvent.cs new file mode 100644 index 00000000..bd5a5d72 --- /dev/null +++ b/Source/Color/UnityColorEvent.cs @@ -0,0 +1,9 @@ +using System; +using UnityEngine.Events; +using UnityEngine; + +namespace UnityAtoms +{ + [Serializable] + public class UnityColorEvent : UnityEvent { } +} \ No newline at end of file diff --git a/Source/Color/UnityColorEvent.cs.meta b/Source/Color/UnityColorEvent.cs.meta new file mode 100644 index 00000000..0fa6f18f --- /dev/null +++ b/Source/Color/UnityColorEvent.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 207d15ae1bff64f4aa12e2897047cfdf +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/UnityAtoms/GameEvents/Editor.meta b/Source/Editor.meta similarity index 77% rename from Assets/UnityAtoms/GameEvents/Editor.meta rename to Source/Editor.meta index 14921e4d..493235c7 100644 --- a/Assets/UnityAtoms/GameEvents/Editor.meta +++ b/Source/Editor.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: e7767cc0fa374403ba1ba34e7f77e628 +guid: 7d2c2809b25094af7975080969ad89b9 folderAsset: yes DefaultImporter: externalObjects: {} diff --git a/Assets/UnityAtoms/GameEvents/Editor/GameEventEditor.cs b/Source/Editor/GameEventEditor.cs similarity index 100% rename from Assets/UnityAtoms/GameEvents/Editor/GameEventEditor.cs rename to Source/Editor/GameEventEditor.cs diff --git a/Assets/UnityAtoms/GameEvents/Editor/GameEventEditor.cs.meta b/Source/Editor/GameEventEditor.cs.meta similarity index 83% rename from Assets/UnityAtoms/GameEvents/Editor/GameEventEditor.cs.meta rename to Source/Editor/GameEventEditor.cs.meta index 2835e2d7..0573badc 100644 --- a/Assets/UnityAtoms/GameEvents/Editor/GameEventEditor.cs.meta +++ b/Source/Editor/GameEventEditor.cs.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: a1e5c8df32b71426e9b548cc1a0dd7ce +guid: 1c5f2ab15ba5340daad606e56a7391cf MonoImporter: externalObjects: {} serializedVersion: 2 diff --git a/Assets/UnityAtoms/References/Editor/ReferenceDrawer.cs b/Source/Editor/ReferenceDrawer.cs similarity index 95% rename from Assets/UnityAtoms/References/Editor/ReferenceDrawer.cs rename to Source/Editor/ReferenceDrawer.cs index 965414c3..0120ac81 100644 --- a/Assets/UnityAtoms/References/Editor/ReferenceDrawer.cs +++ b/Source/Editor/ReferenceDrawer.cs @@ -65,6 +65,9 @@ namespace UnityAtoms [CustomPropertyDrawer(typeof(IntReference))] public class IntReferenceDrawer : ReferenceDrawer { } + [CustomPropertyDrawer(typeof(StringReference))] + public class StringReferenceDrawer : ReferenceDrawer { } + [CustomPropertyDrawer(typeof(Vector2Reference))] public class Vector2ReferenceDrawer : ReferenceDrawer { } diff --git a/Assets/UnityAtoms/References/Editor/ReferenceDrawer.cs.meta b/Source/Editor/ReferenceDrawer.cs.meta similarity index 83% rename from Assets/UnityAtoms/References/Editor/ReferenceDrawer.cs.meta rename to Source/Editor/ReferenceDrawer.cs.meta index 13b5aa18..7ee25228 100644 --- a/Assets/UnityAtoms/References/Editor/ReferenceDrawer.cs.meta +++ b/Source/Editor/ReferenceDrawer.cs.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 338c6200b254c4d57bf429d8f164e472 +guid: d2466924e2026431490540eb861103c3 MonoImporter: externalObjects: {} serializedVersion: 2 diff --git a/Source/Editor/UnityAtomsEditor.asmdef b/Source/Editor/UnityAtomsEditor.asmdef new file mode 100644 index 00000000..534a91e8 --- /dev/null +++ b/Source/Editor/UnityAtomsEditor.asmdef @@ -0,0 +1,16 @@ +{ + "name": "UnityAtomsEditor", + "references": [ + "UnityAtoms" + ], + "optionalUnityReferences": [], + "includePlatforms": [ + "Editor" + ], + "excludePlatforms": [], + "allowUnsafeCode": false, + "overrideReferences": false, + "precompiledReferences": [], + "autoReferenced": true, + "defineConstraints": [] +} diff --git a/Source/Editor/UnityAtomsEditor.asmdef.meta b/Source/Editor/UnityAtomsEditor.asmdef.meta new file mode 100644 index 00000000..77025b57 --- /dev/null +++ b/Source/Editor/UnityAtomsEditor.asmdef.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: 490d635fe19e246ac9ace17c52b29273 +AssemblyDefinitionImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/UnityAtoms/Extensions.meta b/Source/Extensions.meta similarity index 77% rename from Assets/UnityAtoms/Extensions.meta rename to Source/Extensions.meta index 160588b3..85395816 100644 --- a/Assets/UnityAtoms/Extensions.meta +++ b/Source/Extensions.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 2ffc2318e4d5149f0810fc4bb6e64aa2 +guid: 31007114c272743999d7b2156f4b5497 folderAsset: yes DefaultImporter: externalObjects: {} diff --git a/Source/Extensions/ArrayExtensions.cs b/Source/Extensions/ArrayExtensions.cs new file mode 100644 index 00000000..bd8e0fbb --- /dev/null +++ b/Source/Extensions/ArrayExtensions.cs @@ -0,0 +1,19 @@ +using System.Collections; +using System.Collections.Generic; +using UnityEngine; + +namespace UnityAtoms.Extensions +{ + public static class ArrayExtensions + { + public static T GetRandom(this T[] array) + { + if (array == null || array.Length <= 0) + { + return default(T); + } + + return array[Random.Range(0, array.Length)]; + } + } +} \ No newline at end of file diff --git a/Source/Extensions/ArrayExtensions.cs.meta b/Source/Extensions/ArrayExtensions.cs.meta new file mode 100644 index 00000000..dd041b80 --- /dev/null +++ b/Source/Extensions/ArrayExtensions.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 57b4fc9662f524313ba64cbb714db2fb +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Source/Extensions/CameraExtensions.cs b/Source/Extensions/CameraExtensions.cs new file mode 100644 index 00000000..ff28502c --- /dev/null +++ b/Source/Extensions/CameraExtensions.cs @@ -0,0 +1,17 @@ +using UnityEngine; + +namespace UnityAtoms.Extensions +{ + public static class CameraExtensions + { + public static float GetOrthographicWorldScreenHeight(this Camera camera) + { + return camera.orthographicSize * 2f; + } + + public static float GetOrthographicWorldScreenWidth(this Camera camera) + { + return camera.GetOrthographicWorldScreenHeight() / Screen.height * Screen.width; ; + } + } +} \ No newline at end of file diff --git a/Source/Extensions/CameraExtensions.cs.meta b/Source/Extensions/CameraExtensions.cs.meta new file mode 100644 index 00000000..b4ec1f1f --- /dev/null +++ b/Source/Extensions/CameraExtensions.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: bc84a7d69cc6942608d30e7a7fc9cce0 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Source/Extensions/GameObjectExtensions.cs b/Source/Extensions/GameObjectExtensions.cs new file mode 100644 index 00000000..7c4eb853 --- /dev/null +++ b/Source/Extensions/GameObjectExtensions.cs @@ -0,0 +1,82 @@ +using System; +using System.Collections; +using System.Collections.Generic; +using UnityEngine; + +namespace UnityAtoms.Extensions +{ + public static class GameObjectExtensions + { + #region AtomicTagExtensions + + /// + /// Retrieves all AtomicTags for a given GameObject + /// + /// + /// - null if the GameObject does not have Atomic Tags or they (or the GO) are disabled) + /// - an readonly list of strings containing the tags + /// + public static ReadOnlyList GetAtomicTags(this GameObject go) + { + return AtomicTags.GetAtomicTags(go); + } + + /// + /// - False if the GameObject does not have the AtomicTag, else True + /// + public static bool HasTag(this GameObject go, string tag) + { + var atomicTags = AtomicTags.GetForGameObject(go); + if (atomicTags == null) return false; + return atomicTags.HasTag(tag); + } + + /// + /// - False if the GameObject does not have the AtomicTag, else True + /// + public static bool HasTag(this GameObject go, StringConstant stringConstant) + { + return go.HasTag(stringConstant.Value); + } + + + public static bool HasAnyTag(this GameObject go, List strings) + { + var atomicTags = AtomicTags.GetForGameObject(go); + if (atomicTags == null) return false; + + for (var i = 0; i < strings.Count; i++) + { + if (atomicTags.HasTag(strings[i])) return true; + } + return false; + } + + + public static bool HasAnyTag(this GameObject go, List stringConstants) + { + // basically same method as above, the code is mostly copy and pasted because its not preferable to convert + // stringconstants to strings and calling the other method, because of memory allocation + var atomicTags = AtomicTags.GetForGameObject(go); + if (atomicTags == null) return false; + + for (var i = 0; i < stringConstants.Count; i++) + { + if (atomicTags.HasTag(stringConstants[i].Value)) return true; + } + return false; + } + #endregion + + // Tries to get a component on the the GameObject. If the component doesn't exists it adds it and return the newly added component. + public static T GetOrAddComponent(this GameObject go) where T : Component + { + return go.GetComponent() == null ? go.AddComponent() : go.GetComponent(); + } + + public static bool HasComponent(this GameObject go) where T : Component + { + return go.GetComponent() != null; + } + } +} diff --git a/Source/Extensions/GameObjectExtensions.cs.meta b/Source/Extensions/GameObjectExtensions.cs.meta new file mode 100644 index 00000000..7c783cc9 --- /dev/null +++ b/Source/Extensions/GameObjectExtensions.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: b70cb59b7540b43a794791992a68b2f2 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Source/Extensions/ListExtensions.cs b/Source/Extensions/ListExtensions.cs new file mode 100644 index 00000000..8519b894 --- /dev/null +++ b/Source/Extensions/ListExtensions.cs @@ -0,0 +1,177 @@ +using System; +using System.Collections; +using System.Collections.Generic; +using UnityEngine; + +namespace UnityAtoms.Extensions +{ + // Create an Action delegates that takes 5 parameters. Not included in the standard lib. + public delegate void Action(T1 p1, T2 p2, T3 p3, T4 p4, T5 p5); + + public static class ListExtensions + { + public static void ForEach(this List list, Action action, P1 param1) + { + for (int i = 0; list != null && i < list.Count; ++i) + { + action(list[i], param1); + } + } + + public static void ForEach(this List list, Action action, P1 param1, P2 param2) + { + for (int i = 0; list != null && i < list.Count; ++i) + { + action(list[i], param1, param2); + } + } + + public static void ForEach(this List list, Action action, P1 param1, P2 param2, P3 param3) + { + for (int i = 0; list != null && i < list.Count; ++i) + { + action(list[i], param1, param2, param3); + } + } + + public static void ForEach(this List list, Func selector, Action action, P1 param1) + { + for (int i = 0; list != null && i < list.Count; ++i) + { + action(selector(list[i]), param1); + } + } + + public static void ForEach(this List list, Func selector, Action action, P1 param1, P2 param2) + { + for (int i = 0; list != null && i < list.Count; ++i) + { + action(selector(list[i]), param1, param2); + } + } + + public static void ForEach(this List list, Func selector, Action action, P1 param1, P2 param2, P3 param3) + { + for (int i = 0; list != null && i < list.Count; ++i) + { + action(selector(list[i]), param1, param2, param3); + } + } + + public static void ForEach(this List list, Action action) + { + for (int i = 0; list != null && i < list.Count; ++i) + { + action(list[i], i); + } + } + + public static void ForEach(this List list, Action action, P1 param1) + { + for (int i = 0; list != null && i < list.Count; ++i) + { + action(list[i], i, param1); + } + } + + public static void ForEach(this List list, Action action, P1 param1, P2 param2) + { + for (int i = 0; list != null && i < list.Count; ++i) + { + action(list[i], i, param1, param2); + } + } + + public static void ForEach(this List list, Action action, P1 param1, P2 param2, P3 param3) + { + for (int i = 0; list != null && i < list.Count; ++i) + { + action(list[i], i, param1, param2, param3); + } + } + + public static R Reduce(this List list, Func reducer, Func getValue, R initialValue, Func skip = null) + { + R accumulator = initialValue; + for (int i = 0; list != null && i < list.Count; ++i) + { + if (skip != null && skip(list[i])) + { + continue; + } + + accumulator = reducer(accumulator, getValue(list[i])); + } + + return accumulator; + } + + public static float ReturnMaxFloat(float acc, float cur) { return Mathf.Max(acc, cur); } + public static float ReturnMinFloat(float acc, float cur) { return Mathf.Min(acc, cur); } + + public static T First(this List list, Func func) + { + for (int i = 0; list != null && i < list.Count; ++i) + { + if (func(list[i])) return list[i]; + } + + return default(T); + } + + public static bool Some(this List list, Func func) + { + return EqualityComparer.Default.Equals(list.First(func), default(T)); + } + + public static bool AddIfNotExists(this List list, T item) + { + if (!list.Contains(item)) + { + list.Add(item); + return true; + } + + return false; + } + + public static T GetOrInstantiate(this List list, UnityEngine.Object prefab, Vector3 position, Quaternion quaternion, Func condition) where T : UnityEngine.Component + { + var component = list.First(condition); + + if (component != null) + { + component.transform.position = position; + component.transform.rotation = quaternion; + return component; + } + + var newComponent = GameObject.Instantiate(prefab, position, quaternion) as T; + list.Add(newComponent); + return newComponent; + } + + public static GameObject GetOrInstantiate(this List list, UnityEngine.Object prefab, Vector3 position, Quaternion quaternion, Func condition) + { + var component = list.First(condition); + + if (component != null) + { + component.transform.position = position; + component.transform.rotation = quaternion; + return component; + } + + var newGameObject = GameObject.Instantiate(prefab, position, quaternion) as GameObject; + list.Add(newGameObject); + return newGameObject; + } + + public static T InstantiateAndAdd(this List list, UnityEngine.Object prefab, Vector3 position, Quaternion quaternion) where T : UnityEngine.Component + { + var component = GameObject.Instantiate(prefab, position, quaternion) as T; + list.Add(component); + return component; + } + } +} \ No newline at end of file diff --git a/Source/Extensions/ListExtensions.cs.meta b/Source/Extensions/ListExtensions.cs.meta new file mode 100644 index 00000000..97750c6e --- /dev/null +++ b/Source/Extensions/ListExtensions.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 1a4f11425e9364a0e94947e2904a6b10 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Source/Extensions/MonoBehaviourExtensions.cs b/Source/Extensions/MonoBehaviourExtensions.cs new file mode 100644 index 00000000..5bbe1191 --- /dev/null +++ b/Source/Extensions/MonoBehaviourExtensions.cs @@ -0,0 +1,46 @@ +using System; +using System.Collections; +using System.Collections.Generic; +using UnityEngine; + +namespace UnityAtoms.Extensions +{ + public static class MonoBehaviourExtensions + { + public static void ClearInterval(this MonoBehaviour mb, Coroutine coroutine) + { + mb.StopCoroutine(coroutine); + } + + public static Coroutine SetTimeout(this MonoBehaviour mb, Action function, float delay) + { + return mb.StartCoroutine(SetTimeout(function, delay)); + } + + static IEnumerator SetTimeout(Action function, float delay) + { + yield return new WaitForSeconds(delay); + function(); + } + + public static Coroutine SetInterval(this MonoBehaviour mb, Action function, float delay) + { + return mb.StartCoroutine(SetInterval(function, delay)); + } + + static IEnumerator SetInterval(Action function, float delay) + { + while (true && function != null) + { + yield return new WaitForSeconds(delay); + function(); + } + } + + // Tries to get a component on the the MonoBehaviour's GameObject. If the component doesn't exists it adds it and return the newly added component. + public static T GetOrAddComponent(this MonoBehaviour mb) where T : Component + { + return mb.gameObject.GetOrAddComponent(); + } + } +} \ No newline at end of file diff --git a/Source/Extensions/MonoBehaviourExtensions.cs.meta b/Source/Extensions/MonoBehaviourExtensions.cs.meta new file mode 100644 index 00000000..16976bf2 --- /dev/null +++ b/Source/Extensions/MonoBehaviourExtensions.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: b9bb3a029ccc8479ab6abba932404203 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Source/Extensions/TransformExtensions.cs b/Source/Extensions/TransformExtensions.cs new file mode 100644 index 00000000..5f20819f --- /dev/null +++ b/Source/Extensions/TransformExtensions.cs @@ -0,0 +1,130 @@ +using UnityEngine; +using System; +using System.Collections; + +namespace UnityAtoms.Extensions +{ + public static class TransformExtensions + { + + /* Finds a child to this transform by name. Searches not only the first level in the + * tree hierarchy of child objects, but all the children, grand children, and so on. + */ + public static Transform FindDeepChild(this Transform parent, string name) + { + var result = parent.Find(name); + + if (result != null) + return result; + + for (int i = 0; i < parent.childCount; ++i) + { + result = parent.GetChild(i).FindDeepChild(name); + if (result != null) + return result; + } + + return null; + } + + /* Traverse all the children of the transform and executes the action on this transform, + * as well as on all the children. + */ + public static void TraverseAndExecute(this Transform current, Action action) + { + action(current); + + for (int i = 0; i < current.childCount; ++i) + { + current.GetChild(i).TraverseAndExecute(action); + } + } + + /* Traverse all the children of the transform and executes the func on this transform, + * as well as on all the children. Will return true if all of the funcs returns true. + */ + public static bool TraverseExecuteAndCheck(this Transform current, Func func) + { + bool ret = func(current); + + for (int i = 0; i < current.childCount; ++i) + { + var temp = current.GetChild(i).TraverseExecuteAndCheck(func); + if (!temp) + ret = false; + } + + return ret; + } + + public static void ForEachChild(this Transform transform, Action action) + { + for (int i = 0; i < transform.childCount; ++i) + { + action(transform.GetChild(i)); + } + } + + public static void ForEachChild(this Transform transform, Action action, P1 param1) + { + for (int i = 0; i < transform.childCount; ++i) + { + action(transform.GetChild(i), param1); + } + } + + public static void ForEachChild(this Transform transform, Action action, P1 param1, P2 param2) + { + for (int i = 0; i < transform.childCount; ++i) + { + action(transform.GetChild(i), param1, param2); + } + } + + public static void ForEachChild(this Transform transform, Action action, P1 param1, P2 param2, P3 param3) + { + for (int i = 0; i < transform.childCount; ++i) + { + action(transform.GetChild(i), param1, param2, param3); + } + } + + public static void ForEachChild(this Transform transform, Action action) + { + for (int i = 0; i < transform.childCount; ++i) + { + action(transform.GetChild(i), i); + } + } + + public static void ForEachChild(this Transform transform, Action action, P1 param1) + { + for (int i = 0; i < transform.childCount; ++i) + { + action(transform.GetChild(i), i, param1); + } + } + + public static void ForEachChild(this Transform transform, Action action, P1 param1, P2 param2) + { + for (int i = 0; i < transform.childCount; ++i) + { + action(transform.GetChild(i), i, param1, param2); + } + } + + public static void ForEachChild(this Transform transform, Action action, P1 param1, P2 param2, P3 param3) + { + for (int i = 0; i < transform.childCount; ++i) + { + action(transform.GetChild(i), i, param1, param2, param3); + } + } + + public static Transform AddParent(this Transform transform, Transform parent) + { + transform.parent = parent; + return transform; + } + } +} diff --git a/Source/Extensions/TransformExtensions.cs.meta b/Source/Extensions/TransformExtensions.cs.meta new file mode 100644 index 00000000..5da71cb7 --- /dev/null +++ b/Source/Extensions/TransformExtensions.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 98b6df1acc5d948b48a54977fed6768e +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/UnityAtoms/Extensions/Vector2Extensions.cs b/Source/Extensions/Vector2Extensions.cs similarity index 94% rename from Assets/UnityAtoms/Extensions/Vector2Extensions.cs rename to Source/Extensions/Vector2Extensions.cs index 07c78c82..d16e97b1 100644 --- a/Assets/UnityAtoms/Extensions/Vector2Extensions.cs +++ b/Source/Extensions/Vector2Extensions.cs @@ -1,6 +1,6 @@ using UnityEngine; -namespace UnityAtoms +namespace UnityAtoms.Extensions { public static class Vector2Extensions { diff --git a/Assets/UnityAtoms/Extensions/Vector2Extensions.cs.meta b/Source/Extensions/Vector2Extensions.cs.meta similarity index 83% rename from Assets/UnityAtoms/Extensions/Vector2Extensions.cs.meta rename to Source/Extensions/Vector2Extensions.cs.meta index bee5a1c9..9c884ad9 100644 --- a/Assets/UnityAtoms/Extensions/Vector2Extensions.cs.meta +++ b/Source/Extensions/Vector2Extensions.cs.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 201318a5ae06548e2bc1b99f2c3449ce +guid: c4c59accb850d4165b5e54a94a159f06 MonoImporter: externalObjects: {} serializedVersion: 2 diff --git a/Assets/UnityAtoms/Extensions/Vector3Extensions.cs b/Source/Extensions/Vector3Extensions.cs similarity index 53% rename from Assets/UnityAtoms/Extensions/Vector3Extensions.cs rename to Source/Extensions/Vector3Extensions.cs index 527fad6e..23c0ee72 100644 --- a/Assets/UnityAtoms/Extensions/Vector3Extensions.cs +++ b/Source/Extensions/Vector3Extensions.cs @@ -1,7 +1,8 @@ using UnityEngine; -namespace UnityAtoms +namespace UnityAtoms.Extensions { + public enum V3Axis { x, y, z } public static class Vector3Extensions { public static Vector2 ToVector2(this Vector2 v3) @@ -14,5 +15,14 @@ namespace UnityAtoms var distance = target - v3; return v3 + (distance.normalized * maxDistance); } + + public static Vector3 CloneAndChange(this Vector3 v3, V3Axis axis, float val) + { + return new Vector3( + axis == V3Axis.x ? val : v3.x, + axis == V3Axis.y ? val : v3.y, + axis == V3Axis.z ? val : v3.z + ); + } } } \ No newline at end of file diff --git a/Assets/UnityAtoms/Extensions/Vector3Extensions.cs.meta b/Source/Extensions/Vector3Extensions.cs.meta similarity index 83% rename from Assets/UnityAtoms/Extensions/Vector3Extensions.cs.meta rename to Source/Extensions/Vector3Extensions.cs.meta index 0092f552..a88b75b0 100644 --- a/Assets/UnityAtoms/Extensions/Vector3Extensions.cs.meta +++ b/Source/Extensions/Vector3Extensions.cs.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: c4645a7be4d6d40ee9b7bb8d7706f25e +guid: 8531614fdc53540ffb8aa71593f66bb5 MonoImporter: externalObjects: {} serializedVersion: 2 diff --git a/Source/Float.meta b/Source/Float.meta new file mode 100644 index 00000000..b4bd780d --- /dev/null +++ b/Source/Float.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: e5dc4254df2324c93bd06c97bf6b8d55 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Source/Float/ConditionalFloatAction.cs b/Source/Float/ConditionalFloatAction.cs new file mode 100644 index 00000000..d7ad37db --- /dev/null +++ b/Source/Float/ConditionalFloatAction.cs @@ -0,0 +1,20 @@ +using System; +using UnityEngine; + +namespace UnityAtoms +{ + [Serializable] + public class ConditionalFloatGameActionHelper : ConditionalGameActionHelper { } + + [CreateAssetMenu(menuName = "Unity Atoms/Float/Conditional", fileName = "ConditionalFloatAction", order = CreateAssetMenuUtils.Order.CONDITIONAL)] + public class ConditionalFloatAction : FloatAction + { + [SerializeField] + private ConditionalFloatGameActionHelper Conditional = null; + + public override void Do(float t1) + { + Conditional.Do(t1); + } + } +} diff --git a/Source/Float/ConditionalFloatAction.cs.meta b/Source/Float/ConditionalFloatAction.cs.meta new file mode 100644 index 00000000..2c34b787 --- /dev/null +++ b/Source/Float/ConditionalFloatAction.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: cfbbae83f8efe4670bc7aa4cdaacd73f +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/UnityAtoms/GameActions/FloatAction.cs b/Source/Float/FloatAction.cs similarity index 100% rename from Assets/UnityAtoms/GameActions/FloatAction.cs rename to Source/Float/FloatAction.cs diff --git a/Assets/UnityAtoms/GameActions/FloatAction.cs.meta b/Source/Float/FloatAction.cs.meta similarity index 83% rename from Assets/UnityAtoms/GameActions/FloatAction.cs.meta rename to Source/Float/FloatAction.cs.meta index 282bed0f..d4a6e4af 100644 --- a/Assets/UnityAtoms/GameActions/FloatAction.cs.meta +++ b/Source/Float/FloatAction.cs.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: df3be4aed2bae4dbd97a966788ea0663 +guid: b42e3b30eb1144a768cc180a4620f40a MonoImporter: externalObjects: {} serializedVersion: 2 diff --git a/Source/Float/FloatConstant.cs b/Source/Float/FloatConstant.cs new file mode 100644 index 00000000..cc58af03 --- /dev/null +++ b/Source/Float/FloatConstant.cs @@ -0,0 +1,7 @@ +using UnityEngine; + +namespace UnityAtoms +{ + [CreateAssetMenu(menuName = "Unity Atoms/Float/Constant", fileName = "FloatConstant", order = CreateAssetMenuUtils.Order.CONSTANT)] + public class FloatConstant : ScriptableObjectVariableBase { } +} \ No newline at end of file diff --git a/Assets/UnityAtoms/Constants/FloatConstant.cs.meta b/Source/Float/FloatConstant.cs.meta similarity index 83% rename from Assets/UnityAtoms/Constants/FloatConstant.cs.meta rename to Source/Float/FloatConstant.cs.meta index e411f00e..64a01cb2 100644 --- a/Assets/UnityAtoms/Constants/FloatConstant.cs.meta +++ b/Source/Float/FloatConstant.cs.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 383053a236f004aeab4b83d8ef98f157 +guid: dce6288bb93e7409cb5a22ba7c3402bf MonoImporter: externalObjects: {} serializedVersion: 2 diff --git a/Source/Float/FloatEvent.cs b/Source/Float/FloatEvent.cs new file mode 100644 index 00000000..11036dfb --- /dev/null +++ b/Source/Float/FloatEvent.cs @@ -0,0 +1,7 @@ +using UnityEngine; + +namespace UnityAtoms +{ + [CreateAssetMenu(menuName = "Unity Atoms/Float/Event", fileName = "FloatEvent", order = CreateAssetMenuUtils.Order.EVENT)] + public class FloatEvent : GameEvent { } +} \ No newline at end of file diff --git a/Assets/UnityAtoms/GameEvents/FloatEvent.cs.meta b/Source/Float/FloatEvent.cs.meta similarity index 83% rename from Assets/UnityAtoms/GameEvents/FloatEvent.cs.meta rename to Source/Float/FloatEvent.cs.meta index ab0f97e3..361020c8 100644 --- a/Assets/UnityAtoms/GameEvents/FloatEvent.cs.meta +++ b/Source/Float/FloatEvent.cs.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: b83b01ea993a44f87ad4ca400891ec56 +guid: 5e97038fbaadd4f51b86bcd30d2e76d4 MonoImporter: externalObjects: {} serializedVersion: 2 diff --git a/Source/Float/FloatFloatEvent.cs b/Source/Float/FloatFloatEvent.cs new file mode 100644 index 00000000..7c85981b --- /dev/null +++ b/Source/Float/FloatFloatEvent.cs @@ -0,0 +1,8 @@ +using UnityEngine; + +namespace UnityAtoms +{ + + [CreateAssetMenu(menuName = "Unity Atoms/Float/Event x 2", fileName = "FloatFloatEvent", order = CreateAssetMenuUtils.Order.EVENTx2)] + public class FloatFloatEvent : GameEvent { } +} \ No newline at end of file diff --git a/Assets/UnityAtoms/GameEvents/FloatFloatEvent.cs.meta b/Source/Float/FloatFloatEvent.cs.meta similarity index 83% rename from Assets/UnityAtoms/GameEvents/FloatFloatEvent.cs.meta rename to Source/Float/FloatFloatEvent.cs.meta index 66fce9af..ff65baf9 100644 --- a/Assets/UnityAtoms/GameEvents/FloatFloatEvent.cs.meta +++ b/Source/Float/FloatFloatEvent.cs.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 261c04085d0284b9082ce69b9fc5d9f1 +guid: dbb697f336cda40959301eff4b885daa MonoImporter: externalObjects: {} serializedVersion: 2 diff --git a/Source/Float/FloatList.cs b/Source/Float/FloatList.cs new file mode 100644 index 00000000..bdcfe9dc --- /dev/null +++ b/Source/Float/FloatList.cs @@ -0,0 +1,7 @@ +using UnityEngine; + +namespace UnityAtoms +{ + [CreateAssetMenu(menuName = "Unity Atoms/Float/List", fileName = "FloatList", order = CreateAssetMenuUtils.Order.LIST)] + public class FloatList : ScriptableObjectList { } +} \ No newline at end of file diff --git a/Assets/UnityAtoms/Lists/FloatList.cs.meta b/Source/Float/FloatList.cs.meta similarity index 83% rename from Assets/UnityAtoms/Lists/FloatList.cs.meta rename to Source/Float/FloatList.cs.meta index d1a44caf..4ae022cd 100644 --- a/Assets/UnityAtoms/Lists/FloatList.cs.meta +++ b/Source/Float/FloatList.cs.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: a9eb8ea1c1fd94c0ca7127920fede363 +guid: d03f30cdd96a04ca786a0a557ad1f68f MonoImporter: externalObjects: {} serializedVersion: 2 diff --git a/Assets/UnityAtoms/GameEventListeners/FloatListener.cs b/Source/Float/FloatListener.cs similarity index 57% rename from Assets/UnityAtoms/GameEventListeners/FloatListener.cs rename to Source/Float/FloatListener.cs index c5695b8a..c0396b0e 100644 --- a/Assets/UnityAtoms/GameEventListeners/FloatListener.cs +++ b/Source/Float/FloatListener.cs @@ -1,8 +1,3 @@ -using System; -using System.Collections.Generic; -using UnityEngine.Events; -using UnityEngine; - namespace UnityAtoms { public class FloatListener : GameEventListener { } diff --git a/Assets/UnityAtoms/GameEventListeners/FloatListener.cs.meta b/Source/Float/FloatListener.cs.meta similarity index 83% rename from Assets/UnityAtoms/GameEventListeners/FloatListener.cs.meta rename to Source/Float/FloatListener.cs.meta index 71a1a77f..18891060 100644 --- a/Assets/UnityAtoms/GameEventListeners/FloatListener.cs.meta +++ b/Source/Float/FloatListener.cs.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 6d9a93524d8b64dddbfc7169824799f6 +guid: c3c011f4ad76943cf917587b621b8267 MonoImporter: externalObjects: {} serializedVersion: 2 diff --git a/Assets/UnityAtoms/References/FloatReference.cs b/Source/Float/FloatReference.cs similarity index 100% rename from Assets/UnityAtoms/References/FloatReference.cs rename to Source/Float/FloatReference.cs diff --git a/Assets/UnityAtoms/References/FloatReference.cs.meta b/Source/Float/FloatReference.cs.meta similarity index 83% rename from Assets/UnityAtoms/References/FloatReference.cs.meta rename to Source/Float/FloatReference.cs.meta index ae0e2ef7..65f573d0 100644 --- a/Assets/UnityAtoms/References/FloatReference.cs.meta +++ b/Source/Float/FloatReference.cs.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 18acb2a2a45064b71ba8d552db1f6d6a +guid: 9e5c9a69208df442d8d98915d353ce78 MonoImporter: externalObjects: {} serializedVersion: 2 diff --git a/Assets/UnityAtoms/Variables/FloatVariable.cs b/Source/Float/FloatVariable.cs similarity index 64% rename from Assets/UnityAtoms/Variables/FloatVariable.cs rename to Source/Float/FloatVariable.cs index 9847fbb2..9f91f5e3 100644 --- a/Assets/UnityAtoms/Variables/FloatVariable.cs +++ b/Source/Float/FloatVariable.cs @@ -2,9 +2,8 @@ using UnityEngine; namespace UnityAtoms { - [CreateAssetMenu(menuName = "Unity Atoms/Variables/Float", fileName = "FloatVariable", order = 1)] - public class FloatVariable : EquatableScriptableObjectVariable, - IWithApplyChange + [CreateAssetMenu(menuName = "Unity Atoms/Float/Variable", fileName = "FloatVariable", order = CreateAssetMenuUtils.Order.VARIABLE)] + public class FloatVariable : EquatableScriptableObjectVariable, IWithApplyChange { public bool ApplyChange(float amount) { diff --git a/Assets/UnityAtoms/Variables/FloatVariable.cs.meta b/Source/Float/FloatVariable.cs.meta similarity index 83% rename from Assets/UnityAtoms/Variables/FloatVariable.cs.meta rename to Source/Float/FloatVariable.cs.meta index 07576a08..22b5bbdb 100644 --- a/Assets/UnityAtoms/Variables/FloatVariable.cs.meta +++ b/Source/Float/FloatVariable.cs.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: d3cac199eb9ec41f0823c53dc3494c9f +guid: 4b01d10ebe5fb40b988e6f1caaf85145 MonoImporter: externalObjects: {} serializedVersion: 2 diff --git a/Source/Float/SetFloatVariableValue.cs b/Source/Float/SetFloatVariableValue.cs new file mode 100644 index 00000000..98037f36 --- /dev/null +++ b/Source/Float/SetFloatVariableValue.cs @@ -0,0 +1,7 @@ +using UnityEngine; + +namespace UnityAtoms +{ + [CreateAssetMenu(menuName = "Unity Atoms/Float/Set Variable", fileName = "SetFloatVariableValueAction", order = CreateAssetMenuUtils.Order.SET_VARIABLE)] + public class SetFloatVariableValue : SetVariableValue { } +} \ No newline at end of file diff --git a/Assets/UnityAtoms/GameActions/SetVariableValue/SetFloatVariableValue.cs.meta b/Source/Float/SetFloatVariableValue.cs.meta similarity index 83% rename from Assets/UnityAtoms/GameActions/SetVariableValue/SetFloatVariableValue.cs.meta rename to Source/Float/SetFloatVariableValue.cs.meta index a5b7ce34..ec72479e 100644 --- a/Assets/UnityAtoms/GameActions/SetVariableValue/SetFloatVariableValue.cs.meta +++ b/Source/Float/SetFloatVariableValue.cs.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 5001621609c334fbdb8a4cc4ebc1ce53 +guid: 5ab1147161c9343aea124844fdb2a42e MonoImporter: externalObjects: {} serializedVersion: 2 diff --git a/Source/Float/UnityFloatEvent.cs b/Source/Float/UnityFloatEvent.cs new file mode 100644 index 00000000..d2237c40 --- /dev/null +++ b/Source/Float/UnityFloatEvent.cs @@ -0,0 +1,8 @@ +using System; +using UnityEngine.Events; + +namespace UnityAtoms +{ + [Serializable] + public class UnityFloatEvent : UnityEvent { } +} \ No newline at end of file diff --git a/Source/Float/UnityFloatEvent.cs.meta b/Source/Float/UnityFloatEvent.cs.meta new file mode 100644 index 00000000..d35f0570 --- /dev/null +++ b/Source/Float/UnityFloatEvent.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 130f45f85dd3e4c399b9ae9671d00543 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/UnityAtoms/GameFunctions.meta b/Source/GameFunctions.meta similarity index 77% rename from Assets/UnityAtoms/GameFunctions.meta rename to Source/GameFunctions.meta index 8b044dfa..2a92c803 100644 --- a/Assets/UnityAtoms/GameFunctions.meta +++ b/Source/GameFunctions.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: a447e1b6dcdd74debbecbd877179b392 +guid: 8abeddd5121c9489b9e17d4fca1dde3c folderAsset: yes DefaultImporter: externalObjects: {} diff --git a/Source/GameFunctions/BoolBoolFunction.cs b/Source/GameFunctions/BoolBoolFunction.cs new file mode 100644 index 00000000..f5859fd6 --- /dev/null +++ b/Source/GameFunctions/BoolBoolFunction.cs @@ -0,0 +1,6 @@ +using UnityEngine; + +namespace UnityAtoms +{ + public abstract class BoolBoolFunction : GameFunction { } +} \ No newline at end of file diff --git a/Source/GameFunctions/BoolBoolFunction.cs.meta b/Source/GameFunctions/BoolBoolFunction.cs.meta new file mode 100644 index 00000000..e1f57e0d --- /dev/null +++ b/Source/GameFunctions/BoolBoolFunction.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 955b1f84284cb4dd9b1ae6b0096dc262 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Source/GameFunctions/BoolColorFunction.cs b/Source/GameFunctions/BoolColorFunction.cs new file mode 100644 index 00000000..b5d04892 --- /dev/null +++ b/Source/GameFunctions/BoolColorFunction.cs @@ -0,0 +1,6 @@ +using UnityEngine; + +namespace UnityAtoms +{ + public abstract class BoolColorFunction : GameFunction { } +} \ No newline at end of file diff --git a/Source/GameFunctions/BoolColorFunction.cs.meta b/Source/GameFunctions/BoolColorFunction.cs.meta new file mode 100644 index 00000000..149a087f --- /dev/null +++ b/Source/GameFunctions/BoolColorFunction.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: ca8fc899d5ac1459da4150b057f3b8c9 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Source/GameFunctions/BoolFloatFunction.cs b/Source/GameFunctions/BoolFloatFunction.cs new file mode 100644 index 00000000..ae964338 --- /dev/null +++ b/Source/GameFunctions/BoolFloatFunction.cs @@ -0,0 +1,6 @@ +using UnityEngine; + +namespace UnityAtoms +{ + public abstract class BoolFloatFunction : GameFunction { } +} \ No newline at end of file diff --git a/Source/GameFunctions/BoolFloatFunction.cs.meta b/Source/GameFunctions/BoolFloatFunction.cs.meta new file mode 100644 index 00000000..d40e5653 --- /dev/null +++ b/Source/GameFunctions/BoolFloatFunction.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 845bd44cad71a4833a7e2ecf08632dc4 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/UnityAtoms/GameFunctions/BoolFunction.cs b/Source/GameFunctions/BoolFunction.cs similarity index 100% rename from Assets/UnityAtoms/GameFunctions/BoolFunction.cs rename to Source/GameFunctions/BoolFunction.cs diff --git a/Assets/UnityAtoms/GameFunctions/BoolFunction.cs.meta b/Source/GameFunctions/BoolFunction.cs.meta similarity index 100% rename from Assets/UnityAtoms/GameFunctions/BoolFunction.cs.meta rename to Source/GameFunctions/BoolFunction.cs.meta diff --git a/Assets/UnityAtoms/GameFunctions/BoolGameObjectFunction.cs b/Source/GameFunctions/BoolGameObjectFunction.cs similarity index 100% rename from Assets/UnityAtoms/GameFunctions/BoolGameObjectFunction.cs rename to Source/GameFunctions/BoolGameObjectFunction.cs diff --git a/Assets/UnityAtoms/GameFunctions/BoolGameObjectFunction.cs.meta b/Source/GameFunctions/BoolGameObjectFunction.cs.meta similarity index 100% rename from Assets/UnityAtoms/GameFunctions/BoolGameObjectFunction.cs.meta rename to Source/GameFunctions/BoolGameObjectFunction.cs.meta diff --git a/Source/GameFunctions/BoolIntFunction.cs b/Source/GameFunctions/BoolIntFunction.cs new file mode 100644 index 00000000..f0ce9cdc --- /dev/null +++ b/Source/GameFunctions/BoolIntFunction.cs @@ -0,0 +1,6 @@ +using UnityEngine; + +namespace UnityAtoms +{ + public abstract class BoolIntFunction : GameFunction { } +} \ No newline at end of file diff --git a/Source/GameFunctions/BoolIntFunction.cs.meta b/Source/GameFunctions/BoolIntFunction.cs.meta new file mode 100644 index 00000000..dcb42c0f --- /dev/null +++ b/Source/GameFunctions/BoolIntFunction.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 3b55778c926994419af53944ce09e881 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Source/GameFunctions/BoolVector2Function.cs b/Source/GameFunctions/BoolVector2Function.cs new file mode 100644 index 00000000..3e4e2a8d --- /dev/null +++ b/Source/GameFunctions/BoolVector2Function.cs @@ -0,0 +1,6 @@ +using UnityEngine; + +namespace UnityAtoms +{ + public abstract class BoolVector2Function : GameFunction { } +} \ No newline at end of file diff --git a/Source/GameFunctions/BoolVector2Function.cs.meta b/Source/GameFunctions/BoolVector2Function.cs.meta new file mode 100644 index 00000000..89bd9d52 --- /dev/null +++ b/Source/GameFunctions/BoolVector2Function.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: ac5e4eb9fc86743b8aefd667985e1e6e +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Source/GameFunctions/BoolVector3Function.cs b/Source/GameFunctions/BoolVector3Function.cs new file mode 100644 index 00000000..21e4b2c5 --- /dev/null +++ b/Source/GameFunctions/BoolVector3Function.cs @@ -0,0 +1,6 @@ +using UnityEngine; + +namespace UnityAtoms +{ + public abstract class BoolVector3Function : GameFunction { } +} \ No newline at end of file diff --git a/Source/GameFunctions/BoolVector3Function.cs.meta b/Source/GameFunctions/BoolVector3Function.cs.meta new file mode 100644 index 00000000..e99ecddc --- /dev/null +++ b/Source/GameFunctions/BoolVector3Function.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 4d5b7faffa0f248a1899c54326a878bb +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Source/GameFunctions/BoolVoidFunction.cs b/Source/GameFunctions/BoolVoidFunction.cs new file mode 100644 index 00000000..78833b42 --- /dev/null +++ b/Source/GameFunctions/BoolVoidFunction.cs @@ -0,0 +1,6 @@ +using UnityEngine; + +namespace UnityAtoms +{ + public abstract class BoolVoidFunction : GameFunction { } +} \ No newline at end of file diff --git a/Source/GameFunctions/BoolVoidFunction.cs.meta b/Source/GameFunctions/BoolVoidFunction.cs.meta new file mode 100644 index 00000000..260cb01b --- /dev/null +++ b/Source/GameFunctions/BoolVoidFunction.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 0dba5a17dae464c6ebce7659f988681d +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/UnityAtoms/GameFunctions/GameObjectFunction.cs b/Source/GameFunctions/GameObjectFunction.cs similarity index 100% rename from Assets/UnityAtoms/GameFunctions/GameObjectFunction.cs rename to Source/GameFunctions/GameObjectFunction.cs diff --git a/Assets/UnityAtoms/GameFunctions/GameObjectFunction.cs.meta b/Source/GameFunctions/GameObjectFunction.cs.meta similarity index 100% rename from Assets/UnityAtoms/GameFunctions/GameObjectFunction.cs.meta rename to Source/GameFunctions/GameObjectFunction.cs.meta diff --git a/Assets/UnityAtoms/GameFunctions/GameObjectGameObjectFunction.cs b/Source/GameFunctions/GameObjectGameObjectFunction.cs similarity index 100% rename from Assets/UnityAtoms/GameFunctions/GameObjectGameObjectFunction.cs rename to Source/GameFunctions/GameObjectGameObjectFunction.cs diff --git a/Assets/UnityAtoms/GameFunctions/GameObjectGameObjectFunction.cs.meta b/Source/GameFunctions/GameObjectGameObjectFunction.cs.meta similarity index 100% rename from Assets/UnityAtoms/GameFunctions/GameObjectGameObjectFunction.cs.meta rename to Source/GameFunctions/GameObjectGameObjectFunction.cs.meta diff --git a/Assets/UnityAtoms/GameFunctions/GameObjectVector3QuaternionFunction.cs b/Source/GameFunctions/GameObjectVector3QuaternionFunction.cs similarity index 100% rename from Assets/UnityAtoms/GameFunctions/GameObjectVector3QuaternionFunction.cs rename to Source/GameFunctions/GameObjectVector3QuaternionFunction.cs diff --git a/Assets/UnityAtoms/GameFunctions/GameObjectVector3QuaternionFunction.cs.meta b/Source/GameFunctions/GameObjectVector3QuaternionFunction.cs.meta similarity index 100% rename from Assets/UnityAtoms/GameFunctions/GameObjectVector3QuaternionFunction.cs.meta rename to Source/GameFunctions/GameObjectVector3QuaternionFunction.cs.meta diff --git a/Assets/UnityAtoms/GameFunctions/IntFunction.cs b/Source/GameFunctions/IntFunction.cs similarity index 100% rename from Assets/UnityAtoms/GameFunctions/IntFunction.cs rename to Source/GameFunctions/IntFunction.cs diff --git a/Assets/UnityAtoms/GameFunctions/IntFunction.cs.meta b/Source/GameFunctions/IntFunction.cs.meta similarity index 100% rename from Assets/UnityAtoms/GameFunctions/IntFunction.cs.meta rename to Source/GameFunctions/IntFunction.cs.meta diff --git a/Assets/UnityAtoms/GameFunctions/ScriptableObjectFunction.cs b/Source/GameFunctions/ScriptableObjectFunction.cs similarity index 100% rename from Assets/UnityAtoms/GameFunctions/ScriptableObjectFunction.cs rename to Source/GameFunctions/ScriptableObjectFunction.cs diff --git a/Assets/UnityAtoms/GameFunctions/ScriptableObjectFunction.cs.meta b/Source/GameFunctions/ScriptableObjectFunction.cs.meta similarity index 100% rename from Assets/UnityAtoms/GameFunctions/ScriptableObjectFunction.cs.meta rename to Source/GameFunctions/ScriptableObjectFunction.cs.meta diff --git a/Source/GameObject.meta b/Source/GameObject.meta new file mode 100644 index 00000000..6f250ffa --- /dev/null +++ b/Source/GameObject.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: f1fd0d4eb9f694acfbd6cb39d1b0c644 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/UnityAtoms/GameActions/GameObjectAction.cs b/Source/GameObject/GameObjectAction.cs similarity index 100% rename from Assets/UnityAtoms/GameActions/GameObjectAction.cs rename to Source/GameObject/GameObjectAction.cs diff --git a/Assets/UnityAtoms/GameActions/GameObjectAction.cs.meta b/Source/GameObject/GameObjectAction.cs.meta similarity index 83% rename from Assets/UnityAtoms/GameActions/GameObjectAction.cs.meta rename to Source/GameObject/GameObjectAction.cs.meta index 013a9397..9af9835b 100644 --- a/Assets/UnityAtoms/GameActions/GameObjectAction.cs.meta +++ b/Source/GameObject/GameObjectAction.cs.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 8fff9a2eb751d448e9d6c27aef63de36 +guid: cd87b2c742d164592a13e23fde739407 MonoImporter: externalObjects: {} serializedVersion: 2 diff --git a/Source/GameObject/GameObjectEvent.cs b/Source/GameObject/GameObjectEvent.cs new file mode 100644 index 00000000..0fcc558e --- /dev/null +++ b/Source/GameObject/GameObjectEvent.cs @@ -0,0 +1,8 @@ +using UnityEngine; +using UnityAtoms.Utils; + +namespace UnityAtoms +{ + [CreateAssetMenu(menuName = "Unity Atoms/GameObject/Event", fileName = "GameObjectEvent", order = CreateAssetMenuUtils.Order.EVENT)] + public class GameObjectEvent : GameEvent { } +} \ No newline at end of file diff --git a/Assets/UnityAtoms/GameEvents/GameObjectEvent.cs.meta b/Source/GameObject/GameObjectEvent.cs.meta similarity index 83% rename from Assets/UnityAtoms/GameEvents/GameObjectEvent.cs.meta rename to Source/GameObject/GameObjectEvent.cs.meta index c652a25f..7447e700 100644 --- a/Assets/UnityAtoms/GameEvents/GameObjectEvent.cs.meta +++ b/Source/GameObject/GameObjectEvent.cs.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: df43af4c74d4840f596cbdf53d4fae4c +guid: 02f3cf42d5e7e42f7a26d55149be7170 MonoImporter: externalObjects: {} serializedVersion: 2 diff --git a/Source/GameObject/GameObjectGameObjectEvent.cs b/Source/GameObject/GameObjectGameObjectEvent.cs new file mode 100644 index 00000000..593d8675 --- /dev/null +++ b/Source/GameObject/GameObjectGameObjectEvent.cs @@ -0,0 +1,8 @@ +using UnityEngine; + +namespace UnityAtoms +{ + + [CreateAssetMenu(menuName = "Unity Atoms/GameObject/Event x 2", fileName = "GameObjectGameObjectEvent", order = CreateAssetMenuUtils.Order.EVENTx2)] + public class GameObjectGameObjectEvent : GameEvent { } +} \ No newline at end of file diff --git a/Assets/UnityAtoms/GameEvents/GameObjectGameObjectEvent.cs.meta b/Source/GameObject/GameObjectGameObjectEvent.cs.meta similarity index 83% rename from Assets/UnityAtoms/GameEvents/GameObjectGameObjectEvent.cs.meta rename to Source/GameObject/GameObjectGameObjectEvent.cs.meta index e3a52164..3b4c5637 100644 --- a/Assets/UnityAtoms/GameEvents/GameObjectGameObjectEvent.cs.meta +++ b/Source/GameObject/GameObjectGameObjectEvent.cs.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 2f6050365773f4ab69f831ecd779a3cf +guid: d798c1a12f7af47f2a39905483ec9d66 MonoImporter: externalObjects: {} serializedVersion: 2 diff --git a/Source/GameObject/GameObjectList.cs b/Source/GameObject/GameObjectList.cs new file mode 100644 index 00000000..69480a63 --- /dev/null +++ b/Source/GameObject/GameObjectList.cs @@ -0,0 +1,8 @@ +using System; +using UnityEngine; + +namespace UnityAtoms +{ + [CreateAssetMenu(menuName = "Unity Atoms/GameObject/List", fileName = "GameObjectList", order = CreateAssetMenuUtils.Order.LIST)] + public class GameObjectList : ScriptableObjectList { } +} \ No newline at end of file diff --git a/Assets/UnityAtoms/Lists/GameObjectList.cs.meta b/Source/GameObject/GameObjectList.cs.meta similarity index 83% rename from Assets/UnityAtoms/Lists/GameObjectList.cs.meta rename to Source/GameObject/GameObjectList.cs.meta index aaa4878d..8406b0d1 100644 --- a/Assets/UnityAtoms/Lists/GameObjectList.cs.meta +++ b/Source/GameObject/GameObjectList.cs.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 214e3c79802c1470683a024da81274a2 +guid: 7684ba2c18240412088be9f536f102aa MonoImporter: externalObjects: {} serializedVersion: 2 diff --git a/Assets/UnityAtoms/GameActions/GameObjectListAction.cs b/Source/GameObject/GameObjectListAction.cs similarity index 100% rename from Assets/UnityAtoms/GameActions/GameObjectListAction.cs rename to Source/GameObject/GameObjectListAction.cs diff --git a/Assets/UnityAtoms/GameActions/GameObjectListAction.cs.meta b/Source/GameObject/GameObjectListAction.cs.meta similarity index 83% rename from Assets/UnityAtoms/GameActions/GameObjectListAction.cs.meta rename to Source/GameObject/GameObjectListAction.cs.meta index c402ab66..f7486aff 100644 --- a/Assets/UnityAtoms/GameActions/GameObjectListAction.cs.meta +++ b/Source/GameObject/GameObjectListAction.cs.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: c5f22b742cdf84e90915894f010a89b4 +guid: ac161a925a7ee486295ab941c175f172 MonoImporter: externalObjects: {} serializedVersion: 2 diff --git a/Assets/UnityAtoms/GameEventListeners/GameObjectListener.cs b/Source/GameObject/GameObjectListener.cs similarity index 70% rename from Assets/UnityAtoms/GameEventListeners/GameObjectListener.cs rename to Source/GameObject/GameObjectListener.cs index 085e3458..a656f617 100644 --- a/Assets/UnityAtoms/GameEventListeners/GameObjectListener.cs +++ b/Source/GameObject/GameObjectListener.cs @@ -1,7 +1,4 @@ -using System; -using System.Collections.Generic; using UnityEngine; -using UnityEngine.Events; namespace UnityAtoms { diff --git a/Assets/UnityAtoms/GameEventListeners/GameObjectListener.cs.meta b/Source/GameObject/GameObjectListener.cs.meta similarity index 83% rename from Assets/UnityAtoms/GameEventListeners/GameObjectListener.cs.meta rename to Source/GameObject/GameObjectListener.cs.meta index 83f3ef12..f14ac232 100644 --- a/Assets/UnityAtoms/GameEventListeners/GameObjectListener.cs.meta +++ b/Source/GameObject/GameObjectListener.cs.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 4d87cec123cbf4991996eac0f92ba55d +guid: a1778d191394e41bda01316b30d62abc MonoImporter: externalObjects: {} serializedVersion: 2 diff --git a/Assets/UnityAtoms/References/GameObjectReference.cs b/Source/GameObject/GameObjectReference.cs similarity index 100% rename from Assets/UnityAtoms/References/GameObjectReference.cs rename to Source/GameObject/GameObjectReference.cs diff --git a/Assets/UnityAtoms/References/GameObjectReference.cs.meta b/Source/GameObject/GameObjectReference.cs.meta similarity index 83% rename from Assets/UnityAtoms/References/GameObjectReference.cs.meta rename to Source/GameObject/GameObjectReference.cs.meta index 331d02da..98a214f2 100644 --- a/Assets/UnityAtoms/References/GameObjectReference.cs.meta +++ b/Source/GameObject/GameObjectReference.cs.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 18fea8c8b2d2c49639237d712284a94d +guid: 8d496c5a2b2434db0b3d8c7a5bb798cd MonoImporter: externalObjects: {} serializedVersion: 2 diff --git a/Source/GameObject/GameObjectVariable.cs b/Source/GameObject/GameObjectVariable.cs new file mode 100644 index 00000000..fd94cc53 --- /dev/null +++ b/Source/GameObject/GameObjectVariable.cs @@ -0,0 +1,13 @@ +using UnityEngine; + +namespace UnityAtoms +{ + [CreateAssetMenu(menuName = "Unity Atoms/GameObject/Variable", fileName = "GameObjectVariable", order = CreateAssetMenuUtils.Order.VARIABLE)] + public class GameObjectVariable : ScriptableObjectVariable + { + protected override bool AreEqual(GameObject first, GameObject second) + { + return (first == null && second == null) || first != null && second != null && first.GetInstanceID() == second.GetInstanceID(); + } + } +} \ No newline at end of file diff --git a/Assets/UnityAtoms/Variables/GameObjectVariable.cs.meta b/Source/GameObject/GameObjectVariable.cs.meta similarity index 83% rename from Assets/UnityAtoms/Variables/GameObjectVariable.cs.meta rename to Source/GameObject/GameObjectVariable.cs.meta index 7ef41ea9..9e1b3f28 100644 --- a/Assets/UnityAtoms/Variables/GameObjectVariable.cs.meta +++ b/Source/GameObject/GameObjectVariable.cs.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 0cfa65aaf5a834730b2a7c3774f80a1e +guid: 903a974d39f7a48088603c44382b463b MonoImporter: externalObjects: {} serializedVersion: 2 diff --git a/Source/GameObject/GetUnusedGameObject.cs b/Source/GameObject/GetUnusedGameObject.cs new file mode 100644 index 00000000..f670ec52 --- /dev/null +++ b/Source/GameObject/GetUnusedGameObject.cs @@ -0,0 +1,33 @@ +using System.Collections; +using System.Collections.Generic; +using UnityEngine; +using UnityAtoms.Extensions; + +namespace UnityAtoms +{ + /* Gets an unused GameObject from the GameObjectList. If an GameObject is used or not is determined by IsUsed GameFunction. + * If no unused GameObject is found a new one is instantiated and added to the GameObjectList. + */ + [CreateAssetMenu(menuName = "Unity Atoms/GameObject/Get Unused GameObject (GameObject - (V3, Quat))", fileName = "GetUnusedGameObject")] + public class GetUnusedGameObject : GameObjectVector3QuaternionFunction + { + [SerializeField] + private GameObjectList List = null; + + [SerializeField] + private GameObject Prefab = null; + + [SerializeField] + private BoolGameObjectFunction IsNotUsed = null; + + public override GameObject Call(Vector3 position, Quaternion quaternion) + { + if (IsNotUsed == null) + { + Debug.LogWarning("IsUsed must be defined!"); + } + + return List.List.GetOrInstantiate(Prefab, position, quaternion, IsNotUsed.Call); + } + } +} diff --git a/Assets/UnityAtoms/GameFunctions/GetUnusedGameObject/GetUnusedGameObject.cs.meta b/Source/GameObject/GetUnusedGameObject.cs.meta similarity index 83% rename from Assets/UnityAtoms/GameFunctions/GetUnusedGameObject/GetUnusedGameObject.cs.meta rename to Source/GameObject/GetUnusedGameObject.cs.meta index 1dad90dd..9dbb7e2f 100644 --- a/Assets/UnityAtoms/GameFunctions/GetUnusedGameObject/GetUnusedGameObject.cs.meta +++ b/Source/GameObject/GetUnusedGameObject.cs.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: f1cc797b47a8a41398f288e87a83447d +guid: 2e261fe650dc74e089870e954ba8abf0 MonoImporter: externalObjects: {} serializedVersion: 2 diff --git a/Source/GameObject/SetGameObjectVariableValue.cs b/Source/GameObject/SetGameObjectVariableValue.cs new file mode 100644 index 00000000..f29df947 --- /dev/null +++ b/Source/GameObject/SetGameObjectVariableValue.cs @@ -0,0 +1,7 @@ +using UnityEngine; + +namespace UnityAtoms +{ + [CreateAssetMenu(menuName = "Unity Atoms/GameObject/Set Variable", fileName = "SetGameObjectVariableValueAction", order = CreateAssetMenuUtils.Order.SET_VARIABLE)] + public class SetGameObjectVariableValue : SetVariableValue { } +} \ No newline at end of file diff --git a/Assets/UnityAtoms/GameActions/SetVariableValue/SetGameObjectVariableValue.cs.meta b/Source/GameObject/SetGameObjectVariableValue.cs.meta similarity index 83% rename from Assets/UnityAtoms/GameActions/SetVariableValue/SetGameObjectVariableValue.cs.meta rename to Source/GameObject/SetGameObjectVariableValue.cs.meta index 738cf437..da30089c 100644 --- a/Assets/UnityAtoms/GameActions/SetVariableValue/SetGameObjectVariableValue.cs.meta +++ b/Source/GameObject/SetGameObjectVariableValue.cs.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: ddc8def6d34fe47fb944b62948b25dfc +guid: 464101c3d99d44cc1bdee5a8e2d8abe7 MonoImporter: externalObjects: {} serializedVersion: 2 diff --git a/Source/GameObject/UnityGameObjectEvent.cs b/Source/GameObject/UnityGameObjectEvent.cs new file mode 100644 index 00000000..f7b3638b --- /dev/null +++ b/Source/GameObject/UnityGameObjectEvent.cs @@ -0,0 +1,9 @@ +using System; +using UnityEngine.Events; +using UnityEngine; + +namespace UnityAtoms +{ + [Serializable] + public class UnityGameObjectEvent : UnityEvent { } +} \ No newline at end of file diff --git a/Source/GameObject/UnityGameObjectEvent.cs.meta b/Source/GameObject/UnityGameObjectEvent.cs.meta new file mode 100644 index 00000000..6a781d8d --- /dev/null +++ b/Source/GameObject/UnityGameObjectEvent.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 4589c4813d08e45528aec5291bc620e8 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Source/Int.meta b/Source/Int.meta new file mode 100644 index 00000000..c78e25e9 --- /dev/null +++ b/Source/Int.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: e84b27e4260c74c6192ce32653e2a639 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Source/Int/ConditionalIntAction.cs b/Source/Int/ConditionalIntAction.cs new file mode 100644 index 00000000..b4871d0b --- /dev/null +++ b/Source/Int/ConditionalIntAction.cs @@ -0,0 +1,20 @@ +using System; +using UnityEngine; + +namespace UnityAtoms +{ + [Serializable] + public class ConditionalIntGameActionHelper : ConditionalGameActionHelper { } + + [CreateAssetMenu(menuName = "Unity Atoms/Int/Conditional", fileName = "ConditionalIntAction", order = CreateAssetMenuUtils.Order.CONDITIONAL)] + public class ConditionalIntAction : IntAction + { + [SerializeField] + private ConditionalIntGameActionHelper Conditional = null; + + public override void Do(int t1) + { + Conditional.Do(t1); + } + } +} diff --git a/Source/Int/ConditionalIntAction.cs.meta b/Source/Int/ConditionalIntAction.cs.meta new file mode 100644 index 00000000..e8116f27 --- /dev/null +++ b/Source/Int/ConditionalIntAction.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: e3f9d585a245e44f28d63acad8ab9a07 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/UnityAtoms/GameActions/IntAction.cs b/Source/Int/IntAction.cs similarity index 100% rename from Assets/UnityAtoms/GameActions/IntAction.cs rename to Source/Int/IntAction.cs diff --git a/Assets/UnityAtoms/GameActions/IntAction.cs.meta b/Source/Int/IntAction.cs.meta similarity index 83% rename from Assets/UnityAtoms/GameActions/IntAction.cs.meta rename to Source/Int/IntAction.cs.meta index adc756df..199066c7 100644 --- a/Assets/UnityAtoms/GameActions/IntAction.cs.meta +++ b/Source/Int/IntAction.cs.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 710add4913ab9499b867fbe4305e3f02 +guid: 731b44f469d3e4565b18b4a7a3e5222b MonoImporter: externalObjects: {} serializedVersion: 2 diff --git a/Source/Int/IntConstant.cs b/Source/Int/IntConstant.cs new file mode 100644 index 00000000..a3d4d79a --- /dev/null +++ b/Source/Int/IntConstant.cs @@ -0,0 +1,7 @@ +using UnityEngine; + +namespace UnityAtoms +{ + [CreateAssetMenu(menuName = "Unity Atoms/Int/Constant", fileName = "IntConstant", order = CreateAssetMenuUtils.Order.CONSTANT)] + public class IntConstant : ScriptableObjectVariableBase { } +} \ No newline at end of file diff --git a/Assets/UnityAtoms/Constants/IntConstant.cs.meta b/Source/Int/IntConstant.cs.meta similarity index 83% rename from Assets/UnityAtoms/Constants/IntConstant.cs.meta rename to Source/Int/IntConstant.cs.meta index 3a976b8a..4dd9ab8e 100644 --- a/Assets/UnityAtoms/Constants/IntConstant.cs.meta +++ b/Source/Int/IntConstant.cs.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 1179a197d01af4c9fb1825e9235f392a +guid: be00aa7c2423344849366e0e0b258204 MonoImporter: externalObjects: {} serializedVersion: 2 diff --git a/Source/Int/IntEvent.cs b/Source/Int/IntEvent.cs new file mode 100644 index 00000000..a4565003 --- /dev/null +++ b/Source/Int/IntEvent.cs @@ -0,0 +1,7 @@ +using UnityEngine; + +namespace UnityAtoms +{ + [CreateAssetMenu(menuName = "Unity Atoms/Int/Event", fileName = "IntEvent", order = CreateAssetMenuUtils.Order.EVENT)] + public class IntEvent : GameEvent { } +} \ No newline at end of file diff --git a/Assets/UnityAtoms/GameEvents/IntEvent.cs.meta b/Source/Int/IntEvent.cs.meta similarity index 83% rename from Assets/UnityAtoms/GameEvents/IntEvent.cs.meta rename to Source/Int/IntEvent.cs.meta index f1887f34..9c007f02 100644 --- a/Assets/UnityAtoms/GameEvents/IntEvent.cs.meta +++ b/Source/Int/IntEvent.cs.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 1557a2062b49d4fa4bb5ae998e0b2031 +guid: c634fa7b8a2a440a09547cfb8715387c MonoImporter: externalObjects: {} serializedVersion: 2 diff --git a/Source/Int/IntIntEvent.cs b/Source/Int/IntIntEvent.cs new file mode 100644 index 00000000..715d1348 --- /dev/null +++ b/Source/Int/IntIntEvent.cs @@ -0,0 +1,8 @@ +using UnityEngine; + +namespace UnityAtoms +{ + + [CreateAssetMenu(menuName = "Unity Atoms/Int/Event x 2", fileName = "IntIntEvent", order = CreateAssetMenuUtils.Order.EVENTx2)] + public class IntIntEvent : GameEvent { } +} \ No newline at end of file diff --git a/Assets/UnityAtoms/GameEvents/IntIntEvent.cs.meta b/Source/Int/IntIntEvent.cs.meta similarity index 83% rename from Assets/UnityAtoms/GameEvents/IntIntEvent.cs.meta rename to Source/Int/IntIntEvent.cs.meta index 42ab5a69..d9e8f1ec 100644 --- a/Assets/UnityAtoms/GameEvents/IntIntEvent.cs.meta +++ b/Source/Int/IntIntEvent.cs.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 3aa113575420643978d6de4dd371a7c6 +guid: 78f13703128164953bfcb1b9e6282f3c MonoImporter: externalObjects: {} serializedVersion: 2 diff --git a/Source/Int/IntList.cs b/Source/Int/IntList.cs new file mode 100644 index 00000000..13e5f9c2 --- /dev/null +++ b/Source/Int/IntList.cs @@ -0,0 +1,7 @@ +using UnityEngine; + +namespace UnityAtoms +{ + [CreateAssetMenu(menuName = "Unity Atoms/Int/List", fileName = "IntList", order = CreateAssetMenuUtils.Order.LIST)] + public class IntList : ScriptableObjectList { } +} \ No newline at end of file diff --git a/Assets/UnityAtoms/Lists/IntList.cs.meta b/Source/Int/IntList.cs.meta similarity index 83% rename from Assets/UnityAtoms/Lists/IntList.cs.meta rename to Source/Int/IntList.cs.meta index dbdc2f8f..44faaf85 100644 --- a/Assets/UnityAtoms/Lists/IntList.cs.meta +++ b/Source/Int/IntList.cs.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 78793a7bfb8e2413da93a9bbcc469f8d +guid: cfab3ac8d5b7a404490e7ddd84a5490d MonoImporter: externalObjects: {} serializedVersion: 2 diff --git a/Assets/UnityAtoms/GameEventListeners/IntListener.cs b/Source/Int/IntListener.cs similarity index 55% rename from Assets/UnityAtoms/GameEventListeners/IntListener.cs rename to Source/Int/IntListener.cs index 4d1f489b..87bcdf4f 100644 --- a/Assets/UnityAtoms/GameEventListeners/IntListener.cs +++ b/Source/Int/IntListener.cs @@ -1,8 +1,3 @@ -using System; -using System.Collections.Generic; -using UnityEngine.Events; -using UnityEngine; - namespace UnityAtoms { public class IntListener : GameEventListener { } diff --git a/Assets/UnityAtoms/GameEventListeners/IntListener.cs.meta b/Source/Int/IntListener.cs.meta similarity index 83% rename from Assets/UnityAtoms/GameEventListeners/IntListener.cs.meta rename to Source/Int/IntListener.cs.meta index b1748f31..ca237b11 100644 --- a/Assets/UnityAtoms/GameEventListeners/IntListener.cs.meta +++ b/Source/Int/IntListener.cs.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 91b5aee566a354311b8e8c09dbd33fc2 +guid: e564c43d8cd6f404fbf20034291d3354 MonoImporter: externalObjects: {} serializedVersion: 2 diff --git a/Assets/UnityAtoms/References/IntReference.cs b/Source/Int/IntReference.cs similarity index 100% rename from Assets/UnityAtoms/References/IntReference.cs rename to Source/Int/IntReference.cs diff --git a/Assets/UnityAtoms/References/IntReference.cs.meta b/Source/Int/IntReference.cs.meta similarity index 83% rename from Assets/UnityAtoms/References/IntReference.cs.meta rename to Source/Int/IntReference.cs.meta index 0cbf1c71..2fa8f08b 100644 --- a/Assets/UnityAtoms/References/IntReference.cs.meta +++ b/Source/Int/IntReference.cs.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 73d40c805960e45749e8a82340c9ea92 +guid: a22a621a780984f6e9a70be1acd8f757 MonoImporter: externalObjects: {} serializedVersion: 2 diff --git a/Assets/UnityAtoms/Variables/IntVariable.cs b/Source/Int/IntVariable.cs similarity index 66% rename from Assets/UnityAtoms/Variables/IntVariable.cs rename to Source/Int/IntVariable.cs index efcdd1b4..e404de22 100644 --- a/Assets/UnityAtoms/Variables/IntVariable.cs +++ b/Source/Int/IntVariable.cs @@ -2,9 +2,8 @@ namespace UnityAtoms { - [CreateAssetMenu(menuName = "Unity Atoms/Variables/Int", fileName = "IntVariable", order = 0)] - public class IntVariable : EquatableScriptableObjectVariable, - IWithApplyChange + [CreateAssetMenu(menuName = "Unity Atoms/Int/Variable", fileName = "IntVariable", order = CreateAssetMenuUtils.Order.VARIABLE)] + public class IntVariable : EquatableScriptableObjectVariable, IWithApplyChange { public bool ApplyChange(int amount) { diff --git a/Assets/UnityAtoms/Variables/IntVariable.cs.meta b/Source/Int/IntVariable.cs.meta similarity index 83% rename from Assets/UnityAtoms/Variables/IntVariable.cs.meta rename to Source/Int/IntVariable.cs.meta index 6ee27b84..b7a5449c 100644 --- a/Assets/UnityAtoms/Variables/IntVariable.cs.meta +++ b/Source/Int/IntVariable.cs.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: b17ea82f8224441299e0d1a63841f64f +guid: f64af2ed99cb146358b8752c3e393fcc MonoImporter: externalObjects: {} serializedVersion: 2 diff --git a/Source/Int/SetIntVariableValue.cs b/Source/Int/SetIntVariableValue.cs new file mode 100644 index 00000000..299399f7 --- /dev/null +++ b/Source/Int/SetIntVariableValue.cs @@ -0,0 +1,7 @@ +using UnityEngine; + +namespace UnityAtoms +{ + [CreateAssetMenu(menuName = "Unity Atoms/Int/Set Variable", fileName = "SetIntVariableValueAction", order = CreateAssetMenuUtils.Order.SET_VARIABLE)] + public class SetIntVariableValue : SetVariableValue { } +} \ No newline at end of file diff --git a/Assets/UnityAtoms/GameActions/SetVariableValue/SetIntVariableValue.cs.meta b/Source/Int/SetIntVariableValue.cs.meta similarity index 83% rename from Assets/UnityAtoms/GameActions/SetVariableValue/SetIntVariableValue.cs.meta rename to Source/Int/SetIntVariableValue.cs.meta index e9082277..93663e3f 100644 --- a/Assets/UnityAtoms/GameActions/SetVariableValue/SetIntVariableValue.cs.meta +++ b/Source/Int/SetIntVariableValue.cs.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 539a8189c31354a17be5a7fffc9a79c1 +guid: 95d65c506b2924c1aa582cd252c7ed17 MonoImporter: externalObjects: {} serializedVersion: 2 diff --git a/Source/Int/UnityIntEvent.cs b/Source/Int/UnityIntEvent.cs new file mode 100644 index 00000000..592cf6f2 --- /dev/null +++ b/Source/Int/UnityIntEvent.cs @@ -0,0 +1,8 @@ +using System; +using UnityEngine.Events; + +namespace UnityAtoms +{ + [Serializable] + public class UnityIntEvent : UnityEvent { } +} \ No newline at end of file diff --git a/Source/Int/UnityIntEvent.cs.meta b/Source/Int/UnityIntEvent.cs.meta new file mode 100644 index 00000000..a69d8ced --- /dev/null +++ b/Source/Int/UnityIntEvent.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 5457e4fc16db14d9eb1bd5bb33a37977 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Source/Mobile.meta b/Source/Mobile.meta new file mode 100644 index 00000000..1913ad06 --- /dev/null +++ b/Source/Mobile.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 2c16c433cd15740c68d69e34653c10cb +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Source/Mobile/TouchUserInput.meta b/Source/Mobile/TouchUserInput.meta new file mode 100644 index 00000000..5d1429fa --- /dev/null +++ b/Source/Mobile/TouchUserInput.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: d78380e1af2604a039d0d81a9e22bfa6 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Source/Mobile/TouchUserInput/BoolTouchUserInputFunction.cs b/Source/Mobile/TouchUserInput/BoolTouchUserInputFunction.cs new file mode 100644 index 00000000..bfefb4e5 --- /dev/null +++ b/Source/Mobile/TouchUserInput/BoolTouchUserInputFunction.cs @@ -0,0 +1,5 @@ +namespace UnityAtoms.Mobile +{ + public abstract class BoolTouchUserInputFunction : GameFunction { } +} + diff --git a/Source/Mobile/TouchUserInput/BoolTouchUserInputFunction.cs.meta b/Source/Mobile/TouchUserInput/BoolTouchUserInputFunction.cs.meta new file mode 100644 index 00000000..1c8bc4b2 --- /dev/null +++ b/Source/Mobile/TouchUserInput/BoolTouchUserInputFunction.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: a434c7f1fcb7344a894f6783ef814244 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Source/Mobile/TouchUserInput/ConditionalTouchUserInputAction.cs b/Source/Mobile/TouchUserInput/ConditionalTouchUserInputAction.cs new file mode 100644 index 00000000..483b3d7f --- /dev/null +++ b/Source/Mobile/TouchUserInput/ConditionalTouchUserInputAction.cs @@ -0,0 +1,21 @@ +using System; +using UnityEngine; + +namespace UnityAtoms.Mobile +{ + [Serializable] + public class ConditionalTouchUserInputGameActionHelper : ConditionalGameActionHelper { } + + [CreateAssetMenu(menuName = "Unity Atoms/Mobile/Touch User Input/Conditional", fileName = "ConditionalTouchUserInputAction", order = CreateAssetMenuUtils.Order.CONDITIONAL)] + public class ConditionalTouchUserInputAction : TouchUserInputAction + { + [SerializeField] + public ConditionalTouchUserInputGameActionHelper Conditional = null; + + public override void Do(TouchUserInput t1) + { + Conditional.Do(t1); + } + } +} + diff --git a/Source/Mobile/TouchUserInput/ConditionalTouchUserInputAction.cs.meta b/Source/Mobile/TouchUserInput/ConditionalTouchUserInputAction.cs.meta new file mode 100644 index 00000000..655f7161 --- /dev/null +++ b/Source/Mobile/TouchUserInput/ConditionalTouchUserInputAction.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 2dcef1b7859c74cfc9f4dcf20fd44dd1 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Source/Mobile/TouchUserInput/DetectTap.cs b/Source/Mobile/TouchUserInput/DetectTap.cs new file mode 100644 index 00000000..8f2de745 --- /dev/null +++ b/Source/Mobile/TouchUserInput/DetectTap.cs @@ -0,0 +1,102 @@ +using System; +using System.Collections; +using System.Collections.Generic; +using UnityEngine; + +namespace UnityAtoms.Mobile +{ + [Serializable] + public class DetectTap : IGameEventListener + { + [SerializeField] + private Timer FirstTapTimer = null; + [SerializeField] + private Timer SecondTapTimer = null; + [SerializeField] + private FloatReference MaxTimeBetweenTaps = null; + [SerializeField] + private FloatReference MaxDistanceBetweenTaps = null; + [SerializeField] + private FloatReference MaxMovementToCountAsTap = null; + [SerializeField] + private TouchUserInputGameEvent OnTapDetectedEvent = null; + [SerializeField] + private TouchUserInputGameEvent OnDoubleTapDetectedEvent = null; + + private Vector2 inputPosFirstTapDown; + + private void OnEnable() + { + FirstTapTimer.Stop(); + SecondTapTimer.Stop(); + } + + public void OnEventRaised(TouchUserInput touchUserInput) + { + if (!IsPotentialDoubleTapInProgress()) + { + FirstTapTimer.Stop(); + SecondTapTimer.Stop(); + } + + if (touchUserInput.InputState == TouchUserInput.State.Down && CanStartDoubleTap()) + { + inputPosFirstTapDown = touchUserInput.InputPos; + FirstTapTimer.Start(); + } + else if (touchUserInput.InputState == TouchUserInput.State.Drag && FirstTapTimer.IsStarted() && Vector2.Distance(touchUserInput.InputPos, inputPosFirstTapDown) > MaxMovementToCountAsTap.Value) + { + FirstTapTimer.Stop(); + } + else if (touchUserInput.InputState == TouchUserInput.State.Up && WaitingForFinishingFirstTap()) + { + if (FirstTapTimer.GetElapsedTime() <= MaxTimeBetweenTaps.Value) + { + if (OnTapDetectedEvent != null) + { + OnTapDetectedEvent.Raise(touchUserInput); + } + SecondTapTimer.Start(); + } + FirstTapTimer.Stop(); + } + else if (touchUserInput.InputState == TouchUserInput.State.Down && WaitingForSecondTap()) + { + if (Vector2.Distance(touchUserInput.InputPos, inputPosFirstTapDown) <= MaxDistanceBetweenTaps.Value && SecondTapTimer.GetElapsedTime() <= MaxTimeBetweenTaps.Value) + { + if (OnDoubleTapDetectedEvent != null) + { + OnDoubleTapDetectedEvent.Raise(touchUserInput); // OPEN POINT: Should we raise event on state up or down? + } + } + SecondTapTimer.Stop(); + } + } + + private bool CanStartDoubleTap() + { + return !SecondTapTimer.IsStarted(); + } + + private bool WaitingForFinishingFirstTap() + { + return FirstTapTimer.IsStarted(); + } + + private bool WaitingForSecondTap() + { + return SecondTapTimer.IsStarted(); + } + + public bool IsPotentialDoubleTapInProgress() + { + return (FirstTapTimer.IsStarted() && FirstTapTimer.GetElapsedTime() <= MaxTimeBetweenTaps.Value) || (SecondTapTimer.IsStarted() && SecondTapTimer.GetElapsedTime() <= MaxTimeBetweenTaps.Value); + } + + public bool InUse() + { + return FirstTapTimer != null && SecondTapTimer != null && OnDoubleTapDetectedEvent != null; + } + } + +} diff --git a/Source/Mobile/TouchUserInput/DetectTap.cs.meta b/Source/Mobile/TouchUserInput/DetectTap.cs.meta new file mode 100644 index 00000000..6c8efe93 --- /dev/null +++ b/Source/Mobile/TouchUserInput/DetectTap.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 56918c4def57140ce9d8e6825e744797 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Source/Mobile/TouchUserInput/TouchUserInput.cs b/Source/Mobile/TouchUserInput/TouchUserInput.cs new file mode 100644 index 00000000..b1f93655 --- /dev/null +++ b/Source/Mobile/TouchUserInput/TouchUserInput.cs @@ -0,0 +1,38 @@ +using System; +using UnityEngine; + +namespace UnityAtoms.Mobile +{ + [Serializable] + public struct TouchUserInput + { + public enum State + { + None, + Down, + Drag, + Up + }; + + public State InputState; + public Vector2 InputPos; + public Vector2 InputPosLastFrame; + public Vector2 InputPosLastDown; + public Vector2 InputWorldPos { get { return Camera.main.ScreenToWorldPoint(InputPos); } } + public Vector2 InputWorldPosLastFrame { get { return Camera.main.ScreenToWorldPoint(InputPosLastFrame); } } + public Vector2 InputWorldPosLastDown { get { return Camera.main.ScreenToWorldPoint(InputPosLastDown); } } + + public TouchUserInput(State inputState, Vector2 inputPos, Vector2 inputPosLastFrame, Vector2 inputPosLastDown) + { + this.InputState = inputState; + this.InputPos = inputPos; + this.InputPosLastFrame = inputPosLastFrame; + this.InputPosLastDown = inputPosLastDown; + } + + public bool Equals(TouchUserInput other) + { + return this.InputState == other.InputState && this.InputWorldPos == other.InputWorldPos && this.InputWorldPosLastFrame == other.InputWorldPosLastFrame; + } + } +} diff --git a/Source/Mobile/TouchUserInput/TouchUserInput.cs.meta b/Source/Mobile/TouchUserInput/TouchUserInput.cs.meta new file mode 100644 index 00000000..4fc459f2 --- /dev/null +++ b/Source/Mobile/TouchUserInput/TouchUserInput.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 19b766b9ed39b4174bfc33a448d03818 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Source/Mobile/TouchUserInput/TouchUserInputAction.cs b/Source/Mobile/TouchUserInput/TouchUserInputAction.cs new file mode 100644 index 00000000..016c0671 --- /dev/null +++ b/Source/Mobile/TouchUserInput/TouchUserInputAction.cs @@ -0,0 +1,4 @@ +namespace UnityAtoms.Mobile +{ + public abstract class TouchUserInputAction : GameAction { } +} diff --git a/Source/Mobile/TouchUserInput/TouchUserInputAction.cs.meta b/Source/Mobile/TouchUserInput/TouchUserInputAction.cs.meta new file mode 100644 index 00000000..f88872fd --- /dev/null +++ b/Source/Mobile/TouchUserInput/TouchUserInputAction.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 6c8d923b406d749d5aac0877f726a84f +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Source/Mobile/TouchUserInput/TouchUserInputGameEvent.cs b/Source/Mobile/TouchUserInput/TouchUserInputGameEvent.cs new file mode 100644 index 00000000..a7c6d31a --- /dev/null +++ b/Source/Mobile/TouchUserInput/TouchUserInputGameEvent.cs @@ -0,0 +1,7 @@ +using UnityEngine; + +namespace UnityAtoms.Mobile +{ + [CreateAssetMenu(menuName = "Unity Atoms/Mobile/Touch User Input/Event", fileName = "TouchUserInputEvent", order = CreateAssetMenuUtils.Order.EVENT)] + public class TouchUserInputGameEvent : GameEvent { } +} diff --git a/Source/Mobile/TouchUserInput/TouchUserInputGameEvent.cs.meta b/Source/Mobile/TouchUserInput/TouchUserInputGameEvent.cs.meta new file mode 100644 index 00000000..ffd1d419 --- /dev/null +++ b/Source/Mobile/TouchUserInput/TouchUserInputGameEvent.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 8fd3d045d1f8f4da581a442af690fcbd +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Source/Mobile/TouchUserInput/TouchUserInputListener.cs b/Source/Mobile/TouchUserInput/TouchUserInputListener.cs new file mode 100644 index 00000000..48a77baa --- /dev/null +++ b/Source/Mobile/TouchUserInput/TouchUserInputListener.cs @@ -0,0 +1,5 @@ +namespace UnityAtoms.Mobile +{ + public class TouchUserInputListener : GameEventListener { } +} + diff --git a/Source/Mobile/TouchUserInput/TouchUserInputListener.cs.meta b/Source/Mobile/TouchUserInput/TouchUserInputListener.cs.meta new file mode 100644 index 00000000..6527acbb --- /dev/null +++ b/Source/Mobile/TouchUserInput/TouchUserInputListener.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 488cdc56cd2be481f998c8f499fbd33d +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Source/Mobile/TouchUserInput/TouchUserInputTouchUserInputAction.cs b/Source/Mobile/TouchUserInput/TouchUserInputTouchUserInputAction.cs new file mode 100644 index 00000000..e15b838f --- /dev/null +++ b/Source/Mobile/TouchUserInput/TouchUserInputTouchUserInputAction.cs @@ -0,0 +1,4 @@ +namespace UnityAtoms.Mobile +{ + public abstract class TouchUserInputTouchUserInputAction : GameAction { } +} diff --git a/Source/Mobile/TouchUserInput/TouchUserInputTouchUserInputAction.cs.meta b/Source/Mobile/TouchUserInput/TouchUserInputTouchUserInputAction.cs.meta new file mode 100644 index 00000000..e1cdd538 --- /dev/null +++ b/Source/Mobile/TouchUserInput/TouchUserInputTouchUserInputAction.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: c44f990367d144fc2b160ca4c763d501 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Source/Mobile/TouchUserInput/TouchUserInputTouchUserInputGameEvent.cs b/Source/Mobile/TouchUserInput/TouchUserInputTouchUserInputGameEvent.cs new file mode 100644 index 00000000..453b117e --- /dev/null +++ b/Source/Mobile/TouchUserInput/TouchUserInputTouchUserInputGameEvent.cs @@ -0,0 +1,7 @@ +using UnityEngine; + +namespace UnityAtoms.Mobile +{ + [CreateAssetMenu(menuName = "Unity Atoms/Mobile/Touch User Input/Event x 2", fileName = "TouchUserInputx2Event", order = CreateAssetMenuUtils.Order.EVENTx2)] + public class TouchUserInputTouchUserInputGameEvent : GameEvent { } +} diff --git a/Source/Mobile/TouchUserInput/TouchUserInputTouchUserInputGameEvent.cs.meta b/Source/Mobile/TouchUserInput/TouchUserInputTouchUserInputGameEvent.cs.meta new file mode 100644 index 00000000..6eb62a29 --- /dev/null +++ b/Source/Mobile/TouchUserInput/TouchUserInputTouchUserInputGameEvent.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: c374fd767f96a47af966b54ac824fe40 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Source/Mobile/TouchUserInput/TouchUserInputTouchUserInputListener.cs b/Source/Mobile/TouchUserInput/TouchUserInputTouchUserInputListener.cs new file mode 100644 index 00000000..9cf3a989 --- /dev/null +++ b/Source/Mobile/TouchUserInput/TouchUserInputTouchUserInputListener.cs @@ -0,0 +1,5 @@ +namespace UnityAtoms.Mobile +{ + public class TouchUserInputTouchUserInputListener : GameEventListener { } +} + diff --git a/Source/Mobile/TouchUserInput/TouchUserInputTouchUserInputListener.cs.meta b/Source/Mobile/TouchUserInput/TouchUserInputTouchUserInputListener.cs.meta new file mode 100644 index 00000000..a53e87a2 --- /dev/null +++ b/Source/Mobile/TouchUserInput/TouchUserInputTouchUserInputListener.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: c38d084c918904237bf9067ccc7e64d6 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Source/Mobile/TouchUserInput/TouchUserInputVariable.cs b/Source/Mobile/TouchUserInput/TouchUserInputVariable.cs new file mode 100644 index 00000000..182932e9 --- /dev/null +++ b/Source/Mobile/TouchUserInput/TouchUserInputVariable.cs @@ -0,0 +1,38 @@ +using UnityEngine; + +namespace UnityAtoms.Mobile +{ + [CreateAssetMenu(menuName = "Unity Atoms/Mobile/Touch User Input/Variable", fileName = "TouchUserInputVariable", order = CreateAssetMenuUtils.Order.VARIABLE)] + public class TouchUserInputVariable : ScriptableObjectVariable + { + [SerializeField] + private DetectTap DetectTap = null; + + private void OnEnable() + { + if (DetectTap.InUse()) + { + Changed.RegisterListener(DetectTap); + } + } + + private void OnDisable() + { + if (DetectTap.InUse()) + { + Changed.UnregisterListener(DetectTap); + } + } + + public bool IsPotentialDoubleTapInProgress() + { + return DetectTap != null && DetectTap.InUse() && DetectTap.IsPotentialDoubleTapInProgress(); + } + + protected override bool AreEqual(TouchUserInput first, TouchUserInput second) + { + return first.Equals(second); + } + } + +} diff --git a/Source/Mobile/TouchUserInput/TouchUserInputVariable.cs.meta b/Source/Mobile/TouchUserInput/TouchUserInputVariable.cs.meta new file mode 100644 index 00000000..47b3c608 --- /dev/null +++ b/Source/Mobile/TouchUserInput/TouchUserInputVariable.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 0811f97aad3d14146bf978756650c964 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Source/Mobile/TouchUserInput/UnityTouchUserInputEvent.cs b/Source/Mobile/TouchUserInput/UnityTouchUserInputEvent.cs new file mode 100644 index 00000000..2860b34a --- /dev/null +++ b/Source/Mobile/TouchUserInput/UnityTouchUserInputEvent.cs @@ -0,0 +1,12 @@ +using System; +using UnityEngine; +using UnityEngine.Events; + +namespace UnityAtoms.Mobile +{ + [Serializable] + public class UnityTouchUserInputEvent : UnityEvent { } + + [Serializable] + public class UnityTouchUserInputTouchUserInputEvent : UnityEvent { } +} \ No newline at end of file diff --git a/Source/Mobile/TouchUserInput/UnityTouchUserInputEvent.cs.meta b/Source/Mobile/TouchUserInput/UnityTouchUserInputEvent.cs.meta new file mode 100644 index 00000000..8581e067 --- /dev/null +++ b/Source/Mobile/TouchUserInput/UnityTouchUserInputEvent.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: e2b1a453c1dd14a0390aa7b09ec5f42d +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Source/Mobile/TouchUserInput/UpdateTouchUserInput.cs b/Source/Mobile/TouchUserInput/UpdateTouchUserInput.cs new file mode 100644 index 00000000..301e5864 --- /dev/null +++ b/Source/Mobile/TouchUserInput/UpdateTouchUserInput.cs @@ -0,0 +1,68 @@ +using UnityEngine; + +namespace UnityAtoms.Mobile +{ + /* Updates the TouchUserInputVariable on every Update tick. Meant to be placed on a OnUpdateMonoHook. + */ + [CreateAssetMenu(menuName = "Unity Atoms/Mobile/Touch User Input/Update (OnUpdateMonoHook)", fileName = "UpdateTouchUserInputVariable")] + public class UpdateTouchUserInput : VoidAction + { + public TouchUserInputVariable TouchUserInputVariable; + + private TouchUserInput.State inputState = TouchUserInput.State.None; + private Vector2 inputPos = Vector2.zero; + private Vector2 inputPosLastFrame = Vector2.zero; + private Vector2 inputPosLastDown = Vector2.zero; + + public override void Do() + { +#if (UNITY_ANDROID || UNITY_IOS || UNITY_IPHONE) && !UNITY_EDITOR + if (Input.touchCount > 0) + { + inputPos = Input.GetTouch(0).position; + if (Input.GetTouch(0).phase == TouchPhase.Began) + { + inputPosLastDown = inputPos; + inputState = TouchUserInput.State.Down; + } + else if (Input.GetTouch(0).phase == TouchPhase.Ended) + { + inputState = TouchUserInput.State.Up; + } + else + { + inputState = TouchUserInput.State.Drag; + } + } + else + { + inputPos = Vector2.zero; + inputState = TouchUserInput.State.None; + } +#elif UNITY_EDITOR || UNITY_STANDALONE + inputPos = Input.mousePosition; + + if (Input.GetMouseButtonDown(0)) + { + inputPosLastDown = inputPos; + inputState = TouchUserInput.State.Down; + } + else if (Input.GetMouseButtonUp(0)) + { + inputState = TouchUserInput.State.Up; + } + else if (Input.GetMouseButton(0)) + { + inputState = TouchUserInput.State.Drag; + } + else + { + inputState = TouchUserInput.State.None; + } +#endif + + TouchUserInputVariable.SetValue(new TouchUserInput(inputState, inputPos, inputPosLastFrame, inputPosLastDown)); + inputPosLastFrame = inputPos; + } + } +} diff --git a/Source/Mobile/TouchUserInput/UpdateTouchUserInput.cs.meta b/Source/Mobile/TouchUserInput/UpdateTouchUserInput.cs.meta new file mode 100644 index 00000000..8971db3a --- /dev/null +++ b/Source/Mobile/TouchUserInput/UpdateTouchUserInput.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: cb8841de6951243a69b3a619776d3692 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Source/Molecules.meta b/Source/Molecules.meta new file mode 100644 index 00000000..ee3385e1 --- /dev/null +++ b/Source/Molecules.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: f5ac12bb3165d41fc9ac4e29c86deede +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Source/Molecules/Timer.meta b/Source/Molecules/Timer.meta new file mode 100644 index 00000000..d99cdb1f --- /dev/null +++ b/Source/Molecules/Timer.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 712a94f5c9b034313becd0ad3cfd815f +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Source/Molecules/Timer/StartTimer.cs b/Source/Molecules/Timer/StartTimer.cs new file mode 100644 index 00000000..49d8c056 --- /dev/null +++ b/Source/Molecules/Timer/StartTimer.cs @@ -0,0 +1,16 @@ +using UnityEngine; + +namespace UnityAtoms +{ + [CreateAssetMenu(menuName = "Unity Atoms/Molecules/Timer/Start Timer")] + public class StartTimer : VoidAction + { + [SerializeField] + private Timer Timer = null; + + public override void Do() + { + Timer.Start(); + } + } +} diff --git a/Source/Molecules/Timer/StartTimer.cs.meta b/Source/Molecules/Timer/StartTimer.cs.meta new file mode 100644 index 00000000..ecf84a85 --- /dev/null +++ b/Source/Molecules/Timer/StartTimer.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: a08eb70317e0645fa8c4f4a3a3826308 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Source/Molecules/Timer/StopTimer.cs b/Source/Molecules/Timer/StopTimer.cs new file mode 100644 index 00000000..9645bff1 --- /dev/null +++ b/Source/Molecules/Timer/StopTimer.cs @@ -0,0 +1,16 @@ +using UnityEngine; + +namespace UnityAtoms +{ + [CreateAssetMenu(menuName = "Unity Atoms/Molecules/Timer/Stop Timer")] + public class StopTimer : VoidAction + { + [SerializeField] + private Timer Timer = null; + + public override void Do() + { + Timer.Stop(); + } + } +} diff --git a/Source/Molecules/Timer/StopTimer.cs.meta b/Source/Molecules/Timer/StopTimer.cs.meta new file mode 100644 index 00000000..a13fa3ee --- /dev/null +++ b/Source/Molecules/Timer/StopTimer.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 71948dbe3a374442aa8cd2d4309ea0df +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Source/Molecules/Timer/Timer.cs b/Source/Molecules/Timer/Timer.cs new file mode 100644 index 00000000..b510c45f --- /dev/null +++ b/Source/Molecules/Timer/Timer.cs @@ -0,0 +1,33 @@ +using UnityEngine; + +namespace UnityAtoms +{ + [CreateAssetMenu(menuName = "Unity Atoms/Molecules/Timer/Timer")] + public class Timer : ScriptableObject + { + public float TimeElapsed = 0f; + public bool Started = false; + + public void Start() + { + Started = true; + } + + public void Stop() + { + TimeElapsed = 0f; + Started = false; + } + + public float GetElapsedTime() + { + return TimeElapsed; + } + + public bool IsStarted() + { + return Started; + } + } + +} \ No newline at end of file diff --git a/Source/Molecules/Timer/Timer.cs.meta b/Source/Molecules/Timer/Timer.cs.meta new file mode 100644 index 00000000..563ac75c --- /dev/null +++ b/Source/Molecules/Timer/Timer.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: d3af1b79b50004c3898acd443e7cdbdd +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Source/Molecules/Timer/UpdateTimer.cs b/Source/Molecules/Timer/UpdateTimer.cs new file mode 100644 index 00000000..230e70e8 --- /dev/null +++ b/Source/Molecules/Timer/UpdateTimer.cs @@ -0,0 +1,21 @@ +using UnityEngine; + +namespace UnityAtoms +{ + /* Updates the Timer. Meant to be placed on a OnUpdateMonoHook. + */ + [CreateAssetMenu(menuName = "Unity Atoms/Molecules/Timer/Update Timer")] + public class UpdateTimer : VoidAction + { + [SerializeField] + private Timer Timer = null; + + public override void Do() + { + if (Timer.Started) + { + Timer.TimeElapsed += Time.deltaTime; + } + } + } +} diff --git a/Source/Molecules/Timer/UpdateTimer.cs.meta b/Source/Molecules/Timer/UpdateTimer.cs.meta new file mode 100644 index 00000000..50107ec5 --- /dev/null +++ b/Source/Molecules/Timer/UpdateTimer.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 558d82dcdddc64c50b2aba7e0ff2f847 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/UnityAtoms/MonoHooks.meta b/Source/MonoHooks.meta similarity index 77% rename from Assets/UnityAtoms/MonoHooks.meta rename to Source/MonoHooks.meta index 64b6d697..8c19e7a8 100644 --- a/Assets/UnityAtoms/MonoHooks.meta +++ b/Source/MonoHooks.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: e40d14d2aa6f94b2b92e34f2884b69aa +guid: ed92714bbfa43454094cc7d6a539d6bc folderAsset: yes DefaultImporter: externalObjects: {} diff --git a/Assets/UnityAtoms/MonoHooks/Collider2DHook.cs b/Source/MonoHooks/Collider2DHook.cs similarity index 100% rename from Assets/UnityAtoms/MonoHooks/Collider2DHook.cs rename to Source/MonoHooks/Collider2DHook.cs diff --git a/Assets/UnityAtoms/MonoHooks/Collider2DHook.cs.meta b/Source/MonoHooks/Collider2DHook.cs.meta similarity index 100% rename from Assets/UnityAtoms/MonoHooks/Collider2DHook.cs.meta rename to Source/MonoHooks/Collider2DHook.cs.meta diff --git a/Source/MonoHooks/ColliderHook.cs b/Source/MonoHooks/ColliderHook.cs new file mode 100644 index 00000000..8555a03a --- /dev/null +++ b/Source/MonoHooks/ColliderHook.cs @@ -0,0 +1,6 @@ +using UnityEngine; + +namespace UnityAtoms +{ + public abstract class ColliderHook : MonoHook { } +} \ No newline at end of file diff --git a/Source/MonoHooks/ColliderHook.cs.meta b/Source/MonoHooks/ColliderHook.cs.meta new file mode 100644 index 00000000..11e74c1c --- /dev/null +++ b/Source/MonoHooks/ColliderHook.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 6178fc51652f042a4842d227c32e3ec8 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/UnityAtoms/MonoHooks/MonoHook.cs b/Source/MonoHooks/MonoHook.cs similarity index 100% rename from Assets/UnityAtoms/MonoHooks/MonoHook.cs rename to Source/MonoHooks/MonoHook.cs diff --git a/Assets/UnityAtoms/MonoHooks/MonoHook.cs.meta b/Source/MonoHooks/MonoHook.cs.meta similarity index 100% rename from Assets/UnityAtoms/MonoHooks/MonoHook.cs.meta rename to Source/MonoHooks/MonoHook.cs.meta diff --git a/Assets/UnityAtoms/MonoHooks/OnAwakeHook.cs b/Source/MonoHooks/OnAwakeHook.cs similarity index 77% rename from Assets/UnityAtoms/MonoHooks/OnAwakeHook.cs rename to Source/MonoHooks/OnAwakeHook.cs index ed7641bd..3fd6f615 100644 --- a/Assets/UnityAtoms/MonoHooks/OnAwakeHook.cs +++ b/Source/MonoHooks/OnAwakeHook.cs @@ -6,13 +6,13 @@ namespace UnityAtoms public class OnAwakeHook : VoidHook { [SerializeField] - private VoidListener listener; + private VoidListener listener = null; [SerializeField] - private VoidGameObjectListener listenerWithGO; + private VoidGameObjectListener listenerWithGO = null; private void Awake() { - // This is needed because it's not certain that OnEnable on all scripts are called before Awake on all scripts + // This is needed because it's not certain that OnEnable on all scripts are called before Awake on all scripts if (Event != null && listener != null) { Event.RegisterListener(listener); @@ -25,4 +25,4 @@ namespace UnityAtoms OnHook(new Void()); } } -} \ No newline at end of file +} diff --git a/Assets/UnityAtoms/MonoHooks/OnAwakeHook.cs.meta b/Source/MonoHooks/OnAwakeHook.cs.meta similarity index 100% rename from Assets/UnityAtoms/MonoHooks/OnAwakeHook.cs.meta rename to Source/MonoHooks/OnAwakeHook.cs.meta diff --git a/Source/MonoHooks/OnButtonClickHook.cs b/Source/MonoHooks/OnButtonClickHook.cs new file mode 100644 index 00000000..70776ca5 --- /dev/null +++ b/Source/MonoHooks/OnButtonClickHook.cs @@ -0,0 +1,23 @@ +using UnityEngine; +using UnityEngine.UI; + +namespace UnityAtoms +{ + public class OnButtonClickHook : VoidHook + { + private void Awake() + { + GetComponent