diff --git a/.vscode/settings.json b/.vscode/settings.json new file mode 100644 index 0000000..1060b04 --- /dev/null +++ b/.vscode/settings.json @@ -0,0 +1,56 @@ +{ + "files.exclude": + { + "**/.DS_Store":true, + "**/.git":true, + "**/.gitignore":true, + "**/.gitmodules":true, + "**/*.booproj":true, + "**/*.pidb":true, + "**/*.suo":true, + "**/*.user":true, + "**/*.userprefs":true, + "**/*.unityproj":true, + "**/*.dll":true, + "**/*.exe":true, + "**/*.pdf":true, + "**/*.mid":true, + "**/*.midi":true, + "**/*.wav":true, + "**/*.gif":true, + "**/*.ico":true, + "**/*.jpg":true, + "**/*.jpeg":true, + "**/*.png":true, + "**/*.psd":true, + "**/*.tga":true, + "**/*.tif":true, + "**/*.tiff":true, + "**/*.3ds":true, + "**/*.3DS":true, + "**/*.fbx":true, + "**/*.FBX":true, + "**/*.lxo":true, + "**/*.LXO":true, + "**/*.ma":true, + "**/*.MA":true, + "**/*.obj":true, + "**/*.OBJ":true, + "**/*.asset":true, + "**/*.cubemap":true, + "**/*.flare":true, + "**/*.mat":true, + "**/*.meta":true, + "**/*.prefab":true, + "**/*.unity":true, + "build/":true, + "Build/":true, + "Library/":true, + "library/":true, + "obj/":true, + "Obj/":true, + "ProjectSettings/":true, + "temp/":true, + "Temp/":true + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer Movement.meta b/Assets/Behavior Designer Movement.meta new file mode 100644 index 0000000..0c4b265 --- /dev/null +++ b/Assets/Behavior Designer Movement.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 8fa6aee8c5b68834cb1492eb191e2fcf +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Behavior Designer Movement/Animations.meta b/Assets/Behavior Designer Movement/Animations.meta new file mode 100644 index 0000000..8ce3866 --- /dev/null +++ b/Assets/Behavior Designer Movement/Animations.meta @@ -0,0 +1,4 @@ +fileFormatVersion: 2 +guid: b3f4d0bc1b76ae7498a73377ddfc77db +DefaultImporter: + userData: diff --git a/Assets/Behavior Designer Movement/Animations/MarkerEvade.anim b/Assets/Behavior Designer Movement/Animations/MarkerEvade.anim new file mode 100644 index 0000000..7e7b19f --- /dev/null +++ b/Assets/Behavior Designer Movement/Animations/MarkerEvade.anim @@ -0,0 +1,116 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!74 &7400000 +AnimationClip: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_Name: MarkerEvade + serializedVersion: 4 + m_AnimationType: 1 + m_Compressed: 0 + m_UseHighQualityCurve: 1 + m_RotationCurves: [] + m_CompressedRotationCurves: [] + m_PositionCurves: + - curve: + serializedVersion: 2 + m_Curve: + - time: 0 + value: {x: 20, y: 1, z: 20} + inSlope: {x: -8, y: 0, z: 0} + outSlope: {x: -8, y: 0, z: 0} + tangentMode: -559038737 + - time: 5 + value: {x: -20, y: 1, z: 20} + inSlope: {x: -8, y: 0, z: 0} + outSlope: {x: -8, y: 0, z: 0} + tangentMode: -559038737 + m_PreInfinity: 2 + m_PostInfinity: 2 + path: + m_ScaleCurves: [] + m_FloatCurves: [] + m_PPtrCurves: [] + m_SampleRate: 60 + m_WrapMode: 0 + m_Bounds: + m_Center: {x: 0, y: 0, z: 0} + m_Extent: {x: 0, y: 0, z: 0} + m_AnimationClipSettings: + serializedVersion: 2 + m_StartTime: 0 + m_StopTime: 1 + m_OrientationOffsetY: 0 + m_Level: 0 + m_CycleOffset: 0 + m_LoopTime: 0 + m_LoopBlend: 0 + m_LoopBlendOrientation: 0 + m_LoopBlendPositionY: 0 + m_LoopBlendPositionXZ: 0 + m_KeepOriginalOrientation: 0 + m_KeepOriginalPositionY: 1 + m_KeepOriginalPositionXZ: 0 + m_HeightFromFeet: 0 + m_Mirror: 0 + m_EditorCurves: + - curve: + serializedVersion: 2 + m_Curve: + - time: 0 + value: 20 + inSlope: -8 + outSlope: -8 + tangentMode: 10 + - time: 5 + value: -20 + inSlope: -8 + outSlope: -8 + tangentMode: 10 + m_PreInfinity: 2 + m_PostInfinity: 2 + attribute: m_LocalPosition.x + path: + classID: 4 + script: {fileID: 0} + - curve: + serializedVersion: 2 + m_Curve: + - time: 0 + value: 1 + inSlope: 0 + outSlope: 0 + tangentMode: 10 + - time: 5 + value: 1 + inSlope: 0 + outSlope: 0 + tangentMode: 10 + m_PreInfinity: 2 + m_PostInfinity: 2 + attribute: m_LocalPosition.y + path: + classID: 4 + script: {fileID: 0} + - curve: + serializedVersion: 2 + m_Curve: + - time: 0 + value: 20 + inSlope: 0 + outSlope: 0 + tangentMode: 10 + - time: 5 + value: 20 + inSlope: 0 + outSlope: 0 + tangentMode: 10 + m_PreInfinity: 2 + m_PostInfinity: 2 + attribute: m_LocalPosition.z + path: + classID: 4 + script: {fileID: 0} + m_EulerEditorCurves: [] + m_Events: [] diff --git a/Assets/Behavior Designer Movement/Animations/MarkerEvade.anim.meta b/Assets/Behavior Designer Movement/Animations/MarkerEvade.anim.meta new file mode 100644 index 0000000..9fd4790 --- /dev/null +++ b/Assets/Behavior Designer Movement/Animations/MarkerEvade.anim.meta @@ -0,0 +1,4 @@ +fileFormatVersion: 2 +guid: 79d071115d1ae784b83e51b648ec393c +NativeFormatImporter: + userData: diff --git a/Assets/Behavior Designer Movement/Animations/MarkerFlee.anim b/Assets/Behavior Designer Movement/Animations/MarkerFlee.anim new file mode 100644 index 0000000..ff9d8fb --- /dev/null +++ b/Assets/Behavior Designer Movement/Animations/MarkerFlee.anim @@ -0,0 +1,136 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!74 &7400000 +AnimationClip: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_Name: MarkerFlee + serializedVersion: 4 + m_AnimationType: 1 + m_Compressed: 0 + m_UseHighQualityCurve: 1 + m_RotationCurves: [] + m_CompressedRotationCurves: [] + m_PositionCurves: + - curve: + serializedVersion: 2 + m_Curve: + - time: 0 + value: {x: 20, y: 1, z: 20} + inSlope: {x: 0, y: 0, z: 0} + outSlope: {x: 0, y: 0, z: 0} + tangentMode: -559038737 + - time: 1.5 + value: {x: 20, y: 1, z: 20} + inSlope: {x: 0, y: 0, z: 0} + outSlope: {x: 0, y: 0, z: 0} + tangentMode: -559038737 + - time: 3 + value: {x: -20, y: 1, z: 20} + inSlope: {x: -26.666666, y: 0, z: 0} + outSlope: {x: -26.666666, y: 0, z: 0} + tangentMode: -559038737 + m_PreInfinity: 2 + m_PostInfinity: 2 + path: + m_ScaleCurves: [] + m_FloatCurves: [] + m_PPtrCurves: [] + m_SampleRate: 60 + m_WrapMode: 0 + m_Bounds: + m_Center: {x: 0, y: 0, z: 0} + m_Extent: {x: 0, y: 0, z: 0} + m_AnimationClipSettings: + serializedVersion: 2 + m_StartTime: 0 + m_StopTime: 1 + m_OrientationOffsetY: 0 + m_Level: 0 + m_CycleOffset: 0 + m_LoopTime: 0 + m_LoopBlend: 0 + m_LoopBlendOrientation: 0 + m_LoopBlendPositionY: 0 + m_LoopBlendPositionXZ: 0 + m_KeepOriginalOrientation: 0 + m_KeepOriginalPositionY: 1 + m_KeepOriginalPositionXZ: 0 + m_HeightFromFeet: 0 + m_Mirror: 0 + m_EditorCurves: + - curve: + serializedVersion: 2 + m_Curve: + - time: 0 + value: 20 + inSlope: 0 + outSlope: 0 + tangentMode: 10 + - time: 1.5 + value: 20 + inSlope: 0 + outSlope: 0 + tangentMode: 0 + - time: 3 + value: -20 + inSlope: -26.666666 + outSlope: -26.666666 + tangentMode: 10 + m_PreInfinity: 2 + m_PostInfinity: 2 + attribute: m_LocalPosition.x + path: + classID: 4 + script: {fileID: 0} + - curve: + serializedVersion: 2 + m_Curve: + - time: 0 + value: 1 + inSlope: 0 + outSlope: 0 + tangentMode: 10 + - time: 1.5 + value: 1 + inSlope: 0 + outSlope: 0 + tangentMode: 10 + - time: 3 + value: 1 + inSlope: 0 + outSlope: 0 + tangentMode: 10 + m_PreInfinity: 2 + m_PostInfinity: 2 + attribute: m_LocalPosition.y + path: + classID: 4 + script: {fileID: 0} + - curve: + serializedVersion: 2 + m_Curve: + - time: 0 + value: 20 + inSlope: 0 + outSlope: 0 + tangentMode: 10 + - time: 1.5 + value: 20 + inSlope: 0 + outSlope: 0 + tangentMode: 0 + - time: 3 + value: 20 + inSlope: 0 + outSlope: 0 + tangentMode: 10 + m_PreInfinity: 2 + m_PostInfinity: 2 + attribute: m_LocalPosition.z + path: + classID: 4 + script: {fileID: 0} + m_EulerEditorCurves: [] + m_Events: [] diff --git a/Assets/Behavior Designer Movement/Animations/MarkerFlee.anim.meta b/Assets/Behavior Designer Movement/Animations/MarkerFlee.anim.meta new file mode 100644 index 0000000..962b4d5 --- /dev/null +++ b/Assets/Behavior Designer Movement/Animations/MarkerFlee.anim.meta @@ -0,0 +1,4 @@ +fileFormatVersion: 2 +guid: d49c5804b31faad4ca706eb999c87559 +NativeFormatImporter: + userData: diff --git a/Assets/Behavior Designer Movement/Animations/MarkerFollow.anim b/Assets/Behavior Designer Movement/Animations/MarkerFollow.anim new file mode 100644 index 0000000..52432c3 --- /dev/null +++ b/Assets/Behavior Designer Movement/Animations/MarkerFollow.anim @@ -0,0 +1,162 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!74 &7400000 +AnimationClip: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_Name: MarkerFollow + serializedVersion: 6 + m_Legacy: 1 + m_Compressed: 0 + m_UseHighQualityCurve: 1 + m_RotationCurves: [] + m_CompressedRotationCurves: [] + m_PositionCurves: + - curve: + serializedVersion: 2 + m_Curve: + - time: 0 + value: {x: 20, y: 1, z: 20} + inSlope: {x: -8, y: 0, z: 0} + outSlope: {x: -8, y: 0, z: 0} + tangentMode: 0 + - time: 5 + value: {x: -20, y: 1, z: 20} + inSlope: {x: 0, y: 0, z: 0} + outSlope: {x: 0, y: 0, z: 0} + tangentMode: 0 + - time: 6 + value: {x: -20, y: 1, z: 20} + inSlope: {x: 0, y: 0, z: 0} + outSlope: {x: 0, y: 0, z: 0} + tangentMode: 0 + - time: 11.0166664 + value: {x: -20, y: 1, z: -20} + inSlope: {x: 0, y: 0, z: -7.97342253} + outSlope: {x: 0, y: 0, z: -7.97342253} + tangentMode: 0 + m_PreInfinity: 2 + m_PostInfinity: 2 + path: + m_ScaleCurves: [] + m_FloatCurves: [] + m_PPtrCurves: [] + m_SampleRate: 60 + m_WrapMode: 0 + m_Bounds: + m_Center: {x: 0, y: 0, z: 0} + m_Extent: {x: 0, y: 0, z: 0} + m_ClipBindingConstant: + genericBindings: [] + pptrCurveMapping: [] + m_AnimationClipSettings: + serializedVersion: 2 + m_StartTime: 0 + m_StopTime: 11.0166664 + m_OrientationOffsetY: 0 + m_Level: 0 + m_CycleOffset: 0 + m_LoopTime: 0 + m_LoopBlend: 0 + m_LoopBlendOrientation: 0 + m_LoopBlendPositionY: 0 + m_LoopBlendPositionXZ: 0 + m_KeepOriginalOrientation: 0 + m_KeepOriginalPositionY: 1 + m_KeepOriginalPositionXZ: 0 + m_HeightFromFeet: 0 + m_Mirror: 0 + m_EditorCurves: + - curve: + serializedVersion: 2 + m_Curve: + - time: 0 + value: 20 + inSlope: -8 + outSlope: -8 + tangentMode: 10 + - time: 5 + value: -20 + inSlope: 0 + outSlope: 0 + tangentMode: 0 + - time: 6 + value: -20 + inSlope: 0 + outSlope: 0 + tangentMode: 10 + - time: 11.0166664 + value: -20 + inSlope: 0 + outSlope: 0 + tangentMode: 10 + m_PreInfinity: 2 + m_PostInfinity: 2 + attribute: m_LocalPosition.x + path: + classID: 4 + script: {fileID: 0} + - curve: + serializedVersion: 2 + m_Curve: + - time: 0 + value: 1 + inSlope: 0 + outSlope: 0 + tangentMode: 10 + - time: 5 + value: 1 + inSlope: 0 + outSlope: 0 + tangentMode: 1 + - time: 6 + value: 1 + inSlope: 0 + outSlope: 0 + tangentMode: 1 + - time: 11.0166664 + value: 1 + inSlope: 0 + outSlope: 0 + tangentMode: 10 + m_PreInfinity: 2 + m_PostInfinity: 2 + attribute: m_LocalPosition.y + path: + classID: 4 + script: {fileID: 0} + - curve: + serializedVersion: 2 + m_Curve: + - time: 0 + value: 20 + inSlope: 0 + outSlope: 0 + tangentMode: 10 + - time: 5 + value: 20 + inSlope: 0 + outSlope: 0 + tangentMode: 0 + - time: 6 + value: 20 + inSlope: 0 + outSlope: 0 + tangentMode: 0 + - time: 11.0166664 + value: -20 + inSlope: -7.97342253 + outSlope: -7.97342253 + tangentMode: 10 + m_PreInfinity: 2 + m_PostInfinity: 2 + attribute: m_LocalPosition.z + path: + classID: 4 + script: {fileID: 0} + m_EulerEditorCurves: [] + m_HasGenericRootTransform: 0 + m_HasMotionFloatCurves: 0 + m_GenerateMotionCurves: 0 + m_Events: [] diff --git a/Assets/Behavior Designer Movement/Animations/MarkerFollow.anim.meta b/Assets/Behavior Designer Movement/Animations/MarkerFollow.anim.meta new file mode 100644 index 0000000..764c90a --- /dev/null +++ b/Assets/Behavior Designer Movement/Animations/MarkerFollow.anim.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 4e102685eb400e54bb2eced40a6f2efd +timeCreated: 1470316175 +licenseType: Store +NativeFormatImporter: + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Behavior Designer Movement/Animations/MarkerPersue.anim b/Assets/Behavior Designer Movement/Animations/MarkerPersue.anim new file mode 100644 index 0000000..8d5023b --- /dev/null +++ b/Assets/Behavior Designer Movement/Animations/MarkerPersue.anim @@ -0,0 +1,116 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!74 &7400000 +AnimationClip: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_Name: MarkerPersue + serializedVersion: 4 + m_AnimationType: 1 + m_Compressed: 0 + m_UseHighQualityCurve: 1 + m_RotationCurves: [] + m_CompressedRotationCurves: [] + m_PositionCurves: + - curve: + serializedVersion: 2 + m_Curve: + - time: 1 + value: {x: 20, y: 1, z: 20} + inSlope: {x: -8, y: 0, z: 0} + outSlope: {x: -8, y: 0, z: 0} + tangentMode: -559038737 + - time: 6 + value: {x: -20, y: 1, z: 20} + inSlope: {x: -8, y: 0, z: 0} + outSlope: {x: -8, y: 0, z: 0} + tangentMode: -559038737 + m_PreInfinity: 2 + m_PostInfinity: 2 + path: + m_ScaleCurves: [] + m_FloatCurves: [] + m_PPtrCurves: [] + m_SampleRate: 60 + m_WrapMode: 0 + m_Bounds: + m_Center: {x: 0, y: 0, z: 0} + m_Extent: {x: 0, y: 0, z: 0} + m_AnimationClipSettings: + serializedVersion: 2 + m_StartTime: 0 + m_StopTime: 1 + m_OrientationOffsetY: 0 + m_Level: 0 + m_CycleOffset: 0 + m_LoopTime: 0 + m_LoopBlend: 0 + m_LoopBlendOrientation: 0 + m_LoopBlendPositionY: 0 + m_LoopBlendPositionXZ: 0 + m_KeepOriginalOrientation: 0 + m_KeepOriginalPositionY: 1 + m_KeepOriginalPositionXZ: 0 + m_HeightFromFeet: 0 + m_Mirror: 0 + m_EditorCurves: + - curve: + serializedVersion: 2 + m_Curve: + - time: 1 + value: 20 + inSlope: -8 + outSlope: -8 + tangentMode: 10 + - time: 6 + value: -20 + inSlope: -8 + outSlope: -8 + tangentMode: 10 + m_PreInfinity: 2 + m_PostInfinity: 2 + attribute: m_LocalPosition.x + path: + classID: 4 + script: {fileID: 0} + - curve: + serializedVersion: 2 + m_Curve: + - time: 1 + value: 1 + inSlope: 0 + outSlope: 0 + tangentMode: 10 + - time: 6 + value: 1 + inSlope: 0 + outSlope: 0 + tangentMode: 10 + m_PreInfinity: 2 + m_PostInfinity: 2 + attribute: m_LocalPosition.y + path: + classID: 4 + script: {fileID: 0} + - curve: + serializedVersion: 2 + m_Curve: + - time: 1 + value: 20 + inSlope: 0 + outSlope: 0 + tangentMode: 10 + - time: 6 + value: 20 + inSlope: 0 + outSlope: 0 + tangentMode: 10 + m_PreInfinity: 2 + m_PostInfinity: 2 + attribute: m_LocalPosition.z + path: + classID: 4 + script: {fileID: 0} + m_EulerEditorCurves: [] + m_Events: [] diff --git a/Assets/Behavior Designer Movement/Animations/MarkerPersue.anim.meta b/Assets/Behavior Designer Movement/Animations/MarkerPersue.anim.meta new file mode 100644 index 0000000..59885ec --- /dev/null +++ b/Assets/Behavior Designer Movement/Animations/MarkerPersue.anim.meta @@ -0,0 +1,4 @@ +fileFormatVersion: 2 +guid: 9321e00e69f740142a77918a547ce578 +NativeFormatImporter: + userData: diff --git a/Assets/Behavior Designer Movement/Animations/MarkerSeek.anim b/Assets/Behavior Designer Movement/Animations/MarkerSeek.anim new file mode 100644 index 0000000..51ba625 --- /dev/null +++ b/Assets/Behavior Designer Movement/Animations/MarkerSeek.anim @@ -0,0 +1,116 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!74 &7400000 +AnimationClip: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_Name: MarkerSeek + serializedVersion: 4 + m_AnimationType: 1 + m_Compressed: 0 + m_UseHighQualityCurve: 1 + m_RotationCurves: [] + m_CompressedRotationCurves: [] + m_PositionCurves: + - curve: + serializedVersion: 2 + m_Curve: + - time: 2.48333335 + value: {x: 20, y: 1, z: 20} + inSlope: {x: -26.3736191, y: 0, z: 0} + outSlope: {x: -26.3736191, y: 0, z: 0} + tangentMode: -559038737 + - time: 4.00000048 + value: {x: -20, y: 1, z: 20} + inSlope: {x: -26.3736191, y: 0, z: 0} + outSlope: {x: -26.3736191, y: 0, z: 0} + tangentMode: -559038737 + m_PreInfinity: 2 + m_PostInfinity: 2 + path: + m_ScaleCurves: [] + m_FloatCurves: [] + m_PPtrCurves: [] + m_SampleRate: 60 + m_WrapMode: 0 + m_Bounds: + m_Center: {x: 0, y: 0, z: 0} + m_Extent: {x: 0, y: 0, z: 0} + m_AnimationClipSettings: + serializedVersion: 2 + m_StartTime: 0 + m_StopTime: 1 + m_OrientationOffsetY: 0 + m_Level: 0 + m_CycleOffset: 0 + m_LoopTime: 0 + m_LoopBlend: 0 + m_LoopBlendOrientation: 0 + m_LoopBlendPositionY: 0 + m_LoopBlendPositionXZ: 0 + m_KeepOriginalOrientation: 0 + m_KeepOriginalPositionY: 1 + m_KeepOriginalPositionXZ: 0 + m_HeightFromFeet: 0 + m_Mirror: 0 + m_EditorCurves: + - curve: + serializedVersion: 2 + m_Curve: + - time: 2.48333335 + value: 20 + inSlope: -26.3736191 + outSlope: -26.3736191 + tangentMode: 10 + - time: 4.00000048 + value: -20 + inSlope: -26.3736191 + outSlope: -26.3736191 + tangentMode: 10 + m_PreInfinity: 2 + m_PostInfinity: 2 + attribute: m_LocalPosition.x + path: + classID: 4 + script: {fileID: 0} + - curve: + serializedVersion: 2 + m_Curve: + - time: 2.48333335 + value: 1 + inSlope: 0 + outSlope: 0 + tangentMode: 10 + - time: 4.00000048 + value: 1 + inSlope: 0 + outSlope: 0 + tangentMode: 10 + m_PreInfinity: 2 + m_PostInfinity: 2 + attribute: m_LocalPosition.y + path: + classID: 4 + script: {fileID: 0} + - curve: + serializedVersion: 2 + m_Curve: + - time: 2.48333335 + value: 20 + inSlope: 0 + outSlope: 0 + tangentMode: 10 + - time: 4.00000048 + value: 20 + inSlope: 0 + outSlope: 0 + tangentMode: 10 + m_PreInfinity: 2 + m_PostInfinity: 2 + attribute: m_LocalPosition.z + path: + classID: 4 + script: {fileID: 0} + m_EulerEditorCurves: [] + m_Events: [] diff --git a/Assets/Behavior Designer Movement/Animations/MarkerSeek.anim.meta b/Assets/Behavior Designer Movement/Animations/MarkerSeek.anim.meta new file mode 100644 index 0000000..b1c95e9 --- /dev/null +++ b/Assets/Behavior Designer Movement/Animations/MarkerSeek.anim.meta @@ -0,0 +1,4 @@ +fileFormatVersion: 2 +guid: 07e94773bc03f2540806b14a5f8fcbde +NativeFormatImporter: + userData: diff --git a/Assets/Behavior Designer Movement/Documentation.pdf b/Assets/Behavior Designer Movement/Documentation.pdf new file mode 100644 index 0000000..8a0e7cb Binary files /dev/null and b/Assets/Behavior Designer Movement/Documentation.pdf differ diff --git a/Assets/Behavior Designer Movement/Documentation.pdf.meta b/Assets/Behavior Designer Movement/Documentation.pdf.meta new file mode 100644 index 0000000..68b71e9 --- /dev/null +++ b/Assets/Behavior Designer Movement/Documentation.pdf.meta @@ -0,0 +1,4 @@ +fileFormatVersion: 2 +guid: 3c1b70a1ac19dba4cb0051040144dc96 +DefaultImporter: + userData: diff --git a/Assets/Behavior Designer Movement/Editor.meta b/Assets/Behavior Designer Movement/Editor.meta new file mode 100644 index 0000000..b6d72aa --- /dev/null +++ b/Assets/Behavior Designer Movement/Editor.meta @@ -0,0 +1,4 @@ +fileFormatVersion: 2 +guid: 0e7c89f0c6c0d194d9fd5799046b9a5f +DefaultImporter: + userData: diff --git a/Assets/Behavior Designer Movement/Editor/Icons.meta b/Assets/Behavior Designer Movement/Editor/Icons.meta new file mode 100644 index 0000000..86b0d23 --- /dev/null +++ b/Assets/Behavior Designer Movement/Editor/Icons.meta @@ -0,0 +1,4 @@ +fileFormatVersion: 2 +guid: f7fb890fd0f8e8040aaf7ca879d97bbe +DefaultImporter: + userData: diff --git a/Assets/Behavior Designer Movement/Editor/Icons/DarkCanHearObjectIcon.png b/Assets/Behavior Designer Movement/Editor/Icons/DarkCanHearObjectIcon.png new file mode 100644 index 0000000..b5bf30c Binary files /dev/null and b/Assets/Behavior Designer Movement/Editor/Icons/DarkCanHearObjectIcon.png differ diff --git a/Assets/Behavior Designer Movement/Editor/Icons/DarkCanHearObjectIcon.png.meta b/Assets/Behavior Designer Movement/Editor/Icons/DarkCanHearObjectIcon.png.meta new file mode 100644 index 0000000..e535436 --- /dev/null +++ b/Assets/Behavior Designer Movement/Editor/Icons/DarkCanHearObjectIcon.png.meta @@ -0,0 +1,35 @@ +fileFormatVersion: 2 +guid: 941bd88188259374d885440560f1a29d +TextureImporter: + serializedVersion: 2 + mipmaps: + mipMapMode: 0 + enableMipMap: 0 + linearTexture: 1 + correctGamma: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: .25 + normalMapFilter: 0 + isReadable: 0 + grayScaleToAlpha: 0 + generateCubemap: 0 + seamlessCubemap: 0 + textureFormat: -3 + maxTextureSize: 1024 + textureSettings: + filterMode: -1 + aniso: 1 + mipBias: -1 + wrapMode: 1 + nPOTScale: 0 + lightmap: 0 + compressionQuality: 50 + textureType: 2 + buildTargetSettings: [] + userData: diff --git a/Assets/Behavior Designer Movement/Editor/Icons/DarkCanSeeObjectIcon.png b/Assets/Behavior Designer Movement/Editor/Icons/DarkCanSeeObjectIcon.png new file mode 100644 index 0000000..bcd07de Binary files /dev/null and b/Assets/Behavior Designer Movement/Editor/Icons/DarkCanSeeObjectIcon.png differ diff --git a/Assets/Behavior Designer Movement/Editor/Icons/DarkCanSeeObjectIcon.png.meta b/Assets/Behavior Designer Movement/Editor/Icons/DarkCanSeeObjectIcon.png.meta new file mode 100644 index 0000000..5f511d2 --- /dev/null +++ b/Assets/Behavior Designer Movement/Editor/Icons/DarkCanSeeObjectIcon.png.meta @@ -0,0 +1,35 @@ +fileFormatVersion: 2 +guid: 7f2d1486b1b44ec4b8c213df246534c5 +TextureImporter: + serializedVersion: 2 + mipmaps: + mipMapMode: 0 + enableMipMap: 0 + linearTexture: 1 + correctGamma: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: .25 + normalMapFilter: 0 + isReadable: 0 + grayScaleToAlpha: 0 + generateCubemap: 0 + seamlessCubemap: 0 + textureFormat: -3 + maxTextureSize: 1024 + textureSettings: + filterMode: -1 + aniso: 1 + mipBias: -1 + wrapMode: 1 + nPOTScale: 0 + lightmap: 0 + compressionQuality: 50 + textureType: 2 + buildTargetSettings: [] + userData: diff --git a/Assets/Behavior Designer Movement/Editor/Icons/DarkCoverIcon.png b/Assets/Behavior Designer Movement/Editor/Icons/DarkCoverIcon.png new file mode 100644 index 0000000..f3e443a Binary files /dev/null and b/Assets/Behavior Designer Movement/Editor/Icons/DarkCoverIcon.png differ diff --git a/Assets/Behavior Designer Movement/Editor/Icons/DarkCoverIcon.png.meta b/Assets/Behavior Designer Movement/Editor/Icons/DarkCoverIcon.png.meta new file mode 100644 index 0000000..e18f646 --- /dev/null +++ b/Assets/Behavior Designer Movement/Editor/Icons/DarkCoverIcon.png.meta @@ -0,0 +1,35 @@ +fileFormatVersion: 2 +guid: 67e27331b399ae14f9eb7a6debc1802d +TextureImporter: + serializedVersion: 2 + mipmaps: + mipMapMode: 0 + enableMipMap: 0 + linearTexture: 1 + correctGamma: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: .25 + normalMapFilter: 0 + isReadable: 0 + grayScaleToAlpha: 0 + generateCubemap: 0 + seamlessCubemap: 0 + textureFormat: -3 + maxTextureSize: 1024 + textureSettings: + filterMode: -1 + aniso: 1 + mipBias: -1 + wrapMode: 1 + nPOTScale: 0 + lightmap: 0 + compressionQuality: 50 + textureType: 2 + buildTargetSettings: [] + userData: diff --git a/Assets/Behavior Designer Movement/Editor/Icons/DarkEvadeIcon.png b/Assets/Behavior Designer Movement/Editor/Icons/DarkEvadeIcon.png new file mode 100644 index 0000000..44eed70 Binary files /dev/null and b/Assets/Behavior Designer Movement/Editor/Icons/DarkEvadeIcon.png differ diff --git a/Assets/Behavior Designer Movement/Editor/Icons/DarkEvadeIcon.png.meta b/Assets/Behavior Designer Movement/Editor/Icons/DarkEvadeIcon.png.meta new file mode 100644 index 0000000..f45c3b1 --- /dev/null +++ b/Assets/Behavior Designer Movement/Editor/Icons/DarkEvadeIcon.png.meta @@ -0,0 +1,35 @@ +fileFormatVersion: 2 +guid: 992feefbe2d39f945b808bed5b4f0986 +TextureImporter: + serializedVersion: 2 + mipmaps: + mipMapMode: 0 + enableMipMap: 0 + linearTexture: 1 + correctGamma: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: .25 + normalMapFilter: 0 + isReadable: 0 + grayScaleToAlpha: 0 + generateCubemap: 0 + seamlessCubemap: 0 + textureFormat: -3 + maxTextureSize: 1024 + textureSettings: + filterMode: -1 + aniso: 1 + mipBias: -1 + wrapMode: 1 + nPOTScale: 0 + lightmap: 0 + compressionQuality: 50 + textureType: 2 + buildTargetSettings: [] + userData: diff --git a/Assets/Behavior Designer Movement/Editor/Icons/DarkFleeIcon.png b/Assets/Behavior Designer Movement/Editor/Icons/DarkFleeIcon.png new file mode 100644 index 0000000..297fd4d Binary files /dev/null and b/Assets/Behavior Designer Movement/Editor/Icons/DarkFleeIcon.png differ diff --git a/Assets/Behavior Designer Movement/Editor/Icons/DarkFleeIcon.png.meta b/Assets/Behavior Designer Movement/Editor/Icons/DarkFleeIcon.png.meta new file mode 100644 index 0000000..3f98e6d --- /dev/null +++ b/Assets/Behavior Designer Movement/Editor/Icons/DarkFleeIcon.png.meta @@ -0,0 +1,35 @@ +fileFormatVersion: 2 +guid: e1a2340aca5184f4ba0f3e3163864b8e +TextureImporter: + serializedVersion: 2 + mipmaps: + mipMapMode: 0 + enableMipMap: 0 + linearTexture: 1 + correctGamma: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: .25 + normalMapFilter: 0 + isReadable: 0 + grayScaleToAlpha: 0 + generateCubemap: 0 + seamlessCubemap: 0 + textureFormat: -3 + maxTextureSize: 1024 + textureSettings: + filterMode: -1 + aniso: 1 + mipBias: -1 + wrapMode: 1 + nPOTScale: 0 + lightmap: 0 + compressionQuality: 50 + textureType: 2 + buildTargetSettings: [] + userData: diff --git a/Assets/Behavior Designer Movement/Editor/Icons/DarkFlockIcon.png b/Assets/Behavior Designer Movement/Editor/Icons/DarkFlockIcon.png new file mode 100644 index 0000000..6434251 Binary files /dev/null and b/Assets/Behavior Designer Movement/Editor/Icons/DarkFlockIcon.png differ diff --git a/Assets/Behavior Designer Movement/Editor/Icons/DarkFlockIcon.png.meta b/Assets/Behavior Designer Movement/Editor/Icons/DarkFlockIcon.png.meta new file mode 100644 index 0000000..ceff56e --- /dev/null +++ b/Assets/Behavior Designer Movement/Editor/Icons/DarkFlockIcon.png.meta @@ -0,0 +1,35 @@ +fileFormatVersion: 2 +guid: 29465febf85da33499a039c8ec393d64 +TextureImporter: + serializedVersion: 2 + mipmaps: + mipMapMode: 0 + enableMipMap: 0 + linearTexture: 1 + correctGamma: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: .25 + normalMapFilter: 0 + isReadable: 0 + grayScaleToAlpha: 0 + generateCubemap: 0 + seamlessCubemap: 0 + textureFormat: -3 + maxTextureSize: 1024 + textureSettings: + filterMode: -1 + aniso: 1 + mipBias: -1 + wrapMode: 1 + nPOTScale: 0 + lightmap: 0 + compressionQuality: 50 + textureType: 2 + buildTargetSettings: [] + userData: diff --git a/Assets/Behavior Designer Movement/Editor/Icons/DarkFollowIcon.png b/Assets/Behavior Designer Movement/Editor/Icons/DarkFollowIcon.png new file mode 100644 index 0000000..38f7fa7 Binary files /dev/null and b/Assets/Behavior Designer Movement/Editor/Icons/DarkFollowIcon.png differ diff --git a/Assets/Behavior Designer Movement/Editor/Icons/DarkFollowIcon.png.meta b/Assets/Behavior Designer Movement/Editor/Icons/DarkFollowIcon.png.meta new file mode 100644 index 0000000..90d897c --- /dev/null +++ b/Assets/Behavior Designer Movement/Editor/Icons/DarkFollowIcon.png.meta @@ -0,0 +1,55 @@ +fileFormatVersion: 2 +guid: b17f9c5419e855948badb45ca05a4fcd +timeCreated: 1471183834 +licenseType: Store +TextureImporter: + fileIDToRecycleName: {} + serializedVersion: 2 + mipmaps: + mipMapMode: 0 + enableMipMap: 0 + linearTexture: 1 + correctGamma: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: .25 + normalMapFilter: 0 + isReadable: 0 + grayScaleToAlpha: 0 + generateCubemap: 0 + cubemapConvolution: 0 + cubemapConvolutionSteps: 8 + cubemapConvolutionExponent: 1.5 + seamlessCubemap: 0 + textureFormat: -3 + maxTextureSize: 2048 + textureSettings: + filterMode: -1 + aniso: 1 + mipBias: -1 + wrapMode: 1 + nPOTScale: 0 + lightmap: 0 + rGBM: 0 + compressionQuality: 50 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: .5, y: .5} + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spritePixelsToUnits: 100 + alphaIsTransparency: 1 + textureType: 2 + buildTargetSettings: [] + spriteSheet: + sprites: [] + spritePackingTag: + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Behavior Designer Movement/Editor/Icons/DarkLeaderFollowIcon.png b/Assets/Behavior Designer Movement/Editor/Icons/DarkLeaderFollowIcon.png new file mode 100644 index 0000000..3d8aab8 Binary files /dev/null and b/Assets/Behavior Designer Movement/Editor/Icons/DarkLeaderFollowIcon.png differ diff --git a/Assets/Behavior Designer Movement/Editor/Icons/DarkLeaderFollowIcon.png.meta b/Assets/Behavior Designer Movement/Editor/Icons/DarkLeaderFollowIcon.png.meta new file mode 100644 index 0000000..4576b2f --- /dev/null +++ b/Assets/Behavior Designer Movement/Editor/Icons/DarkLeaderFollowIcon.png.meta @@ -0,0 +1,35 @@ +fileFormatVersion: 2 +guid: ceded4836fa9bc24f964ec6fadccdc40 +TextureImporter: + serializedVersion: 2 + mipmaps: + mipMapMode: 0 + enableMipMap: 0 + linearTexture: 1 + correctGamma: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: .25 + normalMapFilter: 0 + isReadable: 0 + grayScaleToAlpha: 0 + generateCubemap: 0 + seamlessCubemap: 0 + textureFormat: -3 + maxTextureSize: 1024 + textureSettings: + filterMode: -1 + aniso: 1 + mipBias: -1 + wrapMode: 1 + nPOTScale: 0 + lightmap: 0 + compressionQuality: 50 + textureType: 2 + buildTargetSettings: [] + userData: diff --git a/Assets/Behavior Designer Movement/Editor/Icons/DarkMoveTowardsIcon.png b/Assets/Behavior Designer Movement/Editor/Icons/DarkMoveTowardsIcon.png new file mode 100644 index 0000000..ce29d3c Binary files /dev/null and b/Assets/Behavior Designer Movement/Editor/Icons/DarkMoveTowardsIcon.png differ diff --git a/Assets/Behavior Designer Movement/Editor/Icons/DarkMoveTowardsIcon.png.meta b/Assets/Behavior Designer Movement/Editor/Icons/DarkMoveTowardsIcon.png.meta new file mode 100644 index 0000000..d804228 --- /dev/null +++ b/Assets/Behavior Designer Movement/Editor/Icons/DarkMoveTowardsIcon.png.meta @@ -0,0 +1,35 @@ +fileFormatVersion: 2 +guid: 812dc79fe1e417548959f61845528372 +TextureImporter: + serializedVersion: 2 + mipmaps: + mipMapMode: 0 + enableMipMap: 0 + linearTexture: 1 + correctGamma: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: .25 + normalMapFilter: 0 + isReadable: 0 + grayScaleToAlpha: 0 + generateCubemap: 0 + seamlessCubemap: 0 + textureFormat: -3 + maxTextureSize: 1024 + textureSettings: + filterMode: -1 + aniso: 1 + mipBias: -1 + wrapMode: 1 + nPOTScale: 0 + lightmap: 0 + compressionQuality: 50 + textureType: 2 + buildTargetSettings: [] + userData: diff --git a/Assets/Behavior Designer Movement/Editor/Icons/DarkPatrolIcon.png b/Assets/Behavior Designer Movement/Editor/Icons/DarkPatrolIcon.png new file mode 100644 index 0000000..bc269b4 Binary files /dev/null and b/Assets/Behavior Designer Movement/Editor/Icons/DarkPatrolIcon.png differ diff --git a/Assets/Behavior Designer Movement/Editor/Icons/DarkPatrolIcon.png.meta b/Assets/Behavior Designer Movement/Editor/Icons/DarkPatrolIcon.png.meta new file mode 100644 index 0000000..975ee17 --- /dev/null +++ b/Assets/Behavior Designer Movement/Editor/Icons/DarkPatrolIcon.png.meta @@ -0,0 +1,35 @@ +fileFormatVersion: 2 +guid: 3c16815a0806b2a4c8cd693c5139b3ea +TextureImporter: + serializedVersion: 2 + mipmaps: + mipMapMode: 0 + enableMipMap: 0 + linearTexture: 1 + correctGamma: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: .25 + normalMapFilter: 0 + isReadable: 0 + grayScaleToAlpha: 0 + generateCubemap: 0 + seamlessCubemap: 0 + textureFormat: -3 + maxTextureSize: 1024 + textureSettings: + filterMode: -1 + aniso: 1 + mipBias: -1 + wrapMode: 1 + nPOTScale: 0 + lightmap: 0 + compressionQuality: 50 + textureType: 2 + buildTargetSettings: [] + userData: diff --git a/Assets/Behavior Designer Movement/Editor/Icons/DarkPursueIcon.png b/Assets/Behavior Designer Movement/Editor/Icons/DarkPursueIcon.png new file mode 100644 index 0000000..9e288ce Binary files /dev/null and b/Assets/Behavior Designer Movement/Editor/Icons/DarkPursueIcon.png differ diff --git a/Assets/Behavior Designer Movement/Editor/Icons/DarkPursueIcon.png.meta b/Assets/Behavior Designer Movement/Editor/Icons/DarkPursueIcon.png.meta new file mode 100644 index 0000000..f81cc01 --- /dev/null +++ b/Assets/Behavior Designer Movement/Editor/Icons/DarkPursueIcon.png.meta @@ -0,0 +1,35 @@ +fileFormatVersion: 2 +guid: c29eb3ccdfa67a744971276c325e44ea +TextureImporter: + serializedVersion: 2 + mipmaps: + mipMapMode: 0 + enableMipMap: 0 + linearTexture: 1 + correctGamma: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: .25 + normalMapFilter: 0 + isReadable: 0 + grayScaleToAlpha: 0 + generateCubemap: 0 + seamlessCubemap: 0 + textureFormat: -3 + maxTextureSize: 1024 + textureSettings: + filterMode: -1 + aniso: 1 + mipBias: -1 + wrapMode: 1 + nPOTScale: 0 + lightmap: 0 + compressionQuality: 50 + textureType: 2 + buildTargetSettings: [] + userData: diff --git a/Assets/Behavior Designer Movement/Editor/Icons/DarkQueueIcon.png b/Assets/Behavior Designer Movement/Editor/Icons/DarkQueueIcon.png new file mode 100644 index 0000000..4ee49b7 Binary files /dev/null and b/Assets/Behavior Designer Movement/Editor/Icons/DarkQueueIcon.png differ diff --git a/Assets/Behavior Designer Movement/Editor/Icons/DarkQueueIcon.png.meta b/Assets/Behavior Designer Movement/Editor/Icons/DarkQueueIcon.png.meta new file mode 100644 index 0000000..3ee7192 --- /dev/null +++ b/Assets/Behavior Designer Movement/Editor/Icons/DarkQueueIcon.png.meta @@ -0,0 +1,35 @@ +fileFormatVersion: 2 +guid: 454cd90f13f2a9a4f93ade9379f9b3c9 +TextureImporter: + serializedVersion: 2 + mipmaps: + mipMapMode: 0 + enableMipMap: 0 + linearTexture: 1 + correctGamma: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: .25 + normalMapFilter: 0 + isReadable: 0 + grayScaleToAlpha: 0 + generateCubemap: 0 + seamlessCubemap: 0 + textureFormat: -3 + maxTextureSize: 1024 + textureSettings: + filterMode: -1 + aniso: 1 + mipBias: -1 + wrapMode: 1 + nPOTScale: 0 + lightmap: 0 + compressionQuality: 50 + textureType: 2 + buildTargetSettings: [] + userData: diff --git a/Assets/Behavior Designer Movement/Editor/Icons/DarkRotateTowardsIcon.png b/Assets/Behavior Designer Movement/Editor/Icons/DarkRotateTowardsIcon.png new file mode 100644 index 0000000..ffc9182 Binary files /dev/null and b/Assets/Behavior Designer Movement/Editor/Icons/DarkRotateTowardsIcon.png differ diff --git a/Assets/Behavior Designer Movement/Editor/Icons/DarkRotateTowardsIcon.png.meta b/Assets/Behavior Designer Movement/Editor/Icons/DarkRotateTowardsIcon.png.meta new file mode 100644 index 0000000..38f845e --- /dev/null +++ b/Assets/Behavior Designer Movement/Editor/Icons/DarkRotateTowardsIcon.png.meta @@ -0,0 +1,35 @@ +fileFormatVersion: 2 +guid: 9bded0edc8b2a2f478fc28396fa41df2 +TextureImporter: + serializedVersion: 2 + mipmaps: + mipMapMode: 0 + enableMipMap: 0 + linearTexture: 1 + correctGamma: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: .25 + normalMapFilter: 0 + isReadable: 0 + grayScaleToAlpha: 0 + generateCubemap: 0 + seamlessCubemap: 0 + textureFormat: -3 + maxTextureSize: 1024 + textureSettings: + filterMode: -1 + aniso: 1 + mipBias: -1 + wrapMode: 1 + nPOTScale: 0 + lightmap: 0 + compressionQuality: 50 + textureType: 2 + buildTargetSettings: [] + userData: diff --git a/Assets/Behavior Designer Movement/Editor/Icons/DarkSearchIcon.png b/Assets/Behavior Designer Movement/Editor/Icons/DarkSearchIcon.png new file mode 100644 index 0000000..7d28970 Binary files /dev/null and b/Assets/Behavior Designer Movement/Editor/Icons/DarkSearchIcon.png differ diff --git a/Assets/Behavior Designer Movement/Editor/Icons/DarkSearchIcon.png.meta b/Assets/Behavior Designer Movement/Editor/Icons/DarkSearchIcon.png.meta new file mode 100644 index 0000000..a463849 --- /dev/null +++ b/Assets/Behavior Designer Movement/Editor/Icons/DarkSearchIcon.png.meta @@ -0,0 +1,35 @@ +fileFormatVersion: 2 +guid: 6e61dc457d90a294783c6cae5443b5f6 +TextureImporter: + serializedVersion: 2 + mipmaps: + mipMapMode: 0 + enableMipMap: 0 + linearTexture: 1 + correctGamma: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: .25 + normalMapFilter: 0 + isReadable: 0 + grayScaleToAlpha: 0 + generateCubemap: 0 + seamlessCubemap: 0 + textureFormat: -3 + maxTextureSize: 1024 + textureSettings: + filterMode: -1 + aniso: 1 + mipBias: -1 + wrapMode: 1 + nPOTScale: 0 + lightmap: 0 + compressionQuality: 50 + textureType: 2 + buildTargetSettings: [] + userData: diff --git a/Assets/Behavior Designer Movement/Editor/Icons/DarkSeekIcon.png b/Assets/Behavior Designer Movement/Editor/Icons/DarkSeekIcon.png new file mode 100644 index 0000000..f8f86d4 Binary files /dev/null and b/Assets/Behavior Designer Movement/Editor/Icons/DarkSeekIcon.png differ diff --git a/Assets/Behavior Designer Movement/Editor/Icons/DarkSeekIcon.png.meta b/Assets/Behavior Designer Movement/Editor/Icons/DarkSeekIcon.png.meta new file mode 100644 index 0000000..a0ea5ef --- /dev/null +++ b/Assets/Behavior Designer Movement/Editor/Icons/DarkSeekIcon.png.meta @@ -0,0 +1,35 @@ +fileFormatVersion: 2 +guid: 9f01c6fc9429bae4bacb3d426405ffe4 +TextureImporter: + serializedVersion: 2 + mipmaps: + mipMapMode: 0 + enableMipMap: 0 + linearTexture: 1 + correctGamma: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: .25 + normalMapFilter: 0 + isReadable: 0 + grayScaleToAlpha: 0 + generateCubemap: 0 + seamlessCubemap: 0 + textureFormat: -3 + maxTextureSize: 1024 + textureSettings: + filterMode: -1 + aniso: 1 + mipBias: -1 + wrapMode: 1 + nPOTScale: 0 + lightmap: 0 + compressionQuality: 50 + textureType: 2 + buildTargetSettings: [] + userData: diff --git a/Assets/Behavior Designer Movement/Editor/Icons/DarkWanderIcon.png b/Assets/Behavior Designer Movement/Editor/Icons/DarkWanderIcon.png new file mode 100644 index 0000000..a7a7cfb Binary files /dev/null and b/Assets/Behavior Designer Movement/Editor/Icons/DarkWanderIcon.png differ diff --git a/Assets/Behavior Designer Movement/Editor/Icons/DarkWanderIcon.png.meta b/Assets/Behavior Designer Movement/Editor/Icons/DarkWanderIcon.png.meta new file mode 100644 index 0000000..d36c793 --- /dev/null +++ b/Assets/Behavior Designer Movement/Editor/Icons/DarkWanderIcon.png.meta @@ -0,0 +1,35 @@ +fileFormatVersion: 2 +guid: cc64e7434e679324c8cb39430f19eda8 +TextureImporter: + serializedVersion: 2 + mipmaps: + mipMapMode: 0 + enableMipMap: 0 + linearTexture: 1 + correctGamma: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: .25 + normalMapFilter: 0 + isReadable: 0 + grayScaleToAlpha: 0 + generateCubemap: 0 + seamlessCubemap: 0 + textureFormat: -3 + maxTextureSize: 1024 + textureSettings: + filterMode: -1 + aniso: 1 + mipBias: -1 + wrapMode: 1 + nPOTScale: 0 + lightmap: 0 + compressionQuality: 50 + textureType: 2 + buildTargetSettings: [] + userData: diff --git a/Assets/Behavior Designer Movement/Editor/Icons/DarkWithinDistanceIcon.png b/Assets/Behavior Designer Movement/Editor/Icons/DarkWithinDistanceIcon.png new file mode 100644 index 0000000..da89f61 Binary files /dev/null and b/Assets/Behavior Designer Movement/Editor/Icons/DarkWithinDistanceIcon.png differ diff --git a/Assets/Behavior Designer Movement/Editor/Icons/DarkWithinDistanceIcon.png.meta b/Assets/Behavior Designer Movement/Editor/Icons/DarkWithinDistanceIcon.png.meta new file mode 100644 index 0000000..78c979d --- /dev/null +++ b/Assets/Behavior Designer Movement/Editor/Icons/DarkWithinDistanceIcon.png.meta @@ -0,0 +1,35 @@ +fileFormatVersion: 2 +guid: 0e2ffa7c5e610214eb6d5c71613bbdec +TextureImporter: + serializedVersion: 2 + mipmaps: + mipMapMode: 0 + enableMipMap: 0 + linearTexture: 1 + correctGamma: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: .25 + normalMapFilter: 0 + isReadable: 0 + grayScaleToAlpha: 0 + generateCubemap: 0 + seamlessCubemap: 0 + textureFormat: -3 + maxTextureSize: 1024 + textureSettings: + filterMode: -1 + aniso: 1 + mipBias: -1 + wrapMode: 1 + nPOTScale: 0 + lightmap: 0 + compressionQuality: 50 + textureType: 2 + buildTargetSettings: [] + userData: diff --git a/Assets/Behavior Designer Movement/Editor/Icons/LightCanHearObjectIcon.png b/Assets/Behavior Designer Movement/Editor/Icons/LightCanHearObjectIcon.png new file mode 100644 index 0000000..1320213 Binary files /dev/null and b/Assets/Behavior Designer Movement/Editor/Icons/LightCanHearObjectIcon.png differ diff --git a/Assets/Behavior Designer Movement/Editor/Icons/LightCanHearObjectIcon.png.meta b/Assets/Behavior Designer Movement/Editor/Icons/LightCanHearObjectIcon.png.meta new file mode 100644 index 0000000..c8b8e5b --- /dev/null +++ b/Assets/Behavior Designer Movement/Editor/Icons/LightCanHearObjectIcon.png.meta @@ -0,0 +1,35 @@ +fileFormatVersion: 2 +guid: a464405df8e82b24db602534724b5e6f +TextureImporter: + serializedVersion: 2 + mipmaps: + mipMapMode: 0 + enableMipMap: 0 + linearTexture: 1 + correctGamma: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: .25 + normalMapFilter: 0 + isReadable: 0 + grayScaleToAlpha: 0 + generateCubemap: 0 + seamlessCubemap: 0 + textureFormat: -3 + maxTextureSize: 1024 + textureSettings: + filterMode: -1 + aniso: 1 + mipBias: -1 + wrapMode: 1 + nPOTScale: 0 + lightmap: 0 + compressionQuality: 50 + textureType: 2 + buildTargetSettings: [] + userData: diff --git a/Assets/Behavior Designer Movement/Editor/Icons/LightCanSeeObjectIcon.png b/Assets/Behavior Designer Movement/Editor/Icons/LightCanSeeObjectIcon.png new file mode 100644 index 0000000..aec212e Binary files /dev/null and b/Assets/Behavior Designer Movement/Editor/Icons/LightCanSeeObjectIcon.png differ diff --git a/Assets/Behavior Designer Movement/Editor/Icons/LightCanSeeObjectIcon.png.meta b/Assets/Behavior Designer Movement/Editor/Icons/LightCanSeeObjectIcon.png.meta new file mode 100644 index 0000000..f6f2a11 --- /dev/null +++ b/Assets/Behavior Designer Movement/Editor/Icons/LightCanSeeObjectIcon.png.meta @@ -0,0 +1,35 @@ +fileFormatVersion: 2 +guid: c3873913d6f08e44d8f24b80257edf45 +TextureImporter: + serializedVersion: 2 + mipmaps: + mipMapMode: 0 + enableMipMap: 0 + linearTexture: 1 + correctGamma: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: .25 + normalMapFilter: 0 + isReadable: 0 + grayScaleToAlpha: 0 + generateCubemap: 0 + seamlessCubemap: 0 + textureFormat: -3 + maxTextureSize: 1024 + textureSettings: + filterMode: -1 + aniso: 1 + mipBias: -1 + wrapMode: 1 + nPOTScale: 0 + lightmap: 0 + compressionQuality: 50 + textureType: 2 + buildTargetSettings: [] + userData: diff --git a/Assets/Behavior Designer Movement/Editor/Icons/LightCoverIcon.png b/Assets/Behavior Designer Movement/Editor/Icons/LightCoverIcon.png new file mode 100644 index 0000000..7f45485 Binary files /dev/null and b/Assets/Behavior Designer Movement/Editor/Icons/LightCoverIcon.png differ diff --git a/Assets/Behavior Designer Movement/Editor/Icons/LightCoverIcon.png.meta b/Assets/Behavior Designer Movement/Editor/Icons/LightCoverIcon.png.meta new file mode 100644 index 0000000..961c0cb --- /dev/null +++ b/Assets/Behavior Designer Movement/Editor/Icons/LightCoverIcon.png.meta @@ -0,0 +1,35 @@ +fileFormatVersion: 2 +guid: c91b8fe3d68a9114dafd557a82d821d8 +TextureImporter: + serializedVersion: 2 + mipmaps: + mipMapMode: 0 + enableMipMap: 0 + linearTexture: 1 + correctGamma: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: .25 + normalMapFilter: 0 + isReadable: 0 + grayScaleToAlpha: 0 + generateCubemap: 0 + seamlessCubemap: 0 + textureFormat: -3 + maxTextureSize: 1024 + textureSettings: + filterMode: -1 + aniso: 1 + mipBias: -1 + wrapMode: 1 + nPOTScale: 0 + lightmap: 0 + compressionQuality: 50 + textureType: 2 + buildTargetSettings: [] + userData: diff --git a/Assets/Behavior Designer Movement/Editor/Icons/LightEvadeIcon.png b/Assets/Behavior Designer Movement/Editor/Icons/LightEvadeIcon.png new file mode 100644 index 0000000..2ca882e Binary files /dev/null and b/Assets/Behavior Designer Movement/Editor/Icons/LightEvadeIcon.png differ diff --git a/Assets/Behavior Designer Movement/Editor/Icons/LightEvadeIcon.png.meta b/Assets/Behavior Designer Movement/Editor/Icons/LightEvadeIcon.png.meta new file mode 100644 index 0000000..d1a7a73 --- /dev/null +++ b/Assets/Behavior Designer Movement/Editor/Icons/LightEvadeIcon.png.meta @@ -0,0 +1,35 @@ +fileFormatVersion: 2 +guid: cecc9277e75f9964e98d167be763695c +TextureImporter: + serializedVersion: 2 + mipmaps: + mipMapMode: 0 + enableMipMap: 0 + linearTexture: 1 + correctGamma: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: .25 + normalMapFilter: 0 + isReadable: 0 + grayScaleToAlpha: 0 + generateCubemap: 0 + seamlessCubemap: 0 + textureFormat: -3 + maxTextureSize: 1024 + textureSettings: + filterMode: -1 + aniso: 1 + mipBias: -1 + wrapMode: 1 + nPOTScale: 0 + lightmap: 0 + compressionQuality: 50 + textureType: 2 + buildTargetSettings: [] + userData: diff --git a/Assets/Behavior Designer Movement/Editor/Icons/LightFleeIcon.png b/Assets/Behavior Designer Movement/Editor/Icons/LightFleeIcon.png new file mode 100644 index 0000000..faff71a Binary files /dev/null and b/Assets/Behavior Designer Movement/Editor/Icons/LightFleeIcon.png differ diff --git a/Assets/Behavior Designer Movement/Editor/Icons/LightFleeIcon.png.meta b/Assets/Behavior Designer Movement/Editor/Icons/LightFleeIcon.png.meta new file mode 100644 index 0000000..8b88e25 --- /dev/null +++ b/Assets/Behavior Designer Movement/Editor/Icons/LightFleeIcon.png.meta @@ -0,0 +1,35 @@ +fileFormatVersion: 2 +guid: e5f0ffa5bd82433428ba4d2dd58d57d8 +TextureImporter: + serializedVersion: 2 + mipmaps: + mipMapMode: 0 + enableMipMap: 0 + linearTexture: 1 + correctGamma: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: .25 + normalMapFilter: 0 + isReadable: 0 + grayScaleToAlpha: 0 + generateCubemap: 0 + seamlessCubemap: 0 + textureFormat: -3 + maxTextureSize: 1024 + textureSettings: + filterMode: -1 + aniso: 1 + mipBias: -1 + wrapMode: 1 + nPOTScale: 0 + lightmap: 0 + compressionQuality: 50 + textureType: 2 + buildTargetSettings: [] + userData: diff --git a/Assets/Behavior Designer Movement/Editor/Icons/LightFlockIcon.png b/Assets/Behavior Designer Movement/Editor/Icons/LightFlockIcon.png new file mode 100644 index 0000000..2ece217 Binary files /dev/null and b/Assets/Behavior Designer Movement/Editor/Icons/LightFlockIcon.png differ diff --git a/Assets/Behavior Designer Movement/Editor/Icons/LightFlockIcon.png.meta b/Assets/Behavior Designer Movement/Editor/Icons/LightFlockIcon.png.meta new file mode 100644 index 0000000..06122f3 --- /dev/null +++ b/Assets/Behavior Designer Movement/Editor/Icons/LightFlockIcon.png.meta @@ -0,0 +1,35 @@ +fileFormatVersion: 2 +guid: 5c4c8ca7a2b26d648ad1b3009d8ee3d6 +TextureImporter: + serializedVersion: 2 + mipmaps: + mipMapMode: 0 + enableMipMap: 0 + linearTexture: 1 + correctGamma: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: .25 + normalMapFilter: 0 + isReadable: 0 + grayScaleToAlpha: 0 + generateCubemap: 0 + seamlessCubemap: 0 + textureFormat: -3 + maxTextureSize: 1024 + textureSettings: + filterMode: -1 + aniso: 1 + mipBias: -1 + wrapMode: 1 + nPOTScale: 0 + lightmap: 0 + compressionQuality: 50 + textureType: 2 + buildTargetSettings: [] + userData: diff --git a/Assets/Behavior Designer Movement/Editor/Icons/LightFollowIcon.png b/Assets/Behavior Designer Movement/Editor/Icons/LightFollowIcon.png new file mode 100644 index 0000000..af46617 Binary files /dev/null and b/Assets/Behavior Designer Movement/Editor/Icons/LightFollowIcon.png differ diff --git a/Assets/Behavior Designer Movement/Editor/Icons/LightFollowIcon.png.meta b/Assets/Behavior Designer Movement/Editor/Icons/LightFollowIcon.png.meta new file mode 100644 index 0000000..35df575 --- /dev/null +++ b/Assets/Behavior Designer Movement/Editor/Icons/LightFollowIcon.png.meta @@ -0,0 +1,55 @@ +fileFormatVersion: 2 +guid: 815ba0528c01fe940bd4d5b51bf80773 +timeCreated: 1471183834 +licenseType: Store +TextureImporter: + fileIDToRecycleName: {} + serializedVersion: 2 + mipmaps: + mipMapMode: 0 + enableMipMap: 0 + linearTexture: 1 + correctGamma: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: .25 + normalMapFilter: 0 + isReadable: 0 + grayScaleToAlpha: 0 + generateCubemap: 0 + cubemapConvolution: 0 + cubemapConvolutionSteps: 8 + cubemapConvolutionExponent: 1.5 + seamlessCubemap: 0 + textureFormat: -3 + maxTextureSize: 2048 + textureSettings: + filterMode: -1 + aniso: 1 + mipBias: -1 + wrapMode: 1 + nPOTScale: 0 + lightmap: 0 + rGBM: 0 + compressionQuality: 50 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: .5, y: .5} + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spritePixelsToUnits: 100 + alphaIsTransparency: 1 + textureType: 2 + buildTargetSettings: [] + spriteSheet: + sprites: [] + spritePackingTag: + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Behavior Designer Movement/Editor/Icons/LightLeaderFollowIcon.png b/Assets/Behavior Designer Movement/Editor/Icons/LightLeaderFollowIcon.png new file mode 100644 index 0000000..17782f7 Binary files /dev/null and b/Assets/Behavior Designer Movement/Editor/Icons/LightLeaderFollowIcon.png differ diff --git a/Assets/Behavior Designer Movement/Editor/Icons/LightLeaderFollowIcon.png.meta b/Assets/Behavior Designer Movement/Editor/Icons/LightLeaderFollowIcon.png.meta new file mode 100644 index 0000000..e5d0b00 --- /dev/null +++ b/Assets/Behavior Designer Movement/Editor/Icons/LightLeaderFollowIcon.png.meta @@ -0,0 +1,35 @@ +fileFormatVersion: 2 +guid: 9ef93ef9a60e48449a642b1b3b2b577d +TextureImporter: + serializedVersion: 2 + mipmaps: + mipMapMode: 0 + enableMipMap: 0 + linearTexture: 1 + correctGamma: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: .25 + normalMapFilter: 0 + isReadable: 0 + grayScaleToAlpha: 0 + generateCubemap: 0 + seamlessCubemap: 0 + textureFormat: -3 + maxTextureSize: 1024 + textureSettings: + filterMode: -1 + aniso: 1 + mipBias: -1 + wrapMode: 1 + nPOTScale: 0 + lightmap: 0 + compressionQuality: 50 + textureType: 2 + buildTargetSettings: [] + userData: diff --git a/Assets/Behavior Designer Movement/Editor/Icons/LightMoveTowardsIcon.png b/Assets/Behavior Designer Movement/Editor/Icons/LightMoveTowardsIcon.png new file mode 100644 index 0000000..6b49dd3 Binary files /dev/null and b/Assets/Behavior Designer Movement/Editor/Icons/LightMoveTowardsIcon.png differ diff --git a/Assets/Behavior Designer Movement/Editor/Icons/LightMoveTowardsIcon.png.meta b/Assets/Behavior Designer Movement/Editor/Icons/LightMoveTowardsIcon.png.meta new file mode 100644 index 0000000..ebc74c6 --- /dev/null +++ b/Assets/Behavior Designer Movement/Editor/Icons/LightMoveTowardsIcon.png.meta @@ -0,0 +1,35 @@ +fileFormatVersion: 2 +guid: c8e612848487a184f9090d416c932c47 +TextureImporter: + serializedVersion: 2 + mipmaps: + mipMapMode: 0 + enableMipMap: 0 + linearTexture: 1 + correctGamma: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: .25 + normalMapFilter: 0 + isReadable: 0 + grayScaleToAlpha: 0 + generateCubemap: 0 + seamlessCubemap: 0 + textureFormat: -3 + maxTextureSize: 1024 + textureSettings: + filterMode: -1 + aniso: 1 + mipBias: -1 + wrapMode: 1 + nPOTScale: 0 + lightmap: 0 + compressionQuality: 50 + textureType: 2 + buildTargetSettings: [] + userData: diff --git a/Assets/Behavior Designer Movement/Editor/Icons/LightPatrolIcon.png b/Assets/Behavior Designer Movement/Editor/Icons/LightPatrolIcon.png new file mode 100644 index 0000000..7063c9f Binary files /dev/null and b/Assets/Behavior Designer Movement/Editor/Icons/LightPatrolIcon.png differ diff --git a/Assets/Behavior Designer Movement/Editor/Icons/LightPatrolIcon.png.meta b/Assets/Behavior Designer Movement/Editor/Icons/LightPatrolIcon.png.meta new file mode 100644 index 0000000..1498172 --- /dev/null +++ b/Assets/Behavior Designer Movement/Editor/Icons/LightPatrolIcon.png.meta @@ -0,0 +1,35 @@ +fileFormatVersion: 2 +guid: 9db06eafffd691549994cfe903905580 +TextureImporter: + serializedVersion: 2 + mipmaps: + mipMapMode: 0 + enableMipMap: 0 + linearTexture: 1 + correctGamma: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: .25 + normalMapFilter: 0 + isReadable: 0 + grayScaleToAlpha: 0 + generateCubemap: 0 + seamlessCubemap: 0 + textureFormat: -3 + maxTextureSize: 1024 + textureSettings: + filterMode: -1 + aniso: 1 + mipBias: -1 + wrapMode: 1 + nPOTScale: 0 + lightmap: 0 + compressionQuality: 50 + textureType: 2 + buildTargetSettings: [] + userData: diff --git a/Assets/Behavior Designer Movement/Editor/Icons/LightPursueIcon.png b/Assets/Behavior Designer Movement/Editor/Icons/LightPursueIcon.png new file mode 100644 index 0000000..57cff61 Binary files /dev/null and b/Assets/Behavior Designer Movement/Editor/Icons/LightPursueIcon.png differ diff --git a/Assets/Behavior Designer Movement/Editor/Icons/LightPursueIcon.png.meta b/Assets/Behavior Designer Movement/Editor/Icons/LightPursueIcon.png.meta new file mode 100644 index 0000000..c67a383 --- /dev/null +++ b/Assets/Behavior Designer Movement/Editor/Icons/LightPursueIcon.png.meta @@ -0,0 +1,35 @@ +fileFormatVersion: 2 +guid: e1387dd5098c1f7449253a17b3b39784 +TextureImporter: + serializedVersion: 2 + mipmaps: + mipMapMode: 0 + enableMipMap: 0 + linearTexture: 1 + correctGamma: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: .25 + normalMapFilter: 0 + isReadable: 0 + grayScaleToAlpha: 0 + generateCubemap: 0 + seamlessCubemap: 0 + textureFormat: -3 + maxTextureSize: 1024 + textureSettings: + filterMode: -1 + aniso: 1 + mipBias: -1 + wrapMode: 1 + nPOTScale: 0 + lightmap: 0 + compressionQuality: 50 + textureType: 2 + buildTargetSettings: [] + userData: diff --git a/Assets/Behavior Designer Movement/Editor/Icons/LightQueueIcon.png b/Assets/Behavior Designer Movement/Editor/Icons/LightQueueIcon.png new file mode 100644 index 0000000..4dd3ad3 Binary files /dev/null and b/Assets/Behavior Designer Movement/Editor/Icons/LightQueueIcon.png differ diff --git a/Assets/Behavior Designer Movement/Editor/Icons/LightQueueIcon.png.meta b/Assets/Behavior Designer Movement/Editor/Icons/LightQueueIcon.png.meta new file mode 100644 index 0000000..1d34ac3 --- /dev/null +++ b/Assets/Behavior Designer Movement/Editor/Icons/LightQueueIcon.png.meta @@ -0,0 +1,35 @@ +fileFormatVersion: 2 +guid: c671469908c78284c909ff1905020250 +TextureImporter: + serializedVersion: 2 + mipmaps: + mipMapMode: 0 + enableMipMap: 0 + linearTexture: 1 + correctGamma: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: .25 + normalMapFilter: 0 + isReadable: 0 + grayScaleToAlpha: 0 + generateCubemap: 0 + seamlessCubemap: 0 + textureFormat: -3 + maxTextureSize: 1024 + textureSettings: + filterMode: -1 + aniso: 1 + mipBias: -1 + wrapMode: 1 + nPOTScale: 0 + lightmap: 0 + compressionQuality: 50 + textureType: 2 + buildTargetSettings: [] + userData: diff --git a/Assets/Behavior Designer Movement/Editor/Icons/LightRotateTowardsIcon.png b/Assets/Behavior Designer Movement/Editor/Icons/LightRotateTowardsIcon.png new file mode 100644 index 0000000..628dec7 Binary files /dev/null and b/Assets/Behavior Designer Movement/Editor/Icons/LightRotateTowardsIcon.png differ diff --git a/Assets/Behavior Designer Movement/Editor/Icons/LightRotateTowardsIcon.png.meta b/Assets/Behavior Designer Movement/Editor/Icons/LightRotateTowardsIcon.png.meta new file mode 100644 index 0000000..59920eb --- /dev/null +++ b/Assets/Behavior Designer Movement/Editor/Icons/LightRotateTowardsIcon.png.meta @@ -0,0 +1,35 @@ +fileFormatVersion: 2 +guid: 04fb8138ea905c04ea39265f778fe1a4 +TextureImporter: + serializedVersion: 2 + mipmaps: + mipMapMode: 0 + enableMipMap: 0 + linearTexture: 1 + correctGamma: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: .25 + normalMapFilter: 0 + isReadable: 0 + grayScaleToAlpha: 0 + generateCubemap: 0 + seamlessCubemap: 0 + textureFormat: -3 + maxTextureSize: 1024 + textureSettings: + filterMode: -1 + aniso: 1 + mipBias: -1 + wrapMode: 1 + nPOTScale: 0 + lightmap: 0 + compressionQuality: 50 + textureType: 2 + buildTargetSettings: [] + userData: diff --git a/Assets/Behavior Designer Movement/Editor/Icons/LightSearchIcon.png b/Assets/Behavior Designer Movement/Editor/Icons/LightSearchIcon.png new file mode 100644 index 0000000..4e7e3cb Binary files /dev/null and b/Assets/Behavior Designer Movement/Editor/Icons/LightSearchIcon.png differ diff --git a/Assets/Behavior Designer Movement/Editor/Icons/LightSearchIcon.png.meta b/Assets/Behavior Designer Movement/Editor/Icons/LightSearchIcon.png.meta new file mode 100644 index 0000000..9fd1b65 --- /dev/null +++ b/Assets/Behavior Designer Movement/Editor/Icons/LightSearchIcon.png.meta @@ -0,0 +1,35 @@ +fileFormatVersion: 2 +guid: 0ebd85be99a56804b9b63041ad4a7d42 +TextureImporter: + serializedVersion: 2 + mipmaps: + mipMapMode: 0 + enableMipMap: 0 + linearTexture: 1 + correctGamma: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: .25 + normalMapFilter: 0 + isReadable: 0 + grayScaleToAlpha: 0 + generateCubemap: 0 + seamlessCubemap: 0 + textureFormat: -3 + maxTextureSize: 1024 + textureSettings: + filterMode: -1 + aniso: 1 + mipBias: -1 + wrapMode: 1 + nPOTScale: 0 + lightmap: 0 + compressionQuality: 50 + textureType: 2 + buildTargetSettings: [] + userData: diff --git a/Assets/Behavior Designer Movement/Editor/Icons/LightSeekIcon.png b/Assets/Behavior Designer Movement/Editor/Icons/LightSeekIcon.png new file mode 100644 index 0000000..e19c30a Binary files /dev/null and b/Assets/Behavior Designer Movement/Editor/Icons/LightSeekIcon.png differ diff --git a/Assets/Behavior Designer Movement/Editor/Icons/LightSeekIcon.png.meta b/Assets/Behavior Designer Movement/Editor/Icons/LightSeekIcon.png.meta new file mode 100644 index 0000000..0295b4d --- /dev/null +++ b/Assets/Behavior Designer Movement/Editor/Icons/LightSeekIcon.png.meta @@ -0,0 +1,35 @@ +fileFormatVersion: 2 +guid: 3278c95539f686f47a519013713b31ac +TextureImporter: + serializedVersion: 2 + mipmaps: + mipMapMode: 0 + enableMipMap: 0 + linearTexture: 1 + correctGamma: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: .25 + normalMapFilter: 0 + isReadable: 0 + grayScaleToAlpha: 0 + generateCubemap: 0 + seamlessCubemap: 0 + textureFormat: -3 + maxTextureSize: 1024 + textureSettings: + filterMode: -1 + aniso: 1 + mipBias: -1 + wrapMode: 1 + nPOTScale: 0 + lightmap: 0 + compressionQuality: 50 + textureType: 2 + buildTargetSettings: [] + userData: diff --git a/Assets/Behavior Designer Movement/Editor/Icons/LightWanderIcon.png b/Assets/Behavior Designer Movement/Editor/Icons/LightWanderIcon.png new file mode 100644 index 0000000..ea9d69e Binary files /dev/null and b/Assets/Behavior Designer Movement/Editor/Icons/LightWanderIcon.png differ diff --git a/Assets/Behavior Designer Movement/Editor/Icons/LightWanderIcon.png.meta b/Assets/Behavior Designer Movement/Editor/Icons/LightWanderIcon.png.meta new file mode 100644 index 0000000..3404334 --- /dev/null +++ b/Assets/Behavior Designer Movement/Editor/Icons/LightWanderIcon.png.meta @@ -0,0 +1,35 @@ +fileFormatVersion: 2 +guid: d66ad6d158b592d46afdb28a7c6216a8 +TextureImporter: + serializedVersion: 2 + mipmaps: + mipMapMode: 0 + enableMipMap: 0 + linearTexture: 1 + correctGamma: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: .25 + normalMapFilter: 0 + isReadable: 0 + grayScaleToAlpha: 0 + generateCubemap: 0 + seamlessCubemap: 0 + textureFormat: -3 + maxTextureSize: 1024 + textureSettings: + filterMode: -1 + aniso: 1 + mipBias: -1 + wrapMode: 1 + nPOTScale: 0 + lightmap: 0 + compressionQuality: 50 + textureType: 2 + buildTargetSettings: [] + userData: diff --git a/Assets/Behavior Designer Movement/Editor/Icons/LightWithinDistanceIcon.png b/Assets/Behavior Designer Movement/Editor/Icons/LightWithinDistanceIcon.png new file mode 100644 index 0000000..0c692ae Binary files /dev/null and b/Assets/Behavior Designer Movement/Editor/Icons/LightWithinDistanceIcon.png differ diff --git a/Assets/Behavior Designer Movement/Editor/Icons/LightWithinDistanceIcon.png.meta b/Assets/Behavior Designer Movement/Editor/Icons/LightWithinDistanceIcon.png.meta new file mode 100644 index 0000000..f37c258 --- /dev/null +++ b/Assets/Behavior Designer Movement/Editor/Icons/LightWithinDistanceIcon.png.meta @@ -0,0 +1,35 @@ +fileFormatVersion: 2 +guid: 62dc1c328b5c4eb45a90ec7a75cfb747 +TextureImporter: + serializedVersion: 2 + mipmaps: + mipMapMode: 0 + enableMipMap: 0 + linearTexture: 1 + correctGamma: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: .25 + normalMapFilter: 0 + isReadable: 0 + grayScaleToAlpha: 0 + generateCubemap: 0 + seamlessCubemap: 0 + textureFormat: -3 + maxTextureSize: 1024 + textureSettings: + filterMode: -1 + aniso: 1 + mipBias: -1 + wrapMode: 1 + nPOTScale: 0 + lightmap: 0 + compressionQuality: 50 + textureType: 2 + buildTargetSettings: [] + userData: diff --git a/Assets/Behavior Designer Movement/FactoryRoom_1.cubemap b/Assets/Behavior Designer Movement/FactoryRoom_1.cubemap new file mode 100644 index 0000000..83b8928 --- /dev/null +++ b/Assets/Behavior Designer Movement/FactoryRoom_1.cubemap @@ -0,0 +1,37 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!89 &8900000 +Cubemap: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_Name: FactoryRoom_1 + m_AlphaIsTransparency: 0 + m_Width: 32 + m_Height: 32 + m_CompleteImageSize: 4096 + m_TextureFormat: 5 + m_MipMap: 0 + m_IsReadable: 1 + m_ReadAllowed: 1 + m_ImageCount: 6 + m_TextureDimension: 2 + m_TextureSettings: + m_FilterMode: 1 + m_Aniso: 1 + m_MipBias: 0 + m_WrapMode: 1 + m_LightmapFormat: 0 + m_ColorSpace: 0 + image data: 24576 + _typelessdata: 80354e5e80344d6180344c6080324b5f80314a5e8031495c802d475a802d475a802c4659802c4559802c4457802c4457802c4457802c4457802b445780334a58802e4556802c4457802b44588031475a80294358802c465a802d475a802e485b80304a5effaf8e6195614d3cb682653cc98d6f44f397774ce48c6e46c3836744803c56698038536580364f6380344d6280344c6080324b5f80314a5e80314a5d802f485a802d475a802d475a802d465a802d4659802c4659802c465980f9fefd80263f47802d465a80424b4e80f6feff802e485b8030495c80314a5d80324c5fffc4a170aa836941b189693fa98267407e7a623dd58c7147d2866b48d78d724a80405b6d803f596b803c566a803a56688037506380344d6380344c6180344c6080324b5f80314a5e80314a5e80314a5c802f495c802f495b802f485a80f7fdfb8024414c80314a5c803e494e80f7ffff80324c5f80334c6180344d62da7f6e50ffa2804ebd856b40a884663fa6826a41cd866d45fb8d724aeb8f724af793754a80435e7080425c6f80415a6d803f5a6c803f586b803c5669803853668037506380364e6380354e6180344d6180344c6080334c5f80324c5f80324c5f80fdfefd80243f4c80344d61803c4a4e80f7feff803650638036516480375265ffa98452fc9e7d4cd48e7044b9876a41e09c7b50ba836943cf8d6f48f594754bf09473498045607080455f7080445f7180435e708045677a806a98a3803f596c80b6d6dc803a5260803a5569803652638036506480365164803651648036516480fbffff802d464c803751648046535680f2f9fb80395469803a5567ca957549dd977747f0a4814ec38a6f44dc92744795806640c2896e45c386683faa7d5f3b8a7b5c37804762728047617180466070804560708046697e805c93a580435e7080add5de8044627180405b6d803f5a6c803f5a6c803e586c803e586c803d586b801a1f1e80202a31803e586c8027353d80181f2280435d70ffd0a875b6957346ab8b6d42e69b7848a2886b42ae886a3fc6917246b1876a409483673b9381623b50574026ddc0975d804c6675804a647380486273804b6e7e806fa4b280465f7180b3d9dc8047667380445f7380445f7280435e7380435e7380435e7180435e7180435e7280435e7280435e7380455f7380466174be7b6b51da967447bf967244b6866a40c38f6f44ac81673c9985663dc78e6f41997a5f37444b3229aa85643dba82613cca8b6740dcfac77c93717975804f6a78804e6a7780425a6180496473805d6d71804964708046617380476273804761738047627380476274804762758047637580496475804a6577804a6578804a6576cc9e7c4bb2917142d39b7647b6917043b487683eaa8a6e42b8917144be856840c289693ea481623bb6725734c36e54338e5e6b6de0ad774ad5a47b4bc27f5d3b80556f7e80546f7e80536e7c80506b7980506a78804d6776804b6776804b6675804b6675804b6675804b6676804b6677804b6678804b6679804b6979ddb38f5cbd9b7545b3927344af916f449f8e6d42b6917046d59c7847b4896b41b9886b3fd08d693fc3765735dc6d4f2cbd7d5935805e7881805d7782805d7781e1ac7448dfb28754ad6557468058737f80577380805773818056717f8055707e8056717f8054717f80536f7f80536f7e80547080805472818054728180577381baa17e4b9e886a3e99896c42bc957041c5937044de957349d49e7b4bb892714558554026d77e5d38e9a06f40b0875f34957e562f8067808780667e8780647d8680637c8480627c84dca87547d86f5234805d7882805d7883805d7884805d7784805d7784805c7784805b7884805d7885805d7986805d7a87805e7a87b87e7c6bac9572449a907042bb9d7849bf947145e79c794ae299734ab99771459e6c502fa27a5732eb9a6c3cd3946538473c27161f22150b9877786c806b8285806b828780698288806c858980698489e06c543dd865513903d0b188806681898065808880647f8880647f8880647f8880647f8a8065808b8065818a8067828ccf9d7c4ecba17e4da6977446b0947347c19c784be49f7a4c334c3a23bc85613bc8956739d9926538706642242a371e101d22140b94794f28454d412e524e412e465a4c363062523b806d8284d9554632d6755135b6957551806d8386806d8488806e8589806f868a8070878a8070888c8070898c8071898d80718a8f80718b909f806641eeb08b57aa8c6c42af937446988c6d46bd805d3aaf8d6036d797663b6d6543272229180d1c21140be59a693cf48d6239ba7f7662e8594932f59a7f58ff907952d38f7652dbac8e63ab776245294f4432c07a6548827486848073868480718584807386848073868480738685807488868075898880768a8880778a8980778b89daa27f4fb38c6d4263533f27d1825d37ba855c3583593b222228180d2221140be57c5532ef815d37807a8a858079898580798985f85f4e34f5846a48fa846e4cd06d5c42de776343e7937a56f75c4d34d7766142b14b412d674d412f6653473580717d7980737f7c80737f7c8073807c8073827e807483808e5e67637c171510341d1b16d1684e2db66c4d2bad5f44252f19110be3312112e64e361fbf6a6355807483808076817e62606459574c4535764f463645231f18b0685539543a3026402f271d43372f22503d3426704033249342362699564732c2241d15d453473835584d3a8d5a4e3bd4b79e7d6da19170cdc0ab8ad5b8a384189d9a7ecc86765dd57e6e56403e3326403a2b1c3e3b2a1ce91e1c18cc1e1b15e317130ee21b1812d0443b2fcc373026c72a261eca2c251e65322c243a332d23c9866c4c40342d24532620184b27211931312a205d5c4c355c2f281b21231e19d1544530c8615139ccffffb7d1958263d2ab8f6accffffc9d19e8a6cd2564b3cdacdc37bd1ac9270d29985672e30271d2c35271945422c1bae33322fde2a2013660f0d0af5312b1fef453b27422e291ede67563ce85b4a31413e3627251e1c15d0876b4b9a837051f4615039e9766043d58d724cf49b80588732291ec22a2116dc5d4b31fd7b6748d98a5c2d16a9946302797a45024b4a2aca73664bc73e3428d6ab8e65ff7d5e41c8917b5941281f16383325184d452e1bce332a1de31c150beb57472bf877644398694f2532211d163d2a251d756e552f74514124f57b6446fe977753d1977c60c664523dc8564836da65553fd18b755ac54b36209f1a1209e2685134b64b371fd3462e1500574a2d06736f480595955ad0322b1c323d32201f18160ef97f6b4bff5f47302c0806052819120d1c070503ff3c2818ff412f1d351d1610ff624e31fd584525d1292218e63b3425ed52442cd95a4a31d8624e3b002e261cd99f8365c2564531e45f4228e05b4026c8564025b143341e5d84b9abac442313ff4f3d259a3c2e170d413a243d4c4c2e10232416791c18101f1d170f413a301e220c0a07f168543818100b07351d120b2d1d1109250f0905fe5a3d25702f21165a19140d5719140b282b2318001a181403725f3a8f785d46001c181200897456e96c4b2cd562482bd8604629cb584127a63f301ccb43301d314860537c2d22138c71694423504c387c6e654b144543349c564e38905d4a34f793785130262219291c170fec7c6141ff553b232b18100a2c1a110a1d130c07de573920f1624326a6443320dd3e3528451a1711000808062e6b685d002a292700a386630079634ad866492ac85a4227ba4b3921e3553b24c73b2c1ab2261e11644733229e867855133b352831393429144f48393d5751420d3b3628c992754c966953372b2a251a3830261af3836544ff593f282c1e130b2225150c2723150c6e372213ff5638205b67573e8c796c510d332e23ce987a52de886b49f56152391e523c2c0046362887825f3a002a2724de784b29cc3629187c1b150c31352f2484847352a59c8a66727f6f527b7168507a7a6e55ab8b816596857a5ed295764ecc8d6f4b2119150d2422190f7d694f35ff9573512319100a1d180f082323140b160d0804da6b4828b87f745a9072674eae897e60ac665138f5654c33f64234245e7e4f34da6b44273a874729072c2721cf34261632352e232c3c3225808d795690786d564775432a588c5d435f935b3f92a96a486da16e5164a05f43d190724be593734c221f190e19110e09937c6242f7a37d562218100a201b0f091d180e0819090603ce714b2a5d86563d7583533a5c5a3a27fe5e46304a1a150f8a261d13d36b462be384553150493926b5291d101640392c1c474034dbaf9d7aba887f626a804d317e9d60407da16342236f47307da76646db3b2819d8382717d4846945dc8a6d4821241c102e211a0dae886947ffc596662b0f0b061b150d07271f1209170b0704e9754e2d396f442d919c63455e754c33786e4732674b2a1ba419120cc7744d2cdf7e56324b614a332e2c281f1c1f1b1581a08f6878786b5369b472494f8e513582a364448e844e34ac291e14d3342617c3533f2adc846c49d6896e4bd77e62401e130f091d1b150b8d7d6140eaa47c531b170f09281f120a78503219b1754924ea7e512c868655386094593c72a9724f7c864d325672442d5b543423c16a4b2ad272502d42644f3632302a20e7a49777656d604aa0b66f4b85c27d5653814c31ea392717e63a271655695c473f665c48e6967a53f169563ade433422bf745a3af99d7a50190907048b725436fa9e7950cea36934ffd58742ea9a6031aa663e1f9f6a4020d8493620df3e2919ce69462e45784c337c90563a62643e2bb2604729cd6f4d2c4c503f2da3827359ab706653c3985939bfad6f4c9217110bd6352515b32a1e11375f55423a635846da8f754fd7876d4af6685538b0362d1ddc644b31ff88643fd8765735d57c5e3ced836440f9714927fe744824ee724523c56d4321a96c4424e353371ede593e24e53c2817f24d362092382b1d8b995f3fae544424c969462a4f56402b32443c307d744a347682533be11e140ea72a1c10565e4f3a4871654f3d6d5f49e8856d4ae29e7f54b28e71499e624f34ad4b3e28dc31281af575593bff93714c99564028f4775b39d35d3b1f372d1c0dee774b28bf5a381cf55c381dce4e3119ee5c3d20e5614124745f4f3ab436281ade48331fc05d4128e06d48294c4532218c6d412daf814c33c61e150ef2302013494d3f2c456f634e2f635642f4806745e7806747ae8b7049d793754cdd75613fe55b4c30cd3c3321c23a2b1be4594026e85f452bf46f5436e84e321bd94e3019e34a301ac64f351db44e3018ce653f20d26a4120e0633f21ad634123396c5b43be312314ce644228db5f40258f452b1b70643926bf271a10ca291c103f3a2f213c675a4539685c464073654dd38f714cec705a3bf1a68154ba94794dc9806a43c0635235c95a4a31c2463b27d4332819b1261a0ff05e4327c7372616ce452f1a99573c22c4754f2ac56f4521b26a4220d46e4421fb7a4b26d36e4524ac7552313f786448c65a3b22d24f371f6b3a2417d4301f13c3281c115b2f241839675b454370634c63928263ea896e49cc8d6f48e36a5336fda98453c899794ed08b734adb74603fc65d4f33c152432bc6564026bc47301bbf3c2917da543920a65f4024bb75502d9a734c28a7794b24dd784924c6744622c8764824e27d4d27d7774b275d6d5539803f58678038526580375063803650638036506380354f6380344d6380344d6380354e6380354d6380354d6280e4f5f980eefdfd80374f638037506380acd9e480e8fdff803a5466803c5569803c556b803f576c8042596c80435d7280445e7380455f7380496175804a6477804c6679804e697b804f6a7c80516b7e80536c7f80daf6f680405968803a55678039546680385365803852658038526480375163803750638036516480365164803d5567804f6c7a8039526580395367804e68778064818d803d566b803e586c8042596d80425c708041576980778e9b8040535e804a6679804d677a804f697b80516a7d80536d808051687b80587283805c768880ecfeff80eafbfd80475f6e803f596e803c5668803b5568803a5567803a5567803a5567803a5468803a5568803a5568803a5568803b5569803d566a803d566b803e586c8042596c80425c7080445d728047607480425769808399a2803a454a804e708180516b7f80546e818057708380617e8e805a7377804e636e80617c8e8047617080daf3f980899fad80445e7380425d7180415c7080405a6d803f586b803f586b803d576b803e576b803e586b803e586b803f586c8040596e80415a6f80435d7180455e738047607480486276804b657880465b6b80839aa1803e484e80507386805b7487805d7888805e7a89808ebbc480cfe0e48065819380608b9280476473804a64748048637480486275804762748046617480455f7380455f7380445e7180445d7180405b6f80415b7080425c7180435d7180445d7380455f738047617480486376804a6579804e687b80506b7d80556b7980495c6a8041525b8062798680637d8f8062808f8087b6c280b9ccd480303c418083aeb980c8dce0802c3d47804a6473804a6474804a6576804a6577804a6577804a65768049657780486476804863768049657780496477804a6479804a657a804b677a804d697b804e6a7d80516c7f80556f8280577385805a7587805d788980607b8e8063809180698393806d86968097bec58085a2ad80677d8a80cbebf080698d9a806e879680516b7a804f6a78804d6776804d6776804b6878804b6777804d6878804d6879804f697b804f6a7c804f6b7c80adcbd5804e6c7e80b8d1d680526e8080536f818056728480587486805b7687805d788a80607c8e806a7f8d808ba3a980464f54806e8c9a80708b9980718b9880738c9980768f9c8074909c80748f9c8075909d8055707f805772818055717e80546f7e80526d7b80516c7a80506a79804e6a7a80506a7b804f6b7b80506b7b80acd4e28054708280bad5da8056728580597485805a7788805d788980607b8a80637d8c80668090806d818b808aa1a780404b50806c8f9c80748e9b80728d9a80748f9c807e97a280819aa6808099a5807e98a3805e7884805b7784805b76848058748280587482805a75848058738280587382805873818055717e8057718180b7d9e28058738580bfd6db805b7585805d7787805d798780617b8a80657f8e80688291806b85948070848d808da2a8804a5558807397a3807e98a3807d98a480839ca580849ea78089a1aa80869fa9917e8f9380637b8480617a8480617a84805f798580607b85805e7986805f7987805e7987805f7a88805f7a8880607b89805f7c8980627b8b80647f8c80647f8e8067829080688491806d8795806e8a9780718d9a8075909d8079949f807c99a580849ca580859ea88089a1aa808aa2a9808ba3aa808da6ac808ba4ab94819396d4666357806a8389806b828b806981898069818a806680898065808880647f8980647f8a8065808a8065818c8066818c8068838d8069848f806b8693806d8894806e899480708c9780758f9a8078939c8079959e807e98a180829ca580879fa88088a1a9808da6ad8091a9ad8092aaad8095abae8095abae93879797cc615c512a27251b806f8487806e84888070868a806f868a8070888b806f888c806f888d806f888e806d898f80708a91806f8a90806f8a9280718c9380738e9480758f95807892998079949a807d979d80819aa080839da48088a1a7808da6ab8091a8ac8094acad8097aeb1809cb0b2809db2b3809db2b1809db1b0c73d33206e3c3021402b261b807184843f393e396e35362e684d56507741433d8f5b635b6c555d5759515b566457605b5857605b80656c65895d66605f5c66616d61696458616b6568676f67aa59594e68666d656a686f69666d746a626d736a5354584f6d848f8b809db0ab809fb1ae80a0b1ae80a1b2ac80a3b2add65d5950d657554cd34c473fd1383530634e554f57464d4755444c47b311100dff2b2922a01f1e1aff93a8ab8078898680798c89807a8c8a807b8d8c807c8e8c8080918e80819490808495938084969480899b97808c9e998090a19b8094a49f8097a7a1809caaa56d86928b642f2c23586b6e6480a5b0a780a5afa7ce4e473ed54d4b42891f1e1b4f191713ae28251cca433521e158462c01363329dc151411db23221de11a1a15fb4d5e5fe62b271dd4787660b5474539e5837c65c29da991e5b9c4acd4b2c7b4e4d5e7d7e7c5d6d1e7c9d5d0f1b7bbaae58c8b82dc52504102aec0bc6e26231db5403626de594631ee443524de302519d231292076282822411716134a1c1a17fb494334f3423b2fb5322919cc3f3420cd42321c5f0e0e0cfd1a18146711110e6623292cd41a1912bd4f5746a7333429cc5e5f47b3747f69cd96b197c39dbca9ccaed6c1d5afcfc6cc98b2a9e0929c86c761665ac5444637c2705d40d35949319e30271acc403524d932281bcb211b11f0535142491e1d19331b1916cc464032f4534b38ec544e3bc12b2013df392817d5523519ff403f36fe2e2a23fd3c3c34ff424b4ce2120f0bc6434237ae28261feb4e6a64d4547479e4717a6ed07b8f86e08da49ae2889d9ae4818e8978b1b07e385e5238008f8566d2b9844ae56c4b2ca42e2317d7251d14e1251c13fe4e493b30131311321918164d292620e1504835ff4e4737ca534c38c0140e07da20150a6e382812d0272621c71d1b17ec282824ff353a3ae50d0b08c826261da814130fe9465456f482aabccf2a2d23c430332bcd393b31d63c3d35cf393930e13c372b0036332ecb252118cf5b4325f394703a7f19140d9f1b181299171410fa3c382d95332f25762d291f311d1a13f24b4331ee443b2dfe564b35000f0d0a000d0b09000e0a05eb1d1b18fe26231ccc1f1e1bf2353937d20a0906b512120d000f0f0c000e0e0d00100f0e001112100011131100161716001c2224000f0e0d000f0f0d000b0a089d15120cc22d20111e0f0e0cf44f4b38a53d36286f1614116a0f0d0a2410100e45171411ff3f3828e73c3827e9463f2eef4a412d6b2c1b106d422b196f4025159e18130f961c16127b1e16137a372a2281412f288a4d382c7c31251d72292a269f3c3d369e3c3c369e393a34903736309c463f328f544a399d494133983731249e685434a89b8354144f413600504f46005a605995352f23f0443b2bc4443a29691f191283241e157717130c311e1a1335201b14b1464a42b2494e47aa333530d4232320c4181716b2141311b22b2e2abb676e6682727769968389788d868e7cab818575b2848a7c80898d7b947f7f6cb4766c55b724221cc32b2925d09c9a7c8369634fb768634f003a3b340069755e0074766618313129451814101e0d0a0888312a1edd4b3f2bda55462dff7663428943362320181a170e1e221e0f2325224a3436316e484d46583f46443a3c3f3c052b2d2808373933b98d907e46555a5248595f5624474a431035352f04302f296e796b54424e4b3f284e4c421323231e9e221f1aa6665a45005a5a470037382f0052564d236b7050230c0a07311914102417120e29120e0a1c0b09072414100b6e342b1b5f4a493d9a4a4a3ea5494c448752534a8247494071545347736d6857626963518c787663927372618e7571607c716c5c65726c575668614d78797057b796826285756f5b87746f5c627166526e645d4a6f191612a3211d199f251f1688221e167a252018fa393329e4322c22250d0b081c100d0a2a0f0d0a2718120e271f18116132322c452c2e2a332b2c292a2c2d290a2e2f281038362e2e4b4336ca8d89753148483f3f4d4b412d4d493e0e403f34163f3b3215464237a293896e7f7e6d52485d5544384b453818464134103c382e153b352a0d2e2a2090221e17ff383025563730252b332d242213110deb332c20dd393123ff594d39170b09071d16110c4e33342f1c2c2b260c2928230c36342a0d403c3181776b53ad8278626a63605264656052204c493c1d4b473a1446413507433f3201403b2ecc90886d496e5c42888c7a5c436e624e2b6359460e4b45370d423c2f0b3f392bac807459a55d4d35f72e2920c425211939322b2116383328571c1811f8453a2b8a2e2619c4413522162826200926251e0f34312604312f259084755d86796d533c545040505250412a524e3f1b4945370f3d3b2e124441330b3d3b2d7e716851b18a7f6b496f5d42708172542f58513f1e524c3a0e444130093f3b2c073e3b2c053935289e847358948169463230291fd3352e24ff493f30ff4e42340e312c220e1f1d15bf382d1d805b5340696e624b7b7468507e7569528e796e58927b7059a5827861a98278610b2f2a247d7b6f588a7f735e70776b556d7669527b7a6e544e6b604a867b71597b796c56918774579ba4865d859a7e56002c271f958c74516a7f69497a7f6846767b65448d7f684781786341935d4d33f0272119ee342b20ff3e3729ba5b4b35847c7054877f7053ae8b7d64ce92866ecf92876fc790866edf968c75c290846c566a5f4ac28e856d9584795f797d715799877a5f9084775da3897e63d4958d73ca978c71eba0977bd59c9172bb96896cc69c9071aa9386678c90764e898e764f7f8b714baf987b54c39d8259cca78b5cd7b49664eb977e55d52f261ae8493f2e525e5444425c513f65675c4a65675d4b61675d4b5f675d4b536458465d655a484b6256434c62574318473c2c495f523d4b61553f4f63584460695e4b6f6a604b628a7b5f6b847358586d624e586a5f492a594e3a4a6459434363574156695e4849655a434f685b433d6d5a3f727e6a4a84917852798e754e6187704b5b705b3a61524b3b94655f4e88645d4b8c69624f6a5e5443776158469a6a625081655e4c6d6059469e6c665285655d49715d523f9368624eb0787058d377705b76615039917a6547857f684a435d4d386161513a7b796446747560437669573e9572604495745f43756b583eac7865486563523b9b7460439b786142907a64437f7864418c5d57475658503f695f5644635b514054574d3d73605646364b4235a36b6352ac6d69565e5c5543937d735c6e5c56448168614dd17c755eae706a58635c4e3a84776346506c583d355b4b37bd705e469c8a724f9f8c724f5967553d6e69594168695940656758405e64523aa2786347836d5b4390735f44686b573c71715c3d002f2a2100342c2100322c2200322b2100332c2300312b2100322b2100342e2500322d2300332e2500332d2400312c2300302b2100322d2300332d2400322c2200322d230034302700322b1e00332e2500322d230028231b00332d2300352f2500332f2400342f2500342f2500362f2400362f2300352f2400352d21003831258036506380344d6380344c6080334b5f80314a5d802e485a802d475a802c4559802c4557f5837658e476684cc86e5f42ef756446f5786549e3756547dc786547d5796546f07b6948e9826e4bec806c4aee856e4aec856c48c3826945c5785f40dd8f7047802d475a802f485c80314a5eb54e3d24955c492dd07b6242f692734a80354f6380344d6280334b5f80314a5d8030485a802d475a802c4559802c4457802b43568029435680294255b14f5551e68f7c5ce4736346c2706144b4715f42ec776546ed7e6a4ae8826c4be7816c48b8776443e67e6847c58a704ce681684680253d4c802d465880314a5c802e485cd35f4c2fda78603bce836841d5896e4580344d6380344c6080314a5e8031495c802d475a802c4559802c4457802b43568029435680294255802941558029415380263f5280263e52f5958364de7a6849d3735f41e17e6846eb876f4ed8846c49cd7b6644c1856d4ad58a714b80e8f9fd8029435880ccdfe480283742802d465abd6553369f796038947c613aff94764980344d6280334b5f80314a5e802e485a802c4659802c4457802c445780294356802942558029415480263f5280253e5280253d5280253c5280243c5080243c50e7736246eb705f43f7816e4bff8a7550d17c6543d68a7149802640528029415280253e4f80a8bbc080294458805a717a99404b51ffa0875cc4846a40a47d653d80344c6080314b5f8031495b802d465a802c4558802c4457802b4356802942568029415480263f5280253d5280243c5180243b4f80233b4f80233b4e80233b4e80233b4e80233b4e80233b4f80233b4f80243c4f80243c5180253d5280263f5280465f6e80294053809ca9ac806d7f87802b4459c1755e38e9927549bd8b6d4380344c6080314a5e802e485a802d465a802c4558802c4457802943568029415480263f5280253d5280243c4f80233b4f80233a4e8022394d8022394d8021394d8021394d8021394d8022394d80223a4d80233a4e80233b4f80243c4f80243d5280263f5280253d4e806c818a80294258802b475180769096ffaf8c609d7e633d80334c5f80314a5e802d475a802c4559802c4458802a4356802942558028405280253d5280243b4f80233a4e8022394d8021384c8021384a8021364a8021364a8021364a8021364a8021364a8021384a8021384d8022394d80233b4e80243b4f80243c5180263f52802941528096a9b0808b9ca4802b4356802d465aa555564d80324b5f8031495b802d475a802d455a802c4457802942558029415580263e5280243c5180233b4e8022394d8021384c8021364a8021354a801e3447801e3447801d3446801e3447801e3447801f35488021364a8021384a8021394d80223a4e80233b4f80243d5280263f528029415380294356802a4356802c4458802d475a80324b5f8031495b802d475a802d455a802c4457802942558029415380253d5280233b4f8022394d8021384b8021364a801e3447801d3346801d3346801d3246801c3245801c3245801d3246801c3346801e34478021354a8021364a8021394d80223a4e80243c4f80253e52802840528029415580294356802c4457802c455980324b5f8031495b802d475a802d455a802c43578029415780273f5380243c5080233a4e8021384c8021364a801e3447801d3346801c3145801b3044801b3044801b3044801b3044801b3044801c3145801d3246801d3446802034498021374a8021394d80233b4f80243c5080253f528029415480294256802a4356802c445880324b5f80314a5d802e475c802d445a802c43578029415680253e5280243b4f8022394d8021374a8021354a801d3346801c3145801b3044801b2f44801b2f43801b2f42801b2f42801b2f43801b3044801b3044801c3245801d34468021354a8021384c80223a4e80243c4f80243d5280273f538029425580294255802b445680f7ffff80f7ffff80f5feff80f5feff80333c3c8029415680253e5280233b4f8022394d8021364a801e3447801d3246801b3044801b2f43801a2f4280182d4280182e4280182e4280182d42801a2f42801b2f43801b3044801d3246801e34478021364a8021384c8084a1a480f9fefd80f7ffff80f7ffff80f7ffff80f7ffff80e6feff80e4feff80ecffff80fbfffd80353f3f8029415680253d5280233b4f8022394d8021364a801e3347801c3145801b3044801b2f4280182c4280182c4280182b4080182b4080182b4180182d42801a2e42801b2f44801b3145801c3345801f35488021374a80819fa580f3fdff80e8fcff80e0fafd80e4fbff80f0fdfd80344c6080324b5f8031495e802e475b802c44588029415580253d5280233b4f8022394d8021364a801d3346801c3145801b3044801a2f4280182e4280182b3f80172b3f80172b3f80172b3f80182b4080182e42801b2f43801b3044801d3246801e34478021374a8021394d80233b4f80243c5080263f53802941558029435580354d6380344c6080314a5e802e475b802c44598029415680253f5280233b4f8022394d8021364a801e3347801c3145801b304480192f4280182d4280182b3f80162b3f80162b3f80162b3f80182b3f80182d4180192f42801b3044801c3145801d34468021364a8021394d80233b4f80243c5080263e52802941558029435680b7e5f080b6e4f080bce9f380ade0ec802c37398029425780263e5380243b4f8022394d8021364a801e3347801d3246801b3044801b2f4280182e4280182b3f80162b3f80162b3f80162b3f80182b3f80182c4080192e42801b3044801c3145801d34468021364a805f838e80b3e6f080b8e7f080b4e1ee80bce7f080b3e1ec80e8fdff80e6fdff80eeffff80ecfdff803f4849802943578028405380243c5080233a4e8021374a80203549801d3246801b3044801b2f4380182d4280182c4080182b3f80172b3f80172b3f80182b3f80182d4280192f42801b3044801c3145801d34468021364a808da9ad80eafbff80ecfdff80e4fdff80e8feff80e8fcff8038516380364f6380354d6180314c61802f475c802c44588029415480253d5280233b4e8022384c8021354a801d3346801c3145801b3044801a2f4280182d4280182b4080182b4080182b4080182c4180182e42801b2f42801b3044801c3145801d34468021364a8021384d80223b4e80223c5080253e528029415280294254803952668037506380354d6380334c608031495e802c4559802a425680263e5280243b4f8023394d8021374a80203449801d3246801b3145801b2f44801a2f4280182d4280182e4280182e4280182d42801a2f42801b2f43801b3044801d3346801e34478021364a8022394d80233b4f80243c5080263e528029415380294255803a53678039526780364f6380354d6380314a5f802f475b802c43578029415480253d5280233a4e8022394c8021364a801e3347801d3246801b3044801b3044801b2f43801b2f42801b2f42801b2f42801b2f43801b3044801c3145801d34468021354a8021384a80223a4d80233b4f80253c5280263e528029415580294255803c5469803a5368803a526580354e6380344c618031495e802c4559802a425780263f5280243b5080233a4d8021384b8021354a801e3347801d3246801c3145801b3044801b3044801b3044801b3044801b3044801c3145801d3346801e34478021364a8021384c80233a4e80243c4f80253d5280263f5280294155802943568050677380c0d9dd806c85938037506480354d6380324c60802f475c802c44588029425680253d5280243b4f8023394d8021384a8021354a801f3348801f3348801f3346801e3143801e3143801b3247801d3246801d3346801e34478021364a8021384c8022394d80233b4f80243c5180253e528029415380294155802a4356803a505f803b526280768b988039526680364f6380344c6280314a5e802e465a802b43578029415480253d5280233b4f80223a4d80d6f5fb80e0fcff80d8f7ff80d8f7ff80dcfaff80d4f3fb801f3348801e34478021354a8021364a8021384a8022394d80233b4e80243c4f80253d5280263f528029415580294255802b435680dceff280b7cad180395369803b53678038516680354e6380334c618030495e802d455a802b43568029415480253d5280223b5180c5d5d680d5dbda80d5dbdc80d5dbda80d5dcde80c5d6d68021374a8021364a8021374a8021384d8022394d80233b4e80243b4f80253c5280263e52802941538029415580294356802c445780465e6e8042596c803d566b803c5569803953678037506480354d6380334b608031495c802c4459802b42568029415480253d5280243b5080233a4e80233a4d8022394d8021394d8021384b8021394d8021394d8022394d80233a4e80233b4f80243c4f80253c5280253e52802941528029415580294255802b4356802c455880445d7380425b6f803f576c803d556b803c54688039526780364f6380344c6280314a5f8030475c802c4459802b43568029415380273f5280273e5280263b5080263b5080223b5080223a4f80223a4e80233b4e80233b4f80243b4f80243c5180253d5280263e52802941528029415580294255802a4356802c4457802c45598046607380445d728042596d803e566b803c5569803a53678038516680354e6380344c6280314a5f8031485c802c4459802a44598090c3c8808ed1dc806eafbf8072adbb807fbdca8086b9c280243c5180253d5280253d5280253d5280263e5280263f5280294153802941558029425580294356802c4457802c4558802d465a8048627580465f7380435c708042596c803d556b803c5468803953678037506480354d6380344c608031485c802f4557802f465a809abbbf8098bcc5808eb5bf8095bdc68099bdc58099b9bd80283d5080273d50802740538029415380294153802941558029425580294255802a4356802c4457802c4558802d465a802e485a804a64778047607480445d7280425b6f803f576c803c566a803a53678039526680364f6380354d6380a2b4bc802b44528031495c8056717d80263d4d802c4358804d6b7880243c4e8029425680283c4a80253d4c8029425680294255802943568029435680294356802b4356802c4457802c4558802d465a802e485a8031495c804d6679804962768047607380435c718042596d803f576b803c5468803953678038506380364e6380b9dce280324b5e80314a5f809bacb380274152802d455a80405b6b80213a4b802c445780283f50808d9da5802a4457802c4457802c4457802c4457802c4457802c4557802c4559802d465a802e485a8031495c80314a5e804e687b804b64778047617580445d7380435c708042596c803d566b803b5468803952668043596880cdeaee80354c6180324b6080e2f0f280364e5b802e485a803d556380273e4a802c445a8030455680ebf8fa802c4457802c4457802c4457802c4558802c4558802e465a802d475a802e485b80314a5f80314a5f80344c60804e697c804d6679804a63768047607480445d7280425a6e803f586c803d566b803a546880bfd9dd80303d4680354d6380344b5e80dcf1f380324c5d8031495d802b404c801c2b33802d465a802f465a8022323b802c4559802c4659802d465a802d475a802f485a802734358024332f802231318022323180263634802b383565955732c8c2703c5491522cabb36336a6bd6e3fb3d186507fa962376395603b9294593997985e3a6e794e326e613823895e3a280031281e00392e2272492c1e146b503800755c4300a4835e6379472c65ac7149c86d452ac4714d2cb2654527d470532fdb77542dc168492bd96c4828dd674528ca5a4024ea634428d2593d237c99562fbfb76b3898a9693de1d77e47a5bd7948cede92586b9c5b325b8a55335f84492f858359406f8655359562392589693f29004b39280052402d7f47281a0046372800614c3880834c326d864f32599a6543e48557328d4b3920c56d4a28db78532cdf7c4e2ee96f4a29b049341dc74f381fdc513d22c74a351fc84a331d638c512d3b7e48276b96583082a362388db16f4138824b2b437b482d276d442e3d74452c48673f28355e3e286a5d39244455331f7c6e4c32003f3122005e4b3700886d4e17745a416c8450349191583ae0754b2cd474502dae5c4424c5654728da71492beb6c462890352716d849351dd647341eba392c18cb412c18a52f21135d8c4f2aaabc713a4d8a502f6888563c828e5737868d55397f8952365f7e4f375b734f364c5e3f2b2d5333203653301d594e2d1c45482d1f003f312200635139009e805a637b4830507b4830ad684026e3875630783b2f1cd170492bd3634326dd5c3c2199302415be392817b3332315c8392516e83d2817db342415db33221481a25e3363845335818d56375e8154398f9057398f8e5e3f7a874d30547a4a3049653f2981643e29434730220031291f002c241c4d5132213a583e2c0066533b94be7b5291d88c5c8cd7875bd0784e2ccf6e4e2ad96e4827cb593c21ca49341cd43b2918d0342315d12f2113d42f2012d8281b10bf1d140bd52a1c0fde2a1d11537d4e3568844d30909056386783503366824a2f8389543a4e79492f4475452d7e74452d58623825002722190028231a00251f176a462617885a34210f5d442f577e4026728b4527fa885833d3754f2bba563b22c250371ec8402e19e7372415a918110b7d1d150e352d241a3c34291d363c2f204c524531617563496c71604774864e307888523364824d325a7e634c66814a305f7d4c369c8c513856774630556e462e7b71442f00262019002b261c00231d14625032211f3f2f21173c20146c854f30ab694028c9724b2ac5674427bf43321ccb3c2717d62b1d1130271f1540362b1e5e62523c50695a41215448353e645741456c5e46426a5e463e6558437f945a39758750326c844c30507a4c344c7847303870402b32653e2b3f5c35236d74472f516c3a2400262219002b251c535c3c2837563421114830212141221590884b30e5835832c56a4927bb46311bd033231490211a0f3e31271b4f4e412f235a4b365e88725355826f523a6b5c44366658424377674d20574b3a2a61543f6f855033888b543b5d7f4c3146764229617c4b31376e3d262e5b301f394a2d1f7a673c275e6239250027211a0029231a2564452f005d47325c7849303c562f1ee27c4d2cc66c4b28e36d4627c02f211431271f15423b2e2063705e454171604552857152356d5c425b8f7a5b74a7916c5a927f604a7b6b512a6457412f655842948d5334978e55388b8955399c8b573a7b824e3488824b3128522f203e41281d50603625303e281c002a241c00261f18005f4b35004d3c2c93b5764f744d3624d677512cc96a4526d83825153c2e24186d614d36295f4e384b796347477f6a4d1b6150394e8c77553f74624a63816f54596d60474e5f513dbf80643fff9c7b4f83864b307a834e3075814a2f82844e32aa8c5437987f4c344b5431224440281a505d423400242018002c261d00201b120034291e1c5235257a7c432ab0644227d973502bc248321a0d1e181042463524235a4933598872543d77634874a48a664b8b75575276644b5d5b4d38c181633ffeb08859c8a07950cf96754cf99f7b4f81864d31988a50329d8b5134a38b5538da955c3ec7825037955835256b42291d3b5232200027231c002a261c00241e15004f3e2c476c3c27697d442cb9674326df674527e320171036382b1d6a7662474f7e684b36826b4c66ab90683d7461466275634853483c2acf9e784bfeae875bffb58c5cf69e784db1775c3ac5604a2fb1915b3d80824c30bf92563a6b7b4730b1885235be794a33855535266e4d31224d532f1d002e271e002b251d3e452819004737284974442d5f7f442ba4543a21cb3323153b30251957594934386b583e4f947a5662987f5c3b7562465d5f50396f3f311fcda67d50caa37d4fe29b764dd08a6944f07d6040514f3920e2a47b4cd0b7734b80a968456c834b2e84804b2f8e7e4a2f956b4531af5d37246c5734224e4e2e1d002e291f0029231b2c60442f00534331657e4d34ac7c492dc05739202a271e1445443422255d4b3449826b4c2570583d3e8a72524e78634635291d11f7d8ae79d2bd9362e1a27c51d87c5f3b5a3728198b6b4f30cf9d794cbd9773477e986747909d714d8e8750326075422a8379472f846038258a583322665c3926373b291d002d261e0029221a005742303166442e60804b33ec81512cdb422b184836281a727962463f786144548d73525aa487605b7e684b3b292117dbe0b581c8e8ba81e5c19c6bcd876945393022136b40301dca977246daa17c4ee89d784ea3b7855b7f8e5d3cb3905835aa87503690794b3380553422645130214b5938280028231b002e261f002822190037291e6576422aa0905137fe9b6235e42b1c10383c2d1d235d4a343d725d426fa1835c598a6f505e58473263402d1bcce2b17bd3d5ab75d4a58157ec7e5f3f1c271a0fd38d6c45da916e45ff98744ae6846943757e4d34b08c573961764529b8894e35977547317d4e32239e573523645f3e2b002b241c0031292000251d16004d3b2c8f81452da0905136d6734e290b211911414c3825406f593e3e705a404f8f714b5d654f373619100ad5ba8b5be4c69562c19f784ebd8162411e21150cf586633cbe7b5c39ed785c3afa7d5f3dfb705c3d8a845037b88e58398b814f33b38451389a704731874f3625575531206a613b27002b241a002f271f4742221400372a208284462c56814126cf6d482543281e13594737253a503e2a3b55402b4d6b52384e54412b26191109f2af804fe1996e44e98b643e774b362220100b06bd705131b76b4f30db664c2ec361492ed257462e5677492e3d70412765794a2e7377492f4b5c36222e41271a304f2e1f1b492d1d002d251e002d271e1f4f3928004435273e713f268e814d30dd603c203d19120c583f2f1f3a4b3825274a382528503c275d523f2b3e291c11da87623de689643be77e59352322150ac063482bde71502fff624629c466482acf6d4a2ad1624428629866408dae70494b8a5536626e3e269a653c26724f2d1e77583320343a271b002f271f002823190043332412402a1c2a482718db7a4d2ac328190d4618100a6646342255564029535e442d48563e2a574d3a268b3b2817d97e5a36eb7d5a34d07050305b402b18f5755230b767492ae46c4d2cd769482ad8674528c260412669a167445a8f5c3b7d9d6c4b5b6a442d825e38268f5a3a266f562e1d00252018002a241c00261e1700281f168a78452ea2854b30d77d512acc1f120a42140e08563b29195f523c274e583f284f553e265d584128ee664527d57b532fe577512eec6545272c21140ad66b4b2bce70512ff1734f2edc6f4b2ad76a4729d95d3f23657c49306e7c472b98834c316f7040277159301f7b5d33204e5332210029231b002d261d00282018003e2f2198814931817e4c31da774d27d92f1c0d3e130d07532e1f123c46301d3b48321f365139225247331f78322011dc724b28e67a4f29d56c4627382a1a0ec56c4a29dc704c2bca6d4b2bcc6e4b2be37a542fdf6a4828757f482d6e7e482d687a462d5c6c4f3c624e2b1c56583423955b322100282219002c251c764f2d1e003a2c215873412a8c7f4a2f803b2614d43a2210170f0a055323170e343a27172c3d2a1a575f42295a4e362133140c05bd6e4623d1754924d56540214429180cc2694324dd774b27c7744b2ac6764f2da8704d2bcf754f2c6c7e462c647b462b6c79432b4c623c294f492a1c46552f1f404b2e1f002a231a002d251c2c543726004b39294a6d3c26a672472ad35a391adb492813d1170f07341a1109323725163c432d1b7364462c64563c243c281a0ff0724523df7b4c26d87547232d211209f36d4322d07a4c27ab774924b07a4c27dc8c5c33e1895e356d7d482e8f864c335c76442b416637235c5c36232a572e1d133823170029231900292219004e3c2a004236282e623522bf6a4124c0543317ed5a3119de180f0831160e08533e2a18554d341e464f352028432e1b5b4d3420b8633c1ec07b4b26bb6f44228c4329139f482b14f57b4b25c4794b25d6825026cb815026ac7a4f299a894f3395874e339787533998824a317973452d74733f2800211c1400282319002921180031261a004e3d2c6176452c864c2b18df643b1cdb583119d622120940170f086230201250513720273c28185261412751553a215b48321dff89572ede875329f87f4e2738201309b36e431fba794a24b97b4a25b87a4c25bb7b4d268283492e87854d306a7b452c8c804b31a6834c32a4814b32001f1b13002d251c00241d15004a39281e563e2d4b6c3f2ae0704222cb61371aba4a2f16c72b1a0cd6281a0d421810083e3c28173c442e1b354b321c55634327665c4025ff6d4524ff8b572ee4814f27eb794a24da6e4321d07b4b24ea7e4e26ce7b4c24da7749248f874c316d7e472c9a854c30ae814d33c27b4b31c17d4d3400272018002621173b5c3623002d241a2650312440563322b95a331af5784220bd4e3218be341f0fe42212083f0f0a053f1f140b4c49311c31442e1a6067462b294b341f5f5b4127d47c4c25e18a5429cd7f4e268c4b2e16f4804f27e07c4d26a7714522e47b4c25b78e563ab98f5638a7854e324d623623c05e3825c46e452f0029221a002621182e4e3423334a30210042312332392115e9673c21cf64381bc6593519b83c2311c62a180bdb160c0543170f085a382515414b34202d48311e69775432224d362050604429de85522acf81522bd37d5029653e2513d5774822e37b4c25e07e4d27ba8e5539747d472d6978432c786e4028714b2c1b4a3d281c0025201700271f1700241e154c38231900271f1730351e137c432717f477421fcd5d381bbd492914c437200fba221309c4180e07411e140b4e4c331e3a4e37212b4c35224a6c4d2e53845e3963735535e9794f2bc37c512ad47f522bd3784b26e6824e26e37f4d26a2855036bb8753379679493263603724854c2b1d00221d17002c231b00271e17474e32226e3b2015333821157f3e241765391e13e6713e1ec961381aba4f2d17d3472813ce311e0de12011089d120a05351f140b52583d2539553d2530513b254b6c50326c7b5b3a31553f296f65492ed17a522cde7d5530f879522ff87e4f29a37c4e34866b3f2ba8663d29a65a352591482d1f002a221b002f251d00221b13934a291a2b44312333301e147b3d201564381f13d8693a1ed76c3c1b8b382413e35a3116d43f2511c328180bcb1b0f08f721120930271b114e4c3723486e503332563e272f57412a1e4e37235e73563a5e7d64455e8e7452b1896b47e577573580516c7f804f6a7c804c6679804963778047607480445d7380425a6e803f586c803a556980c7e4e7803954698037516580344c5f80d5eff380334c5f80324b5f80314a5e8031495c8030495b802e485a802e485a802e485a802f485a802f495b8031495b8033475580eefcff80f9ffff80efffff80efffff80f5ffff80f2fcfd805c76898055708280516b7d804d687b804a64788047617580465f7380435d718040596e80b5d8de803c5666803954678039526680b5d6dc80374e6380344d6280344c6180324b5f80324b5f80314b5f80314a5e80314a5e80314a5e80324b5f80324b5f80344d5f802e465b802f495e8032495e80344c5e80365061803b5568801f2123805c788a8057738680557083804f697c804c6779804963768046607480445d7380a4b4bd802e4550803d566b803b556a80a3c0c6803851648037506380354f6380344d6380344d6280344d6180344d6180344d6180344d6180344d61802d3b4580374c5e80374d5c80394e5c80374b5a803e576a803f596b80405b6d80c4e9f4801a2022805e798a805c76898058738580546f82804e697b804a6579804862758042596a802f404d8040596e803f586b80314556803b556a803a55688039546880385365803851638037516380375063803750638037506380394f5e80c7eaf180c5eff780bfebf780c5eff780c1ebf380425b6d80435d6f80435e708066808f806582908065809180617c8d805d7889805975878057738480546f8180536a7880cff2f98048607480455f7380465d6f80dcf8fb803f596d803f586b8037475280b5d4d9803a5568803a5568808292968056646a803d576a803d596c803d576a803d586c8042596c80435b6d80445e6f80445f718046607380456070806c8694806984928067829080657f9080637d8e805f7b8b805c7889805874868056708280dbf3f5016c6354804d687b804c647480e5f7f98045617580435e73804257658080979f80425c7180425c7180e4f5f7803b546680435d7180435f7180435e7180445f7180455f73804661738046617180466070804761718048617380728d9b806f8a97806b8594c66c6453c06e6553ce7a6d5ac2796e59c97e6f5ac77f735dd66c624f027b6d52039a8162db67482acb725536ef9e734ae97d5836c164482ee6b08454ecae8353db976d45e2be925becb28151dfb88753c9b88e59efb58352ebc9ad6bc6b1915ce7c48f5ceead7e4fd7b9a567e5ca985eed946840807c97a2d16a6357c6696152d9736756c36e6554cd776b58cb7a705dc87e6e59d688765fc86d624dd7362b1ad84d3821d8684b2dc6553a20e9875a36d984613c9d6a4c2ddfa56e44daa47447bf926840e5ac784bdba57547d1a17447dbac794bd7a6784bd7a4774bd6b17b4bdaaa7747d4a7794bc9a16f43dfb67d4dd6a77a4c902a261e553b35287a453d2b38362f228f433b2d9d443d2f3c342e228047403348463d2d5f51483769574d3c68544a3873534735313c3428413c352626362e213c3f3528414a412f804e6978804e6978804e6776804f6978804f6a7880506b7980526d7b80536e7c80546f7e80556f7e8056707e8058727f8058727f805c7581cc635e529143392b3b463b2ae0696051d36a614fca6f6350da7f6f5ad381725dda877963d3af976cd8fcc35bdaffe278d2c1814080607b89805d7886805c7686805b7685805873826b4c402d80577381805772818057728180567180805873808058738280587382805b7481805b7581805d7681805d7681805d7781805f78815938312548363023733d38283a343021a84f4431323b3323283a322351493d2b47443b28744c422f3e3b33243440382533433726504d422d6a26201530423927d7564e39e2453b2e7d352f22ffd8be8c805f7984805d7884805d78848e6e7d7effad9e7aed938060d8d9c18ff9d0b887d67b6b51df8a846f80667d8780678087a1413e36cc45443cd1454038cd443f35be463f35c85b5040cf796a52cd947f62ced8b177d5fffea3ced9aa4dcdddc159cfc88f405d6e593bdb231f16a31c1813ec4d4431dd534a3bf04e452fa861543afc463d2da864655adc3f382af93a3327a03d3628ce5c5038947e6c4d2d44392a92433828345449353f5a4c3647483e2dca2e2d28991b18144c120f0bd338322ad4463f34ce4e4335d374644dc9a5875cd4f6c585cdfffa97acb2833eaeb18a41bdb27e41947a613689252017ac3a3326f559503ae64e4333eb776c4cb9756547b3372e23af473923ff423a2c8229241ccb4c4131c82d261bed61533cef6a5c45a8292419ca30281ef1897251d34c402cd02d281ed9353023bf393425d8473e2cf191764bdc947440d2463a26c5917a52cec69f68d0f3c379cdffde8bd5fff798c5ffd684c6cfa665b9231f168e201c157f1f1b11c550433582221e148e231f17d3362d23cc2a231bff17140fbf1e1a1397251f188f231d15df2e231d871c1711911e1a14c8635239f7735f43fc554531e34f4836f658513df865583ed7a1804a5c7c5f302433281380453720c5a38251d8c9a067cbf1c47cd1ffe393cbfed081c6dcae6adbb18e563f1f1a115a1b1a115a1d1913ce524a37431f1c1553222017d4252018d0201b15530a08053c15120e5c27221a3d252019e33d32275e2921195f28231ade554631ff6d5a40f7564631e0574e3bea665a3ff2997d4ee8cea157374b381a1822190d813f311dc58a7046d2a88c54cfcda469d9ecbd7ad6e4b56fc8be955ccc967544ab2e2815b8242517b7262319cf4d4533b82b271d922a281cd4221c15da1e19126f0a0906ab1a1812872d281cb9352d22d73d33289d322b21b4332e223913100c3213100c401a1611f65d513aeb6d5f42d3bf9a57c3b48d4828352712f0a37d40e25a4726de755d39d77a653dd48c7145cfa7844fd6ad8a53004d4231009e876b00a6916209867e5ebf5f5e4501907d5d007a66470064553d7f706048db1b1611ff2b261dff5f5542ff84755bff8c7a5eeb826f54f787765bff918063ff85765c3f1916103c221c15f8574c35ea675639c67f653a261f190b271a160bf18968348940321cd26d5635d46f5a3ad6816744cf8e734cdb8b6e4100574b3a0069584200605d450028291d005f573b005a4932006e5a400077654800816c4ed618130ef70f0d0af918140e9d211911ff7d6c55fc716148ff7c6c53ff7a6a54ef271f15431b1711261c1812f0524833f86d593ce4916e3e2c3225101b20190a955c46233417140cc83b3224c0332b1dd73d3120f4a47e3fd1362b1a006a573f00816d4e0075664a00353426004842324492a59a559ebeae4a99b5a3007e6b49cd130f0bff100d0aff27241cfc483f2ee6514636ab453b2da94e4333f4483f31ff453c2fdc413526cd51422c4f231d1351231c113d15130f4a16130d683f2f1987604826644d391effd5a856fd4133215719130b59151009cc1e180f003f341f005948300067573c00211f15004b432900665539007d674400493c2600705c3ecc110d0a61060504730b0906c1120f0ac4120f0bcf17110cc5100c0ab30f0c09632d251e684136296344372a65382c1ab8745c37ffb89157bc554429bc58462aaa4e3f262319130c2619130c692f21144c1c130ac1241a0c3230180a003e332100493c2600574b32001c1b12003e39240056452e006b5338003a2f1f0051422e791f1009ff211c15e83c3327a9352e21c93f3426002a241a7232291e00342a1e77372d22002b2219001e19138c3f3321341f191026130f0b19130f0b26211911301c160f3a271e1434241a1161261c106f1811083646230eb4a8581f3ea69e6ab3900100c1a007007fa5352700c1b99d0049392500513f29004a3c2986384d41523c23156516100c002d251c002e261cfd4b3e2cff4234267f453729005e4d3c004f3f33004d3e2e006e5b452317120d242017102a261d15291e17102d221a111c0f0d09ff665437db41321cea392a17296330126a563015c01a140b005f605100696059006d6759d68812032e746d4e004134230047372300372c1e003d3729002a241c005947339773472f346c4f3a005d4d3900a1825f1f3e2b1d005e4c3b00866c5200695642255a423121140f0c2514100c1a100c08ff806c4ab1473a25c74b3e27f8473a24774c3d263b66351849211b118b4b281100454031002d2d269e93844a005e5846d67e300a046d624d01392d1c00392c1e00423424002c261d0043342425382518004d3d2e007762490064533b1f70583d1339291d52482c1d424e2f1f7f66422d8472472fd7463823d2443825fe504129dd4f402755251e139f644b2adc7d6039fa3f3421d02c2114a2aa5d2970bf6c2e766a5c320031332b05403c2e00635f4d054d483d0046413100392b1c002b2114002c261c002823192791704e363f2b1a005a493500715f43154b3b29563b2c1a393629196a49321fbc4d35219949321ee9734d2fcb3c3220421c170fa153412864705938ff68553cbb2a23173819150d1f47251074cd692d7dd573335ab166320d4a4435006a715e00534b3b00595b4800271b1600504b3a71613f26002b261c002a231b867a5935007d674a362f2114003c3123847d4d3477915a3b78955e3dda6743278747321fec895d37b065492ae9855933907a5e3afd51432e2018130df7534634932a22173987421b68bd5e2a3ea7572a3da7552b1c8b48243d814925596f3d1d00383b3265611e1500777860005f5c48003633292432261a002e271d6f6f482b0099795800796448005945325679492d487f4b2e54895031e26f482bde8155308c4c3821e8855b35b2684729e37e5932fd4f4334e52d261e8c40301d887f633d44a3542769af56276ab2582868b15e2e54a5502849904c283d6e3c203f532c1622473223cd4e0c05542f1c1170311c12793927180030281e00251f166a6e4d3600ab89620059432f0a3f2b1e2d714b326a935f3ee0704b2bd87c5330d67c542f854b361de3845b33a9604627d871542fbb78623e85765e3c848b6f472a904c2480b6653377b75e2c6aaa57298aaf582961994c283c784a2b316839203757341f5451301b00423c30713d25186d3a2618002c241b002821187a3f28190051402f00ac8a64003d2d205b76482c7e794c31e2774f2dd7795131d57c512ecf76522e7b3b321ae67e5a31a35b4427db73542e4c6b593a5c715d3e4f98542a77a3582c5b9e562d67a15328649f532d5c995129769d5329408145253b703f222f603b2548613b20535d3d29423d2719002b231a002d251b533f26170082674c007b6248b17f513530522e1c8a4d3a2dfb865733d0745230d2754f30ce724f2cc7714f2d7c42331ee2765732a6584124d76c502c566b5a3f3283462695af5e306e9f562c77a2582f7da4593087a7653875a25a2f61905d362a6037216b8e4e2d75844f2c706339256765442c002e261d0031281e1c302218493f241800483a2b009477577c7e4a2e9c915837e16c4729f5895c36c46c4d2bc7704e2ac06a4c2bc56b4e2b642c2418ba5e4425b9604228da764f311d713e23a9b266372d59301c83a961366ca15d3581a65e33699a603b98b1683c7aaf6336a0c27d4a787e482a736e43296b5e3a26002c251c002b241a0027211773462a1c007b6246007e65495c72493169824a30dca5663fe37f5330ed815b33d072502cc26a4b28bd694b29a5563d228d49331ff07c5332b95c3f25e86e4a2af88e714aca7a6242c155442cb746361f80344d6180324c5f80314a5dbf94744bf9826747ef8a724bf8896e49b47b6341fb846c4bef7f6b49e9846e4eec7a6747d7776346f87c6b4de6746248f3756245d56f5c3fcb695a3db65c503ff07c6c4f801e2b33801c2a34801c2933801e2b3780344c6080374d5e8024333b80212f3afb97774cba78613eac5f4c30c84a3a24271b16104d3f342441372c20be826440fe876944a76b5739a6776140b17b6242db806b49ae796344ff86724ffd836f4df77d6a4cff806e4ee8736043ff7e6b4cfc7c6b4bd0705f40e76e5e42cf6b5b448075b5c5d09c885ccfa8976ff897896b8036506380303e3e8077b7c18079b7c7bf8b6d435c5c4a2fe8675335be4e3d271b18140e3633281b292c221742211a11d0735a38ef77613fef8c7047b47b6341ed856c49ef8b7350fe887151fe846e4dff89724efb806d4cf87a6748fb846c4bff88734ef4806f4cf1726041e66f5d41c548403136201a14eaa28f6beeb3a57f803c556a80587c84804c757d804a737d45594429d76f5535ff644d32c859452bb03b2e1d3f34281c41403423403a2e20b07e5f38c37d613c504b3a26cb7d6542c1806844e8836b49f7866f4ceb836c4aff89714cff88724ddd7c6744ff85704bff88704bff8e7854ff8a7452ff816e50ec5146334617120dce726649f3a89877ba58656480435e7080445f7280466173ba7c5f39945b462cff624a2cb2533f27e04e3b2337201911483c2e1f42382c1d39221b12ffaf7c49b8825932ee806442a16e573cf98f7550ffa2875eea856f4ae9806b4af8846f4cf6836e4df3826c49ff866d4aff866f4ce9736044f1756346b34d42332513100bde5e4f36e2978a6dbb646e6b804660738047617380476274f2765937c663492ffd6a5132b7584025d049351e281c160f3536291c553e31215332281bdb9a7047ffba834ddf84613dfa896745f099774db5735d3ed97e6441c07e6642f4846f4bf3806a48e2766241c3735a39fa786345fa7d6746e0645740fb231f17321c160fe55e4e35d8928360e57c775d80e8f7f780e6f7f780e4f6f7b36d5131ea705230d76a4f2fd65e4529a54b361fc4241a0f2e2f2015333d2b1b3a352517240f0b0730311d10f69d7349ffa97949ff90673eff936d44fc82623cd4755836b86d4f2ff5735637fa6c5235df624b31e35f4c31ff624f35ff514531cc3c3527352e271e5027211738322c22825c553f80adc4c980adc4c9809fb9bfcc7c5c34fb846036e86f512fca614527bd543d22f9402e1b804b6879804b6678804a6675c9412e1c30362112303d25141b26180dffb3834effa87743ffa57844e18b663dff926d43ef7d5c3aef785b39ff775b3aff695337ed4f3d29cf2219114d291e14a732291c2614100c292a211a27201e1a80546e7d8055707f8055707fb77b5932ed825f36c85c4328d26b4d2be1604526ef523c25805672818053707f80546e7cff563d25f766492b2d24160c272f1d112c3420142a301f1423362316212d1d13241b140d231d150e23130e09cb5b442cff3e32243218100a443023177d32271b22120d092015110d2a221a1327181612802d3a3d80445963805e7784262c180c2327160be8664727e56b4a2af3724e2c805f7b88805f7b88805e7987805c78858059768380577381df6c5a47f3765334f36a4d32f162482ed7553e27df533c25dd483825b14f5350a3585c56802c404b80f9fefb80f3fdfb240c080574261d12cf6a4e31a05e4b30fc6b583b5f443a2a80edfafd805e798280627a842622140a1e1f1209241c1009d0634428cf7961478068838c8065808b80657f8a80627d89805f7c87805e7986805c7884805c7884805b7684805b768480597583805a75838059738280597483805d7581805c7581b46c8583ba6f8782ee523b25ef6f5333ea7256358265553d59382f20782c271b80667f878068818980698289e2966131d48f5f32d884562d9f7b807980718b9180718b9080708b91806d888e806c878d806b858c806a848c8065818b80647f898065808880657e8580647d8480637d8480637c8480637d8480637d8480637d8480657d85c57a9287662f2316d2241a11794231228e574533806b8387806b8387806c8387806c8387806e838680798d8c80778c8c80778c8c80768c8c80768b8c80758b8d80738a8c80738a8c80738a8c80738a8c8070898b8070888a8070888a806f868a806d858a806c858a806d8488806c8388806c8387806b8286806b8285806b8285806b828492718784f291a5873a32271b8951423368505653806f838280708482807084828071848480798884785258517160645a6c61645a705d635a5f5c635b675b61597062675d7061675d5e545b55755d645c6a5a61596e575d565e555d5563515a556f565d55805869655e4f5854745d655f6a59625c6e57605a1f282822222929233032312858454942831b15104f201c18d38b997f8472817e8073827d80727f7c80727f7b88594e3cd8695b47d1675846d875664fd07b6853d47f6b53cf7a674fd07c6852db776750d27e6b55d657564a22606a5f80737f7c80717d7980717e7a80717d79806f7d79806e7a78846e7c78df8f9a7b60829394000d0e0f002d333200171b1d00191a175b3a352e8f41362a87302a1e97818a730329241dcb473824de57432bd2362e24d32c261dd540362bd56b5c466b493f32cc836e55ca867055ad8a7f65d577664ed68c765acd5c5c4f00454b41de221c14d5443e2a77c7fcff11616e6b6c525351d68c8870b93a392be04d4839009bcde670ffffff3cffffff00121a1a00161411300c0b09b3544332c8413b29aa3a3223ca524125b43c321fc740351ef64d3f2cff8b7554da715e41d3695844d76a5942c9967e60d3998161cd8f785ad49e8161db9a8465ce646256004e5246e81d1812e2463c2c7cbbeefa13535e5d254d656b468eb7af465e998deb403d30007d8f9422485f55183a4b4800181d1c00171512ae39352a3e3e3024e4ffaf5f00ff7842e5a06936c24d3822de3c2b1bb7766343403932254e3d3224cc7a684ad4ffd77bcaa48965cf988361d3fccf7c9dbc985cc7806f54c9504e43004f5146c913110dc0242118004b7273002b3434023a38361448493304455148cf23231a00121311001818140036332e00151311000f0e0d001f1c194131241ba3b3bdbd001817120017140e0008070500141109e6745d40e39a815cf0a1804cc7846f4dcba6885e01332b2100231b1300342b223050422d674e402d6b574e3d4b4f4b3bbb797964605452445758574572595949333f40348d5c5f4e60494a3c474a4c3f77636655765f6458af6d756a9f353731c24f52495a494032aa4d35255b71432500312c23002b251a0016130e001d1913cd695840d05c4e3ac863533f37352e23005f523f0044372600392a1f005b432d00765b41004b382600956a432d7253393142382c0032231749473f321c302e26152f2d2631484335183c3a311c34332c162e2d2896675f4b1a31322b272e2e28cb1a19151a2424200a1d1e1a1625272495545242803a3b32733d2718793b2314d35f513c6d483f3000373125a0493f309d3e332573623d2a894d3222854b2e1e1c5a473400523d294b74533b00de9b6301896342004d2f195771452a5b6c432a0017120d6a70402669673f2a2a4e362765534a3b7a615c4a9f47473c3a22231f171d1e1b1721211e111a1b19a1131310a7171512df1e1d1b56202321452c2e28561f1a12613b3224823b3223e750402ab9734e2ee19d663ce08b552ee4aa693aebb06d3cd195552da7a15b3456854b2e35442c1e54563926004025110056351c02513c2a0017110c4f654736877f513984794b353f3b24198a32322acf4c4d43ae49473c2f2526225030332e3f292c270f18191761302f29492d2c263c222421d9a37d52f8967349ef624a2cd9221a0fac684c2dd78f663cca754d28e3a7683ae2a26937d48d582cde9f5b2ef6c46e37b2884e29736535203c432516006f452502533d2968492e1d0015100c40311f1649341d14625a3b2a2f381f12893330287d48423681403c31713b3830061b1c170f1d1e1a121c1c1a0f1b1c1906181916ec846240ef70523347130f0a004a39269d5a4930c9846137c46c4a26cd8d6037d0906035c7794d28cf885329f0ac6231be884e26e2904821695b2f1b47482616004a3725004228145f3c23170017120e6f3a2319af40271b78402b1f33331e14913330297a35322b9a3e382d80413b30894c493b784442366830312b733c3b343719130eda4d3823981a130b003f3020b0684f35d37a5331bc613f22ac6a4625bb714e2dc16e4725c87b4e26e192592cc47c4924d57f461ee0824521895b2e1a00433323003d291b00201309753f261c0017140fb0482b1d9b3f281b9a41291d34341d136f2f2c25bc393931e04e4c42e64f4d43873f3b303c2425214b292926982b190f47422315343e2617001b140db6634a2ed97a5733dd694324df895832ee8c5a33df794726a85c3d1fe0875128ab693d1dcd6e3f1cd682431de88447207b442717002e221a0028180c00764f315b472f2100221d179f5e3d2aa460412d7855352435391f137e4b4234834a4537cb8a7b63c474675391524a3b48332c242b6b402a4459341f614f2c1b35391f13a24f3c25c85c4427ce53381eda6f482adf6f4a28d15e3c1fe1724324eb834c287e402a17c2633c1cd1713f1be88a4820b25e351b65472214122d1c12006d482d6a3a231746432d1e002c261d57361e135c39211482472d1f2c351c109b363229933f3b3163675b47a27b6b52ac584c3b73a86e4b8881472c767a462b4d663c289b3d3220c94e361fbd422d18ce5b3c23ce533921c74a3119d156361bf27f4826ca5c351bc6613919c3623b1be07c441eb563371ab4522b1a764524160065472c0046301d6d48312400271f1626362319623e2216763f2518663a2217142e170d592b2922a5423f3587615c4d7c7b6f54ee4b311ddb412c19d43c2515ee492f1bbb3c2c1be5492f1de0452b18c8462d1ab83d2716c03d2814c7462d16f0643c1ec34a2b15d261341aba583818d56f3f1cad5a3317d35d351c724626193a402a1d00875d3a00b27e5400261c14753b2519a442261a7740261a6c3c2419553720150a2b170d4628251f9f4542378f5a5549ea382515cb302012cf2d1e10d52e2112b8241c0fc92b1f11d5301f11df392515e93e2a18e43f2515b2302110ec4b2e17bc3b2110d4512f16bd543118ce663c1a9e4f2f16fb7a4222884827186c41231600876140007f5b3900251d155c422a1e5c462c1e905c3b28815637254f3b23167c41271913321c0f7f3b372ed45a56483865523a417660434c7f684b467a6245245f4b3568896d4c4f5e49303e382a1a821e150dd62e1d0fe1352011c6301d0f9d26170bd2442813e05f3318ce5e371990442b14ef7b4320493d1d119f482517703e23160077553600241c1445573b2a002b2119002a231b984e3829b75a3e2b9342281b91452b1d2842231544423b2f457c674a3b76604437776045549d7e57306752394271583c5a6e53371943312054543b2656251a10d422150bf62c190da01c1109c435200fd74f2b14dc623518843b2612e576411ece62361c92432316753f2216007d5d3e00251c14784d2c1e00271f16002922190028211abb66422db05131213d2d1a11b3663e2b11502c1b + m_SourceTextures: + - {fileID: 0} + - {fileID: 0} + - {fileID: 0} + - {fileID: 0} + - {fileID: 0} + - {fileID: 0} +--- !u!1002 &8900001 +EditorExtensionImpl: + serializedVersion: 6 diff --git a/Assets/Behavior Designer Movement/FactoryRoom_1.cubemap.meta b/Assets/Behavior Designer Movement/FactoryRoom_1.cubemap.meta new file mode 100644 index 0000000..fa8040f --- /dev/null +++ b/Assets/Behavior Designer Movement/FactoryRoom_1.cubemap.meta @@ -0,0 +1,4 @@ +fileFormatVersion: 2 +guid: 94434815c5cb40340ac2e6717cbd2dee +NativeFormatImporter: + userData: diff --git a/Assets/Behavior Designer Movement/GUISkin.guiskin b/Assets/Behavior Designer Movement/GUISkin.guiskin new file mode 100644 index 0000000..98bd5f7 --- /dev/null +++ b/Assets/Behavior Designer Movement/GUISkin.guiskin @@ -0,0 +1,1259 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!114 &11400000 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_GameObject: {fileID: 0} + m_Enabled: 1 + m_EditorHideFlags: 1 + m_Script: {fileID: 12001, guid: 0000000000000000e000000000000000, type: 0} + m_Name: GUISkin + m_EditorClassIdentifier: + m_Font: {fileID: 10102, guid: 0000000000000000e000000000000000, type: 0} + m_box: + m_Name: box + m_Normal: + m_Background: {fileID: 11001, guid: 0000000000000000e000000000000000, type: 0} + m_TextColor: {r: .799999952, g: .799999952, b: .799999952, a: 1} + m_Hover: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_Active: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_Focused: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_OnNormal: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_OnHover: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_OnActive: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_OnFocused: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_Border: + m_Left: 6 + m_Right: 6 + m_Top: 6 + m_Bottom: 6 + m_Margin: + m_Left: 4 + m_Right: 4 + m_Top: 4 + m_Bottom: 4 + m_Padding: + m_Left: 4 + m_Right: 4 + m_Top: 4 + m_Bottom: 4 + m_Overflow: + m_Left: 0 + m_Right: 0 + m_Top: 0 + m_Bottom: 0 + m_Font: {fileID: 0} + m_FontSize: 0 + m_FontStyle: 0 + m_Alignment: 1 + m_WordWrap: 1 + m_RichText: 1 + m_TextClipping: 1 + m_ImagePosition: 0 + m_ContentOffset: {x: 0, y: 0} + m_FixedWidth: 0 + m_FixedHeight: 0 + m_StretchWidth: 1 + m_StretchHeight: 0 + m_button: + m_Name: button + m_Normal: + m_Background: {fileID: 11006, guid: 0000000000000000e000000000000000, type: 0} + m_TextColor: {r: .899999976, g: .899999976, b: .899999976, a: 1} + m_Hover: + m_Background: {fileID: 11003, guid: 0000000000000000e000000000000000, type: 0} + m_TextColor: {r: 1, g: 1, b: 1, a: 1} + m_Active: + m_Background: {fileID: 11002, guid: 0000000000000000e000000000000000, type: 0} + m_TextColor: {r: .899999976, g: .899999976, b: .899999976, a: 1} + m_Focused: + m_Background: {fileID: 0} + m_TextColor: {r: 1, g: 1, b: 1, a: 1} + m_OnNormal: + m_Background: {fileID: 11005, guid: 0000000000000000e000000000000000, type: 0} + m_TextColor: {r: .90196079, g: .90196079, b: .90196079, a: 1} + m_OnHover: + m_Background: {fileID: 11004, guid: 0000000000000000e000000000000000, type: 0} + m_TextColor: {r: 1, g: 1, b: 1, a: 1} + m_OnActive: + m_Background: {fileID: 11002, guid: 0000000000000000e000000000000000, type: 0} + m_TextColor: {r: .899999976, g: .899999976, b: .899999976, a: 1} + m_OnFocused: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_Border: + m_Left: 6 + m_Right: 6 + m_Top: 6 + m_Bottom: 4 + m_Margin: + m_Left: 4 + m_Right: 4 + m_Top: 4 + m_Bottom: 4 + m_Padding: + m_Left: 6 + m_Right: 6 + m_Top: 3 + m_Bottom: 3 + m_Overflow: + m_Left: 0 + m_Right: 0 + m_Top: 0 + m_Bottom: 0 + m_Font: {fileID: 0} + m_FontSize: 0 + m_FontStyle: 0 + m_Alignment: 4 + m_WordWrap: 0 + m_RichText: 1 + m_TextClipping: 1 + m_ImagePosition: 0 + m_ContentOffset: {x: 0, y: 0} + m_FixedWidth: 0 + m_FixedHeight: 0 + m_StretchWidth: 1 + m_StretchHeight: 0 + m_toggle: + m_Name: toggle + m_Normal: + m_Background: {fileID: 11018, guid: 0000000000000000e000000000000000, type: 0} + m_TextColor: {r: .891128957, g: .891128957, b: .891128957, a: 1} + m_Hover: + m_Background: {fileID: 11014, guid: 0000000000000000e000000000000000, type: 0} + m_TextColor: {r: 1, g: 1, b: 1, a: 1} + m_Active: + m_Background: {fileID: 11013, guid: 0000000000000000e000000000000000, type: 0} + m_TextColor: {r: 1, g: 1, b: 1, a: 1} + m_Focused: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_OnNormal: + m_Background: {fileID: 11016, guid: 0000000000000000e000000000000000, type: 0} + m_TextColor: {r: .890196085, g: .890196085, b: .890196085, a: 1} + m_OnHover: + m_Background: {fileID: 11015, guid: 0000000000000000e000000000000000, type: 0} + m_TextColor: {r: 1, g: 1, b: 1, a: 1} + m_OnActive: + m_Background: {fileID: 11017, guid: 0000000000000000e000000000000000, type: 0} + m_TextColor: {r: 1, g: 1, b: 1, a: 1} + m_OnFocused: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_Border: + m_Left: 14 + m_Right: 0 + m_Top: 14 + m_Bottom: 0 + m_Margin: + m_Left: 4 + m_Right: 4 + m_Top: 4 + m_Bottom: 4 + m_Padding: + m_Left: 15 + m_Right: 0 + m_Top: 3 + m_Bottom: 0 + m_Overflow: + m_Left: -1 + m_Right: 0 + m_Top: -4 + m_Bottom: 0 + m_Font: {fileID: 0} + m_FontSize: 0 + m_FontStyle: 0 + m_Alignment: 0 + m_WordWrap: 0 + m_RichText: 1 + m_TextClipping: 1 + m_ImagePosition: 0 + m_ContentOffset: {x: 0, y: 0} + m_FixedWidth: 0 + m_FixedHeight: 0 + m_StretchWidth: 1 + m_StretchHeight: 0 + m_label: + m_Name: label + m_Normal: + m_Background: {fileID: 0} + m_TextColor: {r: .899999976, g: .899999976, b: .899999976, a: 1} + m_Hover: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_Active: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_Focused: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_OnNormal: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_OnHover: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_OnActive: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_OnFocused: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_Border: + m_Left: 0 + m_Right: 0 + m_Top: 0 + m_Bottom: 0 + m_Margin: + m_Left: 4 + m_Right: 4 + m_Top: 4 + m_Bottom: 4 + m_Padding: + m_Left: 0 + m_Right: 0 + m_Top: 3 + m_Bottom: 3 + m_Overflow: + m_Left: 0 + m_Right: 0 + m_Top: 0 + m_Bottom: 0 + m_Font: {fileID: 0} + m_FontSize: 0 + m_FontStyle: 0 + m_Alignment: 0 + m_WordWrap: 1 + m_RichText: 1 + m_TextClipping: 1 + m_ImagePosition: 0 + m_ContentOffset: {x: 0, y: 0} + m_FixedWidth: 0 + m_FixedHeight: 0 + m_StretchWidth: 1 + m_StretchHeight: 0 + m_textField: + m_Name: textfield + m_Normal: + m_Background: {fileID: 11024, guid: 0000000000000000e000000000000000, type: 0} + m_TextColor: {r: .799999952, g: .799999952, b: .799999952, a: 1} + m_Hover: + m_Background: {fileID: 11026, guid: 0000000000000000e000000000000000, type: 0} + m_TextColor: {r: .899999976, g: .899999976, b: .899999976, a: 1} + m_Active: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_Focused: + m_Background: {fileID: 11026, guid: 0000000000000000e000000000000000, type: 0} + m_TextColor: {r: 1, g: 1, b: 1, a: 1} + m_OnNormal: + m_Background: {fileID: 11025, guid: 0000000000000000e000000000000000, type: 0} + m_TextColor: {r: 1, g: 1, b: 1, a: 1} + m_OnHover: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_OnActive: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_OnFocused: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_Border: + m_Left: 4 + m_Right: 4 + m_Top: 4 + m_Bottom: 4 + m_Margin: + m_Left: 4 + m_Right: 4 + m_Top: 4 + m_Bottom: 4 + m_Padding: + m_Left: 3 + m_Right: 3 + m_Top: 3 + m_Bottom: 3 + m_Overflow: + m_Left: 0 + m_Right: 0 + m_Top: 0 + m_Bottom: 0 + m_Font: {fileID: 0} + m_FontSize: 0 + m_FontStyle: 0 + m_Alignment: 0 + m_WordWrap: 0 + m_RichText: 0 + m_TextClipping: 1 + m_ImagePosition: 3 + m_ContentOffset: {x: 0, y: 0} + m_FixedWidth: 0 + m_FixedHeight: 0 + m_StretchWidth: 1 + m_StretchHeight: 0 + m_textArea: + m_Name: textarea + m_Normal: + m_Background: {fileID: 11024, guid: 0000000000000000e000000000000000, type: 0} + m_TextColor: {r: .90196079, g: .90196079, b: .90196079, a: 1} + m_Hover: + m_Background: {fileID: 11026, guid: 0000000000000000e000000000000000, type: 0} + m_TextColor: {r: .799999952, g: .799999952, b: .799999952, a: 1} + m_Active: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_Focused: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_OnNormal: + m_Background: {fileID: 11025, guid: 0000000000000000e000000000000000, type: 0} + m_TextColor: {r: 1, g: 1, b: 1, a: 1} + m_OnHover: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_OnActive: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_OnFocused: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_Border: + m_Left: 4 + m_Right: 4 + m_Top: 4 + m_Bottom: 4 + m_Margin: + m_Left: 4 + m_Right: 4 + m_Top: 4 + m_Bottom: 4 + m_Padding: + m_Left: 3 + m_Right: 3 + m_Top: 3 + m_Bottom: 3 + m_Overflow: + m_Left: 0 + m_Right: 0 + m_Top: 0 + m_Bottom: 0 + m_Font: {fileID: 0} + m_FontSize: 0 + m_FontStyle: 0 + m_Alignment: 0 + m_WordWrap: 1 + m_RichText: 0 + m_TextClipping: 1 + m_ImagePosition: 0 + m_ContentOffset: {x: 0, y: 0} + m_FixedWidth: 0 + m_FixedHeight: 0 + m_StretchWidth: 1 + m_StretchHeight: 0 + m_window: + m_Name: window + m_Normal: + m_Background: {fileID: 11023, guid: 0000000000000000e000000000000000, type: 0} + m_TextColor: {r: 1, g: 1, b: 1, a: 1} + m_Hover: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_Active: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_Focused: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_OnNormal: + m_Background: {fileID: 11022, guid: 0000000000000000e000000000000000, type: 0} + m_TextColor: {r: 1, g: 1, b: 1, a: 1} + m_OnHover: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_OnActive: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_OnFocused: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_Border: + m_Left: 8 + m_Right: 8 + m_Top: 18 + m_Bottom: 8 + m_Margin: + m_Left: 0 + m_Right: 0 + m_Top: 0 + m_Bottom: 0 + m_Padding: + m_Left: 10 + m_Right: 10 + m_Top: 20 + m_Bottom: 10 + m_Overflow: + m_Left: 0 + m_Right: 0 + m_Top: 0 + m_Bottom: 0 + m_Font: {fileID: 0} + m_FontSize: 0 + m_FontStyle: 0 + m_Alignment: 1 + m_WordWrap: 0 + m_RichText: 1 + m_TextClipping: 1 + m_ImagePosition: 0 + m_ContentOffset: {x: 0, y: -18} + m_FixedWidth: 0 + m_FixedHeight: 0 + m_StretchWidth: 1 + m_StretchHeight: 0 + m_horizontalSlider: + m_Name: horizontalslider + m_Normal: + m_Background: {fileID: 11009, guid: 0000000000000000e000000000000000, type: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_Hover: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_Active: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_Focused: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_OnNormal: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_OnHover: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_OnActive: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_OnFocused: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_Border: + m_Left: 3 + m_Right: 3 + m_Top: 0 + m_Bottom: 0 + m_Margin: + m_Left: 4 + m_Right: 4 + m_Top: 4 + m_Bottom: 4 + m_Padding: + m_Left: -1 + m_Right: -1 + m_Top: 0 + m_Bottom: 0 + m_Overflow: + m_Left: 0 + m_Right: 0 + m_Top: -2 + m_Bottom: -3 + m_Font: {fileID: 0} + m_FontSize: 0 + m_FontStyle: 0 + m_Alignment: 0 + m_WordWrap: 0 + m_RichText: 1 + m_TextClipping: 1 + m_ImagePosition: 2 + m_ContentOffset: {x: 0, y: 0} + m_FixedWidth: 0 + m_FixedHeight: 12 + m_StretchWidth: 1 + m_StretchHeight: 0 + m_horizontalSliderThumb: + m_Name: horizontalsliderthumb + m_Normal: + m_Background: {fileID: 11011, guid: 0000000000000000e000000000000000, type: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_Hover: + m_Background: {fileID: 11012, guid: 0000000000000000e000000000000000, type: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_Active: + m_Background: {fileID: 11010, guid: 0000000000000000e000000000000000, type: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_Focused: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_OnNormal: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_OnHover: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_OnActive: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_OnFocused: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_Border: + m_Left: 4 + m_Right: 4 + m_Top: 0 + m_Bottom: 0 + m_Margin: + m_Left: 0 + m_Right: 0 + m_Top: 0 + m_Bottom: 0 + m_Padding: + m_Left: 7 + m_Right: 7 + m_Top: 0 + m_Bottom: 0 + m_Overflow: + m_Left: -1 + m_Right: -1 + m_Top: 0 + m_Bottom: 0 + m_Font: {fileID: 0} + m_FontSize: 0 + m_FontStyle: 0 + m_Alignment: 0 + m_WordWrap: 0 + m_RichText: 1 + m_TextClipping: 1 + m_ImagePosition: 2 + m_ContentOffset: {x: 0, y: 0} + m_FixedWidth: 0 + m_FixedHeight: 12 + m_StretchWidth: 1 + m_StretchHeight: 0 + m_verticalSlider: + m_Name: verticalslider + m_Normal: + m_Background: {fileID: 11021, guid: 0000000000000000e000000000000000, type: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_Hover: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_Active: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_Focused: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_OnNormal: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_OnHover: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_OnActive: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_OnFocused: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_Border: + m_Left: 0 + m_Right: 0 + m_Top: 3 + m_Bottom: 3 + m_Margin: + m_Left: 4 + m_Right: 4 + m_Top: 4 + m_Bottom: 4 + m_Padding: + m_Left: 0 + m_Right: 0 + m_Top: -1 + m_Bottom: -1 + m_Overflow: + m_Left: -2 + m_Right: -3 + m_Top: 0 + m_Bottom: 0 + m_Font: {fileID: 0} + m_FontSize: 0 + m_FontStyle: 0 + m_Alignment: 0 + m_WordWrap: 0 + m_RichText: 1 + m_TextClipping: 0 + m_ImagePosition: 0 + m_ContentOffset: {x: 0, y: 0} + m_FixedWidth: 12 + m_FixedHeight: 0 + m_StretchWidth: 0 + m_StretchHeight: 1 + m_verticalSliderThumb: + m_Name: verticalsliderthumb + m_Normal: + m_Background: {fileID: 11011, guid: 0000000000000000e000000000000000, type: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_Hover: + m_Background: {fileID: 11012, guid: 0000000000000000e000000000000000, type: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_Active: + m_Background: {fileID: 11010, guid: 0000000000000000e000000000000000, type: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_Focused: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_OnNormal: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_OnHover: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_OnActive: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_OnFocused: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_Border: + m_Left: 0 + m_Right: 0 + m_Top: 0 + m_Bottom: 0 + m_Margin: + m_Left: 0 + m_Right: 0 + m_Top: 0 + m_Bottom: 0 + m_Padding: + m_Left: 0 + m_Right: 0 + m_Top: 7 + m_Bottom: 7 + m_Overflow: + m_Left: 0 + m_Right: 0 + m_Top: -1 + m_Bottom: -1 + m_Font: {fileID: 0} + m_FontSize: 0 + m_FontStyle: 0 + m_Alignment: 0 + m_WordWrap: 0 + m_RichText: 1 + m_TextClipping: 1 + m_ImagePosition: 0 + m_ContentOffset: {x: 0, y: 0} + m_FixedWidth: 12 + m_FixedHeight: 0 + m_StretchWidth: 0 + m_StretchHeight: 1 + m_horizontalScrollbar: + m_Name: horizontalscrollbar + m_Normal: + m_Background: {fileID: 11008, guid: 0000000000000000e000000000000000, type: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_Hover: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_Active: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_Focused: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_OnNormal: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_OnHover: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_OnActive: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_OnFocused: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_Border: + m_Left: 9 + m_Right: 9 + m_Top: 0 + m_Bottom: 0 + m_Margin: + m_Left: 4 + m_Right: 4 + m_Top: 1 + m_Bottom: 4 + m_Padding: + m_Left: 0 + m_Right: 0 + m_Top: 0 + m_Bottom: 0 + m_Overflow: + m_Left: 0 + m_Right: 0 + m_Top: 0 + m_Bottom: 0 + m_Font: {fileID: 0} + m_FontSize: 0 + m_FontStyle: 0 + m_Alignment: 0 + m_WordWrap: 0 + m_RichText: 1 + m_TextClipping: 1 + m_ImagePosition: 2 + m_ContentOffset: {x: 0, y: 0} + m_FixedWidth: 0 + m_FixedHeight: 15 + m_StretchWidth: 1 + m_StretchHeight: 0 + m_horizontalScrollbarThumb: + m_Name: horizontalscrollbarthumb + m_Normal: + m_Background: {fileID: 11007, guid: 0000000000000000e000000000000000, type: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_Hover: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_Active: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_Focused: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_OnNormal: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_OnHover: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_OnActive: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_OnFocused: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_Border: + m_Left: 6 + m_Right: 6 + m_Top: 6 + m_Bottom: 6 + m_Margin: + m_Left: 0 + m_Right: 0 + m_Top: 0 + m_Bottom: 0 + m_Padding: + m_Left: 6 + m_Right: 6 + m_Top: 0 + m_Bottom: 0 + m_Overflow: + m_Left: 0 + m_Right: 0 + m_Top: -1 + m_Bottom: 1 + m_Font: {fileID: 0} + m_FontSize: 0 + m_FontStyle: 0 + m_Alignment: 0 + m_WordWrap: 0 + m_RichText: 1 + m_TextClipping: 1 + m_ImagePosition: 0 + m_ContentOffset: {x: 0, y: 0} + m_FixedWidth: 0 + m_FixedHeight: 13 + m_StretchWidth: 1 + m_StretchHeight: 0 + m_horizontalScrollbarLeftButton: + m_Name: horizontalscrollbarleftbutton + m_Normal: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_Hover: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_Active: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_Focused: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_OnNormal: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_OnHover: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_OnActive: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_OnFocused: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_Border: + m_Left: 0 + m_Right: 0 + m_Top: 0 + m_Bottom: 0 + m_Margin: + m_Left: 0 + m_Right: 0 + m_Top: 0 + m_Bottom: 0 + m_Padding: + m_Left: 0 + m_Right: 0 + m_Top: 0 + m_Bottom: 0 + m_Overflow: + m_Left: 0 + m_Right: 0 + m_Top: 0 + m_Bottom: 0 + m_Font: {fileID: 0} + m_FontSize: 0 + m_FontStyle: 0 + m_Alignment: 0 + m_WordWrap: 0 + m_RichText: 1 + m_TextClipping: 1 + m_ImagePosition: 0 + m_ContentOffset: {x: 0, y: 0} + m_FixedWidth: 0 + m_FixedHeight: 0 + m_StretchWidth: 1 + m_StretchHeight: 0 + m_horizontalScrollbarRightButton: + m_Name: horizontalscrollbarrightbutton + m_Normal: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_Hover: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_Active: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_Focused: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_OnNormal: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_OnHover: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_OnActive: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_OnFocused: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_Border: + m_Left: 0 + m_Right: 0 + m_Top: 0 + m_Bottom: 0 + m_Margin: + m_Left: 0 + m_Right: 0 + m_Top: 0 + m_Bottom: 0 + m_Padding: + m_Left: 0 + m_Right: 0 + m_Top: 0 + m_Bottom: 0 + m_Overflow: + m_Left: 0 + m_Right: 0 + m_Top: 0 + m_Bottom: 0 + m_Font: {fileID: 0} + m_FontSize: 0 + m_FontStyle: 0 + m_Alignment: 0 + m_WordWrap: 0 + m_RichText: 1 + m_TextClipping: 1 + m_ImagePosition: 0 + m_ContentOffset: {x: 0, y: 0} + m_FixedWidth: 0 + m_FixedHeight: 0 + m_StretchWidth: 1 + m_StretchHeight: 0 + m_verticalScrollbar: + m_Name: verticalscrollbar + m_Normal: + m_Background: {fileID: 11020, guid: 0000000000000000e000000000000000, type: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_Hover: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_Active: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_Focused: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_OnNormal: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_OnHover: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_OnActive: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_OnFocused: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_Border: + m_Left: 0 + m_Right: 0 + m_Top: 9 + m_Bottom: 9 + m_Margin: + m_Left: 1 + m_Right: 4 + m_Top: 4 + m_Bottom: 4 + m_Padding: + m_Left: 0 + m_Right: 0 + m_Top: 1 + m_Bottom: 1 + m_Overflow: + m_Left: 0 + m_Right: 0 + m_Top: 0 + m_Bottom: 0 + m_Font: {fileID: 0} + m_FontSize: 0 + m_FontStyle: 0 + m_Alignment: 0 + m_WordWrap: 0 + m_RichText: 1 + m_TextClipping: 1 + m_ImagePosition: 0 + m_ContentOffset: {x: 0, y: 0} + m_FixedWidth: 15 + m_FixedHeight: 0 + m_StretchWidth: 1 + m_StretchHeight: 0 + m_verticalScrollbarThumb: + m_Name: verticalscrollbarthumb + m_Normal: + m_Background: {fileID: 11019, guid: 0000000000000000e000000000000000, type: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_Hover: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_Active: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_Focused: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_OnNormal: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_OnHover: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_OnActive: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_OnFocused: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_Border: + m_Left: 6 + m_Right: 6 + m_Top: 6 + m_Bottom: 6 + m_Margin: + m_Left: 0 + m_Right: 0 + m_Top: 0 + m_Bottom: 0 + m_Padding: + m_Left: 0 + m_Right: 0 + m_Top: 6 + m_Bottom: 6 + m_Overflow: + m_Left: -1 + m_Right: -1 + m_Top: 0 + m_Bottom: 0 + m_Font: {fileID: 0} + m_FontSize: 0 + m_FontStyle: 0 + m_Alignment: 0 + m_WordWrap: 0 + m_RichText: 1 + m_TextClipping: 1 + m_ImagePosition: 2 + m_ContentOffset: {x: 0, y: 0} + m_FixedWidth: 15 + m_FixedHeight: 0 + m_StretchWidth: 0 + m_StretchHeight: 1 + m_verticalScrollbarUpButton: + m_Name: verticalscrollbarupbutton + m_Normal: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_Hover: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_Active: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_Focused: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_OnNormal: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_OnHover: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_OnActive: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_OnFocused: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_Border: + m_Left: 0 + m_Right: 0 + m_Top: 0 + m_Bottom: 0 + m_Margin: + m_Left: 0 + m_Right: 0 + m_Top: 0 + m_Bottom: 0 + m_Padding: + m_Left: 0 + m_Right: 0 + m_Top: 0 + m_Bottom: 0 + m_Overflow: + m_Left: 0 + m_Right: 0 + m_Top: 0 + m_Bottom: 0 + m_Font: {fileID: 0} + m_FontSize: 0 + m_FontStyle: 0 + m_Alignment: 0 + m_WordWrap: 0 + m_RichText: 1 + m_TextClipping: 1 + m_ImagePosition: 0 + m_ContentOffset: {x: 0, y: 0} + m_FixedWidth: 0 + m_FixedHeight: 0 + m_StretchWidth: 1 + m_StretchHeight: 0 + m_verticalScrollbarDownButton: + m_Name: verticalscrollbardownbutton + m_Normal: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_Hover: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_Active: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_Focused: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_OnNormal: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_OnHover: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_OnActive: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_OnFocused: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_Border: + m_Left: 0 + m_Right: 0 + m_Top: 0 + m_Bottom: 0 + m_Margin: + m_Left: 0 + m_Right: 0 + m_Top: 0 + m_Bottom: 0 + m_Padding: + m_Left: 0 + m_Right: 0 + m_Top: 0 + m_Bottom: 0 + m_Overflow: + m_Left: 0 + m_Right: 0 + m_Top: 0 + m_Bottom: 0 + m_Font: {fileID: 0} + m_FontSize: 0 + m_FontStyle: 0 + m_Alignment: 0 + m_WordWrap: 0 + m_RichText: 1 + m_TextClipping: 1 + m_ImagePosition: 0 + m_ContentOffset: {x: 0, y: 0} + m_FixedWidth: 0 + m_FixedHeight: 0 + m_StretchWidth: 1 + m_StretchHeight: 0 + m_ScrollView: + m_Name: scrollview + m_Normal: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_Hover: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_Active: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_Focused: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_OnNormal: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_OnHover: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_OnActive: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_OnFocused: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_Border: + m_Left: 0 + m_Right: 0 + m_Top: 0 + m_Bottom: 0 + m_Margin: + m_Left: 0 + m_Right: 0 + m_Top: 0 + m_Bottom: 0 + m_Padding: + m_Left: 0 + m_Right: 0 + m_Top: 0 + m_Bottom: 0 + m_Overflow: + m_Left: 0 + m_Right: 0 + m_Top: 0 + m_Bottom: 0 + m_Font: {fileID: 0} + m_FontSize: 0 + m_FontStyle: 0 + m_Alignment: 0 + m_WordWrap: 0 + m_RichText: 1 + m_TextClipping: 1 + m_ImagePosition: 0 + m_ContentOffset: {x: 0, y: 0} + m_FixedWidth: 0 + m_FixedHeight: 0 + m_StretchWidth: 1 + m_StretchHeight: 0 + m_CustomStyles: + - m_Name: + m_Normal: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_Hover: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_Active: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_Focused: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_OnNormal: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_OnHover: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_OnActive: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_OnFocused: + m_Background: {fileID: 0} + m_TextColor: {r: 0, g: 0, b: 0, a: 1} + m_Border: + m_Left: 0 + m_Right: 0 + m_Top: 0 + m_Bottom: 0 + m_Margin: + m_Left: 0 + m_Right: 0 + m_Top: 0 + m_Bottom: 0 + m_Padding: + m_Left: 0 + m_Right: 0 + m_Top: 0 + m_Bottom: 0 + m_Overflow: + m_Left: 0 + m_Right: 0 + m_Top: 0 + m_Bottom: 0 + m_Font: {fileID: 0} + m_FontSize: 0 + m_FontStyle: 0 + m_Alignment: 0 + m_WordWrap: 0 + m_RichText: 1 + m_TextClipping: 0 + m_ImagePosition: 0 + m_ContentOffset: {x: 0, y: 0} + m_FixedWidth: 0 + m_FixedHeight: 0 + m_StretchWidth: 1 + m_StretchHeight: 0 + m_Settings: + m_DoubleClickSelectsWord: 1 + m_TripleClickSelectsLine: 1 + m_CursorColor: {r: 1, g: 1, b: 1, a: 1} + m_CursorFlashSpeed: -1 + m_SelectionColor: {r: 1, g: .384039074, b: 0, a: .699999988} diff --git a/Assets/Behavior Designer Movement/GUISkin.guiskin.meta b/Assets/Behavior Designer Movement/GUISkin.guiskin.meta new file mode 100644 index 0000000..0a59fe6 --- /dev/null +++ b/Assets/Behavior Designer Movement/GUISkin.guiskin.meta @@ -0,0 +1,4 @@ +fileFormatVersion: 2 +guid: 36eff75c3a960b74bbd5999b301b60ca +NativeFormatImporter: + userData: diff --git a/Assets/Behavior Designer Movement/Integrations.meta b/Assets/Behavior Designer Movement/Integrations.meta new file mode 100644 index 0000000..8bdcd22 --- /dev/null +++ b/Assets/Behavior Designer Movement/Integrations.meta @@ -0,0 +1,4 @@ +fileFormatVersion: 2 +guid: c35e3975f7fb8a34fb76cf9affb89d0a +DefaultImporter: + userData: diff --git a/Assets/Behavior Designer Movement/Integrations/readme.pdf b/Assets/Behavior Designer Movement/Integrations/readme.pdf new file mode 100644 index 0000000..f91e328 Binary files /dev/null and b/Assets/Behavior Designer Movement/Integrations/readme.pdf differ diff --git a/Assets/Behavior Designer Movement/Integrations/readme.pdf.meta b/Assets/Behavior Designer Movement/Integrations/readme.pdf.meta new file mode 100644 index 0000000..e8811e3 --- /dev/null +++ b/Assets/Behavior Designer Movement/Integrations/readme.pdf.meta @@ -0,0 +1,4 @@ +fileFormatVersion: 2 +guid: 77743219b71864543a56cd23646837b5 +DefaultImporter: + userData: diff --git a/Assets/Behavior Designer Movement/Materials.meta b/Assets/Behavior Designer Movement/Materials.meta new file mode 100644 index 0000000..e1a75ae --- /dev/null +++ b/Assets/Behavior Designer Movement/Materials.meta @@ -0,0 +1,4 @@ +fileFormatVersion: 2 +guid: c84ea9daa1b40094fae3e7c430e34865 +DefaultImporter: + userData: diff --git a/Assets/Behavior Designer Movement/Materials/bot.mat b/Assets/Behavior Designer Movement/Materials/bot.mat new file mode 100644 index 0000000..3e5946d --- /dev/null +++ b/Assets/Behavior Designer Movement/Materials/bot.mat @@ -0,0 +1,32 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!21 &2100000 +Material: + serializedVersion: 3 + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_Name: bot + m_Shader: {fileID: 7, guid: 0000000000000000f000000000000000, type: 0} + m_ShaderKeywords: [] + m_CustomRenderQueue: -1 + m_SavedProperties: + serializedVersion: 2 + m_TexEnvs: + data: + first: + name: _MainTex + second: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + m_Floats: {} + m_Colors: + data: + first: + name: _Color + second: {r: 0, g: 1, b: 0, a: 1} + data: + first: + name: _BaseScale + second: {r: 1, g: 1, b: 1, a: 0} diff --git a/Assets/Behavior Designer Movement/Materials/bot.mat.meta b/Assets/Behavior Designer Movement/Materials/bot.mat.meta new file mode 100644 index 0000000..d1c7c61 --- /dev/null +++ b/Assets/Behavior Designer Movement/Materials/bot.mat.meta @@ -0,0 +1,4 @@ +fileFormatVersion: 2 +guid: fecc96c64c214ce40835ac4c3c3099e8 +NativeFormatImporter: + userData: diff --git a/Assets/Behavior Designer Movement/Materials/ground.mat b/Assets/Behavior Designer Movement/Materials/ground.mat new file mode 100644 index 0000000..f5884cf --- /dev/null +++ b/Assets/Behavior Designer Movement/Materials/ground.mat @@ -0,0 +1,30 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!21 &2100000 +Material: + serializedVersion: 6 + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_Name: ground + m_Shader: {fileID: 10752, guid: 0000000000000000f000000000000000, type: 0} + m_ShaderKeywords: + m_LightmapFlags: 5 + m_CustomRenderQueue: 2000 + stringTagMap: {} + m_SavedProperties: + serializedVersion: 2 + m_TexEnvs: + data: + first: + name: _MainTex + second: + m_Texture: {fileID: 2800000, guid: 91aab39565a849342b4733613a339270, type: 3} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + m_Floats: {} + m_Colors: + data: + first: + name: _Color + second: {r: 1, g: 1, b: 1, a: 1} diff --git a/Assets/Behavior Designer Movement/Materials/ground.mat.meta b/Assets/Behavior Designer Movement/Materials/ground.mat.meta new file mode 100644 index 0000000..de8bfd7 --- /dev/null +++ b/Assets/Behavior Designer Movement/Materials/ground.mat.meta @@ -0,0 +1,4 @@ +fileFormatVersion: 2 +guid: dbcdee902c373ec4cbb9e693617708b9 +NativeFormatImporter: + userData: diff --git a/Assets/Behavior Designer Movement/Materials/marker.mat b/Assets/Behavior Designer Movement/Materials/marker.mat new file mode 100644 index 0000000..b9b816d --- /dev/null +++ b/Assets/Behavior Designer Movement/Materials/marker.mat @@ -0,0 +1,48 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!21 &2100000 +Material: + serializedVersion: 5 + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_Name: marker + m_Shader: {fileID: 14, guid: 0000000000000000f000000000000000, type: 0} + m_ShaderKeywords: + m_LightmapFlags: 1 + m_CustomRenderQueue: -1 + m_SavedProperties: + serializedVersion: 2 + m_TexEnvs: + data: + first: + name: _MainTex + second: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + data: + first: + name: _Illum + second: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + m_Floats: + data: + first: + name: _Shininess + second: .699999988 + data: + first: + name: _EmissionLM + second: 0 + m_Colors: + data: + first: + name: _Color + second: {r: 1, g: 0, b: 0, a: 1} + data: + first: + name: _SpecColor + second: {r: 1, g: 1, b: 1, a: 1} diff --git a/Assets/Behavior Designer Movement/Materials/marker.mat.meta b/Assets/Behavior Designer Movement/Materials/marker.mat.meta new file mode 100644 index 0000000..0aa03ff --- /dev/null +++ b/Assets/Behavior Designer Movement/Materials/marker.mat.meta @@ -0,0 +1,4 @@ +fileFormatVersion: 2 +guid: 6ce92c6edcc2df647be90d324133f9ed +NativeFormatImporter: + userData: diff --git a/Assets/Behavior Designer Movement/Materials/wall.mat b/Assets/Behavior Designer Movement/Materials/wall.mat new file mode 100644 index 0000000..1be316f --- /dev/null +++ b/Assets/Behavior Designer Movement/Materials/wall.mat @@ -0,0 +1,28 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!21 &2100000 +Material: + serializedVersion: 3 + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_Name: wall + m_Shader: {fileID: 7, guid: 0000000000000000f000000000000000, type: 0} + m_ShaderKeywords: [] + m_CustomRenderQueue: -1 + m_SavedProperties: + serializedVersion: 2 + m_TexEnvs: + data: + first: + name: _MainTex + second: + m_Texture: {fileID: 2800000, guid: 0c16e655ee9ccbd4ba9d5359b56a9a5c, type: 3} + m_Scale: {x: 10, y: 3} + m_Offset: {x: 0, y: 0} + m_Floats: {} + m_Colors: + data: + first: + name: _Color + second: {r: 1, g: 1, b: 1, a: 1} diff --git a/Assets/Behavior Designer Movement/Materials/wall.mat.meta b/Assets/Behavior Designer Movement/Materials/wall.mat.meta new file mode 100644 index 0000000..54a3e1e --- /dev/null +++ b/Assets/Behavior Designer Movement/Materials/wall.mat.meta @@ -0,0 +1,4 @@ +fileFormatVersion: 2 +guid: a08f97e5b75379d40b08ff5f74847d5c +NativeFormatImporter: + userData: diff --git a/Assets/Behavior Designer Movement/Models.meta b/Assets/Behavior Designer Movement/Models.meta new file mode 100644 index 0000000..55776c0 --- /dev/null +++ b/Assets/Behavior Designer Movement/Models.meta @@ -0,0 +1,5 @@ +fileFormatVersion: 2 +guid: 56d86a9b23999bd43bc7780ac550783d +folderAsset: yes +DefaultImporter: + userData: diff --git a/Assets/Behavior Designer Movement/Models/TriangleBot.fbx b/Assets/Behavior Designer Movement/Models/TriangleBot.fbx new file mode 100644 index 0000000..eaeda0d --- /dev/null +++ b/Assets/Behavior Designer Movement/Models/TriangleBot.fbx @@ -0,0 +1,1503 @@ +; FBX 6.1.0 project file +; Created by Blender FBX Exporter +; for support mail: ideasman42@gmail.com +; ---------------------------------------------------- + +FBXHeaderExtension: { + FBXHeaderVersion: 1003 + FBXVersion: 6100 + CreationTimeStamp: { + Version: 1000 + Year: 2015 + Month: 04 + Day: 06 + Hour: 20 + Minute: 21 + Second: 20 + Millisecond: 0 + } + Creator: "FBX SDK/FBX Plugins build 20070228" + OtherFlags: { + FlagPLE: 0 + } +} +CreationTime: "2015-04-06 20:21:20:000" +Creator: "Blender version 2.70 (sub 0)" + +; Object definitions +;------------------------------------------------------------------ + +Definitions: { + Version: 100 + Count: 11 + ObjectType: "Model" { + Count: 9 + } + ObjectType: "Geometry" { + Count: 1 + } + ObjectType: "Material" { + Count: 1 + } + ObjectType: "Pose" { + Count: 1 + } + ObjectType: "GlobalSettings" { + Count: 1 + } +} + +; Object properties +;------------------------------------------------------------------ + +Objects: { + Model: "Model::Camera Switcher", "CameraSwitcher" { + Version: 232 + Properties60: { + Property: "QuaternionInterpolate", "bool", "",0 + Property: "Visibility", "Visibility", "A+",1 + Property: "Lcl Translation", "Lcl Translation", "A+",0.000000000000000,0.000000000000000,0.000000000000000 + Property: "Lcl Rotation", "Lcl Rotation", "A+",0.000000000000000,0.000000000000000,0.000000000000000 + Property: "Lcl Scaling", "Lcl Scaling", "A+",1.000000000000000,1.000000000000000,1.000000000000000 + Property: "RotationOffset", "Vector3D", "",0,0,0 + Property: "RotationPivot", "Vector3D", "",0,0,0 + Property: "ScalingOffset", "Vector3D", "",0,0,0 + Property: "ScalingPivot", "Vector3D", "",0,0,0 + Property: "TranslationActive", "bool", "",0 + Property: "TranslationMin", "Vector3D", "",0,0,0 + Property: "TranslationMax", "Vector3D", "",0,0,0 + Property: "TranslationMinX", "bool", "",0 + Property: "TranslationMinY", "bool", "",0 + Property: "TranslationMinZ", "bool", "",0 + Property: "TranslationMaxX", "bool", "",0 + Property: "TranslationMaxY", "bool", "",0 + Property: "TranslationMaxZ", "bool", "",0 + Property: "RotationOrder", "enum", "",0 + Property: "RotationSpaceForLimitOnly", "bool", "",0 + Property: "AxisLen", "double", "",10 + Property: "PreRotation", "Vector3D", "",0,0,0 + Property: "PostRotation", "Vector3D", "",0,0,0 + Property: "RotationActive", "bool", "",0 + Property: "RotationMin", "Vector3D", "",0,0,0 + Property: "RotationMax", "Vector3D", "",0,0,0 + Property: "RotationMinX", "bool", "",0 + Property: "RotationMinY", "bool", "",0 + Property: "RotationMinZ", "bool", "",0 + Property: "RotationMaxX", "bool", "",0 + Property: "RotationMaxY", "bool", "",0 + Property: "RotationMaxZ", "bool", "",0 + Property: "RotationStiffnessX", "double", "",0 + Property: "RotationStiffnessY", "double", "",0 + Property: "RotationStiffnessZ", "double", "",0 + Property: "MinDampRangeX", "double", "",0 + Property: "MinDampRangeY", "double", "",0 + Property: "MinDampRangeZ", "double", "",0 + Property: "MaxDampRangeX", "double", "",0 + Property: "MaxDampRangeY", "double", "",0 + Property: "MaxDampRangeZ", "double", "",0 + Property: "MinDampStrengthX", "double", "",0 + Property: "MinDampStrengthY", "double", "",0 + Property: "MinDampStrengthZ", "double", "",0 + Property: "MaxDampStrengthX", "double", "",0 + Property: "MaxDampStrengthY", "double", "",0 + Property: "MaxDampStrengthZ", "double", "",0 + Property: "PreferedAngleX", "double", "",0 + Property: "PreferedAngleY", "double", "",0 + Property: "PreferedAngleZ", "double", "",0 + Property: "InheritType", "enum", "",0 + Property: "ScalingActive", "bool", "",0 + Property: "ScalingMin", "Vector3D", "",1,1,1 + Property: "ScalingMax", "Vector3D", "",1,1,1 + Property: "ScalingMinX", "bool", "",0 + Property: "ScalingMinY", "bool", "",0 + Property: "ScalingMinZ", "bool", "",0 + Property: "ScalingMaxX", "bool", "",0 + Property: "ScalingMaxY", "bool", "",0 + Property: "ScalingMaxZ", "bool", "",0 + Property: "GeometricTranslation", "Vector3D", "",0,0,0 + Property: "GeometricRotation", "Vector3D", "",0,0,0 + Property: "GeometricScaling", "Vector3D", "",1,1,1 + Property: "LookAtProperty", "object", "" + Property: "UpVectorProperty", "object", "" + Property: "Show", "bool", "",1 + Property: "NegativePercentShapeSupport", "bool", "",1 + Property: "DefaultAttributeIndex", "int", "",0 + Property: "Color", "Color", "A",0.8,0.8,0.8 + Property: "Camera Index", "Integer", "A+",100 + } + MultiLayer: 0 + MultiTake: 1 + Hidden: "True" + Shading: W + Culling: "CullingOff" + Version: 101 + Name: "Model::Camera Switcher" + CameraId: 0 + CameraName: 100 + CameraIndexName: + } + Model: "Model::GreenTriangle", "Mesh" { + Version: 232 + Properties60: { + Property: "QuaternionInterpolate", "bool", "",0 + Property: "Visibility", "Visibility", "A+",1 + Property: "Lcl Translation", "Lcl Translation", "A+",0.000000000000000,0.000000000000000,0.000000000000000 + Property: "Lcl Rotation", "Lcl Rotation", "A+",0.000207410156830,-0.000000000000000,0.000000000000000 + Property: "Lcl Scaling", "Lcl Scaling", "A+",1.000000000000000,1.000000000000000,1.000000000000000 + Property: "RotationOffset", "Vector3D", "",0,0,0 + Property: "RotationPivot", "Vector3D", "",0,0,0 + Property: "ScalingOffset", "Vector3D", "",0,0,0 + Property: "ScalingPivot", "Vector3D", "",0,0,0 + Property: "TranslationActive", "bool", "",0 + Property: "TranslationMin", "Vector3D", "",0,0,0 + Property: "TranslationMax", "Vector3D", "",0,0,0 + Property: "TranslationMinX", "bool", "",0 + Property: "TranslationMinY", "bool", "",0 + Property: "TranslationMinZ", "bool", "",0 + Property: "TranslationMaxX", "bool", "",0 + Property: "TranslationMaxY", "bool", "",0 + Property: "TranslationMaxZ", "bool", "",0 + Property: "RotationOrder", "enum", "",0 + Property: "RotationSpaceForLimitOnly", "bool", "",0 + Property: "AxisLen", "double", "",10 + Property: "PreRotation", "Vector3D", "",0,0,0 + Property: "PostRotation", "Vector3D", "",0,0,0 + Property: "RotationActive", "bool", "",0 + Property: "RotationMin", "Vector3D", "",0,0,0 + Property: "RotationMax", "Vector3D", "",0,0,0 + Property: "RotationMinX", "bool", "",0 + Property: "RotationMinY", "bool", "",0 + Property: "RotationMinZ", "bool", "",0 + Property: "RotationMaxX", "bool", "",0 + Property: "RotationMaxY", "bool", "",0 + Property: "RotationMaxZ", "bool", "",0 + Property: "RotationStiffnessX", "double", "",0 + Property: "RotationStiffnessY", "double", "",0 + Property: "RotationStiffnessZ", "double", "",0 + Property: "MinDampRangeX", "double", "",0 + Property: "MinDampRangeY", "double", "",0 + Property: "MinDampRangeZ", "double", "",0 + Property: "MaxDampRangeX", "double", "",0 + Property: "MaxDampRangeY", "double", "",0 + Property: "MaxDampRangeZ", "double", "",0 + Property: "MinDampStrengthX", "double", "",0 + Property: "MinDampStrengthY", "double", "",0 + Property: "MinDampStrengthZ", "double", "",0 + Property: "MaxDampStrengthX", "double", "",0 + Property: "MaxDampStrengthY", "double", "",0 + Property: "MaxDampStrengthZ", "double", "",0 + Property: "PreferedAngleX", "double", "",0 + Property: "PreferedAngleY", "double", "",0 + Property: "PreferedAngleZ", "double", "",0 + Property: "InheritType", "enum", "",0 + Property: "ScalingActive", "bool", "",0 + Property: "ScalingMin", "Vector3D", "",1,1,1 + Property: "ScalingMax", "Vector3D", "",1,1,1 + Property: "ScalingMinX", "bool", "",0 + Property: "ScalingMinY", "bool", "",0 + Property: "ScalingMinZ", "bool", "",0 + Property: "ScalingMaxX", "bool", "",0 + Property: "ScalingMaxY", "bool", "",0 + Property: "ScalingMaxZ", "bool", "",0 + Property: "GeometricTranslation", "Vector3D", "",0,0,0 + Property: "GeometricRotation", "Vector3D", "",0,0,0 + Property: "GeometricScaling", "Vector3D", "",1,1,1 + Property: "LookAtProperty", "object", "" + Property: "UpVectorProperty", "object", "" + Property: "Show", "bool", "",1 + Property: "NegativePercentShapeSupport", "bool", "",1 + Property: "DefaultAttributeIndex", "int", "",0 + Property: "Color", "Color", "A",0.8,0.8,0.8 + Property: "Size", "double", "",100 + Property: "Look", "enum", "",1 + } + MultiLayer: 0 + MultiTake: 1 + Shading: Y + Culling: "CullingOff" + Vertices: -0.500000,0.399999,-0.331573,0.500000,0.399999,-0.331573,0.000000,0.400001,0.668427,0.000000,-0.399999,0.668428, + 0.500000,-0.400001,-0.331572,-0.500000,-0.400001,-0.331571,0.000000,-0.499999,0.543322,0.409472,-0.500001,-0.275622, + -0.409472,-0.500001,-0.275622,-0.500000,-0.000001,-0.331572,0.000000,0.500001,0.543320,0.409472,0.499999,-0.275624, + -0.409472,0.499999,-0.275624,0.000000,0.000001,0.668428,0.500000,-0.000001,-0.331572 + PolygonVertexIndex: 6,8,-8,6,7,4,-4,7,8,5,-5,8,6,3,-6,10,11,-13,13,14,1,-3,10,2,1,-12,11,1,0,-13,12,0, + 2,-11,13,3,4,-15,14,4,5,-10,9,5,3,-14,9,13,2,-1,14,9,0,-2 + GeometryVersion: 124 + LayerElementNormal: 0 { + Version: 101 + Name: "" + MappingInformationType: "ByPolygonVertex" + ReferenceInformationType: "Direct" + Normals: 0.000000,-1.000000,0.000002,0.000000,-1.000000,0.000002,0.000000,-1.000000,0.000002,0.780562,-0.488265,0.390281, + 0.780562,-0.488265,0.390281,0.780562,-0.488265,0.390281,0.780562,-0.488265,0.390281,-0.000000,-0.488268,-0.872694, + -0.000000,-0.488268,-0.872694,-0.000000,-0.488268,-0.872694,-0.000000,-0.488268,-0.872694,-0.780562,-0.488266,0.390282, + -0.780562,-0.488266,0.390282,-0.780562,-0.488266,0.390282,-0.780562,-0.488266,0.390282,-0.000000,1.000000,-0.000002, + -0.000000,1.000000,-0.000002,-0.000000,1.000000,-0.000002,0.894427,0.000001,0.447213,0.894427,0.000001,0.447213, + 0.894427,0.000001,0.447213,0.894427,0.000001,0.447213,0.780562,0.488267,0.390280,0.780562,0.488267,0.390280, + 0.780562,0.488267,0.390280,0.780562,0.488267,0.390280,-0.000000,0.488265,-0.872696,-0.000000,0.488265,-0.872696, + -0.000000,0.488265,-0.872696,-0.000000,0.488265,-0.872696,-0.780562,0.488267,0.390280,-0.780562,0.488267,0.390280, + -0.780562,0.488267,0.390280,-0.780562,0.488267,0.390280,0.894427,0.000001,0.447213,0.894427,0.000001,0.447213, + 0.894427,0.000001,0.447213,0.894427,0.000001,0.447213,-0.000000,-0.000002,-1.000000,-0.000000,-0.000002,-1.000000, + -0.000000,-0.000002,-1.000000,-0.000000,-0.000002,-1.000000,-0.894427,0.000001,0.447214,-0.894427,0.000001,0.447214, + -0.894427,0.000001,0.447214,-0.894427,0.000001,0.447214,-0.894427,0.000001,0.447214,-0.894427,0.000001,0.447214, + -0.894427,0.000001,0.447214,-0.894427,0.000001,0.447214,-0.000000,-0.000002,-1.000000,-0.000000,-0.000002,-1.000000, + -0.000000,-0.000002,-1.000000,-0.000000,-0.000002,-1.000000 + } + LayerElementSmoothing: 0 { + Version: 102 + Name: "" + MappingInformationType: "ByPolygon" + ReferenceInformationType: "Direct" + Smoothing: 0,0,0,0,0,0,0,0,0,0,0,0,0,0 + } + LayerElementUV: 0 { + Version: 101 + Name: "UVMap" + MappingInformationType: "ByPolygonVertex" + ReferenceInformationType: "IndexToDirect" + UV: 0.510014,0.803371,0.768909,0.232201,0.157318,0.023944,0.975186,0.242025,0.633324,0.987534,0.852657,0.024144, + 0.510613,0.920775,0.157317,0.175266,0.633142,0.987336,0.852474,0.175267,0.510197,0.803570,0.975003,0.241827, + 0.852656,0.175465,0.034788,0.244052,0.241273,0.229038,0.388266,0.989760,0.768726,0.232003,0.241090,0.228839, + 0.157500,0.175464,0.510795,0.920974,0.157500,0.024143,0.852474,0.023945,0.034971,0.244251,0.388084,0.989561 + UVIndex: 0,17,16,0,16,9,6,16,17,7,9,17,0,6,7,10,1,14,4,3,12,19,10,19,12,1,1,12,18,14,14,18,19,10,8,6,9,11,21,9,7,2,13,7,6,23,22,15,19,18,5,20,18,12 + } + LayerElementTexture: 0 { + Version: 101 + Name: "" + MappingInformationType: "NoMappingInformation" + ReferenceInformationType: "IndexToDirect" + BlendMode: "Translucent" + TextureAlpha: 1 + TextureId: + } + LayerElementMaterial: 0 { + Version: 101 + Name: "" + MappingInformationType: "AllSame" + ReferenceInformationType: "IndexToDirect" + Materials: 0 + } + Layer: 0 { + Version: 100 + LayerElement: { + Type: "LayerElementNormal" + TypedIndex: 0 + } + LayerElement: { + Type: "LayerElementSmoothing" + TypedIndex: 0 + } + LayerElement: { + Type: "LayerElementUV" + TypedIndex: 0 + } + LayerElement: { + Type: "LayerElementTexture" + TypedIndex: 0 + } + LayerElement: { + Type: "LayerElementMaterial" + TypedIndex: 0 + } + } + } + Model: "Model::Producer Perspective", "Camera" { + Version: 232 + Properties60: { + Property: "QuaternionInterpolate", "bool", "",0 + Property: "Visibility", "Visibility", "A+",1 + Property: "Lcl Translation", "Lcl Translation", "A+",0.000000000000000,71.299999999999997,287.500000000000000 + Property: "Lcl Rotation", "Lcl Rotation", "A+",0.000000000000000,0.000000000000000,0.000000000000000 + Property: "Lcl Scaling", "Lcl Scaling", "A+",1.000000000000000,1.000000000000000,1.000000000000000 + Property: "RotationOffset", "Vector3D", "",0,0,0 + Property: "RotationPivot", "Vector3D", "",0,0,0 + Property: "ScalingOffset", "Vector3D", "",0,0,0 + Property: "ScalingPivot", "Vector3D", "",0,0,0 + Property: "TranslationActive", "bool", "",0 + Property: "TranslationMin", "Vector3D", "",0,0,0 + Property: "TranslationMax", "Vector3D", "",0,0,0 + Property: "TranslationMinX", "bool", "",0 + Property: "TranslationMinY", "bool", "",0 + Property: "TranslationMinZ", "bool", "",0 + Property: "TranslationMaxX", "bool", "",0 + Property: "TranslationMaxY", "bool", "",0 + Property: "TranslationMaxZ", "bool", "",0 + Property: "RotationOrder", "enum", "",0 + Property: "RotationSpaceForLimitOnly", "bool", "",0 + Property: "AxisLen", "double", "",10 + Property: "PreRotation", "Vector3D", "",0,0,0 + Property: "PostRotation", "Vector3D", "",0,0,0 + Property: "RotationActive", "bool", "",0 + Property: "RotationMin", "Vector3D", "",0,0,0 + Property: "RotationMax", "Vector3D", "",0,0,0 + Property: "RotationMinX", "bool", "",0 + Property: "RotationMinY", "bool", "",0 + Property: "RotationMinZ", "bool", "",0 + Property: "RotationMaxX", "bool", "",0 + Property: "RotationMaxY", "bool", "",0 + Property: "RotationMaxZ", "bool", "",0 + Property: "RotationStiffnessX", "double", "",0 + Property: "RotationStiffnessY", "double", "",0 + Property: "RotationStiffnessZ", "double", "",0 + Property: "MinDampRangeX", "double", "",0 + Property: "MinDampRangeY", "double", "",0 + Property: "MinDampRangeZ", "double", "",0 + Property: "MaxDampRangeX", "double", "",0 + Property: "MaxDampRangeY", "double", "",0 + Property: "MaxDampRangeZ", "double", "",0 + Property: "MinDampStrengthX", "double", "",0 + Property: "MinDampStrengthY", "double", "",0 + Property: "MinDampStrengthZ", "double", "",0 + Property: "MaxDampStrengthX", "double", "",0 + Property: "MaxDampStrengthY", "double", "",0 + Property: "MaxDampStrengthZ", "double", "",0 + Property: "PreferedAngleX", "double", "",0 + Property: "PreferedAngleY", "double", "",0 + Property: "PreferedAngleZ", "double", "",0 + Property: "InheritType", "enum", "",0 + Property: "ScalingActive", "bool", "",0 + Property: "ScalingMin", "Vector3D", "",1,1,1 + Property: "ScalingMax", "Vector3D", "",1,1,1 + Property: "ScalingMinX", "bool", "",0 + Property: "ScalingMinY", "bool", "",0 + Property: "ScalingMinZ", "bool", "",0 + Property: "ScalingMaxX", "bool", "",0 + Property: "ScalingMaxY", "bool", "",0 + Property: "ScalingMaxZ", "bool", "",0 + Property: "GeometricTranslation", "Vector3D", "",0,0,0 + Property: "GeometricRotation", "Vector3D", "",0,0,0 + Property: "GeometricScaling", "Vector3D", "",1,1,1 + Property: "LookAtProperty", "object", "" + Property: "UpVectorProperty", "object", "" + Property: "Show", "bool", "",1 + Property: "NegativePercentShapeSupport", "bool", "",1 + Property: "DefaultAttributeIndex", "int", "",0 + Property: "Color", "Color", "A",0.8,0.8,0.8 + Property: "Roll", "Roll", "A+",0 + Property: "FieldOfView", "FieldOfView", "A+",40 + Property: "FieldOfViewX", "FieldOfView", "A+",1 + Property: "FieldOfViewY", "FieldOfView", "A+",1 + Property: "OpticalCenterX", "Real", "A+",0 + Property: "OpticalCenterY", "Real", "A+",0 + Property: "BackgroundColor", "Color", "A+",0.63,0.63,0.63 + Property: "TurnTable", "Real", "A+",0 + Property: "DisplayTurnTableIcon", "bool", "",1 + Property: "Motion Blur Intensity", "Real", "A+",1 + Property: "UseMotionBlur", "bool", "",0 + Property: "UseRealTimeMotionBlur", "bool", "",1 + Property: "ResolutionMode", "enum", "",0 + Property: "ApertureMode", "enum", "",2 + Property: "GateFit", "enum", "",0 + Property: "FocalLength", "Real", "A+",21.3544940948486 + Property: "CameraFormat", "enum", "",0 + Property: "AspectW", "double", "",320 + Property: "AspectH", "double", "",200 + Property: "PixelAspectRatio", "double", "",1 + Property: "UseFrameColor", "bool", "",0 + Property: "FrameColor", "ColorRGB", "",0.3,0.3,0.3 + Property: "ShowName", "bool", "",1 + Property: "ShowGrid", "bool", "",1 + Property: "ShowOpticalCenter", "bool", "",0 + Property: "ShowAzimut", "bool", "",1 + Property: "ShowTimeCode", "bool", "",0 + Property: "NearPlane", "double", "",10.000000 + Property: "FarPlane", "double", "",4000.000000 + Property: "FilmWidth", "double", "",0.816 + Property: "FilmHeight", "double", "",0.612 + Property: "FilmAspectRatio", "double", "",1.33333333333333 + Property: "FilmSqueezeRatio", "double", "",1 + Property: "FilmFormatIndex", "enum", "",4 + Property: "ViewFrustum", "bool", "",1 + Property: "ViewFrustumNearFarPlane", "bool", "",0 + Property: "ViewFrustumBackPlaneMode", "enum", "",2 + Property: "BackPlaneDistance", "double", "",100 + Property: "BackPlaneDistanceMode", "enum", "",0 + Property: "ViewCameraToLookAt", "bool", "",1 + Property: "LockMode", "bool", "",0 + Property: "LockInterestNavigation", "bool", "",0 + Property: "FitImage", "bool", "",0 + Property: "Crop", "bool", "",0 + Property: "Center", "bool", "",1 + Property: "KeepRatio", "bool", "",1 + Property: "BackgroundMode", "enum", "",0 + Property: "BackgroundAlphaTreshold", "double", "",0.5 + Property: "ForegroundTransparent", "bool", "",1 + Property: "DisplaySafeArea", "bool", "",0 + Property: "SafeAreaDisplayStyle", "enum", "",1 + Property: "SafeAreaAspectRatio", "double", "",1.33333333333333 + Property: "Use2DMagnifierZoom", "bool", "",0 + Property: "2D Magnifier Zoom", "Real", "A+",100 + Property: "2D Magnifier X", "Real", "A+",50 + Property: "2D Magnifier Y", "Real", "A+",50 + Property: "CameraProjectionType", "enum", "",0 + Property: "UseRealTimeDOFAndAA", "bool", "",0 + Property: "UseDepthOfField", "bool", "",0 + Property: "FocusSource", "enum", "",0 + Property: "FocusAngle", "double", "",3.5 + Property: "FocusDistance", "double", "",200 + Property: "UseAntialiasing", "bool", "",0 + Property: "AntialiasingIntensity", "double", "",0.77777 + Property: "UseAccumulationBuffer", "bool", "",0 + Property: "FrameSamplingCount", "int", "",7 + } + MultiLayer: 0 + MultiTake: 0 + Hidden: "True" + Shading: Y + Culling: "CullingOff" + TypeFlags: "Camera" + GeometryVersion: 124 + Position: 0.000000,71.300000,287.500000 + Up: 0,1,0 + LookAt: 0,0,0 + ShowInfoOnMoving: 1 + ShowAudio: 0 + AudioColor: 0,1,0 + CameraOrthoZoom: 1 + } + Model: "Model::Producer Top", "Camera" { + Version: 232 + Properties60: { + Property: "QuaternionInterpolate", "bool", "",0 + Property: "Visibility", "Visibility", "A+",1 + Property: "Lcl Translation", "Lcl Translation", "A+",0.000000000000000,4000.000000000000000,0.000000000000000 + Property: "Lcl Rotation", "Lcl Rotation", "A+",0.000000000000000,0.000000000000000,0.000000000000000 + Property: "Lcl Scaling", "Lcl Scaling", "A+",1.000000000000000,1.000000000000000,1.000000000000000 + Property: "RotationOffset", "Vector3D", "",0,0,0 + Property: "RotationPivot", "Vector3D", "",0,0,0 + Property: "ScalingOffset", "Vector3D", "",0,0,0 + Property: "ScalingPivot", "Vector3D", "",0,0,0 + Property: "TranslationActive", "bool", "",0 + Property: "TranslationMin", "Vector3D", "",0,0,0 + Property: "TranslationMax", "Vector3D", "",0,0,0 + Property: "TranslationMinX", "bool", "",0 + Property: "TranslationMinY", "bool", "",0 + Property: "TranslationMinZ", "bool", "",0 + Property: "TranslationMaxX", "bool", "",0 + Property: "TranslationMaxY", "bool", "",0 + Property: "TranslationMaxZ", "bool", "",0 + Property: "RotationOrder", "enum", "",0 + Property: "RotationSpaceForLimitOnly", "bool", "",0 + Property: "AxisLen", "double", "",10 + Property: "PreRotation", "Vector3D", "",0,0,0 + Property: "PostRotation", "Vector3D", "",0,0,0 + Property: "RotationActive", "bool", "",0 + Property: "RotationMin", "Vector3D", "",0,0,0 + Property: "RotationMax", "Vector3D", "",0,0,0 + Property: "RotationMinX", "bool", "",0 + Property: "RotationMinY", "bool", "",0 + Property: "RotationMinZ", "bool", "",0 + Property: "RotationMaxX", "bool", "",0 + Property: "RotationMaxY", "bool", "",0 + Property: "RotationMaxZ", "bool", "",0 + Property: "RotationStiffnessX", "double", "",0 + Property: "RotationStiffnessY", "double", "",0 + Property: "RotationStiffnessZ", "double", "",0 + Property: "MinDampRangeX", "double", "",0 + Property: "MinDampRangeY", "double", "",0 + Property: "MinDampRangeZ", "double", "",0 + Property: "MaxDampRangeX", "double", "",0 + Property: "MaxDampRangeY", "double", "",0 + Property: "MaxDampRangeZ", "double", "",0 + Property: "MinDampStrengthX", "double", "",0 + Property: "MinDampStrengthY", "double", "",0 + Property: "MinDampStrengthZ", "double", "",0 + Property: "MaxDampStrengthX", "double", "",0 + Property: "MaxDampStrengthY", "double", "",0 + Property: "MaxDampStrengthZ", "double", "",0 + Property: "PreferedAngleX", "double", "",0 + Property: "PreferedAngleY", "double", "",0 + Property: "PreferedAngleZ", "double", "",0 + Property: "InheritType", "enum", "",0 + Property: "ScalingActive", "bool", "",0 + Property: "ScalingMin", "Vector3D", "",1,1,1 + Property: "ScalingMax", "Vector3D", "",1,1,1 + Property: "ScalingMinX", "bool", "",0 + Property: "ScalingMinY", "bool", "",0 + Property: "ScalingMinZ", "bool", "",0 + Property: "ScalingMaxX", "bool", "",0 + Property: "ScalingMaxY", "bool", "",0 + Property: "ScalingMaxZ", "bool", "",0 + Property: "GeometricTranslation", "Vector3D", "",0,0,0 + Property: "GeometricRotation", "Vector3D", "",0,0,0 + Property: "GeometricScaling", "Vector3D", "",1,1,1 + Property: "LookAtProperty", "object", "" + Property: "UpVectorProperty", "object", "" + Property: "Show", "bool", "",1 + Property: "NegativePercentShapeSupport", "bool", "",1 + Property: "DefaultAttributeIndex", "int", "",0 + Property: "Color", "Color", "A",0.8,0.8,0.8 + Property: "Roll", "Roll", "A+",0 + Property: "FieldOfView", "FieldOfView", "A+",40 + Property: "FieldOfViewX", "FieldOfView", "A+",1 + Property: "FieldOfViewY", "FieldOfView", "A+",1 + Property: "OpticalCenterX", "Real", "A+",0 + Property: "OpticalCenterY", "Real", "A+",0 + Property: "BackgroundColor", "Color", "A+",0.63,0.63,0.63 + Property: "TurnTable", "Real", "A+",0 + Property: "DisplayTurnTableIcon", "bool", "",1 + Property: "Motion Blur Intensity", "Real", "A+",1 + Property: "UseMotionBlur", "bool", "",0 + Property: "UseRealTimeMotionBlur", "bool", "",1 + Property: "ResolutionMode", "enum", "",0 + Property: "ApertureMode", "enum", "",2 + Property: "GateFit", "enum", "",0 + Property: "FocalLength", "Real", "A+",21.3544940948486 + Property: "CameraFormat", "enum", "",0 + Property: "AspectW", "double", "",320 + Property: "AspectH", "double", "",200 + Property: "PixelAspectRatio", "double", "",1 + Property: "UseFrameColor", "bool", "",0 + Property: "FrameColor", "ColorRGB", "",0.3,0.3,0.3 + Property: "ShowName", "bool", "",1 + Property: "ShowGrid", "bool", "",1 + Property: "ShowOpticalCenter", "bool", "",0 + Property: "ShowAzimut", "bool", "",1 + Property: "ShowTimeCode", "bool", "",0 + Property: "NearPlane", "double", "",1.000000 + Property: "FarPlane", "double", "",30000.000000 + Property: "FilmWidth", "double", "",0.816 + Property: "FilmHeight", "double", "",0.612 + Property: "FilmAspectRatio", "double", "",1.33333333333333 + Property: "FilmSqueezeRatio", "double", "",1 + Property: "FilmFormatIndex", "enum", "",4 + Property: "ViewFrustum", "bool", "",1 + Property: "ViewFrustumNearFarPlane", "bool", "",0 + Property: "ViewFrustumBackPlaneMode", "enum", "",2 + Property: "BackPlaneDistance", "double", "",100 + Property: "BackPlaneDistanceMode", "enum", "",0 + Property: "ViewCameraToLookAt", "bool", "",1 + Property: "LockMode", "bool", "",0 + Property: "LockInterestNavigation", "bool", "",0 + Property: "FitImage", "bool", "",0 + Property: "Crop", "bool", "",0 + Property: "Center", "bool", "",1 + Property: "KeepRatio", "bool", "",1 + Property: "BackgroundMode", "enum", "",0 + Property: "BackgroundAlphaTreshold", "double", "",0.5 + Property: "ForegroundTransparent", "bool", "",1 + Property: "DisplaySafeArea", "bool", "",0 + Property: "SafeAreaDisplayStyle", "enum", "",1 + Property: "SafeAreaAspectRatio", "double", "",1.33333333333333 + Property: "Use2DMagnifierZoom", "bool", "",0 + Property: "2D Magnifier Zoom", "Real", "A+",100 + Property: "2D Magnifier X", "Real", "A+",50 + Property: "2D Magnifier Y", "Real", "A+",50 + Property: "CameraProjectionType", "enum", "",1 + Property: "UseRealTimeDOFAndAA", "bool", "",0 + Property: "UseDepthOfField", "bool", "",0 + Property: "FocusSource", "enum", "",0 + Property: "FocusAngle", "double", "",3.5 + Property: "FocusDistance", "double", "",200 + Property: "UseAntialiasing", "bool", "",0 + Property: "AntialiasingIntensity", "double", "",0.77777 + Property: "UseAccumulationBuffer", "bool", "",0 + Property: "FrameSamplingCount", "int", "",7 + } + MultiLayer: 0 + MultiTake: 0 + Hidden: "True" + Shading: Y + Culling: "CullingOff" + TypeFlags: "Camera" + GeometryVersion: 124 + Position: 0.000000,4000.000000,0.000000 + Up: 0,0,-1 + LookAt: 0,0,0 + ShowInfoOnMoving: 1 + ShowAudio: 0 + AudioColor: 0,1,0 + CameraOrthoZoom: 1 + } + Model: "Model::Producer Bottom", "Camera" { + Version: 232 + Properties60: { + Property: "QuaternionInterpolate", "bool", "",0 + Property: "Visibility", "Visibility", "A+",1 + Property: "Lcl Translation", "Lcl Translation", "A+",0.000000000000000,-4000.000000000000000,0.000000000000000 + Property: "Lcl Rotation", "Lcl Rotation", "A+",0.000000000000000,0.000000000000000,0.000000000000000 + Property: "Lcl Scaling", "Lcl Scaling", "A+",1.000000000000000,1.000000000000000,1.000000000000000 + Property: "RotationOffset", "Vector3D", "",0,0,0 + Property: "RotationPivot", "Vector3D", "",0,0,0 + Property: "ScalingOffset", "Vector3D", "",0,0,0 + Property: "ScalingPivot", "Vector3D", "",0,0,0 + Property: "TranslationActive", "bool", "",0 + Property: "TranslationMin", "Vector3D", "",0,0,0 + Property: "TranslationMax", "Vector3D", "",0,0,0 + Property: "TranslationMinX", "bool", "",0 + Property: "TranslationMinY", "bool", "",0 + Property: "TranslationMinZ", "bool", "",0 + Property: "TranslationMaxX", "bool", "",0 + Property: "TranslationMaxY", "bool", "",0 + Property: "TranslationMaxZ", "bool", "",0 + Property: "RotationOrder", "enum", "",0 + Property: "RotationSpaceForLimitOnly", "bool", "",0 + Property: "AxisLen", "double", "",10 + Property: "PreRotation", "Vector3D", "",0,0,0 + Property: "PostRotation", "Vector3D", "",0,0,0 + Property: "RotationActive", "bool", "",0 + Property: "RotationMin", "Vector3D", "",0,0,0 + Property: "RotationMax", "Vector3D", "",0,0,0 + Property: "RotationMinX", "bool", "",0 + Property: "RotationMinY", "bool", "",0 + Property: "RotationMinZ", "bool", "",0 + Property: "RotationMaxX", "bool", "",0 + Property: "RotationMaxY", "bool", "",0 + Property: "RotationMaxZ", "bool", "",0 + Property: "RotationStiffnessX", "double", "",0 + Property: "RotationStiffnessY", "double", "",0 + Property: "RotationStiffnessZ", "double", "",0 + Property: "MinDampRangeX", "double", "",0 + Property: "MinDampRangeY", "double", "",0 + Property: "MinDampRangeZ", "double", "",0 + Property: "MaxDampRangeX", "double", "",0 + Property: "MaxDampRangeY", "double", "",0 + Property: "MaxDampRangeZ", "double", "",0 + Property: "MinDampStrengthX", "double", "",0 + Property: "MinDampStrengthY", "double", "",0 + Property: "MinDampStrengthZ", "double", "",0 + Property: "MaxDampStrengthX", "double", "",0 + Property: "MaxDampStrengthY", "double", "",0 + Property: "MaxDampStrengthZ", "double", "",0 + Property: "PreferedAngleX", "double", "",0 + Property: "PreferedAngleY", "double", "",0 + Property: "PreferedAngleZ", "double", "",0 + Property: "InheritType", "enum", "",0 + Property: "ScalingActive", "bool", "",0 + Property: "ScalingMin", "Vector3D", "",1,1,1 + Property: "ScalingMax", "Vector3D", "",1,1,1 + Property: "ScalingMinX", "bool", "",0 + Property: "ScalingMinY", "bool", "",0 + Property: "ScalingMinZ", "bool", "",0 + Property: "ScalingMaxX", "bool", "",0 + Property: "ScalingMaxY", "bool", "",0 + Property: "ScalingMaxZ", "bool", "",0 + Property: "GeometricTranslation", "Vector3D", "",0,0,0 + Property: "GeometricRotation", "Vector3D", "",0,0,0 + Property: "GeometricScaling", "Vector3D", "",1,1,1 + Property: "LookAtProperty", "object", "" + Property: "UpVectorProperty", "object", "" + Property: "Show", "bool", "",1 + Property: "NegativePercentShapeSupport", "bool", "",1 + Property: "DefaultAttributeIndex", "int", "",0 + Property: "Color", "Color", "A",0.8,0.8,0.8 + Property: "Roll", "Roll", "A+",0 + Property: "FieldOfView", "FieldOfView", "A+",40 + Property: "FieldOfViewX", "FieldOfView", "A+",1 + Property: "FieldOfViewY", "FieldOfView", "A+",1 + Property: "OpticalCenterX", "Real", "A+",0 + Property: "OpticalCenterY", "Real", "A+",0 + Property: "BackgroundColor", "Color", "A+",0.63,0.63,0.63 + Property: "TurnTable", "Real", "A+",0 + Property: "DisplayTurnTableIcon", "bool", "",1 + Property: "Motion Blur Intensity", "Real", "A+",1 + Property: "UseMotionBlur", "bool", "",0 + Property: "UseRealTimeMotionBlur", "bool", "",1 + Property: "ResolutionMode", "enum", "",0 + Property: "ApertureMode", "enum", "",2 + Property: "GateFit", "enum", "",0 + Property: "FocalLength", "Real", "A+",21.3544940948486 + Property: "CameraFormat", "enum", "",0 + Property: "AspectW", "double", "",320 + Property: "AspectH", "double", "",200 + Property: "PixelAspectRatio", "double", "",1 + Property: "UseFrameColor", "bool", "",0 + Property: "FrameColor", "ColorRGB", "",0.3,0.3,0.3 + Property: "ShowName", "bool", "",1 + Property: "ShowGrid", "bool", "",1 + Property: "ShowOpticalCenter", "bool", "",0 + Property: "ShowAzimut", "bool", "",1 + Property: "ShowTimeCode", "bool", "",0 + Property: "NearPlane", "double", "",1.000000 + Property: "FarPlane", "double", "",30000.000000 + Property: "FilmWidth", "double", "",0.816 + Property: "FilmHeight", "double", "",0.612 + Property: "FilmAspectRatio", "double", "",1.33333333333333 + Property: "FilmSqueezeRatio", "double", "",1 + Property: "FilmFormatIndex", "enum", "",4 + Property: "ViewFrustum", "bool", "",1 + Property: "ViewFrustumNearFarPlane", "bool", "",0 + Property: "ViewFrustumBackPlaneMode", "enum", "",2 + Property: "BackPlaneDistance", "double", "",100 + Property: "BackPlaneDistanceMode", "enum", "",0 + Property: "ViewCameraToLookAt", "bool", "",1 + Property: "LockMode", "bool", "",0 + Property: "LockInterestNavigation", "bool", "",0 + Property: "FitImage", "bool", "",0 + Property: "Crop", "bool", "",0 + Property: "Center", "bool", "",1 + Property: "KeepRatio", "bool", "",1 + Property: "BackgroundMode", "enum", "",0 + Property: "BackgroundAlphaTreshold", "double", "",0.5 + Property: "ForegroundTransparent", "bool", "",1 + Property: "DisplaySafeArea", "bool", "",0 + Property: "SafeAreaDisplayStyle", "enum", "",1 + Property: "SafeAreaAspectRatio", "double", "",1.33333333333333 + Property: "Use2DMagnifierZoom", "bool", "",0 + Property: "2D Magnifier Zoom", "Real", "A+",100 + Property: "2D Magnifier X", "Real", "A+",50 + Property: "2D Magnifier Y", "Real", "A+",50 + Property: "CameraProjectionType", "enum", "",1 + Property: "UseRealTimeDOFAndAA", "bool", "",0 + Property: "UseDepthOfField", "bool", "",0 + Property: "FocusSource", "enum", "",0 + Property: "FocusAngle", "double", "",3.5 + Property: "FocusDistance", "double", "",200 + Property: "UseAntialiasing", "bool", "",0 + Property: "AntialiasingIntensity", "double", "",0.77777 + Property: "UseAccumulationBuffer", "bool", "",0 + Property: "FrameSamplingCount", "int", "",7 + } + MultiLayer: 0 + MultiTake: 0 + Hidden: "True" + Shading: Y + Culling: "CullingOff" + TypeFlags: "Camera" + GeometryVersion: 124 + Position: 0.000000,-4000.000000,0.000000 + Up: 0,0,-1 + LookAt: 0,0,0 + ShowInfoOnMoving: 1 + ShowAudio: 0 + AudioColor: 0,1,0 + CameraOrthoZoom: 1 + } + Model: "Model::Producer Front", "Camera" { + Version: 232 + Properties60: { + Property: "QuaternionInterpolate", "bool", "",0 + Property: "Visibility", "Visibility", "A+",1 + Property: "Lcl Translation", "Lcl Translation", "A+",0.000000000000000,0.000000000000000,4000.000000000000000 + Property: "Lcl Rotation", "Lcl Rotation", "A+",0.000000000000000,0.000000000000000,0.000000000000000 + Property: "Lcl Scaling", "Lcl Scaling", "A+",1.000000000000000,1.000000000000000,1.000000000000000 + Property: "RotationOffset", "Vector3D", "",0,0,0 + Property: "RotationPivot", "Vector3D", "",0,0,0 + Property: "ScalingOffset", "Vector3D", "",0,0,0 + Property: "ScalingPivot", "Vector3D", "",0,0,0 + Property: "TranslationActive", "bool", "",0 + Property: "TranslationMin", "Vector3D", "",0,0,0 + Property: "TranslationMax", "Vector3D", "",0,0,0 + Property: "TranslationMinX", "bool", "",0 + Property: "TranslationMinY", "bool", "",0 + Property: "TranslationMinZ", "bool", "",0 + Property: "TranslationMaxX", "bool", "",0 + Property: "TranslationMaxY", "bool", "",0 + Property: "TranslationMaxZ", "bool", "",0 + Property: "RotationOrder", "enum", "",0 + Property: "RotationSpaceForLimitOnly", "bool", "",0 + Property: "AxisLen", "double", "",10 + Property: "PreRotation", "Vector3D", "",0,0,0 + Property: "PostRotation", "Vector3D", "",0,0,0 + Property: "RotationActive", "bool", "",0 + Property: "RotationMin", "Vector3D", "",0,0,0 + Property: "RotationMax", "Vector3D", "",0,0,0 + Property: "RotationMinX", "bool", "",0 + Property: "RotationMinY", "bool", "",0 + Property: "RotationMinZ", "bool", "",0 + Property: "RotationMaxX", "bool", "",0 + Property: "RotationMaxY", "bool", "",0 + Property: "RotationMaxZ", "bool", "",0 + Property: "RotationStiffnessX", "double", "",0 + Property: "RotationStiffnessY", "double", "",0 + Property: "RotationStiffnessZ", "double", "",0 + Property: "MinDampRangeX", "double", "",0 + Property: "MinDampRangeY", "double", "",0 + Property: "MinDampRangeZ", "double", "",0 + Property: "MaxDampRangeX", "double", "",0 + Property: "MaxDampRangeY", "double", "",0 + Property: "MaxDampRangeZ", "double", "",0 + Property: "MinDampStrengthX", "double", "",0 + Property: "MinDampStrengthY", "double", "",0 + Property: "MinDampStrengthZ", "double", "",0 + Property: "MaxDampStrengthX", "double", "",0 + Property: "MaxDampStrengthY", "double", "",0 + Property: "MaxDampStrengthZ", "double", "",0 + Property: "PreferedAngleX", "double", "",0 + Property: "PreferedAngleY", "double", "",0 + Property: "PreferedAngleZ", "double", "",0 + Property: "InheritType", "enum", "",0 + Property: "ScalingActive", "bool", "",0 + Property: "ScalingMin", "Vector3D", "",1,1,1 + Property: "ScalingMax", "Vector3D", "",1,1,1 + Property: "ScalingMinX", "bool", "",0 + Property: "ScalingMinY", "bool", "",0 + Property: "ScalingMinZ", "bool", "",0 + Property: "ScalingMaxX", "bool", "",0 + Property: "ScalingMaxY", "bool", "",0 + Property: "ScalingMaxZ", "bool", "",0 + Property: "GeometricTranslation", "Vector3D", "",0,0,0 + Property: "GeometricRotation", "Vector3D", "",0,0,0 + Property: "GeometricScaling", "Vector3D", "",1,1,1 + Property: "LookAtProperty", "object", "" + Property: "UpVectorProperty", "object", "" + Property: "Show", "bool", "",1 + Property: "NegativePercentShapeSupport", "bool", "",1 + Property: "DefaultAttributeIndex", "int", "",0 + Property: "Color", "Color", "A",0.8,0.8,0.8 + Property: "Roll", "Roll", "A+",0 + Property: "FieldOfView", "FieldOfView", "A+",40 + Property: "FieldOfViewX", "FieldOfView", "A+",1 + Property: "FieldOfViewY", "FieldOfView", "A+",1 + Property: "OpticalCenterX", "Real", "A+",0 + Property: "OpticalCenterY", "Real", "A+",0 + Property: "BackgroundColor", "Color", "A+",0.63,0.63,0.63 + Property: "TurnTable", "Real", "A+",0 + Property: "DisplayTurnTableIcon", "bool", "",1 + Property: "Motion Blur Intensity", "Real", "A+",1 + Property: "UseMotionBlur", "bool", "",0 + Property: "UseRealTimeMotionBlur", "bool", "",1 + Property: "ResolutionMode", "enum", "",0 + Property: "ApertureMode", "enum", "",2 + Property: "GateFit", "enum", "",0 + Property: "FocalLength", "Real", "A+",21.3544940948486 + Property: "CameraFormat", "enum", "",0 + Property: "AspectW", "double", "",320 + Property: "AspectH", "double", "",200 + Property: "PixelAspectRatio", "double", "",1 + Property: "UseFrameColor", "bool", "",0 + Property: "FrameColor", "ColorRGB", "",0.3,0.3,0.3 + Property: "ShowName", "bool", "",1 + Property: "ShowGrid", "bool", "",1 + Property: "ShowOpticalCenter", "bool", "",0 + Property: "ShowAzimut", "bool", "",1 + Property: "ShowTimeCode", "bool", "",0 + Property: "NearPlane", "double", "",1.000000 + Property: "FarPlane", "double", "",30000.000000 + Property: "FilmWidth", "double", "",0.816 + Property: "FilmHeight", "double", "",0.612 + Property: "FilmAspectRatio", "double", "",1.33333333333333 + Property: "FilmSqueezeRatio", "double", "",1 + Property: "FilmFormatIndex", "enum", "",4 + Property: "ViewFrustum", "bool", "",1 + Property: "ViewFrustumNearFarPlane", "bool", "",0 + Property: "ViewFrustumBackPlaneMode", "enum", "",2 + Property: "BackPlaneDistance", "double", "",100 + Property: "BackPlaneDistanceMode", "enum", "",0 + Property: "ViewCameraToLookAt", "bool", "",1 + Property: "LockMode", "bool", "",0 + Property: "LockInterestNavigation", "bool", "",0 + Property: "FitImage", "bool", "",0 + Property: "Crop", "bool", "",0 + Property: "Center", "bool", "",1 + Property: "KeepRatio", "bool", "",1 + Property: "BackgroundMode", "enum", "",0 + Property: "BackgroundAlphaTreshold", "double", "",0.5 + Property: "ForegroundTransparent", "bool", "",1 + Property: "DisplaySafeArea", "bool", "",0 + Property: "SafeAreaDisplayStyle", "enum", "",1 + Property: "SafeAreaAspectRatio", "double", "",1.33333333333333 + Property: "Use2DMagnifierZoom", "bool", "",0 + Property: "2D Magnifier Zoom", "Real", "A+",100 + Property: "2D Magnifier X", "Real", "A+",50 + Property: "2D Magnifier Y", "Real", "A+",50 + Property: "CameraProjectionType", "enum", "",1 + Property: "UseRealTimeDOFAndAA", "bool", "",0 + Property: "UseDepthOfField", "bool", "",0 + Property: "FocusSource", "enum", "",0 + Property: "FocusAngle", "double", "",3.5 + Property: "FocusDistance", "double", "",200 + Property: "UseAntialiasing", "bool", "",0 + Property: "AntialiasingIntensity", "double", "",0.77777 + Property: "UseAccumulationBuffer", "bool", "",0 + Property: "FrameSamplingCount", "int", "",7 + } + MultiLayer: 0 + MultiTake: 0 + Hidden: "True" + Shading: Y + Culling: "CullingOff" + TypeFlags: "Camera" + GeometryVersion: 124 + Position: 0.000000,0.000000,4000.000000 + Up: 0,1,0 + LookAt: 0,0,0 + ShowInfoOnMoving: 1 + ShowAudio: 0 + AudioColor: 0,1,0 + CameraOrthoZoom: 1 + } + Model: "Model::Producer Back", "Camera" { + Version: 232 + Properties60: { + Property: "QuaternionInterpolate", "bool", "",0 + Property: "Visibility", "Visibility", "A+",1 + Property: "Lcl Translation", "Lcl Translation", "A+",0.000000000000000,0.000000000000000,-4000.000000000000000 + Property: "Lcl Rotation", "Lcl Rotation", "A+",0.000000000000000,0.000000000000000,0.000000000000000 + Property: "Lcl Scaling", "Lcl Scaling", "A+",1.000000000000000,1.000000000000000,1.000000000000000 + Property: "RotationOffset", "Vector3D", "",0,0,0 + Property: "RotationPivot", "Vector3D", "",0,0,0 + Property: "ScalingOffset", "Vector3D", "",0,0,0 + Property: "ScalingPivot", "Vector3D", "",0,0,0 + Property: "TranslationActive", "bool", "",0 + Property: "TranslationMin", "Vector3D", "",0,0,0 + Property: "TranslationMax", "Vector3D", "",0,0,0 + Property: "TranslationMinX", "bool", "",0 + Property: "TranslationMinY", "bool", "",0 + Property: "TranslationMinZ", "bool", "",0 + Property: "TranslationMaxX", "bool", "",0 + Property: "TranslationMaxY", "bool", "",0 + Property: "TranslationMaxZ", "bool", "",0 + Property: "RotationOrder", "enum", "",0 + Property: "RotationSpaceForLimitOnly", "bool", "",0 + Property: "AxisLen", "double", "",10 + Property: "PreRotation", "Vector3D", "",0,0,0 + Property: "PostRotation", "Vector3D", "",0,0,0 + Property: "RotationActive", "bool", "",0 + Property: "RotationMin", "Vector3D", "",0,0,0 + Property: "RotationMax", "Vector3D", "",0,0,0 + Property: "RotationMinX", "bool", "",0 + Property: "RotationMinY", "bool", "",0 + Property: "RotationMinZ", "bool", "",0 + Property: "RotationMaxX", "bool", "",0 + Property: "RotationMaxY", "bool", "",0 + Property: "RotationMaxZ", "bool", "",0 + Property: "RotationStiffnessX", "double", "",0 + Property: "RotationStiffnessY", "double", "",0 + Property: "RotationStiffnessZ", "double", "",0 + Property: "MinDampRangeX", "double", "",0 + Property: "MinDampRangeY", "double", "",0 + Property: "MinDampRangeZ", "double", "",0 + Property: "MaxDampRangeX", "double", "",0 + Property: "MaxDampRangeY", "double", "",0 + Property: "MaxDampRangeZ", "double", "",0 + Property: "MinDampStrengthX", "double", "",0 + Property: "MinDampStrengthY", "double", "",0 + Property: "MinDampStrengthZ", "double", "",0 + Property: "MaxDampStrengthX", "double", "",0 + Property: "MaxDampStrengthY", "double", "",0 + Property: "MaxDampStrengthZ", "double", "",0 + Property: "PreferedAngleX", "double", "",0 + Property: "PreferedAngleY", "double", "",0 + Property: "PreferedAngleZ", "double", "",0 + Property: "InheritType", "enum", "",0 + Property: "ScalingActive", "bool", "",0 + Property: "ScalingMin", "Vector3D", "",1,1,1 + Property: "ScalingMax", "Vector3D", "",1,1,1 + Property: "ScalingMinX", "bool", "",0 + Property: "ScalingMinY", "bool", "",0 + Property: "ScalingMinZ", "bool", "",0 + Property: "ScalingMaxX", "bool", "",0 + Property: "ScalingMaxY", "bool", "",0 + Property: "ScalingMaxZ", "bool", "",0 + Property: "GeometricTranslation", "Vector3D", "",0,0,0 + Property: "GeometricRotation", "Vector3D", "",0,0,0 + Property: "GeometricScaling", "Vector3D", "",1,1,1 + Property: "LookAtProperty", "object", "" + Property: "UpVectorProperty", "object", "" + Property: "Show", "bool", "",1 + Property: "NegativePercentShapeSupport", "bool", "",1 + Property: "DefaultAttributeIndex", "int", "",0 + Property: "Color", "Color", "A",0.8,0.8,0.8 + Property: "Roll", "Roll", "A+",0 + Property: "FieldOfView", "FieldOfView", "A+",40 + Property: "FieldOfViewX", "FieldOfView", "A+",1 + Property: "FieldOfViewY", "FieldOfView", "A+",1 + Property: "OpticalCenterX", "Real", "A+",0 + Property: "OpticalCenterY", "Real", "A+",0 + Property: "BackgroundColor", "Color", "A+",0.63,0.63,0.63 + Property: "TurnTable", "Real", "A+",0 + Property: "DisplayTurnTableIcon", "bool", "",1 + Property: "Motion Blur Intensity", "Real", "A+",1 + Property: "UseMotionBlur", "bool", "",0 + Property: "UseRealTimeMotionBlur", "bool", "",1 + Property: "ResolutionMode", "enum", "",0 + Property: "ApertureMode", "enum", "",2 + Property: "GateFit", "enum", "",0 + Property: "FocalLength", "Real", "A+",21.3544940948486 + Property: "CameraFormat", "enum", "",0 + Property: "AspectW", "double", "",320 + Property: "AspectH", "double", "",200 + Property: "PixelAspectRatio", "double", "",1 + Property: "UseFrameColor", "bool", "",0 + Property: "FrameColor", "ColorRGB", "",0.3,0.3,0.3 + Property: "ShowName", "bool", "",1 + Property: "ShowGrid", "bool", "",1 + Property: "ShowOpticalCenter", "bool", "",0 + Property: "ShowAzimut", "bool", "",1 + Property: "ShowTimeCode", "bool", "",0 + Property: "NearPlane", "double", "",1.000000 + Property: "FarPlane", "double", "",30000.000000 + Property: "FilmWidth", "double", "",0.816 + Property: "FilmHeight", "double", "",0.612 + Property: "FilmAspectRatio", "double", "",1.33333333333333 + Property: "FilmSqueezeRatio", "double", "",1 + Property: "FilmFormatIndex", "enum", "",4 + Property: "ViewFrustum", "bool", "",1 + Property: "ViewFrustumNearFarPlane", "bool", "",0 + Property: "ViewFrustumBackPlaneMode", "enum", "",2 + Property: "BackPlaneDistance", "double", "",100 + Property: "BackPlaneDistanceMode", "enum", "",0 + Property: "ViewCameraToLookAt", "bool", "",1 + Property: "LockMode", "bool", "",0 + Property: "LockInterestNavigation", "bool", "",0 + Property: "FitImage", "bool", "",0 + Property: "Crop", "bool", "",0 + Property: "Center", "bool", "",1 + Property: "KeepRatio", "bool", "",1 + Property: "BackgroundMode", "enum", "",0 + Property: "BackgroundAlphaTreshold", "double", "",0.5 + Property: "ForegroundTransparent", "bool", "",1 + Property: "DisplaySafeArea", "bool", "",0 + Property: "SafeAreaDisplayStyle", "enum", "",1 + Property: "SafeAreaAspectRatio", "double", "",1.33333333333333 + Property: "Use2DMagnifierZoom", "bool", "",0 + Property: "2D Magnifier Zoom", "Real", "A+",100 + Property: "2D Magnifier X", "Real", "A+",50 + Property: "2D Magnifier Y", "Real", "A+",50 + Property: "CameraProjectionType", "enum", "",1 + Property: "UseRealTimeDOFAndAA", "bool", "",0 + Property: "UseDepthOfField", "bool", "",0 + Property: "FocusSource", "enum", "",0 + Property: "FocusAngle", "double", "",3.5 + Property: "FocusDistance", "double", "",200 + Property: "UseAntialiasing", "bool", "",0 + Property: "AntialiasingIntensity", "double", "",0.77777 + Property: "UseAccumulationBuffer", "bool", "",0 + Property: "FrameSamplingCount", "int", "",7 + } + MultiLayer: 0 + MultiTake: 0 + Hidden: "True" + Shading: Y + Culling: "CullingOff" + TypeFlags: "Camera" + GeometryVersion: 124 + Position: 0.000000,0.000000,-4000.000000 + Up: 0,1,0 + LookAt: 0,0,0 + ShowInfoOnMoving: 1 + ShowAudio: 0 + AudioColor: 0,1,0 + CameraOrthoZoom: 1 + } + Model: "Model::Producer Right", "Camera" { + Version: 232 + Properties60: { + Property: "QuaternionInterpolate", "bool", "",0 + Property: "Visibility", "Visibility", "A+",1 + Property: "Lcl Translation", "Lcl Translation", "A+",4000.000000000000000,0.000000000000000,0.000000000000000 + Property: "Lcl Rotation", "Lcl Rotation", "A+",0.000000000000000,0.000000000000000,0.000000000000000 + Property: "Lcl Scaling", "Lcl Scaling", "A+",1.000000000000000,1.000000000000000,1.000000000000000 + Property: "RotationOffset", "Vector3D", "",0,0,0 + Property: "RotationPivot", "Vector3D", "",0,0,0 + Property: "ScalingOffset", "Vector3D", "",0,0,0 + Property: "ScalingPivot", "Vector3D", "",0,0,0 + Property: "TranslationActive", "bool", "",0 + Property: "TranslationMin", "Vector3D", "",0,0,0 + Property: "TranslationMax", "Vector3D", "",0,0,0 + Property: "TranslationMinX", "bool", "",0 + Property: "TranslationMinY", "bool", "",0 + Property: "TranslationMinZ", "bool", "",0 + Property: "TranslationMaxX", "bool", "",0 + Property: "TranslationMaxY", "bool", "",0 + Property: "TranslationMaxZ", "bool", "",0 + Property: "RotationOrder", "enum", "",0 + Property: "RotationSpaceForLimitOnly", "bool", "",0 + Property: "AxisLen", "double", "",10 + Property: "PreRotation", "Vector3D", "",0,0,0 + Property: "PostRotation", "Vector3D", "",0,0,0 + Property: "RotationActive", "bool", "",0 + Property: "RotationMin", "Vector3D", "",0,0,0 + Property: "RotationMax", "Vector3D", "",0,0,0 + Property: "RotationMinX", "bool", "",0 + Property: "RotationMinY", "bool", "",0 + Property: "RotationMinZ", "bool", "",0 + Property: "RotationMaxX", "bool", "",0 + Property: "RotationMaxY", "bool", "",0 + Property: "RotationMaxZ", "bool", "",0 + Property: "RotationStiffnessX", "double", "",0 + Property: "RotationStiffnessY", "double", "",0 + Property: "RotationStiffnessZ", "double", "",0 + Property: "MinDampRangeX", "double", "",0 + Property: "MinDampRangeY", "double", "",0 + Property: "MinDampRangeZ", "double", "",0 + Property: "MaxDampRangeX", "double", "",0 + Property: "MaxDampRangeY", "double", "",0 + Property: "MaxDampRangeZ", "double", "",0 + Property: "MinDampStrengthX", "double", "",0 + Property: "MinDampStrengthY", "double", "",0 + Property: "MinDampStrengthZ", "double", "",0 + Property: "MaxDampStrengthX", "double", "",0 + Property: "MaxDampStrengthY", "double", "",0 + Property: "MaxDampStrengthZ", "double", "",0 + Property: "PreferedAngleX", "double", "",0 + Property: "PreferedAngleY", "double", "",0 + Property: "PreferedAngleZ", "double", "",0 + Property: "InheritType", "enum", "",0 + Property: "ScalingActive", "bool", "",0 + Property: "ScalingMin", "Vector3D", "",1,1,1 + Property: "ScalingMax", "Vector3D", "",1,1,1 + Property: "ScalingMinX", "bool", "",0 + Property: "ScalingMinY", "bool", "",0 + Property: "ScalingMinZ", "bool", "",0 + Property: "ScalingMaxX", "bool", "",0 + Property: "ScalingMaxY", "bool", "",0 + Property: "ScalingMaxZ", "bool", "",0 + Property: "GeometricTranslation", "Vector3D", "",0,0,0 + Property: "GeometricRotation", "Vector3D", "",0,0,0 + Property: "GeometricScaling", "Vector3D", "",1,1,1 + Property: "LookAtProperty", "object", "" + Property: "UpVectorProperty", "object", "" + Property: "Show", "bool", "",1 + Property: "NegativePercentShapeSupport", "bool", "",1 + Property: "DefaultAttributeIndex", "int", "",0 + Property: "Color", "Color", "A",0.8,0.8,0.8 + Property: "Roll", "Roll", "A+",0 + Property: "FieldOfView", "FieldOfView", "A+",40 + Property: "FieldOfViewX", "FieldOfView", "A+",1 + Property: "FieldOfViewY", "FieldOfView", "A+",1 + Property: "OpticalCenterX", "Real", "A+",0 + Property: "OpticalCenterY", "Real", "A+",0 + Property: "BackgroundColor", "Color", "A+",0.63,0.63,0.63 + Property: "TurnTable", "Real", "A+",0 + Property: "DisplayTurnTableIcon", "bool", "",1 + Property: "Motion Blur Intensity", "Real", "A+",1 + Property: "UseMotionBlur", "bool", "",0 + Property: "UseRealTimeMotionBlur", "bool", "",1 + Property: "ResolutionMode", "enum", "",0 + Property: "ApertureMode", "enum", "",2 + Property: "GateFit", "enum", "",0 + Property: "FocalLength", "Real", "A+",21.3544940948486 + Property: "CameraFormat", "enum", "",0 + Property: "AspectW", "double", "",320 + Property: "AspectH", "double", "",200 + Property: "PixelAspectRatio", "double", "",1 + Property: "UseFrameColor", "bool", "",0 + Property: "FrameColor", "ColorRGB", "",0.3,0.3,0.3 + Property: "ShowName", "bool", "",1 + Property: "ShowGrid", "bool", "",1 + Property: "ShowOpticalCenter", "bool", "",0 + Property: "ShowAzimut", "bool", "",1 + Property: "ShowTimeCode", "bool", "",0 + Property: "NearPlane", "double", "",1.000000 + Property: "FarPlane", "double", "",30000.000000 + Property: "FilmWidth", "double", "",0.816 + Property: "FilmHeight", "double", "",0.612 + Property: "FilmAspectRatio", "double", "",1.33333333333333 + Property: "FilmSqueezeRatio", "double", "",1 + Property: "FilmFormatIndex", "enum", "",4 + Property: "ViewFrustum", "bool", "",1 + Property: "ViewFrustumNearFarPlane", "bool", "",0 + Property: "ViewFrustumBackPlaneMode", "enum", "",2 + Property: "BackPlaneDistance", "double", "",100 + Property: "BackPlaneDistanceMode", "enum", "",0 + Property: "ViewCameraToLookAt", "bool", "",1 + Property: "LockMode", "bool", "",0 + Property: "LockInterestNavigation", "bool", "",0 + Property: "FitImage", "bool", "",0 + Property: "Crop", "bool", "",0 + Property: "Center", "bool", "",1 + Property: "KeepRatio", "bool", "",1 + Property: "BackgroundMode", "enum", "",0 + Property: "BackgroundAlphaTreshold", "double", "",0.5 + Property: "ForegroundTransparent", "bool", "",1 + Property: "DisplaySafeArea", "bool", "",0 + Property: "SafeAreaDisplayStyle", "enum", "",1 + Property: "SafeAreaAspectRatio", "double", "",1.33333333333333 + Property: "Use2DMagnifierZoom", "bool", "",0 + Property: "2D Magnifier Zoom", "Real", "A+",100 + Property: "2D Magnifier X", "Real", "A+",50 + Property: "2D Magnifier Y", "Real", "A+",50 + Property: "CameraProjectionType", "enum", "",1 + Property: "UseRealTimeDOFAndAA", "bool", "",0 + Property: "UseDepthOfField", "bool", "",0 + Property: "FocusSource", "enum", "",0 + Property: "FocusAngle", "double", "",3.5 + Property: "FocusDistance", "double", "",200 + Property: "UseAntialiasing", "bool", "",0 + Property: "AntialiasingIntensity", "double", "",0.77777 + Property: "UseAccumulationBuffer", "bool", "",0 + Property: "FrameSamplingCount", "int", "",7 + } + MultiLayer: 0 + MultiTake: 0 + Hidden: "True" + Shading: Y + Culling: "CullingOff" + TypeFlags: "Camera" + GeometryVersion: 124 + Position: 4000.000000,0.000000,0.000000 + Up: 0,1,0 + LookAt: 0,0,0 + ShowInfoOnMoving: 1 + ShowAudio: 0 + AudioColor: 0,1,0 + CameraOrthoZoom: 1 + } + Model: "Model::Producer Left", "Camera" { + Version: 232 + Properties60: { + Property: "QuaternionInterpolate", "bool", "",0 + Property: "Visibility", "Visibility", "A+",1 + Property: "Lcl Translation", "Lcl Translation", "A+",-4000.000000000000000,0.000000000000000,0.000000000000000 + Property: "Lcl Rotation", "Lcl Rotation", "A+",0.000000000000000,0.000000000000000,0.000000000000000 + Property: "Lcl Scaling", "Lcl Scaling", "A+",1.000000000000000,1.000000000000000,1.000000000000000 + Property: "RotationOffset", "Vector3D", "",0,0,0 + Property: "RotationPivot", "Vector3D", "",0,0,0 + Property: "ScalingOffset", "Vector3D", "",0,0,0 + Property: "ScalingPivot", "Vector3D", "",0,0,0 + Property: "TranslationActive", "bool", "",0 + Property: "TranslationMin", "Vector3D", "",0,0,0 + Property: "TranslationMax", "Vector3D", "",0,0,0 + Property: "TranslationMinX", "bool", "",0 + Property: "TranslationMinY", "bool", "",0 + Property: "TranslationMinZ", "bool", "",0 + Property: "TranslationMaxX", "bool", "",0 + Property: "TranslationMaxY", "bool", "",0 + Property: "TranslationMaxZ", "bool", "",0 + Property: "RotationOrder", "enum", "",0 + Property: "RotationSpaceForLimitOnly", "bool", "",0 + Property: "AxisLen", "double", "",10 + Property: "PreRotation", "Vector3D", "",0,0,0 + Property: "PostRotation", "Vector3D", "",0,0,0 + Property: "RotationActive", "bool", "",0 + Property: "RotationMin", "Vector3D", "",0,0,0 + Property: "RotationMax", "Vector3D", "",0,0,0 + Property: "RotationMinX", "bool", "",0 + Property: "RotationMinY", "bool", "",0 + Property: "RotationMinZ", "bool", "",0 + Property: "RotationMaxX", "bool", "",0 + Property: "RotationMaxY", "bool", "",0 + Property: "RotationMaxZ", "bool", "",0 + Property: "RotationStiffnessX", "double", "",0 + Property: "RotationStiffnessY", "double", "",0 + Property: "RotationStiffnessZ", "double", "",0 + Property: "MinDampRangeX", "double", "",0 + Property: "MinDampRangeY", "double", "",0 + Property: "MinDampRangeZ", "double", "",0 + Property: "MaxDampRangeX", "double", "",0 + Property: "MaxDampRangeY", "double", "",0 + Property: "MaxDampRangeZ", "double", "",0 + Property: "MinDampStrengthX", "double", "",0 + Property: "MinDampStrengthY", "double", "",0 + Property: "MinDampStrengthZ", "double", "",0 + Property: "MaxDampStrengthX", "double", "",0 + Property: "MaxDampStrengthY", "double", "",0 + Property: "MaxDampStrengthZ", "double", "",0 + Property: "PreferedAngleX", "double", "",0 + Property: "PreferedAngleY", "double", "",0 + Property: "PreferedAngleZ", "double", "",0 + Property: "InheritType", "enum", "",0 + Property: "ScalingActive", "bool", "",0 + Property: "ScalingMin", "Vector3D", "",1,1,1 + Property: "ScalingMax", "Vector3D", "",1,1,1 + Property: "ScalingMinX", "bool", "",0 + Property: "ScalingMinY", "bool", "",0 + Property: "ScalingMinZ", "bool", "",0 + Property: "ScalingMaxX", "bool", "",0 + Property: "ScalingMaxY", "bool", "",0 + Property: "ScalingMaxZ", "bool", "",0 + Property: "GeometricTranslation", "Vector3D", "",0,0,0 + Property: "GeometricRotation", "Vector3D", "",0,0,0 + Property: "GeometricScaling", "Vector3D", "",1,1,1 + Property: "LookAtProperty", "object", "" + Property: "UpVectorProperty", "object", "" + Property: "Show", "bool", "",1 + Property: "NegativePercentShapeSupport", "bool", "",1 + Property: "DefaultAttributeIndex", "int", "",0 + Property: "Color", "Color", "A",0.8,0.8,0.8 + Property: "Roll", "Roll", "A+",0 + Property: "FieldOfView", "FieldOfView", "A+",40 + Property: "FieldOfViewX", "FieldOfView", "A+",1 + Property: "FieldOfViewY", "FieldOfView", "A+",1 + Property: "OpticalCenterX", "Real", "A+",0 + Property: "OpticalCenterY", "Real", "A+",0 + Property: "BackgroundColor", "Color", "A+",0.63,0.63,0.63 + Property: "TurnTable", "Real", "A+",0 + Property: "DisplayTurnTableIcon", "bool", "",1 + Property: "Motion Blur Intensity", "Real", "A+",1 + Property: "UseMotionBlur", "bool", "",0 + Property: "UseRealTimeMotionBlur", "bool", "",1 + Property: "ResolutionMode", "enum", "",0 + Property: "ApertureMode", "enum", "",2 + Property: "GateFit", "enum", "",0 + Property: "FocalLength", "Real", "A+",21.3544940948486 + Property: "CameraFormat", "enum", "",0 + Property: "AspectW", "double", "",320 + Property: "AspectH", "double", "",200 + Property: "PixelAspectRatio", "double", "",1 + Property: "UseFrameColor", "bool", "",0 + Property: "FrameColor", "ColorRGB", "",0.3,0.3,0.3 + Property: "ShowName", "bool", "",1 + Property: "ShowGrid", "bool", "",1 + Property: "ShowOpticalCenter", "bool", "",0 + Property: "ShowAzimut", "bool", "",1 + Property: "ShowTimeCode", "bool", "",0 + Property: "NearPlane", "double", "",1.000000 + Property: "FarPlane", "double", "",30000.000000 + Property: "FilmWidth", "double", "",0.816 + Property: "FilmHeight", "double", "",0.612 + Property: "FilmAspectRatio", "double", "",1.33333333333333 + Property: "FilmSqueezeRatio", "double", "",1 + Property: "FilmFormatIndex", "enum", "",4 + Property: "ViewFrustum", "bool", "",1 + Property: "ViewFrustumNearFarPlane", "bool", "",0 + Property: "ViewFrustumBackPlaneMode", "enum", "",2 + Property: "BackPlaneDistance", "double", "",100 + Property: "BackPlaneDistanceMode", "enum", "",0 + Property: "ViewCameraToLookAt", "bool", "",1 + Property: "LockMode", "bool", "",0 + Property: "LockInterestNavigation", "bool", "",0 + Property: "FitImage", "bool", "",0 + Property: "Crop", "bool", "",0 + Property: "Center", "bool", "",1 + Property: "KeepRatio", "bool", "",1 + Property: "BackgroundMode", "enum", "",0 + Property: "BackgroundAlphaTreshold", "double", "",0.5 + Property: "ForegroundTransparent", "bool", "",1 + Property: "DisplaySafeArea", "bool", "",0 + Property: "SafeAreaDisplayStyle", "enum", "",1 + Property: "SafeAreaAspectRatio", "double", "",1.33333333333333 + Property: "Use2DMagnifierZoom", "bool", "",0 + Property: "2D Magnifier Zoom", "Real", "A+",100 + Property: "2D Magnifier X", "Real", "A+",50 + Property: "2D Magnifier Y", "Real", "A+",50 + Property: "CameraProjectionType", "enum", "",1 + Property: "UseRealTimeDOFAndAA", "bool", "",0 + Property: "UseDepthOfField", "bool", "",0 + Property: "FocusSource", "enum", "",0 + Property: "FocusAngle", "double", "",3.5 + Property: "FocusDistance", "double", "",200 + Property: "UseAntialiasing", "bool", "",0 + Property: "AntialiasingIntensity", "double", "",0.77777 + Property: "UseAccumulationBuffer", "bool", "",0 + Property: "FrameSamplingCount", "int", "",7 + } + MultiLayer: 0 + MultiTake: 0 + Hidden: "True" + Shading: Y + Culling: "CullingOff" + TypeFlags: "Camera" + GeometryVersion: 124 + Position: -4000.000000,0.000000,0.000000 + Up: 0,1,0 + LookAt: 0,0,0 + ShowInfoOnMoving: 1 + ShowAudio: 0 + AudioColor: 0,1,0 + CameraOrthoZoom: 1 + } + Material: "Material::unnamed", "" { + Version: 102 + ShadingModel: "phong" + MultiLayer: 0 + Properties60: { + Property: "ShadingModel", "KString", "", "Phong" + Property: "MultiLayer", "bool", "",0 + Property: "EmissiveColor", "ColorRGB", "",0.8000,0.8000,0.8000 + Property: "EmissiveFactor", "double", "",0.0000 + Property: "AmbientColor", "ColorRGB", "",1.0000,1.0000,1.0000 + Property: "AmbientFactor", "double", "",1.0000 + Property: "DiffuseColor", "ColorRGB", "",0.8000,0.8000,0.8000 + Property: "DiffuseFactor", "double", "",0.8000 + Property: "Bump", "Vector3D", "",0,0,0 + Property: "TransparentColor", "ColorRGB", "",1,1,1 + Property: "TransparencyFactor", "double", "",0.0000 + Property: "SpecularColor", "ColorRGB", "",1.0000,1.0000,1.0000 + Property: "SpecularFactor", "double", "",0.5000 + Property: "ShininessExponent", "double", "",12.3 + Property: "ReflectionColor", "ColorRGB", "",0,0,0 + Property: "ReflectionFactor", "double", "",1 + Property: "Emissive", "ColorRGB", "",0,0,0 + Property: "Ambient", "ColorRGB", "",1.0,1.0,1.0 + Property: "Diffuse", "ColorRGB", "",0.8,0.8,0.8 + Property: "Specular", "ColorRGB", "",1.0,1.0,1.0 + Property: "Shininess", "double", "",12.3 + Property: "Opacity", "double", "",1.0 + Property: "Reflectivity", "double", "",0 + } + } + Pose: "Pose::BIND_POSES", "BindPose" { + Type: "BindPose" + Version: 100 + Properties60: { + } + NbPoseNodes: 1 + PoseNode: { + Node: "Model::GreenTriangle" + Matrix: 0.000000075497901,1.000000000000000,0.000003619990139,0.000000000000000,-1.000000000000000,0.000000075497901,0.000000000000273,0.000000000000000,0.000000000000000,-0.000003619990139,1.000000000000000,0.000000000000000,0.000000000000000,0.000000000000000,0.000000000000000,1.000000000000000 + } + } + GlobalSettings: { + Version: 1000 + Properties60: { + Property: "UpAxis", "int", "",1 + Property: "UpAxisSign", "int", "",1 + Property: "FrontAxis", "int", "",2 + Property: "FrontAxisSign", "int", "",1 + Property: "CoordAxis", "int", "",0 + Property: "CoordAxisSign", "int", "",1 + Property: "UnitScaleFactor", "double", "",1 + } + } +} + +; Object relations +;------------------------------------------------------------------ + +Relations: { + Model: "Model::GreenTriangle", "Mesh" { + } + Model: "Model::Producer Perspective", "Camera" { + } + Model: "Model::Producer Top", "Camera" { + } + Model: "Model::Producer Bottom", "Camera" { + } + Model: "Model::Producer Front", "Camera" { + } + Model: "Model::Producer Back", "Camera" { + } + Model: "Model::Producer Right", "Camera" { + } + Model: "Model::Producer Left", "Camera" { + } + Model: "Model::Camera Switcher", "CameraSwitcher" { + } + Material: "Material::unnamed", "" { + } +} + +; Object connections +;------------------------------------------------------------------ + +Connections: { + Connect: "OO", "Model::GreenTriangle", "Model::Scene" + Connect: "OO", "Material::unnamed", "Model::GreenTriangle" +} +;Takes and animation section +;---------------------------------------------------- + +Takes: { + Current: "" +} +;Version 5 settings +;------------------------------------------------------------------ + +Version5: { + AmbientRenderSettings: { + Version: 101 + AmbientLightColor: 0.0,0.0,0.0,0 + } + FogOptions: { + FogEnable: 0 + FogMode: 0 + FogDensity: 0.000 + FogStart: 5.000 + FogEnd: 25.000 + FogColor: 0.1,0.1,0.1,1 + } + Settings: { + FrameRate: "24" + TimeFormat: 1 + SnapOnFrames: 0 + ReferenceTimeIndex: -1 + TimeLineStartTime: 0 + TimeLineStopTime: 479181389250 + } + RendererSetting: { + DefaultCamera: "Producer Perspective" + DefaultViewingMode: 0 + } +} diff --git a/Assets/Behavior Designer Movement/Models/TriangleBot.fbx.meta b/Assets/Behavior Designer Movement/Models/TriangleBot.fbx.meta new file mode 100644 index 0000000..87bf713 --- /dev/null +++ b/Assets/Behavior Designer Movement/Models/TriangleBot.fbx.meta @@ -0,0 +1,65 @@ +fileFormatVersion: 2 +guid: 55e5ab7e66bd2eb49bc96935fe0bd04a +ModelImporter: + serializedVersion: 16 + fileIDToRecycleName: + 100000: //RootNode + 400000: //RootNode + 2300000: //RootNode + 3300000: //RootNode + 4300000: GreenTriangle + 9500000: //RootNode + materials: + importMaterials: 0 + materialName: 0 + materialSearch: 1 + animations: + legacyGenerateAnimations: 4 + bakeSimulation: 0 + optimizeGameObjects: 0 + motionNodeName: + animationCompression: 1 + animationRotationError: .5 + animationPositionError: .5 + animationScaleError: .5 + animationWrapMode: 0 + extraExposedTransformPaths: [] + clipAnimations: [] + isReadable: 1 + meshes: + lODScreenPercentages: [] + globalScale: 1 + meshCompression: 0 + addColliders: 0 + importBlendShapes: 1 + swapUVChannels: 0 + generateSecondaryUV: 0 + useFileUnits: 1 + optimizeMeshForGPU: 1 + weldVertices: 1 + secondaryUVAngleDistortion: 8 + secondaryUVAreaDistortion: 15.000001 + secondaryUVHardAngle: 88 + secondaryUVPackMargin: 4 + tangentSpace: + normalSmoothAngle: 60 + splitTangentsAcrossUV: 1 + normalImportMode: 0 + tangentImportMode: 1 + importAnimation: 1 + copyAvatar: 0 + humanDescription: + human: [] + skeleton: [] + armTwist: .5 + foreArmTwist: .5 + upperLegTwist: .5 + legTwist: .5 + armStretch: .0500000007 + legStretch: .0500000007 + feetSpacing: 0 + rootMotionBoneName: + lastHumanDescriptionAvatarSource: {instanceID: 0} + animationType: 0 + additionalBone: 0 + userData: diff --git a/Assets/Behavior Designer Movement/Scene.meta b/Assets/Behavior Designer Movement/Scene.meta new file mode 100644 index 0000000..3a27567 --- /dev/null +++ b/Assets/Behavior Designer Movement/Scene.meta @@ -0,0 +1,4 @@ +fileFormatVersion: 2 +guid: 108e27d4c31afa64a9c52023fe4f2e7a +DefaultImporter: + userData: diff --git a/Assets/Behavior Designer Movement/Scene/Scene.meta b/Assets/Behavior Designer Movement/Scene/Scene.meta new file mode 100644 index 0000000..478a7de --- /dev/null +++ b/Assets/Behavior Designer Movement/Scene/Scene.meta @@ -0,0 +1,5 @@ +fileFormatVersion: 2 +guid: 3e73d594649ce464cbe7b7908fd21f69 +folderAsset: yes +DefaultImporter: + userData: diff --git a/Assets/Behavior Designer Movement/Scene/Scene.unity b/Assets/Behavior Designer Movement/Scene/Scene.unity new file mode 100644 index 0000000..b2e6715 --- /dev/null +++ b/Assets/Behavior Designer Movement/Scene/Scene.unity @@ -0,0 +1,9877 @@ +%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.2, g: 0.2, b: 0.2, a: 1} + m_AmbientEquatorColor: {r: 0.2, g: 0.2, b: 0.2, a: 1} + m_AmbientGroundColor: {r: 0.2, g: 0.2, b: 0.2, 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 &4 +LightmapSettings: + m_ObjectHideFlags: 0 + serializedVersion: 11 + m_GIWorkflowMode: 1 + m_GISettings: + serializedVersion: 2 + m_BounceScale: 1 + m_IndirectOutputScale: 1 + m_AlbedoBoost: 1 + m_EnvironmentLightingMode: 0 + m_EnableBakedLightmaps: 1 + m_EnableRealtimeLightmaps: 0 + m_LightmapEditorSettings: + serializedVersion: 10 + m_Resolution: 1 + m_BakeResolution: 50 + m_AtlasSize: 1024 + m_AO: 0 + m_AOMaxDistance: 1 + m_CompAOExponent: 0 + m_CompAOExponentDirect: 0 + m_Padding: 2 + m_LightmapParameters: {fileID: 0} + m_LightmapsBakeMode: 1 + m_TextureCompression: 0 + m_FinalGather: 0 + m_FinalGatherFiltering: 1 + m_FinalGatherRayCount: 1024 + m_ReflectionCompression: 2 + m_MixedBakeMode: 1 + 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: 0 + 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: 0 +--- !u!196 &5 +NavMeshSettings: + serializedVersion: 2 + m_ObjectHideFlags: 0 + m_BuildSettings: + serializedVersion: 2 + agentTypeID: 0 + agentRadius: 1 + agentHeight: 2 + agentSlope: 45 + agentClimb: 0.4 + ledgeDropHeight: 0 + maxJumpAcrossDistance: 0 + minRegionArea: 2 + manualCellSize: 0 + cellSize: 0.3333333 + manualTileSize: 0 + tileSize: 256 + accuratePlacement: 0 + debug: + m_Flags: 0 + m_NavMeshData: {fileID: 23800000, guid: b8dd84a32b65e0f41a6c7f12ff72f7e6, type: 2} +--- !u!1 &346640 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 100000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 346641} + - component: {fileID: 346646} + - component: {fileID: 346645} + - component: {fileID: 346644} + m_Layer: 0 + m_Name: bot + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &346641 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 400000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 346640} + m_LocalRotation: {x: 6.123233e-17, y: 1, z: 6.123233e-17, w: 0.00000013315805} + m_LocalPosition: {x: -17.492996, y: 24.925999, z: -3.26445} + m_LocalScale: {x: 2, y: 2, z: 2} + m_Children: [] + m_Father: {fileID: 193687608} + m_RootOrder: 5 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!195 &346644 +NavMeshAgent: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 346640} + m_Enabled: 1 + m_AgentTypeID: 0 + m_Radius: 0.6369026 + m_Speed: 10 + m_Acceleration: 10 + avoidancePriority: 50 + m_AngularSpeed: 1200 + m_StoppingDistance: 0 + m_AutoTraverseOffMeshLink: 1 + m_AutoBraking: 1 + m_AutoRepath: 1 + m_Height: 0.5024553 + m_BaseOffset: 0.25122765 + m_WalkableMask: 4294967295 + m_ObstacleAvoidanceType: 4 +--- !u!23 &346645 +MeshRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 2300000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 346640} + m_Enabled: 1 + m_CastShadows: 1 + m_ReceiveShadows: 1 + m_DynamicOccludee: 1 + m_MotionVectors: 1 + m_LightProbeUsage: 0 + m_ReflectionProbeUsage: 1 + m_RenderingLayerMask: 1 + m_RendererPriority: 0 + m_Materials: + - {fileID: 2100000, guid: fecc96c64c214ce40835ac4c3c3099e8, type: 2} + 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: 3 + m_MinimumChartSize: 4 + m_AutoUVMaxDistance: 0.5 + m_AutoUVMaxAngle: 89 + m_LightmapParameters: {fileID: 0} + m_SortingLayerID: 0 + m_SortingLayer: 0 + m_SortingOrder: 0 +--- !u!33 &346646 +MeshFilter: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 3300000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 346640} + m_Mesh: {fileID: 4300000, guid: 55e5ab7e66bd2eb49bc96935fe0bd04a, type: 3} +--- !u!1 &34840226 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 100000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 34840227} + - component: {fileID: 34840232} + - component: {fileID: 34840231} + - component: {fileID: 34840230} + m_Layer: 0 + m_Name: bot + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &34840227 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 400000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 34840226} + m_LocalRotation: {x: 0, y: 1, z: 0, w: 0} + m_LocalPosition: {x: -17.492996, y: 24.925999, z: 12.23288} + m_LocalScale: {x: 2, y: 2, z: 2} + m_Children: [] + m_Father: {fileID: 193687608} + m_RootOrder: 25 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!195 &34840230 +NavMeshAgent: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 34840226} + m_Enabled: 1 + m_AgentTypeID: 0 + m_Radius: 0.6369026 + m_Speed: 10 + m_Acceleration: 10 + avoidancePriority: 50 + m_AngularSpeed: 1200 + m_StoppingDistance: 0 + m_AutoTraverseOffMeshLink: 1 + m_AutoBraking: 1 + m_AutoRepath: 1 + m_Height: 0.5024553 + m_BaseOffset: 0.25122765 + m_WalkableMask: 4294967295 + m_ObstacleAvoidanceType: 4 +--- !u!23 &34840231 +MeshRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 2300000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 34840226} + m_Enabled: 1 + m_CastShadows: 1 + m_ReceiveShadows: 1 + m_DynamicOccludee: 1 + m_MotionVectors: 1 + m_LightProbeUsage: 0 + m_ReflectionProbeUsage: 1 + m_RenderingLayerMask: 1 + m_RendererPriority: 0 + m_Materials: + - {fileID: 2100000, guid: fecc96c64c214ce40835ac4c3c3099e8, type: 2} + 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: 3 + m_MinimumChartSize: 4 + m_AutoUVMaxDistance: 0.5 + m_AutoUVMaxAngle: 89 + m_LightmapParameters: {fileID: 0} + m_SortingLayerID: 0 + m_SortingLayer: 0 + m_SortingOrder: 0 +--- !u!33 &34840232 +MeshFilter: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 3300000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 34840226} + m_Mesh: {fileID: 4300000, guid: 55e5ab7e66bd2eb49bc96935fe0bd04a, type: 3} +--- !u!1 &66600217 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 66600218} + m_Layer: 0 + m_Name: Follow + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &66600218 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 66600217} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: 7.118286, y: -24.249596, z: -157.60332} + m_LocalScale: {x: 1, y: 1, z: 1} + m_Children: + - {fileID: 1277433086} + - {fileID: 1833674481} + - {fileID: 1881403409} + - {fileID: 91496927} + - {fileID: 671785511} + - {fileID: 251429380} + - {fileID: 933433860} + - {fileID: 2046246934} + - {fileID: 1412844392} + - {fileID: 1903416402} + - {fileID: 158913357} + m_Father: {fileID: 0} + m_RootOrder: 3 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!1 &80592862 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 100000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 80592863} + - component: {fileID: 80592868} + - component: {fileID: 80592867} + - component: {fileID: 80592866} + m_Layer: 0 + m_Name: bot + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &80592863 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 400000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 80592862} + m_LocalRotation: {x: 6.123233e-17, y: 1, z: 6.123233e-17, w: 0.00000013315805} + m_LocalPosition: {x: -29.059395, y: 24.925999, z: -3.26445} + m_LocalScale: {x: 2, y: 2, z: 2} + m_Children: [] + m_Father: {fileID: 193687608} + m_RootOrder: 28 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!195 &80592866 +NavMeshAgent: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 80592862} + m_Enabled: 1 + m_AgentTypeID: 0 + m_Radius: 0.6369026 + m_Speed: 10 + m_Acceleration: 10 + avoidancePriority: 50 + m_AngularSpeed: 1200 + m_StoppingDistance: 0 + m_AutoTraverseOffMeshLink: 1 + m_AutoBraking: 1 + m_AutoRepath: 1 + m_Height: 0.5024553 + m_BaseOffset: 0.25122765 + m_WalkableMask: 4294967295 + m_ObstacleAvoidanceType: 4 +--- !u!23 &80592867 +MeshRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 2300000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 80592862} + m_Enabled: 1 + m_CastShadows: 1 + m_ReceiveShadows: 1 + m_DynamicOccludee: 1 + m_MotionVectors: 1 + m_LightProbeUsage: 0 + m_ReflectionProbeUsage: 1 + m_RenderingLayerMask: 1 + m_RendererPriority: 0 + m_Materials: + - {fileID: 2100000, guid: fecc96c64c214ce40835ac4c3c3099e8, type: 2} + 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: 3 + m_MinimumChartSize: 4 + m_AutoUVMaxDistance: 0.5 + m_AutoUVMaxAngle: 89 + m_LightmapParameters: {fileID: 0} + m_SortingLayerID: 0 + m_SortingLayer: 0 + m_SortingOrder: 0 +--- !u!33 &80592868 +MeshFilter: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 3300000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 80592862} + m_Mesh: {fileID: 4300000, guid: 55e5ab7e66bd2eb49bc96935fe0bd04a, type: 3} +--- !u!1 &86219747 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 86219748} + - component: {fileID: 86219749} + - component: {fileID: 86219750} + m_Layer: 0 + m_Name: 4 + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &86219748 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 86219747} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: -10, y: 1, z: -5} + m_LocalScale: {x: 1, y: 1, z: 1} + m_Children: [] + m_Father: {fileID: 1867949263} + m_RootOrder: 6 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!33 &86219749 +MeshFilter: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 86219747} + m_Mesh: {fileID: 10207, guid: 0000000000000000e000000000000000, type: 0} +--- !u!23 &86219750 +MeshRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 86219747} + m_Enabled: 1 + m_CastShadows: 1 + m_ReceiveShadows: 1 + m_DynamicOccludee: 1 + m_MotionVectors: 1 + m_LightProbeUsage: 0 + m_ReflectionProbeUsage: 1 + m_RenderingLayerMask: 1 + m_RendererPriority: 0 + m_Materials: + - {fileID: 10302, 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: 3 + m_MinimumChartSize: 4 + m_AutoUVMaxDistance: 0.5 + m_AutoUVMaxAngle: 89 + m_LightmapParameters: {fileID: 0} + m_SortingLayerID: 0 + m_SortingLayer: 0 + m_SortingOrder: 0 +--- !u!1 &91496926 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 100000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 91496927} + - component: {fileID: 91496932} + - component: {fileID: 91496931} + - component: {fileID: 91496930} + m_Layer: 0 + m_Name: bot + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &91496927 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 400000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 91496926} + m_LocalRotation: {x: 0, y: 1, z: 0, w: 0} + m_LocalPosition: {x: -17.492996, y: 24.925999, z: -15.206207} + m_LocalScale: {x: 2, y: 2, z: 2} + m_Children: [] + m_Father: {fileID: 66600218} + m_RootOrder: 3 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!195 &91496930 +NavMeshAgent: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 91496926} + m_Enabled: 1 + m_AgentTypeID: 0 + m_Radius: 0.6369026 + m_Speed: 15 + m_Acceleration: 15 + avoidancePriority: 50 + m_AngularSpeed: 1200 + m_StoppingDistance: 0 + m_AutoTraverseOffMeshLink: 1 + m_AutoBraking: 1 + m_AutoRepath: 1 + m_Height: 0.5024553 + m_BaseOffset: 0.25122765 + m_WalkableMask: 4294967295 + m_ObstacleAvoidanceType: 4 +--- !u!23 &91496931 +MeshRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 2300000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 91496926} + m_Enabled: 1 + m_CastShadows: 1 + m_ReceiveShadows: 1 + m_DynamicOccludee: 1 + m_MotionVectors: 1 + m_LightProbeUsage: 0 + m_ReflectionProbeUsage: 1 + m_RenderingLayerMask: 1 + m_RendererPriority: 0 + m_Materials: + - {fileID: 2100000, guid: fecc96c64c214ce40835ac4c3c3099e8, type: 2} + 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: 3 + m_MinimumChartSize: 4 + m_AutoUVMaxDistance: 0.5 + m_AutoUVMaxAngle: 89 + m_LightmapParameters: {fileID: 0} + m_SortingLayerID: 0 + m_SortingLayer: 0 + m_SortingOrder: 0 +--- !u!33 &91496932 +MeshFilter: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 3300000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 91496926} + m_Mesh: {fileID: 4300000, guid: 55e5ab7e66bd2eb49bc96935fe0bd04a, type: 3} +--- !u!1 &95806605 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 100000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 95806606} + - component: {fileID: 95806611} + - component: {fileID: 95806610} + - component: {fileID: 95806609} + - component: {fileID: 95806608} + - component: {fileID: 95806612} + - component: {fileID: 95806607} + - component: {fileID: 95806613} + - component: {fileID: 95806614} + - component: {fileID: 95806615} + - component: {fileID: 95806616} + - component: {fileID: 95806625} + - component: {fileID: 95806617} + - component: {fileID: 95806618} + - component: {fileID: 95806619} + - component: {fileID: 95806620} + - component: {fileID: 95806624} + - component: {fileID: 95806621} + - component: {fileID: 95806622} + - component: {fileID: 95806623} + m_Layer: 2 + m_Name: bot + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &95806606 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 400000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 95806605} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: -5, y: 1, z: -127.172516} + m_LocalScale: {x: 2, y: 2, z: 2} + m_Children: [] + m_Father: {fileID: 0} + m_RootOrder: 0 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!114 &95806607 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 95806605} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 8d7b55c7ecdb49a4a89fa5e6f9022861, type: 3} + m_Name: + m_EditorClassIdentifier: + startWhenEnabled: 0 + asynchronousLoad: 0 + pauseWhenDisabled: 0 + restartWhenComplete: 0 + logTaskChanges: 0 + group: 1 + resetValuesOnRestart: 0 + externalBehavior: {fileID: 0} + mBehaviorSource: + behaviorName: Rotate Towards + behaviorDescription: + mTaskData: + types: + - BehaviorDesigner.Runtime.Tasks.EntryTask + - BehaviorDesigner.Runtime.Tasks.Movement.RotateTowards + parentIndex: ffffffff00000000 + startIndex: 000000000a000000 + variableStartIndex: + JSONSerialization: + fieldSerializationData: + typeName: [] + fieldNameHash: 7d6ed74f587d82e1cda3fdf0ab643ccee0f0d2677230fc9344a34c197c55199df179fb1af835a4a97d6ed74f587d82e1cda3fdf0ab643ccee0f0d2677230fc9344a34c197c55199df179fb1af835a4a9c2ca2006a0c1ff0e1aa3b0df4d525fabc307e320fcb18e6876933f39a942ee041ff8717a33a0a912ad815ae3e03009af3044fb2bb87e514832600219650fb1e45bd3c70da3f2afa11dd4607250830f3e652573cb + startIndex: 000000000100000002000000030000000400000005000000060000000700000008000000090000000a0000000b0000000c0000000d0000000e0000000f0000001000000011000000120000001300000014000000150000001500000016000000170000001800000018000000190000001a0000001b0000001b0000001c0000001d0000001e0000001e0000001f0000002000000021000000210000002200000023000000 + dataPosition: 0000000004000000090000000a0000000b00000013000000130000001400000015000000190000001d000000210000002f000000300000003100000039000000390000003a0000003b0000003f000000430000004400000068000000680000006c000000900000009000000094000000b7000000b7000000b8000000e1000000e1000000e50000000b0100000b010000 + unityObjects: + - {fileID: 157415760} + byteData: 00000000456e747279010000000000000000000000000000000000000001000000526f7461746520546f77617264730100000020c00000dc4200000000000000000000004265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f61740000003f4265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f61740000a0404265686176696f7244657369676e65722e52756e74696d652e536861726564426f6f6c004265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a656374000000004265686176696f7244657369676e65722e52756e74696d652e536861726564566563746f7233000000000000000000000000 + byteDataArray: 00000000456e747279010000000000000000000000000000000000000001000000526f7461746520546f77617264730100000020c00000dc4200000000000000000000004265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f61740000003f4265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f61740000a0404265686176696f7244657369676e65722e52756e74696d652e536861726564426f6f6c004265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a656374000000004265686176696f7244657369676e65722e52756e74696d652e536861726564566563746f7233000000000000000000000000 + Version: 1.5.10 + gizmoViewMode: 2 + showBehaviorDesignerGizmo: 1 + unitTestResult: {fileID: 0} +--- !u!65 &95806608 +BoxCollider: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 95806605} + m_Material: {fileID: 0} + m_IsTrigger: 0 + m_Enabled: 1 + serializedVersion: 2 + m_Size: {x: 1, y: 1.000002, z: 1.000001} + m_Center: {x: 0, y: 0, z: 0.1684275} +--- !u!195 &95806609 +NavMeshAgent: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 95806605} + m_Enabled: 1 + m_AgentTypeID: 0 + m_Radius: 0.6369026 + m_Speed: 15 + m_Acceleration: 15 + avoidancePriority: 50 + m_AngularSpeed: 1500 + m_StoppingDistance: 0.5 + m_AutoTraverseOffMeshLink: 1 + m_AutoBraking: 1 + m_AutoRepath: 1 + m_Height: 0.5024553 + m_BaseOffset: 0.25122765 + m_WalkableMask: 4294967295 + m_ObstacleAvoidanceType: 4 +--- !u!23 &95806610 +MeshRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 2300000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 95806605} + m_Enabled: 1 + m_CastShadows: 1 + m_ReceiveShadows: 1 + m_DynamicOccludee: 1 + m_MotionVectors: 1 + m_LightProbeUsage: 0 + m_ReflectionProbeUsage: 1 + m_RenderingLayerMask: 1 + m_RendererPriority: 0 + m_Materials: + - {fileID: 2100000, guid: fecc96c64c214ce40835ac4c3c3099e8, type: 2} + 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: 3 + m_MinimumChartSize: 4 + m_AutoUVMaxDistance: 0.5 + m_AutoUVMaxAngle: 89 + m_LightmapParameters: {fileID: 0} + m_SortingLayerID: 0 + m_SortingLayer: 0 + m_SortingOrder: 0 +--- !u!33 &95806611 +MeshFilter: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 3300000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 95806605} + m_Mesh: {fileID: 4300000, guid: 55e5ab7e66bd2eb49bc96935fe0bd04a, type: 3} +--- !u!114 &95806612 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 95806605} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 8d7b55c7ecdb49a4a89fa5e6f9022861, type: 3} + m_Name: + m_EditorClassIdentifier: + startWhenEnabled: 0 + asynchronousLoad: 0 + pauseWhenDisabled: 0 + restartWhenComplete: 0 + logTaskChanges: 0 + group: 0 + resetValuesOnRestart: 0 + externalBehavior: {fileID: 0} + mBehaviorSource: + behaviorName: Move Towards + behaviorDescription: + mTaskData: + types: + - BehaviorDesigner.Runtime.Tasks.EntryTask + - BehaviorDesigner.Runtime.Tasks.Movement.MoveTowards + parentIndex: ffffffff00000000 + startIndex: 000000000a000000 + variableStartIndex: + JSONSerialization: + fieldSerializationData: + typeName: [] + fieldNameHash: 7d6ed74f587d82e1cda3fdf0ab643ccee0f0d2677230fc9344a34c197c55199df179fb1af835a4a97d6ed74f587d82e1cda3fdf0ab643ccee0f0d2677230fc9344a34c197c55199df179fb1af835a4a91b2296b99503478ac8b2f5553e6879cb3ee8c3dcb8c974adeb782379612ea7ee10e3ace68ac45db7bd730c830d87fefffcb18e6876933f39a942ee041ff8717ab87e514832600219650fb1e45bd3c70d3219e840acfa9811dfa947ddf44bab6a + startIndex: 000000000100000002000000030000000400000005000000060000000700000008000000090000000a0000000b0000000c0000000d0000000e0000000f0000001000000011000000120000001300000014000000140000001500000016000000170000001700000018000000190000001a0000001a0000001b0000001c0000001d0000001d0000001e0000001f0000002000000020000000210000002200000023000000230000002400000025000000 + dataPosition: 0000000004000000090000000a0000000b00000013000000130000001400000015000000190000001d000000210000002d0000002e0000002f000000370000003700000038000000390000003d000000410000006500000065000000690000008d0000008d00000091000000b4000000b4000000b5000000d9000000d9000000dd00000006010000060100000a0100003001000030010000 + unityObjects: + - {fileID: 157415760} + byteData: 00000000456e7472790100000000000000000000000000000000000000010000004d6f766520546f77617264730100000000400000dc42000000000000000000004265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f6174000020414265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f61740000003f4265686176696f7244657369676e65722e52756e74696d652e536861726564426f6f6c014265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f61740000a0404265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a656374000000004265686176696f7244657369676e65722e52756e74696d652e536861726564566563746f7233000000000000000000000000 + byteDataArray: 00000000456e7472790100000000000000000000000000000000000000010000004d6f766520546f77617264730100000000400000dc42000000000000000000004265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f6174000020414265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f61740000003f4265686176696f7244657369676e65722e52756e74696d652e536861726564426f6f6c014265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f61740000a0404265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a656374000000004265686176696f7244657369676e65722e52756e74696d652e536861726564566563746f7233000000000000000000000000 + Version: 1.5.10 + gizmoViewMode: 2 + showBehaviorDesignerGizmo: 1 + unitTestResult: {fileID: 0} +--- !u!114 &95806613 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 95806605} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 8d7b55c7ecdb49a4a89fa5e6f9022861, type: 3} + m_Name: + m_EditorClassIdentifier: + startWhenEnabled: 0 + asynchronousLoad: 0 + pauseWhenDisabled: 0 + restartWhenComplete: 0 + logTaskChanges: 0 + group: 2 + resetValuesOnRestart: 0 + externalBehavior: {fileID: 0} + mBehaviorSource: + behaviorName: Seek + behaviorDescription: + mTaskData: + types: + - BehaviorDesigner.Runtime.Tasks.EntryTask + - BehaviorDesigner.Runtime.Tasks.Movement.Seek + parentIndex: ffffffff00000000 + startIndex: 000000000a000000 + variableStartIndex: + JSONSerialization: + fieldSerializationData: + typeName: [] + fieldNameHash: 7d6ed74f587d82e1cda3fdf0ab643ccee0f0d2677230fc9344a34c197c55199df179fb1af835a4a97d6ed74f587d82e1cda3fdf0ab643ccee0f0d2677230fc9344a34c197c55199df179fb1af835a4a9b87e514832600219650fb1e45bd3c70d3219e840acfa9811dfa947ddf44bab6a1b2296b99503478ac8b2f5553e6879cb1959e99b933a9a6cc6e948383c9fccad3ee8c3dcb8c974adeb782379612ea7ee3d49dd0fb72a8ee0ead93cac3aed2e29c901a8ce43e3589f7692076bc6a5f9e7 + startIndex: 000000000100000002000000030000000400000005000000060000000700000008000000090000000a0000000b0000000c0000000d0000000e0000000f0000001000000011000000120000001300000014000000140000001500000016000000170000001700000018000000190000001a0000001a0000001b0000001c0000001d0000001d0000001e0000001f000000200000002000000021000000220000002300000023000000240000002500000026000000260000002700000028000000 + dataPosition: 0000000004000000090000000a0000000b00000013000000130000001400000015000000190000001d000000210000002500000026000000270000002f0000002f000000300000003100000035000000390000006200000062000000660000008c0000008c00000098000000bc000000bc000000c0000000e4000000e4000000e80000000c0100000c010000100100003301000033010000340100005701000057010000 + unityObjects: + - {fileID: 157415760} + byteData: 00000000456e7472790100000000000000000000000000000000000000010000005365656b0100000000000000dc42000000000000000000004265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a656374000000004265686176696f7244657369676e65722e52756e74696d652e536861726564566563746f72330000000000000000000000004265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f6174000020414265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f6174000096444265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f6174cdcc4c3e4265686176696f7244657369676e65722e52756e74696d652e536861726564426f6f6c014265686176696f7244657369676e65722e52756e74696d652e536861726564426f6f6c01 + byteDataArray: 00000000456e7472790100000000000000000000000000000000000000010000005365656b0100000000000000dc42000000000000000000004265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a656374000000004265686176696f7244657369676e65722e52756e74696d652e536861726564566563746f72330000000000000000000000004265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f6174000020414265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f6174000096444265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f6174cdcc4c3e4265686176696f7244657369676e65722e52756e74696d652e536861726564426f6f6c014265686176696f7244657369676e65722e52756e74696d652e536861726564426f6f6c01 + Version: 1.5.10 + gizmoViewMode: 2 + showBehaviorDesignerGizmo: 1 + unitTestResult: {fileID: 0} +--- !u!114 &95806614 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 95806605} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 8d7b55c7ecdb49a4a89fa5e6f9022861, type: 3} + m_Name: + m_EditorClassIdentifier: + startWhenEnabled: 0 + asynchronousLoad: 0 + pauseWhenDisabled: 0 + restartWhenComplete: 0 + logTaskChanges: 0 + group: 3 + resetValuesOnRestart: 0 + externalBehavior: {fileID: 0} + mBehaviorSource: + behaviorName: Flee + behaviorDescription: + mTaskData: + types: + - BehaviorDesigner.Runtime.Tasks.EntryTask + - BehaviorDesigner.Runtime.Tasks.Movement.Flee + parentIndex: ffffffff00000000 + startIndex: 000000000a000000 + variableStartIndex: + JSONSerialization: + fieldSerializationData: + typeName: [] + fieldNameHash: 7d6ed74f587d82e1cda3fdf0ab643ccee0f0d2677230fc9344a34c197c55199df179fb1af835a4a97d6ed74f587d82e1cda3fdf0ab643ccee0f0d2677230fc9344a34c197c55199df179fb1af835a4a91e64459c9845f66ccbf4a43841aa28aedff9e47e59db954f8c8a441b0240c890b87e514832600219650fb1e45bd3c70d1b2296b99503478ac8b2f5553e6879cb1959e99b933a9a6cc6e948383c9fccad3ee8c3dcb8c974adeb782379612ea7ee3d49dd0fb72a8ee0ead93cac3aed2e29c901a8ce43e3589f7692076bc6a5f9e7 + startIndex: 000000000100000002000000030000000400000005000000060000000700000008000000090000000a0000000b0000000c0000000d0000000e0000000f0000001000000011000000120000001300000014000000140000001500000016000000170000001700000018000000190000001a0000001a0000001b0000001c0000001d0000001d0000001e0000001f00000020000000200000002100000022000000230000002300000024000000250000002600000026000000270000002800000029000000290000002a0000002b000000 + dataPosition: 0000000004000000090000000a0000000b00000013000000130000001400000015000000190000001d000000210000002500000026000000270000002f0000002f000000300000003100000035000000390000005d0000005d00000061000000850000008500000089000000b2000000b2000000b6000000da000000da000000de0000000201000002010000060100002a0100002a0100002e0100005101000051010000520100007501000075010000 + unityObjects: + - {fileID: 157415760} + byteData: 00000000456e747279010000000000000000000000000000000000000001000000466c65650100000000bf0000da42000000000000000000004265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f61740000c8414265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f61740000a0414265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a656374000000004265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f6174000020414265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f6174000096444265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f6174cdcc4c3e4265686176696f7244657369676e65722e52756e74696d652e536861726564426f6f6c014265686176696f7244657369676e65722e52756e74696d652e536861726564426f6f6c01 + byteDataArray: 00000000456e747279010000000000000000000000000000000000000001000000466c65650100000000bf0000da42000000000000000000004265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f61740000c8414265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f61740000a0414265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a656374000000004265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f6174000020414265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f6174000096444265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f6174cdcc4c3e4265686176696f7244657369676e65722e52756e74696d652e536861726564426f6f6c014265686176696f7244657369676e65722e52756e74696d652e536861726564426f6f6c01 + Version: 1.5.10 + gizmoViewMode: 2 + showBehaviorDesignerGizmo: 1 + unitTestResult: {fileID: 0} +--- !u!114 &95806615 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 95806605} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 8d7b55c7ecdb49a4a89fa5e6f9022861, type: 3} + m_Name: + m_EditorClassIdentifier: + startWhenEnabled: 0 + asynchronousLoad: 0 + pauseWhenDisabled: 0 + restartWhenComplete: 0 + logTaskChanges: 0 + group: 4 + resetValuesOnRestart: 0 + externalBehavior: {fileID: 0} + mBehaviorSource: + behaviorName: Pursue + behaviorDescription: + mTaskData: + types: + - BehaviorDesigner.Runtime.Tasks.EntryTask + - BehaviorDesigner.Runtime.Tasks.Movement.Pursue + parentIndex: ffffffff00000000 + startIndex: 000000000a000000 + variableStartIndex: + JSONSerialization: + fieldSerializationData: + typeName: [] + fieldNameHash: 7d6ed74f587d82e1cda3fdf0ab643ccee0f0d2677230fc9344a34c197c55199df179fb1af835a4a97d6ed74f587d82e1cda3fdf0ab643ccee0f0d2677230fc9344a34c197c55199df179fb1af835a4a94187bdb8bb686e89ee171d5564cda0cac3271f463d09d01670b87ee2e66d0258b87e514832600219650fb1e45bd3c70d1b2296b99503478ac8b2f5553e6879cb1959e99b933a9a6cc6e948383c9fccad3ee8c3dcb8c974adeb782379612ea7ee3d49dd0fb72a8ee0ead93cac3aed2e29c901a8ce43e3589f7692076bc6a5f9e7 + startIndex: 000000000100000002000000030000000400000005000000060000000700000008000000090000000a0000000b0000000c0000000d0000000e0000000f0000001000000011000000120000001300000014000000140000001500000016000000170000001700000018000000190000001a0000001a0000001b0000001c0000001d0000001d0000001e0000001f00000020000000200000002100000022000000230000002300000024000000250000002600000026000000270000002800000029000000290000002a0000002b000000 + dataPosition: 0000000004000000090000000a0000000b00000013000000130000001400000015000000190000001d0000002100000027000000280000002900000031000000310000003200000033000000370000003b0000005f0000005f0000006300000087000000870000008b000000b4000000b4000000b8000000dc000000dc000000e00000000401000004010000080100002c0100002c010000300100005301000053010000540100007701000077010000 + unityObjects: + - {fileID: 157415760} + byteData: 00000000456e7472790100000000000000000000000000000000000000010000005075727375650100000000000000dc42000000000000000000004265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f61740000f0414265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f617400000c424265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a656374000000004265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f6174000020414265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f6174000096444265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f61740000003f4265686176696f7244657369676e65722e52756e74696d652e536861726564426f6f6c014265686176696f7244657369676e65722e52756e74696d652e536861726564426f6f6c01 + byteDataArray: 00000000456e7472790100000000000000000000000000000000000000010000005075727375650100000000000000dc42000000000000000000004265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f61740000f0414265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f617400000c424265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a656374000000004265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f6174000020414265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f6174000096444265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f61740000003f4265686176696f7244657369676e65722e52756e74696d652e536861726564426f6f6c014265686176696f7244657369676e65722e52756e74696d652e536861726564426f6f6c01 + Version: 1.5.10 + gizmoViewMode: 2 + showBehaviorDesignerGizmo: 1 + unitTestResult: {fileID: 0} +--- !u!114 &95806616 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 95806605} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 8d7b55c7ecdb49a4a89fa5e6f9022861, type: 3} + m_Name: + m_EditorClassIdentifier: + startWhenEnabled: 0 + asynchronousLoad: 0 + pauseWhenDisabled: 0 + restartWhenComplete: 0 + logTaskChanges: 0 + group: 5 + resetValuesOnRestart: 0 + externalBehavior: {fileID: 0} + mBehaviorSource: + behaviorName: Evade + behaviorDescription: + mTaskData: + types: + - BehaviorDesigner.Runtime.Tasks.EntryTask + - BehaviorDesigner.Runtime.Tasks.Movement.Evade + parentIndex: ffffffff00000000 + startIndex: 000000000a000000 + variableStartIndex: + JSONSerialization: + fieldSerializationData: + typeName: [] + fieldNameHash: 7d6ed74f587d82e1cda3fdf0ab643ccee0f0d2677230fc9344a34c197c55199df179fb1af835a4a97d6ed74f587d82e1cda3fdf0ab643ccee0f0d2677230fc9344a34c197c55199df179fb1af835a4a948247affc2052bd0f5b4d99b6b6a5d11dff9e47e59db954f8c8a441b0240c8904187bdb8bb686e89ee171d5564cda0cac3271f463d09d01670b87ee2e66d0258b87e514832600219650fb1e45bd3c70d1b2296b99503478ac8b2f5553e6879cb1959e99b933a9a6cc6e948383c9fccad3ee8c3dcb8c974adeb782379612ea7ee3d49dd0fb72a8ee0ead93cac3aed2e29c901a8ce43e3589f7692076bc6a5f9e7 + startIndex: 000000000100000002000000030000000400000005000000060000000700000008000000090000000a0000000b0000000c0000000d0000000e0000000f0000001000000011000000120000001300000014000000140000001500000016000000170000001700000018000000190000001a0000001a0000001b0000001c0000001d0000001d0000001e0000001f00000020000000200000002100000022000000230000002300000024000000250000002600000026000000270000002800000029000000290000002a0000002b0000002c0000002c0000002d0000002e0000002f0000002f0000003000000031000000 + dataPosition: 0000000004000000090000000a0000000b00000013000000130000001400000015000000190000001d0000002100000026000000270000002800000030000000300000003100000032000000360000003a0000005e0000005e0000006200000086000000860000008a000000ae000000ae000000b2000000d6000000d6000000da0000000301000003010000070100002b0100002b0100002f0100005301000053010000570100007b0100007b0100007f010000a2010000a2010000a3010000c6010000c6010000 + unityObjects: + - {fileID: 157415760} + byteData: 00000000456e74727901000000000000000000000000000000000000000100000045766164650100000000000000dc42000000000000000000004265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f61740000c8414265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f61740000a0404265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f61740000a0414265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f61740000f0414265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a656374000000004265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f6174000020414265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f6174000096444265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f6174cdcc4c3e4265686176696f7244657369676e65722e52756e74696d652e536861726564426f6f6c014265686176696f7244657369676e65722e52756e74696d652e536861726564426f6f6c01 + byteDataArray: 00000000456e74727901000000000000000000000000000000000000000100000045766164650100000000000000dc42000000000000000000004265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f61740000c8414265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f61740000a0404265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f61740000a0414265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f61740000f0414265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a656374000000004265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f6174000020414265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f6174000096444265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f6174cdcc4c3e4265686176696f7244657369676e65722e52756e74696d652e536861726564426f6f6c014265686176696f7244657369676e65722e52756e74696d652e536861726564426f6f6c01 + Version: 1.5.10 + gizmoViewMode: 2 + showBehaviorDesignerGizmo: 1 + unitTestResult: {fileID: 0} +--- !u!114 &95806617 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 95806605} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 8d7b55c7ecdb49a4a89fa5e6f9022861, type: 3} + m_Name: + m_EditorClassIdentifier: + startWhenEnabled: 0 + asynchronousLoad: 0 + pauseWhenDisabled: 0 + restartWhenComplete: 0 + logTaskChanges: 0 + group: 7 + resetValuesOnRestart: 0 + externalBehavior: {fileID: 0} + mBehaviorSource: + behaviorName: Patrol + behaviorDescription: + mTaskData: + types: + - BehaviorDesigner.Runtime.Tasks.EntryTask + - BehaviorDesigner.Runtime.Tasks.Movement.Patrol + parentIndex: ffffffff00000000 + startIndex: 000000000a000000 + variableStartIndex: + JSONSerialization: + fieldSerializationData: + typeName: [] + fieldNameHash: 7d6ed74f587d82e1cda3fdf0ab643ccee0f0d2677230fc9344a34c197c55199df179fb1af835a4a97d6ed74f587d82e1cda3fdf0ab643ccee0f0d2677230fc9344a34c197c55199df179fb1af835a4a91be9514b95ca021cc879b1e7188da3649e1a281e18fcd8ee4bab87bac1600b30e0443ff15a26f0c18dd59e8de26bdfa5f5e497a98340223b2d90a056cdd9f9001b2296b99503478ac8b2f5553e6879cb1959e99b933a9a6cc6e948383c9fccad3ee8c3dcb8c974adeb782379612ea7ee3d49dd0fb72a8ee0ead93cac3aed2e29c901a8ce43e3589f7692076bc6a5f9e7 + startIndex: 000000000100000002000000030000000400000005000000060000000700000008000000090000000a0000000b0000000c0000000d0000000e0000000f0000001000000011000000120000001300000014000000140000001500000016000000170000001700000018000000190000001a0000001a0000001b0000001c0000001d0000001e0000001f000000200000002100000021000000220000002300000024000000240000002500000026000000270000002700000028000000290000002a0000002a0000002b0000002c0000002d0000002d0000002e0000002f000000 + dataPosition: 0000000004000000090000000a0000000b00000013000000130000001400000015000000190000001d0000002100000027000000280000002900000031000000310000003200000033000000370000003b0000005e0000005e0000005f000000830000008300000087000000b4000000b4000000b8000000bc000000c0000000c4000000c8000000ec000000ec000000f00000001401000014010000180100003c0100003c010000400100006301000063010000640100008701000087010000 + unityObjects: + - {fileID: 1679165112} + - {fileID: 795308213} + - {fileID: 1577869803} + - {fileID: 86219747} + byteData: 00000000456e747279010000000000000000000000000000000000000001000000506174726f6c0100000000000000dc42000000000000000000004265686176696f7244657369676e65722e52756e74696d652e536861726564426f6f6c004265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f6174000000004265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a6563744c69737404000000000000000100000002000000030000004265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f6174000020414265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f6174000096444265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f6174cdcc4c3e4265686176696f7244657369676e65722e52756e74696d652e536861726564426f6f6c014265686176696f7244657369676e65722e52756e74696d652e536861726564426f6f6c01 + byteDataArray: 00000000456e747279010000000000000000000000000000000000000001000000506174726f6c0100000000000000dc42000000000000000000004265686176696f7244657369676e65722e52756e74696d652e536861726564426f6f6c004265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f6174000000004265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a6563744c69737404000000000000000100000002000000030000004265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f6174000020414265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f6174000096444265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f6174cdcc4c3e4265686176696f7244657369676e65722e52756e74696d652e536861726564426f6f6c014265686176696f7244657369676e65722e52756e74696d652e536861726564426f6f6c01 + Version: 1.5.10 + gizmoViewMode: 2 + showBehaviorDesignerGizmo: 1 + unitTestResult: {fileID: 0} +--- !u!114 &95806618 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 95806605} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 8d7b55c7ecdb49a4a89fa5e6f9022861, type: 3} + m_Name: + m_EditorClassIdentifier: + startWhenEnabled: 0 + asynchronousLoad: 0 + pauseWhenDisabled: 0 + restartWhenComplete: 0 + logTaskChanges: 0 + group: 8 + resetValuesOnRestart: 0 + externalBehavior: {fileID: 0} + mBehaviorSource: + behaviorName: Cover + behaviorDescription: + mTaskData: + types: + - BehaviorDesigner.Runtime.Tasks.EntryTask + - BehaviorDesigner.Runtime.Tasks.Movement.Cover + parentIndex: ffffffff00000000 + startIndex: 000000000a000000 + variableStartIndex: + JSONSerialization: + fieldSerializationData: + typeName: [] + fieldNameHash: 7d6ed74f587d82e1cda3fdf0ab643ccee0f0d2677230fc9344a34c197c55199df179fb1af835a4a97d6ed74f587d82e1cda3fdf0ab643ccee0f0d2677230fc9344a34c197c55199df179fb1af835a4a9fcd903d376bbb4a3a96a636f1f20e7e4ba2b1a3314b4566c8e95073dc144b6084e5eee4117315c8691120d57c4c1bb223a773f98af15e02529f790f65ca63fc2d25bc33718a4774892852819c534d7e41548c961a0c1ff0e1aa3b0df4d525fabc307e320fcb18e6876933f39a942ee041ff8717a1b2296b99503478ac8b2f5553e6879cb1959e99b933a9a6cc6e948383c9fccad3ee8c3dcb8c974adeb782379612ea7ee3d49dd0fb72a8ee0ead93cac3aed2e29c901a8ce43e3589f7692076bc6a5f9e7 + startIndex: 000000000100000002000000030000000400000005000000060000000700000008000000090000000a0000000b0000000c0000000d0000000e0000000f0000001000000011000000120000001300000014000000140000001500000016000000170000001800000018000000190000001a0000001b0000001b0000001c0000001d0000001e0000001e0000001f000000200000002100000021000000220000002300000024000000240000002500000026000000270000002700000028000000290000002a0000002a0000002b0000002c0000002d0000002d0000002e0000002f000000300000003000000031000000320000003300000033000000340000003500000036000000360000003700000038000000 + dataPosition: 0000000004000000090000000a0000000b00000013000000130000001400000015000000190000001d0000002100000026000000270000002800000030000000300000003100000032000000360000003a0000005e0000005e000000620000006600000088000000880000008c000000b0000000b0000000b4000000d8000000d8000000dc000000ff000000ff000000000100002401000024010000280100004c0100004c010000500100007401000074010000780100009c0100009c010000a0010000c4010000c4010000c8010000eb010000eb010000ec0100000f0200000f020000 + unityObjects: [] + byteData: 00000000456e747279010000000000000000000000000000000000000001000000436f76657201000000c0bf0000dc42000000000000000000004265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f617400007a44100000004265686176696f7244657369676e65722e52756e74696d652e536861726564496e740a0000004265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f6174000020414265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f61740000803f4265686176696f7244657369676e65722e52756e74696d652e536861726564426f6f6c004265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f61740000003f4265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f61740000a0404265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f6174000020414265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f617400007a444265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f6174cdcc4c3e4265686176696f7244657369676e65722e52756e74696d652e536861726564426f6f6c014265686176696f7244657369676e65722e52756e74696d652e536861726564426f6f6c01 + byteDataArray: 00000000456e747279010000000000000000000000000000000000000001000000436f76657201000000c0bf0000dc42000000000000000000004265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f617400007a44100000004265686176696f7244657369676e65722e52756e74696d652e536861726564496e740a0000004265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f6174000020414265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f61740000803f4265686176696f7244657369676e65722e52756e74696d652e536861726564426f6f6c004265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f61740000003f4265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f61740000a0404265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f6174000020414265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f617400007a444265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f6174cdcc4c3e4265686176696f7244657369676e65722e52756e74696d652e536861726564426f6f6c014265686176696f7244657369676e65722e52756e74696d652e536861726564426f6f6c01 + Version: 1.5.10 + gizmoViewMode: 2 + showBehaviorDesignerGizmo: 1 + unitTestResult: {fileID: 0} +--- !u!114 &95806619 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 95806605} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 8d7b55c7ecdb49a4a89fa5e6f9022861, type: 3} + m_Name: + m_EditorClassIdentifier: + startWhenEnabled: 0 + asynchronousLoad: 0 + pauseWhenDisabled: 0 + restartWhenComplete: 0 + logTaskChanges: 0 + group: 9 + resetValuesOnRestart: 0 + externalBehavior: {fileID: 0} + mBehaviorSource: + behaviorName: Wander + behaviorDescription: + mTaskData: + types: + - BehaviorDesigner.Runtime.Tasks.EntryTask + - BehaviorDesigner.Runtime.Tasks.Movement.Wander + parentIndex: ffffffff00000000 + startIndex: 000000000a000000 + variableStartIndex: + JSONSerialization: + fieldSerializationData: + typeName: [] + fieldNameHash: 7d6ed74f587d82e1cda3fdf0ab643ccee0f0d2677230fc9344a34c197c55199df179fb1af835a4a97d6ed74f587d82e1cda3fdf0ab643ccee0f0d2677230fc9344a34c197c55199df179fb1af835a4a97c32b731f613680229c316ce9f789a435dca44e1d7abf5b10a5ba47d801028f3c63c885e401e392f73cde7fae9826b702be6dc07a5c78dd8d8763ca44e2cc019bf4a23b1392cd4816cdb824de29006c3d44452844e26035581d5b1200eefe9591b2296b99503478ac8b2f5553e6879cb1959e99b933a9a6cc6e948383c9fccad3ee8c3dcb8c974adeb782379612ea7ee3d49dd0fb72a8ee0ead93cac3aed2e29c901a8ce43e3589f7692076bc6a5f9e7 + startIndex: 000000000100000002000000030000000400000005000000060000000700000008000000090000000a0000000b0000000c0000000d0000000e0000000f0000001000000011000000120000001300000014000000140000001500000016000000170000001700000018000000190000001a0000001a0000001b0000001c0000001d0000001d0000001e0000001f00000020000000200000002100000022000000230000002300000024000000250000002600000026000000270000002800000029000000290000002a0000002b0000002c0000002c0000002d0000002e0000002f0000002f000000300000003100000032000000320000003300000034000000 + dataPosition: 0000000004000000090000000a0000000b00000013000000130000001400000015000000190000001d0000002100000027000000280000002900000031000000310000003200000033000000370000003b0000005f0000005f0000006300000087000000870000008b000000af000000af000000b3000000d7000000d7000000db000000ff000000ff000000030100002501000025010000290100004d0100004d010000510100007501000075010000790100009d0100009d010000a1010000c4010000c4010000c5010000e8010000e8010000 + unityObjects: [] + byteData: 00000000456e74727901000000000000000000000000000000000000000100000057616e6465720100000000000000dc42000000000000000000004265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f61740000a0414265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f61740000a0414265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f6174000000404265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f6174000000004265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f6174000000004265686176696f7244657369676e65722e52756e74696d652e536861726564496e74010000004265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f6174000020414265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f6174000096444265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f6174cdcc4c3e4265686176696f7244657369676e65722e52756e74696d652e536861726564426f6f6c014265686176696f7244657369676e65722e52756e74696d652e536861726564426f6f6c01 + byteDataArray: 00000000456e74727901000000000000000000000000000000000000000100000057616e6465720100000000000000dc42000000000000000000004265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f61740000a0414265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f61740000a0414265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f6174000000404265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f6174000000004265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f6174000000004265686176696f7244657369676e65722e52756e74696d652e536861726564496e74010000004265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f6174000020414265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f6174000096444265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f6174cdcc4c3e4265686176696f7244657369676e65722e52756e74696d652e536861726564426f6f6c014265686176696f7244657369676e65722e52756e74696d652e536861726564426f6f6c01 + Version: 1.5.10 + gizmoViewMode: 2 + showBehaviorDesignerGizmo: 1 + unitTestResult: {fileID: 0} +--- !u!114 &95806620 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 95806605} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 8d7b55c7ecdb49a4a89fa5e6f9022861, type: 3} + m_Name: + m_EditorClassIdentifier: + startWhenEnabled: 0 + asynchronousLoad: 0 + pauseWhenDisabled: 0 + restartWhenComplete: 0 + logTaskChanges: 0 + group: 10 + resetValuesOnRestart: 0 + externalBehavior: {fileID: 0} + mBehaviorSource: + behaviorName: Search + behaviorDescription: + mTaskData: + types: + - BehaviorDesigner.Runtime.Tasks.EntryTask + - BehaviorDesigner.Runtime.Tasks.Sequence + - BehaviorDesigner.Runtime.Tasks.Movement.Search + - BehaviorDesigner.Runtime.Tasks.Movement.Seek + parentIndex: ffffffff000000000100000001000000 + startIndex: 0b00000015000000200000007f000000 + variableStartIndex: 000000000300000007000000 + JSONSerialization: + fieldSerializationData: + typeName: [] + fieldNameHash: 7ae1b0d0ad905f9c72aeef987ae1b0d0ad905f9c72aeef982346e3117ae1b0d0ad905f9c72aeef982346e3117d6ed74f587d82e1cda3fdf0ab643ccee0f0d2677230fc9344a34c197c55199df179fb1af835a4a97d6ed74f587d82e1cda3fdf0ab643ccee0f0d2677230fc9344a34c197c55199df179fb1af835a4a90a1684897d6ed74f587d82e1cda3fdf0ab643ccee0f0d2677230fc9344a34c197c55199df179fb1af835a4a97c32b731f613680229c316ce9f789a435dca44e1d7abf5b10a5ba47d801028f3c63c885e401e392f73cde7fae9826b702be6dc07a5c78dd8d8763ca44e2cc019bf4a23b1392cd4816cdb824de29006c3d44452844e26035581d5b1200eefe95926719d07a0524ed8d301fda349b780194c573e94c638ef64f9e79d306f9d21a6e249c1b5685f2afce240dbcc15f0899865037c15e2e1a4695cc3553a8f7204060528887b5a6b61c3d44c129407fcc05f1c9e24edd9fd594353df0a14868eb9df9b301d6dc436415fd718c9a851fa797984a92845d4bc1ac244e90a9ee18d55365b6f06078e1eb5d204d43848a60ed35020f08321539f32ed18bdc2e91b2296b99503478ac8b2f5558dd085523e6879cb1959e99b933a9a6cc6e948388b07d9343c9fccad3ee8c3dcb8c974adeb782379612ea7ee3d49dd0fb72a8ee0ead93cac3aed2e29c901a8ce43e3589f7692076bc6a5f9e77d6ed74f587d82e1cda3fdf0ab643ccee0f0d2677230fc9344a34c197c55199df179fb1af835a4a9b87e514832600219650fb1e42a2d41e13219e840acfa9811dfa947ddf44bab6a1b2296b99503478ac8b2f5558dd085523e6879cb1959e99b933a9a6cc6e948388b07d9343c9fccad3ee8c3dcb8c974adeb782379612ea7ee3d49dd0fb72a8ee0ead93cac3aed2e29c901a8ce43e3589f7692076bc6a5f9e7 + startIndex: 000000000100000002000000030000000400000005000000060000000700000008000000090000000a0000000b0000000c0000000d0000000e0000000f000000100000001100000012000000130000001400000015000000160000001700000018000000190000001a0000001b0000001c0000001d0000001e0000001f000000200000002100000022000000230000002400000025000000260000002700000028000000290000002a0000002a0000002b0000002c0000002d0000002d0000002e0000002f00000030000000300000003100000032000000330000003300000034000000350000003600000036000000370000003800000039000000390000003a0000003b0000003c0000003c0000003d0000003e0000003f0000003f000000400000004100000042000000430000004300000044000000450000004600000046000000470000004800000049000000490000004a0000004b0000004c0000004c0000004d0000004e0000004f000000500000005000000051000000520000005300000054000000540000005500000056000000570000005700000058000000590000005a0000005a0000005b0000005c0000005d0000005e0000005e0000005f000000600000006100000062000000620000006300000064000000650000006500000066000000670000006800000068000000690000006a0000006b0000006c0000006d0000006e0000006f0000007000000071000000720000007300000074000000750000007500000076000000770000007800000078000000790000007a0000007b0000007b0000007c0000007d0000007e0000007f0000007f000000800000008100000082000000830000008300000084000000850000008600000086000000870000008800000089000000890000008a0000008b000000 + dataPosition: 00000000290000003400000035000000590000005e0000005f00000063000000870000009300000094000000980000009c000000a1000000a2000000a3000000ab000000ab000000ac000000ad000000b1000000b5000000b9000000c1000000c2000000c3000000cb000000cb000000cc000000cd000000d1000000d5000000d9000000dd000000e3000000e4000000e5000000ed000000ed000000ee000000ef000000f3000000f70000001b0100001b0100001f0100004301000043010000470100006b0100006b0100006f010000930100009301000097010000bb010000bb010000bf010000e1010000e1010000e501000009020000090200000d020000310200003102000035020000390200005c0200005c0200005d020000810200008102000085020000ab020000ab020000b7020000dd020000dd020000e9020000ed0200001003000010030000110300001503000039030000390300003d030000660300007103000072030000960300009b0300009c030000a0030000c4030000d0030000d1030000d5030000f9030000f9030000fd030000200400002004000021040000440400004404000045040000490400004d0400004e0400004f040000570400005704000058040000590400005d040000610400008a0400009504000096040000bc040000bc040000c8040000ec040000f1040000f2040000f60400001a05000026050000270500002b0500004f0500004f050000530500007605000076050000770500009a0500009a050000 + unityObjects: [] + byteData: 4265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a656374466f756e644f626a656374014265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f6174537065656401000020414265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f6174416e67756c617253706565640100007a4400000000456e74727901000000000000000000000000000000000000000100000053657175656e63650100000000bf0000dc42000000000000000000000000000002000000536561726368010000009dc20000f842000000000000000000004265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f61740000a0414265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f61740000a0414265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f61740000803f4265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f6174000000004265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f6174000000004265686176696f7244657369676e65722e52756e74696d652e536861726564496e74010000004265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f6174000034434265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f61740000f041040000004265686176696f7244657369676e65722e52756e74696d652e536861726564426f6f6c004265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f6174000000004265686176696f7244657369676e65722e52756e74696d652e536861726564566563746f72330000000000000000000000004265686176696f7244657369676e65722e52756e74696d652e536861726564566563746f7233000000000000000000000000010000004265686176696f7244657369676e65722e52756e74696d652e536861726564426f6f6c00000000004265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f6174000000004265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a656374466f756e644f626a656374014265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f6174537065656401000020414265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f6174416e67756c617253706565640100007a444265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f6174cdcc4c3e4265686176696f7244657369676e65722e52756e74696d652e536861726564426f6f6c014265686176696f7244657369676e65722e52756e74696d652e536861726564426f6f6c01030000005365656b0100000066420000f442000000000000000000004265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a656374466f756e644f626a656374014265686176696f7244657369676e65722e52756e74696d652e536861726564566563746f72330000000000000000000000004265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f6174537065656401000020414265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f6174416e67756c617253706565640100007a444265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f6174cdcc4c3e4265686176696f7244657369676e65722e52756e74696d652e536861726564426f6f6c014265686176696f7244657369676e65722e52756e74696d652e536861726564426f6f6c01 + byteDataArray: 4265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a656374466f756e644f626a656374014265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f6174537065656401000020414265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f6174416e67756c617253706565640100007a4400000000456e74727901000000000000000000000000000000000000000100000053657175656e63650100000000bf0000dc42000000000000000000000000000002000000536561726368010000009dc20000f842000000000000000000004265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f61740000a0414265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f61740000a0414265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f61740000803f4265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f6174000000004265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f6174000000004265686176696f7244657369676e65722e52756e74696d652e536861726564496e74010000004265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f6174000034434265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f61740000f041040000004265686176696f7244657369676e65722e52756e74696d652e536861726564426f6f6c004265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f6174000000004265686176696f7244657369676e65722e52756e74696d652e536861726564566563746f72330000000000000000000000004265686176696f7244657369676e65722e52756e74696d652e536861726564566563746f7233000000000000000000000000010000004265686176696f7244657369676e65722e52756e74696d652e536861726564426f6f6c00000000004265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f6174000000004265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a656374466f756e644f626a656374014265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f6174537065656401000020414265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f6174416e67756c617253706565640100007a444265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f6174cdcc4c3e4265686176696f7244657369676e65722e52756e74696d652e536861726564426f6f6c014265686176696f7244657369676e65722e52756e74696d652e536861726564426f6f6c01030000005365656b0100000066420000f442000000000000000000004265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a656374466f756e644f626a656374014265686176696f7244657369676e65722e52756e74696d652e536861726564566563746f72330000000000000000000000004265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f6174537065656401000020414265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f6174416e67756c617253706565640100007a444265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f6174cdcc4c3e4265686176696f7244657369676e65722e52756e74696d652e536861726564426f6f6c014265686176696f7244657369676e65722e52756e74696d652e536861726564426f6f6c01 + Version: 1.5.10 + gizmoViewMode: 2 + showBehaviorDesignerGizmo: 1 + unitTestResult: {fileID: 0} +--- !u!114 &95806621 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 95806605} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 8d7b55c7ecdb49a4a89fa5e6f9022861, type: 3} + m_Name: + m_EditorClassIdentifier: + startWhenEnabled: 0 + asynchronousLoad: 0 + pauseWhenDisabled: 0 + restartWhenComplete: 0 + logTaskChanges: 0 + group: 12 + resetValuesOnRestart: 0 + externalBehavior: {fileID: 0} + mBehaviorSource: + behaviorName: Can See Object + behaviorDescription: + mTaskData: + types: [] + parentIndex: + startIndex: + variableStartIndex: + JSONSerialization: '{"EntryTask":{"Type":"BehaviorDesigner.Runtime.Tasks.EntryTask","NodeData":{"Offset":"(10,0)"},"ID":0,"Name":"Entry","Instant":true},"RootTask":{"Type":"BehaviorDesigner.Runtime.Tasks.Selector","NodeData":{"Offset":"(1.2142334,138.75885)"},"ID":1,"Name":"Selector","Instant":true,"AbortTypeabortType":"None","Children":[{"Type":"BehaviorDesigner.Runtime.Tasks.Sequence","NodeData":{"Offset":"(-70,130)"},"ID":2,"Name":"Sequence","Instant":true,"AbortTypeabortType":"LowerPriority","Children":[{"Type":"BehaviorDesigner.Runtime.Tasks.Movement.CanSeeObject","NodeData":{"Offset":"(-70,120.243919)"},"ID":3,"Name":"Can + See Object","Instant":true,"BooleanusePhysics2D":false,"SharedGameObjecttargetObject":{"Type":"BehaviorDesigner.Runtime.SharedGameObject","Name":""},"SharedGameObjectListtargetObjects":{"Type":"BehaviorDesigner.Runtime.SharedGameObjectList","Name":"","List`1mValue":[]},"SharedStringtargetTag":{"Type":"BehaviorDesigner.Runtime.SharedString","Name":""},"LayerMaskobjectLayerMask":1,"Int32maxCollisionCount":200,"LayerMaskignoreLayerMask":4,"SharedFloatfieldOfViewAngle":{"Type":"BehaviorDesigner.Runtime.SharedFloat","Name":"","SinglemValue":45},"SharedFloatviewDistance":{"Type":"BehaviorDesigner.Runtime.SharedFloat","Name":"","SinglemValue":1000},"SharedVector3offset":{"Type":"BehaviorDesigner.Runtime.SharedVector3","Name":"","Vector3mValue":"(0,0,0)"},"SharedVector3targetOffset":{"Type":"BehaviorDesigner.Runtime.SharedVector3","Name":"","Vector3mValue":"(0,0,0)"},"SharedFloatangleOffset2D":{"Type":"BehaviorDesigner.Runtime.SharedFloat","Name":"","SinglemValue":0},"SharedBooluseTargetBone":{"Type":"BehaviorDesigner.Runtime.SharedBool","Name":"","BooleanmValue":false},"HumanBodyBonestargetBone":"Hips","SharedBooldrawDebugRay":{"Type":"BehaviorDesigner.Runtime.SharedBool","Name":null,"BooleanmValue":true},"SharedBooldisableAgentColliderLayer":{"Type":"BehaviorDesigner.Runtime.SharedBool","Name":null,"BooleanmValue":false},"SharedGameObjectreturnedObject":{"Type":"BehaviorDesigner.Runtime.SharedGameObject","Name":"FoundObject","IsShared":true}},{"Type":"BehaviorDesigner.Runtime.Tasks.Movement.Seek","NodeData":{"Offset":"(80,116.355049)"},"ID":4,"Name":"Seek","Instant":true,"SharedGameObjecttarget":{"Type":"BehaviorDesigner.Runtime.SharedGameObject","Name":"FoundObject","IsShared":true},"SharedVector3targetPosition":{"Type":"BehaviorDesigner.Runtime.SharedVector3","Name":"","Vector3mValue":"(0,0,0)"},"SharedFloatspeed":{"Type":"BehaviorDesigner.Runtime.SharedFloat","Name":"","SinglemValue":10},"SharedFloatangularSpeed":{"Type":"BehaviorDesigner.Runtime.SharedFloat","Name":"","SinglemValue":1200},"SharedFloatarriveDistance":{"Type":"BehaviorDesigner.Runtime.SharedFloat","Name":"","SinglemValue":0.2},"SharedBoolstopOnTaskEnd":{"Type":"BehaviorDesigner.Runtime.SharedBool","Name":"","BooleanmValue":true},"SharedBoolupdateRotation":{"Type":"BehaviorDesigner.Runtime.SharedBool","Name":"","BooleanmValue":true}}]},{"Type":"BehaviorDesigner.Runtime.Tasks.Idle","NodeData":{"Offset":"(112.102112,142.55249)"},"ID":5,"Name":"Idle","Instant":true}]},"Variables":[{"Type":"BehaviorDesigner.Runtime.SharedGameObject","Name":"FoundObject","IsShared":true}]}' + fieldSerializationData: + typeName: [] + fieldNameHash: + startIndex: + dataPosition: + unityObjects: [] + byteData: + byteDataArray: + Version: 1.6.5 + gizmoViewMode: 2 + showBehaviorDesignerGizmo: 1 + unitTestResult: {fileID: 0} +--- !u!114 &95806622 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 95806605} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 8d7b55c7ecdb49a4a89fa5e6f9022861, type: 3} + m_Name: + m_EditorClassIdentifier: + startWhenEnabled: 0 + asynchronousLoad: 0 + pauseWhenDisabled: 0 + restartWhenComplete: 0 + logTaskChanges: 0 + group: 13 + resetValuesOnRestart: 0 + externalBehavior: {fileID: 0} + mBehaviorSource: + behaviorName: Can Hear Object + behaviorDescription: + mTaskData: + types: [] + parentIndex: + startIndex: + variableStartIndex: + JSONSerialization: '{"EntryTask":{"Type":"BehaviorDesigner.Runtime.Tasks.EntryTask","NodeData":{"Offset":"(0,0)"},"ID":0,"Name":"Entry","Instant":true},"RootTask":{"Type":"BehaviorDesigner.Runtime.Tasks.Selector","NodeData":{"Offset":"(-0.8359375,102.169586)"},"ID":1,"Name":"Selector","Instant":true,"AbortTypeabortType":"None","Children":[{"Type":"BehaviorDesigner.Runtime.Tasks.Sequence","NodeData":{"Offset":"(-70,140)"},"ID":2,"Name":"Sequence","Instant":true,"AbortTypeabortType":"LowerPriority","Children":[{"Type":"BehaviorDesigner.Runtime.Tasks.Movement.CanHearObject","NodeData":{"Offset":"(-70,120)"},"ID":3,"Name":"Can + Hear Object","Instant":true,"BooleanusePhysics2D":false,"SharedGameObjecttargetObject":{"Type":"BehaviorDesigner.Runtime.SharedGameObject","Name":"","GameObjectmValue":0},"SharedGameObjectListtargetObjects":{"Type":"BehaviorDesigner.Runtime.SharedGameObjectList","Name":"","List`1mValue":[]},"SharedStringtargetTag":{"Type":"BehaviorDesigner.Runtime.SharedString","Name":""},"LayerMaskobjectLayerMask":1,"Int32maxCollisionCount":200,"SharedFloathearingRadius":{"Type":"BehaviorDesigner.Runtime.SharedFloat","Name":"","SinglemValue":50},"SharedFloataudibilityThreshold":{"Type":"BehaviorDesigner.Runtime.SharedFloat","Name":"","SinglemValue":0.001},"SharedVector3offset":{"Type":"BehaviorDesigner.Runtime.SharedVector3","Name":"","Vector3mValue":"(0,0,0)"},"SharedGameObjectreturnedObject":{"Type":"BehaviorDesigner.Runtime.SharedGameObject","Name":"FoundObject","IsShared":true}},{"Type":"BehaviorDesigner.Runtime.Tasks.Movement.Seek","NodeData":{"Offset":"(80,115)"},"ID":4,"Name":"Seek","Instant":true,"SharedGameObjecttarget":{"Type":"BehaviorDesigner.Runtime.SharedGameObject","Name":"FoundObject","IsShared":true},"SharedVector3targetPosition":{"Type":"BehaviorDesigner.Runtime.SharedVector3","Name":"","Vector3mValue":"(0,0,0)"},"SharedFloatspeed":{"Type":"BehaviorDesigner.Runtime.SharedFloat","Name":"","SinglemValue":10},"SharedFloatangularSpeed":{"Type":"BehaviorDesigner.Runtime.SharedFloat","Name":"","SinglemValue":1200},"SharedFloatarriveDistance":{"Type":"BehaviorDesigner.Runtime.SharedFloat","Name":"","SinglemValue":0.2},"SharedBoolstopOnTaskEnd":{"Type":"BehaviorDesigner.Runtime.SharedBool","Name":"","BooleanmValue":true},"SharedBoolupdateRotation":{"Type":"BehaviorDesigner.Runtime.SharedBool","Name":"","BooleanmValue":true}}]},{"Type":"BehaviorDesigner.Runtime.Tasks.Idle","NodeData":{"Offset":"(110,140)"},"ID":5,"Name":"Idle","Instant":true}]},"Variables":[{"Type":"BehaviorDesigner.Runtime.SharedGameObject","Name":"FoundObject","IsShared":true}]}' + fieldSerializationData: + typeName: [] + fieldNameHash: + startIndex: + dataPosition: + unityObjects: + - {fileID: 157415760} + byteData: + byteDataArray: + Version: 1.6.5 + gizmoViewMode: 2 + showBehaviorDesignerGizmo: 1 + unitTestResult: {fileID: 0} +--- !u!114 &95806623 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 95806605} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 8d7b55c7ecdb49a4a89fa5e6f9022861, type: 3} + m_Name: + m_EditorClassIdentifier: + startWhenEnabled: 0 + asynchronousLoad: 0 + pauseWhenDisabled: 0 + restartWhenComplete: 0 + logTaskChanges: 0 + group: 17 + resetValuesOnRestart: 0 + externalBehavior: {fileID: 0} + mBehaviorSource: + behaviorName: Leader + behaviorDescription: + mTaskData: + types: + - BehaviorDesigner.Runtime.Tasks.EntryTask + - BehaviorDesigner.Runtime.Tasks.Movement.Patrol + parentIndex: ffffffff00000000 + startIndex: 000000000a000000 + variableStartIndex: + JSONSerialization: + fieldSerializationData: + typeName: [] + fieldNameHash: 7d6ed74f587d82e1cda3fdf0ab643ccee0f0d2677230fc9344a34c197c55199df179fb1af835a4a97d6ed74f587d82e1cda3fdf0ab643ccee0f0d2677230fc9344a34c197c55199df179fb1af835a4a91be9514b95ca021cc879b1e7188da3649e1a281e18fcd8ee4bab87bac1600b30e0443ff15a26f0c18dd59e8de26bdfa5f5e497a98340223b2d90a056cdd9f9001b2296b99503478ac8b2f5553e6879cb1959e99b933a9a6cc6e948383c9fccad3ee8c3dcb8c974adeb782379612ea7ee3d49dd0fb72a8ee0ead93cac3aed2e29c901a8ce43e3589f7692076bc6a5f9e7 + startIndex: 000000000100000002000000030000000400000005000000060000000700000008000000090000000a0000000b0000000c0000000d0000000e0000000f0000001000000011000000120000001300000014000000140000001500000016000000170000001700000018000000190000001a0000001a0000001b0000001c0000001d0000001e0000001f000000200000002100000021000000220000002300000024000000240000002500000026000000270000002700000028000000290000002a0000002a0000002b0000002c0000002d0000002d0000002e0000002f000000 + dataPosition: 0000000004000000090000000a0000000b00000013000000130000001400000015000000190000001d0000002100000027000000280000002900000031000000310000003200000033000000370000003b0000005e0000005e0000005f000000830000008300000087000000b4000000b4000000b8000000bc000000c0000000c4000000c8000000ec000000ec000000f00000001401000014010000180100003c0100003c010000400100006301000063010000640100008701000087010000 + unityObjects: + - {fileID: 985012142} + - {fileID: 1114766221} + - {fileID: 453012817} + - {fileID: 1716371254} + byteData: 00000000456e747279010000000000000000000000000000000000000001000000506174726f6c0100000000000000dc42000000000000000000004265686176696f7244657369676e65722e52756e74696d652e536861726564426f6f6c004265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f6174000000004265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a6563744c69737404000000000000000100000002000000030000004265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f6174000020414265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f6174000096444265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f6174cdcc4c3e4265686176696f7244657369676e65722e52756e74696d652e536861726564426f6f6c014265686176696f7244657369676e65722e52756e74696d652e536861726564426f6f6c01 + byteDataArray: 00000000456e747279010000000000000000000000000000000000000001000000506174726f6c0100000000000000dc42000000000000000000004265686176696f7244657369676e65722e52756e74696d652e536861726564426f6f6c004265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f6174000000004265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a6563744c69737404000000000000000100000002000000030000004265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f6174000020414265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f6174000096444265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f6174cdcc4c3e4265686176696f7244657369676e65722e52756e74696d652e536861726564426f6f6c014265686176696f7244657369676e65722e52756e74696d652e536861726564426f6f6c01 + Version: 1.5.10 + gizmoViewMode: 2 + showBehaviorDesignerGizmo: 1 + unitTestResult: {fileID: 0} +--- !u!114 &95806624 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 95806605} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 8d7b55c7ecdb49a4a89fa5e6f9022861, type: 3} + m_Name: + m_EditorClassIdentifier: + startWhenEnabled: 0 + asynchronousLoad: 0 + pauseWhenDisabled: 0 + restartWhenComplete: 0 + logTaskChanges: 0 + group: 11 + resetValuesOnRestart: 0 + externalBehavior: {fileID: 0} + mBehaviorSource: + behaviorName: Within Distance + behaviorDescription: + mTaskData: + types: [] + parentIndex: + startIndex: + variableStartIndex: + JSONSerialization: '{"EntryTask":{"Type":"BehaviorDesigner.Runtime.Tasks.EntryTask","NodeData":{"Offset":"(0,0)"},"ID":0,"Name":"Entry","Instant":true},"RootTask":{"Type":"BehaviorDesigner.Runtime.Tasks.Selector","NodeData":{"Offset":"(1,108)"},"ID":1,"Name":"Selector","Instant":true,"AbortTypeabortType":"None","Children":[{"Type":"BehaviorDesigner.Runtime.Tasks.Sequence","NodeData":{"Offset":"(-69,118)"},"ID":2,"Name":"Sequence","Instant":true,"AbortTypeabortType":"LowerPriority","Children":[{"Type":"BehaviorDesigner.Runtime.Tasks.Movement.WithinDistance","NodeData":{"Offset":"(-80,130)"},"ID":3,"Name":"Within + Distance","Instant":true,"BooleanusePhysics2D":false,"SharedGameObjecttargetObject":{"Type":"BehaviorDesigner.Runtime.SharedGameObject","Name":"","GameObjectmValue":0},"SharedStringtargetTag":{"Type":"BehaviorDesigner.Runtime.SharedString","Name":""},"LayerMaskobjectLayerMask":0,"SharedFloatmagnitude":{"Type":"BehaviorDesigner.Runtime.SharedFloat","Name":"","SinglemValue":25},"SharedBoollineOfSight":{"Type":"BehaviorDesigner.Runtime.SharedBool","Name":"","BooleanmValue":true},"LayerMaskignoreLayerMask":4,"SharedVector3offset":{"Type":"BehaviorDesigner.Runtime.SharedVector3","Name":"","Vector3mValue":"(0,0,0)"},"SharedVector3targetOffset":{"Type":"BehaviorDesigner.Runtime.SharedVector3","Name":"","Vector3mValue":"(0,0,0)"},"SharedBooldrawDebugRay":{"Type":"BehaviorDesigner.Runtime.SharedBool","Name":null,"BooleanmValue":false},"SharedGameObjectreturnedObject":{"Type":"BehaviorDesigner.Runtime.SharedGameObject","Name":"FoundObject","IsShared":true}},{"Type":"BehaviorDesigner.Runtime.Tasks.Movement.Seek","NodeData":{"Offset":"(70,130)"},"ID":4,"Name":"Seek","Instant":true,"SharedGameObjecttarget":{"Type":"BehaviorDesigner.Runtime.SharedGameObject","Name":"FoundObject","IsShared":true},"SharedVector3targetPosition":{"Type":"BehaviorDesigner.Runtime.SharedVector3","Name":"","Vector3mValue":"(0,0,0)"},"SharedFloatspeed":{"Type":"BehaviorDesigner.Runtime.SharedFloat","Name":"","SinglemValue":10},"SharedFloatangularSpeed":{"Type":"BehaviorDesigner.Runtime.SharedFloat","Name":"","SinglemValue":1200},"SharedFloatarriveDistance":{"Type":"BehaviorDesigner.Runtime.SharedFloat","Name":"","SinglemValue":0.2},"SharedBoolstopOnTaskEnd":{"Type":"BehaviorDesigner.Runtime.SharedBool","Name":"","BooleanmValue":true},"SharedBoolupdateRotation":{"Type":"BehaviorDesigner.Runtime.SharedBool","Name":"","BooleanmValue":true}}]},{"Type":"BehaviorDesigner.Runtime.Tasks.Idle","NodeData":{"Offset":"(71,118)"},"ID":5,"Name":"Idle","Instant":true}]},"Variables":[{"Type":"BehaviorDesigner.Runtime.SharedGameObject","Name":"FoundObject","IsShared":true}]}' + fieldSerializationData: + typeName: [] + fieldNameHash: + startIndex: + dataPosition: + unityObjects: + - {fileID: 157415760} + byteData: + byteDataArray: + Version: 1.6.5 + gizmoViewMode: 2 + showBehaviorDesignerGizmo: 1 + unitTestResult: {fileID: 0} +--- !u!114 &95806625 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 95806605} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 8d7b55c7ecdb49a4a89fa5e6f9022861, type: 3} + m_Name: + m_EditorClassIdentifier: + startWhenEnabled: 0 + asynchronousLoad: 0 + pauseWhenDisabled: 0 + restartWhenComplete: 0 + logTaskChanges: 0 + group: 6 + resetValuesOnRestart: 0 + externalBehavior: {fileID: 0} + mBehaviorSource: + behaviorName: Follow + behaviorDescription: + mTaskData: + types: + - BehaviorDesigner.Runtime.Tasks.EntryTask + - BehaviorDesigner.Runtime.Tasks.Movement.Follow + parentIndex: ffffffff00000000 + startIndex: 000000000a000000 + variableStartIndex: + JSONSerialization: + fieldSerializationData: + typeName: [] + fieldNameHash: 7d6ed74f587d82e1cda3fdf0ab643ccee0f0d2677230fc9344a34c197c55199df179fb1af835a4a97d6ed74f587d82e1cda3fdf0ab643ccee0f0d2677230fc9344a34c197c55199df179fb1af835a4a9b87e514832600219650fb1e45bd3c70d6090c9d6da717aa70d21297383d6ace81b2296b99503478ac8b2f5553e6879cb1959e99b933a9a6cc6e948383c9fccad3ee8c3dcb8c974adeb782379612ea7ee3d49dd0fb72a8ee0ead93cac3aed2e29c901a8ce43e3589f7692076bc6a5f9e7 + startIndex: 000000000100000002000000030000000400000005000000060000000700000008000000090000000a0000000b0000000c0000000d0000000e0000000f0000001000000011000000120000001300000014000000140000001500000016000000170000001700000018000000190000001a0000001a0000001b0000001c0000001d0000001d0000001e0000001f000000200000002000000021000000220000002300000023000000240000002500000026000000260000002700000028000000 + dataPosition: 0000000004000000090000000a0000000b00000013000000130000001400000015000000190000001d0000002100000027000000280000002900000031000000310000003200000033000000370000003b0000006400000064000000680000008c0000008c00000090000000b4000000b4000000b8000000dc000000dc000000e00000000401000004010000080100002b0100002b0100002c0100004f0100004f010000 + unityObjects: + - {fileID: 157415760} + byteData: 00000000456e747279010000000000000000000000000000000000000001000000466f6c6c6f770100000000000000dc42000000000000000000004265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a656374000000004265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f6174000080404265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f6174000020414265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f61740000f0424265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f6174cdcc4c3e4265686176696f7244657369676e65722e52756e74696d652e536861726564426f6f6c014265686176696f7244657369676e65722e52756e74696d652e536861726564426f6f6c01 + byteDataArray: 00000000456e747279010000000000000000000000000000000000000001000000466f6c6c6f770100000000000000dc42000000000000000000004265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a656374000000004265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f6174000080404265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f6174000020414265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f61740000f0424265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f6174cdcc4c3e4265686176696f7244657369676e65722e52756e74696d652e536861726564426f6f6c014265686176696f7244657369676e65722e52756e74696d652e536861726564426f6f6c01 + Version: 1.5.10 + gizmoViewMode: 2 + showBehaviorDesignerGizmo: 1 + unitTestResult: {fileID: 0} +--- !u!1 &122009231 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 122009232} + m_Layer: 0 + m_Name: Structure1 + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &122009232 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 122009231} + 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: + - {fileID: 1596608537} + - {fileID: 1190109943} + - {fileID: 1462659479} + - {fileID: 1620701896} + - {fileID: 1993239500} + - {fileID: 1572679522} + - {fileID: 616612090} + - {fileID: 1914565680} + - {fileID: 1487439663} + - {fileID: 1250902117} + - {fileID: 1358453175} + - {fileID: 638693647} + m_Father: {fileID: 0} + m_RootOrder: 7 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!1 &157415760 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 157415764} + - component: {fileID: 157415763} + - component: {fileID: 157415761} + - component: {fileID: 157415762} + - component: {fileID: 157415765} + - component: {fileID: 157415766} + m_Layer: 0 + m_Name: Marker + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!23 &157415761 +MeshRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 157415760} + m_Enabled: 1 + m_CastShadows: 1 + m_ReceiveShadows: 1 + m_DynamicOccludee: 1 + m_MotionVectors: 1 + m_LightProbeUsage: 0 + m_ReflectionProbeUsage: 1 + m_RenderingLayerMask: 1 + m_RendererPriority: 0 + m_Materials: + - {fileID: 2100000, guid: 6ce92c6edcc2df647be90d324133f9ed, type: 2} + 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: 3 + m_MinimumChartSize: 4 + m_AutoUVMaxDistance: 0.5 + m_AutoUVMaxAngle: 89 + m_LightmapParameters: {fileID: 0} + m_SortingLayerID: 0 + m_SortingLayer: 0 + m_SortingOrder: 0 +--- !u!111 &157415762 +Animation: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 157415760} + m_Enabled: 1 + serializedVersion: 3 + m_Animation: {fileID: 7400000, guid: 07e94773bc03f2540806b14a5f8fcbde, type: 2} + m_Animations: + - {fileID: 7400000, guid: 79d071115d1ae784b83e51b648ec393c, type: 2} + - {fileID: 7400000, guid: d49c5804b31faad4ca706eb999c87559, type: 2} + - {fileID: 7400000, guid: 9321e00e69f740142a77918a547ce578, type: 2} + - {fileID: 7400000, guid: 07e94773bc03f2540806b14a5f8fcbde, type: 2} + - {fileID: 7400000, guid: 4e102685eb400e54bb2eced40a6f2efd, type: 2} + m_WrapMode: 0 + m_PlayAutomatically: 0 + m_AnimatePhysics: 0 + m_CullingType: 0 +--- !u!33 &157415763 +MeshFilter: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 157415760} + m_Mesh: {fileID: 10207, guid: 0000000000000000e000000000000000, type: 0} +--- !u!4 &157415764 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 157415760} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: 40, y: 1, z: 0} + m_LocalScale: {x: 1, y: 1, z: 1} + m_Children: [] + m_Father: {fileID: 0} + m_RootOrder: 5 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!135 &157415765 +SphereCollider: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 157415760} + m_Material: {fileID: 0} + m_IsTrigger: 0 + m_Enabled: 1 + serializedVersion: 2 + m_Radius: 0.5000001 + m_Center: {x: 0.000000059604645, y: 0, z: -0.00000008940697} +--- !u!82 &157415766 +AudioSource: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 157415760} + m_Enabled: 1 + serializedVersion: 4 + OutputAudioMixerGroup: {fileID: 0} + m_audioClip: {fileID: 8300000, guid: 68a02d834e9e6e34fa3fa2a492571682, type: 3} + m_PlayOnAwake: 0 + m_Volume: 1 + m_Pitch: 1 + Loop: 0 + Mute: 0 + Spatialize: 0 + SpatializePostEffects: 0 + Priority: 128 + DopplerLevel: 1 + MinDistance: 1 + MaxDistance: 30 + Pan2D: 0 + rolloffMode: 0 + BypassEffects: 0 + BypassListenerEffects: 0 + BypassReverbZones: 0 + rolloffCustomCurve: + serializedVersion: 2 + m_Curve: + - serializedVersion: 3 + time: 0 + value: 1 + inSlope: 0 + outSlope: 0 + tangentMode: 0 + weightedMode: 0 + inWeight: 0.33333334 + outWeight: 0.33333334 + - serializedVersion: 3 + time: 1 + value: 0 + inSlope: 0 + outSlope: 0 + tangentMode: 0 + weightedMode: 0 + inWeight: 0.33333334 + outWeight: 0.33333334 + m_PreInfinity: 2 + m_PostInfinity: 2 + m_RotationOrder: 4 + panLevelCustomCurve: + serializedVersion: 2 + m_Curve: + - serializedVersion: 3 + time: 0 + value: 0 + inSlope: 0 + outSlope: 0 + tangentMode: 0 + weightedMode: 0 + inWeight: 0.33333334 + outWeight: 0.33333334 + m_PreInfinity: 2 + m_PostInfinity: 2 + m_RotationOrder: 4 + spreadCustomCurve: + serializedVersion: 2 + m_Curve: + - serializedVersion: 3 + time: 0 + value: 0 + inSlope: 0 + outSlope: 0 + tangentMode: 0 + weightedMode: 0 + inWeight: 0.33333334 + outWeight: 0.33333334 + m_PreInfinity: 2 + m_PostInfinity: 2 + m_RotationOrder: 4 + reverbZoneMixCustomCurve: + serializedVersion: 2 + m_Curve: + - serializedVersion: 3 + time: 0 + value: 0 + inSlope: 0 + outSlope: 0 + tangentMode: 0 + weightedMode: 0 + inWeight: 0.33333334 + outWeight: 0.33333334 + m_PreInfinity: 2 + m_PostInfinity: 2 + m_RotationOrder: 4 +--- !u!1 &158913356 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 100000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 158913357} + - component: {fileID: 158913360} + - component: {fileID: 158913359} + - component: {fileID: 158913358} + m_Layer: 0 + m_Name: bot + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &158913357 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 400000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 158913356} + m_LocalRotation: {x: 6.123233e-17, y: 1, z: 6.123233e-17, w: 0.00000013315805} + m_LocalPosition: {x: -9.986802, y: 24.925999, z: 3.441162} + m_LocalScale: {x: 2, y: 2, z: 2} + m_Children: [] + m_Father: {fileID: 66600218} + m_RootOrder: 10 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!195 &158913358 +NavMeshAgent: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 158913356} + m_Enabled: 1 + m_AgentTypeID: 0 + m_Radius: 0.6369026 + m_Speed: 15 + m_Acceleration: 15 + avoidancePriority: 50 + m_AngularSpeed: 1200 + m_StoppingDistance: 0 + m_AutoTraverseOffMeshLink: 1 + m_AutoBraking: 1 + m_AutoRepath: 1 + m_Height: 0.5024553 + m_BaseOffset: 0.25122765 + m_WalkableMask: 4294967295 + m_ObstacleAvoidanceType: 4 +--- !u!23 &158913359 +MeshRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 2300000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 158913356} + m_Enabled: 1 + m_CastShadows: 1 + m_ReceiveShadows: 1 + m_DynamicOccludee: 1 + m_MotionVectors: 1 + m_LightProbeUsage: 0 + m_ReflectionProbeUsage: 1 + m_RenderingLayerMask: 1 + m_RendererPriority: 0 + m_Materials: + - {fileID: 2100000, guid: fecc96c64c214ce40835ac4c3c3099e8, type: 2} + 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: 3 + m_MinimumChartSize: 4 + m_AutoUVMaxDistance: 0.5 + m_AutoUVMaxAngle: 89 + m_LightmapParameters: {fileID: 0} + m_SortingLayerID: 0 + m_SortingLayer: 0 + m_SortingOrder: 0 +--- !u!33 &158913360 +MeshFilter: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 3300000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 158913356} + m_Mesh: {fileID: 4300000, guid: 55e5ab7e66bd2eb49bc96935fe0bd04a, type: 3} +--- !u!1 &193687607 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 193687608} + m_Layer: 0 + m_Name: Flock + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &193687608 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 193687607} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: 22.22918, y: -24.249596, z: -157.60332} + m_LocalScale: {x: 1, y: 1, z: 1} + m_Children: + - {fileID: 1111038049} + - {fileID: 1350099622} + - {fileID: 650647372} + - {fileID: 507592136} + - {fileID: 211670239} + - {fileID: 346641} + - {fileID: 1399255298} + - {fileID: 1252079139} + - {fileID: 1726546187} + - {fileID: 862954242} + - {fileID: 366180965} + - {fileID: 1041788010} + - {fileID: 1948759274} + - {fileID: 1031935889} + - {fileID: 551555975} + - {fileID: 1674801249} + - {fileID: 2104181166} + - {fileID: 1014823308} + - {fileID: 1151094526} + - {fileID: 2133735854} + - {fileID: 1518382619} + - {fileID: 561315485} + - {fileID: 1205913527} + - {fileID: 1394933340} + - {fileID: 1111626859} + - {fileID: 34840227} + - {fileID: 2071294761} + - {fileID: 1158265378} + - {fileID: 80592863} + - {fileID: 1125071875} + m_Father: {fileID: 0} + m_RootOrder: 2 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!1 &199306294 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 199306296} + - component: {fileID: 199306295} + m_Layer: 0 + m_Name: Directional light + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!108 &199306295 +Light: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 199306294} + m_Enabled: 1 + serializedVersion: 8 + m_Type: 1 + m_Color: {r: 1, g: 1, b: 1, a: 1} + m_Intensity: 1 + m_Range: 10 + m_SpotAngle: 30 + m_CookieSize: 10 + m_Shadows: + m_Type: 0 + m_Resolution: -1 + m_CustomResolution: -1 + m_Strength: 1 + m_Bias: 0.05 + m_NormalBias: 0.4 + m_NearPlane: 0.2 + m_Cookie: {fileID: 0} + m_DrawHalo: 0 + m_Flare: {fileID: 0} + m_RenderMode: 0 + m_CullingMask: + serializedVersion: 2 + m_Bits: 4294967295 + m_Lightmapping: 1 + m_LightShadowCasterMode: 0 + m_AreaSize: {x: 1, y: 1} + m_BounceIntensity: 1 + m_ColorTemperature: 6570 + m_UseColorTemperature: 0 + m_ShadowRadius: 0 + m_ShadowAngle: 0 +--- !u!4 &199306296 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 199306294} + m_LocalRotation: {x: 0.40821794, y: -0.23456973, z: 0.10938166, w: 0.8754261} + m_LocalPosition: {x: 9.893395, y: -20.77215, z: -4.659794} + m_LocalScale: {x: 1, y: 1, z: 1} + m_Children: [] + m_Father: {fileID: 0} + m_RootOrder: 1 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!1 &211670238 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 100000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 211670239} + - component: {fileID: 211670242} + - component: {fileID: 211670241} + - component: {fileID: 211670240} + m_Layer: 0 + m_Name: bot + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &211670239 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 400000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 211670238} + m_LocalRotation: {x: 0, y: 1, z: 0, w: 0} + m_LocalPosition: {x: -21.553186, y: 24.925999, z: 9.82312} + m_LocalScale: {x: 2, y: 2, z: 2} + m_Children: [] + m_Father: {fileID: 193687608} + m_RootOrder: 4 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!195 &211670240 +NavMeshAgent: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 211670238} + m_Enabled: 1 + m_AgentTypeID: 0 + m_Radius: 0.6369026 + m_Speed: 10 + m_Acceleration: 10 + avoidancePriority: 50 + m_AngularSpeed: 1200 + m_StoppingDistance: 0 + m_AutoTraverseOffMeshLink: 1 + m_AutoBraking: 1 + m_AutoRepath: 1 + m_Height: 0.5024553 + m_BaseOffset: 0.25122765 + m_WalkableMask: 4294967295 + m_ObstacleAvoidanceType: 4 +--- !u!23 &211670241 +MeshRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 2300000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 211670238} + m_Enabled: 1 + m_CastShadows: 1 + m_ReceiveShadows: 1 + m_DynamicOccludee: 1 + m_MotionVectors: 1 + m_LightProbeUsage: 0 + m_ReflectionProbeUsage: 1 + m_RenderingLayerMask: 1 + m_RendererPriority: 0 + m_Materials: + - {fileID: 2100000, guid: fecc96c64c214ce40835ac4c3c3099e8, type: 2} + 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: 3 + m_MinimumChartSize: 4 + m_AutoUVMaxDistance: 0.5 + m_AutoUVMaxAngle: 89 + m_LightmapParameters: {fileID: 0} + m_SortingLayerID: 0 + m_SortingLayer: 0 + m_SortingOrder: 0 +--- !u!33 &211670242 +MeshFilter: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 3300000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 211670238} + m_Mesh: {fileID: 4300000, guid: 55e5ab7e66bd2eb49bc96935fe0bd04a, type: 3} +--- !u!1 &251429379 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 100000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 251429380} + - component: {fileID: 251429385} + - component: {fileID: 251429384} + - component: {fileID: 251429383} + m_Layer: 0 + m_Name: bot + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &251429380 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 400000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 251429379} + m_LocalRotation: {x: 6.123233e-17, y: 1, z: 6.123233e-17, w: 0.00000013315805} + m_LocalPosition: {x: -17.492996, y: 24.925999, z: -3.26445} + m_LocalScale: {x: 2, y: 2, z: 2} + m_Children: [] + m_Father: {fileID: 66600218} + m_RootOrder: 5 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!195 &251429383 +NavMeshAgent: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 251429379} + m_Enabled: 1 + m_AgentTypeID: 0 + m_Radius: 0.6369026 + m_Speed: 15 + m_Acceleration: 15 + avoidancePriority: 50 + m_AngularSpeed: 1200 + m_StoppingDistance: 0 + m_AutoTraverseOffMeshLink: 1 + m_AutoBraking: 1 + m_AutoRepath: 1 + m_Height: 0.5024553 + m_BaseOffset: 0.25122765 + m_WalkableMask: 4294967295 + m_ObstacleAvoidanceType: 4 +--- !u!23 &251429384 +MeshRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 2300000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 251429379} + m_Enabled: 1 + m_CastShadows: 1 + m_ReceiveShadows: 1 + m_DynamicOccludee: 1 + m_MotionVectors: 1 + m_LightProbeUsage: 0 + m_ReflectionProbeUsage: 1 + m_RenderingLayerMask: 1 + m_RendererPriority: 0 + m_Materials: + - {fileID: 2100000, guid: fecc96c64c214ce40835ac4c3c3099e8, type: 2} + 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: 3 + m_MinimumChartSize: 4 + m_AutoUVMaxDistance: 0.5 + m_AutoUVMaxAngle: 89 + m_LightmapParameters: {fileID: 0} + m_SortingLayerID: 0 + m_SortingLayer: 0 + m_SortingOrder: 0 +--- !u!33 &251429385 +MeshFilter: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 3300000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 251429379} + m_Mesh: {fileID: 4300000, guid: 55e5ab7e66bd2eb49bc96935fe0bd04a, type: 3} +--- !u!1 &363215076 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 100000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 363215077} + - component: {fileID: 363215080} + - component: {fileID: 363215079} + - component: {fileID: 363215078} + m_Layer: 0 + m_Name: bot + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &363215077 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 400000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 363215076} + m_LocalRotation: {x: 6.123233e-17, y: 1, z: 6.123233e-17, w: 0.00000013315805} + m_LocalPosition: {x: -9.986802, y: 24.925999, z: 3.441162} + m_LocalScale: {x: 2, y: 2, z: 2} + m_Children: [] + m_Father: {fileID: 1151274299} + m_RootOrder: 10 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!195 &363215078 +NavMeshAgent: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 363215076} + m_Enabled: 1 + m_AgentTypeID: 0 + m_Radius: 0.6369026 + m_Speed: 10 + m_Acceleration: 8 + avoidancePriority: 50 + m_AngularSpeed: 1200 + m_StoppingDistance: 0 + m_AutoTraverseOffMeshLink: 1 + m_AutoBraking: 1 + m_AutoRepath: 1 + m_Height: 0.5024553 + m_BaseOffset: 0.25122765 + m_WalkableMask: 4294967295 + m_ObstacleAvoidanceType: 4 +--- !u!23 &363215079 +MeshRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 2300000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 363215076} + m_Enabled: 1 + m_CastShadows: 1 + m_ReceiveShadows: 1 + m_DynamicOccludee: 1 + m_MotionVectors: 1 + m_LightProbeUsage: 0 + m_ReflectionProbeUsage: 1 + m_RenderingLayerMask: 1 + m_RendererPriority: 0 + m_Materials: + - {fileID: 2100000, guid: fecc96c64c214ce40835ac4c3c3099e8, type: 2} + 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: 3 + m_MinimumChartSize: 4 + m_AutoUVMaxDistance: 0.5 + m_AutoUVMaxAngle: 89 + m_LightmapParameters: {fileID: 0} + m_SortingLayerID: 0 + m_SortingLayer: 0 + m_SortingOrder: 0 +--- !u!33 &363215080 +MeshFilter: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 3300000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 363215076} + m_Mesh: {fileID: 4300000, guid: 55e5ab7e66bd2eb49bc96935fe0bd04a, type: 3} +--- !u!1 &366180964 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 100000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 366180965} + - component: {fileID: 366180968} + - component: {fileID: 366180967} + - component: {fileID: 366180966} + m_Layer: 0 + m_Name: bot + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &366180965 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 400000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 366180964} + m_LocalRotation: {x: 6.123233e-17, y: 1, z: 6.123233e-17, w: 0.00000013315805} + m_LocalPosition: {x: -9.986802, y: 24.925999, z: 3.441162} + m_LocalScale: {x: 2, y: 2, z: 2} + m_Children: [] + m_Father: {fileID: 193687608} + m_RootOrder: 10 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!195 &366180966 +NavMeshAgent: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 366180964} + m_Enabled: 1 + m_AgentTypeID: 0 + m_Radius: 0.6369026 + m_Speed: 10 + m_Acceleration: 10 + avoidancePriority: 50 + m_AngularSpeed: 1200 + m_StoppingDistance: 0 + m_AutoTraverseOffMeshLink: 1 + m_AutoBraking: 1 + m_AutoRepath: 1 + m_Height: 0.5024553 + m_BaseOffset: 0.25122765 + m_WalkableMask: 4294967295 + m_ObstacleAvoidanceType: 4 +--- !u!23 &366180967 +MeshRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 2300000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 366180964} + m_Enabled: 1 + m_CastShadows: 1 + m_ReceiveShadows: 1 + m_DynamicOccludee: 1 + m_MotionVectors: 1 + m_LightProbeUsage: 0 + m_ReflectionProbeUsage: 1 + m_RenderingLayerMask: 1 + m_RendererPriority: 0 + m_Materials: + - {fileID: 2100000, guid: fecc96c64c214ce40835ac4c3c3099e8, type: 2} + 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: 3 + m_MinimumChartSize: 4 + m_AutoUVMaxDistance: 0.5 + m_AutoUVMaxAngle: 89 + m_LightmapParameters: {fileID: 0} + m_SortingLayerID: 0 + m_SortingLayer: 0 + m_SortingOrder: 0 +--- !u!33 &366180968 +MeshFilter: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 3300000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 366180964} + m_Mesh: {fileID: 4300000, guid: 55e5ab7e66bd2eb49bc96935fe0bd04a, type: 3} +--- !u!1 &453012817 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 453012818} + - component: {fileID: 453012820} + - component: {fileID: 453012819} + m_Layer: 0 + m_Name: 3a + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &453012818 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 453012817} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: 32.735687, y: 0, z: -193.53264} + m_LocalScale: {x: 1, y: 1, z: 1} + m_Children: [] + m_Father: {fileID: 1867949263} + m_RootOrder: 3 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!23 &453012819 +MeshRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 453012817} + m_Enabled: 1 + m_CastShadows: 1 + m_ReceiveShadows: 1 + m_DynamicOccludee: 1 + m_MotionVectors: 1 + m_LightProbeUsage: 0 + m_ReflectionProbeUsage: 1 + m_RenderingLayerMask: 1 + m_RendererPriority: 0 + m_Materials: + - {fileID: 10302, 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: 3 + m_MinimumChartSize: 4 + m_AutoUVMaxDistance: 0.5 + m_AutoUVMaxAngle: 89 + m_LightmapParameters: {fileID: 0} + m_SortingLayerID: 0 + m_SortingLayer: 0 + m_SortingOrder: 0 +--- !u!33 &453012820 +MeshFilter: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 453012817} + m_Mesh: {fileID: 10207, guid: 0000000000000000e000000000000000, type: 0} +--- !u!1 &460272616 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 460272617} + - component: {fileID: 460272620} + - component: {fileID: 460272619} + - component: {fileID: 460272618} + m_Layer: 2 + m_Name: Cube + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 4294967295 + m_IsActive: 1 +--- !u!4 &460272617 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 460272616} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: 0, y: 1.5, z: -50} + m_LocalScale: {x: 100, y: 3, z: 2} + m_Children: [] + m_Father: {fileID: 476658879} + m_RootOrder: 0 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!23 &460272618 +MeshRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 460272616} + m_Enabled: 1 + m_CastShadows: 1 + m_ReceiveShadows: 1 + m_DynamicOccludee: 1 + m_MotionVectors: 1 + m_LightProbeUsage: 0 + m_ReflectionProbeUsage: 1 + m_RenderingLayerMask: 1 + m_RendererPriority: 0 + m_Materials: + - {fileID: 2100000, guid: a08f97e5b75379d40b08ff5f74847d5c, type: 2} + 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: 3 + m_MinimumChartSize: 4 + m_AutoUVMaxDistance: 0.5 + m_AutoUVMaxAngle: 89 + m_LightmapParameters: {fileID: 0} + m_SortingLayerID: 0 + m_SortingLayer: 0 + m_SortingOrder: 0 +--- !u!65 &460272619 +BoxCollider: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 460272616} + m_Material: {fileID: 0} + m_IsTrigger: 0 + m_Enabled: 1 + serializedVersion: 2 + m_Size: {x: 1, y: 1, z: 1} + m_Center: {x: 0, y: 0, z: 0} +--- !u!33 &460272620 +MeshFilter: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 460272616} + m_Mesh: {fileID: 10202, guid: 0000000000000000e000000000000000, type: 0} +--- !u!1 &476658878 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 476658879} + m_Layer: 0 + m_Name: Structure2 + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &476658879 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 476658878} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: 0, y: 0, z: -150} + m_LocalScale: {x: 1, y: 1, z: 1} + m_Children: + - {fileID: 460272617} + - {fileID: 1189173171} + - {fileID: 1476304421} + - {fileID: 1144204295} + - {fileID: 1446227435} + m_Father: {fileID: 0} + m_RootOrder: 8 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!1 &507592135 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 100000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 507592136} + - component: {fileID: 507592141} + - component: {fileID: 507592140} + - component: {fileID: 507592139} + m_Layer: 0 + m_Name: bot + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &507592136 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 400000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 507592135} + m_LocalRotation: {x: 0, y: 1, z: 0, w: 0} + m_LocalPosition: {x: -17.492996, y: 24.925999, z: -15.206207} + m_LocalScale: {x: 2, y: 2, z: 2} + m_Children: [] + m_Father: {fileID: 193687608} + m_RootOrder: 3 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!195 &507592139 +NavMeshAgent: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 507592135} + m_Enabled: 1 + m_AgentTypeID: 0 + m_Radius: 0.6369026 + m_Speed: 10 + m_Acceleration: 10 + avoidancePriority: 50 + m_AngularSpeed: 1200 + m_StoppingDistance: 0 + m_AutoTraverseOffMeshLink: 1 + m_AutoBraking: 1 + m_AutoRepath: 1 + m_Height: 0.5024553 + m_BaseOffset: 0.25122765 + m_WalkableMask: 4294967295 + m_ObstacleAvoidanceType: 4 +--- !u!23 &507592140 +MeshRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 2300000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 507592135} + m_Enabled: 1 + m_CastShadows: 1 + m_ReceiveShadows: 1 + m_DynamicOccludee: 1 + m_MotionVectors: 1 + m_LightProbeUsage: 0 + m_ReflectionProbeUsage: 1 + m_RenderingLayerMask: 1 + m_RendererPriority: 0 + m_Materials: + - {fileID: 2100000, guid: fecc96c64c214ce40835ac4c3c3099e8, type: 2} + 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: 3 + m_MinimumChartSize: 4 + m_AutoUVMaxDistance: 0.5 + m_AutoUVMaxAngle: 89 + m_LightmapParameters: {fileID: 0} + m_SortingLayerID: 0 + m_SortingLayer: 0 + m_SortingOrder: 0 +--- !u!33 &507592141 +MeshFilter: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 3300000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 507592135} + m_Mesh: {fileID: 4300000, guid: 55e5ab7e66bd2eb49bc96935fe0bd04a, type: 3} +--- !u!1 &551555974 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 100000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 551555975} + - component: {fileID: 551555980} + - component: {fileID: 551555979} + - component: {fileID: 551555978} + m_Layer: 0 + m_Name: bot + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &551555975 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 400000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 551555974} + m_LocalRotation: {x: 0, y: 1, z: 0, w: 0} + m_LocalPosition: {x: -29.059395, y: 24.925999, z: 9.302292} + m_LocalScale: {x: 2, y: 2, z: 2} + m_Children: [] + m_Father: {fileID: 193687608} + m_RootOrder: 14 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!195 &551555978 +NavMeshAgent: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 551555974} + m_Enabled: 1 + m_AgentTypeID: 0 + m_Radius: 0.6369026 + m_Speed: 10 + m_Acceleration: 10 + avoidancePriority: 50 + m_AngularSpeed: 1200 + m_StoppingDistance: 0 + m_AutoTraverseOffMeshLink: 1 + m_AutoBraking: 1 + m_AutoRepath: 1 + m_Height: 0.5024553 + m_BaseOffset: 0.25122765 + m_WalkableMask: 4294967295 + m_ObstacleAvoidanceType: 4 +--- !u!23 &551555979 +MeshRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 2300000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 551555974} + m_Enabled: 1 + m_CastShadows: 1 + m_ReceiveShadows: 1 + m_DynamicOccludee: 1 + m_MotionVectors: 1 + m_LightProbeUsage: 0 + m_ReflectionProbeUsage: 1 + m_RenderingLayerMask: 1 + m_RendererPriority: 0 + m_Materials: + - {fileID: 2100000, guid: fecc96c64c214ce40835ac4c3c3099e8, type: 2} + 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: 3 + m_MinimumChartSize: 4 + m_AutoUVMaxDistance: 0.5 + m_AutoUVMaxAngle: 89 + m_LightmapParameters: {fileID: 0} + m_SortingLayerID: 0 + m_SortingLayer: 0 + m_SortingOrder: 0 +--- !u!33 &551555980 +MeshFilter: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 3300000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 551555974} + m_Mesh: {fileID: 4300000, guid: 55e5ab7e66bd2eb49bc96935fe0bd04a, type: 3} +--- !u!1 &561315484 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 100000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 561315485} + - component: {fileID: 561315490} + - component: {fileID: 561315489} + - component: {fileID: 561315488} + - component: {fileID: 561315487} + - component: {fileID: 561315486} + m_Layer: 0 + m_Name: bot + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &561315485 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 400000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 561315484} + m_LocalRotation: {x: 0, y: 1, z: 0, w: 0} + m_LocalPosition: {x: -29.059395, y: 24.925999, z: -8.605103} + m_LocalScale: {x: 2, y: 2, z: 2} + m_Children: [] + m_Father: {fileID: 193687608} + m_RootOrder: 21 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!82 &561315486 +AudioSource: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 561315484} + m_Enabled: 1 + serializedVersion: 4 + OutputAudioMixerGroup: {fileID: 0} + m_audioClip: {fileID: 0} + m_PlayOnAwake: 1 + m_Volume: 1 + m_Pitch: 1 + Loop: 0 + Mute: 0 + Spatialize: 0 + SpatializePostEffects: 0 + Priority: 128 + DopplerLevel: 1 + MinDistance: 1 + MaxDistance: 500 + Pan2D: 0 + rolloffMode: 0 + BypassEffects: 0 + BypassListenerEffects: 0 + BypassReverbZones: 0 + rolloffCustomCurve: + serializedVersion: 2 + m_Curve: + - serializedVersion: 3 + time: 0 + value: 1 + inSlope: 0 + outSlope: 0 + tangentMode: 0 + weightedMode: 0 + inWeight: 0.33333334 + outWeight: 0.33333334 + - serializedVersion: 3 + time: 1 + value: 0 + inSlope: 0 + outSlope: 0 + tangentMode: 0 + weightedMode: 0 + inWeight: 0.33333334 + outWeight: 0.33333334 + m_PreInfinity: 2 + m_PostInfinity: 2 + m_RotationOrder: 4 + panLevelCustomCurve: + serializedVersion: 2 + m_Curve: + - serializedVersion: 3 + time: 0 + value: 1 + inSlope: 0 + outSlope: 0 + tangentMode: 0 + weightedMode: 0 + inWeight: 0.33333334 + outWeight: 0.33333334 + m_PreInfinity: 2 + m_PostInfinity: 2 + m_RotationOrder: 4 + spreadCustomCurve: + serializedVersion: 2 + m_Curve: + - serializedVersion: 3 + time: 0 + value: 0 + inSlope: 0 + outSlope: 0 + tangentMode: 0 + weightedMode: 0 + inWeight: 0.33333334 + outWeight: 0.33333334 + m_PreInfinity: 2 + m_PostInfinity: 2 + m_RotationOrder: 4 + reverbZoneMixCustomCurve: + serializedVersion: 2 + m_Curve: + - serializedVersion: 3 + time: 0 + value: 1 + inSlope: 0 + outSlope: 0 + tangentMode: 0 + weightedMode: 0 + inWeight: 0.33333334 + outWeight: 0.33333334 + m_PreInfinity: 2 + m_PostInfinity: 2 + m_RotationOrder: 4 +--- !u!65 &561315487 +BoxCollider: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 561315484} + m_Material: {fileID: 0} + m_IsTrigger: 0 + m_Enabled: 1 + serializedVersion: 2 + m_Size: {x: 1.2738054, y: 0.6292588, z: 0.83338344} + m_Center: {x: -0.00000014901161, y: -0.06340176, z: 0.041081354} +--- !u!195 &561315488 +NavMeshAgent: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 561315484} + m_Enabled: 1 + m_AgentTypeID: 0 + m_Radius: 0.6369026 + m_Speed: 10 + m_Acceleration: 10 + avoidancePriority: 50 + m_AngularSpeed: 1200 + m_StoppingDistance: 0 + m_AutoTraverseOffMeshLink: 1 + m_AutoBraking: 1 + m_AutoRepath: 1 + m_Height: 0.5024553 + m_BaseOffset: 0.25122765 + m_WalkableMask: 4294967295 + m_ObstacleAvoidanceType: 4 +--- !u!23 &561315489 +MeshRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 2300000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 561315484} + m_Enabled: 1 + m_CastShadows: 1 + m_ReceiveShadows: 1 + m_DynamicOccludee: 1 + m_MotionVectors: 1 + m_LightProbeUsage: 0 + m_ReflectionProbeUsage: 1 + m_RenderingLayerMask: 1 + m_RendererPriority: 0 + m_Materials: + - {fileID: 2100000, guid: fecc96c64c214ce40835ac4c3c3099e8, type: 2} + 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: 3 + m_MinimumChartSize: 4 + m_AutoUVMaxDistance: 0.5 + m_AutoUVMaxAngle: 89 + m_LightmapParameters: {fileID: 0} + m_SortingLayerID: 0 + m_SortingLayer: 0 + m_SortingOrder: 0 +--- !u!33 &561315490 +MeshFilter: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 3300000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 561315484} + m_Mesh: {fileID: 4300000, guid: 55e5ab7e66bd2eb49bc96935fe0bd04a, type: 3} +--- !u!1 &605268259 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 605268264} + - component: {fileID: 605268263} + - component: {fileID: 605268261} + - component: {fileID: 605268260} + - component: {fileID: 605268265} + - component: {fileID: 605268266} + - component: {fileID: 605268267} + - component: {fileID: 605268268} + 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 &605268260 +AudioListener: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 605268259} + m_Enabled: 1 +--- !u!124 &605268261 +Behaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 605268259} + m_Enabled: 1 +--- !u!20 &605268263 +Camera: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 605268259} + m_Enabled: 1 + serializedVersion: 2 + m_ClearFlags: 1 + m_BackGroundColor: {r: 0, g: 0, b: 0, a: 0.019607844} + m_projectionMatrixMode: 1 + m_SensorSize: {x: 36, y: 24} + m_LensShift: {x: 0, y: 0} + m_GateFitMode: 2 + 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: 0 + orthographic size: 10 + m_Depth: -1 + m_CullingMask: + serializedVersion: 2 + m_Bits: 4294967295 + m_RenderingPath: -1 + m_TargetTexture: {fileID: 0} + m_TargetDisplay: 0 + m_TargetEye: 3 + m_HDR: 0 + m_AllowMSAA: 1 + m_AllowDynamicResolution: 0 + m_ForceIntoRT: 0 + m_OcclusionCulling: 1 + m_StereoConvergence: 10 + m_StereoSeparation: 0.022 +--- !u!4 &605268264 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 605268259} + m_LocalRotation: {x: 0.7071068, y: 0, z: 0, w: 0.7071068} + m_LocalPosition: {x: 0, y: 90, z: 0.0000047286167} + m_LocalScale: {x: 1, y: 1, z: 1} + m_Children: [] + m_Father: {fileID: 0} + m_RootOrder: 4 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!114 &605268265 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 605268259} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 536f005415e86134c98218681c66ba3c, type: 3} + m_Name: + m_EditorClassIdentifier: + marker: {fileID: 157415760} + mainBot: {fileID: 95806605} + flockGroup: {fileID: 193687607} + followGroup: {fileID: 66600217} + queueGroup: {fileID: 1151274298} + waypoints: + - {fileID: 1679165112} + - {fileID: 795308213} + - {fileID: 1577869803} + - {fileID: 86219747} + waypointsA: + - {fileID: 985012142} + - {fileID: 453012817} + - {fileID: 1114766221} + - {fileID: 1716371254} + descriptionGUISkin: {fileID: 11400000, guid: 36eff75c3a960b74bbd5999b301b60ca, type: 2} +--- !u!114 &605268266 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 605268259} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 8d7b55c7ecdb49a4a89fa5e6f9022861, type: 3} + m_Name: + m_EditorClassIdentifier: + startWhenEnabled: 0 + asynchronousLoad: 0 + pauseWhenDisabled: 0 + restartWhenComplete: 0 + logTaskChanges: 0 + group: 14 + resetValuesOnRestart: 0 + externalBehavior: {fileID: 0} + mBehaviorSource: + behaviorName: Flock + behaviorDescription: + mTaskData: + types: + - BehaviorDesigner.Runtime.Tasks.EntryTask + - BehaviorDesigner.Runtime.Tasks.Movement.Flock + parentIndex: ffffffff00000000 + startIndex: 000000000a000000 + variableStartIndex: + JSONSerialization: + fieldSerializationData: + typeName: [] + fieldNameHash: 7d6ed74f587d82e1cda3fdf0ab643ccee0f0d2677230fc9344a34c197c55199df179fb1af835a4a97d6ed74f587d82e1cda3fdf0ab643ccee0f0d2677230fc9344a34c197c55199df179fb1af835a4a9a28d1d821c6fce524f1e7d1ec5d30094dff9e47e59db954f8c8a441b0240c8909dbbb625179d67f64a4c16c2c0019a37a59cc8a11f7e7972522d283ec8e2abb3527e5c0bcc5f0ddcff0ebca775c43f1d78e72c17d834e34c5216941d85c542e97b8959129bd2c6a515b47776486326423e273d6b01e362ae7bc4137fae73c24aa437d973ff0c4b4f79eefb1fac9daaeba261c11476ed0cfdf0cebdcd237e6c99194283c294fa6b490edc1c1a418bcbe5374fe20e336340e1ad44f1b1e0f39f7dd6b7b6a629bd9f3fa39e5010d64dffdbcc111605d18865404b6a16117e19c5dc74dddb050c1de59d86fe956eb9ad443aaf715b633725ab82b1065c53e4b50a1fda79214860170d02daf8bdd20da86c9e036c83c7b8a7df0b328990dc65383fa85bfc55d1cbec38af45cee97f787d984b6e41af7489b18303039334d43642e39f2c06fac8126f60e18c5011b2bfffbf7db5c3d6a64d67314cc748e21cfaf790e8f0bba711c5a539e13f87eab17236997d68faafa65ba1a426d58255f7083204c3fef51aec898a0767036cb837361b67032cdf7d2c287d5b47a25e0c18d50dbbe3cbd1d10c5fcd2b29d9aedcf90c5e8bc50222a2ee89ae15770390c647363f75132c038c3ccd5eb43d4740650e7aef13da70b32a03e7584f30613a000194e9aecc8aadc5f5e9060edc63e8beac96976d788c5b84a1ea24fc3f6406ad1097b55bdc8d797205180cd5be92ed858fc59c345bbb604b84ede0aec367c25f949a710e609035258993d17d370db32e084062ddd33626f4fc1b2296b99503478ac8b2f5553e6879cb1959e99b933a9a6cc6e948383c9fccad + startIndex: 000000000100000002000000030000000400000005000000060000000700000008000000090000000a0000000b0000000c0000000d0000000e0000000f0000001000000011000000120000001300000014000000140000001500000016000000170000001700000018000000190000001a0000001a0000001b0000001c0000001d0000001d0000001e0000001f000000200000002000000021000000220000002300000024000000240000002500000026000000270000002700000028000000290000002a0000002a0000002b0000002c0000002d0000002d0000002e0000002f00000030000000300000003100000032000000330000003300000034000000350000003600000036000000370000003800000039000000390000003a0000003b0000003c0000003c0000003d0000003e0000003f0000003f000000400000004100000042000000420000004300000044000000450000004500000046000000470000004800000048000000490000004a0000004b0000004b0000004c0000004d0000004e0000004e0000004f000000500000005100000051000000520000005300000054000000540000005500000056000000570000005700000058000000590000005a0000005a0000005b0000005c0000005d0000005d0000005e0000005f00000060000000600000006100000062000000630000006300000064000000650000006600000066000000670000006800000069000000690000006a0000006b0000006c0000006c0000006d0000006e0000006f0000006f000000700000007100000072000000720000007300000074000000750000007500000076000000770000007800000078000000790000007a0000007b0000007b0000007c0000007d0000007e0000007e0000007f0000008000000081000000810000008200000083000000 + dataPosition: 0000000004000000090000000a0000000b00000013000000130000001400000015000000190000001d0000002100000026000000270000002800000030000000300000003100000032000000360000003a0000005e0000005e0000006200000086000000860000008a000000ae000000ae000000b2000000d6000000d6000000da000000fe000000fe00000002010000060100002f0100002f010000330100005c0100005c0100006001000089010000890100008d010000b6010000b6010000ba010000e3010000e3010000e70100001002000010020000140200003d0200003d020000410200006a0200006a0200006e02000097020000970200009b020000c4020000c4020000c8020000f1020000f1020000f50200001e0300001e030000220300004b0300004b0300004f03000078030000780300007c030000a5030000a5030000a9030000d2030000d2030000d6030000ff030000ff030000030400002c0400002c0400003004000059040000590400005d04000086040000860400008a040000b3040000b3040000b7040000e0040000e0040000e40400000d0500000d050000110500003a0500003a0500003e05000067050000670500006b050000940500009405000098050000c1050000c1050000c5050000ee050000ee050000f20500001b0600001b0600001f06000048060000480600004c0600007006000070060000740600009806000098060000 + unityObjects: + - {fileID: 1111038048} + - {fileID: 1350099621} + - {fileID: 650647371} + - {fileID: 507592135} + - {fileID: 211670238} + - {fileID: 346640} + - {fileID: 1399255297} + - {fileID: 1252079133} + - {fileID: 1726546186} + - {fileID: 862954241} + - {fileID: 366180964} + - {fileID: 1041788009} + - {fileID: 1948759273} + - {fileID: 1031935888} + - {fileID: 551555974} + - {fileID: 1674801248} + - {fileID: 2104181165} + - {fileID: 1014823307} + - {fileID: 1151094525} + - {fileID: 2133735853} + - {fileID: 1518382618} + - {fileID: 561315484} + - {fileID: 1205913526} + - {fileID: 1394933339} + - {fileID: 1111626858} + - {fileID: 34840226} + - {fileID: 2071294760} + - {fileID: 1158265377} + - {fileID: 80592862} + - {fileID: 1125071874} + byteData: 00000000456e747279010000000000000000000000000000000000000001000000466c6f636b0100000000000000d842000000000000000000004265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f6174000048424265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f6174000048424265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f61743333333f4265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f6174cdcc0c3f4265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f6174cdcccc3e1e0000004265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a656374000000004265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a656374010000004265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a656374020000004265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a656374030000004265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a656374040000004265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a656374050000004265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a656374060000004265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a656374070000004265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a656374080000004265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a656374090000004265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a6563740a0000004265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a6563740b0000004265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a6563740c0000004265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a6563740d0000004265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a6563740e0000004265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a6563740f0000004265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a656374100000004265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a656374110000004265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a656374120000004265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a656374130000004265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a656374140000004265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a656374150000004265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a656374160000004265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a656374170000004265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a656374180000004265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a656374190000004265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a6563741a0000004265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a6563741b0000004265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a6563741c0000004265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a6563741d0000004265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f6174000020414265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f617400009644 + byteDataArray: 00000000456e747279010000000000000000000000000000000000000001000000466c6f636b0100000000000000d842000000000000000000004265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f6174000048424265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f6174000048424265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f61743333333f4265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f6174cdcc0c3f4265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f6174cdcccc3e1e0000004265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a656374000000004265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a656374010000004265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a656374020000004265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a656374030000004265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a656374040000004265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a656374050000004265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a656374060000004265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a656374070000004265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a656374080000004265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a656374090000004265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a6563740a0000004265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a6563740b0000004265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a6563740c0000004265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a6563740d0000004265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a6563740e0000004265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a6563740f0000004265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a656374100000004265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a656374110000004265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a656374120000004265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a656374130000004265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a656374140000004265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a656374150000004265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a656374160000004265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a656374170000004265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a656374180000004265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a656374190000004265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a6563741a0000004265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a6563741b0000004265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a6563741c0000004265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a6563741d0000004265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f6174000020414265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f617400009644 + Version: 1.5.10 + gizmoViewMode: 2 + showBehaviorDesignerGizmo: 1 + unitTestResult: {fileID: 0} +--- !u!114 &605268267 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 605268259} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 8d7b55c7ecdb49a4a89fa5e6f9022861, type: 3} + m_Name: + m_EditorClassIdentifier: + startWhenEnabled: 0 + asynchronousLoad: 0 + pauseWhenDisabled: 0 + restartWhenComplete: 0 + logTaskChanges: 0 + group: 15 + resetValuesOnRestart: 0 + externalBehavior: {fileID: 0} + mBehaviorSource: + behaviorName: Leader Follow + behaviorDescription: + mTaskData: + types: + - BehaviorDesigner.Runtime.Tasks.EntryTask + - BehaviorDesigner.Runtime.Tasks.Movement.LeaderFollow + parentIndex: ffffffff00000000 + startIndex: 000000000a000000 + variableStartIndex: + JSONSerialization: + fieldSerializationData: + typeName: [] + fieldNameHash: 7d6ed74f587d82e1cda3fdf0ab643ccee0f0d2677230fc9344a34c197c55199df179fb1af835a4a97d6ed74f587d82e1cda3fdf0ab643ccee0f0d2677230fc9344a34c197c55199df179fb1af835a4a9a28d1d821c6fce524f1e7d1ec5d30094d403e9c34ee5999481944860f749ccd57850dc32f2318d0325e13bcf9b96bf44c8781fad425ad07d75097f49ebbe02bf5c5470f6d63521c709e5cf92ffa8e6bb78e72c17d834e34c5216941d85c542e97b8959129bd2c6a515b47776486326423e273d6b01e362ae7bc4137fae73c24aa437d973ff0c4b4f79eefb1fac9daaeba261c11476ed0cfdf0cebdcd237e6c99194283c294fa6b490edc1c1a418bcbe5374fe20e336340e1ad44f1b1e0f39f7dd6b7b6a629bd9f3fa39e5010d64dffdbcc111605d18865404b6a16117e19c5dc74dddb050c1de59d86fe956eb9ad443aaf715b633725ab82b1065c53e4b50a1fda7921481b2296b99503478ac8b2f5553e6879cb1959e99b933a9a6cc6e948383c9fccad + startIndex: 000000000100000002000000030000000400000005000000060000000700000008000000090000000a0000000b0000000c0000000d0000000e0000000f0000001000000011000000120000001300000014000000140000001500000016000000170000001700000018000000190000001a0000001a0000001b0000001c0000001d0000001d0000001e0000001f000000200000002000000021000000220000002300000024000000240000002500000026000000270000002700000028000000290000002a0000002a0000002b0000002c0000002d0000002d0000002e0000002f00000030000000300000003100000032000000330000003300000034000000350000003600000036000000370000003800000039000000390000003a0000003b0000003c0000003c0000003d0000003e0000003f0000003f000000400000004100000042000000420000004300000044000000450000004500000046000000470000004800000048000000490000004a000000 + dataPosition: 0000000004000000090000000a0000000b00000013000000130000001400000015000000190000001d000000210000002e0000002f000000300000003800000038000000390000003a0000003e0000004200000066000000660000006a0000008e0000008e00000092000000b6000000b6000000ba000000de000000de000000e20000000b0100000b0100000f010000130100003c0100003c0100004001000069010000690100006d01000096010000960100009a010000c3010000c3010000c7010000f0010000f0010000f40100001d0200001d020000210200004a0200004a0200004e02000077020000770200007b020000a4020000a4020000a8020000d1020000d1020000d5020000fe020000fe0200000203000026030000260300002a0300004e0300004e030000 + unityObjects: + - {fileID: 95806605} + - {fileID: 1277433085} + - {fileID: 1833674480} + - {fileID: 1881403408} + - {fileID: 91496926} + - {fileID: 671785510} + - {fileID: 251429379} + - {fileID: 933433859} + - {fileID: 2046246928} + - {fileID: 1412844391} + - {fileID: 1903416401} + - {fileID: 158913356} + byteData: 00000000456e7472790100000000000000000000000000000000000000010000004c656164657220466f6c6c6f77010080993940cdccd542000000000000000000004265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f61740000a0404265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f6174000000404265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f6174000000404265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f6174000000404265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a656374000000000b0000004265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a656374010000004265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a656374020000004265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a656374030000004265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a656374040000004265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a656374050000004265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a656374060000004265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a656374070000004265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a656374080000004265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a656374090000004265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a6563740a0000004265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a6563740b0000004265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f6174000020414265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f617400009644 + byteDataArray: 00000000456e7472790100000000000000000000000000000000000000010000004c656164657220466f6c6c6f77010080993940cdccd542000000000000000000004265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f61740000a0404265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f6174000000404265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f6174000000404265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f6174000000404265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a656374000000000b0000004265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a656374010000004265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a656374020000004265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a656374030000004265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a656374040000004265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a656374050000004265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a656374060000004265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a656374070000004265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a656374080000004265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a656374090000004265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a6563740a0000004265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a6563740b0000004265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f6174000020414265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f617400009644 + Version: 1.5.10 + gizmoViewMode: 2 + showBehaviorDesignerGizmo: 1 + unitTestResult: {fileID: 0} +--- !u!114 &605268268 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 605268259} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 8d7b55c7ecdb49a4a89fa5e6f9022861, type: 3} + m_Name: + m_EditorClassIdentifier: + startWhenEnabled: 0 + asynchronousLoad: 0 + pauseWhenDisabled: 0 + restartWhenComplete: 0 + logTaskChanges: 0 + group: 16 + resetValuesOnRestart: 0 + externalBehavior: {fileID: 0} + mBehaviorSource: + behaviorName: Queue + behaviorDescription: + mTaskData: + types: + - BehaviorDesigner.Runtime.Tasks.EntryTask + - BehaviorDesigner.Runtime.Tasks.Movement.Queue + parentIndex: ffffffff00000000 + startIndex: 000000000a000000 + variableStartIndex: + JSONSerialization: + fieldSerializationData: + typeName: [] + fieldNameHash: 7d6ed74f587d82e1cda3fdf0ab643ccee0f0d2677230fc9344a34c197c55199df179fb1af835a4a97d6ed74f587d82e1cda3fdf0ab643ccee0f0d2677230fc9344a34c197c55199df179fb1af835a4a9a28d1d821c6fce524f1e7d1ec5d300947850dc32f2318d0325e13bcf9b96bf44f0e9cc866acb7d579d7a2c231330b09836eb68e9b0cc19bae37bc88559314cfb70bca1efea9d52c01d4d018c93028501b87e514832600219650fb1e45bd3c70d78e72c17d834e34c5216941d85c542e97b8959129bd2c6a515b47776486326423e273d6b01e362ae7bc4137fae73c24aa437d973ff0c4b4f79eefb1fac9daaeba261c11476ed0cfdf0cebdcd237e6c99194283c294fa6b490edc1c1a418bcbe5374fe20e336340e1ad44f1b1e0f39f7dd6b7b6a629bd9f3fa39e5010d64dffdbcc111605d18865404b6a16117e19c5dc74dddb050c1de59d86fe956eb9ad443aaf715b633725ab82b1065c53e4b50a1fda7921481b2296b99503478ac8b2f5553e6879cb1959e99b933a9a6cc6e948383c9fccad + startIndex: 000000000100000002000000030000000400000005000000060000000700000008000000090000000a0000000b0000000c0000000d0000000e0000000f0000001000000011000000120000001300000014000000140000001500000016000000170000001700000018000000190000001a0000001a0000001b0000001c0000001d0000001d0000001e0000001f000000200000002000000021000000220000002300000023000000240000002500000026000000270000002700000028000000290000002a0000002a0000002b0000002c0000002d0000002d0000002e0000002f00000030000000300000003100000032000000330000003300000034000000350000003600000036000000370000003800000039000000390000003a0000003b0000003c0000003c0000003d0000003e0000003f0000003f000000400000004100000042000000420000004300000044000000450000004500000046000000470000004800000048000000490000004a0000004b0000004b0000004c0000004d000000 + dataPosition: 0000000004000000090000000a0000000b00000013000000130000001400000015000000190000001d0000002100000026000000270000002800000030000000300000003100000032000000360000003a0000005e0000005e0000006200000086000000860000008a000000ae000000ae000000b2000000d6000000d6000000da000000fe000000fe000000020100002b0100002b0100002f010000330100005c0100005c0100006001000089010000890100008d010000b6010000b6010000ba010000e3010000e3010000e70100001002000010020000140200003d0200003d020000410200006a0200006a0200006e02000097020000970200009b020000c4020000c4020000c8020000f1020000f1020000f50200001e0300001e0300002203000046030000460300004a0300006e0300006e030000 + unityObjects: + - {fileID: 157415760} + - {fileID: 1449224517} + - {fileID: 669865893} + - {fileID: 1914965757} + - {fileID: 1099702921} + - {fileID: 819671357} + - {fileID: 1792926649} + - {fileID: 823926550} + - {fileID: 899603636} + - {fileID: 2110132575} + - {fileID: 1487380454} + - {fileID: 363215076} + byteData: 00000000456e7472790100000000000000000000000000000000000000010000005175657565010000cd8cbfcdccd542000000000000000000004265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f61740000803f4265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f61740000803f4265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f61740000803f4265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f61740000a0414265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f61747b142e3e4265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a656374000000000b0000004265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a656374010000004265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a656374020000004265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a656374030000004265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a656374040000004265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a656374050000004265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a656374060000004265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a656374070000004265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a656374080000004265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a656374090000004265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a6563740a0000004265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a6563740b0000004265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f6174000020414265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f617400009644 + byteDataArray: 00000000456e7472790100000000000000000000000000000000000000010000005175657565010000cd8cbfcdccd542000000000000000000004265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f61740000803f4265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f61740000803f4265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f61740000803f4265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f61740000a0414265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f61747b142e3e4265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a656374000000000b0000004265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a656374010000004265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a656374020000004265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a656374030000004265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a656374040000004265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a656374050000004265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a656374060000004265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a656374070000004265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a656374080000004265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a656374090000004265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a6563740a0000004265686176696f7244657369676e65722e52756e74696d652e53686172656447616d654f626a6563740b0000004265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f6174000020414265686176696f7244657369676e65722e52756e74696d652e536861726564466c6f617400009644 + Version: 1.5.10 + gizmoViewMode: 2 + showBehaviorDesignerGizmo: 1 + unitTestResult: {fileID: 0} +--- !u!1 &616612086 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 616612090} + - component: {fileID: 616612089} + - component: {fileID: 616612088} + - component: {fileID: 616612087} + m_Layer: 2 + m_Name: Cube + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 4294967295 + m_IsActive: 1 +--- !u!23 &616612087 +MeshRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 616612086} + m_Enabled: 1 + m_CastShadows: 1 + m_ReceiveShadows: 1 + m_DynamicOccludee: 1 + m_MotionVectors: 1 + m_LightProbeUsage: 0 + m_ReflectionProbeUsage: 1 + m_RenderingLayerMask: 1 + m_RendererPriority: 0 + m_Materials: + - {fileID: 2100000, guid: a08f97e5b75379d40b08ff5f74847d5c, type: 2} + 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: 3 + m_MinimumChartSize: 4 + m_AutoUVMaxDistance: 0.5 + m_AutoUVMaxAngle: 89 + m_LightmapParameters: {fileID: 0} + m_SortingLayerID: 0 + m_SortingLayer: 0 + m_SortingOrder: 0 +--- !u!65 &616612088 +BoxCollider: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 616612086} + m_Material: {fileID: 0} + m_IsTrigger: 0 + m_Enabled: 1 + serializedVersion: 2 + m_Size: {x: 1, y: 1, z: 1} + m_Center: {x: 0, y: 0, z: 0} +--- !u!33 &616612089 +MeshFilter: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 616612086} + m_Mesh: {fileID: 10202, guid: 0000000000000000e000000000000000, type: 0} +--- !u!4 &616612090 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 616612086} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: 0, y: 1.5, z: -50} + m_LocalScale: {x: 100, y: 3, z: 2} + m_Children: [] + m_Father: {fileID: 122009232} + m_RootOrder: 6 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!1 &638693643 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 638693647} + - component: {fileID: 638693646} + - component: {fileID: 638693645} + - component: {fileID: 638693644} + m_Layer: 2 + m_Name: Plane + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 4294967295 + m_IsActive: 1 +--- !u!23 &638693644 +MeshRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 638693643} + m_Enabled: 1 + m_CastShadows: 1 + m_ReceiveShadows: 1 + m_DynamicOccludee: 1 + m_MotionVectors: 1 + m_LightProbeUsage: 0 + m_ReflectionProbeUsage: 1 + m_RenderingLayerMask: 1 + m_RendererPriority: 0 + m_Materials: + - {fileID: 2100000, guid: dbcdee902c373ec4cbb9e693617708b9, type: 2} + 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: 3 + m_MinimumChartSize: 4 + m_AutoUVMaxDistance: 0.5 + m_AutoUVMaxAngle: 89 + m_LightmapParameters: {fileID: 0} + m_SortingLayerID: 0 + m_SortingLayer: 0 + m_SortingOrder: 0 +--- !u!64 &638693645 +MeshCollider: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 638693643} + m_Material: {fileID: 0} + m_IsTrigger: 0 + m_Enabled: 1 + serializedVersion: 3 + m_Convex: 0 + m_CookingOptions: 14 + m_Mesh: {fileID: 10209, guid: 0000000000000000e000000000000000, type: 0} +--- !u!33 &638693646 +MeshFilter: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 638693643} + m_Mesh: {fileID: 10209, guid: 0000000000000000e000000000000000, type: 0} +--- !u!4 &638693647 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 638693643} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: 0, y: 0, z: 0} + m_LocalScale: {x: 10, y: 1, z: 10} + m_Children: [] + m_Father: {fileID: 122009232} + m_RootOrder: 11 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!1 &650647371 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 100000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 650647372} + - component: {fileID: 650647375} + - component: {fileID: 650647374} + - component: {fileID: 650647373} + m_Layer: 0 + m_Name: bot + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &650647372 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 400000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 650647371} + m_LocalRotation: {x: 0, y: 1, z: 0, w: 0} + m_LocalPosition: {x: -9.986802, y: 24.925999, z: -8.500595} + m_LocalScale: {x: 2, y: 2, z: 2} + m_Children: [] + m_Father: {fileID: 193687608} + m_RootOrder: 2 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!195 &650647373 +NavMeshAgent: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 650647371} + m_Enabled: 1 + m_AgentTypeID: 0 + m_Radius: 0.6369026 + m_Speed: 10 + m_Acceleration: 10 + avoidancePriority: 50 + m_AngularSpeed: 1200 + m_StoppingDistance: 0 + m_AutoTraverseOffMeshLink: 1 + m_AutoBraking: 1 + m_AutoRepath: 1 + m_Height: 0.5024553 + m_BaseOffset: 0.25122765 + m_WalkableMask: 4294967295 + m_ObstacleAvoidanceType: 4 +--- !u!23 &650647374 +MeshRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 2300000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 650647371} + m_Enabled: 1 + m_CastShadows: 1 + m_ReceiveShadows: 1 + m_DynamicOccludee: 1 + m_MotionVectors: 1 + m_LightProbeUsage: 0 + m_ReflectionProbeUsage: 1 + m_RenderingLayerMask: 1 + m_RendererPriority: 0 + m_Materials: + - {fileID: 2100000, guid: fecc96c64c214ce40835ac4c3c3099e8, type: 2} + 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: 3 + m_MinimumChartSize: 4 + m_AutoUVMaxDistance: 0.5 + m_AutoUVMaxAngle: 89 + m_LightmapParameters: {fileID: 0} + m_SortingLayerID: 0 + m_SortingLayer: 0 + m_SortingOrder: 0 +--- !u!33 &650647375 +MeshFilter: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 3300000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 650647371} + m_Mesh: {fileID: 4300000, guid: 55e5ab7e66bd2eb49bc96935fe0bd04a, type: 3} +--- !u!1 &669865893 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 100000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 669865894} + - component: {fileID: 669865899} + - component: {fileID: 669865898} + - component: {fileID: 669865897} + - component: {fileID: 669865896} + - component: {fileID: 669865895} + m_Layer: 0 + m_Name: bot + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &669865894 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 400000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 669865893} + m_LocalRotation: {x: 0, y: 1, z: 0, w: 0} + m_LocalPosition: {x: -16.450172, y: 24.925999, z: 15.903397} + m_LocalScale: {x: 2, y: 2, z: 2} + m_Children: [] + m_Father: {fileID: 1151274299} + m_RootOrder: 1 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!82 &669865895 +AudioSource: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 669865893} + m_Enabled: 1 + serializedVersion: 4 + OutputAudioMixerGroup: {fileID: 0} + m_audioClip: {fileID: 0} + m_PlayOnAwake: 1 + m_Volume: 1 + m_Pitch: 1 + Loop: 0 + Mute: 0 + Spatialize: 0 + SpatializePostEffects: 0 + Priority: 128 + DopplerLevel: 1 + MinDistance: 1 + MaxDistance: 500 + Pan2D: 0 + rolloffMode: 0 + BypassEffects: 0 + BypassListenerEffects: 0 + BypassReverbZones: 0 + rolloffCustomCurve: + serializedVersion: 2 + m_Curve: + - serializedVersion: 3 + time: 0 + value: 1 + inSlope: 0 + outSlope: 0 + tangentMode: 0 + weightedMode: 0 + inWeight: 0.33333334 + outWeight: 0.33333334 + - serializedVersion: 3 + time: 1 + value: 0 + inSlope: 0 + outSlope: 0 + tangentMode: 0 + weightedMode: 0 + inWeight: 0.33333334 + outWeight: 0.33333334 + m_PreInfinity: 2 + m_PostInfinity: 2 + m_RotationOrder: 4 + panLevelCustomCurve: + serializedVersion: 2 + m_Curve: + - serializedVersion: 3 + time: 0 + value: 1 + inSlope: 0 + outSlope: 0 + tangentMode: 0 + weightedMode: 0 + inWeight: 0.33333334 + outWeight: 0.33333334 + m_PreInfinity: 2 + m_PostInfinity: 2 + m_RotationOrder: 4 + spreadCustomCurve: + serializedVersion: 2 + m_Curve: + - serializedVersion: 3 + time: 0 + value: 0 + inSlope: 0 + outSlope: 0 + tangentMode: 0 + weightedMode: 0 + inWeight: 0.33333334 + outWeight: 0.33333334 + m_PreInfinity: 2 + m_PostInfinity: 2 + m_RotationOrder: 4 + reverbZoneMixCustomCurve: + serializedVersion: 2 + m_Curve: + - serializedVersion: 3 + time: 0 + value: 1 + inSlope: 0 + outSlope: 0 + tangentMode: 0 + weightedMode: 0 + inWeight: 0.33333334 + outWeight: 0.33333334 + m_PreInfinity: 2 + m_PostInfinity: 2 + m_RotationOrder: 4 +--- !u!65 &669865896 +BoxCollider: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 669865893} + m_Material: {fileID: 0} + m_IsTrigger: 0 + m_Enabled: 1 + serializedVersion: 2 + m_Size: {x: 1.2738054, y: 0.6292588, z: 0.83338344} + m_Center: {x: -0.00000014901161, y: -0.06340176, z: 0.041081354} +--- !u!195 &669865897 +NavMeshAgent: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 669865893} + m_Enabled: 1 + m_AgentTypeID: 0 + m_Radius: 0.6369026 + m_Speed: 10 + m_Acceleration: 8 + avoidancePriority: 50 + m_AngularSpeed: 1200 + m_StoppingDistance: 0 + m_AutoTraverseOffMeshLink: 1 + m_AutoBraking: 1 + m_AutoRepath: 1 + m_Height: 0.5024553 + m_BaseOffset: 0.25122765 + m_WalkableMask: 4294967295 + m_ObstacleAvoidanceType: 4 +--- !u!23 &669865898 +MeshRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 2300000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 669865893} + m_Enabled: 1 + m_CastShadows: 1 + m_ReceiveShadows: 1 + m_DynamicOccludee: 1 + m_MotionVectors: 1 + m_LightProbeUsage: 0 + m_ReflectionProbeUsage: 1 + m_RenderingLayerMask: 1 + m_RendererPriority: 0 + m_Materials: + - {fileID: 2100000, guid: fecc96c64c214ce40835ac4c3c3099e8, type: 2} + 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: 3 + m_MinimumChartSize: 4 + m_AutoUVMaxDistance: 0.5 + m_AutoUVMaxAngle: 89 + m_LightmapParameters: {fileID: 0} + m_SortingLayerID: 0 + m_SortingLayer: 0 + m_SortingOrder: 0 +--- !u!33 &669865899 +MeshFilter: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 3300000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 669865893} + m_Mesh: {fileID: 4300000, guid: 55e5ab7e66bd2eb49bc96935fe0bd04a, type: 3} +--- !u!1 &671785510 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 100000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 671785511} + - component: {fileID: 671785514} + - component: {fileID: 671785513} + - component: {fileID: 671785512} + m_Layer: 0 + m_Name: bot + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &671785511 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 400000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 671785510} + m_LocalRotation: {x: 0, y: 1, z: 0, w: 0} + m_LocalPosition: {x: -21.553186, y: 24.925999, z: 9.82312} + m_LocalScale: {x: 2, y: 2, z: 2} + m_Children: [] + m_Father: {fileID: 66600218} + m_RootOrder: 4 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!195 &671785512 +NavMeshAgent: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 671785510} + m_Enabled: 1 + m_AgentTypeID: 0 + m_Radius: 0.6369026 + m_Speed: 15 + m_Acceleration: 15 + avoidancePriority: 50 + m_AngularSpeed: 1200 + m_StoppingDistance: 0 + m_AutoTraverseOffMeshLink: 1 + m_AutoBraking: 1 + m_AutoRepath: 1 + m_Height: 0.5024553 + m_BaseOffset: 0.25122765 + m_WalkableMask: 4294967295 + m_ObstacleAvoidanceType: 4 +--- !u!23 &671785513 +MeshRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 2300000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 671785510} + m_Enabled: 1 + m_CastShadows: 1 + m_ReceiveShadows: 1 + m_DynamicOccludee: 1 + m_MotionVectors: 1 + m_LightProbeUsage: 0 + m_ReflectionProbeUsage: 1 + m_RenderingLayerMask: 1 + m_RendererPriority: 0 + m_Materials: + - {fileID: 2100000, guid: fecc96c64c214ce40835ac4c3c3099e8, type: 2} + 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: 3 + m_MinimumChartSize: 4 + m_AutoUVMaxDistance: 0.5 + m_AutoUVMaxAngle: 89 + m_LightmapParameters: {fileID: 0} + m_SortingLayerID: 0 + m_SortingLayer: 0 + m_SortingOrder: 0 +--- !u!33 &671785514 +MeshFilter: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 3300000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 671785510} + m_Mesh: {fileID: 4300000, guid: 55e5ab7e66bd2eb49bc96935fe0bd04a, type: 3} +--- !u!1 &795308213 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 795308214} + - component: {fileID: 795308215} + - component: {fileID: 795308216} + m_Layer: 0 + m_Name: 2 + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &795308214 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 795308213} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: 40, y: 0, z: -40} + m_LocalScale: {x: 1, y: 1, z: 1} + m_Children: [] + m_Father: {fileID: 1867949263} + m_RootOrder: 2 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!33 &795308215 +MeshFilter: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 795308213} + m_Mesh: {fileID: 10207, guid: 0000000000000000e000000000000000, type: 0} +--- !u!23 &795308216 +MeshRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 795308213} + m_Enabled: 1 + m_CastShadows: 1 + m_ReceiveShadows: 1 + m_DynamicOccludee: 1 + m_MotionVectors: 1 + m_LightProbeUsage: 0 + m_ReflectionProbeUsage: 1 + m_RenderingLayerMask: 1 + m_RendererPriority: 0 + m_Materials: + - {fileID: 10302, 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: 3 + m_MinimumChartSize: 4 + m_AutoUVMaxDistance: 0.5 + m_AutoUVMaxAngle: 89 + m_LightmapParameters: {fileID: 0} + m_SortingLayerID: 0 + m_SortingLayer: 0 + m_SortingOrder: 0 +--- !u!1 &819671357 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 100000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 819671358} + - component: {fileID: 819671361} + - component: {fileID: 819671360} + - component: {fileID: 819671359} + m_Layer: 0 + m_Name: bot + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &819671358 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 400000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 819671357} + m_LocalRotation: {x: 0, y: 1, z: 0, w: 0} + m_LocalPosition: {x: -15.76404, y: 24.925999, z: 9.82312} + m_LocalScale: {x: 2, y: 2, z: 2} + m_Children: [] + m_Father: {fileID: 1151274299} + m_RootOrder: 4 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!195 &819671359 +NavMeshAgent: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 819671357} + m_Enabled: 1 + m_AgentTypeID: 0 + m_Radius: 0.6369026 + m_Speed: 10 + m_Acceleration: 8 + avoidancePriority: 50 + m_AngularSpeed: 1200 + m_StoppingDistance: 0 + m_AutoTraverseOffMeshLink: 1 + m_AutoBraking: 1 + m_AutoRepath: 1 + m_Height: 0.5024553 + m_BaseOffset: 0.25122765 + m_WalkableMask: 4294967295 + m_ObstacleAvoidanceType: 4 +--- !u!23 &819671360 +MeshRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 2300000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 819671357} + m_Enabled: 1 + m_CastShadows: 1 + m_ReceiveShadows: 1 + m_DynamicOccludee: 1 + m_MotionVectors: 1 + m_LightProbeUsage: 0 + m_ReflectionProbeUsage: 1 + m_RenderingLayerMask: 1 + m_RendererPriority: 0 + m_Materials: + - {fileID: 2100000, guid: fecc96c64c214ce40835ac4c3c3099e8, type: 2} + 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: 3 + m_MinimumChartSize: 4 + m_AutoUVMaxDistance: 0.5 + m_AutoUVMaxAngle: 89 + m_LightmapParameters: {fileID: 0} + m_SortingLayerID: 0 + m_SortingLayer: 0 + m_SortingOrder: 0 +--- !u!33 &819671361 +MeshFilter: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 3300000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 819671357} + m_Mesh: {fileID: 4300000, guid: 55e5ab7e66bd2eb49bc96935fe0bd04a, type: 3} +--- !u!1 &823926550 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 100000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 823926551} + - component: {fileID: 823926556} + - component: {fileID: 823926555} + - component: {fileID: 823926554} + m_Layer: 0 + m_Name: bot + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &823926551 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 400000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 823926550} + m_LocalRotation: {x: 0, y: 1, z: 0, w: 0} + m_LocalPosition: {x: -13.446144, y: 24.925999, z: -15.206207} + m_LocalScale: {x: 2, y: 2, z: 2} + m_Children: [] + m_Father: {fileID: 1151274299} + m_RootOrder: 6 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!195 &823926554 +NavMeshAgent: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 823926550} + m_Enabled: 1 + m_AgentTypeID: 0 + m_Radius: 0.6369026 + m_Speed: 10 + m_Acceleration: 8 + avoidancePriority: 50 + m_AngularSpeed: 1200 + m_StoppingDistance: 0 + m_AutoTraverseOffMeshLink: 1 + m_AutoBraking: 1 + m_AutoRepath: 1 + m_Height: 0.5024553 + m_BaseOffset: 0.25122765 + m_WalkableMask: 4294967295 + m_ObstacleAvoidanceType: 4 +--- !u!23 &823926555 +MeshRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 2300000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 823926550} + m_Enabled: 1 + m_CastShadows: 1 + m_ReceiveShadows: 1 + m_DynamicOccludee: 1 + m_MotionVectors: 1 + m_LightProbeUsage: 0 + m_ReflectionProbeUsage: 1 + m_RenderingLayerMask: 1 + m_RendererPriority: 0 + m_Materials: + - {fileID: 2100000, guid: fecc96c64c214ce40835ac4c3c3099e8, type: 2} + 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: 3 + m_MinimumChartSize: 4 + m_AutoUVMaxDistance: 0.5 + m_AutoUVMaxAngle: 89 + m_LightmapParameters: {fileID: 0} + m_SortingLayerID: 0 + m_SortingLayer: 0 + m_SortingOrder: 0 +--- !u!33 &823926556 +MeshFilter: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 3300000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 823926550} + m_Mesh: {fileID: 4300000, guid: 55e5ab7e66bd2eb49bc96935fe0bd04a, type: 3} +--- !u!1 &862954241 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 100000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 862954242} + - component: {fileID: 862954245} + - component: {fileID: 862954244} + - component: {fileID: 862954243} + m_Layer: 0 + m_Name: bot + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &862954242 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 400000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 862954241} + m_LocalRotation: {x: 0, y: 1, z: 0, w: 0} + m_LocalPosition: {x: -21.553186, y: 24.925999, z: 16.007904} + m_LocalScale: {x: 2, y: 2, z: 2} + m_Children: [] + m_Father: {fileID: 193687608} + m_RootOrder: 9 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!195 &862954243 +NavMeshAgent: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 862954241} + m_Enabled: 1 + m_AgentTypeID: 0 + m_Radius: 0.6369026 + m_Speed: 10 + m_Acceleration: 10 + avoidancePriority: 50 + m_AngularSpeed: 1200 + m_StoppingDistance: 0 + m_AutoTraverseOffMeshLink: 1 + m_AutoBraking: 1 + m_AutoRepath: 1 + m_Height: 0.5024553 + m_BaseOffset: 0.25122765 + m_WalkableMask: 4294967295 + m_ObstacleAvoidanceType: 4 +--- !u!23 &862954244 +MeshRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 2300000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 862954241} + m_Enabled: 1 + m_CastShadows: 1 + m_ReceiveShadows: 1 + m_DynamicOccludee: 1 + m_MotionVectors: 1 + m_LightProbeUsage: 0 + m_ReflectionProbeUsage: 1 + m_RenderingLayerMask: 1 + m_RendererPriority: 0 + m_Materials: + - {fileID: 2100000, guid: fecc96c64c214ce40835ac4c3c3099e8, type: 2} + 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: 3 + m_MinimumChartSize: 4 + m_AutoUVMaxDistance: 0.5 + m_AutoUVMaxAngle: 89 + m_LightmapParameters: {fileID: 0} + m_SortingLayerID: 0 + m_SortingLayer: 0 + m_SortingOrder: 0 +--- !u!33 &862954245 +MeshFilter: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 3300000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 862954241} + m_Mesh: {fileID: 4300000, guid: 55e5ab7e66bd2eb49bc96935fe0bd04a, type: 3} +--- !u!1 &899603636 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 100000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 899603637} + - component: {fileID: 899603642} + - component: {fileID: 899603641} + - component: {fileID: 899603640} + m_Layer: 0 + m_Name: bot + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &899603637 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 400000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 899603636} + m_LocalRotation: {x: 6.123233e-17, y: 1, z: 6.123233e-17, w: 0.00000013315805} + m_LocalPosition: {x: -15.693109, y: 24.925999, z: 5.962839} + m_LocalScale: {x: 2, y: 2, z: 2} + m_Children: [] + m_Father: {fileID: 1151274299} + m_RootOrder: 7 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!195 &899603640 +NavMeshAgent: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 899603636} + m_Enabled: 1 + m_AgentTypeID: 0 + m_Radius: 0.6369026 + m_Speed: 10 + m_Acceleration: 8 + avoidancePriority: 50 + m_AngularSpeed: 1200 + m_StoppingDistance: 0 + m_AutoTraverseOffMeshLink: 1 + m_AutoBraking: 1 + m_AutoRepath: 1 + m_Height: 0.5024553 + m_BaseOffset: 0.25122765 + m_WalkableMask: 4294967295 + m_ObstacleAvoidanceType: 4 +--- !u!23 &899603641 +MeshRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 2300000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 899603636} + m_Enabled: 1 + m_CastShadows: 1 + m_ReceiveShadows: 1 + m_DynamicOccludee: 1 + m_MotionVectors: 1 + m_LightProbeUsage: 0 + m_ReflectionProbeUsage: 1 + m_RenderingLayerMask: 1 + m_RendererPriority: 0 + m_Materials: + - {fileID: 2100000, guid: fecc96c64c214ce40835ac4c3c3099e8, type: 2} + 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: 3 + m_MinimumChartSize: 4 + m_AutoUVMaxDistance: 0.5 + m_AutoUVMaxAngle: 89 + m_LightmapParameters: {fileID: 0} + m_SortingLayerID: 0 + m_SortingLayer: 0 + m_SortingOrder: 0 +--- !u!33 &899603642 +MeshFilter: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 3300000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 899603636} + m_Mesh: {fileID: 4300000, guid: 55e5ab7e66bd2eb49bc96935fe0bd04a, type: 3} +--- !u!1 &933433859 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 100000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 933433860} + - component: {fileID: 933433865} + - component: {fileID: 933433864} + - component: {fileID: 933433863} + m_Layer: 0 + m_Name: bot + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &933433860 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 400000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 933433859} + m_LocalRotation: {x: 0, y: 1, z: 0, w: 0} + m_LocalPosition: {x: -29.059395, y: 24.925999, z: -15.206207} + m_LocalScale: {x: 2, y: 2, z: 2} + m_Children: [] + m_Father: {fileID: 66600218} + m_RootOrder: 6 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!195 &933433863 +NavMeshAgent: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 933433859} + m_Enabled: 1 + m_AgentTypeID: 0 + m_Radius: 0.6369026 + m_Speed: 15 + m_Acceleration: 15 + avoidancePriority: 50 + m_AngularSpeed: 1200 + m_StoppingDistance: 0 + m_AutoTraverseOffMeshLink: 1 + m_AutoBraking: 1 + m_AutoRepath: 1 + m_Height: 0.5024553 + m_BaseOffset: 0.25122765 + m_WalkableMask: 4294967295 + m_ObstacleAvoidanceType: 4 +--- !u!23 &933433864 +MeshRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 2300000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 933433859} + m_Enabled: 1 + m_CastShadows: 1 + m_ReceiveShadows: 1 + m_DynamicOccludee: 1 + m_MotionVectors: 1 + m_LightProbeUsage: 0 + m_ReflectionProbeUsage: 1 + m_RenderingLayerMask: 1 + m_RendererPriority: 0 + m_Materials: + - {fileID: 2100000, guid: fecc96c64c214ce40835ac4c3c3099e8, type: 2} + 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: 3 + m_MinimumChartSize: 4 + m_AutoUVMaxDistance: 0.5 + m_AutoUVMaxAngle: 89 + m_LightmapParameters: {fileID: 0} + m_SortingLayerID: 0 + m_SortingLayer: 0 + m_SortingOrder: 0 +--- !u!33 &933433865 +MeshFilter: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 3300000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 933433859} + m_Mesh: {fileID: 4300000, guid: 55e5ab7e66bd2eb49bc96935fe0bd04a, type: 3} +--- !u!1 &985012142 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 985012143} + - component: {fileID: 985012145} + - component: {fileID: 985012144} + m_Layer: 0 + m_Name: 1a + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &985012143 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 985012142} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: -32.264313, y: 0, z: -143.54984} + m_LocalScale: {x: 1, y: 1, z: 1} + m_Children: [] + m_Father: {fileID: 1867949263} + m_RootOrder: 1 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!23 &985012144 +MeshRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 985012142} + m_Enabled: 1 + m_CastShadows: 1 + m_ReceiveShadows: 1 + m_DynamicOccludee: 1 + m_MotionVectors: 1 + m_LightProbeUsage: 0 + m_ReflectionProbeUsage: 1 + m_RenderingLayerMask: 1 + m_RendererPriority: 0 + m_Materials: + - {fileID: 10302, 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: 3 + m_MinimumChartSize: 4 + m_AutoUVMaxDistance: 0.5 + m_AutoUVMaxAngle: 89 + m_LightmapParameters: {fileID: 0} + m_SortingLayerID: 0 + m_SortingLayer: 0 + m_SortingOrder: 0 +--- !u!33 &985012145 +MeshFilter: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 985012142} + m_Mesh: {fileID: 10207, guid: 0000000000000000e000000000000000, type: 0} +--- !u!1 &1014823307 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 100000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1014823308} + - component: {fileID: 1014823311} + - component: {fileID: 1014823310} + - component: {fileID: 1014823309} + m_Layer: 0 + m_Name: bot + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &1014823308 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 400000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1014823307} + m_LocalRotation: {x: 6.123233e-17, y: 1, z: 6.123233e-17, w: 0.00000013315805} + m_LocalPosition: {x: -21.553186, y: 24.925999, z: 3.441162} + m_LocalScale: {x: 2, y: 2, z: 2} + m_Children: [] + m_Father: {fileID: 193687608} + m_RootOrder: 17 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!195 &1014823309 +NavMeshAgent: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1014823307} + m_Enabled: 1 + m_AgentTypeID: 0 + m_Radius: 0.6369026 + m_Speed: 10 + m_Acceleration: 10 + avoidancePriority: 50 + m_AngularSpeed: 1200 + m_StoppingDistance: 0 + m_AutoTraverseOffMeshLink: 1 + m_AutoBraking: 1 + m_AutoRepath: 1 + m_Height: 0.5024553 + m_BaseOffset: 0.25122765 + m_WalkableMask: 4294967295 + m_ObstacleAvoidanceType: 4 +--- !u!23 &1014823310 +MeshRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 2300000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1014823307} + m_Enabled: 1 + m_CastShadows: 1 + m_ReceiveShadows: 1 + m_DynamicOccludee: 1 + m_MotionVectors: 1 + m_LightProbeUsage: 0 + m_ReflectionProbeUsage: 1 + m_RenderingLayerMask: 1 + m_RendererPriority: 0 + m_Materials: + - {fileID: 2100000, guid: fecc96c64c214ce40835ac4c3c3099e8, type: 2} + 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: 3 + m_MinimumChartSize: 4 + m_AutoUVMaxDistance: 0.5 + m_AutoUVMaxAngle: 89 + m_LightmapParameters: {fileID: 0} + m_SortingLayerID: 0 + m_SortingLayer: 0 + m_SortingOrder: 0 +--- !u!33 &1014823311 +MeshFilter: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 3300000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1014823307} + m_Mesh: {fileID: 4300000, guid: 55e5ab7e66bd2eb49bc96935fe0bd04a, type: 3} +--- !u!1 &1031935888 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 100000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1031935889} + - component: {fileID: 1031935892} + - component: {fileID: 1031935891} + - component: {fileID: 1031935890} + m_Layer: 0 + m_Name: bot + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &1031935889 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 400000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1031935888} + m_LocalRotation: {x: 0, y: 1, z: 0, w: 0} + m_LocalPosition: {x: -9.986802, y: 24.925999, z: 16.007904} + m_LocalScale: {x: 2, y: 2, z: 2} + m_Children: [] + m_Father: {fileID: 193687608} + m_RootOrder: 13 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!195 &1031935890 +NavMeshAgent: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1031935888} + m_Enabled: 1 + m_AgentTypeID: 0 + m_Radius: 0.6369026 + m_Speed: 10 + m_Acceleration: 10 + avoidancePriority: 50 + m_AngularSpeed: 1200 + m_StoppingDistance: 0 + m_AutoTraverseOffMeshLink: 1 + m_AutoBraking: 1 + m_AutoRepath: 1 + m_Height: 0.5024553 + m_BaseOffset: 0.25122765 + m_WalkableMask: 4294967295 + m_ObstacleAvoidanceType: 4 +--- !u!23 &1031935891 +MeshRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 2300000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1031935888} + m_Enabled: 1 + m_CastShadows: 1 + m_ReceiveShadows: 1 + m_DynamicOccludee: 1 + m_MotionVectors: 1 + m_LightProbeUsage: 0 + m_ReflectionProbeUsage: 1 + m_RenderingLayerMask: 1 + m_RendererPriority: 0 + m_Materials: + - {fileID: 2100000, guid: fecc96c64c214ce40835ac4c3c3099e8, type: 2} + 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: 3 + m_MinimumChartSize: 4 + m_AutoUVMaxDistance: 0.5 + m_AutoUVMaxAngle: 89 + m_LightmapParameters: {fileID: 0} + m_SortingLayerID: 0 + m_SortingLayer: 0 + m_SortingOrder: 0 +--- !u!33 &1031935892 +MeshFilter: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 3300000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1031935888} + m_Mesh: {fileID: 4300000, guid: 55e5ab7e66bd2eb49bc96935fe0bd04a, type: 3} +--- !u!1 &1041788009 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 100000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1041788010} + - component: {fileID: 1041788013} + - component: {fileID: 1041788012} + - component: {fileID: 1041788011} + m_Layer: 0 + m_Name: bot + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &1041788010 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 400000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1041788009} + m_LocalRotation: {x: 0, y: 1, z: 0, w: 0} + m_LocalPosition: {x: -21.553186, y: 24.925999, z: -8.500595} + m_LocalScale: {x: 2, y: 2, z: 2} + m_Children: [] + m_Father: {fileID: 193687608} + m_RootOrder: 11 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!195 &1041788011 +NavMeshAgent: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1041788009} + m_Enabled: 1 + m_AgentTypeID: 0 + m_Radius: 0.6369026 + m_Speed: 10 + m_Acceleration: 10 + avoidancePriority: 50 + m_AngularSpeed: 1200 + m_StoppingDistance: 0 + m_AutoTraverseOffMeshLink: 1 + m_AutoBraking: 1 + m_AutoRepath: 1 + m_Height: 0.5024553 + m_BaseOffset: 0.25122765 + m_WalkableMask: 4294967295 + m_ObstacleAvoidanceType: 4 +--- !u!23 &1041788012 +MeshRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 2300000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1041788009} + m_Enabled: 1 + m_CastShadows: 1 + m_ReceiveShadows: 1 + m_DynamicOccludee: 1 + m_MotionVectors: 1 + m_LightProbeUsage: 0 + m_ReflectionProbeUsage: 1 + m_RenderingLayerMask: 1 + m_RendererPriority: 0 + m_Materials: + - {fileID: 2100000, guid: fecc96c64c214ce40835ac4c3c3099e8, type: 2} + 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: 3 + m_MinimumChartSize: 4 + m_AutoUVMaxDistance: 0.5 + m_AutoUVMaxAngle: 89 + m_LightmapParameters: {fileID: 0} + m_SortingLayerID: 0 + m_SortingLayer: 0 + m_SortingOrder: 0 +--- !u!33 &1041788013 +MeshFilter: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 3300000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1041788009} + m_Mesh: {fileID: 4300000, guid: 55e5ab7e66bd2eb49bc96935fe0bd04a, type: 3} +--- !u!1 &1099702921 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 100000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1099702922} + - component: {fileID: 1099702927} + - component: {fileID: 1099702926} + - component: {fileID: 1099702925} + - component: {fileID: 1099702924} + - component: {fileID: 1099702923} + m_Layer: 0 + m_Name: bot + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &1099702922 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 400000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1099702921} + m_LocalRotation: {x: 0, y: 1, z: 0, w: 0} + m_LocalPosition: {x: -17.492996, y: 24.925999, z: -15.206207} + m_LocalScale: {x: 2, y: 2, z: 2} + m_Children: [] + m_Father: {fileID: 1151274299} + m_RootOrder: 3 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!82 &1099702923 +AudioSource: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1099702921} + m_Enabled: 1 + serializedVersion: 4 + OutputAudioMixerGroup: {fileID: 0} + m_audioClip: {fileID: 0} + m_PlayOnAwake: 1 + m_Volume: 1 + m_Pitch: 1 + Loop: 0 + Mute: 0 + Spatialize: 0 + SpatializePostEffects: 0 + Priority: 128 + DopplerLevel: 1 + MinDistance: 1 + MaxDistance: 500 + Pan2D: 0 + rolloffMode: 0 + BypassEffects: 0 + BypassListenerEffects: 0 + BypassReverbZones: 0 + rolloffCustomCurve: + serializedVersion: 2 + m_Curve: + - serializedVersion: 3 + time: 0 + value: 1 + inSlope: 0 + outSlope: 0 + tangentMode: 0 + weightedMode: 0 + inWeight: 0.33333334 + outWeight: 0.33333334 + - serializedVersion: 3 + time: 1 + value: 0 + inSlope: 0 + outSlope: 0 + tangentMode: 0 + weightedMode: 0 + inWeight: 0.33333334 + outWeight: 0.33333334 + m_PreInfinity: 2 + m_PostInfinity: 2 + m_RotationOrder: 4 + panLevelCustomCurve: + serializedVersion: 2 + m_Curve: + - serializedVersion: 3 + time: 0 + value: 1 + inSlope: 0 + outSlope: 0 + tangentMode: 0 + weightedMode: 0 + inWeight: 0.33333334 + outWeight: 0.33333334 + m_PreInfinity: 2 + m_PostInfinity: 2 + m_RotationOrder: 4 + spreadCustomCurve: + serializedVersion: 2 + m_Curve: + - serializedVersion: 3 + time: 0 + value: 0 + inSlope: 0 + outSlope: 0 + tangentMode: 0 + weightedMode: 0 + inWeight: 0.33333334 + outWeight: 0.33333334 + m_PreInfinity: 2 + m_PostInfinity: 2 + m_RotationOrder: 4 + reverbZoneMixCustomCurve: + serializedVersion: 2 + m_Curve: + - serializedVersion: 3 + time: 0 + value: 1 + inSlope: 0 + outSlope: 0 + tangentMode: 0 + weightedMode: 0 + inWeight: 0.33333334 + outWeight: 0.33333334 + m_PreInfinity: 2 + m_PostInfinity: 2 + m_RotationOrder: 4 +--- !u!65 &1099702924 +BoxCollider: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1099702921} + m_Material: {fileID: 0} + m_IsTrigger: 0 + m_Enabled: 1 + serializedVersion: 2 + m_Size: {x: 1.2738054, y: 0.6292588, z: 0.83338344} + m_Center: {x: -0.00000014901161, y: -0.06340176, z: 0.041081354} +--- !u!195 &1099702925 +NavMeshAgent: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1099702921} + m_Enabled: 1 + m_AgentTypeID: 0 + m_Radius: 0.6369026 + m_Speed: 10 + m_Acceleration: 8 + avoidancePriority: 50 + m_AngularSpeed: 1200 + m_StoppingDistance: 0 + m_AutoTraverseOffMeshLink: 1 + m_AutoBraking: 1 + m_AutoRepath: 1 + m_Height: 0.5024553 + m_BaseOffset: 0.25122765 + m_WalkableMask: 4294967295 + m_ObstacleAvoidanceType: 4 +--- !u!23 &1099702926 +MeshRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 2300000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1099702921} + m_Enabled: 1 + m_CastShadows: 1 + m_ReceiveShadows: 1 + m_DynamicOccludee: 1 + m_MotionVectors: 1 + m_LightProbeUsage: 0 + m_ReflectionProbeUsage: 1 + m_RenderingLayerMask: 1 + m_RendererPriority: 0 + m_Materials: + - {fileID: 2100000, guid: fecc96c64c214ce40835ac4c3c3099e8, type: 2} + 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: 3 + m_MinimumChartSize: 4 + m_AutoUVMaxDistance: 0.5 + m_AutoUVMaxAngle: 89 + m_LightmapParameters: {fileID: 0} + m_SortingLayerID: 0 + m_SortingLayer: 0 + m_SortingOrder: 0 +--- !u!33 &1099702927 +MeshFilter: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 3300000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1099702921} + m_Mesh: {fileID: 4300000, guid: 55e5ab7e66bd2eb49bc96935fe0bd04a, type: 3} +--- !u!1 &1111038048 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 100000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1111038049} + - component: {fileID: 1111038052} + - component: {fileID: 1111038051} + - component: {fileID: 1111038050} + m_Layer: 0 + m_Name: bot + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &1111038049 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 400000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1111038048} + m_LocalRotation: {x: 0, y: 1, z: 0, w: 0} + m_LocalPosition: {x: -9.986802, y: 24.925999, z: 9.82312} + m_LocalScale: {x: 2, y: 2, z: 2} + m_Children: [] + m_Father: {fileID: 193687608} + m_RootOrder: 0 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!195 &1111038050 +NavMeshAgent: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1111038048} + m_Enabled: 1 + m_AgentTypeID: 0 + m_Radius: 0.6369026 + m_Speed: 10 + m_Acceleration: 10 + avoidancePriority: 50 + m_AngularSpeed: 1200 + m_StoppingDistance: 0 + m_AutoTraverseOffMeshLink: 1 + m_AutoBraking: 1 + m_AutoRepath: 1 + m_Height: 0.5024553 + m_BaseOffset: 0.25122765 + m_WalkableMask: 4294967295 + m_ObstacleAvoidanceType: 4 +--- !u!23 &1111038051 +MeshRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 2300000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1111038048} + m_Enabled: 1 + m_CastShadows: 1 + m_ReceiveShadows: 1 + m_DynamicOccludee: 1 + m_MotionVectors: 1 + m_LightProbeUsage: 0 + m_ReflectionProbeUsage: 1 + m_RenderingLayerMask: 1 + m_RendererPriority: 0 + m_Materials: + - {fileID: 2100000, guid: fecc96c64c214ce40835ac4c3c3099e8, type: 2} + 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: 3 + m_MinimumChartSize: 4 + m_AutoUVMaxDistance: 0.5 + m_AutoUVMaxAngle: 89 + m_LightmapParameters: {fileID: 0} + m_SortingLayerID: 0 + m_SortingLayer: 0 + m_SortingOrder: 0 +--- !u!33 &1111038052 +MeshFilter: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 3300000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1111038048} + m_Mesh: {fileID: 4300000, guid: 55e5ab7e66bd2eb49bc96935fe0bd04a, type: 3} +--- !u!1 &1111626858 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 100000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1111626859} + - component: {fileID: 1111626862} + - component: {fileID: 1111626861} + - component: {fileID: 1111626860} + m_Layer: 0 + m_Name: bot + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &1111626859 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 400000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1111626858} + m_LocalRotation: {x: 6.123233e-17, y: 1, z: 6.123233e-17, w: 0.00000013315805} + m_LocalPosition: {x: -9.986802, y: 24.925999, z: -2.7436218} + m_LocalScale: {x: 2, y: 2, z: 2} + m_Children: [] + m_Father: {fileID: 193687608} + m_RootOrder: 24 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!195 &1111626860 +NavMeshAgent: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1111626858} + m_Enabled: 1 + m_AgentTypeID: 0 + m_Radius: 0.6369026 + m_Speed: 10 + m_Acceleration: 10 + avoidancePriority: 50 + m_AngularSpeed: 1200 + m_StoppingDistance: 0 + m_AutoTraverseOffMeshLink: 1 + m_AutoBraking: 1 + m_AutoRepath: 1 + m_Height: 0.5024553 + m_BaseOffset: 0.25122765 + m_WalkableMask: 4294967295 + m_ObstacleAvoidanceType: 4 +--- !u!23 &1111626861 +MeshRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 2300000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1111626858} + m_Enabled: 1 + m_CastShadows: 1 + m_ReceiveShadows: 1 + m_DynamicOccludee: 1 + m_MotionVectors: 1 + m_LightProbeUsage: 0 + m_ReflectionProbeUsage: 1 + m_RenderingLayerMask: 1 + m_RendererPriority: 0 + m_Materials: + - {fileID: 2100000, guid: fecc96c64c214ce40835ac4c3c3099e8, type: 2} + 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: 3 + m_MinimumChartSize: 4 + m_AutoUVMaxDistance: 0.5 + m_AutoUVMaxAngle: 89 + m_LightmapParameters: {fileID: 0} + m_SortingLayerID: 0 + m_SortingLayer: 0 + m_SortingOrder: 0 +--- !u!33 &1111626862 +MeshFilter: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 3300000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1111626858} + m_Mesh: {fileID: 4300000, guid: 55e5ab7e66bd2eb49bc96935fe0bd04a, type: 3} +--- !u!1 &1114766221 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1114766222} + - component: {fileID: 1114766224} + - component: {fileID: 1114766223} + m_Layer: 0 + m_Name: 2a + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &1114766222 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1114766221} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: 32.735687, y: 0, z: -113.53264} + m_LocalScale: {x: 1, y: 1, z: 1} + m_Children: [] + m_Father: {fileID: 1867949263} + m_RootOrder: 5 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!23 &1114766223 +MeshRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1114766221} + m_Enabled: 1 + m_CastShadows: 1 + m_ReceiveShadows: 1 + m_DynamicOccludee: 1 + m_MotionVectors: 1 + m_LightProbeUsage: 0 + m_ReflectionProbeUsage: 1 + m_RenderingLayerMask: 1 + m_RendererPriority: 0 + m_Materials: + - {fileID: 10302, 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: 3 + m_MinimumChartSize: 4 + m_AutoUVMaxDistance: 0.5 + m_AutoUVMaxAngle: 89 + m_LightmapParameters: {fileID: 0} + m_SortingLayerID: 0 + m_SortingLayer: 0 + m_SortingOrder: 0 +--- !u!33 &1114766224 +MeshFilter: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1114766221} + m_Mesh: {fileID: 10207, guid: 0000000000000000e000000000000000, type: 0} +--- !u!1 &1125071874 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 100000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1125071875} + - component: {fileID: 1125071878} + - component: {fileID: 1125071877} + - component: {fileID: 1125071876} + m_Layer: 0 + m_Name: bot + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &1125071875 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 400000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1125071874} + m_LocalRotation: {x: 6.123233e-17, y: 1, z: 6.123233e-17, w: 0.00000013315805} + m_LocalPosition: {x: -21.553186, y: 24.925999, z: -2.7436218} + m_LocalScale: {x: 2, y: 2, z: 2} + m_Children: [] + m_Father: {fileID: 193687608} + m_RootOrder: 29 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!195 &1125071876 +NavMeshAgent: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1125071874} + m_Enabled: 1 + m_AgentTypeID: 0 + m_Radius: 0.6369026 + m_Speed: 10 + m_Acceleration: 10 + avoidancePriority: 50 + m_AngularSpeed: 1200 + m_StoppingDistance: 0 + m_AutoTraverseOffMeshLink: 1 + m_AutoBraking: 1 + m_AutoRepath: 1 + m_Height: 0.5024553 + m_BaseOffset: 0.25122765 + m_WalkableMask: 4294967295 + m_ObstacleAvoidanceType: 4 +--- !u!23 &1125071877 +MeshRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 2300000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1125071874} + m_Enabled: 1 + m_CastShadows: 1 + m_ReceiveShadows: 1 + m_DynamicOccludee: 1 + m_MotionVectors: 1 + m_LightProbeUsage: 0 + m_ReflectionProbeUsage: 1 + m_RenderingLayerMask: 1 + m_RendererPriority: 0 + m_Materials: + - {fileID: 2100000, guid: fecc96c64c214ce40835ac4c3c3099e8, type: 2} + 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: 3 + m_MinimumChartSize: 4 + m_AutoUVMaxDistance: 0.5 + m_AutoUVMaxAngle: 89 + m_LightmapParameters: {fileID: 0} + m_SortingLayerID: 0 + m_SortingLayer: 0 + m_SortingOrder: 0 +--- !u!33 &1125071878 +MeshFilter: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 3300000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1125071874} + m_Mesh: {fileID: 4300000, guid: 55e5ab7e66bd2eb49bc96935fe0bd04a, type: 3} +--- !u!1 &1144204291 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1144204295} + - component: {fileID: 1144204294} + - component: {fileID: 1144204293} + - component: {fileID: 1144204292} + m_Layer: 2 + m_Name: Cube + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 4294967295 + m_IsActive: 1 +--- !u!23 &1144204292 +MeshRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1144204291} + m_Enabled: 1 + m_CastShadows: 1 + m_ReceiveShadows: 1 + m_DynamicOccludee: 1 + m_MotionVectors: 1 + m_LightProbeUsage: 0 + m_ReflectionProbeUsage: 1 + m_RenderingLayerMask: 1 + m_RendererPriority: 0 + m_Materials: + - {fileID: 2100000, guid: a08f97e5b75379d40b08ff5f74847d5c, type: 2} + 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: 3 + m_MinimumChartSize: 4 + m_AutoUVMaxDistance: 0.5 + m_AutoUVMaxAngle: 89 + m_LightmapParameters: {fileID: 0} + m_SortingLayerID: 0 + m_SortingLayer: 0 + m_SortingOrder: 0 +--- !u!65 &1144204293 +BoxCollider: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1144204291} + m_Material: {fileID: 0} + m_IsTrigger: 0 + m_Enabled: 1 + serializedVersion: 2 + m_Size: {x: 1, y: 1, z: 1} + m_Center: {x: 0, y: 0, z: 0} +--- !u!33 &1144204294 +MeshFilter: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1144204291} + m_Mesh: {fileID: 10202, guid: 0000000000000000e000000000000000, type: 0} +--- !u!4 &1144204295 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1144204291} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: -50, y: 1.5, z: 0} + m_LocalScale: {x: 2, y: 3, z: 100} + m_Children: [] + m_Father: {fileID: 476658879} + m_RootOrder: 3 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!1 &1151094525 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 100000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1151094526} + - component: {fileID: 1151094529} + - component: {fileID: 1151094528} + - component: {fileID: 1151094527} + m_Layer: 0 + m_Name: bot + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &1151094526 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 400000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1151094525} + m_LocalRotation: {x: 0, y: 1, z: 0, w: 0} + m_LocalPosition: {x: -9.986802, y: 24.925999, z: 13.229553} + m_LocalScale: {x: 2, y: 2, z: 2} + m_Children: [] + m_Father: {fileID: 193687608} + m_RootOrder: 18 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!195 &1151094527 +NavMeshAgent: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1151094525} + m_Enabled: 1 + m_AgentTypeID: 0 + m_Radius: 0.6369026 + m_Speed: 10 + m_Acceleration: 10 + avoidancePriority: 50 + m_AngularSpeed: 1200 + m_StoppingDistance: 0 + m_AutoTraverseOffMeshLink: 1 + m_AutoBraking: 1 + m_AutoRepath: 1 + m_Height: 0.5024553 + m_BaseOffset: 0.25122765 + m_WalkableMask: 4294967295 + m_ObstacleAvoidanceType: 4 +--- !u!23 &1151094528 +MeshRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 2300000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1151094525} + m_Enabled: 1 + m_CastShadows: 1 + m_ReceiveShadows: 1 + m_DynamicOccludee: 1 + m_MotionVectors: 1 + m_LightProbeUsage: 0 + m_ReflectionProbeUsage: 1 + m_RenderingLayerMask: 1 + m_RendererPriority: 0 + m_Materials: + - {fileID: 2100000, guid: fecc96c64c214ce40835ac4c3c3099e8, type: 2} + 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: 3 + m_MinimumChartSize: 4 + m_AutoUVMaxDistance: 0.5 + m_AutoUVMaxAngle: 89 + m_LightmapParameters: {fileID: 0} + m_SortingLayerID: 0 + m_SortingLayer: 0 + m_SortingOrder: 0 +--- !u!33 &1151094529 +MeshFilter: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 3300000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1151094525} + m_Mesh: {fileID: 4300000, guid: 55e5ab7e66bd2eb49bc96935fe0bd04a, type: 3} +--- !u!1 &1151274298 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1151274299} + m_Layer: 0 + m_Name: Queue + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &1151274299 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1151274298} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: 19.417397, y: -24.249596, z: -2.6824112} + m_LocalScale: {x: 1, y: 1, z: 1} + m_Children: + - {fileID: 1449224518} + - {fileID: 669865894} + - {fileID: 1914965758} + - {fileID: 1099702922} + - {fileID: 819671358} + - {fileID: 1792926650} + - {fileID: 823926551} + - {fileID: 899603637} + - {fileID: 2110132576} + - {fileID: 1487380455} + - {fileID: 363215077} + m_Father: {fileID: 0} + m_RootOrder: 6 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!1 &1158265377 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 100000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1158265378} + - component: {fileID: 1158265383} + - component: {fileID: 1158265382} + - component: {fileID: 1158265381} + m_Layer: 0 + m_Name: bot + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &1158265378 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 400000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1158265377} + m_LocalRotation: {x: 0, y: 1, z: 0, w: 0} + m_LocalPosition: {x: -17.492996, y: 24.925999, z: 9.302292} + m_LocalScale: {x: 2, y: 2, z: 2} + m_Children: [] + m_Father: {fileID: 193687608} + m_RootOrder: 27 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!195 &1158265381 +NavMeshAgent: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1158265377} + m_Enabled: 1 + m_AgentTypeID: 0 + m_Radius: 0.6369026 + m_Speed: 10 + m_Acceleration: 10 + avoidancePriority: 50 + m_AngularSpeed: 1200 + m_StoppingDistance: 0 + m_AutoTraverseOffMeshLink: 1 + m_AutoBraking: 1 + m_AutoRepath: 1 + m_Height: 0.5024553 + m_BaseOffset: 0.25122765 + m_WalkableMask: 4294967295 + m_ObstacleAvoidanceType: 4 +--- !u!23 &1158265382 +MeshRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 2300000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1158265377} + m_Enabled: 1 + m_CastShadows: 1 + m_ReceiveShadows: 1 + m_DynamicOccludee: 1 + m_MotionVectors: 1 + m_LightProbeUsage: 0 + m_ReflectionProbeUsage: 1 + m_RenderingLayerMask: 1 + m_RendererPriority: 0 + m_Materials: + - {fileID: 2100000, guid: fecc96c64c214ce40835ac4c3c3099e8, type: 2} + 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: 3 + m_MinimumChartSize: 4 + m_AutoUVMaxDistance: 0.5 + m_AutoUVMaxAngle: 89 + m_LightmapParameters: {fileID: 0} + m_SortingLayerID: 0 + m_SortingLayer: 0 + m_SortingOrder: 0 +--- !u!33 &1158265383 +MeshFilter: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 3300000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1158265377} + m_Mesh: {fileID: 4300000, guid: 55e5ab7e66bd2eb49bc96935fe0bd04a, type: 3} +--- !u!1 &1189173170 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1189173171} + - component: {fileID: 1189173174} + - component: {fileID: 1189173173} + - component: {fileID: 1189173172} + m_Layer: 2 + m_Name: Cube + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 4294967295 + m_IsActive: 1 +--- !u!4 &1189173171 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1189173170} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: 0, y: 1.5, z: 50} + m_LocalScale: {x: 100, y: 3, z: 2} + m_Children: [] + m_Father: {fileID: 476658879} + m_RootOrder: 1 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!23 &1189173172 +MeshRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1189173170} + m_Enabled: 1 + m_CastShadows: 1 + m_ReceiveShadows: 1 + m_DynamicOccludee: 1 + m_MotionVectors: 1 + m_LightProbeUsage: 0 + m_ReflectionProbeUsage: 1 + m_RenderingLayerMask: 1 + m_RendererPriority: 0 + m_Materials: + - {fileID: 2100000, guid: a08f97e5b75379d40b08ff5f74847d5c, type: 2} + 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: 3 + m_MinimumChartSize: 4 + m_AutoUVMaxDistance: 0.5 + m_AutoUVMaxAngle: 89 + m_LightmapParameters: {fileID: 0} + m_SortingLayerID: 0 + m_SortingLayer: 0 + m_SortingOrder: 0 +--- !u!65 &1189173173 +BoxCollider: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1189173170} + m_Material: {fileID: 0} + m_IsTrigger: 0 + m_Enabled: 1 + serializedVersion: 2 + m_Size: {x: 1, y: 1, z: 1} + m_Center: {x: 0, y: 0, z: 0} +--- !u!33 &1189173174 +MeshFilter: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1189173170} + m_Mesh: {fileID: 10202, guid: 0000000000000000e000000000000000, type: 0} +--- !u!1 &1190109942 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1190109943} + - component: {fileID: 1190109946} + - component: {fileID: 1190109945} + - component: {fileID: 1190109944} + m_Layer: 2 + m_Name: Cube + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 4294967295 + m_IsActive: 1 +--- !u!4 &1190109943 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1190109942} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: 0, y: 1.5, z: -30} + m_LocalScale: {x: 60, y: 3, z: 2} + m_Children: [] + m_Father: {fileID: 122009232} + m_RootOrder: 1 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!23 &1190109944 +MeshRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1190109942} + m_Enabled: 1 + m_CastShadows: 1 + m_ReceiveShadows: 1 + m_DynamicOccludee: 1 + m_MotionVectors: 1 + m_LightProbeUsage: 0 + m_ReflectionProbeUsage: 1 + m_RenderingLayerMask: 1 + m_RendererPriority: 0 + m_Materials: + - {fileID: 2100000, guid: a08f97e5b75379d40b08ff5f74847d5c, type: 2} + 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: 3 + m_MinimumChartSize: 4 + m_AutoUVMaxDistance: 0.5 + m_AutoUVMaxAngle: 89 + m_LightmapParameters: {fileID: 0} + m_SortingLayerID: 0 + m_SortingLayer: 0 + m_SortingOrder: 0 +--- !u!65 &1190109945 +BoxCollider: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1190109942} + m_Material: {fileID: 0} + m_IsTrigger: 0 + m_Enabled: 1 + serializedVersion: 2 + m_Size: {x: 1, y: 1, z: 1} + m_Center: {x: 0, y: 0, z: 0} +--- !u!33 &1190109946 +MeshFilter: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1190109942} + m_Mesh: {fileID: 10202, guid: 0000000000000000e000000000000000, type: 0} +--- !u!1 &1205913526 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 100000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1205913527} + - component: {fileID: 1205913532} + - component: {fileID: 1205913531} + - component: {fileID: 1205913530} + - component: {fileID: 1205913529} + - component: {fileID: 1205913528} + m_Layer: 0 + m_Name: bot + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &1205913527 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 400000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1205913526} + m_LocalRotation: {x: 6.123233e-17, y: 1, z: 6.123233e-17, w: 0.00000013315805} + m_LocalPosition: {x: -17.492996, y: 24.925999, z: -0.3338623} + m_LocalScale: {x: 2, y: 2, z: 2} + m_Children: [] + m_Father: {fileID: 193687608} + m_RootOrder: 22 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!82 &1205913528 +AudioSource: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1205913526} + m_Enabled: 1 + serializedVersion: 4 + OutputAudioMixerGroup: {fileID: 0} + m_audioClip: {fileID: 0} + m_PlayOnAwake: 1 + m_Volume: 1 + m_Pitch: 1 + Loop: 0 + Mute: 0 + Spatialize: 0 + SpatializePostEffects: 0 + Priority: 128 + DopplerLevel: 1 + MinDistance: 1 + MaxDistance: 500 + Pan2D: 0 + rolloffMode: 0 + BypassEffects: 0 + BypassListenerEffects: 0 + BypassReverbZones: 0 + rolloffCustomCurve: + serializedVersion: 2 + m_Curve: + - serializedVersion: 3 + time: 0 + value: 1 + inSlope: 0 + outSlope: 0 + tangentMode: 0 + weightedMode: 0 + inWeight: 0.33333334 + outWeight: 0.33333334 + - serializedVersion: 3 + time: 1 + value: 0 + inSlope: 0 + outSlope: 0 + tangentMode: 0 + weightedMode: 0 + inWeight: 0.33333334 + outWeight: 0.33333334 + m_PreInfinity: 2 + m_PostInfinity: 2 + m_RotationOrder: 4 + panLevelCustomCurve: + serializedVersion: 2 + m_Curve: + - serializedVersion: 3 + time: 0 + value: 1 + inSlope: 0 + outSlope: 0 + tangentMode: 0 + weightedMode: 0 + inWeight: 0.33333334 + outWeight: 0.33333334 + m_PreInfinity: 2 + m_PostInfinity: 2 + m_RotationOrder: 4 + spreadCustomCurve: + serializedVersion: 2 + m_Curve: + - serializedVersion: 3 + time: 0 + value: 0 + inSlope: 0 + outSlope: 0 + tangentMode: 0 + weightedMode: 0 + inWeight: 0.33333334 + outWeight: 0.33333334 + m_PreInfinity: 2 + m_PostInfinity: 2 + m_RotationOrder: 4 + reverbZoneMixCustomCurve: + serializedVersion: 2 + m_Curve: + - serializedVersion: 3 + time: 0 + value: 1 + inSlope: 0 + outSlope: 0 + tangentMode: 0 + weightedMode: 0 + inWeight: 0.33333334 + outWeight: 0.33333334 + m_PreInfinity: 2 + m_PostInfinity: 2 + m_RotationOrder: 4 +--- !u!65 &1205913529 +BoxCollider: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1205913526} + m_Material: {fileID: 0} + m_IsTrigger: 0 + m_Enabled: 1 + serializedVersion: 2 + m_Size: {x: 1.2738054, y: 0.6292588, z: 0.83338344} + m_Center: {x: -0.00000014901161, y: -0.06340176, z: 0.041081354} +--- !u!195 &1205913530 +NavMeshAgent: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1205913526} + m_Enabled: 1 + m_AgentTypeID: 0 + m_Radius: 0.6369026 + m_Speed: 10 + m_Acceleration: 10 + avoidancePriority: 50 + m_AngularSpeed: 1200 + m_StoppingDistance: 0 + m_AutoTraverseOffMeshLink: 1 + m_AutoBraking: 1 + m_AutoRepath: 1 + m_Height: 0.5024553 + m_BaseOffset: 0.25122765 + m_WalkableMask: 4294967295 + m_ObstacleAvoidanceType: 4 +--- !u!23 &1205913531 +MeshRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 2300000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1205913526} + m_Enabled: 1 + m_CastShadows: 1 + m_ReceiveShadows: 1 + m_DynamicOccludee: 1 + m_MotionVectors: 1 + m_LightProbeUsage: 0 + m_ReflectionProbeUsage: 1 + m_RenderingLayerMask: 1 + m_RendererPriority: 0 + m_Materials: + - {fileID: 2100000, guid: fecc96c64c214ce40835ac4c3c3099e8, type: 2} + 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: 3 + m_MinimumChartSize: 4 + m_AutoUVMaxDistance: 0.5 + m_AutoUVMaxAngle: 89 + m_LightmapParameters: {fileID: 0} + m_SortingLayerID: 0 + m_SortingLayer: 0 + m_SortingOrder: 0 +--- !u!33 &1205913532 +MeshFilter: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 3300000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1205913526} + m_Mesh: {fileID: 4300000, guid: 55e5ab7e66bd2eb49bc96935fe0bd04a, type: 3} +--- !u!1 &1250902116 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1250902117} + - component: {fileID: 1250902120} + - component: {fileID: 1250902119} + - component: {fileID: 1250902118} + m_Layer: 2 + m_Name: Cube + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 4294967295 + m_IsActive: 1 +--- !u!4 &1250902117 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1250902116} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: -50, y: 1.5, z: 0} + m_LocalScale: {x: 2, y: 3, z: 100} + m_Children: [] + m_Father: {fileID: 122009232} + m_RootOrder: 9 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!23 &1250902118 +MeshRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1250902116} + m_Enabled: 1 + m_CastShadows: 1 + m_ReceiveShadows: 1 + m_DynamicOccludee: 1 + m_MotionVectors: 1 + m_LightProbeUsage: 0 + m_ReflectionProbeUsage: 1 + m_RenderingLayerMask: 1 + m_RendererPriority: 0 + m_Materials: + - {fileID: 2100000, guid: a08f97e5b75379d40b08ff5f74847d5c, type: 2} + 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: 3 + m_MinimumChartSize: 4 + m_AutoUVMaxDistance: 0.5 + m_AutoUVMaxAngle: 89 + m_LightmapParameters: {fileID: 0} + m_SortingLayerID: 0 + m_SortingLayer: 0 + m_SortingOrder: 0 +--- !u!65 &1250902119 +BoxCollider: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1250902116} + m_Material: {fileID: 0} + m_IsTrigger: 0 + m_Enabled: 1 + serializedVersion: 2 + m_Size: {x: 1, y: 1, z: 1} + m_Center: {x: 0, y: 0, z: 0} +--- !u!33 &1250902120 +MeshFilter: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1250902116} + m_Mesh: {fileID: 10202, guid: 0000000000000000e000000000000000, type: 0} +--- !u!1 &1252079133 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 100000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1252079139} + - component: {fileID: 1252079138} + - component: {fileID: 1252079137} + - component: {fileID: 1252079136} + m_Layer: 0 + m_Name: bot + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!195 &1252079136 +NavMeshAgent: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1252079133} + m_Enabled: 1 + m_AgentTypeID: 0 + m_Radius: 0.6369026 + m_Speed: 10 + m_Acceleration: 10 + avoidancePriority: 50 + m_AngularSpeed: 1200 + m_StoppingDistance: 0 + m_AutoTraverseOffMeshLink: 1 + m_AutoBraking: 1 + m_AutoRepath: 1 + m_Height: 0.5024553 + m_BaseOffset: 0.25122765 + m_WalkableMask: 4294967295 + m_ObstacleAvoidanceType: 4 +--- !u!23 &1252079137 +MeshRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 2300000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1252079133} + m_Enabled: 1 + m_CastShadows: 1 + m_ReceiveShadows: 1 + m_DynamicOccludee: 1 + m_MotionVectors: 1 + m_LightProbeUsage: 0 + m_ReflectionProbeUsage: 1 + m_RenderingLayerMask: 1 + m_RendererPriority: 0 + m_Materials: + - {fileID: 2100000, guid: fecc96c64c214ce40835ac4c3c3099e8, type: 2} + 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: 3 + m_MinimumChartSize: 4 + m_AutoUVMaxDistance: 0.5 + m_AutoUVMaxAngle: 89 + m_LightmapParameters: {fileID: 0} + m_SortingLayerID: 0 + m_SortingLayer: 0 + m_SortingOrder: 0 +--- !u!33 &1252079138 +MeshFilter: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 3300000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1252079133} + m_Mesh: {fileID: 4300000, guid: 55e5ab7e66bd2eb49bc96935fe0bd04a, type: 3} +--- !u!4 &1252079139 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 400000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1252079133} + m_LocalRotation: {x: 6.123233e-17, y: 1, z: 6.123233e-17, w: 0.00000013315805} + m_LocalPosition: {x: -29.059395, y: 24.925999, z: 3.3366547} + m_LocalScale: {x: 2, y: 2, z: 2} + m_Children: [] + m_Father: {fileID: 193687608} + m_RootOrder: 7 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!1 &1277433085 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 100000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1277433086} + - component: {fileID: 1277433089} + - component: {fileID: 1277433088} + - component: {fileID: 1277433087} + m_Layer: 0 + m_Name: bot + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &1277433086 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 400000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1277433085} + m_LocalRotation: {x: 0, y: 1, z: 0, w: 0} + m_LocalPosition: {x: -9.986802, y: 24.925999, z: 9.82312} + m_LocalScale: {x: 2, y: 2, z: 2} + m_Children: [] + m_Father: {fileID: 66600218} + m_RootOrder: 0 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!195 &1277433087 +NavMeshAgent: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1277433085} + m_Enabled: 1 + m_AgentTypeID: 0 + m_Radius: 0.6369026 + m_Speed: 15 + m_Acceleration: 15 + avoidancePriority: 50 + m_AngularSpeed: 1200 + m_StoppingDistance: 0 + m_AutoTraverseOffMeshLink: 1 + m_AutoBraking: 1 + m_AutoRepath: 1 + m_Height: 0.5024553 + m_BaseOffset: 0.25122765 + m_WalkableMask: 4294967295 + m_ObstacleAvoidanceType: 4 +--- !u!23 &1277433088 +MeshRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 2300000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1277433085} + m_Enabled: 1 + m_CastShadows: 1 + m_ReceiveShadows: 1 + m_DynamicOccludee: 1 + m_MotionVectors: 1 + m_LightProbeUsage: 0 + m_ReflectionProbeUsage: 1 + m_RenderingLayerMask: 1 + m_RendererPriority: 0 + m_Materials: + - {fileID: 2100000, guid: fecc96c64c214ce40835ac4c3c3099e8, type: 2} + 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: 3 + m_MinimumChartSize: 4 + m_AutoUVMaxDistance: 0.5 + m_AutoUVMaxAngle: 89 + m_LightmapParameters: {fileID: 0} + m_SortingLayerID: 0 + m_SortingLayer: 0 + m_SortingOrder: 0 +--- !u!33 &1277433089 +MeshFilter: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 3300000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1277433085} + m_Mesh: {fileID: 4300000, guid: 55e5ab7e66bd2eb49bc96935fe0bd04a, type: 3} +--- !u!1 &1350099621 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 100000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1350099622} + - component: {fileID: 1350099627} + - component: {fileID: 1350099626} + - component: {fileID: 1350099625} + m_Layer: 0 + m_Name: bot + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &1350099622 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 400000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1350099621} + m_LocalRotation: {x: 0, y: 1, z: 0, w: 0} + m_LocalPosition: {x: -29.059395, y: 24.925999, z: 15.903397} + m_LocalScale: {x: 2, y: 2, z: 2} + m_Children: [] + m_Father: {fileID: 193687608} + m_RootOrder: 1 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!195 &1350099625 +NavMeshAgent: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1350099621} + m_Enabled: 1 + m_AgentTypeID: 0 + m_Radius: 0.6369026 + m_Speed: 10 + m_Acceleration: 10 + avoidancePriority: 50 + m_AngularSpeed: 1200 + m_StoppingDistance: 0 + m_AutoTraverseOffMeshLink: 1 + m_AutoBraking: 1 + m_AutoRepath: 1 + m_Height: 0.5024553 + m_BaseOffset: 0.25122765 + m_WalkableMask: 4294967295 + m_ObstacleAvoidanceType: 4 +--- !u!23 &1350099626 +MeshRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 2300000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1350099621} + m_Enabled: 1 + m_CastShadows: 1 + m_ReceiveShadows: 1 + m_DynamicOccludee: 1 + m_MotionVectors: 1 + m_LightProbeUsage: 0 + m_ReflectionProbeUsage: 1 + m_RenderingLayerMask: 1 + m_RendererPriority: 0 + m_Materials: + - {fileID: 2100000, guid: fecc96c64c214ce40835ac4c3c3099e8, type: 2} + 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: 3 + m_MinimumChartSize: 4 + m_AutoUVMaxDistance: 0.5 + m_AutoUVMaxAngle: 89 + m_LightmapParameters: {fileID: 0} + m_SortingLayerID: 0 + m_SortingLayer: 0 + m_SortingOrder: 0 +--- !u!33 &1350099627 +MeshFilter: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 3300000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1350099621} + m_Mesh: {fileID: 4300000, guid: 55e5ab7e66bd2eb49bc96935fe0bd04a, type: 3} +--- !u!1 &1358453174 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1358453175} + - component: {fileID: 1358453178} + - component: {fileID: 1358453177} + - component: {fileID: 1358453176} + m_Layer: 4 + m_Name: Cube + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 4294967295 + m_IsActive: 1 +--- !u!4 &1358453175 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1358453174} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: 0, y: 1.5, z: 0} + m_LocalScale: {x: 2, y: 3, z: 15} + m_Children: [] + m_Father: {fileID: 122009232} + m_RootOrder: 10 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!23 &1358453176 +MeshRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1358453174} + m_Enabled: 1 + m_CastShadows: 1 + m_ReceiveShadows: 1 + m_DynamicOccludee: 1 + m_MotionVectors: 1 + m_LightProbeUsage: 0 + m_ReflectionProbeUsage: 1 + m_RenderingLayerMask: 1 + m_RendererPriority: 0 + m_Materials: + - {fileID: 2100000, guid: a08f97e5b75379d40b08ff5f74847d5c, type: 2} + 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: 3 + m_MinimumChartSize: 4 + m_AutoUVMaxDistance: 0.5 + m_AutoUVMaxAngle: 89 + m_LightmapParameters: {fileID: 0} + m_SortingLayerID: 0 + m_SortingLayer: 0 + m_SortingOrder: 0 +--- !u!65 &1358453177 +BoxCollider: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1358453174} + m_Material: {fileID: 0} + m_IsTrigger: 0 + m_Enabled: 1 + serializedVersion: 2 + m_Size: {x: 1, y: 1, z: 1} + m_Center: {x: 0, y: 0, z: 0} +--- !u!33 &1358453178 +MeshFilter: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1358453174} + m_Mesh: {fileID: 10202, guid: 0000000000000000e000000000000000, type: 0} +--- !u!1 &1394933339 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 100000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1394933340} + - component: {fileID: 1394933345} + - component: {fileID: 1394933344} + - component: {fileID: 1394933343} + - component: {fileID: 1394933342} + - component: {fileID: 1394933341} + m_Layer: 0 + m_Name: bot + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &1394933340 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 400000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1394933339} + m_LocalRotation: {x: 0, y: 1, z: 0, w: 0} + m_LocalPosition: {x: -29.059395, y: 24.925999, z: 12.23288} + m_LocalScale: {x: 2, y: 2, z: 2} + m_Children: [] + m_Father: {fileID: 193687608} + m_RootOrder: 23 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!82 &1394933341 +AudioSource: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1394933339} + m_Enabled: 1 + serializedVersion: 4 + OutputAudioMixerGroup: {fileID: 0} + m_audioClip: {fileID: 0} + m_PlayOnAwake: 1 + m_Volume: 1 + m_Pitch: 1 + Loop: 0 + Mute: 0 + Spatialize: 0 + SpatializePostEffects: 0 + Priority: 128 + DopplerLevel: 1 + MinDistance: 1 + MaxDistance: 500 + Pan2D: 0 + rolloffMode: 0 + BypassEffects: 0 + BypassListenerEffects: 0 + BypassReverbZones: 0 + rolloffCustomCurve: + serializedVersion: 2 + m_Curve: + - serializedVersion: 3 + time: 0 + value: 1 + inSlope: 0 + outSlope: 0 + tangentMode: 0 + weightedMode: 0 + inWeight: 0.33333334 + outWeight: 0.33333334 + - serializedVersion: 3 + time: 1 + value: 0 + inSlope: 0 + outSlope: 0 + tangentMode: 0 + weightedMode: 0 + inWeight: 0.33333334 + outWeight: 0.33333334 + m_PreInfinity: 2 + m_PostInfinity: 2 + m_RotationOrder: 4 + panLevelCustomCurve: + serializedVersion: 2 + m_Curve: + - serializedVersion: 3 + time: 0 + value: 1 + inSlope: 0 + outSlope: 0 + tangentMode: 0 + weightedMode: 0 + inWeight: 0.33333334 + outWeight: 0.33333334 + m_PreInfinity: 2 + m_PostInfinity: 2 + m_RotationOrder: 4 + spreadCustomCurve: + serializedVersion: 2 + m_Curve: + - serializedVersion: 3 + time: 0 + value: 0 + inSlope: 0 + outSlope: 0 + tangentMode: 0 + weightedMode: 0 + inWeight: 0.33333334 + outWeight: 0.33333334 + m_PreInfinity: 2 + m_PostInfinity: 2 + m_RotationOrder: 4 + reverbZoneMixCustomCurve: + serializedVersion: 2 + m_Curve: + - serializedVersion: 3 + time: 0 + value: 1 + inSlope: 0 + outSlope: 0 + tangentMode: 0 + weightedMode: 0 + inWeight: 0.33333334 + outWeight: 0.33333334 + m_PreInfinity: 2 + m_PostInfinity: 2 + m_RotationOrder: 4 +--- !u!65 &1394933342 +BoxCollider: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1394933339} + m_Material: {fileID: 0} + m_IsTrigger: 0 + m_Enabled: 1 + serializedVersion: 2 + m_Size: {x: 1.2738054, y: 0.6292588, z: 0.83338344} + m_Center: {x: -0.00000014901161, y: -0.06340176, z: 0.041081354} +--- !u!195 &1394933343 +NavMeshAgent: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1394933339} + m_Enabled: 1 + m_AgentTypeID: 0 + m_Radius: 0.6369026 + m_Speed: 10 + m_Acceleration: 10 + avoidancePriority: 50 + m_AngularSpeed: 1200 + m_StoppingDistance: 0 + m_AutoTraverseOffMeshLink: 1 + m_AutoBraking: 1 + m_AutoRepath: 1 + m_Height: 0.5024553 + m_BaseOffset: 0.25122765 + m_WalkableMask: 4294967295 + m_ObstacleAvoidanceType: 4 +--- !u!23 &1394933344 +MeshRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 2300000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1394933339} + m_Enabled: 1 + m_CastShadows: 1 + m_ReceiveShadows: 1 + m_DynamicOccludee: 1 + m_MotionVectors: 1 + m_LightProbeUsage: 0 + m_ReflectionProbeUsage: 1 + m_RenderingLayerMask: 1 + m_RendererPriority: 0 + m_Materials: + - {fileID: 2100000, guid: fecc96c64c214ce40835ac4c3c3099e8, type: 2} + 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: 3 + m_MinimumChartSize: 4 + m_AutoUVMaxDistance: 0.5 + m_AutoUVMaxAngle: 89 + m_LightmapParameters: {fileID: 0} + m_SortingLayerID: 0 + m_SortingLayer: 0 + m_SortingOrder: 0 +--- !u!33 &1394933345 +MeshFilter: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 3300000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1394933339} + m_Mesh: {fileID: 4300000, guid: 55e5ab7e66bd2eb49bc96935fe0bd04a, type: 3} +--- !u!1 &1399255297 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 100000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1399255298} + - component: {fileID: 1399255303} + - component: {fileID: 1399255302} + - component: {fileID: 1399255301} + m_Layer: 0 + m_Name: bot + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &1399255298 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 400000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1399255297} + m_LocalRotation: {x: 0, y: 1, z: 0, w: 0} + m_LocalPosition: {x: -29.059395, y: 24.925999, z: -15.206207} + m_LocalScale: {x: 2, y: 2, z: 2} + m_Children: [] + m_Father: {fileID: 193687608} + m_RootOrder: 6 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!195 &1399255301 +NavMeshAgent: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1399255297} + m_Enabled: 1 + m_AgentTypeID: 0 + m_Radius: 0.6369026 + m_Speed: 10 + m_Acceleration: 10 + avoidancePriority: 50 + m_AngularSpeed: 1200 + m_StoppingDistance: 0 + m_AutoTraverseOffMeshLink: 1 + m_AutoBraking: 1 + m_AutoRepath: 1 + m_Height: 0.5024553 + m_BaseOffset: 0.25122765 + m_WalkableMask: 4294967295 + m_ObstacleAvoidanceType: 4 +--- !u!23 &1399255302 +MeshRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 2300000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1399255297} + m_Enabled: 1 + m_CastShadows: 1 + m_ReceiveShadows: 1 + m_DynamicOccludee: 1 + m_MotionVectors: 1 + m_LightProbeUsage: 0 + m_ReflectionProbeUsage: 1 + m_RenderingLayerMask: 1 + m_RendererPriority: 0 + m_Materials: + - {fileID: 2100000, guid: fecc96c64c214ce40835ac4c3c3099e8, type: 2} + 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: 3 + m_MinimumChartSize: 4 + m_AutoUVMaxDistance: 0.5 + m_AutoUVMaxAngle: 89 + m_LightmapParameters: {fileID: 0} + m_SortingLayerID: 0 + m_SortingLayer: 0 + m_SortingOrder: 0 +--- !u!33 &1399255303 +MeshFilter: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 3300000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1399255297} + m_Mesh: {fileID: 4300000, guid: 55e5ab7e66bd2eb49bc96935fe0bd04a, type: 3} +--- !u!1 &1412844391 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 100000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1412844392} + - component: {fileID: 1412844395} + - component: {fileID: 1412844394} + - component: {fileID: 1412844393} + m_Layer: 0 + m_Name: bot + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &1412844392 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 400000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1412844391} + m_LocalRotation: {x: 0, y: 1, z: 0, w: 0} + m_LocalPosition: {x: -9.986802, y: 24.925999, z: 0.6628113} + m_LocalScale: {x: 2, y: 2, z: 2} + m_Children: [] + m_Father: {fileID: 66600218} + m_RootOrder: 8 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!195 &1412844393 +NavMeshAgent: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1412844391} + m_Enabled: 1 + m_AgentTypeID: 0 + m_Radius: 0.6369026 + m_Speed: 15 + m_Acceleration: 15 + avoidancePriority: 50 + m_AngularSpeed: 1200 + m_StoppingDistance: 0 + m_AutoTraverseOffMeshLink: 1 + m_AutoBraking: 1 + m_AutoRepath: 1 + m_Height: 0.5024553 + m_BaseOffset: 0.25122765 + m_WalkableMask: 4294967295 + m_ObstacleAvoidanceType: 4 +--- !u!23 &1412844394 +MeshRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 2300000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1412844391} + m_Enabled: 1 + m_CastShadows: 1 + m_ReceiveShadows: 1 + m_DynamicOccludee: 1 + m_MotionVectors: 1 + m_LightProbeUsage: 0 + m_ReflectionProbeUsage: 1 + m_RenderingLayerMask: 1 + m_RendererPriority: 0 + m_Materials: + - {fileID: 2100000, guid: fecc96c64c214ce40835ac4c3c3099e8, type: 2} + 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: 3 + m_MinimumChartSize: 4 + m_AutoUVMaxDistance: 0.5 + m_AutoUVMaxAngle: 89 + m_LightmapParameters: {fileID: 0} + m_SortingLayerID: 0 + m_SortingLayer: 0 + m_SortingOrder: 0 +--- !u!33 &1412844395 +MeshFilter: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 3300000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1412844391} + m_Mesh: {fileID: 4300000, guid: 55e5ab7e66bd2eb49bc96935fe0bd04a, type: 3} +--- !u!1 &1446227434 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1446227435} + - component: {fileID: 1446227438} + - component: {fileID: 1446227437} + - component: {fileID: 1446227436} + m_Layer: 2 + m_Name: Plane + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 4294967295 + m_IsActive: 1 +--- !u!4 &1446227435 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1446227434} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: 0, y: 0, z: 0} + m_LocalScale: {x: 10, y: 1, z: 10} + m_Children: [] + m_Father: {fileID: 476658879} + m_RootOrder: 4 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!23 &1446227436 +MeshRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1446227434} + m_Enabled: 1 + m_CastShadows: 1 + m_ReceiveShadows: 1 + m_DynamicOccludee: 1 + m_MotionVectors: 1 + m_LightProbeUsage: 0 + m_ReflectionProbeUsage: 1 + m_RenderingLayerMask: 1 + m_RendererPriority: 0 + m_Materials: + - {fileID: 2100000, guid: dbcdee902c373ec4cbb9e693617708b9, type: 2} + 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: 3 + m_MinimumChartSize: 4 + m_AutoUVMaxDistance: 0.5 + m_AutoUVMaxAngle: 89 + m_LightmapParameters: {fileID: 0} + m_SortingLayerID: 0 + m_SortingLayer: 0 + m_SortingOrder: 0 +--- !u!64 &1446227437 +MeshCollider: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1446227434} + m_Material: {fileID: 0} + m_IsTrigger: 0 + m_Enabled: 1 + serializedVersion: 3 + m_Convex: 0 + m_CookingOptions: 14 + m_Mesh: {fileID: 10209, guid: 0000000000000000e000000000000000, type: 0} +--- !u!33 &1446227438 +MeshFilter: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1446227434} + m_Mesh: {fileID: 10209, guid: 0000000000000000e000000000000000, type: 0} +--- !u!1 &1449224517 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 100000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1449224518} + - component: {fileID: 1449224521} + - component: {fileID: 1449224520} + - component: {fileID: 1449224519} + m_Layer: 0 + m_Name: bot + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &1449224518 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 400000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1449224517} + m_LocalRotation: {x: 0, y: 1, z: 0, w: 0} + m_LocalPosition: {x: -9.986802, y: 24.925999, z: 9.82312} + m_LocalScale: {x: 2, y: 2, z: 2} + m_Children: [] + m_Father: {fileID: 1151274299} + m_RootOrder: 0 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!195 &1449224519 +NavMeshAgent: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1449224517} + m_Enabled: 1 + m_AgentTypeID: 0 + m_Radius: 0.6369026 + m_Speed: 10 + m_Acceleration: 8 + avoidancePriority: 50 + m_AngularSpeed: 1200 + m_StoppingDistance: 0 + m_AutoTraverseOffMeshLink: 1 + m_AutoBraking: 1 + m_AutoRepath: 1 + m_Height: 0.5024553 + m_BaseOffset: 0.25122765 + m_WalkableMask: 4294967295 + m_ObstacleAvoidanceType: 4 +--- !u!23 &1449224520 +MeshRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 2300000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1449224517} + m_Enabled: 1 + m_CastShadows: 1 + m_ReceiveShadows: 1 + m_DynamicOccludee: 1 + m_MotionVectors: 1 + m_LightProbeUsage: 0 + m_ReflectionProbeUsage: 1 + m_RenderingLayerMask: 1 + m_RendererPriority: 0 + m_Materials: + - {fileID: 2100000, guid: fecc96c64c214ce40835ac4c3c3099e8, type: 2} + 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: 3 + m_MinimumChartSize: 4 + m_AutoUVMaxDistance: 0.5 + m_AutoUVMaxAngle: 89 + m_LightmapParameters: {fileID: 0} + m_SortingLayerID: 0 + m_SortingLayer: 0 + m_SortingOrder: 0 +--- !u!33 &1449224521 +MeshFilter: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 3300000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1449224517} + m_Mesh: {fileID: 4300000, guid: 55e5ab7e66bd2eb49bc96935fe0bd04a, type: 3} +--- !u!1 &1462659478 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1462659479} + - component: {fileID: 1462659482} + - component: {fileID: 1462659481} + - component: {fileID: 1462659480} + m_Layer: 2 + m_Name: Cube + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 4294967295 + m_IsActive: 1 +--- !u!4 &1462659479 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1462659478} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: 0, y: 1.5, z: 30} + m_LocalScale: {x: 60, y: 3, z: 2} + m_Children: [] + m_Father: {fileID: 122009232} + m_RootOrder: 2 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!23 &1462659480 +MeshRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1462659478} + m_Enabled: 1 + m_CastShadows: 1 + m_ReceiveShadows: 1 + m_DynamicOccludee: 1 + m_MotionVectors: 1 + m_LightProbeUsage: 0 + m_ReflectionProbeUsage: 1 + m_RenderingLayerMask: 1 + m_RendererPriority: 0 + m_Materials: + - {fileID: 2100000, guid: a08f97e5b75379d40b08ff5f74847d5c, type: 2} + 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: 3 + m_MinimumChartSize: 4 + m_AutoUVMaxDistance: 0.5 + m_AutoUVMaxAngle: 89 + m_LightmapParameters: {fileID: 0} + m_SortingLayerID: 0 + m_SortingLayer: 0 + m_SortingOrder: 0 +--- !u!65 &1462659481 +BoxCollider: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1462659478} + m_Material: {fileID: 0} + m_IsTrigger: 0 + m_Enabled: 1 + serializedVersion: 2 + m_Size: {x: 1, y: 1, z: 1} + m_Center: {x: 0, y: 0, z: 0} +--- !u!33 &1462659482 +MeshFilter: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1462659478} + m_Mesh: {fileID: 10202, guid: 0000000000000000e000000000000000, type: 0} +--- !u!1 &1476304420 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1476304421} + - component: {fileID: 1476304424} + - component: {fileID: 1476304423} + - component: {fileID: 1476304422} + m_Layer: 2 + m_Name: Cube + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 4294967295 + m_IsActive: 1 +--- !u!4 &1476304421 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1476304420} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: 50, y: 1.5, z: 0} + m_LocalScale: {x: 2, y: 3, z: 100} + m_Children: [] + m_Father: {fileID: 476658879} + m_RootOrder: 2 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!23 &1476304422 +MeshRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1476304420} + m_Enabled: 1 + m_CastShadows: 1 + m_ReceiveShadows: 1 + m_DynamicOccludee: 1 + m_MotionVectors: 1 + m_LightProbeUsage: 0 + m_ReflectionProbeUsage: 1 + m_RenderingLayerMask: 1 + m_RendererPriority: 0 + m_Materials: + - {fileID: 2100000, guid: a08f97e5b75379d40b08ff5f74847d5c, type: 2} + 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: 3 + m_MinimumChartSize: 4 + m_AutoUVMaxDistance: 0.5 + m_AutoUVMaxAngle: 89 + m_LightmapParameters: {fileID: 0} + m_SortingLayerID: 0 + m_SortingLayer: 0 + m_SortingOrder: 0 +--- !u!65 &1476304423 +BoxCollider: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1476304420} + m_Material: {fileID: 0} + m_IsTrigger: 0 + m_Enabled: 1 + serializedVersion: 2 + m_Size: {x: 1, y: 1, z: 1} + m_Center: {x: 0, y: 0, z: 0} +--- !u!33 &1476304424 +MeshFilter: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1476304420} + m_Mesh: {fileID: 10202, guid: 0000000000000000e000000000000000, type: 0} +--- !u!1 &1487380454 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 100000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1487380455} + - component: {fileID: 1487380458} + - component: {fileID: 1487380457} + - component: {fileID: 1487380456} + m_Layer: 0 + m_Name: bot + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &1487380455 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 400000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1487380454} + m_LocalRotation: {x: 0, y: 1, z: 0, w: 0} + m_LocalPosition: {x: -21.553186, y: 24.925999, z: 16.007904} + m_LocalScale: {x: 2, y: 2, z: 2} + m_Children: [] + m_Father: {fileID: 1151274299} + m_RootOrder: 9 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!195 &1487380456 +NavMeshAgent: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1487380454} + m_Enabled: 1 + m_AgentTypeID: 0 + m_Radius: 0.6369026 + m_Speed: 10 + m_Acceleration: 8 + avoidancePriority: 50 + m_AngularSpeed: 1200 + m_StoppingDistance: 0 + m_AutoTraverseOffMeshLink: 1 + m_AutoBraking: 1 + m_AutoRepath: 1 + m_Height: 0.5024553 + m_BaseOffset: 0.25122765 + m_WalkableMask: 4294967295 + m_ObstacleAvoidanceType: 4 +--- !u!23 &1487380457 +MeshRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 2300000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1487380454} + m_Enabled: 1 + m_CastShadows: 1 + m_ReceiveShadows: 1 + m_DynamicOccludee: 1 + m_MotionVectors: 1 + m_LightProbeUsage: 0 + m_ReflectionProbeUsage: 1 + m_RenderingLayerMask: 1 + m_RendererPriority: 0 + m_Materials: + - {fileID: 2100000, guid: fecc96c64c214ce40835ac4c3c3099e8, type: 2} + 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: 3 + m_MinimumChartSize: 4 + m_AutoUVMaxDistance: 0.5 + m_AutoUVMaxAngle: 89 + m_LightmapParameters: {fileID: 0} + m_SortingLayerID: 0 + m_SortingLayer: 0 + m_SortingOrder: 0 +--- !u!33 &1487380458 +MeshFilter: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 3300000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1487380454} + m_Mesh: {fileID: 4300000, guid: 55e5ab7e66bd2eb49bc96935fe0bd04a, type: 3} +--- !u!1 &1487439662 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1487439663} + - component: {fileID: 1487439666} + - component: {fileID: 1487439665} + - component: {fileID: 1487439664} + m_Layer: 2 + m_Name: Cube + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 4294967295 + m_IsActive: 1 +--- !u!4 &1487439663 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1487439662} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: 50, y: 1.5, z: 0} + m_LocalScale: {x: 2, y: 3, z: 100} + m_Children: [] + m_Father: {fileID: 122009232} + m_RootOrder: 8 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!23 &1487439664 +MeshRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1487439662} + m_Enabled: 1 + m_CastShadows: 1 + m_ReceiveShadows: 1 + m_DynamicOccludee: 1 + m_MotionVectors: 1 + m_LightProbeUsage: 0 + m_ReflectionProbeUsage: 1 + m_RenderingLayerMask: 1 + m_RendererPriority: 0 + m_Materials: + - {fileID: 2100000, guid: a08f97e5b75379d40b08ff5f74847d5c, type: 2} + 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: 3 + m_MinimumChartSize: 4 + m_AutoUVMaxDistance: 0.5 + m_AutoUVMaxAngle: 89 + m_LightmapParameters: {fileID: 0} + m_SortingLayerID: 0 + m_SortingLayer: 0 + m_SortingOrder: 0 +--- !u!65 &1487439665 +BoxCollider: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1487439662} + m_Material: {fileID: 0} + m_IsTrigger: 0 + m_Enabled: 1 + serializedVersion: 2 + m_Size: {x: 1, y: 1, z: 1} + m_Center: {x: 0, y: 0, z: 0} +--- !u!33 &1487439666 +MeshFilter: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1487439662} + m_Mesh: {fileID: 10202, guid: 0000000000000000e000000000000000, type: 0} +--- !u!1 &1518382618 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 100000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1518382619} + - component: {fileID: 1518382622} + - component: {fileID: 1518382621} + - component: {fileID: 1518382620} + m_Layer: 0 + m_Name: bot + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &1518382619 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 400000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1518382618} + m_LocalRotation: {x: 0, y: 1, z: 0, w: 0} + m_LocalPosition: {x: -9.986802, y: 24.925999, z: -11.278946} + m_LocalScale: {x: 2, y: 2, z: 2} + m_Children: [] + m_Father: {fileID: 193687608} + m_RootOrder: 20 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!195 &1518382620 +NavMeshAgent: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1518382618} + m_Enabled: 1 + m_AgentTypeID: 0 + m_Radius: 0.6369026 + m_Speed: 10 + m_Acceleration: 10 + avoidancePriority: 50 + m_AngularSpeed: 1200 + m_StoppingDistance: 0 + m_AutoTraverseOffMeshLink: 1 + m_AutoBraking: 1 + m_AutoRepath: 1 + m_Height: 0.5024553 + m_BaseOffset: 0.25122765 + m_WalkableMask: 4294967295 + m_ObstacleAvoidanceType: 4 +--- !u!23 &1518382621 +MeshRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 2300000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1518382618} + m_Enabled: 1 + m_CastShadows: 1 + m_ReceiveShadows: 1 + m_DynamicOccludee: 1 + m_MotionVectors: 1 + m_LightProbeUsage: 0 + m_ReflectionProbeUsage: 1 + m_RenderingLayerMask: 1 + m_RendererPriority: 0 + m_Materials: + - {fileID: 2100000, guid: fecc96c64c214ce40835ac4c3c3099e8, type: 2} + 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: 3 + m_MinimumChartSize: 4 + m_AutoUVMaxDistance: 0.5 + m_AutoUVMaxAngle: 89 + m_LightmapParameters: {fileID: 0} + m_SortingLayerID: 0 + m_SortingLayer: 0 + m_SortingOrder: 0 +--- !u!33 &1518382622 +MeshFilter: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 3300000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1518382618} + m_Mesh: {fileID: 4300000, guid: 55e5ab7e66bd2eb49bc96935fe0bd04a, type: 3} +--- !u!1 &1572679521 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1572679522} + - component: {fileID: 1572679525} + - component: {fileID: 1572679524} + - component: {fileID: 1572679523} + m_Layer: 2 + m_Name: Cube + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 4294967295 + m_IsActive: 1 +--- !u!4 &1572679522 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1572679521} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: 30, y: 1.5, z: -16} + m_LocalScale: {x: 2, y: 3, z: 27.5} + m_Children: [] + m_Father: {fileID: 122009232} + m_RootOrder: 5 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!23 &1572679523 +MeshRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1572679521} + m_Enabled: 1 + m_CastShadows: 1 + m_ReceiveShadows: 1 + m_DynamicOccludee: 1 + m_MotionVectors: 1 + m_LightProbeUsage: 0 + m_ReflectionProbeUsage: 1 + m_RenderingLayerMask: 1 + m_RendererPriority: 0 + m_Materials: + - {fileID: 2100000, guid: a08f97e5b75379d40b08ff5f74847d5c, type: 2} + 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: 3 + m_MinimumChartSize: 4 + m_AutoUVMaxDistance: 0.5 + m_AutoUVMaxAngle: 89 + m_LightmapParameters: {fileID: 0} + m_SortingLayerID: 0 + m_SortingLayer: 0 + m_SortingOrder: 0 +--- !u!65 &1572679524 +BoxCollider: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1572679521} + m_Material: {fileID: 0} + m_IsTrigger: 0 + m_Enabled: 1 + serializedVersion: 2 + m_Size: {x: 1, y: 1, z: 1} + m_Center: {x: 0, y: 0, z: 0} +--- !u!33 &1572679525 +MeshFilter: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1572679521} + m_Mesh: {fileID: 10202, guid: 0000000000000000e000000000000000, type: 0} +--- !u!1 &1577869803 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1577869804} + - component: {fileID: 1577869805} + - component: {fileID: 1577869806} + m_Layer: 0 + m_Name: 3 + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &1577869804 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1577869803} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: 40, y: 0, z: 40} + m_LocalScale: {x: 1, y: 1, z: 1} + m_Children: [] + m_Father: {fileID: 1867949263} + m_RootOrder: 4 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!33 &1577869805 +MeshFilter: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1577869803} + m_Mesh: {fileID: 10207, guid: 0000000000000000e000000000000000, type: 0} +--- !u!23 &1577869806 +MeshRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1577869803} + m_Enabled: 1 + m_CastShadows: 1 + m_ReceiveShadows: 1 + m_DynamicOccludee: 1 + m_MotionVectors: 1 + m_LightProbeUsage: 0 + m_ReflectionProbeUsage: 1 + m_RenderingLayerMask: 1 + m_RendererPriority: 0 + m_Materials: + - {fileID: 10302, 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: 3 + m_MinimumChartSize: 4 + m_AutoUVMaxDistance: 0.5 + m_AutoUVMaxAngle: 89 + m_LightmapParameters: {fileID: 0} + m_SortingLayerID: 0 + m_SortingLayer: 0 + m_SortingOrder: 0 +--- !u!1 &1596608536 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1596608537} + - component: {fileID: 1596608540} + - component: {fileID: 1596608539} + - component: {fileID: 1596608538} + m_Layer: 4 + m_Name: Cube + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 4294967295 + m_IsActive: 1 +--- !u!4 &1596608537 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1596608536} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: 0, y: 1.5, z: 0} + m_LocalScale: {x: 15, y: 3, z: 2} + m_Children: [] + m_Father: {fileID: 122009232} + m_RootOrder: 0 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!23 &1596608538 +MeshRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1596608536} + m_Enabled: 1 + m_CastShadows: 1 + m_ReceiveShadows: 1 + m_DynamicOccludee: 1 + m_MotionVectors: 1 + m_LightProbeUsage: 0 + m_ReflectionProbeUsage: 1 + m_RenderingLayerMask: 1 + m_RendererPriority: 0 + m_Materials: + - {fileID: 2100000, guid: a08f97e5b75379d40b08ff5f74847d5c, type: 2} + 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: 3 + m_MinimumChartSize: 4 + m_AutoUVMaxDistance: 0.5 + m_AutoUVMaxAngle: 89 + m_LightmapParameters: {fileID: 0} + m_SortingLayerID: 0 + m_SortingLayer: 0 + m_SortingOrder: 0 +--- !u!65 &1596608539 +BoxCollider: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1596608536} + m_Material: {fileID: 0} + m_IsTrigger: 0 + m_Enabled: 1 + serializedVersion: 2 + m_Size: {x: 1, y: 1, z: 1} + m_Center: {x: 0, y: 0, z: 0} +--- !u!33 &1596608540 +MeshFilter: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1596608536} + m_Mesh: {fileID: 10202, guid: 0000000000000000e000000000000000, type: 0} +--- !u!1 &1620701895 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1620701896} + - component: {fileID: 1620701899} + - component: {fileID: 1620701898} + - component: {fileID: 1620701897} + m_Layer: 2 + m_Name: Cube + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 4294967295 + m_IsActive: 1 +--- !u!4 &1620701896 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1620701895} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: -30, y: 1.5, z: 0} + m_LocalScale: {x: 2, y: 3, z: 60} + m_Children: [] + m_Father: {fileID: 122009232} + m_RootOrder: 3 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!23 &1620701897 +MeshRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1620701895} + m_Enabled: 1 + m_CastShadows: 1 + m_ReceiveShadows: 1 + m_DynamicOccludee: 1 + m_MotionVectors: 1 + m_LightProbeUsage: 0 + m_ReflectionProbeUsage: 1 + m_RenderingLayerMask: 1 + m_RendererPriority: 0 + m_Materials: + - {fileID: 2100000, guid: a08f97e5b75379d40b08ff5f74847d5c, type: 2} + 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: 3 + m_MinimumChartSize: 4 + m_AutoUVMaxDistance: 0.5 + m_AutoUVMaxAngle: 89 + m_LightmapParameters: {fileID: 0} + m_SortingLayerID: 0 + m_SortingLayer: 0 + m_SortingOrder: 0 +--- !u!65 &1620701898 +BoxCollider: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1620701895} + m_Material: {fileID: 0} + m_IsTrigger: 0 + m_Enabled: 1 + serializedVersion: 2 + m_Size: {x: 1, y: 1, z: 1} + m_Center: {x: 0, y: 0, z: 0} +--- !u!33 &1620701899 +MeshFilter: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1620701895} + m_Mesh: {fileID: 10202, guid: 0000000000000000e000000000000000, type: 0} +--- !u!1 &1674801248 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 100000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1674801249} + - component: {fileID: 1674801254} + - component: {fileID: 1674801253} + - component: {fileID: 1674801252} + m_Layer: 0 + m_Name: bot + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &1674801249 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 400000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1674801248} + m_LocalRotation: {x: 0, y: 1, z: 0, w: 0} + m_LocalPosition: {x: -29.059395, y: 24.925999, z: -12.2756195} + m_LocalScale: {x: 2, y: 2, z: 2} + m_Children: [] + m_Father: {fileID: 193687608} + m_RootOrder: 15 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!195 &1674801252 +NavMeshAgent: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1674801248} + m_Enabled: 1 + m_AgentTypeID: 0 + m_Radius: 0.6369026 + m_Speed: 10 + m_Acceleration: 10 + avoidancePriority: 50 + m_AngularSpeed: 1200 + m_StoppingDistance: 0 + m_AutoTraverseOffMeshLink: 1 + m_AutoBraking: 1 + m_AutoRepath: 1 + m_Height: 0.5024553 + m_BaseOffset: 0.25122765 + m_WalkableMask: 4294967295 + m_ObstacleAvoidanceType: 4 +--- !u!23 &1674801253 +MeshRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 2300000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1674801248} + m_Enabled: 1 + m_CastShadows: 1 + m_ReceiveShadows: 1 + m_DynamicOccludee: 1 + m_MotionVectors: 1 + m_LightProbeUsage: 0 + m_ReflectionProbeUsage: 1 + m_RenderingLayerMask: 1 + m_RendererPriority: 0 + m_Materials: + - {fileID: 2100000, guid: fecc96c64c214ce40835ac4c3c3099e8, type: 2} + 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: 3 + m_MinimumChartSize: 4 + m_AutoUVMaxDistance: 0.5 + m_AutoUVMaxAngle: 89 + m_LightmapParameters: {fileID: 0} + m_SortingLayerID: 0 + m_SortingLayer: 0 + m_SortingOrder: 0 +--- !u!33 &1674801254 +MeshFilter: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 3300000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1674801248} + m_Mesh: {fileID: 4300000, guid: 55e5ab7e66bd2eb49bc96935fe0bd04a, type: 3} +--- !u!1 &1679165112 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1679165113} + - component: {fileID: 1679165114} + - component: {fileID: 1679165115} + m_Layer: 0 + m_Name: 1 + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &1679165113 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1679165112} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: -25, y: 0, z: 9.982804} + m_LocalScale: {x: 1, y: 1, z: 1} + m_Children: [] + m_Father: {fileID: 1867949263} + m_RootOrder: 0 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!33 &1679165114 +MeshFilter: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1679165112} + m_Mesh: {fileID: 10207, guid: 0000000000000000e000000000000000, type: 0} +--- !u!23 &1679165115 +MeshRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1679165112} + m_Enabled: 1 + m_CastShadows: 1 + m_ReceiveShadows: 1 + m_DynamicOccludee: 1 + m_MotionVectors: 1 + m_LightProbeUsage: 0 + m_ReflectionProbeUsage: 1 + m_RenderingLayerMask: 1 + m_RendererPriority: 0 + m_Materials: + - {fileID: 10302, 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: 3 + m_MinimumChartSize: 4 + m_AutoUVMaxDistance: 0.5 + m_AutoUVMaxAngle: 89 + m_LightmapParameters: {fileID: 0} + m_SortingLayerID: 0 + m_SortingLayer: 0 + m_SortingOrder: 0 +--- !u!1 &1716371254 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1716371255} + - component: {fileID: 1716371257} + - component: {fileID: 1716371256} + m_Layer: 0 + m_Name: 4a + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &1716371255 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1716371254} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: -17.264313, y: 1, z: -158.53264} + m_LocalScale: {x: 1, y: 1, z: 1} + m_Children: [] + m_Father: {fileID: 1867949263} + m_RootOrder: 7 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!23 &1716371256 +MeshRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1716371254} + m_Enabled: 1 + m_CastShadows: 1 + m_ReceiveShadows: 1 + m_DynamicOccludee: 1 + m_MotionVectors: 1 + m_LightProbeUsage: 0 + m_ReflectionProbeUsage: 1 + m_RenderingLayerMask: 1 + m_RendererPriority: 0 + m_Materials: + - {fileID: 10302, 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: 3 + m_MinimumChartSize: 4 + m_AutoUVMaxDistance: 0.5 + m_AutoUVMaxAngle: 89 + m_LightmapParameters: {fileID: 0} + m_SortingLayerID: 0 + m_SortingLayer: 0 + m_SortingOrder: 0 +--- !u!33 &1716371257 +MeshFilter: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1716371254} + m_Mesh: {fileID: 10207, guid: 0000000000000000e000000000000000, type: 0} +--- !u!1 &1726546186 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 100000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1726546187} + - component: {fileID: 1726546190} + - component: {fileID: 1726546189} + - component: {fileID: 1726546188} + m_Layer: 0 + m_Name: bot + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &1726546187 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 400000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1726546186} + m_LocalRotation: {x: 0, y: 1, z: 0, w: 0} + m_LocalPosition: {x: -9.986802, y: 24.925999, z: 0.6628113} + m_LocalScale: {x: 2, y: 2, z: 2} + m_Children: [] + m_Father: {fileID: 193687608} + m_RootOrder: 8 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!195 &1726546188 +NavMeshAgent: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1726546186} + m_Enabled: 1 + m_AgentTypeID: 0 + m_Radius: 0.6369026 + m_Speed: 10 + m_Acceleration: 10 + avoidancePriority: 50 + m_AngularSpeed: 1200 + m_StoppingDistance: 0 + m_AutoTraverseOffMeshLink: 1 + m_AutoBraking: 1 + m_AutoRepath: 1 + m_Height: 0.5024553 + m_BaseOffset: 0.25122765 + m_WalkableMask: 4294967295 + m_ObstacleAvoidanceType: 4 +--- !u!23 &1726546189 +MeshRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 2300000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1726546186} + m_Enabled: 1 + m_CastShadows: 1 + m_ReceiveShadows: 1 + m_DynamicOccludee: 1 + m_MotionVectors: 1 + m_LightProbeUsage: 0 + m_ReflectionProbeUsage: 1 + m_RenderingLayerMask: 1 + m_RendererPriority: 0 + m_Materials: + - {fileID: 2100000, guid: fecc96c64c214ce40835ac4c3c3099e8, type: 2} + 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: 3 + m_MinimumChartSize: 4 + m_AutoUVMaxDistance: 0.5 + m_AutoUVMaxAngle: 89 + m_LightmapParameters: {fileID: 0} + m_SortingLayerID: 0 + m_SortingLayer: 0 + m_SortingOrder: 0 +--- !u!33 &1726546190 +MeshFilter: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 3300000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1726546186} + m_Mesh: {fileID: 4300000, guid: 55e5ab7e66bd2eb49bc96935fe0bd04a, type: 3} +--- !u!1 &1792926649 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 100000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1792926650} + - component: {fileID: 1792926655} + - component: {fileID: 1792926654} + - component: {fileID: 1792926653} + m_Layer: 0 + m_Name: bot + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &1792926650 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 400000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1792926649} + m_LocalRotation: {x: 6.123233e-17, y: 1, z: 6.123233e-17, w: 0.00000013315805} + m_LocalPosition: {x: -14.728401, y: 24.925999, z: -3.2644491} + m_LocalScale: {x: 2, y: 2, z: 2} + m_Children: [] + m_Father: {fileID: 1151274299} + m_RootOrder: 5 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!195 &1792926653 +NavMeshAgent: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1792926649} + m_Enabled: 1 + m_AgentTypeID: 0 + m_Radius: 0.6369026 + m_Speed: 10 + m_Acceleration: 8 + avoidancePriority: 50 + m_AngularSpeed: 1200 + m_StoppingDistance: 0 + m_AutoTraverseOffMeshLink: 1 + m_AutoBraking: 1 + m_AutoRepath: 1 + m_Height: 0.5024553 + m_BaseOffset: 0.25122765 + m_WalkableMask: 4294967295 + m_ObstacleAvoidanceType: 4 +--- !u!23 &1792926654 +MeshRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 2300000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1792926649} + m_Enabled: 1 + m_CastShadows: 1 + m_ReceiveShadows: 1 + m_DynamicOccludee: 1 + m_MotionVectors: 1 + m_LightProbeUsage: 0 + m_ReflectionProbeUsage: 1 + m_RenderingLayerMask: 1 + m_RendererPriority: 0 + m_Materials: + - {fileID: 2100000, guid: fecc96c64c214ce40835ac4c3c3099e8, type: 2} + 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: 3 + m_MinimumChartSize: 4 + m_AutoUVMaxDistance: 0.5 + m_AutoUVMaxAngle: 89 + m_LightmapParameters: {fileID: 0} + m_SortingLayerID: 0 + m_SortingLayer: 0 + m_SortingOrder: 0 +--- !u!33 &1792926655 +MeshFilter: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 3300000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1792926649} + m_Mesh: {fileID: 4300000, guid: 55e5ab7e66bd2eb49bc96935fe0bd04a, type: 3} +--- !u!1 &1833674480 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 100000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1833674481} + - component: {fileID: 1833674486} + - component: {fileID: 1833674485} + - component: {fileID: 1833674484} + m_Layer: 0 + m_Name: bot + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &1833674481 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 400000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1833674480} + m_LocalRotation: {x: 0, y: 1, z: 0, w: 0} + m_LocalPosition: {x: -29.059395, y: 24.925999, z: 15.903397} + m_LocalScale: {x: 2, y: 2, z: 2} + m_Children: [] + m_Father: {fileID: 66600218} + m_RootOrder: 1 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!195 &1833674484 +NavMeshAgent: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1833674480} + m_Enabled: 1 + m_AgentTypeID: 0 + m_Radius: 0.6369026 + m_Speed: 15 + m_Acceleration: 15 + avoidancePriority: 50 + m_AngularSpeed: 1200 + m_StoppingDistance: 0 + m_AutoTraverseOffMeshLink: 1 + m_AutoBraking: 1 + m_AutoRepath: 1 + m_Height: 0.5024553 + m_BaseOffset: 0.25122765 + m_WalkableMask: 4294967295 + m_ObstacleAvoidanceType: 4 +--- !u!23 &1833674485 +MeshRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 2300000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1833674480} + m_Enabled: 1 + m_CastShadows: 1 + m_ReceiveShadows: 1 + m_DynamicOccludee: 1 + m_MotionVectors: 1 + m_LightProbeUsage: 0 + m_ReflectionProbeUsage: 1 + m_RenderingLayerMask: 1 + m_RendererPriority: 0 + m_Materials: + - {fileID: 2100000, guid: fecc96c64c214ce40835ac4c3c3099e8, type: 2} + 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: 3 + m_MinimumChartSize: 4 + m_AutoUVMaxDistance: 0.5 + m_AutoUVMaxAngle: 89 + m_LightmapParameters: {fileID: 0} + m_SortingLayerID: 0 + m_SortingLayer: 0 + m_SortingOrder: 0 +--- !u!33 &1833674486 +MeshFilter: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 3300000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1833674480} + m_Mesh: {fileID: 4300000, guid: 55e5ab7e66bd2eb49bc96935fe0bd04a, type: 3} +--- !u!1 &1867949262 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1867949263} + m_Layer: 0 + m_Name: Waypoints + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &1867949263 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1867949262} + 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: + - {fileID: 1679165113} + - {fileID: 985012143} + - {fileID: 795308214} + - {fileID: 453012818} + - {fileID: 1577869804} + - {fileID: 1114766222} + - {fileID: 86219748} + - {fileID: 1716371255} + m_Father: {fileID: 0} + m_RootOrder: 9 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!1 &1881403408 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 100000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1881403409} + - component: {fileID: 1881403412} + - component: {fileID: 1881403411} + - component: {fileID: 1881403410} + m_Layer: 0 + m_Name: bot + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &1881403409 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 400000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1881403408} + m_LocalRotation: {x: 0, y: 1, z: 0, w: 0} + m_LocalPosition: {x: -9.986802, y: 24.925999, z: -8.500595} + m_LocalScale: {x: 2, y: 2, z: 2} + m_Children: [] + m_Father: {fileID: 66600218} + m_RootOrder: 2 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!195 &1881403410 +NavMeshAgent: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1881403408} + m_Enabled: 1 + m_AgentTypeID: 0 + m_Radius: 0.6369026 + m_Speed: 15 + m_Acceleration: 15 + avoidancePriority: 50 + m_AngularSpeed: 1200 + m_StoppingDistance: 0 + m_AutoTraverseOffMeshLink: 1 + m_AutoBraking: 1 + m_AutoRepath: 1 + m_Height: 0.5024553 + m_BaseOffset: 0.25122765 + m_WalkableMask: 4294967295 + m_ObstacleAvoidanceType: 4 +--- !u!23 &1881403411 +MeshRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 2300000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1881403408} + m_Enabled: 1 + m_CastShadows: 1 + m_ReceiveShadows: 1 + m_DynamicOccludee: 1 + m_MotionVectors: 1 + m_LightProbeUsage: 0 + m_ReflectionProbeUsage: 1 + m_RenderingLayerMask: 1 + m_RendererPriority: 0 + m_Materials: + - {fileID: 2100000, guid: fecc96c64c214ce40835ac4c3c3099e8, type: 2} + 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: 3 + m_MinimumChartSize: 4 + m_AutoUVMaxDistance: 0.5 + m_AutoUVMaxAngle: 89 + m_LightmapParameters: {fileID: 0} + m_SortingLayerID: 0 + m_SortingLayer: 0 + m_SortingOrder: 0 +--- !u!33 &1881403412 +MeshFilter: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 3300000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1881403408} + m_Mesh: {fileID: 4300000, guid: 55e5ab7e66bd2eb49bc96935fe0bd04a, type: 3} +--- !u!1 &1903416401 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 100000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1903416402} + - component: {fileID: 1903416405} + - component: {fileID: 1903416404} + - component: {fileID: 1903416403} + m_Layer: 0 + m_Name: bot + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &1903416402 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 400000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1903416401} + m_LocalRotation: {x: 0, y: 1, z: 0, w: 0} + m_LocalPosition: {x: -21.553186, y: 24.925999, z: 16.007904} + m_LocalScale: {x: 2, y: 2, z: 2} + m_Children: [] + m_Father: {fileID: 66600218} + m_RootOrder: 9 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!195 &1903416403 +NavMeshAgent: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1903416401} + m_Enabled: 1 + m_AgentTypeID: 0 + m_Radius: 0.6369026 + m_Speed: 15 + m_Acceleration: 15 + avoidancePriority: 50 + m_AngularSpeed: 1200 + m_StoppingDistance: 0 + m_AutoTraverseOffMeshLink: 1 + m_AutoBraking: 1 + m_AutoRepath: 1 + m_Height: 0.5024553 + m_BaseOffset: 0.25122765 + m_WalkableMask: 4294967295 + m_ObstacleAvoidanceType: 4 +--- !u!23 &1903416404 +MeshRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 2300000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1903416401} + m_Enabled: 1 + m_CastShadows: 1 + m_ReceiveShadows: 1 + m_DynamicOccludee: 1 + m_MotionVectors: 1 + m_LightProbeUsage: 0 + m_ReflectionProbeUsage: 1 + m_RenderingLayerMask: 1 + m_RendererPriority: 0 + m_Materials: + - {fileID: 2100000, guid: fecc96c64c214ce40835ac4c3c3099e8, type: 2} + 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: 3 + m_MinimumChartSize: 4 + m_AutoUVMaxDistance: 0.5 + m_AutoUVMaxAngle: 89 + m_LightmapParameters: {fileID: 0} + m_SortingLayerID: 0 + m_SortingLayer: 0 + m_SortingOrder: 0 +--- !u!33 &1903416405 +MeshFilter: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 3300000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1903416401} + m_Mesh: {fileID: 4300000, guid: 55e5ab7e66bd2eb49bc96935fe0bd04a, type: 3} +--- !u!1 &1914565679 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1914565680} + - component: {fileID: 1914565683} + - component: {fileID: 1914565682} + - component: {fileID: 1914565681} + m_Layer: 2 + m_Name: Cube + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 4294967295 + m_IsActive: 1 +--- !u!4 &1914565680 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1914565679} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: 0, y: 1.5, z: 50} + m_LocalScale: {x: 100, y: 3, z: 2} + m_Children: [] + m_Father: {fileID: 122009232} + m_RootOrder: 7 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!23 &1914565681 +MeshRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1914565679} + m_Enabled: 1 + m_CastShadows: 1 + m_ReceiveShadows: 1 + m_DynamicOccludee: 1 + m_MotionVectors: 1 + m_LightProbeUsage: 0 + m_ReflectionProbeUsage: 1 + m_RenderingLayerMask: 1 + m_RendererPriority: 0 + m_Materials: + - {fileID: 2100000, guid: a08f97e5b75379d40b08ff5f74847d5c, type: 2} + 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: 3 + m_MinimumChartSize: 4 + m_AutoUVMaxDistance: 0.5 + m_AutoUVMaxAngle: 89 + m_LightmapParameters: {fileID: 0} + m_SortingLayerID: 0 + m_SortingLayer: 0 + m_SortingOrder: 0 +--- !u!65 &1914565682 +BoxCollider: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1914565679} + m_Material: {fileID: 0} + m_IsTrigger: 0 + m_Enabled: 1 + serializedVersion: 2 + m_Size: {x: 1, y: 1, z: 1} + m_Center: {x: 0, y: 0, z: 0} +--- !u!33 &1914565683 +MeshFilter: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1914565679} + m_Mesh: {fileID: 10202, guid: 0000000000000000e000000000000000, type: 0} +--- !u!1 &1914965757 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 100000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1914965758} + - component: {fileID: 1914965761} + - component: {fileID: 1914965760} + - component: {fileID: 1914965759} + m_Layer: 0 + m_Name: bot + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &1914965758 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 400000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1914965757} + m_LocalRotation: {x: 0, y: 1, z: 0, w: 0} + m_LocalPosition: {x: -9.986802, y: 24.925999, z: -8.500595} + m_LocalScale: {x: 2, y: 2, z: 2} + m_Children: [] + m_Father: {fileID: 1151274299} + m_RootOrder: 2 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!195 &1914965759 +NavMeshAgent: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1914965757} + m_Enabled: 1 + m_AgentTypeID: 0 + m_Radius: 0.6369026 + m_Speed: 10 + m_Acceleration: 8 + avoidancePriority: 50 + m_AngularSpeed: 1200 + m_StoppingDistance: 0 + m_AutoTraverseOffMeshLink: 1 + m_AutoBraking: 1 + m_AutoRepath: 1 + m_Height: 0.5024553 + m_BaseOffset: 0.25122765 + m_WalkableMask: 4294967295 + m_ObstacleAvoidanceType: 4 +--- !u!23 &1914965760 +MeshRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 2300000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1914965757} + m_Enabled: 1 + m_CastShadows: 1 + m_ReceiveShadows: 1 + m_DynamicOccludee: 1 + m_MotionVectors: 1 + m_LightProbeUsage: 0 + m_ReflectionProbeUsage: 1 + m_RenderingLayerMask: 1 + m_RendererPriority: 0 + m_Materials: + - {fileID: 2100000, guid: fecc96c64c214ce40835ac4c3c3099e8, type: 2} + 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: 3 + m_MinimumChartSize: 4 + m_AutoUVMaxDistance: 0.5 + m_AutoUVMaxAngle: 89 + m_LightmapParameters: {fileID: 0} + m_SortingLayerID: 0 + m_SortingLayer: 0 + m_SortingOrder: 0 +--- !u!33 &1914965761 +MeshFilter: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 3300000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1914965757} + m_Mesh: {fileID: 4300000, guid: 55e5ab7e66bd2eb49bc96935fe0bd04a, type: 3} +--- !u!1 &1948759273 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 100000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1948759274} + - component: {fileID: 1948759277} + - component: {fileID: 1948759276} + - component: {fileID: 1948759275} + m_Layer: 0 + m_Name: bot + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &1948759274 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 400000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1948759273} + m_LocalRotation: {x: 0, y: 1, z: 0, w: 0} + m_LocalPosition: {x: -21.553186, y: 24.925999, z: -14.685379} + m_LocalScale: {x: 2, y: 2, z: 2} + m_Children: [] + m_Father: {fileID: 193687608} + m_RootOrder: 12 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!195 &1948759275 +NavMeshAgent: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1948759273} + m_Enabled: 1 + m_AgentTypeID: 0 + m_Radius: 0.6369026 + m_Speed: 10 + m_Acceleration: 10 + avoidancePriority: 50 + m_AngularSpeed: 1200 + m_StoppingDistance: 0 + m_AutoTraverseOffMeshLink: 1 + m_AutoBraking: 1 + m_AutoRepath: 1 + m_Height: 0.5024553 + m_BaseOffset: 0.25122765 + m_WalkableMask: 4294967295 + m_ObstacleAvoidanceType: 4 +--- !u!23 &1948759276 +MeshRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 2300000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1948759273} + m_Enabled: 1 + m_CastShadows: 1 + m_ReceiveShadows: 1 + m_DynamicOccludee: 1 + m_MotionVectors: 1 + m_LightProbeUsage: 0 + m_ReflectionProbeUsage: 1 + m_RenderingLayerMask: 1 + m_RendererPriority: 0 + m_Materials: + - {fileID: 2100000, guid: fecc96c64c214ce40835ac4c3c3099e8, type: 2} + 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: 3 + m_MinimumChartSize: 4 + m_AutoUVMaxDistance: 0.5 + m_AutoUVMaxAngle: 89 + m_LightmapParameters: {fileID: 0} + m_SortingLayerID: 0 + m_SortingLayer: 0 + m_SortingOrder: 0 +--- !u!33 &1948759277 +MeshFilter: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 3300000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1948759273} + m_Mesh: {fileID: 4300000, guid: 55e5ab7e66bd2eb49bc96935fe0bd04a, type: 3} +--- !u!1 &1993239499 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1993239500} + - component: {fileID: 1993239503} + - component: {fileID: 1993239502} + - component: {fileID: 1993239501} + m_Layer: 2 + m_Name: Cube + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 4294967295 + m_IsActive: 1 +--- !u!4 &1993239500 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1993239499} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: 30, y: 1.5, z: 16} + m_LocalScale: {x: 2, y: 3, z: 27.5} + m_Children: [] + m_Father: {fileID: 122009232} + m_RootOrder: 4 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!23 &1993239501 +MeshRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1993239499} + m_Enabled: 1 + m_CastShadows: 1 + m_ReceiveShadows: 1 + m_DynamicOccludee: 1 + m_MotionVectors: 1 + m_LightProbeUsage: 0 + m_ReflectionProbeUsage: 1 + m_RenderingLayerMask: 1 + m_RendererPriority: 0 + m_Materials: + - {fileID: 2100000, guid: a08f97e5b75379d40b08ff5f74847d5c, type: 2} + 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: 3 + m_MinimumChartSize: 4 + m_AutoUVMaxDistance: 0.5 + m_AutoUVMaxAngle: 89 + m_LightmapParameters: {fileID: 0} + m_SortingLayerID: 0 + m_SortingLayer: 0 + m_SortingOrder: 0 +--- !u!65 &1993239502 +BoxCollider: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1993239499} + m_Material: {fileID: 0} + m_IsTrigger: 0 + m_Enabled: 1 + serializedVersion: 2 + m_Size: {x: 1, y: 1, z: 1} + m_Center: {x: 0, y: 0, z: 0} +--- !u!33 &1993239503 +MeshFilter: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1993239499} + m_Mesh: {fileID: 10202, guid: 0000000000000000e000000000000000, type: 0} +--- !u!1 &2046246928 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 100000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 2046246934} + - component: {fileID: 2046246933} + - component: {fileID: 2046246932} + - component: {fileID: 2046246931} + m_Layer: 0 + m_Name: bot + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!195 &2046246931 +NavMeshAgent: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 2046246928} + m_Enabled: 1 + m_AgentTypeID: 0 + m_Radius: 0.6369026 + m_Speed: 15 + m_Acceleration: 15 + avoidancePriority: 50 + m_AngularSpeed: 1200 + m_StoppingDistance: 0 + m_AutoTraverseOffMeshLink: 1 + m_AutoBraking: 1 + m_AutoRepath: 1 + m_Height: 0.5024553 + m_BaseOffset: 0.25122765 + m_WalkableMask: 4294967295 + m_ObstacleAvoidanceType: 4 +--- !u!23 &2046246932 +MeshRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 2300000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 2046246928} + m_Enabled: 1 + m_CastShadows: 1 + m_ReceiveShadows: 1 + m_DynamicOccludee: 1 + m_MotionVectors: 1 + m_LightProbeUsage: 0 + m_ReflectionProbeUsage: 1 + m_RenderingLayerMask: 1 + m_RendererPriority: 0 + m_Materials: + - {fileID: 2100000, guid: fecc96c64c214ce40835ac4c3c3099e8, type: 2} + 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: 3 + m_MinimumChartSize: 4 + m_AutoUVMaxDistance: 0.5 + m_AutoUVMaxAngle: 89 + m_LightmapParameters: {fileID: 0} + m_SortingLayerID: 0 + m_SortingLayer: 0 + m_SortingOrder: 0 +--- !u!33 &2046246933 +MeshFilter: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 3300000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 2046246928} + m_Mesh: {fileID: 4300000, guid: 55e5ab7e66bd2eb49bc96935fe0bd04a, type: 3} +--- !u!4 &2046246934 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 400000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 2046246928} + m_LocalRotation: {x: 6.123233e-17, y: 1, z: 6.123233e-17, w: 0.00000013315805} + m_LocalPosition: {x: -29.059395, y: 24.925999, z: 3.3366547} + m_LocalScale: {x: 2, y: 2, z: 2} + m_Children: [] + m_Father: {fileID: 66600218} + m_RootOrder: 7 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!1 &2071294760 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 100000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 2071294761} + - component: {fileID: 2071294766} + - component: {fileID: 2071294765} + - component: {fileID: 2071294764} + m_Layer: 0 + m_Name: bot + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &2071294761 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 400000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 2071294760} + m_LocalRotation: {x: 0, y: 1, z: 0, w: 0} + m_LocalPosition: {x: -17.492996, y: 24.925999, z: -12.2756195} + m_LocalScale: {x: 2, y: 2, z: 2} + m_Children: [] + m_Father: {fileID: 193687608} + m_RootOrder: 26 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!195 &2071294764 +NavMeshAgent: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 2071294760} + m_Enabled: 1 + m_AgentTypeID: 0 + m_Radius: 0.6369026 + m_Speed: 10 + m_Acceleration: 10 + avoidancePriority: 50 + m_AngularSpeed: 1200 + m_StoppingDistance: 0 + m_AutoTraverseOffMeshLink: 1 + m_AutoBraking: 1 + m_AutoRepath: 1 + m_Height: 0.5024553 + m_BaseOffset: 0.25122765 + m_WalkableMask: 4294967295 + m_ObstacleAvoidanceType: 4 +--- !u!23 &2071294765 +MeshRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 2300000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 2071294760} + m_Enabled: 1 + m_CastShadows: 1 + m_ReceiveShadows: 1 + m_DynamicOccludee: 1 + m_MotionVectors: 1 + m_LightProbeUsage: 0 + m_ReflectionProbeUsage: 1 + m_RenderingLayerMask: 1 + m_RendererPriority: 0 + m_Materials: + - {fileID: 2100000, guid: fecc96c64c214ce40835ac4c3c3099e8, type: 2} + 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: 3 + m_MinimumChartSize: 4 + m_AutoUVMaxDistance: 0.5 + m_AutoUVMaxAngle: 89 + m_LightmapParameters: {fileID: 0} + m_SortingLayerID: 0 + m_SortingLayer: 0 + m_SortingOrder: 0 +--- !u!33 &2071294766 +MeshFilter: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 3300000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 2071294760} + m_Mesh: {fileID: 4300000, guid: 55e5ab7e66bd2eb49bc96935fe0bd04a, type: 3} +--- !u!1 &2104181165 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 100000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 2104181166} + - component: {fileID: 2104181171} + - component: {fileID: 2104181170} + - component: {fileID: 2104181169} + m_Layer: 0 + m_Name: bot + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &2104181166 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 400000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 2104181165} + m_LocalRotation: {x: 6.123233e-17, y: 1, z: 6.123233e-17, w: 0.00000013315805} + m_LocalPosition: {x: -29.059395, y: 24.925999, z: -0.3338623} + m_LocalScale: {x: 2, y: 2, z: 2} + m_Children: [] + m_Father: {fileID: 193687608} + m_RootOrder: 16 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!195 &2104181169 +NavMeshAgent: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 2104181165} + m_Enabled: 1 + m_AgentTypeID: 0 + m_Radius: 0.6369026 + m_Speed: 10 + m_Acceleration: 10 + avoidancePriority: 50 + m_AngularSpeed: 1200 + m_StoppingDistance: 0 + m_AutoTraverseOffMeshLink: 1 + m_AutoBraking: 1 + m_AutoRepath: 1 + m_Height: 0.5024553 + m_BaseOffset: 0.25122765 + m_WalkableMask: 4294967295 + m_ObstacleAvoidanceType: 4 +--- !u!23 &2104181170 +MeshRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 2300000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 2104181165} + m_Enabled: 1 + m_CastShadows: 1 + m_ReceiveShadows: 1 + m_DynamicOccludee: 1 + m_MotionVectors: 1 + m_LightProbeUsage: 0 + m_ReflectionProbeUsage: 1 + m_RenderingLayerMask: 1 + m_RendererPriority: 0 + m_Materials: + - {fileID: 2100000, guid: fecc96c64c214ce40835ac4c3c3099e8, type: 2} + 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: 3 + m_MinimumChartSize: 4 + m_AutoUVMaxDistance: 0.5 + m_AutoUVMaxAngle: 89 + m_LightmapParameters: {fileID: 0} + m_SortingLayerID: 0 + m_SortingLayer: 0 + m_SortingOrder: 0 +--- !u!33 &2104181171 +MeshFilter: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 3300000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 2104181165} + m_Mesh: {fileID: 4300000, guid: 55e5ab7e66bd2eb49bc96935fe0bd04a, type: 3} +--- !u!1 &2110132575 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 100000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 2110132576} + - component: {fileID: 2110132579} + - component: {fileID: 2110132578} + - component: {fileID: 2110132577} + m_Layer: 0 + m_Name: bot + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &2110132576 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 400000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 2110132575} + m_LocalRotation: {x: 0, y: 1, z: 0, w: 0} + m_LocalPosition: {x: -9.986802, y: 24.925999, z: 0.6628113} + m_LocalScale: {x: 2, y: 2, z: 2} + m_Children: [] + m_Father: {fileID: 1151274299} + m_RootOrder: 8 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!195 &2110132577 +NavMeshAgent: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 2110132575} + m_Enabled: 1 + m_AgentTypeID: 0 + m_Radius: 0.6369026 + m_Speed: 10 + m_Acceleration: 8 + avoidancePriority: 50 + m_AngularSpeed: 1200 + m_StoppingDistance: 0 + m_AutoTraverseOffMeshLink: 1 + m_AutoBraking: 1 + m_AutoRepath: 1 + m_Height: 0.5024553 + m_BaseOffset: 0.25122765 + m_WalkableMask: 4294967295 + m_ObstacleAvoidanceType: 4 +--- !u!23 &2110132578 +MeshRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 2300000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 2110132575} + m_Enabled: 1 + m_CastShadows: 1 + m_ReceiveShadows: 1 + m_DynamicOccludee: 1 + m_MotionVectors: 1 + m_LightProbeUsage: 0 + m_ReflectionProbeUsage: 1 + m_RenderingLayerMask: 1 + m_RendererPriority: 0 + m_Materials: + - {fileID: 2100000, guid: fecc96c64c214ce40835ac4c3c3099e8, type: 2} + 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: 3 + m_MinimumChartSize: 4 + m_AutoUVMaxDistance: 0.5 + m_AutoUVMaxAngle: 89 + m_LightmapParameters: {fileID: 0} + m_SortingLayerID: 0 + m_SortingLayer: 0 + m_SortingOrder: 0 +--- !u!33 &2110132579 +MeshFilter: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 3300000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 2110132575} + m_Mesh: {fileID: 4300000, guid: 55e5ab7e66bd2eb49bc96935fe0bd04a, type: 3} +--- !u!1 &2133735853 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 100000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 2133735854} + - component: {fileID: 2133735857} + - component: {fileID: 2133735856} + - component: {fileID: 2133735855} + m_Layer: 0 + m_Name: bot + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &2133735854 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 400000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 2133735853} + m_LocalRotation: {x: 0, y: 1, z: 0, w: 0} + m_LocalPosition: {x: -9.986802, y: 24.925999, z: -14.685379} + m_LocalScale: {x: 2, y: 2, z: 2} + m_Children: [] + m_Father: {fileID: 193687608} + m_RootOrder: 19 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!195 &2133735855 +NavMeshAgent: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 2133735853} + m_Enabled: 1 + m_AgentTypeID: 0 + m_Radius: 0.6369026 + m_Speed: 10 + m_Acceleration: 10 + avoidancePriority: 50 + m_AngularSpeed: 1200 + m_StoppingDistance: 0 + m_AutoTraverseOffMeshLink: 1 + m_AutoBraking: 1 + m_AutoRepath: 1 + m_Height: 0.5024553 + m_BaseOffset: 0.25122765 + m_WalkableMask: 4294967295 + m_ObstacleAvoidanceType: 4 +--- !u!23 &2133735856 +MeshRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 2300000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 2133735853} + m_Enabled: 1 + m_CastShadows: 1 + m_ReceiveShadows: 1 + m_DynamicOccludee: 1 + m_MotionVectors: 1 + m_LightProbeUsage: 0 + m_ReflectionProbeUsage: 1 + m_RenderingLayerMask: 1 + m_RendererPriority: 0 + m_Materials: + - {fileID: 2100000, guid: fecc96c64c214ce40835ac4c3c3099e8, type: 2} + 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: 3 + m_MinimumChartSize: 4 + m_AutoUVMaxDistance: 0.5 + m_AutoUVMaxAngle: 89 + m_LightmapParameters: {fileID: 0} + m_SortingLayerID: 0 + m_SortingLayer: 0 + m_SortingOrder: 0 +--- !u!33 &2133735857 +MeshFilter: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 3300000, guid: dace1099a9164ae488b8d71bec3318e4, + type: 3} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 2133735853} + m_Mesh: {fileID: 4300000, guid: 55e5ab7e66bd2eb49bc96935fe0bd04a, type: 3} diff --git a/Assets/Behavior Designer Movement/Scene/Scene.unity.meta b/Assets/Behavior Designer Movement/Scene/Scene.unity.meta new file mode 100644 index 0000000..6da6a7a --- /dev/null +++ b/Assets/Behavior Designer Movement/Scene/Scene.unity.meta @@ -0,0 +1,4 @@ +fileFormatVersion: 2 +guid: 814024599b28f50459412dc5aeaa3ba1 +DefaultImporter: + userData: diff --git a/Assets/Behavior Designer Movement/Scene/Scene/NavMesh.asset b/Assets/Behavior Designer Movement/Scene/Scene/NavMesh.asset new file mode 100644 index 0000000..b8639b4 Binary files /dev/null and b/Assets/Behavior Designer Movement/Scene/Scene/NavMesh.asset differ diff --git a/Assets/Behavior Designer Movement/Scene/Scene/NavMesh.asset.meta b/Assets/Behavior Designer Movement/Scene/Scene/NavMesh.asset.meta new file mode 100644 index 0000000..3e77049 --- /dev/null +++ b/Assets/Behavior Designer Movement/Scene/Scene/NavMesh.asset.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: b8dd84a32b65e0f41a6c7f12ff72f7e6 +timeCreated: 1462401859 +licenseType: Store +NativeFormatImporter: + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Behavior Designer Movement/Scripts.meta b/Assets/Behavior Designer Movement/Scripts.meta new file mode 100644 index 0000000..11dd758 --- /dev/null +++ b/Assets/Behavior Designer Movement/Scripts.meta @@ -0,0 +1,4 @@ +fileFormatVersion: 2 +guid: b2f14f22589429446b62b7857ef011ed +DefaultImporter: + userData: diff --git a/Assets/Behavior Designer Movement/Scripts/BehaviorSelection.cs b/Assets/Behavior Designer Movement/Scripts/BehaviorSelection.cs new file mode 100644 index 0000000..3147e79 --- /dev/null +++ b/Assets/Behavior Designer Movement/Scripts/BehaviorSelection.cs @@ -0,0 +1,358 @@ +using UnityEngine; +using System.Collections; +using System.Collections.Generic; +using System.Text.RegularExpressions; +using BehaviorDesigner.Runtime; + +public class BehaviorSelection : MonoBehaviour +{ + public GameObject marker; + public GameObject mainBot; + public GameObject flockGroup; + public GameObject followGroup; + public GameObject queueGroup; + public GameObject[] waypoints; + public GameObject[] waypointsA; + public GUISkin descriptionGUISkin; + + private Vector3[] flockGroupPosition; + private Vector3[] followGroupPosition; + private Vector3[] queueGroupPosition; + private Quaternion[] flockGroupRotation; + private Quaternion[] followGroupRotation; + private Quaternion[] queueGroupRotation; + + private Dictionary behaviorTreeGroup = new Dictionary(); + private Animation markerAnimation; + + private enum BehaviorSelectionType { MoveTowards, RotateTowards, Seek, Flee, Pursue, Evade, Follow, Patrol, Cover, Wander, Search, WithinDistance, CanSeeObject, CanHearObject, Flock, LeaderFollow, Queue, Last } + private BehaviorSelectionType selectionType = BehaviorSelectionType.MoveTowards; + private BehaviorSelectionType prevSelectionType = BehaviorSelectionType.MoveTowards; + + public void Start() + { + var behaviorTrees = mainBot.GetComponents(); + for (int i = 0; i < behaviorTrees.Length; ++i) { + behaviorTreeGroup.Add(behaviorTrees[i].Group, behaviorTrees[i]); + } + behaviorTrees = Camera.main.GetComponents(); + for (int i = 0; i < behaviorTrees.Length; ++i) { + behaviorTreeGroup.Add(behaviorTrees[i].Group, behaviorTrees[i]); + } + + flockGroupPosition = new Vector3[flockGroup.transform.childCount]; + flockGroupRotation = new Quaternion[flockGroup.transform.childCount]; + for (int i = 0; i < flockGroup.transform.childCount; ++i) { + flockGroup.transform.GetChild(i).gameObject.SetActive(false); + flockGroupPosition[i] = flockGroup.transform.GetChild(i).transform.position; + flockGroupRotation[i] = flockGroup.transform.GetChild(i).transform.rotation; + } + followGroupPosition = new Vector3[followGroup.transform.childCount]; + followGroupRotation = new Quaternion[followGroup.transform.childCount]; + for (int i = 0; i < followGroup.transform.childCount; ++i) { + followGroup.transform.GetChild(i).gameObject.SetActive(false); + followGroupPosition[i] = followGroup.transform.GetChild(i).transform.position; + followGroupRotation[i] = followGroup.transform.GetChild(i).transform.rotation; + } + queueGroupPosition = new Vector3[queueGroup.transform.childCount]; + queueGroupRotation = new Quaternion[queueGroup.transform.childCount]; + for (int i = 0; i < queueGroup.transform.childCount; ++i) { + queueGroup.transform.GetChild(i).gameObject.SetActive(false); + queueGroupPosition[i] = queueGroup.transform.GetChild(i).transform.position; + queueGroupRotation[i] = queueGroup.transform.GetChild(i).transform.rotation; + } + + markerAnimation = marker.GetComponent(); + SelectionChanged(); + } + + public void OnGUI() + { + GUILayout.BeginVertical(GUILayout.Width(300)); + GUILayout.BeginHorizontal(); + if (GUILayout.Button("<-")) { + prevSelectionType = selectionType; + selectionType = (BehaviorSelectionType)(((int)selectionType - 1) % (int)BehaviorSelectionType.Last); + if ((int)selectionType < 0) selectionType = BehaviorSelectionType.Queue; + SelectionChanged(); + } + GUILayout.Box(SplitCamelCase(selectionType.ToString()), GUILayout.Width(220)); + if (GUILayout.Button("->")) { + prevSelectionType = selectionType; + selectionType = (BehaviorSelectionType)(((int)selectionType + 1) % (int)BehaviorSelectionType.Last); + SelectionChanged(); + } + GUILayout.EndHorizontal(); + GUILayout.Box(Description(), descriptionGUISkin.box); + if (selectionType == BehaviorSelectionType.CanHearObject) { + if (GUILayout.Button("Play Sound")) { + marker.GetComponent().Play(); + } + } + GUILayout.EndVertical(); + } + + private string Description() + { + string desc = ""; + switch (selectionType) { + case BehaviorSelectionType.MoveTowards: + desc = "The Move Towards task will move the agent towards the target (without pathfinding). In this example the green agent is moving towards the red dot."; + break; + case BehaviorSelectionType.RotateTowards: + desc = "The Rotate Towards task rotate the agent towards the target. In this example the green agent is rotating towards the red dot."; + break; + case BehaviorSelectionType.Seek: + desc = "The Seek task will move the agent towards the target with pathfinding. In this example the green agent is seeking the red dot (which moves)."; + break; + case BehaviorSelectionType.Flee: + desc = "The Flee task will move the agent away from the target with pathfinding. In this example the green agent is fleeing from red dot (which moves)."; + break; + case BehaviorSelectionType.Pursue: + desc = "The Pursue task is similar to the Seek task except the Pursue task predicts where the target is going to be in the future. This allows the agent to arrive at the target earlier than it would have with the Seek task."; + break; + case BehaviorSelectionType.Evade: + desc = "The Evade task is similar to the Flee task except the Evade task predicts where the target is going to be in the future. This allows the agent to flee from the target earlier than it would have with the Flee task."; + break; + case BehaviorSelectionType.Follow: + desc = "The Follow task will allow the agent to continuously follow a GameObject. In this example the green agent is following the red dot."; + break; + case BehaviorSelectionType.Patrol: + desc = "The Patrol task moves from waypoint to waypint. In this example the green agent is patrolling with four different waypoints (the white dots)."; + break; + case BehaviorSelectionType.Cover: + desc = "The Cover task will move the agent into cover from its current position. In this example the agent sees cover in front of it so takes cover behind the wall."; + break; + case BehaviorSelectionType.Wander: + desc = "The Wander task moves the agent randomly throughout the map with pathfinding."; + break; + case BehaviorSelectionType.Search: + desc = "The Search task will search the map by wandering until it finds the target. It can find the target by seeing or hearing the target. In this example the Search task is looking for the red dot."; + break; + case BehaviorSelectionType.WithinDistance: + desc = "The Within Distance task is a conditional task that returns success when another object comes within distance of the current agent. In this example the Within Distance task is paired with the Seek task so the agent will move towards the target as soon as the target within distance."; + break; + case BehaviorSelectionType.CanSeeObject: + desc = "The Can See Object task is a conditional task that returns success when it sees an object in front of the current agent. In this example the Can See Object task is paired with the Seek task so the agent will move towards the target as soon as the target is seen."; + break; + case BehaviorSelectionType.CanHearObject: + desc = "The Can Hear Object task is a conditional task that returns success when it hears another object. Press the \"Play\" button to emit a sound from the red dot. If the red dot is within range of the agent when the sound is played then the agent will move towards the red dot with the Seek task."; + break; + case BehaviorSelectionType.Flock: + desc = "The Flock task moves a group of objects together in a pattern (which can be adjusted). In this example the Flock task is controlling all 30 objects. There are no colliders on the objects - the Flock task is completing managing the position of all of the objects"; + break; + case BehaviorSelectionType.LeaderFollow: + desc = "The Leader Follow task moves a group of objects behind a leader object. There are two behavior trees running in this example - one for the leader (who is patrolling the area) and one for the group of objects. Again, there is are no colliders on the objects."; + break; + case BehaviorSelectionType.Queue: + desc = "The Queue task will move a group of objects through a small space in an organized way. In this example the Queue task is controlling all of the objects. Another way to move all of the objects through the doorway is with the seek task, however with this approach the objects would group up at the doorway."; + break; + } + return desc; + } + + private static string SplitCamelCase(string s) + { + var r = new Regex(@"(?<=[A-Z])(?=[A-Z][a-z])|(?<=[^A-Z])(?=[A-Z])|(?<=[A-Za-z])(?=[^A-Za-z])", RegexOptions.IgnorePatternWhitespace); + s = r.Replace(s, " "); + return (char.ToUpper(s[0]) + s.Substring(1)).Trim(); + } + + private void SelectionChanged() + { + DisableAll(); + switch (selectionType) { + case BehaviorSelectionType.MoveTowards: + marker.transform.position = new Vector3(20, 1, -20); + marker.SetActive(true); + mainBot.transform.position = new Vector3(-20, 1, -20); + mainBot.transform.eulerAngles = new Vector3(0, 180, 0); + mainBot.SetActive(true); + break; + case BehaviorSelectionType.RotateTowards: + marker.transform.position = new Vector3(20, 1, 10); + marker.SetActive(true); + mainBot.transform.position = new Vector3(0, 1, -20); + mainBot.transform.eulerAngles = new Vector3(0, 180, 0); + mainBot.SetActive(true); + break; + case BehaviorSelectionType.Seek: + marker.transform.position = new Vector3(20, 1, 20); + marker.SetActive(true); + markerAnimation["MarkerSeek"].time = 0; + markerAnimation["MarkerSeek"].speed = 1; + markerAnimation.Play("MarkerSeek"); + mainBot.transform.position = new Vector3(-20, 1, -20); + mainBot.transform.eulerAngles = new Vector3(0, 180, 0); + mainBot.SetActive(true); + break; + case BehaviorSelectionType.Flee: + marker.transform.position = new Vector3(20, 1, 20); + marker.SetActive(true); + markerAnimation["MarkerFlee"].time = 0; + markerAnimation["MarkerFlee"].speed = 1; + markerAnimation.Play("MarkerFlee"); + mainBot.transform.position = new Vector3(10, 1, 18); + mainBot.transform.eulerAngles = new Vector3(0, 180, 0); + mainBot.SetActive(true); + break; + case BehaviorSelectionType.Pursue: + marker.transform.position = new Vector3(20, 1, 20); + marker.SetActive(true); + markerAnimation["MarkerPersue"].time = 0; + markerAnimation["MarkerPersue"].speed = 1; + markerAnimation.Play("MarkerPersue"); + mainBot.transform.position = new Vector3(-20, 1, 0); + mainBot.transform.eulerAngles = new Vector3(0, 90, 0); + mainBot.SetActive(true); + break; + case BehaviorSelectionType.Evade: + marker.transform.position = new Vector3(20, 1, 20); + marker.SetActive(true); + markerAnimation["MarkerEvade"].time = 0; + markerAnimation["MarkerEvade"].speed = 1; + markerAnimation.Play("MarkerEvade"); + mainBot.transform.position = new Vector3(0, 1, 18); + mainBot.transform.eulerAngles = new Vector3(0, 180, 0); + mainBot.SetActive(true); + break; + case BehaviorSelectionType.Follow: + marker.transform.position = new Vector3(20, 1, 20); + marker.SetActive(true); + markerAnimation["MarkerFollow"].time = 0; + markerAnimation["MarkerFollow"].speed = 1; + markerAnimation.Play("MarkerFollow"); + mainBot.transform.position = new Vector3(20, 1, 15); + mainBot.transform.eulerAngles = new Vector3(0, 0, 0); + mainBot.SetActive(true); + break; + case BehaviorSelectionType.Patrol: + for (int i = 0; i < waypoints.Length; ++i) { + waypoints[i].SetActive(true); + } + mainBot.transform.position = new Vector3(-20, 1, 20); + mainBot.transform.eulerAngles = new Vector3(0, 180, 0); + mainBot.SetActive(true); + break; + case BehaviorSelectionType.Cover: + mainBot.transform.position = new Vector3(-5, 1, -10); + mainBot.transform.eulerAngles = new Vector3(0, 0, 0); + mainBot.SetActive(true); + break; + case BehaviorSelectionType.Wander: + mainBot.transform.position = new Vector3(-20, 1, -20); + mainBot.transform.eulerAngles = new Vector3(0, 0, 0); + mainBot.SetActive(true); + break; + case BehaviorSelectionType.Search: + marker.transform.position = new Vector3(20, 1, 20); + marker.SetActive(true); + mainBot.transform.position = new Vector3(-20, 1, -20); + mainBot.transform.eulerAngles = new Vector3(0, 0, 0); + mainBot.SetActive(true); + break; + case BehaviorSelectionType.WithinDistance: + marker.SetActive(true); + marker.transform.position = new Vector3(20, 1, 20); + markerAnimation["MarkerPersue"].time = 0; + markerAnimation["MarkerPersue"].speed = 1; + markerAnimation.Play("MarkerPersue"); + mainBot.transform.position = new Vector3(-15, 1, 2); + mainBot.transform.eulerAngles = new Vector3(0, 0, 0); + mainBot.SetActive(true); + break; + case BehaviorSelectionType.CanSeeObject: + marker.SetActive(true); + marker.transform.position = new Vector3(20, 1, 20); + markerAnimation["MarkerPersue"].time = 0; + markerAnimation["MarkerPersue"].speed = 1; + markerAnimation.Play("MarkerPersue"); + markerAnimation.enabled = true; + mainBot.transform.position = new Vector3(-15, 1, -10); + mainBot.transform.eulerAngles = new Vector3(0, 0, 0); + mainBot.SetActive(true); + break; + case BehaviorSelectionType.CanHearObject: + marker.SetActive(true); + marker.transform.position = new Vector3(20, 1, 20); + markerAnimation["MarkerPersue"].time = 0; + markerAnimation["MarkerPersue"].speed = 1; + markerAnimation.Play("MarkerPersue"); + mainBot.transform.position = new Vector3(-15, 1, -10); + mainBot.transform.eulerAngles = new Vector3(0, 0, 0); + mainBot.SetActive(true); + break; + case BehaviorSelectionType.Flock: + Camera.main.transform.position = new Vector3(0, 90, -150); + for (int i = 0; i < flockGroup.transform.childCount; ++i) { + flockGroup.transform.GetChild(i).gameObject.SetActive(true); + } + break; + case BehaviorSelectionType.LeaderFollow: + for (int i = 0; i < waypointsA.Length; ++i) { + waypointsA[i].SetActive(true); + } + mainBot.transform.position = new Vector3(0, 1, -130); + mainBot.SetActive(true); + Camera.main.transform.position = new Vector3(0, 90, -150); + for (int i = 0; i < followGroup.transform.childCount; ++i) { + followGroup.transform.GetChild(i).gameObject.SetActive(true); + } + break; + case BehaviorSelectionType.Queue: + marker.transform.position = new Vector3(45, 1, 0); + for (int i = 0; i < queueGroup.transform.childCount; ++i) { + queueGroup.transform.GetChild(i).gameObject.SetActive(true); + } + break; + } + StartCoroutine("EnableBehavior"); + } + + private void DisableAll() + { + StopCoroutine("EnableBehavior"); + behaviorTreeGroup[(int)prevSelectionType].DisableBehavior(); + // enable the leader as well + if (prevSelectionType == BehaviorSelectionType.LeaderFollow) { + behaviorTreeGroup[(int)BehaviorSelectionType.Last].DisableBehavior(); + } + markerAnimation.Stop(); + marker.SetActive(false); + mainBot.SetActive(false); + Camera.main.transform.position = new Vector3(0, 90, 0); + for (int i = 0; i < flockGroup.transform.childCount; ++i) { + flockGroup.transform.GetChild(i).gameObject.SetActive(false); + flockGroup.transform.GetChild(i).transform.position = flockGroupPosition[i]; + flockGroup.transform.GetChild(i).transform.rotation = flockGroupRotation[i]; + } + for (int i = 0; i < followGroup.transform.childCount; ++i) { + followGroup.transform.GetChild(i).gameObject.SetActive(false); + followGroup.transform.GetChild(i).transform.position = followGroupPosition[i]; + followGroup.transform.GetChild(i).transform.rotation = followGroupRotation[i]; + } + for (int i = 0; i < queueGroup.transform.childCount; ++i) { + queueGroup.transform.GetChild(i).gameObject.SetActive(false); + queueGroup.transform.GetChild(i).transform.position = queueGroupPosition[i]; + queueGroup.transform.GetChild(i).transform.rotation = queueGroupRotation[i]; + } + for (int i = 0; i < waypoints.Length; ++i) { + waypoints[i].SetActive(false); + } + for (int i = 0; i < waypointsA.Length; ++i) { + waypointsA[i].SetActive(false); + } + } + + private IEnumerator EnableBehavior() + { + yield return new WaitForSeconds(0.5f); + + behaviorTreeGroup[(int)selectionType].EnableBehavior(); + + // enable the leader as well + if (selectionType == BehaviorSelectionType.LeaderFollow) { + behaviorTreeGroup[(int)BehaviorSelectionType.Last].EnableBehavior(); + } + } +} diff --git a/Assets/Behavior Designer Movement/Scripts/BehaviorSelection.cs.meta b/Assets/Behavior Designer Movement/Scripts/BehaviorSelection.cs.meta new file mode 100644 index 0000000..72e0878 --- /dev/null +++ b/Assets/Behavior Designer Movement/Scripts/BehaviorSelection.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 536f005415e86134c98218681c66ba3c +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer Movement/Scripts/GroupMovement.cs b/Assets/Behavior Designer Movement/Scripts/GroupMovement.cs new file mode 100644 index 0000000..47fba15 --- /dev/null +++ b/Assets/Behavior Designer Movement/Scripts/GroupMovement.cs @@ -0,0 +1,11 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Movement +{ + public abstract class GroupMovement : Action + { + protected abstract bool SetDestination(int index, Vector3 target); + + protected abstract Vector3 Velocity(int index); + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer Movement/Scripts/GroupMovement.cs.meta b/Assets/Behavior Designer Movement/Scripts/GroupMovement.cs.meta new file mode 100644 index 0000000..19f317d --- /dev/null +++ b/Assets/Behavior Designer Movement/Scripts/GroupMovement.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: c505248b675e9fd49abace0e3b07a43e +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer Movement/Scripts/Movement.cs b/Assets/Behavior Designer Movement/Scripts/Movement.cs new file mode 100644 index 0000000..c46f867 --- /dev/null +++ b/Assets/Behavior Designer Movement/Scripts/Movement.cs @@ -0,0 +1,43 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Movement +{ + public abstract class Movement : Action + { + /// + /// Set a new pathfinding destination. + /// + /// The destination to set. + /// True if the destination is valid. + protected abstract bool SetDestination(Vector3 destination); + + /// + /// Specifies if the rotation should be updated. + /// + /// Should the rotation be updated? + protected abstract void UpdateRotation(bool update); + + /// + /// Does the agent have a pathfinding path? + /// + /// True if the agent has a pathfinding path. + protected abstract bool HasPath(); + + /// + /// Returns the velocity of the agent. + /// + /// The velocity of the agent. + protected abstract Vector3 Velocity(); + + /// + /// Has the agent arrived at the destination? + /// + /// True if the agent has arrived at the destination. + protected abstract bool HasArrived(); + + /// + /// Stop pathfinding. + /// + protected abstract void Stop(); + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer Movement/Scripts/Movement.cs.meta b/Assets/Behavior Designer Movement/Scripts/Movement.cs.meta new file mode 100644 index 0000000..51f2802 --- /dev/null +++ b/Assets/Behavior Designer Movement/Scripts/Movement.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 1b7d848585dc1fb4ea7b235e94d12ad3 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer Movement/Scripts/MovementUtility.cs b/Assets/Behavior Designer Movement/Scripts/MovementUtility.cs new file mode 100644 index 0000000..5ab4480 --- /dev/null +++ b/Assets/Behavior Designer Movement/Scripts/MovementUtility.cs @@ -0,0 +1,347 @@ +using UnityEngine; +using System; +using System.Collections.Generic; + +namespace BehaviorDesigner.Runtime.Tasks.Movement +{ + public static class MovementUtility + { + private static Dictionary> gameObjectComponentMap = new Dictionary>(); + private static Dictionary> gameObjectParentComponentMap = new Dictionary>(); + private static Dictionary> gameObjectComponentsMap = new Dictionary>(); + + // Cast a sphere with the desired distance. Check each collider hit to see if it is within the field of view. Set objectFound + // to the object that is most directly in front of the agent + public static GameObject WithinSight(Transform transform, Vector3 positionOffset, float fieldOfViewAngle, float viewDistance, Collider[] overlapColliders, LayerMask objectLayerMask, Vector3 targetOffset, LayerMask ignoreLayerMask, bool useTargetBone, HumanBodyBones targetBone, bool drawDebugRay) + { + GameObject objectFound = null; + var hitCount = Physics.OverlapSphereNonAlloc(transform.TransformPoint(positionOffset), viewDistance, overlapColliders, objectLayerMask, QueryTriggerInteraction.Ignore); + if (hitCount > 0) { +#if UNITY_EDITOR + if (hitCount == overlapColliders.Length) { + Debug.LogWarning("Warning: The hit count is equal to the max collider array size. This will cause objects to be missed. Consider increasing the max collision count size."); + } +#endif + float minAngle = Mathf.Infinity; + for (int i = 0; i < hitCount; ++i) { + float angle; + GameObject obj; + // Call the WithinSight function to determine if this specific object is within sight + if ((obj = WithinSight(transform, positionOffset, fieldOfViewAngle, viewDistance, overlapColliders[i].gameObject, targetOffset, false, 0, out angle, ignoreLayerMask, useTargetBone, targetBone, drawDebugRay)) != null) { + // This object is within sight. Set it to the objectFound GameObject if the angle is less than any of the other objects + if (angle < minAngle) { + minAngle = angle; + objectFound = obj; + } + } + } + } + return objectFound; + } + + // Cast a circle with the desired distance. Check each collider hit to see if it is within the field of view. Set objectFound + // to the object that is most directly in front of the agent + public static GameObject WithinSight2D(Transform transform, Vector3 positionOffset, float fieldOfViewAngle, float viewDistance, Collider2D[] overlapColliders, LayerMask objectLayerMask, Vector3 targetOffset, float angleOffset2D, LayerMask ignoreLayerMask, bool drawDebugRay) + { + GameObject objectFound = null; + var hitCount = Physics2D.OverlapCircleNonAlloc(transform.position, viewDistance, overlapColliders, objectLayerMask); + if (hitCount > 0) { +#if UNITY_EDITOR + if (hitCount == overlapColliders.Length) { + Debug.LogWarning("Warning: The hit count is equal to the max collider array size. This will cause objects to be missed. Consider increasing the max collision count size."); + } +#endif + float minAngle = Mathf.Infinity; + for (int i = 0; i < hitCount; ++i) { + float angle; + GameObject obj; + // Call the 2D WithinSight function to determine if this specific object is within sight + if ((obj = WithinSight(transform, positionOffset, fieldOfViewAngle, viewDistance, overlapColliders[i].gameObject, targetOffset, true, angleOffset2D, out angle, ignoreLayerMask, false, HumanBodyBones.Hips, drawDebugRay)) != null) { + // This object is within sight. Set it to the objectFound GameObject if the angle is less than any of the other objects + if (angle < minAngle) { + minAngle = angle; + objectFound = obj; + } + } + } + } + return objectFound; + } + + // Public helper function that will automatically create an angle variable that is not used. This function is useful if the calling object doesn't + // care about the angle between transform and targetObject + public static GameObject WithinSight(Transform transform, Vector3 positionOffset, float fieldOfViewAngle, float viewDistance, GameObject targetObject, Vector3 targetOffset, LayerMask ignoreLayerMask, bool useTargetBone, HumanBodyBones targetBone, bool drawDebugRay) + { + float angle; + return WithinSight(transform, positionOffset, fieldOfViewAngle, viewDistance, targetObject, targetOffset, false, 0, out angle, ignoreLayerMask, useTargetBone, targetBone, drawDebugRay); + } + + // Public helper function that will automatically create an angle variable that is not used. This function is useful if the calling object doesn't + // care about the angle between transform and targetObject + public static GameObject WithinSight2D(Transform transform, Vector3 positionOffset, float fieldOfViewAngle, float viewDistance, GameObject targetObject, Vector3 targetOffset, float angleOffset2D, LayerMask ignoreLayerMask, bool useTargetBone, HumanBodyBones targetBone, bool drawDebugRay) + { + float angle; + return WithinSight(transform, positionOffset, fieldOfViewAngle, viewDistance, targetObject, targetOffset, true, angleOffset2D, out angle, ignoreLayerMask, useTargetBone, targetBone, drawDebugRay); + } + + // Determines if the targetObject is within sight of the transform. It will set the angle regardless of whether or not the object is within sight + public static GameObject WithinSight(Transform transform, Vector3 positionOffset, float fieldOfViewAngle, float viewDistance, GameObject targetObject, Vector3 targetOffset, bool usePhysics2D, float angleOffset2D, out float angle, int ignoreLayerMask, bool useTargetBone, HumanBodyBones targetBone, bool drawDebugRay) + { + if (targetObject == null) { + angle = 0; + return null; + } + if (useTargetBone) { + Animator animator; + if ((animator = GetParentComponentForType(targetObject)) != null) { + var bone = animator.GetBoneTransform(targetBone); + if (bone != null) { + targetObject = bone.gameObject; + } + } + } + // The target object needs to be within the field of view of the current object + var direction = targetObject.transform.TransformPoint(targetOffset) - transform.TransformPoint(positionOffset); + if (usePhysics2D) { + var eulerAngles = transform.eulerAngles; + eulerAngles.z -= angleOffset2D; + angle = Vector3.Angle(direction, Quaternion.Euler(eulerAngles) * Vector3.up); + direction.z = 0; + } else { + angle = Vector3.Angle(direction, transform.forward); + direction.y = 0; + } + if (direction.magnitude < viewDistance && angle < fieldOfViewAngle * 0.5f) { + // The hit agent needs to be within view of the current agent + var hitTransform = LineOfSight(transform, positionOffset, targetObject, targetOffset, usePhysics2D, ignoreLayerMask, drawDebugRay); + if (hitTransform != null) { + if (IsAncestor(targetObject.transform, hitTransform)) { +#if UNITY_EDITOR + if (drawDebugRay) { + Debug.DrawLine(transform.TransformPoint(positionOffset), targetObject.transform.TransformPoint(targetOffset), Color.green); + } +#endif + return targetObject; // return the target object meaning it is within sight +#if UNITY_EDITOR + } else { + if (drawDebugRay) { + Debug.DrawLine(transform.TransformPoint(positionOffset), targetObject.transform.TransformPoint(targetOffset), Color.yellow); + } +#endif + } + } else if (GetComponentForType(targetObject) == null && GetComponentForType(targetObject) == null) { + // If the linecast doesn't hit anything then that the target object doesn't have a collider and there is nothing in the way + if (targetObject.gameObject.activeSelf) { + return targetObject; + } + } + } else { +#if UNITY_EDITOR + if (drawDebugRay) { + Debug.DrawLine(transform.TransformPoint(positionOffset), targetObject.transform.TransformPoint(targetOffset), angle >= fieldOfViewAngle * 0.5f ? Color.red : Color.magenta); + } +#endif + } + // return null if the target object is not within sight + return null; + } + + public static Transform LineOfSight(Transform transform, Vector3 positionOffset, GameObject targetObject, Vector3 targetOffset, bool usePhysics2D, int ignoreLayerMask, bool drawDebugRay) + { + Transform hitTransform = null; + if (usePhysics2D) { + RaycastHit2D hit; + if ((hit = Physics2D.Linecast(transform.TransformPoint(positionOffset), targetObject.transform.TransformPoint(targetOffset), ~ignoreLayerMask))) { + hitTransform = hit.transform; + } + } else { + RaycastHit hit; + if (Physics.Linecast(transform.TransformPoint(positionOffset), targetObject.transform.TransformPoint(targetOffset), out hit, ~ignoreLayerMask, QueryTriggerInteraction.Ignore)) { + hitTransform = hit.transform; + } + } + return hitTransform; + } + + // Is the hitObject an ancestor of the target? + public static bool IsAncestor(Transform target, Transform hitTransform) + { + return hitTransform.IsChildOf(target) || target.IsChildOf(hitTransform); + } + + // Cast a sphere with the desired radius. Check each object's audio source to see if audio is playing. If audio is playing + // and its audibility is greater than the audibility threshold then return the object heard + public static GameObject WithinHearingRange(Transform transform, Vector3 positionOffset, float audibilityThreshold, float hearingRadius, Collider[] overlapColliders, LayerMask objectLayerMask) + { + GameObject objectHeard = null; + var hitCount = Physics.OverlapSphereNonAlloc(transform.TransformPoint(positionOffset), hearingRadius, overlapColliders, objectLayerMask, QueryTriggerInteraction.Ignore); + if (hitCount > 0) { +#if UNITY_EDITOR + if (hitCount == overlapColliders.Length) { + Debug.LogWarning("Warning: The hit count is equal to the max collider array size. This will cause objects to be missed. Consider increasing the max collision count size."); + } +#endif + float maxAudibility = 0; + for (int i = 0; i < hitCount; ++i) { + float audibility = 0; + GameObject obj; + // Call the WithinHearingRange function to determine if this specific object is within hearing range + if ((obj = WithinHearingRange(transform, positionOffset, audibilityThreshold, overlapColliders[i].gameObject, ref audibility)) != null) { + // This object is within hearing range. Set it to the objectHeard GameObject if the audibility is less than any of the other objects + if (audibility > maxAudibility) { + maxAudibility = audibility; + objectHeard = obj; + } + } + } + } + return objectHeard; + } + + // Cast a circle with the desired radius. Check each object's audio source to see if audio is playing. If audio is playing + // and its audibility is greater than the audibility threshold then return the object heard + public static GameObject WithinHearingRange2D(Transform transform, Vector3 positionOffset, float audibilityThreshold, float hearingRadius, Collider2D[] overlapColliders, LayerMask objectLayerMask) + { + GameObject objectHeard = null; + var hitCount = Physics2D.OverlapCircleNonAlloc(transform.TransformPoint(positionOffset), hearingRadius, overlapColliders, objectLayerMask); + if (hitCount > 0) { +#if UNITY_EDITOR + if (hitCount == overlapColliders.Length) { + Debug.LogWarning("Warning: The hit count is equal to the max collider array size. This will cause objects to be missed. Consider increasing the max collision count size."); + } +#endif + float maxAudibility = 0; + for (int i = 0; i < hitCount; ++i) { + float audibility = 0; + GameObject obj; + // Call the WithinHearingRange function to determine if this specific object is within hearing range + if ((obj = WithinHearingRange(transform, positionOffset, audibilityThreshold, overlapColliders[i].gameObject, ref audibility)) != null) { + // This object is within hearing range. Set it to the objectHeard GameObject if the audibility is less than any of the other objects + if (audibility > maxAudibility) { + maxAudibility = audibility; + objectHeard = obj; + } + } + } + } + return objectHeard; + } + + // Public helper function that will automatically create an audibility variable that is not used. This function is useful if the calling call doesn't + // care about the audibility value + public static GameObject WithinHearingRange(Transform transform, Vector3 positionOffset, float audibilityThreshold, GameObject targetObject) + { + float audibility = 0; + return WithinHearingRange(transform, positionOffset, audibilityThreshold, targetObject, ref audibility); + } + + public static GameObject WithinHearingRange(Transform transform, Vector3 positionOffset, float audibilityThreshold, GameObject targetObject, ref float audibility) + { + AudioSource[] colliderAudioSource; + // Check to see if the hit agent has an audio source and that audio source is playing + if ((colliderAudioSource = GetComponentsForType(targetObject)) != null) { + for (int i = 0; i < colliderAudioSource.Length; ++i) { + if (colliderAudioSource[i].isPlaying) { + var distance = Vector3.Distance(transform.position, targetObject.transform.position); + if (colliderAudioSource[i].rolloffMode == AudioRolloffMode.Logarithmic) { + audibility = 1 / (1 + colliderAudioSource[i].maxDistance * (distance - 1)); + } else { // linear + audibility = colliderAudioSource[i].volume * Mathf.Clamp01((distance - colliderAudioSource[i].minDistance) / (colliderAudioSource[i].maxDistance - colliderAudioSource[i].minDistance)); + } + if (audibility > audibilityThreshold) { + return targetObject; + } + } + } + } + return null; + } + + // Draws the line of sight representation + public static void DrawLineOfSight(Transform transform, Vector3 positionOffset, float fieldOfViewAngle, float angleOffset, float viewDistance, bool usePhysics2D) + { +#if UNITY_EDITOR + var oldColor = UnityEditor.Handles.color; + var color = Color.yellow; + color.a = 0.1f; + UnityEditor.Handles.color = color; + + var halfFOV = fieldOfViewAngle * 0.5f + angleOffset; + var beginDirection = Quaternion.AngleAxis(-halfFOV, (usePhysics2D ? transform.forward : transform.up)) * (usePhysics2D ? transform.up : transform.forward); + UnityEditor.Handles.DrawSolidArc(transform.TransformPoint(positionOffset), (usePhysics2D ? transform.forward : transform.up), beginDirection, fieldOfViewAngle, viewDistance); + + UnityEditor.Handles.color = oldColor; +#endif + } + + public static T GetComponentForType(GameObject target) where T : Component + { + Dictionary typeComponentMap; + Component targetComponent; + // Return the cached component if it exists. + if (gameObjectComponentMap.TryGetValue(target, out typeComponentMap)) { + if (typeComponentMap.TryGetValue(typeof(T), out targetComponent)) { + return targetComponent as T; + } + } else { + // The cached component doesn't exist for the specified type. + typeComponentMap = new Dictionary(); + gameObjectComponentMap.Add(target, typeComponentMap); + } + + // Find the component reference and cache the results. + targetComponent = target.GetComponent(); + typeComponentMap.Add(typeof(T), targetComponent); + return targetComponent as T; + } + + public static T GetParentComponentForType(GameObject target) where T : Component + { + Dictionary typeComponentMap; + Component targetComponent; + // Return the cached component if it exists. + if (gameObjectParentComponentMap.TryGetValue(target, out typeComponentMap)) { + if (typeComponentMap.TryGetValue(typeof(T), out targetComponent)) { + return targetComponent as T; + } + } else { + // The cached component doesn't exist for the specified type. + typeComponentMap = new Dictionary(); + gameObjectParentComponentMap.Add(target, typeComponentMap); + } + + // Find the component reference and cache the results. + targetComponent = target.GetComponentInParent(); + typeComponentMap.Add(typeof(T), targetComponent); + return targetComponent as T; + } + + public static T[] GetComponentsForType(GameObject target) where T : Component + { + Dictionary typeComponentsMap; + Component[] targetComponents; + // Return the cached component if it exists. + if (gameObjectComponentsMap.TryGetValue(target, out typeComponentsMap)) { + if (typeComponentsMap.TryGetValue(typeof(T), out targetComponents)) { + return targetComponents as T[]; + } + } else { + // The cached components doesn't exist for the specified type. + typeComponentsMap = new Dictionary(); + gameObjectComponentsMap.Add(target, typeComponentsMap); + } + + // Find the component reference and cache the results. + targetComponents = target.GetComponents(); + typeComponentsMap.Add(typeof(T), targetComponents); + return targetComponents as T[]; + } + + // Clears the static references. + public static void ClearCache() + { + gameObjectComponentMap.Clear(); + gameObjectComponentsMap.Clear(); + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer Movement/Scripts/MovementUtility.cs.meta b/Assets/Behavior Designer Movement/Scripts/MovementUtility.cs.meta new file mode 100644 index 0000000..d77a3ed --- /dev/null +++ b/Assets/Behavior Designer Movement/Scripts/MovementUtility.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 23cee7cf3a3935c40ab4acc084e400e7 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer Movement/Scripts/Tasks.meta b/Assets/Behavior Designer Movement/Scripts/Tasks.meta new file mode 100644 index 0000000..6eef878 --- /dev/null +++ b/Assets/Behavior Designer Movement/Scripts/Tasks.meta @@ -0,0 +1,4 @@ +fileFormatVersion: 2 +guid: a346c322cf10ef6459878863b10d2b59 +DefaultImporter: + userData: diff --git a/Assets/Behavior Designer Movement/Scripts/Tasks/CanHearObject.cs b/Assets/Behavior Designer Movement/Scripts/Tasks/CanHearObject.cs new file mode 100644 index 0000000..a362f05 --- /dev/null +++ b/Assets/Behavior Designer Movement/Scripts/Tasks/CanHearObject.cs @@ -0,0 +1,117 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Movement +{ + [TaskDescription("Check to see if the any objects are within hearing range of the current agent.")] + [TaskCategory("Movement")] + [HelpURL("https://www.opsive.com/support/documentation/behavior-designer-movement-pack/")] + [TaskIcon("Assets/Behavior Designer Movement/Editor/Icons/{SkinColor}CanHearObjectIcon.png")] + public class CanHearObject : Conditional + { + [Tooltip("Should the 2D version be used?")] + public bool usePhysics2D; + [Tooltip("The object that we are searching for")] + public SharedGameObject targetObject; + [Tooltip("The objects that we are searching for")] + public SharedGameObjectList targetObjects; + [Tooltip("The tag of the object that we are searching for")] + public SharedString targetTag; + [Tooltip("The LayerMask of the objects that we are searching for")] + public LayerMask objectLayerMask; + [Tooltip("If using the object layer mask, specifies the maximum number of colliders that the physics cast can collide with")] + public int maxCollisionCount = 200; + [Tooltip("How far away the unit can hear")] + public SharedFloat hearingRadius = 50; + [Tooltip("The further away a sound source is the less likely the agent will be able to hear it. " + + "Set a threshold for the the minimum audibility level that the agent can hear")] + public SharedFloat audibilityThreshold = 0.05f; + [Tooltip("The hearing offset relative to the pivot position")] + public SharedVector3 offset; + [Tooltip("The returned object that is heard")] + public SharedGameObject returnedObject; + + private Collider[] overlapColliders; + private Collider2D[] overlap2DColliders; + + // Returns success if an object was found otherwise failure + public override TaskStatus OnUpdate() + { + if (targetObjects.Value != null && targetObjects.Value.Count > 0) { // If there are objects in the group list then search for the object within that list + GameObject objectFound = null; + for (int i = 0; i < targetObjects.Value.Count; ++i) { + float audibility = 0; + GameObject obj; + if (Vector3.Distance(targetObjects.Value[i].transform.position, transform.position) < hearingRadius.Value) { + if ((obj = MovementUtility.WithinHearingRange(transform, offset.Value, audibilityThreshold.Value, targetObjects.Value[i], ref audibility)) != null) { + objectFound = obj; + } + } + } + returnedObject.Value = objectFound; + } else if (targetObject.Value == null) { // If the target object is null then determine if there are any objects within hearing range based on the layer mask + if (usePhysics2D) { + if (overlap2DColliders == null) { + overlap2DColliders = new Collider2D[maxCollisionCount]; + } + returnedObject.Value = MovementUtility.WithinHearingRange2D(transform, offset.Value, audibilityThreshold.Value, hearingRadius.Value, overlap2DColliders, objectLayerMask); + } else { + if (overlapColliders == null) { + overlapColliders = new Collider[maxCollisionCount]; + } + returnedObject.Value = MovementUtility.WithinHearingRange(transform, offset.Value, audibilityThreshold.Value, hearingRadius.Value, overlapColliders, objectLayerMask); + } + } else if (!string.IsNullOrEmpty(targetTag.Value)) { + GameObject objectFound = null; + var targets = GameObject.FindGameObjectsWithTag(targetTag.Value); + for (int i = 0; i < targets.Length; ++i) { + float audibility = 0; + GameObject obj; + if (Vector3.Distance(targetObjects.Value[i].transform.position, transform.position) < hearingRadius.Value) { + if ((obj = MovementUtility.WithinHearingRange(transform, offset.Value, audibilityThreshold.Value, targetObjects.Value[i], ref audibility)) != null) { + objectFound = obj; + } + } + } + returnedObject.Value = objectFound; + } else { + var target = targetObject.Value; + if (Vector3.Distance(target.transform.position, transform.position) < hearingRadius.Value) { + returnedObject.Value = MovementUtility.WithinHearingRange(transform, offset.Value, audibilityThreshold.Value, targetObject.Value); + } + } + + if (returnedObject.Value != null) { + // returnedObject success if an object was heard + return TaskStatus.Success; + } + // An object is not within heard so return failure + return TaskStatus.Failure; + } + + // Reset the public variables + public override void OnReset() + { + hearingRadius = 50; + audibilityThreshold = 0.05f; + } + + // Draw the hearing radius + public override void OnDrawGizmos() + { +#if UNITY_EDITOR + if (Owner == null || hearingRadius == null) { + return; + } + var oldColor = UnityEditor.Handles.color; + UnityEditor.Handles.color = Color.yellow; + UnityEditor.Handles.DrawWireDisc(Owner.transform.position, Owner.transform.up, hearingRadius.Value); + UnityEditor.Handles.color = oldColor; +#endif + } + + public override void OnBehaviorComplete() + { + MovementUtility.ClearCache(); + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer Movement/Scripts/Tasks/CanHearObject.cs.meta b/Assets/Behavior Designer Movement/Scripts/Tasks/CanHearObject.cs.meta new file mode 100644 index 0000000..7afec4d --- /dev/null +++ b/Assets/Behavior Designer Movement/Scripts/Tasks/CanHearObject.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 634d2d6246879f74e8c8e4fe199fa82b +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer Movement/Scripts/Tasks/CanSeeObject.cs b/Assets/Behavior Designer Movement/Scripts/Tasks/CanSeeObject.cs new file mode 100644 index 0000000..d9e5db7 --- /dev/null +++ b/Assets/Behavior Designer Movement/Scripts/Tasks/CanSeeObject.cs @@ -0,0 +1,202 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Movement +{ + [TaskDescription("Check to see if the any objects are within sight of the agent.")] + [TaskCategory("Movement")] + [HelpURL("https://www.opsive.com/support/documentation/behavior-designer-movement-pack/")] + [TaskIcon("Assets/Behavior Designer Movement/Editor/Icons/{SkinColor}CanSeeObjectIcon.png")] + public class CanSeeObject : Conditional + { + [Tooltip("Should the 2D version be used?")] + public bool usePhysics2D; + [Tooltip("The object that we are searching for")] + public SharedGameObject targetObject; + [Tooltip("The objects that we are searching for")] + public SharedGameObjectList targetObjects; + [Tooltip("The tag of the object that we are searching for")] + public SharedString targetTag; + [Tooltip("The LayerMask of the objects that we are searching for")] + public LayerMask objectLayerMask; + [Tooltip("If using the object layer mask, specifies the maximum number of colliders that the physics cast can collide with")] + public int maxCollisionCount = 200; + [Tooltip("The LayerMask of the objects to ignore when performing the line of sight check")] + public LayerMask ignoreLayerMask; + [Tooltip("The field of view angle of the agent (in degrees)")] + public SharedFloat fieldOfViewAngle = 90; + [Tooltip("The distance that the agent can see")] + public SharedFloat viewDistance = 1000; + [Tooltip("The raycast offset relative to the pivot position")] + public SharedVector3 offset; + [Tooltip("The target raycast offset relative to the pivot position")] + public SharedVector3 targetOffset; + [Tooltip("The offset to apply to 2D angles")] + public SharedFloat angleOffset2D; + [Tooltip("Should the target bone be used?")] + public SharedBool useTargetBone; + [Tooltip("The target's bone if the target is a humanoid")] + public HumanBodyBones targetBone; + [Tooltip("Should a debug look ray be drawn to the scene view?")] + public SharedBool drawDebugRay; + [Tooltip("Should the agent's layer be disabled before the Can See Object check is executed?")] + public SharedBool disableAgentColliderLayer; + [Tooltip("The object that is within sight")] + public SharedGameObject returnedObject; + + private GameObject[] agentColliderGameObjects; + private int[] originalColliderLayer; + private Collider[] overlapColliders; + private Collider2D[] overlap2DColliders; + + private int ignoreRaycastLayer = LayerMask.NameToLayer("Ignore Raycast"); + + // Returns success if an object was found otherwise failure + public override TaskStatus OnUpdate() + { + // The collider layers on the agent can be set to ignore raycast to prevent them from interferring with the raycast checks. + if (disableAgentColliderLayer.Value) { + if (agentColliderGameObjects == null) { + if (usePhysics2D) { + var colliders = gameObject.GetComponentsInChildren(); + agentColliderGameObjects = new GameObject[colliders.Length]; + for (int i = 0; i < agentColliderGameObjects.Length; ++i) { + agentColliderGameObjects[i] = colliders[i].gameObject; + } + } else { + var colliders = gameObject.GetComponentsInChildren(); + agentColliderGameObjects = new GameObject[colliders.Length]; + for (int i = 0; i < agentColliderGameObjects.Length; ++i) { + agentColliderGameObjects[i] = colliders[i].gameObject; + } + } + originalColliderLayer = new int[agentColliderGameObjects.Length]; + } + + // Change the layer. Remember the previous layer so it can be reset after the check has completed. + for (int i = 0; i < agentColliderGameObjects.Length; ++i) { + originalColliderLayer[i] = agentColliderGameObjects[i].layer; + agentColliderGameObjects[i].layer = ignoreRaycastLayer; + } + } + + if (usePhysics2D) { + if (targetObjects.Value != null && targetObjects.Value.Count > 0) { // If there are objects in the group list then search for the object within that list + GameObject objectFound = null; + float minAngle = Mathf.Infinity; + for (int i = 0; i < targetObjects.Value.Count; ++i) { + float angle; + GameObject obj; + if ((obj = MovementUtility.WithinSight(transform, offset.Value, fieldOfViewAngle.Value, viewDistance.Value, targetObjects.Value[i], targetOffset.Value, true, angleOffset2D.Value, out angle, ignoreLayerMask, useTargetBone.Value, targetBone, drawDebugRay.Value)) != null) { + // This object is within sight. Set it to the objectFound GameObject if the angle is less than any of the other objects + if (angle < minAngle) { + minAngle = angle; + objectFound = obj; + } + } + } + returnedObject.Value = objectFound; + } else if (targetObject.Value != null) { // If the target is not null then determine if that object is within sight + returnedObject.Value = MovementUtility.WithinSight2D(transform, offset.Value, fieldOfViewAngle.Value, viewDistance.Value, targetObject.Value, targetOffset.Value, angleOffset2D.Value, ignoreLayerMask, useTargetBone.Value, targetBone, drawDebugRay.Value); + } else if (!string.IsNullOrEmpty(targetTag.Value)) { // If the target tag is not null then determine if there are any objects within sight based on the tag + GameObject objectFound = null; + float minAngle = Mathf.Infinity; + var targets = GameObject.FindGameObjectsWithTag(targetTag.Value); + for (int i = 0; i < targets.Length; ++i) { + float angle; + GameObject obj; + if ((obj = MovementUtility.WithinSight(transform, offset.Value, fieldOfViewAngle.Value, viewDistance.Value, targets[i], targetOffset.Value, true, angleOffset2D.Value, out angle, ignoreLayerMask, useTargetBone.Value, targetBone, drawDebugRay.Value)) != null) { + // This object is within sight. Set it to the objectFound GameObject if the angle is less than any of the other objects + if (angle < minAngle) { + minAngle = angle; + objectFound = obj; + } + } + } + returnedObject.Value = objectFound; + } else { // If the target object is null and there is no tag then determine if there are any objects within sight based on the layer mask + if (overlap2DColliders == null) { + overlap2DColliders = new Collider2D[maxCollisionCount]; + } + returnedObject.Value = MovementUtility.WithinSight2D(transform, offset.Value, fieldOfViewAngle.Value, viewDistance.Value, overlap2DColliders, objectLayerMask, targetOffset.Value, angleOffset2D.Value, ignoreLayerMask, drawDebugRay.Value); + } + } else { + if (targetObjects.Value != null && targetObjects.Value.Count > 0) { // If there are objects in the group list then search for the object within that list + GameObject objectFound = null; + float minAngle = Mathf.Infinity; + for (int i = 0; i < targetObjects.Value.Count; ++i) { + float angle; + GameObject obj; + if ((obj = MovementUtility.WithinSight(transform, offset.Value, fieldOfViewAngle.Value, viewDistance.Value, targetObjects.Value[i], targetOffset.Value, false, angleOffset2D.Value, out angle, ignoreLayerMask, useTargetBone.Value, targetBone, drawDebugRay.Value)) != null) { + // This object is within sight. Set it to the objectFound GameObject if the angle is less than any of the other objects + if (angle < minAngle) { + minAngle = angle; + objectFound = obj; + } + } + } + returnedObject.Value = objectFound; + } else if (targetObject.Value != null) { // If the target is not null then determine if that object is within sight + returnedObject.Value = MovementUtility.WithinSight(transform, offset.Value, fieldOfViewAngle.Value, viewDistance.Value, targetObject.Value, targetOffset.Value, ignoreLayerMask, useTargetBone.Value, targetBone, drawDebugRay.Value); + } else if (!string.IsNullOrEmpty(targetTag.Value)) { // If the target tag is not null then determine if there are any objects within sight based on the tag + GameObject objectFound = null; + float minAngle = Mathf.Infinity; + var targets = GameObject.FindGameObjectsWithTag(targetTag.Value); + for (int i = 0; i < targets.Length; ++i) { + float angle; + GameObject obj; + if ((obj = MovementUtility.WithinSight(transform, offset.Value, fieldOfViewAngle.Value, viewDistance.Value, targets[i], targetOffset.Value, false, angleOffset2D.Value, out angle, ignoreLayerMask, useTargetBone.Value, targetBone, drawDebugRay.Value)) != null) { + // This object is within sight. Set it to the objectFound GameObject if the angle is less than any of the other objects + if (angle < minAngle) { + minAngle = angle; + objectFound = obj; + } + } + } + returnedObject.Value = objectFound; + } else { // If the target object is null and there is no tag then determine if there are any objects within sight based on the layer mask + if (overlapColliders == null) { + overlapColliders = new Collider[maxCollisionCount]; + } + returnedObject.Value = MovementUtility.WithinSight(transform, offset.Value, fieldOfViewAngle.Value, viewDistance.Value, overlapColliders, objectLayerMask, targetOffset.Value, ignoreLayerMask, useTargetBone.Value, targetBone, drawDebugRay.Value); + } + } + + if (disableAgentColliderLayer.Value) { + for (int i = 0; i < agentColliderGameObjects.Length; ++i) { + agentColliderGameObjects[i].layer = originalColliderLayer[i]; + } + } + + if (returnedObject.Value != null) { + // Return success if an object was found + return TaskStatus.Success; + } + // An object is not within sight so return failure + return TaskStatus.Failure; + } + + // Reset the public variables + public override void OnReset() + { + fieldOfViewAngle = 90; + viewDistance = 1000; + offset = Vector3.zero; + targetOffset = Vector3.zero; + angleOffset2D = 0; + targetTag = ""; + drawDebugRay = false; + ignoreLayerMask = 1 << LayerMask.NameToLayer("Ignore Raycast"); + } + + // Draw the line of sight representation within the scene window + public override void OnDrawGizmos() + { + MovementUtility.DrawLineOfSight(Owner.transform, offset.Value, fieldOfViewAngle.Value, angleOffset2D.Value, viewDistance.Value, usePhysics2D); + } + + public override void OnBehaviorComplete() + { + MovementUtility.ClearCache(); + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer Movement/Scripts/Tasks/CanSeeObject.cs.meta b/Assets/Behavior Designer Movement/Scripts/Tasks/CanSeeObject.cs.meta new file mode 100644 index 0000000..b0dd7f3 --- /dev/null +++ b/Assets/Behavior Designer Movement/Scripts/Tasks/CanSeeObject.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 5534277ff5a25bd4abed31059ad7904c +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer Movement/Scripts/Tasks/Cover.cs b/Assets/Behavior Designer Movement/Scripts/Tasks/Cover.cs new file mode 100644 index 0000000..103de78 --- /dev/null +++ b/Assets/Behavior Designer Movement/Scripts/Tasks/Cover.cs @@ -0,0 +1,100 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Movement +{ + [TaskDescription("Find a place to hide and move to it using the Unity NavMesh.")] + [TaskCategory("Movement")] + [HelpURL("https://www.opsive.com/support/documentation/behavior-designer-movement-pack/")] + [TaskIcon("Assets/Behavior Designer Movement/Editor/Icons/{SkinColor}CoverIcon.png")] + public class Cover : NavMeshMovement + { + [Tooltip("The distance to search for cover")] + public SharedFloat maxCoverDistance = 1000; + [Tooltip("The layermask of the available cover positions")] + public LayerMask availableLayerCovers; + [Tooltip("The maximum number of raycasts that should be fired before the agent gives up looking for an agent to find cover behind")] + public SharedInt maxRaycasts = 100; + [Tooltip("How large the step should be between raycasts")] + public SharedFloat rayStep = 1; + [Tooltip("Once a cover point has been found, multiply this offset by the normal to prevent the agent from hugging the wall")] + public SharedFloat coverOffset = 2; + [Tooltip("Should the agent look at the cover point after it has arrived?")] + public SharedBool lookAtCoverPoint = false; + [Tooltip("The agent is done rotating to the cover point when the square magnitude is less than this value")] + public SharedFloat rotationEpsilon = 0.5f; + [Tooltip("Max rotation delta if lookAtCoverPoint")] + public SharedFloat maxLookAtRotationDelta; + + private Vector3 coverPoint; + // The position to reach, offsetted from coverPoint + private Vector3 coverTarget; + // Was cover found? + private bool foundCover; + + public override void OnStart() + { + RaycastHit hit; + int raycastCount = 0; + var direction = transform.forward; + float step = 0; + coverTarget = transform.position; + foundCover = false; + // Keep firing a ray until too many rays have been fired + while (raycastCount < maxRaycasts.Value) { + var ray = new Ray(transform.position, direction); + if (Physics.Raycast(ray, out hit, maxCoverDistance.Value, availableLayerCovers.value)) { + // A suitable agent has been found. Find the opposite side of that agent by shooting a ray in the opposite direction from a point far away + if (hit.collider.Raycast(new Ray(hit.point - hit.normal * maxCoverDistance.Value, hit.normal), out hit, Mathf.Infinity)) { + coverPoint = hit.point; + coverTarget = hit.point + hit.normal * coverOffset.Value; + foundCover = true; + break; + } + } + // Keep sweeiping along the y axis + step += rayStep.Value; + direction = Quaternion.Euler(0, transform.eulerAngles.y + step, 0) * Vector3.forward; + raycastCount++; + } + + if (foundCover) { + SetDestination(coverTarget); + } + + base.OnStart(); + } + + // Seek to the cover point. Return success as soon as the location is reached or the agent is looking at the cover point + public override TaskStatus OnUpdate() + { + if (!foundCover) { + return TaskStatus.Failure; + } + if (HasArrived()) { + var rotation = Quaternion.LookRotation(coverPoint - transform.position); + // Return success if the agent isn't going to look at the cover point or it has completely rotated to look at the cover point + if (!lookAtCoverPoint.Value || Quaternion.Angle(transform.rotation, rotation) < rotationEpsilon.Value) { + return TaskStatus.Success; + } else { + // Still needs to rotate towards the target + transform.rotation = Quaternion.RotateTowards(transform.rotation, rotation, maxLookAtRotationDelta.Value); + } + } + + return TaskStatus.Running; + } + + // Reset the public variables + public override void OnReset() + { + base.OnStart(); + + maxCoverDistance = 1000; + maxRaycasts = 100; + rayStep = 1; + coverOffset = 2; + lookAtCoverPoint = false; + rotationEpsilon = 0.5f; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer Movement/Scripts/Tasks/Cover.cs.meta b/Assets/Behavior Designer Movement/Scripts/Tasks/Cover.cs.meta new file mode 100644 index 0000000..086af44 --- /dev/null +++ b/Assets/Behavior Designer Movement/Scripts/Tasks/Cover.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 4ce745e6d7861534aaaa58a6a60ecc75 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer Movement/Scripts/Tasks/Evade.cs b/Assets/Behavior Designer Movement/Scripts/Tasks/Evade.cs new file mode 100644 index 0000000..131543c --- /dev/null +++ b/Assets/Behavior Designer Movement/Scripts/Tasks/Evade.cs @@ -0,0 +1,81 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Movement +{ + [TaskDescription("Evade the target specified using the Unity NavMesh.")] + [TaskCategory("Movement")] + [HelpURL("https://www.opsive.com/support/documentation/behavior-designer-movement-pack/")] + [TaskIcon("Assets/Behavior Designer Movement/Editor/Icons/{SkinColor}EvadeIcon.png")] + public class Evade : NavMeshMovement + { + [Tooltip("The agent has evaded when the magnitude is greater than this value")] + public SharedFloat evadeDistance = 10; + [Tooltip("The distance to look ahead when evading")] + public SharedFloat lookAheadDistance = 5; + [Tooltip("How far to predict the distance ahead of the target. Lower values indicate less distance should be predicated")] + public SharedFloat targetDistPrediction = 20; + [Tooltip("Multiplier for predicting the look ahead distance")] + public SharedFloat targetDistPredictionMult = 20; + [Tooltip("The GameObject that the agent is evading")] + public SharedGameObject target; + + // The position of the target at the last frame + private Vector3 targetPosition; + + public override void OnStart() + { + base.OnStart(); + + targetPosition = target.Value.transform.position; + SetDestination(Target()); + } + + // Evade from the target. Return success once the agent has fleed the target by moving far enough away from it + // Return running if the agent is still fleeing + public override TaskStatus OnUpdate() + { + if (Vector3.Magnitude(transform.position - target.Value.transform.position) > evadeDistance.Value) { + return TaskStatus.Success; + } + + SetDestination(Target()); + + return TaskStatus.Running; + } + + // Evade in the opposite direction + private Vector3 Target() + { + // Calculate the current distance to the target and the current speed + var distance = (target.Value.transform.position - transform.position).magnitude; + var speed = Velocity().magnitude; + + float futurePrediction = 0; + // Set the future prediction to max prediction if the speed is too small to give an accurate prediction + if (speed <= distance / targetDistPrediction.Value) { + futurePrediction = targetDistPrediction.Value; + } else { + futurePrediction = (distance / speed) * targetDistPredictionMult.Value; // the prediction should be accurate enough + } + + // Predict the future by taking the velocity of the target and multiply it by the future prediction + var prevTargetPosition = targetPosition; + targetPosition = target.Value.transform.position; + var position = targetPosition + (targetPosition - prevTargetPosition) * futurePrediction; + + return transform.position + (transform.position - position).normalized * lookAheadDistance.Value; + } + + // Reset the public variables + public override void OnReset() + { + base.OnReset(); + + evadeDistance = 10; + lookAheadDistance = 5; + targetDistPrediction = 20; + targetDistPredictionMult = 20; + target = null; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer Movement/Scripts/Tasks/Evade.cs.meta b/Assets/Behavior Designer Movement/Scripts/Tasks/Evade.cs.meta new file mode 100644 index 0000000..b0b71bd --- /dev/null +++ b/Assets/Behavior Designer Movement/Scripts/Tasks/Evade.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 4214d47e960a0444491973584f8d4f4a +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer Movement/Scripts/Tasks/Flee.cs b/Assets/Behavior Designer Movement/Scripts/Tasks/Flee.cs new file mode 100644 index 0000000..5d70b7b --- /dev/null +++ b/Assets/Behavior Designer Movement/Scripts/Tasks/Flee.cs @@ -0,0 +1,82 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Movement +{ + [TaskDescription("Flee from the target specified using the Unity NavMesh.")] + [TaskCategory("Movement")] + [HelpURL("https://www.opsive.com/support/documentation/behavior-designer-movement-pack/")] + [TaskIcon("Assets/Behavior Designer Movement/Editor/Icons/{SkinColor}FleeIcon.png")] + public class Flee : NavMeshMovement + { + [Tooltip("The agent has fleed when the magnitude is greater than this value")] + public SharedFloat fleedDistance = 20; + [Tooltip("The distance to look ahead when fleeing")] + public SharedFloat lookAheadDistance = 5; + [Tooltip("The GameObject that the agent is fleeing from")] + public SharedGameObject target; + + private bool hasMoved; + + public override void OnStart() + { + base.OnStart(); + + hasMoved = false; + + SetDestination(Target()); + } + + // Flee from the target. Return success once the agent has fleed the target by moving far enough away from it + // Return running if the agent is still fleeing + public override TaskStatus OnUpdate() + { + if (Vector3.Magnitude(transform.position - target.Value.transform.position) > fleedDistance.Value) { + return TaskStatus.Success; + } + + if (HasArrived()) { + if (!hasMoved) { + return TaskStatus.Failure; + } + if (!SetDestination(Target())) { + return TaskStatus.Failure; + } + hasMoved = false; + } else { + // If the agent is stuck the task shouldn't continue to return a status of running. + var velocityMagnitude = Velocity().sqrMagnitude; + if (hasMoved && velocityMagnitude <= 0f) { + return TaskStatus.Failure; + } + hasMoved = velocityMagnitude > 0f; + } + + return TaskStatus.Running; + } + + // Flee in the opposite direction + private Vector3 Target() + { + return transform.position + (transform.position - target.Value.transform.position).normalized * lookAheadDistance.Value; + } + + // Return false if the position isn't valid on the NavMesh. + protected override bool SetDestination(Vector3 destination) + { + if (!SamplePosition(destination)) { + return false; + } + return base.SetDestination(destination); + } + + // Reset the public variables + public override void OnReset() + { + base.OnReset(); + + fleedDistance = 20; + lookAheadDistance = 5; + target = null; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer Movement/Scripts/Tasks/Flee.cs.meta b/Assets/Behavior Designer Movement/Scripts/Tasks/Flee.cs.meta new file mode 100644 index 0000000..34d8f92 --- /dev/null +++ b/Assets/Behavior Designer Movement/Scripts/Tasks/Flee.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: e4bdc12b530491842b05403138b8425c +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer Movement/Scripts/Tasks/Flock.cs b/Assets/Behavior Designer Movement/Scripts/Tasks/Flock.cs new file mode 100644 index 0000000..029518c --- /dev/null +++ b/Assets/Behavior Designer Movement/Scripts/Tasks/Flock.cs @@ -0,0 +1,89 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Movement +{ + [TaskDescription("Flock around the scene using the Unity NavMesh.")] + [TaskCategory("Movement")] + [HelpURL("https://www.opsive.com/support/documentation/behavior-designer-movement-pack/")] + [TaskIcon("Assets/Behavior Designer Movement/Editor/Icons/{SkinColor}FlockIcon.png")] + public class Flock : NavMeshGroupMovement + { + [Tooltip("Agents less than this distance apart are neighbors")] + public SharedFloat neighborDistance = 100; + [Tooltip("How far the agent should look ahead when determine its pathfinding destination")] + public SharedFloat lookAheadDistance = 5; + [Tooltip("The greater the alignmentWeight is the more likely it is that the agents will be facing the same direction")] + public SharedFloat alignmentWeight = 0.4f; + [Tooltip("The greater the cohesionWeight is the more likely it is that the agents will be moving towards a common position")] + public SharedFloat cohesionWeight = 0.5f; + [Tooltip("The greater the separationWeight is the more likely it is that the agents will be separated")] + public SharedFloat separationWeight = 0.6f; + + // The agents will always be flocking so always return running + public override TaskStatus OnUpdate() + { + // Determine a destination for each agent + for (int i = 0; i < agents.Length; ++i) { + Vector3 alignment, cohesion, separation; + // determineFlockAttributes will determine which direction to head, which common position to move toward, and how far apart each agent is from one another, + DetermineFlockParameters(i, out alignment, out cohesion, out separation); + // Weigh each parameter to give one more of an influence than another + var velocity = alignment * alignmentWeight.Value + cohesion * cohesionWeight.Value + separation * separationWeight.Value; + // Set the destination based on the velocity multiplied by the look ahead distance + if (!SetDestination(i, transforms[i].position + velocity * lookAheadDistance.Value)) { + // Go the opposite direction if the destination is invalid + velocity *= -1; + SetDestination(i, transforms[i].position + velocity * lookAheadDistance.Value); + } + } + return TaskStatus.Running; + } + + // Determine the three flock parameters: alignment, cohesion, and separation. + // Alignment: determines which direction to move + // Cohesion: Determines a common position to move towards + // Separation: Determines how far apart the agent is from all other agents + private void DetermineFlockParameters(int index, out Vector3 alignment, out Vector3 cohesion, out Vector3 separation) + { + alignment = cohesion = separation = Vector3.zero; + int neighborCount = 0; + var agentPosition = transforms[index].position; + // Loop through each agent to determine the alignment, cohesion, and separation + for (int i = 0; i < agents.Length; ++i) { + // The agent can't compare against itself + if (index != i) { + var position = transforms[i].position; + // Only determine the parameters if the other agent is its neighbor + if (Vector3.Magnitude(position - agentPosition) < neighborDistance.Value) { + // This agent is the neighbor of the original agent so add the alignment, cohesion, and separation + alignment += Velocity(i); + cohesion += position; + separation += position - agentPosition; + neighborCount++; + } + } + } + + // Don't move if there are no neighbors + if (neighborCount == 0) { + return; + } + // Normalize all of the values + alignment = (alignment / neighborCount).normalized; + cohesion = ((cohesion / neighborCount) - agentPosition).normalized; + separation = ((separation / neighborCount) * -1).normalized; + } + + // Reset the public variables + public override void OnReset() + { + base.OnReset(); + + neighborDistance = 100; + lookAheadDistance = 5; + alignmentWeight = 0.4f; + cohesionWeight = 0.5f; + separationWeight = 0.6f; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer Movement/Scripts/Tasks/Flock.cs.meta b/Assets/Behavior Designer Movement/Scripts/Tasks/Flock.cs.meta new file mode 100644 index 0000000..566e472 --- /dev/null +++ b/Assets/Behavior Designer Movement/Scripts/Tasks/Flock.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 4c65234f4d5eeb440b84fe6a529ecbe3 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer Movement/Scripts/Tasks/Follow.cs b/Assets/Behavior Designer Movement/Scripts/Tasks/Follow.cs new file mode 100644 index 0000000..67f1cec --- /dev/null +++ b/Assets/Behavior Designer Movement/Scripts/Tasks/Follow.cs @@ -0,0 +1,63 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Movement +{ + [TaskDescription("Follows the specified target using the Unity NavMesh.")] + [TaskCategory("Movement")] + [HelpURL("https://www.opsive.com/support/documentation/behavior-designer-movement-pack/")] + [TaskIcon("Assets/Behavior Designer Movement/Editor/Icons/{SkinColor}FollowIcon.png")] + public class Follow : NavMeshMovement + { + [Tooltip("The GameObject that the agent is following")] + public SharedGameObject target; + [Tooltip("Start moving towards the target if the target is further than the specified distance")] + public SharedFloat moveDistance = 2; + + private Vector3 lastTargetPosition; + private bool hasMoved; + + public override void OnStart() + { + base.OnStart(); + + if (target.Value == null) { + return; + } + + lastTargetPosition = target.Value.transform.position + Vector3.one * (moveDistance.Value + 1); + hasMoved = false; + } + + // Follow the target. The task will never return success as the agent should continue to follow the target even after arriving at the destination. + public override TaskStatus OnUpdate() + { + if (target.Value == null) { + return TaskStatus.Failure; + } + + // Move if the target has moved more than the moveDistance since the last time the agent moved. + var targetPosition = target.Value.transform.position; + if ((targetPosition - lastTargetPosition).magnitude >= moveDistance.Value) { + SetDestination(targetPosition); + lastTargetPosition = targetPosition; + hasMoved = true; + } else { + // Stop moving if the agent is within the moveDistance of the target. + if (hasMoved && (targetPosition - transform.position).magnitude < moveDistance.Value) { + Stop(); + hasMoved = false; + lastTargetPosition = targetPosition; + } + } + + return TaskStatus.Running; + } + + public override void OnReset() + { + base.OnReset(); + target = null; + moveDistance = 2; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer Movement/Scripts/Tasks/Follow.cs.meta b/Assets/Behavior Designer Movement/Scripts/Tasks/Follow.cs.meta new file mode 100644 index 0000000..2f510da --- /dev/null +++ b/Assets/Behavior Designer Movement/Scripts/Tasks/Follow.cs.meta @@ -0,0 +1,12 @@ +fileFormatVersion: 2 +guid: 5d30354af5d5197448f0d29da1f0df5e +timeCreated: 1470312169 +licenseType: Store +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Behavior Designer Movement/Scripts/Tasks/LeaderFollow.cs b/Assets/Behavior Designer Movement/Scripts/Tasks/LeaderFollow.cs new file mode 100644 index 0000000..597ae79 --- /dev/null +++ b/Assets/Behavior Designer Movement/Scripts/Tasks/LeaderFollow.cs @@ -0,0 +1,103 @@ +using UnityEngine; +using UnityEngine.AI; + +namespace BehaviorDesigner.Runtime.Tasks.Movement +{ + [TaskDescription("Follow the leader using the Unity NavMesh.")] + [TaskCategory("Movement")] + [HelpURL("https://www.opsive.com/support/documentation/behavior-designer-movement-pack/")] + [TaskIcon("Assets/Behavior Designer Movement/Editor/Icons/{SkinColor}LeaderFollowIcon.png")] + public class LeaderFollow : NavMeshGroupMovement + { + [Tooltip("Agents less than this distance apart are neighbors")] + public SharedFloat neighborDistance = 10; + [Tooltip("How far behind the leader the agents should follow the leader")] + public SharedFloat leaderBehindDistance = 2; + [Tooltip("The distance that the agents should be separated")] + public SharedFloat separationDistance = 2; + [Tooltip("The agent is getting too close to the front of the leader if they are within the aheadDistance")] + public SharedFloat aheadDistance = 2; + [Tooltip("The leader to follow")] + public SharedGameObject leader = null; + + // component cache + private Transform leaderTransform; + private NavMeshAgent leaderAgent; + + public override void OnStart() + { + leaderTransform = leader.Value.transform; + leaderAgent = leader.Value.GetComponent(); + + base.OnStart(); + } + + // The agents will always be following the leader so always return running + public override TaskStatus OnUpdate() + { + var behindPosition = LeaderBehindPosition(); + // Determine a destination for each agent + for (int i = 0; i < agents.Length; ++i) { + // Get out of the way of the leader if the leader is currently looking at the agent and is getting close + if (LeaderLookingAtAgent(i) && Vector3.Magnitude(leaderTransform.position - transforms[i].position) < aheadDistance.Value) { + SetDestination(i, transforms[i].position + (transforms[i].position - leaderTransform.position).normalized * aheadDistance.Value); + } else { + // The destination is the behind position added to the separation vector + SetDestination(i, behindPosition + DetermineSeparation(i)); + } + } + return TaskStatus.Running; + } + + private Vector3 LeaderBehindPosition() + { + // The behind position is the normalized inverse of the leader's velocity multiplied by the leaderBehindDistance + return leaderTransform.position + (-leaderAgent.velocity).normalized * leaderBehindDistance.Value; + } + + // Determine the separation between the current agent and all of the other agents also following the leader + private Vector3 DetermineSeparation(int agentIndex) + { + var separation = Vector3.zero; + int neighborCount = 0; + var agentTransform = transforms[agentIndex]; + // Loop through each agent to determine the separation + for (int i = 0; i < agents.Length; ++i) { + // The agent can't compare against itself + if (agentIndex != i) { + // Only determine the parameters if the other agent is its neighbor + if (Vector3.SqrMagnitude(transforms[i].position - agentTransform.position) < neighborDistance.Value) { + // This agent is the neighbor of the original agent so add the separation + separation += transforms[i].position - agentTransform.position; + neighborCount++; + } + } + } + + // Don't move if there are no neighbors + if (neighborCount == 0) { + return Vector3.zero; + } + // Normalize the value + return ((separation / neighborCount) * -1).normalized * separationDistance.Value; + } + + // Use the dot product to determine if the leader is looking at the current agent + public bool LeaderLookingAtAgent(int agentIndex) + { + return Vector3.Dot(leaderTransform.forward, transforms[agentIndex].forward) < -0.5f; + } + + // Reset the public variables + public override void OnReset() + { + base.OnReset(); + + neighborDistance = 10; + leaderBehindDistance = 2; + separationDistance = 2; + aheadDistance = 2; + leader = null; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer Movement/Scripts/Tasks/LeaderFollow.cs.meta b/Assets/Behavior Designer Movement/Scripts/Tasks/LeaderFollow.cs.meta new file mode 100644 index 0000000..e4e2284 --- /dev/null +++ b/Assets/Behavior Designer Movement/Scripts/Tasks/LeaderFollow.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 411aa6be7131cc047b9ec3191ba05ca4 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer Movement/Scripts/Tasks/MoveTowards.cs b/Assets/Behavior Designer Movement/Scripts/Tasks/MoveTowards.cs new file mode 100644 index 0000000..6716ab2 --- /dev/null +++ b/Assets/Behavior Designer Movement/Scripts/Tasks/MoveTowards.cs @@ -0,0 +1,56 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Movement +{ + [TaskDescription("Move towards the specified position. The position can either be specified by a transform or position. If the transform " + + "is used then the position will not be used.")] + [TaskCategory("Movement")] + [HelpURL("https://www.opsive.com/support/documentation/behavior-designer-movement-pack/")] + [TaskIcon("Assets/Behavior Designer Movement/Editor/Icons/{SkinColor}MoveTowardsIcon.png")] + public class MoveTowards : Action + { + [Tooltip("The speed of the agent")] + public SharedFloat speed; + [Tooltip("The agent has arrived when the magnitude is less than this value")] + public SharedFloat arriveDistance = 0.1f; + [Tooltip("Should the agent be looking at the target position?")] + public SharedBool lookAtTarget = true; + [Tooltip("Max rotation delta if lookAtTarget is enabled")] + public SharedFloat maxLookAtRotationDelta; + [Tooltip("The GameObject that the agent is moving towards")] + public SharedGameObject target; + [Tooltip("If target is null then use the target position")] + public SharedVector3 targetPosition; + + public override TaskStatus OnUpdate() + { + var position = Target(); + // Return a task status of success once we've reached the target + if (Vector3.Magnitude(transform.position - position) < arriveDistance.Value) { + return TaskStatus.Success; + } + // We haven't reached the target yet so keep moving towards it + transform.position = Vector3.MoveTowards(transform.position, position, speed.Value * Time.deltaTime); + if (lookAtTarget.Value && (position - transform.position).sqrMagnitude > 0.01f) { + transform.rotation = Quaternion.RotateTowards(transform.rotation, Quaternion.LookRotation(position - transform.position), maxLookAtRotationDelta.Value); + } + return TaskStatus.Running; + } + + // Return targetPosition if targetTransform is null + private Vector3 Target() + { + if (target == null || target.Value == null) { + return targetPosition.Value; + } + return target.Value.transform.position; + } + + // Reset the public variables + public override void OnReset() + { + arriveDistance = 0.1f; + lookAtTarget = true; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer Movement/Scripts/Tasks/MoveTowards.cs.meta b/Assets/Behavior Designer Movement/Scripts/Tasks/MoveTowards.cs.meta new file mode 100644 index 0000000..e34d204 --- /dev/null +++ b/Assets/Behavior Designer Movement/Scripts/Tasks/MoveTowards.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 766729a6e22caf24aa69755a0af58804 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer Movement/Scripts/Tasks/NavMeshGroupMovement.cs b/Assets/Behavior Designer Movement/Scripts/Tasks/NavMeshGroupMovement.cs new file mode 100644 index 0000000..0892b9e --- /dev/null +++ b/Assets/Behavior Designer Movement/Scripts/Tasks/NavMeshGroupMovement.cs @@ -0,0 +1,61 @@ +using UnityEngine; +using UnityEngine.AI; + +namespace BehaviorDesigner.Runtime.Tasks.Movement +{ + public abstract class NavMeshGroupMovement : GroupMovement + { + [Tooltip("All of the agents")] + public SharedGameObject[] agents = null; + [Tooltip("The speed of the agents")] + public SharedFloat speed = 10; + [Tooltip("The angular speed of the agents")] + public SharedFloat angularSpeed = 120; + + // A cache of the NavMeshAgents + private NavMeshAgent[] navMeshAgents; + protected Transform[] transforms; + + public override void OnStart() + { + navMeshAgents = new NavMeshAgent[agents.Length]; + transforms = new Transform[agents.Length]; + for (int i = 0; i < agents.Length; ++i) { + transforms[i] = agents[i].Value.transform; + navMeshAgents[i] = agents[i].Value.GetComponent(); + navMeshAgents[i].speed = speed.Value; + navMeshAgents[i].angularSpeed = angularSpeed.Value; + navMeshAgents[i].isStopped = false; + } + } + + protected override bool SetDestination(int index, Vector3 target) + { + if (navMeshAgents[index].destination == target) { + return true; + } + return navMeshAgents[index].SetDestination(target); + } + + protected override Vector3 Velocity(int index) + { + return navMeshAgents[index].velocity; + } + + public override void OnEnd() + { + // Disable the nav mesh + for (int i = 0; i < navMeshAgents.Length; ++i) { + if (navMeshAgents[i] != null) { + navMeshAgents[i].isStopped = true; + } + } + } + + // Reset the public variables + public override void OnReset() + { + agents = null; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer Movement/Scripts/Tasks/NavMeshGroupMovement.cs.meta b/Assets/Behavior Designer Movement/Scripts/Tasks/NavMeshGroupMovement.cs.meta new file mode 100644 index 0000000..6722f70 --- /dev/null +++ b/Assets/Behavior Designer Movement/Scripts/Tasks/NavMeshGroupMovement.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 816bb5c2a0b555e4a9014c7e1eb8c4c0 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer Movement/Scripts/Tasks/NavMeshMovement.cs b/Assets/Behavior Designer Movement/Scripts/Tasks/NavMeshMovement.cs new file mode 100644 index 0000000..ee331b7 --- /dev/null +++ b/Assets/Behavior Designer Movement/Scripts/Tasks/NavMeshMovement.cs @@ -0,0 +1,152 @@ +using UnityEngine; +using UnityEngine.AI; + +namespace BehaviorDesigner.Runtime.Tasks.Movement +{ + public abstract class NavMeshMovement : Movement + { + [Tooltip("The speed of the agent")] + public SharedFloat speed = 10; + [Tooltip("The angular speed of the agent")] + public SharedFloat angularSpeed = 120; + [Tooltip("The agent has arrived when the destination is less than the specified amount. This distance should be greater than or equal to the NavMeshAgent StoppingDistance.")] + public SharedFloat arriveDistance = 0.2f; + [Tooltip("Should the NavMeshAgent be stopped when the task ends?")] + public SharedBool stopOnTaskEnd = true; + [Tooltip("Should the NavMeshAgent rotation be updated when the task ends?")] + public SharedBool updateRotation = true; + + // Component references + protected NavMeshAgent navMeshAgent; + private bool startUpdateRotation; + + /// + /// Cache the component references. + /// + public override void OnAwake() + { + navMeshAgent = GetComponent(); + } + + /// + /// Allow pathfinding to resume. + /// + public override void OnStart() + { + navMeshAgent.speed = speed.Value; + navMeshAgent.angularSpeed = angularSpeed.Value; + navMeshAgent.isStopped = false; + startUpdateRotation = navMeshAgent.updateRotation; + UpdateRotation(updateRotation.Value); + } + + /// + /// Set a new pathfinding destination. + /// + /// The destination to set. + /// True if the destination is valid. + protected override bool SetDestination(Vector3 destination) + { + navMeshAgent.isStopped = false; + return navMeshAgent.SetDestination(destination); + } + + /// + /// Specifies if the rotation should be updated. + /// + /// Should the rotation be updated? + protected override void UpdateRotation(bool update) + { + navMeshAgent.updateRotation = update; + navMeshAgent.updateUpAxis = update; + } + + /// + /// Does the agent have a pathfinding path? + /// + /// True if the agent has a pathfinding path. + protected override bool HasPath() + { + return navMeshAgent.hasPath && navMeshAgent.remainingDistance > arriveDistance.Value; + } + + /// + /// Returns the velocity of the agent. + /// + /// The velocity of the agent. + protected override Vector3 Velocity() + { + return navMeshAgent.velocity; + } + + /// + /// Returns true if the position is a valid pathfinding position. + /// + /// The position to sample. + /// True if the position is a valid pathfinding position. + protected bool SamplePosition(Vector3 position) + { + NavMeshHit hit; + return NavMesh.SamplePosition(position, out hit, navMeshAgent.height * 2, NavMesh.AllAreas); + } + + /// + /// Has the agent arrived at the destination? + /// + /// True if the agent has arrived at the destination. + protected override bool HasArrived() + { + // The path hasn't been computed yet if the path is pending. + float remainingDistance; + if (navMeshAgent.pathPending) { + remainingDistance = float.PositiveInfinity; + } else { + remainingDistance = navMeshAgent.remainingDistance; + } + + return remainingDistance <= arriveDistance.Value; + } + + /// + /// Stop pathfinding. + /// + protected override void Stop() + { + UpdateRotation(startUpdateRotation); + if (navMeshAgent.hasPath) { + navMeshAgent.isStopped = true; + } + } + + /// + /// The task has ended. Stop moving. + /// + public override void OnEnd() + { + if (stopOnTaskEnd.Value) { + Stop(); + } else { + UpdateRotation(startUpdateRotation); + } + } + + /// + /// The behavior tree has ended. Stop moving. + /// + public override void OnBehaviorComplete() + { + Stop(); + } + + /// + /// Reset the values back to their defaults. + /// + public override void OnReset() + { + speed = 10; + angularSpeed = 120; + arriveDistance = 1; + stopOnTaskEnd = true; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer Movement/Scripts/Tasks/NavMeshMovement.cs.meta b/Assets/Behavior Designer Movement/Scripts/Tasks/NavMeshMovement.cs.meta new file mode 100644 index 0000000..45fc2ae --- /dev/null +++ b/Assets/Behavior Designer Movement/Scripts/Tasks/NavMeshMovement.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 235ef0eac75af0343b370b7dd81ddfa6 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer Movement/Scripts/Tasks/Patrol.cs b/Assets/Behavior Designer Movement/Scripts/Tasks/Patrol.cs new file mode 100644 index 0000000..64792a9 --- /dev/null +++ b/Assets/Behavior Designer Movement/Scripts/Tasks/Patrol.cs @@ -0,0 +1,110 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Movement +{ + [TaskDescription("Patrol around the specified waypoints using the Unity NavMesh.")] + [TaskCategory("Movement")] + [HelpURL("https://www.opsive.com/support/documentation/behavior-designer-movement-pack/")] + [TaskIcon("Assets/Behavior Designer Movement/Editor/Icons/{SkinColor}PatrolIcon.png")] + public class Patrol : NavMeshMovement + { + [Tooltip("Should the agent patrol the waypoints randomly?")] + public SharedBool randomPatrol = false; + [Tooltip("The length of time that the agent should pause when arriving at a waypoint")] + public SharedFloat waypointPauseDuration = 0; + [Tooltip("The waypoints to move to")] + public SharedGameObjectList waypoints; + + // The current index that we are heading towards within the waypoints array + private int waypointIndex; + private float waypointReachedTime; + + public override void OnStart() + { + base.OnStart(); + + // initially move towards the closest waypoint + float distance = Mathf.Infinity; + float localDistance; + for (int i = 0; i < waypoints.Value.Count; ++i) { + if ((localDistance = Vector3.Magnitude(transform.position - waypoints.Value[i].transform.position)) < distance) { + distance = localDistance; + waypointIndex = i; + } + } + waypointReachedTime = -1; + SetDestination(Target()); + } + + // Patrol around the different waypoints specified in the waypoint array. Always return a task status of running. + public override TaskStatus OnUpdate() + { + if (waypoints.Value.Count == 0) { + return TaskStatus.Failure; + } + if (HasArrived()) { + if (waypointReachedTime == -1) { + waypointReachedTime = Time.time; + } + // wait the required duration before switching waypoints. + if (waypointReachedTime + waypointPauseDuration.Value <= Time.time) { + if (randomPatrol.Value) { + if (waypoints.Value.Count == 1) { + waypointIndex = 0; + } else { + // prevent the same waypoint from being selected + var newWaypointIndex = waypointIndex; + while (newWaypointIndex == waypointIndex) { + newWaypointIndex = Random.Range(0, waypoints.Value.Count); + } + waypointIndex = newWaypointIndex; + } + } else { + waypointIndex = (waypointIndex + 1) % waypoints.Value.Count; + } + SetDestination(Target()); + waypointReachedTime = -1; + } + } + + return TaskStatus.Running; + } + + // Return the current waypoint index position + private Vector3 Target() + { + if (waypointIndex >= waypoints.Value.Count) { + return transform.position; + } + return waypoints.Value[waypointIndex].transform.position; + } + + // Reset the public variables + public override void OnReset() + { + base.OnReset(); + + randomPatrol = false; + waypointPauseDuration = 0; + waypoints = null; + } + + // Draw a gizmo indicating a patrol + public override void OnDrawGizmos() + { +#if UNITY_EDITOR + if (waypoints == null || waypoints.Value == null) { + return; + } + var oldColor = UnityEditor.Handles.color; + UnityEditor.Handles.color = Color.yellow; + for (int i = 0; i < waypoints.Value.Count; ++i) { + if (waypoints.Value[i] != null) { + UnityEditor.Handles.SphereHandleCap(0, waypoints.Value[i].transform.position, waypoints.Value[i].transform.rotation, 1, EventType.Repaint); + } + } + UnityEditor.Handles.color = oldColor; +#endif + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer Movement/Scripts/Tasks/Patrol.cs.meta b/Assets/Behavior Designer Movement/Scripts/Tasks/Patrol.cs.meta new file mode 100644 index 0000000..b7fd096 --- /dev/null +++ b/Assets/Behavior Designer Movement/Scripts/Tasks/Patrol.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: eea43cbff87e7e0468c9e3ac2b949dd0 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer Movement/Scripts/Tasks/Pursue.cs b/Assets/Behavior Designer Movement/Scripts/Tasks/Pursue.cs new file mode 100644 index 0000000..38d2438 --- /dev/null +++ b/Assets/Behavior Designer Movement/Scripts/Tasks/Pursue.cs @@ -0,0 +1,74 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Movement +{ + [TaskDescription("Pursue the target specified using the Unity NavMesh.")] + [TaskCategory("Movement")] + [HelpURL("https://www.opsive.com/support/documentation/behavior-designer-movement-pack/")] + [TaskIcon("Assets/Behavior Designer Movement/Editor/Icons/{SkinColor}PursueIcon.png")] + public class Pursue : NavMeshMovement + { + [Tooltip("How far to predict the distance ahead of the target. Lower values indicate less distance should be predicated")] + public SharedFloat targetDistPrediction = 20; + [Tooltip("Multiplier for predicting the look ahead distance")] + public SharedFloat targetDistPredictionMult = 20; + [Tooltip("The GameObject that the agent is pursuing")] + public SharedGameObject target; + + // The position of the target at the last frame + private Vector3 targetPosition; + + public override void OnStart() + { + base.OnStart(); + + targetPosition = target.Value.transform.position; + SetDestination(Target()); + } + + // Pursue the destination. Return success once the agent has reached the destination. + // Return running if the agent hasn't reached the destination yet + public override TaskStatus OnUpdate() + { + if (HasArrived()) { + return TaskStatus.Success; + } + + // Target will return the predicated position + SetDestination(Target()); + + return TaskStatus.Running; + } + + // Predict the position of the target + private Vector3 Target() + { + // Calculate the current distance to the target and the current speed + var distance = (target.Value.transform.position - transform.position).magnitude; + var speed = Velocity().magnitude; + + float futurePrediction = 0; + // Set the future prediction to max prediction if the speed is too small to give an accurate prediction + if (speed <= distance / targetDistPrediction.Value) { + futurePrediction = targetDistPrediction.Value; + } else { + futurePrediction = (distance / speed) * targetDistPredictionMult.Value; // the prediction should be accurate enough + } + + // Predict the future by taking the velocity of the target and multiply it by the future prediction + var prevTargetPosition = targetPosition; + targetPosition = target.Value.transform.position; + return targetPosition + (targetPosition - prevTargetPosition) * futurePrediction; + } + + // Reset the public variables + public override void OnReset() + { + base.OnReset(); + + targetDistPrediction = 20; + targetDistPredictionMult = 20; + target = null; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer Movement/Scripts/Tasks/Pursue.cs.meta b/Assets/Behavior Designer Movement/Scripts/Tasks/Pursue.cs.meta new file mode 100644 index 0000000..c4a131a --- /dev/null +++ b/Assets/Behavior Designer Movement/Scripts/Tasks/Pursue.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 593ad61823a8b4644b5860eba9b695a9 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer Movement/Scripts/Tasks/Queue.cs b/Assets/Behavior Designer Movement/Scripts/Tasks/Queue.cs new file mode 100644 index 0000000..531416e --- /dev/null +++ b/Assets/Behavior Designer Movement/Scripts/Tasks/Queue.cs @@ -0,0 +1,91 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Movement +{ + [TaskDescription("Queue in a line using the Unity NavMesh.")] + [TaskCategory("Movement")] + [HelpURL("https://www.opsive.com/support/documentation/behavior-designer-movement-pack/")] + [TaskIcon("Assets/Behavior Designer Movement/Editor/Icons/{SkinColor}QueueIcon.png")] + public class Queue : NavMeshGroupMovement + { + [Tooltip("Agents less than this distance apart are neighbors")] + public SharedFloat neighborDistance = 10; + [Tooltip("The distance that the agents should be separated")] + public SharedFloat separationDistance = 2; + [Tooltip("The distance the the agent should look ahead to see if another agent is in the way")] + public SharedFloat maxQueueAheadDistance = 2; + [Tooltip("The radius that the agent should check to see if another agent is in the way")] + public SharedFloat maxQueueRadius = 20; + [Tooltip("The multiplier to slow down if an agent is in front of the current agent")] + public SharedFloat slowDownSpeed = 0.15f; + [Tooltip("The target to seek towards")] + public SharedGameObject target; + + // The agents will always be flocking so always return running + public override TaskStatus OnUpdate() + { + // Determine a destination for each agent + for (int i = 0; i < agents.Length; ++i) { + if (AgentAhead(i)) { + SetDestination(i, transforms[i].position + transforms[i].forward * slowDownSpeed.Value + DetermineSeparation(i)); + } else { + SetDestination(i, target.Value.transform.position); + } + } + return TaskStatus.Running; + } + + // Returns the agent that is ahead of the current agent + private bool AgentAhead(int index) + { + // queueAhead is the distance in front of the current agent + var queueAhead = Velocity(index) * maxQueueAheadDistance.Value; + for (int i = 0; i < agents.Length; ++i) { + // Return the first agent that is ahead of the current agent + if (index != i && Vector3.SqrMagnitude(queueAhead - transforms[i].position) < maxQueueRadius.Value) { + return true; + } + } + return false; + } + + // Determine the separation between the current agent and all of the other agents also queuing + private Vector3 DetermineSeparation(int agentIndex) + { + var separation = Vector3.zero; + int neighborCount = 0; + var agentTransform = transforms[agentIndex]; + // Loop through each agent to determine the separation + for (int i = 0; i < agents.Length; ++i) { + // The agent can't compare against itself + if (agentIndex != i) { + // Only determine the parameters if the other agent is its neighbor + if (Vector3.SqrMagnitude(transforms[i].position - agentTransform.position) < neighborDistance.Value) { + // This agent is the neighbor of the original agent so add the separation + separation += transforms[i].position - agentTransform.position; + neighborCount++; + } + } + } + + // Don't move if there are no neighbors + if (neighborCount == 0) { + return Vector3.zero; + } + // Normalize the value + return ((separation / neighborCount) * -1).normalized * separationDistance.Value; + } + + // Reset the public variables + public override void OnReset() + { + base.OnReset(); + + neighborDistance = 10; + separationDistance = 2; + maxQueueAheadDistance = 2; + maxQueueRadius = 20; + slowDownSpeed = 0.15f; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer Movement/Scripts/Tasks/Queue.cs.meta b/Assets/Behavior Designer Movement/Scripts/Tasks/Queue.cs.meta new file mode 100644 index 0000000..a439e65 --- /dev/null +++ b/Assets/Behavior Designer Movement/Scripts/Tasks/Queue.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 13eacae67d74cfe4fba2cea104f65fbe +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer Movement/Scripts/Tasks/RotateTowards.cs b/Assets/Behavior Designer Movement/Scripts/Tasks/RotateTowards.cs new file mode 100644 index 0000000..d755308 --- /dev/null +++ b/Assets/Behavior Designer Movement/Scripts/Tasks/RotateTowards.cs @@ -0,0 +1,65 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Movement +{ + [TaskDescription("Rotates towards the specified rotation. The rotation can either be specified by a transform or rotation. If the transform "+ + "is used then the rotation will not be used.")] + [TaskCategory("Movement")] + [HelpURL("https://www.opsive.com/support/documentation/behavior-designer-movement-pack/")] + [TaskIcon("Assets/Behavior Designer Movement/Editor/Icons/{SkinColor}RotateTowardsIcon.png")] + public class RotateTowards : Action + { + [Tooltip("Should the 2D version be used?")] + public bool usePhysics2D; + [Tooltip("The agent is done rotating when the angle is less than this value")] + public SharedFloat rotationEpsilon = 0.5f; + [Tooltip("The maximum number of angles the agent can rotate in a single tick")] + public SharedFloat maxLookAtRotationDelta = 1; + [Tooltip("Should the rotation only affect the Y axis?")] + public SharedBool onlyY; + [Tooltip("The GameObject that the agent is rotating towards")] + public SharedGameObject target; + [Tooltip("If target is null then use the target rotation")] + public SharedVector3 targetRotation; + + public override TaskStatus OnUpdate() + { + var rotation = Target(); + // Return a task status of success once we are done rotating + if (Quaternion.Angle(transform.rotation, rotation) < rotationEpsilon.Value) { + return TaskStatus.Success; + } + // We haven't reached the target yet so keep rotating towards it + transform.rotation = Quaternion.RotateTowards(transform.rotation, rotation, maxLookAtRotationDelta.Value); + return TaskStatus.Running; + } + + // Return targetPosition if targetTransform is null + private Quaternion Target() + { + if (target == null || target.Value == null) { + return Quaternion.Euler(targetRotation.Value); + } + var position = target.Value.transform.position - transform.position; + if (onlyY.Value) { + position.y = 0; + } + if (usePhysics2D) { + var angle = Mathf.Atan2(position.y, position.x) * Mathf.Rad2Deg; + return Quaternion.AngleAxis(angle, Vector3.forward); + } + return Quaternion.LookRotation(position); + } + + // Reset the public variables + public override void OnReset() + { + usePhysics2D = false; + rotationEpsilon = 0.5f; + maxLookAtRotationDelta = 1f; + onlyY = false; + target = null; + targetRotation = Vector3.zero; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer Movement/Scripts/Tasks/RotateTowards.cs.meta b/Assets/Behavior Designer Movement/Scripts/Tasks/RotateTowards.cs.meta new file mode 100644 index 0000000..484d99e --- /dev/null +++ b/Assets/Behavior Designer Movement/Scripts/Tasks/RotateTowards.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: ed780f8831d042e48b4a83bcca7a3628 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer Movement/Scripts/Tasks/Search.cs b/Assets/Behavior Designer Movement/Scripts/Tasks/Search.cs new file mode 100644 index 0000000..bb42fae --- /dev/null +++ b/Assets/Behavior Designer Movement/Scripts/Tasks/Search.cs @@ -0,0 +1,138 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Movement +{ + [TaskDescription("Search for a target by combining the wander, within hearing range, and the within seeing range tasks using the Unity NavMesh.")] + [TaskCategory("Movement")] + [HelpURL("https://www.opsive.com/support/documentation/behavior-designer-movement-pack/")] + [TaskIcon("Assets/Behavior Designer Movement/Editor/Icons/{SkinColor}SearchIcon.png")] + public class Search : NavMeshMovement + { + [Tooltip("Minimum distance ahead of the current position to look ahead for a destination")] + public SharedFloat minWanderDistance = 20; + [Tooltip("Maximum distance ahead of the current position to look ahead for a destination")] + public SharedFloat maxWanderDistance = 20; + [Tooltip("The amount that the agent rotates direction")] + public SharedFloat wanderRate = 1; + [Tooltip("The minimum length of time that the agent should pause at each destination")] + public SharedFloat minPauseDuration = 0; + [Tooltip("The maximum length of time that the agent should pause at each destination (zero to disable)")] + public SharedFloat maxPauseDuration = 0; + [Tooltip("The maximum number of retries per tick (set higher if using a slow tick time)")] + public SharedInt targetRetries = 1; + [Tooltip("The field of view angle of the agent (in degrees)")] + public SharedFloat fieldOfViewAngle = 90; + [Tooltip("The distance that the agent can see")] + public SharedFloat viewDistance = 30; + [Tooltip("The LayerMask of the objects to ignore when performing the line of sight check")] + public LayerMask ignoreLayerMask = 1 << LayerMask.NameToLayer("Ignore Raycast"); + [Tooltip("Should the search end if audio was heard?")] + public SharedBool senseAudio = true; + [Tooltip("How far away the unit can hear")] + public SharedFloat hearingRadius = 30; + [Tooltip("The raycast offset relative to the pivot position")] + public SharedVector3 offset; + [Tooltip("The target raycast offset relative to the pivot position")] + public SharedVector3 targetOffset; + [Tooltip("The LayerMask of the objects that we are searching for")] + public LayerMask objectLayerMask; + [Tooltip("Specifies the maximum number of colliders that the physics cast can collide with")] + public int maxCollisionCount = 200; + [Tooltip("Should the target bone be used?")] + public SharedBool useTargetBone; + [Tooltip("The target's bone if the target is a humanoid")] + public HumanBodyBones targetBone; + [Tooltip("Should a debug look ray be drawn to the scene view?")] + public SharedBool drawDebugRay; + [Tooltip("The further away a sound source is the less likely the agent will be able to hear it. " + + "Set a threshold for the the minimum audibility level that the agent can hear")] + public SharedFloat audibilityThreshold = 0.05f; + [Tooltip("The object that is found")] + public SharedGameObject returnedObject; + + private float pauseTime; + private float destinationReachTime; + + private Collider[] overlapColliders; + + // Keep searching until an object is seen or heard (if senseAudio is enabled) + public override TaskStatus OnUpdate() + { + if (HasArrived()) { + // The agent should pause at the destination only if the max pause duration is greater than 0 + if (maxPauseDuration.Value > 0) { + if (destinationReachTime == -1) { + destinationReachTime = Time.time; + pauseTime = Random.Range(minPauseDuration.Value, maxPauseDuration.Value); + } + if (destinationReachTime + pauseTime <= Time.time) { + // Only reset the time if a destination has been set. + if (TrySetTarget()) { + destinationReachTime = -1; + } + } + } else { + TrySetTarget(); + } + } + + // Detect if any objects are within sight + if (overlapColliders == null) { + overlapColliders = new Collider[maxCollisionCount]; + } + returnedObject.Value = MovementUtility.WithinSight(transform, offset.Value, fieldOfViewAngle.Value, viewDistance.Value, overlapColliders, objectLayerMask, targetOffset.Value, ignoreLayerMask, useTargetBone.Value, targetBone, drawDebugRay.Value); + // If an object was seen then return success + if (returnedObject.Value != null) { + return TaskStatus.Success; + } + // Detect if any object are within audio range (if enabled) + if (senseAudio.Value) { + returnedObject.Value = MovementUtility.WithinHearingRange(transform, offset.Value, audibilityThreshold.Value, hearingRadius.Value, overlapColliders, objectLayerMask); + // If an object was heard then return success + if (returnedObject.Value != null) { + return TaskStatus.Success; + } + } + + // No object has been seen or heard so keep searching + return TaskStatus.Running; + } + + private bool TrySetTarget() + { + var direction = transform.forward; + var validDestination = false; + var attempts = targetRetries.Value; + var destination = transform.position; + while (!validDestination && attempts > 0) { + direction = direction + Random.insideUnitSphere * wanderRate.Value; + destination = transform.position + direction.normalized * Random.Range(minWanderDistance.Value, maxWanderDistance.Value); + validDestination = SamplePosition(destination); + attempts--; + } + if (validDestination) { + SetDestination(destination); + } + return validDestination; + } + + // Reset the public variables + public override void OnReset() + { + base.OnReset(); + + minWanderDistance = 20; + maxWanderDistance = 20; + wanderRate = 2; + minPauseDuration = 0; + maxPauseDuration = 0; + targetRetries = 1; + fieldOfViewAngle = 90; + viewDistance = 30; + drawDebugRay = false; + senseAudio = true; + hearingRadius = 30; + audibilityThreshold = 0.05f; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer Movement/Scripts/Tasks/Search.cs.meta b/Assets/Behavior Designer Movement/Scripts/Tasks/Search.cs.meta new file mode 100644 index 0000000..e3164a3 --- /dev/null +++ b/Assets/Behavior Designer Movement/Scripts/Tasks/Search.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 0a9c0162fb2da7a419429f4f058dd12e +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer Movement/Scripts/Tasks/Seek.cs b/Assets/Behavior Designer Movement/Scripts/Tasks/Seek.cs new file mode 100644 index 0000000..f3cee0c --- /dev/null +++ b/Assets/Behavior Designer Movement/Scripts/Tasks/Seek.cs @@ -0,0 +1,52 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Movement +{ + [TaskDescription("Seek the target specified using the Unity NavMesh.")] + [TaskCategory("Movement")] + [HelpURL("https://www.opsive.com/support/documentation/behavior-designer-movement-pack/")] + [TaskIcon("Assets/Behavior Designer Movement/Editor/Icons/{SkinColor}SeekIcon.png")] + public class Seek : NavMeshMovement + { + [Tooltip("The GameObject that the agent is seeking")] + public SharedGameObject target; + [Tooltip("If target is null then use the target position")] + public SharedVector3 targetPosition; + + public override void OnStart() + { + base.OnStart(); + + SetDestination(Target()); + } + + // Seek the destination. Return success once the agent has reached the destination. + // Return running if the agent hasn't reached the destination yet + public override TaskStatus OnUpdate() + { + if (HasArrived()) { + return TaskStatus.Success; + } + + SetDestination(Target()); + + return TaskStatus.Running; + } + + // Return targetPosition if target is null + private Vector3 Target() + { + if (target.Value != null) { + return target.Value.transform.position; + } + return targetPosition.Value; + } + + public override void OnReset() + { + base.OnReset(); + target = null; + targetPosition = Vector3.zero; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer Movement/Scripts/Tasks/Seek.cs.meta b/Assets/Behavior Designer Movement/Scripts/Tasks/Seek.cs.meta new file mode 100644 index 0000000..05bb56d --- /dev/null +++ b/Assets/Behavior Designer Movement/Scripts/Tasks/Seek.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: d2a1c0efa4c24da42af5e47e0f82ab5c +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer Movement/Scripts/Tasks/Wander.cs b/Assets/Behavior Designer Movement/Scripts/Tasks/Wander.cs new file mode 100644 index 0000000..8a368a3 --- /dev/null +++ b/Assets/Behavior Designer Movement/Scripts/Tasks/Wander.cs @@ -0,0 +1,79 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Movement +{ + [TaskDescription("Wander using the Unity NavMesh.")] + [TaskCategory("Movement")] + [HelpURL("https://www.opsive.com/support/documentation/behavior-designer-movement-pack/")] + [TaskIcon("Assets/Behavior Designer Movement/Editor/Icons/{SkinColor}WanderIcon.png")] + public class Wander : NavMeshMovement + { + [Tooltip("Minimum distance ahead of the current position to look ahead for a destination")] + public SharedFloat minWanderDistance = 20; + [Tooltip("Maximum distance ahead of the current position to look ahead for a destination")] + public SharedFloat maxWanderDistance = 20; + [Tooltip("The amount that the agent rotates direction")] + public SharedFloat wanderRate = 2; + [Tooltip("The minimum length of time that the agent should pause at each destination")] + public SharedFloat minPauseDuration = 0; + [Tooltip("The maximum length of time that the agent should pause at each destination (zero to disable)")] + public SharedFloat maxPauseDuration = 0; + [Tooltip("The maximum number of retries per tick (set higher if using a slow tick time)")] + public SharedInt targetRetries = 1; + + private float pauseTime; + private float destinationReachTime; + + // There is no success or fail state with wander - the agent will just keep wandering + public override TaskStatus OnUpdate() + { + if (HasArrived()) { + // The agent should pause at the destination only if the max pause duration is greater than 0 + if (maxPauseDuration.Value > 0) { + if (destinationReachTime == -1) { + destinationReachTime = Time.time; + pauseTime = Random.Range(minPauseDuration.Value, maxPauseDuration.Value); + } + if (destinationReachTime + pauseTime <= Time.time) { + // Only reset the time if a destination has been set. + if (TrySetTarget()) { + destinationReachTime = -1; + } + } + } else { + TrySetTarget(); + } + } + return TaskStatus.Running; + } + + private bool TrySetTarget() + { + var direction = transform.forward; + var validDestination = false; + var attempts = targetRetries.Value; + var destination = transform.position; + while (!validDestination && attempts > 0) { + direction = direction + Random.insideUnitSphere * wanderRate.Value; + destination = transform.position + direction.normalized * Random.Range(minWanderDistance.Value, maxWanderDistance.Value); + validDestination = SamplePosition(destination); + attempts--; + } + if (validDestination) { + SetDestination(destination); + } + return validDestination; + } + + // Reset the public variables + public override void OnReset() + { + minWanderDistance = 20; + maxWanderDistance = 20; + wanderRate = 2; + minPauseDuration = 0; + maxPauseDuration = 0; + targetRetries = 1; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer Movement/Scripts/Tasks/Wander.cs.meta b/Assets/Behavior Designer Movement/Scripts/Tasks/Wander.cs.meta new file mode 100644 index 0000000..ddd2186 --- /dev/null +++ b/Assets/Behavior Designer Movement/Scripts/Tasks/Wander.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: c16acf9e9d926314489b4fe6473fe118 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer Movement/Scripts/Tasks/WithinDistance.cs b/Assets/Behavior Designer Movement/Scripts/Tasks/WithinDistance.cs new file mode 100644 index 0000000..0f52d8b --- /dev/null +++ b/Assets/Behavior Designer Movement/Scripts/Tasks/WithinDistance.cs @@ -0,0 +1,141 @@ +using UnityEngine; +using System.Collections.Generic; + +namespace BehaviorDesigner.Runtime.Tasks.Movement +{ + [TaskDescription("Check to see if the any object specified by the object list or tag is within the distance specified of the current agent.")] + [TaskCategory("Movement")] + [HelpURL("https://www.opsive.com/support/documentation/behavior-designer-movement-pack/")] + [TaskIcon("Assets/Behavior Designer Movement/Editor/Icons/{SkinColor}WithinDistanceIcon.png")] + public class WithinDistance : Conditional + { + [Tooltip("Should the 2D version be used?")] + public bool usePhysics2D; + [Tooltip("The object that we are searching for")] + public SharedGameObject targetObject; + [Tooltip("The tag of the object that we are searching for")] + public SharedString targetTag; + [Tooltip("The LayerMask of the objects that we are searching for")] + public LayerMask objectLayerMask; + [Tooltip("The distance that the object needs to be within")] + public SharedFloat magnitude = 5; + [Tooltip("If true, the object must be within line of sight to be within distance. For example, if this option is enabled then an object behind a wall will not be within distance even though it may " + + "be physically close to the other object")] + public SharedBool lineOfSight; + [Tooltip("The LayerMask of the objects to ignore when performing the line of sight check")] + public LayerMask ignoreLayerMask = 1 << LayerMask.NameToLayer("Ignore Raycast"); + [Tooltip("The raycast offset relative to the pivot position")] + public SharedVector3 offset; + [Tooltip("The target raycast offset relative to the pivot position")] + public SharedVector3 targetOffset; + [Tooltip("Should a debug look ray be drawn to the scene view?")] + public SharedBool drawDebugRay; + [Tooltip("The object variable that will be set when a object is found what the object is")] + public SharedGameObject returnedObject; + + private List objects; + // distance * distance, optimization so we don't have to take the square root + private float sqrMagnitude; + private bool overlapCast = false; + + public override void OnStart() + { + sqrMagnitude = magnitude.Value * magnitude.Value; + + if (objects != null) { + objects.Clear(); + } else { + objects = new List(); + } + // if objects is null then find all of the objects using the layer mask or tag + if (targetObject.Value == null) { + if (!string.IsNullOrEmpty(targetTag.Value)) { + var gameObjects = GameObject.FindGameObjectsWithTag(targetTag.Value); + for (int i = 0; i < gameObjects.Length; ++i) { + objects.Add(gameObjects[i]); + } + } else { + overlapCast = true; + } + } else { + objects.Add(targetObject.Value); + } + } + + // returns success if any object is within distance of the current object. Otherwise it will return failure + public override TaskStatus OnUpdate() + { + if (transform == null || objects == null) + return TaskStatus.Failure; + + if (overlapCast) { + objects.Clear(); + if (usePhysics2D) { + var colliders = Physics2D.OverlapCircleAll(transform.position, magnitude.Value, objectLayerMask.value); + for (int i = 0; i < colliders.Length; ++i) { + objects.Add(colliders[i].gameObject); + } + } else { + var colliders = Physics.OverlapSphere(transform.position, magnitude.Value, objectLayerMask.value); + for (int i = 0; i < colliders.Length; ++i) { + objects.Add(colliders[i].gameObject); + } + } + } + + Vector3 direction; + // check each object. All it takes is one object to be able to return success + for (int i = 0; i < objects.Count; ++i) { + if (objects[i] == null) { + continue; + } + direction = objects[i].transform.position - (transform.position + offset.Value); + // check to see if the square magnitude is less than what is specified + if (Vector3.SqrMagnitude(direction) < sqrMagnitude) { + // the magnitude is less. If lineOfSight is true do one more check + if (lineOfSight.Value) { + var hitTransform = MovementUtility.LineOfSight(transform, offset.Value, objects[i], targetOffset.Value, usePhysics2D, ignoreLayerMask.value, drawDebugRay.Value); + if (hitTransform != null) { + // the object has a magnitude less than the specified magnitude and is within sight. Set the object and return success + returnedObject.Value = objects[i]; + return TaskStatus.Success; + } + } else { + // the object has a magnitude less than the specified magnitude. Set the object and return success + returnedObject.Value = objects[i]; + return TaskStatus.Success; + } + } + } + // no objects are within distance. Return failure + return TaskStatus.Failure; + } + + public override void OnReset() + { + usePhysics2D = false; + targetObject = null; + targetTag = string.Empty; + objectLayerMask = 0; + magnitude = 5; + lineOfSight = true; + ignoreLayerMask = 1 << LayerMask.NameToLayer("Ignore Raycast"); + offset = Vector3.zero; + targetOffset = Vector3.zero; + } + + // Draw the seeing radius + public override void OnDrawGizmos() + { +#if UNITY_EDITOR + if (Owner == null || magnitude == null) { + return; + } + var oldColor = UnityEditor.Handles.color; + UnityEditor.Handles.color = Color.yellow; + UnityEditor.Handles.DrawWireDisc(Owner.transform.position, usePhysics2D ? Owner.transform.forward : Owner.transform.up, magnitude.Value); + UnityEditor.Handles.color = oldColor; +#endif + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer Movement/Scripts/Tasks/WithinDistance.cs.meta b/Assets/Behavior Designer Movement/Scripts/Tasks/WithinDistance.cs.meta new file mode 100644 index 0000000..4a7db79 --- /dev/null +++ b/Assets/Behavior Designer Movement/Scripts/Tasks/WithinDistance.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: dd30510382d334c408a4e2016c9d804a +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer Movement/Textures.meta b/Assets/Behavior Designer Movement/Textures.meta new file mode 100644 index 0000000..c3af997 --- /dev/null +++ b/Assets/Behavior Designer Movement/Textures.meta @@ -0,0 +1,4 @@ +fileFormatVersion: 2 +guid: 6c5de28c3c73f7a46812b5862660bc3f +DefaultImporter: + userData: diff --git a/Assets/Behavior Designer Movement/Textures/PrototypeBlackAlbedo.png b/Assets/Behavior Designer Movement/Textures/PrototypeBlackAlbedo.png new file mode 100644 index 0000000..2d893a0 Binary files /dev/null and b/Assets/Behavior Designer Movement/Textures/PrototypeBlackAlbedo.png differ diff --git a/Assets/Behavior Designer Movement/Textures/PrototypeBlackAlbedo.png.meta b/Assets/Behavior Designer Movement/Textures/PrototypeBlackAlbedo.png.meta new file mode 100644 index 0000000..61e3edc --- /dev/null +++ b/Assets/Behavior Designer Movement/Textures/PrototypeBlackAlbedo.png.meta @@ -0,0 +1,67 @@ +fileFormatVersion: 2 +guid: 91aab39565a849342b4733613a339270 +TextureImporter: + fileIDToRecycleName: {} + serializedVersion: 2 + mipmaps: + mipMapMode: 0 + enableMipMap: 1 + linearTexture: 0 + correctGamma: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: .25 + normalMapFilter: 0 + isReadable: 0 + grayScaleToAlpha: 0 + generateCubemap: 0 + seamlessCubemap: 0 + textureFormat: -1 + maxTextureSize: 1024 + textureSettings: + filterMode: 2 + aniso: 8 + mipBias: -1 + wrapMode: 0 + nPOTScale: 1 + lightmap: 0 + compressionQuality: 50 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: .5, y: .5} + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spritePixelsToUnits: 100 + alphaIsTransparency: 0 + textureType: 0 + buildTargetSettings: + - buildTarget: iPhone + maxTextureSize: 512 + textureFormat: -1 + compressionQuality: 50 + - buildTarget: Android + maxTextureSize: 512 + textureFormat: -1 + compressionQuality: 50 + - buildTarget: BlackBerry + maxTextureSize: 512 + textureFormat: -1 + compressionQuality: 50 + - buildTarget: FlashPlayer + maxTextureSize: 512 + textureFormat: -1 + compressionQuality: 50 + - buildTarget: WP8 + maxTextureSize: 512 + textureFormat: -1 + compressionQuality: 50 + spriteSheet: + sprites: [] + spritePackingTag: + userData: diff --git a/Assets/Behavior Designer Movement/Textures/prototype_blue_dff.png b/Assets/Behavior Designer Movement/Textures/prototype_blue_dff.png new file mode 100644 index 0000000..4929d6e Binary files /dev/null and b/Assets/Behavior Designer Movement/Textures/prototype_blue_dff.png differ diff --git a/Assets/Behavior Designer Movement/Textures/prototype_blue_dff.png.meta b/Assets/Behavior Designer Movement/Textures/prototype_blue_dff.png.meta new file mode 100644 index 0000000..efcf85f --- /dev/null +++ b/Assets/Behavior Designer Movement/Textures/prototype_blue_dff.png.meta @@ -0,0 +1,47 @@ +fileFormatVersion: 2 +guid: 0c16e655ee9ccbd4ba9d5359b56a9a5c +TextureImporter: + fileIDToRecycleName: {} + serializedVersion: 2 + mipmaps: + mipMapMode: 0 + enableMipMap: 1 + linearTexture: 0 + correctGamma: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: .25 + normalMapFilter: 0 + isReadable: 0 + grayScaleToAlpha: 0 + generateCubemap: 0 + seamlessCubemap: 0 + textureFormat: -1 + maxTextureSize: 1024 + textureSettings: + filterMode: -1 + aniso: -1 + mipBias: -1 + wrapMode: -1 + nPOTScale: 1 + lightmap: 0 + compressionQuality: 50 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: .5, y: .5} + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spritePixelsToUnits: 100 + alphaIsTransparency: 0 + textureType: -1 + buildTargetSettings: [] + spriteSheet: + sprites: [] + spritePackingTag: + userData: diff --git a/Assets/Behavior Designer Movement/enemy_Spider_AlertSound.wav b/Assets/Behavior Designer Movement/enemy_Spider_AlertSound.wav new file mode 100644 index 0000000..1861157 Binary files /dev/null and b/Assets/Behavior Designer Movement/enemy_Spider_AlertSound.wav differ diff --git a/Assets/Behavior Designer Movement/enemy_Spider_AlertSound.wav.meta b/Assets/Behavior Designer Movement/enemy_Spider_AlertSound.wav.meta new file mode 100644 index 0000000..78af883 --- /dev/null +++ b/Assets/Behavior Designer Movement/enemy_Spider_AlertSound.wav.meta @@ -0,0 +1,12 @@ +fileFormatVersion: 2 +guid: 68a02d834e9e6e34fa3fa2a492571682 +AudioImporter: + serializedVersion: 4 + format: -1 + quality: .5 + stream: 1 + 3D: 0 + forceToMono: 0 + useHardware: 0 + loopable: 0 + userData: diff --git a/Assets/Behavior Designer.meta b/Assets/Behavior Designer.meta new file mode 100644 index 0000000..850cf77 --- /dev/null +++ b/Assets/Behavior Designer.meta @@ -0,0 +1,4 @@ +fileFormatVersion: 2 +guid: 7b303277dfa449d4a93437535228816d +DefaultImporter: + userData: diff --git a/Assets/Behavior Designer/Documentation.pdf b/Assets/Behavior Designer/Documentation.pdf new file mode 100644 index 0000000..de5ce33 Binary files /dev/null and b/Assets/Behavior Designer/Documentation.pdf differ diff --git a/Assets/Behavior Designer/Documentation.pdf.meta b/Assets/Behavior Designer/Documentation.pdf.meta new file mode 100644 index 0000000..aa4bb29 --- /dev/null +++ b/Assets/Behavior Designer/Documentation.pdf.meta @@ -0,0 +1,4 @@ +fileFormatVersion: 2 +guid: 4646946da2762db46a08e76a6c42f832 +DefaultImporter: + userData: diff --git a/Assets/Behavior Designer/Editor.meta b/Assets/Behavior Designer/Editor.meta new file mode 100644 index 0000000..8584cfc --- /dev/null +++ b/Assets/Behavior Designer/Editor.meta @@ -0,0 +1,2 @@ +fileFormatVersion: 2 +guid: 3aa7d582439bc2f4da8254d1364e0f41 diff --git a/Assets/Behavior Designer/Editor/BehaviorDesigner.Editor.dll b/Assets/Behavior Designer/Editor/BehaviorDesigner.Editor.dll new file mode 100644 index 0000000..b35183b Binary files /dev/null and b/Assets/Behavior Designer/Editor/BehaviorDesigner.Editor.dll differ diff --git a/Assets/Behavior Designer/Editor/BehaviorDesigner.Editor.dll.meta b/Assets/Behavior Designer/Editor/BehaviorDesigner.Editor.dll.meta new file mode 100644 index 0000000..b271bc3 --- /dev/null +++ b/Assets/Behavior Designer/Editor/BehaviorDesigner.Editor.dll.meta @@ -0,0 +1,32 @@ +fileFormatVersion: 2 +guid: af72b091e5876924c9ab327b2d8de270 +timeCreated: 1581513558 +licenseType: Store +PluginImporter: + externalObjects: {} + serializedVersion: 2 + iconMap: {} + executionOrder: {} + isPreloaded: 0 + isOverridable: 0 + platformData: + - first: + Any: + second: + enabled: 0 + settings: {} + - first: + Editor: Editor + second: + enabled: 1 + settings: + DefaultValueInitialized: true + - first: + Windows Store Apps: WindowsStoreApps + second: + enabled: 0 + settings: + CPU: AnyCPU + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Behavior Designer/Editor/BehaviorTreeInspector.cs b/Assets/Behavior Designer/Editor/BehaviorTreeInspector.cs new file mode 100644 index 0000000..aa1021d --- /dev/null +++ b/Assets/Behavior Designer/Editor/BehaviorTreeInspector.cs @@ -0,0 +1,11 @@ +using UnityEditor; +using BehaviorDesigner.Runtime; + +namespace BehaviorDesigner.Editor +{ + [CustomEditor(typeof(BehaviorTree))] + public class BehaviorTreeInspector : BehaviorInspector + { + // intentionally left blank + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Editor/BehaviorTreeInspector.cs.meta b/Assets/Behavior Designer/Editor/BehaviorTreeInspector.cs.meta new file mode 100644 index 0000000..e013536 --- /dev/null +++ b/Assets/Behavior Designer/Editor/BehaviorTreeInspector.cs.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: 94693c6931cea70439c26417a1fc0d33 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} diff --git a/Assets/Behavior Designer/Editor/ExternalBehaviorTreeInspector.cs b/Assets/Behavior Designer/Editor/ExternalBehaviorTreeInspector.cs new file mode 100644 index 0000000..24da0b8 --- /dev/null +++ b/Assets/Behavior Designer/Editor/ExternalBehaviorTreeInspector.cs @@ -0,0 +1,12 @@ +using UnityEngine; +using UnityEditor; +using BehaviorDesigner.Runtime; + +namespace BehaviorDesigner.Editor +{ + [CustomEditor(typeof(ExternalBehaviorTree))] + public class ExternalBehaviorTreeInspector : ExternalBehaviorInspector + { + // intentionally left blank + } +} diff --git a/Assets/Behavior Designer/Editor/ExternalBehaviorTreeInspector.cs.meta b/Assets/Behavior Designer/Editor/ExternalBehaviorTreeInspector.cs.meta new file mode 100644 index 0000000..b36a252 --- /dev/null +++ b/Assets/Behavior Designer/Editor/ExternalBehaviorTreeInspector.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 1f0cb79f53e760c4d950b8c6ade6a242 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Editor/GridShader.shader b/Assets/Behavior Designer/Editor/GridShader.shader new file mode 100644 index 0000000..8fe5b74 --- /dev/null +++ b/Assets/Behavior Designer/Editor/GridShader.shader @@ -0,0 +1,44 @@ +Shader "Hidden/Behavior Designer/Grid" { + SubShader { + Pass { + CGPROGRAM + #pragma vertex vert_img + #pragma fragment frag + #include "UnityCG.cginc" + fixed4 frag(v2f_img i) : Color { + return fixed4(0.21, 0.21, 0.21, 1); + } + ENDCG + } + Pass { + CGPROGRAM + #pragma vertex vert_img + #pragma fragment frag + #include "UnityCG.cginc" + fixed4 frag(v2f_img i) : Color { + return fixed4(0.33, 0.33, 0.33, 1); + } + ENDCG + } + Pass { + CGPROGRAM + #pragma vertex vert_img + #pragma fragment frag + #include "UnityCG.cginc" + fixed4 frag(v2f_img i) : Color { + return fixed4(0.26, 0.26, 0.26, 1); + } + ENDCG + } + Pass { + CGPROGRAM + #pragma vertex vert_img + #pragma fragment frag + #include "UnityCG.cginc" + fixed4 frag(v2f_img i) : Color { + return fixed4(0.27, 0.27, 0.27, 1); + } + ENDCG + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Editor/GridShader.shader.meta b/Assets/Behavior Designer/Editor/GridShader.shader.meta new file mode 100644 index 0000000..075e373 --- /dev/null +++ b/Assets/Behavior Designer/Editor/GridShader.shader.meta @@ -0,0 +1,5 @@ +fileFormatVersion: 2 +guid: afbd9f0fb1c22d1409403fdef158479f +ShaderImporter: + defaultTextures: [] + userData: diff --git a/Assets/Behavior Designer/Editor/Object Drawers.meta b/Assets/Behavior Designer/Editor/Object Drawers.meta new file mode 100644 index 0000000..a7ead9d --- /dev/null +++ b/Assets/Behavior Designer/Editor/Object Drawers.meta @@ -0,0 +1,5 @@ +fileFormatVersion: 2 +guid: 956347559c803f7489f75873ef2715e5 +folderAsset: yes +DefaultImporter: + userData: diff --git a/Assets/Behavior Designer/Editor/Object Drawers/FloatSliderDrawer.cs b/Assets/Behavior Designer/Editor/Object Drawers/FloatSliderDrawer.cs new file mode 100644 index 0000000..b3cad0e --- /dev/null +++ b/Assets/Behavior Designer/Editor/Object Drawers/FloatSliderDrawer.cs @@ -0,0 +1,22 @@ +using UnityEngine; +using UnityEditor; +using BehaviorDesigner.Runtime; +using BehaviorDesigner.Runtime.ObjectDrawers; + +namespace BehaviorDesigner.Editor.ObjectDrawers +{ + [CustomObjectDrawer(typeof(FloatSliderAttribute))] + public class FloatSliderDrawer : ObjectDrawer + { + public override void OnGUI(GUIContent label) + { + var floatSliderAttribute = (FloatSliderAttribute)attribute; + if (value is SharedFloat) { + var sharedFloat = value as SharedFloat; + sharedFloat.Value = EditorGUILayout.Slider(label, sharedFloat.Value, floatSliderAttribute.min, floatSliderAttribute.max); + } else { + value = EditorGUILayout.Slider(label, (float)value, floatSliderAttribute.min, floatSliderAttribute.max); + } + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Editor/Object Drawers/FloatSliderDrawer.cs.meta b/Assets/Behavior Designer/Editor/Object Drawers/FloatSliderDrawer.cs.meta new file mode 100644 index 0000000..26a3686 --- /dev/null +++ b/Assets/Behavior Designer/Editor/Object Drawers/FloatSliderDrawer.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 5f0987c6ff37141458ff776277e2b65a +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Editor/Object Drawers/IntSliderDrawer.cs b/Assets/Behavior Designer/Editor/Object Drawers/IntSliderDrawer.cs new file mode 100644 index 0000000..d6107b8 --- /dev/null +++ b/Assets/Behavior Designer/Editor/Object Drawers/IntSliderDrawer.cs @@ -0,0 +1,22 @@ +using UnityEngine; +using UnityEditor; +using BehaviorDesigner.Runtime; +using BehaviorDesigner.Runtime.ObjectDrawers; + +namespace BehaviorDesigner.Editor.ObjectDrawers +{ + [CustomObjectDrawer(typeof(IntSliderAttribute))] + public class IntSliderDrawer : ObjectDrawer + { + public override void OnGUI(GUIContent label) + { + var intSliderAttribute = (IntSliderAttribute)attribute; + if (value is SharedInt) { + var sharedFloat = value as SharedInt; + sharedFloat.Value = EditorGUILayout.IntSlider(label, sharedFloat.Value, intSliderAttribute.min, intSliderAttribute.max); + } else { + value = EditorGUILayout.IntSlider(label, (int)value, intSliderAttribute.min, intSliderAttribute.max); + } + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Editor/Object Drawers/IntSliderDrawer.cs.meta b/Assets/Behavior Designer/Editor/Object Drawers/IntSliderDrawer.cs.meta new file mode 100644 index 0000000..402e1f3 --- /dev/null +++ b/Assets/Behavior Designer/Editor/Object Drawers/IntSliderDrawer.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: ed5dac524fa5f61468bb6ca49a556b3b +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Editor/Object Drawers/StackedActionDrawer.cs b/Assets/Behavior Designer/Editor/Object Drawers/StackedActionDrawer.cs new file mode 100644 index 0000000..55a5dc3 --- /dev/null +++ b/Assets/Behavior Designer/Editor/Object Drawers/StackedActionDrawer.cs @@ -0,0 +1,146 @@ +using UnityEngine; +using UnityEditor; +using UnityEditorInternal; +using BehaviorDesigner.Runtime.Tasks; +using System; +using System.Reflection; + +using Action = BehaviorDesigner.Runtime.Tasks.Action; + +namespace BehaviorDesigner.Editor.ObjectDrawers +{ + [CustomObjectDrawer(typeof(StackedAction))] + public class StackedActionDrawer : ObjectDrawer + { + private ReorderableList reorderableList; + private StackedAction lastStackedAction; + + public override void OnGUI(GUIContent label) + { + var stackedAction = task as StackedAction; + + stackedAction.comparisonType = (StackedAction.ComparisonType)FieldInspector.DrawField(stackedAction, + new GUIContent("Comparison Type", "Specifies if the tasks should be traversed with an AND (Sequence) or an OR (Selector)."), + stackedAction.GetType().GetField("comparisonType", BindingFlags.Instance | BindingFlags.Public), + stackedAction.comparisonType); + + stackedAction.graphLabel = (bool)FieldInspector.DrawField(stackedAction, + new GUIContent("Graph Label", "Should the tasks be labeled within te graph?"), + stackedAction.GetType().GetField("graphLabel", BindingFlags.Instance | BindingFlags.Public), + stackedAction.graphLabel); + + if (stackedAction.actions == null) { + stackedAction.actions = new Action[0]; + } + + if (reorderableList == null) { + reorderableList = new ReorderableList(stackedAction.actions, typeof(Action), true, true, true, true); + reorderableList.drawHeaderCallback += (Rect rect) => + { + EditorGUI.LabelField(rect, "Actions"); + }; + reorderableList.onAddDropdownCallback += OnAddDropdownCallback; + reorderableList.drawElementCallback += OnDrawElementCallback; + reorderableList.onReorderCallback += OnReorderCallback; + reorderableList.onSelectCallback += OnSelectCallback; + reorderableList.onCanRemoveCallback += OnCanRemoveCallback; + reorderableList.onRemoveCallback += OnRemoveCallback; + } + if (stackedAction != lastStackedAction) { + lastStackedAction = stackedAction; + var index = EditorPrefs.GetInt("BehaviorDesigner.StackedAction." + stackedAction.ID, -1); + if (index < stackedAction.actions.Length) { + reorderableList.index = index; + } + } + if (reorderableList.index == -1 && stackedAction.actions.Length > 0) { + reorderableList.index = 0; + } + reorderableList.DoLayoutList(); + + if (reorderableList.index >= 0 && stackedAction.actions != null && reorderableList.index < stackedAction.actions.Length) { + var selectedAction = stackedAction.actions[reorderableList.index]; + EditorGUILayout.LabelField(selectedAction.GetType().Name, BehaviorDesignerUtility.BoldLabelGUIStyle); + FieldInspector.DrawFields(selectedAction, selectedAction); + } + } + + private void OnAddDropdownCallback(Rect buttonRect, ReorderableList list) + { + var addMenu = new GenericMenu(); + BehaviorDesignerWindow.instance.TaskList.AddTaskTypesToMenu(0, ref addMenu, null, typeof(StackedAction), string.Empty, false, OnAddTask); + addMenu.ShowAsContext(); + } + + private void OnAddTask(object obj) + { + var stackedAction = task as StackedAction; + var actions = stackedAction.actions; + Array.Resize(ref actions, actions.Length + 1); + var taskType = obj as Type; + actions[actions.Length - 1] = Activator.CreateInstance(taskType) as Action; + reorderableList.list = stackedAction.actions = actions; + reorderableList.index = actions.Length - 1; + BehaviorDesignerWindow.instance.SaveBehavior(); + } + + private void OnDrawElementCallback(Rect rect, int index, bool isActive, bool isFocused) + { + var stackedAction = task as StackedAction; + if (stackedAction.actions == null || index >= stackedAction.actions.Length || stackedAction.actions[index] == null) { + if (stackedAction.actions != null && index < stackedAction.actions.Length) { + var actions = stackedAction.actions; + ArrayUtility.RemoveAt(ref actions, index); + reorderableList.list = stackedAction.actions = actions; + BehaviorDesignerWindow.instance.SaveBehavior(); + } + return; + } + EditorGUI.LabelField(rect, stackedAction.actions[index].GetType().Name); + if (stackedAction.actions[index].NodeData == null || !Application.isPlaying) { + return; + } + + if (stackedAction.actions[index].NodeData.ExecutionStatus == TaskStatus.Success || stackedAction.actions[index].NodeData.ExecutionStatus == TaskStatus.Failure) { + Texture2D texture; + if (stackedAction.NodeData.IsReevaluating) { + texture = stackedAction.actions[index].NodeData.ExecutionStatus == TaskStatus.Failure ? BehaviorDesignerUtility.ExecutionFailureRepeatTexture : BehaviorDesignerUtility.ExecutionSuccessRepeatTexture; + } else { + texture = stackedAction.actions[index].NodeData.ExecutionStatus == TaskStatus.Failure ? BehaviorDesignerUtility.ExecutionFailureTexture : BehaviorDesignerUtility.ExecutionSuccessTexture; + } + rect.x = rect.width + 8; + rect.width = rect.height = 16; + GUI.DrawTexture(rect, texture); + } + } + + private void OnReorderCallback(ReorderableList list) + { + var stackedActions = task as StackedAction; + stackedActions.actions = (Action[])list.list; + BehaviorDesignerWindow.instance.SaveBehavior(); + } + + private void OnSelectCallback(ReorderableList list) + { + EditorPrefs.SetInt("BehaviorDesigner.StackedAction." + task.ID, list.index); + } + + private bool OnCanRemoveCallback(ReorderableList list) + { + var stackedActions = task as StackedAction; + return stackedActions.actions != null && stackedActions.actions.Length > 0; + } + + private void OnRemoveCallback(ReorderableList list) + { + var stackedAction = task as StackedAction; + var actions = stackedAction.actions; + ArrayUtility.RemoveAt(ref actions, list.index); + reorderableList.list = stackedAction.actions = actions; + BehaviorDesignerWindow.instance.SaveBehavior(); + + reorderableList.index -= 1; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Editor/Object Drawers/StackedActionDrawer.cs.meta b/Assets/Behavior Designer/Editor/Object Drawers/StackedActionDrawer.cs.meta new file mode 100644 index 0000000..aacbeb6 --- /dev/null +++ b/Assets/Behavior Designer/Editor/Object Drawers/StackedActionDrawer.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 2dda1c5bd0726be428a9210c793769d7 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Behavior Designer/Editor/Object Drawers/StackedConditionalDrawer.cs b/Assets/Behavior Designer/Editor/Object Drawers/StackedConditionalDrawer.cs new file mode 100644 index 0000000..4cb79b7 --- /dev/null +++ b/Assets/Behavior Designer/Editor/Object Drawers/StackedConditionalDrawer.cs @@ -0,0 +1,144 @@ +using UnityEngine; +using UnityEditor; +using UnityEditorInternal; +using BehaviorDesigner.Runtime.Tasks; +using System; +using System.Reflection; + +namespace BehaviorDesigner.Editor.ObjectDrawers +{ + [CustomObjectDrawer(typeof(StackedConditional))] + public class StackedConditionalDrawer : ObjectDrawer + { + private ReorderableList reorderableList; + private StackedConditional lastStackedConditional; + + public override void OnGUI(GUIContent label) + { + var stackedConditional = task as StackedConditional; + + stackedConditional.comparisonType = (StackedConditional.ComparisonType)FieldInspector.DrawField(stackedConditional, + new GUIContent("Comparison Type", "Specifies if the tasks should be traversed with an AND (Sequence) or an OR (Selector)."), + stackedConditional.GetType().GetField("comparisonType", BindingFlags.Instance | BindingFlags.Public), + stackedConditional.comparisonType); + + stackedConditional.graphLabel = (bool)FieldInspector.DrawField(stackedConditional, + new GUIContent("Graph Label", "Should the tasks be labeled within te graph?"), + stackedConditional.GetType().GetField("graphLabel", BindingFlags.Instance | BindingFlags.Public), + stackedConditional.graphLabel); + + if (stackedConditional.conditionals == null) { + stackedConditional.conditionals = new Conditional[0]; + } + + if (reorderableList == null) { + reorderableList = new ReorderableList(stackedConditional.conditionals, typeof(Conditional), true, true, true, true); + reorderableList.drawHeaderCallback += (Rect rect) => + { + EditorGUI.LabelField(rect, "Conditionals"); + }; + reorderableList.onAddDropdownCallback += OnAddDropdownCallback; + reorderableList.drawElementCallback += OnDrawElementCallback; + reorderableList.onReorderCallback += OnReorderCallback; + reorderableList.onSelectCallback += OnSelectCallback; + reorderableList.onCanRemoveCallback += OnCanRemoveCallback; + reorderableList.onRemoveCallback += OnRemoveCallback; + } + if (stackedConditional != lastStackedConditional) { + lastStackedConditional = stackedConditional; + var index = EditorPrefs.GetInt("BehaviorDesigner.StackedConditional." + stackedConditional.ID, -1); + if (index < stackedConditional.conditionals.Length) { + reorderableList.index = index; + } + } + if (reorderableList.index == -1 && stackedConditional.conditionals.Length > 0) { + reorderableList.index = 0; + } + reorderableList.DoLayoutList(); + + if (reorderableList.index >= 0 && stackedConditional.conditionals != null && reorderableList.index < stackedConditional.conditionals.Length) { + var selectedConditional = stackedConditional.conditionals[reorderableList.index]; + EditorGUILayout.LabelField(selectedConditional.GetType().Name, BehaviorDesignerUtility.BoldLabelGUIStyle); + FieldInspector.DrawFields(selectedConditional, selectedConditional); + } + } + + private void OnAddDropdownCallback(Rect buttonRect, ReorderableList list) + { + var addMenu = new GenericMenu(); + BehaviorDesignerWindow.instance.TaskList.AddTaskTypesToMenu(2, ref addMenu, null, typeof(StackedConditional), string.Empty, false, OnAddTask); + addMenu.ShowAsContext(); + } + + private void OnAddTask(object obj) + { + var stackedConditional = task as StackedConditional; + var conditionals = stackedConditional.conditionals; + Array.Resize(ref conditionals, conditionals.Length + 1); + var taskType = obj as Type; + conditionals[conditionals.Length - 1] = Activator.CreateInstance(taskType) as Conditional; + reorderableList.list = stackedConditional.conditionals = conditionals; + reorderableList.index = conditionals.Length - 1; + BehaviorDesignerWindow.instance.SaveBehavior(); + } + + private void OnDrawElementCallback(Rect rect, int index, bool isActive, bool isFocused) + { + var stackedConditional = task as StackedConditional; + if (stackedConditional.conditionals == null || index >= stackedConditional.conditionals.Length || stackedConditional.conditionals[index] == null) { + if (stackedConditional.conditionals != null && index < stackedConditional.conditionals.Length) { + var conditionals = stackedConditional.conditionals; + ArrayUtility.RemoveAt(ref conditionals, index); + reorderableList.list = stackedConditional.conditionals = conditionals; + BehaviorDesignerWindow.instance.SaveBehavior(); + } + return; + } + EditorGUI.LabelField(rect, stackedConditional.conditionals[index].GetType().Name); + if (stackedConditional.conditionals[index].NodeData == null || !Application.isPlaying) { + return; + } + + if (stackedConditional.conditionals[index].NodeData.ExecutionStatus == TaskStatus.Success || stackedConditional.conditionals[index].NodeData.ExecutionStatus == TaskStatus.Failure) { + Texture2D texture; + if (stackedConditional.NodeData.IsReevaluating) { + texture = stackedConditional.conditionals[index].NodeData.ExecutionStatus == TaskStatus.Failure ? BehaviorDesignerUtility.ExecutionFailureRepeatTexture : BehaviorDesignerUtility.ExecutionSuccessRepeatTexture; + } else { + texture = stackedConditional.conditionals[index].NodeData.ExecutionStatus == TaskStatus.Failure ? BehaviorDesignerUtility.ExecutionFailureTexture : BehaviorDesignerUtility.ExecutionSuccessTexture; + } + rect.x = rect.width + 8; + rect.width = rect.height = 16; + GUI.DrawTexture(rect, texture); + } + } + + private void OnReorderCallback(ReorderableList list) + { + var stackedConditionals = task as StackedConditional; + stackedConditionals.conditionals = (Conditional[])list.list; + BehaviorDesignerWindow.instance.SaveBehavior(); + } + + private void OnSelectCallback(ReorderableList list) + { + EditorPrefs.SetInt("BehaviorDesigner.StackedConditional." + task.ID, list.index); + } + + private bool OnCanRemoveCallback(ReorderableList list) + { + var stackedConditionals = task as StackedConditional; + return stackedConditionals.conditionals != null && stackedConditionals.conditionals.Length > 0; + } + + private void OnRemoveCallback(ReorderableList list) + { + var stackedConditional = task as StackedConditional; + var conditionals = stackedConditional.conditionals; + ArrayUtility.RemoveAt(ref conditionals, list.index); + reorderableList.list = stackedConditional.conditionals = conditionals; + BehaviorDesignerWindow.instance.SaveBehavior(); + + reorderableList.index -= 1; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Editor/Object Drawers/StackedConditionalDrawer.cs.meta b/Assets/Behavior Designer/Editor/Object Drawers/StackedConditionalDrawer.cs.meta new file mode 100644 index 0000000..f375315 --- /dev/null +++ b/Assets/Behavior Designer/Editor/Object Drawers/StackedConditionalDrawer.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 1d12c12988e4c954b81ed7f3cdd0a439 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Behavior Designer/Integrations.meta b/Assets/Behavior Designer/Integrations.meta new file mode 100644 index 0000000..5daa076 --- /dev/null +++ b/Assets/Behavior Designer/Integrations.meta @@ -0,0 +1,9 @@ +fileFormatVersion: 2 +guid: 519776d3d02747548a264d7d32320ab1 +folderAsset: yes +timeCreated: 1536092918 +licenseType: Store +DefaultImporter: + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Behavior Designer/Integrations/Readme.pdf b/Assets/Behavior Designer/Integrations/Readme.pdf new file mode 100644 index 0000000..a027079 Binary files /dev/null and b/Assets/Behavior Designer/Integrations/Readme.pdf differ diff --git a/Assets/Behavior Designer/Integrations/Readme.pdf.meta b/Assets/Behavior Designer/Integrations/Readme.pdf.meta new file mode 100644 index 0000000..2e88d2f --- /dev/null +++ b/Assets/Behavior Designer/Integrations/Readme.pdf.meta @@ -0,0 +1,4 @@ +fileFormatVersion: 2 +guid: a43abd9ecc0166043973a4ba6da07bf1 +DefaultImporter: + userData: diff --git a/Assets/Behavior Designer/Runtime Source Code Location.pdf b/Assets/Behavior Designer/Runtime Source Code Location.pdf new file mode 100644 index 0000000..f0405f3 Binary files /dev/null and b/Assets/Behavior Designer/Runtime Source Code Location.pdf differ diff --git a/Assets/Behavior Designer/Runtime Source Code Location.pdf.meta b/Assets/Behavior Designer/Runtime Source Code Location.pdf.meta new file mode 100644 index 0000000..fcb16e6 --- /dev/null +++ b/Assets/Behavior Designer/Runtime Source Code Location.pdf.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: f76522f0ea27769479b1c38979bac10a +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Behavior Designer/Runtime.meta b/Assets/Behavior Designer/Runtime.meta new file mode 100644 index 0000000..b907fb9 --- /dev/null +++ b/Assets/Behavior Designer/Runtime.meta @@ -0,0 +1,2 @@ +fileFormatVersion: 2 +guid: 33b3095a3727f544dbe47311776edb53 diff --git a/Assets/Behavior Designer/Runtime/BehaviorDesigner.Runtime.dll b/Assets/Behavior Designer/Runtime/BehaviorDesigner.Runtime.dll new file mode 100644 index 0000000..6bd96ce Binary files /dev/null and b/Assets/Behavior Designer/Runtime/BehaviorDesigner.Runtime.dll differ diff --git a/Assets/Behavior Designer/Runtime/BehaviorDesigner.Runtime.dll.meta b/Assets/Behavior Designer/Runtime/BehaviorDesigner.Runtime.dll.meta new file mode 100644 index 0000000..4339806 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/BehaviorDesigner.Runtime.dll.meta @@ -0,0 +1,32 @@ +fileFormatVersion: 2 +guid: da41a8dd3b5ec434a802d9b5a2a0a777 +timeCreated: 1581513561 +licenseType: Store +PluginImporter: + externalObjects: {} + serializedVersion: 2 + iconMap: {} + executionOrder: {} + isPreloaded: 0 + isOverridable: 0 + platformData: + - first: + Any: + second: + enabled: 1 + settings: {} + - first: + Editor: Editor + second: + enabled: 0 + settings: + DefaultValueInitialized: true + - first: + Windows Store Apps: WindowsStoreApps + second: + enabled: 0 + settings: + CPU: AnyCPU + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Behavior Designer/Runtime/BehaviorTree.cs b/Assets/Behavior Designer/Runtime/BehaviorTree.cs new file mode 100644 index 0000000..9a8bbb5 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/BehaviorTree.cs @@ -0,0 +1,11 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime +{ + // Wrapper for the Behavior class + [AddComponentMenu("Behavior Designer/Behavior Tree")] + public class BehaviorTree : Behavior + { + // intentionally left blank + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/BehaviorTree.cs.meta b/Assets/Behavior Designer/Runtime/BehaviorTree.cs.meta new file mode 100644 index 0000000..3beaa5b --- /dev/null +++ b/Assets/Behavior Designer/Runtime/BehaviorTree.cs.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: 8d7b55c7ecdb49a4a89fa5e6f9022861 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {fileID: 2800000, guid: 5b5f458971c6fd5459c51a7b8079bc3b, type: 3} diff --git a/Assets/Behavior Designer/Runtime/ExternalBehaviorTree.cs b/Assets/Behavior Designer/Runtime/ExternalBehaviorTree.cs new file mode 100644 index 0000000..ad0e0f9 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/ExternalBehaviorTree.cs @@ -0,0 +1,8 @@ +namespace BehaviorDesigner.Runtime +{ + [System.Serializable] + public class ExternalBehaviorTree : ExternalBehavior + { + // intentionally left blank + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/ExternalBehaviorTree.cs.meta b/Assets/Behavior Designer/Runtime/ExternalBehaviorTree.cs.meta new file mode 100644 index 0000000..e9b5e12 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/ExternalBehaviorTree.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: b23f08d2ae4cba14087c1ed36193d82b +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {fileID: 2800000, guid: 5b5f458971c6fd5459c51a7b8079bc3b, type: 3} + userData: diff --git a/Assets/Behavior Designer/Runtime/Object Drawers.meta b/Assets/Behavior Designer/Runtime/Object Drawers.meta new file mode 100644 index 0000000..2e72caa --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Object Drawers.meta @@ -0,0 +1,5 @@ +fileFormatVersion: 2 +guid: 29d0d8866b4fa984bbc7dbf5d988ebcc +folderAsset: yes +DefaultImporter: + userData: diff --git a/Assets/Behavior Designer/Runtime/Object Drawers/FloatSliderAttribute.cs b/Assets/Behavior Designer/Runtime/Object Drawers/FloatSliderAttribute.cs new file mode 100644 index 0000000..1f6a451 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Object Drawers/FloatSliderAttribute.cs @@ -0,0 +1,16 @@ +using BehaviorDesigner.Runtime.Tasks; + +namespace BehaviorDesigner.Runtime.ObjectDrawers +{ + public class FloatSliderAttribute : ObjectDrawerAttribute + { + public float min; + public float max; + + public FloatSliderAttribute(float min, float max) + { + this.min = min; + this.max = max; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Object Drawers/FloatSliderAttribute.cs.meta b/Assets/Behavior Designer/Runtime/Object Drawers/FloatSliderAttribute.cs.meta new file mode 100644 index 0000000..3e0ed22 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Object Drawers/FloatSliderAttribute.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 92948bfcff9a1fc48834935ebb0dbdcb +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Object Drawers/IntSliderAttribute.cs b/Assets/Behavior Designer/Runtime/Object Drawers/IntSliderAttribute.cs new file mode 100644 index 0000000..f73b1cb --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Object Drawers/IntSliderAttribute.cs @@ -0,0 +1,16 @@ +using BehaviorDesigner.Runtime.Tasks; + +namespace BehaviorDesigner.Runtime.ObjectDrawers +{ + public class IntSliderAttribute : ObjectDrawerAttribute + { + public int min; + public int max; + + public IntSliderAttribute(int min, int max) + { + this.min = min; + this.max = max; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Object Drawers/IntSliderAttribute.cs.meta b/Assets/Behavior Designer/Runtime/Object Drawers/IntSliderAttribute.cs.meta new file mode 100644 index 0000000..8086c04 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Object Drawers/IntSliderAttribute.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 2373bfe29d0e5bc47b88a46226aa6a61 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks.meta b/Assets/Behavior Designer/Runtime/Tasks.meta new file mode 100644 index 0000000..1cc0009 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 2cd36de769e955742bf9b7cf79fb671f +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Actions.meta b/Assets/Behavior Designer/Runtime/Tasks/Actions.meta new file mode 100644 index 0000000..614c16e --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Actions.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 91c6a439cec3003498369e01301ee57a +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Actions/BehaviorTreeReference.cs b/Assets/Behavior Designer/Runtime/Tasks/Actions/BehaviorTreeReference.cs new file mode 100644 index 0000000..54ab44e --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Actions/BehaviorTreeReference.cs @@ -0,0 +1,17 @@ + + +namespace BehaviorDesigner.Runtime.Tasks +{ + // Wrapper class for the Behavior Reference task. The Behavior Tree Reference task allows you to run another behavior tree within the current behavior tree. + // One use for this task is if you have an unit that plays a series of tasks to attack. You may want the unit to attack at different points within + // the behavior tree, and you want that attack to always be the same. Instead of copying and pasting the same tasks over and over you can just use + // an external behavior and then the tasks are always guaranteed to be the same. This example is demonstrated in the RTS sample project located at + // https://www.opsive.com/downloads/?pid=803. + [TaskDescription("Behavior Tree Reference allows you to run another behavior tree within the current behavior tree.")] + [HelpURL("https://www.opsive.com/support/documentation/behavior-designer/external-behavior-trees/")] + [TaskIcon("BehaviorTreeReferenceIcon.png")] + public class BehaviorTreeReference : BehaviorReference + { + // intentionally left blank - subclass of BehaviorReference + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Actions/BehaviorTreeReference.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Actions/BehaviorTreeReference.cs.meta new file mode 100644 index 0000000..3f47c29 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Actions/BehaviorTreeReference.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: af7b6fcbc7258f34aad1bb82b5b3fdc8 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Actions/Idle.cs b/Assets/Behavior Designer/Runtime/Tasks/Actions/Idle.cs new file mode 100644 index 0000000..039104a --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Actions/Idle.cs @@ -0,0 +1,14 @@ + + +namespace BehaviorDesigner.Runtime.Tasks +{ + [TaskDescription("Returns a TaskStatus of running. Will only stop when interrupted or a conditional abort is triggered.")] + [TaskIcon("{SkinColor}IdleIcon.png")] + public class Idle : Action + { + public override TaskStatus OnUpdate() + { + return TaskStatus.Running; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Actions/Idle.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Actions/Idle.cs.meta new file mode 100644 index 0000000..575161d --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Actions/Idle.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 759252a4ffada80419ef06ce1c625246 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Actions/Log.cs b/Assets/Behavior Designer/Runtime/Tasks/Actions/Log.cs new file mode 100644 index 0000000..1e05caf --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Actions/Log.cs @@ -0,0 +1,35 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks +{ + [TaskDescription("Log is a simple task which will output the specified text and return success. It can be used for debugging.")] + [TaskIcon("{SkinColor}LogIcon.png")] + public class Log : Action + { + [Tooltip("Text to output to the log")] + public SharedString text; + [Tooltip("Is this text an error?")] + public SharedBool logError; + [Tooltip("Should the time be included in the log message?")] + public SharedBool logTime; + + public override TaskStatus OnUpdate() + { + // Log the text and return success + if (logError.Value) { + Debug.LogError(logTime.Value ? string.Format("{0}: {1}", Time.time, text) : text); + } else { + Debug.Log(logTime.Value ? string.Format("{0}: {1}",Time.time, text) : text); + } + return TaskStatus.Success; + } + + public override void OnReset() + { + // Reset the properties back to their original values + text = ""; + logError = false; + logTime = false; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Actions/Log.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Actions/Log.cs.meta new file mode 100644 index 0000000..fadabb1 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Actions/Log.cs.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: d53794347878c7c479da37533dce2024 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} diff --git a/Assets/Behavior Designer/Runtime/Tasks/Actions/PerformInterruption.cs b/Assets/Behavior Designer/Runtime/Tasks/Actions/PerformInterruption.cs new file mode 100644 index 0000000..861345f --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Actions/PerformInterruption.cs @@ -0,0 +1,28 @@ +namespace BehaviorDesigner.Runtime.Tasks +{ + [TaskDescription("Perform the actual interruption. This will immediately stop the specified tasks from running and will return success or failure depending on the value of interrupt success.")] + [TaskIcon("{SkinColor}PerformInterruptionIcon.png")] + public class PerformInterruption : Action + { + [Tooltip("The list of tasks to interrupt. Can be any number of tasks")] + public Interrupt[] interruptTasks; + [Tooltip("When we interrupt the task should we return a task status of success?")] + public SharedBool interruptSuccess; + + public override TaskStatus OnUpdate() + { + // Loop through all of the tasks and fire an interruption. Once complete return success. + for (int i = 0; i < interruptTasks.Length; ++i) { + interruptTasks[i].DoInterrupt(interruptSuccess.Value ? TaskStatus.Success : TaskStatus.Failure); + } + return TaskStatus.Success; + } + + public override void OnReset() + { + // Reset the properties back to their original values. + interruptTasks = null; + interruptSuccess = false; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Actions/PerformInterruption.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Actions/PerformInterruption.cs.meta new file mode 100644 index 0000000..eeed013 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Actions/PerformInterruption.cs.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: 72d2d6051b23e86468e2f715f044dad8 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} diff --git a/Assets/Behavior Designer/Runtime/Tasks/Actions/Reflection.meta b/Assets/Behavior Designer/Runtime/Tasks/Actions/Reflection.meta new file mode 100644 index 0000000..83432cf --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Actions/Reflection.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 7bbf15f7023452341aebe68861a3aabc +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Actions/Reflection/GetFieldValue.cs b/Assets/Behavior Designer/Runtime/Tasks/Actions/Reflection/GetFieldValue.cs new file mode 100644 index 0000000..72a4f4e --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Actions/Reflection/GetFieldValue.cs @@ -0,0 +1,57 @@ +using UnityEngine; +using System; +using System.Reflection; + +namespace BehaviorDesigner.Runtime.Tasks +{ + [TaskDescription("Gets the value from the field specified. Returns success if the field was retrieved.")] + [TaskCategory("Reflection")] + [TaskIcon("{SkinColor}ReflectionIcon.png")] + public class GetFieldValue : Action + { + [Tooltip("The GameObject to get the field on")] + public SharedGameObject targetGameObject; + [Tooltip("The component to get the field on")] + public SharedString componentName; + [Tooltip("The name of the field")] + public SharedString fieldName; + [Tooltip("The value of the field")] + [RequiredField] + public SharedVariable fieldValue; + + public override TaskStatus OnUpdate() + { + if (fieldValue == null) { + Debug.LogWarning("Unable to get field - field value is null"); + return TaskStatus.Failure; + } + + var type = TaskUtility.GetTypeWithinAssembly(componentName.Value); + if (type == null) { + Debug.LogWarning("Unable to get field - type is null"); + return TaskStatus.Failure; + } + + var component = GetDefaultGameObject(targetGameObject.Value).GetComponent(type); + if (component == null) { + Debug.LogWarning("Unable to get the field with component " + componentName.Value); + return TaskStatus.Failure; + } + + // If you are receiving a compiler error on the Windows Store platform see this topic: + // https://www.opsive.com/support/documentation/behavior-designer/installation/ + var field = component.GetType().GetField(fieldName.Value); + fieldValue.SetValue(field.GetValue(component)); + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + componentName = null; + fieldName = null; + fieldValue = null; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Actions/Reflection/GetFieldValue.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Actions/Reflection/GetFieldValue.cs.meta new file mode 100644 index 0000000..72012c5 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Actions/Reflection/GetFieldValue.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: bc317dd7feb2085499edb0d0c4604640 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Actions/Reflection/GetPropertyValue.cs b/Assets/Behavior Designer/Runtime/Tasks/Actions/Reflection/GetPropertyValue.cs new file mode 100644 index 0000000..82669b2 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Actions/Reflection/GetPropertyValue.cs @@ -0,0 +1,57 @@ +using UnityEngine; +using System; +using System.Reflection; + +namespace BehaviorDesigner.Runtime.Tasks +{ + [TaskDescription("Gets the value from the property specified. Returns success if the property was retrieved.")] + [TaskCategory("Reflection")] + [TaskIcon("{SkinColor}ReflectionIcon.png")] + public class GetPropertyValue : Action + { + [Tooltip("The GameObject to get the property of")] + public SharedGameObject targetGameObject; + [Tooltip("The component to get the property of")] + public SharedString componentName; + [Tooltip("The name of the property")] + public SharedString propertyName; + [Tooltip("The value of the property")] + [RequiredField] + public SharedVariable propertyValue; + + public override TaskStatus OnUpdate() + { + if (propertyValue == null) { + Debug.LogWarning("Unable to get property - property value is null"); + return TaskStatus.Failure; + } + + var type = TaskUtility.GetTypeWithinAssembly(componentName.Value); + if (type == null) { + Debug.LogWarning("Unable to get property - type is null"); + return TaskStatus.Failure; + } + + var component = GetDefaultGameObject(targetGameObject.Value).GetComponent(type); + if (component == null) { + Debug.LogWarning("Unable to get the property with component " + componentName.Value); + return TaskStatus.Failure; + } + + // If you are receiving a compiler error on the Windows Store platform see this topic: + // https://www.opsive.com/support/documentation/behavior-designer/installation/ + var property = component.GetType().GetProperty(propertyName.Value); + propertyValue.SetValue(property.GetValue(component, null)); + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + componentName = null; + propertyName = null; + propertyValue = null; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Actions/Reflection/GetPropertyValue.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Actions/Reflection/GetPropertyValue.cs.meta new file mode 100644 index 0000000..ae51d39 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Actions/Reflection/GetPropertyValue.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: dda9c9b7c6ff2ee4f95a2e208cddae64 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Actions/Reflection/InvokeMethod.cs b/Assets/Behavior Designer/Runtime/Tasks/Actions/Reflection/InvokeMethod.cs new file mode 100644 index 0000000..8357523 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Actions/Reflection/InvokeMethod.cs @@ -0,0 +1,84 @@ +using UnityEngine; +using System; +using System.Collections.Generic; + +namespace BehaviorDesigner.Runtime.Tasks +{ + [TaskDescription("Invokes the specified method with the specified parameters. Can optionally store the return value. Returns success if the method was invoked.")] + [TaskCategory("Reflection")] + [TaskIcon("{SkinColor}ReflectionIcon.png")] + public class InvokeMethod : Action + { + [Tooltip("The GameObject to invoke the method on")] + public SharedGameObject targetGameObject; + [Tooltip("The component to invoke the method on")] + public SharedString componentName; + [Tooltip("The name of the method")] + public SharedString methodName; + [Tooltip("The first parameter of the method")] + public SharedVariable parameter1; + [Tooltip("The second parameter of the method")] + public SharedVariable parameter2; + [Tooltip("The third parameter of the method")] + public SharedVariable parameter3; + [Tooltip("The fourth parameter of the method")] + public SharedVariable parameter4; + [Tooltip("Store the result of the invoke call")] + public SharedVariable storeResult; + + public override TaskStatus OnUpdate() + { + var type = TaskUtility.GetTypeWithinAssembly(componentName.Value); + if (type == null) { + Debug.LogWarning("Unable to invoke - type is null"); + return TaskStatus.Failure; + } + + var component = GetDefaultGameObject(targetGameObject.Value).GetComponent(type); + if (component == null) { + Debug.LogWarning("Unable to invoke method with component " + componentName.Value); + return TaskStatus.Failure; + } + + var parameterList = new List(); + var parameterTypeList = new List(); + SharedVariable sharedVariable = null; + for (int i = 0; i < 4; ++i) { + var parameterField = GetType().GetField("parameter" + (i + 1)); + if ((sharedVariable = parameterField.GetValue(this) as SharedVariable) != null) { + parameterList.Add(sharedVariable.GetValue()); + parameterTypeList.Add(sharedVariable.GetType().GetProperty("Value").PropertyType); + } else { + break; + } + } + // If you are receiving a compiler error on the Windows Store platform see this topic: + // https://www.opsive.com/support/documentation/behavior-designer/installation/ + var methodInfo = component.GetType().GetMethod(methodName.Value, parameterTypeList.ToArray()); + + if (methodInfo == null) { + Debug.LogWarning("Unable to invoke method " + methodName.Value + " on component " + componentName.Value); + return TaskStatus.Failure; + } + + var result = methodInfo.Invoke(component, parameterList.ToArray()); + if (storeResult != null) { + storeResult.SetValue(result); + } + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + componentName = null; + methodName = null; + parameter1 = null; + parameter2 = null; + parameter3 = null; + parameter4 = null; + storeResult = null; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Actions/Reflection/InvokeMethod.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Actions/Reflection/InvokeMethod.cs.meta new file mode 100644 index 0000000..76132da --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Actions/Reflection/InvokeMethod.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 359bd67578f53034ab2eb00e7696d317 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Actions/Reflection/SetFieldValue.cs b/Assets/Behavior Designer/Runtime/Tasks/Actions/Reflection/SetFieldValue.cs new file mode 100644 index 0000000..8b8337e --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Actions/Reflection/SetFieldValue.cs @@ -0,0 +1,56 @@ +using UnityEngine; +using System; +using System.Reflection; + +namespace BehaviorDesigner.Runtime.Tasks +{ + [TaskDescription("Sets the field to the value specified. Returns success if the field was set.")] + [TaskCategory("Reflection")] + [TaskIcon("{SkinColor}ReflectionIcon.png")] + public class SetFieldValue : Action + { + [Tooltip("The GameObject to set the field on")] + public SharedGameObject targetGameObject; + [Tooltip("The component to set the field on")] + public SharedString componentName; + [Tooltip("The name of the field")] + public SharedString fieldName; + [Tooltip("The value to set")] + public SharedVariable fieldValue; + + public override TaskStatus OnUpdate() + { + if (fieldValue == null) { + Debug.LogWarning("Unable to get field - field value is null"); + return TaskStatus.Failure; + } + + var type = TaskUtility.GetTypeWithinAssembly(componentName.Value); + if (type == null) { + Debug.LogWarning("Unable to set field - type is null"); + return TaskStatus.Failure; + } + + var component = GetDefaultGameObject(targetGameObject.Value).GetComponent(type); + if (component == null) { + Debug.LogWarning("Unable to set the field with component " + componentName.Value); + return TaskStatus.Failure; + } + + // If you are receiving a compiler error on the Windows Store platform see this topic: + // https://www.opsive.com/support/documentation/behavior-designer/installation/ + var field = component.GetType().GetField(fieldName.Value); + field.SetValue(component, fieldValue.GetValue()); + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + componentName = null; + fieldName = null; + fieldValue = null; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Actions/Reflection/SetFieldValue.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Actions/Reflection/SetFieldValue.cs.meta new file mode 100644 index 0000000..75186ec --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Actions/Reflection/SetFieldValue.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 21e389787213ba24ab1a6817def634ae +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Actions/Reflection/SetPropertyValue.cs b/Assets/Behavior Designer/Runtime/Tasks/Actions/Reflection/SetPropertyValue.cs new file mode 100644 index 0000000..ab0cc1d --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Actions/Reflection/SetPropertyValue.cs @@ -0,0 +1,56 @@ +using UnityEngine; +using System; +using System.Reflection; + +namespace BehaviorDesigner.Runtime.Tasks +{ + [TaskDescription("Sets the property to the value specified. Returns success if the property was set.")] + [TaskCategory("Reflection")] + [TaskIcon("{SkinColor}ReflectionIcon.png")] + public class SetPropertyValue : Action + { + [Tooltip("The GameObject to set the property on")] + public SharedGameObject targetGameObject; + [Tooltip("The component to set the property on")] + public SharedString componentName; + [Tooltip("The name of the property")] + public SharedString propertyName; + [Tooltip("The value to set")] + public SharedVariable propertyValue; + + public override TaskStatus OnUpdate() + { + if (propertyValue == null) { + Debug.LogWarning("Unable to get field - field value is null"); + return TaskStatus.Failure; + } + + var type = TaskUtility.GetTypeWithinAssembly(componentName.Value); + if (type == null) { + Debug.LogWarning("Unable to set property - type is null"); + return TaskStatus.Failure; + } + + var component = GetDefaultGameObject(targetGameObject.Value).GetComponent(type); + if (component == null) { + Debug.LogWarning("Unable to set the property with component " + componentName.Value); + return TaskStatus.Failure; + } + + // If you are receiving a compiler error on the Windows Store platform see this topic: + // https://www.opsive.com/support/documentation/behavior-designer/installation/ + var property = component.GetType().GetProperty(propertyName.Value); + property.SetValue(component, propertyValue.GetValue(), null); + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + componentName = null; + propertyName = null; + propertyValue = null; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Actions/Reflection/SetPropertyValue.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Actions/Reflection/SetPropertyValue.cs.meta new file mode 100644 index 0000000..79968a2 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Actions/Reflection/SetPropertyValue.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: d98b13b7ae4b36b4092b439731466d9b +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Actions/RestartBehaviorTree.cs b/Assets/Behavior Designer/Runtime/Tasks/Actions/RestartBehaviorTree.cs new file mode 100644 index 0000000..2e9bbb6 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Actions/RestartBehaviorTree.cs @@ -0,0 +1,55 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks +{ + [TaskDescription("Restarts a behavior tree, returns success after it has been restarted.")] + [TaskIcon("{SkinColor}RestartBehaviorTreeIcon.png")] + public class RestartBehaviorTree : Action + { + [Tooltip("The GameObject of the behavior tree that should be restarted. If null use the current behavior")] + public SharedGameObject behaviorGameObject; + [Tooltip("The group of the behavior tree that should be restarted")] + public SharedInt group; + + private Behavior behavior; + + public override void OnAwake() + { + var behaviorTrees = GetDefaultGameObject(behaviorGameObject.Value).GetComponents(); + if (behaviorTrees.Length == 1) { + behavior = behaviorTrees[0]; + } else if (behaviorTrees.Length > 1) { + for (int i = 0; i < behaviorTrees.Length; ++i) { + if (behaviorTrees[i].Group == group.Value) { + behavior = behaviorTrees[i]; + break; + } + } + // If the group can't be found then use the first behavior tree + if (behavior == null) { + behavior = behaviorTrees[0]; + } + } + } + + public override TaskStatus OnUpdate() + { + if (behavior == null) { + return TaskStatus.Failure; + } + + // Stop the behavior tree + behavior.DisableBehavior(); + // Start the behavior tree back up + behavior.EnableBehavior(); + // Return success + return TaskStatus.Success; + } + + public override void OnReset() + { + // Reset the properties back to their original values. + behavior = null; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Actions/RestartBehaviorTree.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Actions/RestartBehaviorTree.cs.meta new file mode 100644 index 0000000..aefc2fe --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Actions/RestartBehaviorTree.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 2765e7ece98046542880a1249b87e096 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Actions/SendEvent.cs b/Assets/Behavior Designer/Runtime/Tasks/Actions/SendEvent.cs new file mode 100644 index 0000000..6af8ac4 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Actions/SendEvent.cs @@ -0,0 +1,73 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks +{ + [TaskDescription("Sends an event to the behavior tree, returns success after sending the event.")] + [HelpURL("https://www.opsive.com/support/documentation/behavior-designer/events/")] + [TaskIcon("{SkinColor}SendEventIcon.png")] + public class SendEvent : Action + { + [Tooltip("The GameObject of the behavior tree that should have the event sent to it. If null use the current behavior")] + public SharedGameObject targetGameObject; + [Tooltip("The event to send")] + public SharedString eventName; + [Tooltip("The group of the behavior tree that the event should be sent to")] + public SharedInt group; + [Tooltip("Optionally specify a first argument to send")] + [SharedRequired] + public SharedVariable argument1; + [Tooltip("Optionally specify a second argument to send")] + [SharedRequired] + public SharedVariable argument2; + [Tooltip("Optionally specify a third argument to send")] + [SharedRequired] + public SharedVariable argument3; + + private BehaviorTree behaviorTree; + + public override void OnStart() + { + var behaviorTrees = GetDefaultGameObject(targetGameObject.Value).GetComponents(); + if (behaviorTrees.Length == 1) { + behaviorTree = behaviorTrees[0]; + } else if (behaviorTrees.Length > 1) { + for (int i = 0; i < behaviorTrees.Length; ++i) { + if (behaviorTrees[i].Group == group.Value) { + behaviorTree = behaviorTrees[i]; + break; + } + } + // If the group can't be found then use the first behavior tree + if (behaviorTree == null) { + behaviorTree = behaviorTrees[0]; + } + } + } + + public override TaskStatus OnUpdate() + { + // Send the event and return success + if (argument1 == null || argument1.IsNone) { + behaviorTree.SendEvent(eventName.Value); + } else { + if (argument2 == null || argument2.IsNone) { + behaviorTree.SendEvent(eventName.Value, argument1.GetValue()); + } else { + if (argument3 == null || argument3.IsNone) { + behaviorTree.SendEvent(eventName.Value, argument1.GetValue(), argument2.GetValue()); + } else { + behaviorTree.SendEvent(eventName.Value, argument1.GetValue(), argument2.GetValue(), argument3.GetValue()); + } + } + } + return TaskStatus.Success; + } + + public override void OnReset() + { + // Reset the properties back to their original values + targetGameObject = null; + eventName = ""; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Actions/SendEvent.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Actions/SendEvent.cs.meta new file mode 100644 index 0000000..051587e --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Actions/SendEvent.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 53b90428a37913c40b6d415ced4e12f9 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Actions/StackedAction.cs b/Assets/Behavior Designer/Runtime/Tasks/Actions/StackedAction.cs new file mode 100644 index 0000000..5aad80d --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Actions/StackedAction.cs @@ -0,0 +1,266 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks +{ + [TaskDescription("Allows multiple action tasks to be added to a single node.")] + [TaskIcon("{SkinColor}StackedActionIcon.png")] + public class StackedAction : Action + { + [InspectTask] + public Action[] actions; + public enum ComparisonType + { + Sequence, + Selector + } + [Tooltip("Specifies if the tasks should be traversed with an AND (Sequence) or an OR (Selector).")] + public ComparisonType comparisonType; + [Tooltip("Should the tasks be labeled within the graph?")] + public bool graphLabel; + + public override void OnAwake() + { + if (actions == null) { + return; + } + + for (int i = 0; i < actions.Length; ++i) { + if (actions[i] == null) { + continue; + } + + actions[i].GameObject = gameObject; + actions[i].Transform = transform; + actions[i].Owner = Owner; + actions[i].NodeData = new NodeData(); + actions[i].OnAwake(); + } + } + + public override void OnStart() + { + if (actions == null) { + return; + } + + for (int i = 0; i < actions.Length; ++i) { + if (actions[i] == null) { + continue; + } + actions[i].OnStart(); + } + } + + public override TaskStatus OnUpdate() + { + if (actions == null) { + return TaskStatus.Failure; + } + + for (int i = 0; i < actions.Length; ++i) { + if (actions[i] == null) { + continue; + } + actions[i].NodeData.ExecutionStatus = actions[i].OnUpdate(); + if (actions[i].NodeData.ExecutionStatus == TaskStatus.Running) { + Debug.LogWarning("Warning: The action task returned a status of running when action tasks should only return success or failure."); + } + + if (comparisonType == ComparisonType.Sequence && actions[i].NodeData.ExecutionStatus == TaskStatus.Failure) { + return TaskStatus.Failure; + } else if (comparisonType == ComparisonType.Selector && actions[i].NodeData.ExecutionStatus == TaskStatus.Success) { + return TaskStatus.Success; + } + } + return comparisonType == ComparisonType.Sequence ? TaskStatus.Success : TaskStatus.Failure; + } + + public override void OnFixedUpdate() + { + if (actions == null) { + return; + } + + for (int i = 0; i < actions.Length; ++i) { + if (actions[i] == null) { + continue; + } + actions[i].OnFixedUpdate(); + } + } + + public override void OnLateUpdate() + { + if (actions == null) { + return; + } + + for (int i = 0; i < actions.Length; ++i) { + if (actions[i] == null) { + continue; + } + actions[i].OnLateUpdate(); + } + } + + public override void OnEnd() + { + if (actions == null) { + return; + } + + for (int i = 0; i < actions.Length; ++i) { + if (actions[i] == null) { + continue; + } + actions[i].OnEnd(); + } + } + + public override void OnTriggerEnter(Collider other) + { + if (actions == null) { + return; + } + + for (int i = 0; i < actions.Length; ++i) { + if (actions[i] == null) { + continue; + } + actions[i].OnTriggerEnter(other); + } + } + + public override void OnTriggerEnter2D(Collider2D other) + { + if (actions == null) { + return; + } + + for (int i = 0; i < actions.Length; ++i) { + if (actions[i] == null) { + continue; + } + actions[i].OnTriggerEnter2D(other); + } + } + + public override void OnTriggerExit(Collider other) + { + if (actions == null) { + return; + } + + for (int i = 0; i < actions.Length; ++i) { + if (actions[i] == null) { + continue; + } + actions[i].OnTriggerExit(other); + } + } + + public override void OnTriggerExit2D(Collider2D other) + { + if (actions == null) { + return; + } + + for (int i = 0; i < actions.Length; ++i) { + if (actions[i] == null) { + continue; + } + actions[i].OnTriggerExit2D(other); + } + } + + public override void OnCollisionEnter(Collision collision) + { + if (actions == null) { + return; + } + + for (int i = 0; i < actions.Length; ++i) { + if (actions[i] == null) { + continue; + } + actions[i].OnCollisionEnter(collision); + } + } + + public override void OnCollisionEnter2D(Collision2D collision) + { + if (actions == null) { + return; + } + + for (int i = 0; i < actions.Length; ++i) { + if (actions[i] == null) { + continue; + } + actions[i].OnCollisionEnter2D(collision); + } + } + + public override void OnCollisionExit(Collision collision) + { + if (actions == null) { + return; + } + + for (int i = 0; i < actions.Length; ++i) { + if (actions[i] == null) { + continue; + } + actions[i].OnCollisionExit(collision); + } + } + + public override void OnCollisionExit2D(Collision2D collision) + { + if (actions == null) { + return; + } + + for (int i = 0; i < actions.Length; ++i) { + if (actions[i] == null) { + continue; + } + actions[i].OnCollisionExit2D(collision); + } + } + + public override string OnDrawNodeText() + { + if (actions == null || !graphLabel) { + return string.Empty; + } + + var text = string.Empty; + for (int i = 0; i < actions.Length; ++i) { + if (actions[i] == null) { + continue; + } + if (!string.IsNullOrEmpty(text)) { + text += "\n"; + } + text += actions[i].GetType().Name; + } + + return text; + } + + public override void OnReset() + { + if (actions == null) { + return; + } + + for (int i = 0; i < actions.Length; ++i) { + if (actions[i] == null) { + continue; + } + actions[i].OnReset(); + } + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Actions/StackedAction.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Actions/StackedAction.cs.meta new file mode 100644 index 0000000..4c7a89c --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Actions/StackedAction.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 60f3f340bd02a8a4c84749a903c731da +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Actions/StartBehaviorTree.cs b/Assets/Behavior Designer/Runtime/Tasks/Actions/StartBehaviorTree.cs new file mode 100644 index 0000000..8969ad4 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Actions/StartBehaviorTree.cs @@ -0,0 +1,91 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks +{ + [TaskDescription("Start a new behavior tree and return success after it has been started.")] + [TaskIcon("{SkinColor}StartBehaviorTreeIcon.png")] + public class StartBehaviorTree : Action + { + [Tooltip("The GameObject of the behavior tree that should be started. If null use the current behavior")] + public SharedGameObject behaviorGameObject; + [Tooltip("The group of the behavior tree that should be started")] + public SharedInt group; + [Tooltip("Should this task wait for the behavior tree to complete?")] + public SharedBool waitForCompletion = false; + [Tooltip("Should the variables be synchronized?")] + public SharedBool synchronizeVariables; + + private bool behaviorComplete; + private Behavior behavior; + + public override void OnStart() + { + var behaviorTrees = GetDefaultGameObject(behaviorGameObject.Value).GetComponents(); + if (behaviorTrees.Length == 1) { + behavior = behaviorTrees[0]; + } else if (behaviorTrees.Length > 1) { + for (int i = 0; i < behaviorTrees.Length; ++i) { + if (behaviorTrees[i].Group == group.Value) { + behavior = behaviorTrees[i]; + break; + } + } + // If the group can't be found then use the first behavior tree + if (behavior == null) { + behavior = behaviorTrees[0]; + } + } + + if (behavior != null) { + var variables = Owner.GetAllVariables(); + if (variables != null && synchronizeVariables.Value) { + for (int i = 0; i < variables.Count; ++i) { + behavior.SetVariableValue(variables[i].Name, variables[i]); + } + } + + behavior.EnableBehavior(); + + if (waitForCompletion.Value) { + behaviorComplete = false; + behavior.OnBehaviorEnd += BehaviorEnded; + } + } + } + + public override TaskStatus OnUpdate() + { + if (behavior == null) { + return TaskStatus.Failure; + } + + // Return a status of running if we are waiting for the behavior tree to end and it hasn't ended yet + if (waitForCompletion.Value && !behaviorComplete) { + return TaskStatus.Running; + } + + return TaskStatus.Success; + } + + private void BehaviorEnded(Behavior behavior) + { + behaviorComplete = true; + } + + public override void OnEnd() + { + if (behavior != null && waitForCompletion.Value) { + behavior.OnBehaviorEnd -= BehaviorEnded; + } + } + + public override void OnReset() + { + // Reset the properties back to their original values. + behaviorGameObject = null; + group = 0; + waitForCompletion = false; + synchronizeVariables = false; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Actions/StartBehaviorTree.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Actions/StartBehaviorTree.cs.meta new file mode 100644 index 0000000..14e6841 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Actions/StartBehaviorTree.cs.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: bc3d67c80371297439385b30f4be506c +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} diff --git a/Assets/Behavior Designer/Runtime/Tasks/Actions/StopBehaviorTree.cs b/Assets/Behavior Designer/Runtime/Tasks/Actions/StopBehaviorTree.cs new file mode 100644 index 0000000..b91a0e3 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Actions/StopBehaviorTree.cs @@ -0,0 +1,56 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks +{ + [TaskDescription("Pause or disable a behavior tree and return success after it has been stopped.")] + [TaskIcon("{SkinColor}StopBehaviorTreeIcon.png")] + public class StopBehaviorTree : Action + { + [Tooltip("The GameObject of the behavior tree that should be stopped. If null use the current behavior")] + public SharedGameObject behaviorGameObject; + [Tooltip("The group of the behavior tree that should be stopped")] + public SharedInt group; + [Tooltip("Should the behavior be paused or completely disabled")] + public SharedBool pauseBehavior = false; + + private Behavior behavior; + + public override void OnStart() + { + var behaviorTrees = GetDefaultGameObject(behaviorGameObject.Value).GetComponents(); + if (behaviorTrees.Length == 1) { + behavior = behaviorTrees[0]; + } else if (behaviorTrees.Length > 1) { + for (int i = 0; i < behaviorTrees.Length; ++i) { + if (behaviorTrees[i].Group == group.Value) { + behavior = behaviorTrees[i]; + break; + } + } + // If the group can't be found then use the first behavior tree + if (behavior == null) { + behavior = behaviorTrees[0]; + } + } + } + + public override TaskStatus OnUpdate() + { + if (behavior == null) { + return TaskStatus.Failure; + } + + // Start the behavior and return success. + behavior.DisableBehavior(pauseBehavior.Value); + return TaskStatus.Success; + } + + public override void OnReset() + { + // Reset the properties back to their original values + behaviorGameObject = null; + group = 0; + pauseBehavior = false; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Actions/StopBehaviorTree.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Actions/StopBehaviorTree.cs.meta new file mode 100644 index 0000000..2c86afe --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Actions/StopBehaviorTree.cs.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: 130afc7e6aa6e0c4aba29097334aa66b +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} diff --git a/Assets/Behavior Designer/Runtime/Tasks/Actions/Wait.cs b/Assets/Behavior Designer/Runtime/Tasks/Actions/Wait.cs new file mode 100644 index 0000000..da0ae38 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Actions/Wait.cs @@ -0,0 +1,66 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks +{ + [TaskDescription("Wait a specified amount of time. The task will return running until the task is done waiting. It will return success after the wait time has elapsed.")] + [TaskIcon("{SkinColor}WaitIcon.png")] + public class Wait : Action + { + [Tooltip("The amount of time to wait")] + public SharedFloat waitTime = 1; + [Tooltip("Should the wait be randomized?")] + public SharedBool randomWait = false; + [Tooltip("The minimum wait time if random wait is enabled")] + public SharedFloat randomWaitMin = 1; + [Tooltip("The maximum wait time if random wait is enabled")] + public SharedFloat randomWaitMax = 1; + + // The time to wait + private float waitDuration; + // The time that the task started to wait. + private float startTime; + // Remember the time that the task is paused so the time paused doesn't contribute to the wait time. + private float pauseTime; + + public override void OnStart() + { + // Remember the start time. + startTime = Time.time; + if (randomWait.Value) { + waitDuration = Random.Range(randomWaitMin.Value, randomWaitMax.Value); + } else { + waitDuration = waitTime.Value; + } + } + + public override TaskStatus OnUpdate() + { + // The task is done waiting if the time waitDuration has elapsed since the task was started. + if (startTime + waitDuration < Time.time) { + return TaskStatus.Success; + } + // Otherwise we are still waiting. + return TaskStatus.Running; + } + + public override void OnPause(bool paused) + { + if (paused) { + // Remember the time that the behavior was paused. + pauseTime = Time.time; + } else { + // Add the difference between Time.time and pauseTime to figure out a new start time. + startTime += (Time.time - pauseTime); + } + } + + public override void OnReset() + { + // Reset the public properties back to their original values + waitTime = 1; + randomWait = false; + randomWaitMin = 1; + randomWaitMax = 1; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Actions/Wait.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Actions/Wait.cs.meta new file mode 100644 index 0000000..dbd9b1d --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Actions/Wait.cs.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: 67824d2e00531d84db9973773e4426e9 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} diff --git a/Assets/Behavior Designer/Runtime/Tasks/Composites.meta b/Assets/Behavior Designer/Runtime/Tasks/Composites.meta new file mode 100644 index 0000000..707a8f6 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Composites.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 02c91ef526a3f8a41b5df4402d7c783f +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Composites/Parallel.cs b/Assets/Behavior Designer/Runtime/Tasks/Composites/Parallel.cs new file mode 100644 index 0000000..b8525e6 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Composites/Parallel.cs @@ -0,0 +1,86 @@ +namespace BehaviorDesigner.Runtime.Tasks +{ + [TaskDescription("Similar to the sequence task, the parallel task will run each child task until a child task returns failure. " + + "The difference is that the parallel task will run all of its children tasks simultaneously versus running each task one at a time. " + + "Like the sequence class, the parallel task will return success once all of its children tasks have return success. " + + "If one tasks returns failure the parallel task will end all of the child tasks and return failure.")] + [TaskIcon("{SkinColor}ParallelIcon.png")] + public class Parallel : Composite + { + // The index of the child that is currently running or is about to run. + private int currentChildIndex; + // The task status of every child task. + private TaskStatus[] executionStatus; + + public override void OnAwake() + { + // Create a new task status array that will hold the execution status of all of the children tasks. + executionStatus = new TaskStatus[children.Count]; + } + + public override void OnChildStarted(int childIndex) + { + // One of the children has started to run. Increment the child index and set the current task status of that child to running. + currentChildIndex++; + executionStatus[childIndex] = TaskStatus.Running; + } + + public override bool CanRunParallelChildren() + { + // This task can run parallel children. + return true; + } + + public override int CurrentChildIndex() + { + return currentChildIndex; + } + + public override bool CanExecute() + { + // We can continue executing if we have more children that haven't been started yet. + return currentChildIndex < children.Count; + } + + public override void OnChildExecuted(int childIndex, TaskStatus childStatus) + { + // One of the children has finished running. Set the task status. + executionStatus[childIndex] = childStatus; + } + + public override TaskStatus OverrideStatus(TaskStatus status) + { + // Assume all of the children have finished executing. Loop through the execution status of every child and check to see if any tasks are currently running + // or failed. If a task is still running then all of the children are not done executing and the parallel task should continue to return a task status of running. + // If a task failed then return failure. The Behavior Manager will stop all of the children tasks. If no child task is running or has failed then the parallel + // task succeeded and it will return success. + bool childrenComplete = true; + for (int i = 0; i < executionStatus.Length; ++i) { + if (executionStatus[i] == TaskStatus.Running) { + childrenComplete = false; + } else if (executionStatus[i] == TaskStatus.Failure) { + return TaskStatus.Failure; + } + } + return (childrenComplete ? TaskStatus.Success : TaskStatus.Running); + } + + public override void OnConditionalAbort(int childIndex) + { + // Start from the beginning on an abort + currentChildIndex = 0; + for (int i = 0; i < executionStatus.Length; ++i) { + executionStatus[i] = TaskStatus.Inactive; + } + } + + public override void OnEnd() + { + // Reset the execution status and the child index back to their starting values. + for (int i = 0; i < executionStatus.Length; ++i) { + executionStatus[i] = TaskStatus.Inactive; + } + currentChildIndex = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Composites/Parallel.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Composites/Parallel.cs.meta new file mode 100644 index 0000000..42400c1 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Composites/Parallel.cs.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: 4a7063721a0dbc04787bec1b0507f9ae +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} diff --git a/Assets/Behavior Designer/Runtime/Tasks/Composites/ParallelComplete.cs b/Assets/Behavior Designer/Runtime/Tasks/Composites/ParallelComplete.cs new file mode 100644 index 0000000..3acbadf --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Composites/ParallelComplete.cs @@ -0,0 +1,81 @@ +namespace BehaviorDesigner.Runtime.Tasks +{ + [TaskDescription("Similar to the parallel selector task, except the parallel complete task will return the child status as soon as the child returns success or failure." + + "The child tasks are executed simultaneously.")] + [TaskIcon("{SkinColor}ParallelCompleteIcon.png")] + public class ParallelComplete : Composite + { + // The index of the child that is currently running or is about to run. + private int currentChildIndex; + // The task status of every child task. + private TaskStatus[] executionStatus; + + public override void OnAwake() + { + // Create a new task status array that will hold the execution status of all of the children tasks. + executionStatus = new TaskStatus[children.Count]; + } + + public override void OnChildStarted(int childIndex) + { + // One of the children has started to run. Increment the child index and set the current task status of that child to running. + currentChildIndex++; + executionStatus[childIndex] = TaskStatus.Running; + } + + public override bool CanRunParallelChildren() + { + // This task can run parallel children. + return true; + } + + public override int CurrentChildIndex() + { + return currentChildIndex; + } + + public override bool CanExecute() + { + // We can continue executing if we have more children that haven't been started yet. + return currentChildIndex < children.Count; + } + + public override void OnChildExecuted(int childIndex, TaskStatus childStatus) + { + // One of the children has finished running. Set the task status. + executionStatus[childIndex] = childStatus; + } + + public override void OnConditionalAbort(int childIndex) + { + // Start from the beginning on an abort + currentChildIndex = 0; + for (int i = 0; i < executionStatus.Length; ++i) { + executionStatus[i] = TaskStatus.Inactive; + } + } + + public override TaskStatus OverrideStatus(TaskStatus status) + { + if (currentChildIndex == 0) { + return TaskStatus.Success; + } + // Return the child task's status as soon as a child task returns success or failure. + for (int i = 0; i < currentChildIndex; ++i) { + if (executionStatus[i] == TaskStatus.Success || executionStatus[i] == TaskStatus.Failure) { + return executionStatus[i]; + } + } + return TaskStatus.Running; + } + + public override void OnEnd() + { + // Reset the execution status and the child index back to their starting values. + for (int i = 0; i < executionStatus.Length; ++i) { + executionStatus[i] = TaskStatus.Inactive; + } + currentChildIndex = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Composites/ParallelComplete.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Composites/ParallelComplete.cs.meta new file mode 100644 index 0000000..fc7dd0a --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Composites/ParallelComplete.cs.meta @@ -0,0 +1,12 @@ +fileFormatVersion: 2 +guid: ef4b3eb51f6ede04bba3598677fe8531 +timeCreated: 1487379311 +licenseType: Store +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Composites/ParallelSelector.cs b/Assets/Behavior Designer/Runtime/Tasks/Composites/ParallelSelector.cs new file mode 100644 index 0000000..b140033 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Composites/ParallelSelector.cs @@ -0,0 +1,86 @@ +namespace BehaviorDesigner.Runtime.Tasks +{ + [TaskDescription("Similar to the selector task, the parallel selector task will return success as soon as a child task returns success. " + + "The difference is that the parallel task will run all of its children tasks simultaneously versus running each task one at a time. " + + "If one tasks returns success the parallel selector task will end all of the child tasks and return success. " + + "If every child task returns failure then the parallel selector task will return failure.")] + [TaskIcon("{SkinColor}ParallelSelectorIcon.png")] + public class ParallelSelector : Composite + { + // The index of the child that is currently running or is about to run. + private int currentChildIndex; + // The task status of every child task. + private TaskStatus[] executionStatus; + + public override void OnAwake() + { + // Create a new task status array that will hold the execution status of all of the children tasks. + executionStatus = new TaskStatus[children.Count]; + } + + public override void OnChildStarted(int childIndex) + { + // One of the children has started to run. Increment the child index and set the current task status of that child to running. + currentChildIndex++; + executionStatus[childIndex] = TaskStatus.Running; + } + + public override bool CanRunParallelChildren() + { + // This task can run parallel children. + return true; + } + + public override int CurrentChildIndex() + { + return currentChildIndex; + } + + public override bool CanExecute() + { + // We can continue executing if we have more children that haven't been started yet. + return currentChildIndex < children.Count; + } + + public override void OnChildExecuted(int childIndex, TaskStatus childStatus) + { + // One of the children has finished running. Set the task status. + executionStatus[childIndex] = childStatus; + } + + public override void OnConditionalAbort(int childIndex) + { + // Start from the beginning on an abort + currentChildIndex = 0; + for (int i = 0; i < executionStatus.Length; ++i) { + executionStatus[i] = TaskStatus.Inactive; + } + } + + public override TaskStatus OverrideStatus(TaskStatus status) + { + // Assume all of the children have finished executing. Loop through the execution status of every child and check to see if any tasks are currently running + // or succeeded. If a task is still running then all of the children are not done executing and the parallel selector task should continue to return a task status of running. + // If a task succeeded then return success. The Behavior Manager will stop all of the children tasks. If no child task is running or has succeeded then the parallel selector + // task failed and it will return failure. + bool childrenComplete = true; + for (int i = 0; i < executionStatus.Length; ++i) { + if (executionStatus[i] == TaskStatus.Running) { + childrenComplete = false; + } else if (executionStatus[i] == TaskStatus.Success) { + return TaskStatus.Success; + } + } + return (childrenComplete ? TaskStatus.Failure : TaskStatus.Running); + } + + public override void OnEnd() + { + // Reset the execution status and the child index back to their starting values. + for (int i = 0; i < executionStatus.Length; ++i) { + executionStatus[i] = TaskStatus.Inactive; + } + currentChildIndex = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Composites/ParallelSelector.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Composites/ParallelSelector.cs.meta new file mode 100644 index 0000000..5b8aa3c --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Composites/ParallelSelector.cs.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: 52e4e27ad95cedb41a3bc2c5f5ed0b54 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} diff --git a/Assets/Behavior Designer/Runtime/Tasks/Composites/PrioritySelector.cs b/Assets/Behavior Designer/Runtime/Tasks/Composites/PrioritySelector.cs new file mode 100644 index 0000000..ceda144 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Composites/PrioritySelector.cs @@ -0,0 +1,71 @@ +using System.Collections.Generic; + +namespace BehaviorDesigner.Runtime.Tasks +{ + [TaskDescription("Similar to the selector task, the priority selector task will return success as soon as a child task returns success. " + + "Instead of running the tasks sequentially from left to right within the tree, the priority selector will ask the task what its priority is to determine the order. " + + "The higher priority tasks have a higher chance at being run first.")] + [TaskIcon("{SkinColor}PrioritySelectorIcon.png")] + public class PrioritySelector : Composite + { + // The index of the child that is currently running or is about to run. + private int currentChildIndex = 0; + // The task status of every child task. + private TaskStatus executionStatus = TaskStatus.Inactive; + // The order to run its children in. + private List childrenExecutionOrder = new List(); + + public override void OnStart() + { + // Make sure the list is empty before we add child indexes to it. + childrenExecutionOrder.Clear(); + + // Loop through each child task and determine its priority. The higher the priority the lower it goes within the list. The task with the highest + // priority will be first in the list and will be executed first. + for (int i = 0; i < children.Count; ++i) { + float priority = children[i].GetPriority(); + int insertIndex = childrenExecutionOrder.Count; + for (int j = 0; j < childrenExecutionOrder.Count; ++j) { + if (children[childrenExecutionOrder[j]].GetPriority() < priority) { + insertIndex = j; + break; + } + } + childrenExecutionOrder.Insert(insertIndex, i); + } + } + + public override int CurrentChildIndex() + { + // Use the execution order list in order to determine the current child index. + return childrenExecutionOrder[currentChildIndex]; + } + + public override bool CanExecute() + { + // We can continue to execuate as long as we have children that haven't been executed and no child has returned success. + return currentChildIndex < children.Count && executionStatus != TaskStatus.Success; + } + + public override void OnChildExecuted(TaskStatus childStatus) + { + // Increase the child index and update the execution status after a child has finished running. + currentChildIndex++; + executionStatus = childStatus; + } + + public override void OnConditionalAbort(int childIndex) + { + // Set the current child index to the index that caused the abort + currentChildIndex = childIndex; + executionStatus = TaskStatus.Inactive; + } + + public override void OnEnd() + { + // All of the children have run. Reset the variables back to their starting values. + executionStatus = TaskStatus.Inactive; + currentChildIndex = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Composites/PrioritySelector.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Composites/PrioritySelector.cs.meta new file mode 100644 index 0000000..a532df0 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Composites/PrioritySelector.cs.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: 8b5aa86ad86e94f41841abd04bd96f2a +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} diff --git a/Assets/Behavior Designer/Runtime/Tasks/Composites/RandomSelector.cs b/Assets/Behavior Designer/Runtime/Tasks/Composites/RandomSelector.cs new file mode 100644 index 0000000..e363d10 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Composites/RandomSelector.cs @@ -0,0 +1,101 @@ +using UnityEngine; +using System.Collections.Generic; + +namespace BehaviorDesigner.Runtime.Tasks +{ + [TaskDescription("Similar to the selector task, the random selector task will return success as soon as a child task returns success. " + + "The difference is that the random selector class will run its children in a random order. The selector task is deterministic " + + "in that it will always run the tasks from left to right within the tree. The random selector task shuffles the child tasks up and then begins " + + "execution in a random order. Other than that the random selector class is the same as the selector class. It will continue running tasks " + + "until a task completes successfully. If no child tasks return success then it will return failure.")] + [TaskIcon("{SkinColor}RandomSelectorIcon.png")] + public class RandomSelector : Composite + { + [Tooltip("Seed the random number generator to make things easier to debug")] + public int seed = 0; + [Tooltip("Do we want to use the seed?")] + public bool useSeed = false; + + // A list of indexes of every child task. This list is used by the Fischer-Yates shuffle algorithm. + private List childIndexList = new List(); + // The random child index execution order. + private Stack childrenExecutionOrder = new Stack(); + // The task status of the last child ran. + private TaskStatus executionStatus = TaskStatus.Inactive; + + public override void OnAwake() + { + // If specified, use the seed provided. + if (useSeed) { + Random.InitState(seed); + } + + // Add the index of each child to a list to make the Fischer-Yates shuffle possible. + childIndexList.Clear(); + for (int i = 0; i < children.Count; ++i) { + childIndexList.Add(i); + } + } + + public override void OnStart() + { + // Randomize the indecies + ShuffleChilden(); + } + + public override int CurrentChildIndex() + { + // Peek will return the index at the top of the stack. + return childrenExecutionOrder.Peek(); + } + + public override bool CanExecute() + { + // Continue exectuion if no task has return success and indexes still exist on the stack. + return childrenExecutionOrder.Count > 0 && executionStatus != TaskStatus.Success; + } + + public override void OnChildExecuted(TaskStatus childStatus) + { + // Pop the top index from the stack and set the execution status. + if (childrenExecutionOrder.Count > 0) { + childrenExecutionOrder.Pop(); + } + executionStatus = childStatus; + } + + public override void OnConditionalAbort(int childIndex) + { + // Start from the beginning on an abort + childrenExecutionOrder.Clear(); + executionStatus = TaskStatus.Inactive; + ShuffleChilden(); + } + + public override void OnEnd() + { + // All of the children have run. Reset the variables back to their starting values. + executionStatus = TaskStatus.Inactive; + childrenExecutionOrder.Clear(); + } + + public override void OnReset() + { + // Reset the public properties back to their original values + seed = 0; + useSeed = false; + } + + private void ShuffleChilden() + { + // Use Fischer-Yates shuffle to randomize the child index order. + for (int i = childIndexList.Count; i > 0; --i) { + int j = Random.Range(0, i); + int index = childIndexList[j]; + childrenExecutionOrder.Push(index); + childIndexList[j] = childIndexList[i - 1]; + childIndexList[i - 1] = index; + } + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Composites/RandomSelector.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Composites/RandomSelector.cs.meta new file mode 100644 index 0000000..cb56d7b --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Composites/RandomSelector.cs.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: 4952cbfc1e77be24b99e34c9acffc2a0 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} diff --git a/Assets/Behavior Designer/Runtime/Tasks/Composites/RandomSequence.cs b/Assets/Behavior Designer/Runtime/Tasks/Composites/RandomSequence.cs new file mode 100644 index 0000000..87719fa --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Composites/RandomSequence.cs @@ -0,0 +1,102 @@ +using UnityEngine; +using System.Collections.Generic; + +namespace BehaviorDesigner.Runtime.Tasks +{ + [TaskDescription("Similar to the sequence task, the random sequence task will return success as soon as every child task returns success. " + + "The difference is that the random sequence class will run its children in a random order. The sequence task is deterministic " + + "in that it will always run the tasks from left to right within the tree. The random sequence task shuffles the child tasks up and then begins " + + "execution in a random order. Other than that the random sequence class is the same as the sequence class. It will stop running tasks " + + "as soon as a single task ends in failure. On a task failure it will stop executing all of the child tasks and return failure. " + + "If no child returns failure then it will return success.")] + [TaskIcon("{SkinColor}RandomSequenceIcon.png")] + public class RandomSequence : Composite + { + [Tooltip("Seed the random number generator to make things easier to debug")] + public int seed = 0; + [Tooltip("Do we want to use the seed?")] + public bool useSeed = false; + + // A list of indexes of every child task. This list is used by the Fischer-Yates shuffle algorithm. + private List childIndexList = new List(); + // The random child index execution order. + private Stack childrenExecutionOrder = new Stack(); + // The task status of the last child ran. + private TaskStatus executionStatus = TaskStatus.Inactive; + + public override void OnAwake() + { + // If specified, use the seed provided. + if (useSeed) { + Random.InitState(seed); + } + + // Add the index of each child to a list to make the Fischer-Yates shuffle possible. + childIndexList.Clear(); + for (int i = 0; i < children.Count; ++i) { + childIndexList.Add(i); + } + } + + public override void OnStart() + { + // Randomize the indecies + ShuffleChilden(); + } + + public override int CurrentChildIndex() + { + // Peek will return the index at the top of the stack. + return childrenExecutionOrder.Peek(); + } + + public override bool CanExecute() + { + // Continue exectuion if no task has return failure and indexes still exist on the stack. + return childrenExecutionOrder.Count > 0 && executionStatus != TaskStatus.Failure; + } + + public override void OnChildExecuted(TaskStatus childStatus) + { + // Pop the top index from the stack and set the execution status. + if (childrenExecutionOrder.Count > 0) { + childrenExecutionOrder.Pop(); + } + executionStatus = childStatus; + } + + public override void OnConditionalAbort(int childIndex) + { + // Start from the beginning on an abort + childrenExecutionOrder.Clear(); + executionStatus = TaskStatus.Inactive; + ShuffleChilden(); + } + + public override void OnEnd() + { + // All of the children have run. Reset the variables back to their starting values. + executionStatus = TaskStatus.Inactive; + childrenExecutionOrder.Clear(); + } + + public override void OnReset() + { + // Reset the public properties back to their original values + seed = 0; + useSeed = false; + } + + private void ShuffleChilden() + { + // Use Fischer-Yates shuffle to randomize the child index order. + for (int i = childIndexList.Count; i > 0; --i) { + int j = Random.Range(0, i); + int index = childIndexList[j]; + childrenExecutionOrder.Push(index); + childIndexList[j] = childIndexList[i - 1]; + childIndexList[i - 1] = index; + } + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Composites/RandomSequence.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Composites/RandomSequence.cs.meta new file mode 100644 index 0000000..01b0699 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Composites/RandomSequence.cs.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: 11b102c97eb687b4a9ce1473a334c3dd +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} diff --git a/Assets/Behavior Designer/Runtime/Tasks/Composites/Selector.cs b/Assets/Behavior Designer/Runtime/Tasks/Composites/Selector.cs new file mode 100644 index 0000000..025097b --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Composites/Selector.cs @@ -0,0 +1,45 @@ +namespace BehaviorDesigner.Runtime.Tasks +{ + [TaskDescription("The selector task is similar to an \"or\" operation. It will return success as soon as one of its child tasks return success. " + + "If a child task returns failure then it will sequentially run the next task. If no child task returns success then it will return failure.")] + [TaskIcon("{SkinColor}SelectorIcon.png")] + public class Selector : Composite + { + // The index of the child that is currently running or is about to run. + private int currentChildIndex = 0; + // The task status of the last child ran. + private TaskStatus executionStatus = TaskStatus.Inactive; + + public override int CurrentChildIndex() + { + return currentChildIndex; + } + + public override bool CanExecute() + { + // We can continue to execuate as long as we have children that haven't been executed and no child has returned success. + return currentChildIndex < children.Count && executionStatus != TaskStatus.Success; + } + + public override void OnChildExecuted(TaskStatus childStatus) + { + // Increase the child index and update the execution status after a child has finished running. + currentChildIndex++; + executionStatus = childStatus; + } + + public override void OnConditionalAbort(int childIndex) + { + // Set the current child index to the index that caused the abort + currentChildIndex = childIndex; + executionStatus = TaskStatus.Inactive; + } + + public override void OnEnd() + { + // All of the children have run. Reset the variables back to their starting values. + executionStatus = TaskStatus.Inactive; + currentChildIndex = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Composites/Selector.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Composites/Selector.cs.meta new file mode 100644 index 0000000..9142a26 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Composites/Selector.cs.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: 7cb8dcec14880a443841212e6b595d4f +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} diff --git a/Assets/Behavior Designer/Runtime/Tasks/Composites/SelectorEvaluator.cs b/Assets/Behavior Designer/Runtime/Tasks/Composites/SelectorEvaluator.cs new file mode 100644 index 0000000..eb3f64f --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Composites/SelectorEvaluator.cs @@ -0,0 +1,121 @@ +namespace BehaviorDesigner.Runtime.Tasks +{ + [TaskDescription("The selector evaluator is a selector task which reevaluates its children every tick. It will run the lowest priority child which returns a task status of running. " + + "This is done each tick. If a higher priority child is running and the next frame a lower priority child wants to run it will interrupt the higher priority child. " + + "The selector evaluator will return success as soon as the first child returns success otherwise it will keep trying higher priority children. This task mimics " + + "the conditional abort functionality except the child tasks don't always have to be conditional tasks.")] + [TaskIcon("{SkinColor}SelectorEvaluatorIcon.png")] + public class SelectorEvaluator : Composite + { + // The index of the child that is currently running or is about to run. + private int currentChildIndex = 0; + // The task status of the last child ran. + private TaskStatus executionStatus = TaskStatus.Inactive; + // The index of the child that was running before the tree started to be reevaluated. + private int storedCurrentChildIndex = -1; + // The task status of the last child ran before the tree started to be reevaluated. + private TaskStatus storedExecutionStatus = TaskStatus.Inactive; + + public override int CurrentChildIndex() + { + return currentChildIndex; + } + + public override void OnChildStarted(int childIndex) + { + // The children run sequentially so increment the index and set the status to running. + currentChildIndex++; + executionStatus = TaskStatus.Running; + } + + public override bool CanExecute() + { + // We can continue to execuate as long as we have children that haven't been executed and no child has returned success. + if (executionStatus == TaskStatus.Success || executionStatus == TaskStatus.Running) { + return false; + } + + // Used the storedCurrentChildIndex if reevaluating, otherwise the currentChildIndex + if (storedCurrentChildIndex != -1) { + return currentChildIndex < storedCurrentChildIndex - 1; + } + return currentChildIndex < children.Count; + } + + public override void OnChildExecuted(int childIndex, TaskStatus childStatus) + { + // A disabled task is the equivalent of the task failing for a selector evaluator. + if (childStatus == TaskStatus.Inactive && children[childIndex].Disabled) { + executionStatus = TaskStatus.Failure; + } + // The child status will be inactive immediately following an abort from OnReevaluationEnded. The status will be running if the + // child task is interrupted. Ignore the status for both of these. + if (childStatus != TaskStatus.Inactive && childStatus != TaskStatus.Running) { + executionStatus = childStatus; + } + } + + public override void OnConditionalAbort(int childIndex) + { + // Set the current child index to the index that caused the abort + currentChildIndex = childIndex; + executionStatus = TaskStatus.Inactive; + } + + public override void OnEnd() + { + // All of the children have run. Reset the variables back to their starting values. + executionStatus = TaskStatus.Inactive; + currentChildIndex = 0; + } + + public override TaskStatus OverrideStatus(TaskStatus status) + { + return executionStatus; + } + + // The selector evaluator task is a parallel task to allow the previous child to continue to run while the higher priority task is active. If the + // lower priority child can run then OnReevaluationEnded will interrupt the higher priority task. + public override bool CanRunParallelChildren() + { + return true; + } + + // Can reevaluate to allow the lower priority children the chance to rerun. + public override bool CanReevaluate() + { + return true; + } + + // The behavior tree wants to start reevaluating the tree. + public override bool OnReevaluationStarted() + { + // Cannot reevaluate if the task hasn't even started yet + if (executionStatus == TaskStatus.Inactive) { + return false; + } + + // Store the current index and execution status because it may need to be resumed. + storedCurrentChildIndex = currentChildIndex; + storedExecutionStatus = executionStatus; + currentChildIndex = 0; + executionStatus = TaskStatus.Inactive; + return true; + } + + // Reevaluation has ended. Determine if a task should be interrupted or resumed from the last index. + public override void OnReevaluationEnded(TaskStatus status) + { + // Interrupt the currently running index if a lower priority child returns a status of running or success. + if (executionStatus != TaskStatus.Failure && executionStatus != TaskStatus.Inactive) { + BehaviorManager.instance.Interrupt(Owner, children[storedCurrentChildIndex - 1], this, TaskStatus.Inactive); + } else { + // The lower priority children returned the same status so resume with the current child + currentChildIndex = storedCurrentChildIndex; + executionStatus = storedExecutionStatus; + } + storedCurrentChildIndex = -1; + storedExecutionStatus = TaskStatus.Inactive; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Composites/SelectorEvaluator.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Composites/SelectorEvaluator.cs.meta new file mode 100644 index 0000000..56bbd94 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Composites/SelectorEvaluator.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 15b5d0aafd7d4f04f8332d33705ebd63 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Composites/Sequence.cs b/Assets/Behavior Designer/Runtime/Tasks/Composites/Sequence.cs new file mode 100644 index 0000000..ff4e286 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Composites/Sequence.cs @@ -0,0 +1,45 @@ +namespace BehaviorDesigner.Runtime.Tasks +{ + [TaskDescription("The sequence task is similar to an \"and\" operation. It will return failure as soon as one of its child tasks return failure. " + + "If a child task returns success then it will sequentially run the next task. If all child tasks return success then it will return success.")] + [TaskIcon("{SkinColor}SequenceIcon.png")] + public class Sequence : Composite + { + // The index of the child that is currently running or is about to run. + private int currentChildIndex = 0; + // The task status of the last child ran. + private TaskStatus executionStatus = TaskStatus.Inactive; + + public override int CurrentChildIndex() + { + return currentChildIndex; + } + + public override bool CanExecute() + { + // We can continue to execuate as long as we have children that haven't been executed and no child has returned failure. + return currentChildIndex < children.Count && executionStatus != TaskStatus.Failure; + } + + public override void OnChildExecuted(TaskStatus childStatus) + { + // Increase the child index and update the execution status after a child has finished running. + currentChildIndex++; + executionStatus = childStatus; + } + + public override void OnConditionalAbort(int childIndex) + { + // Set the current child index to the index that caused the abort + currentChildIndex = childIndex; + executionStatus = TaskStatus.Inactive; + } + + public override void OnEnd() + { + // All of the children have run. Reset the variables back to their starting values. + executionStatus = TaskStatus.Inactive; + currentChildIndex = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Composites/Sequence.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Composites/Sequence.cs.meta new file mode 100644 index 0000000..eea9bec --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Composites/Sequence.cs.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: b7226608b64066c40a656d7260249fce +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} diff --git a/Assets/Behavior Designer/Runtime/Tasks/Composites/UtilitySelector.cs b/Assets/Behavior Designer/Runtime/Tasks/Composites/UtilitySelector.cs new file mode 100644 index 0000000..0273c9a --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Composites/UtilitySelector.cs @@ -0,0 +1,149 @@ +using System.Collections.Generic; + +namespace BehaviorDesigner.Runtime.Tasks +{ + [TaskDescription("The utility selector task evaluates the child tasks using Utility Theory AI. The child task can override the GetUtility method and return the utility value " + + "at that particular time. The task with the highest utility value will be selected and the existing running task will be aborted. The utility selector " + + "task reevaluates its children every tick.")] + [TaskIcon("{SkinColor}UtilitySelectorIcon.png")] + public class UtilitySelector : Composite + { + // The index of the child that is currently running or is about to run. + private int currentChildIndex = 0; + // The highest utility value + private float highestUtility; + // The task status of the last child ran. + private TaskStatus executionStatus = TaskStatus.Inactive; + // Is the task being reevaluated? + private bool reevaluating; + // A list of children that can execute. + private List availableChildren = new List(); + + public override void OnStart() + { + highestUtility = float.MinValue; + + // Loop through each child task and determine its utility. The task with the highest utility will run first. + availableChildren.Clear(); + for (int i = 0; i < children.Count; ++i) { + float utility = children[i].GetUtility(); + if (utility > highestUtility) { + highestUtility = utility; + currentChildIndex = i; + } + availableChildren.Add(i); + } + } + + public override int CurrentChildIndex() + { + // The currentChildIndex is the task with the highest utility. + return currentChildIndex; + } + + public override void OnChildStarted(int childIndex) + { + // The child has started - set the execution status. + executionStatus = TaskStatus.Running; + } + + public override bool CanExecute() + { + // Continue to execute new tasks until a task returns success or there are no more children left. If reevaluating then return false + // immediately because each task doesn't need to be reevaluted. + if (executionStatus == TaskStatus.Success || executionStatus == TaskStatus.Running || reevaluating) { + return false; + } + return availableChildren.Count > 0; + } + + public override void OnChildExecuted(int childIndex, TaskStatus childStatus) + { + // The child status will be inactive immediately following an abort from OnReevaluationEnded. The status will be running if the + // child task is interrupted. Ignore the status for both of these. + if (childStatus != TaskStatus.Inactive && childStatus != TaskStatus.Running) { + executionStatus = childStatus; + // If the execution status is failure then a new task needs to be selected. Remove the current task from the available children + // and select the next highest utility child. + if (executionStatus == TaskStatus.Failure) { + availableChildren.Remove(childIndex); + + highestUtility = float.MinValue; + for (int i = 0; i < availableChildren.Count; ++i) { + float utility = children[availableChildren[i]].GetUtility(); + if (utility > highestUtility) { + highestUtility = utility; + currentChildIndex = availableChildren[i]; + } + } + } + } + } + + public override void OnConditionalAbort(int childIndex) + { + // Set the current child index to the index that caused the abort + currentChildIndex = childIndex; + executionStatus = TaskStatus.Inactive; + } + + public override void OnEnd() + { + // All of the children have run. Reset the variables back to their starting values. + executionStatus = TaskStatus.Inactive; + currentChildIndex = 0; + } + + public override TaskStatus OverrideStatus(TaskStatus status) + { + return executionStatus; + } + + // The utility selector task is a parallel task to allow the task utility to be reevaluated. The higest utility task will always run. + public override bool CanRunParallelChildren() + { + return true; + } + + // Can reevaluate to allow the task utilities to be rerun. + public override bool CanReevaluate() + { + return true; + } + + // The behavior tree wants to start reevaluating the tree. + public override bool OnReevaluationStarted() + { + // Cannot reevaluate if the task hasn't even started yet + if (executionStatus == TaskStatus.Inactive) { + return false; + } + + reevaluating = true; + return true; + } + + // Determine if a task with a higher utility exists. + public override void OnReevaluationEnded(TaskStatus status) + { + reevaluating = false; + + // Loop through all of the available children and pick the task with the highest utility. + int prevChildIndex = currentChildIndex; + highestUtility = float.MinValue; + for (int i = 0; i < availableChildren.Count; ++i) { + float utility = children[availableChildren[i]].GetUtility(); + if (utility > highestUtility) { + highestUtility = utility; + currentChildIndex = availableChildren[i]; + } + } + + // If the index is different then the current child task should be aborted and the higher utility task should be run. + if (prevChildIndex != currentChildIndex) { + BehaviorManager.instance.Interrupt(Owner, children[prevChildIndex], this, TaskStatus.Failure); + executionStatus = TaskStatus.Inactive; + } + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Composites/UtilitySelector.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Composites/UtilitySelector.cs.meta new file mode 100644 index 0000000..1ba908d --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Composites/UtilitySelector.cs.meta @@ -0,0 +1,12 @@ +fileFormatVersion: 2 +guid: 1c21b01ca0aa9004fa3a76c9d596eeb1 +timeCreated: 1465679373 +licenseType: Store +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Conditionals.meta b/Assets/Behavior Designer/Runtime/Tasks/Conditionals.meta new file mode 100644 index 0000000..6c056f2 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Conditionals.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: dd959be462adfbc4a8878260547827cb +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Conditionals/HasReceivedEvent.cs b/Assets/Behavior Designer/Runtime/Tasks/Conditionals/HasReceivedEvent.cs new file mode 100644 index 0000000..ba1ef12 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Conditionals/HasReceivedEvent.cs @@ -0,0 +1,113 @@ +namespace BehaviorDesigner.Runtime.Tasks +{ + [TaskDescription("Returns success as soon as the event specified by eventName has been received.")] + [TaskIcon("{SkinColor}HasReceivedEventIcon.png")] + public class HasReceivedEvent : Conditional + { + [Tooltip("The name of the event to receive")] + public SharedString eventName = ""; + [Tooltip("Optionally store the first sent argument")] + [SharedRequired] + public SharedVariable storedValue1; + [Tooltip("Optionally store the second sent argument")] + [SharedRequired] + public SharedVariable storedValue2; + [Tooltip("Optionally store the third sent argument")] + [SharedRequired] + public SharedVariable storedValue3; + + private bool eventReceived = false; + private bool registered = false; + + public override void OnStart() + { + // Let the behavior tree know that we are interested in receiving the event specified + if (!registered) { + Owner.RegisterEvent(eventName.Value, ReceivedEvent); + Owner.RegisterEvent(eventName.Value, ReceivedEvent); + Owner.RegisterEvent(eventName.Value, ReceivedEvent); + Owner.RegisterEvent(eventName.Value, ReceivedEvent); + registered = true; + } + } + + public override TaskStatus OnUpdate() + { + return eventReceived ? TaskStatus.Success : TaskStatus.Failure; + } + + public override void OnEnd() + { + if (eventReceived) { + Owner.UnregisterEvent(eventName.Value, ReceivedEvent); + Owner.UnregisterEvent(eventName.Value, ReceivedEvent); + Owner.UnregisterEvent(eventName.Value, ReceivedEvent); + Owner.UnregisterEvent(eventName.Value, ReceivedEvent); + registered = false; + } + eventReceived = false; + } + + private void ReceivedEvent() + { + eventReceived = true; + } + + private void ReceivedEvent(object arg1) + { + ReceivedEvent(); + + if (storedValue1 != null && !storedValue1.IsNone) { + storedValue1.SetValue(arg1); + } + } + + private void ReceivedEvent(object arg1, object arg2) + { + ReceivedEvent(); + + if (storedValue1 != null && !storedValue1.IsNone) { + storedValue1.SetValue(arg1); + } + + if (storedValue2 != null && !storedValue2.IsNone) { + storedValue2.SetValue(arg2); + } + } + + private void ReceivedEvent(object arg1, object arg2, object arg3) + { + ReceivedEvent(); + + if (storedValue1 != null && !storedValue1.IsNone) { + storedValue1.SetValue(arg1); + } + + if (storedValue2 != null && !storedValue2.IsNone) { + storedValue2.SetValue(arg2); + } + + if (storedValue3 != null && !storedValue3.IsNone) { + storedValue3.SetValue(arg3); + } + } + + public override void OnBehaviorComplete() + { + // Stop receiving the event when the behavior tree is complete + Owner.UnregisterEvent(eventName.Value, ReceivedEvent); + Owner.UnregisterEvent(eventName.Value, ReceivedEvent); + Owner.UnregisterEvent(eventName.Value, ReceivedEvent); + Owner.UnregisterEvent(eventName.Value, ReceivedEvent); + + eventReceived = false; + registered = false; + } + + public override void OnReset() + { + // Reset the properties back to their original values + eventName = ""; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Conditionals/HasReceivedEvent.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Conditionals/HasReceivedEvent.cs.meta new file mode 100644 index 0000000..a663114 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Conditionals/HasReceivedEvent.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 7c0c7f545b074cb48bd552b038ede7af +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Conditionals/Physics.meta b/Assets/Behavior Designer/Runtime/Tasks/Conditionals/Physics.meta new file mode 100644 index 0000000..03fc8c3 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Conditionals/Physics.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: d5b2388776cf10a438e7a4357267c555 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Conditionals/Physics/HasEnteredCollision.cs b/Assets/Behavior Designer/Runtime/Tasks/Conditionals/Physics/HasEnteredCollision.cs new file mode 100644 index 0000000..f3c8ba7 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Conditionals/Physics/HasEnteredCollision.cs @@ -0,0 +1,40 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks +{ + [TaskDescription("Returns success when a collision starts. This task will only receive the physics callback if it is being reevaluated (with a conditional abort or under a parallel task).")] + [TaskCategory("Physics")] + public class HasEnteredCollision : Conditional + { + [Tooltip("The tag of the GameObject to check for a collision against")] + public SharedString tag = ""; + [Tooltip("The object that started the collision")] + public SharedGameObject collidedGameObject; + + private bool enteredCollision = false; + + public override TaskStatus OnUpdate() + { + return enteredCollision ? TaskStatus.Success : TaskStatus.Failure; + } + + public override void OnEnd() + { + enteredCollision = false; + } + + public override void OnCollisionEnter(Collision collision) + { + if (string.IsNullOrEmpty(tag.Value) || collision.gameObject.CompareTag(tag.Value)) { + collidedGameObject.Value = collision.gameObject; + enteredCollision = true; + } + } + + public override void OnReset() + { + tag = ""; + collidedGameObject = null; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Conditionals/Physics/HasEnteredCollision.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Conditionals/Physics/HasEnteredCollision.cs.meta new file mode 100644 index 0000000..c756d7a --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Conditionals/Physics/HasEnteredCollision.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: c1841a802d7ceda449423f001897ecae +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Conditionals/Physics/HasEnteredCollision2D.cs b/Assets/Behavior Designer/Runtime/Tasks/Conditionals/Physics/HasEnteredCollision2D.cs new file mode 100644 index 0000000..cff2872 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Conditionals/Physics/HasEnteredCollision2D.cs @@ -0,0 +1,40 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks +{ + [TaskDescription("Returns success when a 2D collision starts. This task will only receive the physics callback if it is being reevaluated (with a conditional abort or under a parallel task).")] + [TaskCategory("Physics")] + public class HasEnteredCollision2D : Conditional + { + [Tooltip("The tag of the GameObject to check for a collision against")] + public SharedString tag = ""; + [Tooltip("The object that started the collision")] + public SharedGameObject collidedGameObject; + + private bool enteredCollision = false; + + public override TaskStatus OnUpdate() + { + return enteredCollision ? TaskStatus.Success : TaskStatus.Failure; + } + + public override void OnEnd() + { + enteredCollision = false; + } + + public override void OnCollisionEnter2D(Collision2D collision) + { + if (string.IsNullOrEmpty(tag.Value) || collision.gameObject.CompareTag(tag.Value)) { + collidedGameObject.Value = collision.gameObject; + enteredCollision = true; + } + } + + public override void OnReset() + { + tag = ""; + collidedGameObject = null; + } + } +} diff --git a/Assets/Behavior Designer/Runtime/Tasks/Conditionals/Physics/HasEnteredCollision2D.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Conditionals/Physics/HasEnteredCollision2D.cs.meta new file mode 100644 index 0000000..4deddc6 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Conditionals/Physics/HasEnteredCollision2D.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 0ac128198630a2d4b9fee93cc9a1f8fd +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Conditionals/Physics/HasEnteredTrigger.cs b/Assets/Behavior Designer/Runtime/Tasks/Conditionals/Physics/HasEnteredTrigger.cs new file mode 100644 index 0000000..4ec2709 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Conditionals/Physics/HasEnteredTrigger.cs @@ -0,0 +1,40 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks +{ + [TaskDescription("Returns success when an object enters the trigger. This task will only receive the physics callback if it is being reevaluated (with a conditional abort or under a parallel task).")] + [TaskCategory("Physics")] + public class HasEnteredTrigger : Conditional + { + [Tooltip("The tag of the GameObject to check for a trigger against")] + public SharedString tag = ""; + [Tooltip("The object that entered the trigger")] + public SharedGameObject otherGameObject; + + private bool enteredTrigger = false; + + public override TaskStatus OnUpdate() + { + return enteredTrigger ? TaskStatus.Success : TaskStatus.Failure; + } + + public override void OnEnd() + { + enteredTrigger = false; + } + + public override void OnTriggerEnter(Collider other) + { + if (string.IsNullOrEmpty(tag.Value) || other.gameObject.CompareTag(tag.Value)) { + otherGameObject.Value = other.gameObject; + enteredTrigger = true; + } + } + + public override void OnReset() + { + tag = ""; + otherGameObject = null; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Conditionals/Physics/HasEnteredTrigger.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Conditionals/Physics/HasEnteredTrigger.cs.meta new file mode 100644 index 0000000..03153f3 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Conditionals/Physics/HasEnteredTrigger.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 5987844efe0fca7499cec04a9e3962cc +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Conditionals/Physics/HasEnteredTrigger2D.cs b/Assets/Behavior Designer/Runtime/Tasks/Conditionals/Physics/HasEnteredTrigger2D.cs new file mode 100644 index 0000000..9cfa1b1 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Conditionals/Physics/HasEnteredTrigger2D.cs @@ -0,0 +1,40 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks +{ + [TaskDescription("Returns success when an object enters the 2D trigger. This task will only receive the physics callback if it is being reevaluated (with a conditional abort or under a parallel task).")] + [TaskCategory("Physics")] + public class HasEnteredTrigger2D : Conditional + { + [Tooltip("The tag of the GameObject to check for a trigger against")] + public SharedString tag = ""; + [Tooltip("The object that entered the trigger")] + public SharedGameObject otherGameObject; + + private bool enteredTrigger = false; + + public override TaskStatus OnUpdate() + { + return enteredTrigger ? TaskStatus.Success : TaskStatus.Failure; + } + + public override void OnEnd() + { + enteredTrigger = false; + } + + public override void OnTriggerEnter2D(Collider2D other) + { + if (string.IsNullOrEmpty(tag.Value) || other.gameObject.CompareTag(tag.Value)) { + otherGameObject.Value = other.gameObject; + enteredTrigger = true; + } + } + + public override void OnReset() + { + tag = ""; + otherGameObject = null; + } + } +} diff --git a/Assets/Behavior Designer/Runtime/Tasks/Conditionals/Physics/HasEnteredTrigger2D.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Conditionals/Physics/HasEnteredTrigger2D.cs.meta new file mode 100644 index 0000000..9d0f038 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Conditionals/Physics/HasEnteredTrigger2D.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 84e2afb791fe67243a15e45e4af81bb4 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Conditionals/Physics/HasExitedCollision.cs b/Assets/Behavior Designer/Runtime/Tasks/Conditionals/Physics/HasExitedCollision.cs new file mode 100644 index 0000000..e561a02 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Conditionals/Physics/HasExitedCollision.cs @@ -0,0 +1,39 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks +{ + [TaskDescription("Returns success when a collision ends. This task will only receive the physics callback if it is being reevaluated (with a conditional abort or under a parallel task).")] + [TaskCategory("Physics")] + public class HasExitedCollision : Conditional + { + [Tooltip("The tag of the GameObject to check for a collision against")] + public SharedString tag = ""; + [Tooltip("The object that exited the collision")] + public SharedGameObject collidedGameObject; + + private bool exitedCollision = false; + + public override TaskStatus OnUpdate() + { + return exitedCollision ? TaskStatus.Success : TaskStatus.Failure; + } + + public override void OnEnd() + { + exitedCollision = false; + } + + public override void OnCollisionExit(Collision collision) + { + if (string.IsNullOrEmpty(tag.Value) || collision.gameObject.CompareTag(tag.Value)) { + collidedGameObject.Value = collision.gameObject; + exitedCollision = true; + } + } + + public override void OnReset() + { + collidedGameObject = null; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Conditionals/Physics/HasExitedCollision.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Conditionals/Physics/HasExitedCollision.cs.meta new file mode 100644 index 0000000..2041820 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Conditionals/Physics/HasExitedCollision.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 900905a3e42f74c49a6e503349ee651e +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Conditionals/Physics/HasExitedCollision2D.cs b/Assets/Behavior Designer/Runtime/Tasks/Conditionals/Physics/HasExitedCollision2D.cs new file mode 100644 index 0000000..50c6b8b --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Conditionals/Physics/HasExitedCollision2D.cs @@ -0,0 +1,40 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks +{ + [TaskDescription("Returns success when a 2D collision ends. This task will only receive the physics callback if it is being reevaluated (with a conditional abort or under a parallel task).")] + [TaskCategory("Physics")] + public class HasExitedCollision2D : Conditional + { + [Tooltip("The tag of the GameObject to check for a collision against")] + public SharedString tag = ""; + [Tooltip("The object that exited the collision")] + public SharedGameObject collidedGameObject; + + private bool exitedCollision = false; + + public override TaskStatus OnUpdate() + { + return exitedCollision ? TaskStatus.Success : TaskStatus.Failure; + } + + public override void OnEnd() + { + exitedCollision = false; + } + + public override void OnCollisionExit2D(Collision2D collision) + { + if (string.IsNullOrEmpty(tag.Value) || collision.gameObject.CompareTag(tag.Value)) { + collidedGameObject.Value = collision.gameObject; + exitedCollision = true; + } + } + + public override void OnReset() + { + tag = ""; + collidedGameObject = null; + } + } +} diff --git a/Assets/Behavior Designer/Runtime/Tasks/Conditionals/Physics/HasExitedCollision2D.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Conditionals/Physics/HasExitedCollision2D.cs.meta new file mode 100644 index 0000000..f506a12 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Conditionals/Physics/HasExitedCollision2D.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 31cf8edd114ac5c4db22ec65babb3dd3 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Conditionals/Physics/HasExitedTrigger.cs b/Assets/Behavior Designer/Runtime/Tasks/Conditionals/Physics/HasExitedTrigger.cs new file mode 100644 index 0000000..bd1d17b --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Conditionals/Physics/HasExitedTrigger.cs @@ -0,0 +1,40 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks +{ + [TaskDescription("Returns success when an object exits the trigger. This task will only receive the physics callback if it is being reevaluated (with a conditional abort or under a parallel task).")] + [TaskCategory("Physics")] + public class HasExitedTrigger : Conditional + { + [Tooltip("The tag of the GameObject to check for a trigger against")] + public SharedString tag = ""; + [Tooltip("The object that exited the trigger")] + public SharedGameObject otherGameObject; + + private bool exitedTrigger = false; + + public override TaskStatus OnUpdate() + { + return exitedTrigger ? TaskStatus.Success : TaskStatus.Failure; + } + + public override void OnEnd() + { + exitedTrigger = false; + } + + public override void OnTriggerExit(Collider other) + { + if (string.IsNullOrEmpty(tag.Value) || other.gameObject.CompareTag(tag.Value)) { + otherGameObject.Value = other.gameObject; + exitedTrigger = true; + } + } + + public override void OnReset() + { + tag = ""; + otherGameObject = null; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Conditionals/Physics/HasExitedTrigger.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Conditionals/Physics/HasExitedTrigger.cs.meta new file mode 100644 index 0000000..8d23602 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Conditionals/Physics/HasExitedTrigger.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: c7ccd4a2c35d4c748b65ccd086e777e1 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Conditionals/Physics/HasExitedTrigger2D.cs b/Assets/Behavior Designer/Runtime/Tasks/Conditionals/Physics/HasExitedTrigger2D.cs new file mode 100644 index 0000000..5cbf549 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Conditionals/Physics/HasExitedTrigger2D.cs @@ -0,0 +1,40 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks +{ + [TaskDescription("Returns success when an object exits the 2D trigger. This task will only receive the physics callback if it is being reevaluated (with a conditional abort or under a parallel task).")] + [TaskCategory("Physics")] + public class HasExitedTrigger2D : Conditional + { + [Tooltip("The tag of the GameObject to check for a trigger against")] + public SharedString tag = ""; + [Tooltip("The object that exited the trigger")] + public SharedGameObject otherGameObject; + + private bool exitedTrigger = false; + + public override TaskStatus OnUpdate() + { + return exitedTrigger ? TaskStatus.Success : TaskStatus.Failure; + } + + public override void OnEnd() + { + exitedTrigger = false; + } + + public override void OnTriggerExit2D(Collider2D other) + { + if (string.IsNullOrEmpty(tag.Value) || other.gameObject.CompareTag(tag.Value)) { + otherGameObject.Value = other.gameObject; + exitedTrigger = true; + } + } + + public override void OnReset() + { + tag = ""; + otherGameObject = null; + } + } +} diff --git a/Assets/Behavior Designer/Runtime/Tasks/Conditionals/Physics/HasExitedTrigger2D.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Conditionals/Physics/HasExitedTrigger2D.cs.meta new file mode 100644 index 0000000..18f0b42 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Conditionals/Physics/HasExitedTrigger2D.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: ff0486d46da2f7844ac74c6e2ad5af89 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Conditionals/RandomProbability.cs b/Assets/Behavior Designer/Runtime/Tasks/Conditionals/RandomProbability.cs new file mode 100644 index 0000000..1280677 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Conditionals/RandomProbability.cs @@ -0,0 +1,41 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks +{ + [TaskDescription("The random probability task will return success when the random probability is below the succeed probability. It will otherwise return failure.")] + public class RandomProbability : Conditional + { + [Tooltip("The chance that the task will return success")] + public SharedFloat successProbability = 0.5f; + [Tooltip("Seed the random number generator to make things easier to debug")] + public SharedInt seed; + [Tooltip("Do we want to use the seed?")] + public SharedBool useSeed; + + public override void OnAwake() + { + // If specified, use the seed provided. + if (useSeed.Value) { + Random.InitState(seed.Value); + } + } + + public override TaskStatus OnUpdate() + { + // Return success if random value is less than the success probability. Otherwise return failure. + float randomValue = Random.value; + if (randomValue < successProbability.Value) { + return TaskStatus.Success; + } + return TaskStatus.Failure; + } + + public override void OnReset() + { + // Reset the public properties back to their original values + successProbability = 0.5f; + seed = 0; + useSeed = false; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Conditionals/RandomProbability.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Conditionals/RandomProbability.cs.meta new file mode 100644 index 0000000..e4c3ed3 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Conditionals/RandomProbability.cs.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: 468a21510e9558c49a47238ebe4c2270 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} diff --git a/Assets/Behavior Designer/Runtime/Tasks/Conditionals/Reflection.meta b/Assets/Behavior Designer/Runtime/Tasks/Conditionals/Reflection.meta new file mode 100644 index 0000000..2ea3326 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Conditionals/Reflection.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 1fb2ec5c5ded45443834596a451000f9 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Conditionals/Reflection/CompareFieldValue.cs b/Assets/Behavior Designer/Runtime/Tasks/Conditionals/Reflection/CompareFieldValue.cs new file mode 100644 index 0000000..1f02811 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Conditionals/Reflection/CompareFieldValue.cs @@ -0,0 +1,60 @@ +using UnityEngine; +using System; +using System.Reflection; + +namespace BehaviorDesigner.Runtime.Tasks +{ + [TaskDescription("Compares the field value to the value specified. Returns success if the values are the same.")] + [TaskCategory("Reflection")] + [TaskIcon("{SkinColor}ReflectionIcon.png")] + public class CompareFieldValue : Conditional + { + [Tooltip("The GameObject to compare the field on")] + public SharedGameObject targetGameObject; + [Tooltip("The component to compare the field on")] + public SharedString componentName; + [Tooltip("The name of the field")] + public SharedString fieldName; + [Tooltip("The value to compare to")] + public SharedVariable compareValue; + + public override TaskStatus OnUpdate() + { + if (compareValue == null) { + Debug.LogWarning("Unable to compare field - compare value is null"); + return TaskStatus.Failure; + } + + var type = TaskUtility.GetTypeWithinAssembly(componentName.Value); + if (type == null) { + Debug.LogWarning("Unable to compare field - type is null"); + return TaskStatus.Failure; + } + + var component = GetDefaultGameObject(targetGameObject.Value).GetComponent(type); + if (component == null) { + Debug.LogWarning("Unable to compare the field with component " + componentName.Value); + return TaskStatus.Failure; + } + + // If you are receiving a compiler error on the Windows Store platform see this topic: + // https://www.opsive.com/support/documentation/behavior-designer/installation/ + var field = component.GetType().GetField(fieldName.Value); + var fieldValue = field.GetValue(component); + + if (fieldValue == null && compareValue.GetValue() == null) { + return TaskStatus.Success; + } + + return fieldValue.Equals(compareValue.GetValue()) ? TaskStatus.Success : TaskStatus.Failure; + } + + public override void OnReset() + { + targetGameObject = null; + componentName = null; + fieldName = null; + compareValue = null; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Conditionals/Reflection/CompareFieldValue.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Conditionals/Reflection/CompareFieldValue.cs.meta new file mode 100644 index 0000000..4daf721 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Conditionals/Reflection/CompareFieldValue.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: cc6496fb6757b684c8cc0c4ac8929319 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Conditionals/Reflection/ComparePropertyValue.cs b/Assets/Behavior Designer/Runtime/Tasks/Conditionals/Reflection/ComparePropertyValue.cs new file mode 100644 index 0000000..a72d0d0 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Conditionals/Reflection/ComparePropertyValue.cs @@ -0,0 +1,58 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks +{ + [TaskDescription("Compares the property value to the value specified. Returns success if the values are the same.")] + [TaskCategory("Reflection")] + [TaskIcon("{SkinColor}ReflectionIcon.png")] + public class ComparePropertyValue : Conditional + { + [Tooltip("The GameObject to compare the property of")] + public SharedGameObject targetGameObject; + [Tooltip("The component to compare the property of")] + public SharedString componentName; + [Tooltip("The name of the property")] + public SharedString propertyName; + [Tooltip("The value to compare to")] + public SharedVariable compareValue; + + public override TaskStatus OnUpdate() + { + if (compareValue == null) { + Debug.LogWarning("Unable to compare field - compare value is null"); + return TaskStatus.Failure; + } + + var type = TaskUtility.GetTypeWithinAssembly(componentName.Value); + if (type == null) { + Debug.LogWarning("Unable to compare property - type is null"); + return TaskStatus.Failure; + } + + var component = GetDefaultGameObject(targetGameObject.Value).GetComponent(type); + if (component == null) { + Debug.LogWarning("Unable to compare the property with component " + componentName.Value); + return TaskStatus.Failure; + } + + // If you are receiving a compiler error on the Windows Store platform see this topic: + // https://www.opsive.com/support/documentation/behavior-designer/installation/ + var property = component.GetType().GetProperty(propertyName.Value); + var propertyValue = property.GetValue(component, null); + + if (propertyValue == null && compareValue.GetValue() == null) { + return TaskStatus.Success; + } + + return propertyValue.Equals(compareValue.GetValue()) ? TaskStatus.Success : TaskStatus.Failure; + } + + public override void OnReset() + { + targetGameObject = null; + componentName = null; + propertyName = null; + compareValue = null; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Conditionals/Reflection/ComparePropertyValue.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Conditionals/Reflection/ComparePropertyValue.cs.meta new file mode 100644 index 0000000..d858e0a --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Conditionals/Reflection/ComparePropertyValue.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: f8b0fa403f826a74087ece4b81fec1c7 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Conditionals/StackedConditional.cs b/Assets/Behavior Designer/Runtime/Tasks/Conditionals/StackedConditional.cs new file mode 100644 index 0000000..24b9ff0 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Conditionals/StackedConditional.cs @@ -0,0 +1,266 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks +{ + [TaskDescription("Allows multiple conditional tasks to be added to a single node.")] + [TaskIcon("{SkinColor}StackedConditionalIcon.png")] + public class StackedConditional : Conditional + { + [InspectTask] + public Conditional[] conditionals; + public enum ComparisonType + { + Sequence, + Selector + } + [Tooltip("Specifies if the tasks should be traversed with an AND (Sequence) or an OR (Selector).")] + public ComparisonType comparisonType; + [Tooltip("Should the tasks be labeled within the graph?")] + public bool graphLabel; + + public override void OnAwake() + { + if (conditionals == null) { + return; + } + + for (int i = 0; i < conditionals.Length; ++i) { + if (conditionals[i] == null) { + continue; + } + + conditionals[i].GameObject = gameObject; + conditionals[i].Transform = transform; + conditionals[i].Owner = Owner; + conditionals[i].NodeData = new NodeData(); + conditionals[i].OnAwake(); + } + } + + public override void OnStart() + { + if (conditionals == null) { + return; + } + + for (int i = 0; i < conditionals.Length; ++i) { + if (conditionals[i] == null) { + continue; + } + conditionals[i].OnStart(); + } + } + + public override TaskStatus OnUpdate() + { + if (conditionals == null) { + return TaskStatus.Failure; + } + + for (int i = 0; i < conditionals.Length; ++i) { + if (conditionals[i] == null) { + continue; + } + conditionals[i].NodeData.ExecutionStatus = conditionals[i].OnUpdate(); + if (conditionals[i].NodeData.ExecutionStatus == TaskStatus.Running) { + Debug.LogWarning("Warning: The conditional task returned a status of running when conditional tasks should only return success or failure."); + } + + if (comparisonType == ComparisonType.Sequence && conditionals[i].NodeData.ExecutionStatus == TaskStatus.Failure) { + return TaskStatus.Failure; + } else if (comparisonType == ComparisonType.Selector && conditionals[i].NodeData.ExecutionStatus == TaskStatus.Success) { + return TaskStatus.Success; + } + } + return comparisonType == ComparisonType.Sequence ? TaskStatus.Success : TaskStatus.Failure; + } + + public override void OnFixedUpdate() + { + if (conditionals == null) { + return; + } + + for (int i = 0; i < conditionals.Length; ++i) { + if (conditionals[i] == null) { + continue; + } + conditionals[i].OnFixedUpdate(); + } + } + + public override void OnLateUpdate() + { + if (conditionals == null) { + return; + } + + for (int i = 0; i < conditionals.Length; ++i) { + if (conditionals[i] == null) { + continue; + } + conditionals[i].OnLateUpdate(); + } + } + + public override void OnEnd() + { + if (conditionals == null) { + return; + } + + for (int i = 0; i < conditionals.Length; ++i) { + if (conditionals[i] == null) { + continue; + } + conditionals[i].OnEnd(); + } + } + + public override void OnTriggerEnter(Collider other) + { + if (conditionals == null) { + return; + } + + for (int i = 0; i < conditionals.Length; ++i) { + if (conditionals[i] == null) { + continue; + } + conditionals[i].OnTriggerEnter(other); + } + } + + public override void OnTriggerEnter2D(Collider2D other) + { + if (conditionals == null) { + return; + } + + for (int i = 0; i < conditionals.Length; ++i) { + if (conditionals[i] == null) { + continue; + } + conditionals[i].OnTriggerEnter2D(other); + } + } + + public override void OnTriggerExit(Collider other) + { + if (conditionals == null) { + return; + } + + for (int i = 0; i < conditionals.Length; ++i) { + if (conditionals[i] == null) { + continue; + } + conditionals[i].OnTriggerExit(other); + } + } + + public override void OnTriggerExit2D(Collider2D other) + { + if (conditionals == null) { + return; + } + + for (int i = 0; i < conditionals.Length; ++i) { + if (conditionals[i] == null) { + continue; + } + conditionals[i].OnTriggerExit2D(other); + } + } + + public override void OnCollisionEnter(Collision collision) + { + if (conditionals == null) { + return; + } + + for (int i = 0; i < conditionals.Length; ++i) { + if (conditionals[i] == null) { + continue; + } + conditionals[i].OnCollisionEnter(collision); + } + } + + public override void OnCollisionEnter2D(Collision2D collision) + { + if (conditionals == null) { + return; + } + + for (int i = 0; i < conditionals.Length; ++i) { + if (conditionals[i] == null) { + continue; + } + conditionals[i].OnCollisionEnter2D(collision); + } + } + + public override void OnCollisionExit(Collision collision) + { + if (conditionals == null) { + return; + } + + for (int i = 0; i < conditionals.Length; ++i) { + if (conditionals[i] == null) { + continue; + } + conditionals[i].OnCollisionExit(collision); + } + } + + public override void OnCollisionExit2D(Collision2D collision) + { + if (conditionals == null) { + return; + } + + for (int i = 0; i < conditionals.Length; ++i) { + if (conditionals[i] == null) { + continue; + } + conditionals[i].OnCollisionExit2D(collision); + } + } + + public override string OnDrawNodeText() + { + if (conditionals == null || !graphLabel) { + return string.Empty; + } + + var text = string.Empty; + for (int i = 0; i < conditionals.Length; ++i) { + if (conditionals[i] == null) { + continue; + } + if (!string.IsNullOrEmpty(text)) { + text += "\n"; + } + text += conditionals[i].GetType().Name; + } + + return text; + } + + public override void OnReset() + { + if (conditionals == null) { + return; + } + + for (int i = 0; i < conditionals.Length; ++i) { + if (conditionals[i] == null) { + continue; + } + conditionals[i].OnReset(); + } + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Conditionals/StackedConditional.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Conditionals/StackedConditional.cs.meta new file mode 100644 index 0000000..c64a829 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Conditionals/StackedConditional.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 931664f35b02f4f438964c2f7eb4a8ae +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Decorators.meta b/Assets/Behavior Designer/Runtime/Tasks/Decorators.meta new file mode 100644 index 0000000..9961e5b --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Decorators.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: c3a63466abc2809449aec6088f9153e6 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Decorators/ConditionalEvaluator.cs b/Assets/Behavior Designer/Runtime/Tasks/Decorators/ConditionalEvaluator.cs new file mode 100644 index 0000000..46d78c0 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Decorators/ConditionalEvaluator.cs @@ -0,0 +1,110 @@ +namespace BehaviorDesigner.Runtime.Tasks +{ + [TaskDescription("Evaluates the specified conditional task. If the conditional task returns success then the child task is run and the child status is returned. If the conditional task does not " + + "return success then the child task is not run and a failure status is immediately returned.")] + [TaskIcon("{SkinColor}ConditionalEvaluatorIcon.png")] + public class ConditionalEvaluator : Decorator + { + [Tooltip("Should the conditional task be reevaluated every tick?")] + public SharedBool reevaluate; + [InspectTask] + [Tooltip("The conditional task to evaluate")] + public Conditional conditionalTask; + [Tooltip("Should the inspected conditional task be labeled within the graph?")] + public bool graphLabel; + + // The status of the child after it has finished running. + private TaskStatus executionStatus = TaskStatus.Inactive; + private bool checkConditionalTask = true; + private bool conditionalTaskFailed = false; + + public override void OnAwake() + { + if (conditionalTask != null) { + conditionalTask.Owner = Owner; + conditionalTask.GameObject = gameObject; + conditionalTask.Transform = transform; + conditionalTask.OnAwake(); + } + } + + public override void OnStart() + { + if (conditionalTask != null) { + conditionalTask.OnStart(); + } + } + + public override bool CanExecute() + { + // CanExecute is called when checking the condition within a while loop so it will be called at least twice. Ensure the conditional task is checked only once + if (checkConditionalTask) { + checkConditionalTask = false; + OnUpdate(); + } + + if (conditionalTaskFailed) { + return false; + } + return executionStatus == TaskStatus.Inactive || executionStatus == TaskStatus.Running; + } + + public override bool CanReevaluate() + { + return reevaluate.Value; + } + + public override TaskStatus OnUpdate() + { + var childStatus = conditionalTask.OnUpdate(); + conditionalTaskFailed = conditionalTask == null || childStatus == TaskStatus.Failure; + return childStatus; + } + + public override void OnChildExecuted(TaskStatus childStatus) + { + // Update the execution status after a child has finished running. + executionStatus = childStatus; + } + + public override TaskStatus OverrideStatus() + { + // This version of OverrideStatus is called when the conditional evaluator fails reevaluation and has to stop all of its children. + // Therefore, the return status will always be failure + return TaskStatus.Failure; + } + + public override TaskStatus OverrideStatus(TaskStatus status) + { + if (conditionalTaskFailed) + return TaskStatus.Failure; + return status; + } + + public override void OnEnd() + { + // Reset the variables back to their starting values. + executionStatus = TaskStatus.Inactive; + checkConditionalTask = true; + conditionalTaskFailed = false; + if (conditionalTask != null) { + conditionalTask.OnEnd(); + } + } + + public override string OnDrawNodeText() + { + if (conditionalTask == null || !graphLabel) { + return string.Empty; + } + + return conditionalTask.GetType().Name; + } + + public override void OnReset() + { + // Reset the public properties back to their original values. + conditionalTask = null; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Decorators/ConditionalEvaluator.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Decorators/ConditionalEvaluator.cs.meta new file mode 100644 index 0000000..52a457f --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Decorators/ConditionalEvaluator.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 632578e05169d1d45a1ab77ae8bb45ad +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Decorators/Cooldown.cs b/Assets/Behavior Designer/Runtime/Tasks/Decorators/Cooldown.cs new file mode 100644 index 0000000..e47611d --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Decorators/Cooldown.cs @@ -0,0 +1,63 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks +{ + [TaskDescription("Waits the specified duration after the child has completed before returning the child's status of success or failure.")] + [TaskIcon("{SkinColor}CooldownIcon.png")] + public class Cooldown : Decorator + { + public SharedFloat duration = 2; + + // The status of the child after it has finished running. + private TaskStatus executionStatus = TaskStatus.Inactive; + private float cooldownTime = -1; + + public override bool CanExecute() + { + if (cooldownTime == -1) { + return true; + } + + return cooldownTime + duration.Value > Time.time; + } + + public override int CurrentChildIndex() + { + if (cooldownTime == -1) { + return 0; + } + return -1; + } + + public override void OnChildExecuted(TaskStatus childStatus) + { + executionStatus = childStatus; + if (executionStatus == TaskStatus.Failure || executionStatus == TaskStatus.Success) { + cooldownTime = Time.time; + } + } + + public override TaskStatus OverrideStatus() + { + if (!CanExecute()) { + return TaskStatus.Running; + } + return executionStatus; + } + + public override TaskStatus OverrideStatus(TaskStatus status) + { + if (status == TaskStatus.Running) { + return status; + } + return executionStatus; + } + + public override void OnEnd() + { + // Reset the execution status back to its starting values. + executionStatus = TaskStatus.Inactive; + cooldownTime = -1; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Decorators/Cooldown.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Decorators/Cooldown.cs.meta new file mode 100644 index 0000000..00513a7 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Decorators/Cooldown.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 23da28bae244a1b408d0104cd78706d5 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Decorators/Interrupt.cs b/Assets/Behavior Designer/Runtime/Tasks/Decorators/Interrupt.cs new file mode 100644 index 0000000..be356f3 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Decorators/Interrupt.cs @@ -0,0 +1,48 @@ +namespace BehaviorDesigner.Runtime.Tasks +{ + [TaskDescription("The interrupt task will stop all child tasks from running if it is interrupted. The interruption can be triggered by the perform interruption task. " + + "The interrupt task will keep running its child until this interruption is called. If no interruption happens and the child task completed its " + + "execution the interrupt task will return the value assigned by the child task.")] + [TaskIcon("{SkinColor}InterruptIcon.png")] + public class Interrupt : Decorator + { + // When an interruption occurs return with this status. + private TaskStatus interruptStatus = TaskStatus.Failure; + // The status of the child after it has finished running. + private TaskStatus executionStatus = TaskStatus.Inactive; + + public override bool CanExecute() + { + // Continue executing until the child task returns success or failure. + return executionStatus == TaskStatus.Inactive || executionStatus == TaskStatus.Running; + } + + public override void OnChildExecuted(TaskStatus childStatus) + { + // Update the execution status after a child has finished running. + executionStatus = childStatus; + } + + public void DoInterrupt(TaskStatus status) + { + // An interruption has occurred. Update the interrupt status and notify the Behavior Manager. The Behavior Manager will stop all + // child tasks from running. + interruptStatus = status; + + BehaviorManager.instance.Interrupt(Owner, this, status); + } + + public override TaskStatus OverrideStatus() + { + // Return the interruption status as our status. + return interruptStatus; + } + + public override void OnEnd() + { + // Reset the variables back to their starting values. + interruptStatus = TaskStatus.Failure; + executionStatus = TaskStatus.Inactive; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Decorators/Interrupt.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Decorators/Interrupt.cs.meta new file mode 100644 index 0000000..5cde06f --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Decorators/Interrupt.cs.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: 81c44aaaa87500145831c0e167a5bfd3 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} diff --git a/Assets/Behavior Designer/Runtime/Tasks/Decorators/Inverter.cs b/Assets/Behavior Designer/Runtime/Tasks/Decorators/Inverter.cs new file mode 100644 index 0000000..707138f --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Decorators/Inverter.cs @@ -0,0 +1,40 @@ +namespace BehaviorDesigner.Runtime.Tasks +{ + [TaskDescription("The inverter task will invert the return value of the child task after it has finished executing. " + + "If the child returns success, the inverter task will return failure. If the child returns failure, the inverter task will return success.")] + [TaskIcon("{SkinColor}InverterIcon.png")] + public class Inverter : Decorator + { + // The status of the child after it has finished running. + private TaskStatus executionStatus = TaskStatus.Inactive; + + public override bool CanExecute() + { + // Continue executing until the child task returns success or failure. + return executionStatus == TaskStatus.Inactive || executionStatus == TaskStatus.Running; + } + + public override void OnChildExecuted(TaskStatus childStatus) + { + // Update the execution status after a child has finished running. + executionStatus = childStatus; + } + + public override TaskStatus Decorate(TaskStatus status) + { + // Invert the task status. + if (status == TaskStatus.Success) { + return TaskStatus.Failure; + } else if (status == TaskStatus.Failure) { + return TaskStatus.Success; + } + return status; + } + + public override void OnEnd() + { + // Reset the execution status back to its starting values. + executionStatus = TaskStatus.Inactive; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Decorators/Inverter.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Decorators/Inverter.cs.meta new file mode 100644 index 0000000..be3f1a5 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Decorators/Inverter.cs.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: 577fcf144ebc85642889f2dd11147272 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} diff --git a/Assets/Behavior Designer/Runtime/Tasks/Decorators/Repeater.cs b/Assets/Behavior Designer/Runtime/Tasks/Decorators/Repeater.cs new file mode 100644 index 0000000..a4daa39 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Decorators/Repeater.cs @@ -0,0 +1,47 @@ +namespace BehaviorDesigner.Runtime.Tasks +{ + [TaskDescription(@"The repeater task will repeat execution of its child task until the child task has been run a specified number of times. " + + "It has the option of continuing to execute the child task even if the child task returns a failure.")] + [TaskIcon("{SkinColor}RepeaterIcon.png")] + public class Repeater : Decorator + { + [Tooltip("The number of times to repeat the execution of its child task")] + public SharedInt count = 1; + [Tooltip("Allows the repeater to repeat forever")] + public SharedBool repeatForever; + [Tooltip("Should the task return if the child task returns a failure")] + public SharedBool endOnFailure; + + // The number of times the child task has been run. + private int executionCount = 0; + // The status of the child after it has finished running. + private TaskStatus executionStatus = TaskStatus.Inactive; + + public override bool CanExecute() + { + // Continue executing until we've reached the count or the child task returned failure and we should stop on a failure. + return (repeatForever.Value || executionCount < count.Value) && (!endOnFailure.Value || (endOnFailure.Value && executionStatus != TaskStatus.Failure)); + } + + public override void OnChildExecuted(TaskStatus childStatus) + { + // The child task has finished execution. Increase the execution count and update the execution status. + executionCount++; + executionStatus = childStatus; + } + + public override void OnEnd() + { + // Reset the variables back to their starting values. + executionCount = 0; + executionStatus = TaskStatus.Inactive; + } + + public override void OnReset() + { + // Reset the public properties back to their original values. + count = 0; + endOnFailure = true; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Decorators/Repeater.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Decorators/Repeater.cs.meta new file mode 100644 index 0000000..420a251 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Decorators/Repeater.cs.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: e62515fa6915f0d4f88b808e2e77d3ff +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} diff --git a/Assets/Behavior Designer/Runtime/Tasks/Decorators/ReturnFailure.cs b/Assets/Behavior Designer/Runtime/Tasks/Decorators/ReturnFailure.cs new file mode 100644 index 0000000..98cd7b1 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Decorators/ReturnFailure.cs @@ -0,0 +1,37 @@ +namespace BehaviorDesigner.Runtime.Tasks +{ + [TaskDescription("The return failure task will always return failure except when the child task is running.")] + [TaskIcon("{SkinColor}ReturnFailureIcon.png")] + public class ReturnFailure : Decorator + { + // The status of the child after it has finished running. + private TaskStatus executionStatus = TaskStatus.Inactive; + + public override bool CanExecute() + { + // Continue executing until the child task returns success or failure. + return executionStatus == TaskStatus.Inactive || executionStatus == TaskStatus.Running; + } + + public override void OnChildExecuted(TaskStatus childStatus) + { + // Update the execution status after a child has finished running. + executionStatus = childStatus; + } + + public override TaskStatus Decorate(TaskStatus status) + { + // Return failure even if the child task returned success. + if (status == TaskStatus.Success) { + return TaskStatus.Failure; + } + return status; + } + + public override void OnEnd() + { + // Reset the execution status back to its starting values. + executionStatus = TaskStatus.Inactive; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Decorators/ReturnFailure.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Decorators/ReturnFailure.cs.meta new file mode 100644 index 0000000..798bfa0 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Decorators/ReturnFailure.cs.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: f34d21f1bb4e761478bdf76222fcf135 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} diff --git a/Assets/Behavior Designer/Runtime/Tasks/Decorators/ReturnSuccess.cs b/Assets/Behavior Designer/Runtime/Tasks/Decorators/ReturnSuccess.cs new file mode 100644 index 0000000..67eb0ea --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Decorators/ReturnSuccess.cs @@ -0,0 +1,37 @@ +namespace BehaviorDesigner.Runtime.Tasks +{ + [TaskDescription("The return success task will always return success except when the child task is running.")] + [TaskIcon("{SkinColor}ReturnSuccessIcon.png")] + public class ReturnSuccess : Decorator + { + // The status of the child after it has finished running. + private TaskStatus executionStatus = TaskStatus.Inactive; + + public override bool CanExecute() + { + // Continue executing until the child task returns success or failure. + return executionStatus == TaskStatus.Inactive || executionStatus == TaskStatus.Running; + } + + public override void OnChildExecuted(TaskStatus childStatus) + { + // Update the execution status after a child has finished running. + executionStatus = childStatus; + } + + public override TaskStatus Decorate(TaskStatus status) + { + // Return success even if the child task returned failure. + if (status == TaskStatus.Failure) { + return TaskStatus.Success; + } + return status; + } + + public override void OnEnd() + { + // Reset the execution status back to its starting values. + executionStatus = TaskStatus.Inactive; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Decorators/ReturnSuccess.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Decorators/ReturnSuccess.cs.meta new file mode 100644 index 0000000..5056d2f --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Decorators/ReturnSuccess.cs.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: 27d103b9f961fd44da3c4d83dadd90ca +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} diff --git a/Assets/Behavior Designer/Runtime/Tasks/Decorators/TaskGuard.cs b/Assets/Behavior Designer/Runtime/Tasks/Decorators/TaskGuard.cs new file mode 100644 index 0000000..e234873 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Decorators/TaskGuard.cs @@ -0,0 +1,76 @@ +namespace BehaviorDesigner.Runtime.Tasks +{ + [TaskDescription("The task guard task is similar to a semaphore in multithreaded programming. The task guard task is there to ensure a limited resource is not being overused. " + + "\n\nFor example, you may place a task guard above a task that plays an animation. Elsewhere within your behavior tree you may also have another task that plays a different " + + "animation but uses the same bones for that animation. Because of this you don't want that animation to play twice at the same time. Placing a task guard will let you " + + "specify how many times a particular task can be accessed at the same time.\n\nIn the previous animation task example you would specify an access count of 1. With this setup " + + "the animation task can be only controlled by one task at a time. If the first task is playing the animation and a second task wants to control the animation as well, it will " + + "either have to wait or skip over the task completely.")] + [TaskIcon("{SkinColor}TaskGuardIcon.png")] + public class TaskGuard : Decorator + { + [Tooltip("The number of times the child tasks can be accessed by parallel tasks at once")] + public SharedInt maxTaskAccessCount; + [Tooltip("The linked tasks that also guard a task. If the task guard is not linked against any other tasks it doesn't have much purpose. Marked as LinkedTask to " + + "ensure all tasks linked are linked to the same set of tasks")] + [LinkedTask] + public TaskGuard[] linkedTaskGuards = null; + [Tooltip("If true the task will wait until the child task is available. If false then any unavailable child tasks will be skipped over")] + public SharedBool waitUntilTaskAvailable; + + // The number of tasks that are currently using a particular task. + private int executingTasks = 0; + // True if the current task is executing. + private bool executing = false; + + public override bool CanExecute() + { + // The child task can execute if the number of executing tasks is less than the maximum number of tasks allowed. + return executingTasks < maxTaskAccessCount.Value && !executing; + } + + public override void OnChildStarted() + { + // The child task has started to run. Increase the executing tasks counter and notify all of the other linked tasks. + executingTasks++; + executing = true; + for (int i = 0; i < linkedTaskGuards.Length; ++i) { + linkedTaskGuards[i].taskExecuting(true); + } + } + + public override TaskStatus OverrideStatus(TaskStatus status) + { + // return a running status if the children are currently waiting for a task to become available + return (!executing && waitUntilTaskAvailable.Value) ? TaskStatus.Running : status; + } + + public void taskExecuting(bool increase) + { + // A linked task is currently executing a task that is being guarded. If the task just started executing then increase will be true and if it is ending then + // true will be false. + executingTasks += (increase ? 1 : -1); + } + + public override void OnEnd() + { + // The child task has been executed or skipped over. Only decrement the executing tasks count if the child task was being executed. Following that + // notify all of the linked tasks that we are done executing. + if (executing) { + executingTasks--; + for (int i = 0; i < linkedTaskGuards.Length; ++i) { + linkedTaskGuards[i].taskExecuting(false); + } + executing = false; + } + } + + public override void OnReset() + { + // Reset the public properties back to their original values + maxTaskAccessCount = null; + linkedTaskGuards = null; + waitUntilTaskAvailable = true; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Decorators/TaskGuard.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Decorators/TaskGuard.cs.meta new file mode 100644 index 0000000..3f53700 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Decorators/TaskGuard.cs.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: 7e2ae4ab352f20c41be106f92efc3b43 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} diff --git a/Assets/Behavior Designer/Runtime/Tasks/Decorators/UntilFailure.cs b/Assets/Behavior Designer/Runtime/Tasks/Decorators/UntilFailure.cs new file mode 100644 index 0000000..ff2cb15 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Decorators/UntilFailure.cs @@ -0,0 +1,28 @@ +namespace BehaviorDesigner.Runtime.Tasks +{ + [TaskDescription("The until failure task will keep executing its child task until the child task returns failure.")] + [TaskIcon("{SkinColor}UntilFailureIcon.png")] + public class UntilFailure : Decorator + { + // The status of the child after it has finished running. + private TaskStatus executionStatus = TaskStatus.Inactive; + + public override bool CanExecute() + { + // Keep running until the child task returns failure. + return executionStatus == TaskStatus.Success || executionStatus == TaskStatus.Inactive; + } + + public override void OnChildExecuted(TaskStatus childStatus) + { + // Update the execution status after a child has finished running. + executionStatus = childStatus; + } + + public override void OnEnd() + { + // Reset the execution status back to its starting values. + executionStatus = TaskStatus.Inactive; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Decorators/UntilFailure.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Decorators/UntilFailure.cs.meta new file mode 100644 index 0000000..f620b65 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Decorators/UntilFailure.cs.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: 934b87f8f563272469cd9a9b14046ae7 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} diff --git a/Assets/Behavior Designer/Runtime/Tasks/Decorators/UntilSuccess.cs b/Assets/Behavior Designer/Runtime/Tasks/Decorators/UntilSuccess.cs new file mode 100644 index 0000000..25b8ec8 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Decorators/UntilSuccess.cs @@ -0,0 +1,28 @@ +namespace BehaviorDesigner.Runtime.Tasks +{ + [TaskDescription("The until success task will keep executing its child task until the child task returns success.")] + [TaskIcon("{SkinColor}UntilSuccessIcon.png")] + public class UntilSuccess : Decorator + { + // The status of the child after it has finished running. + private TaskStatus executionStatus = TaskStatus.Inactive; + + public override bool CanExecute() + { + // Keep running until the child task returns success. + return executionStatus == TaskStatus.Failure || executionStatus == TaskStatus.Inactive; + } + + public override void OnChildExecuted(TaskStatus childStatus) + { + // Update the execution status after a child has finished running. + executionStatus = childStatus; + } + + public override void OnEnd() + { + // Reset the execution status back to its starting values. + executionStatus = TaskStatus.Inactive; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Decorators/UntilSuccess.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Decorators/UntilSuccess.cs.meta new file mode 100644 index 0000000..572bc12 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Decorators/UntilSuccess.cs.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: 6d5c2cbf6c58f6b419831477bde98317 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} diff --git a/Assets/Behavior Designer/Runtime/Tasks/EntryTask.cs b/Assets/Behavior Designer/Runtime/Tasks/EntryTask.cs new file mode 100644 index 0000000..b06ad59 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/EntryTask.cs @@ -0,0 +1,13 @@ +namespace BehaviorDesigner.Runtime.Tasks +{ + // The entry task is a task that is used for display purposes within Behavior Designer to indicate the root of the tree. It is not a real task and + // cannot be used within the behavior tree. + [TaskIcon("{SkinColor}EntryIcon.png")] + public class EntryTask : ParentTask + { + public override int MaxChildren() + { + return 1; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/EntryTask.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/EntryTask.cs.meta new file mode 100644 index 0000000..631150e --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/EntryTask.cs.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: 143ae0c3fc255864893a532a2571f3d9 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity.meta new file mode 100644 index 0000000..60a3c06 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity.meta @@ -0,0 +1,4 @@ +fileFormatVersion: 2 +guid: de0476b4548c1d4408860e4ee2dd9471 +DefaultImporter: + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Animation.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animation.meta new file mode 100644 index 0000000..6479b90 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animation.meta @@ -0,0 +1,4 @@ +fileFormatVersion: 2 +guid: fa1395121fbad8b40934c69350e58065 +DefaultImporter: + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Animation/Blend.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animation/Blend.cs new file mode 100644 index 0000000..a8409f8 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animation/Blend.cs @@ -0,0 +1,51 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityAnimation +{ + [TaskCategory("Unity/Animation")] + [TaskDescription("Blends the animation. Returns Success.")] + public class Blend : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The name of the animation")] + public SharedString animationName; + [Tooltip("The weight the animation should blend to")] + public float targetWeight = 1; + [Tooltip("The amount of time it takes to blend")] + public float fadeLength = 0.3f; + + // cache the animation component + private Animation animation; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + animation = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (animation == null) { + Debug.LogWarning("Animation is null"); + return TaskStatus.Failure; + } + + animation.Blend(animationName.Value, targetWeight, fadeLength); + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + animationName = ""; + targetWeight = 1; + fadeLength = 0.3f; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Animation/Blend.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animation/Blend.cs.meta new file mode 100644 index 0000000..87e27a2 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animation/Blend.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: dc0640154eb6b674e89f4a2ec1632696 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Animation/CrossFade.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animation/CrossFade.cs new file mode 100644 index 0000000..fb13abd --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animation/CrossFade.cs @@ -0,0 +1,58 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityAnimation +{ + [TaskCategory("Unity/Animation")] + [TaskDescription("Fades the animation over a period of time and fades other animations out. Returns Success.")] + public class CrossFade : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The name of the animation")] + public SharedString animationName; + [Tooltip("The speed of the animation. Use a negative value to play the animation backwards")] + public SharedFloat animationSpeed = 1f; + [Tooltip("The amount of time it takes to blend")] + public SharedFloat fadeLength = 0.3f; + [Tooltip("The play mode of the animation")] + public PlayMode playMode = PlayMode.StopSameLayer; + + // cache the animation component + private Animation animation; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + animation = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (animation == null) { + Debug.LogWarning("Animation is null"); + return TaskStatus.Failure; + } + + animation[animationName.Value].speed = animationSpeed.Value; + if (animation[animationName.Value].speed < 0) { + animation[animationName.Value].time = animation[animationName.Value].length; + } + animation.CrossFade(animationName.Value, fadeLength.Value, playMode); + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + animationName.Value = ""; + animationSpeed = 1; + fadeLength = 0.3f; + playMode = PlayMode.StopSameLayer; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Animation/CrossFade.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animation/CrossFade.cs.meta new file mode 100644 index 0000000..2185950 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animation/CrossFade.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 57d9d1509d13e454caae6f3219c83cc7 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Animation/CrossFadeQueued.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animation/CrossFadeQueued.cs new file mode 100644 index 0000000..a52eb3e --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animation/CrossFadeQueued.cs @@ -0,0 +1,54 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityAnimation +{ + [TaskCategory("Unity/Animation")] + [TaskDescription("Cross fades an animation after previous animations has finished playing. Returns Success.")] + public class CrossFadeQueued : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The name of the animation")] + public SharedString animationName; + [Tooltip("The amount of time it takes to blend")] + public float fadeLength = 0.3f; + [Tooltip("Specifies when the animation should start playing")] + public QueueMode queue = QueueMode.CompleteOthers; + [Tooltip("The play mode of the animation")] + public PlayMode playMode = PlayMode.StopSameLayer; + + // cache the animation component + private Animation animation; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + animation = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (animation == null) { + Debug.LogWarning("Animation is null"); + return TaskStatus.Failure; + } + + animation.CrossFadeQueued(animationName.Value, fadeLength, queue, playMode); + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + animationName.Value = ""; + fadeLength = 0.3f; + queue = QueueMode.CompleteOthers; + playMode = PlayMode.StopSameLayer; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Animation/CrossFadeQueued.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animation/CrossFadeQueued.cs.meta new file mode 100644 index 0000000..255f3d0 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animation/CrossFadeQueued.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: c1cc2a160ee1978488696564200b3c25 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Animation/GetAnimatePhysics.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animation/GetAnimatePhysics.cs new file mode 100644 index 0000000..44b5d28 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animation/GetAnimatePhysics.cs @@ -0,0 +1,46 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityAnimation +{ + [TaskCategory("Unity/Animation")] + [TaskDescription("Stores the animate physics value. Returns Success.")] + public class GetAnimatePhysics : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("Are the if animations are executed in the physics loop?")] + [RequiredField] + public SharedBool storeValue; + + // cache the animation component + private Animation animation; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + animation = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (animation == null) { + Debug.LogWarning("Animation is null"); + return TaskStatus.Failure; + } + + storeValue.Value = animation.animatePhysics; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + storeValue.Value = false; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Animation/GetAnimatePhysics.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animation/GetAnimatePhysics.cs.meta new file mode 100644 index 0000000..157b899 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animation/GetAnimatePhysics.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: b5bd2b0ed07f42142934568bd6813619 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Animation/IsPlaying.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animation/IsPlaying.cs new file mode 100644 index 0000000..d96ae6d --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animation/IsPlaying.cs @@ -0,0 +1,47 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityAnimation +{ + [TaskCategory("Unity/Animation")] + [TaskDescription("Returns Success if the animation is currently playing.")] + public class IsPlaying : Conditional + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The name of the animation")] + public SharedString animationName; + + // cache the animation component + private Animation animation; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + animation = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (animation == null) { + Debug.LogWarning("Animation is null"); + return TaskStatus.Failure; + } + + if (string.IsNullOrEmpty(animationName.Value)) { + return animation.isPlaying ? TaskStatus.Success : TaskStatus.Failure; + } else { + return animation.IsPlaying(animationName.Value) ? TaskStatus.Success : TaskStatus.Failure; + } + } + + public override void OnReset() + { + targetGameObject = null; + animationName.Value = ""; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Animation/IsPlaying.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animation/IsPlaying.cs.meta new file mode 100644 index 0000000..d846eb9 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animation/IsPlaying.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: ce80475167d230d4181baa69071465ff +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Animation/Play.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animation/Play.cs new file mode 100644 index 0000000..623bc08 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animation/Play.cs @@ -0,0 +1,52 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityAnimation +{ + [TaskCategory("Unity/Animation")] + [TaskDescription("Plays animation without any blending. Returns Success.")] + public class Play : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The name of the animation")] + public SharedString animationName; + [Tooltip("The play mode of the animation")] + public PlayMode playMode = PlayMode.StopSameLayer; + + // cache the animation component + private Animation animation; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + animation = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (animation == null) { + Debug.LogWarning("Animation is null"); + return TaskStatus.Failure; + } + + if (string.IsNullOrEmpty(animationName.Value)) { + animation.Play(); + } else { + animation.Play(animationName.Value, playMode); + } + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + animationName.Value = ""; + playMode = PlayMode.StopSameLayer; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Animation/Play.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animation/Play.cs.meta new file mode 100644 index 0000000..5162330 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animation/Play.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 0b1bf3b05e79dcc468cf71b63d54a4cd +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Animation/PlayQueued.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animation/PlayQueued.cs new file mode 100644 index 0000000..c0fcbaf --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animation/PlayQueued.cs @@ -0,0 +1,51 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityAnimation +{ + [TaskCategory("Unity/Animation")] + [TaskDescription("Plays an animation after previous animations has finished playing. Returns Success.")] + public class PlayQueued : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The name of the animation")] + public SharedString animationName; + [Tooltip("Specifies when the animation should start playing")] + public QueueMode queue = QueueMode.CompleteOthers; + [Tooltip("The play mode of the animation")] + public PlayMode playMode = PlayMode.StopSameLayer; + + // cache the animation component + private Animation animation; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + animation = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (animation == null) { + Debug.LogWarning("Animation is null"); + return TaskStatus.Failure; + } + + animation.PlayQueued(animationName.Value, queue, playMode); + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + animationName.Value = ""; + queue = QueueMode.CompleteOthers; + playMode = PlayMode.StopSameLayer; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Animation/PlayQueued.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animation/PlayQueued.cs.meta new file mode 100644 index 0000000..8e69a10 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animation/PlayQueued.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: bb55ee97bf8cb3d479de025d77a9c4b6 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Animation/Rewind.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animation/Rewind.cs new file mode 100644 index 0000000..f3636c9 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animation/Rewind.cs @@ -0,0 +1,49 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityAnimation +{ + [TaskCategory("Unity/Animation")] + [TaskDescription("Rewinds an animation. Rewinds all animations if animationName is blank. Returns Success.")] + public class Rewind : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The name of the animation")] + public SharedString animationName; + + // cache the animation component + private Animation animation; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + animation = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (animation == null) { + Debug.LogWarning("Animation is null"); + return TaskStatus.Failure; + } + + if (string.IsNullOrEmpty(animationName.Value)) { + animation.Rewind(); + } else { + animation.Rewind(animationName.Value); + } + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + animationName.Value = ""; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Animation/Rewind.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animation/Rewind.cs.meta new file mode 100644 index 0000000..2d3c45b --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animation/Rewind.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 364beb9f6996556449b9f3e03db75290 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Animation/Sample.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animation/Sample.cs new file mode 100644 index 0000000..5cb1319 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animation/Sample.cs @@ -0,0 +1,41 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityAnimation +{ + [TaskCategory("Unity/Animation")] + [TaskDescription("Samples animations at the current state. Returns Success.")] + public class Sample : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + // cache the animation component + private Animation animation; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + animation = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (animation == null) { + Debug.LogWarning("Animation is null"); + return TaskStatus.Failure; + } + + animation.Sample(); + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Animation/Sample.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animation/Sample.cs.meta new file mode 100644 index 0000000..61d607b --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animation/Sample.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 2cc64c997b5d6e640af8cc9bd7cf1b5d +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Animation/SetAnimatePhysics.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animation/SetAnimatePhysics.cs new file mode 100644 index 0000000..c6df4be --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animation/SetAnimatePhysics.cs @@ -0,0 +1,45 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityAnimation +{ + [TaskCategory("Unity/Animation")] + [TaskDescription("Sets animate physics to the specified value. Returns Success.")] + public class SetAnimatePhysics : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("Are animations executed in the physics loop?")] + public SharedBool animatePhysics; + + // cache the animation component + private Animation animation; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + animation = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (animation == null) { + Debug.LogWarning("Animation is null"); + return TaskStatus.Failure; + } + + animation.animatePhysics = animatePhysics.Value; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + animatePhysics.Value = false; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Animation/SetAnimatePhysics.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animation/SetAnimatePhysics.cs.meta new file mode 100644 index 0000000..0b602de --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animation/SetAnimatePhysics.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: f93fd0c7638add0468744d4f7249c1a7 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Animation/SetWrapMode.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animation/SetWrapMode.cs new file mode 100644 index 0000000..2c2dd50 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animation/SetWrapMode.cs @@ -0,0 +1,45 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityAnimation +{ + [TaskCategory("Unity/Animation")] + [TaskDescription("Sets the wrap mode to the specified value. Returns Success.")] + public class SetWrapMode : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("How should time beyond the playback range of the clip be treated?")] + public WrapMode wrapMode = WrapMode.Default; + + // cache the animation component + private Animation animation; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + animation = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (animation == null) { + Debug.LogWarning("Animation is null"); + return TaskStatus.Failure; + } + + animation.wrapMode = wrapMode; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + wrapMode = WrapMode.Default; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Animation/SetWrapMode.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animation/SetWrapMode.cs.meta new file mode 100644 index 0000000..db5450a --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animation/SetWrapMode.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 39af69a1e220fc2419a5d34933029ff9 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Animation/Stop.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animation/Stop.cs new file mode 100644 index 0000000..c31f35c --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animation/Stop.cs @@ -0,0 +1,49 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityAnimation +{ + [TaskCategory("Unity/Animation")] + [TaskDescription("Stops an animation. Stops all animations if animationName is blank. Returns Success.")] + public class Stop : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The name of the animation")] + public SharedString animationName; + + // cache the animation component + private Animation animation; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + animation = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (animation == null) { + Debug.LogWarning("Animation is null"); + return TaskStatus.Failure; + } + + if (string.IsNullOrEmpty(animationName.Value)) { + animation.Stop(); + } else { + animation.Stop(animationName.Value); + } + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + animationName = ""; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Animation/Stop.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animation/Stop.cs.meta new file mode 100644 index 0000000..7f81a7c --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animation/Stop.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: c3dca423f03e936449fdb622cac3f430 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator.meta new file mode 100644 index 0000000..34457bb --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator.meta @@ -0,0 +1,4 @@ +fileFormatVersion: 2 +guid: 0b46617b2906c0049b19ab613fae2882 +DefaultImporter: + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/CrossFade.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/CrossFade.cs new file mode 100644 index 0000000..7c2ace8 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/CrossFade.cs @@ -0,0 +1,53 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityAnimator +{ + [TaskCategory("Unity/Animator")] + [TaskDescription("Creates a dynamic transition between the current state and the destination state. Returns Success.")] + public class CrossFade : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The name of the state")] + public SharedString stateName; + [Tooltip("The duration of the transition. Value is in source state normalized time")] + public SharedFloat transitionDuration; + [Tooltip("The layer where the state is")] + public int layer = -1; + [Tooltip("The normalized time at which the state will play")] + public float normalizedTime = float.NegativeInfinity; + + private Animator animator; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + animator = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (animator == null) { + Debug.LogWarning("Animator is null"); + return TaskStatus.Failure; + } + + animator.CrossFade(stateName.Value, transitionDuration.Value, layer, normalizedTime); + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + stateName = ""; + transitionDuration = 0; + layer = -1; + normalizedTime = float.NegativeInfinity; + } + } +} diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/CrossFade.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/CrossFade.cs.meta new file mode 100644 index 0000000..1607d7c --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/CrossFade.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 09e5aba2adc719f42876293bcbea7819 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/GetApplyRootMotion.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/GetApplyRootMotion.cs new file mode 100644 index 0000000..1069fd3 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/GetApplyRootMotion.cs @@ -0,0 +1,45 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityAnimator +{ + [TaskCategory("Unity/Animator")] + [TaskDescription("Stores if root motion is applied. Returns Success.")] + public class GetApplyRootMotion : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("Is root motion applied?")] + [RequiredField] + public SharedBool storeValue; + + private Animator animator; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + animator = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (animator == null) { + Debug.LogWarning("Animator is null"); + return TaskStatus.Failure; + } + + storeValue.Value = animator.applyRootMotion; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + storeValue = false; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/GetApplyRootMotion.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/GetApplyRootMotion.cs.meta new file mode 100644 index 0000000..7f3a08c --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/GetApplyRootMotion.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 872c96b3950799546863110b7e54d0c8 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/GetBoolParameter.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/GetBoolParameter.cs new file mode 100644 index 0000000..028c00b --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/GetBoolParameter.cs @@ -0,0 +1,48 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityAnimator +{ + [TaskCategory("Unity/Animator")] + [TaskDescription("Stores the bool parameter on an animator. Returns Success.")] + public class GetBoolParameter : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The name of the parameter")] + public SharedString paramaterName; + [Tooltip("The value of the bool parameter")] + [RequiredField] + public SharedBool storeValue; + + private Animator animator; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + animator = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (animator == null) { + Debug.LogWarning("Animator is null"); + return TaskStatus.Failure; + } + + storeValue.Value = animator.GetBool(paramaterName.Value); + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + paramaterName = ""; + storeValue = false; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/GetBoolParameter.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/GetBoolParameter.cs.meta new file mode 100644 index 0000000..657843a --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/GetBoolParameter.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 2aeb7ebc08541794aa3ed0343c49c9f9 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/GetDeltaPosition.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/GetDeltaPosition.cs new file mode 100644 index 0000000..91d59ba --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/GetDeltaPosition.cs @@ -0,0 +1,45 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityAnimator +{ + [TaskCategory("Unity/Animator")] + [TaskDescription("Gets the avatar delta position for the last evaluated frame. Returns Success.")] + public class GetDeltaPosition : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The avatar delta position")] + [RequiredField] + public SharedVector3 storeValue; + + private Animator animator; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + animator = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (animator == null) { + Debug.LogWarning("Animator is null"); + return TaskStatus.Failure; + } + + storeValue.Value = animator.deltaPosition; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + storeValue = Vector3.zero; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/GetDeltaPosition.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/GetDeltaPosition.cs.meta new file mode 100644 index 0000000..c401d59 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/GetDeltaPosition.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 9c44c26d5d6b3484397b8aa6ed658b1e +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/GetDeltaRotation.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/GetDeltaRotation.cs new file mode 100644 index 0000000..bb7a1cf --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/GetDeltaRotation.cs @@ -0,0 +1,46 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityAnimator +{ + [TaskCategory("Unity/Animator")] + [TaskDescription("Gets the avatar delta rotation for the last evaluated frame. Returns Success.")] + public class GetDeltaRotation : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The avatar delta rotation")] + [RequiredField] + public SharedQuaternion storeValue; + + private Animator animator; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + animator = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (animator == null) { + Debug.LogWarning("Animator is null"); + return TaskStatus.Failure; + } + + storeValue.Value = animator.deltaRotation; + + return TaskStatus.Success; + } + + public override void OnReset() + { + if (storeValue != null) { + storeValue.Value = Quaternion.identity; + } + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/GetDeltaRotation.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/GetDeltaRotation.cs.meta new file mode 100644 index 0000000..5301eb0 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/GetDeltaRotation.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: f120073dca714344495aa139eea16e2b +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/GetFloatParameter.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/GetFloatParameter.cs new file mode 100644 index 0000000..5253f57 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/GetFloatParameter.cs @@ -0,0 +1,48 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityAnimator +{ + [TaskCategory("Unity/Animator")] + [TaskDescription("Stores the float parameter on an animator. Returns Success.")] + public class GetFloatParameter : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The name of the parameter")] + public SharedString paramaterName; + [Tooltip("The value of the float parameter")] + [RequiredField] + public SharedFloat storeValue; + + private Animator animator; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + animator = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (animator == null) { + Debug.LogWarning("Animator is null"); + return TaskStatus.Failure; + } + + storeValue.Value = animator.GetFloat(paramaterName.Value); + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + paramaterName = ""; + storeValue = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/GetFloatParameter.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/GetFloatParameter.cs.meta new file mode 100644 index 0000000..12ccef0 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/GetFloatParameter.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: d33dbb5444b5bbe44bb200e39823cfe1 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/GetGravityWeight.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/GetGravityWeight.cs new file mode 100644 index 0000000..ee67a29 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/GetGravityWeight.cs @@ -0,0 +1,45 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityAnimator +{ + [TaskCategory("Unity/Animator")] + [TaskDescription("Stores the current gravity weight based on current animations that are played. Returns Success.")] + public class GetGravityWeight : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The value of the gravity weight")] + [RequiredField] + public SharedFloat storeValue; + + private Animator animator; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + animator = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (animator == null) { + Debug.LogWarning("Animator is null"); + return TaskStatus.Failure; + } + + storeValue.Value = animator.gravityWeight; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + storeValue = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/GetGravityWeight.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/GetGravityWeight.cs.meta new file mode 100644 index 0000000..3c8b690 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/GetGravityWeight.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 945593329da80b44898e7e1ae1883d07 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/GetIntegerParameter.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/GetIntegerParameter.cs new file mode 100644 index 0000000..20ad279 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/GetIntegerParameter.cs @@ -0,0 +1,48 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityAnimator +{ + [TaskCategory("Unity/Animator")] + [TaskDescription("Stores the integer parameter on an animator. Returns Success.")] + public class GetIntegerParameter : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The name of the parameter")] + public SharedString paramaterName; + [Tooltip("The value of the integer parameter")] + [RequiredField] + public SharedInt storeValue; + + private Animator animator; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + animator = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (animator == null) { + Debug.LogWarning("Animator is null"); + return TaskStatus.Failure; + } + + storeValue.Value = animator.GetInteger(paramaterName.Value); + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + paramaterName = ""; + storeValue = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/GetIntegerParameter.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/GetIntegerParameter.cs.meta new file mode 100644 index 0000000..9b2f9fa --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/GetIntegerParameter.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: c8640eaeae64c2e48ba85336474d59d8 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/GetLayerWeight.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/GetLayerWeight.cs new file mode 100644 index 0000000..8987217 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/GetLayerWeight.cs @@ -0,0 +1,48 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityAnimator +{ + [TaskCategory("Unity/Animator")] + [TaskDescription("Stores the layer's weight. Returns Success.")] + public class GetLayerWeight : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The index of the layer")] + public SharedInt index; + [Tooltip("The value of the float parameter")] + [RequiredField] + public SharedFloat storeValue; + + private Animator animator; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + animator = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (animator == null) { + Debug.LogWarning("Animator is null"); + return TaskStatus.Failure; + } + + storeValue.Value = animator.GetLayerWeight(index.Value); + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + index = 0; + storeValue = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/GetLayerWeight.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/GetLayerWeight.cs.meta new file mode 100644 index 0000000..fe22746 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/GetLayerWeight.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 346c4295a827d9e4c8029cd29a8e18ca +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/GetSpeed.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/GetSpeed.cs new file mode 100644 index 0000000..f869062 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/GetSpeed.cs @@ -0,0 +1,45 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityAnimator +{ + [TaskCategory("Unity/Animator")] + [TaskDescription("Stores the playback speed of the animator. 1 is normal playback speed. Returns Success.")] + public class GetSpeed : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The playback speed of the Animator")] + [RequiredField] + public SharedFloat storeValue; + + private Animator animator; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + animator = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (animator == null) { + Debug.LogWarning("Animator is null"); + return TaskStatus.Failure; + } + + storeValue.Value = animator.speed; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + storeValue = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/GetSpeed.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/GetSpeed.cs.meta new file mode 100644 index 0000000..746f2b5 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/GetSpeed.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: f87648f776ab12c45883b01e9bebc6a3 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/GetStringToHash.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/GetStringToHash.cs new file mode 100644 index 0000000..c905a7c --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/GetStringToHash.cs @@ -0,0 +1,28 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityAnimator +{ + [TaskCategory("Unity/Animator")] + [TaskDescription("Converts the state name to its corresponding hash code. Returns Success.")] + public class GetStringToHash : Action + { + [Tooltip("The name of the state to convert to a hash code")] + public SharedString stateName; + [Tooltip("The hash value")] + [RequiredField] + public SharedInt storeValue; + + public override TaskStatus OnUpdate() + { + storeValue.Value = Animator.StringToHash(stateName.Value); + + return TaskStatus.Success; + } + + public override void OnReset() + { + stateName = ""; + storeValue = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/GetStringToHash.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/GetStringToHash.cs.meta new file mode 100644 index 0000000..6fe0962 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/GetStringToHash.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 234dcf26bcb550043b3b5de33f0e6a11 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/InterruptMatchTarget.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/InterruptMatchTarget.cs new file mode 100644 index 0000000..a08688c --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/InterruptMatchTarget.cs @@ -0,0 +1,44 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityAnimator +{ + [TaskCategory("Unity/Animator")] + [TaskDescription("Interrupts the automatic target matching. Returns Success.")] + public class InterruptMatchTarget : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("CompleteMatch will make the gameobject match the target completely at the next frame")] + public bool completeMatch = true; + + private Animator animator; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + animator = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (animator == null) { + Debug.LogWarning("Animator is null"); + return TaskStatus.Failure; + } + + animator.InterruptMatchTarget(completeMatch); + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + completeMatch = true; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/InterruptMatchTarget.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/InterruptMatchTarget.cs.meta new file mode 100644 index 0000000..e0ee0c6 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/InterruptMatchTarget.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 766d802f8842a2945b11253f60d431bb +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/IsInTransition.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/IsInTransition.cs new file mode 100644 index 0000000..cd05c48 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/IsInTransition.cs @@ -0,0 +1,42 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityAnimator +{ + [TaskCategory("Unity/Animator")] + [TaskDescription("Returns success if the specified AnimatorController layer in a transition.")] + public class IsInTransition : Conditional + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The layer's index")] + public SharedInt index; + + private Animator animator; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + animator = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (animator == null) { + Debug.LogWarning("Animator is null"); + return TaskStatus.Failure; + } + + return animator.IsInTransition(index.Value) ? TaskStatus.Success : TaskStatus.Failure; + } + + public override void OnReset() + { + targetGameObject = null; + index = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/IsInTransition.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/IsInTransition.cs.meta new file mode 100644 index 0000000..6968096 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/IsInTransition.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 48c086aaf693a604d8b83eabac3b568e +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/IsName.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/IsName.cs new file mode 100644 index 0000000..d5cbdbe --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/IsName.cs @@ -0,0 +1,45 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityAnimator +{ + [TaskCategory("Unity/Animator")] + [TaskDescription("Returns success if the specified name matches the name of the active state.")] + public class IsName : Conditional + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The layer's index")] + public SharedInt index; + [Tooltip("The state name to compare")] + public SharedString name; + + private Animator animator; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + animator = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (animator == null) { + Debug.LogWarning("Animator is null"); + return TaskStatus.Failure; + } + + return animator.GetCurrentAnimatorStateInfo(index.Value).IsName(name.Value) ? TaskStatus.Success : TaskStatus.Failure; + } + + public override void OnReset() + { + targetGameObject = null; + index = 0; + name = ""; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/IsName.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/IsName.cs.meta new file mode 100644 index 0000000..37efe1f --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/IsName.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 96051e2f6a0e7ea42a493e6245e4ccde +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/IsParameterControlledByCurve.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/IsParameterControlledByCurve.cs new file mode 100644 index 0000000..225c274 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/IsParameterControlledByCurve.cs @@ -0,0 +1,42 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityAnimator +{ + [TaskCategory("Unity/Animator")] + [TaskDescription("Returns success if the specified parameter is controlled by an additional curve on an animation.")] + public class IsParameterControlledByCurve : Conditional + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The name of the parameter")] + public SharedString paramaterName; + + private Animator animator; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + animator = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (animator == null) { + Debug.LogWarning("Animator is null"); + return TaskStatus.Failure; + } + + return animator.IsParameterControlledByCurve(paramaterName.Value) ? TaskStatus.Success : TaskStatus.Failure; + } + + public override void OnReset() + { + targetGameObject = null; + paramaterName = ""; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/IsParameterControlledByCurve.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/IsParameterControlledByCurve.cs.meta new file mode 100644 index 0000000..28ed2fb --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/IsParameterControlledByCurve.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: c5eb4141402ab7c4abb1d4a5c687a757 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/MatchTarget.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/MatchTarget.cs new file mode 100644 index 0000000..ada0bf5 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/MatchTarget.cs @@ -0,0 +1,62 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityAnimator +{ + [TaskCategory("Unity/Animator")] + [TaskDescription("Automatically adjust the gameobject position and rotation so that the AvatarTarget reaches the matchPosition when the current state is at the specified progress. Returns Success.")] + public class MatchTarget : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The position we want the body part to reach")] + public SharedVector3 matchPosition; + [Tooltip("The rotation in which we want the body part to be")] + public SharedQuaternion matchRotation; + [Tooltip("The body part that is involved in the match")] + public AvatarTarget targetBodyPart; + [Tooltip("Weights for matching position")] + public Vector3 weightMaskPosition; + [Tooltip("Weights for matching rotation")] + public float weightMaskRotation; + [Tooltip("Start time within the animation clip")] + public float startNormalizedTime; + [Tooltip("End time within the animation clip")] + public float targetNormalizedTime = 1; + + private Animator animator; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + animator = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (animator == null) { + Debug.LogWarning("Animator is null"); + return TaskStatus.Failure; + } + + animator.MatchTarget(matchPosition.Value, matchRotation.Value, targetBodyPart, new MatchTargetWeightMask(weightMaskPosition, weightMaskRotation), startNormalizedTime, targetNormalizedTime); + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + matchPosition = Vector3.zero; + matchRotation = Quaternion.identity; + targetBodyPart = AvatarTarget.Root; + weightMaskPosition = Vector3.zero; + weightMaskRotation = 0; + startNormalizedTime = 0; + targetNormalizedTime = 1; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/MatchTarget.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/MatchTarget.cs.meta new file mode 100644 index 0000000..b11a126 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/MatchTarget.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: e0e788b711539ed4dad258780be29de6 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/Play.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/Play.cs new file mode 100644 index 0000000..8dfc972 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/Play.cs @@ -0,0 +1,50 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityAnimator +{ + [TaskCategory("Unity/Animator")] + [TaskDescription("Plays an animator state. Returns Success.")] + public class Play : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The name of the state")] + public SharedString stateName; + [Tooltip("The layer where the state is")] + public int layer = -1; + [Tooltip("The normalized time at which the state will play")] + public float normalizedTime = float.NegativeInfinity; + + private Animator animator; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + animator = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (animator == null) { + Debug.LogWarning("Animator is null"); + return TaskStatus.Failure; + } + + animator.Play(stateName.Value, layer, normalizedTime); + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + stateName = ""; + layer = -1; + normalizedTime = float.NegativeInfinity; + } + } +} diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/Play.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/Play.cs.meta new file mode 100644 index 0000000..1c72104 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/Play.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: a62df911d37cd8349b0168f875cd58ea +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/SetApplyRootMotion.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/SetApplyRootMotion.cs new file mode 100644 index 0000000..62c7646 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/SetApplyRootMotion.cs @@ -0,0 +1,44 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityAnimator +{ + [TaskCategory("Unity/Animator")] + [TaskDescription("Sets if root motion is applied. Returns Success.")] + public class SetApplyRootMotion : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("Is root motion applied?")] + public SharedBool rootMotion; + + private Animator animator; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + animator = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (animator == null) { + Debug.LogWarning("Animator is null"); + return TaskStatus.Failure; + } + + animator.applyRootMotion = rootMotion.Value; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + rootMotion = false; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/SetApplyRootMotion.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/SetApplyRootMotion.cs.meta new file mode 100644 index 0000000..fea9695 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/SetApplyRootMotion.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: f10479b97efcbb94a8089a12bf891b5b +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/SetBoolParameter.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/SetBoolParameter.cs new file mode 100644 index 0000000..d1ac54a --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/SetBoolParameter.cs @@ -0,0 +1,62 @@ +using UnityEngine; +using System.Collections; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityAnimator +{ + [TaskCategory("Unity/Animator")] + [TaskDescription("Sets the bool parameter on an animator. Returns Success.")] + public class SetBoolParameter : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The name of the parameter")] + public SharedString paramaterName; + [Tooltip("The value of the bool parameter")] + public SharedBool boolValue; + [Tooltip("Should the value be reverted back to its original value after it has been set?")] + public bool setOnce; + + private int hashID; + private Animator animator; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + animator = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (animator == null) { + Debug.LogWarning("Animator is null"); + return TaskStatus.Failure; + } + + hashID = UnityEngine.Animator.StringToHash(paramaterName.Value); + + bool prevValue = animator.GetBool(hashID); + animator.SetBool(hashID, boolValue.Value); + if (setOnce) { + StartCoroutine(ResetValue(prevValue)); + } + return TaskStatus.Success; + } + + public IEnumerator ResetValue(bool origVale) + { + yield return null; + animator.SetBool(hashID, origVale); + } + + public override void OnReset() + { + targetGameObject = null; + paramaterName = ""; + boolValue = false; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/SetBoolParameter.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/SetBoolParameter.cs.meta new file mode 100644 index 0000000..1b3b697 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/SetBoolParameter.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 04e0905e87bf90a408551067942c08c7 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/SetFloatParameter.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/SetFloatParameter.cs new file mode 100644 index 0000000..95c0416 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/SetFloatParameter.cs @@ -0,0 +1,63 @@ +using UnityEngine; +using System.Collections; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityAnimator +{ + [TaskCategory("Unity/Animator")] + [TaskDescription("Sets the float parameter on an animator. Returns Success.")] + public class SetFloatParameter : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The name of the parameter")] + public SharedString paramaterName; + [Tooltip("The value of the float parameter")] + public SharedFloat floatValue; + [Tooltip("Should the value be reverted back to its original value after it has been set?")] + public bool setOnce; + + private int hashID; + private Animator animator; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + animator = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (animator == null) { + Debug.LogWarning("Animator is null"); + return TaskStatus.Failure; + } + + hashID = UnityEngine.Animator.StringToHash(paramaterName.Value); + + float prevValue = animator.GetFloat(hashID); + animator.SetFloat(hashID, floatValue.Value); + if (setOnce) { + StartCoroutine(ResetValue(prevValue)); + } + + return TaskStatus.Success; + } + + public IEnumerator ResetValue(float origVale) + { + yield return null; + animator.SetFloat(hashID, origVale); + } + + public override void OnReset() + { + targetGameObject = null; + paramaterName = ""; + floatValue = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/SetFloatParameter.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/SetFloatParameter.cs.meta new file mode 100644 index 0000000..b3cf978 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/SetFloatParameter.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: b601abdc989d2ce4f8dc0d3434705814 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/SetIntegerParameter.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/SetIntegerParameter.cs new file mode 100644 index 0000000..a065528 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/SetIntegerParameter.cs @@ -0,0 +1,63 @@ +using UnityEngine; +using System.Collections; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityAnimator +{ + [TaskCategory("Unity/Animator")] + [TaskDescription("Sets the int parameter on an animator. Returns Success.")] + public class SetIntegerParameter : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The name of the parameter")] + public SharedString paramaterName; + [Tooltip("The value of the int parameter")] + public SharedInt intValue; + [Tooltip("Should the value be reverted back to its original value after it has been set?")] + public bool setOnce; + + private int hashID; + private Animator animator; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + animator = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (animator == null) { + Debug.LogWarning("Animator is null"); + return TaskStatus.Failure; + } + + hashID = UnityEngine.Animator.StringToHash(paramaterName.Value); + + int prevValue = animator.GetInteger(hashID); + animator.SetInteger(hashID, intValue.Value); + if (setOnce) { + StartCoroutine(ResetValue(prevValue)); + } + + return TaskStatus.Success; + } + + public IEnumerator ResetValue(int origVale) + { + yield return null; + animator.SetInteger(hashID, origVale); + } + + public override void OnReset() + { + targetGameObject = null; + paramaterName = ""; + intValue = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/SetIntegerParameter.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/SetIntegerParameter.cs.meta new file mode 100644 index 0000000..72a945a --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/SetIntegerParameter.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 07345b9144172a74892b176413bf9ac3 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/SetLayerWeight.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/SetLayerWeight.cs new file mode 100644 index 0000000..b391a45 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/SetLayerWeight.cs @@ -0,0 +1,47 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityAnimator +{ + [TaskCategory("Unity/Animator")] + [TaskDescription("Sets the layer's current weight. Returns Success.")] + public class SetLayerWeight : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The layer's index")] + public SharedInt index; + [Tooltip("The weight of the layer")] + public SharedFloat weight; + + private Animator animator; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + animator = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (animator == null) { + Debug.LogWarning("Animator is null"); + return TaskStatus.Failure; + } + + animator.SetLayerWeight(index.Value, weight.Value); + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + index = 0; + weight = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/SetLayerWeight.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/SetLayerWeight.cs.meta new file mode 100644 index 0000000..f2e18d0 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/SetLayerWeight.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 979ffd79261d4bb499331ba9fa80ed7d +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/SetLookAtPosition.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/SetLookAtPosition.cs new file mode 100644 index 0000000..a65f32b --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/SetLookAtPosition.cs @@ -0,0 +1,45 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityAnimator +{ + [TaskCategory("Unity/Animator")] + [TaskDescription("Sets the look at position. Returns Success.")] + public class SetLookAtPosition : Action + { + [Tooltip("The position to lookAt")] + public SharedVector3 position; + + private Animator animator; + private bool positionSet; + + public override void OnStart() + { + animator = GetComponent(); + positionSet = false; + } + + public override TaskStatus OnUpdate() + { + if (animator == null) { + Debug.LogWarning("Animator is null"); + return TaskStatus.Failure; + } + + return positionSet ? TaskStatus.Success : TaskStatus.Running; + } + + public override void OnAnimatorIK() + { + if (animator == null) { + return; + } + animator.SetLookAtPosition(position.Value); + positionSet = true; + } + + public override void OnReset() + { + position = Vector3.zero; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/SetLookAtPosition.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/SetLookAtPosition.cs.meta new file mode 100644 index 0000000..1acff7c --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/SetLookAtPosition.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 31c4894aafa2b7f40984915713cff50b +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/SetLookAtWeight.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/SetLookAtWeight.cs new file mode 100644 index 0000000..37a2cdd --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/SetLookAtWeight.cs @@ -0,0 +1,58 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityAnimator +{ + [TaskCategory("Unity/Animator")] + [TaskDescription("Sets the look at weight. Returns success immediately after.")] + public class SetLookAtWeight : Action + { + [Tooltip("(0-1) the global weight of the LookAt, multiplier for other parameters.")] + public SharedFloat weight; + [Tooltip("(0-1) determines how much the body is involved in the LookAt.")] + public float bodyWeight; + [Tooltip("(0-1) determines how much the head is involved in the LookAt.")] + public float headWeight = 1; + [Tooltip("(0-1) determines how much the eyes are involved in the LookAt.")] + public float eyesWeight; + [Tooltip("(0-1) 0.0 means the character is completely unrestrained in motion, 1.0 means he's completely clamped " + + "(look at becomes impossible), and 0.5 means he'll be able to move on half of the possible range (180 degrees).")] + public float clampWeight = 0.5f; + + private Animator animator; + private bool weightSet; + + public override void OnStart() + { + animator = GetComponent(); + weightSet = false; + } + + public override TaskStatus OnUpdate() + { + if (animator == null) { + Debug.LogWarning("Animator is null"); + return TaskStatus.Failure; + } + + return weightSet ? TaskStatus.Success : TaskStatus.Running; + } + + public override void OnAnimatorIK() + { + if (animator == null) { + return; + } + animator.SetLookAtWeight(weight.Value, bodyWeight, headWeight, eyesWeight, clampWeight); + weightSet = true; + } + + public override void OnReset() + { + weight = 0; + bodyWeight = 0; + headWeight = 1; + eyesWeight = 0; + clampWeight = 0.5f; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/SetLookAtWeight.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/SetLookAtWeight.cs.meta new file mode 100644 index 0000000..6c9cf13 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/SetLookAtWeight.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 1d700204dde35cd4c9e5a8553089127e +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/SetSpeed.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/SetSpeed.cs new file mode 100644 index 0000000..14d10f9 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/SetSpeed.cs @@ -0,0 +1,44 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityAnimator +{ + [TaskCategory("Unity/Animator")] + [TaskDescription("Sets the playback speed of the Animator. 1 is normal playback speed. Returns Success.")] + public class SetSpeed : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The playback speed of the Animator")] + public SharedFloat speed; + + private Animator animator; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + animator = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (animator == null) { + Debug.LogWarning("Animator is null"); + return TaskStatus.Failure; + } + + animator.speed = speed.Value; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + speed = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/SetSpeed.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/SetSpeed.cs.meta new file mode 100644 index 0000000..e292eb2 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/SetSpeed.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: b5cd3c9afb48ee541afcce2dade6bc6a +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/SetTrigger.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/SetTrigger.cs new file mode 100644 index 0000000..92c0a85 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/SetTrigger.cs @@ -0,0 +1,44 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityAnimator +{ + [TaskCategory("Unity/Animator")] + [TaskDescription("Sets a trigger parameter to active or inactive. Returns Success.")] + public class SetTrigger : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The name of the parameter")] + public SharedString paramaterName; + + private Animator animator; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + animator = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (animator == null) { + Debug.LogWarning("Animator is null"); + return TaskStatus.Failure; + } + + animator.SetTrigger(paramaterName.Value); + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + paramaterName = ""; + } + } +} diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/SetTrigger.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/SetTrigger.cs.meta new file mode 100644 index 0000000..f38a0dc --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/SetTrigger.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 004807d2b68cad7459f6d84ce1274c16 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/StartPlayback.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/StartPlayback.cs new file mode 100644 index 0000000..2a58808 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/StartPlayback.cs @@ -0,0 +1,41 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityAnimator +{ + [TaskCategory("Unity/Animator")] + [TaskDescription("Sets the animator in playback mode.")] + public class StartPlayback : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + + private Animator animator; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + animator = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (animator == null) { + Debug.LogWarning("Animator is null"); + return TaskStatus.Failure; + } + + animator.StartPlayback(); + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + } + } +} diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/StartPlayback.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/StartPlayback.cs.meta new file mode 100644 index 0000000..b0ed558 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/StartPlayback.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 46d4b19160ba8774ea6100dda4288753 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/StartRecording.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/StartRecording.cs new file mode 100644 index 0000000..b79f55c --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/StartRecording.cs @@ -0,0 +1,44 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityAnimator +{ + [TaskCategory("Unity/Animator")] + [TaskDescription("Sets the animator in recording mode. Returns Success.")] + public class StartRecording : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The number of frames (updates) that will be recorded")] + public int frameCount; + + private Animator animator; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + animator = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (animator == null) { + Debug.LogWarning("Animator is null"); + return TaskStatus.Failure; + } + + animator.StartRecording(frameCount); + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + frameCount = 0; + } + } +} diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/StartRecording.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/StartRecording.cs.meta new file mode 100644 index 0000000..73fcd02 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/StartRecording.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: d6f14b502ed889444a0e44e8cb06e767 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/StopPlayback.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/StopPlayback.cs new file mode 100644 index 0000000..ae9c230 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/StopPlayback.cs @@ -0,0 +1,41 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityAnimator +{ + [TaskCategory("Unity/Animator")] + [TaskDescription("Stops the animator playback mode. Returns Success.")] + public class StopPlayback : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + + private Animator animator; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + animator = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (animator == null) { + Debug.LogWarning("Animator is null"); + return TaskStatus.Failure; + } + + animator.StopPlayback(); + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + } + } +} diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/StopPlayback.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/StopPlayback.cs.meta new file mode 100644 index 0000000..d92ed32 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/StopPlayback.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 7daa3c083e51ad44a8c8b05bb4e70689 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/StopRecording.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/StopRecording.cs new file mode 100644 index 0000000..6781273 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/StopRecording.cs @@ -0,0 +1,41 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityAnimator +{ + [TaskCategory("Unity/Animator")] + [TaskDescription("Stops animator record mode. Returns Success.")] + public class StopRecording : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + + private Animator animator; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + animator = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (animator == null) { + Debug.LogWarning("Animator is null"); + return TaskStatus.Failure; + } + + animator.StopRecording(); + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + } + } +} diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/StopRecording.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/StopRecording.cs.meta new file mode 100644 index 0000000..d1c4606 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/StopRecording.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: c62c2817a5d72054caebff852d50ef17 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/WaitForState.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/WaitForState.cs new file mode 100644 index 0000000..c5a8f03 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/WaitForState.cs @@ -0,0 +1,60 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityAnimator +{ + [TaskCategory("Unity/Animator")] + [TaskDescription("Waits for the Animator to reach the specified state.")] + public class WaitForState : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The name of the state")] + public SharedString stateName; + [Tooltip("The layer where the state is")] + public SharedInt layer = -1; + + private Animator animator; + private GameObject prevGameObject; + private int stateHash; + + public override void OnAwake() + { + stateHash = Animator.StringToHash(stateName.Value); + } + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + animator = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + + if (!animator.HasState(layer.Value, stateHash)) { + Debug.LogError("Error: The Animator does not have the state " + stateName.Value + " on layer " + layer.Value); + } + } + } + + public override TaskStatus OnUpdate() + { + if (animator == null) { + Debug.LogWarning("Animator is null"); + return TaskStatus.Failure; + } + + var state = animator.GetCurrentAnimatorStateInfo(layer.Value); + if (state.shortNameHash == stateHash) { + return TaskStatus.Success; + } + + return TaskStatus.Running; + } + + public override void OnReset() + { + targetGameObject = null; + stateName = ""; + layer = -1; + } + } +} diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/WaitForState.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/WaitForState.cs.meta new file mode 100644 index 0000000..491bcff --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Animator/WaitForState.cs.meta @@ -0,0 +1,12 @@ +fileFormatVersion: 2 +guid: eff6d0a1593e4f7459f0194f9cbd79f1 +timeCreated: 1523364189 +licenseType: Store +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource.meta new file mode 100644 index 0000000..d08b44c --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource.meta @@ -0,0 +1,4 @@ +fileFormatVersion: 2 +guid: 8d2af13ebd5ef0b428b7ea2a3eb85c95 +DefaultImporter: + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/GetIgnoreListenerPause.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/GetIgnoreListenerPause.cs new file mode 100644 index 0000000..0a507ed --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/GetIgnoreListenerPause.cs @@ -0,0 +1,45 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityAudioSource +{ + [TaskCategory("Unity/AudioSource")] + [TaskDescription("Stores the ignore listener pause value of the AudioSource. Returns Success.")] + public class GetIgnoreListenerPause : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The ignore listener pause value of the AudioSource")] + [RequiredField] + public SharedBool storeValue; + + private AudioSource audioSource; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + audioSource = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (audioSource == null) { + Debug.LogWarning("AudioSource is null"); + return TaskStatus.Failure; + } + + storeValue.Value = audioSource.ignoreListenerPause; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + storeValue = false; + } + } +} diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/GetIgnoreListenerPause.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/GetIgnoreListenerPause.cs.meta new file mode 100644 index 0000000..5f27ded --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/GetIgnoreListenerPause.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: b3bd7bb287fe91747bca60ebe3d53e87 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/GetIgnoreListenerVolume.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/GetIgnoreListenerVolume.cs new file mode 100644 index 0000000..dd876c0 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/GetIgnoreListenerVolume.cs @@ -0,0 +1,45 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityAudioSource +{ + [TaskCategory("Unity/AudioSource")] + [TaskDescription("Stores the ignore listener volume value of the AudioSource. Returns Success.")] + public class GetIgnoreListenerVolume : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The ignore listener volume value of the AudioSource")] + [RequiredField] + public SharedBool storeValue; + + private AudioSource audioSource; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + audioSource = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (audioSource == null) { + Debug.LogWarning("AudioSource is null"); + return TaskStatus.Failure; + } + + storeValue.Value = audioSource.ignoreListenerVolume; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + storeValue = false; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/GetIgnoreListenerVolume.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/GetIgnoreListenerVolume.cs.meta new file mode 100644 index 0000000..013c32c --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/GetIgnoreListenerVolume.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: c45986918364dfc4e9eca01d2839e2e4 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/GetLoop.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/GetLoop.cs new file mode 100644 index 0000000..3cf01d5 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/GetLoop.cs @@ -0,0 +1,45 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityAudioSource +{ + [TaskCategory("Unity/AudioSource")] + [TaskDescription("Stores the loop value of the AudioSource. Returns Success.")] + public class GetLoop : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The loop value of the AudioSource")] + [RequiredField] + public SharedBool storeValue; + + private AudioSource audioSource; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + audioSource = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (audioSource == null) { + Debug.LogWarning("AudioSource is null"); + return TaskStatus.Failure; + } + + storeValue.Value = audioSource.loop; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + storeValue = false; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/GetLoop.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/GetLoop.cs.meta new file mode 100644 index 0000000..9283de6 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/GetLoop.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 699b9d0d798a219459c6477d2c21d4ba +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/GetMaxDistance.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/GetMaxDistance.cs new file mode 100644 index 0000000..0728396 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/GetMaxDistance.cs @@ -0,0 +1,45 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityAudioSource +{ + [TaskCategory("Unity/AudioSource")] + [TaskDescription("Stores the max distance value of the AudioSource. Returns Success.")] + public class GetMaxDistance : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The max distance value of the AudioSource")] + [RequiredField] + public SharedFloat storeValue; + + private AudioSource audioSource; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + audioSource = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (audioSource == null) { + Debug.LogWarning("AudioSource is null"); + return TaskStatus.Failure; + } + + storeValue.Value = audioSource.maxDistance; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + storeValue = 1; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/GetMaxDistance.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/GetMaxDistance.cs.meta new file mode 100644 index 0000000..2f84af4 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/GetMaxDistance.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 3e2b2500d8e2b0c45825c0650f64eae2 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/GetMinDistance.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/GetMinDistance.cs new file mode 100644 index 0000000..3d1051d --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/GetMinDistance.cs @@ -0,0 +1,45 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityAudioSource +{ + [TaskCategory("Unity/AudioSource")] + [TaskDescription("Stores the min distance value of the AudioSource. Returns Success.")] + public class GetMinDistance : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The min distance value of the AudioSource")] + [RequiredField] + public SharedFloat storeValue; + + private AudioSource audioSource; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + audioSource = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (audioSource == null) { + Debug.LogWarning("AudioSource is null"); + return TaskStatus.Failure; + } + + storeValue.Value = audioSource.minDistance; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + storeValue = 1; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/GetMinDistance.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/GetMinDistance.cs.meta new file mode 100644 index 0000000..d40a7fc --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/GetMinDistance.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: cad762e82ef22644ca968b4a1c51eaec +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/GetMute.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/GetMute.cs new file mode 100644 index 0000000..905bd86 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/GetMute.cs @@ -0,0 +1,45 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityAudioSource +{ + [TaskCategory("Unity/AudioSource")] + [TaskDescription("Stores the mute value of the AudioSource. Returns Success.")] + public class GetMute : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The mute value of the AudioSource")] + [RequiredField] + public SharedBool storeValue; + + private AudioSource audioSource; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + audioSource = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (audioSource == null) { + Debug.LogWarning("AudioSource is null"); + return TaskStatus.Failure; + } + + storeValue.Value = audioSource.mute; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + storeValue = false; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/GetMute.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/GetMute.cs.meta new file mode 100644 index 0000000..258db04 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/GetMute.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 51df88b2df77e294cb673105b1c36961 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/GetPitch.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/GetPitch.cs new file mode 100644 index 0000000..88aeb0d --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/GetPitch.cs @@ -0,0 +1,45 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityAudioSource +{ + [TaskCategory("Unity/AudioSource")] + [TaskDescription("Stores the pitch value of the AudioSource. Returns Success.")] + public class GetPitch : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The pitch value of the AudioSource")] + [RequiredField] + public SharedFloat storeValue; + + private AudioSource audioSource; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + audioSource = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (audioSource == null) { + Debug.LogWarning("AudioSource is null"); + return TaskStatus.Failure; + } + + storeValue.Value = audioSource.pitch; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + storeValue = 1; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/GetPitch.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/GetPitch.cs.meta new file mode 100644 index 0000000..fdd48d6 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/GetPitch.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 930fa7881ae9236449d90546f9922656 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/GetPriority.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/GetPriority.cs new file mode 100644 index 0000000..279d032 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/GetPriority.cs @@ -0,0 +1,45 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityAudioSource +{ + [TaskCategory("Unity/AudioSource")] + [TaskDescription("Stores the priority value of the AudioSource. Returns Success.")] + public class GetPriority : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The priority value of the AudioSource")] + [RequiredField] + public SharedInt storeValue; + + private AudioSource audioSource; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + audioSource = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (audioSource == null) { + Debug.LogWarning("AudioSource is null"); + return TaskStatus.Failure; + } + + storeValue.Value = audioSource.priority; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + storeValue = 1; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/GetPriority.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/GetPriority.cs.meta new file mode 100644 index 0000000..a4e8142 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/GetPriority.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: de856d580ad945e4d846fa52d3d647cc +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/GetSpread.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/GetSpread.cs new file mode 100644 index 0000000..f105e8e --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/GetSpread.cs @@ -0,0 +1,45 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityAudioSource +{ + [TaskCategory("Unity/AudioSource")] + [TaskDescription("Stores the spread value of the AudioSource. Returns Success.")] + public class GetSpread : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The spread value of the AudioSource")] + [RequiredField] + public SharedFloat storeValue; + + private AudioSource audioSource; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + audioSource = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (audioSource == null) { + Debug.LogWarning("AudioSource is null"); + return TaskStatus.Failure; + } + + storeValue.Value = audioSource.spread; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + storeValue = 1; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/GetSpread.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/GetSpread.cs.meta new file mode 100644 index 0000000..4f8d493 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/GetSpread.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: ba6a60eccf688514392e782348b84628 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/GetTime.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/GetTime.cs new file mode 100644 index 0000000..ccdb389 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/GetTime.cs @@ -0,0 +1,45 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityAudioSource +{ + [TaskCategory("Unity/AudioSource")] + [TaskDescription("Stores the time value of the AudioSource. Returns Success.")] + public class GetTime : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The time value of the AudioSource")] + [RequiredField] + public SharedFloat storeValue; + + private AudioSource audioSource; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + audioSource = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (audioSource == null) { + Debug.LogWarning("AudioSource is null"); + return TaskStatus.Failure; + } + + storeValue.Value = audioSource.time; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + storeValue = 1; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/GetTime.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/GetTime.cs.meta new file mode 100644 index 0000000..b7a6384 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/GetTime.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 600c95fc760afa140bd0a7b98bd5071f +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/GetTimeSamples.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/GetTimeSamples.cs new file mode 100644 index 0000000..ea9023a --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/GetTimeSamples.cs @@ -0,0 +1,45 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityAudioSource +{ + [TaskCategory("Unity/AudioSource")] + [TaskDescription("Stores the time samples value of the AudioSource. Returns Success.")] + public class GetTimeSamples : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The time samples value of the AudioSource")] + [RequiredField] + public SharedFloat storeValue; + + private AudioSource audioSource; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + audioSource = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (audioSource == null) { + Debug.LogWarning("AudioSource is null"); + return TaskStatus.Failure; + } + + storeValue.Value = audioSource.timeSamples; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + storeValue = 1; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/GetTimeSamples.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/GetTimeSamples.cs.meta new file mode 100644 index 0000000..e91e9bf --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/GetTimeSamples.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: af34adc5779f33442909ff32140dcdd4 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/GetVolume.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/GetVolume.cs new file mode 100644 index 0000000..4aa3beb --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/GetVolume.cs @@ -0,0 +1,45 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityAudioSource +{ + [TaskCategory("Unity/AudioSource")] + [TaskDescription("Stores the volume value of the AudioSource. Returns Success.")] + public class GetVolume : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The volume value of the AudioSource")] + [RequiredField] + public SharedFloat storeValue; + + private AudioSource audioSource; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + audioSource = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (audioSource == null) { + Debug.LogWarning("AudioSource is null"); + return TaskStatus.Failure; + } + + storeValue.Value = audioSource.volume; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + storeValue = 1; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/GetVolume.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/GetVolume.cs.meta new file mode 100644 index 0000000..e623f56 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/GetVolume.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: aad3b2c644baeb646b0b33b7317413d4 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/IsPlaying.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/IsPlaying.cs new file mode 100644 index 0000000..839eb1e --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/IsPlaying.cs @@ -0,0 +1,39 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityAudioSource +{ + [TaskCategory("Unity/AudioSource")] + [TaskDescription("Returns Success if the AudioClip is playing, otherwise Failure.")] + public class IsPlaying : Conditional + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + + private AudioSource audioSource; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + audioSource = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (audioSource == null) { + Debug.LogWarning("AudioSource is null"); + return TaskStatus.Failure; + } + + return audioSource.isPlaying ? TaskStatus.Success : TaskStatus.Failure; + } + + public override void OnReset() + { + targetGameObject = null; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/IsPlaying.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/IsPlaying.cs.meta new file mode 100644 index 0000000..53c4011 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/IsPlaying.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 20fb79d98326b794fb309a291613cab4 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/Pause.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/Pause.cs new file mode 100644 index 0000000..cdce6ae --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/Pause.cs @@ -0,0 +1,41 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityAudioSource +{ + [TaskCategory("Unity/AudioSource")] + [TaskDescription("Pauses the audio clip. Returns Success.")] + public class Pause : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + + private AudioSource audioSource; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + audioSource = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (audioSource == null) { + Debug.LogWarning("AudioSource is null"); + return TaskStatus.Failure; + } + + audioSource.Pause(); + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/Pause.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/Pause.cs.meta new file mode 100644 index 0000000..cd0abdf --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/Pause.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 91db8dd58e79db745acc39f3f52da88e +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/Play.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/Play.cs new file mode 100644 index 0000000..f202e78 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/Play.cs @@ -0,0 +1,41 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityAudioSource +{ + [TaskCategory("Unity/AudioSource")] + [TaskDescription("Plays the audio clip. Returns Success.")] + public class Play : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + + private AudioSource audioSource; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + audioSource = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (audioSource == null) { + Debug.LogWarning("AudioSource is null"); + return TaskStatus.Failure; + } + + audioSource.Play(); + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/Play.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/Play.cs.meta new file mode 100644 index 0000000..98460d7 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/Play.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 7ac8cfb80c6a44c42b4ac4eef6f29bd5 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/PlayDelayed.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/PlayDelayed.cs new file mode 100644 index 0000000..c93addb --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/PlayDelayed.cs @@ -0,0 +1,44 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityAudioSource +{ + [TaskCategory("Unity/AudioSource")] + [TaskDescription("Plays the audio clip with a delay specified in seconds. Returns Success.")] + public class PlayDelayed : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("Delay time specified in seconds")] + public SharedFloat delay = 0; + + private AudioSource audioSource; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + audioSource = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (audioSource == null) { + Debug.LogWarning("AudioSource is null"); + return TaskStatus.Failure; + } + + audioSource.PlayDelayed(delay.Value); + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + delay = 0; + } + } +} diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/PlayDelayed.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/PlayDelayed.cs.meta new file mode 100644 index 0000000..c654bd3 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/PlayDelayed.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 0125706a59bb7974eb3d425d3869779a +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/PlayOneShot.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/PlayOneShot.cs new file mode 100644 index 0000000..072f6f8 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/PlayOneShot.cs @@ -0,0 +1,47 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityAudioSource +{ + [TaskCategory("Unity/AudioSource")] + [TaskDescription("Plays an AudioClip, and scales the AudioSource volume by volumeScale. Returns Success.")] + public class PlayOneShot : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The clip being played")] + public SharedObject clip; + [Tooltip("The scale of the volume (0-1)")] + public SharedFloat volumeScale = 1; + + private AudioSource audioSource; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + audioSource = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (audioSource == null) { + Debug.LogWarning("AudioSource is null"); + return TaskStatus.Failure; + } + + audioSource.PlayOneShot((AudioClip)clip.Value, volumeScale.Value); + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + clip = null; + volumeScale = 1; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/PlayOneShot.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/PlayOneShot.cs.meta new file mode 100644 index 0000000..88fe74f --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/PlayOneShot.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 112c969d16008464f96ce23aa5b32486 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/PlayScheduled.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/PlayScheduled.cs new file mode 100644 index 0000000..edabd97 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/PlayScheduled.cs @@ -0,0 +1,44 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityAudioSource +{ + [TaskCategory("Unity/AudioSource")] + [TaskDescription("Plays the audio clip with a delay specified in seconds. Returns Success.")] + public class PlayScheduled : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("Time in seconds on the absolute time-line that AudioSettings.dspTime refers to for when the sound should start playing")] + public SharedFloat time = 0; + + private AudioSource audioSource; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + audioSource = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (audioSource == null) { + Debug.LogWarning("AudioSource is null"); + return TaskStatus.Failure; + } + + audioSource.PlayScheduled(time.Value); + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + time = 0; + } + } +} diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/PlayScheduled.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/PlayScheduled.cs.meta new file mode 100644 index 0000000..4164377 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/PlayScheduled.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 08d431471ffd8954197b88b698f0d424 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/SetAudioClip.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/SetAudioClip.cs new file mode 100644 index 0000000..91dbfe6 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/SetAudioClip.cs @@ -0,0 +1,44 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityAudioSource +{ + [TaskCategory("Unity/AudioSource")] + [TaskDescription("Sets the clip value of the AudioSource. Returns Success.")] + public class SetAudioClip : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The AudioSource clip")] + public AudioClip audioClip; + + private AudioSource audioSource; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + audioSource = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (audioSource == null) { + Debug.LogWarning("AudioSource is null"); + return TaskStatus.Failure; + } + + audioSource.clip = audioClip; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + audioClip = null; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/SetAudioClip.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/SetAudioClip.cs.meta new file mode 100644 index 0000000..7c88488 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/SetAudioClip.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: f52d9d404f7deab448e4f5c2bb3f7892 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/SetIgnoreListenerPause.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/SetIgnoreListenerPause.cs new file mode 100644 index 0000000..17456c1 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/SetIgnoreListenerPause.cs @@ -0,0 +1,44 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityAudioSource +{ + [TaskCategory("Unity/AudioSource")] + [TaskDescription("Sets the ignore listener volume value of the AudioSource. Returns Success.")] + public class SetIgnoreListenerVolume : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The ignore listener volume value of the AudioSource")] + public SharedBool ignoreListenerVolume; + + private AudioSource audioSource; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + audioSource = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (audioSource == null) { + Debug.LogWarning("AudioSource is null"); + return TaskStatus.Failure; + } + + audioSource.ignoreListenerVolume = ignoreListenerVolume.Value; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + ignoreListenerVolume = false; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/SetIgnoreListenerPause.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/SetIgnoreListenerPause.cs.meta new file mode 100644 index 0000000..ea5527d --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/SetIgnoreListenerPause.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: d617db8232463c444a8a3159da109798 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/SetIgnoreListenerVolume.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/SetIgnoreListenerVolume.cs new file mode 100644 index 0000000..bd7fcf3 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/SetIgnoreListenerVolume.cs @@ -0,0 +1,44 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityAudioSource +{ + [TaskCategory("Unity/AudioSource")] + [TaskDescription("Sets the ignore listener pause value of the AudioSource. Returns Success.")] + public class SetIgnoreListenerPause : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The ignore listener pause value of the AudioSource")] + public SharedBool ignoreListenerPause; + + private AudioSource audioSource; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + audioSource = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (audioSource == null) { + Debug.LogWarning("AudioSource is null"); + return TaskStatus.Failure; + } + + audioSource.ignoreListenerPause = ignoreListenerPause.Value; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + ignoreListenerPause = false; + } + } +} diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/SetIgnoreListenerVolume.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/SetIgnoreListenerVolume.cs.meta new file mode 100644 index 0000000..e412821 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/SetIgnoreListenerVolume.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 6f1f5937bfa03484296c0fb5a9ce9b29 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/SetLoop.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/SetLoop.cs new file mode 100644 index 0000000..3925212 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/SetLoop.cs @@ -0,0 +1,44 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityAudioSource +{ + [TaskCategory("Unity/AudioSource")] + [TaskDescription("Sets the loop value of the AudioSource. Returns Success.")] + public class SetLoop : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The loop value of the AudioSource")] + public SharedBool loop; + + private AudioSource audioSource; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + audioSource = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (audioSource == null) { + Debug.LogWarning("AudioSource is null"); + return TaskStatus.Failure; + } + + audioSource.loop = loop.Value; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + loop = false; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/SetLoop.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/SetLoop.cs.meta new file mode 100644 index 0000000..a581880 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/SetLoop.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 50536bd6b5fa6924bb7217dd3b6e3f45 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/SetMaxDistance.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/SetMaxDistance.cs new file mode 100644 index 0000000..1d70c27 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/SetMaxDistance.cs @@ -0,0 +1,44 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityAudioSource +{ + [TaskCategory("Unity/AudioSource")] + [TaskDescription("Sets the max distance value of the AudioSource. Returns Success.")] + public class SetMaxDistance : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The max distance value of the AudioSource")] + public SharedFloat maxDistance; + + private AudioSource audioSource; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + audioSource = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (audioSource == null) { + Debug.LogWarning("AudioSource is null"); + return TaskStatus.Failure; + } + + audioSource.maxDistance = maxDistance.Value; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + maxDistance = 1; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/SetMaxDistance.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/SetMaxDistance.cs.meta new file mode 100644 index 0000000..86acafa --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/SetMaxDistance.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: b0c75cf2afc289c4a8962f71b5e17dd1 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/SetMinDistance.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/SetMinDistance.cs new file mode 100644 index 0000000..d747d5e --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/SetMinDistance.cs @@ -0,0 +1,44 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityAudioSource +{ + [TaskCategory("Unity/AudioSource")] + [TaskDescription("Sets the min distance value of the AudioSource. Returns Success.")] + public class SetMinDistance : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The min distance value of the AudioSource")] + public SharedFloat minDistance; + + private AudioSource audioSource; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + audioSource = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (audioSource == null) { + Debug.LogWarning("AudioSource is null"); + return TaskStatus.Failure; + } + + audioSource.minDistance = minDistance.Value; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + minDistance = 1; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/SetMinDistance.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/SetMinDistance.cs.meta new file mode 100644 index 0000000..dd1ebf7 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/SetMinDistance.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: ccb3beba9296fc54d8427cd646af4f4e +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/SetMute.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/SetMute.cs new file mode 100644 index 0000000..f783555 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/SetMute.cs @@ -0,0 +1,44 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityAudioSource +{ + [TaskCategory("Unity/AudioSource")] + [TaskDescription("Sets the mute value of the AudioSource. Returns Success.")] + public class SetMute : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The mute value of the AudioSource")] + public SharedBool mute; + + private AudioSource audioSource; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + audioSource = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (audioSource == null) { + Debug.LogWarning("AudioSource is null"); + return TaskStatus.Failure; + } + + audioSource.mute = mute.Value; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + mute = false; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/SetMute.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/SetMute.cs.meta new file mode 100644 index 0000000..a9ca361 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/SetMute.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: ec553c7ad9360a24fb7ce3bf3bc48c97 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/SetPan.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/SetPan.cs new file mode 100644 index 0000000..0c464bc --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/SetPan.cs @@ -0,0 +1,46 @@ +#if UNITY_4_6 || UNITY_4_7 +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityAudioSource +{ + [TaskCategory("Unity/AudioSource")] + [TaskDescription("Sets the pan value of the AudioSource. Returns Success.")] + public class SetPan : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The pan value of the AudioSource")] + public SharedFloat pan; + + private AudioSource audioSource; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + audioSource = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (audioSource == null) { + Debug.LogWarning("AudioSource is null"); + return TaskStatus.Failure; + } + + audioSource.pan = pan.Value; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + pan = 1; + } + } +} +#endif \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/SetPan.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/SetPan.cs.meta new file mode 100644 index 0000000..71adc17 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/SetPan.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: ed66670f171cea24c9208fff10bfc43d +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/SetPanLevel.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/SetPanLevel.cs new file mode 100644 index 0000000..d0dc961 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/SetPanLevel.cs @@ -0,0 +1,46 @@ +#if UNITY_4_6 || UNITY_4_7 +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityAudioSource +{ + [TaskCategory("Unity/AudioSource")] + [TaskDescription("Sets the pan level value of the AudioSource. Returns Success.")] + public class SetPanLevel : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The pan level value of the AudioSource")] + public SharedFloat panLevel; + + private AudioSource audioSource; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + audioSource = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (audioSource == null) { + Debug.LogWarning("AudioSource is null"); + return TaskStatus.Failure; + } + + audioSource.panLevel = panLevel.Value; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + panLevel = 1; + } + } +} +#endif \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/SetPanLevel.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/SetPanLevel.cs.meta new file mode 100644 index 0000000..a307f19 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/SetPanLevel.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 219609a4a0818d746a7828dc968c31a9 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/SetPitch.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/SetPitch.cs new file mode 100644 index 0000000..c3efee4 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/SetPitch.cs @@ -0,0 +1,44 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityAudioSource +{ + [TaskCategory("Unity/AudioSource")] + [TaskDescription("Sets the pitch value of the AudioSource. Returns Success.")] + public class SetPitch : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The pitch value of the AudioSource")] + public SharedFloat pitch; + + private AudioSource audioSource; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + audioSource = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (audioSource == null) { + Debug.LogWarning("AudioSource is null"); + return TaskStatus.Failure; + } + + audioSource.pitch = pitch.Value; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + pitch = 1; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/SetPitch.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/SetPitch.cs.meta new file mode 100644 index 0000000..533cc45 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/SetPitch.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 3c7615ddc4e92fd41b72de06f039f9e1 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/SetPriority.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/SetPriority.cs new file mode 100644 index 0000000..ffd1584 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/SetPriority.cs @@ -0,0 +1,44 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityAudioSource +{ + [TaskCategory("Unity/AudioSource")] + [TaskDescription("Sets the priority value of the AudioSource. Returns Success.")] + public class SetPriority : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The priority value of the AudioSource")] + public SharedInt priority; + + private AudioSource audioSource; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + audioSource = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (audioSource == null) { + Debug.LogWarning("AudioSource is null"); + return TaskStatus.Failure; + } + + audioSource.priority = priority.Value; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + priority = 1; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/SetPriority.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/SetPriority.cs.meta new file mode 100644 index 0000000..f17aaa8 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/SetPriority.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 4fc15622e17101f4b95be39910433c8a +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/SetRolloffMode.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/SetRolloffMode.cs new file mode 100644 index 0000000..0a25308 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/SetRolloffMode.cs @@ -0,0 +1,44 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityAudioSource +{ + [TaskCategory("Unity/AudioSource")] + [TaskDescription("Sets the rolloff mode of the AudioSource. Returns Success.")] + public class SetRolloffMode : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The rolloff mode of the AudioSource")] + public AudioRolloffMode rolloffMode; + + private AudioSource audioSource; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + audioSource = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (audioSource == null) { + Debug.LogWarning("AudioSource is null"); + return TaskStatus.Failure; + } + + audioSource.rolloffMode = rolloffMode; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + rolloffMode = AudioRolloffMode.Logarithmic; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/SetRolloffMode.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/SetRolloffMode.cs.meta new file mode 100644 index 0000000..68fe867 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/SetRolloffMode.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: ef88d71b5b7e0a84d98bde6405eb294d +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/SetScheduledEndTime.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/SetScheduledEndTime.cs new file mode 100644 index 0000000..20c149f --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/SetScheduledEndTime.cs @@ -0,0 +1,45 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityAudioSource +{ + [TaskCategory("Unity/AudioSource")] + [TaskDescription("Changes the time at which a sound that has already been scheduled to play will end. Notice that depending on the " + + "timing not all rescheduling requests can be fulfilled. Returns Success.")] + public class SetScheduledEndTime : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("Time in seconds")] + public SharedFloat time = 0; + + private AudioSource audioSource; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + audioSource = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (audioSource == null) { + Debug.LogWarning("AudioSource is null"); + return TaskStatus.Failure; + } + + audioSource.SetScheduledEndTime(time.Value); + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + time = 0; + } + } +} diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/SetScheduledEndTime.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/SetScheduledEndTime.cs.meta new file mode 100644 index 0000000..754972b --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/SetScheduledEndTime.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 8867d64aa9a2add4f913b8b5faa9d1ce +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/SetScheduledStartTime.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/SetScheduledStartTime.cs new file mode 100644 index 0000000..be0f696 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/SetScheduledStartTime.cs @@ -0,0 +1,44 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityAudioSource +{ + [TaskCategory("Unity/AudioSource")] + [TaskDescription("Changes the time at which a sound that has already been scheduled to play will start. Returns Success.")] + public class SetScheduledStartTime : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("Time in seconds")] + public SharedFloat time = 0; + + private AudioSource audioSource; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + audioSource = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (audioSource == null) { + Debug.LogWarning("AudioSource is null"); + return TaskStatus.Failure; + } + + audioSource.SetScheduledStartTime(time.Value); + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + time = 0; + } + } +} diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/SetScheduledStartTime.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/SetScheduledStartTime.cs.meta new file mode 100644 index 0000000..25b0f13 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/SetScheduledStartTime.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: cf64b74120564064a8d9c622ccc7115a +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/SetSpread.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/SetSpread.cs new file mode 100644 index 0000000..dbf2cbd --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/SetSpread.cs @@ -0,0 +1,44 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityAudioSource +{ + [TaskCategory("Unity/AudioSource")] + [TaskDescription("Sets the spread value of the AudioSource. Returns Success.")] + public class SetSpread : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The spread value of the AudioSource")] + public SharedFloat spread; + + private AudioSource audioSource; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + audioSource = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (audioSource == null) { + Debug.LogWarning("AudioSource is null"); + return TaskStatus.Failure; + } + + audioSource.spread = spread.Value; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + spread = 1; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/SetSpread.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/SetSpread.cs.meta new file mode 100644 index 0000000..0751b60 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/SetSpread.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: f6d964d5fdf24bf449d3f59de1864dd8 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/SetTime.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/SetTime.cs new file mode 100644 index 0000000..b152104 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/SetTime.cs @@ -0,0 +1,44 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityAudioSource +{ + [TaskCategory("Unity/AudioSource")] + [TaskDescription("Sets the time value of the AudioSource. Returns Success.")] + public class SetTime : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The time value of the AudioSource")] + public SharedFloat time; + + private AudioSource audioSource; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + audioSource = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (audioSource == null) { + Debug.LogWarning("AudioSource is null"); + return TaskStatus.Failure; + } + + audioSource.time = time.Value; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + time = 1; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/SetTime.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/SetTime.cs.meta new file mode 100644 index 0000000..6526a9a --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/SetTime.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 3173ce3fda9d60f48b159759f8981f89 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/SetVelocityUpdateMode.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/SetVelocityUpdateMode.cs new file mode 100644 index 0000000..95edb97 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/SetVelocityUpdateMode.cs @@ -0,0 +1,44 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityAudioSource +{ + [TaskCategory("Unity/AudioSource")] + [TaskDescription("Sets the rolloff mode of the AudioSource. Returns Success.")] + public class SetVelocityUpdateMode : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The velocity update mode of the AudioSource")] + public AudioVelocityUpdateMode velocityUpdateMode; + + private AudioSource audioSource; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + audioSource = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (audioSource == null) { + Debug.LogWarning("AudioSource is null"); + return TaskStatus.Failure; + } + + audioSource.velocityUpdateMode = velocityUpdateMode; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + velocityUpdateMode = AudioVelocityUpdateMode.Auto; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/SetVelocityUpdateMode.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/SetVelocityUpdateMode.cs.meta new file mode 100644 index 0000000..617eda0 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/SetVelocityUpdateMode.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: c26ea6b22d3fa7843a73e5088376996c +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/SetVolume.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/SetVolume.cs new file mode 100644 index 0000000..0ae1954 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/SetVolume.cs @@ -0,0 +1,44 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityAudioSource +{ + [TaskCategory("Unity/AudioSource")] + [TaskDescription("Sets the volume value of the AudioSource. Returns Success.")] + public class SetVolume : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The volume value of the AudioSource")] + public SharedFloat volume; + + private AudioSource audioSource; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + audioSource = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (audioSource == null) { + Debug.LogWarning("AudioSource is null"); + return TaskStatus.Failure; + } + + audioSource.volume = volume.Value; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + volume = 1; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/SetVolume.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/SetVolume.cs.meta new file mode 100644 index 0000000..b5cfece --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/SetVolume.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: edfc39045c7af164fb340d21762e4d79 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/Stop.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/Stop.cs new file mode 100644 index 0000000..ab5fdf4 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/Stop.cs @@ -0,0 +1,41 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityAudioSource +{ + [TaskCategory("Unity/AudioSource")] + [TaskDescription("Stops playing the audio clip. Returns Success.")] + public class Stop : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + + private AudioSource audioSource; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + audioSource = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (audioSource == null) { + Debug.LogWarning("AudioSource is null"); + return TaskStatus.Failure; + } + + audioSource.Stop(); + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/Stop.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/Stop.cs.meta new file mode 100644 index 0000000..0041e88 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/AudioSource/Stop.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: bd4cec1e9e81e664d8e7782bd02bcade +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Behaviour.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Behaviour.meta new file mode 100644 index 0000000..9d3d4dc --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Behaviour.meta @@ -0,0 +1,4 @@ +fileFormatVersion: 2 +guid: 51de5dc2234f2d642b8b53dd9ccc9be3 +DefaultImporter: + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Behaviour/GetEnabled.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Behaviour/GetEnabled.cs new file mode 100644 index 0000000..296542b --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Behaviour/GetEnabled.cs @@ -0,0 +1,33 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityBehaviour +{ + [TaskCategory("Unity/Behaviour")] + [TaskDescription("Stores the enabled state of the object. Returns Success.")] + public class GetEnabled : Action + { + [Tooltip("The Behavior to use")] + public SharedBehaviour specifiedObject; + [Tooltip("The enabled/disabled state")] + [RequiredField] + public SharedBool storeValue; + + public override TaskStatus OnUpdate() + { + if (specifiedObject == null) { + Debug.LogWarning("SpecifiedObject is null"); + return TaskStatus.Failure; + } + + storeValue.Value = specifiedObject.Value.enabled; + + return TaskStatus.Success; + } + + public override void OnReset() + { + specifiedObject.Value = null; + storeValue = false; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Behaviour/GetEnabled.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Behaviour/GetEnabled.cs.meta new file mode 100644 index 0000000..018de83 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Behaviour/GetEnabled.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: ad6519dede06d7b46b95e54bb60be281 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Behaviour/IsEnabled.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Behaviour/IsEnabled.cs new file mode 100644 index 0000000..c3e8c55 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Behaviour/IsEnabled.cs @@ -0,0 +1,29 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityBehaviour +{ + [TaskCategory("Unity/Behaviour")] + [TaskDescription("Returns Success if the object is enabled, otherwise Failure.")] + public class IsEnabled : Conditional + { + [Tooltip("The Object to use")] + public SharedObject specifiedObject; + + public override TaskStatus OnUpdate() + { + if (specifiedObject == null && !(specifiedObject.Value is UnityEngine.Behaviour)) { + Debug.LogWarning("SpecifiedObject is null or not a subclass of UnityEngine.Behaviour"); + return TaskStatus.Failure; + } + + return (specifiedObject.Value as Behaviour).enabled ? TaskStatus.Success : TaskStatus.Failure; + } + + public override void OnReset() + { + if (specifiedObject != null) { + specifiedObject.Value = null; + } + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Behaviour/IsEnabled.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Behaviour/IsEnabled.cs.meta new file mode 100644 index 0000000..0fcdd99 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Behaviour/IsEnabled.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 32f61cbdb8bdf1e44bf418ca21681bc3 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Behaviour/SetEnabled.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Behaviour/SetEnabled.cs new file mode 100644 index 0000000..4d70712 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Behaviour/SetEnabled.cs @@ -0,0 +1,32 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityBehaviour +{ + [TaskCategory("Unity/Behaviour")] + [TaskDescription("Enables/Disables the object. Returns Success.")] + public class SetEnabled : Action + { + [Tooltip("The Behavior to use")] + public SharedBehaviour specifiedObject; + [Tooltip("The enabled/disabled state")] + public SharedBool enabled; + + public override TaskStatus OnUpdate() + { + if (specifiedObject == null) { + Debug.LogWarning("SpecifiedObject is null"); + return TaskStatus.Failure; + } + + specifiedObject.Value.enabled = enabled.Value; + + return TaskStatus.Success; + } + + public override void OnReset() + { + specifiedObject.Value = null; + enabled = false; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Behaviour/SetEnabled.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Behaviour/SetEnabled.cs.meta new file mode 100644 index 0000000..8c0d513 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Behaviour/SetEnabled.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: cf7703ff7e9055e4f811a5b95bf18930 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/BoxCollider.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/BoxCollider.meta new file mode 100644 index 0000000..6791afa --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/BoxCollider.meta @@ -0,0 +1,4 @@ +fileFormatVersion: 2 +guid: 876af1fbcf3642e4b987507ed975a15a +DefaultImporter: + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/BoxCollider/GetCenter.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/BoxCollider/GetCenter.cs new file mode 100644 index 0000000..3173fcf --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/BoxCollider/GetCenter.cs @@ -0,0 +1,45 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityBoxCollider +{ + [TaskCategory("Unity/BoxCollider")] + [TaskDescription("Stores the center of the BoxCollider. Returns Success.")] + public class GetCenter : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The center of the BoxCollider")] + [RequiredField] + public SharedVector3 storeValue; + + private BoxCollider boxCollider; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + boxCollider = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (boxCollider == null) { + Debug.LogWarning("BoxCollider is null"); + return TaskStatus.Failure; + } + + storeValue.Value = boxCollider.center; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + storeValue = Vector3.zero; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/BoxCollider/GetCenter.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/BoxCollider/GetCenter.cs.meta new file mode 100644 index 0000000..543e50a --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/BoxCollider/GetCenter.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 9c3ae13d2bd0e5f4186835c672d9461f +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/BoxCollider/GetSize.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/BoxCollider/GetSize.cs new file mode 100644 index 0000000..ac12291 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/BoxCollider/GetSize.cs @@ -0,0 +1,45 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityBoxCollider +{ + [TaskCategory("Unity/BoxCollider")] + [TaskDescription("Stores the size of the BoxCollider. Returns Success.")] + public class GetSize : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The size of the BoxCollider")] + [RequiredField] + public SharedVector3 storeValue; + + private BoxCollider boxCollider; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + boxCollider = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (boxCollider == null) { + Debug.LogWarning("BoxCollider is null"); + return TaskStatus.Failure; + } + + storeValue.Value = boxCollider.size; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + storeValue = Vector3.zero; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/BoxCollider/GetSize.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/BoxCollider/GetSize.cs.meta new file mode 100644 index 0000000..a99834a --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/BoxCollider/GetSize.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 0afec21454700d3479c4f9767f9382f9 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/BoxCollider/SetCenter.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/BoxCollider/SetCenter.cs new file mode 100644 index 0000000..7731b60 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/BoxCollider/SetCenter.cs @@ -0,0 +1,44 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityBoxCollider +{ + [TaskCategory("Unity/BoxCollider")] + [TaskDescription("Sets the center of the BoxCollider. Returns Success.")] + public class SetCenter : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The center of the BoxCollider")] + public SharedVector3 center; + + private BoxCollider boxCollider; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + boxCollider = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (boxCollider == null) { + Debug.LogWarning("BoxCollider is null"); + return TaskStatus.Failure; + } + + boxCollider.center = center.Value; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + center = Vector3.zero; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/BoxCollider/SetCenter.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/BoxCollider/SetCenter.cs.meta new file mode 100644 index 0000000..9b200de --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/BoxCollider/SetCenter.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 45b3b4dc79247bd46a9c2b11fa9b125c +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/BoxCollider/SetSize.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/BoxCollider/SetSize.cs new file mode 100644 index 0000000..82e8b92 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/BoxCollider/SetSize.cs @@ -0,0 +1,44 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityBoxCollider +{ + [TaskCategory("Unity/BoxCollider")] + [TaskDescription("Sets the size of the BoxCollider. Returns Success.")] + public class SetSize : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The size of the BoxCollider")] + public SharedVector3 size; + + private BoxCollider boxCollider; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + boxCollider = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (boxCollider == null) { + Debug.LogWarning("BoxCollider is null"); + return TaskStatus.Failure; + } + + boxCollider.size = size.Value; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + size = Vector3.zero; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/BoxCollider/SetSize.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/BoxCollider/SetSize.cs.meta new file mode 100644 index 0000000..ec6c848 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/BoxCollider/SetSize.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: d899b6ed83f6e264f8e5867cf68c0cda +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/BoxCollider2D.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/BoxCollider2D.meta new file mode 100644 index 0000000..8093c21 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/BoxCollider2D.meta @@ -0,0 +1,4 @@ +fileFormatVersion: 2 +guid: c7814e7f18119144182f77f9b2a01af2 +DefaultImporter: + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/BoxCollider2D/GetSize.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/BoxCollider2D/GetSize.cs new file mode 100644 index 0000000..b352537 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/BoxCollider2D/GetSize.cs @@ -0,0 +1,45 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityBoxCollider2D +{ + [TaskCategory("Unity/BoxCollider2D")] + [TaskDescription("Stores the size of the BoxCollider2D. Returns Success.")] + public class GetSize : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The size of the BoxCollider2D")] + [RequiredField] + public SharedVector2 storeValue; + + private BoxCollider2D boxCollider2D; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + boxCollider2D = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (boxCollider2D == null) { + Debug.LogWarning("BoxCollider2D is null"); + return TaskStatus.Failure; + } + + storeValue.Value = boxCollider2D.size; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + storeValue = Vector2.zero; + } + } +} diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/BoxCollider2D/GetSize.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/BoxCollider2D/GetSize.cs.meta new file mode 100644 index 0000000..84ef28c --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/BoxCollider2D/GetSize.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: c69113b787759f340aacbb9d99a6d654 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/BoxCollider2D/SetSize.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/BoxCollider2D/SetSize.cs new file mode 100644 index 0000000..b58f42b --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/BoxCollider2D/SetSize.cs @@ -0,0 +1,44 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityBoxCollider2D +{ + [TaskCategory("Unity/BoxCollider2D")] + [TaskDescription("Sets the size of the BoxCollider2D. Returns Success.")] + public class SetSize : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The size of the BoxCollider2D")] + public SharedVector2 size; + + private BoxCollider2D boxCollider2D; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + boxCollider2D = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (boxCollider2D == null) { + Debug.LogWarning("BoxCollider2D is null"); + return TaskStatus.Failure; + } + + boxCollider2D.size = size.Value; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + size = Vector2.zero; + } + } +} diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/BoxCollider2D/SetSize.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/BoxCollider2D/SetSize.cs.meta new file mode 100644 index 0000000..661d126 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/BoxCollider2D/SetSize.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 1875fd00045d98848b028015a17aeeaf +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/CapsuleCollider.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/CapsuleCollider.meta new file mode 100644 index 0000000..d777955 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/CapsuleCollider.meta @@ -0,0 +1,4 @@ +fileFormatVersion: 2 +guid: 0cf43865b0892fb48ac285f63910ff97 +DefaultImporter: + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/CapsuleCollider/GetCenter.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/CapsuleCollider/GetCenter.cs new file mode 100644 index 0000000..b979006 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/CapsuleCollider/GetCenter.cs @@ -0,0 +1,45 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityCapsuleCollider +{ + [TaskCategory("Unity/CapsuleCollider")] + [TaskDescription("Stores the center of the CapsuleCollider. Returns Success.")] + public class GetCenter : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The center of the CapsuleCollider")] + [RequiredField] + public SharedVector3 storeValue; + + private CapsuleCollider capsuleCollider; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + capsuleCollider = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (capsuleCollider == null) { + Debug.LogWarning("CapsuleCollider is null"); + return TaskStatus.Failure; + } + + storeValue.Value = capsuleCollider.center; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + storeValue = Vector3.zero; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/CapsuleCollider/GetCenter.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/CapsuleCollider/GetCenter.cs.meta new file mode 100644 index 0000000..e93bd47 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/CapsuleCollider/GetCenter.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 3a032cb4c0b97b844ad53ad7bb2617c3 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/CapsuleCollider/GetDirection.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/CapsuleCollider/GetDirection.cs new file mode 100644 index 0000000..84e8301 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/CapsuleCollider/GetDirection.cs @@ -0,0 +1,45 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityCapsuleCollider +{ + [TaskCategory("Unity/CapsuleCollider")] + [TaskDescription("Stores the direction of the CapsuleCollider. Returns Success.")] + public class GetDirection : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The direction of the CapsuleCollider")] + [RequiredField] + public SharedInt storeValue; + + private CapsuleCollider capsuleCollider; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + capsuleCollider = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (capsuleCollider == null) { + Debug.LogWarning("CapsuleCollider is null"); + return TaskStatus.Failure; + } + + storeValue.Value = capsuleCollider.direction; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + storeValue = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/CapsuleCollider/GetDirection.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/CapsuleCollider/GetDirection.cs.meta new file mode 100644 index 0000000..87c7536 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/CapsuleCollider/GetDirection.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 7e9f2ebb599281345a458fab17aab5fd +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/CapsuleCollider/GetHeight.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/CapsuleCollider/GetHeight.cs new file mode 100644 index 0000000..2028892 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/CapsuleCollider/GetHeight.cs @@ -0,0 +1,45 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityCapsuleCollider +{ + [TaskCategory("Unity/CapsuleCollider")] + [TaskDescription("Gets the height of the CapsuleCollider. Returns Success.")] + public class GetHeight : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The height of the CapsuleCollider")] + [RequiredField] + public SharedFloat storeValue; + + private CapsuleCollider capsuleCollider; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + capsuleCollider = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (capsuleCollider == null) { + Debug.LogWarning("CapsuleCollider is null"); + return TaskStatus.Failure; + } + + storeValue.Value = capsuleCollider.height; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + storeValue = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/CapsuleCollider/GetHeight.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/CapsuleCollider/GetHeight.cs.meta new file mode 100644 index 0000000..d7e5c72 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/CapsuleCollider/GetHeight.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 29e860749600e174aa61dd42be0a3126 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/CapsuleCollider/GetRadius.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/CapsuleCollider/GetRadius.cs new file mode 100644 index 0000000..a489372 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/CapsuleCollider/GetRadius.cs @@ -0,0 +1,45 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityCapsuleCollider +{ + [TaskCategory("Unity/CapsuleCollider")] + [TaskDescription("Stores the radius of the CapsuleCollider. Returns Success.")] + public class GetRadius : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The radius of the CapsuleCollider")] + [RequiredField] + public SharedFloat storeValue; + + private CapsuleCollider capsuleCollider; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + capsuleCollider = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (capsuleCollider == null) { + Debug.LogWarning("CapsuleCollider is null"); + return TaskStatus.Failure; + } + + storeValue.Value = capsuleCollider.radius; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + storeValue = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/CapsuleCollider/GetRadius.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/CapsuleCollider/GetRadius.cs.meta new file mode 100644 index 0000000..f689aa1 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/CapsuleCollider/GetRadius.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: d03b50a6f076c75408ef6e843bd75539 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/CapsuleCollider/SetCenter.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/CapsuleCollider/SetCenter.cs new file mode 100644 index 0000000..edc0ede --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/CapsuleCollider/SetCenter.cs @@ -0,0 +1,44 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityCapsuleCollider +{ + [TaskCategory("Unity/CapsuleCollider")] + [TaskDescription("Sets the center of the CapsuleCollider. Returns Success.")] + public class SetCenter : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The center of the CapsuleCollider")] + public SharedVector3 center; + + private CapsuleCollider capsuleCollider; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + capsuleCollider = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (capsuleCollider == null) { + Debug.LogWarning("CapsuleCollider is null"); + return TaskStatus.Failure; + } + + capsuleCollider.center = center.Value; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + center = Vector3.zero; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/CapsuleCollider/SetCenter.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/CapsuleCollider/SetCenter.cs.meta new file mode 100644 index 0000000..2593282 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/CapsuleCollider/SetCenter.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: f8292285661aa7e4086c0b59926632c3 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/CapsuleCollider/SetDirection.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/CapsuleCollider/SetDirection.cs new file mode 100644 index 0000000..f4a8c72 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/CapsuleCollider/SetDirection.cs @@ -0,0 +1,44 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityCapsuleCollider +{ + [TaskCategory("Unity/CapsuleCollider")] + [TaskDescription("Sets the direction of the CapsuleCollider. Returns Success.")] + public class SetDirection : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The direction of the CapsuleCollider")] + public SharedInt direction; + + private CapsuleCollider capsuleCollider; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + capsuleCollider = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (capsuleCollider == null) { + Debug.LogWarning("CapsuleCollider is null"); + return TaskStatus.Failure; + } + + capsuleCollider.direction = direction.Value; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + direction = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/CapsuleCollider/SetDirection.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/CapsuleCollider/SetDirection.cs.meta new file mode 100644 index 0000000..2784514 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/CapsuleCollider/SetDirection.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 4146b45b3a598294f86dbbac03e6e8cb +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/CapsuleCollider/SetHeight.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/CapsuleCollider/SetHeight.cs new file mode 100644 index 0000000..18906dd --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/CapsuleCollider/SetHeight.cs @@ -0,0 +1,44 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityCapsuleCollider +{ + [TaskCategory("Unity/CapsuleCollider")] + [TaskDescription("Sets the height of the CapsuleCollider. Returns Success.")] + public class SetHeight : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The height of the CapsuleCollider")] + public SharedFloat direction; + + private CapsuleCollider capsuleCollider; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + capsuleCollider = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (capsuleCollider == null) { + Debug.LogWarning("CapsuleCollider is null"); + return TaskStatus.Failure; + } + + capsuleCollider.height = direction.Value; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + direction = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/CapsuleCollider/SetHeight.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/CapsuleCollider/SetHeight.cs.meta new file mode 100644 index 0000000..62d5f9c --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/CapsuleCollider/SetHeight.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 34f947c079c1159488c80854ee53ecd8 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/CapsuleCollider/SetRadius.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/CapsuleCollider/SetRadius.cs new file mode 100644 index 0000000..16c15b8 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/CapsuleCollider/SetRadius.cs @@ -0,0 +1,44 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityCapsuleCollider +{ + [TaskCategory("Unity/CapsuleCollider")] + [TaskDescription("Sets the radius of the CapsuleCollider. Returns Success.")] + public class SetRadius : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The radius of the CapsuleCollider")] + public SharedFloat radius; + + private CapsuleCollider capsuleCollider; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + capsuleCollider = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (capsuleCollider == null) { + Debug.LogWarning("CapsuleCollider is null"); + return TaskStatus.Failure; + } + + capsuleCollider.radius = radius.Value; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + radius = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/CapsuleCollider/SetRadius.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/CapsuleCollider/SetRadius.cs.meta new file mode 100644 index 0000000..a6d7a74 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/CapsuleCollider/SetRadius.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: fed5a0f5604af324cb2e4a3ed9315793 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/CharacterController.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/CharacterController.meta new file mode 100644 index 0000000..65989b5 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/CharacterController.meta @@ -0,0 +1,4 @@ +fileFormatVersion: 2 +guid: 4b58bcba0c40cfc448a1f2a5f2a57c57 +DefaultImporter: + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/CharacterController/GetCenter.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/CharacterController/GetCenter.cs new file mode 100644 index 0000000..1e2769b --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/CharacterController/GetCenter.cs @@ -0,0 +1,45 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityCharacterController +{ + [TaskCategory("Unity/CharacterController")] + [TaskDescription("Stores the center of the CharacterController. Returns Success.")] + public class GetCenter : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The center of the CharacterController")] + [RequiredField] + public SharedVector3 storeValue; + + private CharacterController characterController; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + characterController = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (characterController == null) { + Debug.LogWarning("CharacterController is null"); + return TaskStatus.Failure; + } + + storeValue.Value = characterController.center; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + storeValue = Vector3.zero; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/CharacterController/GetCenter.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/CharacterController/GetCenter.cs.meta new file mode 100644 index 0000000..0e50703 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/CharacterController/GetCenter.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: e4033e3d9c7ef994ba600b3afec28a0d +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/CharacterController/GetHeight.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/CharacterController/GetHeight.cs new file mode 100644 index 0000000..8a01b49 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/CharacterController/GetHeight.cs @@ -0,0 +1,44 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityCharacterController +{ + [TaskCategory("Unity/CharacterController")] + [TaskDescription("Stores the height of the CharacterController. Returns Success.")] + public class GetHeight : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The height of the CharacterController")] + [RequiredField] + public SharedFloat storeValue; + + private CharacterController characterController; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + characterController = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (characterController == null) { + Debug.LogWarning("CharacterController is null"); + return TaskStatus.Failure; + } + storeValue.Value = characterController.height; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + storeValue = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/CharacterController/GetHeight.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/CharacterController/GetHeight.cs.meta new file mode 100644 index 0000000..b503d89 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/CharacterController/GetHeight.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: eec31e6d5685c674fa2952757b4adf9a +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/CharacterController/GetRadius.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/CharacterController/GetRadius.cs new file mode 100644 index 0000000..2179911 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/CharacterController/GetRadius.cs @@ -0,0 +1,45 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityCharacterController +{ + [TaskCategory("Unity/CharacterController")] + [TaskDescription("Stores the radius of the CharacterController. Returns Success.")] + public class GetRadius : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The radius of the CharacterController")] + [RequiredField] + public SharedFloat storeValue; + + private CharacterController characterController; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + characterController = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (characterController == null) { + Debug.LogWarning("CharacterController is null"); + return TaskStatus.Failure; + } + + storeValue.Value = characterController.radius; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + storeValue = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/CharacterController/GetRadius.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/CharacterController/GetRadius.cs.meta new file mode 100644 index 0000000..0204380 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/CharacterController/GetRadius.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 3bf330244cdea3b43ad95e8731fdb78b +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/CharacterController/GetSlopeLimit.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/CharacterController/GetSlopeLimit.cs new file mode 100644 index 0000000..bc936a6 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/CharacterController/GetSlopeLimit.cs @@ -0,0 +1,45 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityCharacterController +{ + [TaskCategory("Unity/CharacterController")] + [TaskDescription("Stores the slope limit of the CharacterController. Returns Success.")] + public class GetSlopeLimit : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The slope limit of the CharacterController")] + [RequiredField] + public SharedFloat storeValue; + + private CharacterController characterController; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + characterController = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (characterController == null) { + Debug.LogWarning("CharacterController is null"); + return TaskStatus.Failure; + } + + storeValue.Value = characterController.slopeLimit; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + storeValue = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/CharacterController/GetSlopeLimit.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/CharacterController/GetSlopeLimit.cs.meta new file mode 100644 index 0000000..7cec83c --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/CharacterController/GetSlopeLimit.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 3cb445c34dce1a14aa5134278025ec59 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/CharacterController/GetStepOffset.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/CharacterController/GetStepOffset.cs new file mode 100644 index 0000000..348d4f0 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/CharacterController/GetStepOffset.cs @@ -0,0 +1,45 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityCharacterController +{ + [TaskCategory("Unity/CharacterController")] + [TaskDescription("Stores the step offset of the CharacterController. Returns Success.")] + public class GetStepOffset : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The step offset of the CharacterController")] + [RequiredField] + public SharedFloat storeValue; + + private CharacterController characterController; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + characterController = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (characterController == null) { + Debug.LogWarning("CharacterController is null"); + return TaskStatus.Failure; + } + + storeValue.Value = characterController.stepOffset; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + storeValue = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/CharacterController/GetStepOffset.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/CharacterController/GetStepOffset.cs.meta new file mode 100644 index 0000000..c07cb4e --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/CharacterController/GetStepOffset.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: d9bb8d4be247f4d4cb9b2b05a6efd48f +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/CharacterController/GetVelocity.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/CharacterController/GetVelocity.cs new file mode 100644 index 0000000..ada878a --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/CharacterController/GetVelocity.cs @@ -0,0 +1,45 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityCharacterController +{ + [TaskCategory("Unity/CharacterController")] + [TaskDescription("Stores the velocity of the CharacterController. Returns Success.")] + public class GetVelocity : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The velocity of the CharacterController")] + [RequiredField] + public SharedVector3 storeValue; + + private CharacterController characterController; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + characterController = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (characterController == null) { + Debug.LogWarning("CharacterController is null"); + return TaskStatus.Failure; + } + + storeValue.Value = characterController.velocity; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + storeValue = Vector3.zero; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/CharacterController/GetVelocity.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/CharacterController/GetVelocity.cs.meta new file mode 100644 index 0000000..942c99c --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/CharacterController/GetVelocity.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 783c920567425bd4c9385eeaf8099ea4 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/CharacterController/HasColliderHit.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/CharacterController/HasColliderHit.cs new file mode 100644 index 0000000..0eea080 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/CharacterController/HasColliderHit.cs @@ -0,0 +1,43 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityCharacterController +{ + [TaskCategory("Unity/CharacterController")] + [TaskDescription("Returns Success if the collider hit another object, otherwise Failure.")] + public class HasColliderHit : Conditional + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The tag of the GameObject to check for a collision against")] + public SharedString tag = ""; + [Tooltip("The object that started the collision")] + public SharedGameObject collidedGameObject; + + private bool enteredCollision = false; + + public override TaskStatus OnUpdate() + { + return enteredCollision ? TaskStatus.Success : TaskStatus.Failure; + } + + public override void OnEnd() + { + enteredCollision = false; + } + + public override void OnControllerColliderHit(ControllerColliderHit hit) + { + if (string.IsNullOrEmpty(tag.Value) || tag.Value.Equals(hit.gameObject.tag)) { + collidedGameObject.Value = hit.gameObject; + enteredCollision = true; + } + } + + public override void OnReset() + { + targetGameObject = null; + tag = ""; + collidedGameObject = null; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/CharacterController/HasColliderHit.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/CharacterController/HasColliderHit.cs.meta new file mode 100644 index 0000000..992f423 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/CharacterController/HasColliderHit.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 9ff7c43d9df5279489455a4ce2eb3b20 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/CharacterController/IsGrounded.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/CharacterController/IsGrounded.cs new file mode 100644 index 0000000..076cc3c --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/CharacterController/IsGrounded.cs @@ -0,0 +1,39 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityCharacterController +{ + [TaskCategory("Unity/CharacterController")] + [TaskDescription("Returns Success if the character is grounded, otherwise Failure.")] + public class IsGrounded : Conditional + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + + private CharacterController characterController; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + characterController = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (characterController == null) { + Debug.LogWarning("CharacterController is null"); + return TaskStatus.Failure; + } + + return characterController.isGrounded ? TaskStatus.Success : TaskStatus.Failure; + } + + public override void OnReset() + { + targetGameObject = null; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/CharacterController/IsGrounded.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/CharacterController/IsGrounded.cs.meta new file mode 100644 index 0000000..88c9d64 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/CharacterController/IsGrounded.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: e8541a996b0a37b4f8bce82dd23ddb84 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/CharacterController/Move.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/CharacterController/Move.cs new file mode 100644 index 0000000..ec9de43 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/CharacterController/Move.cs @@ -0,0 +1,44 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityCharacterController +{ + [TaskCategory("Unity/CharacterController")] + [TaskDescription("A more complex move function taking absolute movement deltas. Returns Success.")] + public class Move : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The amount to move")] + public SharedVector3 motion; + + private CharacterController characterController; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + characterController = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (characterController == null) { + Debug.LogWarning("CharacterController is null"); + return TaskStatus.Failure; + } + + characterController.Move(motion.Value); + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + motion = Vector3.zero; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/CharacterController/Move.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/CharacterController/Move.cs.meta new file mode 100644 index 0000000..ef8b792 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/CharacterController/Move.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 546770f14f8265d4c83b94210630b644 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/CharacterController/SetCenter.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/CharacterController/SetCenter.cs new file mode 100644 index 0000000..58d527c --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/CharacterController/SetCenter.cs @@ -0,0 +1,44 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityCharacterController +{ + [TaskCategory("Unity/CharacterController")] + [TaskDescription("Sets the center of the CharacterController. Returns Success.")] + public class SetCenter : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The center of the CharacterController")] + public SharedVector3 center; + + private CharacterController characterController; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + characterController = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (characterController == null) { + Debug.LogWarning("CharacterController is null"); + return TaskStatus.Failure; + } + + characterController.center = center.Value; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + center = Vector3.zero; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/CharacterController/SetCenter.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/CharacterController/SetCenter.cs.meta new file mode 100644 index 0000000..9ceb03c --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/CharacterController/SetCenter.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 1072c5d1f7d15b24d811ee2e52f5806f +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/CharacterController/SetHeight.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/CharacterController/SetHeight.cs new file mode 100644 index 0000000..83020a3 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/CharacterController/SetHeight.cs @@ -0,0 +1,44 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityCharacterController +{ + [TaskCategory("Unity/CharacterController")] + [TaskDescription("Sets the height of the CharacterController. Returns Success.")] + public class SetHeight : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The height of the CharacterController")] + public SharedFloat height; + + private CharacterController characterController; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + characterController = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (characterController == null) { + Debug.LogWarning("CharacterController is null"); + return TaskStatus.Failure; + } + + characterController.height = height.Value; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + height = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/CharacterController/SetHeight.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/CharacterController/SetHeight.cs.meta new file mode 100644 index 0000000..7f0a13a --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/CharacterController/SetHeight.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: f3646fc892390f443ab43e4313cd0c6a +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/CharacterController/SetRadius.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/CharacterController/SetRadius.cs new file mode 100644 index 0000000..acf866e --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/CharacterController/SetRadius.cs @@ -0,0 +1,44 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityCharacterController +{ + [TaskCategory("Unity/CharacterController")] + [TaskDescription("Sets the radius of the CharacterController. Returns Success.")] + public class SetRadius : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The radius of the CharacterController")] + public SharedFloat radius; + + private CharacterController characterController; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + characterController = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (characterController == null) { + Debug.LogWarning("CharacterController is null"); + return TaskStatus.Failure; + } + + characterController.radius = radius.Value; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + radius = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/CharacterController/SetRadius.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/CharacterController/SetRadius.cs.meta new file mode 100644 index 0000000..078d95a --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/CharacterController/SetRadius.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: d3d7c584aef3bd5468165685a1975862 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/CharacterController/SetSlopeLimit.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/CharacterController/SetSlopeLimit.cs new file mode 100644 index 0000000..f265d1a --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/CharacterController/SetSlopeLimit.cs @@ -0,0 +1,44 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityCharacterController +{ + [TaskCategory("Unity/CharacterController")] + [TaskDescription("Sets the slope limit of the CharacterController. Returns Success.")] + public class SetSlopeLimit : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The slope limit of the CharacterController")] + public SharedFloat slopeLimit; + + private CharacterController characterController; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + characterController = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (characterController == null) { + Debug.LogWarning("CharacterController is null"); + return TaskStatus.Failure; + } + + characterController.slopeLimit = slopeLimit.Value; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + slopeLimit = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/CharacterController/SetSlopeLimit.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/CharacterController/SetSlopeLimit.cs.meta new file mode 100644 index 0000000..353704a --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/CharacterController/SetSlopeLimit.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 65d4ccec4c868584a89d9037a6eec3e6 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/CharacterController/SetStepOffset.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/CharacterController/SetStepOffset.cs new file mode 100644 index 0000000..4696d64 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/CharacterController/SetStepOffset.cs @@ -0,0 +1,44 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityCharacterController +{ + [TaskCategory("Unity/CharacterController")] + [TaskDescription("Sets the step offset of the CharacterController. Returns Success.")] + public class SetStepOffset : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The step offset of the CharacterController")] + public SharedFloat stepOffset; + + private CharacterController characterController; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + characterController = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (characterController == null) { + Debug.LogWarning("CharacterController is null"); + return TaskStatus.Failure; + } + + characterController.stepOffset = stepOffset.Value; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + stepOffset = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/CharacterController/SetStepOffset.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/CharacterController/SetStepOffset.cs.meta new file mode 100644 index 0000000..dfabde0 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/CharacterController/SetStepOffset.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: b062e83de9feb8a41a9e4989f2d65b97 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/CharacterController/SimpleMove.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/CharacterController/SimpleMove.cs new file mode 100644 index 0000000..ccd853e --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/CharacterController/SimpleMove.cs @@ -0,0 +1,44 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityCharacterController +{ + [TaskCategory("Unity/CharacterController")] + [TaskDescription("Moves the character with speed. Returns Success.")] + public class SimpleMove : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The speed of the movement")] + public SharedVector3 speed; + + private CharacterController characterController; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + characterController = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (characterController == null) { + Debug.LogWarning("CharacterController is null"); + return TaskStatus.Failure; + } + + characterController.SimpleMove(speed.Value); + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + speed = Vector3.zero; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/CharacterController/SimpleMove.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/CharacterController/SimpleMove.cs.meta new file mode 100644 index 0000000..7a567a4 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/CharacterController/SimpleMove.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: c760a29b8a35c044d87b7a80a58f046c +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/CircleCollider2D.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/CircleCollider2D.meta new file mode 100644 index 0000000..bde0971 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/CircleCollider2D.meta @@ -0,0 +1,4 @@ +fileFormatVersion: 2 +guid: e179f1af407aa8b469c6d96d7c0e2563 +DefaultImporter: + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/CircleCollider2D/GetOffset.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/CircleCollider2D/GetOffset.cs new file mode 100644 index 0000000..f1e0d2f --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/CircleCollider2D/GetOffset.cs @@ -0,0 +1,45 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityCircleCollider2D +{ + [TaskCategory("Unity/CircleCollider2D")] + [TaskDescription("Stores the offset of the CircleCollider2D. Returns Success.")] + public class GetOffset : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The offset of the CircleCollider2D")] + [RequiredField] + public SharedVector3 storeValue; + + private CircleCollider2D circleCollider2D; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + circleCollider2D = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (circleCollider2D == null) { + Debug.LogWarning("CircleCollider2D is null"); + return TaskStatus.Failure; + } + + storeValue.Value = circleCollider2D.offset; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + storeValue = Vector3.zero; + } + } +} diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/CircleCollider2D/GetOffset.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/CircleCollider2D/GetOffset.cs.meta new file mode 100644 index 0000000..b2882e1 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/CircleCollider2D/GetOffset.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 336c692acc5ff024988b77803ca15fac +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/CircleCollider2D/GetRadius.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/CircleCollider2D/GetRadius.cs new file mode 100644 index 0000000..24f5f05 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/CircleCollider2D/GetRadius.cs @@ -0,0 +1,45 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityCircleCollider2D +{ + [TaskCategory("Unity/CircleCollider2D")] + [TaskDescription("Stores the radius of the CircleCollider2D. Returns Success.")] + public class GetRadius : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The radius of the CircleCollider2D")] + [RequiredField] + public SharedFloat storeValue; + + private CircleCollider2D circleCollider2D; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + circleCollider2D = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (circleCollider2D == null) { + Debug.LogWarning("CircleCollider2D is null"); + return TaskStatus.Failure; + } + + storeValue.Value = circleCollider2D.radius; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + storeValue = 0; + } + } +} diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/CircleCollider2D/GetRadius.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/CircleCollider2D/GetRadius.cs.meta new file mode 100644 index 0000000..8a69e83 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/CircleCollider2D/GetRadius.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 5301adcc69414e44681c1d4dc7ecde58 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/CircleCollider2D/SetOffset.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/CircleCollider2D/SetOffset.cs new file mode 100644 index 0000000..c82abcf --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/CircleCollider2D/SetOffset.cs @@ -0,0 +1,44 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityCircleCollider2D +{ + [TaskCategory("Unity/CircleCollider2D")] + [TaskDescription("Sets the offset of the CircleCollider2D. Returns Success.")] + public class SetOffset : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The offset of the CircleCollider2D")] + public SharedVector3 offset; + + private CircleCollider2D circleCollider2D; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + circleCollider2D = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (circleCollider2D == null) { + Debug.LogWarning("CircleCollider2D is null"); + return TaskStatus.Failure; + } + + circleCollider2D.offset = offset.Value; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + offset = Vector3.zero; + } + } +} diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/CircleCollider2D/SetOffset.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/CircleCollider2D/SetOffset.cs.meta new file mode 100644 index 0000000..16aeb13 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/CircleCollider2D/SetOffset.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 6784dbe1d7c00c44bbd9ec3557c10053 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/CircleCollider2D/SetRadius.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/CircleCollider2D/SetRadius.cs new file mode 100644 index 0000000..3613f51 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/CircleCollider2D/SetRadius.cs @@ -0,0 +1,44 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityCircleCollider2D +{ + [TaskCategory("Unity/CircleCollider2D")] + [TaskDescription("Sets the radius of the CircleCollider2D. Returns Success.")] + public class SetRadius : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The radius of the CircleCollider2D")] + public SharedFloat radius; + + private CircleCollider2D circleCollider2D; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + circleCollider2D = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (circleCollider2D == null) { + Debug.LogWarning("CircleCollider2D is null"); + return TaskStatus.Failure; + } + + circleCollider2D.radius = radius.Value; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + radius = 0; + } + } +} diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/CircleCollider2D/SetRadius.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/CircleCollider2D/SetRadius.cs.meta new file mode 100644 index 0000000..863ba50 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/CircleCollider2D/SetRadius.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: a9f837093c996864d95d92cae654a8ba +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Collider.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Collider.meta new file mode 100644 index 0000000..ce4182f --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Collider.meta @@ -0,0 +1,10 @@ +fileFormatVersion: 2 +guid: cb2dc414c7a533a4da3e56a73ffae66a +folderAsset: yes +timeCreated: 1567507235 +licenseType: Store +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Collider/GetEnabled.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Collider/GetEnabled.cs new file mode 100644 index 0000000..9f37e3a --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Collider/GetEnabled.cs @@ -0,0 +1,33 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.Collider +{ + [TaskCategory("Unity/Collider")] + [TaskDescription("Stores the enabled state of the collider. Returns Success.")] + public class GetEnabled : Action + { + [Tooltip("The Collider to use")] + public SharedCollider specifiedCollider; + [Tooltip("The enabled/disabled state")] + [RequiredField] + public SharedBool storeValue; + + public override TaskStatus OnUpdate() + { + if (specifiedCollider == null) { + Debug.LogWarning("SpecifiedObject is null"); + return TaskStatus.Failure; + } + + storeValue.Value = specifiedCollider.Value.enabled; + + return TaskStatus.Success; + } + + public override void OnReset() + { + specifiedCollider.Value = null; + storeValue = false; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Collider/GetEnabled.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Collider/GetEnabled.cs.meta new file mode 100644 index 0000000..665b546 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Collider/GetEnabled.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 5c25d5e795c9ec5498489871de79c3b4 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Collider/SetEnabled.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Collider/SetEnabled.cs new file mode 100644 index 0000000..3c2bcff --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Collider/SetEnabled.cs @@ -0,0 +1,32 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.Collider +{ + [TaskCategory("Unity/Collider")] + [TaskDescription("Enables/Disables the collider. Returns Success.")] + public class SetEnabled : Action + { + [Tooltip("The Behavior to use")] + public SharedCollider specifiedCollider; + [Tooltip("The enabled/disabled state")] + public SharedBool enabled; + + public override TaskStatus OnUpdate() + { + if (specifiedCollider == null) { + Debug.LogWarning("SpecifiedCollider is null"); + return TaskStatus.Failure; + } + + specifiedCollider.Value.enabled = enabled.Value; + + return TaskStatus.Success; + } + + public override void OnReset() + { + specifiedCollider.Value = null; + enabled = false; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Collider/SetEnabled.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Collider/SetEnabled.cs.meta new file mode 100644 index 0000000..14ae742 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Collider/SetEnabled.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: b09a9f05408671b4fbdda3531c9fe9d8 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Debug.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Debug.meta new file mode 100644 index 0000000..fd66ec6 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Debug.meta @@ -0,0 +1,4 @@ +fileFormatVersion: 2 +guid: d1140cef910ebcb4fa9817c4ec7fe2df +DefaultImporter: + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Debug/DrawLine.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Debug/DrawLine.cs new file mode 100644 index 0000000..2889d1a --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Debug/DrawLine.cs @@ -0,0 +1,36 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityDebug +{ + [TaskCategory("Unity/Debug")] + [TaskDescription("Draws a debug line")] + public class DrawLine : Action + { + [Tooltip("The start position")] + public SharedVector3 start; + [Tooltip("The end position")] + public SharedVector3 end; + [Tooltip("The color")] + public SharedColor color = Color.white; + [Tooltip("Duration the line will be visible for in seconds.\nDefault: 0 means 1 frame.")] + public SharedFloat duration; + [Tooltip("Whether the line should show through world geometry.")] + public SharedBool depthTest = true; + + public override TaskStatus OnUpdate() + { + Debug.DrawLine(start.Value, end.Value, color.Value, duration.Value, depthTest.Value); + + return TaskStatus.Success; + } + + public override void OnReset() + { + start = Vector3.zero; + end = Vector3.zero; + color = Color.white; + duration = 0f; + depthTest = true; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Debug/DrawLine.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Debug/DrawLine.cs.meta new file mode 100644 index 0000000..f7d4380 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Debug/DrawLine.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 66a533f4f027ab44bb35e498d761ce50 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Debug/DrawRay.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Debug/DrawRay.cs new file mode 100644 index 0000000..34d064e --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Debug/DrawRay.cs @@ -0,0 +1,30 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityDebug +{ + [TaskCategory("Unity/Debug")] + [TaskDescription("Draws a debug ray")] + public class DrawRay : Action + { + [Tooltip("The position")] + public SharedVector3 start; + [Tooltip("The direction")] + public SharedVector3 direction; + [Tooltip("The color")] + public SharedColor color = Color.white; + + public override TaskStatus OnUpdate() + { + Debug.DrawRay(start.Value, direction.Value, color.Value); + + return TaskStatus.Success; + } + + public override void OnReset() + { + start = Vector3.zero; + direction = Vector3.zero; + color = Color.white; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Debug/DrawRay.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Debug/DrawRay.cs.meta new file mode 100644 index 0000000..63a767b --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Debug/DrawRay.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 786ac0c09ce982e43b444670fdfe4c74 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Debug/LogFormat.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Debug/LogFormat.cs new file mode 100644 index 0000000..3536d51 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Debug/LogFormat.cs @@ -0,0 +1,76 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityDebug +{ + [TaskDescription("LogFormat is analgous to Debug.LogFormat().\n" + + "It takes format string, substitutes arguments supplied a '{0-4}' and returns success.\n" + + "Any fields or arguments not supplied are ignored." + + "It can be used for debugging.")] + [TaskIcon("{SkinColor}LogIcon.png")] + public class LogFormat : Action + { + [Tooltip("Text format with {0}, {1}, etc")] + public SharedString textFormat; + + [Tooltip("Is this text an error?")] + public SharedBool logError; + + public SharedVariable arg0; + public SharedVariable arg1; + public SharedVariable arg2; + public SharedVariable arg3; + + public override TaskStatus OnUpdate() + { + var paramsArray = buildParamsArray(); + // Log the text and return success + if (logError.Value) { + Debug.LogErrorFormat(textFormat.Value, paramsArray); + } else { + Debug.LogFormat(textFormat.Value, paramsArray); + } + return TaskStatus.Success; + } + + private object[] buildParamsArray() { + object[] paramsArray; + if (isValid(arg3)) { + paramsArray = new object[4]; + paramsArray[3] = arg3.GetValue(); + paramsArray[2] = arg2.GetValue(); + paramsArray[1] = arg1.GetValue(); + paramsArray[0] = arg0.GetValue(); + } else if (isValid(arg2)) { + paramsArray = new object[3]; + paramsArray[2] = arg2.GetValue(); + paramsArray[1] = arg1.GetValue(); + paramsArray[0] = arg0.GetValue(); + } else if (isValid(arg1)) { + paramsArray = new object[2]; + paramsArray[1] = arg1.GetValue(); + paramsArray[0] = arg0.GetValue(); + } else if (isValid(arg0)) { + paramsArray = new object[1]; + paramsArray[0] = arg0.GetValue(); + } else { + return null; + } + return paramsArray; + } + + private bool isValid(SharedVariable sv) { + return null != sv && !sv.IsNone; + } + + public override void OnReset() + { + // Reset the properties back to their original values + textFormat = string.Empty; + logError = false; + arg0 = null; + arg1 = null; + arg2 = null; + arg3 = null; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Debug/LogFormat.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Debug/LogFormat.cs.meta new file mode 100644 index 0000000..07abe00 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Debug/LogFormat.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 70765819b419e8a45b326e92edf17ef5 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Debug/LogValue.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Debug/LogValue.cs new file mode 100644 index 0000000..96b5057 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Debug/LogValue.cs @@ -0,0 +1,24 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityDebug +{ + [TaskCategory("Unity/Debug")] + [TaskDescription("Log a variable value.")] + public class LogValue : Action + { + [Tooltip("The variable to output")] + public SharedGenericVariable variable; + + public override TaskStatus OnUpdate() + { + Debug.Log(variable.Value.value.GetValue()); + + return TaskStatus.Success; + } + + public override void OnReset() + { + variable = null; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Debug/LogValue.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Debug/LogValue.cs.meta new file mode 100644 index 0000000..75817e5 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Debug/LogValue.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: c50983a88995f4f4197f7b39ca796667 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/GameObject.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/GameObject.meta new file mode 100644 index 0000000..c0d4b94 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/GameObject.meta @@ -0,0 +1,4 @@ +fileFormatVersion: 2 +guid: c03de85966f0a834383cef512841e4a9 +DefaultImporter: + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/GameObject/ActiveInHierarchy.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/GameObject/ActiveInHierarchy.cs new file mode 100644 index 0000000..ea41a2d --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/GameObject/ActiveInHierarchy.cs @@ -0,0 +1,22 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityGameObject +{ + [TaskCategory("Unity/GameObject")] + [TaskDescription("Returns Success if the GameObject is active in the hierarchy, otherwise Failure.")] + public class ActiveInHierarchy : Conditional + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + + public override TaskStatus OnUpdate() + { + return GetDefaultGameObject(targetGameObject.Value).activeInHierarchy ? TaskStatus.Success : TaskStatus.Failure; + } + + public override void OnReset() + { + targetGameObject = null; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/GameObject/ActiveInHierarchy.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/GameObject/ActiveInHierarchy.cs.meta new file mode 100644 index 0000000..68716f6 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/GameObject/ActiveInHierarchy.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 0bbe57db7a21ee94f86aef75bbcd6d18 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/GameObject/ActiveSelf.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/GameObject/ActiveSelf.cs new file mode 100644 index 0000000..71a644b --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/GameObject/ActiveSelf.cs @@ -0,0 +1,22 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityGameObject +{ + [TaskCategory("Unity/GameObject")] + [TaskDescription("Returns Success if the GameObject is active in the hierarchy, otherwise Failure.")] + public class ActiveSelf : Conditional + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + + public override TaskStatus OnUpdate() + { + return GetDefaultGameObject(targetGameObject.Value).activeSelf ? TaskStatus.Success : TaskStatus.Failure; + } + + public override void OnReset() + { + targetGameObject = null; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/GameObject/ActiveSelf.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/GameObject/ActiveSelf.cs.meta new file mode 100644 index 0000000..744eada --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/GameObject/ActiveSelf.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 26a4530d0ecaa774aaf060511089ddc3 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/GameObject/CompareLayer.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/GameObject/CompareLayer.cs new file mode 100644 index 0000000..c7da78d --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/GameObject/CompareLayer.cs @@ -0,0 +1,24 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityGameObject +{ + [TaskCategory("Unity/GameObject")] + [TaskDescription("Returns Success if the layermasks match, otherwise Failure.")] + public class CompareLayerMask : Conditional + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The layermask to compare against")] + public LayerMask layermask; + + public override TaskStatus OnUpdate() + { + return ((1 << GetDefaultGameObject(targetGameObject.Value).layer) & layermask.value) != 0 ? TaskStatus.Success : TaskStatus.Failure; + } + + public override void OnReset() + { + targetGameObject = null; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/GameObject/CompareLayer.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/GameObject/CompareLayer.cs.meta new file mode 100644 index 0000000..35f4bfa --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/GameObject/CompareLayer.cs.meta @@ -0,0 +1,12 @@ +fileFormatVersion: 2 +guid: 1458e688aa4cc8449bd37ebdcf7903d6 +timeCreated: 1503157605 +licenseType: Store +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/GameObject/CompareTag.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/GameObject/CompareTag.cs new file mode 100644 index 0000000..b91e094 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/GameObject/CompareTag.cs @@ -0,0 +1,25 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityGameObject +{ + [TaskCategory("Unity/GameObject")] + [TaskDescription("Returns Success if tags match, otherwise Failure.")] + public class CompareTag : Conditional + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The tag to compare against")] + public SharedString tag; + + public override TaskStatus OnUpdate() + { + return GetDefaultGameObject(targetGameObject.Value).CompareTag(tag.Value) ? TaskStatus.Success : TaskStatus.Failure; + } + + public override void OnReset() + { + targetGameObject = null; + tag = ""; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/GameObject/CompareTag.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/GameObject/CompareTag.cs.meta new file mode 100644 index 0000000..3172ece --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/GameObject/CompareTag.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: fa50c2eedc866794890ff361bdd1d593 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/GameObject/Destroy.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/GameObject/Destroy.cs new file mode 100644 index 0000000..b91d45b --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/GameObject/Destroy.cs @@ -0,0 +1,32 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityGameObject +{ + [TaskCategory("Unity/GameObject")] + [TaskDescription("Destorys the specified GameObject. Returns Success.")] + public class Destroy : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("Time to destroy the GameObject in")] + public float time; + + public override TaskStatus OnUpdate() + { + var destroyGameObject = GetDefaultGameObject(targetGameObject.Value); + if (time == 0) { + GameObject.Destroy(destroyGameObject); + } else { + GameObject.Destroy(destroyGameObject, time); + } + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + time = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/GameObject/Destroy.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/GameObject/Destroy.cs.meta new file mode 100644 index 0000000..2383eac --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/GameObject/Destroy.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 42a90ad4cba90604b8be494aa74df349 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/GameObject/DestroyImmediate.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/GameObject/DestroyImmediate.cs new file mode 100644 index 0000000..600c074 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/GameObject/DestroyImmediate.cs @@ -0,0 +1,25 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityGameObject +{ + [TaskCategory("Unity/GameObject")] + [TaskDescription("Destorys the specified GameObject immediately. Returns Success.")] + public class DestroyImmediate : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + + public override TaskStatus OnUpdate() + { + var destroyGameObject = GetDefaultGameObject(targetGameObject.Value); + GameObject.DestroyImmediate(destroyGameObject); + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/GameObject/DestroyImmediate.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/GameObject/DestroyImmediate.cs.meta new file mode 100644 index 0000000..6c0304d --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/GameObject/DestroyImmediate.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 81f8712bcbdbdbf4aad17ba5e1e20d8c +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/GameObject/Find.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/GameObject/Find.cs new file mode 100644 index 0000000..c7b1f69 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/GameObject/Find.cs @@ -0,0 +1,28 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityGameObject +{ + [TaskCategory("Unity/GameObject")] + [TaskDescription("Finds a GameObject by name. Returns success if an object is found.")] + public class Find : Action + { + [Tooltip("The GameObject name to find")] + public SharedString gameObjectName; + [Tooltip("The object found by name")] + [RequiredField] + public SharedGameObject storeValue; + + public override TaskStatus OnUpdate() + { + storeValue.Value = GameObject.Find(gameObjectName.Value); + + return storeValue.Value != null ? TaskStatus.Success : TaskStatus.Failure; + } + + public override void OnReset() + { + gameObjectName = null; + storeValue = null; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/GameObject/Find.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/GameObject/Find.cs.meta new file mode 100644 index 0000000..4faf58c --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/GameObject/Find.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 5388c9a6fc7770f44885176c24f68aaa +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/GameObject/FindGameObjectsWithTag.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/GameObject/FindGameObjectsWithTag.cs new file mode 100644 index 0000000..9af0c77 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/GameObject/FindGameObjectsWithTag.cs @@ -0,0 +1,31 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityGameObject +{ + [TaskCategory("Unity/GameObject")] + [TaskDescription("Finds a GameObject by tag. Returns Success.")] + public class FindGameObjectsWithTag : Action + { + [Tooltip("The tag of the GameObject to find")] + public SharedString tag; + [Tooltip("The objects found by name")] + [RequiredField] + public SharedGameObjectList storeValue; + + public override TaskStatus OnUpdate() + { + var gameObjects = GameObject.FindGameObjectsWithTag(tag.Value); + for (int i = 0; i < gameObjects.Length; ++i) { + storeValue.Value.Add(gameObjects[i]); + } + + return TaskStatus.Success; + } + + public override void OnReset() + { + tag.Value = null; + storeValue.Value = null; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/GameObject/FindGameObjectsWithTag.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/GameObject/FindGameObjectsWithTag.cs.meta new file mode 100644 index 0000000..731e9e6 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/GameObject/FindGameObjectsWithTag.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: ccc3e1d2bf7cfc74089c17d593472f98 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/GameObject/FindWithTag.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/GameObject/FindWithTag.cs new file mode 100644 index 0000000..f19a286 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/GameObject/FindWithTag.cs @@ -0,0 +1,35 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityGameObject +{ + [TaskCategory("Unity/GameObject")] + [TaskDescription("Finds a GameObject by tag. Returns success if an object is found.")] + public class FindWithTag : Action + { + [Tooltip("The tag of the GameObject to find")] + public SharedString tag; + [Tooltip("Should a random GameObject be found?")] + public SharedBool random; + [Tooltip("The object found by name")] + [RequiredField] + public SharedGameObject storeValue; + + public override TaskStatus OnUpdate() + { + if (random.Value) { + var gameObjects = GameObject.FindGameObjectsWithTag(tag.Value); + storeValue.Value = gameObjects[Random.Range(0, gameObjects.Length)]; + } else { + storeValue.Value = GameObject.FindWithTag(tag.Value); + } + + return storeValue.Value != null ? TaskStatus.Success : TaskStatus.Failure; + } + + public override void OnReset() + { + tag.Value = null; + storeValue.Value = null; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/GameObject/FindWithTag.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/GameObject/FindWithTag.cs.meta new file mode 100644 index 0000000..e62318a --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/GameObject/FindWithTag.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: d8768bdf841982f4aae662ee5dac3f2d +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/GameObject/GetComponent.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/GameObject/GetComponent.cs new file mode 100644 index 0000000..387f3ab --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/GameObject/GetComponent.cs @@ -0,0 +1,31 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityGameObject +{ + [TaskCategory("Unity/GameObject")] + [TaskDescription("Returns the component of Type type if the game object has one attached, null if it doesn't. Returns Success.")] + public class GetComponent : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The type of component")] + public SharedString type; + [Tooltip("The component")] + [RequiredField] + public SharedObject storeValue; + + public override TaskStatus OnUpdate() + { + storeValue.Value = GetDefaultGameObject(targetGameObject.Value).GetComponent(type.Value); + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + type.Value = ""; + storeValue.Value = null; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/GameObject/GetComponent.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/GameObject/GetComponent.cs.meta new file mode 100644 index 0000000..5bf6c59 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/GameObject/GetComponent.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 46e3dd9b1b260584b893abde5f733359 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/GameObject/GetTag.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/GameObject/GetTag.cs new file mode 100644 index 0000000..2d271a3 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/GameObject/GetTag.cs @@ -0,0 +1,28 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityGameObject +{ + [TaskCategory("Unity/GameObject")] + [TaskDescription("Stores the GameObject tag. Returns Success.")] + public class GetTag : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("Active state of the GameObject")] + [RequiredField] + public SharedString storeValue; + + public override TaskStatus OnUpdate() + { + storeValue.Value = GetDefaultGameObject(targetGameObject.Value).tag; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + storeValue = ""; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/GameObject/GetTag.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/GameObject/GetTag.cs.meta new file mode 100644 index 0000000..f63d3d7 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/GameObject/GetTag.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 44bf3273a8802dc408352f165f18c541 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/GameObject/Instantiate.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/GameObject/Instantiate.cs new file mode 100644 index 0000000..c1929e2 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/GameObject/Instantiate.cs @@ -0,0 +1,33 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityGameObject +{ + [TaskCategory("Unity/GameObject")] + [TaskDescription("Instantiates a new GameObject. Returns Success.")] + public class Instantiate : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The position of the new GameObject")] + public SharedVector3 position; + [Tooltip("The rotation of the new GameObject")] + public SharedQuaternion rotation = Quaternion.identity; + [SharedRequired] + [Tooltip("The instantiated GameObject")] + public SharedGameObject storeResult; + + public override TaskStatus OnUpdate() + { + storeResult.Value = GameObject.Instantiate(targetGameObject.Value, position.Value, rotation.Value) as GameObject; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + position = Vector3.zero; + rotation = Quaternion.identity; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/GameObject/Instantiate.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/GameObject/Instantiate.cs.meta new file mode 100644 index 0000000..36b4b33 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/GameObject/Instantiate.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 804a64515d87a0546ad7c6c4408ed53f +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/GameObject/SendMessage.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/GameObject/SendMessage.cs new file mode 100644 index 0000000..354fa41 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/GameObject/SendMessage.cs @@ -0,0 +1,33 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityGameObject +{ + [TaskCategory("Unity/GameObject")] + [TaskDescription("Sends a message to the target GameObject. Returns Success.")] + public class SendMessage : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The message to send")] + public SharedString message; + [Tooltip("The value to send")] + public SharedGenericVariable value; + + public override TaskStatus OnUpdate() + { + if (value.Value != null) { + GetDefaultGameObject(targetGameObject.Value).SendMessage(message.Value, value.Value.value.GetValue()); + } else { + GetDefaultGameObject(targetGameObject.Value).SendMessage(message.Value); + } + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + message = ""; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/GameObject/SendMessage.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/GameObject/SendMessage.cs.meta new file mode 100644 index 0000000..fe7af57 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/GameObject/SendMessage.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: dd0f144b1db34024eaea548f6539d2ae +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/GameObject/SetActive.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/GameObject/SetActive.cs new file mode 100644 index 0000000..f790089 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/GameObject/SetActive.cs @@ -0,0 +1,27 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityGameObject +{ + [TaskCategory("Unity/GameObject")] + [TaskDescription("Activates/Deactivates the GameObject. Returns Success.")] + public class SetActive : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("Active state of the GameObject")] + public SharedBool active; + + public override TaskStatus OnUpdate() + { + GetDefaultGameObject(targetGameObject.Value).SetActive(active.Value); + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + active = false; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/GameObject/SetActive.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/GameObject/SetActive.cs.meta new file mode 100644 index 0000000..70d63ae --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/GameObject/SetActive.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 5237a810dcce11e499c1915171ec670b +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/GameObject/SetTag.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/GameObject/SetTag.cs new file mode 100644 index 0000000..283360b --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/GameObject/SetTag.cs @@ -0,0 +1,27 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityGameObject +{ + [TaskCategory("Unity/GameObject")] + [TaskDescription("Sets the GameObject tag. Returns Success.")] + public class SetTag : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The GameObject tag")] + public SharedString tag; + + public override TaskStatus OnUpdate() + { + GetDefaultGameObject(targetGameObject.Value).tag = tag.Value; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + tag = ""; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/GameObject/SetTag.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/GameObject/SetTag.cs.meta new file mode 100644 index 0000000..3306127 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/GameObject/SetTag.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: e275477e6962d9b4fb90d7930bb6ff5a +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Input.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Input.meta new file mode 100644 index 0000000..56aea24 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Input.meta @@ -0,0 +1,4 @@ +fileFormatVersion: 2 +guid: 77642b8113f3f334d971d61be9516264 +DefaultImporter: + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Input/GetAcceleration.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Input/GetAcceleration.cs new file mode 100644 index 0000000..d1a9f37 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Input/GetAcceleration.cs @@ -0,0 +1,24 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityInput +{ + [TaskCategory("Unity/Input")] + [TaskDescription("Stores the acceleration value.")] + public class GetAcceleration : Action + { + [RequiredField] + [Tooltip("The stored result")] + public SharedVector3 storeResult; + + public override TaskStatus OnUpdate() + { + storeResult.Value = Input.acceleration; + return TaskStatus.Success; + } + + public override void OnReset() + { + storeResult = Vector3.zero; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Input/GetAcceleration.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Input/GetAcceleration.cs.meta new file mode 100644 index 0000000..1e8dfda --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Input/GetAcceleration.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 06e82895d2abea24599ddfd6f0d7386a +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Input/GetAxis.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Input/GetAxis.cs new file mode 100644 index 0000000..6338f95 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Input/GetAxis.cs @@ -0,0 +1,37 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityInput +{ + [TaskCategory("Unity/Input")] + [TaskDescription("Stores the value of the specified axis and stores it in a float.")] + public class GetAxis : Action + { + [Tooltip("The name of the axis")] + public SharedString axisName; + [Tooltip("Axis values are in the range -1 to 1. Use the multiplier to set a larger range")] + public SharedFloat multiplier; + [RequiredField] + [Tooltip("The stored result")] + public SharedFloat storeResult; + + public override TaskStatus OnUpdate() + { + var axisValue = Input.GetAxis(axisName.Value); + + // if variable set to none, assume multiplier of 1 + if (!multiplier.IsNone) { + axisValue *= multiplier.Value; + } + + storeResult.Value = axisValue; + return TaskStatus.Success; + } + + public override void OnReset() + { + axisName = ""; + multiplier = 1.0f; + storeResult = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Input/GetAxis.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Input/GetAxis.cs.meta new file mode 100644 index 0000000..1cd25e7 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Input/GetAxis.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 84fa68d3aa9286f488ee60bb7f420079 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Input/GetAxisRaw.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Input/GetAxisRaw.cs new file mode 100644 index 0000000..8bf1bb0 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Input/GetAxisRaw.cs @@ -0,0 +1,37 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityInput +{ + [TaskCategory("Unity/Input")] + [TaskDescription("Stores the raw value of the specified axis and stores it in a float.")] + public class GetAxisRaw : Action + { + [Tooltip("The name of the axis")] + public SharedString axisName; + [Tooltip("Axis values are in the range -1 to 1. Use the multiplier to set a larger range")] + public SharedFloat multiplier; + [RequiredField] + [Tooltip("The stored result")] + public SharedFloat storeResult; + + public override TaskStatus OnUpdate() + { + var axisValue = Input.GetAxis(axisName.Value); + + // if variable set to none, assume multiplier of 1 + if (!multiplier.IsNone) { + axisValue *= multiplier.Value; + } + + storeResult.Value = axisValue; + return TaskStatus.Success; + } + + public override void OnReset() + { + axisName = ""; + multiplier = 1.0f; + storeResult = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Input/GetAxisRaw.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Input/GetAxisRaw.cs.meta new file mode 100644 index 0000000..77f2594 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Input/GetAxisRaw.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: d7ba1768defe9ae4489e2d849801caf2 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Input/GetButton.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Input/GetButton.cs new file mode 100644 index 0000000..e52bd22 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Input/GetButton.cs @@ -0,0 +1,27 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityInput +{ + [TaskCategory("Unity/Input")] + [TaskDescription("Stores the state of the specified button.")] + public class GetButton : Action + { + [Tooltip("The name of the button")] + public SharedString buttonName; + [RequiredField] + [Tooltip("The stored result")] + public SharedBool storeResult; + + public override TaskStatus OnUpdate() + { + storeResult.Value = Input.GetButton(buttonName.Value); + return TaskStatus.Success; + } + + public override void OnReset() + { + buttonName = "Fire1"; + storeResult = false; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Input/GetButton.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Input/GetButton.cs.meta new file mode 100644 index 0000000..faf918f --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Input/GetButton.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 7ca2e1ded24b0a144b628bb8ed81ccd0 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Input/GetKey.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Input/GetKey.cs new file mode 100644 index 0000000..bb356cc --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Input/GetKey.cs @@ -0,0 +1,27 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityInput +{ + [TaskCategory("Unity/Input")] + [TaskDescription("Stores the pressed state of the specified key.")] + public class GetKey : Action + { + [Tooltip("The key to test.")] + public KeyCode key; + [RequiredField] + [Tooltip("The stored result")] + public SharedBool storeResult; + + public override TaskStatus OnUpdate() + { + storeResult.Value = Input.GetKey(key); + return TaskStatus.Success; + } + + public override void OnReset() + { + key = KeyCode.None; + storeResult = false; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Input/GetKey.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Input/GetKey.cs.meta new file mode 100644 index 0000000..a2b83cd --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Input/GetKey.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 8d91595c5c003b948abb908c7465a7ec +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Input/GetMouseButton.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Input/GetMouseButton.cs new file mode 100644 index 0000000..94595b9 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Input/GetMouseButton.cs @@ -0,0 +1,27 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityInput +{ + [TaskCategory("Unity/Input")] + [TaskDescription("Stores the state of the specified mouse button.")] + public class GetMouseButton : Action + { + [Tooltip("The index of the button")] + public SharedInt buttonIndex; + [RequiredField] + [Tooltip("The stored result")] + public SharedBool storeResult; + + public override TaskStatus OnUpdate() + { + storeResult.Value = Input.GetMouseButton(buttonIndex.Value); + return TaskStatus.Success; + } + + public override void OnReset() + { + buttonIndex = 0; + storeResult = false; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Input/GetMouseButton.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Input/GetMouseButton.cs.meta new file mode 100644 index 0000000..668f795 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Input/GetMouseButton.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 3449e6301a95d9e49a8f6b50ef862faa +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Input/GetMousePosition.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Input/GetMousePosition.cs new file mode 100644 index 0000000..d71d31e --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Input/GetMousePosition.cs @@ -0,0 +1,24 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityInput +{ + [TaskCategory("Unity/Input")] + [TaskDescription("Stores the mouse position.")] + public class GetMousePosition : Action + { + [RequiredField] + [Tooltip("The stored result")] + public SharedVector3 storeResult; + + public override TaskStatus OnUpdate() + { + storeResult.Value = Input.mousePosition; + return TaskStatus.Success; + } + + public override void OnReset() + { + storeResult = Vector3.zero; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Input/GetMousePosition.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Input/GetMousePosition.cs.meta new file mode 100644 index 0000000..ecbbec4 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Input/GetMousePosition.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: f11dbb85cfc5b3941ae4f82fa54b7d27 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Input/IsButtonDown.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Input/IsButtonDown.cs new file mode 100644 index 0000000..26d7d98 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Input/IsButtonDown.cs @@ -0,0 +1,22 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityInput +{ + [TaskCategory("Unity/Input")] + [TaskDescription("Returns success when the specified button is pressed.")] + public class IsButtonDown : Conditional + { + [Tooltip("The name of the button")] + public SharedString buttonName; + + public override TaskStatus OnUpdate() + { + return Input.GetButtonDown(buttonName.Value) ? TaskStatus.Success : TaskStatus.Failure; + } + + public override void OnReset() + { + buttonName = "Fire1"; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Input/IsButtonDown.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Input/IsButtonDown.cs.meta new file mode 100644 index 0000000..58e45ee --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Input/IsButtonDown.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 554c281a83ae5bb4bbcdf3bdeac6779e +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Input/IsButtonUp.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Input/IsButtonUp.cs new file mode 100644 index 0000000..d3dafa4 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Input/IsButtonUp.cs @@ -0,0 +1,22 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityInput +{ + [TaskCategory("Unity/Input")] + [TaskDescription("Returns success when the specified button is released.")] + public class IsButtonUp : Conditional + { + [Tooltip("The name of the button")] + public SharedString buttonName; + + public override TaskStatus OnUpdate() + { + return Input.GetButtonUp(buttonName.Value) ? TaskStatus.Success : TaskStatus.Failure; + } + + public override void OnReset() + { + buttonName = "Fire1"; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Input/IsButtonUp.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Input/IsButtonUp.cs.meta new file mode 100644 index 0000000..4708eee --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Input/IsButtonUp.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 71d9dda886873b943922eae52da81244 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Input/IsKeyDown.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Input/IsKeyDown.cs new file mode 100644 index 0000000..5125966 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Input/IsKeyDown.cs @@ -0,0 +1,22 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityInput +{ + [TaskCategory("Unity/Input")] + [TaskDescription("Returns success when the specified key is pressed.")] + public class IsKeyDown : Conditional + { + [Tooltip("The key to test")] + public KeyCode key; + + public override TaskStatus OnUpdate() + { + return Input.GetKeyDown(key) ? TaskStatus.Success : TaskStatus.Failure; + } + + public override void OnReset() + { + key = KeyCode.None; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Input/IsKeyDown.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Input/IsKeyDown.cs.meta new file mode 100644 index 0000000..51c7860 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Input/IsKeyDown.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: b4c02f1f071b9604389e1c1f1bfab3eb +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Input/IsKeyUp.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Input/IsKeyUp.cs new file mode 100644 index 0000000..889b54d --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Input/IsKeyUp.cs @@ -0,0 +1,22 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityInput +{ + [TaskCategory("Unity/Input")] + [TaskDescription("Returns success when the specified key is released.")] + public class IsKeyUp : Conditional + { + [Tooltip("The key to test")] + public KeyCode key; + + public override TaskStatus OnUpdate() + { + return Input.GetKeyUp(key) ? TaskStatus.Success : TaskStatus.Failure; + } + + public override void OnReset() + { + key = KeyCode.None; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Input/IsKeyUp.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Input/IsKeyUp.cs.meta new file mode 100644 index 0000000..fc9b37b --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Input/IsKeyUp.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 7d8622d5540c851448ad036016f0f426 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Input/IsMouseDown.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Input/IsMouseDown.cs new file mode 100644 index 0000000..a095c99 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Input/IsMouseDown.cs @@ -0,0 +1,22 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityInput +{ + [TaskCategory("Unity/Input")] + [TaskDescription("Returns success when the specified mouse button is pressed.")] + public class IsMouseDown : Conditional + { + [Tooltip("The button index")] + public SharedInt buttonIndex; + + public override TaskStatus OnUpdate() + { + return Input.GetMouseButtonDown(buttonIndex.Value) ? TaskStatus.Success : TaskStatus.Failure; + } + + public override void OnReset() + { + buttonIndex = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Input/IsMouseDown.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Input/IsMouseDown.cs.meta new file mode 100644 index 0000000..bb11a39 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Input/IsMouseDown.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: fd85264410cd9ac45b0c9c2e550f7c46 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Input/IsMouseUp.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Input/IsMouseUp.cs new file mode 100644 index 0000000..4da0861 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Input/IsMouseUp.cs @@ -0,0 +1,22 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityInput +{ + [TaskCategory("Unity/Input")] + [TaskDescription("Returns success when the specified mouse button is pressed.")] + public class IsMouseUp : Conditional + { + [Tooltip("The button index")] + public SharedInt buttonIndex; + + public override TaskStatus OnUpdate() + { + return Input.GetMouseButtonUp(buttonIndex.Value) ? TaskStatus.Success : TaskStatus.Failure; + } + + public override void OnReset() + { + buttonIndex = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Input/IsMouseUp.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Input/IsMouseUp.cs.meta new file mode 100644 index 0000000..42a5ef7 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Input/IsMouseUp.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: b2ecc8718d19d9b46832c51de0390245 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/LayerMask.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/LayerMask.meta new file mode 100644 index 0000000..acfd7dc --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/LayerMask.meta @@ -0,0 +1,5 @@ +fileFormatVersion: 2 +guid: 03592e079804666408280a195c972a69 +folderAsset: yes +DefaultImporter: + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/LayerMask/GetLayer.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/LayerMask/GetLayer.cs new file mode 100644 index 0000000..a5d0238 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/LayerMask/GetLayer.cs @@ -0,0 +1,28 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityLayerMask +{ + [TaskCategory("Unity/LayerMask")] + [TaskDescription("Gets the layer of a GameObject.")] + public class GetLayer : Action + { + [Tooltip("The GameObject to set the layer of")] + public SharedGameObject targetGameObject; + [Tooltip("The name of the layer to get")] + [RequiredField] + public SharedString storeResult; + + public override TaskStatus OnUpdate() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + storeResult.Value = LayerMask.LayerToName(currentGameObject.layer); + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + storeResult = ""; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/LayerMask/GetLayer.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/LayerMask/GetLayer.cs.meta new file mode 100644 index 0000000..9b8bf34 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/LayerMask/GetLayer.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 4a7e0974f9cfb9945bb2d0f41ed55f10 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/LayerMask/SetLayer.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/LayerMask/SetLayer.cs new file mode 100644 index 0000000..1e85c67 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/LayerMask/SetLayer.cs @@ -0,0 +1,27 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityLayerMask +{ + [TaskCategory("Unity/LayerMask")] + [TaskDescription("Sets the layer of a GameObject.")] + public class SetLayer : Action + { + [Tooltip("The GameObject to set the layer of")] + public SharedGameObject targetGameObject; + [Tooltip("The name of the layer to set")] + public SharedString layerName = "Default"; + + public override TaskStatus OnUpdate() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + currentGameObject.layer = LayerMask.NameToLayer(layerName.Value); + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + layerName = "Default"; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/LayerMask/SetLayer.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/LayerMask/SetLayer.cs.meta new file mode 100644 index 0000000..5a60441 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/LayerMask/SetLayer.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 483904cd6081c8440a146b11481d6623 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Light.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Light.meta new file mode 100644 index 0000000..55d3e0b --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Light.meta @@ -0,0 +1,4 @@ +fileFormatVersion: 2 +guid: 48823f7ab681c2b4f9439c617555cf7a +DefaultImporter: + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Light/GetColor.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Light/GetColor.cs new file mode 100644 index 0000000..b6971a1 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Light/GetColor.cs @@ -0,0 +1,45 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityLight +{ + [TaskCategory("Unity/Light")] + [TaskDescription("Stores the color of the light.")] + public class GetColor : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [RequiredField] + [Tooltip("The color to store")] + public SharedColor storeValue; + + // cache the light component + private Light light; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + light = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (light == null) { + Debug.LogWarning("Light is null"); + return TaskStatus.Failure; + } + + storeValue = light.color; + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + storeValue = Color.white; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Light/GetColor.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Light/GetColor.cs.meta new file mode 100644 index 0000000..06bb9a6 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Light/GetColor.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 935c3e08c991a524fa451ba010bb7077 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Light/GetCookieSize.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Light/GetCookieSize.cs new file mode 100644 index 0000000..4c19650 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Light/GetCookieSize.cs @@ -0,0 +1,45 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityLight +{ + [TaskCategory("Unity/Light")] + [TaskDescription("Stores the light's cookie size.")] + public class GetCookieSize : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [RequiredField] + [Tooltip("The size to store")] + public SharedFloat storeValue; + + // cache the light component + private Light light; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + light = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (light == null) { + Debug.LogWarning("Light is null"); + return TaskStatus.Failure; + } + + storeValue = light.cookieSize; + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + storeValue = 0; + } + } +} diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Light/GetCookieSize.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Light/GetCookieSize.cs.meta new file mode 100644 index 0000000..9ae6bc4 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Light/GetCookieSize.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 4c382d40893d45d46842714355d4cab4 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Light/GetIntensity.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Light/GetIntensity.cs new file mode 100644 index 0000000..aafda8b --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Light/GetIntensity.cs @@ -0,0 +1,45 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityLight +{ + [TaskCategory("Unity/Light")] + [TaskDescription("Stores the intensity of the light.")] + public class GetIntensity : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [RequiredField] + [Tooltip("The intensity to store")] + public SharedFloat storeValue; + + // cache the light component + private Light light; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + light = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (light == null) { + Debug.LogWarning("Light is null"); + return TaskStatus.Failure; + } + + storeValue = light.intensity; + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + storeValue = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Light/GetIntensity.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Light/GetIntensity.cs.meta new file mode 100644 index 0000000..5bbd249 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Light/GetIntensity.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 8af031ee741aec645bcf65ae806e78a7 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Light/GetRange.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Light/GetRange.cs new file mode 100644 index 0000000..d735777 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Light/GetRange.cs @@ -0,0 +1,45 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityLight +{ + [TaskCategory("Unity/Light")] + [TaskDescription("Stores the range of the light.")] + public class GetRange : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [RequiredField] + [Tooltip("The range to store")] + public SharedFloat storeValue; + + // cache the light component + private Light light; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + light = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (light == null) { + Debug.LogWarning("Light is null"); + return TaskStatus.Failure; + } + + storeValue = light.range; + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + storeValue = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Light/GetRange.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Light/GetRange.cs.meta new file mode 100644 index 0000000..f103a34 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Light/GetRange.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 5ebab1924e0212c4ca589526a033fda6 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Light/GetShadowBias.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Light/GetShadowBias.cs new file mode 100644 index 0000000..55be16a --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Light/GetShadowBias.cs @@ -0,0 +1,45 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityLight +{ + [TaskCategory("Unity/Light")] + [TaskDescription("Stores the shadow bias of the light.")] + public class GetShadowBias : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [RequiredField] + [Tooltip("The shadow bias to store")] + public SharedFloat storeValue; + + // cache the light component + private Light light; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + light = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (light == null) { + Debug.LogWarning("Light is null"); + return TaskStatus.Failure; + } + + storeValue = light.shadowBias; + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + storeValue = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Light/GetShadowBias.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Light/GetShadowBias.cs.meta new file mode 100644 index 0000000..2041cba --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Light/GetShadowBias.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 9d0cbb27de892b44193aaa9f12842ed2 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Light/GetShadowStrength.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Light/GetShadowStrength.cs new file mode 100644 index 0000000..a5b49c4 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Light/GetShadowStrength.cs @@ -0,0 +1,45 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityLight +{ + [TaskCategory("Unity/Light")] + [TaskDescription("Stores the color of the light.")] + public class GetShadowStrength : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [RequiredField] + [Tooltip("The color to store")] + public SharedFloat storeValue; + + // cache the light component + private Light light; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + light = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (light == null) { + Debug.LogWarning("Light is null"); + return TaskStatus.Failure; + } + + storeValue = light.shadowStrength; + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + storeValue = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Light/GetShadowStrength.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Light/GetShadowStrength.cs.meta new file mode 100644 index 0000000..c73f629 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Light/GetShadowStrength.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 7a7fe83e412ff344888939e6a974a064 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Light/GetSpotAngle.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Light/GetSpotAngle.cs new file mode 100644 index 0000000..e172660 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Light/GetSpotAngle.cs @@ -0,0 +1,45 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityLight +{ + [TaskCategory("Unity/Light")] + [TaskDescription("Stores the spot angle of the light.")] + public class GetSpotAngle : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [RequiredField] + [Tooltip("The spot angle to store")] + public SharedFloat storeValue; + + // cache the light component + private Light light; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + light = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (light == null) { + Debug.LogWarning("Light is null"); + return TaskStatus.Failure; + } + + storeValue = light.spotAngle; + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + storeValue = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Light/GetSpotAngle.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Light/GetSpotAngle.cs.meta new file mode 100644 index 0000000..e81614a --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Light/GetSpotAngle.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 4dfc8df823e06cd45a09d929a060f99d +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Light/SetColor.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Light/SetColor.cs new file mode 100644 index 0000000..aeed40a --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Light/SetColor.cs @@ -0,0 +1,44 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityLight +{ + [TaskCategory("Unity/Light")] + [TaskDescription("Sets the color of the light.")] + public class SetColor : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The color to set")] + public SharedColor color; + + // cache the light component + private Light light; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + light = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (light == null) { + Debug.LogWarning("Light is null"); + return TaskStatus.Failure; + } + + light.color = color.Value; + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + color = Color.white; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Light/SetColor.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Light/SetColor.cs.meta new file mode 100644 index 0000000..cea4659 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Light/SetColor.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 0ba683b0b18385042b3351c660f29d33 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Light/SetCookie.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Light/SetCookie.cs new file mode 100644 index 0000000..785502b --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Light/SetCookie.cs @@ -0,0 +1,44 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityLight +{ + [TaskCategory("Unity/Light")] + [TaskDescription("Sets the cookie of the light.")] + public class SetCookie : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The cookie to set")] + public Texture2D cookie; + + // cache the light component + private Light light; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + light = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (light == null) { + Debug.LogWarning("Light is null"); + return TaskStatus.Failure; + } + + light.cookie = cookie; + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + cookie = null; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Light/SetCookie.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Light/SetCookie.cs.meta new file mode 100644 index 0000000..69051c8 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Light/SetCookie.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 374f9a87dc387a04585b87f187d019c5 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Light/SetCookieSize.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Light/SetCookieSize.cs new file mode 100644 index 0000000..aeda25f --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Light/SetCookieSize.cs @@ -0,0 +1,44 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityLight +{ + [TaskCategory("Unity/Light")] + [TaskDescription("Sets the light's cookie size.")] + public class SetCookieSize : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The size to set")] + public SharedFloat cookieSize; + + // cache the light component + private Light light; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + light = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (light == null) { + Debug.LogWarning("Light is null"); + return TaskStatus.Failure; + } + + light.cookieSize = cookieSize.Value; + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + cookieSize = 0; + } + } +} diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Light/SetCookieSize.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Light/SetCookieSize.cs.meta new file mode 100644 index 0000000..c78f80b --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Light/SetCookieSize.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: fbc2d3865f928144ea551b1d927ddc96 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Light/SetCullingMask.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Light/SetCullingMask.cs new file mode 100644 index 0000000..6ecf523 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Light/SetCullingMask.cs @@ -0,0 +1,44 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityLight +{ + [TaskCategory("Unity/Light")] + [TaskDescription("Sets the culling mask of the light.")] + public class SetCullingMask : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The culling mask to set")] + public LayerMask cullingMask; + + // cache the light component + private Light light; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + light = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (light == null) { + Debug.LogWarning("Light is null"); + return TaskStatus.Failure; + } + + light.cullingMask = cullingMask.value; + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + cullingMask = -1; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Light/SetCullingMask.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Light/SetCullingMask.cs.meta new file mode 100644 index 0000000..d069ada --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Light/SetCullingMask.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 3f67673818b7e914ebf088b3752d716b +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Light/SetIntensity.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Light/SetIntensity.cs new file mode 100644 index 0000000..d44c573 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Light/SetIntensity.cs @@ -0,0 +1,44 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityLight +{ + [TaskCategory("Unity/Light")] + [TaskDescription("Sets the intensity of the light.")] + public class SetIntensity : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The intensity to set")] + public SharedFloat intensity; + + // cache the light component + private Light light; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + light = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (light == null) { + Debug.LogWarning("Light is null"); + return TaskStatus.Failure; + } + + light.intensity = intensity.Value; + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + intensity = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Light/SetIntensity.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Light/SetIntensity.cs.meta new file mode 100644 index 0000000..57dd8cc --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Light/SetIntensity.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 1f32aa9b9681f0a4285bd60ac0607d00 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Light/SetRange.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Light/SetRange.cs new file mode 100644 index 0000000..9866a17 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Light/SetRange.cs @@ -0,0 +1,44 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityLight +{ + [TaskCategory("Unity/Light")] + [TaskDescription("Sets the range of the light.")] + public class SetRange : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The range to set")] + public SharedFloat range; + + // cache the light component + private Light light; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + light = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (light == null) { + Debug.LogWarning("Light is null"); + return TaskStatus.Failure; + } + + light.range = range.Value; + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + range = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Light/SetRange.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Light/SetRange.cs.meta new file mode 100644 index 0000000..ba42aef --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Light/SetRange.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: f0b5d0c0a07806244a3c5b15e29cf90c +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Light/SetShadowBias.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Light/SetShadowBias.cs new file mode 100644 index 0000000..1ea35ab --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Light/SetShadowBias.cs @@ -0,0 +1,44 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityLight +{ + [TaskCategory("Unity/Light")] + [TaskDescription("Sets the shadow bias of the light.")] + public class SetShadowBias : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The shadow bias to set")] + public SharedFloat shadowBias; + + // cache the light component + private Light light; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + light = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (light == null) { + Debug.LogWarning("Light is null"); + return TaskStatus.Failure; + } + + light.shadowBias = shadowBias.Value; + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + shadowBias = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Light/SetShadowBias.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Light/SetShadowBias.cs.meta new file mode 100644 index 0000000..1ab413e --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Light/SetShadowBias.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: f2b374e3c2e26e94ba76dd68290ff538 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Light/SetShadowSoftness.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Light/SetShadowSoftness.cs new file mode 100644 index 0000000..427cc35 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Light/SetShadowSoftness.cs @@ -0,0 +1,46 @@ +#if UNITY_4_6 || UNITY_4_7 +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityLight +{ + [TaskCategory("Unity/Light")] + [TaskDescription("Sets the shadow softness of the light.")] + public class SetShadowSoftness : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The shadow softness to set")] + public SharedFloat shadowSoftness; + + // cache the light component + private Light light; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + light = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (light == null) { + Debug.LogWarning("Light is null"); + return TaskStatus.Failure; + } + + light.shadowSoftness = shadowSoftness.Value; + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + shadowSoftness = 0; + } + } +} +#endif \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Light/SetShadowSoftness.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Light/SetShadowSoftness.cs.meta new file mode 100644 index 0000000..2756964 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Light/SetShadowSoftness.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: ca82eb780880d17499dc6de132631073 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Light/SetShadowSoftnessFade.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Light/SetShadowSoftnessFade.cs new file mode 100644 index 0000000..f3d6e63 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Light/SetShadowSoftnessFade.cs @@ -0,0 +1,46 @@ +#if UNITY_4_6 || UNITY_4_7 +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityLight +{ + [TaskCategory("Unity/Light")] + [TaskDescription("Sets the shadow softness fade value of the light.")] + public class SetShadowSoftnessFade : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The shadow softness fade to set")] + public SharedFloat shadowSoftnessFade; + + // cache the light component + private Light light; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + light = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (light == null) { + Debug.LogWarning("Light is null"); + return TaskStatus.Failure; + } + + light.shadowSoftnessFade = shadowSoftnessFade.Value; + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + shadowSoftnessFade = 0; + } + } +} +#endif \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Light/SetShadowSoftnessFade.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Light/SetShadowSoftnessFade.cs.meta new file mode 100644 index 0000000..cd06cc7 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Light/SetShadowSoftnessFade.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 5e7db120bd152164eb6d586a39e53175 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Light/SetShadowStrength.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Light/SetShadowStrength.cs new file mode 100644 index 0000000..486f31c --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Light/SetShadowStrength.cs @@ -0,0 +1,44 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityLight +{ + [TaskCategory("Unity/Light")] + [TaskDescription("Sets the shadow strength of the light.")] + public class SetShadowSoftnessStrength : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The shadow strength to set")] + public SharedFloat shadowStrength; + + // cache the light component + private Light light; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + light = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (light == null) { + Debug.LogWarning("Light is null"); + return TaskStatus.Failure; + } + + light.shadowStrength = shadowStrength.Value; + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + shadowStrength = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Light/SetShadowStrength.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Light/SetShadowStrength.cs.meta new file mode 100644 index 0000000..d9a0888 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Light/SetShadowStrength.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 611e5846c0413be46bbc44fbd256b4e9 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Light/SetShadows.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Light/SetShadows.cs new file mode 100644 index 0000000..dabe752 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Light/SetShadows.cs @@ -0,0 +1,43 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityLight +{ + [TaskCategory("Unity/Light")] + [TaskDescription("Sets the shadow type of the light.")] + public class SetShadows : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The shadow type to set")] + public LightShadows shadows; + + // cache the light component + private Light light; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + light = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (light == null) { + Debug.LogWarning("Light is null"); + return TaskStatus.Failure; + } + + light.shadows = shadows; + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Light/SetShadows.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Light/SetShadows.cs.meta new file mode 100644 index 0000000..c0ef005 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Light/SetShadows.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: b6226eb03ad729445bc7ccfb1f0cd89d +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Light/SetSpotAngle.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Light/SetSpotAngle.cs new file mode 100644 index 0000000..28b3ff6 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Light/SetSpotAngle.cs @@ -0,0 +1,44 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityLight +{ + [TaskCategory("Unity/Light")] + [TaskDescription("Sets the spot angle of the light.")] + public class SetSpotAngle : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The spot angle to set")] + public SharedFloat spotAngle; + + // cache the light component + private Light light; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + light = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (light == null) { + Debug.LogWarning("Light is null"); + return TaskStatus.Failure; + } + + light.spotAngle = spotAngle.Value; + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + spotAngle = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Light/SetSpotAngle.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Light/SetSpotAngle.cs.meta new file mode 100644 index 0000000..484e8a1 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Light/SetSpotAngle.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 9a8b9b0654618fe48953e059d4aa5ee3 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Light/SetType.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Light/SetType.cs new file mode 100644 index 0000000..f4706a8 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Light/SetType.cs @@ -0,0 +1,43 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityLight +{ + [TaskCategory("Unity/Light")] + [TaskDescription("Sets the type of the light.")] + public class SetType : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The type to set")] + public LightType type; + + // cache the light component + private Light light; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + light = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (light == null) { + Debug.LogWarning("Light is null"); + return TaskStatus.Failure; + } + + light.type = type; + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Light/SetType.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Light/SetType.cs.meta new file mode 100644 index 0000000..47baa0a --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Light/SetType.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 85cae5f82bfcbfb41ac7c66464eef85f +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Math.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Math.meta new file mode 100644 index 0000000..862668e --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Math.meta @@ -0,0 +1,4 @@ +fileFormatVersion: 2 +guid: fffa44303fdbffe4289373d6e5087b4a +DefaultImporter: + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/BoolComparison.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/BoolComparison.cs new file mode 100644 index 0000000..e176fa7 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/BoolComparison.cs @@ -0,0 +1,23 @@ +namespace BehaviorDesigner.Runtime.Tasks.Unity.Math +{ + [TaskCategory("Unity/Math")] + [TaskDescription("Performs a comparison between two bools.")] + public class BoolComparison : Conditional + { + [Tooltip("The first bool")] + public SharedBool bool1; + [Tooltip("The second bool")] + public SharedBool bool2; + + public override TaskStatus OnUpdate() + { + return bool1.Value == bool2.Value ? TaskStatus.Success : TaskStatus.Failure; + } + + public override void OnReset() + { + bool1 = false; + bool2 = false; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/BoolComparison.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/BoolComparison.cs.meta new file mode 100644 index 0000000..9fc9c76 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/BoolComparison.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: abaa3d78e68f249428f3be7acae86b0d +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/BoolFlip.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/BoolFlip.cs new file mode 100644 index 0000000..351e315 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/BoolFlip.cs @@ -0,0 +1,21 @@ +namespace BehaviorDesigner.Runtime.Tasks.Unity.Math +{ + [TaskCategory("Unity/Math")] + [TaskDescription("Flips the value of the bool.")] + public class BoolFlip : Action + { + [Tooltip("The bool to flip the value of")] + public SharedBool boolVariable; + + public override TaskStatus OnUpdate() + { + boolVariable.Value = !boolVariable.Value; + return TaskStatus.Success; + } + + public override void OnReset() + { + boolVariable.Value = false; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/BoolFlip.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/BoolFlip.cs.meta new file mode 100644 index 0000000..d489589 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/BoolFlip.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 54aae1e47fe3be6458751bf1f9defe8f +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/BoolOperator.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/BoolOperator.cs new file mode 100644 index 0000000..7311642 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/BoolOperator.cs @@ -0,0 +1,50 @@ +namespace BehaviorDesigner.Runtime.Tasks.Unity.Math +{ + [TaskCategory("Unity/Math")] + [TaskDescription("Performs a math operation on two bools: AND, OR, NAND, or XOR.")] + public class BoolOperator : Action + { + public enum Operation + { + AND, + OR, + NAND, + XOR + } + + [Tooltip("The operation to perform")] + public Operation operation; + [Tooltip("The first bool")] + public SharedBool bool1; + [Tooltip("The second bool")] + public SharedBool bool2; + [Tooltip("The variable to store the result")] + public SharedBool storeResult; + + public override TaskStatus OnUpdate() + { + switch (operation) { + case Operation.AND: + storeResult.Value = bool1.Value && bool2.Value; + break; + case Operation.OR: + storeResult.Value = bool1.Value || bool2.Value; + break; + case Operation.NAND: + storeResult.Value = !(bool1.Value && bool2.Value); + break; + case Operation.XOR: + storeResult.Value = bool1.Value ^ bool2.Value; + break; + } + return TaskStatus.Success; + } + + public override void OnReset() + { + operation = Operation.AND; + bool1 = false; + bool2 = false; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/BoolOperator.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/BoolOperator.cs.meta new file mode 100644 index 0000000..907ae77 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/BoolOperator.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: bd7b9dfddd114be4a8c8a8521262970d +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/FloatAbs.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/FloatAbs.cs new file mode 100644 index 0000000..b5be228 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/FloatAbs.cs @@ -0,0 +1,23 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.Math +{ + [TaskCategory("Unity/Math")] + [TaskDescription("Stores the absolute value of the float.")] + public class FloatAbs : Action + { + [Tooltip("The float to return the absolute value of")] + public SharedFloat floatVariable; + + public override TaskStatus OnUpdate() + { + floatVariable.Value = Mathf.Abs(floatVariable.Value); + return TaskStatus.Success; + } + + public override void OnReset() + { + floatVariable = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/FloatAbs.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/FloatAbs.cs.meta new file mode 100644 index 0000000..cdfcb10 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/FloatAbs.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: ab5531c4ed335b643a6f310c048a6b00 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/FloatClamp.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/FloatClamp.cs new file mode 100644 index 0000000..667b097 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/FloatClamp.cs @@ -0,0 +1,29 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.Math +{ + [TaskCategory("Unity/Math")] + [TaskDescription("Clamps the float between two values.")] + public class FloatClamp : Action + { + [Tooltip("The float to clamp")] + public SharedFloat floatVariable; + [Tooltip("The maximum value of the float")] + public SharedFloat minValue; + [Tooltip("The maximum value of the float")] + public SharedFloat maxValue; + + public override TaskStatus OnUpdate() + { + floatVariable.Value = Mathf.Clamp(floatVariable.Value, minValue.Value, maxValue.Value); + return TaskStatus.Success; + } + + public override void OnReset() + { + floatVariable = 0; + minValue = 0; + maxValue = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/FloatClamp.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/FloatClamp.cs.meta new file mode 100644 index 0000000..7bb65ab --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/FloatClamp.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 75c3634f2c8f1dd49b826a7ac0c7bdbe +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/FloatComparison.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/FloatComparison.cs new file mode 100644 index 0000000..a1d2382 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/FloatComparison.cs @@ -0,0 +1,50 @@ +namespace BehaviorDesigner.Runtime.Tasks.Unity.Math +{ + [TaskCategory("Unity/Math")] + [TaskDescription("Performs comparison between two floats: less than, less than or equal to, equal to, not equal to, greater than or equal to, or greater than.")] + public class FloatComparison : Conditional + { + public enum Operation + { + LessThan, + LessThanOrEqualTo, + EqualTo, + NotEqualTo, + GreaterThanOrEqualTo, + GreaterThan + } + + [Tooltip("The operation to perform")] + public Operation operation; + [Tooltip("The first float")] + public SharedFloat float1; + [Tooltip("The second float")] + public SharedFloat float2; + + public override TaskStatus OnUpdate() + { + switch (operation) { + case Operation.LessThan: + return float1.Value < float2.Value ? TaskStatus.Success : TaskStatus.Failure; + case Operation.LessThanOrEqualTo: + return float1.Value <= float2.Value ? TaskStatus.Success : TaskStatus.Failure; + case Operation.EqualTo: + return UnityEngine.Mathf.Approximately(float1.Value, float2.Value) ? TaskStatus.Success : TaskStatus.Failure; + case Operation.NotEqualTo: + return !UnityEngine.Mathf.Approximately(float1.Value, float2.Value) ? TaskStatus.Success : TaskStatus.Failure; + case Operation.GreaterThanOrEqualTo: + return float1.Value >= float2.Value ? TaskStatus.Success : TaskStatus.Failure; + case Operation.GreaterThan: + return float1.Value > float2.Value ? TaskStatus.Success : TaskStatus.Failure; + } + return TaskStatus.Failure; + } + + public override void OnReset() + { + operation = Operation.LessThan; + float1.Value = 0; + float2.Value = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/FloatComparison.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/FloatComparison.cs.meta new file mode 100644 index 0000000..6fc80f8 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/FloatComparison.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 79c81f4e67dbdc44880734e78153117c +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/FloatOperator.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/FloatOperator.cs new file mode 100644 index 0000000..d222db4 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/FloatOperator.cs @@ -0,0 +1,65 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.Math +{ + [TaskCategory("Unity/Math")] + [TaskDescription("Performs a math operation on two floats: Add, Subtract, Multiply, Divide, Min, or Max.")] + public class FloatOperator : Action + { + public enum Operation + { + Add, + Subtract, + Multiply, + Divide, + Min, + Max, + Modulo + } + + [Tooltip("The operation to perform")] + public Operation operation; + [Tooltip("The first float")] + public SharedFloat float1; + [Tooltip("The second float")] + public SharedFloat float2; + [Tooltip("The variable to store the result")] + public SharedFloat storeResult; + + public override TaskStatus OnUpdate() + { + switch (operation) { + case Operation.Add: + storeResult.Value = float1.Value + float2.Value; + break; + case Operation.Subtract: + storeResult.Value = float1.Value - float2.Value; + break; + case Operation.Multiply: + storeResult.Value = float1.Value * float2.Value; + break; + case Operation.Divide: + storeResult.Value = float1.Value / float2.Value; + break; + case Operation.Min: + storeResult.Value = Mathf.Min(float1.Value, float2.Value); + break; + case Operation.Max: + storeResult.Value = Mathf.Max(float1.Value, float2.Value); + break; + case Operation.Modulo: + storeResult.Value = float1.Value % float2.Value; + break; + } + return TaskStatus.Success; + } + + public override void OnReset() + { + operation = Operation.Add; + float1 = 0; + float2 = 0; + storeResult = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/FloatOperator.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/FloatOperator.cs.meta new file mode 100644 index 0000000..e7704cc --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/FloatOperator.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 9144ac2a8b796c941aeb3d6a4bc2cf7c +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/IntAbs.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/IntAbs.cs new file mode 100644 index 0000000..d2ae96a --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/IntAbs.cs @@ -0,0 +1,23 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.Math +{ + [TaskCategory("Unity/Math")] + [TaskDescription("Stores the absolute value of the int.")] + public class IntAbs : Action + { + [Tooltip("The int to return the absolute value of")] + public SharedInt intVariable; + + public override TaskStatus OnUpdate() + { + intVariable.Value = Mathf.Abs(intVariable.Value); + return TaskStatus.Success; + } + + public override void OnReset() + { + intVariable = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/IntAbs.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/IntAbs.cs.meta new file mode 100644 index 0000000..f591245 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/IntAbs.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 8edcbab77068fe044842381cfe0acc19 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/IntClamp.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/IntClamp.cs new file mode 100644 index 0000000..f26a110 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/IntClamp.cs @@ -0,0 +1,29 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.Math +{ + [TaskCategory("Unity/Math")] + [TaskDescription("Clamps the int between two values.")] + public class IntClamp : Action + { + [Tooltip("The int to clamp")] + public SharedInt intVariable; + [Tooltip("The maximum value of the int")] + public SharedInt minValue; + [Tooltip("The maximum value of the int")] + public SharedInt maxValue; + + public override TaskStatus OnUpdate() + { + intVariable.Value = Mathf.Clamp(intVariable.Value, minValue.Value, maxValue.Value); + return TaskStatus.Success; + } + + public override void OnReset() + { + intVariable = 0; + minValue = 0; + maxValue = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/IntClamp.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/IntClamp.cs.meta new file mode 100644 index 0000000..94b9482 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/IntClamp.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 67cbe30015f2b4940a069cbbee22d888 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/IntComparison.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/IntComparison.cs new file mode 100644 index 0000000..24d55a9 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/IntComparison.cs @@ -0,0 +1,50 @@ +namespace BehaviorDesigner.Runtime.Tasks.Unity.Math +{ + [TaskCategory("Unity/Math")] + [TaskDescription("Performs comparison between two integers: less than, less than or equal to, equal to, not equal to, greater than or equal to, or greater than.")] + public class IntComparison : Conditional + { + public enum Operation + { + LessThan, + LessThanOrEqualTo, + EqualTo, + NotEqualTo, + GreaterThanOrEqualTo, + GreaterThan + } + + [Tooltip("The operation to perform")] + public Operation operation; + [Tooltip("The first integer")] + public SharedInt integer1; + [Tooltip("The second integer")] + public SharedInt integer2; + + public override TaskStatus OnUpdate() + { + switch (operation) { + case Operation.LessThan: + return integer1.Value < integer2.Value ? TaskStatus.Success : TaskStatus.Failure; + case Operation.LessThanOrEqualTo: + return integer1.Value <= integer2.Value ? TaskStatus.Success : TaskStatus.Failure; + case Operation.EqualTo: + return integer1.Value == integer2.Value ? TaskStatus.Success : TaskStatus.Failure; + case Operation.NotEqualTo: + return integer1.Value != integer2.Value ? TaskStatus.Success : TaskStatus.Failure; + case Operation.GreaterThanOrEqualTo: + return integer1.Value >= integer2.Value ? TaskStatus.Success : TaskStatus.Failure; + case Operation.GreaterThan: + return integer1.Value > integer2.Value ? TaskStatus.Success : TaskStatus.Failure; + } + return TaskStatus.Failure; + } + + public override void OnReset() + { + operation = Operation.LessThan; + integer1.Value = 0; + integer2.Value = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/IntComparison.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/IntComparison.cs.meta new file mode 100644 index 0000000..a3bea5e --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/IntComparison.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 99108c35b6d8e9942b8cf441a63f97b5 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/IntOperator.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/IntOperator.cs new file mode 100644 index 0000000..f104ebb --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/IntOperator.cs @@ -0,0 +1,66 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.Math +{ + [TaskCategory("Unity/Math")] + [TaskDescription("Performs a math operation on two integers: Add, Subtract, Multiply, Divide, Min, or Max.")] + public class IntOperator : Action + { + public enum Operation + { + Add, + Subtract, + Multiply, + Divide, + Min, + Max, + Modulo + } + + [Tooltip("The operation to perform")] + public Operation operation; + [Tooltip("The first integer")] + public SharedInt integer1; + [Tooltip("The second integer")] + public SharedInt integer2; + [RequiredField] + [Tooltip("The variable to store the result")] + public SharedInt storeResult; + + public override TaskStatus OnUpdate() + { + switch (operation) { + case Operation.Add: + storeResult.Value = integer1.Value + integer2.Value; + break; + case Operation.Subtract: + storeResult.Value = integer1.Value - integer2.Value; + break; + case Operation.Multiply: + storeResult.Value = integer1.Value * integer2.Value; + break; + case Operation.Divide: + storeResult.Value = integer1.Value / integer2.Value; + break; + case Operation.Min: + storeResult.Value = Mathf.Min(integer1.Value, integer2.Value); + break; + case Operation.Max: + storeResult.Value = Mathf.Max(integer1.Value, integer2.Value); + break; + case Operation.Modulo: + storeResult.Value = integer1.Value % integer2.Value; + break; + } + return TaskStatus.Success; + } + + public override void OnReset() + { + operation = Operation.Add; + integer1 = 0; + integer2 = 0; + storeResult = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/IntOperator.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/IntOperator.cs.meta new file mode 100644 index 0000000..36e4c90 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/IntOperator.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 84208004fb80c0945acc5685aa0a2681 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/IsFloatPositive.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/IsFloatPositive.cs new file mode 100644 index 0000000..076b93f --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/IsFloatPositive.cs @@ -0,0 +1,20 @@ +namespace BehaviorDesigner.Runtime.Tasks.Unity.Math +{ + [TaskCategory("Unity/Math")] + [TaskDescription("Is the float a positive value?")] + public class IsFloatPositive : Conditional + { + [Tooltip("The float to check if positive")] + public SharedFloat floatVariable; + + public override TaskStatus OnUpdate() + { + return floatVariable.Value > 0 ? TaskStatus.Success : TaskStatus.Failure; + } + + public override void OnReset() + { + floatVariable = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/IsFloatPositive.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/IsFloatPositive.cs.meta new file mode 100644 index 0000000..ac6f310 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/IsFloatPositive.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: db01d0da1f282134ca0ff7332eb19208 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/IsIntPositive.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/IsIntPositive.cs new file mode 100644 index 0000000..a69e351 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/IsIntPositive.cs @@ -0,0 +1,20 @@ +namespace BehaviorDesigner.Runtime.Tasks.Unity.Math +{ + [TaskCategory("Unity/Math")] + [TaskDescription("Is the int a positive value?")] + public class IsIntPositive : Conditional + { + [Tooltip("The int to check if positive")] + public SharedInt intVariable; + + public override TaskStatus OnUpdate() + { + return intVariable.Value > 0 ? TaskStatus.Success : TaskStatus.Failure; + } + + public override void OnReset() + { + intVariable = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/IsIntPositive.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/IsIntPositive.cs.meta new file mode 100644 index 0000000..1a85bae --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/IsIntPositive.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 0caff63c23ae17343a455fcbe6eab40a +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/Lerp.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/Lerp.cs new file mode 100644 index 0000000..384f591 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/Lerp.cs @@ -0,0 +1,33 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.Math +{ + [TaskCategory("Unity/Math")] + [TaskDescription("Lerp the float by an amount.")] + public class Lerp : Action + { + [Tooltip("The from value")] + public SharedFloat fromValue; + [Tooltip("The to value")] + public SharedFloat toValue; + [Tooltip("The amount to lerp")] + public SharedFloat lerpAmount; + [Tooltip("The lerp resut")] + [RequiredField] + public SharedFloat storeResult; + + public override TaskStatus OnUpdate() + { + storeResult.Value = Mathf.Lerp(fromValue.Value, toValue.Value, lerpAmount.Value); + return TaskStatus.Success; + } + + public override void OnReset() + { + fromValue = 0; + toValue = 0; + lerpAmount = 0; + storeResult = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/Lerp.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/Lerp.cs.meta new file mode 100644 index 0000000..7ce47e4 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/Lerp.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 355f3f83182cc434cb3a1bfb66862e29 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/LerpAngle.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/LerpAngle.cs new file mode 100644 index 0000000..dcde263 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/LerpAngle.cs @@ -0,0 +1,33 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.Math +{ + [TaskCategory("Unity/Math")] + [TaskDescription("Lerp the angle by an amount.")] + public class LerpAngle : Action + { + [Tooltip("The from value")] + public SharedFloat fromValue; + [Tooltip("The to value")] + public SharedFloat toValue; + [Tooltip("The amount to lerp")] + public SharedFloat lerpAmount; + [Tooltip("The lerp resut")] + [RequiredField] + public SharedFloat storeResult; + + public override TaskStatus OnUpdate() + { + storeResult.Value = Mathf.LerpAngle(fromValue.Value, toValue.Value, lerpAmount.Value); + return TaskStatus.Success; + } + + public override void OnReset() + { + fromValue = 0; + toValue = 0; + lerpAmount = 0; + storeResult = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/LerpAngle.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/LerpAngle.cs.meta new file mode 100644 index 0000000..914c03b --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/LerpAngle.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: c3b148edcb926b744a2bb789f7967e24 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/RandomBool.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/RandomBool.cs new file mode 100644 index 0000000..8a2e2fa --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/RandomBool.cs @@ -0,0 +1,18 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.Math +{ + [TaskCategory("Unity/Math")] + [TaskDescription("Sets a random bool value")] + public class RandomBool : Action + { + [Tooltip("The variable to store the result")] + public SharedBool storeResult; + + public override TaskStatus OnUpdate() + { + storeResult.Value = Random.value < 0.5f; + return TaskStatus.Success; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/RandomBool.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/RandomBool.cs.meta new file mode 100644 index 0000000..d1b2dab --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/RandomBool.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 76d2565ca99ca26459dbefb44dcac109 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/RandomFloat.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/RandomFloat.cs new file mode 100644 index 0000000..1c6ef2e --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/RandomFloat.cs @@ -0,0 +1,36 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.Math +{ + [TaskCategory("Unity/Math")] + [TaskDescription("Sets a random float value")] + public class RandomFloat : Action + { + [Tooltip("The minimum amount")] + public SharedFloat min; + [Tooltip("The maximum amount")] + public SharedFloat max; + [Tooltip("Is the maximum value inclusive?")] + public bool inclusive; + [Tooltip("The variable to store the result")] + public SharedFloat storeResult; + + public override TaskStatus OnUpdate() + { + if (inclusive) { + storeResult.Value = Random.Range(min.Value, max.Value); + } else { + storeResult.Value = Random.Range(min.Value, max.Value - 0.00001f); + } + return TaskStatus.Success; + } + + public override void OnReset() + { + min.Value = 0; + max.Value = 0; + inclusive = false; + storeResult = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/RandomFloat.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/RandomFloat.cs.meta new file mode 100644 index 0000000..1cdc412 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/RandomFloat.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 9f81e111c77731b418178f1226975c3f +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/RandomInt.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/RandomInt.cs new file mode 100644 index 0000000..7ac5708 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/RandomInt.cs @@ -0,0 +1,36 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.Math +{ + [TaskCategory("Unity/Math")] + [TaskDescription("Sets a random int value")] + public class RandomInt : Action + { + [Tooltip("The minimum amount")] + public SharedInt min; + [Tooltip("The maximum amount")] + public SharedInt max; + [Tooltip("Is the maximum value inclusive?")] + public bool inclusive; + [Tooltip("The variable to store the result")] + public SharedInt storeResult; + + public override TaskStatus OnUpdate() + { + if (inclusive) { + storeResult.Value = Random.Range(min.Value, max.Value + 1); + } else { + storeResult.Value = Random.Range(min.Value, max.Value); + } + return TaskStatus.Success; + } + + public override void OnReset() + { + min.Value = 0; + max.Value = 0; + inclusive = false; + storeResult = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/RandomInt.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/RandomInt.cs.meta new file mode 100644 index 0000000..03c3421 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/RandomInt.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 067384c41f33cff49bcdf6adec9da049 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/SetBool.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/SetBool.cs new file mode 100644 index 0000000..f95dced --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/SetBool.cs @@ -0,0 +1,23 @@ +namespace BehaviorDesigner.Runtime.Tasks.Unity.Math +{ + [TaskCategory("Unity/Math")] + [TaskDescription("Sets a bool value")] + public class SetBool : Action + { + [Tooltip("The bool value to set")] + public SharedBool boolValue; + [Tooltip("The variable to store the result")] + public SharedBool storeResult; + + public override TaskStatus OnUpdate() + { + storeResult.Value = boolValue.Value; + return TaskStatus.Success; + } + + public override void OnReset() + { + boolValue = false; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/SetBool.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/SetBool.cs.meta new file mode 100644 index 0000000..4a522d9 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/SetBool.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 55f244424a532d24bba59542e2f0fc59 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/SetFloat.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/SetFloat.cs new file mode 100644 index 0000000..11f79a6 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/SetFloat.cs @@ -0,0 +1,24 @@ +namespace BehaviorDesigner.Runtime.Tasks.Unity.Math +{ + [TaskCategory("Unity/Math")] + [TaskDescription("Sets a float value")] + public class SetFloat : Action + { + [Tooltip("The float value to set")] + public SharedFloat floatValue; + [Tooltip("The variable to store the result")] + public SharedFloat storeResult; + + public override TaskStatus OnUpdate() + { + storeResult.Value = floatValue.Value; + return TaskStatus.Success; + } + + public override void OnReset() + { + floatValue = 0; + storeResult = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/SetFloat.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/SetFloat.cs.meta new file mode 100644 index 0000000..b17a55e --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/SetFloat.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 4d915065ba447c64ba05f8e2841c6efd +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/SetInt.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/SetInt.cs new file mode 100644 index 0000000..03af02d --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/SetInt.cs @@ -0,0 +1,24 @@ +namespace BehaviorDesigner.Runtime.Tasks.Unity.Math +{ + [TaskCategory("Unity/Math")] + [TaskDescription("Sets an int value")] + public class SetInt : Action + { + [Tooltip("The int value to set")] + public SharedInt intValue; + [Tooltip("The variable to store the result")] + public SharedInt storeResult; + + public override TaskStatus OnUpdate() + { + storeResult.Value = intValue.Value; + return TaskStatus.Success; + } + + public override void OnReset() + { + intValue = 0; + storeResult = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/SetInt.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/SetInt.cs.meta new file mode 100644 index 0000000..67e3cf6 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Math/SetInt.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: da57a0a43f227e445b9311bae043401f +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/NavMeshAgent.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/NavMeshAgent.meta new file mode 100644 index 0000000..bbaf141 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/NavMeshAgent.meta @@ -0,0 +1,5 @@ +fileFormatVersion: 2 +guid: 7e052e6171d06ed43bea8c8143e7bce5 +folderAsset: yes +DefaultImporter: + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/NavMeshAgent/GetAcceleration.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/NavMeshAgent/GetAcceleration.cs new file mode 100644 index 0000000..58945db --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/NavMeshAgent/GetAcceleration.cs @@ -0,0 +1,47 @@ +using UnityEngine; +using UnityEngine.AI; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityNavMeshAgent +{ + [TaskCategory("Unity/NavMeshAgent")] + [TaskDescription("Gets the maximum acceleration of an agent as it follows a path, given in units / sec^2.. Returns Success.")] + public class GetAcceleration : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [SharedRequired] + [Tooltip("The NavMeshAgent acceleration")] + public SharedFloat storeValue; + + // cache the navmeshagent component + private NavMeshAgent navMeshAgent; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + navMeshAgent = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (navMeshAgent == null) { + Debug.LogWarning("NavMeshAgent is null"); + return TaskStatus.Failure; + } + + storeValue.Value = navMeshAgent.acceleration; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + storeValue = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/NavMeshAgent/GetAcceleration.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/NavMeshAgent/GetAcceleration.cs.meta new file mode 100644 index 0000000..82d8c43 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/NavMeshAgent/GetAcceleration.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 7e00211632663cc43bc88ab068ab5d44 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/NavMeshAgent/GetAngularSpeed.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/NavMeshAgent/GetAngularSpeed.cs new file mode 100644 index 0000000..d912e57 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/NavMeshAgent/GetAngularSpeed.cs @@ -0,0 +1,47 @@ +using UnityEngine; +using UnityEngine.AI; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityNavMeshAgent +{ + [TaskCategory("Unity/NavMeshAgent")] + [TaskDescription("Gets the maximum turning speed in (deg/s) while following a path.. Returns Success.")] + public class GetAngularSpeed : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [SharedRequired] + [Tooltip("The NavMeshAgent angular speed")] + public SharedFloat storeValue; + + // cache the navmeshagent component + private NavMeshAgent navMeshAgent; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + navMeshAgent = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (navMeshAgent == null) { + Debug.LogWarning("NavMeshAgent is null"); + return TaskStatus.Failure; + } + + storeValue.Value = navMeshAgent.angularSpeed; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + storeValue = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/NavMeshAgent/GetAngularSpeed.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/NavMeshAgent/GetAngularSpeed.cs.meta new file mode 100644 index 0000000..655ec1a --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/NavMeshAgent/GetAngularSpeed.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 110bcd7b4d1baae4096b5da6737c1e16 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/NavMeshAgent/GetDestination.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/NavMeshAgent/GetDestination.cs new file mode 100644 index 0000000..a937e61 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/NavMeshAgent/GetDestination.cs @@ -0,0 +1,47 @@ +using UnityEngine; +using UnityEngine.AI; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityNavMeshAgent +{ + [TaskCategory("Unity/NavMeshAgent")] + [TaskDescription("Gets the destination of the agent in world-space units. Returns Success.")] + public class GetDestination : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [SharedRequired] + [Tooltip("The NavMeshAgent destination")] + public SharedVector3 storeValue; + + // cache the navmeshagent component + private NavMeshAgent navMeshAgent; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + navMeshAgent = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (navMeshAgent == null) { + Debug.LogWarning("NavMeshAgent is null"); + return TaskStatus.Failure; + } + + storeValue.Value = navMeshAgent.destination; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + storeValue = Vector3.zero; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/NavMeshAgent/GetDestination.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/NavMeshAgent/GetDestination.cs.meta new file mode 100644 index 0000000..6909e8a --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/NavMeshAgent/GetDestination.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 4368ae3e22d36604697d420dff004cbe +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/NavMeshAgent/GetIsStopped.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/NavMeshAgent/GetIsStopped.cs new file mode 100644 index 0000000..1c5328a --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/NavMeshAgent/GetIsStopped.cs @@ -0,0 +1,47 @@ +using UnityEngine; +using UnityEngine.AI; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityNavMeshAgent +{ + [TaskCategory("Unity/NavMeshAgent")] + [TaskDescription("Gets the stop status. Returns Success.")] + public class GetIsStopped : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [SharedRequired] + [Tooltip("The stop status")] + public SharedBool storeValue; + + // cache the navmeshagent component + private NavMeshAgent navMeshAgent; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + navMeshAgent = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (navMeshAgent == null) { + Debug.LogWarning("NavMeshAgent is null"); + return TaskStatus.Failure; + } + + storeValue.Value = navMeshAgent.isStopped; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + storeValue = null; + } + } +} diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/NavMeshAgent/GetIsStopped.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/NavMeshAgent/GetIsStopped.cs.meta new file mode 100644 index 0000000..4591cc9 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/NavMeshAgent/GetIsStopped.cs.meta @@ -0,0 +1,12 @@ +fileFormatVersion: 2 +guid: 16a58d9763ce6c34690e0946a64c4176 +timeCreated: 1507381813 +licenseType: Store +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/NavMeshAgent/GetRemainingDistance.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/NavMeshAgent/GetRemainingDistance.cs new file mode 100644 index 0000000..782ef8c --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/NavMeshAgent/GetRemainingDistance.cs @@ -0,0 +1,47 @@ +using UnityEngine; +using UnityEngine.AI; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityNavMeshAgent +{ + [TaskCategory("Unity/NavMeshAgent")] + [TaskDescription("Gets the distance between the agent's position and the destination on the current path. Returns Success.")] + public class GetRemainingDistance : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [SharedRequired] + [Tooltip("The remaining distance")] + public SharedFloat storeValue; + + // cache the navmeshagent component + private NavMeshAgent navMeshAgent; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + navMeshAgent = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (navMeshAgent == null) { + Debug.LogWarning("NavMeshAgent is null"); + return TaskStatus.Failure; + } + + storeValue.Value = navMeshAgent.remainingDistance; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + storeValue = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/NavMeshAgent/GetRemainingDistance.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/NavMeshAgent/GetRemainingDistance.cs.meta new file mode 100644 index 0000000..f07ba12 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/NavMeshAgent/GetRemainingDistance.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: ab046b37543b6744aa440cd708a93b81 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/NavMeshAgent/GetSpeed.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/NavMeshAgent/GetSpeed.cs new file mode 100644 index 0000000..6e18c9d --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/NavMeshAgent/GetSpeed.cs @@ -0,0 +1,47 @@ +using UnityEngine; +using UnityEngine.AI; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityNavMeshAgent +{ + [TaskCategory("Unity/NavMeshAgent")] + [TaskDescription("Gets the maximum movement speed when following a path. Returns Success.")] + public class GetSpeed : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [SharedRequired] + [Tooltip("The NavMeshAgent speed")] + public SharedFloat storeValue; + + // cache the navmeshagent component + private NavMeshAgent navMeshAgent; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + navMeshAgent = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (navMeshAgent == null) { + Debug.LogWarning("NavMeshAgent is null"); + return TaskStatus.Failure; + } + + storeValue.Value = navMeshAgent.speed; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + storeValue = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/NavMeshAgent/GetSpeed.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/NavMeshAgent/GetSpeed.cs.meta new file mode 100644 index 0000000..5d4defe --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/NavMeshAgent/GetSpeed.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: b6397854a3aea4b44a5ab4ccf98d082d +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/NavMeshAgent/IsStopped.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/NavMeshAgent/IsStopped.cs new file mode 100644 index 0000000..aea54fa --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/NavMeshAgent/IsStopped.cs @@ -0,0 +1,41 @@ +using UnityEngine; +using UnityEngine.AI; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityNavMeshAgent +{ + [TaskCategory("Unity/NavMeshAgent")] + [TaskDescription("Is the agent stopped?")] + public class IsStopped : Conditional + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + + // cache the navmeshagent component + private NavMeshAgent navMeshAgent; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + navMeshAgent = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (navMeshAgent == null) { + Debug.LogWarning("NavMeshAgent is null"); + return TaskStatus.Failure; + } + + return navMeshAgent.isStopped ? TaskStatus.Success : TaskStatus.Failure; + } + + public override void OnReset() + { + targetGameObject = null; + } + } +} diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/NavMeshAgent/IsStopped.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/NavMeshAgent/IsStopped.cs.meta new file mode 100644 index 0000000..34c8b58 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/NavMeshAgent/IsStopped.cs.meta @@ -0,0 +1,12 @@ +fileFormatVersion: 2 +guid: 1b7f86ab194623f4997c385d2cce0caf +timeCreated: 1507329647 +licenseType: Store +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/NavMeshAgent/Move.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/NavMeshAgent/Move.cs new file mode 100644 index 0000000..a7c4808 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/NavMeshAgent/Move.cs @@ -0,0 +1,46 @@ +using UnityEngine; +using UnityEngine.AI; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityNavMeshAgent +{ + [TaskCategory("Unity/NavMeshAgent")] + [TaskDescription("Apply relative movement to the current position. Returns Success.")] + public class Move : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The relative movement vector")] + public SharedVector3 offset; + + // cache the navmeshagent component + private NavMeshAgent navMeshAgent; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + navMeshAgent = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (navMeshAgent == null) { + Debug.LogWarning("NavMeshAgent is null"); + return TaskStatus.Failure; + } + + navMeshAgent.Move(offset.Value); + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + offset = Vector3.zero; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/NavMeshAgent/Move.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/NavMeshAgent/Move.cs.meta new file mode 100644 index 0000000..bdceb77 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/NavMeshAgent/Move.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 55ea16e678f6fae47a46affd3d22b883 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/NavMeshAgent/ResetPath.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/NavMeshAgent/ResetPath.cs new file mode 100644 index 0000000..0c13570 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/NavMeshAgent/ResetPath.cs @@ -0,0 +1,43 @@ +using UnityEngine; +using UnityEngine.AI; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityNavMeshAgent +{ + [TaskCategory("Unity/NavMeshAgent")] + [TaskDescription("Clears the current path. Returns Success.")] + public class ResetPath : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + + // cache the navmeshagent component + private NavMeshAgent navMeshAgent; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + navMeshAgent = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (navMeshAgent == null) { + Debug.LogWarning("NavMeshAgent is null"); + return TaskStatus.Failure; + } + + navMeshAgent.ResetPath(); + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/NavMeshAgent/ResetPath.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/NavMeshAgent/ResetPath.cs.meta new file mode 100644 index 0000000..579ffdc --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/NavMeshAgent/ResetPath.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: e90973887b9e7d04aafc5d13ecdfc8b9 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/NavMeshAgent/Resume.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/NavMeshAgent/Resume.cs new file mode 100644 index 0000000..4faf7ad --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/NavMeshAgent/Resume.cs @@ -0,0 +1,43 @@ +using UnityEngine; +using UnityEngine.AI; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityNavMeshAgent +{ + [TaskCategory("Unity/NavMeshAgent")] + [TaskDescription("Resumes the movement along the current path after a pause. Returns Success.")] + public class Resume : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + + // cache the navmeshagent component + private NavMeshAgent navMeshAgent; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + navMeshAgent = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (navMeshAgent == null) { + Debug.LogWarning("NavMeshAgent is null"); + return TaskStatus.Failure; + } + + navMeshAgent.isStopped = false; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/NavMeshAgent/Resume.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/NavMeshAgent/Resume.cs.meta new file mode 100644 index 0000000..94fe5b4 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/NavMeshAgent/Resume.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 2c87e343e0ec23041b0cf7d8090d4814 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/NavMeshAgent/SetAcceleration.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/NavMeshAgent/SetAcceleration.cs new file mode 100644 index 0000000..3552b5a --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/NavMeshAgent/SetAcceleration.cs @@ -0,0 +1,46 @@ +using UnityEngine; +using UnityEngine.AI; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityNavMeshAgent +{ + [TaskCategory("Unity/NavMeshAgent")] + [TaskDescription("Sets the maximum acceleration of an agent as it follows a path, given in units / sec^2. Returns Success.")] + public class SetAcceleration : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The NavMeshAgent acceleration")] + public SharedFloat acceleration; + + // cache the navmeshagent component + private NavMeshAgent navMeshAgent; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + navMeshAgent = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (navMeshAgent == null) { + Debug.LogWarning("NavMeshAgent is null"); + return TaskStatus.Failure; + } + + navMeshAgent.acceleration = acceleration.Value; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + acceleration = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/NavMeshAgent/SetAcceleration.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/NavMeshAgent/SetAcceleration.cs.meta new file mode 100644 index 0000000..31d7d12 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/NavMeshAgent/SetAcceleration.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: a8357209bccc16442b549c580872bb05 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/NavMeshAgent/SetAngularSpeed.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/NavMeshAgent/SetAngularSpeed.cs new file mode 100644 index 0000000..1fa682f --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/NavMeshAgent/SetAngularSpeed.cs @@ -0,0 +1,46 @@ +using UnityEngine; +using UnityEngine.AI; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityNavMeshAgent +{ + [TaskCategory("Unity/NavMeshAgent")] + [TaskDescription("Sets the maximum turning speed in (deg/s) while following a path. Returns Success.")] + public class SetAngularSpeed : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The NavMeshAgent angular speed")] + public SharedFloat angularSpeed; + + // cache the navmeshagent component + private NavMeshAgent navMeshAgent; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + navMeshAgent = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (navMeshAgent == null) { + Debug.LogWarning("NavMeshAgent is null"); + return TaskStatus.Failure; + } + + navMeshAgent.angularSpeed = angularSpeed.Value; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + angularSpeed = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/NavMeshAgent/SetAngularSpeed.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/NavMeshAgent/SetAngularSpeed.cs.meta new file mode 100644 index 0000000..a19eb41 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/NavMeshAgent/SetAngularSpeed.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 0d8e213aa17540848b83b17ba1609c74 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/NavMeshAgent/SetDestination.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/NavMeshAgent/SetDestination.cs new file mode 100644 index 0000000..0ec07bc --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/NavMeshAgent/SetDestination.cs @@ -0,0 +1,45 @@ +using UnityEngine; +using UnityEngine.AI; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityNavMeshAgent +{ + [TaskCategory("Unity/NavMeshAgent")] + [TaskDescription("Sets the destination of the agent in world-space units. Returns Success if the destination is valid.")] + public class SetDestination: Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [SharedRequired] + [Tooltip("The NavMeshAgent destination")] + public SharedVector3 destination; + + // cache the navmeshagent component + private NavMeshAgent navMeshAgent; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + navMeshAgent = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (navMeshAgent == null) { + Debug.LogWarning("NavMeshAgent is null"); + return TaskStatus.Failure; + } + + return navMeshAgent.SetDestination(destination.Value) ? TaskStatus.Success : TaskStatus.Failure; + } + + public override void OnReset() + { + targetGameObject = null; + destination = Vector3.zero; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/NavMeshAgent/SetDestination.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/NavMeshAgent/SetDestination.cs.meta new file mode 100644 index 0000000..5f6feda --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/NavMeshAgent/SetDestination.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 55d9c2d20e895104181ae1b484868ead +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/NavMeshAgent/SetIsStopped.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/NavMeshAgent/SetIsStopped.cs new file mode 100644 index 0000000..36ad7a5 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/NavMeshAgent/SetIsStopped.cs @@ -0,0 +1,45 @@ +using UnityEngine; +using UnityEngine.AI; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityNavMeshAgent +{ + [TaskCategory("Unity/NavMeshAgent")] + [TaskDescription("Sets the stop status. Returns Success.")] + public class SetIsStopped : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The stop status")] + public SharedBool isStopped; + + // cache the navmeshagent component + private NavMeshAgent navMeshAgent; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + navMeshAgent = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (navMeshAgent == null) { + Debug.LogWarning("NavMeshAgent is null"); + return TaskStatus.Failure; + } + + navMeshAgent.isStopped = isStopped.Value; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + } + } +} diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/NavMeshAgent/SetIsStopped.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/NavMeshAgent/SetIsStopped.cs.meta new file mode 100644 index 0000000..22a2f3f --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/NavMeshAgent/SetIsStopped.cs.meta @@ -0,0 +1,12 @@ +fileFormatVersion: 2 +guid: 8b7446e67db5ff34a88b8fbc7899e5e9 +timeCreated: 1507381999 +licenseType: Store +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/NavMeshAgent/SetSpeed.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/NavMeshAgent/SetSpeed.cs new file mode 100644 index 0000000..d54f91e --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/NavMeshAgent/SetSpeed.cs @@ -0,0 +1,46 @@ +using UnityEngine; +using UnityEngine.AI; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityNavMeshAgent +{ + [TaskCategory("Unity/NavMeshAgent")] + [TaskDescription("Sets the maximum movement speed when following a path. Returns Success.")] + public class SetSpeed : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The NavMeshAgent speed")] + public SharedFloat speed; + + // cache the navmeshagent component + private NavMeshAgent navMeshAgent; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + navMeshAgent = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (navMeshAgent == null) { + Debug.LogWarning("NavMeshAgent is null"); + return TaskStatus.Failure; + } + + navMeshAgent.speed = speed.Value; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + speed = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/NavMeshAgent/SetSpeed.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/NavMeshAgent/SetSpeed.cs.meta new file mode 100644 index 0000000..3173ef5 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/NavMeshAgent/SetSpeed.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 34372b45870504b419f34165fb1fa4fb +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/NavMeshAgent/Stop.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/NavMeshAgent/Stop.cs new file mode 100644 index 0000000..f168fc6 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/NavMeshAgent/Stop.cs @@ -0,0 +1,43 @@ +using UnityEngine; +using UnityEngine.AI; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityNavMeshAgent +{ + [TaskCategory("Unity/NavMeshAgent")] + [TaskDescription("Stop movement of this agent along its current path. Returns Success.")] + public class Stop : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + + // cache the navmeshagent component + private NavMeshAgent navMeshAgent; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + navMeshAgent = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (navMeshAgent == null) { + Debug.LogWarning("NavMeshAgent is null"); + return TaskStatus.Failure; + } + + navMeshAgent.isStopped = true; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/NavMeshAgent/Stop.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/NavMeshAgent/Stop.cs.meta new file mode 100644 index 0000000..67e0d39 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/NavMeshAgent/Stop.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: b20958b8b92e47f40ba3178c99576182 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/NavMeshAgent/Warp.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/NavMeshAgent/Warp.cs new file mode 100644 index 0000000..37b0bdf --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/NavMeshAgent/Warp.cs @@ -0,0 +1,46 @@ +using UnityEngine; +using UnityEngine.AI; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityNavMeshAgent +{ + [TaskCategory("Unity/NavMeshAgent")] + [TaskDescription("Warps agent to the provided position. Returns Success.")] + public class Warp : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The position to warp to")] + public SharedVector3 newPosition; + + // cache the navmeshagent component + private NavMeshAgent navMeshAgent; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + navMeshAgent = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (navMeshAgent == null) { + Debug.LogWarning("NavMeshAgent is null"); + return TaskStatus.Failure; + } + + navMeshAgent.Warp(newPosition.Value); + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + newPosition = Vector3.zero; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/NavMeshAgent/Warp.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/NavMeshAgent/Warp.cs.meta new file mode 100644 index 0000000..9b17591 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/NavMeshAgent/Warp.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 9d2356bfaf0a64b4d9d65d32708630db +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem.meta new file mode 100644 index 0000000..7cee88f --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem.meta @@ -0,0 +1,4 @@ +fileFormatVersion: 2 +guid: 298b24307673c7a49b5cabe1dbcae115 +DefaultImporter: + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/Clear.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/Clear.cs new file mode 100644 index 0000000..d6ffc68 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/Clear.cs @@ -0,0 +1,41 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityParticleSystem +{ + [TaskCategory("Unity/ParticleSystem")] + [TaskDescription("Clear the Particle System.")] + public class Clear : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + + private ParticleSystem particleSystem; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + particleSystem = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (particleSystem == null) { + Debug.LogWarning("ParticleSystem is null"); + return TaskStatus.Failure; + } + + particleSystem.Clear(); + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/Clear.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/Clear.cs.meta new file mode 100644 index 0000000..0d63507 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/Clear.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: de273e542591d5946a8728190438ae27 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/GetDuration.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/GetDuration.cs new file mode 100644 index 0000000..ef2f9c9 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/GetDuration.cs @@ -0,0 +1,45 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityParticleSystem +{ + [TaskCategory("Unity/ParticleSystem")] + [TaskDescription("Stores the duration of the Particle System.")] + public class GetDuration : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The duration of the ParticleSystem")] + [RequiredField] + public SharedFloat storeResult; + + private ParticleSystem particleSystem; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + particleSystem = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (particleSystem == null) { + Debug.LogWarning("ParticleSystem is null"); + return TaskStatus.Failure; + } + + storeResult.Value = particleSystem.main.duration; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + storeResult = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/GetDuration.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/GetDuration.cs.meta new file mode 100644 index 0000000..f735803 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/GetDuration.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 02a4d610e82f1854c87701c4d51957fb +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/GetEmissionRate.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/GetEmissionRate.cs new file mode 100644 index 0000000..2796880 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/GetEmissionRate.cs @@ -0,0 +1,49 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityParticleSystem +{ + [TaskCategory("Unity/ParticleSystem")] + [TaskDescription("Stores the emission rate of the Particle System.")] + public class GetEmissionRate : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The emission rate of the ParticleSystem")] + [RequiredField] + public SharedFloat storeResult; + + private ParticleSystem particleSystem; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + particleSystem = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (particleSystem == null) { + Debug.LogWarning("ParticleSystem is null"); + return TaskStatus.Failure; + } + +#if !(UNITY_5_1 || UNITY_5_2) + Debug.Log("Warning: GetEmissionRate is not used in Unity 5.3 or later."); +#else + storeResult.Value = particleSystem.emissionRate; +#endif + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + storeResult = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/GetEmissionRate.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/GetEmissionRate.cs.meta new file mode 100644 index 0000000..cc913ca --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/GetEmissionRate.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 3adb98115d27ec64da9b5f56391570be +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/GetEnableEmission.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/GetEnableEmission.cs new file mode 100644 index 0000000..6313f4f --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/GetEnableEmission.cs @@ -0,0 +1,45 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityParticleSystem +{ + [TaskCategory("Unity/ParticleSystem")] + [TaskDescription("Stores if the Particle System is emitting particles.")] + public class GetEnableEmission : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("Is the Particle System emitting particles?")] + [RequiredField] + public SharedBool storeResult; + + private ParticleSystem particleSystem; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + particleSystem = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (particleSystem == null) { + Debug.LogWarning("ParticleSystem is null"); + return TaskStatus.Failure; + } + + storeResult.Value = particleSystem.emission.enabled; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + storeResult = false; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/GetEnableEmission.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/GetEnableEmission.cs.meta new file mode 100644 index 0000000..0b61019 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/GetEnableEmission.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 81dc1a241a2c872409a7919742df7581 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/GetLoop.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/GetLoop.cs new file mode 100644 index 0000000..ca54170 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/GetLoop.cs @@ -0,0 +1,45 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityParticleSystem +{ + [TaskCategory("Unity/ParticleSystem")] + [TaskDescription("Stores if the Particle System should loop.")] + public class GetLoop : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("Should the ParticleSystem loop?")] + [RequiredField] + public SharedBool storeResult; + + private ParticleSystem particleSystem; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + particleSystem = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (particleSystem == null) { + Debug.LogWarning("ParticleSystem is null"); + return TaskStatus.Failure; + } + + storeResult.Value = particleSystem.main.loop; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + storeResult = false; + } + } +} diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/GetLoop.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/GetLoop.cs.meta new file mode 100644 index 0000000..f2956bb --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/GetLoop.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 82f4ee8cf50887a4488fe6d0da18afc0 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/GetMaxParticles.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/GetMaxParticles.cs new file mode 100644 index 0000000..a3344e4 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/GetMaxParticles.cs @@ -0,0 +1,45 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityParticleSystem +{ + [TaskCategory("Unity/ParticleSystem")] + [TaskDescription("Stores the max particles of the Particle System.")] + public class GetMaxParticles : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The max particles of the ParticleSystem")] + [RequiredField] + public SharedFloat storeResult; + + private ParticleSystem particleSystem; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + particleSystem = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (particleSystem == null) { + Debug.LogWarning("ParticleSystem is null"); + return TaskStatus.Failure; + } + + storeResult.Value = particleSystem.main.maxParticles; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + storeResult = 0; + } + } +} diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/GetMaxParticles.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/GetMaxParticles.cs.meta new file mode 100644 index 0000000..cfff2dd --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/GetMaxParticles.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 429771af65df81c49aaf4b34630473fe +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/GetParticleCount.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/GetParticleCount.cs new file mode 100644 index 0000000..c5b6e66 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/GetParticleCount.cs @@ -0,0 +1,45 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityParticleSystem +{ + [TaskCategory("Unity/ParticleSystem")] + [TaskDescription("Stores the particle count of the Particle System.")] + public class GetParticleCount : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The particle count of the ParticleSystem")] + [RequiredField] + public SharedFloat storeResult; + + private ParticleSystem particleSystem; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + particleSystem = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (particleSystem == null) { + Debug.LogWarning("ParticleSystem is null"); + return TaskStatus.Failure; + } + + storeResult.Value = particleSystem.particleCount; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + storeResult = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/GetParticleCount.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/GetParticleCount.cs.meta new file mode 100644 index 0000000..ec3fba0 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/GetParticleCount.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: f32e2ff9de4ff7b47a256ac3b51123c6 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/GetPlaybackSpeed.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/GetPlaybackSpeed.cs new file mode 100644 index 0000000..8a7b93e --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/GetPlaybackSpeed.cs @@ -0,0 +1,46 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityParticleSystem +{ + [TaskCategory("Unity/ParticleSystem")] + [TaskDescription("Stores the playback speed of the Particle System.")] + public class GetPlaybackSpeed : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The playback speed of the ParticleSystem")] + [RequiredField] + public SharedFloat storeResult; + + private ParticleSystem particleSystem; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + particleSystem = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (particleSystem == null) { + Debug.LogWarning("ParticleSystem is null"); + return TaskStatus.Failure; + } + + ParticleSystem.MainModule mainParticleSystem = particleSystem.main; + storeResult.Value = mainParticleSystem.simulationSpeed; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + storeResult = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/GetPlaybackSpeed.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/GetPlaybackSpeed.cs.meta new file mode 100644 index 0000000..a053e81 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/GetPlaybackSpeed.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: f8f29f170ac706b498e7c933136d8036 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/GetTime.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/GetTime.cs new file mode 100644 index 0000000..c9f73da --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/GetTime.cs @@ -0,0 +1,45 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityParticleSystem +{ + [TaskCategory("Unity/ParticleSystem")] + [TaskDescription("Stores the time of the Particle System.")] + public class GetTime : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The time of the ParticleSystem")] + [RequiredField] + public SharedFloat storeResult; + + private ParticleSystem particleSystem; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + particleSystem = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (particleSystem == null) { + Debug.LogWarning("ParticleSystem is null"); + return TaskStatus.Failure; + } + + storeResult.Value = particleSystem.time; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + storeResult = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/GetTime.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/GetTime.cs.meta new file mode 100644 index 0000000..8a1d855 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/GetTime.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 9b15c7efbf98f7649adf8dd4474b0579 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/IsAlive.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/IsAlive.cs new file mode 100644 index 0000000..baef730 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/IsAlive.cs @@ -0,0 +1,39 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityParticleSystem +{ + [TaskCategory("Unity/ParticleSystem")] + [TaskDescription("Is the Particle System alive?")] + public class IsAlive : Conditional + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + + private ParticleSystem particleSystem; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + particleSystem = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (particleSystem == null) { + Debug.LogWarning("ParticleSystem is null"); + return TaskStatus.Failure; + } + + return particleSystem.IsAlive() ? TaskStatus.Success : TaskStatus.Failure; + } + + public override void OnReset() + { + targetGameObject = null; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/IsAlive.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/IsAlive.cs.meta new file mode 100644 index 0000000..725336e --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/IsAlive.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 3d554784e9a9fa040a2446402ba3f10e +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/IsPaused.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/IsPaused.cs new file mode 100644 index 0000000..53b61fc --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/IsPaused.cs @@ -0,0 +1,39 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityParticleSystem +{ + [TaskCategory("Unity/ParticleSystem")] + [TaskDescription("Is the Particle System paused?")] + public class IsPaused : Conditional + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + + private ParticleSystem particleSystem; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + particleSystem = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (particleSystem == null) { + Debug.LogWarning("ParticleSystem is null"); + return TaskStatus.Failure; + } + + return particleSystem.isPaused ? TaskStatus.Success : TaskStatus.Failure; + } + + public override void OnReset() + { + targetGameObject = null; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/IsPaused.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/IsPaused.cs.meta new file mode 100644 index 0000000..cce6df0 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/IsPaused.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: e4e9ab132f20dfa4095b3c90303ebf74 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/IsPlaying.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/IsPlaying.cs new file mode 100644 index 0000000..d27d63b --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/IsPlaying.cs @@ -0,0 +1,39 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityParticleSystem +{ + [TaskCategory("Unity/ParticleSystem")] + [TaskDescription("Is the Particle System playing?")] + public class IsPlaying : Conditional + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + + private ParticleSystem particleSystem; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + particleSystem = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (particleSystem == null) { + Debug.LogWarning("ParticleSystem is null"); + return TaskStatus.Failure; + } + + return particleSystem.isPlaying ? TaskStatus.Success : TaskStatus.Failure; + } + + public override void OnReset() + { + targetGameObject = null; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/IsPlaying.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/IsPlaying.cs.meta new file mode 100644 index 0000000..9f3cb6a --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/IsPlaying.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 654b51e99f64bfb489e12866a569f00e +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/IsStopped.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/IsStopped.cs new file mode 100644 index 0000000..2820df7 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/IsStopped.cs @@ -0,0 +1,39 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityParticleSystem +{ + [TaskCategory("Unity/ParticleSystem")] + [TaskDescription("Is the Particle System stopped?")] + public class IsStopped : Conditional + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + + private ParticleSystem particleSystem; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + particleSystem = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (particleSystem == null) { + Debug.LogWarning("ParticleSystem is null"); + return TaskStatus.Failure; + } + + return particleSystem.isStopped ? TaskStatus.Success : TaskStatus.Failure; + } + + public override void OnReset() + { + targetGameObject = null; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/IsStopped.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/IsStopped.cs.meta new file mode 100644 index 0000000..61219cd --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/IsStopped.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: c719a7379c22b184380b4e63ccdfd064 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/Pause.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/Pause.cs new file mode 100644 index 0000000..dc93485 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/Pause.cs @@ -0,0 +1,41 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityParticleSystem +{ + [TaskCategory("Unity/ParticleSystem")] + [TaskDescription("Pause the Particle System.")] + public class Pause : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + + private ParticleSystem particleSystem; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + particleSystem = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (particleSystem == null) { + Debug.LogWarning("ParticleSystem is null"); + return TaskStatus.Failure; + } + + particleSystem.Pause(); + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/Pause.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/Pause.cs.meta new file mode 100644 index 0000000..da4922e --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/Pause.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: c9c9cc56691817b49af4fd1cfbc3e363 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/Play.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/Play.cs new file mode 100644 index 0000000..907aba4 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/Play.cs @@ -0,0 +1,41 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityParticleSystem +{ + [TaskCategory("Unity/ParticleSystem")] + [TaskDescription("Play the Particle System.")] + public class Play : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + + private ParticleSystem particleSystem; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + particleSystem = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (particleSystem == null) { + Debug.LogWarning("ParticleSystem is null"); + return TaskStatus.Failure; + } + + particleSystem.Play(); + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/Play.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/Play.cs.meta new file mode 100644 index 0000000..3d9a8d4 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/Play.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: a8ffb889d35074d4fb08d8502155c0b2 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/SetEmissionRate.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/SetEmissionRate.cs new file mode 100644 index 0000000..536c2a9 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/SetEmissionRate.cs @@ -0,0 +1,48 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityParticleSystem +{ + [TaskCategory("Unity/ParticleSystem")] + [TaskDescription("Sets the emission rate of the Particle System.")] + public class SetEmissionRate : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The emission rate of the ParticleSystem")] + public SharedFloat emissionRate; + + private ParticleSystem particleSystem; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + particleSystem = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (particleSystem == null) { + Debug.LogWarning("ParticleSystem is null"); + return TaskStatus.Failure; + } + +#if !(UNITY_5_1 || UNITY_5_2) + Debug.Log("Warning: SetEmissionRate is not used in Unity 5.3 or later."); +#else + particleSystem.emissionRate = emissionRate.Value; +#endif + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + emissionRate = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/SetEmissionRate.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/SetEmissionRate.cs.meta new file mode 100644 index 0000000..2b47f82 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/SetEmissionRate.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: a8300eee629ad77419f2eb91477a0b62 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/SetEnableEmission.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/SetEnableEmission.cs new file mode 100644 index 0000000..8248738 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/SetEnableEmission.cs @@ -0,0 +1,45 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityParticleSystem +{ + [TaskCategory("Unity/ParticleSystem")] + [TaskDescription("Enables or disables the Particle System emission.")] + public class SetEnableEmission : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("Enable the ParticleSystem emissions?")] + public SharedBool enable; + + private ParticleSystem particleSystem; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + particleSystem = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (particleSystem == null) { + Debug.LogWarning("ParticleSystem is null"); + return TaskStatus.Failure; + } + + var emission = particleSystem.emission; + emission.enabled = enable.Value; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + enable = false; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/SetEnableEmission.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/SetEnableEmission.cs.meta new file mode 100644 index 0000000..f3d412e --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/SetEnableEmission.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: f7c295b4d24628146a885d21bf699993 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/SetLoop.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/SetLoop.cs new file mode 100644 index 0000000..ea13ccd --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/SetLoop.cs @@ -0,0 +1,45 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityParticleSystem +{ + [TaskCategory("Unity/ParticleSystem")] + [TaskDescription("Sets if the Particle System should loop.")] + public class SetLoop : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("Should the ParticleSystem loop?")] + public SharedBool loop; + + private ParticleSystem particleSystem; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + particleSystem = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (particleSystem == null) { + Debug.LogWarning("ParticleSystem is null"); + return TaskStatus.Failure; + } + + ParticleSystem.MainModule mainParticleSystem = particleSystem.main; + mainParticleSystem.loop = loop.Value; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + loop = false; + } + } +} diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/SetLoop.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/SetLoop.cs.meta new file mode 100644 index 0000000..3b3736b --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/SetLoop.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: b9fa90adc0377cc4592de00e410a4060 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/SetMaxParticles.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/SetMaxParticles.cs new file mode 100644 index 0000000..e37909e --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/SetMaxParticles.cs @@ -0,0 +1,44 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityParticleSystem +{ + [TaskCategory("Unity/ParticleSystem")] + [TaskDescription("Sets the max particles of the Particle System.")] + public class SetMaxParticles : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The max particles of the ParticleSystem")] + public SharedInt maxParticles; + + private ParticleSystem particleSystem; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + particleSystem = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (particleSystem == null) { + Debug.LogWarning("ParticleSystem is null"); + return TaskStatus.Failure; + } + ParticleSystem.MainModule mainParticleSystem = particleSystem.main; + mainParticleSystem.maxParticles = maxParticles.Value; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + maxParticles = 0; + } + } +} diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/SetMaxParticles.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/SetMaxParticles.cs.meta new file mode 100644 index 0000000..d580519 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/SetMaxParticles.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: eadca930ad32a404886060ee43e4d802 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/SetPlaybackSpeed.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/SetPlaybackSpeed.cs new file mode 100644 index 0000000..e4eabc6 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/SetPlaybackSpeed.cs @@ -0,0 +1,45 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityParticleSystem +{ + [TaskCategory("Unity/ParticleSystem")] + [TaskDescription("Sets the playback speed of the Particle System.")] + public class SetPlaybackSpeed : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The playback speed of the ParticleSystem")] + public SharedFloat playbackSpeed = 1; + + private ParticleSystem particleSystem; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + particleSystem = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (particleSystem == null) { + Debug.LogWarning("ParticleSystem is null"); + return TaskStatus.Failure; + } + + ParticleSystem.MainModule mainParticleSystem = particleSystem.main; + mainParticleSystem.simulationSpeed = playbackSpeed.Value; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + playbackSpeed = 1; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/SetPlaybackSpeed.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/SetPlaybackSpeed.cs.meta new file mode 100644 index 0000000..16007fa --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/SetPlaybackSpeed.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 8f4d79e34ac8820458a2813895d3962d +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/SetStartColor.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/SetStartColor.cs new file mode 100644 index 0000000..43a2f88 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/SetStartColor.cs @@ -0,0 +1,45 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityParticleSystem +{ + [TaskCategory("Unity/ParticleSystem")] + [TaskDescription("Sets the start color of the Particle System.")] + public class SetStartColor : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The start color of the ParticleSystem")] + public SharedColor startColor; + + private ParticleSystem particleSystem; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + particleSystem = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (particleSystem == null) { + Debug.LogWarning("ParticleSystem is null"); + return TaskStatus.Failure; + } + + ParticleSystem.MainModule mainParticleSystem = particleSystem.main; + mainParticleSystem.startColor = startColor.Value; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + startColor = Color.white; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/SetStartColor.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/SetStartColor.cs.meta new file mode 100644 index 0000000..ca6b403 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/SetStartColor.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: f91be163d0c01ec42bf120c267dcceea +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/SetStartDelay.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/SetStartDelay.cs new file mode 100644 index 0000000..e56181c --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/SetStartDelay.cs @@ -0,0 +1,45 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityParticleSystem +{ + [TaskCategory("Unity/ParticleSystem")] + [TaskDescription("Sets the start delay of the Particle System.")] + public class SetStartDelay : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The start delay of the ParticleSystem")] + public SharedFloat startDelay; + + private ParticleSystem particleSystem; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + particleSystem = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (particleSystem == null) { + Debug.LogWarning("ParticleSystem is null"); + return TaskStatus.Failure; + } + + ParticleSystem.MainModule mainParticleSystem = particleSystem.main; + mainParticleSystem.startDelay = startDelay.Value; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + startDelay = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/SetStartDelay.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/SetStartDelay.cs.meta new file mode 100644 index 0000000..5292374 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/SetStartDelay.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 532026cf3b430c840897e66bdde5006e +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/SetStartLifetime.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/SetStartLifetime.cs new file mode 100644 index 0000000..627f5a3 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/SetStartLifetime.cs @@ -0,0 +1,45 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityParticleSystem +{ + [TaskCategory("Unity/ParticleSystem")] + [TaskDescription("Sets the start lifetime of the Particle System.")] + public class SetStartLifetime : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The start lifetime of the ParticleSystem")] + public SharedFloat startLifetime; + + private ParticleSystem particleSystem; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + particleSystem = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (particleSystem == null) { + Debug.LogWarning("ParticleSystem is null"); + return TaskStatus.Failure; + } + + ParticleSystem.MainModule mainParticleSystem = particleSystem.main; + mainParticleSystem.startLifetime = startLifetime.Value; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + startLifetime = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/SetStartLifetime.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/SetStartLifetime.cs.meta new file mode 100644 index 0000000..cc4506d --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/SetStartLifetime.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 311b9ed850b4e2243ae44487b9ece819 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/SetStartRotation.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/SetStartRotation.cs new file mode 100644 index 0000000..cd00f96 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/SetStartRotation.cs @@ -0,0 +1,45 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityParticleSystem +{ + [TaskCategory("Unity/ParticleSystem")] + [TaskDescription("Sets the start rotation of the Particle System.")] + public class SetStartRotation : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The start rotation of the ParticleSystem")] + public SharedFloat startRotation; + + private ParticleSystem particleSystem; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + particleSystem = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (particleSystem == null) { + Debug.LogWarning("ParticleSystem is null"); + return TaskStatus.Failure; + } + + ParticleSystem.MainModule mainParticleSystem = particleSystem.main; + mainParticleSystem.startRotation = startRotation.Value; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + startRotation = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/SetStartRotation.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/SetStartRotation.cs.meta new file mode 100644 index 0000000..b2eb21f --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/SetStartRotation.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: ae611ab09913de6438aeb81d7a621c51 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/SetStartSize.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/SetStartSize.cs new file mode 100644 index 0000000..cef0ef8 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/SetStartSize.cs @@ -0,0 +1,45 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityParticleSystem +{ + [TaskCategory("Unity/ParticleSystem")] + [TaskDescription("Sets the start size of the Particle System.")] + public class SetStartSize : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The start size of the ParticleSystem")] + public SharedFloat startSize; + + private ParticleSystem particleSystem; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + particleSystem = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (particleSystem == null) { + Debug.LogWarning("ParticleSystem is null"); + return TaskStatus.Failure; + } + + ParticleSystem.MainModule mainParticleSystem = particleSystem.main; + mainParticleSystem.startSize = startSize.Value; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + startSize = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/SetStartSize.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/SetStartSize.cs.meta new file mode 100644 index 0000000..7dc39bf --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/SetStartSize.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: d7be6a1da3f4f7a418e5739a6cc6e78e +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/SetStartSpeed.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/SetStartSpeed.cs new file mode 100644 index 0000000..4856dd2 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/SetStartSpeed.cs @@ -0,0 +1,45 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityParticleSystem +{ + [TaskCategory("Unity/ParticleSystem")] + [TaskDescription("Sets the start speed of the Particle System.")] + public class SetStartSpeed : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The start speed of the ParticleSystem")] + public SharedFloat startSpeed; + + private ParticleSystem particleSystem; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + particleSystem = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (particleSystem == null) { + Debug.LogWarning("ParticleSystem is null"); + return TaskStatus.Failure; + } + + ParticleSystem.MainModule mainParticleSystem = particleSystem.main; + mainParticleSystem.startSpeed = startSpeed.Value; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + startSpeed = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/SetStartSpeed.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/SetStartSpeed.cs.meta new file mode 100644 index 0000000..ed294e2 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/SetStartSpeed.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: b7716318475d3854a96729d1a7540d4a +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/SetTime.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/SetTime.cs new file mode 100644 index 0000000..35e9e42 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/SetTime.cs @@ -0,0 +1,44 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityParticleSystem +{ + [TaskCategory("Unity/ParticleSystem")] + [TaskDescription("Sets the time of the Particle System.")] + public class SetTime : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The time of the ParticleSystem")] + public SharedFloat time; + + private ParticleSystem particleSystem; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + particleSystem = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (particleSystem == null) { + Debug.LogWarning("ParticleSystem is null"); + return TaskStatus.Failure; + } + + particleSystem.time = time.Value; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + time = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/SetTime.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/SetTime.cs.meta new file mode 100644 index 0000000..9ca5aa9 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/SetTime.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 103e78e9c755fe3469e63115eb1c0d80 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/Simulate.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/Simulate.cs new file mode 100644 index 0000000..0c75412 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/Simulate.cs @@ -0,0 +1,44 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityParticleSystem +{ + [TaskCategory("Unity/ParticleSystem")] + [TaskDescription("Simulate the Particle System.")] + public class Simulate : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("Time to fastfoward the Particle System to")] + public SharedFloat time; + + private ParticleSystem particleSystem; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + particleSystem = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (particleSystem == null) { + Debug.LogWarning("ParticleSystem is null"); + return TaskStatus.Failure; + } + + particleSystem.Simulate(time.Value); + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + time = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/Simulate.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/Simulate.cs.meta new file mode 100644 index 0000000..d1234fd --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/Simulate.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 24d79d661acf61e44918320624b49dd5 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/Stop.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/Stop.cs new file mode 100644 index 0000000..2911847 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/Stop.cs @@ -0,0 +1,41 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityParticleSystem +{ + [TaskCategory("Unity/ParticleSystem")] + [TaskDescription("Stop the Particle System.")] + public class Stop : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + + private ParticleSystem particleSystem; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + particleSystem = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (particleSystem == null) { + Debug.LogWarning("ParticleSystem is null"); + return TaskStatus.Failure; + } + + particleSystem.Stop(); + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/Stop.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/Stop.cs.meta new file mode 100644 index 0000000..7c2dc1d --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/ParticleSystem/Stop.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: fd83617024d6bff44824a83b472db8e6 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Physics.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Physics.meta new file mode 100644 index 0000000..267455f --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Physics.meta @@ -0,0 +1,4 @@ +fileFormatVersion: 2 +guid: f029d04458be91f4d9b9bec1c9ccfde7 +DefaultImporter: + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Physics/Linecast.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Physics/Linecast.cs new file mode 100644 index 0000000..1abefa7 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Physics/Linecast.cs @@ -0,0 +1,28 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityPhysics +{ + [TaskCategory("Unity/Physics")] + [TaskDescription("Returns success if there is any collider intersecting the line between start and end")] + public class Linecast : Action + { + [Tooltip("The starting position of the linecast")] + public SharedVector3 startPosition; + [Tooltip("The ending position of the linecast")] + public SharedVector3 endPosition; + [Tooltip("Selectively ignore colliders.")] + public LayerMask layerMask = -1; + + public override TaskStatus OnUpdate() + { + return Physics.Linecast(startPosition.Value, endPosition.Value, layerMask) ? TaskStatus.Success : TaskStatus.Failure; + } + + public override void OnReset() + { + startPosition = Vector3.zero; + endPosition = Vector3.zero; + layerMask = -1; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Physics/Linecast.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Physics/Linecast.cs.meta new file mode 100644 index 0000000..ce27adb --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Physics/Linecast.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 163f5567b8906cd45adf138c3c022152 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Physics/Raycast.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Physics/Raycast.cs new file mode 100644 index 0000000..1c163dd --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Physics/Raycast.cs @@ -0,0 +1,70 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityPhysics +{ + [TaskCategory("Unity/Physics")] + [TaskDescription("Casts a ray against all colliders in the scene. Returns success if a collider was hit.")] + public class Raycast : Action + { + [Tooltip("Starts the ray at the GameObject's position. If null the originPosition will be used")] + public SharedGameObject originGameObject; + [Tooltip("Starts the ray at the position. Only used if originGameObject is null")] + public SharedVector3 originPosition; + [Tooltip("The direction of the ray")] + public SharedVector3 direction; + [Tooltip("The length of the ray. Set to -1 for infinity")] + public SharedFloat distance = -1; + [Tooltip("Selectively ignore colliders")] + public LayerMask layerMask = -1; + [Tooltip("Cast the ray in world or local space. The direction is in world space if no GameObject is specified")] + public Space space = Space.Self; + + [SharedRequired] + [Tooltip("Stores the hit object of the raycast")] + public SharedGameObject storeHitObject; + [SharedRequired] + [Tooltip("Stores the hit point of the raycast")] + public SharedVector3 storeHitPoint; + [SharedRequired] + [Tooltip("Stores the hit normal of the raycast")] + public SharedVector3 storeHitNormal; + [SharedRequired] + [Tooltip("Stores the hit distance of the raycast")] + public SharedFloat storeHitDistance; + + public override TaskStatus OnUpdate() + { + Vector3 position; + Vector3 dir = direction.Value; + if (originGameObject.Value != null) { + position = originGameObject.Value.transform.position; + if (space == Space.Self) { + dir = originGameObject.Value.transform.TransformDirection(direction.Value); + } + } else { + position = originPosition.Value; + } + + RaycastHit hit; + if (Physics.Raycast(position, dir, out hit, distance.Value == -1 ? Mathf.Infinity : distance.Value, layerMask)) { + storeHitObject.Value = hit.collider.gameObject; + storeHitPoint.Value = hit.point; + storeHitNormal.Value = hit.normal; + storeHitDistance.Value = hit.distance; + return TaskStatus.Success; + } + + return TaskStatus.Failure; + } + + public override void OnReset() + { + originGameObject = null; + originPosition = Vector3.zero; + direction = Vector3.zero; + distance = -1; + layerMask = -1; + space = Space.Self; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Physics/Raycast.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Physics/Raycast.cs.meta new file mode 100644 index 0000000..79cb22a --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Physics/Raycast.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: afcf9d39edef45146ad7a043b8bfa76e +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Physics/Spherecast.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Physics/Spherecast.cs new file mode 100644 index 0000000..d168e2f --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Physics/Spherecast.cs @@ -0,0 +1,73 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityPhysics +{ + [TaskCategory("Unity/Physics")] + [TaskDescription("Casts a sphere against all colliders in the scene. Returns success if a collider was hit.")] + public class SphereCast : Action + { + [Tooltip("Starts the spherecast at the GameObject's position. If null the originPosition will be used")] + public SharedGameObject originGameObject; + [Tooltip("Starts the sherecast at the position. Only used if originGameObject is null")] + public SharedVector3 originPosition; + [Tooltip("The radius of the spherecast")] + public SharedFloat radius; + [Tooltip("The direction of the spherecast")] + public SharedVector3 direction; + [Tooltip("The length of the spherecast. Set to -1 for infinity")] + public SharedFloat distance = -1; + [Tooltip("Selectively ignore colliders")] + public LayerMask layerMask = -1; + [Tooltip("Use world or local space. The direction is in world space if no GameObject is specified")] + public Space space = Space.Self; + + [SharedRequired] + [Tooltip("Stores the hit object of the spherecast")] + public SharedGameObject storeHitObject; + [SharedRequired] + [Tooltip("Stores the hit point of the spherecast")] + public SharedVector3 storeHitPoint; + [SharedRequired] + [Tooltip("Stores the hit normal of the spherecast")] + public SharedVector3 storeHitNormal; + [SharedRequired] + [Tooltip("Stores the hit distance of the spherecast")] + public SharedFloat storeHitDistance; + + public override TaskStatus OnUpdate() + { + Vector3 position; + Vector3 dir = direction.Value; + if (originGameObject.Value != null) { + position = originGameObject.Value.transform.position; + if (space == Space.Self) { + dir = originGameObject.Value.transform.TransformDirection(direction.Value); + } + } else { + position = originPosition.Value; + } + + RaycastHit hit; + if (Physics.SphereCast(position, radius.Value, dir, out hit, distance.Value == -1 ? Mathf.Infinity : distance.Value, layerMask)) { + storeHitObject.Value = hit.collider.gameObject; + storeHitPoint.Value = hit.point; + storeHitNormal.Value = hit.normal; + storeHitDistance.Value = hit.distance; + return TaskStatus.Success; + } + + return TaskStatus.Failure; + } + + public override void OnReset() + { + originGameObject = null; + originPosition = Vector3.zero; + radius = 0; + direction = Vector3.zero; + distance = -1; + layerMask = -1; + space = Space.Self; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Physics/Spherecast.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Physics/Spherecast.cs.meta new file mode 100644 index 0000000..93f3804 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Physics/Spherecast.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 2058f3f94c5bdf5409f9ff80ea61d44a +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Physics2D.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Physics2D.meta new file mode 100644 index 0000000..57df9f4 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Physics2D.meta @@ -0,0 +1,4 @@ +fileFormatVersion: 2 +guid: 056a8d0f58dcb4749949548a468e90c0 +DefaultImporter: + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Physics2D/Circlecast.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Physics2D/Circlecast.cs new file mode 100644 index 0000000..e00abdc --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Physics2D/Circlecast.cs @@ -0,0 +1,72 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityPhysics2D +{ + [TaskCategory("Unity/Physics2D")] + [TaskDescription("Casts a circle against all colliders in the scene. Returns success if a collider was hit.")] + public class Circlecast : Action + { + [Tooltip("Starts the circlecast at the GameObject's position. If null the originPosition will be used.")] + public SharedGameObject originGameObject; + [Tooltip("Starts the circlecast at the position. Only used if originGameObject is null.")] + public SharedVector2 originPosition; + [Tooltip("The radius of the circlecast")] + public SharedFloat radius; + [Tooltip("The direction of the circlecast")] + public SharedVector2 direction; + [Tooltip("The length of the ray. Set to -1 for infinity.")] + public SharedFloat distance = -1; + [Tooltip("Selectively ignore colliders.")] + public LayerMask layerMask = -1; + [Tooltip("Use world or local space. The direction is in world space if no GameObject is specified.")] + public Space space = Space.Self; + + [SharedRequired] + [Tooltip("Stores the hit object of the circlecast.")] + public SharedGameObject storeHitObject; + [SharedRequired] + [Tooltip("Stores the hit point of the circlecast.")] + public SharedVector2 storeHitPoint; + [SharedRequired] + [Tooltip("Stores the hit normal of the circlecast.")] + public SharedVector2 storeHitNormal; + [SharedRequired] + [Tooltip("Stores the hit distance of the circlecast.")] + public SharedFloat storeHitDistance; + + public override TaskStatus OnUpdate() + { + Vector2 position; + Vector2 dir = direction.Value; + if (originGameObject.Value != null) { + position = originGameObject.Value.transform.position; + if (space == Space.Self) { + dir = originGameObject.Value.transform.TransformDirection(direction.Value); + } + } else { + position = originPosition.Value; + } + + var hit = Physics2D.CircleCast(position, radius.Value, dir, distance.Value == -1 ? Mathf.Infinity : distance.Value, layerMask); + if (hit.collider != null) { + storeHitObject.Value = hit.collider.gameObject; + storeHitPoint.Value = hit.point; + storeHitNormal.Value = hit.normal; + storeHitDistance.Value = hit.distance; + return TaskStatus.Success; + } + return TaskStatus.Failure; + } + + public override void OnReset() + { + originGameObject = null; + originPosition = Vector2.zero; + direction = Vector2.zero; + radius = 0; + distance = -1; + layerMask = -1; + space = Space.Self; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Physics2D/Circlecast.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Physics2D/Circlecast.cs.meta new file mode 100644 index 0000000..5ba9d49 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Physics2D/Circlecast.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 6989aa8730764ee459a07f88d84302e0 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Physics2D/Linecast.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Physics2D/Linecast.cs new file mode 100644 index 0000000..8f83668 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Physics2D/Linecast.cs @@ -0,0 +1,28 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityPhysics2D +{ + [TaskCategory("Unity/Physics2D")] + [TaskDescription("Returns success if there is any collider intersecting the line between start and end")] + public class Linecast : Action + { + [Tooltip("The starting position of the linecast.")] + public SharedVector2 startPosition; + [Tooltip("The ending position of the linecast.")] + public SharedVector2 endPosition; + [Tooltip("Selectively ignore colliders.")] + public LayerMask layerMask = -1; + + public override TaskStatus OnUpdate() + { + return Physics2D.Linecast(startPosition.Value, endPosition.Value, layerMask) ? TaskStatus.Success : TaskStatus.Failure; + } + + public override void OnReset() + { + startPosition = Vector2.zero; + endPosition = Vector2.zero; + layerMask = -1; + } + } +} diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Physics2D/Linecast.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Physics2D/Linecast.cs.meta new file mode 100644 index 0000000..1c907c5 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Physics2D/Linecast.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: a402dbfe872764f49b3a03d7048e866e +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Physics2D/Raycast.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Physics2D/Raycast.cs new file mode 100644 index 0000000..21bf47d --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Physics2D/Raycast.cs @@ -0,0 +1,71 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityPhysics2D +{ + [TaskCategory("Unity/Physics2D")] + [TaskDescription("Casts a ray against all colliders in the scene. Returns success if a collider was hit.")] + public class Raycast : Action + { + [Tooltip("Starts the ray at the GameObject's position. If null the originPosition will be used.")] + public SharedGameObject originGameObject; + [Tooltip("Starts the ray at the position. Only used if originGameObject is null.")] + public SharedVector2 originPosition; + [Tooltip("The direction of the ray")] + public SharedVector2 direction; + [Tooltip("The length of the ray. Set to -1 for infinity.")] + public SharedFloat distance = -1; + [Tooltip("Selectively ignore colliders.")] + public LayerMask layerMask = -1; + [Tooltip("Cast the ray in world or local space. The direction is in world space if no GameObject is specified.")] + public Space space = Space.Self; + + [SharedRequired] + [Tooltip("Stores the hit object of the raycast.")] + public SharedGameObject storeHitObject; + [SharedRequired] + [Tooltip("Stores the hit point of the raycast.")] + public SharedVector2 storeHitPoint; + [SharedRequired] + [Tooltip("Stores the hit normal of the raycast.")] + public SharedVector2 storeHitNormal; + [SharedRequired] + [Tooltip("Stores the hit distance of the raycast.")] + public SharedFloat storeHitDistance; + + public override TaskStatus OnUpdate() + { + Vector2 position; + Vector2 dir = direction.Value; + if (originGameObject.Value != null) { + position = originGameObject.Value.transform.position; + if (space == Space.Self) { + dir = originGameObject.Value.transform.TransformDirection(direction.Value); + } + } else { + position = originPosition.Value; + } + + var hit = Physics2D.Raycast(position, dir, distance.Value == -1 ? Mathf.Infinity : distance.Value, layerMask); + if (hit.collider != null) { + storeHitObject.Value = hit.collider.gameObject; + storeHitPoint.Value = hit.point; + storeHitNormal.Value = hit.normal; +#if !UNITY_4_3 + storeHitDistance.Value = hit.distance; +#endif + return TaskStatus.Success; + } + return TaskStatus.Failure; + } + + public override void OnReset() + { + originGameObject = null; + originPosition = Vector2.zero; + direction = Vector2.zero; + distance = -1; + layerMask = -1; + space = Space.Self; + } + } +} diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Physics2D/Raycast.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Physics2D/Raycast.cs.meta new file mode 100644 index 0000000..efa824c --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Physics2D/Raycast.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 513dc641bb68bcc4d9c3bdfb1ccc57b6 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/PlayerPrefs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/PlayerPrefs.meta new file mode 100644 index 0000000..a552708 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/PlayerPrefs.meta @@ -0,0 +1,4 @@ +fileFormatVersion: 2 +guid: ae97053a4ac34f74d8edc5c635b28bda +DefaultImporter: + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/PlayerPrefs/DeleteAll.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/PlayerPrefs/DeleteAll.cs new file mode 100644 index 0000000..2560326 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/PlayerPrefs/DeleteAll.cs @@ -0,0 +1,16 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityPlayerPrefs +{ + [TaskCategory("Unity/PlayerPrefs")] + [TaskDescription("Deletes all entries from the PlayerPrefs.")] + public class DeleteAll : Action + { + public override TaskStatus OnUpdate() + { + PlayerPrefs.DeleteAll(); + + return TaskStatus.Success; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/PlayerPrefs/DeleteAll.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/PlayerPrefs/DeleteAll.cs.meta new file mode 100644 index 0000000..bb93ba6 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/PlayerPrefs/DeleteAll.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 0c6d6b2dabc08ac42875cdbe1f86642b +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/PlayerPrefs/DeleteKey.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/PlayerPrefs/DeleteKey.cs new file mode 100644 index 0000000..bad8eb9 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/PlayerPrefs/DeleteKey.cs @@ -0,0 +1,24 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityPlayerPrefs +{ + [TaskCategory("Unity/PlayerPrefs")] + [TaskDescription("Deletes the specified key from the PlayerPrefs.")] + public class DeleteKey : Action + { + [Tooltip("The key to delete")] + public SharedString key; + + public override TaskStatus OnUpdate() + { + PlayerPrefs.DeleteKey(key.Value); + + return TaskStatus.Success; + } + + public override void OnReset() + { + key = ""; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/PlayerPrefs/DeleteKey.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/PlayerPrefs/DeleteKey.cs.meta new file mode 100644 index 0000000..5428849 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/PlayerPrefs/DeleteKey.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: ed24098bd046f724e90474d47e1677d3 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/PlayerPrefs/GetFloat.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/PlayerPrefs/GetFloat.cs new file mode 100644 index 0000000..e9c808c --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/PlayerPrefs/GetFloat.cs @@ -0,0 +1,31 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityPlayerPrefs +{ + [TaskCategory("Unity/PlayerPrefs")] + [TaskDescription("Stores the value with the specified key from the PlayerPrefs.")] + public class GetFloat : Action + { + [Tooltip("The key to store")] + public SharedString key; + [Tooltip("The default value")] + public SharedFloat defaultValue; + [Tooltip("The value retrieved from the PlayerPrefs")] + [RequiredField] + public SharedFloat storeResult; + + public override TaskStatus OnUpdate() + { + storeResult.Value = PlayerPrefs.GetFloat(key.Value, defaultValue.Value); + + return TaskStatus.Success; + } + + public override void OnReset() + { + key = ""; + defaultValue = 0; + storeResult = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/PlayerPrefs/GetFloat.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/PlayerPrefs/GetFloat.cs.meta new file mode 100644 index 0000000..b85df40 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/PlayerPrefs/GetFloat.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 14752e1987d17d546838a32459045c67 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/PlayerPrefs/GetInt.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/PlayerPrefs/GetInt.cs new file mode 100644 index 0000000..f5ec055 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/PlayerPrefs/GetInt.cs @@ -0,0 +1,31 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityPlayerPrefs +{ + [TaskCategory("Unity/PlayerPrefs")] + [TaskDescription("Stores the value with the specified key from the PlayerPrefs.")] + public class GetInt : Action + { + [Tooltip("The key to store")] + public SharedString key; + [Tooltip("The default value")] + public SharedInt defaultValue; + [Tooltip("The value retrieved from the PlayerPrefs")] + [RequiredField] + public SharedInt storeResult; + + public override TaskStatus OnUpdate() + { + storeResult.Value = PlayerPrefs.GetInt(key.Value, defaultValue.Value); + + return TaskStatus.Success; + } + + public override void OnReset() + { + key = ""; + defaultValue = 0; + storeResult = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/PlayerPrefs/GetInt.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/PlayerPrefs/GetInt.cs.meta new file mode 100644 index 0000000..1f711f2 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/PlayerPrefs/GetInt.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 66c5c9cfd0fb52344875db0cefc5d6f8 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/PlayerPrefs/GetString.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/PlayerPrefs/GetString.cs new file mode 100644 index 0000000..cc38b81 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/PlayerPrefs/GetString.cs @@ -0,0 +1,31 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityPlayerPrefs +{ + [TaskCategory("Unity/PlayerPrefs")] + [TaskDescription("Stores the value with the specified key from the PlayerPrefs.")] + public class GetString : Action + { + [Tooltip("The key to store")] + public SharedString key; + [Tooltip("The default value")] + public SharedString defaultValue; + [Tooltip("The value retrieved from the PlayerPrefs")] + [RequiredField] + public SharedString storeResult; + + public override TaskStatus OnUpdate() + { + storeResult.Value = PlayerPrefs.GetString(key.Value, defaultValue.Value); + + return TaskStatus.Success; + } + + public override void OnReset() + { + key = ""; + defaultValue = ""; + storeResult = ""; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/PlayerPrefs/GetString.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/PlayerPrefs/GetString.cs.meta new file mode 100644 index 0000000..b0aca45 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/PlayerPrefs/GetString.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 418066da4d19f1742a6435c0ee7aa01b +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/PlayerPrefs/HasKey.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/PlayerPrefs/HasKey.cs new file mode 100644 index 0000000..08c2951 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/PlayerPrefs/HasKey.cs @@ -0,0 +1,22 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityPlayerPrefs +{ + [TaskCategory("Unity/PlayerPrefs")] + [TaskDescription("Retruns success if the specified key exists.")] + public class HasKey : Conditional + { + [Tooltip("The key to check")] + public SharedString key; + + public override TaskStatus OnUpdate() + { + return PlayerPrefs.HasKey(key.Value) ? TaskStatus.Success : TaskStatus.Failure; + } + + public override void OnReset() + { + key = ""; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/PlayerPrefs/HasKey.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/PlayerPrefs/HasKey.cs.meta new file mode 100644 index 0000000..9ce9a93 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/PlayerPrefs/HasKey.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 3b16fab74ec9f364f911696814716ca2 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/PlayerPrefs/Save.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/PlayerPrefs/Save.cs new file mode 100644 index 0000000..e5e2c53 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/PlayerPrefs/Save.cs @@ -0,0 +1,16 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityPlayerPrefs +{ + [TaskCategory("Unity/PlayerPrefs")] + [TaskDescription("Saves the PlayerPrefs.")] + public class Save : Action + { + public override TaskStatus OnUpdate() + { + PlayerPrefs.Save(); + + return TaskStatus.Success; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/PlayerPrefs/Save.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/PlayerPrefs/Save.cs.meta new file mode 100644 index 0000000..a6dc1b1 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/PlayerPrefs/Save.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 898765f1bc90e154e9cab895a814221e +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/PlayerPrefs/SetFloat.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/PlayerPrefs/SetFloat.cs new file mode 100644 index 0000000..3998083 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/PlayerPrefs/SetFloat.cs @@ -0,0 +1,27 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityPlayerPrefs +{ + [TaskCategory("Unity/PlayerPrefs")] + [TaskDescription("Sets the value with the specified key from the PlayerPrefs.")] + public class SetFloat : Action + { + [Tooltip("The key to store")] + public SharedString key; + [Tooltip("The value to set")] + public SharedFloat value; + + public override TaskStatus OnUpdate() + { + PlayerPrefs.SetFloat(key.Value, value.Value); + + return TaskStatus.Success; + } + + public override void OnReset() + { + key = ""; + value = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/PlayerPrefs/SetFloat.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/PlayerPrefs/SetFloat.cs.meta new file mode 100644 index 0000000..78d58c0 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/PlayerPrefs/SetFloat.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 88feec854545b9b428ed714fbebe872f +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/PlayerPrefs/SetInt.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/PlayerPrefs/SetInt.cs new file mode 100644 index 0000000..d67afee --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/PlayerPrefs/SetInt.cs @@ -0,0 +1,27 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityPlayerPrefs +{ + [TaskCategory("Unity/PlayerPrefs")] + [TaskDescription("Sets the value with the specified key from the PlayerPrefs.")] + public class SetInt : Action + { + [Tooltip("The key to store")] + public SharedString key; + [Tooltip("The value to set")] + public SharedInt value; + + public override TaskStatus OnUpdate() + { + PlayerPrefs.SetInt(key.Value, value.Value); + + return TaskStatus.Success; + } + + public override void OnReset() + { + key = ""; + value = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/PlayerPrefs/SetInt.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/PlayerPrefs/SetInt.cs.meta new file mode 100644 index 0000000..ddb66dd --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/PlayerPrefs/SetInt.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: ad23859aa9f9e68468891ba9600b9828 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/PlayerPrefs/SetString.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/PlayerPrefs/SetString.cs new file mode 100644 index 0000000..6a9c0e6 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/PlayerPrefs/SetString.cs @@ -0,0 +1,27 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityPlayerPrefs +{ + [TaskCategory("Unity/PlayerPrefs")] + [TaskDescription("Sets the value with the specified key from the PlayerPrefs.")] + public class SetString : Action + { + [Tooltip("The key to store")] + public SharedString key; + [Tooltip("The value to set")] + public SharedString value; + + public override TaskStatus OnUpdate() + { + PlayerPrefs.SetString(key.Value, value.Value); + + return TaskStatus.Success; + } + + public override void OnReset() + { + key = ""; + value = ""; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/PlayerPrefs/SetString.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/PlayerPrefs/SetString.cs.meta new file mode 100644 index 0000000..58ad430 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/PlayerPrefs/SetString.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 923ae6162a2661e47be9af80a19e48b6 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Quaternion.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Quaternion.meta new file mode 100644 index 0000000..de31e0f --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Quaternion.meta @@ -0,0 +1,4 @@ +fileFormatVersion: 2 +guid: fdfca1ec6223a5644919a38e092a933c +DefaultImporter: + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Quaternion/Angle.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Quaternion/Angle.cs new file mode 100644 index 0000000..5bd74f4 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Quaternion/Angle.cs @@ -0,0 +1,29 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityQuaternion +{ + [TaskCategory("Unity/Quaternion")] + [TaskDescription("Stores the angle in degrees between two rotations.")] + public class Angle : Action + { + [Tooltip("The first rotation")] + public SharedQuaternion firstRotation; + [Tooltip("The second rotation")] + public SharedQuaternion secondRotation; + [Tooltip("The stored result")] + [RequiredField] + public SharedFloat storeResult; + + public override TaskStatus OnUpdate() + { + storeResult.Value = Quaternion.Angle(firstRotation.Value, secondRotation.Value); + return TaskStatus.Success; + } + + public override void OnReset() + { + firstRotation = secondRotation = Quaternion.identity; + storeResult = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Quaternion/Angle.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Quaternion/Angle.cs.meta new file mode 100644 index 0000000..0e74384 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Quaternion/Angle.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 0d316a25dcddd6f4a981df05a1eeaf7c +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Quaternion/AngleAxis.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Quaternion/AngleAxis.cs new file mode 100644 index 0000000..62b55b0 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Quaternion/AngleAxis.cs @@ -0,0 +1,30 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityQuaternion +{ + [TaskCategory("Unity/Quaternion")] + [TaskDescription("Stores the rotation which rotates the specified degrees around the specified axis.")] + public class AngleAxis : Action + { + [Tooltip("The number of degrees")] + public SharedFloat degrees; + [Tooltip("The axis direction")] + public SharedVector3 axis; + [Tooltip("The stored result")] + [RequiredField] + public SharedQuaternion storeResult; + + public override TaskStatus OnUpdate() + { + storeResult.Value = Quaternion.AngleAxis(degrees.Value, axis.Value); + return TaskStatus.Success; + } + + public override void OnReset() + { + degrees = 0; + axis = Vector3.zero; + storeResult = Quaternion.identity; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Quaternion/AngleAxis.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Quaternion/AngleAxis.cs.meta new file mode 100644 index 0000000..8f24b10 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Quaternion/AngleAxis.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 82152b844829f8f43ab44f35bf7d786f +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Quaternion/Dot.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Quaternion/Dot.cs new file mode 100644 index 0000000..d022ef9 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Quaternion/Dot.cs @@ -0,0 +1,29 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityQuaternion +{ + [TaskCategory("Unity/Quaternion")] + [TaskDescription("Stores the dot product between two rotations.")] + public class Dot : Action + { + [Tooltip("The first rotation")] + public SharedQuaternion leftRotation; + [Tooltip("The second rotation")] + public SharedQuaternion rightRotation; + [Tooltip("The stored result")] + [RequiredField] + public SharedFloat storeResult; + + public override TaskStatus OnUpdate() + { + storeResult.Value = Quaternion.Dot(leftRotation.Value, rightRotation.Value); + return TaskStatus.Success; + } + + public override void OnReset() + { + leftRotation = rightRotation = Quaternion.identity; + storeResult = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Quaternion/Dot.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Quaternion/Dot.cs.meta new file mode 100644 index 0000000..eef8d8f --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Quaternion/Dot.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: fa9235523569d574aa7d22ce89423eca +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Quaternion/Euler.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Quaternion/Euler.cs new file mode 100644 index 0000000..2462a11 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Quaternion/Euler.cs @@ -0,0 +1,27 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityQuaternion +{ + [TaskCategory("Unity/Quaternion")] + [TaskDescription("Stores the quaternion of a euler vector.")] + public class Euler : Action + { + [Tooltip("The euler vector")] + public SharedVector3 eulerVector; + [Tooltip("The stored quaternion")] + [RequiredField] + public SharedQuaternion storeResult; + + public override TaskStatus OnUpdate() + { + storeResult.Value = Quaternion.Euler(eulerVector.Value); + return TaskStatus.Success; + } + + public override void OnReset() + { + eulerVector = Vector3.zero; + storeResult = Quaternion.identity; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Quaternion/Euler.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Quaternion/Euler.cs.meta new file mode 100644 index 0000000..eb7b8d3 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Quaternion/Euler.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: b4d275b4450a324409ace385a718d9ee +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Quaternion/FromToRotation.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Quaternion/FromToRotation.cs new file mode 100644 index 0000000..b1aeb95 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Quaternion/FromToRotation.cs @@ -0,0 +1,29 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityQuaternion +{ + [TaskCategory("Unity/Quaternion")] + [TaskDescription("Stores a rotation which rotates from the first direction to the second.")] + public class FromToRotation : Action + { + [Tooltip("The from rotation")] + public SharedVector3 fromDirection; + [Tooltip("The to rotation")] + public SharedVector3 toDirection; + [Tooltip("The stored result")] + [RequiredField] + public SharedQuaternion storeResult; + + public override TaskStatus OnUpdate() + { + storeResult.Value = Quaternion.FromToRotation(fromDirection.Value, toDirection.Value); + return TaskStatus.Success; + } + + public override void OnReset() + { + fromDirection = toDirection = Vector3.zero; + storeResult = Quaternion.identity; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Quaternion/FromToRotation.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Quaternion/FromToRotation.cs.meta new file mode 100644 index 0000000..a4c7b77 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Quaternion/FromToRotation.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 56740b2c218d500408dd75c6c15006ec +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Quaternion/Identity.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Quaternion/Identity.cs new file mode 100644 index 0000000..4709984 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Quaternion/Identity.cs @@ -0,0 +1,24 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityQuaternion +{ + [TaskCategory("Unity/Quaternion")] + [TaskDescription("Stores the quaternion identity.")] + public class Identity : Action + { + [Tooltip("The identity")] + [RequiredField] + public SharedQuaternion storeResult; + + public override TaskStatus OnUpdate() + { + storeResult.Value = Quaternion.identity; + return TaskStatus.Success; + } + + public override void OnReset() + { + storeResult = Quaternion.identity; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Quaternion/Identity.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Quaternion/Identity.cs.meta new file mode 100644 index 0000000..24cd336 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Quaternion/Identity.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: f4eefb6e25898904688a422ca79d763c +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Quaternion/Inverse.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Quaternion/Inverse.cs new file mode 100644 index 0000000..d4d42ab --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Quaternion/Inverse.cs @@ -0,0 +1,26 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityQuaternion +{ + [TaskCategory("Unity/Quaternion")] + [TaskDescription("Stores the inverse of the specified quaternion.")] + public class Inverse : Action + { + [Tooltip("The target quaternion")] + public SharedQuaternion targetQuaternion; + [Tooltip("The stored quaternion")] + [RequiredField] + public SharedQuaternion storeResult; + + public override TaskStatus OnUpdate() + { + storeResult.Value = Quaternion.Inverse(targetQuaternion.Value); + return TaskStatus.Success; + } + + public override void OnReset() + { + targetQuaternion = storeResult = Quaternion.identity; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Quaternion/Inverse.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Quaternion/Inverse.cs.meta new file mode 100644 index 0000000..1275f98 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Quaternion/Inverse.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: ab8f5048bc0e5ce409bf3408c60bc3eb +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Quaternion/Lerp.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Quaternion/Lerp.cs new file mode 100644 index 0000000..826448b --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Quaternion/Lerp.cs @@ -0,0 +1,31 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityQuaternion +{ + [TaskCategory("Unity/Quaternion")] + [TaskDescription("Lerps between two quaternions.")] + public class Lerp : Action + { + [Tooltip("The from rotation")] + public SharedQuaternion fromQuaternion; + [Tooltip("The to rotation")] + public SharedQuaternion toQuaternion; + [Tooltip("The amount to lerp")] + public SharedFloat amount; + [Tooltip("The stored result")] + [RequiredField] + public SharedQuaternion storeResult; + + public override TaskStatus OnUpdate() + { + storeResult.Value = Quaternion.Lerp(fromQuaternion.Value, toQuaternion.Value, amount.Value); + return TaskStatus.Success; + } + + public override void OnReset() + { + fromQuaternion = toQuaternion = storeResult = Quaternion.identity; + amount = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Quaternion/Lerp.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Quaternion/Lerp.cs.meta new file mode 100644 index 0000000..eef16d9 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Quaternion/Lerp.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: fb19d83a245337542a5c0f02593e8dab +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Quaternion/LookRotation.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Quaternion/LookRotation.cs new file mode 100644 index 0000000..e6b8e85 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Quaternion/LookRotation.cs @@ -0,0 +1,29 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityQuaternion +{ + [TaskCategory("Unity/Quaternion")] + [TaskDescription("Stores the quaternion of a forward vector.")] + public class LookRotation : Action + { + [Tooltip("The forward vector")] + public SharedVector3 forwardVector; + [Tooltip("The second Vector3")] + public SharedVector3 secondVector3; + [Tooltip("The stored quaternion")] + [RequiredField] + public SharedQuaternion storeResult; + + public override TaskStatus OnUpdate() + { + storeResult.Value = Quaternion.LookRotation(forwardVector.Value); + return TaskStatus.Success; + } + + public override void OnReset() + { + forwardVector = Vector3.zero; + storeResult = Quaternion.identity; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Quaternion/LookRotation.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Quaternion/LookRotation.cs.meta new file mode 100644 index 0000000..fcfab1a --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Quaternion/LookRotation.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: e006fb91f87854448b9bd6cb1d20b2f1 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Quaternion/RotateTowards.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Quaternion/RotateTowards.cs new file mode 100644 index 0000000..bbdfecf --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Quaternion/RotateTowards.cs @@ -0,0 +1,31 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityQuaternion +{ + [TaskCategory("Unity/Quaternion")] + [TaskDescription("Stores the quaternion after a rotation.")] + public class RotateTowards : Action + { + [Tooltip("The from rotation")] + public SharedQuaternion fromQuaternion; + [Tooltip("The to rotation")] + public SharedQuaternion toQuaternion; + [Tooltip("The maximum degrees delta")] + public SharedFloat maxDeltaDegrees; + [Tooltip("The stored result")] + [RequiredField] + public SharedQuaternion storeResult; + + public override TaskStatus OnUpdate() + { + storeResult.Value = Quaternion.RotateTowards(fromQuaternion.Value, toQuaternion.Value, maxDeltaDegrees.Value); + return TaskStatus.Success; + } + + public override void OnReset() + { + fromQuaternion = toQuaternion = storeResult = Quaternion.identity; + maxDeltaDegrees = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Quaternion/RotateTowards.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Quaternion/RotateTowards.cs.meta new file mode 100644 index 0000000..c203760 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Quaternion/RotateTowards.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: b5e043a106ab4784aab997fa0e27f972 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Quaternion/Slerp.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Quaternion/Slerp.cs new file mode 100644 index 0000000..0a4fb20 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Quaternion/Slerp.cs @@ -0,0 +1,31 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityQuaternion +{ + [TaskCategory("Unity/Quaternion")] + [TaskDescription("Spherically lerp between two quaternions.")] + public class Slerp : Action + { + [Tooltip("The from rotation")] + public SharedQuaternion fromQuaternion; + [Tooltip("The to rotation")] + public SharedQuaternion toQuaternion; + [Tooltip("The amount to lerp")] + public SharedFloat amount; + [Tooltip("The stored result")] + [RequiredField] + public SharedQuaternion storeResult; + + public override TaskStatus OnUpdate() + { + storeResult.Value = Quaternion.Slerp(fromQuaternion.Value, toQuaternion.Value, amount.Value); + return TaskStatus.Success; + } + + public override void OnReset() + { + fromQuaternion = toQuaternion = storeResult = Quaternion.identity; + amount = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Quaternion/Slerp.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Quaternion/Slerp.cs.meta new file mode 100644 index 0000000..7e3a5e4 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Quaternion/Slerp.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: b36eacb0f1a46624193a622ef50979ff +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Renderer.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Renderer.meta new file mode 100644 index 0000000..6eedf10 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Renderer.meta @@ -0,0 +1,4 @@ +fileFormatVersion: 2 +guid: b7bee06bd6fde844784243b656f96db8 +DefaultImporter: + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Renderer/IsVisible.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Renderer/IsVisible.cs new file mode 100644 index 0000000..157b4f7 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Renderer/IsVisible.cs @@ -0,0 +1,40 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityRenderer +{ + [TaskCategory("Unity/Renderer")] + [TaskDescription("Returns Success if the Renderer is visible, otherwise Failure.")] + public class IsVisible : Conditional + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + + // cache the renderer component + private Renderer renderer; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + renderer = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (renderer == null) { + Debug.LogWarning("Renderer is null"); + return TaskStatus.Failure; + } + + return renderer.isVisible ? TaskStatus.Success : TaskStatus.Failure; + } + + public override void OnReset() + { + targetGameObject = null; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Renderer/IsVisible.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Renderer/IsVisible.cs.meta new file mode 100644 index 0000000..5f1bd6a --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Renderer/IsVisible.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 3b6ba7f7e8884c14c9ef4a74b50b0a8e +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Renderer/SetMaterial.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Renderer/SetMaterial.cs new file mode 100644 index 0000000..a8da2ab --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Renderer/SetMaterial.cs @@ -0,0 +1,44 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityRenderer +{ + [TaskCategory("Unity/Renderer")] + [TaskDescription("Sets the material on the Renderer.")] + public class SetMaterial : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The material to set")] + public SharedMaterial material; + + // cache the renderer component + private Renderer renderer; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + renderer = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (renderer == null) { + Debug.LogWarning("Renderer is null"); + return TaskStatus.Failure; + } + + renderer.material = material.Value; + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + material = null; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Renderer/SetMaterial.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Renderer/SetMaterial.cs.meta new file mode 100644 index 0000000..bea6ec5 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Renderer/SetMaterial.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: bf71e4b9292cad342877356107f76d39 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody.meta new file mode 100644 index 0000000..cfa304f --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody.meta @@ -0,0 +1,4 @@ +fileFormatVersion: 2 +guid: f560fb42f946dcb4a819c0cca91d9c9d +DefaultImporter: + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/AddExplosionForce.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/AddExplosionForce.cs new file mode 100644 index 0000000..3ee4327 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/AddExplosionForce.cs @@ -0,0 +1,57 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityRigidbody +{ + [TaskCategory("Unity/Rigidbody")] + [TaskDescription("Applies a force to the rigidbody that simulates explosion effects. Returns Success.")] + public class AddExplosionForce : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The force of the explosion")] + public SharedFloat explosionForce; + [Tooltip("The position of the explosion")] + public SharedVector3 explosionPosition; + [Tooltip("The radius of the explosion")] + public SharedFloat explosionRadius; + [Tooltip("Applies the force as if it was applied from beneath the object")] + public float upwardsModifier = 0; + [Tooltip("The type of force")] + public ForceMode forceMode = ForceMode.Force; + + // cache the rigidbody component + private Rigidbody rigidbody; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + rigidbody = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (rigidbody == null) { + Debug.LogWarning("Rigidbody is null"); + return TaskStatus.Failure; + } + + rigidbody.AddExplosionForce(explosionForce.Value, explosionPosition.Value, explosionRadius.Value, upwardsModifier, forceMode); + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + explosionForce = 0; + explosionPosition = Vector3.zero; + explosionRadius = 0; + upwardsModifier = 0; + forceMode = ForceMode.Force; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/AddExplosionForce.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/AddExplosionForce.cs.meta new file mode 100644 index 0000000..432abb4 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/AddExplosionForce.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: ccb592e850d4c734995a2a1c3f930b62 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/AddForce.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/AddForce.cs new file mode 100644 index 0000000..32ef6e8 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/AddForce.cs @@ -0,0 +1,51 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityRigidbody +{ + [RequiredComponent(typeof(Rigidbody))] + [TaskCategory("Unity/Rigidbody")] + [TaskDescription("Applies a force to the rigidbody. Returns Success.")] + public class AddForce : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The amount of force to apply")] + public SharedVector3 force; + [Tooltip("The type of force")] + public ForceMode forceMode = ForceMode.Force; + + // cache the rigidbody component + private Rigidbody rigidbody; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + rigidbody = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (rigidbody == null) { + Debug.LogWarning("Rigidbody is null"); + return TaskStatus.Failure; + } + + rigidbody.AddForce(force.Value, forceMode); + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + if (force != null) { + force.Value = Vector3.zero; + } + forceMode = ForceMode.Force; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/AddForce.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/AddForce.cs.meta new file mode 100644 index 0000000..04ce1ea --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/AddForce.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 5748d4214b99b8c49ba67902a8495a30 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/AddForceAtPosition.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/AddForceAtPosition.cs new file mode 100644 index 0000000..cefd112 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/AddForceAtPosition.cs @@ -0,0 +1,51 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityRigidbody +{ + [TaskCategory("Unity/Rigidbody")] + [TaskDescription("Applies a force at the specified position to the rigidbody. Returns Success.")] + public class AddForceAtPosition : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The amount of force to apply")] + public SharedVector3 force; + [Tooltip("The position of the force")] + public SharedVector3 position; + [Tooltip("The type of force")] + public ForceMode forceMode = ForceMode.Force; + + // cache the rigidbody component + private Rigidbody rigidbody; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + rigidbody = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (rigidbody == null) { + Debug.LogWarning("Rigidbody is null"); + return TaskStatus.Failure; + } + + rigidbody.AddForceAtPosition(force.Value, position.Value, forceMode); + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + force = Vector3.zero; + position = Vector3.zero; + forceMode = ForceMode.Force; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/AddForceAtPosition.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/AddForceAtPosition.cs.meta new file mode 100644 index 0000000..7431cc1 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/AddForceAtPosition.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: c3938bcd4e88b45419aa86adee51a2c2 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/AddRelativeForce.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/AddRelativeForce.cs new file mode 100644 index 0000000..46a04a6 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/AddRelativeForce.cs @@ -0,0 +1,48 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityRigidbody +{ + [TaskCategory("Unity/Rigidbody")] + [TaskDescription("Applies a force to the rigidbody relative to its coordinate system. Returns Success.")] + public class AddRelativeForce : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The amount of force to apply")] + public SharedVector3 force; + [Tooltip("The type of force")] + public ForceMode forceMode = ForceMode.Force; + + // cache the rigidbody component + private Rigidbody rigidbody; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + rigidbody = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (rigidbody == null) { + Debug.LogWarning("Rigidbody is null"); + return TaskStatus.Failure; + } + + rigidbody.AddRelativeForce(force.Value, forceMode); + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + force = Vector3.zero; + forceMode = ForceMode.Force; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/AddRelativeForce.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/AddRelativeForce.cs.meta new file mode 100644 index 0000000..d9789f7 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/AddRelativeForce.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 1de05a2b6197b2d4b9da1c36bf382649 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/AddRelativeTorque.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/AddRelativeTorque.cs new file mode 100644 index 0000000..58f4cb3 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/AddRelativeTorque.cs @@ -0,0 +1,43 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityRigidbody +{ + [TaskCategory("Unity/Rigidbody")] + [TaskDescription("Applies a torque to the rigidbody relative to its coordinate system. Returns Success.")] + public class AddRelativeTorque : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The amount of torque to apply")] + public SharedVector3 torque; + [Tooltip("The type of torque")] + public ForceMode forceMode = ForceMode.Force; + + // cache the rigidbody component + private Rigidbody rigidbody; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + rigidbody = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + rigidbody.AddRelativeTorque(torque.Value, forceMode); + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + torque = Vector3.zero; + forceMode = ForceMode.Force; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/AddRelativeTorque.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/AddRelativeTorque.cs.meta new file mode 100644 index 0000000..a975660 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/AddRelativeTorque.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 71136c1193309b24c93d450b5f2e47be +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/AddTorque.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/AddTorque.cs new file mode 100644 index 0000000..f0ee46b --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/AddTorque.cs @@ -0,0 +1,48 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityRigidbody +{ + [TaskCategory("Unity/Rigidbody")] + [TaskDescription("Applies a torque to the rigidbody. Returns Success.")] + public class AddTorque : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The amount of torque to apply")] + public SharedVector3 torque; + [Tooltip("The type of torque")] + public ForceMode forceMode = ForceMode.Force; + + // cache the rigidbody component + private Rigidbody rigidbody; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + rigidbody = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (rigidbody == null) { + Debug.LogWarning("Rigidbody is null"); + return TaskStatus.Failure; + } + + rigidbody.AddTorque(torque.Value, forceMode); + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + torque = Vector3.zero; + forceMode = ForceMode.Force; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/AddTorque.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/AddTorque.cs.meta new file mode 100644 index 0000000..3a3abfd --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/AddTorque.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 88c726c1cb324e6429637f55d36c3d01 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/GetAngularDrag.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/GetAngularDrag.cs new file mode 100644 index 0000000..32ed160 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/GetAngularDrag.cs @@ -0,0 +1,46 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityRigidbody +{ + [TaskCategory("Unity/Rigidbody")] + [TaskDescription("Stores the angular drag of the Rigidbody. Returns Success.")] + public class GetAngularDrag : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The angular drag of the Rigidbody")] + [RequiredField] + public SharedFloat storeValue; + + // cache the rigidbody component + private Rigidbody rigidbody; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + rigidbody = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (rigidbody == null) { + Debug.LogWarning("Rigidbody is null"); + return TaskStatus.Failure; + } + + storeValue.Value = rigidbody.angularDrag; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + storeValue = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/GetAngularDrag.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/GetAngularDrag.cs.meta new file mode 100644 index 0000000..2e4fb6f --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/GetAngularDrag.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 5fb34b334a02db64db2d6a2fb2448be5 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/GetAngularVelocity.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/GetAngularVelocity.cs new file mode 100644 index 0000000..efe2505 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/GetAngularVelocity.cs @@ -0,0 +1,46 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityRigidbody +{ + [TaskCategory("Unity/Rigidbody")] + [TaskDescription("Stores the angular velocity of the Rigidbody. Returns Success.")] + public class GetAngularVelocity : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The angular velocity of the Rigidbody")] + [RequiredField] + public SharedVector3 storeValue; + + // cache the rigidbody component + private Rigidbody rigidbody; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + rigidbody = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (rigidbody == null) { + Debug.LogWarning("Rigidbody is null"); + return TaskStatus.Failure; + } + + storeValue.Value = rigidbody.angularVelocity; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + storeValue = Vector3.zero; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/GetAngularVelocity.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/GetAngularVelocity.cs.meta new file mode 100644 index 0000000..c55ad13 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/GetAngularVelocity.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 492dc3a13d07ed149bcd19d36e2f7ee7 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/GetCenterOfMass.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/GetCenterOfMass.cs new file mode 100644 index 0000000..3fa69fd --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/GetCenterOfMass.cs @@ -0,0 +1,46 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityRigidbody +{ + [TaskCategory("Unity/Rigidbody")] + [TaskDescription("Stores the center of mass of the Rigidbody. Returns Success.")] + public class GetCenterOfMass : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The center of mass of the Rigidbody")] + [RequiredField] + public SharedVector3 storeValue; + + // cache the rigidbody component + private Rigidbody rigidbody; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + rigidbody = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (rigidbody == null) { + Debug.LogWarning("Rigidbody is null"); + return TaskStatus.Failure; + } + + storeValue.Value = rigidbody.centerOfMass; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + storeValue = Vector3.zero; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/GetCenterOfMass.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/GetCenterOfMass.cs.meta new file mode 100644 index 0000000..7de5f1f --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/GetCenterOfMass.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: b993020e1d60f5242a7e3618501f871e +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/GetDrag.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/GetDrag.cs new file mode 100644 index 0000000..e5be30b --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/GetDrag.cs @@ -0,0 +1,46 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityRigidbody +{ + [TaskCategory("Unity/Rigidbody")] + [TaskDescription("Stores the drag of the Rigidbody. Returns Success.")] + public class GetDrag : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The drag of the Rigidbody")] + [RequiredField] + public SharedFloat storeValue; + + // cache the rigidbody component + private Rigidbody rigidbody; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + rigidbody = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (rigidbody == null) { + Debug.LogWarning("Rigidbody is null"); + return TaskStatus.Failure; + } + + storeValue.Value = rigidbody.drag; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + storeValue = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/GetDrag.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/GetDrag.cs.meta new file mode 100644 index 0000000..7eec4f8 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/GetDrag.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 69bd087f6899c604f82441b108ead2a8 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/GetFreezeRotation.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/GetFreezeRotation.cs new file mode 100644 index 0000000..8deef57 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/GetFreezeRotation.cs @@ -0,0 +1,46 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityRigidbody +{ + [TaskCategory("Unity/Rigidbody")] + [TaskDescription("Stores the freeze rotation value of the Rigidbody. Returns Success.")] + public class GetFreezeRotation : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The freeze rotation value of the Rigidbody")] + [RequiredField] + public SharedBool storeValue; + + // cache the rigidbody component + private Rigidbody rigidbody; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + rigidbody = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (rigidbody == null) { + Debug.LogWarning("Rigidbody is null"); + return TaskStatus.Failure; + } + + storeValue.Value = rigidbody.freezeRotation; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + storeValue = false; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/GetFreezeRotation.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/GetFreezeRotation.cs.meta new file mode 100644 index 0000000..3ce8c03 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/GetFreezeRotation.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 889065cfad95df04a802761fcccb8359 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/GetIsKinematic.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/GetIsKinematic.cs new file mode 100644 index 0000000..36454f2 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/GetIsKinematic.cs @@ -0,0 +1,46 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityRigidbody +{ + [TaskCategory("Unity/Rigidbody")] + [TaskDescription("Stores the is kinematic value of the Rigidbody. Returns Success.")] + public class GetIsKinematic : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The is kinematic value of the Rigidbody")] + [RequiredField] + public SharedBool storeValue; + + // cache the rigidbody component + private Rigidbody rigidbody; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + rigidbody = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (rigidbody == null) { + Debug.LogWarning("Rigidbody is null"); + return TaskStatus.Failure; + } + + storeValue.Value = rigidbody.isKinematic; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + storeValue = false; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/GetIsKinematic.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/GetIsKinematic.cs.meta new file mode 100644 index 0000000..26a44fe --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/GetIsKinematic.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: a531151d14b8a9640be8d499d9db4538 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/GetMass.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/GetMass.cs new file mode 100644 index 0000000..f13f0fb --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/GetMass.cs @@ -0,0 +1,46 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityRigidbody +{ + [TaskCategory("Unity/Rigidbody")] + [TaskDescription("Stores the mass of the Rigidbody. Returns Success.")] + public class GetMass : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The mass of the Rigidbody")] + [RequiredField] + public SharedFloat storeValue; + + // cache the rigidbody component + private Rigidbody rigidbody; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + rigidbody = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (rigidbody == null) { + Debug.LogWarning("Rigidbody is null"); + return TaskStatus.Failure; + } + + storeValue.Value = rigidbody.mass; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + storeValue = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/GetMass.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/GetMass.cs.meta new file mode 100644 index 0000000..afb509e --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/GetMass.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 2638ca749ba5a404f84fd72811b16c81 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/GetPosition.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/GetPosition.cs new file mode 100644 index 0000000..908746a --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/GetPosition.cs @@ -0,0 +1,46 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityRigidbody +{ + [TaskCategory("Unity/Rigidbody")] + [TaskDescription("Stores the position of the Rigidbody. Returns Success.")] + public class GetPosition : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The position of the Rigidbody")] + [RequiredField] + public SharedVector3 storeValue; + + // cache the rigidbody component + private Rigidbody rigidbody; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + rigidbody = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (rigidbody == null) { + Debug.LogWarning("Rigidbody is null"); + return TaskStatus.Failure; + } + + storeValue.Value = rigidbody.position; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + storeValue = Vector3.zero; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/GetPosition.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/GetPosition.cs.meta new file mode 100644 index 0000000..15eee63 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/GetPosition.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 25f9090c180831b4daaa1a24894681ac +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/GetRotation.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/GetRotation.cs new file mode 100644 index 0000000..6dcac3e --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/GetRotation.cs @@ -0,0 +1,46 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityRigidbody +{ + [TaskCategory("Unity/Rigidbody")] + [TaskDescription("Stores the rotation of the Rigidbody. Returns Success.")] + public class GetRotation : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The rotation of the Rigidbody")] + [RequiredField] + public SharedQuaternion storeValue; + + // cache the rigidbody component + private Rigidbody rigidbody; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + rigidbody = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (rigidbody == null) { + Debug.LogWarning("Rigidbody is null"); + return TaskStatus.Failure; + } + + storeValue.Value = rigidbody.rotation; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + storeValue = Quaternion.identity; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/GetRotation.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/GetRotation.cs.meta new file mode 100644 index 0000000..c2b3328 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/GetRotation.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 937400bc82220b543aa9b3074f17f4d6 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/GetUseGravity.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/GetUseGravity.cs new file mode 100644 index 0000000..b7cdfda --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/GetUseGravity.cs @@ -0,0 +1,46 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityRigidbody +{ + [TaskCategory("Unity/Rigidbody")] + [TaskDescription("Stores the use gravity value of the Rigidbody. Returns Success.")] + public class GetUseGravity : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The use gravity value of the Rigidbody")] + [RequiredField] + public SharedBool storeValue; + + // cache the rigidbody component + private Rigidbody rigidbody; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + rigidbody = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (rigidbody == null) { + Debug.LogWarning("Rigidbody is null"); + return TaskStatus.Failure; + } + + storeValue.Value = rigidbody.useGravity; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + storeValue = false; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/GetUseGravity.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/GetUseGravity.cs.meta new file mode 100644 index 0000000..ea95a3c --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/GetUseGravity.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 1d7358afc7810ca4aa2ae8a2cd4b9e6e +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/GetVelocity.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/GetVelocity.cs new file mode 100644 index 0000000..fe79554 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/GetVelocity.cs @@ -0,0 +1,46 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityRigidbody +{ + [TaskCategory("Unity/Rigidbody")] + [TaskDescription("Stores the velocity of the Rigidbody. Returns Success.")] + public class GetVelocity : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The velocity of the Rigidbody")] + [RequiredField] + public SharedVector3 storeValue; + + // cache the rigidbody component + private Rigidbody rigidbody; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + rigidbody = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (rigidbody == null) { + Debug.LogWarning("Rigidbody is null"); + return TaskStatus.Failure; + } + + storeValue.Value = rigidbody.velocity; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + storeValue = Vector3.zero; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/GetVelocity.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/GetVelocity.cs.meta new file mode 100644 index 0000000..3bb5ce9 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/GetVelocity.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 9c18365eb6865164ebb5b0057dcc6bb4 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/IsKinematic.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/IsKinematic.cs new file mode 100644 index 0000000..9273777 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/IsKinematic.cs @@ -0,0 +1,40 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityRigidbody +{ + [TaskCategory("Unity/Rigidbody")] + [TaskDescription("Returns Success if the Rigidbody is kinematic, otherwise Failure.")] + public class IsKinematic : Conditional + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + + // cache the rigidbody component + private Rigidbody rigidbody; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + rigidbody = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (rigidbody == null) { + Debug.LogWarning("Rigidbody is null"); + return TaskStatus.Failure; + } + + return rigidbody.isKinematic ? TaskStatus.Success : TaskStatus.Failure; + } + + public override void OnReset() + { + targetGameObject = null; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/IsKinematic.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/IsKinematic.cs.meta new file mode 100644 index 0000000..05fb2ae --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/IsKinematic.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 30be28b36412643418c2e61640147eac +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/IsSleeping.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/IsSleeping.cs new file mode 100644 index 0000000..286fe39 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/IsSleeping.cs @@ -0,0 +1,40 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityRigidbody +{ + [TaskCategory("Unity/Rigidbody")] + [TaskDescription("Returns Success if the Rigidbody is sleeping, otherwise Failure.")] + public class IsSleeping : Conditional + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + + // cache the rigidbody component + private Rigidbody rigidbody; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + rigidbody = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (rigidbody == null) { + Debug.LogWarning("Rigidbody is null"); + return TaskStatus.Failure; + } + + return rigidbody.IsSleeping() ? TaskStatus.Success : TaskStatus.Failure; + } + + public override void OnReset() + { + targetGameObject = null; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/IsSleeping.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/IsSleeping.cs.meta new file mode 100644 index 0000000..ed17bf0 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/IsSleeping.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 37e8153613f519240a11c3f6583d1030 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/MovePosition.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/MovePosition.cs new file mode 100644 index 0000000..f7506b4 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/MovePosition.cs @@ -0,0 +1,45 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityRigidbody +{ + [TaskCategory("Unity/Rigidbody")] + [TaskDescription("Moves the Rigidbody to the specified position. Returns Success.")] + public class MovePosition : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The new position of the Rigidbody")] + public SharedVector3 position; + + // cache the rigidbody component + private Rigidbody rigidbody; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + rigidbody = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (rigidbody == null) { + Debug.LogWarning("Rigidbody is null"); + return TaskStatus.Failure; + } + + rigidbody.MovePosition(position.Value); + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + position = Vector3.zero; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/MovePosition.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/MovePosition.cs.meta new file mode 100644 index 0000000..da678aa --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/MovePosition.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 87176662744aee049b8af51b01bcb526 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/MoveRotation.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/MoveRotation.cs new file mode 100644 index 0000000..ea87fdb --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/MoveRotation.cs @@ -0,0 +1,45 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityRigidbody +{ + [TaskCategory("Unity/Rigidbody")] + [TaskDescription("Rotates the Rigidbody to the specified rotation. Returns Success.")] + public class MoveRotation : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The new rotation of the Rigidbody")] + public SharedQuaternion rotation; + + // cache the rigidbody component + private Rigidbody rigidbody; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + rigidbody = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (rigidbody == null) { + Debug.LogWarning("Rigidbody is null"); + return TaskStatus.Failure; + } + + rigidbody.MoveRotation(rotation.Value); + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + rotation = Quaternion.identity; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/MoveRotation.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/MoveRotation.cs.meta new file mode 100644 index 0000000..56c916a --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/MoveRotation.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: f1ba2e66d5ca98a4ba4020b4eff4da6e +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/SetAngularDrag.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/SetAngularDrag.cs new file mode 100644 index 0000000..724da63 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/SetAngularDrag.cs @@ -0,0 +1,45 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityRigidbody +{ + [TaskCategory("Unity/Rigidbody")] + [TaskDescription("Sets the angular drag of the Rigidbody. Returns Success.")] + public class SetAngularDrag : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The angular drag of the Rigidbody")] + public SharedFloat angularDrag; + + // cache the rigidbody component + private Rigidbody rigidbody; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + rigidbody = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (rigidbody == null) { + Debug.LogWarning("Rigidbody is null"); + return TaskStatus.Failure; + } + + rigidbody.angularDrag = angularDrag.Value; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + angularDrag = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/SetAngularDrag.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/SetAngularDrag.cs.meta new file mode 100644 index 0000000..bf8edeb --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/SetAngularDrag.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 2883595af7ee1c649ae45353482beed8 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/SetAngularVelocity.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/SetAngularVelocity.cs new file mode 100644 index 0000000..a0f1ac6 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/SetAngularVelocity.cs @@ -0,0 +1,45 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityRigidbody +{ + [TaskCategory("Unity/Rigidbody")] + [TaskDescription("Sets the angular velocity of the Rigidbody. Returns Success.")] + public class SetAngularVelocity : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The angular velocity of the Rigidbody")] + public SharedVector3 angularVelocity; + + // cache the rigidbody component + private Rigidbody rigidbody; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + rigidbody = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (rigidbody == null) { + Debug.LogWarning("Rigidbody is null"); + return TaskStatus.Failure; + } + + rigidbody.angularVelocity = angularVelocity.Value; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + angularVelocity = Vector3.zero; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/SetAngularVelocity.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/SetAngularVelocity.cs.meta new file mode 100644 index 0000000..29d731e --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/SetAngularVelocity.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 8652396368a6dad4eb6e1259e680595c +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/SetCenterOfMass.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/SetCenterOfMass.cs new file mode 100644 index 0000000..61dd56c --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/SetCenterOfMass.cs @@ -0,0 +1,45 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityRigidbody +{ + [TaskCategory("Unity/Rigidbody")] + [TaskDescription("Sets the center of mass of the Rigidbody. Returns Success.")] + public class SetCenterOfMass : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The center of mass of the Rigidbody")] + public SharedVector3 centerOfMass; + + // cache the rigidbody component + private Rigidbody rigidbody; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + rigidbody = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (rigidbody == null) { + Debug.LogWarning("Rigidbody is null"); + return TaskStatus.Failure; + } + + rigidbody.centerOfMass = centerOfMass.Value; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + centerOfMass = Vector3.zero; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/SetCenterOfMass.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/SetCenterOfMass.cs.meta new file mode 100644 index 0000000..d747972 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/SetCenterOfMass.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 594f2d37fbfc0d545a0377cf63543f41 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/SetConstraints.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/SetConstraints.cs new file mode 100644 index 0000000..1b19dc9 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/SetConstraints.cs @@ -0,0 +1,45 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityRigidbody +{ + [TaskCategory("Unity/Rigidbody")] + [TaskDescription("Sets the constraints of the Rigidbody. Returns Success.")] + public class SetConstraints : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The constraints of the Rigidbody")] + public RigidbodyConstraints constraints = RigidbodyConstraints.None; + + // cache the rigidbody component + private Rigidbody rigidbody; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + rigidbody = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (rigidbody == null) { + Debug.LogWarning("Rigidbody is null"); + return TaskStatus.Failure; + } + + rigidbody.constraints = constraints; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + constraints = RigidbodyConstraints.None; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/SetConstraints.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/SetConstraints.cs.meta new file mode 100644 index 0000000..7cbdba8 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/SetConstraints.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: dd098240974b0184ca8c66cb6e450753 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/SetDrag.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/SetDrag.cs new file mode 100644 index 0000000..766c811 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/SetDrag.cs @@ -0,0 +1,45 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityRigidbody +{ + [TaskCategory("Unity/Rigidbody")] + [TaskDescription("Sets the drag of the Rigidbody. Returns Success.")] + public class SetDrag : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The drag of the Rigidbody")] + public SharedFloat drag; + + // cache the rigidbody component + private Rigidbody rigidbody; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + rigidbody = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (rigidbody == null) { + Debug.LogWarning("Rigidbody is null"); + return TaskStatus.Failure; + } + + rigidbody.drag = drag.Value; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + drag = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/SetDrag.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/SetDrag.cs.meta new file mode 100644 index 0000000..6c2b31c --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/SetDrag.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 8984a684f33e6644abbb9cfe6c9068d9 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/SetFreezeRotation.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/SetFreezeRotation.cs new file mode 100644 index 0000000..df97a2f --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/SetFreezeRotation.cs @@ -0,0 +1,45 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityRigidbody +{ + [TaskCategory("Unity/Rigidbody")] + [TaskDescription("Sets the freeze rotation value of the Rigidbody. Returns Success.")] + public class SetFreezeRotation : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The freeze rotation value of the Rigidbody")] + public SharedBool freezeRotation; + + // cache the rigidbody component + private Rigidbody rigidbody; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + rigidbody = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (rigidbody == null) { + Debug.LogWarning("Rigidbody is null"); + return TaskStatus.Failure; + } + + rigidbody.freezeRotation = freezeRotation.Value; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + freezeRotation = false; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/SetFreezeRotation.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/SetFreezeRotation.cs.meta new file mode 100644 index 0000000..2111c7b --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/SetFreezeRotation.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 4160755a1f5174546b6ccbabff469187 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/SetIsKinematic.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/SetIsKinematic.cs new file mode 100644 index 0000000..ec6f852 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/SetIsKinematic.cs @@ -0,0 +1,45 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityRigidbody +{ + [TaskCategory("Unity/Rigidbody")] + [TaskDescription("Sets the is kinematic value of the Rigidbody. Returns Success.")] + public class SetIsKinematic : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The is kinematic value of the Rigidbody")] + public SharedBool isKinematic; + + // cache the rigidbody component + private Rigidbody rigidbody; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + rigidbody = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (rigidbody == null) { + Debug.LogWarning("Rigidbody is null"); + return TaskStatus.Failure; + } + + rigidbody.isKinematic = isKinematic.Value; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + isKinematic = false; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/SetIsKinematic.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/SetIsKinematic.cs.meta new file mode 100644 index 0000000..c5d16ee --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/SetIsKinematic.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 6d93194d82815024cadf3f4f842666d0 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/SetMass.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/SetMass.cs new file mode 100644 index 0000000..8a823f0 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/SetMass.cs @@ -0,0 +1,45 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityRigidbody +{ + [TaskCategory("Unity/Rigidbody")] + [TaskDescription("Sets the mass of the Rigidbody. Returns Success.")] + public class SetMass : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The mass of the Rigidbody")] + public SharedFloat mass; + + // cache the rigidbody component + private Rigidbody rigidbody; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + rigidbody = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (rigidbody == null) { + Debug.LogWarning("Rigidbody is null"); + return TaskStatus.Failure; + } + + rigidbody.mass = mass.Value; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + mass = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/SetMass.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/SetMass.cs.meta new file mode 100644 index 0000000..7f3f0f9 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/SetMass.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 82f7a92bee3553d49bbb1ebabfaffc12 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/SetPosition.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/SetPosition.cs new file mode 100644 index 0000000..add8f63 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/SetPosition.cs @@ -0,0 +1,45 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityRigidbody +{ + [TaskCategory("Unity/Rigidbody")] + [TaskDescription("Sets the position of the Rigidbody. Returns Success.")] + public class SetPosition : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The position of the Rigidbody")] + public SharedVector3 position; + + // cache the rigidbody component + private Rigidbody rigidbody; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + rigidbody = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (rigidbody == null) { + Debug.LogWarning("Rigidbody is null"); + return TaskStatus.Failure; + } + + rigidbody.position = position.Value; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + position = Vector3.zero; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/SetPosition.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/SetPosition.cs.meta new file mode 100644 index 0000000..ee0e76a --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/SetPosition.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 8a33b86eb94a87c449e1f3344973cc50 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/SetRotation.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/SetRotation.cs new file mode 100644 index 0000000..24be3ec --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/SetRotation.cs @@ -0,0 +1,45 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityRigidbody +{ + [TaskCategory("Unity/Rigidbody")] + [TaskDescription("Stores the rotation of the Rigidbody. Returns Success.")] + public class SetRotation : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The rotation of the Rigidbody")] + public SharedQuaternion rotation; + + // cache the rigidbody component + private Rigidbody rigidbody; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + rigidbody = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (rigidbody == null) { + Debug.LogWarning("Rigidbody is null"); + return TaskStatus.Failure; + } + + rigidbody.rotation = rotation.Value; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + rotation = Quaternion.identity; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/SetRotation.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/SetRotation.cs.meta new file mode 100644 index 0000000..0272f41 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/SetRotation.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: c5ac2e84278f4a845ba47d1e4469e869 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/SetUseGravity.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/SetUseGravity.cs new file mode 100644 index 0000000..0380dbf --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/SetUseGravity.cs @@ -0,0 +1,45 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityRigidbody +{ + [TaskCategory("Unity/Rigidbody")] + [TaskDescription("Sets the use gravity value of the Rigidbody. Returns Success.")] + public class SetUseGravity : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The use gravity value of the Rigidbody")] + public SharedBool useGravity; + + // cache the rigidbody component + private Rigidbody rigidbody; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + rigidbody = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (rigidbody == null) { + Debug.LogWarning("Rigidbody is null"); + return TaskStatus.Failure; + } + + rigidbody.useGravity = useGravity.Value; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + useGravity = false; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/SetUseGravity.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/SetUseGravity.cs.meta new file mode 100644 index 0000000..0300c04 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/SetUseGravity.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 19548f438ad1c684180d41713cbdeb76 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/SetVelocity.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/SetVelocity.cs new file mode 100644 index 0000000..b57239e --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/SetVelocity.cs @@ -0,0 +1,45 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityRigidbody +{ + [TaskCategory("Unity/Rigidbody")] + [TaskDescription("Sets the velocity of the Rigidbody. Returns Success.")] + public class SetVelocity : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The velocity of the Rigidbody")] + public SharedVector3 velocity; + + // cache the rigidbody component + private Rigidbody rigidbody; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + rigidbody = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (rigidbody == null) { + Debug.LogWarning("Rigidbody is null"); + return TaskStatus.Failure; + } + + rigidbody.velocity = velocity.Value; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + velocity = Vector3.zero; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/SetVelocity.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/SetVelocity.cs.meta new file mode 100644 index 0000000..f62238b --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/SetVelocity.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 3e3fc3ca798c87644a42b1c930fff3f0 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/Sleep.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/Sleep.cs new file mode 100644 index 0000000..80ceee6 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/Sleep.cs @@ -0,0 +1,42 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityRigidbody +{ + [TaskCategory("Unity/Rigidbody")] + [TaskDescription("Forces the Rigidbody to sleep at least one frame. Returns Success.")] + public class Sleep : Conditional + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + + // cache the rigidbody component + private Rigidbody rigidbody; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + rigidbody = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (rigidbody == null) { + Debug.LogWarning("Rigidbody is null"); + return TaskStatus.Failure; + } + + rigidbody.Sleep(); + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/Sleep.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/Sleep.cs.meta new file mode 100644 index 0000000..3440d81 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/Sleep.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 1683ca7168c4ce74db4396c4d3cb65ce +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/UseGravity.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/UseGravity.cs new file mode 100644 index 0000000..6933c91 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/UseGravity.cs @@ -0,0 +1,40 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityRigidbody +{ + [TaskCategory("Unity/Rigidbody")] + [TaskDescription("Returns Success if the Rigidbody is using gravity, otherwise Failure.")] + public class UseGravity : Conditional + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + + // cache the rigidbody component + private Rigidbody rigidbody; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + rigidbody = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (rigidbody == null) { + Debug.LogWarning("Rigidbody is null"); + return TaskStatus.Failure; + } + + return rigidbody.useGravity ? TaskStatus.Success : TaskStatus.Failure; + } + + public override void OnReset() + { + targetGameObject = null; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/UseGravity.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/UseGravity.cs.meta new file mode 100644 index 0000000..fd11010 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/UseGravity.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: a0d11b67c4ae058469e7f7b00db7103f +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/WakeUp.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/WakeUp.cs new file mode 100644 index 0000000..b699040 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/WakeUp.cs @@ -0,0 +1,42 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityRigidbody +{ + [TaskCategory("Unity/Rigidbody")] + [TaskDescription("Forces the Rigidbody to wake up. Returns Success.")] + public class WakeUp : Conditional + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + + // cache the rigidbody component + private Rigidbody rigidbody; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + rigidbody = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (rigidbody == null) { + Debug.LogWarning("Rigidbody is null"); + return TaskStatus.Failure; + } + + rigidbody.WakeUp(); + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/WakeUp.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/WakeUp.cs.meta new file mode 100644 index 0000000..ca8eade --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody/WakeUp.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: d4314af88b4d86046bdac1f10f6f9a47 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D.meta new file mode 100644 index 0000000..84e1cee --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D.meta @@ -0,0 +1,4 @@ +fileFormatVersion: 2 +guid: 842427c186c2e5941b1b02873f6480e3 +DefaultImporter: + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/AddForce.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/AddForce.cs new file mode 100644 index 0000000..86e2d3e --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/AddForce.cs @@ -0,0 +1,44 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityRigidbody2D +{ + [TaskCategory("Unity/Rigidbody2D")] + [TaskDescription("Applies a force to the Rigidbody2D. Returns Success.")] + public class AddForce : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The amount of force to apply")] + public SharedVector2 force; + + private Rigidbody2D rigidbody2D; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + rigidbody2D = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (rigidbody2D == null) { + Debug.LogWarning("Rigidbody2D is null"); + return TaskStatus.Failure; + } + + rigidbody2D.AddForce(force.Value); + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + force = Vector2.zero; + } + } +} diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/AddForce.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/AddForce.cs.meta new file mode 100644 index 0000000..2ed7346 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/AddForce.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 9ea79154ee01cf441a9744c877542a1f +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/AddForceAtPosition.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/AddForceAtPosition.cs new file mode 100644 index 0000000..8d8be2f --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/AddForceAtPosition.cs @@ -0,0 +1,47 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityRigidbody2D +{ + [TaskCategory("Unity/Rigidbody2D")] + [TaskDescription("Applies a force at the specified position to the Rigidbody2D. Returns Success.")] + public class AddForceAtPosition : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The amount of force to apply")] + public SharedVector2 force; + [Tooltip("The position of the force")] + public SharedVector2 position; + + private Rigidbody2D rigidbody2D; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + rigidbody2D = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (rigidbody2D == null) { + Debug.LogWarning("Rigidbody2D is null"); + return TaskStatus.Failure; + } + + rigidbody2D.AddForceAtPosition(force.Value, position.Value); + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + force = Vector2.zero; + position = Vector2.zero; + } + } +} diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/AddForceAtPosition.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/AddForceAtPosition.cs.meta new file mode 100644 index 0000000..f0d7e68 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/AddForceAtPosition.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: dd82f0f77306bad46bae7944a5c66664 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/AddTorque.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/AddTorque.cs new file mode 100644 index 0000000..f214d95 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/AddTorque.cs @@ -0,0 +1,44 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityRigidbody2D +{ + [TaskCategory("Unity/Rigidbody2D")] + [TaskDescription("Applies a torque to the Rigidbody2D. Returns Success.")] + public class AddTorque : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The amount of torque to apply")] + public SharedFloat torque; + + private Rigidbody2D rigidbody2D; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + rigidbody2D = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (rigidbody2D == null) { + Debug.LogWarning("Rigidbody2D is null"); + return TaskStatus.Failure; + } + + rigidbody2D.AddTorque(torque.Value); + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + torque = 0; + } + } +} diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/AddTorque.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/AddTorque.cs.meta new file mode 100644 index 0000000..b460ed5 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/AddTorque.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: cc561d806d4518044becff628e148424 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/GetAngularDrag.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/GetAngularDrag.cs new file mode 100644 index 0000000..a3c812f --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/GetAngularDrag.cs @@ -0,0 +1,45 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityRigidbody2D +{ + [TaskCategory("Unity/Rigidbody2D")] + [TaskDescription("Stores the angular drag of the Rigidbody2D. Returns Success.")] + public class GetAngularDrag : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The angular drag of the Rigidbody2D")] + [RequiredField] + public SharedFloat storeValue; + + private Rigidbody2D rigidbody2D; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + rigidbody2D = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (rigidbody2D == null) { + Debug.LogWarning("Rigidbody2D is null"); + return TaskStatus.Failure; + } + + storeValue.Value = rigidbody2D.angularDrag; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + storeValue = 0; + } + } +} diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/GetAngularDrag.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/GetAngularDrag.cs.meta new file mode 100644 index 0000000..812c673 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/GetAngularDrag.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 10833270578d69041b561c5126bb31f2 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/GetAngularVelocity.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/GetAngularVelocity.cs new file mode 100644 index 0000000..d3edc1c --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/GetAngularVelocity.cs @@ -0,0 +1,45 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityRigidbody2D +{ + [TaskCategory("Unity/Rigidbody2D")] + [TaskDescription("Stores the angular velocity of the Rigidbody2D. Returns Success.")] + public class GetAngularVelocity : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The angular velocity of the Rigidbody2D")] + [RequiredField] + public SharedFloat storeValue; + + private Rigidbody2D rigidbody2D; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + rigidbody2D = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (rigidbody2D == null) { + Debug.LogWarning("Rigidbody2D is null"); + return TaskStatus.Failure; + } + + storeValue.Value = rigidbody2D.angularVelocity; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + storeValue = 0; + } + } +} diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/GetAngularVelocity.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/GetAngularVelocity.cs.meta new file mode 100644 index 0000000..f01c125 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/GetAngularVelocity.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 68ac62a9384c11245a850220f1bc72b8 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/GetDrag.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/GetDrag.cs new file mode 100644 index 0000000..6cd0940 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/GetDrag.cs @@ -0,0 +1,45 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityRigidbody2D +{ + [TaskCategory("Unity/Rigidbody2D")] + [TaskDescription("Stores the drag of the Rigidbody2D. Returns Success.")] + public class GetDrag : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The drag of the Rigidbody2D")] + [RequiredField] + public SharedFloat storeValue; + + private Rigidbody2D rigidbody2D; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + rigidbody2D = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (rigidbody2D == null) { + Debug.LogWarning("Rigidbody2D is null"); + return TaskStatus.Failure; + } + + storeValue.Value = rigidbody2D.drag; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + storeValue = 0; + } + } +} diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/GetDrag.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/GetDrag.cs.meta new file mode 100644 index 0000000..3ec7bfe --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/GetDrag.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 6e39198e5d65d514185f2816cced7c7b +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/GetGravtyScale.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/GetGravtyScale.cs new file mode 100644 index 0000000..41a2a7f --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/GetGravtyScale.cs @@ -0,0 +1,45 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityRigidbody2D +{ + [TaskCategory("Unity/Rigidbody2D")] + [TaskDescription("Stores the gravity scale of the Rigidbody2D. Returns Success.")] + public class GetGravityScale : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The gravity scale of the Rigidbody2D")] + [RequiredField] + public SharedFloat storeValue; + + private Rigidbody2D rigidbody2D; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + rigidbody2D = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (rigidbody2D == null) { + Debug.LogWarning("Rigidbody2D is null"); + return TaskStatus.Failure; + } + + storeValue.Value = rigidbody2D.gravityScale; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + storeValue = 0; + } + } +} diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/GetGravtyScale.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/GetGravtyScale.cs.meta new file mode 100644 index 0000000..38d9057 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/GetGravtyScale.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: e2d17fb9baea6554082f2edc46483e8c +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/GetIsKinematic.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/GetIsKinematic.cs new file mode 100644 index 0000000..d32b65e --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/GetIsKinematic.cs @@ -0,0 +1,45 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityRigidbody2D +{ + [TaskCategory("Unity/Rigidbody2D")] + [TaskDescription("Stores the is kinematic value of the Rigidbody2D. Returns Success.")] + public class GetIsKinematic : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The is kinematic value of the Rigidbody2D")] + [RequiredField] + public SharedBool storeValue; + + private Rigidbody2D rigidbody2D; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + rigidbody2D = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (rigidbody2D == null) { + Debug.LogWarning("Rigidbody2D is null"); + return TaskStatus.Failure; + } + + storeValue.Value = rigidbody2D.isKinematic; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + storeValue = false; + } + } +} diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/GetIsKinematic.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/GetIsKinematic.cs.meta new file mode 100644 index 0000000..b60ef91 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/GetIsKinematic.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 66c6175d42bd49e48be458378e0a7875 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/GetMass.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/GetMass.cs new file mode 100644 index 0000000..f7faaee --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/GetMass.cs @@ -0,0 +1,45 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityRigidbody2D +{ + [TaskCategory("Unity/Rigidbody2D")] + [TaskDescription("Stores the mass of the Rigidbody2D. Returns Success.")] + public class GetMass : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The mass of the Rigidbody2D")] + [RequiredField] + public SharedFloat storeValue; + + private Rigidbody2D rigidbody2D; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + rigidbody2D = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (rigidbody2D == null) { + Debug.LogWarning("Rigidbody2D is null"); + return TaskStatus.Failure; + } + + storeValue.Value = rigidbody2D.mass; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + storeValue = 0; + } + } +} diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/GetMass.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/GetMass.cs.meta new file mode 100644 index 0000000..19d27e0 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/GetMass.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 72d52ef5efe5e974994c91279536555e +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/GetPosition.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/GetPosition.cs new file mode 100644 index 0000000..da0dd26 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/GetPosition.cs @@ -0,0 +1,45 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityRigidbody2D +{ + [TaskCategory("Unity/Rigidbody2D")] + [TaskDescription("Stores the position of the Rigidbody2D. Returns Success.")] + public class GetPosition : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The velocity of the Rigidbody2D")] + [RequiredField] + public SharedVector2 storeValue; + + private Rigidbody2D rigidbody2D; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + rigidbody2D = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (rigidbody2D == null) { + Debug.LogWarning("Rigidbody2D is null"); + return TaskStatus.Failure; + } + + storeValue.Value = rigidbody2D.position; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + storeValue = Vector2.zero; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/GetPosition.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/GetPosition.cs.meta new file mode 100644 index 0000000..412187c --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/GetPosition.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 98dff23734f3a834cbf5ccf87c9904f7 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/GetRotation.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/GetRotation.cs new file mode 100644 index 0000000..5b89ff3 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/GetRotation.cs @@ -0,0 +1,45 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityRigidbody2D +{ + [TaskCategory("Unity/Rigidbody2D")] + [TaskDescription("Stores the rotation of the Rigidbody2D. Returns Success.")] + public class GetRotation : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The rotation of the Rigidbody2D")] + [RequiredField] + public SharedFloat storeValue; + + private Rigidbody2D rigidbody2D; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + rigidbody2D = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (rigidbody2D == null) { + Debug.LogWarning("Rigidbody2D is null"); + return TaskStatus.Failure; + } + + storeValue.Value = rigidbody2D.rotation; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + storeValue = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/GetRotation.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/GetRotation.cs.meta new file mode 100644 index 0000000..7d9b14f --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/GetRotation.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: a7d82ab7ef780f34cb5df06366b0bdbf +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/GetVelocity.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/GetVelocity.cs new file mode 100644 index 0000000..98b6b4e --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/GetVelocity.cs @@ -0,0 +1,45 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityRigidbody2D +{ + [TaskCategory("Unity/Rigidbody2D")] + [TaskDescription("Stores the velocity of the Rigidbody2D. Returns Success.")] + public class GetVelocity : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The velocity of the Rigidbody2D")] + [RequiredField] + public SharedVector2 storeValue; + + private Rigidbody2D rigidbody2D; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + rigidbody2D = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (rigidbody2D == null) { + Debug.LogWarning("Rigidbody2D is null"); + return TaskStatus.Failure; + } + + storeValue.Value = rigidbody2D.velocity; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + storeValue = Vector2.zero; + } + } +} diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/GetVelocity.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/GetVelocity.cs.meta new file mode 100644 index 0000000..70d8f29 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/GetVelocity.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 13009f7b6ee1bc04884442484a065cc3 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/IsKinematic.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/IsKinematic.cs new file mode 100644 index 0000000..7c7ecab --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/IsKinematic.cs @@ -0,0 +1,39 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityRigidbody2D +{ + [TaskCategory("Unity/Rigidbody2D")] + [TaskDescription("Returns Success if the Rigidbody2D is kinematic, otherwise Failure.")] + public class IsKinematic : Conditional + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + + private Rigidbody2D rigidbody2D; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + rigidbody2D = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (rigidbody2D == null) { + Debug.LogWarning("Rigidbody2D is null"); + return TaskStatus.Failure; + } + + return rigidbody2D.isKinematic ? TaskStatus.Success : TaskStatus.Failure; + } + + public override void OnReset() + { + targetGameObject = null; + } + } +} diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/IsKinematic.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/IsKinematic.cs.meta new file mode 100644 index 0000000..1150f10 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/IsKinematic.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 47d2e6e60a2251c41a2c548dc9a8c922 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/IsSleeping.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/IsSleeping.cs new file mode 100644 index 0000000..248a23e --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/IsSleeping.cs @@ -0,0 +1,39 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityRigidbody2D +{ + [TaskCategory("Unity/Rigidbody2D")] + [TaskDescription("Returns Success if the Rigidbody2D is sleeping, otherwise Failure.")] + public class IsSleeping : Conditional + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + + private Rigidbody2D rigidbody2D; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + rigidbody2D = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (rigidbody2D == null) { + Debug.LogWarning("Rigidbody2D is null"); + return TaskStatus.Failure; + } + + return rigidbody2D.IsSleeping() ? TaskStatus.Success : TaskStatus.Failure; + } + + public override void OnReset() + { + targetGameObject = null; + } + } +} diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/IsSleeping.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/IsSleeping.cs.meta new file mode 100644 index 0000000..b6e37b8 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/IsSleeping.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 52859810158277a4a917e70a834a82a5 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/MovePosition.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/MovePosition.cs new file mode 100644 index 0000000..f77e34d --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/MovePosition.cs @@ -0,0 +1,45 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityRigidbody2D +{ + [TaskCategory("Unity/Rigidbody2D")] + [TaskDescription("Moves the Rigidbody2D to the specified position. Returns Success.")] + public class MovePosition : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The new position of the Rigidbody")] + public SharedVector2 position; + + // cache the rigidbody component + private Rigidbody2D rigidbody2D; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + rigidbody2D = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (rigidbody2D == null) { + Debug.LogWarning("Rigidbody is null"); + return TaskStatus.Failure; + } + + rigidbody2D.MovePosition(position.Value); + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + position = Vector2.zero; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/MovePosition.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/MovePosition.cs.meta new file mode 100644 index 0000000..1c9ece8 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/MovePosition.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 3e72fab171287194ea2d8eb2aa239cd4 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/MoveRotation.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/MoveRotation.cs new file mode 100644 index 0000000..f55821f --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/MoveRotation.cs @@ -0,0 +1,45 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityRigidbody2D +{ + [TaskCategory("Unity/Rigidbody2D")] + [TaskDescription("Rotates the Rigidbody2D to the specified rotation. Returns Success.")] + public class MoveRotation : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The new rotation of the Rigidbody")] + public SharedFloat rotation; + + // cache the rigidbody component + private Rigidbody2D rigidbody2D; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + rigidbody2D = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (rigidbody2D == null) { + Debug.LogWarning("Rigidbody is null"); + return TaskStatus.Failure; + } + + rigidbody2D.MoveRotation(rotation.Value); + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + rotation = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/MoveRotation.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/MoveRotation.cs.meta new file mode 100644 index 0000000..3e57ec9 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/MoveRotation.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 38b0095c420511f4b9ed263b1b5c6054 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/SetAngularDrag.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/SetAngularDrag.cs new file mode 100644 index 0000000..1df126b --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/SetAngularDrag.cs @@ -0,0 +1,44 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityRigidbody2D +{ + [TaskCategory("Unity/Rigidbody2D")] + [TaskDescription("Sets the angular drag of the Rigidbody2D. Returns Success.")] + public class SetAngularDrag : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The angular drag of the Rigidbody2D")] + public SharedFloat angularDrag; + + private Rigidbody2D rigidbody2D; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + rigidbody2D = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (rigidbody2D == null) { + Debug.LogWarning("Rigidbody2D is null"); + return TaskStatus.Failure; + } + + rigidbody2D.angularDrag = angularDrag.Value; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + angularDrag = 0; + } + } +} diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/SetAngularDrag.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/SetAngularDrag.cs.meta new file mode 100644 index 0000000..3515b41 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/SetAngularDrag.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 1717a737318274e4caa244f86c908851 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/SetAngularVelocity.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/SetAngularVelocity.cs new file mode 100644 index 0000000..ef1595f --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/SetAngularVelocity.cs @@ -0,0 +1,44 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityRigidbody2D +{ + [TaskCategory("Unity/Rigidbody2D")] + [TaskDescription("Sets the angular velocity of the Rigidbody2D. Returns Success.")] + public class SetAngularVelocity : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The angular velocity of the Rigidbody2D")] + public SharedFloat angularVelocity; + + private Rigidbody2D rigidbody2D; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + rigidbody2D = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (rigidbody2D == null) { + Debug.LogWarning("Rigidbody2D is null"); + return TaskStatus.Failure; + } + + rigidbody2D.angularVelocity = angularVelocity.Value; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + angularVelocity = 0; + } + } +} diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/SetAngularVelocity.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/SetAngularVelocity.cs.meta new file mode 100644 index 0000000..dc5a1c7 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/SetAngularVelocity.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: c73dfb332d90cbe4280c21fafa59e2fa +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/SetDrag.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/SetDrag.cs new file mode 100644 index 0000000..77b462e --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/SetDrag.cs @@ -0,0 +1,44 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityRigidbody2D +{ + [TaskCategory("Unity/Rigidbody2D")] + [TaskDescription("Sets the drag of the Rigidbody2D. Returns Success.")] + public class SetDrag : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The drag of the Rigidbody2D")] + public SharedFloat drag; + + private Rigidbody2D rigidbody2D; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + rigidbody2D = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (rigidbody2D == null) { + Debug.LogWarning("Rigidbody2D is null"); + return TaskStatus.Failure; + } + + rigidbody2D.drag = drag.Value; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + drag = 0; + } + } +} diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/SetDrag.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/SetDrag.cs.meta new file mode 100644 index 0000000..a58b5b9 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/SetDrag.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 3148efd94c23d634a9f02cc9c808de80 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/SetGravityScale.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/SetGravityScale.cs new file mode 100644 index 0000000..85ebe61 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/SetGravityScale.cs @@ -0,0 +1,44 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityRigidbody2D +{ + [TaskCategory("Unity/Rigidbody2D")] + [TaskDescription("Sets the gravity scale of the Rigidbody2D. Returns Success.")] + public class SetGravityScale : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The gravity scale of the Rigidbody2D")] + public SharedFloat gravityScale; + + private Rigidbody2D rigidbody2D; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + rigidbody2D = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (rigidbody2D == null) { + Debug.LogWarning("Rigidbody2D is null"); + return TaskStatus.Failure; + } + + rigidbody2D.gravityScale = gravityScale.Value; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + gravityScale = 0; + } + } +} diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/SetGravityScale.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/SetGravityScale.cs.meta new file mode 100644 index 0000000..6e1eaf5 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/SetGravityScale.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: ac896135858701649bcaffc7ef00637f +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/SetIsKinematic.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/SetIsKinematic.cs new file mode 100644 index 0000000..401f422 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/SetIsKinematic.cs @@ -0,0 +1,44 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityRigidbody2D +{ + [TaskCategory("Unity/Rigidbody2D")] + [TaskDescription("Sets the is kinematic value of the Rigidbody2D. Returns Success.")] + public class SetIsKinematic : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The is kinematic value of the Rigidbody2D")] + public SharedBool isKinematic; + + private Rigidbody2D rigidbody2D; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + rigidbody2D = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (rigidbody2D == null) { + Debug.LogWarning("Rigidbody2D is null"); + return TaskStatus.Failure; + } + + rigidbody2D.isKinematic = isKinematic.Value; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + isKinematic = false; + } + } +} diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/SetIsKinematic.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/SetIsKinematic.cs.meta new file mode 100644 index 0000000..e9987a3 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/SetIsKinematic.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: b7c96d64d821e304a8c67c031565d902 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/SetMass.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/SetMass.cs new file mode 100644 index 0000000..1042b6d --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/SetMass.cs @@ -0,0 +1,44 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityRigidbody2D +{ + [TaskCategory("Unity/Rigidbody2D")] + [TaskDescription("Sets the mass of the Rigidbody2D. Returns Success.")] + public class SetMass : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The mass of the Rigidbody2D")] + public SharedFloat mass; + + private Rigidbody2D rigidbody2D; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + rigidbody2D = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (rigidbody2D == null) { + Debug.LogWarning("Rigidbody2D is null"); + return TaskStatus.Failure; + } + + rigidbody2D.mass = mass.Value; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + mass = 0; + } + } +} diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/SetMass.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/SetMass.cs.meta new file mode 100644 index 0000000..eb5e835 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/SetMass.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: facbfd14ece02214889d587f06215105 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/SetVelocity.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/SetVelocity.cs new file mode 100644 index 0000000..7ea019c --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/SetVelocity.cs @@ -0,0 +1,44 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityRigidbody2D +{ + [TaskCategory("Unity/Rigidbody2D")] + [TaskDescription("Sets the velocity of the Rigidbody2D. Returns Success.")] + public class SetVelocity : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The velocity of the Rigidbody2D")] + public SharedVector2 velocity; + + private Rigidbody2D rigidbody2D; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + rigidbody2D = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (rigidbody2D == null) { + Debug.LogWarning("Rigidbody2D is null"); + return TaskStatus.Failure; + } + + rigidbody2D.velocity = velocity.Value; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + velocity = Vector2.zero; + } + } +} diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/SetVelocity.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/SetVelocity.cs.meta new file mode 100644 index 0000000..ca75962 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/SetVelocity.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 5830960da4f9a3148ba5d8cd87228748 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/Sleep.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/Sleep.cs new file mode 100644 index 0000000..345386f --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/Sleep.cs @@ -0,0 +1,41 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityRigidbody2D +{ + [TaskCategory("Unity/Rigidbody2D")] + [TaskDescription("Forces the Rigidbody2D to sleep at least one frame. Returns Success.")] + public class Sleep : Conditional + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + + private Rigidbody2D rigidbody2D; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + rigidbody2D = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (rigidbody2D == null) { + Debug.LogWarning("Rigidbody2D is null"); + return TaskStatus.Failure; + } + + rigidbody2D.Sleep(); + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + } + } +} diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/Sleep.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/Sleep.cs.meta new file mode 100644 index 0000000..523fbe5 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/Sleep.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 7e24fd00ca72fda48a132dc9bfa71070 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/WakeUp.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/WakeUp.cs new file mode 100644 index 0000000..dfe4910 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/WakeUp.cs @@ -0,0 +1,41 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityRigidbody2D +{ + [TaskCategory("Unity/Rigidbody2D")] + [TaskDescription("Forces the Rigidbody2D to wake up. Returns Success.")] + public class WakeUp : Conditional + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + + private Rigidbody2D rigidbody2D; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + rigidbody2D = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (rigidbody2D == null) { + Debug.LogWarning("Rigidbody2D is null"); + return TaskStatus.Failure; + } + + rigidbody2D.WakeUp(); + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + } + } +} diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/WakeUp.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/WakeUp.cs.meta new file mode 100644 index 0000000..5bda548 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Rigidbody2D/WakeUp.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 954f1f9c196c39345b2fd389516ad613 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables.meta new file mode 100644 index 0000000..33f2d8f --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables.meta @@ -0,0 +1,4 @@ +fileFormatVersion: 2 +guid: 1ca8022ad636ccc4ab940c05d58dfd6b +DefaultImporter: + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/CompareSharedBool.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/CompareSharedBool.cs new file mode 100644 index 0000000..453f10a --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/CompareSharedBool.cs @@ -0,0 +1,23 @@ +namespace BehaviorDesigner.Runtime.Tasks.Unity.SharedVariables +{ + [TaskCategory("Unity/SharedVariable")] + [TaskDescription("Returns success if the variable value is equal to the compareTo value.")] + public class CompareSharedBool : Conditional + { + [Tooltip("The first variable to compare")] + public SharedBool variable; + [Tooltip("The variable to compare to")] + public SharedBool compareTo; + + public override TaskStatus OnUpdate() + { + return variable.Value.Equals(compareTo.Value) ? TaskStatus.Success : TaskStatus.Failure; + } + + public override void OnReset() + { + variable = false; + compareTo = false; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/CompareSharedBool.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/CompareSharedBool.cs.meta new file mode 100644 index 0000000..90059a9 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/CompareSharedBool.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: ba0766a97c2e5c94fbc49d8cb1dea8e3 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/CompareSharedColor.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/CompareSharedColor.cs new file mode 100644 index 0000000..f37908f --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/CompareSharedColor.cs @@ -0,0 +1,25 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.SharedVariables +{ + [TaskCategory("Unity/SharedVariable")] + [TaskDescription("Returns success if the variable value is equal to the compareTo value.")] + public class CompareSharedColor : Conditional + { + [Tooltip("The first variable to compare")] + public SharedColor variable; + [Tooltip("The variable to compare to")] + public SharedColor compareTo; + + public override TaskStatus OnUpdate() + { + return variable.Value.Equals(compareTo.Value) ? TaskStatus.Success : TaskStatus.Failure; + } + + public override void OnReset() + { + variable = Color.black; + compareTo = Color.black; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/CompareSharedColor.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/CompareSharedColor.cs.meta new file mode 100644 index 0000000..5dc8c7c --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/CompareSharedColor.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: c9e83747d98bd064b9a5ad62b36d7657 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/CompareSharedFloat.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/CompareSharedFloat.cs new file mode 100644 index 0000000..3c58f8d --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/CompareSharedFloat.cs @@ -0,0 +1,23 @@ +namespace BehaviorDesigner.Runtime.Tasks.Unity.SharedVariables +{ + [TaskCategory("Unity/SharedVariable")] + [TaskDescription("Returns success if the variable value is equal to the compareTo value.")] + public class CompareSharedFloat : Conditional + { + [Tooltip("The first variable to compare")] + public SharedFloat variable; + [Tooltip("The variable to compare to")] + public SharedFloat compareTo; + + public override TaskStatus OnUpdate() + { + return variable.Value.Equals(compareTo.Value) ? TaskStatus.Success : TaskStatus.Failure; + } + + public override void OnReset() + { + variable = 0; + compareTo = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/CompareSharedFloat.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/CompareSharedFloat.cs.meta new file mode 100644 index 0000000..6f4760e --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/CompareSharedFloat.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 6925a99e92b6d804db1f4b607e7501d3 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/CompareSharedGameObject.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/CompareSharedGameObject.cs new file mode 100644 index 0000000..8f550e3 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/CompareSharedGameObject.cs @@ -0,0 +1,30 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.SharedVariables +{ + [TaskCategory("Unity/SharedVariable")] + [TaskDescription("Returns success if the variable value is equal to the compareTo value.")] + public class CompareSharedGameObject : Conditional + { + [Tooltip("The first variable to compare")] + public SharedGameObject variable; + [Tooltip("The variable to compare to")] + public SharedGameObject compareTo; + + public override TaskStatus OnUpdate() + { + if (variable.Value == null && compareTo.Value != null) + return TaskStatus.Failure; + if (variable.Value == null && compareTo.Value == null) + return TaskStatus.Success; + + return variable.Value.Equals(compareTo.Value) ? TaskStatus.Success : TaskStatus.Failure; + } + + public override void OnReset() + { + variable = null; + compareTo = null; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/CompareSharedGameObject.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/CompareSharedGameObject.cs.meta new file mode 100644 index 0000000..8ed84aa --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/CompareSharedGameObject.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: daa5c3b8a325bcd4bb3da10a6715f6d0 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/CompareSharedGameObjectList.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/CompareSharedGameObjectList.cs new file mode 100644 index 0000000..0362e59 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/CompareSharedGameObjectList.cs @@ -0,0 +1,35 @@ +namespace BehaviorDesigner.Runtime.Tasks.Unity.SharedVariables +{ + [TaskCategory("Unity/SharedVariable")] + [TaskDescription("Returns success if the variable value is equal to the compareTo value.")] + public class CompareSharedGameObjectList : Conditional + { + [Tooltip("The first variable to compare")] + public SharedGameObjectList variable; + [Tooltip("The variable to compare to")] + public SharedGameObjectList compareTo; + + public override TaskStatus OnUpdate() + { + if (variable.Value == null && compareTo.Value != null) + return TaskStatus.Failure; + if (variable.Value == null && compareTo.Value == null) + return TaskStatus.Success; + if (variable.Value.Count != compareTo.Value.Count) + return TaskStatus.Failure; + + for (int i = 0; i < variable.Value.Count; ++i) { + if (variable.Value[i] != compareTo.Value[i]) { + return TaskStatus.Failure; + } + } + return TaskStatus.Success; + } + + public override void OnReset() + { + variable = null; + compareTo = null; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/CompareSharedGameObjectList.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/CompareSharedGameObjectList.cs.meta new file mode 100644 index 0000000..95523b2 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/CompareSharedGameObjectList.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: a2b81932d36a0be4fba0868f7ed3e53c +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/CompareSharedInt.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/CompareSharedInt.cs new file mode 100644 index 0000000..ce216d9 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/CompareSharedInt.cs @@ -0,0 +1,23 @@ +namespace BehaviorDesigner.Runtime.Tasks.Unity.SharedVariables +{ + [TaskCategory("Unity/SharedVariable")] + [TaskDescription("Returns success if the variable value is equal to the compareTo value.")] + public class CompareSharedInt : Conditional + { + [Tooltip("The first variable to compare")] + public SharedInt variable; + [Tooltip("The variable to compare to")] + public SharedInt compareTo; + + public override TaskStatus OnUpdate() + { + return variable.Value.Equals(compareTo.Value) ? TaskStatus.Success : TaskStatus.Failure; + } + + public override void OnReset() + { + variable = 0; + compareTo = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/CompareSharedInt.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/CompareSharedInt.cs.meta new file mode 100644 index 0000000..ed16555 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/CompareSharedInt.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 40307a4117777b4479a1402fd67811ff +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/CompareSharedObject.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/CompareSharedObject.cs new file mode 100644 index 0000000..6ea4fed --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/CompareSharedObject.cs @@ -0,0 +1,30 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.SharedVariables +{ + [TaskCategory("Unity/SharedVariable")] + [TaskDescription("Returns success if the variable value is equal to the compareTo value.")] + public class CompareSharedObject : Conditional + { + [Tooltip("The first variable to compare")] + public SharedObject variable; + [Tooltip("The variable to compare to")] + public SharedObject compareTo; + + public override TaskStatus OnUpdate() + { + if (variable.Value == null && compareTo.Value != null) + return TaskStatus.Failure; + if (variable.Value == null && compareTo.Value == null) + return TaskStatus.Success; + + return variable.Value.Equals(compareTo.Value) ? TaskStatus.Success : TaskStatus.Failure; + } + + public override void OnReset() + { + variable = null; + compareTo = null; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/CompareSharedObject.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/CompareSharedObject.cs.meta new file mode 100644 index 0000000..2e6db0e --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/CompareSharedObject.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 66a9105498519ae4082d9ac7adcf5da4 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/CompareSharedObjectList.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/CompareSharedObjectList.cs new file mode 100644 index 0000000..be59a58 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/CompareSharedObjectList.cs @@ -0,0 +1,35 @@ +namespace BehaviorDesigner.Runtime.Tasks.Unity.SharedVariables +{ + [TaskCategory("Unity/SharedVariable")] + [TaskDescription("Returns success if the variable value is equal to the compareTo value.")] + public class CompareSharedObjectList : Conditional + { + [Tooltip("The first variable to compare")] + public SharedObjectList variable; + [Tooltip("The variable to compare to")] + public SharedObjectList compareTo; + + public override TaskStatus OnUpdate() + { + if (variable.Value == null && compareTo.Value != null) + return TaskStatus.Failure; + if (variable.Value == null && compareTo.Value == null) + return TaskStatus.Success; + if (variable.Value.Count != compareTo.Value.Count) + return TaskStatus.Failure; + + for (int i = 0; i < variable.Value.Count; ++i) { + if (variable.Value[i] != compareTo.Value[i]) { + return TaskStatus.Failure; + } + } + return TaskStatus.Success; + } + + public override void OnReset() + { + variable = null; + compareTo = null; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/CompareSharedObjectList.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/CompareSharedObjectList.cs.meta new file mode 100644 index 0000000..8d768fe --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/CompareSharedObjectList.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: ac4cab9acc737904885d379388e83950 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/CompareSharedQuaternion.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/CompareSharedQuaternion.cs new file mode 100644 index 0000000..9867ed5 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/CompareSharedQuaternion.cs @@ -0,0 +1,25 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.SharedVariables +{ + [TaskCategory("Unity/SharedVariable")] + [TaskDescription("Returns success if the variable value is equal to the compareTo value.")] + public class CompareSharedQuaternion : Conditional + { + [Tooltip("The first variable to compare")] + public SharedQuaternion variable; + [Tooltip("The variable to compare to")] + public SharedQuaternion compareTo; + + public override TaskStatus OnUpdate() + { + return variable.Value.Equals(compareTo.Value) ? TaskStatus.Success : TaskStatus.Failure; + } + + public override void OnReset() + { + variable = Quaternion.identity; + compareTo = Quaternion.identity; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/CompareSharedQuaternion.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/CompareSharedQuaternion.cs.meta new file mode 100644 index 0000000..802d377 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/CompareSharedQuaternion.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 101b2ac215bf58149ab91be3b55d5145 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/CompareSharedRect.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/CompareSharedRect.cs new file mode 100644 index 0000000..92060a8 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/CompareSharedRect.cs @@ -0,0 +1,25 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.SharedVariables +{ + [TaskCategory("Unity/SharedVariable")] + [TaskDescription("Returns success if the variable value is equal to the compareTo value.")] + public class CompareSharedRect : Conditional + { + [Tooltip("The first variable to compare")] + public SharedRect variable; + [Tooltip("The variable to compare to")] + public SharedRect compareTo; + + public override TaskStatus OnUpdate() + { + return variable.Value.Equals(compareTo.Value) ? TaskStatus.Success : TaskStatus.Failure; + } + + public override void OnReset() + { + variable = new Rect(); + compareTo = new Rect(); + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/CompareSharedRect.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/CompareSharedRect.cs.meta new file mode 100644 index 0000000..14ff94c --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/CompareSharedRect.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: d73d97622bbe61d4c91f9b4cacb3e0c2 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/CompareSharedString.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/CompareSharedString.cs new file mode 100644 index 0000000..2c566a5 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/CompareSharedString.cs @@ -0,0 +1,23 @@ +namespace BehaviorDesigner.Runtime.Tasks.Unity.SharedVariables +{ + [TaskCategory("Unity/SharedVariable")] + [TaskDescription("Returns success if the variable value is equal to the compareTo value.")] + public class CompareSharedString : Conditional + { + [Tooltip("The first variable to compare")] + public SharedString variable; + [Tooltip("The variable to compare to")] + public SharedString compareTo; + + public override TaskStatus OnUpdate() + { + return variable.Value.Equals(compareTo.Value) ? TaskStatus.Success : TaskStatus.Failure; + } + + public override void OnReset() + { + variable = ""; + compareTo = ""; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/CompareSharedString.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/CompareSharedString.cs.meta new file mode 100644 index 0000000..edf1bb7 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/CompareSharedString.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 8b1a3248c84732345914404e47a55fcc +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/CompareSharedTransform.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/CompareSharedTransform.cs new file mode 100644 index 0000000..6210a6d --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/CompareSharedTransform.cs @@ -0,0 +1,30 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.SharedVariables +{ + [TaskCategory("Unity/SharedVariable")] + [TaskDescription("Returns success if the variable value is equal to the compareTo value.")] + public class CompareSharedTransform : Conditional + { + [Tooltip("The first variable to compare")] + public SharedTransform variable; + [Tooltip("The variable to compare to")] + public SharedTransform compareTo; + + public override TaskStatus OnUpdate() + { + if (variable.Value == null && compareTo.Value != null) + return TaskStatus.Failure; + if (variable.Value == null && compareTo.Value == null) + return TaskStatus.Success; + + return variable.Value.Equals(compareTo.Value) ? TaskStatus.Success : TaskStatus.Failure; + } + + public override void OnReset() + { + variable = null; + compareTo = null; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/CompareSharedTransform.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/CompareSharedTransform.cs.meta new file mode 100644 index 0000000..3074aa4 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/CompareSharedTransform.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: a21f70566ff2afc4e95454d3d658c1fa +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/CompareSharedTransformList.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/CompareSharedTransformList.cs new file mode 100644 index 0000000..16248c9 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/CompareSharedTransformList.cs @@ -0,0 +1,35 @@ +namespace BehaviorDesigner.Runtime.Tasks.Unity.SharedVariables +{ + [TaskCategory("Unity/SharedVariable")] + [TaskDescription("Returns success if the variable value is equal to the compareTo value.")] + public class CompareSharedTransformList : Conditional + { + [Tooltip("The first variable to compare")] + public SharedTransformList variable; + [Tooltip("The variable to compare to")] + public SharedTransformList compareTo; + + public override TaskStatus OnUpdate() + { + if (variable.Value == null && compareTo.Value != null) + return TaskStatus.Failure; + if (variable.Value == null && compareTo.Value == null) + return TaskStatus.Success; + if (variable.Value.Count != compareTo.Value.Count) + return TaskStatus.Failure; + + for (int i = 0; i < variable.Value.Count; ++i) { + if (variable.Value[i] != compareTo.Value[i]) { + return TaskStatus.Failure; + } + } + return TaskStatus.Success; + } + + public override void OnReset() + { + variable = null; + compareTo = null; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/CompareSharedTransformList.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/CompareSharedTransformList.cs.meta new file mode 100644 index 0000000..a0dbf65 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/CompareSharedTransformList.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 8ea22243f4fc22946a0033142f3a2380 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/CompareSharedVector2.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/CompareSharedVector2.cs new file mode 100644 index 0000000..72892c5 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/CompareSharedVector2.cs @@ -0,0 +1,25 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.SharedVariables +{ + [TaskCategory("Unity/SharedVariable")] + [TaskDescription("Returns success if the variable value is equal to the compareTo value.")] + public class CompareSharedVector2 : Conditional + { + [Tooltip("The first variable to compare")] + public SharedVector2 variable; + [Tooltip("The variable to compare to")] + public SharedVector2 compareTo; + + public override TaskStatus OnUpdate() + { + return variable.Value.Equals(compareTo.Value) ? TaskStatus.Success : TaskStatus.Failure; + } + + public override void OnReset() + { + variable = Vector2.zero; + compareTo = Vector2.zero; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/CompareSharedVector2.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/CompareSharedVector2.cs.meta new file mode 100644 index 0000000..35f54c8 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/CompareSharedVector2.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: ce90fa6ac7a64b044936fa647e5f0e80 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/CompareSharedVector3.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/CompareSharedVector3.cs new file mode 100644 index 0000000..0b9e6ad --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/CompareSharedVector3.cs @@ -0,0 +1,25 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.SharedVariables +{ + [TaskCategory("Unity/SharedVariable")] + [TaskDescription("Returns success if the variable value is equal to the compareTo value.")] + public class CompareSharedVector3 : Conditional + { + [Tooltip("The first variable to compare")] + public SharedVector3 variable; + [Tooltip("The variable to compare to")] + public SharedVector3 compareTo; + + public override TaskStatus OnUpdate() + { + return variable.Value.Equals(compareTo.Value) ? TaskStatus.Success : TaskStatus.Failure; + } + + public override void OnReset() + { + variable = Vector3.zero; + compareTo = Vector3.zero; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/CompareSharedVector3.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/CompareSharedVector3.cs.meta new file mode 100644 index 0000000..7aba52d --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/CompareSharedVector3.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 617192db87511d844940d400c960d13d +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/CompareSharedVector4.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/CompareSharedVector4.cs new file mode 100644 index 0000000..8085c55 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/CompareSharedVector4.cs @@ -0,0 +1,25 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.SharedVariables +{ + [TaskCategory("Unity/SharedVariable")] + [TaskDescription("Returns success if the variable value is equal to the compareTo value.")] + public class CompareSharedVector4 : Conditional + { + [Tooltip("The first variable to compare")] + public SharedVector4 variable; + [Tooltip("The variable to compare to")] + public SharedVector4 compareTo; + + public override TaskStatus OnUpdate() + { + return variable.Value.Equals(compareTo.Value) ? TaskStatus.Success : TaskStatus.Failure; + } + + public override void OnReset() + { + variable = Vector4.zero; + compareTo = Vector4.zero; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/CompareSharedVector4.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/CompareSharedVector4.cs.meta new file mode 100644 index 0000000..e58a57f --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/CompareSharedVector4.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 9738be23ad39d2c4ba8adc018b545ece +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/SetSharedBool.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/SetSharedBool.cs new file mode 100644 index 0000000..70643f0 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/SetSharedBool.cs @@ -0,0 +1,26 @@ +namespace BehaviorDesigner.Runtime.Tasks.Unity.SharedVariables +{ + [TaskCategory("Unity/SharedVariable")] + [TaskDescription("Sets the SharedBool variable to the specified object. Returns Success.")] + public class SetSharedBool : Action + { + [Tooltip("The value to set the SharedBool to")] + public SharedBool targetValue; + [RequiredField] + [Tooltip("The SharedBool to set")] + public SharedBool targetVariable; + + public override TaskStatus OnUpdate() + { + targetVariable.Value = targetValue.Value; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetValue = false; + targetVariable = false; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/SetSharedBool.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/SetSharedBool.cs.meta new file mode 100644 index 0000000..0e79bf5 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/SetSharedBool.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 54f63c79d78692a4e84e502f7cd705a6 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/SetSharedColor.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/SetSharedColor.cs new file mode 100644 index 0000000..663e69e --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/SetSharedColor.cs @@ -0,0 +1,28 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.SharedVariables +{ + [TaskCategory("Unity/SharedVariable")] + [TaskDescription("Sets the SharedColor variable to the specified object. Returns Success.")] + public class SetSharedColor : Action + { + [Tooltip("The value to set the SharedColor to")] + public SharedColor targetValue; + [RequiredField] + [Tooltip("The SharedColor to set")] + public SharedColor targetVariable; + + public override TaskStatus OnUpdate() + { + targetVariable.Value = targetValue.Value; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetValue = Color.black; + targetVariable = Color.black; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/SetSharedColor.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/SetSharedColor.cs.meta new file mode 100644 index 0000000..1e0b216 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/SetSharedColor.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 48c49264be0e7244ba46b8c970027a20 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/SetSharedFloat.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/SetSharedFloat.cs new file mode 100644 index 0000000..9d6df7e --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/SetSharedFloat.cs @@ -0,0 +1,26 @@ +namespace BehaviorDesigner.Runtime.Tasks.Unity.SharedVariables +{ + [TaskCategory("Unity/SharedVariable")] + [TaskDescription("Sets the SharedFloat variable to the specified object. Returns Success.")] + public class SetSharedFloat : Action + { + [Tooltip("The value to set the SharedFloat to")] + public SharedFloat targetValue; + [RequiredField] + [Tooltip("The SharedFloat to set")] + public SharedFloat targetVariable; + + public override TaskStatus OnUpdate() + { + targetVariable.Value = targetValue.Value; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetValue = 0; + targetVariable = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/SetSharedFloat.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/SetSharedFloat.cs.meta new file mode 100644 index 0000000..837ae1b --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/SetSharedFloat.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 4d5b15c88fb154446b9b1ad90cb3987f +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/SetSharedGameObject.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/SetSharedGameObject.cs new file mode 100644 index 0000000..a6fd5e6 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/SetSharedGameObject.cs @@ -0,0 +1,29 @@ +namespace BehaviorDesigner.Runtime.Tasks.Unity.SharedVariables +{ + [TaskCategory("Unity/SharedVariable")] + [TaskDescription("Sets the SharedGameObject variable to the specified object. Returns Success.")] + public class SetSharedGameObject : Action + { + [Tooltip("The value to set the SharedGameObject to. If null the variable will be set to the current GameObject")] + public SharedGameObject targetValue; + [RequiredField] + [Tooltip("The SharedGameObject to set")] + public SharedGameObject targetVariable; + [Tooltip("Can the target value be null?")] + public SharedBool valueCanBeNull; + + public override TaskStatus OnUpdate() + { + targetVariable.Value = ((targetValue.Value != null || valueCanBeNull.Value) ? targetValue.Value : gameObject); + + return TaskStatus.Success; + } + + public override void OnReset() + { + valueCanBeNull = false; + targetValue = null; + targetVariable = null; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/SetSharedGameObject.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/SetSharedGameObject.cs.meta new file mode 100644 index 0000000..882c5a7 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/SetSharedGameObject.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: bf4af224a0ebd5946bc4f01f18d0627b +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/SetSharedGameObjectList.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/SetSharedGameObjectList.cs new file mode 100644 index 0000000..f71bef4 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/SetSharedGameObjectList.cs @@ -0,0 +1,26 @@ +namespace BehaviorDesigner.Runtime.Tasks.Unity.SharedVariables +{ + [TaskCategory("Unity/SharedVariable")] + [TaskDescription("Sets the SharedGameObjectList variable to the specified object. Returns Success.")] + public class SetSharedGameObjectList : Action + { + [Tooltip("The value to set the SharedGameObjectList to.")] + public SharedGameObjectList targetValue; + [RequiredField] + [Tooltip("The SharedGameObjectList to set")] + public SharedGameObjectList targetVariable; + + public override TaskStatus OnUpdate() + { + targetVariable.Value = targetValue.Value; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetValue = null; + targetVariable = null; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/SetSharedGameObjectList.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/SetSharedGameObjectList.cs.meta new file mode 100644 index 0000000..658c20c --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/SetSharedGameObjectList.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: b02b163c1dc1b894ca53f80378e39b26 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/SetSharedInt.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/SetSharedInt.cs new file mode 100644 index 0000000..b62b2a9 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/SetSharedInt.cs @@ -0,0 +1,26 @@ +namespace BehaviorDesigner.Runtime.Tasks.Unity.SharedVariables +{ + [TaskCategory("Unity/SharedVariable")] + [TaskDescription("Sets the SharedInt variable to the specified object. Returns Success.")] + public class SetSharedInt : Action + { + [Tooltip("The value to set the SharedInt to")] + public SharedInt targetValue; + [RequiredField] + [Tooltip("The SharedInt to set")] + public SharedInt targetVariable; + + public override TaskStatus OnUpdate() + { + targetVariable.Value = targetValue.Value; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetValue = 0; + targetVariable = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/SetSharedInt.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/SetSharedInt.cs.meta new file mode 100644 index 0000000..fb59443 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/SetSharedInt.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 742d2b1426f291e45b03bcf845c53a67 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/SetSharedObject.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/SetSharedObject.cs new file mode 100644 index 0000000..b6711fc --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/SetSharedObject.cs @@ -0,0 +1,26 @@ +namespace BehaviorDesigner.Runtime.Tasks.Unity.SharedVariables +{ + [TaskCategory("Unity/SharedVariable")] + [TaskDescription("Sets the SharedObject variable to the specified object. Returns Success.")] + public class SetSharedObject : Action + { + [Tooltip("The value to set the SharedObject to")] + public SharedObject targetValue; + [RequiredField] + [Tooltip("The SharedTransform to set")] + public SharedObject targetVariable; + + public override TaskStatus OnUpdate() + { + targetVariable.Value = targetValue.Value; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetValue = null; + targetVariable = null; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/SetSharedObject.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/SetSharedObject.cs.meta new file mode 100644 index 0000000..83c8474 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/SetSharedObject.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: f80da138a03cfdd4e98af96ed5f6681b +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/SetSharedObjectList.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/SetSharedObjectList.cs new file mode 100644 index 0000000..39ca4bb --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/SetSharedObjectList.cs @@ -0,0 +1,26 @@ +namespace BehaviorDesigner.Runtime.Tasks.Unity.SharedVariables +{ + [TaskCategory("Unity/SharedVariable")] + [TaskDescription("Sets the SharedObjectList variable to the specified object. Returns Success.")] + public class SetSharedObjectList : Action + { + [Tooltip("The value to set the SharedObjectList to.")] + public SharedObjectList targetValue; + [RequiredField] + [Tooltip("The SharedObjectList to set")] + public SharedObjectList targetVariable; + + public override TaskStatus OnUpdate() + { + targetVariable.Value = targetValue.Value; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetValue = null; + targetVariable = null; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/SetSharedObjectList.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/SetSharedObjectList.cs.meta new file mode 100644 index 0000000..72bc0cd --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/SetSharedObjectList.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: b5c211b64a2cf364e99b99dab3ce3c87 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/SetSharedQuaternion.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/SetSharedQuaternion.cs new file mode 100644 index 0000000..acca1c5 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/SetSharedQuaternion.cs @@ -0,0 +1,27 @@ +using UnityEngine; +namespace BehaviorDesigner.Runtime.Tasks.Unity.SharedVariables +{ + [TaskCategory("Unity/SharedVariable")] + [TaskDescription("Sets the SharedQuaternion variable to the specified object. Returns Success.")] + public class SetSharedQuaternion : Action + { + [Tooltip("The value to set the SharedQuaternion to")] + public SharedQuaternion targetValue; + [RequiredField] + [Tooltip("The SharedQuaternion to set")] + public SharedQuaternion targetVariable; + + public override TaskStatus OnUpdate() + { + targetVariable.Value = targetValue.Value; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetValue = Quaternion.identity; + targetVariable = Quaternion.identity; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/SetSharedQuaternion.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/SetSharedQuaternion.cs.meta new file mode 100644 index 0000000..17a5c96 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/SetSharedQuaternion.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 42f84705fc5571e4088098d1239b5f46 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/SetSharedRect.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/SetSharedRect.cs new file mode 100644 index 0000000..a598b81 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/SetSharedRect.cs @@ -0,0 +1,28 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.SharedVariables +{ + [TaskCategory("Unity/SharedVariable")] + [TaskDescription("Sets the SharedRect variable to the specified object. Returns Success.")] + public class SetSharedRect : Action + { + [Tooltip("The value to set the SharedRect to")] + public SharedRect targetValue; + [RequiredField] + [Tooltip("The SharedRect to set")] + public SharedRect targetVariable; + + public override TaskStatus OnUpdate() + { + targetVariable.Value = targetValue.Value; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetValue = new Rect(); + targetVariable = new Rect(); + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/SetSharedRect.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/SetSharedRect.cs.meta new file mode 100644 index 0000000..9120c8b --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/SetSharedRect.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 7313c7640a9d92b4294a7702b3c5339b +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/SetSharedString.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/SetSharedString.cs new file mode 100644 index 0000000..0c2c726 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/SetSharedString.cs @@ -0,0 +1,26 @@ +namespace BehaviorDesigner.Runtime.Tasks.Unity.SharedVariables +{ + [TaskCategory("Unity/SharedVariable")] + [TaskDescription("Sets the SharedString variable to the specified object. Returns Success.")] + public class SetSharedString : Action + { + [Tooltip("The value to set the SharedString to")] + public SharedString targetValue; + [RequiredField] + [Tooltip("The SharedString to set")] + public SharedString targetVariable; + + public override TaskStatus OnUpdate() + { + targetVariable.Value = targetValue.Value; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetValue = ""; + targetVariable = ""; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/SetSharedString.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/SetSharedString.cs.meta new file mode 100644 index 0000000..5600e88 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/SetSharedString.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 92060068b2f07c54f930e1b8a8976c11 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/SetSharedTransform.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/SetSharedTransform.cs new file mode 100644 index 0000000..c926294 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/SetSharedTransform.cs @@ -0,0 +1,26 @@ +namespace BehaviorDesigner.Runtime.Tasks.Unity.SharedVariables +{ + [TaskCategory("Unity/SharedVariable")] + [TaskDescription("Sets the SharedTransform variable to the specified object. Returns Success.")] + public class SetSharedTransform : Action + { + [Tooltip("The value to set the SharedTransform to. If null the variable will be set to the current Transform")] + public SharedTransform targetValue; + [RequiredField] + [Tooltip("The SharedTransform to set")] + public SharedTransform targetVariable; + + public override TaskStatus OnUpdate() + { + targetVariable.Value = (targetValue.Value != null ? targetValue.Value : transform); + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetValue = null; + targetVariable = null; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/SetSharedTransform.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/SetSharedTransform.cs.meta new file mode 100644 index 0000000..0b1e17d --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/SetSharedTransform.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 78e7da45e8b6c2e4cbbf4fdf474070e5 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/SetSharedTransformList.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/SetSharedTransformList.cs new file mode 100644 index 0000000..198fef2 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/SetSharedTransformList.cs @@ -0,0 +1,26 @@ +namespace BehaviorDesigner.Runtime.Tasks.Unity.SharedVariables +{ + [TaskCategory("Unity/SharedVariable")] + [TaskDescription("Sets the SharedTransformList variable to the specified object. Returns Success.")] + public class SetSharedTransformList : Action + { + [Tooltip("The value to set the SharedTransformList to.")] + public SharedTransformList targetValue; + [RequiredField] + [Tooltip("The SharedTransformList to set")] + public SharedTransformList targetVariable; + + public override TaskStatus OnUpdate() + { + targetVariable.Value = targetValue.Value; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetValue = null; + targetVariable = null; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/SetSharedTransformList.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/SetSharedTransformList.cs.meta new file mode 100644 index 0000000..b4aed39 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/SetSharedTransformList.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: fae9cd59e50283949a2cc8ec460ffafe +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/SetSharedVector2.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/SetSharedVector2.cs new file mode 100644 index 0000000..a2e67e8 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/SetSharedVector2.cs @@ -0,0 +1,28 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.SharedVariables +{ + [TaskCategory("Unity/SharedVariable")] + [TaskDescription("Sets the SharedVector2 variable to the specified object. Returns Success.")] + public class SetSharedVector2 : Action + { + [Tooltip("The value to set the SharedVector2 to")] + public SharedVector2 targetValue; + [RequiredField] + [Tooltip("The SharedVector2 to set")] + public SharedVector2 targetVariable; + + public override TaskStatus OnUpdate() + { + targetVariable.Value = targetValue.Value; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetValue = Vector2.zero; + targetVariable = Vector2.zero; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/SetSharedVector2.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/SetSharedVector2.cs.meta new file mode 100644 index 0000000..60ecf92 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/SetSharedVector2.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: c70cf248c723950409d74c11d0781c06 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/SetSharedVector3.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/SetSharedVector3.cs new file mode 100644 index 0000000..d8283ee --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/SetSharedVector3.cs @@ -0,0 +1,28 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.SharedVariables +{ + [TaskCategory("Unity/SharedVariable")] + [TaskDescription("Sets the SharedVector3 variable to the specified object. Returns Success.")] + public class SetSharedVector3 : Action + { + [Tooltip("The value to set the SharedVector3 to")] + public SharedVector3 targetValue; + [RequiredField] + [Tooltip("The SharedVector3 to set")] + public SharedVector3 targetVariable; + + public override TaskStatus OnUpdate() + { + targetVariable.Value = targetValue.Value; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetValue = Vector3.zero; + targetVariable = Vector3.zero; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/SetSharedVector3.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/SetSharedVector3.cs.meta new file mode 100644 index 0000000..80458f0 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/SetSharedVector3.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 281820e8b30038d48b4fa8f25728e6c3 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/SetSharedVector4.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/SetSharedVector4.cs new file mode 100644 index 0000000..83572d1 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/SetSharedVector4.cs @@ -0,0 +1,28 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.SharedVariables +{ + [TaskCategory("Unity/SharedVariable")] + [TaskDescription("Sets the SharedVector4 variable to the specified object. Returns Success.")] + public class SetSharedVector4 : Action + { + [Tooltip("The value to set the SharedVector4 to")] + public SharedVector4 targetValue; + [RequiredField] + [Tooltip("The SharedVector4 to set")] + public SharedVector4 targetVariable; + + public override TaskStatus OnUpdate() + { + targetVariable.Value = targetValue.Value; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetValue = Vector4.zero; + targetVariable = Vector4.zero; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/SetSharedVector4.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/SetSharedVector4.cs.meta new file mode 100644 index 0000000..fd20cfb --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/SetSharedVector4.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 5ca30d99da0685a4fa32d79624a5c0a0 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/SharedGameObjectToTransform.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/SharedGameObjectToTransform.cs new file mode 100644 index 0000000..28e8842 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/SharedGameObjectToTransform.cs @@ -0,0 +1,32 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.SharedVariables +{ + [TaskCategory("Unity/SharedVariable")] + [TaskDescription("Gets the Transform from the GameObject. Returns Success.")] + public class SharedGameObjectToTransform : Action + { + [Tooltip("The GameObject to get the Transform of")] + public SharedGameObject sharedGameObject; + [RequiredField] + [Tooltip("The Transform to set")] + public SharedTransform sharedTransform; + + public override TaskStatus OnUpdate() + { + if (sharedGameObject.Value == null) { + return TaskStatus.Failure; + } + + sharedTransform.Value = sharedGameObject.Value.GetComponent(); + + return TaskStatus.Success; + } + + public override void OnReset() + { + sharedGameObject = null; + sharedTransform = null; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/SharedGameObjectToTransform.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/SharedGameObjectToTransform.cs.meta new file mode 100644 index 0000000..c1d7e7b --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/SharedGameObjectToTransform.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: c08dcd1e915bef6448649ffe4d3bef3d +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/SharedGameObjectsToGameObjectList.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/SharedGameObjectsToGameObjectList.cs new file mode 100644 index 0000000..aadcfb6 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/SharedGameObjectsToGameObjectList.cs @@ -0,0 +1,41 @@ +using UnityEngine; +using System.Collections.Generic; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.SharedVariables +{ + [TaskCategory("Unity/SharedVariable")] + [TaskDescription("Sets the SharedGameObjectList values from the GameObjects. Returns Success.")] + public class SharedGameObjectsToGameObjectList : Action + { + [Tooltip("The GameObjects value")] + public SharedGameObject[] gameObjects; + [RequiredField] + [Tooltip("The SharedTransformList to set")] + public SharedGameObjectList storedGameObjectList; + + public override void OnAwake() + { + storedGameObjectList.Value = new List(); + } + + public override TaskStatus OnUpdate() + { + if (gameObjects == null || gameObjects.Length == 0) { + return TaskStatus.Failure; + } + + storedGameObjectList.Value.Clear(); + for (int i = 0; i < gameObjects.Length; ++i) { + storedGameObjectList.Value.Add(gameObjects[i].Value); + } + + return TaskStatus.Success; + } + + public override void OnReset() + { + gameObjects = null; + storedGameObjectList = null; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/SharedGameObjectsToGameObjectList.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/SharedGameObjectsToGameObjectList.cs.meta new file mode 100644 index 0000000..e912b24 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/SharedGameObjectsToGameObjectList.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 4460871f1a9671343896ef9e56d9ceab +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/SharedTransformToGameObject.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/SharedTransformToGameObject.cs new file mode 100644 index 0000000..a9d9e78 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/SharedTransformToGameObject.cs @@ -0,0 +1,32 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.SharedVariables +{ + [TaskCategory("Unity/SharedVariable")] + [TaskDescription("Gets the GameObject from the Transform component. Returns Success.")] + public class SharedTransformToGameObject : Action + { + [Tooltip("The Transform component")] + public SharedTransform sharedTransform; + [RequiredField] + [Tooltip("The GameObject to set")] + public SharedGameObject sharedGameObject; + + public override TaskStatus OnUpdate() + { + if (sharedTransform.Value == null) { + return TaskStatus.Failure; + } + + sharedGameObject.Value = sharedTransform.Value.gameObject; + + return TaskStatus.Success; + } + + public override void OnReset() + { + sharedTransform = null; + sharedGameObject = null; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/SharedTransformToGameObject.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/SharedTransformToGameObject.cs.meta new file mode 100644 index 0000000..e2ca55e --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/SharedTransformToGameObject.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: f2fd208ea1a8e1642a32148186f9e077 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/SharedTransformsToTransformList.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/SharedTransformsToTransformList.cs new file mode 100644 index 0000000..05d3c8c --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/SharedTransformsToTransformList.cs @@ -0,0 +1,41 @@ +using UnityEngine; +using System.Collections.Generic; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.SharedVariables +{ + [TaskCategory("Unity/SharedVariable")] + [TaskDescription("Sets the SharedTransformList values from the Transforms. Returns Success.")] + public class SharedTransformsToTransformList : Action + { + [Tooltip("The Transforms value")] + public SharedTransform[] transforms; + [RequiredField] + [Tooltip("The SharedTransformList to set")] + public SharedTransformList storedTransformList; + + public override void OnAwake() + { + storedTransformList.Value = new List(); + } + + public override TaskStatus OnUpdate() + { + if (transforms == null || transforms.Length == 0) { + return TaskStatus.Failure; + } + + storedTransformList.Value.Clear(); + for (int i = 0; i < transforms.Length; ++i) { + storedTransformList.Value.Add(transforms[i].Value); + } + + return TaskStatus.Success; + } + + public override void OnReset() + { + transforms = null; + storedTransformList = null; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/SharedTransformsToTransformList.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/SharedTransformsToTransformList.cs.meta new file mode 100644 index 0000000..400f9a4 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/SharedVariables/SharedTransformsToTransformList.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 3533c6733499e9446b1eae98c8fcaeea +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/SphereCollider.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/SphereCollider.meta new file mode 100644 index 0000000..330a861 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/SphereCollider.meta @@ -0,0 +1,4 @@ +fileFormatVersion: 2 +guid: 79bf48a44f2371244a34ff82aaeaaded +DefaultImporter: + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/SphereCollider/GetCenter.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/SphereCollider/GetCenter.cs new file mode 100644 index 0000000..a8626d2 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/SphereCollider/GetCenter.cs @@ -0,0 +1,44 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnitySphereCollider +{ + [TaskCategory("Unity/SphereCollider")] + [TaskDescription("Stores the center of the SphereCollider. Returns Success.")] + public class GetCenter : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The center of the SphereCollider")] + [RequiredField] + public SharedVector3 storeValue; + + private SphereCollider sphereCollider; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + sphereCollider = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (sphereCollider == null) { + Debug.LogWarning("SphereCollider is null"); + return TaskStatus.Failure; + } + + storeValue.Value = sphereCollider.center; + + return TaskStatus.Success; + } + + public override void OnReset() + { + storeValue = Vector3.zero; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/SphereCollider/GetCenter.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/SphereCollider/GetCenter.cs.meta new file mode 100644 index 0000000..c554278 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/SphereCollider/GetCenter.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: d95a2896b550c5b4382b7ed35860f504 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/SphereCollider/GetRadius.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/SphereCollider/GetRadius.cs new file mode 100644 index 0000000..3dc2809 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/SphereCollider/GetRadius.cs @@ -0,0 +1,45 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnitySphereCollider +{ + [TaskCategory("Unity/SphereCollider")] + [TaskDescription("Stores the radius of the SphereCollider. Returns Success.")] + public class GetRadius : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The radius of the SphereCollider")] + [RequiredField] + public SharedFloat storeValue; + + private SphereCollider sphereCollider; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + sphereCollider = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (sphereCollider == null) { + Debug.LogWarning("SphereCollider is null"); + return TaskStatus.Failure; + } + + storeValue.Value = sphereCollider.radius; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + storeValue = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/SphereCollider/GetRadius.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/SphereCollider/GetRadius.cs.meta new file mode 100644 index 0000000..19d0e86 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/SphereCollider/GetRadius.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 2ff93bf538eee1444b3c51aadfc9bb7f +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/SphereCollider/SetCenter.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/SphereCollider/SetCenter.cs new file mode 100644 index 0000000..718fd4f --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/SphereCollider/SetCenter.cs @@ -0,0 +1,44 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnitySphereCollider +{ + [TaskCategory("Unity/SphereCollider")] + [TaskDescription("Sets the center of the SphereCollider. Returns Success.")] + public class SetCenter : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The center of the SphereCollider")] + public SharedVector3 center; + + private SphereCollider sphereCollider; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + sphereCollider = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (sphereCollider == null) { + Debug.LogWarning("SphereCollider is null"); + return TaskStatus.Failure; + } + + sphereCollider.center = center.Value; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + center = Vector3.zero; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/SphereCollider/SetCenter.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/SphereCollider/SetCenter.cs.meta new file mode 100644 index 0000000..c8841b3 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/SphereCollider/SetCenter.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: dffebfe905e60814ab75e0d7c57432ec +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/SphereCollider/SetRadius.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/SphereCollider/SetRadius.cs new file mode 100644 index 0000000..0c2e2fc --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/SphereCollider/SetRadius.cs @@ -0,0 +1,44 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnitySphereCollider +{ + [TaskCategory("Unity/SphereCollider")] + [TaskDescription("Sets the radius of the SphereCollider. Returns Success.")] + public class SetRadius : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The radius of the SphereCollider")] + public SharedFloat radius; + + private SphereCollider sphereCollider; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + sphereCollider = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (sphereCollider == null) { + Debug.LogWarning("SphereCollider is null"); + return TaskStatus.Failure; + } + + sphereCollider.radius = radius.Value; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + radius = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/SphereCollider/SetRadius.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/SphereCollider/SetRadius.cs.meta new file mode 100644 index 0000000..0247437 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/SphereCollider/SetRadius.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 5f45a94e6b603f2498481f61218b1769 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/String.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/String.meta new file mode 100644 index 0000000..738cfb1 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/String.meta @@ -0,0 +1,4 @@ +fileFormatVersion: 2 +guid: f1fb420b7a56bfa4ebafed6237009045 +DefaultImporter: + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/String/BuildString.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/String/BuildString.cs new file mode 100644 index 0000000..884d4b1 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/String/BuildString.cs @@ -0,0 +1,28 @@ +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityString +{ + [TaskCategory("Unity/String")] + [TaskDescription("Creates a string from multiple other strings.")] + public class BuildString : Action + { + [Tooltip("The array of strings")] + public SharedString[] source; + [Tooltip("The stored result")] + [RequiredField] + public SharedString storeResult; + + public override TaskStatus OnUpdate() + { + for (int i = 0; i < source.Length; ++i) { + storeResult.Value += source[i]; + } + + return TaskStatus.Success; + } + + public override void OnReset() + { + source = null; + storeResult = null; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/String/BuildString.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/String/BuildString.cs.meta new file mode 100644 index 0000000..bcfbe7e --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/String/BuildString.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 9373af75c434e1a4784c2a165ad3ce3b +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/String/CompareTo.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/String/CompareTo.cs new file mode 100644 index 0000000..92448f6 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/String/CompareTo.cs @@ -0,0 +1,28 @@ +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityString +{ + [TaskCategory("Unity/String")] + [TaskDescription("Compares the first string to the second string. Returns an int which indicates whether the first string precedes, matches, or follows the second string.")] + public class CompareTo : Action + { + [Tooltip("The string to compare")] + public SharedString firstString; + [Tooltip("The string to compare to")] + public SharedString secondString; + [Tooltip("The stored result")] + [RequiredField] + public SharedInt storeResult; + + public override TaskStatus OnUpdate() + { + storeResult.Value = firstString.Value.CompareTo(secondString.Value); + return TaskStatus.Success; + } + + public override void OnReset() + { + firstString = ""; + secondString = ""; + storeResult = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/String/CompareTo.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/String/CompareTo.cs.meta new file mode 100644 index 0000000..ed37dd2 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/String/CompareTo.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: c752378530d87cb4c98ba15e55936abf +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/String/Format.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/String/Format.cs new file mode 100644 index 0000000..02d899b --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/String/Format.cs @@ -0,0 +1,47 @@ +using UnityEngine; +using System; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityString +{ + [TaskCategory("Unity/String")] + [TaskDescription("Stores a string with the specified format.")] + public class Format : Action + { + [Tooltip("The format of the string")] + public SharedString format; + [Tooltip("Any variables to appear in the string")] + public SharedGenericVariable[] variables; + [Tooltip("The result of the format")] + [RequiredField] + public SharedString storeResult; + + private object[] variableValues; + + public override void OnAwake() + { + variableValues = new object[variables.Length]; + } + + public override TaskStatus OnUpdate() + { + for (int i = 0; i < variableValues.Length; ++i) { + variableValues[i] = variables[i].Value.value.GetValue(); + } + + try { + storeResult.Value = string.Format(format.Value, variableValues); + } catch (Exception e) { + Debug.LogError(e.Message); + return TaskStatus.Failure; + } + return TaskStatus.Success; + } + + public override void OnReset() + { + format = ""; + variables = null; + storeResult = null; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/String/Format.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/String/Format.cs.meta new file mode 100644 index 0000000..39b8c09 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/String/Format.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: d96c5da37483da346b96ef02fde824cb +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/String/GetLength.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/String/GetLength.cs new file mode 100644 index 0000000..82dfed2 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/String/GetLength.cs @@ -0,0 +1,25 @@ +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityString +{ + [TaskCategory("Unity/String")] + [TaskDescription("Stores the length of the string")] + public class GetLength : Action + { + [Tooltip("The target string")] + public SharedString targetString; + [Tooltip("The stored result")] + [RequiredField] + public SharedInt storeResult; + + public override TaskStatus OnUpdate() + { + storeResult.Value = targetString.Value.Length; + return TaskStatus.Success; + } + + public override void OnReset() + { + targetString = ""; + storeResult = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/String/GetLength.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/String/GetLength.cs.meta new file mode 100644 index 0000000..75ecf6e --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/String/GetLength.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 5ab3e7e038a50c14f9fa0b019399f3be +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/String/GetRandomString.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/String/GetRandomString.cs new file mode 100644 index 0000000..8cf9760 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/String/GetRandomString.cs @@ -0,0 +1,28 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityString +{ + [TaskCategory("Unity/String")] + [TaskDescription("Randomly selects a string from the array of strings.")] + public class GetRandomString : Action + { + [Tooltip("The array of strings")] + public SharedString[] source; + [Tooltip("The stored result")] + [RequiredField] + public SharedString storeResult; + + public override TaskStatus OnUpdate() + { + storeResult.Value = source[Random.Range(0, source.Length)].Value; + + return TaskStatus.Success; + } + + public override void OnReset() + { + source = null; + storeResult = null; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/String/GetRandomString.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/String/GetRandomString.cs.meta new file mode 100644 index 0000000..cb729d5 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/String/GetRandomString.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 355abdec2d73d2545b16d5e0d5f4c589 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/String/GetSubstring.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/String/GetSubstring.cs new file mode 100644 index 0000000..56db623 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/String/GetSubstring.cs @@ -0,0 +1,35 @@ +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityString +{ + [TaskCategory("Unity/String")] + [TaskDescription("Stores a substring of the target string")] + public class GetSubstring : Action + { + [Tooltip("The target string")] + public SharedString targetString; + [Tooltip("The start substring index")] + public SharedInt startIndex = 0; + [Tooltip("The length of the substring. Don't use if -1")] + public SharedInt length = -1; + [Tooltip("The stored result")] + [RequiredField] + public SharedString storeResult; + + public override TaskStatus OnUpdate() + { + if (length.Value != -1) { + storeResult.Value = targetString.Value.Substring(startIndex.Value, length.Value); + } else { + storeResult.Value = targetString.Value.Substring(startIndex.Value); + } + return TaskStatus.Success; + } + + public override void OnReset() + { + targetString = ""; + startIndex = 0; + length = -1; + storeResult = ""; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/String/GetSubstring.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/String/GetSubstring.cs.meta new file mode 100644 index 0000000..c7d84bf --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/String/GetSubstring.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 6ce20430f88c32b418f29b42531eca4a +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/String/IsNullOrEmpty.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/String/IsNullOrEmpty.cs new file mode 100644 index 0000000..4f91f74 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/String/IsNullOrEmpty.cs @@ -0,0 +1,20 @@ +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityString +{ + [TaskCategory("Unity/String")] + [TaskDescription("Returns success if the string is null or empty")] + public class IsNullOrEmpty : Conditional + { + [Tooltip("The target string")] + public SharedString targetString; + + public override TaskStatus OnUpdate() + { + return string.IsNullOrEmpty(targetString.Value) ? TaskStatus.Success : TaskStatus.Failure; + } + + public override void OnReset() + { + targetString = ""; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/String/IsNullOrEmpty.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/String/IsNullOrEmpty.cs.meta new file mode 100644 index 0000000..f5c1b67 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/String/IsNullOrEmpty.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: f6f4d4c690c09bb48a388f36f4e30245 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/String/Replace.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/String/Replace.cs new file mode 100644 index 0000000..86fd98d --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/String/Replace.cs @@ -0,0 +1,32 @@ +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityString +{ + [TaskCategory("Unity/String")] + [TaskDescription("Replaces a string with the new string")] + public class Replace : Action + { + [Tooltip("The target string")] + public SharedString targetString; + [Tooltip("The old replace")] + public SharedString oldString; + [Tooltip("The new string")] + public SharedString newString; + [Tooltip("The stored result")] + [RequiredField] + public SharedString storeResult; + + public override TaskStatus OnUpdate() + { + storeResult.Value = targetString.Value.Replace(oldString.Value, newString.Value); + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetString = ""; + oldString = ""; + newString = ""; + storeResult = ""; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/String/Replace.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/String/Replace.cs.meta new file mode 100644 index 0000000..f75ac06 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/String/Replace.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 30fc7adfdddc39245a433ea477c01adf +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/String/SetString.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/String/SetString.cs new file mode 100644 index 0000000..96060db --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/String/SetString.cs @@ -0,0 +1,26 @@ +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityString +{ + [TaskCategory("Unity/String")] + [TaskDescription("Sets the variable string to the value string.")] + public class SetString : Action + { + [Tooltip("The target string")] + [RequiredField] + public SharedString variable; + [Tooltip("The value string")] + public SharedString value; + + public override TaskStatus OnUpdate() + { + variable.Value = value.Value; + + return TaskStatus.Success; + } + + public override void OnReset() + { + variable = ""; + value = ""; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/String/SetString.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/String/SetString.cs.meta new file mode 100644 index 0000000..7b9a5ae --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/String/SetString.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: da59105cbc94b5d4da3c805897f4a099 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Time.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Time.meta new file mode 100644 index 0000000..e59fe44 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Time.meta @@ -0,0 +1,4 @@ +fileFormatVersion: 2 +guid: d8d2d4d347504b146a2c930a2b806d71 +DefaultImporter: + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Time/GetDeltaTime.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Time/GetDeltaTime.cs new file mode 100644 index 0000000..0a8e5f5 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Time/GetDeltaTime.cs @@ -0,0 +1,23 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityTime +{ + [TaskCategory("Unity/Time")] + [TaskDescription("Returns the time in seconds it took to complete the last frame.")] + public class GetDeltaTime : Action + { + [Tooltip("The variable to store the result")] + public SharedFloat storeResult; + + public override TaskStatus OnUpdate() + { + storeResult.Value = Time.deltaTime; + return TaskStatus.Success; + } + + public override void OnReset() + { + storeResult = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Time/GetDeltaTime.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Time/GetDeltaTime.cs.meta new file mode 100644 index 0000000..50f235e --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Time/GetDeltaTime.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: d9d47b1b40fc1214298a3f6bfdc37e87 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Time/GetRealtimeSinceStartup.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Time/GetRealtimeSinceStartup.cs new file mode 100644 index 0000000..43bd70b --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Time/GetRealtimeSinceStartup.cs @@ -0,0 +1,23 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityTime +{ + [TaskCategory("Unity/Time")] + [TaskDescription("Returns the real time in seconds since the game started.")] + public class GetRealtimeSinceStartup : Action + { + [Tooltip("The variable to store the result")] + public SharedFloat storeResult; + + public override TaskStatus OnUpdate() + { + storeResult.Value = Time.realtimeSinceStartup; + return TaskStatus.Success; + } + + public override void OnReset() + { + storeResult = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Time/GetRealtimeSinceStartup.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Time/GetRealtimeSinceStartup.cs.meta new file mode 100644 index 0000000..56813be --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Time/GetRealtimeSinceStartup.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: c265b103d220b0e4fa45138fcd605f62 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Time/GetTime.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Time/GetTime.cs new file mode 100644 index 0000000..3bae770 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Time/GetTime.cs @@ -0,0 +1,23 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityTime +{ + [TaskCategory("Unity/Time")] + [TaskDescription("Returns the time in second since the start of the game.")] + public class GetTime : Action + { + [Tooltip("The variable to store the result")] + public SharedFloat storeResult; + + public override TaskStatus OnUpdate() + { + storeResult.Value = Time.time; + return TaskStatus.Success; + } + + public override void OnReset() + { + storeResult = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Time/GetTime.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Time/GetTime.cs.meta new file mode 100644 index 0000000..7147cb3 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Time/GetTime.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 5afd2ca3dda059243bf7a9156438475e +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Time/GetTimeScale.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Time/GetTimeScale.cs new file mode 100644 index 0000000..4df0525 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Time/GetTimeScale.cs @@ -0,0 +1,23 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityTime +{ + [TaskCategory("Unity/Time")] + [TaskDescription("Returns the scale at which time is passing.")] + public class GetTimeScale : Action + { + [Tooltip("The variable to store the result")] + public SharedFloat storeResult; + + public override TaskStatus OnUpdate() + { + storeResult.Value = Time.timeScale; + return TaskStatus.Success; + } + + public override void OnReset() + { + storeResult = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Time/GetTimeScale.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Time/GetTimeScale.cs.meta new file mode 100644 index 0000000..676cccb --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Time/GetTimeScale.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 79be8ba43b4c1db468d2476318e7e71a +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Time/SetTimeScale.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Time/SetTimeScale.cs new file mode 100644 index 0000000..d315b19 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Time/SetTimeScale.cs @@ -0,0 +1,23 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityTime +{ + [TaskCategory("Unity/Time")] + [TaskDescription("Sets the scale at which time is passing.")] + public class SetTimeScale : Action + { + [Tooltip("The timescale")] + public SharedFloat timeScale; + + public override TaskStatus OnUpdate() + { + Time.timeScale = timeScale.Value; + return TaskStatus.Success; + } + + public override void OnReset() + { + timeScale.Value = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Time/SetTimeScale.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Time/SetTimeScale.cs.meta new file mode 100644 index 0000000..1e7ea59 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Time/SetTimeScale.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 6283d9f4bb690c64b9d986b6ff1271f0 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Timeline.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Timeline.meta new file mode 100644 index 0000000..0ceb76a --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Timeline.meta @@ -0,0 +1,9 @@ +fileFormatVersion: 2 +guid: 50e6b8a5d6bb9cb49957395165f737a7 +folderAsset: yes +timeCreated: 1519216643 +licenseType: Store +DefaultImporter: + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Timeline/IsPaused.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Timeline/IsPaused.cs new file mode 100644 index 0000000..f502f08 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Timeline/IsPaused.cs @@ -0,0 +1,40 @@ +using UnityEngine; +using UnityEngine.Playables; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.Timeline +{ + [TaskCategory("Unity/Timeline")] + [TaskDescription("Is the timeline currently paused?")] + public class IsPaused : Conditional + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + + private PlayableDirector playableDirector; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + playableDirector = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (playableDirector == null) { + Debug.LogWarning("PlayableDirector is null"); + return TaskStatus.Failure; + } + + return playableDirector.state == PlayState.Paused ? TaskStatus.Success : TaskStatus.Failure; + } + + public override void OnReset() + { + targetGameObject = null; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Timeline/IsPaused.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Timeline/IsPaused.cs.meta new file mode 100644 index 0000000..61d3253 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Timeline/IsPaused.cs.meta @@ -0,0 +1,12 @@ +fileFormatVersion: 2 +guid: 52231614084966e4ea648e3293e3de67 +timeCreated: 1519216674 +licenseType: Store +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Timeline/IsPlaying.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Timeline/IsPlaying.cs new file mode 100644 index 0000000..bf1331b --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Timeline/IsPlaying.cs @@ -0,0 +1,40 @@ +using UnityEngine; +using UnityEngine.Playables; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.Timeline +{ + [TaskCategory("Unity/Timeline")] + [TaskDescription("Is the timeline currently playing?")] + public class IsPlaying : Conditional + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + + private PlayableDirector playableDirector; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + playableDirector = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (playableDirector == null) { + Debug.LogWarning("PlayableDirector is null"); + return TaskStatus.Failure; + } + + return playableDirector.state == PlayState.Playing ? TaskStatus.Success : TaskStatus.Failure; + } + + public override void OnReset() + { + targetGameObject = null; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Timeline/IsPlaying.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Timeline/IsPlaying.cs.meta new file mode 100644 index 0000000..fe9e574 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Timeline/IsPlaying.cs.meta @@ -0,0 +1,12 @@ +fileFormatVersion: 2 +guid: 61a5af2ddf414484cb4f4048f2342c4f +timeCreated: 1519216674 +licenseType: Store +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Timeline/Pause.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Timeline/Pause.cs new file mode 100644 index 0000000..449aa24 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Timeline/Pause.cs @@ -0,0 +1,42 @@ +using UnityEngine; +using UnityEngine.Playables; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.Timeline +{ + [TaskCategory("Unity/Timeline")] + [TaskDescription("Pauses playback of the currently running playable.")] + public class Pause : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + + private PlayableDirector playableDirector; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + playableDirector = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (playableDirector == null) { + Debug.LogWarning("PlayableDirector is null"); + return TaskStatus.Failure; + } + + playableDirector.Pause(); + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Timeline/Pause.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Timeline/Pause.cs.meta new file mode 100644 index 0000000..2f844ee --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Timeline/Pause.cs.meta @@ -0,0 +1,12 @@ +fileFormatVersion: 2 +guid: 158fd9e1af5fac248913c0f749720737 +timeCreated: 1519216674 +licenseType: Store +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Timeline/Play.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Timeline/Play.cs new file mode 100644 index 0000000..b1ab42e --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Timeline/Play.cs @@ -0,0 +1,62 @@ +using UnityEngine; +using UnityEngine.Playables; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.Timeline +{ + [TaskCategory("Unity/Timeline")] + [TaskDescription("Instatiates a Playable using the provided PlayableAsset and starts playback.")] + public class Play : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("An asset to instantiate a playable from.")] + public PlayableAsset playableAsset; + [Tooltip("Should the task be stopped when the timeline has stopped playing?")] + public SharedBool stopWhenComplete; + + private PlayableDirector playableDirector; + private GameObject prevGameObject; + private bool playbackStarted; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + playableDirector = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + playbackStarted = false; + } + + public override TaskStatus OnUpdate() + { + if (playableDirector == null) { + Debug.LogWarning("PlayableDirector is null"); + return TaskStatus.Failure; + } + + if (playbackStarted) { + if (stopWhenComplete.Value && playableDirector.state == PlayState.Playing) { + return TaskStatus.Running; + } + return TaskStatus.Success; + } + + if (playableAsset == null) { + playableDirector.Play(); + } else { + playableDirector.Play(playableAsset); + } + playbackStarted = true; + + return stopWhenComplete.Value ? TaskStatus.Running : TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + playableAsset = null; + stopWhenComplete = false; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Timeline/Play.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Timeline/Play.cs.meta new file mode 100644 index 0000000..4902f96 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Timeline/Play.cs.meta @@ -0,0 +1,12 @@ +fileFormatVersion: 2 +guid: 3268be37f87a5134e8c90f65a338172e +timeCreated: 1519216674 +licenseType: Store +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Timeline/Resume.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Timeline/Resume.cs new file mode 100644 index 0000000..c665f53 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Timeline/Resume.cs @@ -0,0 +1,55 @@ +using UnityEngine; +using UnityEngine.Playables; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.Timeline +{ + [TaskCategory("Unity/Timeline")] + [TaskDescription("Resume playing a paused playable.")] + public class Resume : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("Should the task be stopped when the timeline has stopped playing?")] + public SharedBool stopWhenComplete; + + private PlayableDirector playableDirector; + private GameObject prevGameObject; + private bool playbackStarted; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + playableDirector = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + playbackStarted = false; + } + + public override TaskStatus OnUpdate() + { + if (playableDirector == null) { + Debug.LogWarning("PlayableDirector is null"); + return TaskStatus.Failure; + } + + if (playbackStarted) { + if (stopWhenComplete.Value && playableDirector.state == PlayState.Playing) { + return TaskStatus.Running; + } + return TaskStatus.Success; + } + + playableDirector.Resume(); + playbackStarted = true; + + return stopWhenComplete.Value ? TaskStatus.Running : TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + stopWhenComplete = false; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Timeline/Resume.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Timeline/Resume.cs.meta new file mode 100644 index 0000000..cf41f61 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Timeline/Resume.cs.meta @@ -0,0 +1,12 @@ +fileFormatVersion: 2 +guid: 08ea323394eb79c48a2aa692cb4e82ac +timeCreated: 1519216674 +licenseType: Store +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Timeline/Stop.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Timeline/Stop.cs new file mode 100644 index 0000000..7331267 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Timeline/Stop.cs @@ -0,0 +1,42 @@ +using UnityEngine; +using UnityEngine.Playables; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.Timeline +{ + [TaskCategory("Unity/Timeline")] + [TaskDescription("Stops playback of the current Playable and destroys the corresponding graph.")] + public class Stop : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + + private PlayableDirector playableDirector; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + playableDirector = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (playableDirector == null) { + Debug.LogWarning("PlayableDirector is null"); + return TaskStatus.Failure; + } + + playableDirector.Stop(); + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Timeline/Stop.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Timeline/Stop.cs.meta new file mode 100644 index 0000000..193a7db --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Timeline/Stop.cs.meta @@ -0,0 +1,12 @@ +fileFormatVersion: 2 +guid: 7941758d54ddf364ca7b43af93da05ec +timeCreated: 1519216674 +licenseType: Store +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform.meta new file mode 100644 index 0000000..633ff13 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform.meta @@ -0,0 +1,4 @@ +fileFormatVersion: 2 +guid: d2f1ebdae5c7ffb4d8c7a9daa37b5130 +DefaultImporter: + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/Find.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/Find.cs new file mode 100644 index 0000000..2a8f893 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/Find.cs @@ -0,0 +1,48 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityTransform +{ + [TaskCategory("Unity/Transform")] + [TaskDescription("Finds a transform by name. Returns success if an object is found.")] + public class Find : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The transform name to find")] + public SharedString transformName; + [Tooltip("The object found by name")] + [RequiredField] + public SharedTransform storeValue; + + private Transform targetTransform; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + targetTransform = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (targetTransform == null) { + Debug.LogWarning("Transform is null"); + return TaskStatus.Failure; + } + + storeValue.Value = targetTransform.Find(transformName.Value); + + return storeValue.Value != null ? TaskStatus.Success : TaskStatus.Failure; + } + + public override void OnReset() + { + targetGameObject = null; + transformName = null; + storeValue = null; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/Find.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/Find.cs.meta new file mode 100644 index 0000000..089a623 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/Find.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 387fd22087393ab4e91f0ad4fce4e77f +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/GetAngleToTarget.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/GetAngleToTarget.cs new file mode 100644 index 0000000..370c2b0 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/GetAngleToTarget.cs @@ -0,0 +1,66 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityTransform +{ + [TaskCategory("Unity/Transform")] + [TaskDescription("Gets the Angle between a GameObject's forward direction and a target. Returns Success.")] + public class GetAngleToTarget : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The target object to measure the angle to. If null the targetPosition will be used.")] + public SharedGameObject targetObject; + [Tooltip("The world position to measure an angle to. If the targetObject is also not null, this value is used as an offset from that object's position.")] + public SharedVector3 targetPosition; + [Tooltip("Ignore height differences when calculating the angle?")] + public SharedBool ignoreHeight = true; + [Tooltip("The angle to the target")] + [RequiredField] + public SharedFloat storeValue; + + private Transform targetTransform; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + targetTransform = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (targetTransform == null) { + Debug.LogWarning("Transform is null"); + return TaskStatus.Failure; + } + + Vector3 targetPos; + if (targetObject.Value != null) { + targetPos = targetObject.Value.transform.InverseTransformPoint(targetPosition.Value); + } else { + targetPos = targetPosition.Value; + } + + if (ignoreHeight.Value) { + targetPos.y = targetTransform.position.y; + } + + var targetDir = targetPos - targetTransform.position; + storeValue.Value = Vector3.Angle(targetDir, targetTransform.forward); + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + targetObject = null; + targetPosition = Vector3.zero; + ignoreHeight = true; + storeValue = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/GetAngleToTarget.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/GetAngleToTarget.cs.meta new file mode 100644 index 0000000..0130aef --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/GetAngleToTarget.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: ae176a605fff9a2468198085313c26ad +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/GetChild.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/GetChild.cs new file mode 100644 index 0000000..9a12c8a --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/GetChild.cs @@ -0,0 +1,48 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityTransform +{ + [TaskCategory("Unity/Transform")] + [TaskDescription("Stores the transform child at the specified index. Returns Success.")] + public class GetChild : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The index of the child")] + public SharedInt index; + [Tooltip("The child of the Transform")] + [RequiredField] + public SharedTransform storeValue; + + private Transform targetTransform; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + targetTransform = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (targetTransform == null) { + Debug.LogWarning("Transform is null"); + return TaskStatus.Failure; + } + + storeValue.Value = targetTransform.GetChild(index.Value); + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + index = 0; + storeValue = null; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/GetChild.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/GetChild.cs.meta new file mode 100644 index 0000000..bd7309a --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/GetChild.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 04ea225bb12181a4daf7f3d6a21eaa5d +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/GetChildCount.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/GetChildCount.cs new file mode 100644 index 0000000..faa7a03 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/GetChildCount.cs @@ -0,0 +1,45 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityTransform +{ + [TaskCategory("Unity/Transform")] + [TaskDescription("Stores the number of children a Transform has. Returns Success.")] + public class GetChildCount : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The number of children")] + [RequiredField] + public SharedInt storeValue; + + private Transform targetTransform; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + targetTransform = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (targetTransform == null) { + Debug.LogWarning("Transform is null"); + return TaskStatus.Failure; + } + + storeValue.Value = targetTransform.childCount; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + storeValue = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/GetChildCount.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/GetChildCount.cs.meta new file mode 100644 index 0000000..66784af --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/GetChildCount.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 8e31c13112e4d334ab9d67feaac94d3f +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/GetEulerAngles.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/GetEulerAngles.cs new file mode 100644 index 0000000..f44f0f1 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/GetEulerAngles.cs @@ -0,0 +1,45 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityTransform +{ + [TaskCategory("Unity/Transform")] + [TaskDescription("Stores the euler angles of the Transform. Returns Success.")] + public class GetEulerAngles : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The euler angles of the Transform")] + [RequiredField] + public SharedVector3 storeValue; + + private Transform targetTransform; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + targetTransform = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (targetTransform == null) { + Debug.LogWarning("Transform is null"); + return TaskStatus.Failure; + } + + storeValue.Value = targetTransform.eulerAngles; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + storeValue = Vector3.zero; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/GetEulerAngles.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/GetEulerAngles.cs.meta new file mode 100644 index 0000000..1d635fb --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/GetEulerAngles.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 43295a23f5d9cb345ae408d5ac843b52 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/GetForwardVector.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/GetForwardVector.cs new file mode 100644 index 0000000..a98596d --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/GetForwardVector.cs @@ -0,0 +1,45 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityTransform +{ + [TaskCategory("Unity/Transform")] + [TaskDescription("Stores the forward vector of the Transform. Returns Success.")] + public class GetForwardVector : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The position of the Transform")] + [RequiredField] + public SharedVector3 storeValue; + + private Transform targetTransform; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + targetTransform = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (targetTransform == null) { + Debug.LogWarning("Transform is null"); + return TaskStatus.Failure; + } + + storeValue.Value = targetTransform.forward; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + storeValue = Vector3.zero; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/GetForwardVector.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/GetForwardVector.cs.meta new file mode 100644 index 0000000..e4ef77f --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/GetForwardVector.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: a5748c07a5ebe54429eb3e9ae032b5e2 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/GetLocalEulerAngles.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/GetLocalEulerAngles.cs new file mode 100644 index 0000000..fddd98b --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/GetLocalEulerAngles.cs @@ -0,0 +1,45 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityTransform +{ + [TaskCategory("Unity/Transform")] + [TaskDescription("Stores the local euler angles of the Transform. Returns Success.")] + public class GetLocalEulerAngles : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The local euler angles of the Transform")] + [RequiredField] + public SharedVector3 storeValue; + + private Transform targetTransform; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + targetTransform = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (targetTransform == null) { + Debug.LogWarning("Transform is null"); + return TaskStatus.Failure; + } + + storeValue.Value = targetTransform.localEulerAngles; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + storeValue = Vector3.zero; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/GetLocalEulerAngles.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/GetLocalEulerAngles.cs.meta new file mode 100644 index 0000000..640a7fb --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/GetLocalEulerAngles.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 459c793e1b836104f901813471414ccc +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/GetLocalPosition.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/GetLocalPosition.cs new file mode 100644 index 0000000..084b111 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/GetLocalPosition.cs @@ -0,0 +1,45 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityTransform +{ + [TaskCategory("Unity/Transform")] + [TaskDescription("Stores the local position of the Transform. Returns Success.")] + public class GetLocalPosition : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The local position of the Transform")] + [RequiredField] + public SharedVector3 storeValue; + + private Transform targetTransform; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + targetTransform = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (targetTransform == null) { + Debug.LogWarning("Transform is null"); + return TaskStatus.Failure; + } + + storeValue.Value = targetTransform.localPosition; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + storeValue = Vector3.zero; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/GetLocalPosition.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/GetLocalPosition.cs.meta new file mode 100644 index 0000000..73195a6 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/GetLocalPosition.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 4fdc0d751b2c91f438142cf65fcbba34 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/GetLocalRotation.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/GetLocalRotation.cs new file mode 100644 index 0000000..992c034 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/GetLocalRotation.cs @@ -0,0 +1,45 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityTransform +{ + [TaskCategory("Unity/Transform")] + [TaskDescription("Stores the local rotation of the Transform. Returns Success.")] + public class GetLocalRotation : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The local rotation of the Transform")] + [RequiredField] + public SharedQuaternion storeValue; + + private Transform targetTransform; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + targetTransform = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (targetTransform == null) { + Debug.LogWarning("Transform is null"); + return TaskStatus.Failure; + } + + storeValue.Value = targetTransform.localRotation; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + storeValue = Quaternion.identity; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/GetLocalRotation.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/GetLocalRotation.cs.meta new file mode 100644 index 0000000..c18aa76 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/GetLocalRotation.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 2334ddf0e58b67e40ad16e2f63dad8ee +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/GetLocalScale.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/GetLocalScale.cs new file mode 100644 index 0000000..efc187e --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/GetLocalScale.cs @@ -0,0 +1,45 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityTransform +{ + [TaskCategory("Unity/Transform")] + [TaskDescription("Stores the local scale of the Transform. Returns Success.")] + public class GetLocalScale : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The local scale of the Transform")] + [RequiredField] + public SharedVector3 storeValue; + + private Transform targetTransform; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + targetTransform = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (targetTransform == null) { + Debug.LogWarning("Transform is null"); + return TaskStatus.Failure; + } + + storeValue.Value = targetTransform.localScale; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + storeValue = Vector3.zero; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/GetLocalScale.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/GetLocalScale.cs.meta new file mode 100644 index 0000000..a8488d0 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/GetLocalScale.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: e0b10fe3fcda1914fbbdde4a860cd403 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/GetParent.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/GetParent.cs new file mode 100644 index 0000000..d29f7aa --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/GetParent.cs @@ -0,0 +1,45 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityTransform +{ + [TaskCategory("Unity/Transform")] + [TaskDescription("Stores the parent of the Transform. Returns Success.")] + public class GetParent : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The parent of the Transform")] + [RequiredField] + public SharedTransform storeValue; + + private Transform targetTransform; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + targetTransform = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (targetTransform == null) { + Debug.LogWarning("Transform is null"); + return TaskStatus.Failure; + } + + storeValue.Value = targetTransform.parent; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + storeValue = null; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/GetParent.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/GetParent.cs.meta new file mode 100644 index 0000000..48fa974 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/GetParent.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: f149245d8fce789498c301657a7eaf88 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/GetPosition.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/GetPosition.cs new file mode 100644 index 0000000..c5151fc --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/GetPosition.cs @@ -0,0 +1,45 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityTransform +{ + [TaskCategory("Unity/Transform")] + [TaskDescription("Stores the position of the Transform. Returns Success.")] + public class GetPosition : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("Can the target GameObject be empty?")] + [RequiredField] + public SharedVector3 storeValue; + + private Transform targetTransform; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + targetTransform = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (targetTransform == null) { + Debug.LogWarning("Transform is null"); + return TaskStatus.Failure; + } + + storeValue.Value = targetTransform.position; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + storeValue = Vector3.zero; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/GetPosition.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/GetPosition.cs.meta new file mode 100644 index 0000000..a633cf6 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/GetPosition.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 9ce1fdc3f652b3043b5116efba12cc48 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/GetRightVector.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/GetRightVector.cs new file mode 100644 index 0000000..4bc1b36 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/GetRightVector.cs @@ -0,0 +1,45 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityTransform +{ + [TaskCategory("Unity/Transform")] + [TaskDescription("Stores the right vector of the Transform. Returns Success.")] + public class GetRightVector : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The position of the Transform")] + [RequiredField] + public SharedVector3 storeValue; + + private Transform targetTransform; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + targetTransform = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (targetTransform == null) { + Debug.LogWarning("Transform is null"); + return TaskStatus.Failure; + } + + storeValue.Value = targetTransform.right; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + storeValue = Vector3.zero; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/GetRightVector.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/GetRightVector.cs.meta new file mode 100644 index 0000000..50452e1 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/GetRightVector.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 6b5147164f2674547888db24cba68770 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/GetRotation.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/GetRotation.cs new file mode 100644 index 0000000..bb1c439 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/GetRotation.cs @@ -0,0 +1,45 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityTransform +{ + [TaskCategory("Unity/Transform")] + [TaskDescription("Stores the rotation of the Transform. Returns Success.")] + public class GetRotation : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The rotation of the Transform")] + [RequiredField] + public SharedQuaternion storeValue; + + private Transform targetTransform; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + targetTransform = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (targetTransform == null) { + Debug.LogWarning("Transform is null"); + return TaskStatus.Failure; + } + + storeValue.Value = targetTransform.rotation; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + storeValue = Quaternion.identity; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/GetRotation.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/GetRotation.cs.meta new file mode 100644 index 0000000..c68d076 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/GetRotation.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 5384b69809f40f5489ca7d7d345471d2 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/GetUpVector.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/GetUpVector.cs new file mode 100644 index 0000000..abb5ef1 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/GetUpVector.cs @@ -0,0 +1,45 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityTransform +{ + [TaskCategory("Unity/Transform")] + [TaskDescription("Stores the up vector of the Transform. Returns Success.")] + public class GetUpVector : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The position of the Transform")] + [RequiredField] + public SharedVector3 storeValue; + + private Transform targetTransform; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + targetTransform = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (targetTransform == null) { + Debug.LogWarning("Transform is null"); + return TaskStatus.Failure; + } + + storeValue.Value = targetTransform.up; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + storeValue = Vector3.zero; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/GetUpVector.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/GetUpVector.cs.meta new file mode 100644 index 0000000..256776f --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/GetUpVector.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 605a7c93705031042be47bd4a4ab6079 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/IsChildOf.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/IsChildOf.cs new file mode 100644 index 0000000..f262593 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/IsChildOf.cs @@ -0,0 +1,42 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityTransform +{ + [TaskCategory("Unity/Transform")] + [TaskDescription("Returns Success if the transform is a child of the specified GameObject.")] + public class IsChildOf : Conditional + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The interested transform")] + public SharedTransform transformName; + + private Transform targetTransform; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + targetTransform = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (targetTransform == null) { + Debug.LogWarning("Transform is null"); + return TaskStatus.Failure; + } + + return targetTransform.IsChildOf(transformName.Value) ? TaskStatus.Success : TaskStatus.Failure; + } + + public override void OnReset() + { + targetGameObject = null; + transformName = null; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/IsChildOf.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/IsChildOf.cs.meta new file mode 100644 index 0000000..fe74bb1 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/IsChildOf.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 304e488eb1caa4f45a8bd903292492ca +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/LookAt.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/LookAt.cs new file mode 100644 index 0000000..a1ddca1 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/LookAt.cs @@ -0,0 +1,54 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityTransform +{ + [TaskCategory("Unity/Transform")] + [TaskDescription("Rotates the transform so the forward vector points at worldPosition. Returns Success.")] + public class LookAt : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The GameObject to look at. If null the world position will be used.")] + public SharedGameObject targetLookAt; + [Tooltip("Point to look at")] + public SharedVector3 worldPosition; + [Tooltip("Vector specifying the upward direction")] + public Vector3 worldUp; + + private Transform targetTransform; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + targetTransform = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (targetTransform == null) { + Debug.LogWarning("Transform is null"); + return TaskStatus.Failure; + } + + if (targetLookAt.Value != null) { + targetTransform.LookAt(targetLookAt.Value.transform); + } else { + targetTransform.LookAt(worldPosition.Value, worldUp); + } + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + targetLookAt = null; + worldPosition = Vector3.up; + worldUp = Vector3.up; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/LookAt.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/LookAt.cs.meta new file mode 100644 index 0000000..23a6c4b --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/LookAt.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 64883614392671f438244b3aa5b91c6c +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/Rotate.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/Rotate.cs new file mode 100644 index 0000000..8541527 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/Rotate.cs @@ -0,0 +1,47 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityTransform +{ + [TaskCategory("Unity/Transform")] + [TaskDescription("Applies a rotation. Returns Success.")] + public class Rotate : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("Amount to rotate")] + public SharedVector3 eulerAngles; + [Tooltip("Specifies which axis the rotation is relative to")] + public Space relativeTo = Space.Self; + + private Transform targetTransform; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + targetTransform = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (targetTransform == null) { + Debug.LogWarning("Transform is null"); + return TaskStatus.Failure; + } + + targetTransform.Rotate(eulerAngles.Value, relativeTo); + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + eulerAngles = Vector3.zero; + relativeTo = Space.Self; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/Rotate.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/Rotate.cs.meta new file mode 100644 index 0000000..f8d3495 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/Rotate.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: db0cba6372babb541a0da57412963760 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/RotateAround.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/RotateAround.cs new file mode 100644 index 0000000..b36fa3d --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/RotateAround.cs @@ -0,0 +1,50 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityTransform +{ + [TaskCategory("Unity/Transform")] + [TaskDescription("Applies a rotation. Returns Success.")] + public class RotateAround : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("Point to rotate around")] + public SharedVector3 point; + [Tooltip("Axis to rotate around")] + public SharedVector3 axis; + [Tooltip("Amount to rotate")] + public SharedFloat angle; + + private Transform targetTransform; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + targetTransform = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (targetTransform == null) { + Debug.LogWarning("Transform is null"); + return TaskStatus.Failure; + } + + targetTransform.RotateAround(point.Value, axis.Value, angle.Value); + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + point = Vector3.zero; + axis = Vector3.zero; + angle = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/RotateAround.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/RotateAround.cs.meta new file mode 100644 index 0000000..6bf5b16 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/RotateAround.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 65cef920fcc4ec449a1e6a29fe79c024 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/SetEulerAngles.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/SetEulerAngles.cs new file mode 100644 index 0000000..249c368 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/SetEulerAngles.cs @@ -0,0 +1,44 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityTransform +{ + [TaskCategory("Unity/Transform")] + [TaskDescription("Sets the euler angles of the Transform. Returns Success.")] + public class SetEulerAngles : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The euler angles of the Transform")] + public SharedVector3 eulerAngles; + + private Transform targetTransform; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + targetTransform = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (targetTransform == null) { + Debug.LogWarning("Transform is null"); + return TaskStatus.Failure; + } + + targetTransform.eulerAngles = eulerAngles.Value; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + eulerAngles = Vector3.zero; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/SetEulerAngles.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/SetEulerAngles.cs.meta new file mode 100644 index 0000000..3667157 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/SetEulerAngles.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: edad3f12ad10ba14aac656b7f431ff31 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/SetForwardVector.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/SetForwardVector.cs new file mode 100644 index 0000000..9c73691 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/SetForwardVector.cs @@ -0,0 +1,44 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityTransform +{ + [TaskCategory("Unity/Transform")] + [TaskDescription("Sets the forward vector of the Transform. Returns Success.")] + public class SetForwardVector : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The position of the Transform")] + public SharedVector3 position; + + private Transform targetTransform; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + targetTransform = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (targetTransform == null) { + Debug.LogWarning("Transform is null"); + return TaskStatus.Failure; + } + + targetTransform.forward = position.Value; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + position = Vector3.zero; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/SetForwardVector.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/SetForwardVector.cs.meta new file mode 100644 index 0000000..2ce239d --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/SetForwardVector.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 4cf669b5419d7294cb72c90881267c0c +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/SetLocalEulerAngles.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/SetLocalEulerAngles.cs new file mode 100644 index 0000000..9fd68c0 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/SetLocalEulerAngles.cs @@ -0,0 +1,44 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityTransform +{ + [TaskCategory("Unity/Transform")] + [TaskDescription("Sets the local euler angles of the Transform. Returns Success.")] + public class SetLocalEulerAngles : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The local euler angles of the Transform")] + public SharedVector3 localEulerAngles; + + private Transform targetTransform; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + targetTransform = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (targetTransform == null) { + Debug.LogWarning("Transform is null"); + return TaskStatus.Failure; + } + + targetTransform.localEulerAngles = localEulerAngles.Value; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + localEulerAngles = Vector3.zero; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/SetLocalEulerAngles.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/SetLocalEulerAngles.cs.meta new file mode 100644 index 0000000..71401d8 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/SetLocalEulerAngles.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 2e1ed691ebf9f154e88bb8be7319baad +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/SetLocalPosition.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/SetLocalPosition.cs new file mode 100644 index 0000000..7d276ae --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/SetLocalPosition.cs @@ -0,0 +1,44 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityTransform +{ + [TaskCategory("Unity/Transform")] + [TaskDescription("Sets the local position of the Transform. Returns Success.")] + public class SetLocalPosition : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The local position of the Transform")] + public SharedVector3 localPosition; + + private Transform targetTransform; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + targetTransform = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (targetTransform == null) { + Debug.LogWarning("Transform is null"); + return TaskStatus.Failure; + } + + targetTransform.localPosition = localPosition.Value; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + localPosition = Vector3.zero; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/SetLocalPosition.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/SetLocalPosition.cs.meta new file mode 100644 index 0000000..28893bb --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/SetLocalPosition.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 5af08673c7a3bb54c974bb23094d4587 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/SetLocalRotation.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/SetLocalRotation.cs new file mode 100644 index 0000000..a7ead69 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/SetLocalRotation.cs @@ -0,0 +1,44 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityTransform +{ + [TaskCategory("Unity/Transform")] + [TaskDescription("Sets the local rotation of the Transform. Returns Success.")] + public class SetLocalRotation : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The local rotation of the Transform")] + public SharedQuaternion localRotation; + + private Transform targetTransform; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + targetTransform = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (targetTransform == null) { + Debug.LogWarning("Transform is null"); + return TaskStatus.Failure; + } + + targetTransform.localRotation = localRotation.Value; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + localRotation = Quaternion.identity; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/SetLocalRotation.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/SetLocalRotation.cs.meta new file mode 100644 index 0000000..da3a3c9 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/SetLocalRotation.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: de22c6e6826367540b2f25957757a1d4 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/SetLocalScale.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/SetLocalScale.cs new file mode 100644 index 0000000..381f843 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/SetLocalScale.cs @@ -0,0 +1,44 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityTransform +{ + [TaskCategory("Unity/Transform")] + [TaskDescription("Sets the local scale of the Transform. Returns Success.")] + public class SetLocalScale : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The local scale of the Transform")] + public SharedVector3 localScale; + + private Transform targetTransform; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + targetTransform = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (targetTransform == null) { + Debug.LogWarning("Transform is null"); + return TaskStatus.Failure; + } + + targetTransform.localScale = localScale.Value; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + localScale = Vector3.zero; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/SetLocalScale.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/SetLocalScale.cs.meta new file mode 100644 index 0000000..c79102f --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/SetLocalScale.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 354ce71974ea2b44ab820c8285f72421 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/SetParent.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/SetParent.cs new file mode 100644 index 0000000..80e3f7d --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/SetParent.cs @@ -0,0 +1,44 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityTransform +{ + [TaskCategory("Unity/Transform")] + [TaskDescription("Sets the parent of the Transform. Returns Success.")] + public class SetParent : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The parent of the Transform")] + public SharedTransform parent; + + private Transform targetTransform; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + targetTransform = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (targetTransform == null) { + Debug.LogWarning("Transform is null"); + return TaskStatus.Failure; + } + + targetTransform.parent = parent.Value; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + parent = null; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/SetParent.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/SetParent.cs.meta new file mode 100644 index 0000000..91463e0 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/SetParent.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: a19c91d6c31b48d45b2ea97efeae14aa +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/SetPosition.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/SetPosition.cs new file mode 100644 index 0000000..250d78f --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/SetPosition.cs @@ -0,0 +1,44 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityTransform +{ + [TaskCategory("Unity/Transform")] + [TaskDescription("Sets the position of the Transform. Returns Success.")] + public class SetPosition : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The position of the Transform")] + public SharedVector3 position; + + private Transform targetTransform; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + targetTransform = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (targetTransform == null) { + Debug.LogWarning("Transform is null"); + return TaskStatus.Failure; + } + + targetTransform.position = position.Value; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + position = Vector3.zero; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/SetPosition.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/SetPosition.cs.meta new file mode 100644 index 0000000..363a016 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/SetPosition.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: d0586a5078618624398df51fd677a2e0 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/SetRightVector.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/SetRightVector.cs new file mode 100644 index 0000000..2d94fed --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/SetRightVector.cs @@ -0,0 +1,44 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityTransform +{ + [TaskCategory("Unity/Transform")] + [TaskDescription("Sets the right vector of the Transform. Returns Success.")] + public class SetRightVector : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The position of the Transform")] + public SharedVector3 position; + + private Transform targetTransform; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + targetTransform = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (targetTransform == null) { + Debug.LogWarning("Transform is null"); + return TaskStatus.Failure; + } + + targetTransform.right = position.Value; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + position = Vector3.zero; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/SetRightVector.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/SetRightVector.cs.meta new file mode 100644 index 0000000..41304d9 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/SetRightVector.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 4629bee77af22ca42a716dfa8ad3e669 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/SetRotation.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/SetRotation.cs new file mode 100644 index 0000000..76038c4 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/SetRotation.cs @@ -0,0 +1,44 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityTransform +{ + [TaskCategory("Unity/Transform")] + [TaskDescription("Sets the rotation of the Transform. Returns Success.")] + public class SetRotation : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The rotation of the Transform")] + public SharedQuaternion rotation; + + private Transform targetTransform; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + targetTransform = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (targetTransform == null) { + Debug.LogWarning("Transform is null"); + return TaskStatus.Failure; + } + + targetTransform.rotation = rotation.Value; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + rotation = Quaternion.identity; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/SetRotation.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/SetRotation.cs.meta new file mode 100644 index 0000000..97fc98d --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/SetRotation.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: fb61cc6175ff14c4d84c3c72541bc30d +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/SetUpVector.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/SetUpVector.cs new file mode 100644 index 0000000..d189524 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/SetUpVector.cs @@ -0,0 +1,44 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityTransform +{ + [TaskCategory("Unity/Transform")] + [TaskDescription("Sets the up vector of the Transform. Returns Success.")] + public class SetUpVector : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("The position of the Transform")] + public SharedVector3 position; + + private Transform targetTransform; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + targetTransform = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (targetTransform == null) { + Debug.LogWarning("Transform is null"); + return TaskStatus.Failure; + } + + targetTransform.up = position.Value; + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + position = Vector3.zero; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/SetUpVector.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/SetUpVector.cs.meta new file mode 100644 index 0000000..0e73cc6 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/SetUpVector.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 2e65dee462c24694a9835796a770af6e +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/Translate.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/Translate.cs new file mode 100644 index 0000000..439c83a --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/Translate.cs @@ -0,0 +1,47 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityTransform +{ + [TaskCategory("Unity/Transform")] + [TaskDescription("Moves the transform in the direction and distance of translation. Returns Success.")] + public class Translate : Action + { + [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] + public SharedGameObject targetGameObject; + [Tooltip("Move direction and distance")] + public SharedVector3 translation; + [Tooltip("Specifies which axis the rotation is relative to")] + public Space relativeTo = Space.Self; + + private Transform targetTransform; + private GameObject prevGameObject; + + public override void OnStart() + { + var currentGameObject = GetDefaultGameObject(targetGameObject.Value); + if (currentGameObject != prevGameObject) { + targetTransform = currentGameObject.GetComponent(); + prevGameObject = currentGameObject; + } + } + + public override TaskStatus OnUpdate() + { + if (targetTransform == null) { + Debug.LogWarning("Transform is null"); + return TaskStatus.Failure; + } + + targetTransform.Translate(translation.Value, relativeTo); + + return TaskStatus.Success; + } + + public override void OnReset() + { + targetGameObject = null; + translation = Vector3.zero; + relativeTo = Space.Self; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/Translate.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/Translate.cs.meta new file mode 100644 index 0000000..2307cc1 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Transform/Translate.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: d4a788705b79d3745a26867acf47a63a +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector2.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector2.meta new file mode 100644 index 0000000..a0115a9 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector2.meta @@ -0,0 +1,4 @@ +fileFormatVersion: 2 +guid: ea5a99c944135bb47be3809004f4ca10 +DefaultImporter: + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector2/ClampMagnitude.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector2/ClampMagnitude.cs new file mode 100644 index 0000000..a1dbc69 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector2/ClampMagnitude.cs @@ -0,0 +1,30 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityVector2 +{ + [TaskCategory("Unity/Vector2")] + [TaskDescription("Clamps the magnitude of the Vector2.")] + public class ClampMagnitude : Action + { + [Tooltip("The Vector2 to clamp the magnitude of")] + public SharedVector2 vector2Variable; + [Tooltip("The max length of the magnitude")] + public SharedFloat maxLength; + [Tooltip("The clamp magnitude resut")] + [RequiredField] + public SharedVector2 storeResult; + + public override TaskStatus OnUpdate() + { + storeResult.Value = Vector2.ClampMagnitude(vector2Variable.Value, maxLength.Value); + return TaskStatus.Success; + } + + public override void OnReset() + { + vector2Variable = Vector2.zero; + storeResult = Vector2.zero; + maxLength = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector2/ClampMagnitude.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector2/ClampMagnitude.cs.meta new file mode 100644 index 0000000..feb1ebc --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector2/ClampMagnitude.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: a2a5d2ecd681ef64ea5b5fbf81cc0b2d +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector2/Distance.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector2/Distance.cs new file mode 100644 index 0000000..9be80d6 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector2/Distance.cs @@ -0,0 +1,30 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityVector2 +{ + [TaskCategory("Unity/Vector2")] + [TaskDescription("Returns the distance between two Vector2s.")] + public class Distance : Action + { + [Tooltip("The first Vector2")] + public SharedVector2 firstVector2; + [Tooltip("The second Vector2")] + public SharedVector2 secondVector2; + [Tooltip("The distance")] + [RequiredField] + public SharedFloat storeResult; + + public override TaskStatus OnUpdate() + { + storeResult.Value = Vector2.Distance(firstVector2.Value, secondVector2.Value); + return TaskStatus.Success; + } + + public override void OnReset() + { + firstVector2 = Vector2.zero; + secondVector2 = Vector2.zero; + storeResult = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector2/Distance.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector2/Distance.cs.meta new file mode 100644 index 0000000..9865e78 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector2/Distance.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: a35c2cb53a768894f8d81c2e8dc87b9b +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector2/Dot.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector2/Dot.cs new file mode 100644 index 0000000..1d57a5d --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector2/Dot.cs @@ -0,0 +1,30 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityVector2 +{ + [TaskCategory("Unity/Vector2")] + [TaskDescription("Stores the dot product of two Vector2 values.")] + public class Dot : Action + { + [Tooltip("The left hand side of the dot product")] + public SharedVector2 leftHandSide; + [Tooltip("The right hand side of the dot product")] + public SharedVector2 rightHandSide; + [Tooltip("The dot product result")] + [RequiredField] + public SharedFloat storeResult; + + public override TaskStatus OnUpdate() + { + storeResult.Value = Vector2.Dot(leftHandSide.Value, rightHandSide.Value); + return TaskStatus.Success; + } + + public override void OnReset() + { + leftHandSide = Vector2.zero; + rightHandSide = Vector2.zero; + storeResult = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector2/Dot.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector2/Dot.cs.meta new file mode 100644 index 0000000..c51f741 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector2/Dot.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: c9c233b5173aece4493146b736d4e65d +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector2/GetMagnitude.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector2/GetMagnitude.cs new file mode 100644 index 0000000..b799ac1 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector2/GetMagnitude.cs @@ -0,0 +1,27 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityVector2 +{ + [TaskCategory("Unity/Vector2")] + [TaskDescription("Stores the magnitude of the Vector2.")] + public class GetMagnitude : Action + { + [Tooltip("The Vector2 to get the magnitude of")] + public SharedVector2 vector2Variable; + [Tooltip("The magnitude of the vector")] + [RequiredField] + public SharedFloat storeResult; + + public override TaskStatus OnUpdate() + { + storeResult.Value = vector2Variable.Value.magnitude; + return TaskStatus.Success; + } + + public override void OnReset() + { + vector2Variable = Vector2.zero; + storeResult = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector2/GetMagnitude.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector2/GetMagnitude.cs.meta new file mode 100644 index 0000000..d21823c --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector2/GetMagnitude.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 64a63651c7294144197858c8b6387b49 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector2/GetRightVector.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector2/GetRightVector.cs new file mode 100644 index 0000000..f9ba29c --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector2/GetRightVector.cs @@ -0,0 +1,24 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityVector2 +{ + [TaskCategory("Unity/Vector2")] + [TaskDescription("Stores the right vector value.")] + public class GetRightVector : Action + { + [Tooltip("The stored result")] + [RequiredField] + public SharedVector2 storeResult; + + public override TaskStatus OnUpdate() + { + storeResult.Value = Vector2.right; + return TaskStatus.Success; + } + + public override void OnReset() + { + storeResult = Vector2.zero; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector2/GetRightVector.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector2/GetRightVector.cs.meta new file mode 100644 index 0000000..03483ea --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector2/GetRightVector.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: f46062197c393bb4a809f7faf8e9fc70 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector2/GetSqrMagnitude.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector2/GetSqrMagnitude.cs new file mode 100644 index 0000000..69ac616 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector2/GetSqrMagnitude.cs @@ -0,0 +1,27 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityVector2 +{ + [TaskCategory("Unity/Vector2")] + [TaskDescription("Stores the square magnitude of the Vector2.")] + public class GetSqrMagnitude : Action + { + [Tooltip("The Vector2 to get the square magnitude of")] + public SharedVector2 vector2Variable; + [Tooltip("The square magnitude of the vector")] + [RequiredField] + public SharedFloat storeResult; + + public override TaskStatus OnUpdate() + { + storeResult.Value = vector2Variable.Value.sqrMagnitude; + return TaskStatus.Success; + } + + public override void OnReset() + { + vector2Variable = Vector2.zero; + storeResult = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector2/GetSqrMagnitude.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector2/GetSqrMagnitude.cs.meta new file mode 100644 index 0000000..a496766 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector2/GetSqrMagnitude.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 5366ccb4258ea7f49ae280d05d2a195c +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector2/GetUpVector.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector2/GetUpVector.cs new file mode 100644 index 0000000..9e59866 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector2/GetUpVector.cs @@ -0,0 +1,24 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityVector2 +{ + [TaskCategory("Unity/Vector2")] + [TaskDescription("Stores the up vector value.")] + public class GetUpVector : Action + { + [Tooltip("The stored result")] + [RequiredField] + public SharedVector2 storeResult; + + public override TaskStatus OnUpdate() + { + storeResult.Value = Vector2.up; + return TaskStatus.Success; + } + + public override void OnReset() + { + storeResult = Vector2.zero; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector2/GetUpVector.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector2/GetUpVector.cs.meta new file mode 100644 index 0000000..0332d1a --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector2/GetUpVector.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 7ec54e34058d3a04dbd9ed27538731b0 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector2/GetVector3.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector2/GetVector3.cs new file mode 100644 index 0000000..929884f --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector2/GetVector3.cs @@ -0,0 +1,27 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityVector2 +{ + [TaskCategory("Unity/Vector2")] + [TaskDescription("Stores the Vector3 value of the Vector2.")] + public class GetVector3 : Action + { + [Tooltip("The Vector2 to get the Vector3 value of")] + public SharedVector2 vector3Variable; + [Tooltip("The Vector3 value")] + [RequiredField] + public SharedVector3 storeResult; + + public override TaskStatus OnUpdate() + { + storeResult.Value = vector3Variable.Value; + return TaskStatus.Success; + } + + public override void OnReset() + { + vector3Variable = Vector2.zero; + storeResult = Vector3.zero; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector2/GetVector3.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector2/GetVector3.cs.meta new file mode 100644 index 0000000..7d17877 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector2/GetVector3.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 89ba2f45bfecb9c40a4de0394c8019e0 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector2/GetXY.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector2/GetXY.cs new file mode 100644 index 0000000..154d5fc --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector2/GetXY.cs @@ -0,0 +1,31 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityVector2 +{ + [TaskCategory("Unity/Vector2")] + [TaskDescription("Stores the X and Y values of the Vector2.")] + public class GetXY : Action + { + [Tooltip("The Vector2 to get the values of")] + public SharedVector2 vector2Variable; + [Tooltip("The X value")] + [RequiredField] + public SharedFloat storeX; + [Tooltip("The Y value")] + [RequiredField] + public SharedFloat storeY; + + public override TaskStatus OnUpdate() + { + storeX.Value = vector2Variable.Value.x; + storeY.Value = vector2Variable.Value.y; + return TaskStatus.Success; + } + + public override void OnReset() + { + vector2Variable = Vector2.zero; + storeX = storeY = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector2/GetXY.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector2/GetXY.cs.meta new file mode 100644 index 0000000..1bc498e --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector2/GetXY.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: e258a57c9873ecf4fb8a1432e418ecb4 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector2/Lerp.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector2/Lerp.cs new file mode 100644 index 0000000..81919fe --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector2/Lerp.cs @@ -0,0 +1,33 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityVector2 +{ + [TaskCategory("Unity/Vector2")] + [TaskDescription("Lerp the Vector2 by an amount.")] + public class Lerp : Action + { + [Tooltip("The from value")] + public SharedVector2 fromVector2; + [Tooltip("The to value")] + public SharedVector2 toVector2; + [Tooltip("The amount to lerp")] + public SharedFloat lerpAmount; + [Tooltip("The lerp resut")] + [RequiredField] + public SharedVector2 storeResult; + + public override TaskStatus OnUpdate() + { + storeResult.Value = Vector2.Lerp(fromVector2.Value, toVector2.Value, lerpAmount.Value); + return TaskStatus.Success; + } + + public override void OnReset() + { + fromVector2 = Vector2.zero; + toVector2 = Vector2.zero; + storeResult = Vector2.zero; + lerpAmount = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector2/Lerp.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector2/Lerp.cs.meta new file mode 100644 index 0000000..49d2645 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector2/Lerp.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 6f709035ad060c04d9f758980ad7e2c3 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector2/MoveTowards.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector2/MoveTowards.cs new file mode 100644 index 0000000..1d17e47 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector2/MoveTowards.cs @@ -0,0 +1,33 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityVector2 +{ + [TaskCategory("Unity/Vector2")] + [TaskDescription("Move from the current position to the target position.")] + public class MoveTowards : Action + { + [Tooltip("The current position")] + public SharedVector2 currentPosition; + [Tooltip("The target position")] + public SharedVector2 targetPosition; + [Tooltip("The movement speed")] + public SharedFloat speed; + [Tooltip("The move resut")] + [RequiredField] + public SharedVector2 storeResult; + + public override TaskStatus OnUpdate() + { + storeResult.Value = Vector2.MoveTowards(currentPosition.Value, targetPosition.Value, speed.Value * Time.deltaTime); + return TaskStatus.Success; + } + + public override void OnReset() + { + currentPosition = Vector2.zero; + targetPosition = Vector2.zero; + storeResult = Vector2.zero; + speed = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector2/MoveTowards.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector2/MoveTowards.cs.meta new file mode 100644 index 0000000..ff772b9 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector2/MoveTowards.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: ab464382cafa087498bef68f6988dff7 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector2/Multiply.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector2/Multiply.cs new file mode 100644 index 0000000..82bb7bf --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector2/Multiply.cs @@ -0,0 +1,29 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityVector2 +{ + [TaskCategory("Unity/Vector2")] + [TaskDescription("Multiply the Vector2 by a float.")] + public class Multiply : Action + { + [Tooltip("The Vector2 to multiply of")] + public SharedVector2 vector2Variable; + [Tooltip("The value to multiply the Vector2 of")] + public SharedFloat multiplyBy; + [Tooltip("The multiplication resut")] + [RequiredField] + public SharedVector2 storeResult; + + public override TaskStatus OnUpdate() + { + storeResult.Value = vector2Variable.Value * multiplyBy.Value; + return TaskStatus.Success; + } + + public override void OnReset() + { + vector2Variable = storeResult = Vector2.zero; + multiplyBy = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector2/Multiply.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector2/Multiply.cs.meta new file mode 100644 index 0000000..75a0ef4 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector2/Multiply.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 7f21148eaa498684baa11ac8ac177599 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector2/Normalize.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector2/Normalize.cs new file mode 100644 index 0000000..da1440e --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector2/Normalize.cs @@ -0,0 +1,27 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityVector2 +{ + [TaskCategory("Unity/Vector2")] + [TaskDescription("Normalize the Vector2.")] + public class Normalize : Action + { + [Tooltip("The Vector2 to normalize")] + public SharedVector2 vector2Variable; + [Tooltip("The normalized resut")] + [RequiredField] + public SharedVector2 storeResult; + + public override TaskStatus OnUpdate() + { + storeResult.Value = vector2Variable.Value.normalized; + return TaskStatus.Success; + } + + public override void OnReset() + { + vector2Variable = Vector2.zero; + storeResult = Vector2.zero; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector2/Normalize.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector2/Normalize.cs.meta new file mode 100644 index 0000000..b89a8f9 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector2/Normalize.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: ed5b59611a512984f9755c358afc67d8 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector2/Operator.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector2/Operator.cs new file mode 100644 index 0000000..0af22ca --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector2/Operator.cs @@ -0,0 +1,49 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityVector2 +{ + [TaskCategory("Unity/Vector2")] + [TaskDescription("Performs a math operation on two Vector2s: Add, Subtract, Multiply, Divide, Min, or Max.")] + public class Operator : Action + { + public enum Operation + { + Add, + Subtract, + Scale + } + + [Tooltip("The operation to perform")] + public Operation operation; + [Tooltip("The first Vector2")] + public SharedVector2 firstVector2; + [Tooltip("The second Vector2")] + public SharedVector2 secondVector2; + [Tooltip("The variable to store the result")] + public SharedVector2 storeResult; + + public override TaskStatus OnUpdate() + { + switch (operation) { + case Operation.Add: + storeResult.Value = firstVector2.Value + secondVector2.Value; + break; + case Operation.Subtract: + storeResult.Value = firstVector2.Value - secondVector2.Value; + break; + case Operation.Scale: + storeResult.Value = Vector2.Scale(firstVector2.Value, secondVector2.Value); + break; + } + return TaskStatus.Success; + } + + public override void OnReset() + { + operation = Operation.Add; + firstVector2 = Vector2.zero; + secondVector2 = Vector2.zero; + storeResult = Vector2.zero; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector2/Operator.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector2/Operator.cs.meta new file mode 100644 index 0000000..83d4d5b --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector2/Operator.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 2ae8ac6f41714174fa63df41c7e32019 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector2/SetValue.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector2/SetValue.cs new file mode 100644 index 0000000..246c155 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector2/SetValue.cs @@ -0,0 +1,26 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityVector2 +{ + [TaskCategory("Unity/Vector2")] + [TaskDescription("Sets the value of the Vector2.")] + public class SetValue : Action + { + [Tooltip("The Vector2 to get the values of")] + public SharedVector2 vector2Value; + [Tooltip("The Vector2 to set the values of")] + public SharedVector2 vector2Variable; + + public override TaskStatus OnUpdate() + { + vector2Variable.Value = vector2Value.Value; + return TaskStatus.Success; + } + + public override void OnReset() + { + vector2Value = Vector2.zero; + vector2Variable = Vector2.zero; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector2/SetValue.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector2/SetValue.cs.meta new file mode 100644 index 0000000..42fdffc --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector2/SetValue.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 61e3d384c43977148b829dab4090ab3b +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector2/SetXY.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector2/SetXY.cs new file mode 100644 index 0000000..f6c23d0 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector2/SetXY.cs @@ -0,0 +1,36 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityVector2 +{ + [TaskCategory("Unity/Vector2")] + [TaskDescription("Sets the X and Y values of the Vector2.")] + public class SetXY : Action + { + [Tooltip("The Vector2 to set the values of")] + public SharedVector2 vector2Variable; + [Tooltip("The X value. Set to None to have the value ignored")] + public SharedFloat xValue; + [Tooltip("The Y value. Set to None to have the value ignored")] + public SharedFloat yValue; + + public override TaskStatus OnUpdate() + { + var vector2Value = vector2Variable.Value; + if (!xValue.IsNone) { + vector2Value.x = xValue.Value; + } + if (!yValue.IsNone) { + vector2Value.y = yValue.Value; + } + vector2Variable.Value = vector2Value; + return TaskStatus.Success; + } + + public override void OnReset() + { + vector2Variable = Vector2.zero; + xValue = 0; + yValue = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector2/SetXY.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector2/SetXY.cs.meta new file mode 100644 index 0000000..d2d4591 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector2/SetXY.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: a24836a22bca9bd4ab701e35bf36f6a9 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector3.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector3.meta new file mode 100644 index 0000000..1dea600 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector3.meta @@ -0,0 +1,4 @@ +fileFormatVersion: 2 +guid: 65391955a7357ef4e82aa0214dc9b407 +DefaultImporter: + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector3/Angle.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector3/Angle.cs new file mode 100644 index 0000000..054c9c2 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector3/Angle.cs @@ -0,0 +1,30 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityVector3 +{ + [TaskCategory("Unity/Vector3")] + [TaskDescription("Returns the angle between two Vector3s.")] + public class Angle : Action + { + [Tooltip("The first Vector3")] + public SharedVector3 firstVector3; + [Tooltip("The second Vector3")] + public SharedVector3 secondVector3; + [Tooltip("The angle")] + [RequiredField] + public SharedFloat storeResult; + + public override TaskStatus OnUpdate() + { + storeResult.Value = Vector3.Angle(firstVector3.Value, secondVector3.Value); + return TaskStatus.Success; + } + + public override void OnReset() + { + firstVector3 = Vector3.zero; + secondVector3 = Vector3.zero; + storeResult = 0; + } + } +} diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector3/Angle.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector3/Angle.cs.meta new file mode 100644 index 0000000..c60274a --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector3/Angle.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 1e3b18a7f2f7db54992b881f449091ad +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector3/ClampMagnitude.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector3/ClampMagnitude.cs new file mode 100644 index 0000000..9795cdc --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector3/ClampMagnitude.cs @@ -0,0 +1,30 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityVector3 +{ + [TaskCategory("Unity/Vector3")] + [TaskDescription("Clamps the magnitude of the Vector3.")] + public class ClampMagnitude : Action + { + [Tooltip("The Vector3 to clamp the magnitude of")] + public SharedVector3 vector3Variable; + [Tooltip("The max length of the magnitude")] + public SharedFloat maxLength; + [Tooltip("The clamp magnitude resut")] + [RequiredField] + public SharedVector3 storeResult; + + public override TaskStatus OnUpdate() + { + storeResult.Value = Vector3.ClampMagnitude(vector3Variable.Value, maxLength.Value); + return TaskStatus.Success; + } + + public override void OnReset() + { + vector3Variable = Vector3.zero; + storeResult = Vector3.zero; + maxLength = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector3/ClampMagnitude.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector3/ClampMagnitude.cs.meta new file mode 100644 index 0000000..de537be --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector3/ClampMagnitude.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: e3d2efd14a9499b47a17ea16bf45512f +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector3/Distance.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector3/Distance.cs new file mode 100644 index 0000000..2266cf2 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector3/Distance.cs @@ -0,0 +1,30 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityVector3 +{ + [TaskCategory("Unity/Vector3")] + [TaskDescription("Returns the distance between two Vector3s.")] + public class Distance : Action + { + [Tooltip("The first Vector3")] + public SharedVector3 firstVector3; + [Tooltip("The second Vector3")] + public SharedVector3 secondVector3; + [Tooltip("The distance")] + [RequiredField] + public SharedFloat storeResult; + + public override TaskStatus OnUpdate() + { + storeResult.Value = Vector3.Distance(firstVector3.Value, secondVector3.Value); + return TaskStatus.Success; + } + + public override void OnReset() + { + firstVector3 = Vector3.zero; + secondVector3 = Vector3.zero; + storeResult = 0; + } + } +} diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector3/Distance.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector3/Distance.cs.meta new file mode 100644 index 0000000..4b3f57f --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector3/Distance.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 8c4522b996b52d040822fb808cfc9d97 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector3/Dot.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector3/Dot.cs new file mode 100644 index 0000000..b68ea04 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector3/Dot.cs @@ -0,0 +1,30 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityVector3 +{ + [TaskCategory("Unity/Vector3")] + [TaskDescription("Stores the dot product of two Vector3 values.")] + public class Dot : Action + { + [Tooltip("The left hand side of the dot product")] + public SharedVector3 leftHandSide; + [Tooltip("The right hand side of the dot product")] + public SharedVector3 rightHandSide; + [Tooltip("The dot product result")] + [RequiredField] + public SharedFloat storeResult; + + public override TaskStatus OnUpdate() + { + storeResult.Value = Vector3.Dot(leftHandSide.Value, rightHandSide.Value); + return TaskStatus.Success; + } + + public override void OnReset() + { + leftHandSide = Vector3.zero; + rightHandSide = Vector3.zero; + storeResult = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector3/Dot.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector3/Dot.cs.meta new file mode 100644 index 0000000..a4ab8aa --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector3/Dot.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: fe5e2655abffbe94eba3f6a0abd34b5c +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector3/GetForwardVector.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector3/GetForwardVector.cs new file mode 100644 index 0000000..eee7e00 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector3/GetForwardVector.cs @@ -0,0 +1,24 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityVector3 +{ + [TaskCategory("Unity/Vector3")] + [TaskDescription("Stores the forward vector value.")] + public class GetForwardVector : Action + { + [Tooltip("The stored result")] + [RequiredField] + public SharedVector3 storeResult; + + public override TaskStatus OnUpdate() + { + storeResult.Value = Vector3.forward; + return TaskStatus.Success; + } + + public override void OnReset() + { + storeResult = Vector3.zero; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector3/GetForwardVector.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector3/GetForwardVector.cs.meta new file mode 100644 index 0000000..1cd9492 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector3/GetForwardVector.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: b09c11f987794eb45b65e0ef249cdb3f +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector3/GetMagnitude.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector3/GetMagnitude.cs new file mode 100644 index 0000000..5a7c516 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector3/GetMagnitude.cs @@ -0,0 +1,27 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityVector3 +{ + [TaskCategory("Unity/Vector3")] + [TaskDescription("Stores the magnitude of the Vector3.")] + public class GetMagnitude : Action + { + [Tooltip("The Vector3 to get the magnitude of")] + public SharedVector3 vector3Variable; + [Tooltip("The magnitude of the vector")] + [RequiredField] + public SharedFloat storeResult; + + public override TaskStatus OnUpdate() + { + storeResult.Value = vector3Variable.Value.magnitude; + return TaskStatus.Success; + } + + public override void OnReset() + { + vector3Variable = Vector3.zero; + storeResult = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector3/GetMagnitude.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector3/GetMagnitude.cs.meta new file mode 100644 index 0000000..37cf1b4 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector3/GetMagnitude.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: dcf2397966692fe4a819a0db18186778 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector3/GetRightVector.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector3/GetRightVector.cs new file mode 100644 index 0000000..7e49602 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector3/GetRightVector.cs @@ -0,0 +1,24 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityVector3 +{ + [TaskCategory("Unity/Vector3")] + [TaskDescription("Stores the right vector value.")] + public class GetRightVector : Action + { + [Tooltip("The stored result")] + [RequiredField] + public SharedVector3 storeResult; + + public override TaskStatus OnUpdate() + { + storeResult.Value = Vector3.right; + return TaskStatus.Success; + } + + public override void OnReset() + { + storeResult = Vector3.zero; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector3/GetRightVector.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector3/GetRightVector.cs.meta new file mode 100644 index 0000000..f4f53d7 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector3/GetRightVector.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: ca338b1189144fe47ab9b1fa6a54e970 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector3/GetSqrMagnitude.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector3/GetSqrMagnitude.cs new file mode 100644 index 0000000..92dfeb2 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector3/GetSqrMagnitude.cs @@ -0,0 +1,27 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityVector3 +{ + [TaskCategory("Unity/Vector3")] + [TaskDescription("Stores the square magnitude of the Vector3.")] + public class GetSqrMagnitude : Action + { + [Tooltip("The Vector3 to get the square magnitude of")] + public SharedVector3 vector3Variable; + [Tooltip("The square magnitude of the vector")] + [RequiredField] + public SharedFloat storeResult; + + public override TaskStatus OnUpdate() + { + storeResult.Value = vector3Variable.Value.sqrMagnitude; + return TaskStatus.Success; + } + + public override void OnReset() + { + vector3Variable = Vector3.zero; + storeResult = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector3/GetSqrMagnitude.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector3/GetSqrMagnitude.cs.meta new file mode 100644 index 0000000..4bb80c4 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector3/GetSqrMagnitude.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: fb704714eacb92948bd59ddd38865b59 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector3/GetUpVector.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector3/GetUpVector.cs new file mode 100644 index 0000000..95fa362 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector3/GetUpVector.cs @@ -0,0 +1,24 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityVector3 +{ + [TaskCategory("Unity/Vector3")] + [TaskDescription("Stores the up vector value.")] + public class GetUpVector : Action + { + [Tooltip("The stored result")] + [RequiredField] + public SharedVector3 storeResult; + + public override TaskStatus OnUpdate() + { + storeResult.Value = Vector3.up; + return TaskStatus.Success; + } + + public override void OnReset() + { + storeResult = Vector3.zero; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector3/GetUpVector.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector3/GetUpVector.cs.meta new file mode 100644 index 0000000..ff2bde2 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector3/GetUpVector.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 225a4566a02bdec4e82a2335b4e6c5fc +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector3/GetVector2.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector3/GetVector2.cs new file mode 100644 index 0000000..ef92300 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector3/GetVector2.cs @@ -0,0 +1,27 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityVector3 +{ + [TaskCategory("Unity/Vector3")] + [TaskDescription("Stores the Vector2 value of the Vector3.")] + public class GetVector2 : Action + { + [Tooltip("The Vector3 to get the Vector2 value of")] + public SharedVector3 vector3Variable; + [Tooltip("The Vector2 value")] + [RequiredField] + public SharedVector2 storeResult; + + public override TaskStatus OnUpdate() + { + storeResult.Value = vector3Variable.Value; + return TaskStatus.Success; + } + + public override void OnReset() + { + vector3Variable = Vector3.zero; + storeResult = Vector2.zero; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector3/GetVector2.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector3/GetVector2.cs.meta new file mode 100644 index 0000000..1f9a741 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector3/GetVector2.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 959ed107c681b1c44af1b842ed7ca445 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector3/GetXYZ.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector3/GetXYZ.cs new file mode 100644 index 0000000..56307e9 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector3/GetXYZ.cs @@ -0,0 +1,37 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityVector3 +{ + [TaskCategory("Unity/Vector3")] + [TaskDescription("Stores the X, Y, and Z values of the Vector3.")] + public class GetXYZ : Action + { + [Tooltip("The Vector3 to get the values of")] + public SharedVector3 vector3Variable; + [Tooltip("The X value")] + [RequiredField] + public SharedFloat storeX; + [Tooltip("The Y value")] + [RequiredField] + public SharedFloat storeY; + [Tooltip("The Z value")] + [RequiredField] + public SharedFloat storeZ; + + public override TaskStatus OnUpdate() + { + storeX.Value = vector3Variable.Value.x; + storeY.Value = vector3Variable.Value.y; + storeZ.Value = vector3Variable.Value.z; + return TaskStatus.Success; + } + + public override void OnReset() + { + vector3Variable = Vector3.zero; + storeX = 0; + storeY = 0; + storeZ = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector3/GetXYZ.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector3/GetXYZ.cs.meta new file mode 100644 index 0000000..7599e94 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector3/GetXYZ.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: fbab043af227fe14e8875a1df65cbae4 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector3/Lerp.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector3/Lerp.cs new file mode 100644 index 0000000..e939878 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector3/Lerp.cs @@ -0,0 +1,31 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityVector3 +{ + [TaskCategory("Unity/Vector3")] + [TaskDescription("Lerp the Vector3 by an amount.")] + public class Lerp : Action + { + [Tooltip("The from value")] + public SharedVector3 fromVector3; + [Tooltip("The to value")] + public SharedVector3 toVector3; + [Tooltip("The amount to lerp")] + public SharedFloat lerpAmount; + [Tooltip("The lerp resut")] + [RequiredField] + public SharedVector3 storeResult; + + public override TaskStatus OnUpdate() + { + storeResult.Value = Vector3.Lerp(fromVector3.Value, toVector3.Value, lerpAmount.Value); + return TaskStatus.Success; + } + + public override void OnReset() + { + fromVector3 = toVector3 = storeResult = Vector3.zero; + lerpAmount = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector3/Lerp.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector3/Lerp.cs.meta new file mode 100644 index 0000000..04c4ca1 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector3/Lerp.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: ef769062529820342a12a00e9cf8611d +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector3/MoveTowards.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector3/MoveTowards.cs new file mode 100644 index 0000000..b082f20 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector3/MoveTowards.cs @@ -0,0 +1,33 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityVector3 +{ + [TaskCategory("Unity/Vector3")] + [TaskDescription("Move from the current position to the target position.")] + public class MoveTowards : Action + { + [Tooltip("The current position")] + public SharedVector3 currentPosition; + [Tooltip("The target position")] + public SharedVector3 targetPosition; + [Tooltip("The movement speed")] + public SharedFloat speed; + [Tooltip("The move resut")] + [RequiredField] + public SharedVector3 storeResult; + + public override TaskStatus OnUpdate() + { + storeResult.Value = Vector3.MoveTowards(currentPosition.Value, targetPosition.Value, speed.Value * Time.deltaTime); + return TaskStatus.Success; + } + + public override void OnReset() + { + currentPosition = Vector3.zero; + targetPosition = Vector3.zero; + storeResult = Vector3.zero; + speed = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector3/MoveTowards.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector3/MoveTowards.cs.meta new file mode 100644 index 0000000..efbf9fd --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector3/MoveTowards.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: b6562a7b02f6ab1478612f41defc5299 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector3/Multiply.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector3/Multiply.cs new file mode 100644 index 0000000..8804156 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector3/Multiply.cs @@ -0,0 +1,30 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityVector3 +{ + [TaskCategory("Unity/Vector3")] + [TaskDescription("Multiply the Vector3 by a float.")] + public class Multiply : Action + { + [Tooltip("The Vector3 to multiply of")] + public SharedVector3 vector3Variable; + [Tooltip("The value to multiply the Vector3 of")] + public SharedFloat multiplyBy; + [Tooltip("The multiplication resut")] + [RequiredField] + public SharedVector3 storeResult; + + public override TaskStatus OnUpdate() + { + storeResult.Value = vector3Variable.Value * multiplyBy.Value; + return TaskStatus.Success; + } + + public override void OnReset() + { + vector3Variable = Vector3.zero; + storeResult = Vector3.zero; + multiplyBy = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector3/Multiply.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector3/Multiply.cs.meta new file mode 100644 index 0000000..4c531d7 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector3/Multiply.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 1d1d7bd2678e229468abd363ac4a3dd6 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector3/Normalize.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector3/Normalize.cs new file mode 100644 index 0000000..6d03c73 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector3/Normalize.cs @@ -0,0 +1,27 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityVector3 +{ + [TaskCategory("Unity/Vector3")] + [TaskDescription("Normalize the Vector3.")] + public class Normalize : Action + { + [Tooltip("The Vector3 to normalize")] + public SharedVector3 vector3Variable; + [Tooltip("The normalized resut")] + [RequiredField] + public SharedVector3 storeResult; + + public override TaskStatus OnUpdate() + { + storeResult.Value = Vector3.Normalize(vector3Variable.Value); + return TaskStatus.Success; + } + + public override void OnReset() + { + vector3Variable = Vector3.zero; + storeResult = Vector3.zero; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector3/Normalize.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector3/Normalize.cs.meta new file mode 100644 index 0000000..a6eab81 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector3/Normalize.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: bc8d58dc29ef6ab49a11e77f517e30ca +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector3/Operator.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector3/Operator.cs new file mode 100644 index 0000000..64f6dfd --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector3/Operator.cs @@ -0,0 +1,49 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityVector3 +{ + [TaskCategory("Unity/Vector3")] + [TaskDescription("Performs a math operation on two Vector3s: Add, Subtract, Multiply, Divide, Min, or Max.")] + public class Operator : Action + { + public enum Operation + { + Add, + Subtract, + Scale + } + + [Tooltip("The operation to perform")] + public Operation operation; + [Tooltip("The first Vector3")] + public SharedVector3 firstVector3; + [Tooltip("The second Vector3")] + public SharedVector3 secondVector3; + [Tooltip("The variable to store the result")] + public SharedVector3 storeResult; + + public override TaskStatus OnUpdate() + { + switch (operation) { + case Operation.Add: + storeResult.Value = firstVector3.Value + secondVector3.Value; + break; + case Operation.Subtract: + storeResult.Value = firstVector3.Value - secondVector3.Value; + break; + case Operation.Scale: + storeResult.Value = Vector3.Scale(firstVector3.Value, secondVector3.Value); + break; + } + return TaskStatus.Success; + } + + public override void OnReset() + { + operation = Operation.Add; + firstVector3 = Vector3.zero; + secondVector3 = Vector3.zero; + storeResult = Vector3.zero; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector3/Operator.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector3/Operator.cs.meta new file mode 100644 index 0000000..6b89a7d --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector3/Operator.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 606d84afee1cfbe4892d452884d36be8 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector3/RotateTowards.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector3/RotateTowards.cs new file mode 100644 index 0000000..72e1f5c --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector3/RotateTowards.cs @@ -0,0 +1,36 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityVector3 +{ + [TaskCategory("Unity/Vector3")] + [TaskDescription("Rotate the current rotation to the target rotation.")] + public class RotateTowards : Action + { + [Tooltip("The current rotation in euler angles")] + public SharedVector3 currentRotation; + [Tooltip("The target rotation in euler angles")] + public SharedVector3 targetRotation; + [Tooltip("The maximum delta of the degrees")] + public SharedFloat maxDegreesDelta; + [Tooltip("The maximum delta of the magnitude")] + public SharedFloat maxMagnitudeDelta; + [Tooltip("The rotation resut")] + [RequiredField] + public SharedVector3 storeResult; + + public override TaskStatus OnUpdate() + { + storeResult.Value = Vector3.RotateTowards(currentRotation.Value, targetRotation.Value, maxDegreesDelta.Value * Mathf.Deg2Rad * Time.deltaTime, maxMagnitudeDelta.Value); + return TaskStatus.Success; + } + + public override void OnReset() + { + currentRotation = Vector3.zero; + targetRotation = Vector3.zero; + storeResult = Vector3.zero; + maxDegreesDelta = 0; + maxMagnitudeDelta = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector3/RotateTowards.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector3/RotateTowards.cs.meta new file mode 100644 index 0000000..a6fcfb0 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector3/RotateTowards.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 55175ed9420ee88429fbb91a9b433b9c +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector3/SetValue.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector3/SetValue.cs new file mode 100644 index 0000000..194fa6e --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector3/SetValue.cs @@ -0,0 +1,26 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityVector3 +{ + [TaskCategory("Unity/Vector3")] + [TaskDescription("Sets the value of the Vector3.")] + public class SetValue : Action + { + [Tooltip("The Vector3 to get the values of")] + public SharedVector3 vector3Value; + [Tooltip("The Vector3 to set the values of")] + public SharedVector3 vector3Variable; + + public override TaskStatus OnUpdate() + { + vector3Variable.Value = vector3Value.Value; + return TaskStatus.Success; + } + + public override void OnReset() + { + vector3Value = Vector3.zero; + vector3Variable = Vector3.zero; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector3/SetValue.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector3/SetValue.cs.meta new file mode 100644 index 0000000..b81ab13 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector3/SetValue.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: d512a8eb2bde4ea49868fdd746dafb0d +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector3/SetXYZ.cs b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector3/SetXYZ.cs new file mode 100644 index 0000000..23d05a0 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector3/SetXYZ.cs @@ -0,0 +1,40 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime.Tasks.Unity.UnityVector3 +{ + [TaskCategory("Unity/Vector3")] + [TaskDescription("Sets the X, Y, and Z values of the Vector3.")] + public class SetXYZ : Action + { + [Tooltip("The Vector3 to set the values of")] + public SharedVector3 vector3Variable; + [Tooltip("The X value. Set to None to have the value ignored")] + public SharedFloat xValue; + [Tooltip("The Y value. Set to None to have the value ignored")] + public SharedFloat yValue; + [Tooltip("The Z value. Set to None to have the value ignored")] + public SharedFloat zValue; + + public override TaskStatus OnUpdate() + { + var vector3Value = vector3Variable.Value; + if (!xValue.IsNone) { + vector3Value.x = xValue.Value; + } + if (!yValue.IsNone) { + vector3Value.y = yValue.Value; + } + if (!zValue.IsNone) { + vector3Value.z = zValue.Value; + } + vector3Variable.Value = vector3Value; + return TaskStatus.Success; + } + + public override void OnReset() + { + vector3Variable = Vector3.zero; + xValue = yValue = zValue = 0; + } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector3/SetXYZ.cs.meta b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector3/SetXYZ.cs.meta new file mode 100644 index 0000000..bfdd20f --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Tasks/Unity/Vector3/SetXYZ.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: efcd4530935b0c445804e64d0820f27b +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Variables.meta b/Assets/Behavior Designer/Runtime/Variables.meta new file mode 100644 index 0000000..c91b795 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Variables.meta @@ -0,0 +1,4 @@ +fileFormatVersion: 2 +guid: a52d5a185c5a1614f875fcb1828d78d8 +DefaultImporter: + userData: diff --git a/Assets/Behavior Designer/Runtime/Variables/SharedAnimationCurve.cs b/Assets/Behavior Designer/Runtime/Variables/SharedAnimationCurve.cs new file mode 100644 index 0000000..f7c8a6d --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Variables/SharedAnimationCurve.cs @@ -0,0 +1,10 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime +{ + [System.Serializable] + public class SharedAnimationCurve : SharedVariable + { + public static implicit operator SharedAnimationCurve(AnimationCurve value) { return new SharedAnimationCurve { mValue = value }; } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Variables/SharedAnimationCurve.cs.meta b/Assets/Behavior Designer/Runtime/Variables/SharedAnimationCurve.cs.meta new file mode 100644 index 0000000..701b4ee --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Variables/SharedAnimationCurve.cs.meta @@ -0,0 +1,12 @@ +fileFormatVersion: 2 +guid: e30f25f7530f8424a997bd05af4ef4fd +timeCreated: 1500510014 +licenseType: Store +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Behavior Designer/Runtime/Variables/SharedBehaviour.cs b/Assets/Behavior Designer/Runtime/Variables/SharedBehaviour.cs new file mode 100644 index 0000000..e896be7 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Variables/SharedBehaviour.cs @@ -0,0 +1,10 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime +{ + [System.Serializable] + public class SharedBehaviour : SharedVariable + { + public static explicit operator SharedBehaviour(Behaviour value) { return new SharedBehaviour { mValue = value }; } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Variables/SharedBehaviour.cs.meta b/Assets/Behavior Designer/Runtime/Variables/SharedBehaviour.cs.meta new file mode 100644 index 0000000..6e48631 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Variables/SharedBehaviour.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 30ee055ba23074141b455674e2e17bff +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Variables/SharedBool.cs b/Assets/Behavior Designer/Runtime/Variables/SharedBool.cs new file mode 100644 index 0000000..233470f --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Variables/SharedBool.cs @@ -0,0 +1,8 @@ +namespace BehaviorDesigner.Runtime +{ + [System.Serializable] + public class SharedBool : SharedVariable + { + public static implicit operator SharedBool(bool value) { return new SharedBool { mValue = value }; } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Variables/SharedBool.cs.meta b/Assets/Behavior Designer/Runtime/Variables/SharedBool.cs.meta new file mode 100644 index 0000000..180a25b --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Variables/SharedBool.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: c2f4e02925f3d454c8a49a9f9cc1d497 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Variables/SharedCollider.cs b/Assets/Behavior Designer/Runtime/Variables/SharedCollider.cs new file mode 100644 index 0000000..9311dc4 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Variables/SharedCollider.cs @@ -0,0 +1,10 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime +{ + [System.Serializable] + public class SharedCollider : SharedVariable + { + public static implicit operator SharedCollider(Collider value) { return new SharedCollider { mValue = value }; } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Variables/SharedCollider.cs.meta b/Assets/Behavior Designer/Runtime/Variables/SharedCollider.cs.meta new file mode 100644 index 0000000..13207d0 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Variables/SharedCollider.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 9e04c1684b0b8b7439be44cc63a4d5f2 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Variables/SharedColor.cs b/Assets/Behavior Designer/Runtime/Variables/SharedColor.cs new file mode 100644 index 0000000..7a893ab --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Variables/SharedColor.cs @@ -0,0 +1,10 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime +{ + [System.Serializable] + public class SharedColor : SharedVariable + { + public static implicit operator SharedColor(Color value) { return new SharedColor { mValue = value }; } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Variables/SharedColor.cs.meta b/Assets/Behavior Designer/Runtime/Variables/SharedColor.cs.meta new file mode 100644 index 0000000..3d29798 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Variables/SharedColor.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 1aebb6343767438449d67bf4118aeefe +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Variables/SharedFloat.cs b/Assets/Behavior Designer/Runtime/Variables/SharedFloat.cs new file mode 100644 index 0000000..4655959 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Variables/SharedFloat.cs @@ -0,0 +1,8 @@ +namespace BehaviorDesigner.Runtime +{ + [System.Serializable] + public class SharedFloat : SharedVariable + { + public static implicit operator SharedFloat(float value) { return new SharedFloat { Value = value }; } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Variables/SharedFloat.cs.meta b/Assets/Behavior Designer/Runtime/Variables/SharedFloat.cs.meta new file mode 100644 index 0000000..602cdff --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Variables/SharedFloat.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 954735ce9c49fd845add7abd7883211c +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Variables/SharedGameObject.cs b/Assets/Behavior Designer/Runtime/Variables/SharedGameObject.cs new file mode 100644 index 0000000..1347a43 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Variables/SharedGameObject.cs @@ -0,0 +1,10 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime +{ + [System.Serializable] + public class SharedGameObject : SharedVariable + { + public static implicit operator SharedGameObject(GameObject value) { return new SharedGameObject { mValue = value }; } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Variables/SharedGameObject.cs.meta b/Assets/Behavior Designer/Runtime/Variables/SharedGameObject.cs.meta new file mode 100644 index 0000000..4e324c9 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Variables/SharedGameObject.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: df84e4f8f0e526344a46be1b083e0218 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Variables/SharedGameObjectList.cs b/Assets/Behavior Designer/Runtime/Variables/SharedGameObjectList.cs new file mode 100644 index 0000000..d202649 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Variables/SharedGameObjectList.cs @@ -0,0 +1,11 @@ +using UnityEngine; +using System.Collections.Generic; + +namespace BehaviorDesigner.Runtime +{ + [System.Serializable] + public class SharedGameObjectList : SharedVariable> + { + public static implicit operator SharedGameObjectList(List value) { return new SharedGameObjectList { mValue = value }; } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Variables/SharedGameObjectList.cs.meta b/Assets/Behavior Designer/Runtime/Variables/SharedGameObjectList.cs.meta new file mode 100644 index 0000000..d7d994b --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Variables/SharedGameObjectList.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 70650d45c2fa6794a9fdd7d2a74bb59a +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Variables/SharedInt.cs b/Assets/Behavior Designer/Runtime/Variables/SharedInt.cs new file mode 100644 index 0000000..6b5229c --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Variables/SharedInt.cs @@ -0,0 +1,8 @@ +namespace BehaviorDesigner.Runtime +{ + [System.Serializable] + public class SharedInt : SharedVariable + { + public static implicit operator SharedInt(int value) { return new SharedInt { mValue = value }; } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Variables/SharedInt.cs.meta b/Assets/Behavior Designer/Runtime/Variables/SharedInt.cs.meta new file mode 100644 index 0000000..6918550 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Variables/SharedInt.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 00de328b40e8ac84ebf75e48fe353f38 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Variables/SharedLayerMask.cs b/Assets/Behavior Designer/Runtime/Variables/SharedLayerMask.cs new file mode 100644 index 0000000..3701e7b --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Variables/SharedLayerMask.cs @@ -0,0 +1,8 @@ +namespace BehaviorDesigner.Runtime +{ + [System.Serializable] + public class SharedLayerMask : SharedVariable + { + public static implicit operator SharedLayerMask(UnityEngine.LayerMask value) { return new SharedLayerMask { Value = value }; } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Variables/SharedLayerMask.cs.meta b/Assets/Behavior Designer/Runtime/Variables/SharedLayerMask.cs.meta new file mode 100644 index 0000000..a31391f --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Variables/SharedLayerMask.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 86ff0dd68e1e479408158dfe30d4258f +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Variables/SharedMaterial.cs b/Assets/Behavior Designer/Runtime/Variables/SharedMaterial.cs new file mode 100644 index 0000000..31813e4 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Variables/SharedMaterial.cs @@ -0,0 +1,10 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime +{ + [System.Serializable] + public class SharedMaterial : SharedVariable + { + public static implicit operator SharedMaterial(Material value) { return new SharedMaterial { mValue = value }; } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Variables/SharedMaterial.cs.meta b/Assets/Behavior Designer/Runtime/Variables/SharedMaterial.cs.meta new file mode 100644 index 0000000..8e88abf --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Variables/SharedMaterial.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 2e84514e0f685a64795ecdb776888407 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Variables/SharedObject.cs b/Assets/Behavior Designer/Runtime/Variables/SharedObject.cs new file mode 100644 index 0000000..8d948cc --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Variables/SharedObject.cs @@ -0,0 +1,10 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime +{ + [System.Serializable] + public class SharedObject : SharedVariable + { + public static explicit operator SharedObject(Object value) { return new SharedObject { mValue = value }; } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Variables/SharedObject.cs.meta b/Assets/Behavior Designer/Runtime/Variables/SharedObject.cs.meta new file mode 100644 index 0000000..5f09774 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Variables/SharedObject.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: d5ffddfc2d65c6e4ca1dedda5afd6ccc +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Variables/SharedObjectList.cs b/Assets/Behavior Designer/Runtime/Variables/SharedObjectList.cs new file mode 100644 index 0000000..c20f8d0 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Variables/SharedObjectList.cs @@ -0,0 +1,11 @@ +using UnityEngine; +using System.Collections.Generic; + +namespace BehaviorDesigner.Runtime +{ + [System.Serializable] + public class SharedObjectList : SharedVariable> + { + public static implicit operator SharedObjectList(List value) { return new SharedObjectList { mValue = value }; } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Variables/SharedObjectList.cs.meta b/Assets/Behavior Designer/Runtime/Variables/SharedObjectList.cs.meta new file mode 100644 index 0000000..5ed3d24 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Variables/SharedObjectList.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: c7644e981f746b5458fb6adbda412b2d +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Variables/SharedQuaternion.cs b/Assets/Behavior Designer/Runtime/Variables/SharedQuaternion.cs new file mode 100644 index 0000000..217bd70 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Variables/SharedQuaternion.cs @@ -0,0 +1,10 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime +{ + [System.Serializable] + public class SharedQuaternion : SharedVariable + { + public static implicit operator SharedQuaternion(Quaternion value) { return new SharedQuaternion { mValue = value }; } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Variables/SharedQuaternion.cs.meta b/Assets/Behavior Designer/Runtime/Variables/SharedQuaternion.cs.meta new file mode 100644 index 0000000..303deed --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Variables/SharedQuaternion.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 1ec5ca504fe011b449506c42d3e5ac7f +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Variables/SharedRect.cs b/Assets/Behavior Designer/Runtime/Variables/SharedRect.cs new file mode 100644 index 0000000..3e026fc --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Variables/SharedRect.cs @@ -0,0 +1,10 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime +{ + [System.Serializable] + public class SharedRect : SharedVariable + { + public static implicit operator SharedRect(Rect value) { return new SharedRect { mValue = value }; } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Variables/SharedRect.cs.meta b/Assets/Behavior Designer/Runtime/Variables/SharedRect.cs.meta new file mode 100644 index 0000000..bef3369 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Variables/SharedRect.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 23ef607e9df5ab742afbea152c79eed5 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Variables/SharedString.cs b/Assets/Behavior Designer/Runtime/Variables/SharedString.cs new file mode 100644 index 0000000..ae99746 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Variables/SharedString.cs @@ -0,0 +1,8 @@ +namespace BehaviorDesigner.Runtime +{ + [System.Serializable] + public class SharedString : SharedVariable + { + public static implicit operator SharedString(string value) { return new SharedString { mValue = value }; } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Variables/SharedString.cs.meta b/Assets/Behavior Designer/Runtime/Variables/SharedString.cs.meta new file mode 100644 index 0000000..36f8f59 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Variables/SharedString.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 2b562573ea4266848bc3f78352dca3a5 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Variables/SharedTransform.cs b/Assets/Behavior Designer/Runtime/Variables/SharedTransform.cs new file mode 100644 index 0000000..ac12b57 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Variables/SharedTransform.cs @@ -0,0 +1,10 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime +{ + [System.Serializable] + public class SharedTransform : SharedVariable + { + public static implicit operator SharedTransform(Transform value) { return new SharedTransform { mValue = value }; } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Variables/SharedTransform.cs.meta b/Assets/Behavior Designer/Runtime/Variables/SharedTransform.cs.meta new file mode 100644 index 0000000..beb8c12 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Variables/SharedTransform.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 3e084053b0dbe6541bc2408005c85606 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Variables/SharedTransformList.cs b/Assets/Behavior Designer/Runtime/Variables/SharedTransformList.cs new file mode 100644 index 0000000..768f7b8 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Variables/SharedTransformList.cs @@ -0,0 +1,11 @@ +using UnityEngine; +using System.Collections.Generic; + +namespace BehaviorDesigner.Runtime +{ + [System.Serializable] + public class SharedTransformList : SharedVariable> + { + public static implicit operator SharedTransformList(List value) { return new SharedTransformList { mValue = value }; } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Variables/SharedTransformList.cs.meta b/Assets/Behavior Designer/Runtime/Variables/SharedTransformList.cs.meta new file mode 100644 index 0000000..f4381f2 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Variables/SharedTransformList.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 11f38abc81b11804aabe69ae80011a60 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Variables/SharedUInt.cs b/Assets/Behavior Designer/Runtime/Variables/SharedUInt.cs new file mode 100644 index 0000000..cd81297 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Variables/SharedUInt.cs @@ -0,0 +1,8 @@ +namespace BehaviorDesigner.Runtime +{ + [System.Serializable] + public class SharedUInt : SharedVariable + { + public static implicit operator SharedUInt(uint value) { return new SharedUInt { mValue = value }; } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Variables/SharedUInt.cs.meta b/Assets/Behavior Designer/Runtime/Variables/SharedUInt.cs.meta new file mode 100644 index 0000000..d1ed3fe --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Variables/SharedUInt.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: f63201b0b2f3043409fc893c5556cd35 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Variables/SharedVector2.cs b/Assets/Behavior Designer/Runtime/Variables/SharedVector2.cs new file mode 100644 index 0000000..46d0b30 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Variables/SharedVector2.cs @@ -0,0 +1,10 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime +{ + [System.Serializable] + public class SharedVector2 : SharedVariable + { + public static implicit operator SharedVector2(Vector2 value) { return new SharedVector2 { mValue = value }; } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Variables/SharedVector2.cs.meta b/Assets/Behavior Designer/Runtime/Variables/SharedVector2.cs.meta new file mode 100644 index 0000000..a6183af --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Variables/SharedVector2.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 2398d4531b638134384482dcac3e850c +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Variables/SharedVector2Int.cs b/Assets/Behavior Designer/Runtime/Variables/SharedVector2Int.cs new file mode 100644 index 0000000..85b1bcd --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Variables/SharedVector2Int.cs @@ -0,0 +1,10 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime +{ + [System.Serializable] + public class SharedVector2Int : SharedVariable + { + public static implicit operator SharedVector2Int(Vector2Int value) { return new SharedVector2Int { mValue = value }; } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Variables/SharedVector2Int.cs.meta b/Assets/Behavior Designer/Runtime/Variables/SharedVector2Int.cs.meta new file mode 100644 index 0000000..4cff0d9 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Variables/SharedVector2Int.cs.meta @@ -0,0 +1,12 @@ +fileFormatVersion: 2 +guid: 2030317e0987d01489996e3719960b2d +timeCreated: 1516763749 +licenseType: Store +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Behavior Designer/Runtime/Variables/SharedVector3.cs b/Assets/Behavior Designer/Runtime/Variables/SharedVector3.cs new file mode 100644 index 0000000..e78560a --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Variables/SharedVector3.cs @@ -0,0 +1,10 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime +{ + [System.Serializable] + public class SharedVector3 : SharedVariable + { + public static implicit operator SharedVector3(Vector3 value) { return new SharedVector3 { mValue = value }; } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Variables/SharedVector3.cs.meta b/Assets/Behavior Designer/Runtime/Variables/SharedVector3.cs.meta new file mode 100644 index 0000000..b6504c7 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Variables/SharedVector3.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 2093670c041663d4096c217e7c790683 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Behavior Designer/Runtime/Variables/SharedVector3Int.cs b/Assets/Behavior Designer/Runtime/Variables/SharedVector3Int.cs new file mode 100644 index 0000000..b811c17 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Variables/SharedVector3Int.cs @@ -0,0 +1,10 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime +{ + [System.Serializable] + public class SharedVector3Int : SharedVariable + { + public static implicit operator SharedVector3Int(Vector3Int value) { return new SharedVector3Int { mValue = value }; } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Variables/SharedVector3Int.cs.meta b/Assets/Behavior Designer/Runtime/Variables/SharedVector3Int.cs.meta new file mode 100644 index 0000000..14c9bc9 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Variables/SharedVector3Int.cs.meta @@ -0,0 +1,12 @@ +fileFormatVersion: 2 +guid: 6b50923655e14e64986162aa7f34d318 +timeCreated: 1516763759 +licenseType: Store +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Behavior Designer/Runtime/Variables/SharedVector4.cs b/Assets/Behavior Designer/Runtime/Variables/SharedVector4.cs new file mode 100644 index 0000000..8d7d439 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Variables/SharedVector4.cs @@ -0,0 +1,10 @@ +using UnityEngine; + +namespace BehaviorDesigner.Runtime +{ + [System.Serializable] + public class SharedVector4 : SharedVariable + { + public static implicit operator SharedVector4(Vector4 value) { return new SharedVector4 { mValue = value }; } + } +} \ No newline at end of file diff --git a/Assets/Behavior Designer/Runtime/Variables/SharedVector4.cs.meta b/Assets/Behavior Designer/Runtime/Variables/SharedVector4.cs.meta new file mode 100644 index 0000000..588e5b1 --- /dev/null +++ b/Assets/Behavior Designer/Runtime/Variables/SharedVector4.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: e12e4a2550a6e5f4aa39fdd59126ed66 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Demigiant.meta b/Assets/Demigiant.meta new file mode 100644 index 0000000..c683097 --- /dev/null +++ b/Assets/Demigiant.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: f126aa22382add04a928df7e660f235c +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DOTween.meta b/Assets/Demigiant/DOTween.meta new file mode 100644 index 0000000..12f704b --- /dev/null +++ b/Assets/Demigiant/DOTween.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: c07b12ece143f854f9344f036f5450dc +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DOTween/DOTween.XML b/Assets/Demigiant/DOTween/DOTween.XML new file mode 100644 index 0000000..d3bf9e1 --- /dev/null +++ b/Assets/Demigiant/DOTween/DOTween.XML @@ -0,0 +1,2554 @@ + + + + DOTween + + + + + Types of autoPlay behaviours + + + + No tween is automatically played + + + Only Sequences are automatically played + + + Only Tweeners are automatically played + + + All tweens are automatically played + + + + What axis to constrain in case of Vector tweens + + + + Called the first time the tween is set in a playing state, after any eventual delay + + + + Used in place of System.Func, which is not available in mscorlib. + + + + + Used in place of System.Action. + + + + + Public so it can be used by lose scripts related to DOTween (like DOTweenAnimation) + + + + + Used to separate DOTween class from the MonoBehaviour instance (in order to use static constructors on DOTween). + Contains all instance-based methods + + + + Used internally inside Unity Editor, as a trick to update DOTween's inspector at every frame + + + + Directly sets the current max capacity of Tweeners and Sequences + (meaning how many Tweeners and Sequences can be running at the same time), + so that DOTween doesn't need to automatically increase them in case the max is reached + (which might lead to hiccups when that happens). + Sequences capacity must be less or equal to Tweeners capacity + (if you pass a low Tweener capacity it will be automatically increased to match the Sequence's). + Beware: use this method only when there are no tweens running. + + Max Tweeners capacity. + Default: 200 + Max Sequences capacity. + Default: 50 + + + + This class contains a C# port of the easing equations created by Robert Penner (http://robertpenner.com/easing). + + + + + Easing equation function for a bounce (exponentially decaying parabolic bounce) easing in: accelerating from zero velocity. + + + Current time (in frames or seconds). + + + Expected easing duration (in frames or seconds). + + Unused: here to keep same delegate for all ease types. + Unused: here to keep same delegate for all ease types. + + The eased value. + + + + + Easing equation function for a bounce (exponentially decaying parabolic bounce) easing out: decelerating from zero velocity. + + + Current time (in frames or seconds). + + + Expected easing duration (in frames or seconds). + + Unused: here to keep same delegate for all ease types. + Unused: here to keep same delegate for all ease types. + + The eased value. + + + + + Easing equation function for a bounce (exponentially decaying parabolic bounce) easing in/out: acceleration until halfway, then deceleration. + + + Current time (in frames or seconds). + + + Expected easing duration (in frames or seconds). + + Unused: here to keep same delegate for all ease types. + Unused: here to keep same delegate for all ease types. + + The eased value. + + + + + Returns a value between 0 and 1 (inclusive) based on the elapsed time and ease selected + + + + + Returns a value between 0 and 1 (inclusive) based on the elapsed time and ease selected + + + + + Used to interpret AnimationCurves as eases. + Public so it can be used by external ease factories + + + + + Additional notices passed to plugins when updating. + Public so it can be used by custom plugins. Internally, only PathPlugin uses it + + + + + None + + + + + Lets the plugin know that we restarted or rewinded + + + + + OnRewind callback behaviour (can only be set via DOTween's Utility Panel) + + + + + When calling Rewind or PlayBackwards/SmoothRewind, OnRewind callbacks will be fired only if the tween isn't already rewinded + + + + + When calling Rewind, OnRewind callbacks will always be fired, even if the tween is already rewinded. + When calling PlayBackwards/SmoothRewind instead, OnRewind callbacks will be fired only if the tween isn't already rewinded + + + + + When calling Rewind or PlayBackwards/SmoothRewind, OnRewind callbacks will always be fired, even if the tween is already rewinded + + + + + Public only so custom shortcuts can access some of these methods + + + + + INTERNAL: used by DO shortcuts and Modules to set special startup mode + + + + + INTERNAL: used by DO shortcuts and Modules to set the tween as blendable + + + + + INTERNAL: used by DO shortcuts and Modules to prevent a tween from using a From setup even if passed + + + + + Used to dispatch commands that need to be captured externally, usually by Modules + + + + + Returns a Vector3 with z = 0 + + + + + Returns the 2D angle between two vectors + + + + + Uses approximate equality on each axis instead of Unity's Vector3 equality, + because the latter fails (in some cases) when assigning a Vector3 to a transform.position and then checking it. + + + + + Looks for the type withing all possible project assembly names + + + + + Struct that stores two colors (used for LineRenderer tweens) + + + + + Used for tween callbacks + + + + + Used for tween callbacks + + + + + Used for custom and animationCurve-based ease functions. Must return a value between 0 and 1. + + + + + Straight Quaternion plugin. Instead of using Vector3 values accepts Quaternion values directly. + Beware: doesn't work with LoopType.Incremental (neither directly nor if inside a LoopType.Incremental Sequence). + To use it, call DOTween.To with the plugin parameter overload, passing it PureQuaternionPlugin.Plug() as first parameter + (do not use any of the other public PureQuaternionPlugin methods): + DOTween.To(PureQuaternionPlugin.Plug(), ()=> myQuaternionProperty, x=> myQuaternionProperty = x, myQuaternionEndValue, duration); + + + + + Plug this plugin inside a DOTween.To call. + Example: + DOTween.To(PureQuaternionPlugin.Plug(), ()=> myQuaternionProperty, x=> myQuaternionProperty = x, myQuaternionEndValue, duration); + + + + INTERNAL: do not use + + + INTERNAL: do not use + + + INTERNAL: do not use + + + INTERNAL: do not use + + + INTERNAL: do not use + + + INTERNAL: do not use + + + INTERNAL: do not use + + + + Main DOTween class. Contains static methods to create and control tweens in a generic way + + + + DOTween's version + + + If TRUE (default) makes tweens slightly slower but safer, automatically taking care of a series of things + (like targets becoming null while a tween is playing). + Default: TRUE + + + If TRUE you will get a DOTween report when exiting play mode (only in the Editor). + Useful to know how many max Tweeners and Sequences you reached and optimize your final project accordingly. + Beware, this will slightly slow down your tweens while inside Unity Editor. + Default: FALSE + + + Global DOTween timeScale. + Default: 1 + + + If TRUE, DOTween will use Time.smoothDeltaTime instead of Time.deltaTime for UpdateType.Normal and UpdateType.Late tweens + (unless they're set as timeScaleIndependent, in which case a value between the last timestep + and will be used instead). + Setting this to TRUE will lead to smoother animations. + Default: FALSE + + + If is TRUE, this indicates the max timeStep that an independent update call can last. + Setting this to TRUE will lead to smoother animations. + Default: FALSE + + + DOTween's log behaviour. + Default: LogBehaviour.ErrorsOnly + + + If TRUE draws path gizmos in Unity Editor (if the gizmos button is active). + Deactivate this if you want to avoid gizmos overhead while in Unity Editor + + + Default updateType for new tweens. + Default: UpdateType.Normal + + + Sets whether Unity's timeScale should be taken into account by default or not. + Default: false + + + Default autoPlay behaviour for new tweens. + Default: AutoPlay.All + + + Default autoKillOnComplete behaviour for new tweens. + Default: TRUE + + + Default loopType applied to all new tweens. + Default: LoopType.Restart + + + If TRUE all newly created tweens are set as recyclable, otherwise not. + Default: FALSE + + + Default ease applied to all new Tweeners (not to Sequences which always have Ease.Linear as default). + Default: Ease.InOutQuad + + + Default overshoot/amplitude used for eases + Default: 1.70158f + + + Default period used for eases + Default: 0 + + + Used internally. Assigned/removed by DOTweenComponent.Create/DestroyInstance + + + + Must be called once, before the first ever DOTween call/reference, + otherwise it will be called automatically and will use default options. + Calling it a second time won't have any effect. + You can chain SetCapacity to this method, to directly set the max starting size of Tweeners and Sequences: + DOTween.Init(false, false, LogBehaviour.Default).SetCapacity(100, 20); + + If TRUE all new tweens will be set for recycling, meaning that when killed, + instead of being destroyed, they will be put in a pool and reused instead of creating new tweens. This option allows you to avoid + GC allocations by reusing tweens, but you will have to take care of tween references, since they might result active + even if they were killed (since they might have been respawned and are now being used for other tweens). + If you want to automatically set your tween references to NULL when a tween is killed + you can use the OnKill callback like this: + .OnKill(()=> myTweenReference = null) + You can change this setting at any time by changing the static property, + or you can set the recycling behaviour for each tween separately, using: + SetRecyclable(bool recyclable) + Default: FALSE + If TRUE makes tweens slightly slower but safer, automatically taking care of a series of things + (like targets becoming null while a tween is playing). + You can change this setting at any time by changing the static property. + Default: FALSE + Type of logging to use. + You can change this setting at any time by changing the static property. + Default: ErrorsOnly + + + + Directly sets the current max capacity of Tweeners and Sequences + (meaning how many Tweeners and Sequences can be running at the same time), + so that DOTween doesn't need to automatically increase them in case the max is reached + (which might lead to hiccups when that happens). + Sequences capacity must be less or equal to Tweeners capacity + (if you pass a low Tweener capacity it will be automatically increased to match the Sequence's). + Beware: use this method only when there are no tweens running. + + Max Tweeners capacity. + Default: 200 + Max Sequences capacity. + Default: 50 + + + + Kills all tweens, clears all cached tween pools and plugins and resets the max Tweeners/Sequences capacities to the default values. + + If TRUE also destroys DOTween's gameObject and resets its initializiation, default settings and everything else + (so that next time you use it it will need to be re-initialized) + + + + Clears all cached tween pools. + + + + + Checks all active tweens to find and remove eventually invalid ones (usually because their targets became NULL) + and returns the total number of invalid tweens found and removed. + IMPORTANT: this will cause an error on UWP platform, so don't use it there + BEWARE: this is a slightly expensive operation so use it with care + + + + + Updates all tweens that are set to . + + Manual deltaTime + Unscaled delta time (used with tweens set as timeScaleIndependent) + + + Tweens a property or field to the given value using default plugins + A getter for the field or property to tween. + Example usage with lambda:()=> myProperty + A setter for the field or property to tween + Example usage with lambda:x=> myProperty = x + The end value to reachThe tween's duration + + + Tweens a property or field to the given value using default plugins + A getter for the field or property to tween. + Example usage with lambda:()=> myProperty + A setter for the field or property to tween + Example usage with lambda:x=> myProperty = x + The end value to reachThe tween's duration + + + Tweens a property or field to the given value using default plugins + A getter for the field or property to tween. + Example usage with lambda:()=> myProperty + A setter for the field or property to tween + Example usage with lambda:x=> myProperty = x + The end value to reachThe tween's duration + + + Tweens a property or field to the given value using default plugins + A getter for the field or property to tween. + Example usage with lambda:()=> myProperty + A setter for the field or property to tween + Example usage with lambda:x=> myProperty = x + The end value to reachThe tween's duration + + + Tweens a property or field to the given value using default plugins + A getter for the field or property to tween. + Example usage with lambda:()=> myProperty + A setter for the field or property to tween + Example usage with lambda:x=> myProperty = x + The end value to reachThe tween's duration + + + Tweens a property or field to the given value using default plugins + A getter for the field or property to tween. + Example usage with lambda:()=> myProperty + A setter for the field or property to tween + Example usage with lambda:x=> myProperty = x + The end value to reachThe tween's duration + + + Tweens a property or field to the given value using default plugins + A getter for the field or property to tween. + Example usage with lambda:()=> myProperty + A setter for the field or property to tween + Example usage with lambda:x=> myProperty = x + The end value to reachThe tween's duration + + + Tweens a property or field to the given value using default plugins + A getter for the field or property to tween. + Example usage with lambda:()=> myProperty + A setter for the field or property to tween + Example usage with lambda:x=> myProperty = x + The end value to reachThe tween's duration + + + Tweens a property or field to the given value using default plugins + A getter for the field or property to tween. + Example usage with lambda:()=> myProperty + A setter for the field or property to tween + Example usage with lambda:x=> myProperty = x + The end value to reachThe tween's duration + + + Tweens a property or field to the given value using default plugins + A getter for the field or property to tween. + Example usage with lambda:()=> myProperty + A setter for the field or property to tween + Example usage with lambda:x=> myProperty = x + The end value to reachThe tween's duration + + + Tweens a property or field to the given value using default plugins + A getter for the field or property to tween. + Example usage with lambda:()=> myProperty + A setter for the field or property to tween + Example usage with lambda:x=> myProperty = x + The end value to reachThe tween's duration + + + Tweens a property or field to the given value using default plugins + A getter for the field or property to tween. + Example usage with lambda:()=> myProperty + A setter for the field or property to tween + Example usage with lambda:x=> myProperty = x + The end value to reachThe tween's duration + + + Tweens a property or field to the given value using default plugins + A getter for the field or property to tween. + Example usage with lambda:()=> myProperty + A setter for the field or property to tween + Example usage with lambda:x=> myProperty = x + The end value to reachThe tween's duration + + + Tweens a property or field to the given value using default plugins + A getter for the field or property to tween. + Example usage with lambda:()=> myProperty + A setter for the field or property to tween + Example usage with lambda:x=> myProperty = x + The end value to reachThe tween's duration + + + Tweens a property or field to the given value using a custom plugin + The plugin to use. Each custom plugin implements a static Get() method + you'll need to call to assign the correct plugin in the correct way, like this: + CustomPlugin.Get() + A getter for the field or property to tween. + Example usage with lambda:()=> myProperty + A setter for the field or property to tween + Example usage with lambda:x=> myProperty = x + The end value to reachThe tween's duration + + + Tweens only one axis of a Vector3 to the given value using default plugins. + A getter for the field or property to tween. + Example usage with lambda:()=> myProperty + A setter for the field or property to tween + Example usage with lambda:x=> myProperty = x + The end value to reachThe tween's duration + The axis to tween + + + Tweens only the alpha of a Color to the given value using default plugins + A getter for the field or property to tween. + Example usage with lambda:()=> myProperty + A setter for the field or property to tween + Example usage with lambda:x=> myProperty = x + The end value to reachThe tween's duration + + + Tweens a virtual property from the given start to the given end value + and implements a setter that allows to use that value with an external method or a lambda + Example: + To(MyMethod, 0, 12, 0.5f); + Where MyMethod is a function that accepts a float parameter (which will be the result of the virtual tween) + The action to perform with the tweened value + The value to start from + The end value to reach + The duration of the virtual tween + + + + Punches a Vector3 towards the given direction and then back to the starting one + as if it was connected to the starting position via an elastic. + This tween type generates some GC allocations at startup + A getter for the field or property to tween. + Example usage with lambda:()=> myProperty + A setter for the field or property to tween + Example usage with lambda:x=> myProperty = x + The direction and strength of the punch + The duration of the tween + Indicates how much will the punch vibrate + Represents how much (0 to 1) the vector will go beyond the starting position when bouncing backwards. + 1 creates a full oscillation between the direction and the opposite decaying direction, + while 0 oscillates only between the starting position and the decaying direction + + + Shakes a Vector3 with the given values. + A getter for the field or property to tween. + Example usage with lambda:()=> myProperty + A setter for the field or property to tween + Example usage with lambda:x=> myProperty = x + The duration of the tween + The shake strength + Indicates how much will the shake vibrate + Indicates how much the shake will be random (0 to 180 - values higher than 90 kind of suck, so beware). + Setting it to 0 will shake along a single direction and behave like a random punch. + If TRUE only shakes on the X Y axis (looks better with things like cameras). + If TRUE the shake will automatically fadeOut smoothly within the tween's duration, otherwise it will not + + + Shakes a Vector3 with the given values. + A getter for the field or property to tween. + Example usage with lambda:()=> myProperty + A setter for the field or property to tween + Example usage with lambda:x=> myProperty = x + The duration of the tween + The shake strength on each axis + Indicates how much will the shake vibrate + Indicates how much the shake will be random (0 to 180 - values higher than 90 kind of suck, so beware). + Setting it to 0 will shake along a single direction and behave like a random punch. + If TRUE the shake will automatically fadeOut smoothly within the tween's duration, otherwise it will not + + + Tweens a property or field to the given values using default plugins. + Ease is applied between each segment and not as a whole. + This tween type generates some GC allocations at startup + A getter for the field or property to tween. + Example usage with lambda:()=> myProperty + A setter for the field or property to tween + Example usage with lambda:x=> myProperty = x + The end values to reach for each segment. This array must have the same length as durations + The duration of each segment. This array must have the same length as endValues + + + + Returns a new to be used for tween groups + + + + Completes all tweens and returns the number of actual tweens completed + (meaning tweens that don't have infinite loops and were not already complete) + For Sequences only: if TRUE also internal Sequence callbacks will be fired, + otherwise they will be ignored + + + Completes all tweens with the given ID or target and returns the number of actual tweens completed + (meaning the tweens that don't have infinite loops and were not already complete) + For Sequences only: if TRUE internal Sequence callbacks will be fired, + otherwise they will be ignored + + + Flips all tweens (changing their direction to forward if it was backwards and viceversa), + then returns the number of actual tweens flipped + + + Flips the tweens with the given ID or target (changing their direction to forward if it was backwards and viceversa), + then returns the number of actual tweens flipped + + + Sends all tweens to the given position (calculating also eventual loop cycles) and returns the actual tweens involved + + + Sends all tweens with the given ID or target to the given position (calculating also eventual loop cycles) + and returns the actual tweens involved + + + Kills all tweens and returns the number of actual tweens killed + If TRUE completes the tweens before killing them + + + Kills all tweens and returns the number of actual tweens killed + If TRUE completes the tweens before killing them + Eventual IDs or targets to exclude from the killing + + + Kills all tweens with the given ID or target and returns the number of actual tweens killed + If TRUE completes the tweens before killing them + + + Pauses all tweens and returns the number of actual tweens paused + + + Pauses all tweens with the given ID or target and returns the number of actual tweens paused + (meaning the tweens that were actually playing and have been paused) + + + Plays all tweens and returns the number of actual tweens played + (meaning tweens that were not already playing or complete) + + + Plays all tweens with the given ID or target and returns the number of actual tweens played + (meaning the tweens that were not already playing or complete) + + + Plays all tweens with the given target and the given ID, and returns the number of actual tweens played + (meaning the tweens that were not already playing or complete) + + + Plays backwards all tweens and returns the number of actual tweens played + (meaning tweens that were not already started, playing backwards or rewinded) + + + Plays backwards all tweens with the given ID or target and returns the number of actual tweens played + (meaning the tweens that were not already started, playing backwards or rewinded) + + + Plays backwards all tweens with the given target and ID and returns the number of actual tweens played + (meaning the tweens that were not already started, playing backwards or rewinded) + + + Plays forward all tweens and returns the number of actual tweens played + (meaning tweens that were not already playing forward or complete) + + + Plays forward all tweens with the given ID or target and returns the number of actual tweens played + (meaning the tweens that were not already playing forward or complete) + + + Plays forward all tweens with the given target and ID and returns the number of actual tweens played + (meaning the tweens that were not already started, playing backwards or rewinded) + + + Restarts all tweens, then returns the number of actual tweens restarted + + + Restarts all tweens with the given ID or target, then returns the number of actual tweens restarted + If TRUE includes the eventual tweens delays, otherwise skips them + If >= 0 changes the startup delay of all involved tweens to this value, otherwise doesn't touch it + + + Restarts all tweens with the given target and the given ID, and returns the number of actual tweens played + (meaning the tweens that were not already playing or complete) + If TRUE includes the eventual tweens delays, otherwise skips them + If >= 0 changes the startup delay of all involved tweens to this value, otherwise doesn't touch it + + + Rewinds and pauses all tweens, then returns the number of actual tweens rewinded + (meaning tweens that were not already rewinded) + + + Rewinds and pauses all tweens with the given ID or target, then returns the number of actual tweens rewinded + (meaning the tweens that were not already rewinded) + + + Smoothly rewinds all tweens (delays excluded), then returns the number of actual tweens rewinding/rewinded + (meaning tweens that were not already rewinded). + A "smooth rewind" animates the tween to its start position, + skipping all elapsed loops (except in case of LoopType.Incremental) while keeping the animation fluent. + Note that a tween that was smoothly rewinded will have its play direction flipped + + + Smoothly rewinds all tweens (delays excluded) with the given ID or target, then returns the number of actual tweens rewinding/rewinded + (meaning the tweens that were not already rewinded). + A "smooth rewind" animates the tween to its start position, + skipping all elapsed loops (except in case of LoopType.Incremental) while keeping the animation fluent. + Note that a tween that was smoothly rewinded will have its play direction flipped + + + Toggles the play state of all tweens and returns the number of actual tweens toggled + (meaning tweens that could be played or paused, depending on the toggle state) + + + Toggles the play state of all tweens with the given ID or target and returns the number of actual tweens toggled + (meaning the tweens that could be played or paused, depending on the toggle state) + + + + Returns TRUE if a tween with the given ID or target is active. + You can also use this to know if a shortcut tween is active for a given target. + Example: + transform.DOMoveX(45, 1); // transform is automatically added as the tween target + DOTween.IsTweening(transform); // Returns true + + The target or ID to look for + If FALSE (default) returns TRUE as long as a tween for the given target/ID is active, + otherwise also requires it to be playing + + + + Returns the total number of active and playing tweens. + A tween is considered as playing even if its delay is actually playing + + + + + Returns a list of all active tweens in a playing state. + Returns NULL if there are no active playing tweens. + Beware: each time you call this method a new list is generated, so use it for debug only + + If NULL creates a new list, otherwise clears and fills this one (and thus saves allocations) + + + + Returns a list of all active tweens in a paused state. + Returns NULL if there are no active paused tweens. + Beware: each time you call this method a new list is generated, so use it for debug only + + If NULL creates a new list, otherwise clears and fills this one (and thus saves allocations) + + + + Returns a list of all active tweens with the given id. + Returns NULL if there are no active tweens with the given id. + Beware: each time you call this method a new list is generated + + If TRUE returns only the tweens with the given ID that are currently playing + If NULL creates a new list, otherwise clears and fills this one (and thus saves allocations) + + + + Returns a list of all active tweens with the given target. + Returns NULL if there are no active tweens with the given target. + Beware: each time you call this method a new list is generated + If TRUE returns only the tweens with the given target that are currently playing + If NULL creates a new list, otherwise clears and fills this one (and thus saves allocations) + + + + + Creates virtual tweens that can be used to change other elements via their OnUpdate calls + + + + + Tweens a virtual float. + You can add regular settings to the generated tween, + but do not use SetUpdate or you will overwrite the onVirtualUpdate parameter + + The value to start from + The value to tween to + The duration of the tween + A callback which must accept a parameter of type float, called at each update + + + + Returns a value based on the given ease and lifetime percentage (0 to 1) + The value to start from when lifetimePercentage is 0 + The value to reach when lifetimePercentage is 1 + The time percentage (0 to 1) at which the value should be taken + The type of ease + + + Returns a value based on the given ease and lifetime percentage (0 to 1) + The value to start from when lifetimePercentage is 0 + The value to reach when lifetimePercentage is 1 + The time percentage (0 to 1) at which the value should be taken + The type of ease + Eventual overshoot to use with Back ease + + + Returns a value based on the given ease and lifetime percentage (0 to 1) + The value to start from when lifetimePercentage is 0 + The value to reach when lifetimePercentage is 1 + The time percentage (0 to 1) at which the value should be taken + The type of ease + Eventual amplitude to use with Elastic easeType + Eventual period to use with Elastic easeType + + + Returns a value based on the given ease and lifetime percentage (0 to 1) + The value to start from when lifetimePercentage is 0 + The value to reach when lifetimePercentage is 1 + The time percentage (0 to 1) at which the value should be taken + The AnimationCurve to use for ease + + + Fires the given callback after the given time. + Callback delay + Callback to fire when the delay has expired + If TRUE (default) ignores Unity's timeScale + + + + Don't assign this! It's assigned automatically when creating 0 duration tweens + + + + + Don't assign this! It's assigned automatically when setting the ease to an AnimationCurve or to a custom ease function + + + + + Allows to wrap ease method in special ways, adding extra features + + + + + Converts the given ease so that it also creates a stop-motion effect, by playing the tween at the given FPS + + FPS at which the tween should be played + Ease type + + + + Converts the given ease so that it also creates a stop-motion effect, by playing the tween at the given FPS + + FPS at which the tween should be played + AnimationCurve to use for the ease + + + + Converts the given ease so that it also creates a stop-motion effect, by playing the tween at the given FPS + + FPS at which the tween should be played + Custom ease function to use + + + + Used to allow method chaining with DOTween.Init + + + + + Directly sets the current max capacity of Tweeners and Sequences + (meaning how many Tweeners and Sequences can be running at the same time), + so that DOTween doesn't need to automatically increase them in case the max is reached + (which might lead to hiccups when that happens). + Sequences capacity must be less or equal to Tweeners capacity + (if you pass a low Tweener capacity it will be automatically increased to match the Sequence's). + Beware: use this method only when there are no tweens running. + + Max Tweeners capacity. + Default: 200 + Max Sequences capacity. + Default: 50 + + + + Path mode (used to determine correct LookAt orientation) + + + + Ignores the path mode (and thus LookAt behaviour) + + + Regular 3D path + + + 2D top-down path + + + 2D side-scroller path + + + + Type of path to use with DOPath tweens + + + + Linear, composed of straight segments between each waypoint + + + Curved path (which uses Catmull-Rom curves) + + + + Path control point + + + + + Gets the point on the path at the given percentage (0 to 1) + + The percentage (0 to 1) at which to get the point + If TRUE constant speed is taken into account, otherwise not + + + + Base interface for all tween plugins options + + + + Resets the plugin + + + + This plugin generates some GC allocations at startup + + + + + Path plugin works exclusively with Transforms + + + + + Rotation mode used with DORotate methods + + + + + Fastest way that never rotates beyond 360° + + + + + Fastest way that rotates beyond 360° + + + + + Adds the given rotation to the transform using world axis and an advanced precision mode + (like when using transform.Rotate(Space.World)). + In this mode the end value is is always considered relative + + + + + Adds the given rotation to the transform's local axis + (like when rotating an object with the "local" switch enabled in Unity's editor or using transform.Rotate(Space.Self)). + In this mode the end value is is always considered relative + + + + + Type of scramble to apply to string tweens + + + + + No scrambling of characters + + + + + A-Z + a-z + 0-9 characters + + + + + A-Z characters + + + + + a-z characters + + + + + 0-9 characters + + + + + Custom characters + + + + + Methods that extend Tween objects and allow to control or get data from them + + + + Completes the tween + + + Completes the tween + For Sequences only: if TRUE also internal Sequence callbacks will be fired, + otherwise they will be ignored + + + Flips the direction of this tween (backwards if it was going forward or viceversa) + + + Forces the tween to initialize its settings immediately + + + Send the tween to the given position in time + Time position to reach + (if higher than the whole tween duration the tween will simply reach its end) + If TRUE will play the tween after reaching the given position, otherwise it will pause it + + + Kills the tween + If TRUE completes the tween before killing it + + + Pauses the tween + + + Plays the tween + + + Sets the tween in a backwards direction and plays it + + + Sets the tween in a forward direction and plays it + + + Restarts the tween from the beginning + If TRUE includes the eventual tween delay, otherwise skips it + If >= 0 changes the startup delay to this value, otherwise doesn't touch it + + + Rewinds and pauses the tween + If TRUE includes the eventual tween delay, otherwise skips it + + + Smoothly rewinds the tween (delays excluded). + A "smooth rewind" animates the tween to its start position, + skipping all elapsed loops (except in case of LoopType.Incremental) while keeping the animation fluent. + If called on a tween who is still waiting for its delay to happen, it will simply set the delay to 0 and pause the tween. + Note that a tween that was smoothly rewinded will have its play direction flipped + + + Plays the tween if it was paused, pauses it if it was playing + + + Send a path tween to the given waypoint. + Has no effect if this is not a path tween. + BEWARE, this is a special utility method: + it works only with Linear eases. Also, the lookAt direction might be wrong after calling this and might need to be set manually + (because it relies on a smooth path movement and doesn't work well with jumps that encompass dramatic direction changes) + Waypoint index to reach + (if higher than the max waypoint index the tween will simply go to the last one) + If TRUE will play the tween after reaching the given waypoint, otherwise it will pause it + + + + Creates a yield instruction that waits until the tween is killed or complete. + It can be used inside a coroutine as a yield. + Example usage:yield return myTween.WaitForCompletion(); + + + + + Creates a yield instruction that waits until the tween is killed or rewinded. + It can be used inside a coroutine as a yield. + Example usage:yield return myTween.WaitForRewind(); + + + + + Creates a yield instruction that waits until the tween is killed. + It can be used inside a coroutine as a yield. + Example usage:yield return myTween.WaitForKill(); + + + + + Creates a yield instruction that waits until the tween is killed or has gone through the given amount of loops. + It can be used inside a coroutine as a yield. + Example usage:yield return myTween.WaitForElapsedLoops(2); + + Elapsed loops to wait for + + + + Creates a yield instruction that waits until the tween is killed or has reached the given position (loops included, delays excluded). + It can be used inside a coroutine as a yield. + Example usage:yield return myTween.WaitForPosition(2.5f); + + Position (loops included, delays excluded) to wait for + + + + Creates a yield instruction that waits until the tween is killed or started + (meaning when the tween is set in a playing state the first time, after any eventual delay). + It can be used inside a coroutine as a yield. + Example usage:yield return myTween.WaitForStart(); + + + + Returns the total number of loops completed by this tween + + + Returns the eventual delay set for this tween + + + Returns the duration of this tween (delays excluded). + NOTE: when using settings like SpeedBased, the duration will be recalculated when the tween starts + If TRUE returns the full duration loops included, + otherwise the duration of a single loop cycle + + + Returns the elapsed time for this tween (delays exluded) + If TRUE returns the elapsed time since startup loops included, + otherwise the elapsed time within the current loop cycle + + + Returns the elapsed percentage (0 to 1) of this tween (delays exluded) + If TRUE returns the elapsed percentage since startup loops included, + otherwise the elapsed percentage within the current loop cycle + + + Returns the elapsed percentage (0 to 1) of this tween (delays exluded), + based on a single loop, and calculating eventual backwards Yoyo loops as 1 to 0 instead of 0 to 1 + + + Returns FALSE if this tween has been killed. + BEWARE: if this tween is recyclable it might have been spawned again for another use and thus return TRUE anyway. + When working with recyclable tweens you should take care to know when a tween has been killed and manually set your references to NULL. + If you want to be sure your references are set to NULL when a tween is killed you can use the OnKill callback like this: + .OnKill(()=> myTweenReference = null) + + + Returns TRUE if this tween was reversed and is set to go backwards + + + Returns TRUE if the tween is complete + (silently fails and returns FALSE if the tween has been killed) + + + Returns TRUE if this tween has been initialized + + + Returns TRUE if this tween is playing + + + Returns the total number of loops set for this tween + (returns -1 if the loops are infinite) + + + + Returns a point on a path based on the given path percentage. + Returns Vector3.zero if this is not a path tween, if the tween is invalid, or if the path is not yet initialized. + A path is initialized after its tween starts, or immediately if the tween was created with the Path Editor (DOTween Pro feature). + You can force a path to be initialized by calling myTween.ForceInit(). + + Percentage of the path (0 to 1) on which to get the point + + + + Returns an array of points that can be used to draw the path. + Note that this method generates allocations, because it creates a new array. + Returns NULL if this is not a path tween, if the tween is invalid, or if the path is not yet initialized. + A path is initialized after its tween starts, or immediately if the tween was created with the Path Editor (DOTween Pro feature). + You can force a path to be initialized by calling myTween.ForceInit(). + + How many points to create for each path segment (waypoint to waypoint). + Only used in case of non-Linear paths + + + + Returns the length of a path. + Returns -1 if this is not a path tween, if the tween is invalid, or if the path is not yet initialized. + A path is initialized after its tween starts, or immediately if the tween was created with the Path Editor (DOTween Pro feature). + You can force a path to be initialized by calling myTween.ForceInit(). + + + + + Types of loop + + + + Each loop cycle restarts from the beginning + + + The tween moves forward and backwards at alternate cycles + + + Continuously increments the tween at the end of each loop cycle (A to B, B to B+(A-B), and so on), thus always moving "onward". + In case of String tweens works only if the tween is set as relative + + + + Controls other tweens as a group + + + + + Methods that extend known Unity objects and allow to directly create and control tweens from their instances + + + + Tweens a Camera's aspect to the given value. + Also stores the camera as the tween's target so it can be used for filtered operations + The end value to reachThe duration of the tween + + + Tweens a Camera's backgroundColor to the given value. + Also stores the camera as the tween's target so it can be used for filtered operations + The end value to reachThe duration of the tween + + + Tweens a Camera's farClipPlane to the given value. + Also stores the camera as the tween's target so it can be used for filtered operations + The end value to reachThe duration of the tween + + + Tweens a Camera's fieldOfView to the given value. + Also stores the camera as the tween's target so it can be used for filtered operations + The end value to reachThe duration of the tween + + + Tweens a Camera's nearClipPlane to the given value. + Also stores the camera as the tween's target so it can be used for filtered operations + The end value to reachThe duration of the tween + + + Tweens a Camera's orthographicSize to the given value. + Also stores the camera as the tween's target so it can be used for filtered operations + The end value to reachThe duration of the tween + + + Tweens a Camera's pixelRect to the given value. + Also stores the camera as the tween's target so it can be used for filtered operations + The end value to reachThe duration of the tween + + + Tweens a Camera's rect to the given value. + Also stores the camera as the tween's target so it can be used for filtered operations + The end value to reachThe duration of the tween + + + Shakes a Camera's localPosition along its relative X Y axes with the given values. + Also stores the camera as the tween's target so it can be used for filtered operations + The duration of the tween + The shake strength + Indicates how much will the shake vibrate + Indicates how much the shake will be random (0 to 180 - values higher than 90 kind of suck, so beware). + Setting it to 0 will shake along a single direction. + If TRUE the shake will automatically fadeOut smoothly within the tween's duration, otherwise it will not + + + Shakes a Camera's localPosition along its relative X Y axes with the given values. + Also stores the camera as the tween's target so it can be used for filtered operations + The duration of the tween + The shake strength on each axis + Indicates how much will the shake vibrate + Indicates how much the shake will be random (0 to 180 - values higher than 90 kind of suck, so beware). + Setting it to 0 will shake along a single direction. + If TRUE the shake will automatically fadeOut smoothly within the tween's duration, otherwise it will not + + + Shakes a Camera's localRotation. + Also stores the camera as the tween's target so it can be used for filtered operations + The duration of the tween + The shake strength + Indicates how much will the shake vibrate + Indicates how much the shake will be random (0 to 180 - values higher than 90 kind of suck, so beware). + Setting it to 0 will shake along a single direction. + If TRUE the shake will automatically fadeOut smoothly within the tween's duration, otherwise it will not + + + Shakes a Camera's localRotation. + Also stores the camera as the tween's target so it can be used for filtered operations + The duration of the tween + The shake strength on each axis + Indicates how much will the shake vibrate + Indicates how much the shake will be random (0 to 180 - values higher than 90 kind of suck, so beware). + Setting it to 0 will shake along a single direction. + If TRUE the shake will automatically fadeOut smoothly within the tween's duration, otherwise it will not + + + Tweens a Light's color to the given value. + Also stores the light as the tween's target so it can be used for filtered operations + The end value to reachThe duration of the tween + + + Tweens a Light's intensity to the given value. + Also stores the light as the tween's target so it can be used for filtered operations + The end value to reachThe duration of the tween + + + Tweens a Light's shadowStrength to the given value. + Also stores the light as the tween's target so it can be used for filtered operations + The end value to reachThe duration of the tween + + + Tweens a LineRenderer's color to the given value. + Also stores the LineRenderer as the tween's target so it can be used for filtered operations. + Note that this method requires to also insert the start colors for the tween, + since LineRenderers have no way to get them. + The start value to tween from + The end value to reachThe duration of the tween + + + Tweens a Material's color to the given value. + Also stores the material as the tween's target so it can be used for filtered operations + The end value to reachThe duration of the tween + + + Tweens a Material's named color property to the given value. + Also stores the material as the tween's target so it can be used for filtered operations + The end value to reach + The name of the material property to tween (like _Tint or _SpecColor) + The duration of the tween + + + Tweens a Material's alpha color to the given value + (will have no effect unless your material supports transparency). + Also stores the material as the tween's target so it can be used for filtered operations + The end value to reachThe duration of the tween + + + Tweens a Material's alpha color to the given value + (will have no effect unless your material supports transparency). + Also stores the material as the tween's target so it can be used for filtered operations + The end value to reach + The name of the material property to tween (like _Tint or _SpecColor) + The duration of the tween + + + Tweens a Material's named float property to the given value. + Also stores the material as the tween's target so it can be used for filtered operations + The end value to reach + The name of the material property to tween + The duration of the tween + + + Tweens a Material's texture offset to the given value. + Also stores the material as the tween's target so it can be used for filtered operations + The end value to reach + The duration of the tween + + + Tweens a Material's named texture offset property to the given value. + Also stores the material as the tween's target so it can be used for filtered operations + The end value to reach + The name of the material property to tween + The duration of the tween + + + Tweens a Material's texture scale to the given value. + Also stores the material as the tween's target so it can be used for filtered operations + The end value to reach + The duration of the tween + + + Tweens a Material's named texture scale property to the given value. + Also stores the material as the tween's target so it can be used for filtered operations + The end value to reach + The name of the material property to tween + The duration of the tween + + + Tweens a Material's named Vector property to the given value. + Also stores the material as the tween's target so it can be used for filtered operations + The end value to reach + The name of the material property to tween + The duration of the tween + + + Tweens a TrailRenderer's startWidth/endWidth to the given value. + Also stores the TrailRenderer as the tween's target so it can be used for filtered operations + The end startWidth to reachThe end endWidth to reach + The duration of the tween + + + Tweens a TrailRenderer's time to the given value. + Also stores the TrailRenderer as the tween's target so it can be used for filtered operations + The end value to reachThe duration of the tween + + + Tweens a Transform's position to the given value. + Also stores the transform as the tween's target so it can be used for filtered operations + The end value to reachThe duration of the tween + If TRUE the tween will smoothly snap all values to integers + + + Tweens a Transform's X position to the given value. + Also stores the transform as the tween's target so it can be used for filtered operations + The end value to reachThe duration of the tween + If TRUE the tween will smoothly snap all values to integers + + + Tweens a Transform's Y position to the given value. + Also stores the transform as the tween's target so it can be used for filtered operations + The end value to reachThe duration of the tween + If TRUE the tween will smoothly snap all values to integers + + + Tweens a Transform's Z position to the given value. + Also stores the transform as the tween's target so it can be used for filtered operations + The end value to reachThe duration of the tween + If TRUE the tween will smoothly snap all values to integers + + + Tweens a Transform's localPosition to the given value. + Also stores the transform as the tween's target so it can be used for filtered operations + The end value to reachThe duration of the tween + If TRUE the tween will smoothly snap all values to integers + + + Tweens a Transform's X localPosition to the given value. + Also stores the transform as the tween's target so it can be used for filtered operations + The end value to reachThe duration of the tween + If TRUE the tween will smoothly snap all values to integers + + + Tweens a Transform's Y localPosition to the given value. + Also stores the transform as the tween's target so it can be used for filtered operations + The end value to reachThe duration of the tween + If TRUE the tween will smoothly snap all values to integers + + + Tweens a Transform's Z localPosition to the given value. + Also stores the transform as the tween's target so it can be used for filtered operations + The end value to reachThe duration of the tween + If TRUE the tween will smoothly snap all values to integers + + + Tweens a Transform's rotation to the given value. + Also stores the transform as the tween's target so it can be used for filtered operations + The end value to reachThe duration of the tween + Rotation mode + + + Tweens a Transform's rotation to the given value using pure quaternion values. + Also stores the transform as the tween's target so it can be used for filtered operations. + PLEASE NOTE: DORotate, which takes Vector3 values, is the preferred rotation method. + This method was implemented for very special cases, and doesn't support LoopType.Incremental loops + (neither for itself nor if placed inside a LoopType.Incremental Sequence) + + The end value to reachThe duration of the tween + + + Tweens a Transform's localRotation to the given value. + Also stores the transform as the tween's target so it can be used for filtered operations + The end value to reachThe duration of the tween + Rotation mode + + + Tweens a Transform's rotation to the given value using pure quaternion values. + Also stores the transform as the tween's target so it can be used for filtered operations. + PLEASE NOTE: DOLocalRotate, which takes Vector3 values, is the preferred rotation method. + This method was implemented for very special cases, and doesn't support LoopType.Incremental loops + (neither for itself nor if placed inside a LoopType.Incremental Sequence) + + The end value to reachThe duration of the tween + + + Tweens a Transform's localScale to the given value. + Also stores the transform as the tween's target so it can be used for filtered operations + The end value to reachThe duration of the tween + + + Tweens a Transform's localScale uniformly to the given value. + Also stores the transform as the tween's target so it can be used for filtered operations + The end value to reachThe duration of the tween + + + Tweens a Transform's X localScale to the given value. + Also stores the transform as the tween's target so it can be used for filtered operations + The end value to reachThe duration of the tween + + + Tweens a Transform's Y localScale to the given value. + Also stores the transform as the tween's target so it can be used for filtered operations + The end value to reachThe duration of the tween + + + Tweens a Transform's Z localScale to the given value. + Also stores the transform as the tween's target so it can be used for filtered operations + The end value to reachThe duration of the tween + + + Tweens a Transform's rotation so that it will look towards the given position. + Also stores the transform as the tween's target so it can be used for filtered operations + The position to look atThe duration of the tween + Eventual axis constraint for the rotation + The vector that defines in which direction up is (default: Vector3.up) + + + Punches a Transform's localPosition towards the given direction and then back to the starting one + as if it was connected to the starting position via an elastic. + The direction and strength of the punch (added to the Transform's current position) + The duration of the tween + Indicates how much will the punch vibrate + Represents how much (0 to 1) the vector will go beyond the starting position when bouncing backwards. + 1 creates a full oscillation between the punch direction and the opposite direction, + while 0 oscillates only between the punch and the start position + If TRUE the tween will smoothly snap all values to integers + + + Punches a Transform's localScale towards the given size and then back to the starting one + as if it was connected to the starting scale via an elastic. + The punch strength (added to the Transform's current scale) + The duration of the tween + Indicates how much will the punch vibrate + Represents how much (0 to 1) the vector will go beyond the starting size when bouncing backwards. + 1 creates a full oscillation between the punch scale and the opposite scale, + while 0 oscillates only between the punch scale and the start scale + + + Punches a Transform's localRotation towards the given size and then back to the starting one + as if it was connected to the starting rotation via an elastic. + The punch strength (added to the Transform's current rotation) + The duration of the tween + Indicates how much will the punch vibrate + Represents how much (0 to 1) the vector will go beyond the starting rotation when bouncing backwards. + 1 creates a full oscillation between the punch rotation and the opposite rotation, + while 0 oscillates only between the punch and the start rotation + + + Shakes a Transform's localPosition with the given values. + The duration of the tween + The shake strength + Indicates how much will the shake vibrate + Indicates how much the shake will be random (0 to 180 - values higher than 90 kind of suck, so beware). + Setting it to 0 will shake along a single direction. + If TRUE the tween will smoothly snap all values to integers + If TRUE the shake will automatically fadeOut smoothly within the tween's duration, otherwise it will not + + + Shakes a Transform's localPosition with the given values. + The duration of the tween + The shake strength on each axis + Indicates how much will the shake vibrate + Indicates how much the shake will be random (0 to 180 - values higher than 90 kind of suck, so beware). + Setting it to 0 will shake along a single direction. + If TRUE the tween will smoothly snap all values to integers + If TRUE the shake will automatically fadeOut smoothly within the tween's duration, otherwise it will not + + + Shakes a Transform's localRotation. + The duration of the tween + The shake strength + Indicates how much will the shake vibrate + Indicates how much the shake will be random (0 to 180 - values higher than 90 kind of suck, so beware). + Setting it to 0 will shake along a single direction. + If TRUE the shake will automatically fadeOut smoothly within the tween's duration, otherwise it will not + + + Shakes a Transform's localRotation. + The duration of the tween + The shake strength on each axis + Indicates how much will the shake vibrate + Indicates how much the shake will be random (0 to 180 - values higher than 90 kind of suck, so beware). + Setting it to 0 will shake along a single direction. + If TRUE the shake will automatically fadeOut smoothly within the tween's duration, otherwise it will not + + + Shakes a Transform's localScale. + The duration of the tween + The shake strength + Indicates how much will the shake vibrate + Indicates how much the shake will be random (0 to 180 - values higher than 90 kind of suck, so beware). + Setting it to 0 will shake along a single direction. + If TRUE the shake will automatically fadeOut smoothly within the tween's duration, otherwise it will not + + + Shakes a Transform's localScale. + The duration of the tween + The shake strength on each axis + Indicates how much will the shake vibrate + Indicates how much the shake will be random (0 to 180 - values higher than 90 kind of suck, so beware). + Setting it to 0 will shake along a single direction. + If TRUE the shake will automatically fadeOut smoothly within the tween's duration, otherwise it will not + + + Tweens a Transform's position to the given value, while also applying a jump effect along the Y axis. + Returns a Sequence instead of a Tweener. + Also stores the transform as the tween's target so it can be used for filtered operations + The end value to reach + Power of the jump (the max height of the jump is represented by this plus the final Y offset) + Total number of jumps + The duration of the tween + If TRUE the tween will smoothly snap all values to integers + + + Tweens a Transform's localPosition to the given value, while also applying a jump effect along the Y axis. + Returns a Sequence instead of a Tweener. + Also stores the transform as the tween's target so it can be used for filtered operations + The end value to reach + Power of the jump (the max height of the jump is represented by this plus the final Y offset) + Total number of jumps + The duration of the tween + If TRUE the tween will smoothly snap all values to integers + + + Tweens a Transform's position through the given path waypoints, using the chosen path algorithm. + Also stores the transform as the tween's target so it can be used for filtered operations + The waypoints to go through + The duration of the tween + The type of path: Linear (straight path) or CatmullRom (curved CatmullRom path) + The path mode: 3D, side-scroller 2D, top-down 2D + The resolution of the path (useless in case of Linear paths): higher resolutions make for more detailed curved paths but are more expensive. + Defaults to 10, but a value of 5 is usually enough if you don't have dramatic long curves between waypoints + The color of the path (shown when gizmos are active in the Play panel and the tween is running) + + + Tweens a Transform's localPosition through the given path waypoints, using the chosen path algorithm. + Also stores the transform as the tween's target so it can be used for filtered operations + The waypoint to go through + The duration of the tween + The type of path: Linear (straight path) or CatmullRom (curved CatmullRom path) + The path mode: 3D, side-scroller 2D, top-down 2D + The resolution of the path: higher resolutions make for more detailed curved paths but are more expensive. + Defaults to 10, but a value of 5 is usually enough if you don't have dramatic long curves between waypoints + The color of the path (shown when gizmos are active in the Play panel and the tween is running) + + + IMPORTANT: Unless you really know what you're doing, you should use the overload that accepts a Vector3 array instead. + Tweens a Transform's position via the given path. + Also stores the transform as the tween's target so it can be used for filtered operations + The path to use + The duration of the tween + The path mode: 3D, side-scroller 2D, top-down 2D + + + IMPORTANT: Unless you really know what you're doing, you should use the overload that accepts a Vector3 array instead. + Tweens a Transform's localPosition via the given path. + Also stores the transform as the tween's target so it can be used for filtered operations + The path to use + The duration of the tween + The path mode: 3D, side-scroller 2D, top-down 2D + + + Tweens a Tween's timeScale to the given value. + Also stores the Tween as the tween's target so it can be used for filtered operations + The end value to reachThe duration of the tween + + + Tweens a Light's color to the given value, + in a way that allows other DOBlendableColor tweens to work together on the same target, + instead than fight each other as multiple DOColor would do. + Also stores the Light as the tween's target so it can be used for filtered operations + The value to tween toThe duration of the tween + + + Tweens a Material's color to the given value, + in a way that allows other DOBlendableColor tweens to work together on the same target, + instead than fight each other as multiple DOColor would do. + Also stores the Material as the tween's target so it can be used for filtered operations + The value to tween toThe duration of the tween + + + Tweens a Material's named color property to the given value, + in a way that allows other DOBlendableColor tweens to work together on the same target, + instead than fight each other as multiple DOColor would do. + Also stores the Material as the tween's target so it can be used for filtered operations + The value to tween to + The name of the material property to tween (like _Tint or _SpecColor) + The duration of the tween + + + Tweens a Transform's position BY the given value (as if you chained a SetRelative), + in a way that allows other DOBlendableMove tweens to work together on the same target, + instead than fight each other as multiple DOMove would do. + Also stores the transform as the tween's target so it can be used for filtered operations + The value to tween byThe duration of the tween + If TRUE the tween will smoothly snap all values to integers + + + Tweens a Transform's localPosition BY the given value (as if you chained a SetRelative), + in a way that allows other DOBlendableMove tweens to work together on the same target, + instead than fight each other as multiple DOMove would do. + Also stores the transform as the tween's target so it can be used for filtered operations + The value to tween byThe duration of the tween + If TRUE the tween will smoothly snap all values to integers + + + EXPERIMENTAL METHOD - Tweens a Transform's rotation BY the given value (as if you chained a SetRelative), + in a way that allows other DOBlendableRotate tweens to work together on the same target, + instead than fight each other as multiple DORotate would do. + Also stores the transform as the tween's target so it can be used for filtered operations + The value to tween byThe duration of the tween + Rotation mode + + + EXPERIMENTAL METHOD - Tweens a Transform's lcoalRotation BY the given value (as if you chained a SetRelative), + in a way that allows other DOBlendableRotate tweens to work together on the same target, + instead than fight each other as multiple DORotate would do. + Also stores the transform as the tween's target so it can be used for filtered operations + The value to tween byThe duration of the tween + Rotation mode + + + Punches a Transform's localRotation BY the given value and then back to the starting one + as if it was connected to the starting rotation via an elastic. Does it in a way that allows other + DOBlendableRotate tweens to work together on the same target + The punch strength (added to the Transform's current rotation) + The duration of the tween + Indicates how much will the punch vibrate + Represents how much (0 to 1) the vector will go beyond the starting rotation when bouncing backwards. + 1 creates a full oscillation between the punch rotation and the opposite rotation, + while 0 oscillates only between the punch and the start rotation + + + Tweens a Transform's localScale BY the given value (as if you chained a SetRelative), + in a way that allows other DOBlendableScale tweens to work together on the same target, + instead than fight each other as multiple DOScale would do. + Also stores the transform as the tween's target so it can be used for filtered operations + The value to tween byThe duration of the tween + + + + Completes all tweens that have this target as a reference + (meaning tweens that were started from this target, or that had this target added as an Id) + and returns the total number of tweens completed + (meaning the tweens that don't have infinite loops and were not already complete) + + For Sequences only: if TRUE also internal Sequence callbacks will be fired, + otherwise they will be ignored + + + + Completes all tweens that have this target as a reference + (meaning tweens that were started from this target, or that had this target added as an Id) + and returns the total number of tweens completed + (meaning the tweens that don't have infinite loops and were not already complete) + + For Sequences only: if TRUE also internal Sequence callbacks will be fired, + otherwise they will be ignored + + + + Kills all tweens that have this target as a reference + (meaning tweens that were started from this target, or that had this target added as an Id) + and returns the total number of tweens killed. + + If TRUE completes the tween before killing it + + + + Kills all tweens that have this target as a reference + (meaning tweens that were started from this target, or that had this target added as an Id) + and returns the total number of tweens killed. + + If TRUE completes the tween before killing it + + + + Flips the direction (backwards if it was going forward or viceversa) of all tweens that have this target as a reference + (meaning tweens that were started from this target, or that had this target added as an Id) + and returns the total number of tweens flipped. + + + + + Flips the direction (backwards if it was going forward or viceversa) of all tweens that have this target as a reference + (meaning tweens that were started from this target, or that had this target added as an Id) + and returns the total number of tweens flipped. + + + + + Sends to the given position all tweens that have this target as a reference + (meaning tweens that were started from this target, or that had this target added as an Id) + and returns the total number of tweens involved. + + Time position to reach + (if higher than the whole tween duration the tween will simply reach its end) + If TRUE will play the tween after reaching the given position, otherwise it will pause it + + + + Sends to the given position all tweens that have this target as a reference + (meaning tweens that were started from this target, or that had this target added as an Id) + and returns the total number of tweens involved. + + Time position to reach + (if higher than the whole tween duration the tween will simply reach its end) + If TRUE will play the tween after reaching the given position, otherwise it will pause it + + + + Pauses all tweens that have this target as a reference + (meaning tweens that were started from this target, or that had this target added as an Id) + and returns the total number of tweens paused. + + + + + Pauses all tweens that have this target as a reference + (meaning tweens that were started from this target, or that had this target added as an Id) + and returns the total number of tweens paused. + + + + + Plays all tweens that have this target as a reference + (meaning tweens that were started from this target, or that had this target added as an Id) + and returns the total number of tweens played. + + + + + Plays all tweens that have this target as a reference + (meaning tweens that were started from this target, or that had this target added as an Id) + and returns the total number of tweens played. + + + + + Plays backwards all tweens that have this target as a reference + (meaning tweens that were started from this target, or that had this target added as an Id) + and returns the total number of tweens played. + + + + + Plays backwards all tweens that have this target as a reference + (meaning tweens that were started from this target, or that had this target added as an Id) + and returns the total number of tweens played. + + + + + Plays forward all tweens that have this target as a reference + (meaning tweens that were started from this target, or that had this target added as an Id) + and returns the total number of tweens played. + + + + + Plays forward all tweens that have this target as a reference + (meaning tweens that were started from this target, or that had this target added as an Id) + and returns the total number of tweens played. + + + + + Restarts all tweens that have this target as a reference + (meaning tweens that were started from this target, or that had this target added as an Id) + and returns the total number of tweens restarted. + + + + + Restarts all tweens that have this target as a reference + (meaning tweens that were started from this target, or that had this target added as an Id) + and returns the total number of tweens restarted. + + + + + Rewinds all tweens that have this target as a reference + (meaning tweens that were started from this target, or that had this target added as an Id) + and returns the total number of tweens rewinded. + + + + + Rewinds all tweens that have this target as a reference + (meaning tweens that were started from this target, or that had this target added as an Id) + and returns the total number of tweens rewinded. + + + + + Smoothly rewinds all tweens that have this target as a reference + (meaning tweens that were started from this target, or that had this target added as an Id) + and returns the total number of tweens rewinded. + + + + + Smoothly rewinds all tweens that have this target as a reference + (meaning tweens that were started from this target, or that had this target added as an Id) + and returns the total number of tweens rewinded. + + + + + Toggles the paused state (plays if it was paused, pauses if it was playing) of all tweens that have this target as a reference + (meaning tweens that were started from this target, or that had this target added as an Id) + and returns the total number of tweens involved. + + + + + Toggles the paused state (plays if it was paused, pauses if it was playing) of all tweens that have this target as a reference + (meaning tweens that were started from this target, or that had this target added as an Id) + and returns the total number of tweens involved. + + + + + This class serves only as a utility class to store tween settings to apply on multiple tweens. + It is in no way needed otherwise, since you can directly apply tween settings to a tween via chaining + + + + A variable you can eventually Clear and reuse when needed, + to avoid instantiating TweenParams objects + + + Creates a new TweenParams object, which you can use to store tween settings + to pass to multiple tweens via myTween.SetAs(myTweenParms) + + + Clears and resets this TweenParams instance using default values, + so it can be reused without instantiating another one + + + Sets the autoKill behaviour of the tween. + Has no effect if the tween has already started + If TRUE the tween will be automatically killed when complete + + + Sets an ID for the tween, which can then be used as a filter with DOTween's static methods. + The ID to assign to this tween. Can be an int, a string, an object or anything else. + + + Sets the target for the tween, which can then be used as a filter with DOTween's static methods. + IMPORTANT: use it with caution. If you just want to set an ID for the tween use SetId instead. + When using shorcuts the shortcut target is already assigned as the tween's target, + so using this method will overwrite it and prevent shortcut-operations like myTarget.DOPause from working correctly. + The target to assign to this tween. Can be an int, a string, an object or anything else. + + + Sets the looping options for the tween. + Has no effect if the tween has already started + Number of cycles to play (-1 for infinite - will be converted to 1 in case the tween is nested in a Sequence) + Loop behaviour type (default: LoopType.Restart) + + + Sets the ease of the tween. + If applied to Sequences eases the whole sequence animation + Eventual overshoot or amplitude to use with Back or Elastic easeType (default is 1.70158) + Eventual period to use with Elastic easeType (default is 0) + + + Sets the ease of the tween using an AnimationCurve. + If applied to Sequences eases the whole sequence animation + + + Sets the ease of the tween using a custom ease function. + If applied to Sequences eases the whole sequence animation + + + Sets the recycling behaviour for the tween. + If TRUE the tween will be recycled after being killed, otherwise it will be destroyed. + + + Sets the update type to the one defined in DOTween.defaultUpdateType (UpdateType.Normal unless changed) + and lets you choose if it should be independent from Unity's Time.timeScale + If TRUE the tween will ignore Unity's Time.timeScale + + + Sets the type of update (default or independent) for the tween + The type of update (default: UpdateType.Normal) + If TRUE the tween will ignore Unity's Time.timeScale + + + Sets the onStart callback for the tween. + Called the first time the tween is set in a playing state, after any eventual delay + + + Sets the onPlay callback for the tween. + Called when the tween is set in a playing state, after any eventual delay. + Also called each time the tween resumes playing from a paused state + + + Sets the onRewind callback for the tween. + Called when the tween is rewinded, + either by calling Rewind or by reaching the start position while playing backwards. + Rewinding a tween that is already rewinded will not fire this callback + + + Sets the onUpdate callback for the tween. + Called each time the tween updates + + + Sets the onStepComplete callback for the tween. + Called the moment the tween completes one loop cycle, even when going backwards + + + Sets the onComplete callback for the tween. + Called the moment the tween reaches its final forward position, loops included + + + Sets the onKill callback for the tween. + Called the moment the tween is killed + + + Sets the onWaypointChange callback for the tween. + Called when a path tween reaches a new waypoint + + + Sets a delayed startup for the tween. + Has no effect on Sequences or if the tween has already started + + + If isRelative is TRUE sets the tween as relative + (the endValue will be calculated as startValue + endValue instead than being used directly). + Has no effect on Sequences or if the tween has already started + + + If isSpeedBased is TRUE sets the tween as speed based + (the duration will represent the number of units the tween moves x second). + Has no effect on Sequences, nested tweens, or if the tween has already started + + + + Methods that extend Tween objects and allow to set their parameters + + + + Sets the autoKill behaviour of the tween. + Has no effect if the tween has already started + + + Sets the autoKill behaviour of the tween. + Has no effect if the tween has already started + If TRUE the tween will be automatically killed when complete + + + Sets an ID for the tween (), which can then be used as a filter with DOTween's static methods. + The ID to assign to this tween. Can be an int, a string, an object or anything else. + + + Sets a string ID for the tween (), which can then be used as a filter with DOTween's static methods. + Filtering via string is 2X faster than using an object as an ID (using the alternate obejct overload) + The string ID to assign to this tween. + + + Sets an int ID for the tween (), which can then be used as a filter with DOTween's static methods. + Filtering via int is 4X faster than via object, 2X faster than via string (using the alternate object/string overloads) + The int ID to assign to this tween. + + + Sets the target for the tween, which can then be used as a filter with DOTween's static methods. + IMPORTANT: use it with caution. If you just want to set an ID for the tween use SetId instead. + When using shorcuts the shortcut target is already assigned as the tween's target, + so using this method will overwrite it and prevent shortcut-operations like myTarget.DOPause from working correctly. + The target to assign to this tween. Can be an int, a string, an object or anything else. + + + Sets the looping options for the tween. + Has no effect if the tween has already started + Number of cycles to play (-1 for infinite - will be converted to 1 in case the tween is nested in a Sequence) + + + Sets the looping options for the tween. + Has no effect if the tween has already started + Number of cycles to play (-1 for infinite - will be converted to 1 in case the tween is nested in a Sequence) + Loop behaviour type (default: LoopType.Restart) + + + Sets the ease of the tween. + If applied to Sequences eases the whole sequence animation + + + Sets the ease of the tween. + If applied to Sequences eases the whole sequence animation + + Eventual overshoot to use with Back or Flash ease (default is 1.70158 - 1 for Flash). + In case of Flash ease it must be an intenger and sets the total number of flashes that will happen. + Using an even number will complete the tween on the starting value, while an odd one will complete it on the end value. + + + + Sets the ease of the tween. + If applied to Sequences eases the whole sequence animation + Eventual amplitude to use with Elastic easeType or overshoot to use with Flash easeType (default is 1.70158 - 1 for Flash). + In case of Flash ease it must be an integer and sets the total number of flashes that will happen. + Using an even number will complete the tween on the starting value, while an odd one will complete it on the end value. + + Eventual period to use with Elastic or Flash easeType (default is 0). + In case of Flash ease it indicates the power in time of the ease, and must be between -1 and 1. + 0 is balanced, 1 weakens the ease with time, -1 starts the ease weakened and gives it power towards the end. + + + + Sets the ease of the tween using an AnimationCurve. + If applied to Sequences eases the whole sequence animation + + + Sets the ease of the tween using a custom ease function (which must return a value between 0 and 1). + If applied to Sequences eases the whole sequence animation + + + Allows the tween to be recycled after being killed. + + + Sets the recycling behaviour for the tween. + If TRUE the tween will be recycled after being killed, otherwise it will be destroyed. + + + Sets the update type to UpdateType.Normal and lets you choose if it should be independent from Unity's Time.timeScale + If TRUE the tween will ignore Unity's Time.timeScale + + + Sets the type of update for the tween + The type of update (defalt: UpdateType.Normal) + + + Sets the type of update for the tween and lets you choose if it should be independent from Unity's Time.timeScale + The type of update + If TRUE the tween will ignore Unity's Time.timeScale + + + Sets the onStart callback for the tween, clearing any previous onStart callback that was set. + Called the first time the tween is set in a playing state, after any eventual delay + + + Sets the onPlay callback for the tween, clearing any previous onPlay callback that was set. + Called when the tween is set in a playing state, after any eventual delay. + Also called each time the tween resumes playing from a paused state + + + Sets the onPause callback for the tween, clearing any previous onPause callback that was set. + Called when the tween state changes from playing to paused. + If the tween has autoKill set to FALSE, this is called also when the tween reaches completion. + + + Sets the onRewind callback for the tween, clearing any previous onRewind callback that was set. + Called when the tween is rewinded, + either by calling Rewind or by reaching the start position while playing backwards. + Rewinding a tween that is already rewinded will not fire this callback + + + Sets the onUpdate callback for the tween, clearing any previous onUpdate callback that was set. + Called each time the tween updates + + + Sets the onStepComplete callback for the tween, clearing any previous onStepComplete callback that was set. + Called the moment the tween completes one loop cycle, even when going backwards + + + Sets the onComplete callback for the tween, clearing any previous onComplete callback that was set. + Called the moment the tween reaches its final forward position, loops included + + + Sets the onKill callback for the tween, clearing any previous onKill callback that was set. + Called the moment the tween is killed + + + Sets the onWaypointChange callback for the tween, clearing any previous onWaypointChange callback that was set. + Called when a path tween's current waypoint changes + + + Sets the parameters of the tween (id, ease, loops, delay, timeScale, callbacks, etc) as the parameters of the given one. + Doesn't copy specific SetOptions settings: those will need to be applied manually each time. + Has no effect if the tween has already started. + NOTE: the tween's target will not be changed + Tween from which to copy the parameters + + + Sets the parameters of the tween (id, ease, loops, delay, timeScale, callbacks, etc) as the parameters of the given TweenParams. + Has no effect if the tween has already started. + TweenParams from which to copy the parameters + + + Adds the given tween to the end of the Sequence. + Has no effect if the Sequence has already started + The tween to append + + + Adds the given tween to the beginning of the Sequence, pushing forward the other nested content. + Has no effect if the Sequence has already started + The tween to prepend + + + Inserts the given tween at the same time position of the last tween, callback or intervale added to the Sequence. + Note that, in case of a Join after an interval, the insertion time will be the time where the interval starts, not where it finishes. + Has no effect if the Sequence has already started + + + Inserts the given tween at the given time position in the Sequence, + automatically adding an interval if needed. + Has no effect if the Sequence has already started + The time position where the tween will be placed + The tween to insert + + + Adds the given interval to the end of the Sequence. + Has no effect if the Sequence has already started + The interval duration + + + Adds the given interval to the beginning of the Sequence, pushing forward the other nested content. + Has no effect if the Sequence has already started + The interval duration + + + Adds the given callback to the end of the Sequence. + Has no effect if the Sequence has already started + The callback to append + + + Adds the given callback to the beginning of the Sequence, pushing forward the other nested content. + Has no effect if the Sequence has already started + The callback to prepend + + + Inserts the given callback at the given time position in the Sequence, + automatically adding an interval if needed. + Has no effect if the Sequence has already started + The time position where the callback will be placed + The callback to insert + + + Changes a TO tween into a FROM tween: sets the current target's position as the tween's endValue + then immediately sends the target to the previously set endValue. + + + Changes a TO tween into a FROM tween: sets the current target's position as the tween's endValue + then immediately sends the target to the previously set endValue. + If TRUE the FROM value will be calculated as relative to the current one + + + Sets a delayed startup for the tween. + Has no effect on Sequences or if the tween has already started + + + Sets the tween as relative + (the endValue will be calculated as startValue + endValue instead than being used directly). + Has no effect on Sequences or if the tween has already started + + + If isRelative is TRUE sets the tween as relative + (the endValue will be calculated as startValue + endValue instead than being used directly). + Has no effect on Sequences or if the tween has already started + + + If isSpeedBased is TRUE sets the tween as speed based + (the duration will represent the number of units the tween moves x second). + Has no effect on Sequences, nested tweens, or if the tween has already started + + + If isSpeedBased is TRUE sets the tween as speed based + (the duration will represent the number of units the tween moves x second). + Has no effect on Sequences, nested tweens, or if the tween has already started + + + Options for float tweens + If TRUE the tween will smoothly snap all values to integers + + + Options for Vector2 tweens + If TRUE the tween will smoothly snap all values to integers + + + Options for Vector2 tweens + Selecting an axis will tween the vector only on that axis, leaving the others untouched + If TRUE the tween will smoothly snap all values to integers + + + Options for Vector3 tweens + If TRUE the tween will smoothly snap all values to integers + + + Options for Vector3 tweens + Selecting an axis will tween the vector only on that axis, leaving the others untouched + If TRUE the tween will smoothly snap all values to integers + + + Options for Vector4 tweens + If TRUE the tween will smoothly snap all values to integers + + + Options for Vector4 tweens + Selecting an axis will tween the vector only on that axis, leaving the others untouched + If TRUE the tween will smoothly snap all values to integers + + + Options for Quaternion tweens + If TRUE (default) the rotation will take the shortest route, and will not rotate more than 360°. + If FALSE the rotation will be fully accounted. Is always FALSE if the tween is set as relative + + + Options for Color tweens + If TRUE only the alpha value of the color will be tweened + + + Options for Vector4 tweens + If TRUE the tween will smoothly snap all values to integers + + + Options for Vector4 tweens + If TRUE, rich text will be interpreted correctly while animated, + otherwise all tags will be considered as normal text + The type of scramble to use, if any + A string containing the characters to use for scrambling. + Use as many characters as possible (minimum 10) because DOTween uses a fast scramble mode which gives better results with more characters. + Leave it to NULL to use default ones + + + Options for Vector3Array tweens + If TRUE the tween will smoothly snap all values to integers + + + Options for Vector3Array tweens + If TRUE the tween will smoothly snap all values to integers + + + Options for Path tweens (created via the DOPath shortcut) + The eventual movement axis to lock. You can input multiple axis if you separate them like this: + AxisConstrain.X | AxisConstraint.Y + The eventual rotation axis to lock. You can input multiple axis if you separate them like this: + AxisConstrain.X | AxisConstraint.Y + + + Options for Path tweens (created via the DOPath shortcut) + If TRUE the path will be automatically closed + The eventual movement axis to lock. You can input multiple axis if you separate them like this: + AxisConstrain.X | AxisConstraint.Y + The eventual rotation axis to lock. You can input multiple axis if you separate them like this: + AxisConstrain.X | AxisConstraint.Y + + + Additional LookAt options for Path tweens (created via the DOPath shortcut). + Orients the target towards the given position. + Must be chained directly to the tween creation method or to a SetOptions + The position to look at + The eventual direction to consider as "forward". + If left to NULL defaults to the regular forward side of the transform + The vector that defines in which direction up is (default: Vector3.up) + + + Additional LookAt options for Path tweens (created via the DOPath shortcut). + Orients the target towards another transform. + Must be chained directly to the tween creation method or to a SetOptions + The transform to look at + The eventual direction to consider as "forward". + If left to NULL defaults to the regular forward side of the transform + The vector that defines in which direction up is (default: Vector3.up) + + + Additional LookAt options for Path tweens (created via the DOPath shortcut). + Orients the target to the path, with the given lookAhead. + Must be chained directly to the tween creation method or to a SetOptions + The percentage of lookAhead to use (0 to 1) + The eventual direction to consider as "forward". + If left to NULL defaults to the regular forward side of the transform + The vector that defines in which direction up is (default: Vector3.up) + + + + Types of log behaviours + + + + Log only warnings and errors + + + Log warnings, errors and additional infos + + + Log only errors + + + + Indicates either a Tweener or a Sequence + + + + TimeScale for the tween + + + If TRUE the tween wil go backwards + + + Object ID (usable for filtering with DOTween static methods). Can be anything except a string or an int + (use or for those) + + + String ID (usable for filtering with DOTween static methods). 2X faster than using an object id + + + Int ID (usable for filtering with DOTween static methods). 4X faster than using an object id, 2X faster than using a string id. + Default is -999 so avoid using an ID like that or it will capture all unset intIds + + + Tween target (usable for filtering with DOTween static methods). Automatically set by tween creation shorcuts + + + Called when the tween is set in a playing state, after any eventual delay. + Also called each time the tween resumes playing from a paused state + + + Called when the tween state changes from playing to paused. + If the tween has autoKill set to FALSE, this is called also when the tween reaches completion. + + + Called when the tween is rewinded, + either by calling Rewind or by reaching the start position while playing backwards. + Rewinding a tween that is already rewinded will not fire this callback + + + Called each time the tween updates + + + Called the moment the tween completes one loop cycle + + + Called the moment the tween reaches completion (loops included) + + + Called the moment the tween is killed + + + Called when a path tween's current waypoint changes + + + Tweeners-only (ignored by Sequences), returns TRUE if the tween was set as relative + + + FALSE when tween is (or should be) despawned - set only by TweenManager + + + Gets and sets the time position (loops included, delays excluded) of the tween + + + TRUE after the tween was set in a play state at least once, AFTER any delay is elapsed + + + Time position within a single loop cycle + + + + Animates a single value + + + + Changes the start value of a tween and rewinds it (without pausing it). + Has no effect with tweens that are inside Sequences + The new start value + If bigger than 0 applies it as the new tween duration + + + Changes the end value of a tween and rewinds it (without pausing it). + Has no effect with tweens that are inside Sequences + The new end value + If bigger than 0 applies it as the new tween duration + If TRUE the start value will become the current target's value, otherwise it will stay the same + + + Changes the end value of a tween and rewinds it (without pausing it). + Has no effect with tweens that are inside Sequences + The new end value + If TRUE the start value will become the current target's value, otherwise it will stay the same + + + Changes the start and end value of a tween and rewinds it (without pausing it). + Has no effect with tweens that are inside Sequences + The new start value + The new end value + If bigger than 0 applies it as the new tween duration + + + + Used internally + + + + + Update type + + + + Updates every frame during Update calls + + + Updates every frame during LateUpdate calls + + + Updates using FixedUpdate calls + + + Updates using manual update calls + + + diff --git a/Assets/Demigiant/DOTween/DOTween.XML.meta b/Assets/Demigiant/DOTween/DOTween.XML.meta new file mode 100644 index 0000000..c87a520 --- /dev/null +++ b/Assets/Demigiant/DOTween/DOTween.XML.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: 34192c5e0d14aee43a0e86cc4823268a +TextScriptImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DOTween/DOTween.dll b/Assets/Demigiant/DOTween/DOTween.dll new file mode 100644 index 0000000..6444402 Binary files /dev/null and b/Assets/Demigiant/DOTween/DOTween.dll differ diff --git a/Assets/Demigiant/DOTween/DOTween.dll.mdb b/Assets/Demigiant/DOTween/DOTween.dll.mdb new file mode 100644 index 0000000..6bf9731 Binary files /dev/null and b/Assets/Demigiant/DOTween/DOTween.dll.mdb differ diff --git a/Assets/Demigiant/DOTween/DOTween.dll.mdb.meta b/Assets/Demigiant/DOTween/DOTween.dll.mdb.meta new file mode 100644 index 0000000..779c1ad --- /dev/null +++ b/Assets/Demigiant/DOTween/DOTween.dll.mdb.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: 4f007001a22b3d24dae350342c4d19c8 +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DOTween/DOTween.dll.meta b/Assets/Demigiant/DOTween/DOTween.dll.meta new file mode 100644 index 0000000..e8655b6 --- /dev/null +++ b/Assets/Demigiant/DOTween/DOTween.dll.meta @@ -0,0 +1,21 @@ +fileFormatVersion: 2 +guid: a811bde74b26b53498b4f6d872b09b6d +PluginImporter: + externalObjects: {} + serializedVersion: 2 + iconMap: {} + executionOrder: {} + defineConstraints: [] + isPreloaded: 0 + isOverridable: 0 + isExplicitlyReferenced: 0 + validateReferences: 1 + platformData: + - first: + Any: + second: + enabled: 1 + settings: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DOTween/Editor.meta b/Assets/Demigiant/DOTween/Editor.meta new file mode 100644 index 0000000..1ac7445 --- /dev/null +++ b/Assets/Demigiant/DOTween/Editor.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 05f8a23aa702c8a47b2947a3e1f64d03 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DOTween/Editor/DOTweenEditor.XML b/Assets/Demigiant/DOTween/Editor/DOTweenEditor.XML new file mode 100644 index 0000000..884656c --- /dev/null +++ b/Assets/Demigiant/DOTween/Editor/DOTweenEditor.XML @@ -0,0 +1,97 @@ + + + + DOTweenEditor + + + + + Starts the update loop of tween in the editor. Has no effect during playMode. + + Eventual callback to call after every update + + + + Stops the update loop and clears any callback. + + + + + Readies the tween for editor preview by setting its UpdateType to Manual plus eventual extra settings. + + The tween to ready + If TRUE (recommended) removes all callbacks (OnComplete/Rewind/etc) + If TRUE prevents the tween from being auto-killed at completion + If TRUE starts playing the tween immediately + + + + Checks that the given editor texture use the correct import settings, + and applies them if they're incorrect. + + + + + Returns TRUE if setup is required + + + + + Returns TRUE if the file/directory at the given path exists. + + Path, relative to Unity's project folder + + + + + Converts the given project-relative path to a full path, + with backward (\) slashes). + + + + + Converts the given full path to a path usable with AssetDatabase methods + (relative to Unity's project folder, and with the correct Unity forward (/) slashes). + + + + + Connects to a asset. + If the asset already exists at the given path, loads it and returns it. + Otherwise, either returns NULL or automatically creates it before loading and returning it + (depending on the given parameters). + + Asset type + File path (relative to Unity's project folder) + If TRUE and the requested asset doesn't exist, forces its creation + + + + Full path for the given loaded assembly, assembly file included + + + + + Adds the given global define if it's not already present + + + + + Removes the given global define if it's present + + + + + Returns TRUE if the given global define is present in all the + or only in the given , depending on passed parameters. + + + to use. Leave NULL to check in all of them. + + + + Not used as menu item anymore, but as a utiity function + + + + diff --git a/Assets/Demigiant/DOTween/Editor/DOTweenEditor.XML.meta b/Assets/Demigiant/DOTween/Editor/DOTweenEditor.XML.meta new file mode 100644 index 0000000..258ca87 --- /dev/null +++ b/Assets/Demigiant/DOTween/Editor/DOTweenEditor.XML.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: 2e2c6224d345d9249acfa6e8ef40bb2d +TextScriptImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DOTween/Editor/DOTweenEditor.dll b/Assets/Demigiant/DOTween/Editor/DOTweenEditor.dll new file mode 100644 index 0000000..abad050 Binary files /dev/null and b/Assets/Demigiant/DOTween/Editor/DOTweenEditor.dll differ diff --git a/Assets/Demigiant/DOTween/Editor/DOTweenEditor.dll.mdb b/Assets/Demigiant/DOTween/Editor/DOTweenEditor.dll.mdb new file mode 100644 index 0000000..b30774f Binary files /dev/null and b/Assets/Demigiant/DOTween/Editor/DOTweenEditor.dll.mdb differ diff --git a/Assets/Demigiant/DOTween/Editor/DOTweenEditor.dll.mdb.meta b/Assets/Demigiant/DOTween/Editor/DOTweenEditor.dll.mdb.meta new file mode 100644 index 0000000..2ee6141 --- /dev/null +++ b/Assets/Demigiant/DOTween/Editor/DOTweenEditor.dll.mdb.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: 8f46310a8b0a8f04a92993c37c713243 +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DOTween/Editor/DOTweenEditor.dll.meta b/Assets/Demigiant/DOTween/Editor/DOTweenEditor.dll.meta new file mode 100644 index 0000000..8ae528a --- /dev/null +++ b/Assets/Demigiant/DOTween/Editor/DOTweenEditor.dll.meta @@ -0,0 +1,21 @@ +fileFormatVersion: 2 +guid: 45d5034162d6cf04dbe46da84fc7d074 +PluginImporter: + externalObjects: {} + serializedVersion: 2 + iconMap: {} + executionOrder: {} + defineConstraints: [] + isPreloaded: 0 + isOverridable: 0 + isExplicitlyReferenced: 0 + validateReferences: 1 + platformData: + - first: + Any: + second: + enabled: 1 + settings: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DOTween/Editor/Imgs.meta b/Assets/Demigiant/DOTween/Editor/Imgs.meta new file mode 100644 index 0000000..af410a8 --- /dev/null +++ b/Assets/Demigiant/DOTween/Editor/Imgs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: e2956dad15d720e4884aabb37c6cca2c +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DOTween/Editor/Imgs/DOTweenIcon.png b/Assets/Demigiant/DOTween/Editor/Imgs/DOTweenIcon.png new file mode 100644 index 0000000..d06fc7c Binary files /dev/null and b/Assets/Demigiant/DOTween/Editor/Imgs/DOTweenIcon.png differ diff --git a/Assets/Demigiant/DOTween/Editor/Imgs/DOTweenIcon.png.meta b/Assets/Demigiant/DOTween/Editor/Imgs/DOTweenIcon.png.meta new file mode 100644 index 0000000..c391b7c --- /dev/null +++ b/Assets/Demigiant/DOTween/Editor/Imgs/DOTweenIcon.png.meta @@ -0,0 +1,96 @@ +fileFormatVersion: 2 +guid: 8da095e39e9b4df488dfd436f81116d6 +TextureImporter: + internalIDToNameTable: [] + externalObjects: {} + serializedVersion: 11 + mipmaps: + mipMapMode: 0 + enableMipMap: 0 + sRGBTexture: 1 + linearTexture: 1 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + streamingMipmaps: 0 + streamingMipmapsPriority: 0 + vTOnly: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: -3 + maxTextureSize: 128 + textureSettings: + serializedVersion: 2 + filterMode: 1 + aniso: 1 + mipBias: 0 + wrapU: 1 + wrapV: 1 + wrapW: 1 + nPOTScale: 0 + lightmap: 0 + compressionQuality: 50 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spritePixelsToUnits: 100 + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spriteGenerateFallbackPhysicsShape: 1 + alphaUsage: 1 + alphaIsTransparency: 1 + spriteTessellationDetail: -1 + textureType: 2 + textureShape: 1 + singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + platformSettings: + - serializedVersion: 3 + buildTarget: DefaultTexturePlatform + maxTextureSize: 128 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 0 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + bones: [] + spriteID: + internalID: 0 + vertices: [] + indices: + edges: [] + weights: [] + secondaryTextures: [] + spritePackingTag: + pSDRemoveMatte: 0 + pSDShowRemoveMatteOption: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DOTween/Editor/Imgs/Footer.png b/Assets/Demigiant/DOTween/Editor/Imgs/Footer.png new file mode 100644 index 0000000..e29d02f Binary files /dev/null and b/Assets/Demigiant/DOTween/Editor/Imgs/Footer.png differ diff --git a/Assets/Demigiant/DOTween/Editor/Imgs/Footer.png.meta b/Assets/Demigiant/DOTween/Editor/Imgs/Footer.png.meta new file mode 100644 index 0000000..ffa4c59 --- /dev/null +++ b/Assets/Demigiant/DOTween/Editor/Imgs/Footer.png.meta @@ -0,0 +1,96 @@ +fileFormatVersion: 2 +guid: 7051dba417b3d53409f2918f1ea4938d +TextureImporter: + internalIDToNameTable: [] + externalObjects: {} + serializedVersion: 11 + mipmaps: + mipMapMode: 0 + enableMipMap: 0 + sRGBTexture: 1 + linearTexture: 1 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + streamingMipmaps: 0 + streamingMipmapsPriority: 0 + vTOnly: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: -3 + maxTextureSize: 256 + textureSettings: + serializedVersion: 2 + filterMode: 1 + aniso: 1 + mipBias: 0 + wrapU: 1 + wrapV: 1 + wrapW: 1 + nPOTScale: 0 + lightmap: 0 + compressionQuality: 50 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spritePixelsToUnits: 100 + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spriteGenerateFallbackPhysicsShape: 1 + alphaUsage: 1 + alphaIsTransparency: 1 + spriteTessellationDetail: -1 + textureType: 2 + textureShape: 1 + singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + platformSettings: + - serializedVersion: 3 + buildTarget: DefaultTexturePlatform + maxTextureSize: 256 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 0 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + bones: [] + spriteID: + internalID: 0 + vertices: [] + indices: + edges: [] + weights: [] + secondaryTextures: [] + spritePackingTag: + pSDRemoveMatte: 0 + pSDShowRemoveMatteOption: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DOTween/Editor/Imgs/Footer_dark.png b/Assets/Demigiant/DOTween/Editor/Imgs/Footer_dark.png new file mode 100644 index 0000000..e48db5e Binary files /dev/null and b/Assets/Demigiant/DOTween/Editor/Imgs/Footer_dark.png differ diff --git a/Assets/Demigiant/DOTween/Editor/Imgs/Footer_dark.png.meta b/Assets/Demigiant/DOTween/Editor/Imgs/Footer_dark.png.meta new file mode 100644 index 0000000..33a5ee0 --- /dev/null +++ b/Assets/Demigiant/DOTween/Editor/Imgs/Footer_dark.png.meta @@ -0,0 +1,96 @@ +fileFormatVersion: 2 +guid: 519694efe2bb2914788b151fbd8c01f4 +TextureImporter: + internalIDToNameTable: [] + externalObjects: {} + serializedVersion: 11 + mipmaps: + mipMapMode: 0 + enableMipMap: 1 + sRGBTexture: 1 + linearTexture: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + streamingMipmaps: 0 + streamingMipmapsPriority: 0 + vTOnly: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: -1 + maxTextureSize: 1024 + textureSettings: + serializedVersion: 2 + filterMode: 1 + aniso: 1 + mipBias: 0 + wrapU: 0 + wrapV: 0 + wrapW: 0 + nPOTScale: 1 + lightmap: 0 + compressionQuality: 50 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spritePixelsToUnits: 100 + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spriteGenerateFallbackPhysicsShape: 1 + alphaUsage: 1 + alphaIsTransparency: 0 + spriteTessellationDetail: -1 + textureType: 0 + textureShape: 1 + singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + platformSettings: + - serializedVersion: 3 + buildTarget: DefaultTexturePlatform + maxTextureSize: 1024 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + bones: [] + spriteID: + internalID: 0 + vertices: [] + indices: + edges: [] + weights: [] + secondaryTextures: [] + spritePackingTag: + pSDRemoveMatte: 0 + pSDShowRemoveMatteOption: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DOTween/Editor/Imgs/Header.jpg b/Assets/Demigiant/DOTween/Editor/Imgs/Header.jpg new file mode 100644 index 0000000..4d710d7 Binary files /dev/null and b/Assets/Demigiant/DOTween/Editor/Imgs/Header.jpg differ diff --git a/Assets/Demigiant/DOTween/Editor/Imgs/Header.jpg.meta b/Assets/Demigiant/DOTween/Editor/Imgs/Header.jpg.meta new file mode 100644 index 0000000..fc6ef6b --- /dev/null +++ b/Assets/Demigiant/DOTween/Editor/Imgs/Header.jpg.meta @@ -0,0 +1,96 @@ +fileFormatVersion: 2 +guid: 78a59ca99f8987941adb61f9e14a06a7 +TextureImporter: + internalIDToNameTable: [] + externalObjects: {} + serializedVersion: 11 + mipmaps: + mipMapMode: 0 + enableMipMap: 0 + sRGBTexture: 1 + linearTexture: 1 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + streamingMipmaps: 0 + streamingMipmapsPriority: 0 + vTOnly: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: -3 + maxTextureSize: 512 + textureSettings: + serializedVersion: 2 + filterMode: 1 + aniso: 1 + mipBias: 0 + wrapU: 1 + wrapV: 1 + wrapW: 1 + nPOTScale: 0 + lightmap: 0 + compressionQuality: 50 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spritePixelsToUnits: 100 + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spriteGenerateFallbackPhysicsShape: 1 + alphaUsage: 1 + alphaIsTransparency: 1 + spriteTessellationDetail: -1 + textureType: 2 + textureShape: 1 + singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + platformSettings: + - serializedVersion: 3 + buildTarget: DefaultTexturePlatform + maxTextureSize: 512 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 0 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + bones: [] + spriteID: + internalID: 0 + vertices: [] + indices: + edges: [] + weights: [] + secondaryTextures: [] + spritePackingTag: + pSDRemoveMatte: 0 + pSDShowRemoveMatteOption: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DOTween/Modules.meta b/Assets/Demigiant/DOTween/Modules.meta new file mode 100644 index 0000000..11be892 --- /dev/null +++ b/Assets/Demigiant/DOTween/Modules.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: a92336d577e37eb44a67713dffc108f2 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DOTween/Modules/DOTweenModuleAudio.cs b/Assets/Demigiant/DOTween/Modules/DOTweenModuleAudio.cs new file mode 100644 index 0000000..c342c02 --- /dev/null +++ b/Assets/Demigiant/DOTween/Modules/DOTweenModuleAudio.cs @@ -0,0 +1,195 @@ +// Author: Daniele Giardini - http://www.demigiant.com +// Created: 2018/07/13 + +#if true // MODULE_MARKER +using System; +using UnityEngine; +#if UNITY_5 || UNITY_2017_1_OR_NEWER +using UnityEngine.Audio; // Required for AudioMixer +#endif + +#pragma warning disable 1591 +namespace DG.Tweening +{ + public static class DOTweenModuleAudio + { + #region Shortcuts + + #region Audio + + /// Tweens an AudioSource's volume to the given value. + /// Also stores the AudioSource as the tween's target so it can be used for filtered operations + /// The end value to reach (0 to 1)The duration of the tween + public static Tweener DOFade(this AudioSource target, float endValue, float duration) + { + if (endValue < 0) endValue = 0; + else if (endValue > 1) endValue = 1; + return DOTween.To(() => target.volume, x => target.volume = x, endValue, duration).SetTarget(target); + } + + /// Tweens an AudioSource's pitch to the given value. + /// Also stores the AudioSource as the tween's target so it can be used for filtered operations + /// The end value to reachThe duration of the tween + public static Tweener DOPitch(this AudioSource target, float endValue, float duration) + { + return DOTween.To(() => target.pitch, x => target.pitch = x, endValue, duration).SetTarget(target); + } + + #endregion + +#if UNITY_5 || UNITY_2017_1_OR_NEWER + #region AudioMixer (Unity 5 or Newer) + + /// Tweens an AudioMixer's exposed float to the given value. + /// Also stores the AudioMixer as the tween's target so it can be used for filtered operations. + /// Note that you need to manually expose a float in an AudioMixerGroup in order to be able to tween it from an AudioMixer. + /// Name given to the exposed float to set + /// The end value to reachThe duration of the tween + public static Tweener DOSetFloat(this AudioMixer target, string floatName, float endValue, float duration) + { + return DOTween.To(()=> { + float currVal; + target.GetFloat(floatName, out currVal); + return currVal; + }, x=> target.SetFloat(floatName, x), endValue, duration) + .SetTarget(target); + } + + #region Operation Shortcuts + + /// + /// Completes all tweens that have this target as a reference + /// (meaning tweens that were started from this target, or that had this target added as an Id) + /// and returns the total number of tweens completed + /// (meaning the tweens that don't have infinite loops and were not already complete) + /// + /// For Sequences only: if TRUE also internal Sequence callbacks will be fired, + /// otherwise they will be ignored + public static int DOComplete(this AudioMixer target, bool withCallbacks = false) + { + return DOTween.Complete(target, withCallbacks); + } + + /// + /// Kills all tweens that have this target as a reference + /// (meaning tweens that were started from this target, or that had this target added as an Id) + /// and returns the total number of tweens killed. + /// + /// If TRUE completes the tween before killing it + public static int DOKill(this AudioMixer target, bool complete = false) + { + return DOTween.Kill(target, complete); + } + + /// + /// Flips the direction (backwards if it was going forward or viceversa) of all tweens that have this target as a reference + /// (meaning tweens that were started from this target, or that had this target added as an Id) + /// and returns the total number of tweens flipped. + /// + public static int DOFlip(this AudioMixer target) + { + return DOTween.Flip(target); + } + + /// + /// Sends to the given position all tweens that have this target as a reference + /// (meaning tweens that were started from this target, or that had this target added as an Id) + /// and returns the total number of tweens involved. + /// + /// Time position to reach + /// (if higher than the whole tween duration the tween will simply reach its end) + /// If TRUE will play the tween after reaching the given position, otherwise it will pause it + public static int DOGoto(this AudioMixer target, float to, bool andPlay = false) + { + return DOTween.Goto(target, to, andPlay); + } + + /// + /// Pauses all tweens that have this target as a reference + /// (meaning tweens that were started from this target, or that had this target added as an Id) + /// and returns the total number of tweens paused. + /// + public static int DOPause(this AudioMixer target) + { + return DOTween.Pause(target); + } + + /// + /// Plays all tweens that have this target as a reference + /// (meaning tweens that were started from this target, or that had this target added as an Id) + /// and returns the total number of tweens played. + /// + public static int DOPlay(this AudioMixer target) + { + return DOTween.Play(target); + } + + /// + /// Plays backwards all tweens that have this target as a reference + /// (meaning tweens that were started from this target, or that had this target added as an Id) + /// and returns the total number of tweens played. + /// + public static int DOPlayBackwards(this AudioMixer target) + { + return DOTween.PlayBackwards(target); + } + + /// + /// Plays forward all tweens that have this target as a reference + /// (meaning tweens that were started from this target, or that had this target added as an Id) + /// and returns the total number of tweens played. + /// + public static int DOPlayForward(this AudioMixer target) + { + return DOTween.PlayForward(target); + } + + /// + /// Restarts all tweens that have this target as a reference + /// (meaning tweens that were started from this target, or that had this target added as an Id) + /// and returns the total number of tweens restarted. + /// + public static int DORestart(this AudioMixer target) + { + return DOTween.Restart(target); + } + + /// + /// Rewinds all tweens that have this target as a reference + /// (meaning tweens that were started from this target, or that had this target added as an Id) + /// and returns the total number of tweens rewinded. + /// + public static int DORewind(this AudioMixer target) + { + return DOTween.Rewind(target); + } + + /// + /// Smoothly rewinds all tweens that have this target as a reference + /// (meaning tweens that were started from this target, or that had this target added as an Id) + /// and returns the total number of tweens rewinded. + /// + public static int DOSmoothRewind(this AudioMixer target) + { + return DOTween.SmoothRewind(target); + } + + /// + /// Toggles the paused state (plays if it was paused, pauses if it was playing) of all tweens that have this target as a reference + /// (meaning tweens that were started from this target, or that had this target added as an Id) + /// and returns the total number of tweens involved. + /// + public static int DOTogglePause(this AudioMixer target) + { + return DOTween.TogglePause(target); + } + + #endregion + + #endregion +#endif + + #endregion + } +} +#endif diff --git a/Assets/Demigiant/DOTween/Modules/DOTweenModuleAudio.cs.meta b/Assets/Demigiant/DOTween/Modules/DOTweenModuleAudio.cs.meta new file mode 100644 index 0000000..5568217 --- /dev/null +++ b/Assets/Demigiant/DOTween/Modules/DOTweenModuleAudio.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: b766d08851589514b97afb23c6f30a70 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DOTween/Modules/DOTweenModulePhysics.cs b/Assets/Demigiant/DOTween/Modules/DOTweenModulePhysics.cs new file mode 100644 index 0000000..2a85cc6 --- /dev/null +++ b/Assets/Demigiant/DOTween/Modules/DOTweenModulePhysics.cs @@ -0,0 +1,212 @@ +// Author: Daniele Giardini - http://www.demigiant.com +// Created: 2018/07/13 + +#if true // MODULE_MARKER +using System; +using DG.Tweening.Core; +using DG.Tweening.Core.Enums; +using DG.Tweening.Plugins; +using DG.Tweening.Plugins.Core.PathCore; +using DG.Tweening.Plugins.Options; +using UnityEngine; + +#pragma warning disable 1591 +namespace DG.Tweening +{ + public static class DOTweenModulePhysics + { + #region Shortcuts + + #region Rigidbody + + /// Tweens a Rigidbody's position to the given value. + /// Also stores the rigidbody as the tween's target so it can be used for filtered operations + /// The end value to reachThe duration of the tween + /// If TRUE the tween will smoothly snap all values to integers + public static Tweener DOMove(this Rigidbody target, Vector3 endValue, float duration, bool snapping = false) + { + return DOTween.To(() => target.position, target.MovePosition, endValue, duration) + .SetOptions(snapping).SetTarget(target); + } + + /// Tweens a Rigidbody's X position to the given value. + /// Also stores the rigidbody as the tween's target so it can be used for filtered operations + /// The end value to reachThe duration of the tween + /// If TRUE the tween will smoothly snap all values to integers + public static Tweener DOMoveX(this Rigidbody target, float endValue, float duration, bool snapping = false) + { + return DOTween.To(() => target.position, target.MovePosition, new Vector3(endValue, 0, 0), duration) + .SetOptions(AxisConstraint.X, snapping).SetTarget(target); + } + + /// Tweens a Rigidbody's Y position to the given value. + /// Also stores the rigidbody as the tween's target so it can be used for filtered operations + /// The end value to reachThe duration of the tween + /// If TRUE the tween will smoothly snap all values to integers + public static Tweener DOMoveY(this Rigidbody target, float endValue, float duration, bool snapping = false) + { + return DOTween.To(() => target.position, target.MovePosition, new Vector3(0, endValue, 0), duration) + .SetOptions(AxisConstraint.Y, snapping).SetTarget(target); + } + + /// Tweens a Rigidbody's Z position to the given value. + /// Also stores the rigidbody as the tween's target so it can be used for filtered operations + /// The end value to reachThe duration of the tween + /// If TRUE the tween will smoothly snap all values to integers + public static Tweener DOMoveZ(this Rigidbody target, float endValue, float duration, bool snapping = false) + { + return DOTween.To(() => target.position, target.MovePosition, new Vector3(0, 0, endValue), duration) + .SetOptions(AxisConstraint.Z, snapping).SetTarget(target); + } + + /// Tweens a Rigidbody's rotation to the given value. + /// Also stores the rigidbody as the tween's target so it can be used for filtered operations + /// The end value to reachThe duration of the tween + /// Rotation mode + public static Tweener DORotate(this Rigidbody target, Vector3 endValue, float duration, RotateMode mode = RotateMode.Fast) + { + TweenerCore t = DOTween.To(() => target.rotation, target.MoveRotation, endValue, duration); + t.SetTarget(target); + t.plugOptions.rotateMode = mode; + return t; + } + + /// Tweens a Rigidbody's rotation so that it will look towards the given position. + /// Also stores the rigidbody as the tween's target so it can be used for filtered operations + /// The position to look atThe duration of the tween + /// Eventual axis constraint for the rotation + /// The vector that defines in which direction up is (default: Vector3.up) + public static Tweener DOLookAt(this Rigidbody target, Vector3 towards, float duration, AxisConstraint axisConstraint = AxisConstraint.None, Vector3? up = null) + { + TweenerCore t = DOTween.To(() => target.rotation, target.MoveRotation, towards, duration) + .SetTarget(target).SetSpecialStartupMode(SpecialStartupMode.SetLookAt); + t.plugOptions.axisConstraint = axisConstraint; + t.plugOptions.up = (up == null) ? Vector3.up : (Vector3)up; + return t; + } + + #region Special + + /// Tweens a Rigidbody's position to the given value, while also applying a jump effect along the Y axis. + /// Returns a Sequence instead of a Tweener. + /// Also stores the Rigidbody as the tween's target so it can be used for filtered operations + /// The end value to reach + /// Power of the jump (the max height of the jump is represented by this plus the final Y offset) + /// Total number of jumps + /// The duration of the tween + /// If TRUE the tween will smoothly snap all values to integers + public static Sequence DOJump(this Rigidbody target, Vector3 endValue, float jumpPower, int numJumps, float duration, bool snapping = false) + { + if (numJumps < 1) numJumps = 1; + float startPosY = 0; + float offsetY = -1; + bool offsetYSet = false; + Sequence s = DOTween.Sequence(); + Tween yTween = DOTween.To(() => target.position, target.MovePosition, new Vector3(0, jumpPower, 0), duration / (numJumps * 2)) + .SetOptions(AxisConstraint.Y, snapping).SetEase(Ease.OutQuad).SetRelative() + .SetLoops(numJumps * 2, LoopType.Yoyo) + .OnStart(() => startPosY = target.position.y); + s.Append(DOTween.To(() => target.position, target.MovePosition, new Vector3(endValue.x, 0, 0), duration) + .SetOptions(AxisConstraint.X, snapping).SetEase(Ease.Linear) + ).Join(DOTween.To(() => target.position, target.MovePosition, new Vector3(0, 0, endValue.z), duration) + .SetOptions(AxisConstraint.Z, snapping).SetEase(Ease.Linear) + ).Join(yTween) + .SetTarget(target).SetEase(DOTween.defaultEaseType); + yTween.OnUpdate(() => { + if (!offsetYSet) { + offsetYSet = true; + offsetY = s.isRelative ? endValue.y : endValue.y - startPosY; + } + Vector3 pos = target.position; + pos.y += DOVirtual.EasedValue(0, offsetY, yTween.ElapsedPercentage(), Ease.OutQuad); + target.MovePosition(pos); + }); + return s; + } + + /// Tweens a Rigidbody's position through the given path waypoints, using the chosen path algorithm. + /// Also stores the Rigidbody as the tween's target so it can be used for filtered operations. + /// NOTE: to tween a rigidbody correctly it should be set to kinematic at least while being tweened. + /// BEWARE: doesn't work on Windows Phone store (waiting for Unity to fix their own bug). + /// If you plan to publish there you should use a regular transform.DOPath. + /// The waypoints to go through + /// The duration of the tween + /// The type of path: Linear (straight path) or CatmullRom (curved CatmullRom path) + /// The path mode: 3D, side-scroller 2D, top-down 2D + /// The resolution of the path (useless in case of Linear paths): higher resolutions make for more detailed curved paths but are more expensive. + /// Defaults to 10, but a value of 5 is usually enough if you don't have dramatic long curves between waypoints + /// The color of the path (shown when gizmos are active in the Play panel and the tween is running) + public static TweenerCore DOPath( + this Rigidbody target, Vector3[] path, float duration, PathType pathType = PathType.Linear, + PathMode pathMode = PathMode.Full3D, int resolution = 10, Color? gizmoColor = null + ) + { + if (resolution < 1) resolution = 1; + TweenerCore t = DOTween.To(PathPlugin.Get(), () => target.position, target.MovePosition, new Path(pathType, path, resolution, gizmoColor), duration) + .SetTarget(target).SetUpdate(UpdateType.Fixed); + + t.plugOptions.isRigidbody = true; + t.plugOptions.mode = pathMode; + return t; + } + /// Tweens a Rigidbody's localPosition through the given path waypoints, using the chosen path algorithm. + /// Also stores the Rigidbody as the tween's target so it can be used for filtered operations + /// NOTE: to tween a rigidbody correctly it should be set to kinematic at least while being tweened. + /// BEWARE: doesn't work on Windows Phone store (waiting for Unity to fix their own bug). + /// If you plan to publish there you should use a regular transform.DOLocalPath. + /// The waypoint to go through + /// The duration of the tween + /// The type of path: Linear (straight path) or CatmullRom (curved CatmullRom path) + /// The path mode: 3D, side-scroller 2D, top-down 2D + /// The resolution of the path: higher resolutions make for more detailed curved paths but are more expensive. + /// Defaults to 10, but a value of 5 is usually enough if you don't have dramatic long curves between waypoints + /// The color of the path (shown when gizmos are active in the Play panel and the tween is running) + public static TweenerCore DOLocalPath( + this Rigidbody target, Vector3[] path, float duration, PathType pathType = PathType.Linear, + PathMode pathMode = PathMode.Full3D, int resolution = 10, Color? gizmoColor = null + ) + { + if (resolution < 1) resolution = 1; + Transform trans = target.transform; + TweenerCore t = DOTween.To(PathPlugin.Get(), () => trans.localPosition, x => target.MovePosition(trans.parent == null ? x : trans.parent.TransformPoint(x)), new Path(pathType, path, resolution, gizmoColor), duration) + .SetTarget(target).SetUpdate(UpdateType.Fixed); + + t.plugOptions.isRigidbody = true; + t.plugOptions.mode = pathMode; + t.plugOptions.useLocalPosition = true; + return t; + } + // Used by path editor when creating the actual tween, so it can pass a pre-compiled path + internal static TweenerCore DOPath( + this Rigidbody target, Path path, float duration, PathMode pathMode = PathMode.Full3D + ) + { + TweenerCore t = DOTween.To(PathPlugin.Get(), () => target.position, target.MovePosition, path, duration) + .SetTarget(target); + + t.plugOptions.isRigidbody = true; + t.plugOptions.mode = pathMode; + return t; + } + internal static TweenerCore DOLocalPath( + this Rigidbody target, Path path, float duration, PathMode pathMode = PathMode.Full3D + ) + { + Transform trans = target.transform; + TweenerCore t = DOTween.To(PathPlugin.Get(), () => trans.localPosition, x => target.MovePosition(trans.parent == null ? x : trans.parent.TransformPoint(x)), path, duration) + .SetTarget(target); + + t.plugOptions.isRigidbody = true; + t.plugOptions.mode = pathMode; + t.plugOptions.useLocalPosition = true; + return t; + } + + #endregion + + #endregion + + #endregion + } +} +#endif diff --git a/Assets/Demigiant/DOTween/Modules/DOTweenModulePhysics.cs.meta b/Assets/Demigiant/DOTween/Modules/DOTweenModulePhysics.cs.meta new file mode 100644 index 0000000..42a0566 --- /dev/null +++ b/Assets/Demigiant/DOTween/Modules/DOTweenModulePhysics.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: dae9aa560b4242648a3affa2bfabc365 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DOTween/Modules/DOTweenModulePhysics2D.cs b/Assets/Demigiant/DOTween/Modules/DOTweenModulePhysics2D.cs new file mode 100644 index 0000000..f4e2aa2 --- /dev/null +++ b/Assets/Demigiant/DOTween/Modules/DOTweenModulePhysics2D.cs @@ -0,0 +1,101 @@ +// Author: Daniele Giardini - http://www.demigiant.com +// Created: 2018/07/13 + +#if true && (UNITY_4_3 || UNITY_4_4 || UNITY_4_5 || UNITY_4_6 || UNITY_5 || UNITY_2017_1_OR_NEWER) // MODULE_MARKER +using System; +using UnityEngine; + +#pragma warning disable 1591 +namespace DG.Tweening +{ + public static class DOTweenModulePhysics2D + { + #region Shortcuts + + #region Rigidbody2D Shortcuts + + /// Tweens a Rigidbody2D's position to the given value. + /// Also stores the Rigidbody2D as the tween's target so it can be used for filtered operations + /// The end value to reachThe duration of the tween + /// If TRUE the tween will smoothly snap all values to integers + public static Tweener DOMove(this Rigidbody2D target, Vector2 endValue, float duration, bool snapping = false) + { + return DOTween.To(() => target.position, target.MovePosition, endValue, duration) + .SetOptions(snapping).SetTarget(target); + } + + /// Tweens a Rigidbody2D's X position to the given value. + /// Also stores the Rigidbody2D as the tween's target so it can be used for filtered operations + /// The end value to reachThe duration of the tween + /// If TRUE the tween will smoothly snap all values to integers + public static Tweener DOMoveX(this Rigidbody2D target, float endValue, float duration, bool snapping = false) + { + return DOTween.To(() => target.position, target.MovePosition, new Vector2(endValue, 0), duration) + .SetOptions(AxisConstraint.X, snapping).SetTarget(target); + } + + /// Tweens a Rigidbody2D's Y position to the given value. + /// Also stores the Rigidbody2D as the tween's target so it can be used for filtered operations + /// The end value to reachThe duration of the tween + /// If TRUE the tween will smoothly snap all values to integers + public static Tweener DOMoveY(this Rigidbody2D target, float endValue, float duration, bool snapping = false) + { + return DOTween.To(() => target.position, target.MovePosition, new Vector2(0, endValue), duration) + .SetOptions(AxisConstraint.Y, snapping).SetTarget(target); + } + + /// Tweens a Rigidbody2D's rotation to the given value. + /// Also stores the Rigidbody2D as the tween's target so it can be used for filtered operations + /// The end value to reachThe duration of the tween + public static Tweener DORotate(this Rigidbody2D target, float endValue, float duration) + { + return DOTween.To(() => target.rotation, target.MoveRotation, endValue, duration) + .SetTarget(target); + } + + #region Special + + /// Tweens a Rigidbody2D's position to the given value, while also applying a jump effect along the Y axis. + /// Returns a Sequence instead of a Tweener. + /// Also stores the Rigidbody2D as the tween's target so it can be used for filtered operations. + /// IMPORTANT: a rigidbody2D can't be animated in a jump arc using MovePosition, so the tween will directly set the position + /// The end value to reach + /// Power of the jump (the max height of the jump is represented by this plus the final Y offset) + /// Total number of jumps + /// The duration of the tween + /// If TRUE the tween will smoothly snap all values to integers + public static Sequence DOJump(this Rigidbody2D target, Vector2 endValue, float jumpPower, int numJumps, float duration, bool snapping = false) + { + if (numJumps < 1) numJumps = 1; + float startPosY = 0; + float offsetY = -1; + bool offsetYSet = false; + Sequence s = DOTween.Sequence(); + Tween yTween = DOTween.To(() => target.position, x => target.position = x, new Vector2(0, jumpPower), duration / (numJumps * 2)) + .SetOptions(AxisConstraint.Y, snapping).SetEase(Ease.OutQuad).SetRelative() + .SetLoops(numJumps * 2, LoopType.Yoyo) + .OnStart(() => startPosY = target.position.y); + s.Append(DOTween.To(() => target.position, x => target.position = x, new Vector2(endValue.x, 0), duration) + .SetOptions(AxisConstraint.X, snapping).SetEase(Ease.Linear) + ).Join(yTween) + .SetTarget(target).SetEase(DOTween.defaultEaseType); + yTween.OnUpdate(() => { + if (!offsetYSet) { + offsetYSet = true; + offsetY = s.isRelative ? endValue.y : endValue.y - startPosY; + } + Vector3 pos = target.position; + pos.y += DOVirtual.EasedValue(0, offsetY, yTween.ElapsedPercentage(), Ease.OutQuad); + target.MovePosition(pos); + }); + return s; + } + + #endregion + + #endregion + + #endregion + } +} +#endif diff --git a/Assets/Demigiant/DOTween/Modules/DOTweenModulePhysics2D.cs.meta b/Assets/Demigiant/DOTween/Modules/DOTweenModulePhysics2D.cs.meta new file mode 100644 index 0000000..323d0dd --- /dev/null +++ b/Assets/Demigiant/DOTween/Modules/DOTweenModulePhysics2D.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 230fe34542e175245ba74b4659dae700 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DOTween/Modules/DOTweenModuleSprite.cs b/Assets/Demigiant/DOTween/Modules/DOTweenModuleSprite.cs new file mode 100644 index 0000000..12e07aa --- /dev/null +++ b/Assets/Demigiant/DOTween/Modules/DOTweenModuleSprite.cs @@ -0,0 +1,88 @@ +// Author: Daniele Giardini - http://www.demigiant.com +// Created: 2018/07/13 + +#if true && (UNITY_4_3 || UNITY_4_4 || UNITY_4_5 || UNITY_4_6 || UNITY_5 || UNITY_2017_1_OR_NEWER) // MODULE_MARKER +using System; +using UnityEngine; +using DG.Tweening.Core; + +#pragma warning disable 1591 +namespace DG.Tweening +{ + public static class DOTweenModuleSprite + { + #region Shortcuts + + #region SpriteRenderer + + /// Tweens a SpriteRenderer's color to the given value. + /// Also stores the spriteRenderer as the tween's target so it can be used for filtered operations + /// The end value to reachThe duration of the tween + public static Tweener DOColor(this SpriteRenderer target, Color endValue, float duration) + { + return DOTween.To(() => target.color, x => target.color = x, endValue, duration).SetTarget(target); + } + + /// Tweens a Material's alpha color to the given value. + /// Also stores the spriteRenderer as the tween's target so it can be used for filtered operations + /// The end value to reachThe duration of the tween + public static Tweener DOFade(this SpriteRenderer target, float endValue, float duration) + { + return DOTween.ToAlpha(() => target.color, x => target.color = x, endValue, duration) + .SetTarget(target); + } + + /// Tweens a SpriteRenderer's color using the given gradient + /// (NOTE 1: only uses the colors of the gradient, not the alphas - NOTE 2: creates a Sequence, not a Tweener). + /// Also stores the image as the tween's target so it can be used for filtered operations + /// The gradient to useThe duration of the tween + public static Sequence DOGradientColor(this SpriteRenderer target, Gradient gradient, float duration) + { + Sequence s = DOTween.Sequence(); + GradientColorKey[] colors = gradient.colorKeys; + int len = colors.Length; + for (int i = 0; i < len; ++i) { + GradientColorKey c = colors[i]; + if (i == 0 && c.time <= 0) { + target.color = c.color; + continue; + } + float colorDuration = i == len - 1 + ? duration - s.Duration(false) // Verifies that total duration is correct + : duration * (i == 0 ? c.time : c.time - colors[i - 1].time); + s.Append(target.DOColor(c.color, colorDuration).SetEase(Ease.Linear)); + } + return s; + } + + #endregion + + #region Blendables + + #region SpriteRenderer + + /// Tweens a SpriteRenderer's color to the given value, + /// in a way that allows other DOBlendableColor tweens to work together on the same target, + /// instead than fight each other as multiple DOColor would do. + /// Also stores the SpriteRenderer as the tween's target so it can be used for filtered operations + /// The value to tween toThe duration of the tween + public static Tweener DOBlendableColor(this SpriteRenderer target, Color endValue, float duration) + { + endValue = endValue - target.color; + Color to = new Color(0, 0, 0, 0); + return DOTween.To(() => to, x => { + Color diff = x - to; + to = x; + target.color += diff; + }, endValue, duration) + .Blendable().SetTarget(target); + } + + #endregion + + #endregion + + #endregion + } +} +#endif diff --git a/Assets/Demigiant/DOTween/Modules/DOTweenModuleSprite.cs.meta b/Assets/Demigiant/DOTween/Modules/DOTweenModuleSprite.cs.meta new file mode 100644 index 0000000..e6ade0c --- /dev/null +++ b/Assets/Demigiant/DOTween/Modules/DOTweenModuleSprite.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 188918ab119d93148aa0de59ccf5286b +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DOTween/Modules/DOTweenModuleUI.cs b/Assets/Demigiant/DOTween/Modules/DOTweenModuleUI.cs new file mode 100644 index 0000000..df2b42c --- /dev/null +++ b/Assets/Demigiant/DOTween/Modules/DOTweenModuleUI.cs @@ -0,0 +1,570 @@ +// Author: Daniele Giardini - http://www.demigiant.com +// Created: 2018/07/13 + +#if true && (UNITY_4_6 || UNITY_5 || UNITY_2017_1_OR_NEWER) // MODULE_MARKER +using System; +using UnityEngine; +using UnityEngine.UI; +using DG.Tweening.Core; +using DG.Tweening.Core.Enums; + +#pragma warning disable 1591 +namespace DG.Tweening +{ + public static class DOTweenModuleUI + { + #region Shortcuts + + #region CanvasGroup + + /// Tweens a CanvasGroup's alpha color to the given value. + /// Also stores the canvasGroup as the tween's target so it can be used for filtered operations + /// The end value to reachThe duration of the tween + public static Tweener DOFade(this CanvasGroup target, float endValue, float duration) + { + return DOTween.To(() => target.alpha, x => target.alpha = x, endValue, duration) + .SetTarget(target); + } + + #endregion + + #region Graphic + + /// Tweens an Graphic's color to the given value. + /// Also stores the image as the tween's target so it can be used for filtered operations + /// The end value to reachThe duration of the tween + public static Tweener DOColor(this Graphic target, Color endValue, float duration) + { + return DOTween.To(() => target.color, x => target.color = x, endValue, duration).SetTarget(target); + } + + /// Tweens an Graphic's alpha color to the given value. + /// Also stores the image as the tween's target so it can be used for filtered operations + /// The end value to reachThe duration of the tween + public static Tweener DOFade(this Graphic target, float endValue, float duration) + { + return DOTween.ToAlpha(() => target.color, x => target.color = x, endValue, duration) + .SetTarget(target); + } + + #endregion + + #region Image + + /// Tweens an Image's color to the given value. + /// Also stores the image as the tween's target so it can be used for filtered operations + /// The end value to reachThe duration of the tween + public static Tweener DOColor(this Image target, Color endValue, float duration) + { + return DOTween.To(() => target.color, x => target.color = x, endValue, duration).SetTarget(target); + } + + /// Tweens an Image's alpha color to the given value. + /// Also stores the image as the tween's target so it can be used for filtered operations + /// The end value to reachThe duration of the tween + public static Tweener DOFade(this Image target, float endValue, float duration) + { + return DOTween.ToAlpha(() => target.color, x => target.color = x, endValue, duration) + .SetTarget(target); + } + + /// Tweens an Image's fillAmount to the given value. + /// Also stores the image as the tween's target so it can be used for filtered operations + /// The end value to reach (0 to 1)The duration of the tween + public static Tweener DOFillAmount(this Image target, float endValue, float duration) + { + if (endValue > 1) endValue = 1; + else if (endValue < 0) endValue = 0; + return DOTween.To(() => target.fillAmount, x => target.fillAmount = x, endValue, duration) + .SetTarget(target); + } + + /// Tweens an Image's colors using the given gradient + /// (NOTE 1: only uses the colors of the gradient, not the alphas - NOTE 2: creates a Sequence, not a Tweener). + /// Also stores the image as the tween's target so it can be used for filtered operations + /// The gradient to useThe duration of the tween + public static Sequence DOGradientColor(this Image target, Gradient gradient, float duration) + { + Sequence s = DOTween.Sequence(); + GradientColorKey[] colors = gradient.colorKeys; + int len = colors.Length; + for (int i = 0; i < len; ++i) { + GradientColorKey c = colors[i]; + if (i == 0 && c.time <= 0) { + target.color = c.color; + continue; + } + float colorDuration = i == len - 1 + ? duration - s.Duration(false) // Verifies that total duration is correct + : duration * (i == 0 ? c.time : c.time - colors[i - 1].time); + s.Append(target.DOColor(c.color, colorDuration).SetEase(Ease.Linear)); + } + return s; + } + + #endregion + + #region LayoutElement + + /// Tweens an LayoutElement's flexibleWidth/Height to the given value. + /// Also stores the LayoutElement as the tween's target so it can be used for filtered operations + /// The end value to reachThe duration of the tween + /// If TRUE the tween will smoothly snap all values to integers + public static Tweener DOFlexibleSize(this LayoutElement target, Vector2 endValue, float duration, bool snapping = false) + { + return DOTween.To(() => new Vector2(target.flexibleWidth, target.flexibleHeight), x => { + target.flexibleWidth = x.x; + target.flexibleHeight = x.y; + }, endValue, duration) + .SetOptions(snapping).SetTarget(target); + } + + /// Tweens an LayoutElement's minWidth/Height to the given value. + /// Also stores the LayoutElement as the tween's target so it can be used for filtered operations + /// The end value to reachThe duration of the tween + /// If TRUE the tween will smoothly snap all values to integers + public static Tweener DOMinSize(this LayoutElement target, Vector2 endValue, float duration, bool snapping = false) + { + return DOTween.To(() => new Vector2(target.minWidth, target.minHeight), x => { + target.minWidth = x.x; + target.minHeight = x.y; + }, endValue, duration) + .SetOptions(snapping).SetTarget(target); + } + + /// Tweens an LayoutElement's preferredWidth/Height to the given value. + /// Also stores the LayoutElement as the tween's target so it can be used for filtered operations + /// The end value to reachThe duration of the tween + /// If TRUE the tween will smoothly snap all values to integers + public static Tweener DOPreferredSize(this LayoutElement target, Vector2 endValue, float duration, bool snapping = false) + { + return DOTween.To(() => new Vector2(target.preferredWidth, target.preferredHeight), x => { + target.preferredWidth = x.x; + target.preferredHeight = x.y; + }, endValue, duration) + .SetOptions(snapping).SetTarget(target); + } + + #endregion + + #region Outline + + /// Tweens a Outline's effectColor to the given value. + /// Also stores the Outline as the tween's target so it can be used for filtered operations + /// The end value to reachThe duration of the tween + public static Tweener DOColor(this Outline target, Color endValue, float duration) + { + return DOTween.To(() => target.effectColor, x => target.effectColor = x, endValue, duration).SetTarget(target); + } + + /// Tweens a Outline's effectColor alpha to the given value. + /// Also stores the Outline as the tween's target so it can be used for filtered operations + /// The end value to reachThe duration of the tween + public static Tweener DOFade(this Outline target, float endValue, float duration) + { + return DOTween.ToAlpha(() => target.effectColor, x => target.effectColor = x, endValue, duration) + .SetTarget(target); + } + + /// Tweens a Outline's effectDistance to the given value. + /// Also stores the Outline as the tween's target so it can be used for filtered operations + /// The end value to reachThe duration of the tween + public static Tweener DOScale(this Outline target, Vector2 endValue, float duration) + { + return DOTween.To(() => target.effectDistance, x => target.effectDistance = x, endValue, duration) + .SetTarget(target); + } + + #endregion + + #region RectTransform + + /// Tweens a RectTransform's anchoredPosition to the given value. + /// Also stores the RectTransform as the tween's target so it can be used for filtered operations + /// The end value to reachThe duration of the tween + /// If TRUE the tween will smoothly snap all values to integers + public static Tweener DOAnchorPos(this RectTransform target, Vector2 endValue, float duration, bool snapping = false) + { + return DOTween.To(() => target.anchoredPosition, x => target.anchoredPosition = x, endValue, duration) + .SetOptions(snapping).SetTarget(target); + } + /// Tweens a RectTransform's anchoredPosition X to the given value. + /// Also stores the RectTransform as the tween's target so it can be used for filtered operations + /// The end value to reachThe duration of the tween + /// If TRUE the tween will smoothly snap all values to integers + public static Tweener DOAnchorPosX(this RectTransform target, float endValue, float duration, bool snapping = false) + { + return DOTween.To(() => target.anchoredPosition, x => target.anchoredPosition = x, new Vector2(endValue, 0), duration) + .SetOptions(AxisConstraint.X, snapping).SetTarget(target); + } + /// Tweens a RectTransform's anchoredPosition Y to the given value. + /// Also stores the RectTransform as the tween's target so it can be used for filtered operations + /// The end value to reachThe duration of the tween + /// If TRUE the tween will smoothly snap all values to integers + public static Tweener DOAnchorPosY(this RectTransform target, float endValue, float duration, bool snapping = false) + { + return DOTween.To(() => target.anchoredPosition, x => target.anchoredPosition = x, new Vector2(0, endValue), duration) + .SetOptions(AxisConstraint.Y, snapping).SetTarget(target); + } + + /// Tweens a RectTransform's anchoredPosition3D to the given value. + /// Also stores the RectTransform as the tween's target so it can be used for filtered operations + /// The end value to reachThe duration of the tween + /// If TRUE the tween will smoothly snap all values to integers + public static Tweener DOAnchorPos3D(this RectTransform target, Vector3 endValue, float duration, bool snapping = false) + { + return DOTween.To(() => target.anchoredPosition3D, x => target.anchoredPosition3D = x, endValue, duration) + .SetOptions(snapping).SetTarget(target); + } + /// Tweens a RectTransform's anchoredPosition3D X to the given value. + /// Also stores the RectTransform as the tween's target so it can be used for filtered operations + /// The end value to reachThe duration of the tween + /// If TRUE the tween will smoothly snap all values to integers + public static Tweener DOAnchorPos3DX(this RectTransform target, float endValue, float duration, bool snapping = false) + { + return DOTween.To(() => target.anchoredPosition3D, x => target.anchoredPosition3D = x, new Vector3(endValue, 0, 0), duration) + .SetOptions(AxisConstraint.X, snapping).SetTarget(target); + } + /// Tweens a RectTransform's anchoredPosition3D Y to the given value. + /// Also stores the RectTransform as the tween's target so it can be used for filtered operations + /// The end value to reachThe duration of the tween + /// If TRUE the tween will smoothly snap all values to integers + public static Tweener DOAnchorPos3DY(this RectTransform target, float endValue, float duration, bool snapping = false) + { + return DOTween.To(() => target.anchoredPosition3D, x => target.anchoredPosition3D = x, new Vector3(0, endValue, 0), duration) + .SetOptions(AxisConstraint.Y, snapping).SetTarget(target); + } + /// Tweens a RectTransform's anchoredPosition3D Z to the given value. + /// Also stores the RectTransform as the tween's target so it can be used for filtered operations + /// The end value to reachThe duration of the tween + /// If TRUE the tween will smoothly snap all values to integers + public static Tweener DOAnchorPos3DZ(this RectTransform target, float endValue, float duration, bool snapping = false) + { + return DOTween.To(() => target.anchoredPosition3D, x => target.anchoredPosition3D = x, new Vector3(0, 0, endValue), duration) + .SetOptions(AxisConstraint.Z, snapping).SetTarget(target); + } + + /// Tweens a RectTransform's anchorMax to the given value. + /// Also stores the RectTransform as the tween's target so it can be used for filtered operations + /// The end value to reachThe duration of the tween + /// If TRUE the tween will smoothly snap all values to integers + public static Tweener DOAnchorMax(this RectTransform target, Vector2 endValue, float duration, bool snapping = false) + { + return DOTween.To(() => target.anchorMax, x => target.anchorMax = x, endValue, duration) + .SetOptions(snapping).SetTarget(target); + } + + /// Tweens a RectTransform's anchorMin to the given value. + /// Also stores the RectTransform as the tween's target so it can be used for filtered operations + /// The end value to reachThe duration of the tween + /// If TRUE the tween will smoothly snap all values to integers + public static Tweener DOAnchorMin(this RectTransform target, Vector2 endValue, float duration, bool snapping = false) + { + return DOTween.To(() => target.anchorMin, x => target.anchorMin = x, endValue, duration) + .SetOptions(snapping).SetTarget(target); + } + + /// Tweens a RectTransform's pivot to the given value. + /// Also stores the RectTransform as the tween's target so it can be used for filtered operations + /// The end value to reachThe duration of the tween + public static Tweener DOPivot(this RectTransform target, Vector2 endValue, float duration) + { + return DOTween.To(() => target.pivot, x => target.pivot = x, endValue, duration) + .SetTarget(target); + } + /// Tweens a RectTransform's pivot X to the given value. + /// Also stores the RectTransform as the tween's target so it can be used for filtered operations + /// The end value to reachThe duration of the tween + public static Tweener DOPivotX(this RectTransform target, float endValue, float duration) + { + return DOTween.To(() => target.pivot, x => target.pivot = x, new Vector2(endValue, 0), duration) + .SetOptions(AxisConstraint.X).SetTarget(target); + } + /// Tweens a RectTransform's pivot Y to the given value. + /// Also stores the RectTransform as the tween's target so it can be used for filtered operations + /// The end value to reachThe duration of the tween + public static Tweener DOPivotY(this RectTransform target, float endValue, float duration) + { + return DOTween.To(() => target.pivot, x => target.pivot = x, new Vector2(0, endValue), duration) + .SetOptions(AxisConstraint.Y).SetTarget(target); + } + + /// Tweens a RectTransform's sizeDelta to the given value. + /// Also stores the RectTransform as the tween's target so it can be used for filtered operations + /// The end value to reachThe duration of the tween + /// If TRUE the tween will smoothly snap all values to integers + public static Tweener DOSizeDelta(this RectTransform target, Vector2 endValue, float duration, bool snapping = false) + { + return DOTween.To(() => target.sizeDelta, x => target.sizeDelta = x, endValue, duration) + .SetOptions(snapping).SetTarget(target); + } + + /// Punches a RectTransform's anchoredPosition towards the given direction and then back to the starting one + /// as if it was connected to the starting position via an elastic. + /// Also stores the RectTransform as the tween's target so it can be used for filtered operations + /// The direction and strength of the punch (added to the RectTransform's current position) + /// The duration of the tween + /// Indicates how much will the punch vibrate + /// Represents how much (0 to 1) the vector will go beyond the starting position when bouncing backwards. + /// 1 creates a full oscillation between the punch direction and the opposite direction, + /// while 0 oscillates only between the punch and the start position + /// If TRUE the tween will smoothly snap all values to integers + public static Tweener DOPunchAnchorPos(this RectTransform target, Vector2 punch, float duration, int vibrato = 10, float elasticity = 1, bool snapping = false) + { + return DOTween.Punch(() => target.anchoredPosition, x => target.anchoredPosition = x, punch, duration, vibrato, elasticity) + .SetTarget(target).SetOptions(snapping); + } + + /// Shakes a RectTransform's anchoredPosition with the given values. + /// Also stores the RectTransform as the tween's target so it can be used for filtered operations + /// The duration of the tween + /// The shake strength + /// Indicates how much will the shake vibrate + /// Indicates how much the shake will be random (0 to 180 - values higher than 90 kind of suck, so beware). + /// Setting it to 0 will shake along a single direction. + /// If TRUE the tween will smoothly snap all values to integers + /// If TRUE the shake will automatically fadeOut smoothly within the tween's duration, otherwise it will not + public static Tweener DOShakeAnchorPos(this RectTransform target, float duration, float strength = 100, int vibrato = 10, float randomness = 90, bool snapping = false, bool fadeOut = true) + { + return DOTween.Shake(() => target.anchoredPosition, x => target.anchoredPosition = x, duration, strength, vibrato, randomness, true, fadeOut) + .SetTarget(target).SetSpecialStartupMode(SpecialStartupMode.SetShake).SetOptions(snapping); + } + /// Shakes a RectTransform's anchoredPosition with the given values. + /// Also stores the RectTransform as the tween's target so it can be used for filtered operations + /// The duration of the tween + /// The shake strength on each axis + /// Indicates how much will the shake vibrate + /// Indicates how much the shake will be random (0 to 180 - values higher than 90 kind of suck, so beware). + /// Setting it to 0 will shake along a single direction. + /// If TRUE the tween will smoothly snap all values to integers + /// If TRUE the shake will automatically fadeOut smoothly within the tween's duration, otherwise it will not + public static Tweener DOShakeAnchorPos(this RectTransform target, float duration, Vector2 strength, int vibrato = 10, float randomness = 90, bool snapping = false, bool fadeOut = true) + { + return DOTween.Shake(() => target.anchoredPosition, x => target.anchoredPosition = x, duration, strength, vibrato, randomness, fadeOut) + .SetTarget(target).SetSpecialStartupMode(SpecialStartupMode.SetShake).SetOptions(snapping); + } + + #region Special + + /// Tweens a RectTransform's anchoredPosition to the given value, while also applying a jump effect along the Y axis. + /// Returns a Sequence instead of a Tweener. + /// Also stores the RectTransform as the tween's target so it can be used for filtered operations + /// The end value to reach + /// Power of the jump (the max height of the jump is represented by this plus the final Y offset) + /// Total number of jumps + /// The duration of the tween + /// If TRUE the tween will smoothly snap all values to integers + public static Sequence DOJumpAnchorPos(this RectTransform target, Vector2 endValue, float jumpPower, int numJumps, float duration, bool snapping = false) + { + if (numJumps < 1) numJumps = 1; + float startPosY = 0; + float offsetY = -1; + bool offsetYSet = false; + + // Separate Y Tween so we can elaborate elapsedPercentage on that insted of on the Sequence + // (in case users add a delay or other elements to the Sequence) + Sequence s = DOTween.Sequence(); + Tween yTween = DOTween.To(() => target.anchoredPosition, x => target.anchoredPosition = x, new Vector2(0, jumpPower), duration / (numJumps * 2)) + .SetOptions(AxisConstraint.Y, snapping).SetEase(Ease.OutQuad).SetRelative() + .SetLoops(numJumps * 2, LoopType.Yoyo) + .OnStart(()=> startPosY = target.anchoredPosition.y); + s.Append(DOTween.To(() => target.anchoredPosition, x => target.anchoredPosition = x, new Vector2(endValue.x, 0), duration) + .SetOptions(AxisConstraint.X, snapping).SetEase(Ease.Linear) + ).Join(yTween) + .SetTarget(target).SetEase(DOTween.defaultEaseType); + s.OnUpdate(() => { + if (!offsetYSet) { + offsetYSet = true; + offsetY = s.isRelative ? endValue.y : endValue.y - startPosY; + } + Vector2 pos = target.anchoredPosition; + pos.y += DOVirtual.EasedValue(0, offsetY, s.ElapsedDirectionalPercentage(), Ease.OutQuad); + target.anchoredPosition = pos; + }); + return s; + } + + #endregion + + #endregion + + #region ScrollRect + + /// Tweens a ScrollRect's horizontal/verticalNormalizedPosition to the given value. + /// Also stores the ScrollRect as the tween's target so it can be used for filtered operations + /// The end value to reachThe duration of the tween + /// If TRUE the tween will smoothly snap all values to integers + public static Tweener DONormalizedPos(this ScrollRect target, Vector2 endValue, float duration, bool snapping = false) + { + return DOTween.To(() => new Vector2(target.horizontalNormalizedPosition, target.verticalNormalizedPosition), + x => { + target.horizontalNormalizedPosition = x.x; + target.verticalNormalizedPosition = x.y; + }, endValue, duration) + .SetOptions(snapping).SetTarget(target); + } + /// Tweens a ScrollRect's horizontalNormalizedPosition to the given value. + /// Also stores the ScrollRect as the tween's target so it can be used for filtered operations + /// The end value to reachThe duration of the tween + /// If TRUE the tween will smoothly snap all values to integers + public static Tweener DOHorizontalNormalizedPos(this ScrollRect target, float endValue, float duration, bool snapping = false) + { + return DOTween.To(() => target.horizontalNormalizedPosition, x => target.horizontalNormalizedPosition = x, endValue, duration) + .SetOptions(snapping).SetTarget(target); + } + /// Tweens a ScrollRect's verticalNormalizedPosition to the given value. + /// Also stores the ScrollRect as the tween's target so it can be used for filtered operations + /// The end value to reachThe duration of the tween + /// If TRUE the tween will smoothly snap all values to integers + public static Tweener DOVerticalNormalizedPos(this ScrollRect target, float endValue, float duration, bool snapping = false) + { + return DOTween.To(() => target.verticalNormalizedPosition, x => target.verticalNormalizedPosition = x, endValue, duration) + .SetOptions(snapping).SetTarget(target); + } + + #endregion + + #region Slider + + /// Tweens a Slider's value to the given value. + /// Also stores the Slider as the tween's target so it can be used for filtered operations + /// The end value to reachThe duration of the tween + /// If TRUE the tween will smoothly snap all values to integers + public static Tweener DOValue(this Slider target, float endValue, float duration, bool snapping = false) + { + return DOTween.To(() => target.value, x => target.value = x, endValue, duration) + .SetOptions(snapping).SetTarget(target); + } + + #endregion + + #region Text + + /// Tweens a Text's color to the given value. + /// Also stores the Text as the tween's target so it can be used for filtered operations + /// The end value to reachThe duration of the tween + public static Tweener DOColor(this Text target, Color endValue, float duration) + { + return DOTween.To(() => target.color, x => target.color = x, endValue, duration).SetTarget(target); + } + + /// Tweens a Text's alpha color to the given value. + /// Also stores the Text as the tween's target so it can be used for filtered operations + /// The end value to reachThe duration of the tween + public static Tweener DOFade(this Text target, float endValue, float duration) + { + return DOTween.ToAlpha(() => target.color, x => target.color = x, endValue, duration) + .SetTarget(target); + } + + /// Tweens a Text's text to the given value. + /// Also stores the Text as the tween's target so it can be used for filtered operations + /// The end string to tween toThe duration of the tween + /// If TRUE (default), rich text will be interpreted correctly while animated, + /// otherwise all tags will be considered as normal text + /// The type of scramble mode to use, if any + /// A string containing the characters to use for scrambling. + /// Use as many characters as possible (minimum 10) because DOTween uses a fast scramble mode which gives better results with more characters. + /// Leave it to NULL (default) to use default ones + public static Tweener DOText(this Text target, string endValue, float duration, bool richTextEnabled = true, ScrambleMode scrambleMode = ScrambleMode.None, string scrambleChars = null) + { + return DOTween.To(() => target.text, x => target.text = x, endValue, duration) + .SetOptions(richTextEnabled, scrambleMode, scrambleChars) + .SetTarget(target); + } + + #endregion + + #region Blendables + + #region Graphic + + /// Tweens a Graphic's color to the given value, + /// in a way that allows other DOBlendableColor tweens to work together on the same target, + /// instead than fight each other as multiple DOColor would do. + /// Also stores the Graphic as the tween's target so it can be used for filtered operations + /// The value to tween toThe duration of the tween + public static Tweener DOBlendableColor(this Graphic target, Color endValue, float duration) + { + endValue = endValue - target.color; + Color to = new Color(0, 0, 0, 0); + return DOTween.To(() => to, x => { + Color diff = x - to; + to = x; + target.color += diff; + }, endValue, duration) + .Blendable().SetTarget(target); + } + + #endregion + + #region Image + + /// Tweens a Image's color to the given value, + /// in a way that allows other DOBlendableColor tweens to work together on the same target, + /// instead than fight each other as multiple DOColor would do. + /// Also stores the Image as the tween's target so it can be used for filtered operations + /// The value to tween toThe duration of the tween + public static Tweener DOBlendableColor(this Image target, Color endValue, float duration) + { + endValue = endValue - target.color; + Color to = new Color(0, 0, 0, 0); + return DOTween.To(() => to, x => { + Color diff = x - to; + to = x; + target.color += diff; + }, endValue, duration) + .Blendable().SetTarget(target); + } + + #endregion + + #region Text + + /// Tweens a Text's color BY the given value, + /// in a way that allows other DOBlendableColor tweens to work together on the same target, + /// instead than fight each other as multiple DOColor would do. + /// Also stores the Text as the tween's target so it can be used for filtered operations + /// The value to tween toThe duration of the tween + public static Tweener DOBlendableColor(this Text target, Color endValue, float duration) + { + endValue = endValue - target.color; + Color to = new Color(0, 0, 0, 0); + return DOTween.To(() => to, x => { + Color diff = x - to; + to = x; + target.color += diff; + }, endValue, duration) + .Blendable().SetTarget(target); + } + + #endregion + + #endregion + + #endregion + + // █████████████████████████████████████████████████████████████████████████████████████████████████████████████████████ + // ███ INTERNAL CLASSES ████████████████████████████████████████████████████████████████████████████████████████████████ + // █████████████████████████████████████████████████████████████████████████████████████████████████████████████████████ + + public static class Utils + { + /// + /// Converts the anchoredPosition of the first RectTransform to the second RectTransform, + /// taking into consideration offset, anchors and pivot, and returns the new anchoredPosition + /// + public static Vector2 SwitchToRectTransform(RectTransform from, RectTransform to) + { + Vector2 localPoint; + Vector2 fromPivotDerivedOffset = new Vector2(from.rect.width * 0.5f + from.rect.xMin, from.rect.height * 0.5f + from.rect.yMin); + Vector2 screenP = RectTransformUtility.WorldToScreenPoint(null, from.position); + screenP += fromPivotDerivedOffset; + RectTransformUtility.ScreenPointToLocalPointInRectangle(to, screenP, null, out localPoint); + Vector2 pivotDerivedOffset = new Vector2(to.rect.width * 0.5f + to.rect.xMin, to.rect.height * 0.5f + to.rect.yMin); + return to.anchoredPosition + localPoint - pivotDerivedOffset; + } + } + } +} +#endif diff --git a/Assets/Demigiant/DOTween/Modules/DOTweenModuleUI.cs.meta b/Assets/Demigiant/DOTween/Modules/DOTweenModuleUI.cs.meta new file mode 100644 index 0000000..b7f95cb --- /dev/null +++ b/Assets/Demigiant/DOTween/Modules/DOTweenModuleUI.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: a060394c03331a64392db53a10e7f2d1 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DOTween/Modules/DOTweenModuleUnityVersion.cs b/Assets/Demigiant/DOTween/Modules/DOTweenModuleUnityVersion.cs new file mode 100644 index 0000000..26c4a69 --- /dev/null +++ b/Assets/Demigiant/DOTween/Modules/DOTweenModuleUnityVersion.cs @@ -0,0 +1,252 @@ +// Author: Daniele Giardini - http://www.demigiant.com +// Created: 2018/07/13 + +using System; +using UnityEngine; +using DG.Tweening.Core; + +#pragma warning disable 1591 +namespace DG.Tweening +{ + /// + /// Shortcuts/functions that are not strictly related to specific Modules + /// but are available only on some Unity versions + /// + public static class DOTweenModuleUnityVersion + { +#if UNITY_4_3 || UNITY_4_4 || UNITY_4_5 || UNITY_4_6 || UNITY_5 || UNITY_2017_1_OR_NEWER + #region Unity 4.3 or Newer + + #region Material + + /// Tweens a Material's color using the given gradient + /// (NOTE 1: only uses the colors of the gradient, not the alphas - NOTE 2: creates a Sequence, not a Tweener). + /// Also stores the image as the tween's target so it can be used for filtered operations + /// The gradient to useThe duration of the tween + public static Sequence DOGradientColor(this Material target, Gradient gradient, float duration) + { + Sequence s = DOTween.Sequence(); + GradientColorKey[] colors = gradient.colorKeys; + int len = colors.Length; + for (int i = 0; i < len; ++i) { + GradientColorKey c = colors[i]; + if (i == 0 && c.time <= 0) { + target.color = c.color; + continue; + } + float colorDuration = i == len - 1 + ? duration - s.Duration(false) // Verifies that total duration is correct + : duration * (i == 0 ? c.time : c.time - colors[i - 1].time); + s.Append(target.DOColor(c.color, colorDuration).SetEase(Ease.Linear)); + } + return s; + } + /// Tweens a Material's named color property using the given gradient + /// (NOTE 1: only uses the colors of the gradient, not the alphas - NOTE 2: creates a Sequence, not a Tweener). + /// Also stores the image as the tween's target so it can be used for filtered operations + /// The gradient to use + /// The name of the material property to tween (like _Tint or _SpecColor) + /// The duration of the tween + public static Sequence DOGradientColor(this Material target, Gradient gradient, string property, float duration) + { + Sequence s = DOTween.Sequence(); + GradientColorKey[] colors = gradient.colorKeys; + int len = colors.Length; + for (int i = 0; i < len; ++i) { + GradientColorKey c = colors[i]; + if (i == 0 && c.time <= 0) { + target.SetColor(property, c.color); + continue; + } + float colorDuration = i == len - 1 + ? duration - s.Duration(false) // Verifies that total duration is correct + : duration * (i == 0 ? c.time : c.time - colors[i - 1].time); + s.Append(target.DOColor(c.color, property, colorDuration).SetEase(Ease.Linear)); + } + return s; + } + + #endregion + + #endregion +#endif + +#if UNITY_5_3_OR_NEWER || UNITY_2017_1_OR_NEWER + #region CustomYieldInstructions (Unity 5.3 or Newer) + + /// + /// Returns a that waits until the tween is killed or complete. + /// It can be used inside a coroutine as a yield. + /// Example usage:yield return myTween.WaitForCompletion(true); + /// + public static CustomYieldInstruction WaitForCompletion(this Tween t, bool returnCustomYieldInstruction) + { + if (!t.active) { + if (Debugger.logPriority > 0) Debugger.LogInvalidTween(t); + return null; + } + return new DOTweenCYInstruction.WaitForCompletion(t); + } + + /// + /// Returns a that waits until the tween is killed or rewinded. + /// It can be used inside a coroutine as a yield. + /// Example usage:yield return myTween.WaitForRewind(); + /// + public static CustomYieldInstruction WaitForRewind(this Tween t, bool returnCustomYieldInstruction) + { + if (!t.active) { + if (Debugger.logPriority > 0) Debugger.LogInvalidTween(t); + return null; + } + return new DOTweenCYInstruction.WaitForRewind(t); + } + + /// + /// Returns a that waits until the tween is killed. + /// It can be used inside a coroutine as a yield. + /// Example usage:yield return myTween.WaitForKill(); + /// + public static CustomYieldInstruction WaitForKill(this Tween t, bool returnCustomYieldInstruction) + { + if (!t.active) { + if (Debugger.logPriority > 0) Debugger.LogInvalidTween(t); + return null; + } + return new DOTweenCYInstruction.WaitForKill(t); + } + + /// + /// Returns a that waits until the tween is killed or has gone through the given amount of loops. + /// It can be used inside a coroutine as a yield. + /// Example usage:yield return myTween.WaitForElapsedLoops(2); + /// + /// Elapsed loops to wait for + public static CustomYieldInstruction WaitForElapsedLoops(this Tween t, int elapsedLoops, bool returnCustomYieldInstruction) + { + if (!t.active) { + if (Debugger.logPriority > 0) Debugger.LogInvalidTween(t); + return null; + } + return new DOTweenCYInstruction.WaitForElapsedLoops(t, elapsedLoops); + } + + /// + /// Returns a that waits until the tween is killed or has reached the given position (loops included, delays excluded). + /// It can be used inside a coroutine as a yield. + /// Example usage:yield return myTween.WaitForPosition(2.5f); + /// + /// Position (loops included, delays excluded) to wait for + public static CustomYieldInstruction WaitForPosition(this Tween t, float position, bool returnCustomYieldInstruction) + { + if (!t.active) { + if (Debugger.logPriority > 0) Debugger.LogInvalidTween(t); + return null; + } + return new DOTweenCYInstruction.WaitForPosition(t, position); + } + + /// + /// Returns a that waits until the tween is killed or started + /// (meaning when the tween is set in a playing state the first time, after any eventual delay). + /// It can be used inside a coroutine as a yield. + /// Example usage:yield return myTween.WaitForStart(); + /// + public static CustomYieldInstruction WaitForStart(this Tween t, bool returnCustomYieldInstruction) + { + if (!t.active) { + if (Debugger.logPriority > 0) Debugger.LogInvalidTween(t); + return null; + } + return new DOTweenCYInstruction.WaitForStart(t); + } + + #endregion +#endif + } + + // █████████████████████████████████████████████████████████████████████████████████████████████████████████████████████ + // ███ CLASSES █████████████████████████████████████████████████████████████████████████████████████████████████████████ + // █████████████████████████████████████████████████████████████████████████████████████████████████████████████████████ + +#if UNITY_5_3_OR_NEWER || UNITY_2017_1_OR_NEWER + public static class DOTweenCYInstruction + { + public class WaitForCompletion : CustomYieldInstruction + { + public override bool keepWaiting { get { + return t.active && !t.IsComplete(); + }} + readonly Tween t; + public WaitForCompletion(Tween tween) + { + t = tween; + } + } + + public class WaitForRewind : CustomYieldInstruction + { + public override bool keepWaiting { get { + return t.active && (!t.playedOnce || t.position * (t.CompletedLoops() + 1) > 0); + }} + readonly Tween t; + public WaitForRewind(Tween tween) + { + t = tween; + } + } + + public class WaitForKill : CustomYieldInstruction + { + public override bool keepWaiting { get { + return t.active; + }} + readonly Tween t; + public WaitForKill(Tween tween) + { + t = tween; + } + } + + public class WaitForElapsedLoops : CustomYieldInstruction + { + public override bool keepWaiting { get { + return t.active && t.CompletedLoops() < elapsedLoops; + }} + readonly Tween t; + readonly int elapsedLoops; + public WaitForElapsedLoops(Tween tween, int elapsedLoops) + { + t = tween; + this.elapsedLoops = elapsedLoops; + } + } + + public class WaitForPosition : CustomYieldInstruction + { + public override bool keepWaiting { get { + return t.active && t.position * (t.CompletedLoops() + 1) < position; + }} + readonly Tween t; + readonly float position; + public WaitForPosition(Tween tween, float position) + { + t = tween; + this.position = position; + } + } + + public class WaitForStart : CustomYieldInstruction + { + public override bool keepWaiting { get { + return t.active && !t.playedOnce; + }} + readonly Tween t; + public WaitForStart(Tween tween) + { + t = tween; + } + } + } +#endif +} diff --git a/Assets/Demigiant/DOTween/Modules/DOTweenModuleUnityVersion.cs.meta b/Assets/Demigiant/DOTween/Modules/DOTweenModuleUnityVersion.cs.meta new file mode 100644 index 0000000..6256c54 --- /dev/null +++ b/Assets/Demigiant/DOTween/Modules/DOTweenModuleUnityVersion.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 63c02322328255542995bd02b47b0457 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DOTween/Modules/DOTweenModuleUtils.cs b/Assets/Demigiant/DOTween/Modules/DOTweenModuleUtils.cs new file mode 100644 index 0000000..acc9124 --- /dev/null +++ b/Assets/Demigiant/DOTween/Modules/DOTweenModuleUtils.cs @@ -0,0 +1,128 @@ +// Author: Daniele Giardini - http://www.demigiant.com +// Created: 2018/07/13 + +using UnityEngine; +using DG.Tweening.Core; +using DG.Tweening.Plugins.Core.PathCore; +using DG.Tweening.Plugins.Options; + +#pragma warning disable 1591 +namespace DG.Tweening +{ + /// + /// Utility functions that deal with available Modules. + /// Modules defines: + /// - DOTAUDIO + /// - DOTPHYSICS + /// - DOTPHYSICS2D + /// - DOTSPRITE + /// - DOTUI + /// Extra defines set and used for implementation of external assets: + /// - DOTWEEN_TMP ► TextMesh Pro + /// - DOTWEEN_TK2D ► 2D Toolkit + /// + public static class DOTweenModuleUtils + { + static bool _initialized; + + /// + /// Called via Reflection by DOTweenComponent on Awake + /// + public static void Init() + { + if (_initialized) return; + + _initialized = true; + DOTweenExternalCommand.SetOrientationOnPath += Physics.SetOrientationOnPath; + +#if UNITY_EDITOR +#if UNITY_4_3 || UNITY_4_4 || UNITY_4_5 || UNITY_4_6 || UNITY_5 + UnityEditor.EditorApplication.playmodeStateChanged += PlaymodeStateChanged; +#else + UnityEditor.EditorApplication.playModeStateChanged += PlaymodeStateChanged; +#endif +#endif + } + +#if UNITY_EDITOR + // Fires OnApplicationPause in DOTweenComponent even when Editor is paused (otherwise it's only fired at runtime) +#if UNITY_4_3 || UNITY_4_4 || UNITY_4_5 || UNITY_4_6 || UNITY_5 + static void PlaymodeStateChanged() + #else + static void PlaymodeStateChanged(UnityEditor.PlayModeStateChange state) +#endif + { + if (DOTween.instance == null) return; + DOTween.instance.OnApplicationPause(UnityEditor.EditorApplication.isPaused); + } +#endif + + // █████████████████████████████████████████████████████████████████████████████████████████████████████████████████████ + // ███ INTERNAL CLASSES ████████████████████████████████████████████████████████████████████████████████████████████████ + // █████████████████████████████████████████████████████████████████████████████████████████████████████████████████████ + + public static class Physics + { + // Called via DOTweenExternalCommand callback + public static void SetOrientationOnPath(PathOptions options, Tween t, Quaternion newRot, Transform trans) + { +#if true // PHYSICS_MARKER + if (options.isRigidbody) ((Rigidbody)t.target).rotation = newRot; + else trans.rotation = newRot; +#else + trans.rotation = newRot; +#endif + } + + // Returns FALSE if the DOTween's Physics2D Module is disabled, or if there's no Rigidbody2D attached + public static bool HasRigidbody2D(Component target) + { +#if true // PHYSICS2D_MARKER + return target.GetComponent() != null; +#else + return false; +#endif + } + + #region Called via Reflection + + + // Called via Reflection by DOTweenPathInspector + // Returns FALSE if the DOTween's Physics Module is disabled, or if there's no rigidbody attached + public static bool HasRigidbody(Component target) + { +#if true // PHYSICS_MARKER + return target.GetComponent() != null; +#else + return false; +#endif + } + + // Called via Reflection by DOTweenPath + public static TweenerCore CreateDOTweenPathTween( + MonoBehaviour target, bool tweenRigidbody, bool isLocal, Path path, float duration, PathMode pathMode + ){ + TweenerCore t; +#if true // PHYSICS_MARKER + Rigidbody rBody = tweenRigidbody ? target.GetComponent() : null; + if (tweenRigidbody && rBody != null) { + t = isLocal + ? rBody.DOLocalPath(path, duration, pathMode) + : rBody.DOPath(path, duration, pathMode); + } else { + t = isLocal + ? target.transform.DOLocalPath(path, duration, pathMode) + : target.transform.DOPath(path, duration, pathMode); + } +#else + t = isLocal + ? target.transform.DOLocalPath(path, duration, pathMode) + : target.transform.DOPath(path, duration, pathMode); +#endif + return t; + } + + #endregion + } + } +} diff --git a/Assets/Demigiant/DOTween/Modules/DOTweenModuleUtils.cs.meta b/Assets/Demigiant/DOTween/Modules/DOTweenModuleUtils.cs.meta new file mode 100644 index 0000000..9164e1e --- /dev/null +++ b/Assets/Demigiant/DOTween/Modules/DOTweenModuleUtils.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 7bcaf917d9cf5b84090421a5a2abe42e +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DOTween/readme.txt b/Assets/Demigiant/DOTween/readme.txt new file mode 100644 index 0000000..37ff7ef --- /dev/null +++ b/Assets/Demigiant/DOTween/readme.txt @@ -0,0 +1,29 @@ +DOTween and DOTween Pro are copyright (c) 2014-2018 Daniele Giardini - Demigiant + +// IMPORTANT!!! ///////////////////////////////////////////// +// Upgrading DOTween from versions older than 1.2.000 /////// +// (or DOTween Pro older than 1.0.000) ////////////////////// +------------------------------------------------------------- +If you're upgrading your project from a version of DOTween older than 1.2.000 (or DOTween Pro older than 1.0.000) please follow these instructions carefully. +1) Import the new version in the same folder as the previous one, overwriting old files. A lot of errors will appear but don't worry +2) Close and reopen Unity (and your project). This is fundamental: skipping this step will cause a bloodbath +3) Open DOTween's Utility Panel (Tools > Demigiant > DOTween Utility Panel) if it doesn't open automatically, then press "Setup DOTween...": this will run the upgrade setup +4) From the Add/Remove Modules panel that opens, activate/deactivate Modules for Unity systems and for external assets (Pro version only) + +// GET STARTED ////////////////////////////////////////////// + +- After importing a new DOTween update, select DOTween's Utility Panel from the "Tools/Demigiant" menu (if it doesn't open automatically) and press the "Setup DOTween..." button to activate/deactivate Modules. You can also access a Preferences Tab from there to choose default settings for DOTween. +- In your code, add "using DG.Tweening" to each class where you want to use DOTween. +- You're ready to tween. Check out the links below for full documentation and license info. + + +// LINKS /////////////////////////////////////////////////////// + +DOTween website (documentation, examples, etc): http://dotween.demigiant.com +DOTween license: http://dotween.demigiant.com/license.php +DOTween repository (Google Code): https://code.google.com/p/dotween/ +Demigiant website (documentation, examples, etc): http://www.demigiant.com + +// NOTES ////////////////////////////////////////////////////// + +- DOTween's Utility Panel can be found under "Tools > Demigiant > DOTween Utility Panel" and also contains other useful options, plus a tab to set DOTween's preferences \ No newline at end of file diff --git a/Assets/Demigiant/DOTween/readme.txt.meta b/Assets/Demigiant/DOTween/readme.txt.meta new file mode 100644 index 0000000..9c3a968 --- /dev/null +++ b/Assets/Demigiant/DOTween/readme.txt.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: fccfc62abf2eb0a4db614853430894fd +TextScriptImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DOTweenPro Examples.meta b/Assets/Demigiant/DOTweenPro Examples.meta new file mode 100644 index 0000000..c153fba --- /dev/null +++ b/Assets/Demigiant/DOTweenPro Examples.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: b6bdab3c01557584180159a3469b6048 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DOTweenPro Examples/DOTweenAnimation_Advanced.unity b/Assets/Demigiant/DOTweenPro Examples/DOTweenAnimation_Advanced.unity new file mode 100644 index 0000000..09a4bfa --- /dev/null +++ b/Assets/Demigiant/DOTweenPro Examples/DOTweenAnimation_Advanced.unity @@ -0,0 +1,5243 @@ +%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.2, g: 0.2, b: 0.2, a: 1} + m_AmbientEquatorColor: {r: 0.2, g: 0.2, b: 0.2, a: 1} + m_AmbientGroundColor: {r: 0.2, g: 0.2, b: 0.2, 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 &4 +LightmapSettings: + m_ObjectHideFlags: 0 + serializedVersion: 12 + m_GIWorkflowMode: 1 + m_GISettings: + serializedVersion: 2 + m_BounceScale: 1 + m_IndirectOutputScale: 1 + m_AlbedoBoost: 1 + m_EnvironmentLightingMode: 0 + m_EnableBakedLightmaps: 1 + m_EnableRealtimeLightmaps: 0 + m_LightmapEditorSettings: + serializedVersion: 12 + m_Resolution: 1 + m_BakeResolution: 50 + m_AtlasSize: 1024 + m_AO: 1 + m_AOMaxDistance: 1 + m_CompAOExponent: 1 + m_CompAOExponentDirect: 0 + m_ExtractAmbientOcclusion: 0 + m_Padding: 2 + m_LightmapParameters: {fileID: 0} + m_LightmapsBakeMode: 1 + m_TextureCompression: 0 + m_FinalGather: 0 + m_FinalGatherFiltering: 1 + m_FinalGatherRayCount: 256 + m_ReflectionCompression: 2 + m_MixedBakeMode: 1 + m_BakeBackend: 0 + m_PVRSampling: 1 + m_PVRDirectSampleCount: 32 + m_PVRSampleCount: 512 + m_PVRBounces: 2 + m_PVREnvironmentSampleCount: 512 + m_PVREnvironmentReferencePointCount: 2048 + m_PVRFilteringMode: 0 + m_PVRDenoiserTypeDirect: 0 + m_PVRDenoiserTypeIndirect: 0 + m_PVRDenoiserTypeAO: 0 + m_PVRFilterTypeDirect: 0 + m_PVRFilterTypeIndirect: 0 + m_PVRFilterTypeAO: 0 + m_PVREnvironmentMIS: 0 + m_PVRCulling: 1 + m_PVRFilteringGaussRadiusDirect: 1 + m_PVRFilteringGaussRadiusIndirect: 5 + m_PVRFilteringGaussRadiusAO: 2 + m_PVRFilteringAtrousPositionSigmaDirect: 0.5 + m_PVRFilteringAtrousPositionSigmaIndirect: 2 + m_PVRFilteringAtrousPositionSigmaAO: 1 + m_ExportTrainingData: 0 + m_TrainingDataDestination: TrainingData + m_LightProbeSampleCountMultiplier: 4 + m_LightingDataAsset: {fileID: 0} + m_LightingSettings: {fileID: 4890085278179872738, guid: 6914d42df2cd2ab48897601759547b3b, type: 2} +--- !u!196 &5 +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.16666666 + manualTileSize: 0 + tileSize: 256 + accuratePlacement: 0 + maxJobWorkers: 0 + preserveTilesOutsideBounds: 0 + debug: + m_Flags: 0 + m_NavMeshData: {fileID: 0} +--- !u!1 &45542689 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 45542690} + - component: {fileID: 45542693} + - component: {fileID: 45542692} + - component: {fileID: 45542691} + m_Layer: 5 + m_Name: 'Button (ID: move)' + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!224 &45542690 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 45542689} + 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: + - {fileID: 191643491} + m_Father: {fileID: 1997177219} + m_RootOrder: 2 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0.5, y: 0.5} + m_AnchorMax: {x: 0.5, y: 0.5} + m_AnchoredPosition: {x: 0, y: -36} + m_SizeDelta: {x: 100, y: 30} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!114 &45542691 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 45542689} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 4e29b1a8efbd4b44bb3f3716e73f07ff, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Navigation: + m_Mode: 3 + m_WrapAround: 0 + m_SelectOnUp: {fileID: 0} + m_SelectOnDown: {fileID: 0} + m_SelectOnLeft: {fileID: 0} + m_SelectOnRight: {fileID: 0} + m_Transition: 1 + m_Colors: + m_NormalColor: {r: 1, g: 1, b: 1, a: 1} + m_HighlightedColor: {r: 0.9607843, g: 0.9607843, b: 0.9607843, a: 1} + m_PressedColor: {r: 0.78431374, g: 0.78431374, b: 0.78431374, a: 1} + m_SelectedColor: {r: 0.9607843, g: 0.9607843, b: 0.9607843, a: 1} + m_DisabledColor: {r: 0.78431374, g: 0.78431374, b: 0.78431374, a: 0.5019608} + m_ColorMultiplier: 1 + m_FadeDuration: 0.1 + m_SpriteState: + m_HighlightedSprite: {fileID: 0} + m_PressedSprite: {fileID: 0} + m_SelectedSprite: {fileID: 0} + m_DisabledSprite: {fileID: 0} + m_AnimationTriggers: + m_NormalTrigger: Normal + m_HighlightedTrigger: Highlighted + m_PressedTrigger: Pressed + m_SelectedTrigger: Highlighted + m_DisabledTrigger: Disabled + m_Interactable: 1 + m_TargetGraphic: {fileID: 45542692} + m_OnClick: + m_PersistentCalls: + m_Calls: + - m_Target: {fileID: 1844382610} + m_TargetAssemblyTypeName: + m_MethodName: DORestartById + m_Mode: 5 + m_Arguments: + m_ObjectArgument: {fileID: 0} + m_ObjectArgumentAssemblyTypeName: UnityEngine.Object, UnityEngine + m_IntArgument: 0 + m_FloatArgument: 0 + m_StringArgument: move + m_BoolArgument: 0 + m_CallState: 2 +--- !u!114 &45542692 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 45542689} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: fe87c0e1cc204ed48ad3b37840f39efc, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 1, g: 1, b: 1, a: 1} + m_RaycastTarget: 1 + m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0} + m_Maskable: 1 + m_OnCullStateChanged: + m_PersistentCalls: + m_Calls: [] + m_Sprite: {fileID: 10905, guid: 0000000000000000f000000000000000, type: 0} + m_Type: 1 + m_PreserveAspect: 0 + m_FillCenter: 1 + m_FillMethod: 4 + m_FillAmount: 1 + m_FillClockwise: 1 + m_FillOrigin: 0 + m_UseSpriteMesh: 0 + m_PixelsPerUnitMultiplier: 1 +--- !u!222 &45542693 +CanvasRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 45542689} + m_CullTransparentMesh: 1 +--- !u!1 &76224661 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 76224668} + - component: {fileID: 76224667} + - component: {fileID: 76224666} + - component: {fileID: 76224665} + - component: {fileID: 76224664} + - component: {fileID: 76224663} + m_Layer: 0 + m_Name: Cube C (w animation) + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!114 &76224663 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 76224661} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 4d0390bd8b8ffd640b34fe25065ff1df, type: 3} + m_Name: + m_EditorClassIdentifier: + updateType: 0 + isSpeedBased: 0 + hasOnStart: 0 + hasOnPlay: 0 + hasOnUpdate: 0 + hasOnStepComplete: 0 + hasOnComplete: 0 + hasOnTweenCreated: 0 + hasOnRewind: 0 + onStart: + m_PersistentCalls: + m_Calls: [] + onPlay: + m_PersistentCalls: + m_Calls: [] + onUpdate: + m_PersistentCalls: + m_Calls: [] + onStepComplete: + m_PersistentCalls: + m_Calls: [] + onComplete: + m_PersistentCalls: + m_Calls: [] + onTweenCreated: + m_PersistentCalls: + m_Calls: [] + onRewind: + m_PersistentCalls: + m_Calls: [] + targetIsSelf: 1 + targetGO: {fileID: 0} + tweenTargetIsTargetGO: 1 + delay: 0 + duration: 1 + easeType: 6 + easeCurve: + serializedVersion: 2 + m_Curve: + - serializedVersion: 3 + time: 0 + value: 0 + inSlope: 0 + outSlope: 0 + tangentMode: 0 + weightedMode: 0 + inWeight: 0.33333334 + outWeight: 0.33333334 + - serializedVersion: 3 + time: 1 + value: 1 + inSlope: 0 + outSlope: 0 + tangentMode: 0 + weightedMode: 0 + inWeight: 0.33333334 + outWeight: 0.33333334 + m_PreInfinity: 2 + m_PostInfinity: 2 + m_RotationOrder: 4 + loopType: 0 + loops: 1 + id: rotate + isRelative: 0 + isFrom: 0 + isIndependentUpdate: 0 + autoKill: 0 + isActive: 1 + isValid: 1 + target: {fileID: 76224668} + animationType: 3 + targetType: 0 + forcedTargetType: 0 + autoPlay: 0 + useTargetAsV3: 0 + endValueFloat: 0 + endValueV3: {x: 0, y: 180, z: 0} + endValueV2: {x: 0, y: 0} + endValueColor: {r: 1, g: 1, b: 1, a: 1} + endValueString: + endValueRect: + serializedVersion: 2 + x: 0 + y: 0 + width: 0 + height: 0 + endValueTransform: {fileID: 0} + optionalBool0: 0 + optionalFloat0: 0 + optionalInt0: 0 + optionalRotationMode: 0 + optionalScrambleMode: 0 + optionalString: +--- !u!114 &76224664 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 76224661} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 4d0390bd8b8ffd640b34fe25065ff1df, type: 3} + m_Name: + m_EditorClassIdentifier: + updateType: 0 + isSpeedBased: 0 + hasOnStart: 0 + hasOnPlay: 0 + hasOnUpdate: 0 + hasOnStepComplete: 0 + hasOnComplete: 0 + hasOnTweenCreated: 0 + hasOnRewind: 0 + onStart: + m_PersistentCalls: + m_Calls: [] + onPlay: + m_PersistentCalls: + m_Calls: [] + onUpdate: + m_PersistentCalls: + m_Calls: [] + onStepComplete: + m_PersistentCalls: + m_Calls: [] + onComplete: + m_PersistentCalls: + m_Calls: [] + onTweenCreated: + m_PersistentCalls: + m_Calls: [] + onRewind: + m_PersistentCalls: + m_Calls: [] + targetIsSelf: 1 + targetGO: {fileID: 0} + tweenTargetIsTargetGO: 1 + delay: 0 + duration: 1 + easeType: 6 + easeCurve: + serializedVersion: 2 + m_Curve: + - serializedVersion: 3 + time: 0 + value: 0 + inSlope: 0 + outSlope: 0 + tangentMode: 0 + weightedMode: 0 + inWeight: 0.33333334 + outWeight: 0.33333334 + - serializedVersion: 3 + time: 1 + value: 1 + inSlope: 0 + outSlope: 0 + tangentMode: 0 + weightedMode: 0 + inWeight: 0.33333334 + outWeight: 0.33333334 + m_PreInfinity: 2 + m_PostInfinity: 2 + m_RotationOrder: 4 + loopType: 0 + loops: 1 + id: move + isRelative: 1 + isFrom: 0 + isIndependentUpdate: 0 + autoKill: 0 + isActive: 1 + isValid: 1 + target: {fileID: 76224668} + animationType: 1 + targetType: 0 + forcedTargetType: 0 + autoPlay: 0 + useTargetAsV3: 0 + endValueFloat: 0 + endValueV3: {x: 0, y: 1, z: 0} + endValueV2: {x: 0, y: 0} + endValueColor: {r: 1, g: 1, b: 1, a: 1} + endValueString: + endValueRect: + serializedVersion: 2 + x: 0 + y: 0 + width: 0 + height: 0 + endValueTransform: {fileID: 0} + optionalBool0: 0 + optionalFloat0: 0 + optionalInt0: 0 + optionalRotationMode: 0 + optionalScrambleMode: 0 + optionalString: +--- !u!114 &76224665 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 76224661} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 4d0390bd8b8ffd640b34fe25065ff1df, type: 3} + m_Name: + m_EditorClassIdentifier: + updateType: 0 + isSpeedBased: 0 + hasOnStart: 0 + hasOnPlay: 0 + hasOnUpdate: 0 + hasOnStepComplete: 0 + hasOnComplete: 0 + hasOnTweenCreated: 0 + hasOnRewind: 0 + onStart: + m_PersistentCalls: + m_Calls: [] + onPlay: + m_PersistentCalls: + m_Calls: [] + onUpdate: + m_PersistentCalls: + m_Calls: [] + onStepComplete: + m_PersistentCalls: + m_Calls: [] + onComplete: + m_PersistentCalls: + m_Calls: [] + onTweenCreated: + m_PersistentCalls: + m_Calls: [] + onRewind: + m_PersistentCalls: + m_Calls: [] + targetIsSelf: 1 + targetGO: {fileID: 0} + tweenTargetIsTargetGO: 1 + delay: 0 + duration: 1 + easeType: 6 + easeCurve: + serializedVersion: 2 + m_Curve: + - serializedVersion: 3 + time: 0 + value: 0 + inSlope: 0 + outSlope: 0 + tangentMode: 0 + weightedMode: 0 + inWeight: 0.33333334 + outWeight: 0.33333334 + - serializedVersion: 3 + time: 1 + value: 1 + inSlope: 0 + outSlope: 0 + tangentMode: 0 + weightedMode: 0 + inWeight: 0.33333334 + outWeight: 0.33333334 + m_PreInfinity: 2 + m_PostInfinity: 2 + m_RotationOrder: 4 + loopType: 0 + loops: 1 + id: toRed + isRelative: 0 + isFrom: 0 + isIndependentUpdate: 0 + autoKill: 0 + isActive: 1 + isValid: 1 + target: {fileID: 76224666} + animationType: 6 + targetType: 0 + forcedTargetType: 0 + autoPlay: 0 + useTargetAsV3: 0 + endValueFloat: 0 + endValueV3: {x: 0, y: 0, z: 0} + endValueV2: {x: 0, y: 0} + endValueColor: {r: 1, g: 0, b: 0, a: 1} + endValueString: + endValueRect: + serializedVersion: 2 + x: 0 + y: 0 + width: 0 + height: 0 + endValueTransform: {fileID: 0} + optionalBool0: 0 + optionalFloat0: 0 + optionalInt0: 0 + optionalRotationMode: 0 + optionalScrambleMode: 0 + optionalString: +--- !u!23 &76224666 +MeshRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 76224661} + m_Enabled: 1 + m_CastShadows: 1 + m_ReceiveShadows: 1 + m_DynamicOccludee: 1 + m_MotionVectors: 1 + m_LightProbeUsage: 0 + m_ReflectionProbeUsage: 1 + m_RayTracingMode: 2 + m_RayTraceProcedural: 0 + m_RenderingLayerMask: 1 + m_RendererPriority: 0 + m_Materials: + - {fileID: 10302, 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_ReceiveGI: 1 + m_PreserveUVs: 0 + m_IgnoreNormalsForChartDetection: 0 + m_ImportantGI: 0 + m_StitchLightmapSeams: 1 + m_SelectedEditorRenderState: 3 + m_MinimumChartSize: 4 + m_AutoUVMaxDistance: 0.5 + m_AutoUVMaxAngle: 89 + m_LightmapParameters: {fileID: 0} + m_SortingLayerID: 0 + m_SortingLayer: 0 + m_SortingOrder: 0 + m_AdditionalVertexStreams: {fileID: 0} +--- !u!33 &76224667 +MeshFilter: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 76224661} + m_Mesh: {fileID: 10202, guid: 0000000000000000e000000000000000, type: 0} +--- !u!4 &76224668 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 76224661} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: 2, y: 3, z: 0} + m_LocalScale: {x: 1, y: 1, z: 1} + m_Children: + - {fileID: 1760580329} + m_Father: {fileID: 0} + m_RootOrder: 4 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!1 &83016929 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 83016930} + - component: {fileID: 83016932} + - component: {fileID: 83016931} + m_Layer: 5 + m_Name: Text + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!224 &83016930 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 83016929} + 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: 1839080358} + m_RootOrder: 0 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0, y: 0} + m_AnchorMax: {x: 1, y: 1} + m_AnchoredPosition: {x: 0, y: 0} + m_SizeDelta: {x: 0, y: 0} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!114 &83016931 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 83016929} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 5f7201a12d95ffc409449d95f23cf332, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 0.196, g: 0.196, b: 0.196, a: 1} + m_RaycastTarget: 1 + m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0} + m_Maskable: 1 + m_OnCullStateChanged: + m_PersistentCalls: + m_Calls: [] + m_FontData: + m_Font: {fileID: 10102, guid: 0000000000000000e000000000000000, type: 0} + m_FontSize: 14 + m_FontStyle: 0 + m_BestFit: 0 + m_MinSize: 10 + m_MaxSize: 40 + m_Alignment: 4 + m_AlignByGeometry: 0 + m_RichText: 1 + m_HorizontalOverflow: 0 + m_VerticalOverflow: 0 + m_LineSpacing: 1 + m_Text: 'ID: toRed' +--- !u!222 &83016932 +CanvasRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 83016929} + m_CullTransparentMesh: 1 +--- !u!1 &118309267 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 118309271} + - component: {fileID: 118309270} + - component: {fileID: 118309268} + - component: {fileID: 118309274} + - component: {fileID: 118309272} + - component: {fileID: 118309269} + m_Layer: 0 + m_Name: Cube A (w animation) + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!23 &118309268 +MeshRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 118309267} + m_Enabled: 1 + m_CastShadows: 1 + m_ReceiveShadows: 1 + m_DynamicOccludee: 1 + m_MotionVectors: 1 + m_LightProbeUsage: 0 + m_ReflectionProbeUsage: 1 + m_RayTracingMode: 2 + m_RayTraceProcedural: 0 + m_RenderingLayerMask: 1 + m_RendererPriority: 0 + m_Materials: + - {fileID: 10302, 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_ReceiveGI: 1 + m_PreserveUVs: 0 + m_IgnoreNormalsForChartDetection: 0 + m_ImportantGI: 0 + m_StitchLightmapSeams: 1 + m_SelectedEditorRenderState: 3 + m_MinimumChartSize: 4 + m_AutoUVMaxDistance: 0.5 + m_AutoUVMaxAngle: 89 + m_LightmapParameters: {fileID: 0} + m_SortingLayerID: 0 + m_SortingLayer: 0 + m_SortingOrder: 0 + m_AdditionalVertexStreams: {fileID: 0} +--- !u!114 &118309269 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 118309267} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 4d0390bd8b8ffd640b34fe25065ff1df, type: 3} + m_Name: + m_EditorClassIdentifier: + updateType: 0 + isSpeedBased: 0 + hasOnStart: 0 + hasOnPlay: 0 + hasOnUpdate: 0 + hasOnStepComplete: 0 + hasOnComplete: 0 + hasOnTweenCreated: 0 + hasOnRewind: 0 + onStart: + m_PersistentCalls: + m_Calls: [] + onPlay: + m_PersistentCalls: + m_Calls: [] + onUpdate: + m_PersistentCalls: + m_Calls: [] + onStepComplete: + m_PersistentCalls: + m_Calls: [] + onComplete: + m_PersistentCalls: + m_Calls: [] + onTweenCreated: + m_PersistentCalls: + m_Calls: [] + onRewind: + m_PersistentCalls: + m_Calls: [] + targetIsSelf: 1 + targetGO: {fileID: 0} + tweenTargetIsTargetGO: 1 + delay: 0 + duration: 1 + easeType: 6 + easeCurve: + serializedVersion: 2 + m_Curve: + - serializedVersion: 3 + time: 0 + value: 0 + inSlope: 0 + outSlope: 0 + tangentMode: 0 + weightedMode: 0 + inWeight: 0.33333334 + outWeight: 0.33333334 + - serializedVersion: 3 + time: 1 + value: 1 + inSlope: 0 + outSlope: 0 + tangentMode: 0 + weightedMode: 0 + inWeight: 0.33333334 + outWeight: 0.33333334 + m_PreInfinity: 2 + m_PostInfinity: 2 + m_RotationOrder: 4 + loopType: 0 + loops: 1 + id: rotate + isRelative: 0 + isFrom: 0 + isIndependentUpdate: 0 + autoKill: 0 + isActive: 1 + isValid: 1 + target: {fileID: 118309271} + animationType: 3 + targetType: 0 + forcedTargetType: 0 + autoPlay: 0 + useTargetAsV3: 0 + endValueFloat: 0 + endValueV3: {x: 0, y: 180, z: 0} + endValueV2: {x: 0, y: 0} + endValueColor: {r: 1, g: 1, b: 1, a: 1} + endValueString: + endValueRect: + serializedVersion: 2 + x: 0 + y: 0 + width: 0 + height: 0 + endValueTransform: {fileID: 0} + optionalBool0: 0 + optionalFloat0: 0 + optionalInt0: 0 + optionalRotationMode: 0 + optionalScrambleMode: 0 + optionalString: +--- !u!33 &118309270 +MeshFilter: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 118309267} + m_Mesh: {fileID: 10202, guid: 0000000000000000e000000000000000, type: 0} +--- !u!4 &118309271 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 118309267} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: -2, y: 3, z: 0} + m_LocalScale: {x: 1, y: 1, z: 1} + m_Children: + - {fileID: 1192540964} + m_Father: {fileID: 0} + m_RootOrder: 2 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!114 &118309272 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 118309267} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 4d0390bd8b8ffd640b34fe25065ff1df, type: 3} + m_Name: + m_EditorClassIdentifier: + updateType: 0 + isSpeedBased: 0 + hasOnStart: 0 + hasOnPlay: 0 + hasOnUpdate: 0 + hasOnStepComplete: 0 + hasOnComplete: 0 + hasOnTweenCreated: 0 + hasOnRewind: 0 + onStart: + m_PersistentCalls: + m_Calls: [] + onPlay: + m_PersistentCalls: + m_Calls: [] + onUpdate: + m_PersistentCalls: + m_Calls: [] + onStepComplete: + m_PersistentCalls: + m_Calls: [] + onComplete: + m_PersistentCalls: + m_Calls: [] + onTweenCreated: + m_PersistentCalls: + m_Calls: [] + onRewind: + m_PersistentCalls: + m_Calls: [] + targetIsSelf: 1 + targetGO: {fileID: 0} + tweenTargetIsTargetGO: 1 + delay: 0 + duration: 1 + easeType: 6 + easeCurve: + serializedVersion: 2 + m_Curve: + - serializedVersion: 3 + time: 0 + value: 0 + inSlope: 0 + outSlope: 0 + tangentMode: 0 + weightedMode: 0 + inWeight: 0.33333334 + outWeight: 0.33333334 + - serializedVersion: 3 + time: 1 + value: 1 + inSlope: 0 + outSlope: 0 + tangentMode: 0 + weightedMode: 0 + inWeight: 0.33333334 + outWeight: 0.33333334 + m_PreInfinity: 2 + m_PostInfinity: 2 + m_RotationOrder: 4 + loopType: 0 + loops: 1 + id: move + isRelative: 1 + isFrom: 0 + isIndependentUpdate: 0 + autoKill: 0 + isActive: 1 + isValid: 1 + target: {fileID: 118309271} + animationType: 1 + targetType: 0 + forcedTargetType: 0 + autoPlay: 0 + useTargetAsV3: 0 + endValueFloat: 0 + endValueV3: {x: 0, y: 1, z: 0} + endValueV2: {x: 0, y: 0} + endValueColor: {r: 1, g: 1, b: 1, a: 1} + endValueString: + endValueRect: + serializedVersion: 2 + x: 0 + y: 0 + width: 0 + height: 0 + endValueTransform: {fileID: 0} + optionalBool0: 0 + optionalFloat0: 0 + optionalInt0: 0 + optionalRotationMode: 0 + optionalScrambleMode: 0 + optionalString: +--- !u!114 &118309274 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 118309267} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 4d0390bd8b8ffd640b34fe25065ff1df, type: 3} + m_Name: + m_EditorClassIdentifier: + updateType: 0 + isSpeedBased: 0 + hasOnStart: 0 + hasOnPlay: 0 + hasOnUpdate: 0 + hasOnStepComplete: 0 + hasOnComplete: 0 + hasOnTweenCreated: 0 + hasOnRewind: 0 + onStart: + m_PersistentCalls: + m_Calls: [] + onPlay: + m_PersistentCalls: + m_Calls: [] + onUpdate: + m_PersistentCalls: + m_Calls: [] + onStepComplete: + m_PersistentCalls: + m_Calls: [] + onComplete: + m_PersistentCalls: + m_Calls: [] + onTweenCreated: + m_PersistentCalls: + m_Calls: [] + onRewind: + m_PersistentCalls: + m_Calls: [] + targetIsSelf: 1 + targetGO: {fileID: 0} + tweenTargetIsTargetGO: 1 + delay: 0 + duration: 1 + easeType: 6 + easeCurve: + serializedVersion: 2 + m_Curve: + - serializedVersion: 3 + time: 0 + value: 0 + inSlope: 0 + outSlope: 0 + tangentMode: 0 + weightedMode: 0 + inWeight: 0.33333334 + outWeight: 0.33333334 + - serializedVersion: 3 + time: 1 + value: 1 + inSlope: 0 + outSlope: 0 + tangentMode: 0 + weightedMode: 0 + inWeight: 0.33333334 + outWeight: 0.33333334 + m_PreInfinity: 2 + m_PostInfinity: 2 + m_RotationOrder: 4 + loopType: 0 + loops: 1 + id: toRed + isRelative: 0 + isFrom: 0 + isIndependentUpdate: 0 + autoKill: 0 + isActive: 1 + isValid: 1 + target: {fileID: 118309268} + animationType: 6 + targetType: 0 + forcedTargetType: 0 + autoPlay: 0 + useTargetAsV3: 0 + endValueFloat: 0 + endValueV3: {x: 0, y: 0, z: 0} + endValueV2: {x: 0, y: 0} + endValueColor: {r: 1, g: 0, b: 0, a: 1} + endValueString: + endValueRect: + serializedVersion: 2 + x: 0 + y: 0 + width: 0 + height: 0 + endValueTransform: {fileID: 0} + optionalBool0: 0 + optionalFloat0: 0 + optionalInt0: 0 + optionalRotationMode: 0 + optionalScrambleMode: 0 + optionalString: +--- !u!1 &186391000 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 186391001} + m_Layer: 5 + m_Name: Buttons - PlayAllById + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!224 &186391001 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 186391000} + 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: + - {fileID: 467194356} + - {fileID: 1492174307} + - {fileID: 323853745} + - {fileID: 1644045641} + m_Father: {fileID: 1260203941} + m_RootOrder: 2 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0, y: 0} + m_AnchorMax: {x: 1, y: 1} + m_AnchoredPosition: {x: 0, y: -34} + m_SizeDelta: {x: 0, y: -48.000015} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!1 &191643490 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 191643491} + - component: {fileID: 191643493} + - component: {fileID: 191643492} + m_Layer: 5 + m_Name: Text + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!224 &191643491 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 191643490} + 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: 45542690} + m_RootOrder: 0 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0, y: 0} + m_AnchorMax: {x: 1, y: 1} + m_AnchoredPosition: {x: 0, y: 0} + m_SizeDelta: {x: 0, y: 0} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!114 &191643492 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 191643490} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 5f7201a12d95ffc409449d95f23cf332, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 0.196, g: 0.196, b: 0.196, a: 1} + m_RaycastTarget: 1 + m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0} + m_Maskable: 1 + m_OnCullStateChanged: + m_PersistentCalls: + m_Calls: [] + m_FontData: + m_Font: {fileID: 10102, guid: 0000000000000000e000000000000000, type: 0} + m_FontSize: 14 + m_FontStyle: 0 + m_BestFit: 0 + m_MinSize: 10 + m_MaxSize: 40 + m_Alignment: 4 + m_AlignByGeometry: 0 + m_RichText: 1 + m_HorizontalOverflow: 0 + m_VerticalOverflow: 0 + m_LineSpacing: 1 + m_Text: 'ID: move' +--- !u!222 &191643493 +CanvasRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 191643490} + m_CullTransparentMesh: 1 +--- !u!1 &215583160 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 215583161} + - component: {fileID: 215583163} + - component: {fileID: 215583162} + m_Layer: 5 + m_Name: Text + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!224 &215583161 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 215583160} + 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: 1619597526} + m_RootOrder: 0 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0, y: 0} + m_AnchorMax: {x: 1, y: 1} + m_AnchoredPosition: {x: 0, y: 0} + m_SizeDelta: {x: 0, y: 0} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!114 &215583162 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 215583160} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 5f7201a12d95ffc409449d95f23cf332, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 0.196, g: 0.196, b: 0.196, a: 1} + m_RaycastTarget: 1 + m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0} + m_Maskable: 1 + m_OnCullStateChanged: + m_PersistentCalls: + m_Calls: [] + m_FontData: + m_Font: {fileID: 10102, guid: 0000000000000000e000000000000000, type: 0} + m_FontSize: 14 + m_FontStyle: 0 + m_BestFit: 0 + m_MinSize: 10 + m_MaxSize: 40 + m_Alignment: 4 + m_AlignByGeometry: 0 + m_RichText: 1 + m_HorizontalOverflow: 0 + m_VerticalOverflow: 0 + m_LineSpacing: 1 + m_Text: 'ID: move' +--- !u!222 &215583163 +CanvasRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 215583160} + m_CullTransparentMesh: 1 +--- !u!1 &286188793 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 286188794} + m_Layer: 5 + m_Name: Buttons - PlayById + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!224 &286188794 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 286188793} + 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: + - {fileID: 1158456312} + - {fileID: 1839080358} + - {fileID: 1095596651} + - {fileID: 566135255} + m_Father: {fileID: 1260203941} + m_RootOrder: 1 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0, y: 0} + m_AnchorMax: {x: 1, y: 1} + m_AnchoredPosition: {x: 0, y: 42} + m_SizeDelta: {x: 0, y: 0} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!1 &323853744 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 323853745} + - component: {fileID: 323853748} + - component: {fileID: 323853747} + - component: {fileID: 323853746} + m_Layer: 5 + m_Name: 'Button (ID: move)' + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!224 &323853745 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 323853744} + 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: + - {fileID: 645240663} + m_Father: {fileID: 186391001} + m_RootOrder: 2 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0.5, y: 0.5} + m_AnchorMax: {x: 0.5, y: 0.5} + m_AnchoredPosition: {x: 0, y: -36} + m_SizeDelta: {x: 100, y: 30} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!114 &323853746 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 323853744} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 4e29b1a8efbd4b44bb3f3716e73f07ff, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Navigation: + m_Mode: 3 + m_WrapAround: 0 + m_SelectOnUp: {fileID: 0} + m_SelectOnDown: {fileID: 0} + m_SelectOnLeft: {fileID: 0} + m_SelectOnRight: {fileID: 0} + m_Transition: 1 + m_Colors: + m_NormalColor: {r: 1, g: 1, b: 1, a: 1} + m_HighlightedColor: {r: 0.9607843, g: 0.9607843, b: 0.9607843, a: 1} + m_PressedColor: {r: 0.78431374, g: 0.78431374, b: 0.78431374, a: 1} + m_SelectedColor: {r: 0.9607843, g: 0.9607843, b: 0.9607843, a: 1} + m_DisabledColor: {r: 0.78431374, g: 0.78431374, b: 0.78431374, a: 0.5019608} + m_ColorMultiplier: 1 + m_FadeDuration: 0.1 + m_SpriteState: + m_HighlightedSprite: {fileID: 0} + m_PressedSprite: {fileID: 0} + m_SelectedSprite: {fileID: 0} + m_DisabledSprite: {fileID: 0} + m_AnimationTriggers: + m_NormalTrigger: Normal + m_HighlightedTrigger: Highlighted + m_PressedTrigger: Pressed + m_SelectedTrigger: Highlighted + m_DisabledTrigger: Disabled + m_Interactable: 1 + m_TargetGraphic: {fileID: 323853747} + m_OnClick: + m_PersistentCalls: + m_Calls: + - m_Target: {fileID: 1844382610} + m_TargetAssemblyTypeName: + m_MethodName: DOPlayAllById + m_Mode: 5 + m_Arguments: + m_ObjectArgument: {fileID: 0} + m_ObjectArgumentAssemblyTypeName: UnityEngine.Object, UnityEngine + m_IntArgument: 0 + m_FloatArgument: 0 + m_StringArgument: move + m_BoolArgument: 0 + m_CallState: 2 +--- !u!114 &323853747 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 323853744} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: fe87c0e1cc204ed48ad3b37840f39efc, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 1, g: 1, b: 1, a: 1} + m_RaycastTarget: 1 + m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0} + m_Maskable: 1 + m_OnCullStateChanged: + m_PersistentCalls: + m_Calls: [] + m_Sprite: {fileID: 10905, guid: 0000000000000000f000000000000000, type: 0} + m_Type: 1 + m_PreserveAspect: 0 + m_FillCenter: 1 + m_FillMethod: 4 + m_FillAmount: 1 + m_FillClockwise: 1 + m_FillOrigin: 0 + m_UseSpriteMesh: 0 + m_PixelsPerUnitMultiplier: 1 +--- !u!222 &323853748 +CanvasRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 323853744} + m_CullTransparentMesh: 1 +--- !u!1 &386943563 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 386943564} + - component: {fileID: 386943566} + - component: {fileID: 386943565} + m_Layer: 5 + m_Name: Text + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!224 &386943564 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 386943563} + 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: 766204080} + m_RootOrder: 0 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0, y: 0} + m_AnchorMax: {x: 1, y: 1} + m_AnchoredPosition: {x: 0, y: 0} + m_SizeDelta: {x: 0, y: 0} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!114 &386943565 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 386943563} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 5f7201a12d95ffc409449d95f23cf332, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 0.196, g: 0.196, b: 0.196, a: 1} + m_RaycastTarget: 1 + m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0} + m_Maskable: 1 + m_OnCullStateChanged: + m_PersistentCalls: + m_Calls: [] + m_FontData: + m_Font: {fileID: 10102, guid: 0000000000000000e000000000000000, type: 0} + m_FontSize: 14 + m_FontStyle: 0 + m_BestFit: 0 + m_MinSize: 10 + m_MaxSize: 40 + m_Alignment: 4 + m_AlignByGeometry: 0 + m_RichText: 1 + m_HorizontalOverflow: 0 + m_VerticalOverflow: 0 + m_LineSpacing: 1 + m_Text: 'ID: toRed' +--- !u!222 &386943566 +CanvasRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 386943563} + m_CullTransparentMesh: 1 +--- !u!1 &461995929 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 461995932} + - component: {fileID: 461995931} + - component: {fileID: 461995930} + m_Layer: 0 + m_Name: Name + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!102 &461995930 +TextMesh: + serializedVersion: 3 + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 461995929} + m_Text: B + m_OffsetZ: 0 + m_CharacterSize: 20 + m_LineSpacing: 1 + m_Anchor: 4 + m_Alignment: 1 + m_TabSize: 4 + m_FontSize: 30 + m_FontStyle: 1 + m_RichText: 1 + m_Font: {fileID: 10102, guid: 0000000000000000e000000000000000, type: 0} + m_Color: + serializedVersion: 2 + rgba: 4294967295 +--- !u!23 &461995931 +MeshRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 461995929} + m_Enabled: 1 + m_CastShadows: 0 + m_ReceiveShadows: 0 + m_DynamicOccludee: 1 + m_MotionVectors: 1 + m_LightProbeUsage: 0 + m_ReflectionProbeUsage: 1 + m_RayTracingMode: 2 + m_RayTraceProcedural: 0 + m_RenderingLayerMask: 1 + m_RendererPriority: 0 + m_Materials: + - {fileID: 10100, guid: 0000000000000000e000000000000000, type: 0} + m_StaticBatchInfo: + firstSubMesh: 0 + subMeshCount: 0 + m_StaticBatchRoot: {fileID: 0} + m_ProbeAnchor: {fileID: 0} + m_LightProbeVolumeOverride: {fileID: 0} + m_ScaleInLightmap: 1 + m_ReceiveGI: 1 + m_PreserveUVs: 0 + m_IgnoreNormalsForChartDetection: 0 + m_ImportantGI: 0 + m_StitchLightmapSeams: 1 + m_SelectedEditorRenderState: 3 + m_MinimumChartSize: 4 + m_AutoUVMaxDistance: 0.5 + m_AutoUVMaxAngle: 89 + m_LightmapParameters: {fileID: 0} + m_SortingLayerID: 0 + m_SortingLayer: 0 + m_SortingOrder: 0 + m_AdditionalVertexStreams: {fileID: 0} +--- !u!4 &461995932 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 461995929} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: 0, y: 0, z: 0} + m_LocalScale: {x: 0.01, y: 0.01, z: 0.01} + m_Children: [] + m_Father: {fileID: 1844382606} + m_RootOrder: 0 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!1 &467194355 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 467194356} + - component: {fileID: 467194358} + - component: {fileID: 467194357} + m_Layer: 5 + m_Name: Description + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!224 &467194356 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 467194355} + 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: 186391001} + m_RootOrder: 0 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0.5, y: 0.5} + m_AnchorMax: {x: 0.5, y: 0.5} + m_AnchoredPosition: {x: 0, y: 0} + m_SizeDelta: {x: 550, y: 30} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!114 &467194357 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 467194355} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 5f7201a12d95ffc409449d95f23cf332, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 1, g: 1, b: 1, a: 1} + m_RaycastTarget: 1 + m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0} + m_Maskable: 1 + m_OnCullStateChanged: + m_PersistentCalls: + m_Calls: [] + m_FontData: + m_Font: {fileID: 10102, guid: 0000000000000000e000000000000000, type: 0} + m_FontSize: 14 + m_FontStyle: 0 + m_BestFit: 0 + m_MinSize: 10 + m_MaxSize: 40 + m_Alignment: 1 + m_AlignByGeometry: 0 + m_RichText: 1 + m_HorizontalOverflow: 0 + m_VerticalOverflow: 1 + m_LineSpacing: 1 + m_Text: 'DOPlayAllById (Cube B as target) + + Will play the DOTweenAnimations + with the given ID, on ANY gameObject' +--- !u!222 &467194358 +CanvasRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 467194355} + m_CullTransparentMesh: 1 +--- !u!1 &502741617 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 502741618} + - component: {fileID: 502741621} + - component: {fileID: 502741620} + - component: {fileID: 502741619} + m_Layer: 5 + m_Name: 'Button (ID: rotate)' + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!224 &502741618 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 502741617} + 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: + - {fileID: 685170976} + m_Father: {fileID: 1997177219} + m_RootOrder: 3 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0.5, y: 0.5} + m_AnchorMax: {x: 0.5, y: 0.5} + m_AnchoredPosition: {x: 100, y: -36} + m_SizeDelta: {x: 100, y: 30} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!114 &502741619 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 502741617} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 4e29b1a8efbd4b44bb3f3716e73f07ff, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Navigation: + m_Mode: 3 + m_WrapAround: 0 + m_SelectOnUp: {fileID: 0} + m_SelectOnDown: {fileID: 0} + m_SelectOnLeft: {fileID: 0} + m_SelectOnRight: {fileID: 0} + m_Transition: 1 + m_Colors: + m_NormalColor: {r: 1, g: 1, b: 1, a: 1} + m_HighlightedColor: {r: 0.9607843, g: 0.9607843, b: 0.9607843, a: 1} + m_PressedColor: {r: 0.78431374, g: 0.78431374, b: 0.78431374, a: 1} + m_SelectedColor: {r: 0.9607843, g: 0.9607843, b: 0.9607843, a: 1} + m_DisabledColor: {r: 0.78431374, g: 0.78431374, b: 0.78431374, a: 0.5019608} + m_ColorMultiplier: 1 + m_FadeDuration: 0.1 + m_SpriteState: + m_HighlightedSprite: {fileID: 0} + m_PressedSprite: {fileID: 0} + m_SelectedSprite: {fileID: 0} + m_DisabledSprite: {fileID: 0} + m_AnimationTriggers: + m_NormalTrigger: Normal + m_HighlightedTrigger: Highlighted + m_PressedTrigger: Pressed + m_SelectedTrigger: Highlighted + m_DisabledTrigger: Disabled + m_Interactable: 1 + m_TargetGraphic: {fileID: 502741620} + m_OnClick: + m_PersistentCalls: + m_Calls: + - m_Target: {fileID: 1844382610} + m_TargetAssemblyTypeName: + m_MethodName: DORestartById + m_Mode: 5 + m_Arguments: + m_ObjectArgument: {fileID: 0} + m_ObjectArgumentAssemblyTypeName: UnityEngine.Object, UnityEngine + m_IntArgument: 0 + m_FloatArgument: 0 + m_StringArgument: rotate + m_BoolArgument: 0 + m_CallState: 2 +--- !u!114 &502741620 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 502741617} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: fe87c0e1cc204ed48ad3b37840f39efc, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 1, g: 1, b: 1, a: 1} + m_RaycastTarget: 1 + m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0} + m_Maskable: 1 + m_OnCullStateChanged: + m_PersistentCalls: + m_Calls: [] + m_Sprite: {fileID: 10905, guid: 0000000000000000f000000000000000, type: 0} + m_Type: 1 + m_PreserveAspect: 0 + m_FillCenter: 1 + m_FillMethod: 4 + m_FillAmount: 1 + m_FillClockwise: 1 + m_FillOrigin: 0 + m_UseSpriteMesh: 0 + m_PixelsPerUnitMultiplier: 1 +--- !u!222 &502741621 +CanvasRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 502741617} + m_CullTransparentMesh: 1 +--- !u!1 &566135254 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 566135255} + - component: {fileID: 566135258} + - component: {fileID: 566135257} + - component: {fileID: 566135256} + m_Layer: 5 + m_Name: 'Button (ID: rotate)' + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!224 &566135255 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 566135254} + 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: + - {fileID: 740664255} + m_Father: {fileID: 286188794} + m_RootOrder: 3 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0.5, y: 0.5} + m_AnchorMax: {x: 0.5, y: 0.5} + m_AnchoredPosition: {x: 100, y: -36} + m_SizeDelta: {x: 100, y: 30} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!114 &566135256 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 566135254} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 4e29b1a8efbd4b44bb3f3716e73f07ff, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Navigation: + m_Mode: 3 + m_WrapAround: 0 + m_SelectOnUp: {fileID: 0} + m_SelectOnDown: {fileID: 0} + m_SelectOnLeft: {fileID: 0} + m_SelectOnRight: {fileID: 0} + m_Transition: 1 + m_Colors: + m_NormalColor: {r: 1, g: 1, b: 1, a: 1} + m_HighlightedColor: {r: 0.9607843, g: 0.9607843, b: 0.9607843, a: 1} + m_PressedColor: {r: 0.78431374, g: 0.78431374, b: 0.78431374, a: 1} + m_SelectedColor: {r: 0.9607843, g: 0.9607843, b: 0.9607843, a: 1} + m_DisabledColor: {r: 0.78431374, g: 0.78431374, b: 0.78431374, a: 0.5019608} + m_ColorMultiplier: 1 + m_FadeDuration: 0.1 + m_SpriteState: + m_HighlightedSprite: {fileID: 0} + m_PressedSprite: {fileID: 0} + m_SelectedSprite: {fileID: 0} + m_DisabledSprite: {fileID: 0} + m_AnimationTriggers: + m_NormalTrigger: Normal + m_HighlightedTrigger: Highlighted + m_PressedTrigger: Pressed + m_SelectedTrigger: Highlighted + m_DisabledTrigger: Disabled + m_Interactable: 1 + m_TargetGraphic: {fileID: 566135257} + m_OnClick: + m_PersistentCalls: + m_Calls: + - m_Target: {fileID: 1844382610} + m_TargetAssemblyTypeName: + m_MethodName: DOPlayById + m_Mode: 5 + m_Arguments: + m_ObjectArgument: {fileID: 0} + m_ObjectArgumentAssemblyTypeName: UnityEngine.Object, UnityEngine + m_IntArgument: 0 + m_FloatArgument: 0 + m_StringArgument: rotate + m_BoolArgument: 0 + m_CallState: 2 +--- !u!114 &566135257 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 566135254} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: fe87c0e1cc204ed48ad3b37840f39efc, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 1, g: 1, b: 1, a: 1} + m_RaycastTarget: 1 + m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0} + m_Maskable: 1 + m_OnCullStateChanged: + m_PersistentCalls: + m_Calls: [] + m_Sprite: {fileID: 10905, guid: 0000000000000000f000000000000000, type: 0} + m_Type: 1 + m_PreserveAspect: 0 + m_FillCenter: 1 + m_FillMethod: 4 + m_FillAmount: 1 + m_FillClockwise: 1 + m_FillOrigin: 0 + m_UseSpriteMesh: 0 + m_PixelsPerUnitMultiplier: 1 +--- !u!222 &566135258 +CanvasRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 566135254} + m_CullTransparentMesh: 1 +--- !u!1 &608072282 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 608072283} + - component: {fileID: 608072285} + - component: {fileID: 608072284} + m_Layer: 5 + m_Name: Description + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!224 &608072283 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 608072282} + 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: 1785989881} + m_RootOrder: 0 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0.5, y: 0.5} + m_AnchorMax: {x: 0.5, y: 0.5} + m_AnchoredPosition: {x: 0, y: 0} + m_SizeDelta: {x: 550, y: 30} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!114 &608072284 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 608072282} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 5f7201a12d95ffc409449d95f23cf332, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 1, g: 1, b: 1, a: 1} + m_RaycastTarget: 1 + m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0} + m_Maskable: 1 + m_OnCullStateChanged: + m_PersistentCalls: + m_Calls: [] + m_FontData: + m_Font: {fileID: 10102, guid: 0000000000000000e000000000000000, type: 0} + m_FontSize: 14 + m_FontStyle: 0 + m_BestFit: 0 + m_MinSize: 10 + m_MaxSize: 40 + m_Alignment: 1 + m_AlignByGeometry: 0 + m_RichText: 1 + m_HorizontalOverflow: 0 + m_VerticalOverflow: 1 + m_LineSpacing: 1 + m_Text: 'DORestartAllById (Cube B as target) + + Will restart the DOTweenAnimations + with the given ID, on ANY gameObject' +--- !u!222 &608072285 +CanvasRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 608072282} + m_CullTransparentMesh: 1 +--- !u!1 &645240662 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 645240663} + - component: {fileID: 645240665} + - component: {fileID: 645240664} + m_Layer: 5 + m_Name: Text + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!224 &645240663 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 645240662} + 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: 323853745} + m_RootOrder: 0 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0, y: 0} + m_AnchorMax: {x: 1, y: 1} + m_AnchoredPosition: {x: 0, y: 0} + m_SizeDelta: {x: 0, y: 0} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!114 &645240664 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 645240662} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 5f7201a12d95ffc409449d95f23cf332, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 0.196, g: 0.196, b: 0.196, a: 1} + m_RaycastTarget: 1 + m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0} + m_Maskable: 1 + m_OnCullStateChanged: + m_PersistentCalls: + m_Calls: [] + m_FontData: + m_Font: {fileID: 10102, guid: 0000000000000000e000000000000000, type: 0} + m_FontSize: 14 + m_FontStyle: 0 + m_BestFit: 0 + m_MinSize: 10 + m_MaxSize: 40 + m_Alignment: 4 + m_AlignByGeometry: 0 + m_RichText: 1 + m_HorizontalOverflow: 0 + m_VerticalOverflow: 0 + m_LineSpacing: 1 + m_Text: 'ID: move' +--- !u!222 &645240665 +CanvasRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 645240662} + m_CullTransparentMesh: 1 +--- !u!1 &685170975 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 685170976} + - component: {fileID: 685170978} + - component: {fileID: 685170977} + m_Layer: 5 + m_Name: Text + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!224 &685170976 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 685170975} + 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: 502741618} + m_RootOrder: 0 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0, y: 0} + m_AnchorMax: {x: 1, y: 1} + m_AnchoredPosition: {x: 0, y: 0} + m_SizeDelta: {x: 0, y: 0} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!114 &685170977 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 685170975} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 5f7201a12d95ffc409449d95f23cf332, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 0.196, g: 0.196, b: 0.196, a: 1} + m_RaycastTarget: 1 + m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0} + m_Maskable: 1 + m_OnCullStateChanged: + m_PersistentCalls: + m_Calls: [] + m_FontData: + m_Font: {fileID: 10102, guid: 0000000000000000e000000000000000, type: 0} + m_FontSize: 14 + m_FontStyle: 0 + m_BestFit: 0 + m_MinSize: 10 + m_MaxSize: 40 + m_Alignment: 4 + m_AlignByGeometry: 0 + m_RichText: 1 + m_HorizontalOverflow: 0 + m_VerticalOverflow: 0 + m_LineSpacing: 1 + m_Text: 'ID: rotate' +--- !u!222 &685170978 +CanvasRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 685170975} + m_CullTransparentMesh: 1 +--- !u!1 &718047501 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 718047502} + - component: {fileID: 718047504} + - component: {fileID: 718047503} + m_Layer: 5 + m_Name: Text + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!224 &718047502 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 718047501} + 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: 1371900811} + m_RootOrder: 0 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0, y: 0} + m_AnchorMax: {x: 1, y: 1} + m_AnchoredPosition: {x: 0, y: 0} + m_SizeDelta: {x: 0, y: 0} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!114 &718047503 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 718047501} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 5f7201a12d95ffc409449d95f23cf332, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 0.196, g: 0.196, b: 0.196, a: 1} + m_RaycastTarget: 1 + m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0} + m_Maskable: 1 + m_OnCullStateChanged: + m_PersistentCalls: + m_Calls: [] + m_FontData: + m_Font: {fileID: 10102, guid: 0000000000000000e000000000000000, type: 0} + m_FontSize: 14 + m_FontStyle: 0 + m_BestFit: 0 + m_MinSize: 10 + m_MaxSize: 40 + m_Alignment: 4 + m_AlignByGeometry: 0 + m_RichText: 1 + m_HorizontalOverflow: 0 + m_VerticalOverflow: 0 + m_LineSpacing: 1 + m_Text: 'ID: rotate' +--- !u!222 &718047504 +CanvasRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 718047501} + m_CullTransparentMesh: 1 +--- !u!1 &731424937 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 731424938} + - component: {fileID: 731424940} + - component: {fileID: 731424939} + m_Layer: 5 + m_Name: Text + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!224 &731424938 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 731424937} + 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: 899835911} + m_RootOrder: 0 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0, y: 0} + m_AnchorMax: {x: 1, y: 1} + m_AnchoredPosition: {x: 0, y: 0} + m_SizeDelta: {x: 0, y: 0} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!114 &731424939 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 731424937} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 5f7201a12d95ffc409449d95f23cf332, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 0.196, g: 0.196, b: 0.196, a: 1} + m_RaycastTarget: 1 + m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0} + m_Maskable: 1 + m_OnCullStateChanged: + m_PersistentCalls: + m_Calls: [] + m_FontData: + m_Font: {fileID: 10102, guid: 0000000000000000e000000000000000, type: 0} + m_FontSize: 14 + m_FontStyle: 0 + m_BestFit: 0 + m_MinSize: 10 + m_MaxSize: 40 + m_Alignment: 4 + m_AlignByGeometry: 0 + m_RichText: 1 + m_HorizontalOverflow: 0 + m_VerticalOverflow: 0 + m_LineSpacing: 1 + m_Text: 'ID: toRed' +--- !u!222 &731424940 +CanvasRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 731424937} + m_CullTransparentMesh: 1 +--- !u!1 &740664254 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 740664255} + - component: {fileID: 740664257} + - component: {fileID: 740664256} + m_Layer: 5 + m_Name: Text + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!224 &740664255 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 740664254} + 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: 566135255} + m_RootOrder: 0 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0, y: 0} + m_AnchorMax: {x: 1, y: 1} + m_AnchoredPosition: {x: 0, y: 0} + m_SizeDelta: {x: 0, y: 0} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!114 &740664256 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 740664254} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 5f7201a12d95ffc409449d95f23cf332, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 0.196, g: 0.196, b: 0.196, a: 1} + m_RaycastTarget: 1 + m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0} + m_Maskable: 1 + m_OnCullStateChanged: + m_PersistentCalls: + m_Calls: [] + m_FontData: + m_Font: {fileID: 10102, guid: 0000000000000000e000000000000000, type: 0} + m_FontSize: 14 + m_FontStyle: 0 + m_BestFit: 0 + m_MinSize: 10 + m_MaxSize: 40 + m_Alignment: 4 + m_AlignByGeometry: 0 + m_RichText: 1 + m_HorizontalOverflow: 0 + m_VerticalOverflow: 0 + m_LineSpacing: 1 + m_Text: 'ID: rotate' +--- !u!222 &740664257 +CanvasRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 740664254} + m_CullTransparentMesh: 1 +--- !u!1 &766204079 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 766204080} + - component: {fileID: 766204083} + - component: {fileID: 766204082} + - component: {fileID: 766204081} + m_Layer: 5 + m_Name: 'Button (ID: toRed)' + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!224 &766204080 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 766204079} + 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: + - {fileID: 386943564} + m_Father: {fileID: 1785989881} + m_RootOrder: 1 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0.5, y: 0.5} + m_AnchorMax: {x: 0.5, y: 0.5} + m_AnchoredPosition: {x: -100, y: -36} + m_SizeDelta: {x: 100, y: 30} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!114 &766204081 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 766204079} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 4e29b1a8efbd4b44bb3f3716e73f07ff, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Navigation: + m_Mode: 3 + m_WrapAround: 0 + m_SelectOnUp: {fileID: 0} + m_SelectOnDown: {fileID: 0} + m_SelectOnLeft: {fileID: 0} + m_SelectOnRight: {fileID: 0} + m_Transition: 1 + m_Colors: + m_NormalColor: {r: 1, g: 1, b: 1, a: 1} + m_HighlightedColor: {r: 0.9607843, g: 0.9607843, b: 0.9607843, a: 1} + m_PressedColor: {r: 0.78431374, g: 0.78431374, b: 0.78431374, a: 1} + m_SelectedColor: {r: 0.9607843, g: 0.9607843, b: 0.9607843, a: 1} + m_DisabledColor: {r: 0.78431374, g: 0.78431374, b: 0.78431374, a: 0.5019608} + m_ColorMultiplier: 1 + m_FadeDuration: 0.1 + m_SpriteState: + m_HighlightedSprite: {fileID: 0} + m_PressedSprite: {fileID: 0} + m_SelectedSprite: {fileID: 0} + m_DisabledSprite: {fileID: 0} + m_AnimationTriggers: + m_NormalTrigger: Normal + m_HighlightedTrigger: Highlighted + m_PressedTrigger: Pressed + m_SelectedTrigger: Highlighted + m_DisabledTrigger: Disabled + m_Interactable: 1 + m_TargetGraphic: {fileID: 766204082} + m_OnClick: + m_PersistentCalls: + m_Calls: + - m_Target: {fileID: 1844382610} + m_TargetAssemblyTypeName: + m_MethodName: DORestartAllById + m_Mode: 5 + m_Arguments: + m_ObjectArgument: {fileID: 0} + m_ObjectArgumentAssemblyTypeName: UnityEngine.Object, UnityEngine + m_IntArgument: 0 + m_FloatArgument: 0 + m_StringArgument: toRed + m_BoolArgument: 0 + m_CallState: 2 +--- !u!114 &766204082 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 766204079} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: fe87c0e1cc204ed48ad3b37840f39efc, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 1, g: 1, b: 1, a: 1} + m_RaycastTarget: 1 + m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0} + m_Maskable: 1 + m_OnCullStateChanged: + m_PersistentCalls: + m_Calls: [] + m_Sprite: {fileID: 10905, guid: 0000000000000000f000000000000000, type: 0} + m_Type: 1 + m_PreserveAspect: 0 + m_FillCenter: 1 + m_FillMethod: 4 + m_FillAmount: 1 + m_FillClockwise: 1 + m_FillOrigin: 0 + m_UseSpriteMesh: 0 + m_PixelsPerUnitMultiplier: 1 +--- !u!222 &766204083 +CanvasRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 766204079} + m_CullTransparentMesh: 1 +--- !u!1 &848136767 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 848136772} + - component: {fileID: 848136771} + - component: {fileID: 848136769} + - component: {fileID: 848136768} + 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 &848136768 +AudioListener: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 848136767} + m_Enabled: 1 +--- !u!124 &848136769 +Behaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 848136767} + m_Enabled: 1 +--- !u!20 &848136771 +Camera: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 848136767} + m_Enabled: 1 + serializedVersion: 2 + m_ClearFlags: 1 + m_BackGroundColor: {r: 0.16176468, g: 0.16176468, b: 0.16176468, a: 0.019607844} + m_projectionMatrixMode: 1 + m_GateFitMode: 2 + m_FOVAxisMode: 0 + 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: 0 + 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: 3 + m_HDR: 0 + m_AllowMSAA: 1 + m_AllowDynamicResolution: 0 + m_ForceIntoRT: 0 + m_OcclusionCulling: 1 + m_StereoConvergence: 10 + m_StereoSeparation: 0.022 +--- !u!4 &848136772 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 848136767} + 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 &899835910 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 899835911} + - component: {fileID: 899835914} + - component: {fileID: 899835913} + - component: {fileID: 899835912} + m_Layer: 5 + m_Name: 'Button (ID: toRed)' + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!224 &899835911 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 899835910} + 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: + - {fileID: 731424938} + m_Father: {fileID: 1997177219} + m_RootOrder: 1 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0.5, y: 0.5} + m_AnchorMax: {x: 0.5, y: 0.5} + m_AnchoredPosition: {x: -100, y: -36} + m_SizeDelta: {x: 100, y: 30} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!114 &899835912 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 899835910} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 4e29b1a8efbd4b44bb3f3716e73f07ff, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Navigation: + m_Mode: 3 + m_WrapAround: 0 + m_SelectOnUp: {fileID: 0} + m_SelectOnDown: {fileID: 0} + m_SelectOnLeft: {fileID: 0} + m_SelectOnRight: {fileID: 0} + m_Transition: 1 + m_Colors: + m_NormalColor: {r: 1, g: 1, b: 1, a: 1} + m_HighlightedColor: {r: 0.9607843, g: 0.9607843, b: 0.9607843, a: 1} + m_PressedColor: {r: 0.78431374, g: 0.78431374, b: 0.78431374, a: 1} + m_SelectedColor: {r: 0.9607843, g: 0.9607843, b: 0.9607843, a: 1} + m_DisabledColor: {r: 0.78431374, g: 0.78431374, b: 0.78431374, a: 0.5019608} + m_ColorMultiplier: 1 + m_FadeDuration: 0.1 + m_SpriteState: + m_HighlightedSprite: {fileID: 0} + m_PressedSprite: {fileID: 0} + m_SelectedSprite: {fileID: 0} + m_DisabledSprite: {fileID: 0} + m_AnimationTriggers: + m_NormalTrigger: Normal + m_HighlightedTrigger: Highlighted + m_PressedTrigger: Pressed + m_SelectedTrigger: Highlighted + m_DisabledTrigger: Disabled + m_Interactable: 1 + m_TargetGraphic: {fileID: 899835913} + m_OnClick: + m_PersistentCalls: + m_Calls: + - m_Target: {fileID: 1844382610} + m_TargetAssemblyTypeName: + m_MethodName: DORestartById + m_Mode: 5 + m_Arguments: + m_ObjectArgument: {fileID: 0} + m_ObjectArgumentAssemblyTypeName: UnityEngine.Object, UnityEngine + m_IntArgument: 0 + m_FloatArgument: 0 + m_StringArgument: toRed + m_BoolArgument: 0 + m_CallState: 2 +--- !u!114 &899835913 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 899835910} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: fe87c0e1cc204ed48ad3b37840f39efc, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 1, g: 1, b: 1, a: 1} + m_RaycastTarget: 1 + m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0} + m_Maskable: 1 + m_OnCullStateChanged: + m_PersistentCalls: + m_Calls: [] + m_Sprite: {fileID: 10905, guid: 0000000000000000f000000000000000, type: 0} + m_Type: 1 + m_PreserveAspect: 0 + m_FillCenter: 1 + m_FillMethod: 4 + m_FillAmount: 1 + m_FillClockwise: 1 + m_FillOrigin: 0 + m_UseSpriteMesh: 0 + m_PixelsPerUnitMultiplier: 1 +--- !u!222 &899835914 +CanvasRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 899835910} + m_CullTransparentMesh: 1 +--- !u!1 &970591913 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 970591914} + - component: {fileID: 970591916} + - component: {fileID: 970591915} + m_Layer: 5 + m_Name: Text + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!224 &970591914 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 970591913} + 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: 1356883401} + m_RootOrder: 0 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0, y: 0} + m_AnchorMax: {x: 1, y: 1} + m_AnchoredPosition: {x: 0, y: 0} + m_SizeDelta: {x: 0, y: 0} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!114 &970591915 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 970591913} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 5f7201a12d95ffc409449d95f23cf332, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 0.196, g: 0.196, b: 0.196, a: 1} + m_RaycastTarget: 1 + m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0} + m_Maskable: 1 + m_OnCullStateChanged: + m_PersistentCalls: + m_Calls: [] + m_FontData: + m_Font: {fileID: 10102, guid: 0000000000000000e000000000000000, type: 0} + m_FontSize: 14 + m_FontStyle: 0 + m_BestFit: 0 + m_MinSize: 10 + m_MaxSize: 40 + m_Alignment: 4 + m_AlignByGeometry: 0 + m_RichText: 1 + m_HorizontalOverflow: 0 + m_VerticalOverflow: 0 + m_LineSpacing: 1 + m_Text: DOPlayNext +--- !u!222 &970591916 +CanvasRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 970591913} + m_CullTransparentMesh: 1 +--- !u!1 &1025578319 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1025578320} + - component: {fileID: 1025578322} + - component: {fileID: 1025578321} + m_Layer: 5 + m_Name: Text + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!224 &1025578320 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1025578319} + 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: 1095596651} + m_RootOrder: 0 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0, y: 0} + m_AnchorMax: {x: 1, y: 1} + m_AnchoredPosition: {x: 0, y: 0} + m_SizeDelta: {x: 0, y: 0} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!114 &1025578321 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1025578319} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 5f7201a12d95ffc409449d95f23cf332, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 0.196, g: 0.196, b: 0.196, a: 1} + m_RaycastTarget: 1 + m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0} + m_Maskable: 1 + m_OnCullStateChanged: + m_PersistentCalls: + m_Calls: [] + m_FontData: + m_Font: {fileID: 10102, guid: 0000000000000000e000000000000000, type: 0} + m_FontSize: 14 + m_FontStyle: 0 + m_BestFit: 0 + m_MinSize: 10 + m_MaxSize: 40 + m_Alignment: 4 + m_AlignByGeometry: 0 + m_RichText: 1 + m_HorizontalOverflow: 0 + m_VerticalOverflow: 0 + m_LineSpacing: 1 + m_Text: 'ID: move' +--- !u!222 &1025578322 +CanvasRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1025578319} + m_CullTransparentMesh: 1 +--- !u!1 &1053889438 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1053889442} + - component: {fileID: 1053889441} + - component: {fileID: 1053889440} + - component: {fileID: 1053889439} + m_Layer: 0 + m_Name: EventSystem + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!114 &1053889439 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1053889438} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 2d49b7c1bcd2e07499844da127be038d, type: 3} + m_Name: + m_EditorClassIdentifier: + m_ForceModuleActive: 0 +--- !u!114 &1053889440 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1053889438} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 4f231c4fb786f3946a6b90b886c48677, 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 &1053889441 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1053889438} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 76c392e42b5098c458856cdf6ecaaaa1, type: 3} + m_Name: + m_EditorClassIdentifier: + m_FirstSelected: {fileID: 0} + m_sendNavigationEvents: 1 + m_DragThreshold: 5 +--- !u!4 &1053889442 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1053889438} + 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: 6 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!1 &1095596650 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1095596651} + - component: {fileID: 1095596654} + - component: {fileID: 1095596653} + - component: {fileID: 1095596652} + m_Layer: 5 + m_Name: 'Button (ID: move)' + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!224 &1095596651 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1095596650} + 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: + - {fileID: 1025578320} + m_Father: {fileID: 286188794} + m_RootOrder: 2 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0.5, y: 0.5} + m_AnchorMax: {x: 0.5, y: 0.5} + m_AnchoredPosition: {x: 0, y: -36} + m_SizeDelta: {x: 100, y: 30} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!114 &1095596652 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1095596650} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 4e29b1a8efbd4b44bb3f3716e73f07ff, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Navigation: + m_Mode: 3 + m_WrapAround: 0 + m_SelectOnUp: {fileID: 0} + m_SelectOnDown: {fileID: 0} + m_SelectOnLeft: {fileID: 0} + m_SelectOnRight: {fileID: 0} + m_Transition: 1 + m_Colors: + m_NormalColor: {r: 1, g: 1, b: 1, a: 1} + m_HighlightedColor: {r: 0.9607843, g: 0.9607843, b: 0.9607843, a: 1} + m_PressedColor: {r: 0.78431374, g: 0.78431374, b: 0.78431374, a: 1} + m_SelectedColor: {r: 0.9607843, g: 0.9607843, b: 0.9607843, a: 1} + m_DisabledColor: {r: 0.78431374, g: 0.78431374, b: 0.78431374, a: 0.5019608} + m_ColorMultiplier: 1 + m_FadeDuration: 0.1 + m_SpriteState: + m_HighlightedSprite: {fileID: 0} + m_PressedSprite: {fileID: 0} + m_SelectedSprite: {fileID: 0} + m_DisabledSprite: {fileID: 0} + m_AnimationTriggers: + m_NormalTrigger: Normal + m_HighlightedTrigger: Highlighted + m_PressedTrigger: Pressed + m_SelectedTrigger: Highlighted + m_DisabledTrigger: Disabled + m_Interactable: 1 + m_TargetGraphic: {fileID: 1095596653} + m_OnClick: + m_PersistentCalls: + m_Calls: + - m_Target: {fileID: 1844382610} + m_TargetAssemblyTypeName: + m_MethodName: DOPlayById + m_Mode: 5 + m_Arguments: + m_ObjectArgument: {fileID: 0} + m_ObjectArgumentAssemblyTypeName: UnityEngine.Object, UnityEngine + m_IntArgument: 0 + m_FloatArgument: 0 + m_StringArgument: move + m_BoolArgument: 0 + m_CallState: 2 +--- !u!114 &1095596653 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1095596650} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: fe87c0e1cc204ed48ad3b37840f39efc, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 1, g: 1, b: 1, a: 1} + m_RaycastTarget: 1 + m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0} + m_Maskable: 1 + m_OnCullStateChanged: + m_PersistentCalls: + m_Calls: [] + m_Sprite: {fileID: 10905, guid: 0000000000000000f000000000000000, type: 0} + m_Type: 1 + m_PreserveAspect: 0 + m_FillCenter: 1 + m_FillMethod: 4 + m_FillAmount: 1 + m_FillClockwise: 1 + m_FillOrigin: 0 + m_UseSpriteMesh: 0 + m_PixelsPerUnitMultiplier: 1 +--- !u!222 &1095596654 +CanvasRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1095596650} + m_CullTransparentMesh: 1 +--- !u!1 &1158456309 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1158456312} + - component: {fileID: 1158456311} + - component: {fileID: 1158456310} + m_Layer: 5 + m_Name: Description + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!114 &1158456310 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1158456309} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 5f7201a12d95ffc409449d95f23cf332, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 1, g: 1, b: 1, a: 1} + m_RaycastTarget: 1 + m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0} + m_Maskable: 1 + m_OnCullStateChanged: + m_PersistentCalls: + m_Calls: [] + m_FontData: + m_Font: {fileID: 10102, guid: 0000000000000000e000000000000000, type: 0} + m_FontSize: 14 + m_FontStyle: 0 + m_BestFit: 0 + m_MinSize: 10 + m_MaxSize: 40 + m_Alignment: 1 + m_AlignByGeometry: 0 + m_RichText: 1 + m_HorizontalOverflow: 0 + m_VerticalOverflow: 1 + m_LineSpacing: 1 + m_Text: 'DOPlayById (Cube B as target) + + Will play only the DOTweenAnimations + with the given ID that are on Cube B' +--- !u!222 &1158456311 +CanvasRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1158456309} + m_CullTransparentMesh: 1 +--- !u!224 &1158456312 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1158456309} + 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: 286188794} + m_RootOrder: 0 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0.5, y: 0.5} + m_AnchorMax: {x: 0.5, y: 0.5} + m_AnchoredPosition: {x: 0, y: 0} + m_SizeDelta: {x: 550, y: 30} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!1 &1192540961 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1192540964} + - component: {fileID: 1192540963} + - component: {fileID: 1192540962} + m_Layer: 0 + m_Name: Name + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!102 &1192540962 +TextMesh: + serializedVersion: 3 + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1192540961} + m_Text: A + m_OffsetZ: 0 + m_CharacterSize: 20 + m_LineSpacing: 1 + m_Anchor: 4 + m_Alignment: 1 + m_TabSize: 4 + m_FontSize: 30 + m_FontStyle: 1 + m_RichText: 1 + m_Font: {fileID: 10102, guid: 0000000000000000e000000000000000, type: 0} + m_Color: + serializedVersion: 2 + rgba: 4294967295 +--- !u!23 &1192540963 +MeshRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1192540961} + m_Enabled: 1 + m_CastShadows: 0 + m_ReceiveShadows: 0 + m_DynamicOccludee: 1 + m_MotionVectors: 1 + m_LightProbeUsage: 0 + m_ReflectionProbeUsage: 1 + m_RayTracingMode: 2 + m_RayTraceProcedural: 0 + m_RenderingLayerMask: 1 + m_RendererPriority: 0 + m_Materials: + - {fileID: 10100, guid: 0000000000000000e000000000000000, type: 0} + m_StaticBatchInfo: + firstSubMesh: 0 + subMeshCount: 0 + m_StaticBatchRoot: {fileID: 0} + m_ProbeAnchor: {fileID: 0} + m_LightProbeVolumeOverride: {fileID: 0} + m_ScaleInLightmap: 1 + m_ReceiveGI: 1 + m_PreserveUVs: 0 + m_IgnoreNormalsForChartDetection: 0 + m_ImportantGI: 0 + m_StitchLightmapSeams: 1 + m_SelectedEditorRenderState: 3 + m_MinimumChartSize: 4 + m_AutoUVMaxDistance: 0.5 + m_AutoUVMaxAngle: 89 + m_LightmapParameters: {fileID: 0} + m_SortingLayerID: 0 + m_SortingLayer: 0 + m_SortingOrder: 0 + m_AdditionalVertexStreams: {fileID: 0} +--- !u!4 &1192540964 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1192540961} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: 0, y: 0, z: 0} + m_LocalScale: {x: 0.01, y: 0.01, z: 0.01} + m_Children: [] + m_Father: {fileID: 118309271} + m_RootOrder: 0 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!1 &1242857378 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1242857380} + - component: {fileID: 1242857379} + m_Layer: 0 + m_Name: Directional light + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!108 &1242857379 +Light: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1242857378} + m_Enabled: 1 + serializedVersion: 10 + m_Type: 1 + m_Shape: 0 + m_Color: {r: 1, g: 1, b: 1, a: 1} + m_Intensity: 1 + m_Range: 10 + m_SpotAngle: 30 + m_InnerSpotAngle: 21.80208 + m_CookieSize: 10 + m_Shadows: + m_Type: 0 + m_Resolution: -1 + m_CustomResolution: -1 + m_Strength: 1 + m_Bias: 0.05 + m_NormalBias: 0.4 + m_NearPlane: 0.2 + m_CullingMatrixOverride: + e00: 1 + e01: 0 + e02: 0 + e03: 0 + e10: 0 + e11: 1 + e12: 0 + e13: 0 + e20: 0 + e21: 0 + e22: 1 + e23: 0 + e30: 0 + e31: 0 + e32: 0 + e33: 1 + m_UseCullingMatrixOverride: 0 + m_Cookie: {fileID: 0} + m_DrawHalo: 0 + m_Flare: {fileID: 0} + m_RenderMode: 0 + m_CullingMask: + serializedVersion: 2 + m_Bits: 4294967295 + m_RenderingLayerMask: 1 + m_Lightmapping: 1 + m_LightShadowCasterMode: 0 + m_AreaSize: {x: 1, y: 1} + m_BounceIntensity: 1 + m_ColorTemperature: 6570 + m_UseColorTemperature: 0 + m_BoundingSphereOverride: {x: 0, y: 0, z: 0, w: 0} + m_UseBoundingSphereOverride: 0 + m_UseViewFrustumForShadowCasterCull: 1 + m_ShadowRadius: 0 + m_ShadowAngle: 0 +--- !u!4 &1242857380 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1242857378} + m_LocalRotation: {x: 0.40821794, y: -0.23456973, z: 0.10938166, w: 0.8754261} + m_LocalPosition: {x: 0, y: 0, z: 0} + m_LocalScale: {x: 1, y: 0.99999994, z: 1} + m_Children: [] + m_Father: {fileID: 0} + m_RootOrder: 1 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!1 &1260203940 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1260203941} + - component: {fileID: 1260203944} + - component: {fileID: 1260203943} + - component: {fileID: 1260203942} + m_Layer: 5 + m_Name: Canvas (w button controls) + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!224 &1260203941 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1260203940} + 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: 1356883401} + - {fileID: 286188794} + - {fileID: 186391001} + - {fileID: 1997177219} + - {fileID: 1785989881} + m_Father: {fileID: 0} + m_RootOrder: 5 + 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!114 &1260203942 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1260203940} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: dc42784cf147c0c48a680349fa168899, type: 3} + m_Name: + m_EditorClassIdentifier: + m_IgnoreReversedGraphics: 1 + m_BlockingObjects: 0 + m_BlockingMask: + serializedVersion: 2 + m_Bits: 4294967295 +--- !u!114 &1260203943 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1260203940} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 0cd44c1031e13a943bb63640046fad76, 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 + m_PresetInfoIsWorld: 0 +--- !u!223 &1260203944 +Canvas: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1260203940} + m_Enabled: 1 + serializedVersion: 3 + m_RenderMode: 1 + m_Camera: {fileID: 848136771} + m_PlaneDistance: 100 + m_PixelPerfect: 1 + m_ReceivesEvents: 1 + m_OverrideSorting: 0 + m_OverridePixelPerfect: 0 + m_SortingBucketNormalizedSize: 0 + m_AdditionalShaderChannelsFlag: 25 + m_SortingLayerID: 0 + m_SortingOrder: 0 + m_TargetDisplay: 0 +--- !u!1 &1305249262 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1305249263} + - component: {fileID: 1305249265} + - component: {fileID: 1305249264} + m_Layer: 5 + m_Name: Text + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!224 &1305249263 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1305249262} + 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: 1492174307} + m_RootOrder: 0 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0, y: 0} + m_AnchorMax: {x: 1, y: 1} + m_AnchoredPosition: {x: 0, y: 0} + m_SizeDelta: {x: 0, y: 0} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!114 &1305249264 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1305249262} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 5f7201a12d95ffc409449d95f23cf332, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 0.196, g: 0.196, b: 0.196, a: 1} + m_RaycastTarget: 1 + m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0} + m_Maskable: 1 + m_OnCullStateChanged: + m_PersistentCalls: + m_Calls: [] + m_FontData: + m_Font: {fileID: 10102, guid: 0000000000000000e000000000000000, type: 0} + m_FontSize: 14 + m_FontStyle: 0 + m_BestFit: 0 + m_MinSize: 10 + m_MaxSize: 40 + m_Alignment: 4 + m_AlignByGeometry: 0 + m_RichText: 1 + m_HorizontalOverflow: 0 + m_VerticalOverflow: 0 + m_LineSpacing: 1 + m_Text: 'ID: toRed' +--- !u!222 &1305249265 +CanvasRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1305249262} + m_CullTransparentMesh: 1 +--- !u!1 &1356883400 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1356883401} + - component: {fileID: 1356883404} + - component: {fileID: 1356883403} + - component: {fileID: 1356883402} + m_Layer: 5 + m_Name: Button (DOPlayNext) + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!224 &1356883401 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1356883400} + 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: + - {fileID: 970591914} + m_Father: {fileID: 1260203941} + m_RootOrder: 0 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0.5, y: 0.5} + m_AnchorMax: {x: 0.5, y: 0.5} + m_AnchoredPosition: {x: 0, y: 82} + m_SizeDelta: {x: 160, y: 30} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!114 &1356883402 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1356883400} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 4e29b1a8efbd4b44bb3f3716e73f07ff, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Navigation: + m_Mode: 3 + m_WrapAround: 0 + m_SelectOnUp: {fileID: 0} + m_SelectOnDown: {fileID: 0} + m_SelectOnLeft: {fileID: 0} + m_SelectOnRight: {fileID: 0} + m_Transition: 1 + m_Colors: + m_NormalColor: {r: 1, g: 1, b: 1, a: 1} + m_HighlightedColor: {r: 0.9607843, g: 0.9607843, b: 0.9607843, a: 1} + m_PressedColor: {r: 0.78431374, g: 0.78431374, b: 0.78431374, a: 1} + m_SelectedColor: {r: 0.9607843, g: 0.9607843, b: 0.9607843, a: 1} + m_DisabledColor: {r: 0.78431374, g: 0.78431374, b: 0.78431374, a: 0.5019608} + m_ColorMultiplier: 1 + m_FadeDuration: 0.1 + m_SpriteState: + m_HighlightedSprite: {fileID: 0} + m_PressedSprite: {fileID: 0} + m_SelectedSprite: {fileID: 0} + m_DisabledSprite: {fileID: 0} + m_AnimationTriggers: + m_NormalTrigger: Normal + m_HighlightedTrigger: Highlighted + m_PressedTrigger: Pressed + m_SelectedTrigger: Highlighted + m_DisabledTrigger: Disabled + m_Interactable: 1 + m_TargetGraphic: {fileID: 1356883403} + m_OnClick: + m_PersistentCalls: + m_Calls: + - m_Target: {fileID: 118309274} + m_TargetAssemblyTypeName: + m_MethodName: DOPlayNext + m_Mode: 1 + m_Arguments: + m_ObjectArgument: {fileID: 0} + m_ObjectArgumentAssemblyTypeName: UnityEngine.Object, UnityEngine + m_IntArgument: 0 + m_FloatArgument: 0 + m_StringArgument: + m_BoolArgument: 0 + m_CallState: 2 + - m_Target: {fileID: 1844382610} + m_TargetAssemblyTypeName: + m_MethodName: DOPlayNext + m_Mode: 1 + m_Arguments: + m_ObjectArgument: {fileID: 0} + m_ObjectArgumentAssemblyTypeName: UnityEngine.Object, UnityEngine + m_IntArgument: 0 + m_FloatArgument: 0 + m_StringArgument: + m_BoolArgument: 0 + m_CallState: 2 + - m_Target: {fileID: 76224665} + m_TargetAssemblyTypeName: + m_MethodName: DOPlayNext + m_Mode: 1 + m_Arguments: + m_ObjectArgument: {fileID: 0} + m_ObjectArgumentAssemblyTypeName: UnityEngine.Object, UnityEngine + m_IntArgument: 0 + m_FloatArgument: 0 + m_StringArgument: + m_BoolArgument: 0 + m_CallState: 2 +--- !u!114 &1356883403 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1356883400} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: fe87c0e1cc204ed48ad3b37840f39efc, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 1, g: 1, b: 1, a: 1} + m_RaycastTarget: 1 + m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0} + m_Maskable: 1 + m_OnCullStateChanged: + m_PersistentCalls: + m_Calls: [] + m_Sprite: {fileID: 10905, guid: 0000000000000000f000000000000000, type: 0} + m_Type: 1 + m_PreserveAspect: 0 + m_FillCenter: 1 + m_FillMethod: 4 + m_FillAmount: 1 + m_FillClockwise: 1 + m_FillOrigin: 0 + m_UseSpriteMesh: 0 + m_PixelsPerUnitMultiplier: 1 +--- !u!222 &1356883404 +CanvasRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1356883400} + m_CullTransparentMesh: 1 +--- !u!1 &1371900810 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1371900811} + - component: {fileID: 1371900814} + - component: {fileID: 1371900813} + - component: {fileID: 1371900812} + m_Layer: 5 + m_Name: 'Button (ID: rotate)' + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!224 &1371900811 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1371900810} + 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: + - {fileID: 718047502} + m_Father: {fileID: 1785989881} + m_RootOrder: 3 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0.5, y: 0.5} + m_AnchorMax: {x: 0.5, y: 0.5} + m_AnchoredPosition: {x: 100, y: -36} + m_SizeDelta: {x: 100, y: 30} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!114 &1371900812 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1371900810} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 4e29b1a8efbd4b44bb3f3716e73f07ff, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Navigation: + m_Mode: 3 + m_WrapAround: 0 + m_SelectOnUp: {fileID: 0} + m_SelectOnDown: {fileID: 0} + m_SelectOnLeft: {fileID: 0} + m_SelectOnRight: {fileID: 0} + m_Transition: 1 + m_Colors: + m_NormalColor: {r: 1, g: 1, b: 1, a: 1} + m_HighlightedColor: {r: 0.9607843, g: 0.9607843, b: 0.9607843, a: 1} + m_PressedColor: {r: 0.78431374, g: 0.78431374, b: 0.78431374, a: 1} + m_SelectedColor: {r: 0.9607843, g: 0.9607843, b: 0.9607843, a: 1} + m_DisabledColor: {r: 0.78431374, g: 0.78431374, b: 0.78431374, a: 0.5019608} + m_ColorMultiplier: 1 + m_FadeDuration: 0.1 + m_SpriteState: + m_HighlightedSprite: {fileID: 0} + m_PressedSprite: {fileID: 0} + m_SelectedSprite: {fileID: 0} + m_DisabledSprite: {fileID: 0} + m_AnimationTriggers: + m_NormalTrigger: Normal + m_HighlightedTrigger: Highlighted + m_PressedTrigger: Pressed + m_SelectedTrigger: Highlighted + m_DisabledTrigger: Disabled + m_Interactable: 1 + m_TargetGraphic: {fileID: 1371900813} + m_OnClick: + m_PersistentCalls: + m_Calls: + - m_Target: {fileID: 1844382610} + m_TargetAssemblyTypeName: + m_MethodName: DORestartAllById + m_Mode: 5 + m_Arguments: + m_ObjectArgument: {fileID: 0} + m_ObjectArgumentAssemblyTypeName: UnityEngine.Object, UnityEngine + m_IntArgument: 0 + m_FloatArgument: 0 + m_StringArgument: rotate + m_BoolArgument: 0 + m_CallState: 2 +--- !u!114 &1371900813 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1371900810} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: fe87c0e1cc204ed48ad3b37840f39efc, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 1, g: 1, b: 1, a: 1} + m_RaycastTarget: 1 + m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0} + m_Maskable: 1 + m_OnCullStateChanged: + m_PersistentCalls: + m_Calls: [] + m_Sprite: {fileID: 10905, guid: 0000000000000000f000000000000000, type: 0} + m_Type: 1 + m_PreserveAspect: 0 + m_FillCenter: 1 + m_FillMethod: 4 + m_FillAmount: 1 + m_FillClockwise: 1 + m_FillOrigin: 0 + m_UseSpriteMesh: 0 + m_PixelsPerUnitMultiplier: 1 +--- !u!222 &1371900814 +CanvasRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1371900810} + m_CullTransparentMesh: 1 +--- !u!1 &1477055226 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1477055227} + - component: {fileID: 1477055229} + - component: {fileID: 1477055228} + m_Layer: 5 + m_Name: Text + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!224 &1477055227 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1477055226} + 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: 1644045641} + m_RootOrder: 0 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0, y: 0} + m_AnchorMax: {x: 1, y: 1} + m_AnchoredPosition: {x: 0, y: 0} + m_SizeDelta: {x: 0, y: 0} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!114 &1477055228 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1477055226} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 5f7201a12d95ffc409449d95f23cf332, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 0.196, g: 0.196, b: 0.196, a: 1} + m_RaycastTarget: 1 + m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0} + m_Maskable: 1 + m_OnCullStateChanged: + m_PersistentCalls: + m_Calls: [] + m_FontData: + m_Font: {fileID: 10102, guid: 0000000000000000e000000000000000, type: 0} + m_FontSize: 14 + m_FontStyle: 0 + m_BestFit: 0 + m_MinSize: 10 + m_MaxSize: 40 + m_Alignment: 4 + m_AlignByGeometry: 0 + m_RichText: 1 + m_HorizontalOverflow: 0 + m_VerticalOverflow: 0 + m_LineSpacing: 1 + m_Text: 'ID: rotate' +--- !u!222 &1477055229 +CanvasRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1477055226} + m_CullTransparentMesh: 1 +--- !u!1 &1492174306 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1492174307} + - component: {fileID: 1492174310} + - component: {fileID: 1492174309} + - component: {fileID: 1492174308} + m_Layer: 5 + m_Name: 'Button (ID: toRed)' + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!224 &1492174307 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1492174306} + 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: + - {fileID: 1305249263} + m_Father: {fileID: 186391001} + m_RootOrder: 1 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0.5, y: 0.5} + m_AnchorMax: {x: 0.5, y: 0.5} + m_AnchoredPosition: {x: -100, y: -36} + m_SizeDelta: {x: 100, y: 30} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!114 &1492174308 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1492174306} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 4e29b1a8efbd4b44bb3f3716e73f07ff, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Navigation: + m_Mode: 3 + m_WrapAround: 0 + m_SelectOnUp: {fileID: 0} + m_SelectOnDown: {fileID: 0} + m_SelectOnLeft: {fileID: 0} + m_SelectOnRight: {fileID: 0} + m_Transition: 1 + m_Colors: + m_NormalColor: {r: 1, g: 1, b: 1, a: 1} + m_HighlightedColor: {r: 0.9607843, g: 0.9607843, b: 0.9607843, a: 1} + m_PressedColor: {r: 0.78431374, g: 0.78431374, b: 0.78431374, a: 1} + m_SelectedColor: {r: 0.9607843, g: 0.9607843, b: 0.9607843, a: 1} + m_DisabledColor: {r: 0.78431374, g: 0.78431374, b: 0.78431374, a: 0.5019608} + m_ColorMultiplier: 1 + m_FadeDuration: 0.1 + m_SpriteState: + m_HighlightedSprite: {fileID: 0} + m_PressedSprite: {fileID: 0} + m_SelectedSprite: {fileID: 0} + m_DisabledSprite: {fileID: 0} + m_AnimationTriggers: + m_NormalTrigger: Normal + m_HighlightedTrigger: Highlighted + m_PressedTrigger: Pressed + m_SelectedTrigger: Highlighted + m_DisabledTrigger: Disabled + m_Interactable: 1 + m_TargetGraphic: {fileID: 1492174309} + m_OnClick: + m_PersistentCalls: + m_Calls: + - m_Target: {fileID: 1844382610} + m_TargetAssemblyTypeName: + m_MethodName: DOPlayAllById + m_Mode: 5 + m_Arguments: + m_ObjectArgument: {fileID: 0} + m_ObjectArgumentAssemblyTypeName: UnityEngine.Object, UnityEngine + m_IntArgument: 0 + m_FloatArgument: 0 + m_StringArgument: toRed + m_BoolArgument: 0 + m_CallState: 2 +--- !u!114 &1492174309 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1492174306} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: fe87c0e1cc204ed48ad3b37840f39efc, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 1, g: 1, b: 1, a: 1} + m_RaycastTarget: 1 + m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0} + m_Maskable: 1 + m_OnCullStateChanged: + m_PersistentCalls: + m_Calls: [] + m_Sprite: {fileID: 10905, guid: 0000000000000000f000000000000000, type: 0} + m_Type: 1 + m_PreserveAspect: 0 + m_FillCenter: 1 + m_FillMethod: 4 + m_FillAmount: 1 + m_FillClockwise: 1 + m_FillOrigin: 0 + m_UseSpriteMesh: 0 + m_PixelsPerUnitMultiplier: 1 +--- !u!222 &1492174310 +CanvasRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1492174306} + m_CullTransparentMesh: 1 +--- !u!1 &1619597525 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1619597526} + - component: {fileID: 1619597529} + - component: {fileID: 1619597528} + - component: {fileID: 1619597527} + m_Layer: 5 + m_Name: 'Button (ID: move)' + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!224 &1619597526 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1619597525} + 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: + - {fileID: 215583161} + m_Father: {fileID: 1785989881} + m_RootOrder: 2 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0.5, y: 0.5} + m_AnchorMax: {x: 0.5, y: 0.5} + m_AnchoredPosition: {x: 0, y: -36} + m_SizeDelta: {x: 100, y: 30} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!114 &1619597527 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1619597525} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 4e29b1a8efbd4b44bb3f3716e73f07ff, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Navigation: + m_Mode: 3 + m_WrapAround: 0 + m_SelectOnUp: {fileID: 0} + m_SelectOnDown: {fileID: 0} + m_SelectOnLeft: {fileID: 0} + m_SelectOnRight: {fileID: 0} + m_Transition: 1 + m_Colors: + m_NormalColor: {r: 1, g: 1, b: 1, a: 1} + m_HighlightedColor: {r: 0.9607843, g: 0.9607843, b: 0.9607843, a: 1} + m_PressedColor: {r: 0.78431374, g: 0.78431374, b: 0.78431374, a: 1} + m_SelectedColor: {r: 0.9607843, g: 0.9607843, b: 0.9607843, a: 1} + m_DisabledColor: {r: 0.78431374, g: 0.78431374, b: 0.78431374, a: 0.5019608} + m_ColorMultiplier: 1 + m_FadeDuration: 0.1 + m_SpriteState: + m_HighlightedSprite: {fileID: 0} + m_PressedSprite: {fileID: 0} + m_SelectedSprite: {fileID: 0} + m_DisabledSprite: {fileID: 0} + m_AnimationTriggers: + m_NormalTrigger: Normal + m_HighlightedTrigger: Highlighted + m_PressedTrigger: Pressed + m_SelectedTrigger: Highlighted + m_DisabledTrigger: Disabled + m_Interactable: 1 + m_TargetGraphic: {fileID: 1619597528} + m_OnClick: + m_PersistentCalls: + m_Calls: + - m_Target: {fileID: 1844382610} + m_TargetAssemblyTypeName: + m_MethodName: DORestartAllById + m_Mode: 5 + m_Arguments: + m_ObjectArgument: {fileID: 0} + m_ObjectArgumentAssemblyTypeName: UnityEngine.Object, UnityEngine + m_IntArgument: 0 + m_FloatArgument: 0 + m_StringArgument: move + m_BoolArgument: 0 + m_CallState: 2 +--- !u!114 &1619597528 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1619597525} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: fe87c0e1cc204ed48ad3b37840f39efc, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 1, g: 1, b: 1, a: 1} + m_RaycastTarget: 1 + m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0} + m_Maskable: 1 + m_OnCullStateChanged: + m_PersistentCalls: + m_Calls: [] + m_Sprite: {fileID: 10905, guid: 0000000000000000f000000000000000, type: 0} + m_Type: 1 + m_PreserveAspect: 0 + m_FillCenter: 1 + m_FillMethod: 4 + m_FillAmount: 1 + m_FillClockwise: 1 + m_FillOrigin: 0 + m_UseSpriteMesh: 0 + m_PixelsPerUnitMultiplier: 1 +--- !u!222 &1619597529 +CanvasRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1619597525} + m_CullTransparentMesh: 1 +--- !u!1 &1644045637 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1644045641} + - component: {fileID: 1644045640} + - component: {fileID: 1644045639} + - component: {fileID: 1644045638} + m_Layer: 5 + m_Name: 'Button (ID: rotate)' + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!114 &1644045638 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1644045637} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 4e29b1a8efbd4b44bb3f3716e73f07ff, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Navigation: + m_Mode: 3 + m_WrapAround: 0 + m_SelectOnUp: {fileID: 0} + m_SelectOnDown: {fileID: 0} + m_SelectOnLeft: {fileID: 0} + m_SelectOnRight: {fileID: 0} + m_Transition: 1 + m_Colors: + m_NormalColor: {r: 1, g: 1, b: 1, a: 1} + m_HighlightedColor: {r: 0.9607843, g: 0.9607843, b: 0.9607843, a: 1} + m_PressedColor: {r: 0.78431374, g: 0.78431374, b: 0.78431374, a: 1} + m_SelectedColor: {r: 0.9607843, g: 0.9607843, b: 0.9607843, a: 1} + m_DisabledColor: {r: 0.78431374, g: 0.78431374, b: 0.78431374, a: 0.5019608} + m_ColorMultiplier: 1 + m_FadeDuration: 0.1 + m_SpriteState: + m_HighlightedSprite: {fileID: 0} + m_PressedSprite: {fileID: 0} + m_SelectedSprite: {fileID: 0} + m_DisabledSprite: {fileID: 0} + m_AnimationTriggers: + m_NormalTrigger: Normal + m_HighlightedTrigger: Highlighted + m_PressedTrigger: Pressed + m_SelectedTrigger: Highlighted + m_DisabledTrigger: Disabled + m_Interactable: 1 + m_TargetGraphic: {fileID: 1644045639} + m_OnClick: + m_PersistentCalls: + m_Calls: + - m_Target: {fileID: 1844382610} + m_TargetAssemblyTypeName: + m_MethodName: DOPlayAllById + m_Mode: 5 + m_Arguments: + m_ObjectArgument: {fileID: 0} + m_ObjectArgumentAssemblyTypeName: UnityEngine.Object, UnityEngine + m_IntArgument: 0 + m_FloatArgument: 0 + m_StringArgument: rotate + m_BoolArgument: 0 + m_CallState: 2 +--- !u!114 &1644045639 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1644045637} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: fe87c0e1cc204ed48ad3b37840f39efc, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 1, g: 1, b: 1, a: 1} + m_RaycastTarget: 1 + m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0} + m_Maskable: 1 + m_OnCullStateChanged: + m_PersistentCalls: + m_Calls: [] + m_Sprite: {fileID: 10905, guid: 0000000000000000f000000000000000, type: 0} + m_Type: 1 + m_PreserveAspect: 0 + m_FillCenter: 1 + m_FillMethod: 4 + m_FillAmount: 1 + m_FillClockwise: 1 + m_FillOrigin: 0 + m_UseSpriteMesh: 0 + m_PixelsPerUnitMultiplier: 1 +--- !u!222 &1644045640 +CanvasRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1644045637} + m_CullTransparentMesh: 1 +--- !u!224 &1644045641 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1644045637} + 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: + - {fileID: 1477055227} + m_Father: {fileID: 186391001} + m_RootOrder: 3 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0.5, y: 0.5} + m_AnchorMax: {x: 0.5, y: 0.5} + m_AnchoredPosition: {x: 100, y: -36} + m_SizeDelta: {x: 100, y: 30} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!1 &1760580328 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1760580329} + - component: {fileID: 1760580331} + - component: {fileID: 1760580330} + m_Layer: 0 + m_Name: Name + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &1760580329 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1760580328} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: 0, y: 0, z: 0} + m_LocalScale: {x: 0.01, y: 0.01, z: 0.01} + m_Children: [] + m_Father: {fileID: 76224668} + m_RootOrder: 0 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!102 &1760580330 +TextMesh: + serializedVersion: 3 + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1760580328} + m_Text: C + m_OffsetZ: 0 + m_CharacterSize: 20 + m_LineSpacing: 1 + m_Anchor: 4 + m_Alignment: 1 + m_TabSize: 4 + m_FontSize: 30 + m_FontStyle: 1 + m_RichText: 1 + m_Font: {fileID: 10102, guid: 0000000000000000e000000000000000, type: 0} + m_Color: + serializedVersion: 2 + rgba: 4294967295 +--- !u!23 &1760580331 +MeshRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1760580328} + m_Enabled: 1 + m_CastShadows: 0 + m_ReceiveShadows: 0 + m_DynamicOccludee: 1 + m_MotionVectors: 1 + m_LightProbeUsage: 0 + m_ReflectionProbeUsage: 1 + m_RayTracingMode: 2 + m_RayTraceProcedural: 0 + m_RenderingLayerMask: 1 + m_RendererPriority: 0 + m_Materials: + - {fileID: 10100, guid: 0000000000000000e000000000000000, type: 0} + m_StaticBatchInfo: + firstSubMesh: 0 + subMeshCount: 0 + m_StaticBatchRoot: {fileID: 0} + m_ProbeAnchor: {fileID: 0} + m_LightProbeVolumeOverride: {fileID: 0} + m_ScaleInLightmap: 1 + m_ReceiveGI: 1 + m_PreserveUVs: 0 + m_IgnoreNormalsForChartDetection: 0 + m_ImportantGI: 0 + m_StitchLightmapSeams: 1 + m_SelectedEditorRenderState: 3 + m_MinimumChartSize: 4 + m_AutoUVMaxDistance: 0.5 + m_AutoUVMaxAngle: 89 + m_LightmapParameters: {fileID: 0} + m_SortingLayerID: 0 + m_SortingLayer: 0 + m_SortingOrder: 0 + m_AdditionalVertexStreams: {fileID: 0} +--- !u!1 &1785989880 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1785989881} + m_Layer: 5 + m_Name: Buttons - RestartAllById + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!224 &1785989881 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1785989880} + 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: + - {fileID: 608072283} + - {fileID: 766204080} + - {fileID: 1619597526} + - {fileID: 1371900811} + m_Father: {fileID: 1260203941} + m_RootOrder: 4 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0, y: 0} + m_AnchorMax: {x: 1, y: 1} + m_AnchoredPosition: {x: 0, y: -184} + m_SizeDelta: {x: 0, y: -48} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!1 &1812319720 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1812319721} + - component: {fileID: 1812319723} + - component: {fileID: 1812319722} + m_Layer: 5 + m_Name: Description + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!224 &1812319721 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1812319720} + 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: 1997177219} + m_RootOrder: 0 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0.5, y: 0.5} + m_AnchorMax: {x: 0.5, y: 0.5} + m_AnchoredPosition: {x: 0, y: 0} + m_SizeDelta: {x: 550, y: 30} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!114 &1812319722 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1812319720} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 5f7201a12d95ffc409449d95f23cf332, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 1, g: 1, b: 1, a: 1} + m_RaycastTarget: 1 + m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0} + m_Maskable: 1 + m_OnCullStateChanged: + m_PersistentCalls: + m_Calls: [] + m_FontData: + m_Font: {fileID: 10102, guid: 0000000000000000e000000000000000, type: 0} + m_FontSize: 14 + m_FontStyle: 0 + m_BestFit: 0 + m_MinSize: 10 + m_MaxSize: 40 + m_Alignment: 1 + m_AlignByGeometry: 0 + m_RichText: 1 + m_HorizontalOverflow: 0 + m_VerticalOverflow: 1 + m_LineSpacing: 1 + m_Text: 'DORestartById (Cube B as target) + + Will restart only the DOTweenAnimations + with the given ID that are on Cube B' +--- !u!222 &1812319723 +CanvasRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1812319720} + m_CullTransparentMesh: 1 +--- !u!1 &1839080357 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1839080358} + - component: {fileID: 1839080361} + - component: {fileID: 1839080360} + - component: {fileID: 1839080359} + m_Layer: 5 + m_Name: 'Button (ID: toRed)' + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!224 &1839080358 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1839080357} + 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: + - {fileID: 83016930} + m_Father: {fileID: 286188794} + m_RootOrder: 1 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0.5, y: 0.5} + m_AnchorMax: {x: 0.5, y: 0.5} + m_AnchoredPosition: {x: -100, y: -36} + m_SizeDelta: {x: 100, y: 30} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!114 &1839080359 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1839080357} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 4e29b1a8efbd4b44bb3f3716e73f07ff, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Navigation: + m_Mode: 3 + m_WrapAround: 0 + m_SelectOnUp: {fileID: 0} + m_SelectOnDown: {fileID: 0} + m_SelectOnLeft: {fileID: 0} + m_SelectOnRight: {fileID: 0} + m_Transition: 1 + m_Colors: + m_NormalColor: {r: 1, g: 1, b: 1, a: 1} + m_HighlightedColor: {r: 0.9607843, g: 0.9607843, b: 0.9607843, a: 1} + m_PressedColor: {r: 0.78431374, g: 0.78431374, b: 0.78431374, a: 1} + m_SelectedColor: {r: 0.9607843, g: 0.9607843, b: 0.9607843, a: 1} + m_DisabledColor: {r: 0.78431374, g: 0.78431374, b: 0.78431374, a: 0.5019608} + m_ColorMultiplier: 1 + m_FadeDuration: 0.1 + m_SpriteState: + m_HighlightedSprite: {fileID: 0} + m_PressedSprite: {fileID: 0} + m_SelectedSprite: {fileID: 0} + m_DisabledSprite: {fileID: 0} + m_AnimationTriggers: + m_NormalTrigger: Normal + m_HighlightedTrigger: Highlighted + m_PressedTrigger: Pressed + m_SelectedTrigger: Highlighted + m_DisabledTrigger: Disabled + m_Interactable: 1 + m_TargetGraphic: {fileID: 1839080360} + m_OnClick: + m_PersistentCalls: + m_Calls: + - m_Target: {fileID: 1844382610} + m_TargetAssemblyTypeName: + m_MethodName: DOPlayById + m_Mode: 5 + m_Arguments: + m_ObjectArgument: {fileID: 0} + m_ObjectArgumentAssemblyTypeName: UnityEngine.Object, UnityEngine + m_IntArgument: 0 + m_FloatArgument: 0 + m_StringArgument: toRed + m_BoolArgument: 0 + m_CallState: 2 +--- !u!114 &1839080360 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1839080357} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: fe87c0e1cc204ed48ad3b37840f39efc, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 1, g: 1, b: 1, a: 1} + m_RaycastTarget: 1 + m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0} + m_Maskable: 1 + m_OnCullStateChanged: + m_PersistentCalls: + m_Calls: [] + m_Sprite: {fileID: 10905, guid: 0000000000000000f000000000000000, type: 0} + m_Type: 1 + m_PreserveAspect: 0 + m_FillCenter: 1 + m_FillMethod: 4 + m_FillAmount: 1 + m_FillClockwise: 1 + m_FillOrigin: 0 + m_UseSpriteMesh: 0 + m_PixelsPerUnitMultiplier: 1 +--- !u!222 &1839080361 +CanvasRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1839080357} + m_CullTransparentMesh: 1 +--- !u!1 &1844382605 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1844382606} + - component: {fileID: 1844382612} + - component: {fileID: 1844382611} + - component: {fileID: 1844382610} + - component: {fileID: 1844382609} + - component: {fileID: 1844382608} + m_Layer: 0 + m_Name: Cube B (w animation) + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &1844382606 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1844382605} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: 0, y: 3, z: 0} + m_LocalScale: {x: 1, y: 1, z: 1} + m_Children: + - {fileID: 461995932} + m_Father: {fileID: 0} + m_RootOrder: 3 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!114 &1844382608 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1844382605} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 4d0390bd8b8ffd640b34fe25065ff1df, type: 3} + m_Name: + m_EditorClassIdentifier: + updateType: 0 + isSpeedBased: 0 + hasOnStart: 0 + hasOnPlay: 0 + hasOnUpdate: 0 + hasOnStepComplete: 0 + hasOnComplete: 0 + hasOnTweenCreated: 0 + hasOnRewind: 0 + onStart: + m_PersistentCalls: + m_Calls: [] + onPlay: + m_PersistentCalls: + m_Calls: [] + onUpdate: + m_PersistentCalls: + m_Calls: [] + onStepComplete: + m_PersistentCalls: + m_Calls: [] + onComplete: + m_PersistentCalls: + m_Calls: [] + onTweenCreated: + m_PersistentCalls: + m_Calls: [] + onRewind: + m_PersistentCalls: + m_Calls: [] + targetIsSelf: 1 + targetGO: {fileID: 0} + tweenTargetIsTargetGO: 1 + delay: 0 + duration: 1 + easeType: 6 + easeCurve: + serializedVersion: 2 + m_Curve: + - serializedVersion: 3 + time: 0 + value: 0 + inSlope: 0 + outSlope: 0 + tangentMode: 0 + weightedMode: 0 + inWeight: 0.33333334 + outWeight: 0.33333334 + - serializedVersion: 3 + time: 1 + value: 1 + inSlope: 0 + outSlope: 0 + tangentMode: 0 + weightedMode: 0 + inWeight: 0.33333334 + outWeight: 0.33333334 + m_PreInfinity: 2 + m_PostInfinity: 2 + m_RotationOrder: 4 + loopType: 0 + loops: 1 + id: rotate + isRelative: 0 + isFrom: 0 + isIndependentUpdate: 0 + autoKill: 0 + isActive: 1 + isValid: 1 + target: {fileID: 1844382606} + animationType: 3 + targetType: 0 + forcedTargetType: 0 + autoPlay: 0 + useTargetAsV3: 0 + endValueFloat: 0 + endValueV3: {x: 0, y: 180, z: 0} + endValueV2: {x: 0, y: 0} + endValueColor: {r: 1, g: 1, b: 1, a: 1} + endValueString: + endValueRect: + serializedVersion: 2 + x: 0 + y: 0 + width: 0 + height: 0 + endValueTransform: {fileID: 0} + optionalBool0: 0 + optionalFloat0: 0 + optionalInt0: 0 + optionalRotationMode: 0 + optionalScrambleMode: 0 + optionalString: +--- !u!114 &1844382609 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1844382605} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 4d0390bd8b8ffd640b34fe25065ff1df, type: 3} + m_Name: + m_EditorClassIdentifier: + updateType: 0 + isSpeedBased: 0 + hasOnStart: 0 + hasOnPlay: 0 + hasOnUpdate: 0 + hasOnStepComplete: 0 + hasOnComplete: 0 + hasOnTweenCreated: 0 + hasOnRewind: 0 + onStart: + m_PersistentCalls: + m_Calls: [] + onPlay: + m_PersistentCalls: + m_Calls: [] + onUpdate: + m_PersistentCalls: + m_Calls: [] + onStepComplete: + m_PersistentCalls: + m_Calls: [] + onComplete: + m_PersistentCalls: + m_Calls: [] + onTweenCreated: + m_PersistentCalls: + m_Calls: [] + onRewind: + m_PersistentCalls: + m_Calls: [] + targetIsSelf: 1 + targetGO: {fileID: 0} + tweenTargetIsTargetGO: 1 + delay: 0 + duration: 1 + easeType: 6 + easeCurve: + serializedVersion: 2 + m_Curve: + - serializedVersion: 3 + time: 0 + value: 0 + inSlope: 0 + outSlope: 0 + tangentMode: 0 + weightedMode: 0 + inWeight: 0.33333334 + outWeight: 0.33333334 + - serializedVersion: 3 + time: 1 + value: 1 + inSlope: 0 + outSlope: 0 + tangentMode: 0 + weightedMode: 0 + inWeight: 0.33333334 + outWeight: 0.33333334 + m_PreInfinity: 2 + m_PostInfinity: 2 + m_RotationOrder: 4 + loopType: 0 + loops: 1 + id: move + isRelative: 1 + isFrom: 0 + isIndependentUpdate: 0 + autoKill: 0 + isActive: 1 + isValid: 1 + target: {fileID: 1844382606} + animationType: 1 + targetType: 0 + forcedTargetType: 0 + autoPlay: 0 + useTargetAsV3: 0 + endValueFloat: 0 + endValueV3: {x: 0, y: 1, z: 0} + endValueV2: {x: 0, y: 0} + endValueColor: {r: 1, g: 1, b: 1, a: 1} + endValueString: + endValueRect: + serializedVersion: 2 + x: 0 + y: 0 + width: 0 + height: 0 + endValueTransform: {fileID: 0} + optionalBool0: 0 + optionalFloat0: 0 + optionalInt0: 0 + optionalRotationMode: 0 + optionalScrambleMode: 0 + optionalString: +--- !u!114 &1844382610 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1844382605} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 4d0390bd8b8ffd640b34fe25065ff1df, type: 3} + m_Name: + m_EditorClassIdentifier: + updateType: 0 + isSpeedBased: 0 + hasOnStart: 0 + hasOnPlay: 0 + hasOnUpdate: 0 + hasOnStepComplete: 0 + hasOnComplete: 0 + hasOnTweenCreated: 0 + hasOnRewind: 0 + onStart: + m_PersistentCalls: + m_Calls: [] + onPlay: + m_PersistentCalls: + m_Calls: [] + onUpdate: + m_PersistentCalls: + m_Calls: [] + onStepComplete: + m_PersistentCalls: + m_Calls: [] + onComplete: + m_PersistentCalls: + m_Calls: [] + onTweenCreated: + m_PersistentCalls: + m_Calls: [] + onRewind: + m_PersistentCalls: + m_Calls: [] + targetIsSelf: 1 + targetGO: {fileID: 0} + tweenTargetIsTargetGO: 1 + delay: 0 + duration: 1 + easeType: 6 + easeCurve: + serializedVersion: 2 + m_Curve: + - serializedVersion: 3 + time: 0 + value: 0 + inSlope: 0 + outSlope: 0 + tangentMode: 0 + weightedMode: 0 + inWeight: 0.33333334 + outWeight: 0.33333334 + - serializedVersion: 3 + time: 1 + value: 1 + inSlope: 0 + outSlope: 0 + tangentMode: 0 + weightedMode: 0 + inWeight: 0.33333334 + outWeight: 0.33333334 + m_PreInfinity: 2 + m_PostInfinity: 2 + m_RotationOrder: 4 + loopType: 0 + loops: 1 + id: toRed + isRelative: 0 + isFrom: 0 + isIndependentUpdate: 0 + autoKill: 0 + isActive: 1 + isValid: 1 + target: {fileID: 1844382611} + animationType: 6 + targetType: 0 + forcedTargetType: 0 + autoPlay: 0 + useTargetAsV3: 0 + endValueFloat: 0 + endValueV3: {x: 0, y: 0, z: 0} + endValueV2: {x: 0, y: 0} + endValueColor: {r: 1, g: 0, b: 0, a: 1} + endValueString: + endValueRect: + serializedVersion: 2 + x: 0 + y: 0 + width: 0 + height: 0 + endValueTransform: {fileID: 0} + optionalBool0: 0 + optionalFloat0: 0 + optionalInt0: 0 + optionalRotationMode: 0 + optionalScrambleMode: 0 + optionalString: +--- !u!23 &1844382611 +MeshRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1844382605} + m_Enabled: 1 + m_CastShadows: 1 + m_ReceiveShadows: 1 + m_DynamicOccludee: 1 + m_MotionVectors: 1 + m_LightProbeUsage: 0 + m_ReflectionProbeUsage: 1 + m_RayTracingMode: 2 + m_RayTraceProcedural: 0 + m_RenderingLayerMask: 1 + m_RendererPriority: 0 + m_Materials: + - {fileID: 10302, 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_ReceiveGI: 1 + m_PreserveUVs: 0 + m_IgnoreNormalsForChartDetection: 0 + m_ImportantGI: 0 + m_StitchLightmapSeams: 1 + m_SelectedEditorRenderState: 3 + m_MinimumChartSize: 4 + m_AutoUVMaxDistance: 0.5 + m_AutoUVMaxAngle: 89 + m_LightmapParameters: {fileID: 0} + m_SortingLayerID: 0 + m_SortingLayer: 0 + m_SortingOrder: 0 + m_AdditionalVertexStreams: {fileID: 0} +--- !u!33 &1844382612 +MeshFilter: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1844382605} + m_Mesh: {fileID: 10202, guid: 0000000000000000e000000000000000, type: 0} +--- !u!1 &1997177218 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1997177219} + m_Layer: 5 + m_Name: Buttons - RestartById + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!224 &1997177219 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1997177218} + 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: + - {fileID: 1812319721} + - {fileID: 899835911} + - {fileID: 45542690} + - {fileID: 502741618} + m_Father: {fileID: 1260203941} + m_RootOrder: 3 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0, y: 0} + m_AnchorMax: {x: 1, y: 1} + m_AnchoredPosition: {x: 0, y: -110} + m_SizeDelta: {x: 0, y: -200} + m_Pivot: {x: 0.5, y: 0.5} diff --git a/Assets/Demigiant/DOTweenPro Examples/DOTweenAnimation_Advanced.unity.meta b/Assets/Demigiant/DOTweenPro Examples/DOTweenAnimation_Advanced.unity.meta new file mode 100644 index 0000000..88026a4 --- /dev/null +++ b/Assets/Demigiant/DOTweenPro Examples/DOTweenAnimation_Advanced.unity.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: a5f7a56d339da84449899ecf95fbe33d +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DOTweenPro Examples/DOTweenAnimation_AdvancedSettings.lighting b/Assets/Demigiant/DOTweenPro Examples/DOTweenAnimation_AdvancedSettings.lighting new file mode 100644 index 0000000..dbaae51 --- /dev/null +++ b/Assets/Demigiant/DOTweenPro Examples/DOTweenAnimation_AdvancedSettings.lighting @@ -0,0 +1,63 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!850595691 &4890085278179872738 +LightingSettings: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_Name: DOTweenAnimation_AdvancedSettings + serializedVersion: 3 + m_GIWorkflowMode: 1 + m_EnableBakedLightmaps: 1 + m_EnableRealtimeLightmaps: 0 + m_RealtimeEnvironmentLighting: 1 + m_BounceScale: 1 + m_AlbedoBoost: 1 + m_IndirectOutputScale: 1 + m_UsingShadowmask: 0 + m_BakeBackend: 0 + m_LightmapMaxSize: 1024 + m_BakeResolution: 50 + m_Padding: 2 + m_TextureCompression: 0 + m_AO: 1 + m_AOMaxDistance: 1 + m_CompAOExponent: 1 + m_CompAOExponentDirect: 0 + m_ExtractAO: 0 + m_MixedBakeMode: 1 + m_LightmapsBakeMode: 1 + m_FilterMode: 1 + m_LightmapParameters: {fileID: 15204, guid: 0000000000000000f000000000000000, type: 0} + m_ExportTrainingData: 0 + m_TrainingDataDestination: TrainingData + m_RealtimeResolution: 1 + m_ForceWhiteAlbedo: 0 + m_ForceUpdates: 0 + m_FinalGather: 0 + m_FinalGatherRayCount: 256 + m_FinalGatherFiltering: 1 + m_PVRCulling: 1 + m_PVRSampling: 1 + m_PVRDirectSampleCount: 32 + m_PVRSampleCount: 512 + m_PVREnvironmentSampleCount: 512 + m_PVREnvironmentReferencePointCount: 2048 + m_LightProbeSampleCountMultiplier: 4 + m_PVRBounces: 2 + m_PVRMinBounces: 2 + m_PVREnvironmentMIS: 0 + m_PVRFilteringMode: 0 + m_PVRDenoiserTypeDirect: 0 + m_PVRDenoiserTypeIndirect: 0 + m_PVRDenoiserTypeAO: 0 + m_PVRFilterTypeDirect: 0 + m_PVRFilterTypeIndirect: 0 + m_PVRFilterTypeAO: 0 + m_PVRFilteringGaussRadiusDirect: 1 + m_PVRFilteringGaussRadiusIndirect: 5 + m_PVRFilteringGaussRadiusAO: 2 + m_PVRFilteringAtrousPositionSigmaDirect: 0.5 + m_PVRFilteringAtrousPositionSigmaIndirect: 2 + m_PVRFilteringAtrousPositionSigmaAO: 1 diff --git a/Assets/Demigiant/DOTweenPro Examples/DOTweenAnimation_AdvancedSettings.lighting.meta b/Assets/Demigiant/DOTweenPro Examples/DOTweenAnimation_AdvancedSettings.lighting.meta new file mode 100644 index 0000000..23a63d2 --- /dev/null +++ b/Assets/Demigiant/DOTweenPro Examples/DOTweenAnimation_AdvancedSettings.lighting.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 6914d42df2cd2ab48897601759547b3b +NativeFormatImporter: + externalObjects: {} + mainObjectFileID: 4890085278179872738 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DOTweenPro Examples/DOTweenAnimation_Basics.unity b/Assets/Demigiant/DOTweenPro Examples/DOTweenAnimation_Basics.unity new file mode 100644 index 0000000..0902e49 --- /dev/null +++ b/Assets/Demigiant/DOTweenPro Examples/DOTweenAnimation_Basics.unity @@ -0,0 +1,1777 @@ +%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.2, g: 0.2, b: 0.2, a: 1} + m_AmbientEquatorColor: {r: 0.2, g: 0.2, b: 0.2, a: 1} + m_AmbientGroundColor: {r: 0.2, g: 0.2, b: 0.2, 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 &4 +LightmapSettings: + m_ObjectHideFlags: 0 + serializedVersion: 12 + m_GIWorkflowMode: 1 + m_GISettings: + serializedVersion: 2 + m_BounceScale: 1 + m_IndirectOutputScale: 1 + m_AlbedoBoost: 1 + m_EnvironmentLightingMode: 0 + m_EnableBakedLightmaps: 1 + m_EnableRealtimeLightmaps: 0 + m_LightmapEditorSettings: + serializedVersion: 12 + m_Resolution: 1 + m_BakeResolution: 50 + m_AtlasSize: 1024 + m_AO: 1 + m_AOMaxDistance: 1 + m_CompAOExponent: 1 + m_CompAOExponentDirect: 0 + m_ExtractAmbientOcclusion: 0 + m_Padding: 2 + m_LightmapParameters: {fileID: 0} + m_LightmapsBakeMode: 1 + m_TextureCompression: 0 + m_FinalGather: 0 + m_FinalGatherFiltering: 1 + m_FinalGatherRayCount: 256 + m_ReflectionCompression: 2 + m_MixedBakeMode: 1 + m_BakeBackend: 0 + m_PVRSampling: 1 + m_PVRDirectSampleCount: 32 + m_PVRSampleCount: 512 + m_PVRBounces: 2 + m_PVREnvironmentSampleCount: 512 + m_PVREnvironmentReferencePointCount: 2048 + m_PVRFilteringMode: 0 + m_PVRDenoiserTypeDirect: 0 + m_PVRDenoiserTypeIndirect: 0 + m_PVRDenoiserTypeAO: 0 + m_PVRFilterTypeDirect: 0 + m_PVRFilterTypeIndirect: 0 + m_PVRFilterTypeAO: 0 + m_PVREnvironmentMIS: 0 + m_PVRCulling: 1 + m_PVRFilteringGaussRadiusDirect: 1 + m_PVRFilteringGaussRadiusIndirect: 5 + m_PVRFilteringGaussRadiusAO: 2 + m_PVRFilteringAtrousPositionSigmaDirect: 0.5 + m_PVRFilteringAtrousPositionSigmaIndirect: 2 + m_PVRFilteringAtrousPositionSigmaAO: 1 + m_ExportTrainingData: 0 + m_TrainingDataDestination: TrainingData + m_LightProbeSampleCountMultiplier: 4 + m_LightingDataAsset: {fileID: 0} + m_LightingSettings: {fileID: 4890085278179872738, guid: 5e22310a645f7bd4ab6357d40c9f33fa, type: 2} +--- !u!196 &5 +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.16666666 + manualTileSize: 0 + tileSize: 256 + accuratePlacement: 0 + maxJobWorkers: 0 + preserveTilesOutsideBounds: 0 + debug: + m_Flags: 0 + m_NavMeshData: {fileID: 0} +--- !u!1 &118309267 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 118309271} + - component: {fileID: 118309270} + - component: {fileID: 118309268} + - component: {fileID: 118309273} + - component: {fileID: 118309272} + m_Layer: 0 + m_Name: Cube (w animation) + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!23 &118309268 +MeshRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 118309267} + m_Enabled: 1 + m_CastShadows: 1 + m_ReceiveShadows: 1 + m_DynamicOccludee: 1 + m_MotionVectors: 1 + m_LightProbeUsage: 0 + m_ReflectionProbeUsage: 1 + m_RayTracingMode: 2 + m_RayTraceProcedural: 0 + m_RenderingLayerMask: 1 + m_RendererPriority: 0 + m_Materials: + - {fileID: 10302, 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_ReceiveGI: 1 + m_PreserveUVs: 0 + m_IgnoreNormalsForChartDetection: 0 + m_ImportantGI: 0 + m_StitchLightmapSeams: 1 + m_SelectedEditorRenderState: 3 + m_MinimumChartSize: 4 + m_AutoUVMaxDistance: 0.5 + m_AutoUVMaxAngle: 89 + m_LightmapParameters: {fileID: 0} + m_SortingLayerID: 0 + m_SortingLayer: 0 + m_SortingOrder: 0 + m_AdditionalVertexStreams: {fileID: 0} +--- !u!33 &118309270 +MeshFilter: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 118309267} + m_Mesh: {fileID: 10202, guid: 0000000000000000e000000000000000, type: 0} +--- !u!4 &118309271 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 118309267} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: -4, y: 0, z: 0} + m_LocalScale: {x: 1, y: 1, z: 1} + m_Children: [] + m_Father: {fileID: 0} + m_RootOrder: 2 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!114 &118309272 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 118309267} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 4d0390bd8b8ffd640b34fe25065ff1df, type: 3} + m_Name: + m_EditorClassIdentifier: + updateType: 0 + isSpeedBased: 0 + hasOnStart: 0 + hasOnPlay: 0 + hasOnUpdate: 0 + hasOnStepComplete: 0 + hasOnComplete: 0 + hasOnTweenCreated: 0 + hasOnRewind: 0 + onStart: + m_PersistentCalls: + m_Calls: [] + onPlay: + m_PersistentCalls: + m_Calls: [] + onUpdate: + m_PersistentCalls: + m_Calls: [] + onStepComplete: + m_PersistentCalls: + m_Calls: [] + onComplete: + m_PersistentCalls: + m_Calls: [] + onTweenCreated: + m_PersistentCalls: + m_Calls: [] + onRewind: + m_PersistentCalls: + m_Calls: [] + targetIsSelf: 1 + targetGO: {fileID: 0} + tweenTargetIsTargetGO: 1 + delay: 0 + duration: 2 + easeType: 6 + easeCurve: + serializedVersion: 2 + m_Curve: + - serializedVersion: 3 + time: 0 + value: 0 + inSlope: 0 + outSlope: 0 + tangentMode: 0 + weightedMode: 0 + inWeight: 0.33333334 + outWeight: 0.33333334 + - serializedVersion: 3 + time: 1 + value: 1 + inSlope: 0 + outSlope: 0 + tangentMode: 0 + weightedMode: 0 + inWeight: 0.33333334 + outWeight: 0.33333334 + m_PreInfinity: 2 + m_PostInfinity: 2 + m_RotationOrder: 4 + loopType: 1 + loops: -1 + id: + isRelative: 0 + isFrom: 0 + isIndependentUpdate: 0 + autoKill: 1 + isActive: 1 + isValid: 1 + target: {fileID: 118309271} + animationType: 3 + targetType: 0 + forcedTargetType: 0 + autoPlay: 0 + useTargetAsV3: 0 + endValueFloat: 0 + endValueV3: {x: 0, y: 180, z: 0} + endValueV2: {x: 0, y: 0} + endValueColor: {r: 1, g: 1, b: 1, a: 1} + endValueString: + endValueRect: + serializedVersion: 2 + x: 0 + y: 0 + width: 0 + height: 0 + endValueTransform: {fileID: 0} + optionalBool0: 0 + optionalFloat0: 0 + optionalInt0: 0 + optionalRotationMode: 0 + optionalScrambleMode: 0 + optionalString: +--- !u!114 &118309273 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 118309267} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 4d0390bd8b8ffd640b34fe25065ff1df, type: 3} + m_Name: + m_EditorClassIdentifier: + updateType: 0 + isSpeedBased: 0 + hasOnStart: 0 + hasOnPlay: 0 + hasOnUpdate: 0 + hasOnStepComplete: 0 + hasOnComplete: 0 + hasOnTweenCreated: 0 + hasOnRewind: 0 + onStart: + m_PersistentCalls: + m_Calls: [] + onPlay: + m_PersistentCalls: + m_Calls: [] + onUpdate: + m_PersistentCalls: + m_Calls: [] + onStepComplete: + m_PersistentCalls: + m_Calls: [] + onComplete: + m_PersistentCalls: + m_Calls: [] + onTweenCreated: + m_PersistentCalls: + m_Calls: [] + onRewind: + m_PersistentCalls: + m_Calls: [] + targetIsSelf: 1 + targetGO: {fileID: 0} + tweenTargetIsTargetGO: 1 + delay: 0 + duration: 2 + easeType: 6 + easeCurve: + serializedVersion: 2 + m_Curve: + - serializedVersion: 3 + time: 0 + value: 0 + inSlope: 0 + outSlope: 0 + tangentMode: 0 + weightedMode: 0 + inWeight: 0.33333334 + outWeight: 0.33333334 + - serializedVersion: 3 + time: 1 + value: 1 + inSlope: 0 + outSlope: 0 + tangentMode: 0 + weightedMode: 0 + inWeight: 0.33333334 + outWeight: 0.33333334 + m_PreInfinity: 2 + m_PostInfinity: 2 + m_RotationOrder: 4 + loopType: 1 + loops: -1 + id: + isRelative: 1 + isFrom: 0 + isIndependentUpdate: 0 + autoKill: 1 + isActive: 1 + isValid: 1 + target: {fileID: 118309271} + animationType: 1 + targetType: 0 + forcedTargetType: 0 + autoPlay: 0 + useTargetAsV3: 0 + endValueFloat: 0 + endValueV3: {x: 0, y: 4, z: 0} + endValueV2: {x: 0, y: 0} + endValueColor: {r: 1, g: 1, b: 1, a: 1} + endValueString: + endValueRect: + serializedVersion: 2 + x: 0 + y: 0 + width: 0 + height: 0 + endValueTransform: {fileID: 0} + optionalBool0: 0 + optionalFloat0: 0 + optionalInt0: 0 + optionalRotationMode: 0 + optionalScrambleMode: 0 + optionalString: +--- !u!1 &848136767 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 848136772} + - component: {fileID: 848136771} + - component: {fileID: 848136769} + - component: {fileID: 848136768} + 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 &848136768 +AudioListener: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 848136767} + m_Enabled: 1 +--- !u!124 &848136769 +Behaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 848136767} + m_Enabled: 1 +--- !u!20 &848136771 +Camera: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 848136767} + m_Enabled: 1 + serializedVersion: 2 + m_ClearFlags: 1 + m_BackGroundColor: {r: 0.16176468, g: 0.16176468, b: 0.16176468, a: 0.019607844} + m_projectionMatrixMode: 1 + m_GateFitMode: 2 + m_FOVAxisMode: 0 + 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: 0 + 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: 3 + m_HDR: 0 + m_AllowMSAA: 1 + m_AllowDynamicResolution: 0 + m_ForceIntoRT: 0 + m_OcclusionCulling: 1 + m_StereoConvergence: 10 + m_StereoSeparation: 0.022 +--- !u!4 &848136772 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 848136767} + 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 &970591913 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 970591914} + - component: {fileID: 970591916} + - component: {fileID: 970591915} + m_Layer: 5 + m_Name: Text + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!224 &970591914 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 970591913} + 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: 1356883401} + m_RootOrder: 0 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0, y: 0} + m_AnchorMax: {x: 1, y: 1} + m_AnchoredPosition: {x: 0, y: 0} + m_SizeDelta: {x: 0, y: 0} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!114 &970591915 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 970591913} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 5f7201a12d95ffc409449d95f23cf332, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 0.196, g: 0.196, b: 0.196, a: 1} + m_RaycastTarget: 1 + m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0} + m_Maskable: 1 + m_OnCullStateChanged: + m_PersistentCalls: + m_Calls: [] + m_FontData: + m_Font: {fileID: 10102, guid: 0000000000000000e000000000000000, type: 0} + m_FontSize: 14 + m_FontStyle: 0 + m_BestFit: 0 + m_MinSize: 10 + m_MaxSize: 40 + m_Alignment: 4 + m_AlignByGeometry: 0 + m_RichText: 1 + m_HorizontalOverflow: 0 + m_VerticalOverflow: 0 + m_LineSpacing: 1 + m_Text: PLAY +--- !u!222 &970591916 +CanvasRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 970591913} + m_CullTransparentMesh: 1 +--- !u!1 &990238542 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 990238543} + - component: {fileID: 990238545} + - component: {fileID: 990238544} + - component: {fileID: 990238546} + m_Layer: 5 + m_Name: Text (w text animation) + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!224 &990238543 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 990238542} + 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: 1260203941} + m_RootOrder: 1 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0.5, y: 0.5} + m_AnchorMax: {x: 0.5, y: 0.5} + m_AnchoredPosition: {x: 0, y: 230} + m_SizeDelta: {x: 400, y: 30} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!114 &990238544 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 990238542} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 5f7201a12d95ffc409449d95f23cf332, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 1, g: 1, b: 1, a: 1} + m_RaycastTarget: 1 + m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0} + m_Maskable: 1 + m_OnCullStateChanged: + m_PersistentCalls: + m_Calls: [] + m_FontData: + m_Font: {fileID: 10102, guid: 0000000000000000e000000000000000, type: 0} + m_FontSize: 16 + m_FontStyle: 0 + m_BestFit: 0 + m_MinSize: 10 + m_MaxSize: 40 + m_Alignment: 1 + m_AlignByGeometry: 0 + m_RichText: 1 + m_HorizontalOverflow: 0 + m_VerticalOverflow: 1 + m_LineSpacing: 1 + m_Text: 'Original text that will be + tweened + +' +--- !u!222 &990238545 +CanvasRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 990238542} + m_CullTransparentMesh: 1 +--- !u!114 &990238546 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 990238542} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 4d0390bd8b8ffd640b34fe25065ff1df, type: 3} + m_Name: + m_EditorClassIdentifier: + updateType: 0 + isSpeedBased: 0 + hasOnStart: 0 + hasOnPlay: 0 + hasOnUpdate: 0 + hasOnStepComplete: 0 + hasOnComplete: 0 + hasOnTweenCreated: 0 + hasOnRewind: 0 + onStart: + m_PersistentCalls: + m_Calls: [] + onPlay: + m_PersistentCalls: + m_Calls: [] + onUpdate: + m_PersistentCalls: + m_Calls: [] + onStepComplete: + m_PersistentCalls: + m_Calls: [] + onComplete: + m_PersistentCalls: + m_Calls: [] + onTweenCreated: + m_PersistentCalls: + m_Calls: [] + onRewind: + m_PersistentCalls: + m_Calls: [] + targetIsSelf: 1 + targetGO: {fileID: 0} + tweenTargetIsTargetGO: 1 + delay: 0 + duration: 3 + easeType: 1 + easeCurve: + serializedVersion: 2 + m_Curve: + - serializedVersion: 3 + time: 0 + value: 0 + inSlope: 0 + outSlope: 0 + tangentMode: 0 + weightedMode: 0 + inWeight: 0.33333334 + outWeight: 0.33333334 + - serializedVersion: 3 + time: 1 + value: 1 + inSlope: 0 + outSlope: 0 + tangentMode: 0 + weightedMode: 0 + inWeight: 0.33333334 + outWeight: 0.33333334 + m_PreInfinity: 2 + m_PostInfinity: 2 + m_RotationOrder: 4 + loopType: 1 + loops: 0 + id: + isRelative: 0 + isFrom: 0 + isIndependentUpdate: 0 + autoKill: 1 + isActive: 1 + isValid: 1 + target: {fileID: 990238544} + animationType: 8 + targetType: 0 + forcedTargetType: 0 + autoPlay: 0 + useTargetAsV3: 0 + endValueFloat: 0 + endValueV3: {x: 0, y: 0, z: 0} + endValueV2: {x: 0, y: 0} + endValueColor: {r: 1, g: 1, b: 1, a: 1} + endValueString: This is the new tweened text + (scandalous)! + endValueRect: + serializedVersion: 2 + x: 0 + y: 0 + width: 0 + height: 0 + endValueTransform: {fileID: 0} + optionalBool0: 1 + optionalFloat0: 0 + optionalInt0: 0 + optionalRotationMode: 0 + optionalScrambleMode: 0 + optionalString: +--- !u!1 &1053889438 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1053889442} + - component: {fileID: 1053889441} + - component: {fileID: 1053889440} + - component: {fileID: 1053889439} + m_Layer: 0 + m_Name: EventSystem + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!114 &1053889439 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1053889438} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 2d49b7c1bcd2e07499844da127be038d, type: 3} + m_Name: + m_EditorClassIdentifier: + m_ForceModuleActive: 0 +--- !u!114 &1053889440 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1053889438} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 4f231c4fb786f3946a6b90b886c48677, 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 &1053889441 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1053889438} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 76c392e42b5098c458856cdf6ecaaaa1, type: 3} + m_Name: + m_EditorClassIdentifier: + m_FirstSelected: {fileID: 0} + m_sendNavigationEvents: 1 + m_DragThreshold: 5 +--- !u!4 &1053889442 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1053889438} + 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: 4 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!1 &1127963255 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1127963256} + - component: {fileID: 1127963258} + - component: {fileID: 1127963257} + m_Layer: 5 + m_Name: Info + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!224 &1127963256 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1127963255} + 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: 1260203941} + m_RootOrder: 4 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0.5, y: 0.5} + m_AnchorMax: {x: 0.5, y: 0.5} + m_AnchoredPosition: {x: 0, y: -186} + m_SizeDelta: {x: 300, y: 30} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!114 &1127963257 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1127963255} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 5f7201a12d95ffc409449d95f23cf332, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 1, g: 1, b: 1, a: 1} + m_RaycastTarget: 1 + m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0} + m_Maskable: 1 + m_OnCullStateChanged: + m_PersistentCalls: + m_Calls: [] + m_FontData: + m_Font: {fileID: 10102, guid: 0000000000000000e000000000000000, type: 0} + m_FontSize: 14 + m_FontStyle: 0 + m_BestFit: 0 + m_MinSize: 10 + m_MaxSize: 40 + m_Alignment: 1 + m_AlignByGeometry: 0 + m_RichText: 1 + m_HorizontalOverflow: 0 + m_VerticalOverflow: 1 + m_LineSpacing: 1 + m_Text: The PLAY button starts the logo fade out. When the fade out is complete, + it will start all the other animations (thanks to the Events created in the logo + DOTweenAnimation Component) +--- !u!222 &1127963258 +CanvasRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1127963255} + m_CullTransparentMesh: 1 +--- !u!1 &1242857378 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1242857380} + - component: {fileID: 1242857379} + m_Layer: 0 + m_Name: Directional light + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!108 &1242857379 +Light: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1242857378} + m_Enabled: 1 + serializedVersion: 10 + m_Type: 1 + m_Shape: 0 + m_Color: {r: 1, g: 1, b: 1, a: 1} + m_Intensity: 1 + m_Range: 10 + m_SpotAngle: 30 + m_InnerSpotAngle: 21.80208 + m_CookieSize: 10 + m_Shadows: + m_Type: 0 + m_Resolution: -1 + m_CustomResolution: -1 + m_Strength: 1 + m_Bias: 0.05 + m_NormalBias: 0.4 + m_NearPlane: 0.2 + m_CullingMatrixOverride: + e00: 1 + e01: 0 + e02: 0 + e03: 0 + e10: 0 + e11: 1 + e12: 0 + e13: 0 + e20: 0 + e21: 0 + e22: 1 + e23: 0 + e30: 0 + e31: 0 + e32: 0 + e33: 1 + m_UseCullingMatrixOverride: 0 + m_Cookie: {fileID: 0} + m_DrawHalo: 0 + m_Flare: {fileID: 0} + m_RenderMode: 0 + m_CullingMask: + serializedVersion: 2 + m_Bits: 4294967295 + m_RenderingLayerMask: 1 + m_Lightmapping: 1 + m_LightShadowCasterMode: 0 + m_AreaSize: {x: 1, y: 1} + m_BounceIntensity: 1 + m_ColorTemperature: 6570 + m_UseColorTemperature: 0 + m_BoundingSphereOverride: {x: 0, y: 0, z: 0, w: 0} + m_UseBoundingSphereOverride: 0 + m_UseViewFrustumForShadowCasterCull: 1 + m_ShadowRadius: 0 + m_ShadowAngle: 0 +--- !u!4 &1242857380 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1242857378} + m_LocalRotation: {x: 0.40821794, y: -0.23456973, z: 0.10938166, w: 0.8754261} + m_LocalPosition: {x: 0, y: 0, z: 0} + m_LocalScale: {x: 1, y: 0.99999994, z: 1} + m_Children: [] + m_Father: {fileID: 0} + m_RootOrder: 1 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!1 &1260203940 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1260203941} + - component: {fileID: 1260203944} + - component: {fileID: 1260203943} + - component: {fileID: 1260203942} + m_Layer: 5 + m_Name: Canvas (contains animated objects) + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!224 &1260203941 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1260203940} + 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: 1636198022} + - {fileID: 990238543} + - {fileID: 1323952358} + - {fileID: 1356883401} + - {fileID: 1127963256} + m_Father: {fileID: 0} + m_RootOrder: 3 + 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!114 &1260203942 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1260203940} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: dc42784cf147c0c48a680349fa168899, type: 3} + m_Name: + m_EditorClassIdentifier: + m_IgnoreReversedGraphics: 1 + m_BlockingObjects: 0 + m_BlockingMask: + serializedVersion: 2 + m_Bits: 4294967295 +--- !u!114 &1260203943 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1260203940} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 0cd44c1031e13a943bb63640046fad76, 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 + m_PresetInfoIsWorld: 0 +--- !u!223 &1260203944 +Canvas: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1260203940} + m_Enabled: 1 + serializedVersion: 3 + m_RenderMode: 0 + m_Camera: {fileID: 0} + m_PlaneDistance: 100 + m_PixelPerfect: 1 + m_ReceivesEvents: 1 + m_OverrideSorting: 0 + m_OverridePixelPerfect: 0 + m_SortingBucketNormalizedSize: 0 + m_AdditionalShaderChannelsFlag: 25 + m_SortingLayerID: 0 + m_SortingOrder: 0 + m_TargetDisplay: 0 +--- !u!1 &1323952357 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1323952358} + - component: {fileID: 1323952362} + - component: {fileID: 1323952361} + - component: {fileID: 1323952360} + - component: {fileID: 1323952359} + m_Layer: 5 + m_Name: Text (w color animation) + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!224 &1323952358 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1323952357} + 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: 1260203941} + m_RootOrder: 2 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0.5, y: 0.5} + m_AnchorMax: {x: 0.5, y: 0.5} + m_AnchoredPosition: {x: 0, y: 254} + m_SizeDelta: {x: 400, y: 30} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!114 &1323952359 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1323952357} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 4d0390bd8b8ffd640b34fe25065ff1df, type: 3} + m_Name: + m_EditorClassIdentifier: + updateType: 0 + isSpeedBased: 0 + hasOnStart: 0 + hasOnPlay: 0 + hasOnUpdate: 0 + hasOnStepComplete: 0 + hasOnComplete: 0 + hasOnTweenCreated: 0 + hasOnRewind: 0 + onStart: + m_PersistentCalls: + m_Calls: [] + onPlay: + m_PersistentCalls: + m_Calls: [] + onUpdate: + m_PersistentCalls: + m_Calls: [] + onStepComplete: + m_PersistentCalls: + m_Calls: [] + onComplete: + m_PersistentCalls: + m_Calls: [] + onTweenCreated: + m_PersistentCalls: + m_Calls: [] + onRewind: + m_PersistentCalls: + m_Calls: [] + targetIsSelf: 1 + targetGO: {fileID: 0} + tweenTargetIsTargetGO: 1 + delay: 0 + duration: 3 + easeType: 1 + easeCurve: + serializedVersion: 2 + m_Curve: + - serializedVersion: 3 + time: 0 + value: 0 + inSlope: 0 + outSlope: 0 + tangentMode: 0 + weightedMode: 0 + inWeight: 0.33333334 + outWeight: 0.33333334 + - serializedVersion: 3 + time: 1 + value: 1 + inSlope: 0 + outSlope: 0 + tangentMode: 0 + weightedMode: 0 + inWeight: 0.33333334 + outWeight: 0.33333334 + m_PreInfinity: 2 + m_PostInfinity: 2 + m_RotationOrder: 4 + loopType: 1 + loops: -1 + id: + isRelative: 0 + isFrom: 0 + isIndependentUpdate: 0 + autoKill: 1 + isActive: 1 + isValid: 1 + target: {fileID: 1323952361} + animationType: 6 + targetType: 0 + forcedTargetType: 0 + autoPlay: 0 + useTargetAsV3: 0 + endValueFloat: 0 + endValueV3: {x: 0, y: 0, z: 0} + endValueV2: {x: 0, y: 0} + endValueColor: {r: 1, g: 0, b: 0.8068962, a: 1} + endValueString: + endValueRect: + serializedVersion: 2 + x: 0 + y: 0 + width: 0 + height: 0 + endValueTransform: {fileID: 0} + optionalBool0: 0 + optionalFloat0: 0 + optionalInt0: 0 + optionalRotationMode: 0 + optionalScrambleMode: 0 + optionalString: +--- !u!114 &1323952360 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1323952357} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 4d0390bd8b8ffd640b34fe25065ff1df, type: 3} + m_Name: + m_EditorClassIdentifier: + updateType: 0 + isSpeedBased: 0 + hasOnStart: 0 + hasOnPlay: 0 + hasOnUpdate: 0 + hasOnStepComplete: 0 + hasOnComplete: 0 + hasOnTweenCreated: 0 + hasOnRewind: 0 + onStart: + m_PersistentCalls: + m_Calls: [] + onPlay: + m_PersistentCalls: + m_Calls: [] + onUpdate: + m_PersistentCalls: + m_Calls: [] + onStepComplete: + m_PersistentCalls: + m_Calls: [] + onComplete: + m_PersistentCalls: + m_Calls: [] + onTweenCreated: + m_PersistentCalls: + m_Calls: [] + onRewind: + m_PersistentCalls: + m_Calls: [] + targetIsSelf: 1 + targetGO: {fileID: 0} + tweenTargetIsTargetGO: 1 + delay: 0 + duration: 3 + easeType: 1 + easeCurve: + serializedVersion: 2 + m_Curve: + - serializedVersion: 3 + time: 0 + value: 0 + inSlope: 0 + outSlope: 0 + tangentMode: 0 + weightedMode: 0 + inWeight: 0.33333334 + outWeight: 0.33333334 + - serializedVersion: 3 + time: 1 + value: 1 + inSlope: 0 + outSlope: 0 + tangentMode: 0 + weightedMode: 0 + inWeight: 0.33333334 + outWeight: 0.33333334 + m_PreInfinity: 2 + m_PostInfinity: 2 + m_RotationOrder: 4 + loopType: 1 + loops: 0 + id: + isRelative: 1 + isFrom: 0 + isIndependentUpdate: 0 + autoKill: 1 + isActive: 1 + isValid: 1 + target: {fileID: 1323952361} + animationType: 8 + targetType: 0 + forcedTargetType: 0 + autoPlay: 0 + useTargetAsV3: 0 + endValueFloat: 0 + endValueV3: {x: 0, y: 0, z: 0} + endValueV2: {x: 0, y: 0} + endValueColor: {r: 1, g: 1, b: 1, a: 1} + endValueString: ' See? What did I tell you?' + endValueRect: + serializedVersion: 2 + x: 0 + y: 0 + width: 0 + height: 0 + endValueTransform: {fileID: 0} + optionalBool0: 1 + optionalFloat0: 0 + optionalInt0: 0 + optionalRotationMode: 0 + optionalScrambleMode: 0 + optionalString: +--- !u!114 &1323952361 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1323952357} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 5f7201a12d95ffc409449d95f23cf332, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 1, g: 1, b: 1, a: 1} + m_RaycastTarget: 1 + m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0} + m_Maskable: 1 + m_OnCullStateChanged: + m_PersistentCalls: + m_Calls: [] + m_FontData: + m_Font: {fileID: 10102, guid: 0000000000000000e000000000000000, type: 0} + m_FontSize: 16 + m_FontStyle: 0 + m_BestFit: 0 + m_MinSize: 10 + m_MaxSize: 40 + m_Alignment: 1 + m_AlignByGeometry: 0 + m_RichText: 1 + m_HorizontalOverflow: 0 + m_VerticalOverflow: 1 + m_LineSpacing: 1 + m_Text: This text will change color... +--- !u!222 &1323952362 +CanvasRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1323952357} + m_CullTransparentMesh: 1 +--- !u!1 &1356883400 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1356883401} + - component: {fileID: 1356883404} + - component: {fileID: 1356883403} + - component: {fileID: 1356883402} + m_Layer: 5 + m_Name: Button + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!224 &1356883401 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1356883400} + 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: + - {fileID: 970591914} + m_Father: {fileID: 1260203941} + m_RootOrder: 3 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0.5, y: 0.5} + m_AnchorMax: {x: 0.5, y: 0.5} + m_AnchoredPosition: {x: 0, y: -147} + m_SizeDelta: {x: 160, y: 30} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!114 &1356883402 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1356883400} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 4e29b1a8efbd4b44bb3f3716e73f07ff, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Navigation: + m_Mode: 3 + m_WrapAround: 0 + m_SelectOnUp: {fileID: 0} + m_SelectOnDown: {fileID: 0} + m_SelectOnLeft: {fileID: 0} + m_SelectOnRight: {fileID: 0} + m_Transition: 1 + m_Colors: + m_NormalColor: {r: 1, g: 1, b: 1, a: 1} + m_HighlightedColor: {r: 0.9607843, g: 0.9607843, b: 0.9607843, a: 1} + m_PressedColor: {r: 0.78431374, g: 0.78431374, b: 0.78431374, a: 1} + m_SelectedColor: {r: 0.9607843, g: 0.9607843, b: 0.9607843, a: 1} + m_DisabledColor: {r: 0.78431374, g: 0.78431374, b: 0.78431374, a: 0.5019608} + m_ColorMultiplier: 1 + m_FadeDuration: 0.1 + m_SpriteState: + m_HighlightedSprite: {fileID: 0} + m_PressedSprite: {fileID: 0} + m_SelectedSprite: {fileID: 0} + m_DisabledSprite: {fileID: 0} + m_AnimationTriggers: + m_NormalTrigger: Normal + m_HighlightedTrigger: Highlighted + m_PressedTrigger: Pressed + m_SelectedTrigger: Highlighted + m_DisabledTrigger: Disabled + m_Interactable: 1 + m_TargetGraphic: {fileID: 1356883403} + m_OnClick: + m_PersistentCalls: + m_Calls: + - m_Target: {fileID: 1636198019} + m_TargetAssemblyTypeName: + m_MethodName: DOPlay + m_Mode: 1 + m_Arguments: + m_ObjectArgument: {fileID: 0} + m_ObjectArgumentAssemblyTypeName: UnityEngine.Object, UnityEngine + m_IntArgument: 0 + m_FloatArgument: 0 + m_StringArgument: + m_BoolArgument: 0 + m_CallState: 2 +--- !u!114 &1356883403 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1356883400} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: fe87c0e1cc204ed48ad3b37840f39efc, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 1, g: 1, b: 1, a: 1} + m_RaycastTarget: 1 + m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0} + m_Maskable: 1 + m_OnCullStateChanged: + m_PersistentCalls: + m_Calls: [] + m_Sprite: {fileID: 10905, guid: 0000000000000000f000000000000000, type: 0} + m_Type: 1 + m_PreserveAspect: 0 + m_FillCenter: 1 + m_FillMethod: 4 + m_FillAmount: 1 + m_FillClockwise: 1 + m_FillOrigin: 0 + m_UseSpriteMesh: 0 + m_PixelsPerUnitMultiplier: 1 +--- !u!222 &1356883404 +CanvasRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1356883400} + m_CullTransparentMesh: 1 +--- !u!1 &1636198018 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1636198022} + - component: {fileID: 1636198021} + - component: {fileID: 1636198020} + - component: {fileID: 1636198019} + m_Layer: 5 + m_Name: Logo (starts animations w events) + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!114 &1636198019 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1636198018} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 4d0390bd8b8ffd640b34fe25065ff1df, type: 3} + m_Name: + m_EditorClassIdentifier: + updateType: 0 + isSpeedBased: 0 + hasOnStart: 0 + hasOnPlay: 0 + hasOnUpdate: 0 + hasOnStepComplete: 0 + hasOnComplete: 1 + hasOnTweenCreated: 0 + hasOnRewind: 0 + onStart: + m_PersistentCalls: + m_Calls: [] + onPlay: + m_PersistentCalls: + m_Calls: [] + onUpdate: + m_PersistentCalls: + m_Calls: [] + onStepComplete: + m_PersistentCalls: + m_Calls: [] + onComplete: + m_PersistentCalls: + m_Calls: + - m_Target: {fileID: 990238546} + m_TargetAssemblyTypeName: + m_MethodName: DOPlay + m_Mode: 1 + m_Arguments: + m_ObjectArgument: {fileID: 0} + m_ObjectArgumentAssemblyTypeName: UnityEngine.Object, UnityEngine + m_IntArgument: 0 + m_FloatArgument: 0 + m_StringArgument: + m_BoolArgument: 0 + m_CallState: 2 + - m_Target: {fileID: 118309273} + m_TargetAssemblyTypeName: + m_MethodName: DOPlay + m_Mode: 1 + m_Arguments: + m_ObjectArgument: {fileID: 0} + m_ObjectArgumentAssemblyTypeName: UnityEngine.Object, UnityEngine + m_IntArgument: 0 + m_FloatArgument: 0 + m_StringArgument: + m_BoolArgument: 0 + m_CallState: 2 + - m_Target: {fileID: 1323952360} + m_TargetAssemblyTypeName: + m_MethodName: DOPlay + m_Mode: 1 + m_Arguments: + m_ObjectArgument: {fileID: 0} + m_ObjectArgumentAssemblyTypeName: UnityEngine.Object, UnityEngine + m_IntArgument: 0 + m_FloatArgument: 0 + m_StringArgument: + m_BoolArgument: 0 + m_CallState: 2 + onTweenCreated: + m_PersistentCalls: + m_Calls: [] + onRewind: + m_PersistentCalls: + m_Calls: [] + targetIsSelf: 1 + targetGO: {fileID: 0} + tweenTargetIsTargetGO: 1 + delay: 0 + duration: 1 + easeType: 5 + easeCurve: + serializedVersion: 2 + m_Curve: + - serializedVersion: 3 + time: 0 + value: 0 + inSlope: 0 + outSlope: 0 + tangentMode: 0 + weightedMode: 0 + inWeight: 0.33333334 + outWeight: 0.33333334 + - serializedVersion: 3 + time: 1 + value: 1 + inSlope: 0 + outSlope: 0 + tangentMode: 0 + weightedMode: 0 + inWeight: 0.33333334 + outWeight: 0.33333334 + m_PreInfinity: 2 + m_PostInfinity: 2 + m_RotationOrder: 4 + loopType: 0 + loops: 1 + id: + isRelative: 0 + isFrom: 0 + isIndependentUpdate: 0 + autoKill: 1 + isActive: 1 + isValid: 1 + target: {fileID: 1636198020} + animationType: 7 + targetType: 0 + forcedTargetType: 0 + autoPlay: 0 + useTargetAsV3: 0 + endValueFloat: 0 + endValueV3: {x: 0, y: 0, z: 0} + endValueV2: {x: 0, y: 0} + endValueColor: {r: 1, g: 1, b: 1, a: 1} + endValueString: + endValueRect: + serializedVersion: 2 + x: 0 + y: 0 + width: 0 + height: 0 + endValueTransform: {fileID: 0} + optionalBool0: 0 + optionalFloat0: 0 + optionalInt0: 0 + optionalRotationMode: 0 + optionalScrambleMode: 0 + optionalString: +--- !u!114 &1636198020 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1636198018} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: fe87c0e1cc204ed48ad3b37840f39efc, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 1, g: 1, b: 1, a: 1} + m_RaycastTarget: 1 + m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0} + m_Maskable: 1 + m_OnCullStateChanged: + m_PersistentCalls: + m_Calls: [] + m_Sprite: {fileID: 21300000, guid: 44a054df1702e39458b7072b08d0f212, type: 3} + m_Type: 0 + m_PreserveAspect: 1 + m_FillCenter: 1 + m_FillMethod: 4 + m_FillAmount: 1 + m_FillClockwise: 1 + m_FillOrigin: 0 + m_UseSpriteMesh: 0 + m_PixelsPerUnitMultiplier: 1 +--- !u!222 &1636198021 +CanvasRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1636198018} + m_CullTransparentMesh: 1 +--- !u!224 &1636198022 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1636198018} + 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: 1260203941} + m_RootOrder: 0 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0.5, y: 0.5} + m_AnchorMax: {x: 0.5, y: 0.5} + m_AnchoredPosition: {x: 0, y: 45} + m_SizeDelta: {x: 241, y: 320} + m_Pivot: {x: 0.5, y: 0.5} diff --git a/Assets/Demigiant/DOTweenPro Examples/DOTweenAnimation_Basics.unity.meta b/Assets/Demigiant/DOTweenPro Examples/DOTweenAnimation_Basics.unity.meta new file mode 100644 index 0000000..5ebfe59 --- /dev/null +++ b/Assets/Demigiant/DOTweenPro Examples/DOTweenAnimation_Basics.unity.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: 6a2ad353325ffe64983c28d69a8738f5 +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DOTweenPro Examples/DOTweenAnimation_BasicsSettings.lighting b/Assets/Demigiant/DOTweenPro Examples/DOTweenAnimation_BasicsSettings.lighting new file mode 100644 index 0000000..06dea5d --- /dev/null +++ b/Assets/Demigiant/DOTweenPro Examples/DOTweenAnimation_BasicsSettings.lighting @@ -0,0 +1,63 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!850595691 &4890085278179872738 +LightingSettings: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_Name: DOTweenAnimation_BasicsSettings + serializedVersion: 3 + m_GIWorkflowMode: 1 + m_EnableBakedLightmaps: 1 + m_EnableRealtimeLightmaps: 0 + m_RealtimeEnvironmentLighting: 1 + m_BounceScale: 1 + m_AlbedoBoost: 1 + m_IndirectOutputScale: 1 + m_UsingShadowmask: 0 + m_BakeBackend: 0 + m_LightmapMaxSize: 1024 + m_BakeResolution: 50 + m_Padding: 2 + m_TextureCompression: 0 + m_AO: 1 + m_AOMaxDistance: 1 + m_CompAOExponent: 1 + m_CompAOExponentDirect: 0 + m_ExtractAO: 0 + m_MixedBakeMode: 1 + m_LightmapsBakeMode: 1 + m_FilterMode: 1 + m_LightmapParameters: {fileID: 15204, guid: 0000000000000000f000000000000000, type: 0} + m_ExportTrainingData: 0 + m_TrainingDataDestination: TrainingData + m_RealtimeResolution: 1 + m_ForceWhiteAlbedo: 0 + m_ForceUpdates: 0 + m_FinalGather: 0 + m_FinalGatherRayCount: 256 + m_FinalGatherFiltering: 1 + m_PVRCulling: 1 + m_PVRSampling: 1 + m_PVRDirectSampleCount: 32 + m_PVRSampleCount: 512 + m_PVREnvironmentSampleCount: 512 + m_PVREnvironmentReferencePointCount: 2048 + m_LightProbeSampleCountMultiplier: 4 + m_PVRBounces: 2 + m_PVRMinBounces: 2 + m_PVREnvironmentMIS: 0 + m_PVRFilteringMode: 0 + m_PVRDenoiserTypeDirect: 0 + m_PVRDenoiserTypeIndirect: 0 + m_PVRDenoiserTypeAO: 0 + m_PVRFilterTypeDirect: 0 + m_PVRFilterTypeIndirect: 0 + m_PVRFilterTypeAO: 0 + m_PVRFilteringGaussRadiusDirect: 1 + m_PVRFilteringGaussRadiusIndirect: 5 + m_PVRFilteringGaussRadiusAO: 2 + m_PVRFilteringAtrousPositionSigmaDirect: 0.5 + m_PVRFilteringAtrousPositionSigmaIndirect: 2 + m_PVRFilteringAtrousPositionSigmaAO: 1 diff --git a/Assets/Demigiant/DOTweenPro Examples/DOTweenAnimation_BasicsSettings.lighting.meta b/Assets/Demigiant/DOTweenPro Examples/DOTweenAnimation_BasicsSettings.lighting.meta new file mode 100644 index 0000000..4452a09 --- /dev/null +++ b/Assets/Demigiant/DOTweenPro Examples/DOTweenAnimation_BasicsSettings.lighting.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 5e22310a645f7bd4ab6357d40c9f33fa +NativeFormatImporter: + externalObjects: {} + mainObjectFileID: 4890085278179872738 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DOTweenPro Examples/DOTweenPath.unity b/Assets/Demigiant/DOTweenPro Examples/DOTweenPath.unity new file mode 100644 index 0000000..11408ec --- /dev/null +++ b/Assets/Demigiant/DOTweenPro Examples/DOTweenPath.unity @@ -0,0 +1,1581 @@ +%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.2, g: 0.2, b: 0.2, a: 1} + m_AmbientEquatorColor: {r: 0.2, g: 0.2, b: 0.2, a: 1} + m_AmbientGroundColor: {r: 0.2, g: 0.2, b: 0.2, 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 &4 +LightmapSettings: + m_ObjectHideFlags: 0 + serializedVersion: 12 + m_GIWorkflowMode: 1 + m_GISettings: + serializedVersion: 2 + m_BounceScale: 1 + m_IndirectOutputScale: 1 + m_AlbedoBoost: 1 + m_EnvironmentLightingMode: 0 + m_EnableBakedLightmaps: 1 + m_EnableRealtimeLightmaps: 0 + m_LightmapEditorSettings: + serializedVersion: 12 + m_Resolution: 1 + m_BakeResolution: 50 + m_AtlasSize: 1024 + m_AO: 1 + m_AOMaxDistance: 1 + m_CompAOExponent: 1 + m_CompAOExponentDirect: 0 + m_ExtractAmbientOcclusion: 0 + m_Padding: 2 + m_LightmapParameters: {fileID: 0} + m_LightmapsBakeMode: 1 + m_TextureCompression: 0 + m_FinalGather: 0 + m_FinalGatherFiltering: 1 + m_FinalGatherRayCount: 256 + m_ReflectionCompression: 2 + m_MixedBakeMode: 1 + m_BakeBackend: 0 + m_PVRSampling: 1 + m_PVRDirectSampleCount: 32 + m_PVRSampleCount: 512 + m_PVRBounces: 2 + m_PVREnvironmentSampleCount: 512 + m_PVREnvironmentReferencePointCount: 2048 + m_PVRFilteringMode: 0 + m_PVRDenoiserTypeDirect: 0 + m_PVRDenoiserTypeIndirect: 0 + m_PVRDenoiserTypeAO: 0 + m_PVRFilterTypeDirect: 0 + m_PVRFilterTypeIndirect: 0 + m_PVRFilterTypeAO: 0 + m_PVREnvironmentMIS: 0 + m_PVRCulling: 1 + m_PVRFilteringGaussRadiusDirect: 1 + m_PVRFilteringGaussRadiusIndirect: 5 + m_PVRFilteringGaussRadiusAO: 2 + m_PVRFilteringAtrousPositionSigmaDirect: 0.5 + m_PVRFilteringAtrousPositionSigmaIndirect: 2 + m_PVRFilteringAtrousPositionSigmaAO: 1 + m_ExportTrainingData: 0 + m_TrainingDataDestination: TrainingData + m_LightProbeSampleCountMultiplier: 4 + m_LightingDataAsset: {fileID: 0} + m_LightingSettings: {fileID: 4890085278179872738, guid: 34ca5be95e0dca3489f5c662ce26a862, type: 2} +--- !u!196 &5 +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.16666666 + manualTileSize: 0 + tileSize: 256 + accuratePlacement: 0 + maxJobWorkers: 0 + preserveTilesOutsideBounds: 0 + debug: + m_Flags: 0 + m_NavMeshData: {fileID: 0} +--- !u!1 &118309267 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 118309271} + - component: {fileID: 118309270} + - component: {fileID: 118309268} + - component: {fileID: 118309269} + m_Layer: 0 + m_Name: Cube A (w path) + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!23 &118309268 +MeshRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 118309267} + m_Enabled: 1 + m_CastShadows: 1 + m_ReceiveShadows: 1 + m_DynamicOccludee: 1 + m_MotionVectors: 1 + m_LightProbeUsage: 0 + m_ReflectionProbeUsage: 1 + m_RayTracingMode: 2 + m_RayTraceProcedural: 0 + m_RenderingLayerMask: 1 + m_RendererPriority: 0 + m_Materials: + - {fileID: 10302, 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_ReceiveGI: 1 + m_PreserveUVs: 0 + m_IgnoreNormalsForChartDetection: 0 + m_ImportantGI: 0 + m_StitchLightmapSeams: 1 + m_SelectedEditorRenderState: 3 + m_MinimumChartSize: 4 + m_AutoUVMaxDistance: 0.5 + m_AutoUVMaxAngle: 89 + m_LightmapParameters: {fileID: 0} + m_SortingLayerID: 0 + m_SortingLayer: 0 + m_SortingOrder: 0 + m_AdditionalVertexStreams: {fileID: 0} +--- !u!114 &118309269 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 118309267} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: -333801856, guid: aa0b1eebb5db27a419fa4564bbe5c9c5, type: 3} + m_Name: + m_EditorClassIdentifier: + updateType: 0 + isSpeedBased: 0 + hasOnStart: 0 + hasOnPlay: 0 + hasOnUpdate: 0 + hasOnStepComplete: 0 + hasOnComplete: 1 + hasOnTweenCreated: 0 + hasOnRewind: 0 + onStart: + m_PersistentCalls: + m_Calls: [] + onPlay: + m_PersistentCalls: + m_Calls: [] + onUpdate: + m_PersistentCalls: + m_Calls: [] + onStepComplete: + m_PersistentCalls: + m_Calls: [] + onComplete: + m_PersistentCalls: + m_Calls: + - m_Target: {fileID: 1087750405} + m_TargetAssemblyTypeName: + m_MethodName: DOPlay + m_Mode: 1 + m_Arguments: + m_ObjectArgument: {fileID: 0} + m_ObjectArgumentAssemblyTypeName: UnityEngine.Object, UnityEngine + m_IntArgument: 0 + m_FloatArgument: 0 + m_StringArgument: + m_BoolArgument: 0 + m_CallState: 2 + onTweenCreated: + m_PersistentCalls: + m_Calls: [] + onRewind: + m_PersistentCalls: + m_Calls: [] + delay: 0 + duration: 3 + easeType: 6 + easeCurve: + serializedVersion: 2 + m_Curve: + - serializedVersion: 3 + time: 0 + value: 0 + inSlope: 0 + outSlope: 0 + tangentMode: 0 + weightedMode: 0 + inWeight: 0.33333334 + outWeight: 0.33333334 + - serializedVersion: 3 + time: 1 + value: 1 + inSlope: 0 + outSlope: 0 + tangentMode: 0 + weightedMode: 0 + inWeight: 0.33333334 + outWeight: 0.33333334 + m_PreInfinity: 2 + m_PostInfinity: 2 + m_RotationOrder: 4 + loops: 1 + id: + loopType: 0 + orientType: 0 + lookAtTransform: {fileID: 0} + lookAtPosition: {x: 0, y: 0, z: 0} + lookAhead: 0.01 + autoPlay: 0 + autoKill: 1 + relative: 0 + isLocal: 0 + isClosedPath: 1 + pathResolution: 10 + pathMode: 1 + lockRotation: 0 + assignForwardAndUp: 0 + forwardDirection: {x: 0, y: 0, z: 1} + upDirection: {x: 0, y: 1, z: 0} + tweenRigidbody: 0 + wps: + - {x: 3.8321667, y: 6.9544535, z: 0} + - {x: -6.0542445, y: 9.465288, z: 0} + - {x: -12.069765, y: 6.1698112, z: 0} + - {x: -12.069786, y: -0.2641964, z: 0} + - {x: -6.368099, y: -4.187376, z: 0} + fullWps: [] + path: + wpLengths: + - 0 + - 9.359136 + - 10.405018 + - 7.102792 + - 6.6672983 + - 7.1915474 + - 11.289525 + type: 1 + subdivisionsXSegment: 10 + subdivisions: 70 + wps: + - {x: 4.45, y: -1.83, z: 0} + - {x: 3.8321667, y: 6.9544535, z: 0} + - {x: -6.0542445, y: 9.465288, z: 0} + - {x: -12.069765, y: 6.1698112, z: 0} + - {x: -12.069786, y: -0.2641964, z: 0} + - {x: -6.368099, y: -4.187376, z: 0} + - {x: 4.45, y: -1.83, z: 0} + controlPoints: + - a: {x: -6.368099, y: -4.187376, z: 0} + b: {x: 0, y: 0, z: 0} + - a: {x: 3.8321667, y: 6.9544535, z: 0} + b: {x: 0, y: 0, z: 0} + length: 52.02238 + isFinalized: 1 + timesTable: + - 0.014285714 + - 0.028571429 + - 0.042857144 + - 0.057142857 + - 0.071428575 + - 0.08571429 + - 0.1 + - 0.114285715 + - 0.12857144 + - 0.14285715 + - 0.15714286 + - 0.17142858 + - 0.18571429 + - 0.2 + - 0.21428572 + - 0.22857143 + - 0.24285714 + - 0.25714287 + - 0.27142859 + - 0.2857143 + - 0.3 + - 0.31428573 + - 0.32857144 + - 0.34285715 + - 0.35714287 + - 0.37142858 + - 0.3857143 + - 0.4 + - 0.41428572 + - 0.42857143 + - 0.44285715 + - 0.45714286 + - 0.47142857 + - 0.4857143 + - 0.5 + - 0.51428574 + - 0.5285714 + - 0.54285717 + - 0.55714285 + - 0.5714286 + - 0.5857143 + - 0.6 + - 0.6142857 + - 0.62857145 + - 0.64285713 + - 0.6571429 + - 0.67142856 + - 0.6857143 + - 0.7 + - 0.71428573 + - 0.7285714 + - 0.74285716 + - 0.75714284 + - 0.7714286 + - 0.78571427 + - 0.8 + - 0.8142857 + - 0.82857144 + - 0.8428571 + - 0.85714287 + - 0.87142855 + - 0.8857143 + - 0.9 + - 0.9142857 + - 0.92857146 + - 0.94285715 + - 0.9571429 + - 0.9714286 + - 0.9857143 + - 1 + lengthsTable: + - 0.66792893 + - 1.3899281 + - 2.16896 + - 2.9980419 + - 3.8644814 + - 4.752426 + - 5.6444182 + - 6.5224686 + - 7.368998 + - 8.167948 + - 8.906464 + - 9.58573 + - 10.313842 + - 11.125577 + - 12.012393 + - 12.959278 + - 13.947668 + - 14.956963 + - 15.965341 + - 16.950247 + - 17.888689 + - 18.75748 + - 19.533484 + - 20.220243 + - 20.891918 + - 21.555 + - 22.208927 + - 22.852415 + - 23.483595 + - 24.100157 + - 24.699495 + - 25.278862 + - 25.83552 + - 26.366951 + - 26.8711 + - 27.376375 + - 27.912098 + - 28.475262 + - 29.060778 + - 29.66227 + - 30.272577 + - 30.884148 + - 31.48931 + - 32.080574 + - 32.650936 + - 33.194313 + - 33.709743 + - 34.240025 + - 34.79521 + - 35.371506 + - 35.965523 + - 36.574467 + - 37.19625 + - 37.829685 + - 38.474625 + - 39.132145 + - 39.804657 + - 40.496033 + - 41.23852 + - 42.10978 + - 43.088493 + - 44.145332 + - 45.25077 + - 46.375446 + - 47.49042 + - 48.567577 + - 49.58027 + - 50.50447 + - 51.32128 + - 52.02238 + inspectorMode: 0 + pathType: 1 + handlesType: 0 + livePreview: 1 + handlesDrawMode: 0 + perspectiveHandleSize: 0.5 + showIndexes: 1 + showWpLength: 0 + pathColor: {r: 1, g: 1, b: 1, a: 0.5} + lastSrcPosition: {x: 4.45, y: -1.83, z: 0} + wpsDropdown: 0 + dropToFloorOffset: 0 +--- !u!33 &118309270 +MeshFilter: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 118309267} + m_Mesh: {fileID: 10202, guid: 0000000000000000e000000000000000, type: 0} +--- !u!4 &118309271 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 118309267} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: 4.45, y: -1.83, z: 0} + m_LocalScale: {x: 1, y: 1, z: 1} + m_Children: [] + m_Father: {fileID: 0} + m_RootOrder: 2 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!1 &848136767 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 848136772} + - component: {fileID: 848136771} + - component: {fileID: 848136769} + - component: {fileID: 848136768} + 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 &848136768 +AudioListener: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 848136767} + m_Enabled: 1 +--- !u!124 &848136769 +Behaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 848136767} + m_Enabled: 1 +--- !u!20 &848136771 +Camera: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 848136767} + m_Enabled: 1 + serializedVersion: 2 + m_ClearFlags: 1 + m_BackGroundColor: {r: 0.16176468, g: 0.16176468, b: 0.16176468, a: 0.019607844} + m_projectionMatrixMode: 1 + m_GateFitMode: 2 + m_FOVAxisMode: 0 + 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: 0 + 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: 3 + m_HDR: 0 + m_AllowMSAA: 1 + m_AllowDynamicResolution: 0 + m_ForceIntoRT: 0 + m_OcclusionCulling: 1 + m_StereoConvergence: 10 + m_StereoSeparation: 0.022 +--- !u!4 &848136772 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 848136767} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: 0, y: 0, z: -30} + 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 &970591913 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 970591914} + - component: {fileID: 970591916} + - component: {fileID: 970591915} + m_Layer: 5 + m_Name: Text + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!224 &970591914 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 970591913} + 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: 1356883401} + m_RootOrder: 0 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0, y: 0} + m_AnchorMax: {x: 1, y: 1} + m_AnchoredPosition: {x: 0, y: 0} + m_SizeDelta: {x: 0, y: 0} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!114 &970591915 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 970591913} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 5f7201a12d95ffc409449d95f23cf332, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 0.196, g: 0.196, b: 0.196, a: 1} + m_RaycastTarget: 1 + m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0} + m_Maskable: 1 + m_OnCullStateChanged: + m_PersistentCalls: + m_Calls: [] + m_FontData: + m_Font: {fileID: 10102, guid: 0000000000000000e000000000000000, type: 0} + m_FontSize: 14 + m_FontStyle: 0 + m_BestFit: 0 + m_MinSize: 10 + m_MaxSize: 40 + m_Alignment: 4 + m_AlignByGeometry: 0 + m_RichText: 1 + m_HorizontalOverflow: 0 + m_VerticalOverflow: 0 + m_LineSpacing: 1 + m_Text: PLAY +--- !u!222 &970591916 +CanvasRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 970591913} + m_CullTransparentMesh: 1 +--- !u!1 &1053889438 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1053889442} + - component: {fileID: 1053889441} + - component: {fileID: 1053889440} + - component: {fileID: 1053889439} + m_Layer: 0 + m_Name: EventSystem + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!114 &1053889439 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1053889438} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 2d49b7c1bcd2e07499844da127be038d, type: 3} + m_Name: + m_EditorClassIdentifier: + m_ForceModuleActive: 0 +--- !u!114 &1053889440 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1053889438} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 4f231c4fb786f3946a6b90b886c48677, 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 &1053889441 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1053889438} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 76c392e42b5098c458856cdf6ecaaaa1, type: 3} + m_Name: + m_EditorClassIdentifier: + m_FirstSelected: {fileID: 0} + m_sendNavigationEvents: 1 + m_DragThreshold: 5 +--- !u!4 &1053889442 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1053889438} + 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: 5 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!1 &1087750404 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1087750408} + - component: {fileID: 1087750407} + - component: {fileID: 1087750406} + - component: {fileID: 1087750405} + m_Layer: 0 + m_Name: Cube B (animated after Cube A) + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!114 &1087750405 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1087750404} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: -333801856, guid: aa0b1eebb5db27a419fa4564bbe5c9c5, type: 3} + m_Name: + m_EditorClassIdentifier: + updateType: 0 + isSpeedBased: 0 + hasOnStart: 0 + hasOnPlay: 0 + hasOnUpdate: 0 + hasOnStepComplete: 0 + hasOnComplete: 0 + hasOnTweenCreated: 0 + hasOnRewind: 0 + onStart: + m_PersistentCalls: + m_Calls: [] + onPlay: + m_PersistentCalls: + m_Calls: [] + onUpdate: + m_PersistentCalls: + m_Calls: [] + onStepComplete: + m_PersistentCalls: + m_Calls: [] + onComplete: + m_PersistentCalls: + m_Calls: [] + onTweenCreated: + m_PersistentCalls: + m_Calls: [] + onRewind: + m_PersistentCalls: + m_Calls: [] + delay: 0 + duration: 3 + easeType: 1 + easeCurve: + serializedVersion: 2 + m_Curve: + - serializedVersion: 3 + time: 0 + value: 0 + inSlope: 0 + outSlope: 0 + tangentMode: 0 + weightedMode: 0 + inWeight: 0.33333334 + outWeight: 0.33333334 + - serializedVersion: 3 + time: 1 + value: 1 + inSlope: 0 + outSlope: 0 + tangentMode: 0 + weightedMode: 0 + inWeight: 0.33333334 + outWeight: 0.33333334 + m_PreInfinity: 2 + m_PostInfinity: 2 + m_RotationOrder: 4 + loops: -1 + id: + loopType: 0 + orientType: 0 + lookAtTransform: {fileID: 0} + lookAtPosition: {x: 0, y: 0, z: 0} + lookAhead: 0.01 + autoPlay: 0 + autoKill: 1 + relative: 1 + isLocal: 0 + isClosedPath: 1 + pathResolution: 10 + pathMode: 1 + lockRotation: 0 + assignForwardAndUp: 0 + forwardDirection: {x: 0, y: 0, z: 1} + upDirection: {x: 0, y: 1, z: 0} + tweenRigidbody: 0 + wps: + - {x: 13.417454, y: 2.978077, z: 0} + - {x: 9.493597, y: 8.510473, z: 0} + - {x: -3.3649445, y: 5.5603714, z: 0} + - {x: -13.000723, y: 12.019701, z: 0} + - {x: -19.387083, y: 4.5597005, z: 0} + - {x: -15.279156, y: -3.646319, z: 0} + - {x: -4.1231623, y: -1.0233588, z: 0} + - {x: 3.7979867, y: -4.5040193, z: 0} + fullWps: [] + path: + wpLengths: + - 0 + - 5.8644567 + - 7.2802324 + - 13.301847 + - 11.81175 + - 10.301735 + - 9.680841 + - 11.593836 + - 8.754475 + - 7.309784 + type: 1 + subdivisionsXSegment: 10 + subdivisions: 100 + wps: + - {x: 10.45, y: -1.83, z: 0} + - {x: 13.417454, y: 2.978077, z: 0} + - {x: 9.493597, y: 8.510473, z: 0} + - {x: -3.3649445, y: 5.5603714, z: 0} + - {x: -13.000723, y: 12.019701, z: 0} + - {x: -19.387083, y: 4.5597005, z: 0} + - {x: -15.279156, y: -3.646319, z: 0} + - {x: -4.1231623, y: -1.0233588, z: 0} + - {x: 3.7979867, y: -4.5040193, z: 0} + - {x: 10.45, y: -1.83, z: 0} + controlPoints: + - a: {x: 3.7979867, y: -4.5040193, z: 0} + b: {x: 0, y: 0, z: 0} + - a: {x: 13.417454, y: 2.978077, z: 0} + b: {x: 0, y: 0, z: 0} + length: 85.91056 + isFinalized: 1 + timesTable: + - 0.01 + - 0.02 + - 0.03 + - 0.04 + - 0.049999997 + - 0.06 + - 0.07 + - 0.08 + - 0.089999996 + - 0.099999994 + - 0.11 + - 0.12 + - 0.13 + - 0.14 + - 0.14999999 + - 0.16 + - 0.17 + - 0.17999999 + - 0.19 + - 0.19999999 + - 0.21 + - 0.22 + - 0.22999999 + - 0.24 + - 0.25 + - 0.26 + - 0.26999998 + - 0.28 + - 0.29 + - 0.29999998 + - 0.31 + - 0.32 + - 0.32999998 + - 0.34 + - 0.35 + - 0.35999998 + - 0.37 + - 0.38 + - 0.39 + - 0.39999998 + - 0.41 + - 0.42 + - 0.42999998 + - 0.44 + - 0.45 + - 0.45999998 + - 0.47 + - 0.48 + - 0.48999998 + - 0.5 + - 0.51 + - 0.52 + - 0.53 + - 0.53999996 + - 0.55 + - 0.56 + - 0.57 + - 0.58 + - 0.59 + - 0.59999996 + - 0.61 + - 0.62 + - 0.63 + - 0.64 + - 0.65 + - 0.65999997 + - 0.66999996 + - 0.68 + - 0.69 + - 0.7 + - 0.71 + - 0.71999997 + - 0.72999996 + - 0.74 + - 0.75 + - 0.76 + - 0.77 + - 0.78 + - 0.78999996 + - 0.79999995 + - 0.81 + - 0.82 + - 0.83 + - 0.84 + - 0.84999996 + - 0.85999995 + - 0.87 + - 0.88 + - 0.89 + - 0.9 + - 0.90999997 + - 0.91999996 + - 0.93 + - 0.94 + - 0.95 + - 0.96 + - 0.96999997 + - 0.97999996 + - 0.98999995 + - 1 + lengthsTable: + - 0.5545968 + - 1.1175883 + - 1.6830537 + - 2.245447 + - 2.7997518 + - 3.3416884 + - 3.867998 + - 4.376838 + - 4.868309 + - 5.3450947 + - 5.813135 + - 6.311367 + - 6.877433 + - 7.495066 + - 8.148528 + - 8.823632 + - 9.508459 + - 10.194385 + - 10.877503 + - 11.560418 + - 12.254057 + - 12.978595 + - 13.783311 + - 14.741959 + - 15.848983 + - 17.077965 + - 18.394625 + - 19.761522 + - 21.140495 + - 22.494476 + - 23.78951 + - 24.997858 + - 26.103634 + - 27.136875 + - 28.20907 + - 29.343433 + - 30.531721 + - 31.750658 + - 32.96895 + - 34.151752 + - 35.26419 + - 36.275455 + - 37.165974 + - 37.94238 + - 38.672184 + - 39.461693 + - 40.331173 + - 41.275455 + - 42.278408 + - 43.318016 + - 44.36911 + - 45.404976 + - 46.39841 + - 47.322807 + - 48.15364 + - 48.891544 + - 49.678425 + - 50.534695 + - 51.444313 + - 52.38865 + - 53.348053 + - 54.30292 + - 55.23473 + - 56.12729 + - 56.968613 + - 57.754013 + - 58.495777 + - 59.294735 + - 60.205452 + - 61.226448 + - 62.33766 + - 63.510315 + - 64.71169 + - 65.907745 + - 67.06497 + - 68.15262 + - 69.14602 + - 70.03488 + - 70.87562 + - 71.70776 + - 72.54151 + - 73.377945 + - 74.21172 + - 75.033615 + - 75.83277 + - 76.59903 + - 77.325615 + - 78.01288 + - 78.67338 + - 79.33375 + - 80.00281 + - 80.68108 + - 81.366684 + - 82.05582 + - 82.74328 + - 83.422775 + - 84.087204 + - 84.728836 + - 85.33948 + - 85.91056 + inspectorMode: 0 + pathType: 1 + handlesType: 0 + livePreview: 1 + handlesDrawMode: 0 + perspectiveHandleSize: 0.5 + showIndexes: 1 + showWpLength: 0 + pathColor: {r: 1, g: 1, b: 1, a: 0.5} + lastSrcPosition: {x: 10.45, y: -1.83, z: 0} + wpsDropdown: 0 + dropToFloorOffset: 0 +--- !u!23 &1087750406 +MeshRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1087750404} + m_Enabled: 1 + m_CastShadows: 1 + m_ReceiveShadows: 1 + m_DynamicOccludee: 1 + m_MotionVectors: 1 + m_LightProbeUsage: 0 + m_ReflectionProbeUsage: 1 + m_RayTracingMode: 2 + m_RayTraceProcedural: 0 + m_RenderingLayerMask: 1 + m_RendererPriority: 0 + m_Materials: + - {fileID: 10302, 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_ReceiveGI: 1 + m_PreserveUVs: 0 + m_IgnoreNormalsForChartDetection: 0 + m_ImportantGI: 0 + m_StitchLightmapSeams: 1 + m_SelectedEditorRenderState: 3 + m_MinimumChartSize: 4 + m_AutoUVMaxDistance: 0.5 + m_AutoUVMaxAngle: 89 + m_LightmapParameters: {fileID: 0} + m_SortingLayerID: 0 + m_SortingLayer: 0 + m_SortingOrder: 0 + m_AdditionalVertexStreams: {fileID: 0} +--- !u!33 &1087750407 +MeshFilter: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1087750404} + m_Mesh: {fileID: 10202, guid: 0000000000000000e000000000000000, type: 0} +--- !u!4 &1087750408 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1087750404} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: 10.45, y: -1.83, 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 &1127963255 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1127963256} + - component: {fileID: 1127963258} + - component: {fileID: 1127963257} + m_Layer: 5 + m_Name: Info + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!224 &1127963256 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1127963255} + 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: 1260203941} + m_RootOrder: 1 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0.5, y: 0.5} + m_AnchorMax: {x: 0.5, y: 0.5} + m_AnchoredPosition: {x: 0, y: -186} + m_SizeDelta: {x: 300, y: 30} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!114 &1127963257 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1127963255} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 5f7201a12d95ffc409449d95f23cf332, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 1, g: 1, b: 1, a: 1} + m_RaycastTarget: 1 + m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0} + m_Maskable: 1 + m_OnCullStateChanged: + m_PersistentCalls: + m_Calls: [] + m_FontData: + m_Font: {fileID: 10102, guid: 0000000000000000e000000000000000, type: 0} + m_FontSize: 14 + m_FontStyle: 0 + m_BestFit: 0 + m_MinSize: 10 + m_MaxSize: 40 + m_Alignment: 1 + m_AlignByGeometry: 0 + m_RichText: 1 + m_HorizontalOverflow: 0 + m_VerticalOverflow: 1 + m_LineSpacing: 1 + m_Text: The PLAY button starts Cube A path animation. When that is complete, it + will start the other cube's animation (thanks to the Event created in Cube A's + DOTweenPath Component) +--- !u!222 &1127963258 +CanvasRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1127963255} + m_CullTransparentMesh: 1 +--- !u!1 &1242857378 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1242857380} + - component: {fileID: 1242857379} + m_Layer: 0 + m_Name: Directional light + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!108 &1242857379 +Light: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1242857378} + m_Enabled: 1 + serializedVersion: 10 + m_Type: 1 + m_Shape: 0 + m_Color: {r: 1, g: 1, b: 1, a: 1} + m_Intensity: 1 + m_Range: 10 + m_SpotAngle: 30 + m_InnerSpotAngle: 21.80208 + m_CookieSize: 10 + m_Shadows: + m_Type: 0 + m_Resolution: -1 + m_CustomResolution: -1 + m_Strength: 1 + m_Bias: 0.05 + m_NormalBias: 0.4 + m_NearPlane: 0.2 + m_CullingMatrixOverride: + e00: 1 + e01: 0 + e02: 0 + e03: 0 + e10: 0 + e11: 1 + e12: 0 + e13: 0 + e20: 0 + e21: 0 + e22: 1 + e23: 0 + e30: 0 + e31: 0 + e32: 0 + e33: 1 + m_UseCullingMatrixOverride: 0 + m_Cookie: {fileID: 0} + m_DrawHalo: 0 + m_Flare: {fileID: 0} + m_RenderMode: 0 + m_CullingMask: + serializedVersion: 2 + m_Bits: 4294967295 + m_RenderingLayerMask: 1 + m_Lightmapping: 1 + m_LightShadowCasterMode: 0 + m_AreaSize: {x: 1, y: 1} + m_BounceIntensity: 1 + m_ColorTemperature: 6570 + m_UseColorTemperature: 0 + m_BoundingSphereOverride: {x: 0, y: 0, z: 0, w: 0} + m_UseBoundingSphereOverride: 0 + m_UseViewFrustumForShadowCasterCull: 1 + m_ShadowRadius: 0 + m_ShadowAngle: 0 +--- !u!4 &1242857380 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1242857378} + m_LocalRotation: {x: 0.40821794, y: -0.23456973, z: 0.10938166, w: 0.8754261} + m_LocalPosition: {x: 0, y: 0, z: 0} + m_LocalScale: {x: 1, y: 0.99999994, z: 1} + m_Children: [] + m_Father: {fileID: 0} + m_RootOrder: 1 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!1 &1260203940 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1260203941} + - component: {fileID: 1260203944} + - component: {fileID: 1260203943} + - component: {fileID: 1260203942} + m_Layer: 5 + m_Name: Canvas + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!224 &1260203941 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1260203940} + 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: 1356883401} + - {fileID: 1127963256} + m_Father: {fileID: 0} + m_RootOrder: 4 + 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!114 &1260203942 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1260203940} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: dc42784cf147c0c48a680349fa168899, type: 3} + m_Name: + m_EditorClassIdentifier: + m_IgnoreReversedGraphics: 1 + m_BlockingObjects: 0 + m_BlockingMask: + serializedVersion: 2 + m_Bits: 4294967295 +--- !u!114 &1260203943 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1260203940} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 0cd44c1031e13a943bb63640046fad76, 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 + m_PresetInfoIsWorld: 0 +--- !u!223 &1260203944 +Canvas: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1260203940} + m_Enabled: 1 + serializedVersion: 3 + m_RenderMode: 0 + m_Camera: {fileID: 0} + m_PlaneDistance: 100 + m_PixelPerfect: 1 + m_ReceivesEvents: 1 + m_OverrideSorting: 0 + m_OverridePixelPerfect: 0 + m_SortingBucketNormalizedSize: 0 + m_AdditionalShaderChannelsFlag: 25 + m_SortingLayerID: 0 + m_SortingOrder: 0 + m_TargetDisplay: 0 +--- !u!1 &1356883400 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1356883401} + - component: {fileID: 1356883404} + - component: {fileID: 1356883403} + - component: {fileID: 1356883402} + m_Layer: 5 + m_Name: Button + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!224 &1356883401 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1356883400} + 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: + - {fileID: 970591914} + m_Father: {fileID: 1260203941} + m_RootOrder: 0 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0.5, y: 0.5} + m_AnchorMax: {x: 0.5, y: 0.5} + m_AnchoredPosition: {x: 0, y: -147} + m_SizeDelta: {x: 160, y: 30} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!114 &1356883402 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1356883400} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 4e29b1a8efbd4b44bb3f3716e73f07ff, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Navigation: + m_Mode: 3 + m_WrapAround: 0 + m_SelectOnUp: {fileID: 0} + m_SelectOnDown: {fileID: 0} + m_SelectOnLeft: {fileID: 0} + m_SelectOnRight: {fileID: 0} + m_Transition: 1 + m_Colors: + m_NormalColor: {r: 1, g: 1, b: 1, a: 1} + m_HighlightedColor: {r: 0.9607843, g: 0.9607843, b: 0.9607843, a: 1} + m_PressedColor: {r: 0.78431374, g: 0.78431374, b: 0.78431374, a: 1} + m_SelectedColor: {r: 0.9607843, g: 0.9607843, b: 0.9607843, a: 1} + m_DisabledColor: {r: 0.78431374, g: 0.78431374, b: 0.78431374, a: 0.5019608} + m_ColorMultiplier: 1 + m_FadeDuration: 0.1 + m_SpriteState: + m_HighlightedSprite: {fileID: 0} + m_PressedSprite: {fileID: 0} + m_SelectedSprite: {fileID: 0} + m_DisabledSprite: {fileID: 0} + m_AnimationTriggers: + m_NormalTrigger: Normal + m_HighlightedTrigger: Highlighted + m_PressedTrigger: Pressed + m_SelectedTrigger: Highlighted + m_DisabledTrigger: Disabled + m_Interactable: 1 + m_TargetGraphic: {fileID: 1356883403} + m_OnClick: + m_PersistentCalls: + m_Calls: + - m_Target: {fileID: 118309269} + m_TargetAssemblyTypeName: + m_MethodName: DOPlay + m_Mode: 1 + m_Arguments: + m_ObjectArgument: {fileID: 0} + m_ObjectArgumentAssemblyTypeName: UnityEngine.Object, UnityEngine + m_IntArgument: 0 + m_FloatArgument: 0 + m_StringArgument: + m_BoolArgument: 0 + m_CallState: 2 +--- !u!114 &1356883403 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1356883400} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: fe87c0e1cc204ed48ad3b37840f39efc, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 1, g: 1, b: 1, a: 1} + m_RaycastTarget: 1 + m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0} + m_Maskable: 1 + m_OnCullStateChanged: + m_PersistentCalls: + m_Calls: [] + m_Sprite: {fileID: 10905, guid: 0000000000000000f000000000000000, type: 0} + m_Type: 1 + m_PreserveAspect: 0 + m_FillCenter: 1 + m_FillMethod: 4 + m_FillAmount: 1 + m_FillClockwise: 1 + m_FillOrigin: 0 + m_UseSpriteMesh: 0 + m_PixelsPerUnitMultiplier: 1 +--- !u!222 &1356883404 +CanvasRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1356883400} + m_CullTransparentMesh: 1 diff --git a/Assets/Demigiant/DOTweenPro Examples/DOTweenPath.unity.meta b/Assets/Demigiant/DOTweenPro Examples/DOTweenPath.unity.meta new file mode 100644 index 0000000..f480ec1 --- /dev/null +++ b/Assets/Demigiant/DOTweenPro Examples/DOTweenPath.unity.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: a351b59ca54a0bc4083c35844da13a61 +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DOTweenPro Examples/DOTweenPathSettings.lighting b/Assets/Demigiant/DOTweenPro Examples/DOTweenPathSettings.lighting new file mode 100644 index 0000000..5e44e07 --- /dev/null +++ b/Assets/Demigiant/DOTweenPro Examples/DOTweenPathSettings.lighting @@ -0,0 +1,63 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!850595691 &4890085278179872738 +LightingSettings: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_Name: DOTweenPathSettings + serializedVersion: 3 + m_GIWorkflowMode: 1 + m_EnableBakedLightmaps: 1 + m_EnableRealtimeLightmaps: 0 + m_RealtimeEnvironmentLighting: 1 + m_BounceScale: 1 + m_AlbedoBoost: 1 + m_IndirectOutputScale: 1 + m_UsingShadowmask: 0 + m_BakeBackend: 0 + m_LightmapMaxSize: 1024 + m_BakeResolution: 50 + m_Padding: 2 + m_TextureCompression: 0 + m_AO: 1 + m_AOMaxDistance: 1 + m_CompAOExponent: 1 + m_CompAOExponentDirect: 0 + m_ExtractAO: 0 + m_MixedBakeMode: 1 + m_LightmapsBakeMode: 1 + m_FilterMode: 1 + m_LightmapParameters: {fileID: 15204, guid: 0000000000000000f000000000000000, type: 0} + m_ExportTrainingData: 0 + m_TrainingDataDestination: TrainingData + m_RealtimeResolution: 1 + m_ForceWhiteAlbedo: 0 + m_ForceUpdates: 0 + m_FinalGather: 0 + m_FinalGatherRayCount: 256 + m_FinalGatherFiltering: 1 + m_PVRCulling: 1 + m_PVRSampling: 1 + m_PVRDirectSampleCount: 32 + m_PVRSampleCount: 512 + m_PVREnvironmentSampleCount: 512 + m_PVREnvironmentReferencePointCount: 2048 + m_LightProbeSampleCountMultiplier: 4 + m_PVRBounces: 2 + m_PVRMinBounces: 2 + m_PVREnvironmentMIS: 0 + m_PVRFilteringMode: 0 + m_PVRDenoiserTypeDirect: 0 + m_PVRDenoiserTypeIndirect: 0 + m_PVRDenoiserTypeAO: 0 + m_PVRFilterTypeDirect: 0 + m_PVRFilterTypeIndirect: 0 + m_PVRFilterTypeAO: 0 + m_PVRFilteringGaussRadiusDirect: 1 + m_PVRFilteringGaussRadiusIndirect: 5 + m_PVRFilteringGaussRadiusAO: 2 + m_PVRFilteringAtrousPositionSigmaDirect: 0.5 + m_PVRFilteringAtrousPositionSigmaIndirect: 2 + m_PVRFilteringAtrousPositionSigmaAO: 1 diff --git a/Assets/Demigiant/DOTweenPro Examples/DOTweenPathSettings.lighting.meta b/Assets/Demigiant/DOTweenPro Examples/DOTweenPathSettings.lighting.meta new file mode 100644 index 0000000..4a21714 --- /dev/null +++ b/Assets/Demigiant/DOTweenPro Examples/DOTweenPathSettings.lighting.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 34ca5be95e0dca3489f5c662ce26a862 +NativeFormatImporter: + externalObjects: {} + mainObjectFileID: 4890085278179872738 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DOTweenPro Examples/Examples Assets.meta b/Assets/Demigiant/DOTweenPro Examples/Examples Assets.meta new file mode 100644 index 0000000..cb155cb --- /dev/null +++ b/Assets/Demigiant/DOTweenPro Examples/Examples Assets.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: bc383323f6b27ea4ab42a5fe7d7dbf06 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DOTweenPro Examples/Examples Assets/dotweenpro_logo.png b/Assets/Demigiant/DOTweenPro Examples/Examples Assets/dotweenpro_logo.png new file mode 100644 index 0000000..c6d8420 Binary files /dev/null and b/Assets/Demigiant/DOTweenPro Examples/Examples Assets/dotweenpro_logo.png differ diff --git a/Assets/Demigiant/DOTweenPro Examples/Examples Assets/dotweenpro_logo.png.meta b/Assets/Demigiant/DOTweenPro Examples/Examples Assets/dotweenpro_logo.png.meta new file mode 100644 index 0000000..be1b898 --- /dev/null +++ b/Assets/Demigiant/DOTweenPro Examples/Examples Assets/dotweenpro_logo.png.meta @@ -0,0 +1,96 @@ +fileFormatVersion: 2 +guid: 44a054df1702e39458b7072b08d0f212 +TextureImporter: + internalIDToNameTable: [] + externalObjects: {} + serializedVersion: 11 + mipmaps: + mipMapMode: 0 + enableMipMap: 1 + sRGBTexture: 1 + linearTexture: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + streamingMipmaps: 0 + streamingMipmapsPriority: 0 + vTOnly: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: -3 + maxTextureSize: 512 + textureSettings: + serializedVersion: 2 + filterMode: 1 + aniso: 16 + mipBias: 0 + wrapU: 1 + wrapV: 1 + wrapW: 1 + nPOTScale: 0 + lightmap: 0 + compressionQuality: 50 + spriteMode: 1 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spritePixelsToUnits: 100 + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spriteGenerateFallbackPhysicsShape: 1 + alphaUsage: 1 + alphaIsTransparency: 1 + spriteTessellationDetail: -1 + textureType: 8 + textureShape: 1 + singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + platformSettings: + - serializedVersion: 3 + buildTarget: DefaultTexturePlatform + maxTextureSize: 512 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 0 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + bones: [] + spriteID: 5e97eb03825dee720800000000000000 + internalID: 0 + vertices: [] + indices: + edges: [] + weights: [] + secondaryTextures: [] + spritePackingTag: + pSDRemoveMatte: 0 + pSDShowRemoveMatteOption: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DOTweenPro.meta b/Assets/Demigiant/DOTweenPro.meta new file mode 100644 index 0000000..cf975b1 --- /dev/null +++ b/Assets/Demigiant/DOTweenPro.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 27ff63655232ee540882ae60c8f71218 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DOTweenPro/DOTweenAnimation.cs b/Assets/Demigiant/DOTweenPro/DOTweenAnimation.cs new file mode 100644 index 0000000..b4b1d24 --- /dev/null +++ b/Assets/Demigiant/DOTweenPro/DOTweenAnimation.cs @@ -0,0 +1,662 @@ +// Author: Daniele Giardini - http://www.demigiant.com +// Created: 2015/03/12 15:55 + +using System; +using System.Collections.Generic; +using DG.Tweening.Core; +using UnityEngine; +#if true // UI_MARKER +using UnityEngine.UI; +#endif +#if true // TEXTMESHPRO_MARKER +using TMPro; +#endif + +#pragma warning disable 1591 +namespace DG.Tweening +{ + /// + /// Attach this to a GameObject to create a tween + /// + [AddComponentMenu("DOTween/DOTween Animation")] + public class DOTweenAnimation : ABSAnimationComponent + { + public bool targetIsSelf = true; // If FALSE allows to set the target manually + public GameObject targetGO = null; // Used in case targetIsSelf is FALSE + // If TRUE always uses the GO containing this DOTweenAnimation (and not the one containing the target) as DOTween's SetTarget target + public bool tweenTargetIsTargetGO = true; + + public float delay; + public float duration = 1; + public Ease easeType = Ease.OutQuad; + public AnimationCurve easeCurve = new AnimationCurve(new Keyframe(0, 0), new Keyframe(1, 1)); + public LoopType loopType = LoopType.Restart; + public int loops = 1; + public string id = ""; + public bool isRelative; + public bool isFrom; + public bool isIndependentUpdate = false; + public bool autoKill = true; + + public bool isActive = true; + public bool isValid; + public Component target; + public DOTweenAnimationType animationType; + public TargetType targetType; + public TargetType forcedTargetType; // Used when choosing between multiple targets + public bool autoPlay = true; + public bool useTargetAsV3; + + public float endValueFloat; + public Vector3 endValueV3; + public Vector2 endValueV2; + public Color endValueColor = new Color(1, 1, 1, 1); + public string endValueString = ""; + public Rect endValueRect = new Rect(0, 0, 0, 0); + public Transform endValueTransform; + + public bool optionalBool0; + public float optionalFloat0; + public int optionalInt0; + public RotateMode optionalRotationMode = RotateMode.Fast; + public ScrambleMode optionalScrambleMode = ScrambleMode.None; + public string optionalString; + + bool _tweenCreated; // TRUE after the tweens have been created + int _playCount = -1; // Used when calling DOPlayNext + + #region Unity Methods + + void Awake() + { + if (!isActive || !isValid) return; + + if (animationType != DOTweenAnimationType.Move || !useTargetAsV3) { + // Don't create tweens if we're using a RectTransform as a Move target, + // because that will work only inside Start + CreateTween(); + _tweenCreated = true; + } + } + + void Start() + { + if (_tweenCreated || !isActive || !isValid) return; + + CreateTween(); + _tweenCreated = true; + } + + void OnDestroy() + { + if (tween != null && tween.IsActive()) tween.Kill(); + tween = null; + } + + // Used also by DOTweenAnimationInspector when applying runtime changes and restarting + public void CreateTween() + { +// if (target == null) { +// Debug.LogWarning(string.Format("{0} :: This DOTweenAnimation's target is NULL, because the animation was created with a DOTween Pro version older than 0.9.255. To fix this, exit Play mode then simply select this object, and it will update automatically", this.gameObject.name), this.gameObject); +// return; +// } + + GameObject tweenGO = GetTweenGO(); + if (target == null || tweenGO == null) { + if (targetIsSelf && target == null) { + // Old error caused during upgrade from DOTween Pro 0.9.255 + Debug.LogWarning(string.Format("{0} :: This DOTweenAnimation's target is NULL, because the animation was created with a DOTween Pro version older than 0.9.255. To fix this, exit Play mode then simply select this object, and it will update automatically", this.gameObject.name), this.gameObject); + } else { + // Missing non-self target + Debug.LogWarning(string.Format("{0} :: This DOTweenAnimation's target/GameObject is unset: the tween will not be created.", this.gameObject.name), this.gameObject); + } + return; + } + + if (forcedTargetType != TargetType.Unset) targetType = forcedTargetType; + if (targetType == TargetType.Unset) { + // Legacy DOTweenAnimation (made with a version older than 0.9.450) without stored targetType > assign it now + targetType = TypeToDOTargetType(target.GetType()); + } + + switch (animationType) { + case DOTweenAnimationType.None: + break; + case DOTweenAnimationType.Move: + if (useTargetAsV3) { + isRelative = false; + if (endValueTransform == null) { + Debug.LogWarning(string.Format("{0} :: This tween's TO target is NULL, a Vector3 of (0,0,0) will be used instead", this.gameObject.name), this.gameObject); + endValueV3 = Vector3.zero; + } else { +#if true // UI_MARKER + if (targetType == TargetType.RectTransform) { + RectTransform endValueT = endValueTransform as RectTransform; + if (endValueT == null) { + Debug.LogWarning(string.Format("{0} :: This tween's TO target should be a RectTransform, a Vector3 of (0,0,0) will be used instead", this.gameObject.name), this.gameObject); + endValueV3 = Vector3.zero; + } else { + RectTransform rTarget = target as RectTransform; + if (rTarget == null) { + Debug.LogWarning(string.Format("{0} :: This tween's target and TO target are not of the same type. Please reassign the values", this.gameObject.name), this.gameObject); + } else { + // Problem: doesn't work inside Awake (ararargh!) + endValueV3 = DOTweenModuleUI.Utils.SwitchToRectTransform(endValueT, rTarget); + } + } + } else +#endif + endValueV3 = endValueTransform.position; + } + } + switch (targetType) { + case TargetType.Transform: + tween = ((Transform)target).DOMove(endValueV3, duration, optionalBool0); + break; + case TargetType.RectTransform: +#if true // UI_MARKER + tween = ((RectTransform)target).DOAnchorPos3D(endValueV3, duration, optionalBool0); +#else + tween = ((Transform)target).DOMove(endValueV3, duration, optionalBool0); +#endif + break; + case TargetType.Rigidbody: +#if true // PHYSICS_MARKER + tween = ((Rigidbody)target).DOMove(endValueV3, duration, optionalBool0); +#else + tween = ((Transform)target).DOMove(endValueV3, duration, optionalBool0); +#endif + break; + case TargetType.Rigidbody2D: +#if true // PHYSICS2D_MARKER + tween = ((Rigidbody2D)target).DOMove(endValueV3, duration, optionalBool0); +#else + tween = ((Transform)target).DOMove(endValueV3, duration, optionalBool0); +#endif + break; + } + break; + case DOTweenAnimationType.LocalMove: + tween = tweenGO.transform.DOLocalMove(endValueV3, duration, optionalBool0); + break; + case DOTweenAnimationType.Rotate: + switch (targetType) { + case TargetType.Transform: + tween = ((Transform)target).DORotate(endValueV3, duration, optionalRotationMode); + break; + case TargetType.Rigidbody: +#if true // PHYSICS_MARKER + tween = ((Rigidbody)target).DORotate(endValueV3, duration, optionalRotationMode); +#else + tween = ((Transform)target).DORotate(endValueV3, duration, optionalRotationMode); +#endif + break; + case TargetType.Rigidbody2D: +#if true // PHYSICS2D_MARKER + tween = ((Rigidbody2D)target).DORotate(endValueFloat, duration); +#else + tween = ((Transform)target).DORotate(endValueV3, duration, optionalRotationMode); +#endif + break; + } + break; + case DOTweenAnimationType.LocalRotate: + tween = tweenGO.transform.DOLocalRotate(endValueV3, duration, optionalRotationMode); + break; + case DOTweenAnimationType.Scale: + switch (targetType) { +#if false // TK2D_MARKER + case TargetType.tk2dTextMesh: + tween = ((tk2dTextMesh)target).DOScale(optionalBool0 ? new Vector3(endValueFloat, endValueFloat, endValueFloat) : endValueV3, duration); + break; + case TargetType.tk2dBaseSprite: + tween = ((tk2dBaseSprite)target).DOScale(optionalBool0 ? new Vector3(endValueFloat, endValueFloat, endValueFloat) : endValueV3, duration); + break; +#endif + default: + tween = tweenGO.transform.DOScale(optionalBool0 ? new Vector3(endValueFloat, endValueFloat, endValueFloat) : endValueV3, duration); + break; + } + break; +#if true // UI_MARKER + case DOTweenAnimationType.UIWidthHeight: + tween = ((RectTransform)target).DOSizeDelta(optionalBool0 ? new Vector2(endValueFloat, endValueFloat) : endValueV2, duration); + break; +#endif + case DOTweenAnimationType.Color: + isRelative = false; + switch (targetType) { + case TargetType.Renderer: + tween = ((Renderer)target).material.DOColor(endValueColor, duration); + break; + case TargetType.Light: + tween = ((Light)target).DOColor(endValueColor, duration); + break; +#if true // SPRITE_MARKER + case TargetType.SpriteRenderer: + tween = ((SpriteRenderer)target).DOColor(endValueColor, duration); + break; +#endif +#if true // UI_MARKER + case TargetType.Image: + tween = ((Image)target).DOColor(endValueColor, duration); + break; + case TargetType.Text: + tween = ((Text)target).DOColor(endValueColor, duration); + break; +#endif +#if false // TK2D_MARKER + case TargetType.tk2dTextMesh: + tween = ((tk2dTextMesh)target).DOColor(endValueColor, duration); + break; + case TargetType.tk2dBaseSprite: + tween = ((tk2dBaseSprite)target).DOColor(endValueColor, duration); + break; +#endif +#if true // TEXTMESHPRO_MARKER + case TargetType.TextMeshProUGUI: + tween = ((TextMeshProUGUI)target).DOColor(endValueColor, duration); + break; + case TargetType.TextMeshPro: + tween = ((TextMeshPro)target).DOColor(endValueColor, duration); + break; +#endif + } + break; + case DOTweenAnimationType.Fade: + isRelative = false; + switch (targetType) { + case TargetType.Renderer: + tween = ((Renderer)target).material.DOFade(endValueFloat, duration); + break; + case TargetType.Light: + tween = ((Light)target).DOIntensity(endValueFloat, duration); + break; +#if true // SPRITE_MARKER + case TargetType.SpriteRenderer: + tween = ((SpriteRenderer)target).DOFade(endValueFloat, duration); + break; +#endif +#if true // UI_MARKER + case TargetType.Image: + tween = ((Image)target).DOFade(endValueFloat, duration); + break; + case TargetType.Text: + tween = ((Text)target).DOFade(endValueFloat, duration); + break; + case TargetType.CanvasGroup: + tween = ((CanvasGroup)target).DOFade(endValueFloat, duration); + break; +#endif +#if false // TK2D_MARKER + case TargetType.tk2dTextMesh: + tween = ((tk2dTextMesh)target).DOFade(endValueFloat, duration); + break; + case TargetType.tk2dBaseSprite: + tween = ((tk2dBaseSprite)target).DOFade(endValueFloat, duration); + break; +#endif +#if true // TEXTMESHPRO_MARKER + case TargetType.TextMeshProUGUI: + tween = ((TextMeshProUGUI)target).DOFade(endValueFloat, duration); + break; + case TargetType.TextMeshPro: + tween = ((TextMeshPro)target).DOFade(endValueFloat, duration); + break; +#endif + } + break; + case DOTweenAnimationType.Text: +#if true // UI_MARKER + switch (targetType) { + case TargetType.Text: + tween = ((Text)target).DOText(endValueString, duration, optionalBool0, optionalScrambleMode, optionalString); + break; + } +#endif +#if false // TK2D_MARKER + switch (targetType) { + case TargetType.tk2dTextMesh: + tween = ((tk2dTextMesh)target).DOText(endValueString, duration, optionalBool0, optionalScrambleMode, optionalString); + break; + } +#endif +#if true // TEXTMESHPRO_MARKER + switch (targetType) { + case TargetType.TextMeshProUGUI: + tween = ((TextMeshProUGUI)target).DOText(endValueString, duration, optionalBool0, optionalScrambleMode, optionalString); + break; + case TargetType.TextMeshPro: + tween = ((TextMeshPro)target).DOText(endValueString, duration, optionalBool0, optionalScrambleMode, optionalString); + break; + } +#endif + break; + case DOTweenAnimationType.PunchPosition: + switch (targetType) { + case TargetType.Transform: + tween = ((Transform)target).DOPunchPosition(endValueV3, duration, optionalInt0, optionalFloat0, optionalBool0); + break; +#if true // UI_MARKER + case TargetType.RectTransform: + tween = ((RectTransform)target).DOPunchAnchorPos(endValueV3, duration, optionalInt0, optionalFloat0, optionalBool0); + break; +#endif + } + break; + case DOTweenAnimationType.PunchScale: + tween = tweenGO.transform.DOPunchScale(endValueV3, duration, optionalInt0, optionalFloat0); + break; + case DOTweenAnimationType.PunchRotation: + tween = tweenGO.transform.DOPunchRotation(endValueV3, duration, optionalInt0, optionalFloat0); + break; + case DOTweenAnimationType.ShakePosition: + switch (targetType) { + case TargetType.Transform: + tween = ((Transform)target).DOShakePosition(duration, endValueV3, optionalInt0, optionalFloat0, optionalBool0); + break; +#if true // UI_MARKER + case TargetType.RectTransform: + tween = ((RectTransform)target).DOShakeAnchorPos(duration, endValueV3, optionalInt0, optionalFloat0, optionalBool0); + break; +#endif + } + break; + case DOTweenAnimationType.ShakeScale: + tween = tweenGO.transform.DOShakeScale(duration, endValueV3, optionalInt0, optionalFloat0); + break; + case DOTweenAnimationType.ShakeRotation: + tween = tweenGO.transform.DOShakeRotation(duration, endValueV3, optionalInt0, optionalFloat0); + break; + case DOTweenAnimationType.CameraAspect: + tween = ((Camera)target).DOAspect(endValueFloat, duration); + break; + case DOTweenAnimationType.CameraBackgroundColor: + tween = ((Camera)target).DOColor(endValueColor, duration); + break; + case DOTweenAnimationType.CameraFieldOfView: + tween = ((Camera)target).DOFieldOfView(endValueFloat, duration); + break; + case DOTweenAnimationType.CameraOrthoSize: + tween = ((Camera)target).DOOrthoSize(endValueFloat, duration); + break; + case DOTweenAnimationType.CameraPixelRect: + tween = ((Camera)target).DOPixelRect(endValueRect, duration); + break; + case DOTweenAnimationType.CameraRect: + tween = ((Camera)target).DORect(endValueRect, duration); + break; + } + + if (tween == null) return; + + if (isFrom) { + ((Tweener)tween).From(isRelative); + } else { + tween.SetRelative(isRelative); + } + GameObject setTarget = targetIsSelf || !tweenTargetIsTargetGO ? this.gameObject : targetGO; + tween.SetTarget(setTarget).SetDelay(delay).SetLoops(loops, loopType).SetAutoKill(autoKill) + .OnKill(()=> tween = null); + if (isSpeedBased) tween.SetSpeedBased(); + if (easeType == Ease.INTERNAL_Custom) tween.SetEase(easeCurve); + else tween.SetEase(easeType); + if (!string.IsNullOrEmpty(id)) tween.SetId(id); + tween.SetUpdate(isIndependentUpdate); + + if (hasOnStart) { + if (onStart != null) tween.OnStart(onStart.Invoke); + } else onStart = null; + if (hasOnPlay) { + if (onPlay != null) tween.OnPlay(onPlay.Invoke); + } else onPlay = null; + if (hasOnUpdate) { + if (onUpdate != null) tween.OnUpdate(onUpdate.Invoke); + } else onUpdate = null; + if (hasOnStepComplete) { + if (onStepComplete != null) tween.OnStepComplete(onStepComplete.Invoke); + } else onStepComplete = null; + if (hasOnComplete) { + if (onComplete != null) tween.OnComplete(onComplete.Invoke); + } else onComplete = null; + if (hasOnRewind) { + if (onRewind != null) tween.OnRewind(onRewind.Invoke); + } else onRewind = null; + + if (autoPlay) tween.Play(); + else tween.Pause(); + + if (hasOnTweenCreated && onTweenCreated != null) onTweenCreated.Invoke(); + } + + #endregion + + #region Public Methods + + // These methods are here so they can be called directly via Unity's UGUI event system + + public override void DOPlay() + { + DOTween.Play(this.gameObject); + } + + public override void DOPlayBackwards() + { + DOTween.PlayBackwards(this.gameObject); + } + + public override void DOPlayForward() + { + DOTween.PlayForward(this.gameObject); + } + + public override void DOPause() + { + DOTween.Pause(this.gameObject); + } + + public override void DOTogglePause() + { + DOTween.TogglePause(this.gameObject); + } + + public override void DORewind() + { + _playCount = -1; + // Rewind using Components order (in case there are multiple animations on the same property) + DOTweenAnimation[] anims = this.gameObject.GetComponents(); + for (int i = anims.Length - 1; i > -1; --i) { + Tween t = anims[i].tween; + if (t != null && t.IsInitialized()) anims[i].tween.Rewind(); + } + // DOTween.Rewind(this.gameObject); + } + + /// + /// Restarts the tween + /// + /// If TRUE, re-evaluates the tween's start and end values from its current position. + /// Set it to TRUE when spawning the same DOTweenAnimation in different positions (like when using a pooling system) + public override void DORestart(bool fromHere = false) + { + _playCount = -1; + if (tween == null) { + if (Debugger.logPriority > 1) Debugger.LogNullTween(tween); return; + } + if (fromHere && isRelative) ReEvaluateRelativeTween(); + DOTween.Restart(this.gameObject); + } + + public override void DOComplete() + { + DOTween.Complete(this.gameObject); + } + + public override void DOKill() + { + DOTween.Kill(this.gameObject); + tween = null; + } + + #region Specifics + + public void DOPlayById(string id) + { + DOTween.Play(this.gameObject, id); + } + public void DOPlayAllById(string id) + { + DOTween.Play(id); + } + + public void DOPauseAllById(string id) + { + DOTween.Pause(id); + } + + public void DOPlayBackwardsById(string id) + { + DOTween.PlayBackwards(this.gameObject, id); + } + public void DOPlayBackwardsAllById(string id) + { + DOTween.PlayBackwards(id); + } + + public void DOPlayForwardById(string id) + { + DOTween.PlayForward(this.gameObject, id); + } + public void DOPlayForwardAllById(string id) + { + DOTween.PlayForward(id); + } + + public void DOPlayNext() + { + DOTweenAnimation[] anims = this.GetComponents(); + while (_playCount < anims.Length - 1) { + _playCount++; + DOTweenAnimation anim = anims[_playCount]; + if (anim != null && anim.tween != null && !anim.tween.IsPlaying() && !anim.tween.IsComplete()) { + anim.tween.Play(); + break; + } + } + } + + public void DORewindAndPlayNext() + { + _playCount = -1; + DOTween.Rewind(this.gameObject); + DOPlayNext(); + } + + public void DORewindAllById(string id) + { + _playCount = -1; + DOTween.Rewind(id); + } + + public void DORestartById(string id) + { + _playCount = -1; + DOTween.Restart(this.gameObject, id); + } + public void DORestartAllById(string id) + { + _playCount = -1; + DOTween.Restart(id); + } + + /// + /// Returns the tweens created by this DOTweenAnimation, in the same order as they appear in the Inspector (top to bottom) + /// + public List GetTweens() + { +// return DOTween.TweensByTarget(this.gameObject); + + List result = new List(); + DOTweenAnimation[] anims = this.GetComponents(); + foreach (DOTweenAnimation anim in anims) result.Add(anim.tween); + return result; + } + + #endregion + + #region Internal (also used by Inspector) + + public static TargetType TypeToDOTargetType(Type t) + { + string str = t.ToString(); + int dotIndex = str.LastIndexOf("."); + if (dotIndex != -1) str = str.Substring(dotIndex + 1); + if (str.IndexOf("Renderer") != -1 && (str != "SpriteRenderer")) str = "Renderer"; +#if !true // PHYSICS_MARKER + if (str == "Rigidbody") str = "Transform"; +#endif +#if !true // PHYSICS2D_MARKER + if (str == "Rigidbody2D") str = "Transform"; +#endif +#if !true // UI_MARKER + if (str == "RectTransform") str = "Transform"; +#endif + return (TargetType)Enum.Parse(typeof(TargetType), str); + } + + // Editor preview system + /// + /// Previews the tween in the editor. Only for DOTween internal usage: don't use otherwise. + /// + public Tween CreateEditorPreview() + { + if (Application.isPlaying) return null; + + CreateTween(); + return tween; + } + + #endregion + + #endregion + + #region Private + + // Returns the gameObject whose target component should be animated + GameObject GetTweenGO() + { + return targetIsSelf ? this.gameObject : targetGO; + } + + // Re-evaluate relative position of path + void ReEvaluateRelativeTween() + { + GameObject tweenGO = GetTweenGO(); + if (tweenGO == null) { + Debug.LogWarning(string.Format("{0} :: This DOTweenAnimation's target/GameObject is unset: the tween will not be created.", this.gameObject.name), this.gameObject); + return; + } + if (animationType == DOTweenAnimationType.Move) { + ((Tweener)tween).ChangeEndValue(tweenGO.transform.position + endValueV3, true); + } else if (animationType == DOTweenAnimationType.LocalMove) { + ((Tweener)tween).ChangeEndValue(tweenGO.transform.localPosition + endValueV3, true); + } + } + + #endregion + } + + public static class DOTweenAnimationExtensions + { +// // Doesn't work on Win 8.1 +// public static bool IsSameOrSubclassOf(this Type t, Type tBase) +// { +// return t.IsSubclassOf(tBase) || t == tBase; +// } + + public static bool IsSameOrSubclassOf(this Component t) + { + return t is T; + } + } +} diff --git a/Assets/Demigiant/DOTweenPro/DOTweenAnimation.cs.meta b/Assets/Demigiant/DOTweenPro/DOTweenAnimation.cs.meta new file mode 100644 index 0000000..5d92ac7 --- /dev/null +++ b/Assets/Demigiant/DOTweenPro/DOTweenAnimation.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 4d0390bd8b8ffd640b34fe25065ff1df +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DOTweenPro/DOTweenPro.XML b/Assets/Demigiant/DOTweenPro/DOTweenPro.XML new file mode 100644 index 0000000..9a8fa69 --- /dev/null +++ b/Assets/Demigiant/DOTweenPro/DOTweenPro.XML @@ -0,0 +1,49 @@ + + + + DOTweenPro + + + + + Restarts the tween + + If TRUE, re-evaluates the tween's start and end values from its current position. + Set it to TRUE when spawning the same DOTweenPath in different positions (like when using a pooling system) + + + + Attach this to a GameObject to create and assign a path to it + + + + + Restarts the tween + + If TRUE, re-evaluates the tween's start and end values from its current position. + Set it to TRUE when spawning the same DOTweenPath in different positions (like when using a pooling system) + + + + Returns a list of points that are used to draw the path inside the editor. + + + + + Tweens a Vector3 along a spiral. + EndValue represents the direction of the spiral + + + + + Spiral tween mode + + + + The spiral motion will expand outwards for the whole the tween + + + The spiral motion will expand outwards for half the tween and then will spiral back to the starting position + + + diff --git a/Assets/Demigiant/DOTweenPro/DOTweenPro.XML.meta b/Assets/Demigiant/DOTweenPro/DOTweenPro.XML.meta new file mode 100644 index 0000000..a396828 --- /dev/null +++ b/Assets/Demigiant/DOTweenPro/DOTweenPro.XML.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: db7d7ef84c388bc4fbc3835d31a15306 +TextScriptImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DOTweenPro/DOTweenPro.dll b/Assets/Demigiant/DOTweenPro/DOTweenPro.dll new file mode 100644 index 0000000..bfd1a80 Binary files /dev/null and b/Assets/Demigiant/DOTweenPro/DOTweenPro.dll differ diff --git a/Assets/Demigiant/DOTweenPro/DOTweenPro.dll.mdb b/Assets/Demigiant/DOTweenPro/DOTweenPro.dll.mdb new file mode 100644 index 0000000..4c20587 Binary files /dev/null and b/Assets/Demigiant/DOTweenPro/DOTweenPro.dll.mdb differ diff --git a/Assets/Demigiant/DOTweenPro/DOTweenPro.dll.mdb.meta b/Assets/Demigiant/DOTweenPro/DOTweenPro.dll.mdb.meta new file mode 100644 index 0000000..c40cf1b --- /dev/null +++ b/Assets/Demigiant/DOTweenPro/DOTweenPro.dll.mdb.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: d719ed2e2c87eae4e8dd520e2df659c1 +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DOTweenPro/DOTweenPro.dll.meta b/Assets/Demigiant/DOTweenPro/DOTweenPro.dll.meta new file mode 100644 index 0000000..6bcf817 --- /dev/null +++ b/Assets/Demigiant/DOTweenPro/DOTweenPro.dll.meta @@ -0,0 +1,21 @@ +fileFormatVersion: 2 +guid: aa0b1eebb5db27a419fa4564bbe5c9c5 +PluginImporter: + externalObjects: {} + serializedVersion: 2 + iconMap: {} + executionOrder: {} + defineConstraints: [] + isPreloaded: 0 + isOverridable: 0 + isExplicitlyReferenced: 0 + validateReferences: 1 + platformData: + - first: + Any: + second: + enabled: 1 + settings: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DOTweenPro/DOTweenProShortcuts.cs b/Assets/Demigiant/DOTweenPro/DOTweenProShortcuts.cs new file mode 100644 index 0000000..12ee7ef --- /dev/null +++ b/Assets/Demigiant/DOTweenPro/DOTweenProShortcuts.cs @@ -0,0 +1,90 @@ +// Author: Daniele Giardini - http://www.demigiant.com +// Created: 2018/07/13 + +using System; +using DG.Tweening.Core; +using DG.Tweening.Plugins; +using UnityEngine; + +#pragma warning disable 1591 +namespace DG.Tweening +{ + public static class DOTweenProShortcuts + { + static DOTweenProShortcuts() + { + // Create stub instances of custom plugins, in order to allow IL2CPP to understand they must be included in the build +#pragma warning disable 219 + SpiralPlugin stub = new SpiralPlugin(); +#pragma warning restore 219 + } + + #region Shortcuts + + #region Transform + + /// Tweens a Transform's localPosition in a spiral shape. + /// Also stores the transform as the tween's target so it can be used for filtered operations + /// The duration of the tween + /// The axis around which the spiral will rotate + /// The type of spiral movement + /// Speed of the rotations + /// Frequency of the rotation. Lower values lead to wider spirals + /// Indicates how much the tween should move along the spiral's axis + /// If TRUE the tween will smoothly snap all values to integers + public static Tweener DOSpiral( + this Transform target, float duration, Vector3? axis = null, SpiralMode mode = SpiralMode.Expand, + float speed = 1, float frequency = 10, float depth = 0, bool snapping = false + ) { + if (Mathf.Approximately(speed, 0)) speed = 1; + if (axis == null || axis == Vector3.zero) axis = Vector3.forward; + + TweenerCore t = DOTween.To(SpiralPlugin.Get(), () => target.localPosition, x => target.localPosition = x, (Vector3)axis, duration) + .SetTarget(target); + + t.plugOptions.mode = mode; + t.plugOptions.speed = speed; + t.plugOptions.frequency = frequency; + t.plugOptions.depth = depth; + t.plugOptions.snapping = snapping; + return t; + } + + #endregion + +#if true // PHYSICS_MARKER + #region Rigidbody + + /// Tweens a Rigidbody's position in a spiral shape. + /// Also stores the transform as the tween's target so it can be used for filtered operations + /// The duration of the tween + /// The axis around which the spiral will rotate + /// The type of spiral movement + /// Speed of the rotations + /// Frequency of the rotation. Lower values lead to wider spirals + /// Indicates how much the tween should move along the spiral's axis + /// If TRUE the tween will smoothly snap all values to integers + public static Tweener DOSpiral( + this Rigidbody target, float duration, Vector3? axis = null, SpiralMode mode = SpiralMode.Expand, + float speed = 1, float frequency = 10, float depth = 0, bool snapping = false + ) { + if (Mathf.Approximately(speed, 0)) speed = 1; + if (axis == null || axis == Vector3.zero) axis = Vector3.forward; + + TweenerCore t = DOTween.To(SpiralPlugin.Get(), () => target.position, target.MovePosition, (Vector3)axis, duration) + .SetTarget(target); + + t.plugOptions.mode = mode; + t.plugOptions.speed = speed; + t.plugOptions.frequency = frequency; + t.plugOptions.depth = depth; + t.plugOptions.snapping = snapping; + return t; + } + + #endregion +#endif + + #endregion + } +} diff --git a/Assets/Demigiant/DOTweenPro/DOTweenProShortcuts.cs.meta b/Assets/Demigiant/DOTweenPro/DOTweenProShortcuts.cs.meta new file mode 100644 index 0000000..99f8a2e --- /dev/null +++ b/Assets/Demigiant/DOTweenPro/DOTweenProShortcuts.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 1c3190a1a1c53f449926f6d5542b4ce5 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DOTweenPro/DOTweenTextMeshPro.cs b/Assets/Demigiant/DOTweenPro/DOTweenTextMeshPro.cs new file mode 100644 index 0000000..60faa7c --- /dev/null +++ b/Assets/Demigiant/DOTweenPro/DOTweenTextMeshPro.cs @@ -0,0 +1,355 @@ +// Author: Daniele Giardini - http://www.demigiant.com +// Created: 2015/03/27 19:02 +// +// License Copyright (c) Daniele Giardini. +// This work is subject to the terms at http://dotween.demigiant.com/license.php + +#if true // MODULE_MARKER +using UnityEngine; +using TMPro; + +namespace DG.Tweening +{ + /// + /// Methods that extend TMP_Text objects and allow to directly create and control tweens from their instances. + /// + public static class ShortcutExtensionsTMPText + { + #region Colors + + /// Tweens a TextMeshPro's color to the given value. + /// Also stores the TextMeshPro as the tween's target so it can be used for filtered operations + /// The end value to reachThe duration of the tween + public static Tweener DOColor(this TMP_Text target, Color endValue, float duration) + { + return DOTween.To(() => target.color, x => target.color = x, endValue, duration) + .SetTarget(target); + } + + /// Tweens a TextMeshPro's faceColor to the given value. + /// Also stores the TextMeshPro as the tween's target so it can be used for filtered operations + /// The end value to reachThe duration of the tween + public static Tweener DOFaceColor(this TMP_Text target, Color32 endValue, float duration) + { + return DOTween.To(() => target.faceColor, x => target.faceColor = x, endValue, duration) + .SetTarget(target); + } + + /// Tweens a TextMeshPro's outlineColor to the given value. + /// Also stores the TextMeshPro as the tween's target so it can be used for filtered operations + /// The end value to reachThe duration of the tween + public static Tweener DOOutlineColor(this TMP_Text target, Color32 endValue, float duration) + { + return DOTween.To(() => target.outlineColor, x => target.outlineColor = x, endValue, duration) + .SetTarget(target); + } + + /// Tweens a TextMeshPro's glow color to the given value. + /// Also stores the TextMeshPro as the tween's target so it can be used for filtered operations + /// The end value to reachThe duration of the tween + /// If TRUE will use the fontSharedMaterial instead than the fontMaterial + public static Tweener DOGlowColor(this TMP_Text target, Color endValue, float duration, bool useSharedMaterial = false) + { + return useSharedMaterial + ? target.fontSharedMaterial.DOColor(endValue, "_GlowColor", duration).SetTarget(target) + : target.fontMaterial.DOColor(endValue, "_GlowColor", duration).SetTarget(target); + } + + /// Tweens a TextMeshPro's alpha color to the given value. + /// Also stores the TextMeshPro as the tween's target so it can be used for filtered operations + /// The end value to reachThe duration of the tween + public static Tweener DOFade(this TMP_Text target, float endValue, float duration) + { + return DOTween.ToAlpha(() => target.color, x => target.color = x, endValue, duration) + .SetTarget(target); + } + + /// Tweens a TextMeshPro faceColor's alpha to the given value. + /// Also stores the TextMeshPro as the tween's target so it can be used for filtered operations + /// The end value to reachThe duration of the tween + public static Tweener DOFaceFade(this TMP_Text target, float endValue, float duration) + { + return DOTween.ToAlpha(() => target.faceColor, x => target.faceColor = x, endValue, duration) + .SetTarget(target); + } + + #endregion + + #region Other + + /// Tweens a TextMeshPro's scale to the given value (using correct uniform scale as TMP requires). + /// Also stores the TextMeshPro as the tween's target so it can be used for filtered operations + /// The end value to reachThe duration of the tween + public static Tweener DOScale(this TMP_Text target, float endValue, float duration) + { + Transform t = target.transform; + Vector3 endValueV3 = new Vector3(endValue, endValue, endValue); + return DOTween.To(() => t.localScale, x => t.localScale = x, endValueV3, duration).SetTarget(target); + } + + /// Tweens a TextMeshPro's fontSize to the given value. + /// Also stores the TextMeshPro as the tween's target so it can be used for filtered operations + /// The end value to reachThe duration of the tween + public static Tweener DOFontSize(this TMP_Text target, float endValue, float duration) + { + return DOTween.To(() => target.fontSize, x => target.fontSize = x, endValue, duration) + .SetTarget(target); + } + + /// Tweens a TextMeshPro's maxVisibleCharacters to the given value. + /// Also stores the TextMeshPro as the tween's target so it can be used for filtered operations + /// The end value to reachThe duration of the tween + public static Tweener DOMaxVisibleCharacters(this TMP_Text target, int endValue, float duration) + { + return DOTween.To(() => target.maxVisibleCharacters, x => target.maxVisibleCharacters = x, endValue, duration) + .SetTarget(target); + } + + /// Tweens a TextMeshPro's text to the given value. + /// Also stores the TextMeshPro as the tween's target so it can be used for filtered operations + /// The end string to tween toThe duration of the tween + /// If TRUE (default), rich text will be interpreted correctly while animated, + /// otherwise all tags will be considered as normal text + /// The type of scramble mode to use, if any + /// A string containing the characters to use for scrambling. + /// Use as many characters as possible (minimum 10) because DOTween uses a fast scramble mode which gives better results with more characters. + /// Leave it to NULL (default) to use default ones + public static Tweener DOText(this TMP_Text target, string endValue, float duration, bool richTextEnabled = true, ScrambleMode scrambleMode = ScrambleMode.None, string scrambleChars = null) + { + return DOTween.To(() => target.text, x => target.text = x, endValue, duration) + .SetOptions(richTextEnabled, scrambleMode, scrambleChars) + .SetTarget(target); + } + + #endregion + } + +// /// +// /// Methods that extend TextMeshPro objects and allow to directly create and control tweens from their instances. +// /// +// public static class ShortcutExtensionsTextMeshPro +// { +// #region Colors +// +// /// Tweens a TextMeshPro's color to the given value. +// /// Also stores the TextMeshPro as the tween's target so it can be used for filtered operations +// /// The end value to reachThe duration of the tween +// public static Tweener DOColor(this TextMeshPro target, Color endValue, float duration) +// { +// return DOTween.To(() => target.color, x => target.color = x, endValue, duration) +// .SetTarget(target); +// } +// +// /// Tweens a TextMeshPro's faceColor to the given value. +// /// Also stores the TextMeshPro as the tween's target so it can be used for filtered operations +// /// The end value to reachThe duration of the tween +// public static Tweener DOFaceColor(this TextMeshPro target, Color32 endValue, float duration) +// { +// return DOTween.To(() => target.faceColor, x => target.faceColor = x, endValue, duration) +// .SetTarget(target); +// } +// +// /// Tweens a TextMeshPro's outlineColor to the given value. +// /// Also stores the TextMeshPro as the tween's target so it can be used for filtered operations +// /// The end value to reachThe duration of the tween +// public static Tweener DOOutlineColor(this TextMeshPro target, Color32 endValue, float duration) +// { +// return DOTween.To(() => target.outlineColor, x => target.outlineColor = x, endValue, duration) +// .SetTarget(target); +// } +// +// /// Tweens a TextMeshPro's glow color to the given value. +// /// Also stores the TextMeshPro as the tween's target so it can be used for filtered operations +// /// The end value to reachThe duration of the tween +// /// If TRUE will use the fontSharedMaterial instead than the fontMaterial +// public static Tweener DOGlowColor(this TextMeshPro target, Color endValue, float duration, bool useSharedMaterial = false) +// { +// return useSharedMaterial +// ? target.fontSharedMaterial.DOColor(endValue, "_GlowColor", duration).SetTarget(target) +// : target.fontMaterial.DOColor(endValue, "_GlowColor", duration).SetTarget(target); +// } +// +// /// Tweens a TextMeshPro's alpha color to the given value. +// /// Also stores the TextMeshPro as the tween's target so it can be used for filtered operations +// /// The end value to reachThe duration of the tween +// public static Tweener DOFade(this TextMeshPro target, float endValue, float duration) +// { +// return DOTween.ToAlpha(() => target.color, x => target.color = x, endValue, duration) +// .SetTarget(target); +// } +// +// /// Tweens a TextMeshPro faceColor's alpha to the given value. +// /// Also stores the TextMeshPro as the tween's target so it can be used for filtered operations +// /// The end value to reachThe duration of the tween +// public static Tweener DOFaceFade(this TextMeshPro target, float endValue, float duration) +// { +// return DOTween.ToAlpha(() => target.faceColor, x => target.faceColor = x, endValue, duration) +// .SetTarget(target); +// } +// +// #endregion +// +// #region Other +// +// /// Tweens a TextMeshPro's scale to the given value (using correct uniform scale as TMP requires). +// /// Also stores the TextMeshPro as the tween's target so it can be used for filtered operations +// /// The end value to reachThe duration of the tween +// public static Tweener DOScale(this TextMeshPro target, float endValue, float duration) +// { +// Transform t = target.transform; +// Vector3 endValueV3 = new Vector3(endValue, endValue, endValue); +// return DOTween.To(() => t.localScale, x => t.localScale = x, endValueV3, duration).SetTarget(target); +// } +// +// /// Tweens a TextMeshPro's fontSize to the given value. +// /// Also stores the TextMeshPro as the tween's target so it can be used for filtered operations +// /// The end value to reachThe duration of the tween +// public static Tweener DOFontSize(this TextMeshPro target, float endValue, float duration) +// { +// return DOTween.To(() => target.fontSize, x => target.fontSize = x, endValue, duration) +// .SetTarget(target); +// } +// +// /// Tweens a TextMeshPro's maxVisibleCharacters to the given value. +// /// Also stores the TextMeshPro as the tween's target so it can be used for filtered operations +// /// The end value to reachThe duration of the tween +// public static Tweener DOMaxVisibleCharacters(this TextMeshPro target, int endValue, float duration) +// { +// return DOTween.To(() => target.maxVisibleCharacters, x => target.maxVisibleCharacters = x, endValue, duration) +// .SetTarget(target); +// } +// +// /// Tweens a TextMeshPro's text to the given value. +// /// Also stores the TextMeshPro as the tween's target so it can be used for filtered operations +// /// The end string to tween toThe duration of the tween +// /// If TRUE (default), rich text will be interpreted correctly while animated, +// /// otherwise all tags will be considered as normal text +// /// The type of scramble mode to use, if any +// /// A string containing the characters to use for scrambling. +// /// Use as many characters as possible (minimum 10) because DOTween uses a fast scramble mode which gives better results with more characters. +// /// Leave it to NULL (default) to use default ones +// public static Tweener DOText(this TextMeshPro target, string endValue, float duration, bool richTextEnabled = true, ScrambleMode scrambleMode = ScrambleMode.None, string scrambleChars = null) +// { +// return DOTween.To(() => target.text, x => target.text = x, endValue, duration) +// .SetOptions(richTextEnabled, scrambleMode, scrambleChars) +// .SetTarget(target); +// } +// +// #endregion +// } +// +// /// +// /// Methods that extend TextMeshProUGUI objects and allow to directly create and control tweens from their instances. +// /// +// public static class ShortcutExtensionsTextMeshProUGUI +// { +// #region Colors +// +// /// Tweens a TextMeshProUGUI's color to the given value. +// /// Also stores the TextMeshProUGUI as the tween's target so it can be used for filtered operations +// /// The end value to reachThe duration of the tween +// public static Tweener DOColor(this TextMeshProUGUI target, Color endValue, float duration) +// { +// return DOTween.To(() => target.color, x => target.color = x, endValue, duration) +// .SetTarget(target); +// } +// +// /// Tweens a TextMeshProUGUI's faceColor to the given value. +// /// Also stores the TextMeshProUGUI as the tween's target so it can be used for filtered operations +// /// The end value to reachThe duration of the tween +// public static Tweener DOFaceColor(this TextMeshProUGUI target, Color32 endValue, float duration) +// { +// return DOTween.To(() => target.faceColor, x => target.faceColor = x, endValue, duration) +// .SetTarget(target); +// } +// +// /// Tweens a TextMeshProUGUI's outlineColor to the given value. +// /// Also stores the TextMeshProUGUI as the tween's target so it can be used for filtered operations +// /// The end value to reachThe duration of the tween +// public static Tweener DOOutlineColor(this TextMeshProUGUI target, Color32 endValue, float duration) +// { +// return DOTween.To(() => target.outlineColor, x => target.outlineColor = x, endValue, duration) +// .SetTarget(target); +// } +// +// /// Tweens a TextMeshProUGUI's glow color to the given value. +// /// Also stores the TextMeshProUGUI as the tween's target so it can be used for filtered operations +// /// The end value to reachThe duration of the tween +// /// If TRUE will use the fontSharedMaterial instead than the fontMaterial +// public static Tweener DOGlowColor(this TextMeshProUGUI target, Color endValue, float duration, bool useSharedMaterial = false) +// { +// return useSharedMaterial +// ? target.fontSharedMaterial.DOColor(endValue, "_GlowColor", duration).SetTarget(target) +// : target.fontMaterial.DOColor(endValue, "_GlowColor", duration).SetTarget(target); +// } +// +// /// Tweens a TextMeshProUGUI's alpha color to the given value. +// /// Also stores the TextMeshProUGUI as the tween's target so it can be used for filtered operations +// /// The end value to reachThe duration of the tween +// public static Tweener DOFade(this TextMeshProUGUI target, float endValue, float duration) +// { +// return DOTween.ToAlpha(() => target.color, x => target.color = x, endValue, duration) +// .SetTarget(target); +// } +// +// /// Tweens a TextMeshProUGUI faceColor's alpha to the given value. +// /// Also stores the TextMeshProUGUI as the tween's target so it can be used for filtered operations +// /// The end value to reachThe duration of the tween +// public static Tweener DOFaceFade(this TextMeshProUGUI target, float endValue, float duration) +// { +// return DOTween.ToAlpha(() => target.faceColor, x => target.faceColor = x, endValue, duration) +// .SetTarget(target); +// } +// +// #endregion +// +// #region Other +// +// /// Tweens a TextMeshProUGUI's scale to the given value (using correct uniform scale as TMP requires). +// /// Also stores the TextMeshProUGUI as the tween's target so it can be used for filtered operations +// /// The end value to reachThe duration of the tween +// public static Tweener DOScale(this TextMeshProUGUI target, float endValue, float duration) +// { +// Transform t = target.transform; +// Vector3 endValueV3 = new Vector3(endValue, endValue, endValue); +// return DOTween.To(() => t.localScale, x => t.localScale = x, endValueV3, duration).SetTarget(target); +// } +// +// /// Tweens a TextMeshProUGUI's fontSize to the given value. +// /// Also stores the TextMeshProUGUI as the tween's target so it can be used for filtered operations +// /// The end value to reachThe duration of the tween +// public static Tweener DOFontSize(this TextMeshProUGUI target, float endValue, float duration) +// { +// return DOTween.To(() => target.fontSize, x => target.fontSize = x, endValue, duration) +// .SetTarget(target); +// } +// +// /// Tweens a TextMeshProUGUI's maxVisibleCharacters to the given value. +// /// Also stores the TextMeshProUGUI as the tween's target so it can be used for filtered operations +// /// The end value to reachThe duration of the tween +// public static Tweener DOMaxVisibleCharacters(this TextMeshProUGUI target, int endValue, float duration) +// { +// return DOTween.To(() => target.maxVisibleCharacters, x => target.maxVisibleCharacters = x, endValue, duration) +// .SetTarget(target); +// } +// +// /// Tweens a TextMeshProUGUI's text to the given value. +// /// Also stores the TextMeshProUGUI as the tween's target so it can be used for filtered operations +// /// The end string to tween toThe duration of the tween +// /// If TRUE (default), rich text will be interpreted correctly while animated, +// /// otherwise all tags will be considered as normal text +// /// The type of scramble mode to use, if any +// /// A string containing the characters to use for scrambling. +// /// Use as many characters as possible (minimum 10) because DOTween uses a fast scramble mode which gives better results with more characters. +// /// Leave it to NULL (default) to use default ones +// public static Tweener DOText(this TextMeshProUGUI target, string endValue, float duration, bool richTextEnabled = true, ScrambleMode scrambleMode = ScrambleMode.None, string scrambleChars = null) +// { +// return DOTween.To(() => target.text, x => target.text = x, endValue, duration) +// .SetOptions(richTextEnabled, scrambleMode, scrambleChars) +// .SetTarget(target); +// } +// +// #endregion +// } +} +#endif diff --git a/Assets/Demigiant/DOTweenPro/DOTweenTextMeshPro.cs.meta b/Assets/Demigiant/DOTweenPro/DOTweenTextMeshPro.cs.meta new file mode 100644 index 0000000..66ff6cd --- /dev/null +++ b/Assets/Demigiant/DOTweenPro/DOTweenTextMeshPro.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 8fb0d65aa5b048649a3a785b82b8f8db +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DOTweenPro/DOTweenTk2d.cs b/Assets/Demigiant/DOTweenPro/DOTweenTk2d.cs new file mode 100644 index 0000000..d55cc3e --- /dev/null +++ b/Assets/Demigiant/DOTweenPro/DOTweenTk2d.cs @@ -0,0 +1,227 @@ +// Author: Daniele Giardini - http://www.demigiant.com +// Created: 2014/10/27 15:59 +// +// License Copyright (c) Daniele Giardini. +// This work is subject to the terms at http://dotween.demigiant.com/license.php + +#if false // MODULE_MARKER +using UnityEngine; + +namespace DG.Tweening +{ + /// + /// Methods that extend 2D Toolkit objects and allow to directly create and control tweens from their instances. + /// + public static class ShortcutExtensionsTk2d + { + #region Sprite + + /// Tweens a 2D Toolkit Sprite's dimensions to the given value. + /// Also stores the Sprite as the tween's target so it can be used for filtered operations + /// The end value to reachThe duration of the tween + public static Tweener DOScale(this tk2dBaseSprite target, Vector3 endValue, float duration) + { + return DOTween.To(() => target.scale, x => target.scale = x, endValue, duration) + .SetTarget(target); + } + /// Tweens a Sprite's dimensions to the given value. + /// Also stores the Sprite as the tween's target so it can be used for filtered operations + /// The end value to reachThe duration of the tween + public static Tweener DOScaleX(this tk2dBaseSprite target, float endValue, float duration) + { + return DOTween.To(() => target.scale, x => target.scale = x, new Vector3(endValue, 0, 0), duration) + .SetOptions(AxisConstraint.X) + .SetTarget(target); + } + /// Tweens a Sprite's dimensions to the given value. + /// Also stores the Sprite as the tween's target so it can be used for filtered operations + /// The end value to reachThe duration of the tween + public static Tweener DOScaleY(this tk2dBaseSprite target, float endValue, float duration) + { + return DOTween.To(() => target.scale, x => target.scale = x, new Vector3(0, endValue, 0), duration) + .SetOptions(AxisConstraint.Y) + .SetTarget(target); + } + /// Tweens a Sprite's dimensions to the given value. + /// Also stores the Sprite as the tween's target so it can be used for filtered operations + /// The end value to reachThe duration of the tween + public static Tweener DOScaleZ(this tk2dBaseSprite target, float endValue, float duration) + { + return DOTween.To(() => target.scale, x => target.scale = x, new Vector3(0, 0, endValue), duration) + .SetOptions(AxisConstraint.Z) + .SetTarget(target); + } + + /// Tweens a 2D Toolkit Sprite's color to the given value. + /// Also stores the Sprite as the tween's target so it can be used for filtered operations + /// The end value to reachThe duration of the tween + public static Tweener DOColor(this tk2dBaseSprite target, Color endValue, float duration) + { + return DOTween.To(() => target.color, x => target.color = x, endValue, duration) + .SetTarget(target); + } + + /// Tweens a 2D Toolkit Sprite's alpha color to the given value. + /// Also stores the Sprite as the tween's target so it can be used for filtered operations + /// The end value to reachThe duration of the tween + public static Tweener DOFade(this tk2dBaseSprite target, float endValue, float duration) + { + return DOTween.ToAlpha(() => target.color, x => target.color = x, endValue, duration) + .SetTarget(target); + } + + /// Tweens a 2D Toolkit Sprite's color using the given gradient + /// (NOTE 1: only uses the colors of the gradient, not the alphas - NOTE 2: creates a Sequence, not a Tweener). + /// Also stores the image as the tween's target so it can be used for filtered operations + /// The gradient to useThe duration of the tween + public static Sequence DOGradientColor(this tk2dBaseSprite target, Gradient gradient, float duration) + { + Sequence s = DOTween.Sequence(); + GradientColorKey[] colors = gradient.colorKeys; + int len = colors.Length; + for (int i = 0; i < len; ++i) { + GradientColorKey c = colors[i]; + if (i == 0 && c.time <= 0) { + target.color = c.color; + continue; + } + float colorDuration = i == len - 1 + ? duration - s.Duration(false) // Verifies that total duration is correct + : duration * (i == 0 ? c.time : c.time - colors[i - 1].time); + s.Append(target.DOColor(c.color, colorDuration).SetEase(Ease.Linear)); + } + return s; + } + + #endregion + + #region tk2dSlicedSprite + + /// Tweens a 2D Toolkit SlicedSprite's dimensions to the given value. + /// Also stores the SlicedSprite as the tween's target so it can be used for filtered operations + /// The end value to reachThe duration of the tween + public static Tweener DOScaleDimensions(this tk2dSlicedSprite target, Vector2 endValue, float duration) + { + return DOTween.To(() => target.dimensions, x => target.dimensions = x, endValue, duration) + .SetTarget(target); + } + /// Tweens a SlicedSprite's dimensions to the given value. + /// Also stores the SlicedSprite as the tween's target so it can be used for filtered operations + /// The end value to reachThe duration of the tween + public static Tweener DOScaleDimensionsX(this tk2dSlicedSprite target, float endValue, float duration) + { + return DOTween.To(() => target.dimensions, x => target.dimensions = x, new Vector2(endValue, 0), duration) + .SetOptions(AxisConstraint.X) + .SetTarget(target); + } + /// Tweens a SlicedSprite's dimensions to the given value. + /// Also stores the SlicedSprite as the tween's target so it can be used for filtered operations + /// The end value to reachThe duration of the tween + public static Tweener DOScaleDimensionsY(this tk2dSlicedSprite target, float endValue, float duration) + { + return DOTween.To(() => target.dimensions, x => target.dimensions = x, new Vector2(0, endValue), duration) + .SetOptions(AxisConstraint.Y) + .SetTarget(target); + } + + #endregion + + #region TextMesh + + /// Tweens a 2D Toolkit TextMesh's dimensions to the given value. + /// Also stores the TextMesh as the tween's target so it can be used for filtered operations + /// The end value to reachThe duration of the tween + public static Tweener DOScale(this tk2dTextMesh target, Vector3 endValue, float duration) + { + return DOTween.To(() => target.scale, x => target.scale = x, endValue, duration) + .SetTarget(target); + } + /// Tweens a 2D Toolkit TextMesh's dimensions to the given value. + /// Also stores the TextMesh as the tween's target so it can be used for filtered operations + /// The end value to reachThe duration of the tween + public static Tweener DOScaleX(this tk2dTextMesh target, float endValue, float duration) + { + return DOTween.To(() => target.scale, x => target.scale = x, new Vector3(endValue, 0, 0), duration) + .SetOptions(AxisConstraint.X) + .SetTarget(target); + } + /// Tweens a 2D Toolkit TextMesh's dimensions to the given value. + /// Also stores the TextMesh as the tween's target so it can be used for filtered operations + /// The end value to reachThe duration of the tween + public static Tweener DOScaleY(this tk2dTextMesh target, float endValue, float duration) + { + return DOTween.To(() => target.scale, x => target.scale = x, new Vector3(0, endValue, 0), duration) + .SetOptions(AxisConstraint.Y) + .SetTarget(target); + } + /// Tweens a 2D Toolkit TextMesh's dimensions to the given value. + /// Also stores the TextMesh as the tween's target so it can be used for filtered operations + /// The end value to reachThe duration of the tween + public static Tweener DOScaleZ(this tk2dTextMesh target, float endValue, float duration) + { + return DOTween.To(() => target.scale, x => target.scale = x, new Vector3(0, 0, endValue), duration) + .SetOptions(AxisConstraint.Z) + .SetTarget(target); + } + + /// Tweens a 2D Toolkit TextMesh's color to the given value. + /// Also stores the TextMesh as the tween's target so it can be used for filtered operations + /// The end value to reachThe duration of the tween + public static Tweener DOColor(this tk2dTextMesh target, Color endValue, float duration) + { + return DOTween.To(() => target.color, x => target.color = x, endValue, duration) + .SetTarget(target); + } + + /// Tweens a 2D Toolkit TextMesh's alpha color to the given value. + /// Also stores the TextMesh as the tween's target so it can be used for filtered operations + /// The end value to reachThe duration of the tween + public static Tweener DOFade(this tk2dTextMesh target, float endValue, float duration) + { + return DOTween.ToAlpha(() => target.color, x => target.color = x, endValue, duration) + .SetTarget(target); + } + + /// Tweens a 2D Toolkit TextMesh's color using the given gradient + /// (NOTE 1: only uses the colors of the gradient, not the alphas - NOTE 2: creates a Sequence, not a Tweener). + /// Also stores the image as the tween's target so it can be used for filtered operations + /// The gradient to useThe duration of the tween + public static Sequence DOGradientColor(this tk2dTextMesh target, Gradient gradient, float duration) + { + Sequence s = DOTween.Sequence(); + GradientColorKey[] colors = gradient.colorKeys; + int len = colors.Length; + for (int i = 0; i < len; ++i) { + GradientColorKey c = colors[i]; + if (i == 0 && c.time <= 0) { + target.color = c.color; + continue; + } + float colorDuration = i == len - 1 + ? duration - s.Duration(false) // Verifies that total duration is correct + : duration * (i == 0 ? c.time : c.time - colors[i - 1].time); + s.Append(target.DOColor(c.color, colorDuration).SetEase(Ease.Linear)); + } + return s; + } + + /// Tweens a tk2dTextMesh's text to the given value. + /// Also stores the tk2dTextMesh as the tween's target so it can be used for filtered operations + /// The end string to tween toThe duration of the tween + /// If TRUE (default), rich text will be interpreted correctly while animated, + /// otherwise all tags will be considered as normal text + /// The type of scramble mode to use, if any + /// A string containing the characters to use for scrambling. + /// Use as many characters as possible (minimum 10) because DOTween uses a fast scramble mode which gives better results with more characters. + /// Leave it to NULL (default) to use default ones + public static Tweener DOText(this tk2dTextMesh target, string endValue, float duration, bool richTextEnabled = true, ScrambleMode scrambleMode = ScrambleMode.None, string scrambleChars = null) + { + return DOTween.To(() => target.text, x => target.text = x, endValue, duration) + .SetOptions(richTextEnabled, scrambleMode, scrambleChars) + .SetTarget(target); + } + + #endregion + } +} +#endif diff --git a/Assets/Demigiant/DOTweenPro/DOTweenTk2d.cs.meta b/Assets/Demigiant/DOTweenPro/DOTweenTk2d.cs.meta new file mode 100644 index 0000000..d9c7902 --- /dev/null +++ b/Assets/Demigiant/DOTweenPro/DOTweenTk2d.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: b590cd7c24ffa5d4faa5b6fa993cccad +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DOTweenPro/Editor.meta b/Assets/Demigiant/DOTweenPro/Editor.meta new file mode 100644 index 0000000..24daff5 --- /dev/null +++ b/Assets/Demigiant/DOTweenPro/Editor.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: d5ac6e5aca16df84793e9fee91bb0b9a +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DOTweenPro/Editor/DOTweenAnimationInspector.cs b/Assets/Demigiant/DOTweenPro/Editor/DOTweenAnimationInspector.cs new file mode 100644 index 0000000..19dc131 --- /dev/null +++ b/Assets/Demigiant/DOTweenPro/Editor/DOTweenAnimationInspector.cs @@ -0,0 +1,707 @@ +// Author: Daniele Giardini - http://www.demigiant.com +// Created: 2015/03/12 16:03 + +using System; +using System.Collections.Generic; +using System.IO; +using DG.DemiEditor; +using DG.DOTweenEditor.Core; +using DG.DOTweenEditor.UI; +using DG.Tweening; +using DG.Tweening.Core; +using UnityEditor; +using UnityEngine; +#if true // UI_MARKER +using UnityEngine.UI; +#endif +#if true // TEXTMESHPRO_MARKER + using TMPro; +#endif + +namespace DG.DOTweenEditor +{ + [CustomEditor(typeof(DOTweenAnimation))] + public class DOTweenAnimationInspector : ABSAnimationInspector + { + enum FadeTargetType + { + CanvasGroup, + Image + } + + enum ChooseTargetMode + { + None, + BetweenCanvasGroupAndImage + } + + static readonly Dictionary _AnimationTypeToComponent = new Dictionary() { + { DOTweenAnimationType.Move, new[] { +#if true // PHYSICS_MARKER + typeof(Rigidbody), +#endif +#if true // PHYSICS2D_MARKER + typeof(Rigidbody2D), +#endif +#if true // UI_MARKER + typeof(RectTransform), +#endif + typeof(Transform) + }}, + { DOTweenAnimationType.Rotate, new[] { +#if true // PHYSICS_MARKER + typeof(Rigidbody), +#endif +#if true // PHYSICS2D_MARKER + typeof(Rigidbody2D), +#endif + typeof(Transform) + }}, + { DOTweenAnimationType.LocalMove, new[] { typeof(Transform) } }, + { DOTweenAnimationType.LocalRotate, new[] { typeof(Transform) } }, + { DOTweenAnimationType.Scale, new[] { typeof(Transform) } }, + { DOTweenAnimationType.Color, new[] { + typeof(Light), +#if true // SPRITE_MARKER + typeof(SpriteRenderer), +#endif +#if true // UI_MARKER + typeof(Image), typeof(Text), +#endif + typeof(Renderer), + }}, + { DOTweenAnimationType.Fade, new[] { + typeof(Light), +#if true // SPRITE_MARKER + typeof(SpriteRenderer), +#endif +#if true // UI_MARKER + typeof(Image), typeof(Text), typeof(CanvasGroup), +#endif + typeof(Renderer), + }}, +#if true // UI_MARKER + { DOTweenAnimationType.Text, new[] { typeof(Text) } }, +#endif + { DOTweenAnimationType.PunchPosition, new[] { +#if true // UI_MARKER + typeof(RectTransform), +#endif + typeof(Transform) + }}, + { DOTweenAnimationType.PunchRotation, new[] { typeof(Transform) } }, + { DOTweenAnimationType.PunchScale, new[] { typeof(Transform) } }, + { DOTweenAnimationType.ShakePosition, new[] { +#if true // UI_MARKER + typeof(RectTransform), +#endif + typeof(Transform) + }}, + { DOTweenAnimationType.ShakeRotation, new[] { typeof(Transform) } }, + { DOTweenAnimationType.ShakeScale, new[] { typeof(Transform) } }, + { DOTweenAnimationType.CameraAspect, new[] { typeof(Camera) } }, + { DOTweenAnimationType.CameraBackgroundColor, new[] { typeof(Camera) } }, + { DOTweenAnimationType.CameraFieldOfView, new[] { typeof(Camera) } }, + { DOTweenAnimationType.CameraOrthoSize, new[] { typeof(Camera) } }, + { DOTweenAnimationType.CameraPixelRect, new[] { typeof(Camera) } }, + { DOTweenAnimationType.CameraRect, new[] { typeof(Camera) } }, +#if true // UI_MARKER + { DOTweenAnimationType.UIWidthHeight, new[] { typeof(RectTransform) } }, +#endif + }; + +#if false // TK2D_MARKER + static readonly Dictionary _Tk2dAnimationTypeToComponent = new Dictionary() { + { DOTweenAnimationType.Scale, new[] { typeof(tk2dBaseSprite), typeof(tk2dTextMesh) } }, + { DOTweenAnimationType.Color, new[] { typeof(tk2dBaseSprite), typeof(tk2dTextMesh) } }, + { DOTweenAnimationType.Fade, new[] { typeof(tk2dBaseSprite), typeof(tk2dTextMesh) } }, + { DOTweenAnimationType.Text, new[] { typeof(tk2dTextMesh) } } + }; +#endif +#if true // TEXTMESHPRO_MARKER + static readonly Dictionary _TMPAnimationTypeToComponent = new Dictionary() { + { DOTweenAnimationType.Color, new[] { typeof(TextMeshPro), typeof(TextMeshProUGUI) } }, + { DOTweenAnimationType.Fade, new[] { typeof(TextMeshPro), typeof(TextMeshProUGUI) } }, + { DOTweenAnimationType.Text, new[] { typeof(TextMeshPro), typeof(TextMeshProUGUI) } } + }; +#endif + + static readonly string[] _AnimationType = new[] { + "None", + "Move", "LocalMove", + "Rotate", "LocalRotate", + "Scale", + "Color", "Fade", +#if true // UI_MARKER + "Text", +#endif +#if false // TK2D_MARKER + "Text", +#endif +#if true // TEXTMESHPRO_MARKER + "Text", +#endif +#if true // UI_MARKER + "UIWidthHeight", +#endif + "Punch/Position", "Punch/Rotation", "Punch/Scale", + "Shake/Position", "Shake/Rotation", "Shake/Scale", + "Camera/Aspect", "Camera/BackgroundColor", "Camera/FieldOfView", "Camera/OrthoSize", "Camera/PixelRect", "Camera/Rect" + }; + static string[] _animationTypeNoSlashes; // _AnimationType list without slashes in values + static string[] _datString; // String representation of DOTweenAnimation enum (here for caching reasons) + + DOTweenAnimation _src; + bool _runtimeEditMode; // If TRUE allows to change and save stuff at runtime + bool _refreshRequired; // If TRUE refreshes components data + int _totComponentsOnSrc; // Used to determine if a Component is added or removed from the source + bool _isLightSrc; // Used to determine if we're tweening a Light, to set the max Fade value to more than 1 +#pragma warning disable 414 + ChooseTargetMode _chooseTargetMode = ChooseTargetMode.None; +#pragma warning restore 414 + + static readonly GUIContent _GuiC_selfTarget_true = new GUIContent( + "SELF", "Will animate components on this gameObject" + ); + static readonly GUIContent _GuiC_selfTarget_false = new GUIContent( + "OTHER", "Will animate components on the given gameObject instead than on this one" + ); + static readonly GUIContent _GuiC_tweenTargetIsTargetGO_true = new GUIContent( + "Use As Tween Target", "Will set the tween target (via SetTarget, used to control a tween directly from a target) to the \"OTHER\" gameObject" + ); + static readonly GUIContent _GuiC_tweenTargetIsTargetGO_false = new GUIContent( + "Use As Tween Target", "Will set the tween target (via SetTarget, used to control a tween directly from a target) to the gameObject containing this animation, not the \"OTHER\" one" + ); + + #region MonoBehaviour Methods + + void OnEnable() + { + _src = target as DOTweenAnimation; + + onStartProperty = base.serializedObject.FindProperty("onStart"); + onPlayProperty = base.serializedObject.FindProperty("onPlay"); + onUpdateProperty = base.serializedObject.FindProperty("onUpdate"); + onStepCompleteProperty = base.serializedObject.FindProperty("onStepComplete"); + onCompleteProperty = base.serializedObject.FindProperty("onComplete"); + onRewindProperty = base.serializedObject.FindProperty("onRewind"); + onTweenCreatedProperty = base.serializedObject.FindProperty("onTweenCreated"); + + // Convert _AnimationType to _animationTypeNoSlashes + int len = _AnimationType.Length; + _animationTypeNoSlashes = new string[len]; + for (int i = 0; i < len; ++i) { + string a = _AnimationType[i]; + a = a.Replace("/", ""); + _animationTypeNoSlashes[i] = a; + } + } + + void OnDisable() + { + DOTweenPreviewManager.StopAllPreviews(); + } + + override public void OnInspectorGUI() + { + base.OnInspectorGUI(); + + GUILayout.Space(3); + EditorGUIUtils.SetGUIStyles(); + + bool playMode = Application.isPlaying; + _runtimeEditMode = _runtimeEditMode && playMode; + + GUILayout.BeginHorizontal(); + EditorGUIUtils.InspectorLogo(); + GUILayout.Label(_src.animationType.ToString() + (string.IsNullOrEmpty(_src.id) ? "" : " [" + _src.id + "]"), EditorGUIUtils.sideLogoIconBoldLabelStyle); + // Up-down buttons + GUILayout.FlexibleSpace(); + if (GUILayout.Button("▲", DeGUI.styles.button.toolIco)) UnityEditorInternal.ComponentUtility.MoveComponentUp(_src); + if (GUILayout.Button("▼", DeGUI.styles.button.toolIco)) UnityEditorInternal.ComponentUtility.MoveComponentDown(_src); + GUILayout.EndHorizontal(); + + if (playMode) { + if (_runtimeEditMode) { + + } else { + GUILayout.Space(8); + GUILayout.Label("Animation Editor disabled while in play mode", EditorGUIUtils.wordWrapLabelStyle); + if (!_src.isActive) { + GUILayout.Label("This animation has been toggled as inactive and won't be generated", EditorGUIUtils.wordWrapLabelStyle); + GUI.enabled = false; + } + if (GUILayout.Button(new GUIContent("Activate Edit Mode", "Switches to Runtime Edit Mode, where you can change animations values and restart them"))) { + _runtimeEditMode = true; + } + GUILayout.Label("NOTE: when using DOPlayNext, the sequence is determined by the DOTweenAnimation Components order in the target GameObject's Inspector", EditorGUIUtils.wordWrapLabelStyle); + GUILayout.Space(10); + if (!_runtimeEditMode) return; + } + } + + Undo.RecordObject(_src, "DOTween Animation"); + +// _src.isValid = Validate(); // Moved down + + EditorGUIUtility.labelWidth = 110; + + if (playMode) { + GUILayout.Space(4); + DeGUILayout.Toolbar("Edit Mode Commands"); + DeGUILayout.BeginVBox(DeGUI.styles.box.stickyTop); + GUILayout.BeginHorizontal(); + if (GUILayout.Button("TogglePause")) _src.tween.TogglePause(); + if (GUILayout.Button("Rewind")) _src.tween.Rewind(); + if (GUILayout.Button("Restart")) _src.tween.Restart(); + GUILayout.EndHorizontal(); + if (GUILayout.Button("Commit changes and restart")) { + _src.tween.Rewind(); + _src.tween.Kill(); + if (_src.isValid) { + _src.CreateTween(); + _src.tween.Play(); + } + } + GUILayout.Label("To apply your changes when exiting Play mode, use the Component's upper right menu and choose \"Copy Component\", then \"Paste Component Values\" after exiting Play mode", DeGUI.styles.label.wordwrap); + DeGUILayout.EndVBox(); + } else { + bool hasManager = _src.GetComponent() != null; + if (!hasManager) { + if (GUILayout.Button(new GUIContent("Add Manager", "Adds a manager component which allows you to choose additional options for this gameObject"))) { + _src.gameObject.AddComponent(); + } + } + } + + // Preview in editor + bool isPreviewing = DOTweenPreviewManager.PreviewGUI(_src); + + EditorGUI.BeginDisabledGroup(isPreviewing); + // Choose target + GUILayout.BeginHorizontal(); + _src.isActive = EditorGUILayout.Toggle(new GUIContent("", "If unchecked, this animation will not be created"), _src.isActive, GUILayout.Width(14)); + EditorGUI.BeginChangeCheck(); + EditorGUI.BeginChangeCheck(); + _src.targetIsSelf = DeGUILayout.ToggleButton( + _src.targetIsSelf, _src.targetIsSelf ? _GuiC_selfTarget_true : _GuiC_selfTarget_false, + new Color(1f, 0.78f, 0f), DeGUI.colors.bg.toggleOn, new Color(0.33f, 0.14f, 0.02f), DeGUI.colors.content.toggleOn, + null, GUILayout.Width(47) + ); + bool innerChanged = EditorGUI.EndChangeCheck(); + if (innerChanged) { + _src.targetGO = null; + GUI.changed = true; + } + if (_src.targetIsSelf) GUILayout.Label(_GuiC_selfTarget_true.tooltip); + else { + using (new DeGUI.ColorScope(null, null, _src.targetGO == null ? Color.red : Color.white)) { + _src.targetGO = (GameObject)EditorGUILayout.ObjectField(_src.targetGO, typeof(GameObject), true); + } + _src.tweenTargetIsTargetGO = DeGUILayout.ToggleButton( + _src.tweenTargetIsTargetGO, _src.tweenTargetIsTargetGO ? _GuiC_tweenTargetIsTargetGO_true : _GuiC_tweenTargetIsTargetGO_false, + GUILayout.Width(131) + ); + } + bool check = EditorGUI.EndChangeCheck(); + if (check) _refreshRequired = true; + GUILayout.EndHorizontal(); + + GameObject targetGO = _src.targetIsSelf ? _src.gameObject : _src.targetGO; + + if (targetGO == null) { + // Uses external target gameObject but it's not set + if (_src.targetGO != null || _src.target != null) { + _src.targetGO = null; + _src.target = null; + GUI.changed = true; + } + } else { + GUILayout.BeginHorizontal(); + DOTweenAnimationType prevAnimType = _src.animationType; +// _src.animationType = (DOTweenAnimationType)EditorGUILayout.EnumPopup(_src.animationType, EditorGUIUtils.popupButton); + GUI.enabled = GUI.enabled && _src.isActive; + _src.animationType = AnimationToDOTweenAnimationType(_AnimationType[EditorGUILayout.Popup(DOTweenAnimationTypeToPopupId(_src.animationType), _AnimationType)]); + _src.autoPlay = DeGUILayout.ToggleButton(_src.autoPlay, new GUIContent("AutoPlay", "If selected, the tween will play automatically")); + _src.autoKill = DeGUILayout.ToggleButton(_src.autoKill, new GUIContent("AutoKill", "If selected, the tween will be killed when it completes, and won't be reusable")); + GUILayout.EndHorizontal(); + if (prevAnimType != _src.animationType) { + // Set default optional values based on animation type + _src.endValueTransform = null; + _src.useTargetAsV3 = false; + switch (_src.animationType) { + case DOTweenAnimationType.Move: + case DOTweenAnimationType.LocalMove: + case DOTweenAnimationType.Rotate: + case DOTweenAnimationType.LocalRotate: + case DOTweenAnimationType.Scale: + _src.endValueV3 = Vector3.zero; + _src.endValueFloat = 0; + _src.optionalBool0 = _src.animationType == DOTweenAnimationType.Scale; + break; + case DOTweenAnimationType.UIWidthHeight: + _src.endValueV3 = Vector3.zero; + _src.endValueFloat = 0; + _src.optionalBool0 = _src.animationType == DOTweenAnimationType.UIWidthHeight; + break; + case DOTweenAnimationType.Color: + case DOTweenAnimationType.Fade: + _isLightSrc = targetGO.GetComponent() != null; + _src.endValueFloat = 0; + break; + case DOTweenAnimationType.Text: + _src.optionalBool0 = true; + break; + case DOTweenAnimationType.PunchPosition: + case DOTweenAnimationType.PunchRotation: + case DOTweenAnimationType.PunchScale: + _src.endValueV3 = _src.animationType == DOTweenAnimationType.PunchRotation ? new Vector3(0, 180, 0) : Vector3.one; + _src.optionalFloat0 = 1; + _src.optionalInt0 = 10; + _src.optionalBool0 = false; + break; + case DOTweenAnimationType.ShakePosition: + case DOTweenAnimationType.ShakeRotation: + case DOTweenAnimationType.ShakeScale: + _src.endValueV3 = _src.animationType == DOTweenAnimationType.ShakeRotation ? new Vector3(90, 90, 90) : Vector3.one; + _src.optionalInt0 = 10; + _src.optionalFloat0 = 90; + _src.optionalBool0 = false; + break; + case DOTweenAnimationType.CameraAspect: + case DOTweenAnimationType.CameraFieldOfView: + case DOTweenAnimationType.CameraOrthoSize: + _src.endValueFloat = 0; + break; + case DOTweenAnimationType.CameraPixelRect: + case DOTweenAnimationType.CameraRect: + _src.endValueRect = new Rect(0, 0, 0, 0); + break; + } + } + if (_src.animationType == DOTweenAnimationType.None) { + _src.isValid = false; + if (GUI.changed) EditorUtility.SetDirty(_src); + return; + } + + if (_refreshRequired || prevAnimType != _src.animationType || ComponentsChanged()) { + _refreshRequired = false; + _src.isValid = Validate(targetGO); + // See if we need to choose between multiple targets +#if true // UI_MARKER + if (_src.animationType == DOTweenAnimationType.Fade && targetGO.GetComponent() != null && targetGO.GetComponent() != null) { + _chooseTargetMode = ChooseTargetMode.BetweenCanvasGroupAndImage; + // Reassign target and forcedTargetType if lost + if (_src.forcedTargetType == TargetType.Unset) _src.forcedTargetType = _src.targetType; + switch (_src.forcedTargetType) { + case TargetType.CanvasGroup: + _src.target = targetGO.GetComponent(); + break; + case TargetType.Image: + _src.target = targetGO.GetComponent(); + break; + } + } else { +#endif + _chooseTargetMode = ChooseTargetMode.None; + _src.forcedTargetType = TargetType.Unset; +#if true // UI_MARKER + } +#endif + } + + if (!_src.isValid) { + GUI.color = Color.red; + GUILayout.BeginVertical(GUI.skin.box); + GUILayout.Label("No valid Component was found for the selected animation", EditorGUIUtils.wordWrapLabelStyle); + GUILayout.EndVertical(); + GUI.color = Color.white; + if (GUI.changed) EditorUtility.SetDirty(_src); + return; + } + +#if true // UI_MARKER + // Special cases in which multiple target types could be used (set after validation) + if (_chooseTargetMode == ChooseTargetMode.BetweenCanvasGroupAndImage && _src.forcedTargetType != TargetType.Unset) { + FadeTargetType fadeTargetType = (FadeTargetType)Enum.Parse(typeof(FadeTargetType), _src.forcedTargetType.ToString()); + TargetType prevTargetType = _src.forcedTargetType; + _src.forcedTargetType = (TargetType)Enum.Parse(typeof(TargetType), EditorGUILayout.EnumPopup(_src.animationType + " Target", fadeTargetType).ToString()); + if (_src.forcedTargetType != prevTargetType) { + // Target type change > assign correct target + switch (_src.forcedTargetType) { + case TargetType.CanvasGroup: + _src.target = targetGO.GetComponent(); + break; + case TargetType.Image: + _src.target = targetGO.GetComponent(); + break; + } + } + } +#endif + + GUILayout.BeginHorizontal(); + _src.duration = EditorGUILayout.FloatField("Duration", _src.duration); + if (_src.duration < 0) _src.duration = 0; + _src.isSpeedBased = DeGUILayout.ToggleButton(_src.isSpeedBased, new GUIContent("SpeedBased", "If selected, the duration will count as units/degree x second"), DeGUI.styles.button.tool, GUILayout.Width(75)); + GUILayout.EndHorizontal(); + _src.delay = EditorGUILayout.FloatField("Delay", _src.delay); + if (_src.delay < 0) _src.delay = 0; + _src.isIndependentUpdate = EditorGUILayout.Toggle("Ignore TimeScale", _src.isIndependentUpdate); + _src.easeType = EditorGUIUtils.FilteredEasePopup(_src.easeType); + if (_src.easeType == Ease.INTERNAL_Custom) { + _src.easeCurve = EditorGUILayout.CurveField(" Ease Curve", _src.easeCurve); + } + _src.loops = EditorGUILayout.IntField(new GUIContent("Loops", "Set to -1 for infinite loops"), _src.loops); + if (_src.loops < -1) _src.loops = -1; + if (_src.loops > 1 || _src.loops == -1) + _src.loopType = (LoopType)EditorGUILayout.EnumPopup(" Loop Type", _src.loopType); + _src.id = EditorGUILayout.TextField("ID", _src.id); + + bool canBeRelative = true; + // End value and eventual specific options + switch (_src.animationType) { + case DOTweenAnimationType.Move: + case DOTweenAnimationType.LocalMove: + GUIEndValueV3(targetGO, _src.animationType == DOTweenAnimationType.Move); + _src.optionalBool0 = EditorGUILayout.Toggle(" Snapping", _src.optionalBool0); + canBeRelative = !_src.useTargetAsV3; + break; + case DOTweenAnimationType.Rotate: + case DOTweenAnimationType.LocalRotate: + bool isRigidbody2D = DOTweenModuleUtils.Physics.HasRigidbody2D(_src); + if (isRigidbody2D) GUIEndValueFloat(); + else { + GUIEndValueV3(targetGO); + _src.optionalRotationMode = (RotateMode)EditorGUILayout.EnumPopup(" Rotation Mode", _src.optionalRotationMode); + } + break; + case DOTweenAnimationType.Scale: + if (_src.optionalBool0) GUIEndValueFloat(); + else GUIEndValueV3(targetGO); + _src.optionalBool0 = EditorGUILayout.Toggle("Uniform Scale", _src.optionalBool0); + break; + case DOTweenAnimationType.UIWidthHeight: + if (_src.optionalBool0) GUIEndValueFloat(); + else GUIEndValueV2(); + _src.optionalBool0 = EditorGUILayout.Toggle("Uniform Scale", _src.optionalBool0); + break; + case DOTweenAnimationType.Color: + GUIEndValueColor(); + canBeRelative = false; + break; + case DOTweenAnimationType.Fade: + GUIEndValueFloat(); + if (_src.endValueFloat < 0) _src.endValueFloat = 0; + if (!_isLightSrc && _src.endValueFloat > 1) _src.endValueFloat = 1; + canBeRelative = false; + break; + case DOTweenAnimationType.Text: + GUIEndValueString(); + _src.optionalBool0 = EditorGUILayout.Toggle("Rich Text Enabled", _src.optionalBool0); + _src.optionalScrambleMode = (ScrambleMode)EditorGUILayout.EnumPopup("Scramble Mode", _src.optionalScrambleMode); + _src.optionalString = EditorGUILayout.TextField(new GUIContent("Custom Scramble", "Custom characters to use in case of ScrambleMode.Custom"), _src.optionalString); + break; + case DOTweenAnimationType.PunchPosition: + case DOTweenAnimationType.PunchRotation: + case DOTweenAnimationType.PunchScale: + GUIEndValueV3(targetGO); + canBeRelative = false; + _src.optionalInt0 = EditorGUILayout.IntSlider(new GUIContent(" Vibrato", "How much will the punch vibrate"), _src.optionalInt0, 1, 50); + _src.optionalFloat0 = EditorGUILayout.Slider(new GUIContent(" Elasticity", "How much the vector will go beyond the starting position when bouncing backwards"), _src.optionalFloat0, 0, 1); + if (_src.animationType == DOTweenAnimationType.PunchPosition) _src.optionalBool0 = EditorGUILayout.Toggle(" Snapping", _src.optionalBool0); + break; + case DOTweenAnimationType.ShakePosition: + case DOTweenAnimationType.ShakeRotation: + case DOTweenAnimationType.ShakeScale: + GUIEndValueV3(targetGO); + canBeRelative = false; + _src.optionalInt0 = EditorGUILayout.IntSlider(new GUIContent(" Vibrato", "How much will the shake vibrate"), _src.optionalInt0, 1, 50); + _src.optionalFloat0 = EditorGUILayout.Slider(new GUIContent(" Randomness", "The shake randomness"), _src.optionalFloat0, 0, 90); + if (_src.animationType == DOTweenAnimationType.ShakePosition) _src.optionalBool0 = EditorGUILayout.Toggle(" Snapping", _src.optionalBool0); + break; + case DOTweenAnimationType.CameraAspect: + case DOTweenAnimationType.CameraFieldOfView: + case DOTweenAnimationType.CameraOrthoSize: + GUIEndValueFloat(); + canBeRelative = false; + break; + case DOTweenAnimationType.CameraBackgroundColor: + GUIEndValueColor(); + canBeRelative = false; + break; + case DOTweenAnimationType.CameraPixelRect: + case DOTweenAnimationType.CameraRect: + GUIEndValueRect(); + canBeRelative = false; + break; + } + + // Final settings + if (canBeRelative) _src.isRelative = EditorGUILayout.Toggle(" Relative", _src.isRelative); + + // Events + AnimationInspectorGUI.AnimationEvents(this, _src); + } + EditorGUI.EndDisabledGroup(); + + if (GUI.changed) EditorUtility.SetDirty(_src); + } + + #endregion + + #region Methods + + // Returns TRUE if the Component layout on the src gameObject changed (a Component was added or removed) + bool ComponentsChanged() + { + int prevTotComponentsOnSrc = _totComponentsOnSrc; + _totComponentsOnSrc = _src.gameObject.GetComponents().Length; + return prevTotComponentsOnSrc != _totComponentsOnSrc; + } + + // Checks if a Component that can be animated with the given animationType is attached to the src + bool Validate(GameObject targetGO) + { + if (_src.animationType == DOTweenAnimationType.None) return false; + + Component srcTarget; + // First check for external plugins +#if false // TK2D_MARKER + if (_Tk2dAnimationTypeToComponent.ContainsKey(_src.animationType)) { + foreach (Type t in _Tk2dAnimationTypeToComponent[_src.animationType]) { + srcTarget = targetGO.GetComponent(t); + if (srcTarget != null) { + _src.target = srcTarget; + _src.targetType = DOTweenAnimation.TypeToDOTargetType(t); + return true; + } + } + } +#endif +#if true // TEXTMESHPRO_MARKER + if (_TMPAnimationTypeToComponent.ContainsKey(_src.animationType)) { + foreach (Type t in _TMPAnimationTypeToComponent[_src.animationType]) { + srcTarget = targetGO.GetComponent(t); + if (srcTarget != null) { + _src.target = srcTarget; + _src.targetType = DOTweenAnimation.TypeToDOTargetType(t); + return true; + } + } + } +#endif + // Then check for regular stuff + if (_AnimationTypeToComponent.ContainsKey(_src.animationType)) { + foreach (Type t in _AnimationTypeToComponent[_src.animationType]) { + srcTarget = targetGO.GetComponent(t); + if (srcTarget != null) { + _src.target = srcTarget; + _src.targetType = DOTweenAnimation.TypeToDOTargetType(t); + return true; + } + } + } + return false; + } + + DOTweenAnimationType AnimationToDOTweenAnimationType(string animation) + { + if (_datString == null) _datString = Enum.GetNames(typeof(DOTweenAnimationType)); + animation = animation.Replace("/", ""); + return (DOTweenAnimationType)(Array.IndexOf(_datString, animation)); + } + int DOTweenAnimationTypeToPopupId(DOTweenAnimationType animation) + { + return Array.IndexOf(_animationTypeNoSlashes, animation.ToString()); + } + + #endregion + + #region GUI Draw Methods + + void GUIEndValueFloat() + { + GUILayout.BeginHorizontal(); + GUIToFromButton(); + _src.endValueFloat = EditorGUILayout.FloatField(_src.endValueFloat); + GUILayout.EndHorizontal(); + } + + void GUIEndValueColor() + { + GUILayout.BeginHorizontal(); + GUIToFromButton(); + _src.endValueColor = EditorGUILayout.ColorField(_src.endValueColor); + GUILayout.EndHorizontal(); + } + + void GUIEndValueV3(GameObject targetGO, bool optionalTransform = false) + { + GUILayout.BeginHorizontal(); + GUIToFromButton(); + if (_src.useTargetAsV3) { + Transform prevT = _src.endValueTransform; + _src.endValueTransform = EditorGUILayout.ObjectField(_src.endValueTransform, typeof(Transform), true) as Transform; + if (_src.endValueTransform != prevT && _src.endValueTransform != null) { +#if true // UI_MARKER + // Check that it's a Transform for a Transform or a RectTransform for a RectTransform + if (targetGO.GetComponent() != null) { + if (_src.endValueTransform.GetComponent() == null) { + EditorUtility.DisplayDialog("DOTween Pro", "For Unity UI elements, the target must also be a UI element", "Ok"); + _src.endValueTransform = null; + } + } else if (_src.endValueTransform.GetComponent() != null) { + EditorUtility.DisplayDialog("DOTween Pro", "You can't use a UI target for a non UI object", "Ok"); + _src.endValueTransform = null; + } +#endif + } + } else { + _src.endValueV3 = EditorGUILayout.Vector3Field("", _src.endValueV3, GUILayout.Height(16)); + } + if (optionalTransform) { + if (GUILayout.Button(_src.useTargetAsV3 ? "target" : "value", EditorGUIUtils.sideBtStyle, GUILayout.Width(44))) _src.useTargetAsV3 = !_src.useTargetAsV3; + } + GUILayout.EndHorizontal(); +#if true // UI_MARKER + if (_src.useTargetAsV3 && _src.endValueTransform != null && _src.target is RectTransform) { + EditorGUILayout.HelpBox("NOTE: when using a UI target, the tween will be created during Start instead of Awake", MessageType.Info); + } +#endif + } + + void GUIEndValueV2() + { + GUILayout.BeginHorizontal(); + GUIToFromButton(); + _src.endValueV2 = EditorGUILayout.Vector2Field("", _src.endValueV2, GUILayout.Height(16)); + GUILayout.EndHorizontal(); + } + + void GUIEndValueString() + { + GUILayout.BeginHorizontal(); + GUIToFromButton(); + _src.endValueString = EditorGUILayout.TextArea(_src.endValueString, EditorGUIUtils.wordWrapTextArea); + GUILayout.EndHorizontal(); + } + + void GUIEndValueRect() + { + GUILayout.BeginHorizontal(); + GUIToFromButton(); + _src.endValueRect = EditorGUILayout.RectField(_src.endValueRect); + GUILayout.EndHorizontal(); + } + + void GUIToFromButton() + { + if (GUILayout.Button(_src.isFrom ? "FROM" : "TO", EditorGUIUtils.sideBtStyle, GUILayout.Width(90))) _src.isFrom = !_src.isFrom; + GUILayout.Space(16); + } + + #endregion + } +} diff --git a/Assets/Demigiant/DOTweenPro/Editor/DOTweenAnimationInspector.cs.meta b/Assets/Demigiant/DOTweenPro/Editor/DOTweenAnimationInspector.cs.meta new file mode 100644 index 0000000..a3905ce --- /dev/null +++ b/Assets/Demigiant/DOTweenPro/Editor/DOTweenAnimationInspector.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: e0203fd81362bab4d842d87ad09ee76e +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DOTweenPro/Editor/DOTweenPreviewManager.cs b/Assets/Demigiant/DOTweenPro/Editor/DOTweenPreviewManager.cs new file mode 100644 index 0000000..8e1d35b --- /dev/null +++ b/Assets/Demigiant/DOTweenPro/Editor/DOTweenPreviewManager.cs @@ -0,0 +1,255 @@ +// Author: Daniele Giardini - http://www.demigiant.com +// Created: 2015/03/12 16:03 + +using System; +using System.Collections.Generic; +using DG.DemiEditor; +using DG.DemiLib; +using DG.Tweening; +using DG.Tweening.Core; +using UnityEditor; +using UnityEditorInternal; +using UnityEngine; +using Object = UnityEngine.Object; + +namespace DG.DOTweenEditor +{ + public static class DOTweenPreviewManager + { + static bool _previewOnlyIfSetToAutoPlay = true; + static readonly Dictionary _AnimationToTween = new Dictionary(); + static readonly List _TmpKeys = new List(); + + #region Public Methods & GUI + + /// + /// Returns TRUE if its actually previewing animations + /// + public static bool PreviewGUI(DOTweenAnimation src) + { + if (EditorApplication.isPlaying) return false; + + Styles.Init(); + + bool isPreviewing = _AnimationToTween.Count > 0; + bool isPreviewingThis = isPreviewing && _AnimationToTween.ContainsKey(src); + + // Preview in editor + GUI.backgroundColor = isPreviewing + ? new DeSkinColor(new Color(0.49f, 0.8f, 0.86f), new Color(0.15f, 0.26f, 0.35f)) + : new DeSkinColor(Color.white, new Color(0.13f, 0.13f, 0.13f)); + GUILayout.BeginVertical(Styles.previewBox); + DeGUI.ResetGUIColors(); + GUILayout.BeginHorizontal(); + GUILayout.Label("Preview Mode - Experimental", Styles.previewLabel); + _previewOnlyIfSetToAutoPlay = DeGUILayout.ToggleButton( + _previewOnlyIfSetToAutoPlay, + new GUIContent("AutoPlay only", "If toggled only previews animations that have AutoPlay turned ON"), + Styles.btOption + ); + GUILayout.EndHorizontal(); + GUILayout.Space(1); + // Preview - Play + GUILayout.BeginHorizontal(); + EditorGUI.BeginDisabledGroup( + isPreviewingThis || src.animationType == DOTweenAnimationType.None + || !src.isActive || _previewOnlyIfSetToAutoPlay && !src.autoPlay + ); + if (GUILayout.Button("► Play", Styles.btPreview)) { + if (!isPreviewing) StartupGlobalPreview(); + AddAnimationToGlobalPreview(src); + } + EditorGUI.EndDisabledGroup(); + EditorGUI.BeginDisabledGroup(isPreviewing); + if (GUILayout.Button("► Play All on GameObject", Styles.btPreview)) { + if (!isPreviewing) StartupGlobalPreview(); + DOTweenAnimation[] anims = src.gameObject.GetComponents(); + foreach (DOTweenAnimation anim in anims) AddAnimationToGlobalPreview(anim); + } + if (GUILayout.Button("► Play All in Scene", Styles.btPreview)) { + if (!isPreviewing) StartupGlobalPreview(); + DOTweenAnimation[] anims = Object.FindObjectsOfType(); + foreach (DOTweenAnimation anim in anims) AddAnimationToGlobalPreview(anim); + } + EditorGUI.EndDisabledGroup(); + GUILayout.EndHorizontal(); + // Preview - Stop + GUILayout.BeginHorizontal(); + EditorGUI.BeginDisabledGroup(!isPreviewingThis); + if (GUILayout.Button("■ Stop", Styles.btPreview)) { + if (_AnimationToTween.ContainsKey(src)) StopPreview(_AnimationToTween[src].tween); + } + EditorGUI.EndDisabledGroup(); + EditorGUI.BeginDisabledGroup(!isPreviewing); + if (GUILayout.Button("■ Stop All on GameObject", Styles.btPreview)) { + StopPreview(src.gameObject); + } + if (GUILayout.Button("■ Stop All in Scene", Styles.btPreview)) { + StopAllPreviews(); + } + EditorGUI.EndDisabledGroup(); + GUILayout.EndHorizontal(); + if (isPreviewing) { + int playingTweens = 0; + int completedTweens = 0; + int pausedTweens = 0; + foreach (KeyValuePair kvp in _AnimationToTween) { + Tween t = kvp.Value.tween; + if (t.IsPlaying()) playingTweens++; + else if (t.IsComplete()) completedTweens++; + else pausedTweens++; + } + GUILayout.Label("Playing Tweens: " + playingTweens, Styles.previewStatusLabel); + GUILayout.Label("Completed Tweens: " + completedTweens, Styles.previewStatusLabel); +// GUILayout.Label("Paused Tweens: " + playingTweens); + } + GUILayout.EndVertical(); + + return isPreviewing; + } + +#if !(UNITY_4_3 || UNITY_4_4 || UNITY_4_5 || UNITY_4_6 || UNITY_5) + public static void StopAllPreviews(PlayModeStateChange state) + { + StopAllPreviews(); + } +#endif + + public static void StopAllPreviews() + { + _TmpKeys.Clear(); + foreach (KeyValuePair kvp in _AnimationToTween) { + _TmpKeys.Add(kvp.Key); + } + StopPreview(_TmpKeys); + _TmpKeys.Clear(); + _AnimationToTween.Clear(); + + DOTweenEditorPreview.Stop(); +#if UNITY_4_3 || UNITY_4_4 || UNITY_4_5 || UNITY_4_6 || UNITY_5 + UnityEditor.EditorApplication.playmodeStateChanged -= StopAllPreviews; +#else + UnityEditor.EditorApplication.playModeStateChanged -= StopAllPreviews; +#endif +// EditorApplication.playmodeStateChanged -= StopAllPreviews; + + InternalEditorUtility.RepaintAllViews(); + } + +#endregion + +#region Methods + + static void StartupGlobalPreview() + { + DOTweenEditorPreview.Start(); +#if UNITY_4_3 || UNITY_4_4 || UNITY_4_5 || UNITY_4_6 || UNITY_5 + UnityEditor.EditorApplication.playmodeStateChanged += StopAllPreviews; +#else + UnityEditor.EditorApplication.playModeStateChanged += StopAllPreviews; +#endif +// EditorApplication.playmodeStateChanged += StopAllPreviews; + } + + static void AddAnimationToGlobalPreview(DOTweenAnimation src) + { + if (!src.isActive) return; // Ignore sources whose tweens have been set to inactive + if (_previewOnlyIfSetToAutoPlay && !src.autoPlay) return; + + Tween t = src.CreateEditorPreview(); + _AnimationToTween.Add(src, new TweenInfo(src, t, src.isFrom)); + // Tween setup + DOTweenEditorPreview.PrepareTweenForPreview(t); + } + + static void StopPreview(GameObject go) + { + _TmpKeys.Clear(); + foreach (KeyValuePair kvp in _AnimationToTween) { + if (kvp.Key.gameObject != go) continue; + _TmpKeys.Add(kvp.Key); + } + StopPreview(_TmpKeys); + _TmpKeys.Clear(); + + if (_AnimationToTween.Count == 0) StopAllPreviews(); + else InternalEditorUtility.RepaintAllViews(); + } + + static void StopPreview(Tween t) + { + TweenInfo tInfo = null; + foreach (KeyValuePair kvp in _AnimationToTween) { + if (kvp.Value.tween != t) continue; + tInfo = kvp.Value; + _AnimationToTween.Remove(kvp.Key); + break; + } + if (tInfo == null) { + Debug.LogWarning("DOTween Preview ► Couldn't find tween to stop"); + return; + } + if (tInfo.isFrom) tInfo.tween.Complete(); + else tInfo.tween.Rewind(); + tInfo.tween.Kill(); + EditorUtility.SetDirty(tInfo.animation); // Refresh views + + if (_AnimationToTween.Count == 0) StopAllPreviews(); + else InternalEditorUtility.RepaintAllViews(); + } + + // Stops while iterating inversely, which deals better with tweens that overwrite each other + static void StopPreview(List keys) + { + for (int i = keys.Count - 1; i > -1; --i) { + DOTweenAnimation anim = keys[i]; + TweenInfo tInfo = _AnimationToTween[anim]; + if (tInfo.isFrom) tInfo.tween.Complete(); + else tInfo.tween.Rewind(); + tInfo.tween.Kill(); + EditorUtility.SetDirty(anim); // Refresh views + _AnimationToTween.Remove(anim); + } + } + +#endregion + + // █████████████████████████████████████████████████████████████████████████████████████████████████████████████████████ + // ███ INTERNAL CLASSES ████████████████████████████████████████████████████████████████████████████████████████████████ + // █████████████████████████████████████████████████████████████████████████████████████████████████████████████████████ + + class TweenInfo + { + public DOTweenAnimation animation; + public Tween tween; + public bool isFrom; + public TweenInfo(DOTweenAnimation animation, Tween tween, bool isFrom) + { + this.animation = animation; + this.tween = tween; + this.isFrom = isFrom; + } + } + + static class Styles + { + static bool _initialized; + + public static GUIStyle previewBox, previewLabel, btOption, btPreview, previewStatusLabel; + + public static void Init() + { + if (_initialized) return; + + _initialized = true; + + previewBox = new GUIStyle(GUI.skin.box).Clone().Padding(1, 1, 0, 3) + .Background(DeStylePalette.squareBorderCurved_darkBorders).Border(7, 7, 7, 7); + previewLabel = new GUIStyle(GUI.skin.label).Clone(10, FontStyle.Bold).Padding(1, 0, 3, 0).Margin(3, 6, 0, 0).StretchWidth(false); + btOption = DeGUI.styles.button.bBlankBorderCompact.MarginBottom(2).MarginRight(4); + btPreview = EditorStyles.miniButton.Clone(Format.RichText); + previewStatusLabel = EditorStyles.miniLabel.Clone().Padding(4, 0, 0, 0).Margin(0); + } + } + } +} diff --git a/Assets/Demigiant/DOTweenPro/Editor/DOTweenPreviewManager.cs.meta b/Assets/Demigiant/DOTweenPro/Editor/DOTweenPreviewManager.cs.meta new file mode 100644 index 0000000..1586a48 --- /dev/null +++ b/Assets/Demigiant/DOTweenPro/Editor/DOTweenPreviewManager.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 22292a5f27a9a644ba9e6ad1bf863531 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DOTweenPro/Editor/DOTweenProEditor.XML b/Assets/Demigiant/DOTweenPro/Editor/DOTweenProEditor.XML new file mode 100644 index 0000000..ad80aef --- /dev/null +++ b/Assets/Demigiant/DOTweenPro/Editor/DOTweenProEditor.XML @@ -0,0 +1,18 @@ + + + + DOTweenProEditor + + + + + Custom colors + + + + + Needs to be overridden in order to initialize new styles added from inherited classes + + + + diff --git a/Assets/Demigiant/DOTweenPro/Editor/DOTweenProEditor.XML.meta b/Assets/Demigiant/DOTweenPro/Editor/DOTweenProEditor.XML.meta new file mode 100644 index 0000000..5328cb8 --- /dev/null +++ b/Assets/Demigiant/DOTweenPro/Editor/DOTweenProEditor.XML.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: 753a4f4ed73b17143923101226957756 +TextScriptImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DOTweenPro/Editor/DOTweenProEditor.dll b/Assets/Demigiant/DOTweenPro/Editor/DOTweenProEditor.dll new file mode 100644 index 0000000..4253b6c Binary files /dev/null and b/Assets/Demigiant/DOTweenPro/Editor/DOTweenProEditor.dll differ diff --git a/Assets/Demigiant/DOTweenPro/Editor/DOTweenProEditor.dll.mdb b/Assets/Demigiant/DOTweenPro/Editor/DOTweenProEditor.dll.mdb new file mode 100644 index 0000000..fee33b9 Binary files /dev/null and b/Assets/Demigiant/DOTweenPro/Editor/DOTweenProEditor.dll.mdb differ diff --git a/Assets/Demigiant/DOTweenPro/Editor/DOTweenProEditor.dll.mdb.meta b/Assets/Demigiant/DOTweenPro/Editor/DOTweenProEditor.dll.mdb.meta new file mode 100644 index 0000000..dc73eda --- /dev/null +++ b/Assets/Demigiant/DOTweenPro/Editor/DOTweenProEditor.dll.mdb.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: ee3a420017f129443896310d9fab256b +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DOTweenPro/Editor/DOTweenProEditor.dll.meta b/Assets/Demigiant/DOTweenPro/Editor/DOTweenProEditor.dll.meta new file mode 100644 index 0000000..c980e74 --- /dev/null +++ b/Assets/Demigiant/DOTweenPro/Editor/DOTweenProEditor.dll.meta @@ -0,0 +1,21 @@ +fileFormatVersion: 2 +guid: a6402d4311c862b4eb1325590d6466af +PluginImporter: + externalObjects: {} + serializedVersion: 2 + iconMap: {} + executionOrder: {} + defineConstraints: [] + isPreloaded: 0 + isOverridable: 0 + isExplicitlyReferenced: 0 + validateReferences: 1 + platformData: + - first: + Any: + second: + enabled: 1 + settings: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DOTweenPro/readme.txt b/Assets/Demigiant/DOTweenPro/readme.txt new file mode 100644 index 0000000..9837c95 --- /dev/null +++ b/Assets/Demigiant/DOTweenPro/readme.txt @@ -0,0 +1,35 @@ +DOTween and DOTween Pro are copyright (c) 2014-2018 Daniele Giardini - Demigiant + +// IMPORTANT!!! ///////////////////////////////////////////// +// Upgrading DOTween from versions older than 1.2.000 /////// +// (or DOTween Pro older than 1.0.000) ////////////////////// +------------------------------------------------------------- +If you're upgrading your project from a version of DOTween older than 1.2.000 (or DOTween Pro older than 1.0.000) please follow these instructions carefully. +1) Import the new version in the same folder as the previous one, overwriting old files. A lot of errors will appear but don't worry +2) Close and reopen Unity (and your project). This is fundamental: skipping this step will cause a bloodbath +3) Open DOTween's Utility Panel (Tools > Demigiant > DOTween Utility Panel) if it doesn't open automatically, then press "Setup DOTween...": this will run the upgrade setup +4) From the Add/Remove Modules panel that opens, activate/deactivate Modules for Unity systems and for external assets (like TextMesh Pro) + +// GET STARTED ////////////////////////////////////////////// + +- After importing a new DOTween update, select DOTween's Utility Panel from the "Tools/Demigiant" menu (if it doesn't open automatically) and press the "Setup DOTween..." button to activate/deactivate Modules. You can also access a Preferences Tab from there to choose default settings for DOTween. + +// VISUAL SCRIPTING (PRO ONLY) +- To animate a gameObject, select it and choose "Add Component > DOTween > DOTween Animation" +- To animate a gameObject along a path, select it and choose "Add Component > DOTween > DOTween Path" + +// SCRIPTING +- In your code, add "using DG.Tweening" to each class where you want to use DOTween. +- You're ready to tween. Check out the links below for full documentation and license info. + + +// LINKS /////////////////////////////////////////////////////// + +DOTween website (documentation, examples, etc): http://dotween.demigiant.com +DOTween license: http://dotween.demigiant.com/license.php +DOTween repository (Google Code): https://code.google.com/p/dotween/ +Demigiant website (documentation, examples, etc): http://www.demigiant.com + +// NOTES ////////////////////////////////////////////////////// + +- DOTween's Utility Panel can be found under "Tools > Demigiant > DOTween Utility Panel" and also contains other useful options, plus a tab to set DOTween's preferences \ No newline at end of file diff --git a/Assets/Demigiant/DOTweenPro/readme.txt.meta b/Assets/Demigiant/DOTweenPro/readme.txt.meta new file mode 100644 index 0000000..17911b4 --- /dev/null +++ b/Assets/Demigiant/DOTweenPro/readme.txt.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: aa8f07903bf128e44a7d0b91a63dedab +TextScriptImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DemiLib.meta b/Assets/Demigiant/DemiLib.meta new file mode 100644 index 0000000..3e9c851 --- /dev/null +++ b/Assets/Demigiant/DemiLib.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: eb6786b91408a384cab1a4539b1ed736 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DemiLib/Core.meta b/Assets/Demigiant/DemiLib/Core.meta new file mode 100644 index 0000000..1e2cd4d --- /dev/null +++ b/Assets/Demigiant/DemiLib/Core.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 55f29a97a160512418d94be6e26dbea0 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DemiLib/Core/DemiLib.dll b/Assets/Demigiant/DemiLib/Core/DemiLib.dll new file mode 100644 index 0000000..fe47ea8 Binary files /dev/null and b/Assets/Demigiant/DemiLib/Core/DemiLib.dll differ diff --git a/Assets/Demigiant/DemiLib/Core/DemiLib.dll.mdb b/Assets/Demigiant/DemiLib/Core/DemiLib.dll.mdb new file mode 100644 index 0000000..d2887aa Binary files /dev/null and b/Assets/Demigiant/DemiLib/Core/DemiLib.dll.mdb differ diff --git a/Assets/Demigiant/DemiLib/Core/DemiLib.dll.mdb.meta b/Assets/Demigiant/DemiLib/Core/DemiLib.dll.mdb.meta new file mode 100644 index 0000000..4b7d047 --- /dev/null +++ b/Assets/Demigiant/DemiLib/Core/DemiLib.dll.mdb.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: 995cf2d9b4a41f840b3a41712e9b3bc0 +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DemiLib/Core/DemiLib.dll.meta b/Assets/Demigiant/DemiLib/Core/DemiLib.dll.meta new file mode 100644 index 0000000..c99073f --- /dev/null +++ b/Assets/Demigiant/DemiLib/Core/DemiLib.dll.meta @@ -0,0 +1,21 @@ +fileFormatVersion: 2 +guid: 54be29b67d0d29a478da2c6e5c62f091 +PluginImporter: + externalObjects: {} + serializedVersion: 2 + iconMap: {} + executionOrder: {} + defineConstraints: [] + isPreloaded: 0 + isOverridable: 0 + isExplicitlyReferenced: 0 + validateReferences: 1 + platformData: + - first: + Any: + second: + enabled: 1 + settings: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DemiLib/Core/DemiLib.xml b/Assets/Demigiant/DemiLib/Core/DemiLib.xml new file mode 100644 index 0000000..7246b6d --- /dev/null +++ b/Assets/Demigiant/DemiLib/Core/DemiLib.xml @@ -0,0 +1,156 @@ + + + + DemiLib + + + + + Set when calling DeGUI.BeginGUI + + + + + Stores a color palette, which can be passed to default DeGUI layouts when calling DeGUI.BeginGUI, + and changed at any time by calling DeGUI.ChangePalette. + You can inherit from this class to create custom color palettes with more hColor options. + + + + + Converts a HEX color to a Unity Color and returns it + + The HEX color, either with or without the initial # (accepts both regular and short format) + + + + Global colors + + + + + Background colors + + + + Editor background color + + + + Content colors + + + + + Extend this to replicate Unity's Scope system with any Unity version. + Thanks to Dmitriy Yukhanov for pointing this out and creating an initial version. + Expand this class to create scopes. + Example: + public class VBoxScope : DeScope + { + public VBoxScope(GUIStyle style) + { + BeginVBox(style); + } + + protected override void CloseScope() + { + EndVBox(); + } + } + Usage: + using (new VBoxScope(myStyle) { + // Do something + } + + + + + Contains both free and pro skins color variations, + and automatically returns the correct one when converted to Color + + + + + Used by DeHierarchy + + + + + Returns a list of all items whose gameObject is NULL, or NULL if there's no missing gameObjects. + + + + + If the item exists sets it, otherwise first creates it and then sets it + + + + + If the item exists sets it, otherwise first creates it and then sets it + + + + + Returns TRUE if the item existed and was removed. + + + + + Returns the customizedItem for the given gameObject, or NULL if none was found + + + + Must be univocal + + + Node position in editor GUI + + + Ids of all forward connected nodes. Length indicates how many forward connections are allowed. + Min length represents available connections from node. + + + + A serializable struct including a min and a max int value + + + + Min value + + + Max value + + + + Creates a new Range + + + + + Returns a random value within this range (min/max included) + + + + + A serializable struct including a min and a max float value + + + + Min value + + + Max value + + + + Creates a new Range + + + + + Returns a random value within this range (min/max included) + + + + diff --git a/Assets/Demigiant/DemiLib/Core/DemiLib.xml.meta b/Assets/Demigiant/DemiLib/Core/DemiLib.xml.meta new file mode 100644 index 0000000..2192b21 --- /dev/null +++ b/Assets/Demigiant/DemiLib/Core/DemiLib.xml.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: 9bf2564c9817bb34988453ae948954d2 +TextScriptImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DemiLib/Core/Editor.meta b/Assets/Demigiant/DemiLib/Core/Editor.meta new file mode 100644 index 0000000..ac21344 --- /dev/null +++ b/Assets/Demigiant/DemiLib/Core/Editor.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 1e3887b9d0c9c4348aa3af5507d175cf +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DemiLib/Core/Editor/DemiEditor.dll b/Assets/Demigiant/DemiLib/Core/Editor/DemiEditor.dll new file mode 100644 index 0000000..b949eaa Binary files /dev/null and b/Assets/Demigiant/DemiLib/Core/Editor/DemiEditor.dll differ diff --git a/Assets/Demigiant/DemiLib/Core/Editor/DemiEditor.dll.mdb b/Assets/Demigiant/DemiLib/Core/Editor/DemiEditor.dll.mdb new file mode 100644 index 0000000..cd6055f Binary files /dev/null and b/Assets/Demigiant/DemiLib/Core/Editor/DemiEditor.dll.mdb differ diff --git a/Assets/Demigiant/DemiLib/Core/Editor/DemiEditor.dll.mdb.meta b/Assets/Demigiant/DemiLib/Core/Editor/DemiEditor.dll.mdb.meta new file mode 100644 index 0000000..d7b402f --- /dev/null +++ b/Assets/Demigiant/DemiLib/Core/Editor/DemiEditor.dll.mdb.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: 2c20a7b4db3cd0a4a99bcf6218f92860 +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DemiLib/Core/Editor/DemiEditor.dll.meta b/Assets/Demigiant/DemiLib/Core/Editor/DemiEditor.dll.meta new file mode 100644 index 0000000..75149a3 --- /dev/null +++ b/Assets/Demigiant/DemiLib/Core/Editor/DemiEditor.dll.meta @@ -0,0 +1,21 @@ +fileFormatVersion: 2 +guid: 202f9ddaf2c1a8a429504f7f3cd7b84f +PluginImporter: + externalObjects: {} + serializedVersion: 2 + iconMap: {} + executionOrder: {} + defineConstraints: [] + isPreloaded: 0 + isOverridable: 0 + isExplicitlyReferenced: 0 + validateReferences: 1 + platformData: + - first: + Any: + second: + enabled: 1 + settings: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DemiLib/Core/Editor/DemiEditor.xml b/Assets/Demigiant/DemiLib/Core/Editor/DemiEditor.xml new file mode 100644 index 0000000..67e922d --- /dev/null +++ b/Assets/Demigiant/DemiLib/Core/Editor/DemiEditor.xml @@ -0,0 +1,1488 @@ + + + + DemiEditor + + + + + Utils to use he correct method based on Unity's version + + + + + Encodes to PNG using reflection to use correct method depending if editor is version 2017 or earlier + + + + + Returns the prefab parent by using different code on Unity 2018 or later + + + + + + + File utils + + + + Path slash for AssetDatabase format + + + Path slash to replace for AssetDatabase format + + + Current OS path slash + + + Path slash to replace on current OS + + + + Full path to project directory, without final slash. + + + + + Full path to project's Assets directory, without final slash. + + + + + Returns TRUE if the given path is an absolute path + + + + + Returns TRUE if the given path is an AssetDatabase path + + + + + Returns TRUE if the given GUID refers to a valid and existing project folder + + + + + Converts the given project-relative path to a full path + + + + + Converts the given full path to a project-relative path + + + + + Returns TRUE if the file/directory at the given path exists. + + Path, relative to Unity's project folder + + + + Validates the string as a valid fileName + (uses commonly accepted characters an all systems instead of system-specific ones). + BEWARE: doesn't check for reserved words + + string to replace + Minimum length for considering the string valid + + + + Returns the given string stripped of any invalid filename characters. + BEWARE: doesn't check for reserved words + + string to replace + Character to use as replacement for invalid ones + + + + Returns the given path with all slashes converted to the correct ones used by the system + + + + + Returns the asset path of the given GUID (relative to Unity project's folder), + or an empty string if either the GUID is invalid or the related path doesn't exist. + + + + + Checks if the given directory (full path) is empty or not + + + + + Deletes all files and subdirectories from the given directory + + + + Returns the adb path to the given ScriptableObject + + + Returns the adb path to the given MonoBehaviour + + + Returns the adb directory that contains the given ScriptableObject without final slash + + + Returns the adb directory that contains the given MonoBehaviour without final slash + + + + Returns the adb paths to the selected folders in the Project panel, or NULL if there is none. + Contrary to Selection.activeObject, which only returns folders selected in the right side of the panel, + this method also works with folders selected in the left side. + + + + + Sets the script execution order of the given MonoBehaviour + + + + + Gets the script execution order of the given MonoBehaviour + + + + + Precisely returns the last controlId assigned to a GUI element + + + + + Utilities for Editor Panels. + + + + + Connects to a asset. + If the asset already exists at the given path, loads it and returns it. + Otherwise, depending on the given parameters, either returns NULL or automatically creates it before loading and returning it. + + Asset type + File path (relative to Unity's project folder) + If TRUE and the requested asset doesn't exist, forces its creation + If TRUE also creates the path folders if they don't exist + + + + Returns TRUE if the given is dockable, FALSE if instead it's a utility window + + + + + + + Sets the icon and title of an editor window. Works with older versions of Unity, where the titleContent property wasn't available. + + Reference to the editor panel whose icon to set + Icon to apply + Title. If NULL doesn't change it + + + + Prefab utilities + + + + + Behaves as the Inspector's Apply button, applying any modification of this instance to the prefab parent + + + + + + Returns TRUe if a prefab instance has unapplied modifications, ignoring any modifications applied to the transform. + NOTE: this a somehow costly operation (since it generates GC) + + + + + Completely removes any prefab connection from the given prefab instances, by desotroing the original object and recreating it. + Returns a list with all the new elements created. + + Based on RodGreen's method (http://forum.unity3d.com/threads/82883-Breaking-connection-from-gameObject-to-prefab-for-good.?p=726602&viewfull=1#post726602) + + + + + + Completely removes any prefab connection from the given prefab instance, by desotroing the original object and recreating it. + + Based on RodGreen's method (http://forum.unity3d.com/threads/82883-Breaking-connection-from-gameObject-to-prefab-for-good.?p=726602&viewfull=1#post726602) + + + + + Calls the given action after the given delay + + + + Return the size of the editor game view, eventual extra bars excluded (meaning the true size of the game area) + + + + + + Clears all logs from Unity's console + + + + + Adds the given global define (if it's not already present) to all the + or only to the given , depending on passed parameters, + and returns TRUE if it was added, FALSE otherwise. + NOTE: when adding to all of them some legacy warnings might appear, which you can ignore. + + + to use. Leave NULL to add to all of them. + + + + Removes the given global define (if present) from all the + or only from the given , depending on passed parameters, + and returns TRUE if it was removed, FALSE otherwise. + NOTE: when removing from all of them some legacy warnings might appear, which you can ignore. + + + to use. Leave NULL to remove from all of them. + + + + Returns TRUE if the given global define is present in all the + or only in the given , depending on passed parameters. + + + to use. Leave NULL to check in all of them. + + + + Returns all components of type T in the currently open scene, or NULL if none could be found. + If you're on Unity 5 or later, and have DeEditorTools, use DeEditorToolsUtils.FindAllComponentsOfType + instead, which is more efficient. + + + + Nothing is being dragged + + + Dragging + + + Dragging concluced and accepted + + + Dragging concluced but item position didn't change + + + Dragging canceled + + + Dragging concluced but not accepted because too short + + + + Manages the dragging of GUI elements + + + + + True if a GUI element is currently being dragged + + + + + Return the current item being dragged, or NULL if there is none + + + + + Type of current item being dragged, or NULL if there is none + + + + + Starting index of current item being dragged, or NULL if there is none + + + + + Retrieves the eventual optional data stored via the StartDrag method + + + + + Starts a drag operation on a GUI element. + + ID for this drag operation (must be the same for both StartDrag and Drag + Reference to the current editor drawing the GUI (used when a Repaint is needed) + List containing the dragged item and all other relative draggable items + DraggableList index of the item being dragged + Optional data that can be retrieved via the static property + + + + Starts a drag operation on a GUI element. + + ID for this drag operation (must be the same for both StartDrag and Drag + Reference to the current editor drawing the GUI (used when a Repaint is needed) + List containing the dragged item and all other relative draggable items + DraggableList index of the item being dragged + Optional data that can be retrieved via the static property + + + + Call this after each draggable GUI block, to calculate and draw the current drag state + (or complete it if the mouse was released). + + ID for this drag operation (must be the same for both StartDrag and Drag + List containing the draggable item and all other relative draggable items + Current index of the draggable item being drawn + If NULL will calculate this automatically using . + Pass this if you're creating a drag between elements that don't use GUILayout + + + + Call this after each draggable GUI block, to calculate and draw the current drag state + (or complete it if the mouse was released). + + ID for this drag operation (must be the same for both StartDrag and Drag + List containing the draggable item and all other relative draggable items + Current index of the draggable item being drawn + Color to use for drag divider and selection + If NULL will calculate this automatically using . + Pass this if you're creating a drag between elements that don't use GUILayout + + + + Ends the drag operations, and eventually applies the drag outcome. + Returns TRUE if the position of the dragged item actually changed. + Called automatically by Drag method. Use it only if you want to force the end of a drag operation. + + If TRUE applies the drag results, otherwise simply cancels the drag + + + + Abstract dynamic class used for every node of the same type + (meaning there is only a single recycled instance for all same-type nodes) + + + + Used to fill + + + Called when the node needs to be drawn + + + + The connectedNodesIds list will be automatically increased/decreased when adding/removing connections + (otherwise connectedNodesIds will have to be increased via custom code) + + + + + Requires only two connectedNodesIds (no more, no less), + uses regular CTRL+Drag to connect connection 0, CTRL+SPACE+Drag to connect connection 1 + + + + + Like , but with an extra connection as a last extra index, which is set when pressing CTRL+SPACE+Drag. + Must always have at least one element in connectedNodesIds + + + + Layout, Repaint, LayoutAndRepaint + + + + Stores cloned nodes for pasting + + + + + Returns a list of pasteable nodes, with their GUID recreated and their connections adapted + + + + + + Returns a clone of the given node (clones also lists, but leaves other references as references). + A new ID will be automatically generated. + + + + + Always connects a node from BottomOrRight side to TopOrLeft side + + + + + Always connects from BottomOrRight side to TopOrLeft side. + If ALT is pressed shows the delete connection button. + Called during Repaint or MouseDown/Up. + Returns TRUE if the connection was deleted using the delete connection button. + + + + + Always connects a node from BottomOrRight side to TopOrLeft side + + + + + Always connects from BottomOrRight side to TopOrLeft side. + If ALT is pressed shows the delete connection button. + Called during Repaint or MouseDown/Up. + Returns TRUE if the connection was deleted using the delete connection button. + + + + + You can attach to this + + + + + Use this to add a content group to the Help Panel + + + + Regular note + + + Editable note (activated by setting to TRUE + (but you will have to save the result somewhere yourself) + + + If TRUE shows the textArea + + + + Add definition. Supports rich-text but also these special tags: + - [b][/b] + + + + + Add key, automatically formatting these special keys: + / + + + → + + If TRUE and there's other keys/targets, adds the new key on a new line preceded by a comma + + + + Recalculates all rects based on the given Y shift + + + + + One per . + Partially independent, mainly controlled by process. + + + + Returns TRUE if the given node is currently being dragged + + + + Returns TRUE if a repaint is required + + + + + + Main class for DeGUI Node system. + Create it, then enclose your GUI node calls inside a . + CODING ORDER: + - Create a to use for your node system (create it once, obviously) + - Inside OnGUI, write all your nodes GUI code inside a + + + + Distance at which nodes will be placed when snapping next to each other + + + Full area without zeroed coordinates + + + Position with zeroed coordinates (used by all node GUI since it's inside a GUILayout(area)) + + + + Creates a new NodeProcess. + + EditorWindow for this process + Callback called when one or more nodes are going to be deleted. + Return FALSE if you want the deletion to be canceled. + Can be NULL, in which case it will be ignored + Callback called when a node is cloned. + Return FALSE if you want the cloning to be canceled. + Can be NULL, in which case it will be ignored + + + + Needs to be called when loading a complete new series of nodes + + + + + Call this when the layout/size of one or more nodes changed because of external intervention + (if a whole new range of nodes has been loaded, just call instead) + + + + + Forces the refresh of the area calculations. Useful if you need them before the first GUI call has run + + + + + Shifts the visible are to the given coordinates and repaints on end + + + + + Tells the process to repaint once the process has ended. + Calling this + + + + + Draws the given node using the given T editor GUINode type. + Retuns the full area of the node + + + + + Opens the Help Panel + + + + + Closes the Help Panel + + + + + Opens or closes the Help panel based on its current state + + + + + Returns TRUE if the given area is visible (even if partially) inside the current nodeProcess area + + + + + Use this to encapsulate node GUI operations. + Automatically manages various operations (press F1 to see them). + Sets GUI.changed to TRUE if the area is panned, a node is dragged, controlNodes change sorting or are deleted. + Wraps all content inside a GUILayout Area (nodeArea). + + The to use + Area within which the nodes will be drawn + Area shift (caused by dragging) + This list will be sorted based on current node draw order, + and changed in case one of its nodes is deleted. + IMPORTANT: this list should be part of your serialized class (MonoBehaviour or ScriptableObject), + so it will be stored as a reference and modifying one will modify the other. + Usually you want to pass all nodes to this except the eventual start node (or nodes that can't be sorted nor deleted). + + + + Set automatically when a selection ends up selecting a single node, + reset when deselecting all nodes, selecting multiple nodes, or resetting the + + + + + Returns TRUE if something was actually deselected, FALSE if there were no selected nodes + + + + + + Returns key modifiers currently pressed. + Requires to be updated at the beginning of every GUI call. + + + + + Call this method to update data required by softCtrl calculations. + Automatically called from within a . + Returns a object with the keys that were just pressed and just released + + Required to have the correct for the given target call + + + + Returns the given as an int, or -1 if it's not a number + + + + + Returns by . + Contains properties and methods to manage non-layout scrollview better. + Remember to use or to increase or set the full content height + + + + Area used by ScrollView and its content + + + Full content area regardless if visible or not. Its height should be set manually based on the contents' height + + + Content area currently visible (scroll bars excluded) + + + Current scrollPosition + + + + Returns the current open, or an empty one if none is open. + + + + + Sets the height + + + + + + Increase the height by the given amount + + + + + + Returns a Rect for a single line at the current scrollView yMax + + If less than 0 uses default line height, otherwise the value passed + if TRUE (default) automatically increases the height of the accordingly + + + + + Returns TRUE if the given rect is at least partially visible in the displayed scroll area + + + + + Contains both free and pro skins GUIStyle variations, + and automatically returns the correct one when converted to GUIStyle + + + + + Plays the given clip in the Editor + + + + + Stops playing the given clip. + + + + + Stops all clips playing. + + + + + Util to determine Unity editor version and store them as comparable numbers + + + + Full major version + first minor version (ex: 2018.1f) + + + Major version + + + First minor version (ex: in 2018.1 it would be 1) + + + + Assembly extensions + + + + + Full path to the assembly directory, without final slash + + + + + AssetDatabase path to the assembly directory, without final slash + + + + + GUI extension methods + + + + + Clones the style and adds the given formats to it. You can pass any of these types of values: + + Format:Rich-text, wordwrap + FontStyle:Font style + TextAnchor:Content anchor + int:Font size + Color/DeSkinColor:Font color + + + + + + Adds the given formats to the style. You can pass any of these types of values: + + Format:RichText, WordWrap + FontStyle:Font style + TextAnchor:Content anchor + int:Font size + Color/DeSkinColor:Font color + + + + + + Sets the border of the style + + + + + Sets the border of the style + + + + + Sets the background of the style + + + + + Sets the contentOffset of the style + + + + + Sets the contentOffset of the style + + + + + Sets the X contentOffset of the style + + + + + Sets the Y contentOffset of the style + + + + + Sets the margin of the style + + + + + Sets the margin of the style + + + + + Sets the margin of the style + + + + + Sets the left margin of the style + + + + + Sets the right margin of the style + + + + + Sets the top margin of the style + + + + + Sets the bottom margin of the style + + + + + Sets the overflow of the style + + + + + Sets the overflow of the style + + + + + Sets the overflow of the style + + + + + Sets the left overflow of the style + + + + + Sets the right overflow of the style + + + + + Sets the top overflow of the style + + + + + Sets the bottom overflow of the style + + + + + Sets the padding of the style + + + + + Sets the padding of the style + + + + + Sets the padding of the style + + + + + Sets the left padding of the style + + + + + Sets the right padding of the style + + + + + Sets the top padding of the style + + + + + Sets the bottom padding of the style + + + + + Sets the Y fixedWidth of the style + + + + + Sets the fixedHeight of the style + + + + + Sets the stretchHeight property of the style + + + + + Sets the stretchWidth property of the style + + + + + Stores a GUIStyle palette, which can be passed to default DeGUI layouts when calling DeGUI.BeginGUI, + and changed at any time by calling DeGUI.ChangePalette. + You can inherit from this class to create custom GUIStyle palettes with more options. + Each of the sub-options require a public Init method to initialize the styles, which will be called via Reflection. + + + + + Called automatically by DeGUI.BeginGUI. + Override when adding new style subclasses. + + + + + Extend any custom subpalettes from this, so they will be initialized correctly + + + + + GUILayout methods + + + + Shaded button + + + Shaded button + + + Shaded button + + + Shaded button + + + Colored button + + + Colored button + + + Colored button + + + Colored button + + + + Draws a button that returns TRUE the first time it's pressed, instead than when its released. + + + + + Draws a button that returns TRUE the first time it's pressed, instead than when its released. + + + + Toolbar foldout button + + + Button that can be toggled on and off + + + Button that can be toggled on and off + + + Button that can be toggled on and off + + + Button that can be toggled on and off + + + Button that can be toggled on and off + + + Button that can be toggled on and off + + + Button that can be toggled on and off + + + Button that can be toggled on and off + + + Button that can be toggled on and off + + + Begins an horizontal toolbar layout + + + Begins an horizontal toolbar layout + + + Begins an horizontal toolbar layout + + + Begins an horizontal toolbar layout + + + Ends an horizontal toolbar layout + + + A toolbar with a label + + + A toolbar with a label + + + A toolbar with a label + + + A toolbar with a label + + + A toolbar with a label + + + A toolbar with a label + + + Vertical box layout with style and color options + + + Vertical box layout with style and color options + + + End vertical box layout + + + Horizontal Divider + + + + A text field that becomes editable only on double-click + + EditorWindow reference + A unique ID to use in order to determine if the text is selected or not + Text + Style for default (non-editing mode) appearance + Style for editing mode + + + + A text field that becomes editable only on double-click + + Editor reference + A unique ID to use in order to determine if the text is selected or not + Text + Style for default (non-editing mode) appearance + Style for editing mode + + + + A text field that becomes editable only on double-click and can also be dragged + + EditorWindow reference + A unique ID to use in order to determine if the text is selected or not + Text + ID for this drag operation (must be the same for both this and Drag + List containing the dragged item and all other relative draggable items + DraggableList index of the item being dragged + Style for default (non-editing mode) appearance + Style for editing mode + + + + + A text field that becomes editable only on double-click and can also be dragged + + Editor reference + A unique ID to use in order to determine if the text is selected or not + Text + ID for this drag operation (must be the same for both this and Drag + List containing the dragged item and all other relative draggable items + DraggableList index of the item being dragged + Style for default (non-editing mode) appearance + Style for editing mode + + + + + Creates a Gradient field by using Unity 4.x hidden default one and Reflection. + + + + Scene field + + + + Global Demigiant GUI manager. Call to initialize it inside GUI calls. + + + + + Default color palette + + + + + Default style palette + + + + TRUE if we're using the PRO skin + + + + Call this at the beginning of GUI methods + + Eventual to use + Eventual to use + + + + Better implementation of GUI.BeginScrollView. + Returns the modified scrollView struct. + Must be closed by a DeGUI.. + + Area used by the scrollView + target + If TRUE (default) resets .height to 0 + after beginning the ScrollView + + + + Closes a DeGUI. correctly + + + + + Exits the current event correctly, also taking care of eventual drag operations + + + + + Changes the active palettes to the given ones + (or resets them to the default ones if NULL) + + + + + Resets the GUI colors to the default ones (only available if BeginGUI was called first) + + + + + Sets the GUI colors to the given ones + + + + + Sets the GUI cursor color to the given ones + + + + + Sets the GUI matrix to the given ones + + + + Shaded button + + + Shaded button + + + Shaded button + + + Shaded button + + + Colored button + + + Colored button + + + Colored button + + + Colored button + + + Toolbar foldout button which allows clicking even on its label + + + + Draws a button that returns TRUE the first time it's pressed, instead than when its released. + + + + + Draws a button that returns TRUE the first time it's pressed, instead than when its released. + + + + Toolbar foldout button + + + Button that can be toggled on and off + + + Button that can be toggled on and off + + + Button that can be toggled on and off + + + Button that can be toggled on and off + + + Button that can be toggled on and off + + + Button that can be toggled on and off + + + Button that can be toggled on and off + + + Button that can be toggled on and off + + + Button that can be toggled on and off + + + Scene field + + + + Draws a background grid using the given grid texture + + Area rect + Offset from 0, 0 position (used when area has been dragged) + Texture to use for the grid + Eventual scale to apply to the grid + + + + Draws a background grid using default grid textures + + Area rect + Offset from 0, 0 position (used when area has been dragged) + If TRUE forces a dark skin, otherwise uses a skin that fits with the current Unity's one + Eventual scale to apply to the grid + + + Box with style and color options + + + + Can be used instead of EditorGUI.PropertyField, to draw a serializedProperty without its attributes + (very useful in case you want to use this from within a PropertyDrawer for that same property, + since otherwise bad infinite loops might happen) + + + + Draws a colored square + + + Draws the given texture tiled within the given rect + Eventual scale to apply + If not NULL, colorizes the texture with this color + + + + A text field that becomes editable only on double-click + + Area + EditorWindow reference + A unique ID to use in order to determine if the text is selected or not + Text + Style for default (non-editing mode) appearance + Style for editing mode + + + + A text field that becomes editable only on double-click + + Area + Editor reference + A unique ID to use in order to determine if the text is selected or not + Text + Style for default (non-editing mode) appearance + Style for editing mode + + + + A text field that becomes editable only on double-click and can also be dragged + + Area + EditorWindow reference + A unique ID to use in order to determine if the text is selected or not + Text + ID for this drag operation (must be the same for both this and Drag + List containing the dragged item and all other relative draggable items + DraggableList index of the item being dragged + Style for default (non-editing mode) appearance + Style for editing mode + + + + A text field that becomes editable only on double-click and can also be dragged + + Area + Editor reference + A unique ID to use in order to determine if the text is selected or not + Text + ID for this drag operation (must be the same for both this and Drag + List containing the dragged item and all other relative draggable items + DraggableList index of the item being dragged + Style for default (non-editing mode) appearance + Style for editing mode + + + + A textArea that becomes editable only on double-click + + Area + EditorWindow reference + A unique ID to use in order to determine if the text is selected or not + Text + Style for default (non-editing mode) appearance + Style for editing mode + + + + A textArea that becomes editable only on double-click + + Area + Editor reference + A unique ID to use in order to determine if the text is selected or not + Text + Style for default (non-editing mode) appearance + Style for editing mode + + + Divider + + + + Changes the alpha of this color and returns it + + + + + Replicates DeExtensions.RectExtensions for internal usage + + + + + Adds one rect into another, and returns the resulting a + + + + + Returns a copy or the Rect expanded around its center by the given amount + + Indicates how much to expand the rect on each size + + + + Returns a copy or the Rect contracted around its center by the given amount + + Indicates how much to contract the rect on each size + + + + Returns a copy of the Rect resized so it fits proportionally within the given size limits + + Width to fit + Height to fit + If TRUE (default) only shrinks the rect if needed, if FALSE also enlarges it to fit + + + + + Returns TRUE if the first rect includes the second one + + If TRUE, returns TRUE only if the second rect is fully included, + otherwise just if some part of it is included + + + + Returns a copy of the Rect with its X/Y coordinates set to 0 + + + + + Returns a copy of the Rect with its values shifted according the the given parameters + + + + + Returns a copy of the Rect with its X property set to the given value + + + + + Returns a copy of the Rect with its Y property set to the given value + + + + + Returns a copy of the Rect with its height property set to the given value + + + + + Returns a copy of the Rect with its width property set to the given value + + + + + Returns the value of the given property (works like a cast to type). + + Improved from HiddenMonk's functions (http://answers.unity3d.com/questions/627090/convert-serializedproperty-to-custom-class.html) + + + + + + Returns TRUE if this property is inside an array + + + + + Returns -1 if the property is not inside an array, otherwise returns its index inside the array + + + + + String extensions + + + + + If the given string is a directory path, returns its parent + with or without final slash depending on the original directory format + + + + + If the string is a directory, returns the directory name, + if instead it's a file returns its name without extension. + Works better than Path.GetDirectoryName, which kind of sucks imho + + + + + Texture extensions + + + + + Checks that the texture uses the correct import settings, and applies them if they're incorrect. + + + + + Replicates parts of DeExtensions.ListExtensions for internal usage + + + + + Shifts an item from an index to another, without modifying the list except than by moving elements around + + + + diff --git a/Assets/Demigiant/DemiLib/Core/Editor/DemiEditor.xml.meta b/Assets/Demigiant/DemiLib/Core/Editor/DemiEditor.xml.meta new file mode 100644 index 0000000..22f8130 --- /dev/null +++ b/Assets/Demigiant/DemiLib/Core/Editor/DemiEditor.xml.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: d4a42b2e4e6f64d4ba01d35c5a3dafed +TextScriptImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs.meta b/Assets/Demigiant/DemiLib/Core/Editor/Imgs.meta new file mode 100644 index 0000000..d08e739 --- /dev/null +++ b/Assets/Demigiant/DemiLib/Core/Editor/Imgs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: a8b725bac4954584bb9e4e5a215fe5b7 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/blackSquare.png b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/blackSquare.png new file mode 100644 index 0000000..6fbcc51 Binary files /dev/null and b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/blackSquare.png differ diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/blackSquare.png.meta b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/blackSquare.png.meta new file mode 100644 index 0000000..0d69ecd --- /dev/null +++ b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/blackSquare.png.meta @@ -0,0 +1,96 @@ +fileFormatVersion: 2 +guid: 7ba4b2810f605d945af87e032ca2957b +TextureImporter: + internalIDToNameTable: [] + externalObjects: {} + serializedVersion: 11 + mipmaps: + mipMapMode: 0 + enableMipMap: 1 + sRGBTexture: 1 + linearTexture: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + streamingMipmaps: 0 + streamingMipmapsPriority: 0 + vTOnly: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: -1 + maxTextureSize: 1024 + textureSettings: + serializedVersion: 2 + filterMode: 1 + aniso: 1 + mipBias: 0 + wrapU: 0 + wrapV: 0 + wrapW: 0 + nPOTScale: 1 + lightmap: 0 + compressionQuality: 50 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spritePixelsToUnits: 100 + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spriteGenerateFallbackPhysicsShape: 1 + alphaUsage: 1 + alphaIsTransparency: 0 + spriteTessellationDetail: -1 + textureType: 0 + textureShape: 1 + singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + platformSettings: + - serializedVersion: 3 + buildTarget: DefaultTexturePlatform + maxTextureSize: 1024 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + bones: [] + spriteID: + internalID: 0 + vertices: [] + indices: + edges: [] + weights: [] + secondaryTextures: [] + spritePackingTag: + pSDRemoveMatte: 0 + pSDShowRemoveMatteOption: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/blackSquareAlpha10.png b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/blackSquareAlpha10.png new file mode 100644 index 0000000..21afc7b Binary files /dev/null and b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/blackSquareAlpha10.png differ diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/blackSquareAlpha10.png.meta b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/blackSquareAlpha10.png.meta new file mode 100644 index 0000000..dcf0dbf --- /dev/null +++ b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/blackSquareAlpha10.png.meta @@ -0,0 +1,96 @@ +fileFormatVersion: 2 +guid: 8c9cfa1dbe00a1d41ae9d14f5ac543ec +TextureImporter: + internalIDToNameTable: [] + externalObjects: {} + serializedVersion: 11 + mipmaps: + mipMapMode: 0 + enableMipMap: 1 + sRGBTexture: 1 + linearTexture: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + streamingMipmaps: 0 + streamingMipmapsPriority: 0 + vTOnly: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: -1 + maxTextureSize: 1024 + textureSettings: + serializedVersion: 2 + filterMode: 1 + aniso: 1 + mipBias: 0 + wrapU: 0 + wrapV: 0 + wrapW: 0 + nPOTScale: 1 + lightmap: 0 + compressionQuality: 50 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spritePixelsToUnits: 100 + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spriteGenerateFallbackPhysicsShape: 1 + alphaUsage: 1 + alphaIsTransparency: 0 + spriteTessellationDetail: -1 + textureType: 0 + textureShape: 1 + singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + platformSettings: + - serializedVersion: 3 + buildTarget: DefaultTexturePlatform + maxTextureSize: 1024 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + bones: [] + spriteID: + internalID: 0 + vertices: [] + indices: + edges: [] + weights: [] + secondaryTextures: [] + spritePackingTag: + pSDRemoveMatte: 0 + pSDShowRemoveMatteOption: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/blackSquareAlpha15.png b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/blackSquareAlpha15.png new file mode 100644 index 0000000..3097db8 Binary files /dev/null and b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/blackSquareAlpha15.png differ diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/blackSquareAlpha15.png.meta b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/blackSquareAlpha15.png.meta new file mode 100644 index 0000000..a0b7103 --- /dev/null +++ b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/blackSquareAlpha15.png.meta @@ -0,0 +1,96 @@ +fileFormatVersion: 2 +guid: 53d696c01f6ca524383f11fcc34dd13c +TextureImporter: + internalIDToNameTable: [] + externalObjects: {} + serializedVersion: 11 + mipmaps: + mipMapMode: 0 + enableMipMap: 1 + sRGBTexture: 1 + linearTexture: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + streamingMipmaps: 0 + streamingMipmapsPriority: 0 + vTOnly: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: -1 + maxTextureSize: 1024 + textureSettings: + serializedVersion: 2 + filterMode: 1 + aniso: 1 + mipBias: 0 + wrapU: 0 + wrapV: 0 + wrapW: 0 + nPOTScale: 1 + lightmap: 0 + compressionQuality: 50 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spritePixelsToUnits: 100 + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spriteGenerateFallbackPhysicsShape: 1 + alphaUsage: 1 + alphaIsTransparency: 0 + spriteTessellationDetail: -1 + textureType: 0 + textureShape: 1 + singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + platformSettings: + - serializedVersion: 3 + buildTarget: DefaultTexturePlatform + maxTextureSize: 1024 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + bones: [] + spriteID: + internalID: 0 + vertices: [] + indices: + edges: [] + weights: [] + secondaryTextures: [] + spritePackingTag: + pSDRemoveMatte: 0 + pSDShowRemoveMatteOption: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/blackSquareAlpha25.png b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/blackSquareAlpha25.png new file mode 100644 index 0000000..521e6dc Binary files /dev/null and b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/blackSquareAlpha25.png differ diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/blackSquareAlpha25.png.meta b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/blackSquareAlpha25.png.meta new file mode 100644 index 0000000..c95f767 --- /dev/null +++ b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/blackSquareAlpha25.png.meta @@ -0,0 +1,96 @@ +fileFormatVersion: 2 +guid: f7ff421f40d548444864a01cd7f47112 +TextureImporter: + internalIDToNameTable: [] + externalObjects: {} + serializedVersion: 11 + mipmaps: + mipMapMode: 0 + enableMipMap: 1 + sRGBTexture: 1 + linearTexture: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + streamingMipmaps: 0 + streamingMipmapsPriority: 0 + vTOnly: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: -1 + maxTextureSize: 1024 + textureSettings: + serializedVersion: 2 + filterMode: 1 + aniso: 1 + mipBias: 0 + wrapU: 0 + wrapV: 0 + wrapW: 0 + nPOTScale: 1 + lightmap: 0 + compressionQuality: 50 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spritePixelsToUnits: 100 + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spriteGenerateFallbackPhysicsShape: 1 + alphaUsage: 1 + alphaIsTransparency: 0 + spriteTessellationDetail: -1 + textureType: 0 + textureShape: 1 + singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + platformSettings: + - serializedVersion: 3 + buildTarget: DefaultTexturePlatform + maxTextureSize: 1024 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + bones: [] + spriteID: + internalID: 0 + vertices: [] + indices: + edges: [] + weights: [] + secondaryTextures: [] + spritePackingTag: + pSDRemoveMatte: 0 + pSDShowRemoveMatteOption: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/blackSquareAlpha50.png b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/blackSquareAlpha50.png new file mode 100644 index 0000000..700b9de Binary files /dev/null and b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/blackSquareAlpha50.png differ diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/blackSquareAlpha50.png.meta b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/blackSquareAlpha50.png.meta new file mode 100644 index 0000000..0c2f5f1 --- /dev/null +++ b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/blackSquareAlpha50.png.meta @@ -0,0 +1,96 @@ +fileFormatVersion: 2 +guid: aa1d42dc6ff3e894da2208c6929d2165 +TextureImporter: + internalIDToNameTable: [] + externalObjects: {} + serializedVersion: 11 + mipmaps: + mipMapMode: 0 + enableMipMap: 1 + sRGBTexture: 1 + linearTexture: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + streamingMipmaps: 0 + streamingMipmapsPriority: 0 + vTOnly: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: -1 + maxTextureSize: 1024 + textureSettings: + serializedVersion: 2 + filterMode: 1 + aniso: 1 + mipBias: 0 + wrapU: 0 + wrapV: 0 + wrapW: 0 + nPOTScale: 1 + lightmap: 0 + compressionQuality: 50 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spritePixelsToUnits: 100 + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spriteGenerateFallbackPhysicsShape: 1 + alphaUsage: 1 + alphaIsTransparency: 0 + spriteTessellationDetail: -1 + textureType: 0 + textureShape: 1 + singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + platformSettings: + - serializedVersion: 3 + buildTarget: DefaultTexturePlatform + maxTextureSize: 1024 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + bones: [] + spriteID: + internalID: 0 + vertices: [] + indices: + edges: [] + weights: [] + secondaryTextures: [] + spritePackingTag: + pSDRemoveMatte: 0 + pSDShowRemoveMatteOption: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/blackSquareAlpha80.png b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/blackSquareAlpha80.png new file mode 100644 index 0000000..f4a47c3 Binary files /dev/null and b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/blackSquareAlpha80.png differ diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/blackSquareAlpha80.png.meta b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/blackSquareAlpha80.png.meta new file mode 100644 index 0000000..9b7704b --- /dev/null +++ b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/blackSquareAlpha80.png.meta @@ -0,0 +1,96 @@ +fileFormatVersion: 2 +guid: 595b166389c8db546a199430284ebc9b +TextureImporter: + internalIDToNameTable: [] + externalObjects: {} + serializedVersion: 11 + mipmaps: + mipMapMode: 0 + enableMipMap: 1 + sRGBTexture: 1 + linearTexture: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + streamingMipmaps: 0 + streamingMipmapsPriority: 0 + vTOnly: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: -1 + maxTextureSize: 1024 + textureSettings: + serializedVersion: 2 + filterMode: 1 + aniso: 1 + mipBias: 0 + wrapU: 0 + wrapV: 0 + wrapW: 0 + nPOTScale: 1 + lightmap: 0 + compressionQuality: 50 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spritePixelsToUnits: 100 + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spriteGenerateFallbackPhysicsShape: 1 + alphaUsage: 1 + alphaIsTransparency: 0 + spriteTessellationDetail: -1 + textureType: 0 + textureShape: 1 + singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + platformSettings: + - serializedVersion: 3 + buildTarget: DefaultTexturePlatform + maxTextureSize: 1024 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + bones: [] + spriteID: + internalID: 0 + vertices: [] + indices: + edges: [] + weights: [] + secondaryTextures: [] + spritePackingTag: + pSDRemoveMatte: 0 + pSDShowRemoveMatteOption: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/blueSquare.png b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/blueSquare.png new file mode 100644 index 0000000..9d8a19a Binary files /dev/null and b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/blueSquare.png differ diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/blueSquare.png.meta b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/blueSquare.png.meta new file mode 100644 index 0000000..3298612 --- /dev/null +++ b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/blueSquare.png.meta @@ -0,0 +1,96 @@ +fileFormatVersion: 2 +guid: 05cfe010378336646ad6c721f66543d1 +TextureImporter: + internalIDToNameTable: [] + externalObjects: {} + serializedVersion: 11 + mipmaps: + mipMapMode: 0 + enableMipMap: 1 + sRGBTexture: 1 + linearTexture: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + streamingMipmaps: 0 + streamingMipmapsPriority: 0 + vTOnly: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: -1 + maxTextureSize: 1024 + textureSettings: + serializedVersion: 2 + filterMode: 1 + aniso: 1 + mipBias: 0 + wrapU: 0 + wrapV: 0 + wrapW: 0 + nPOTScale: 1 + lightmap: 0 + compressionQuality: 50 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spritePixelsToUnits: 100 + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spriteGenerateFallbackPhysicsShape: 1 + alphaUsage: 1 + alphaIsTransparency: 0 + spriteTessellationDetail: -1 + textureType: 0 + textureShape: 1 + singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + platformSettings: + - serializedVersion: 3 + buildTarget: DefaultTexturePlatform + maxTextureSize: 1024 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + bones: [] + spriteID: + internalID: 0 + vertices: [] + indices: + edges: [] + weights: [] + secondaryTextures: [] + spritePackingTag: + pSDRemoveMatte: 0 + pSDShowRemoveMatteOption: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/circle.png b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/circle.png new file mode 100644 index 0000000..3ed059a Binary files /dev/null and b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/circle.png differ diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/circle.png.meta b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/circle.png.meta new file mode 100644 index 0000000..a046efa --- /dev/null +++ b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/circle.png.meta @@ -0,0 +1,96 @@ +fileFormatVersion: 2 +guid: af28470bd0e2e9543a6dfa9a1a4b348d +TextureImporter: + internalIDToNameTable: [] + externalObjects: {} + serializedVersion: 11 + mipmaps: + mipMapMode: 0 + enableMipMap: 1 + sRGBTexture: 1 + linearTexture: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + streamingMipmaps: 0 + streamingMipmapsPriority: 0 + vTOnly: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: -1 + maxTextureSize: 1024 + textureSettings: + serializedVersion: 2 + filterMode: 1 + aniso: 1 + mipBias: 0 + wrapU: 0 + wrapV: 0 + wrapW: 0 + nPOTScale: 1 + lightmap: 0 + compressionQuality: 50 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spritePixelsToUnits: 100 + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spriteGenerateFallbackPhysicsShape: 1 + alphaUsage: 1 + alphaIsTransparency: 0 + spriteTessellationDetail: -1 + textureType: 0 + textureShape: 1 + singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + platformSettings: + - serializedVersion: 3 + buildTarget: DefaultTexturePlatform + maxTextureSize: 1024 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + bones: [] + spriteID: + internalID: 0 + vertices: [] + indices: + edges: [] + weights: [] + secondaryTextures: [] + spritePackingTag: + pSDRemoveMatte: 0 + pSDShowRemoveMatteOption: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/greenSquare.png b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/greenSquare.png new file mode 100644 index 0000000..63ef49a Binary files /dev/null and b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/greenSquare.png differ diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/greenSquare.png.meta b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/greenSquare.png.meta new file mode 100644 index 0000000..41b174d --- /dev/null +++ b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/greenSquare.png.meta @@ -0,0 +1,96 @@ +fileFormatVersion: 2 +guid: 789ef07ba2573f6448fa8b5dc5224c44 +TextureImporter: + internalIDToNameTable: [] + externalObjects: {} + serializedVersion: 11 + mipmaps: + mipMapMode: 0 + enableMipMap: 1 + sRGBTexture: 1 + linearTexture: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + streamingMipmaps: 0 + streamingMipmapsPriority: 0 + vTOnly: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: -1 + maxTextureSize: 1024 + textureSettings: + serializedVersion: 2 + filterMode: 1 + aniso: 1 + mipBias: 0 + wrapU: 0 + wrapV: 0 + wrapW: 0 + nPOTScale: 1 + lightmap: 0 + compressionQuality: 50 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spritePixelsToUnits: 100 + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spriteGenerateFallbackPhysicsShape: 1 + alphaUsage: 1 + alphaIsTransparency: 0 + spriteTessellationDetail: -1 + textureType: 0 + textureShape: 1 + singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + platformSettings: + - serializedVersion: 3 + buildTarget: DefaultTexturePlatform + maxTextureSize: 1024 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + bones: [] + spriteID: + internalID: 0 + vertices: [] + indices: + edges: [] + weights: [] + secondaryTextures: [] + spritePackingTag: + pSDRemoveMatte: 0 + pSDShowRemoveMatteOption: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/grid_bright.png b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/grid_bright.png new file mode 100644 index 0000000..5c2feae Binary files /dev/null and b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/grid_bright.png differ diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/grid_bright.png.meta b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/grid_bright.png.meta new file mode 100644 index 0000000..9c5322d --- /dev/null +++ b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/grid_bright.png.meta @@ -0,0 +1,96 @@ +fileFormatVersion: 2 +guid: 93b1287b4a087f84c95c72f49ec94e83 +TextureImporter: + internalIDToNameTable: [] + externalObjects: {} + serializedVersion: 11 + mipmaps: + mipMapMode: 0 + enableMipMap: 1 + sRGBTexture: 1 + linearTexture: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + streamingMipmaps: 0 + streamingMipmapsPriority: 0 + vTOnly: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: -1 + maxTextureSize: 1024 + textureSettings: + serializedVersion: 2 + filterMode: 1 + aniso: 1 + mipBias: 0 + wrapU: 0 + wrapV: 0 + wrapW: 0 + nPOTScale: 1 + lightmap: 0 + compressionQuality: 50 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spritePixelsToUnits: 100 + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spriteGenerateFallbackPhysicsShape: 1 + alphaUsage: 1 + alphaIsTransparency: 0 + spriteTessellationDetail: -1 + textureType: 0 + textureShape: 1 + singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + platformSettings: + - serializedVersion: 3 + buildTarget: DefaultTexturePlatform + maxTextureSize: 1024 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + bones: [] + spriteID: + internalID: 0 + vertices: [] + indices: + edges: [] + weights: [] + secondaryTextures: [] + spritePackingTag: + pSDRemoveMatte: 0 + pSDShowRemoveMatteOption: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/grid_dark.png b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/grid_dark.png new file mode 100644 index 0000000..5dc9a72 Binary files /dev/null and b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/grid_dark.png differ diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/grid_dark.png.meta b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/grid_dark.png.meta new file mode 100644 index 0000000..04715b7 --- /dev/null +++ b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/grid_dark.png.meta @@ -0,0 +1,96 @@ +fileFormatVersion: 2 +guid: d542f997a51000946873268e3546b6ba +TextureImporter: + internalIDToNameTable: [] + externalObjects: {} + serializedVersion: 11 + mipmaps: + mipMapMode: 0 + enableMipMap: 1 + sRGBTexture: 1 + linearTexture: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + streamingMipmaps: 0 + streamingMipmapsPriority: 0 + vTOnly: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: -1 + maxTextureSize: 1024 + textureSettings: + serializedVersion: 2 + filterMode: 1 + aniso: 1 + mipBias: 0 + wrapU: 0 + wrapV: 0 + wrapW: 0 + nPOTScale: 1 + lightmap: 0 + compressionQuality: 50 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spritePixelsToUnits: 100 + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spriteGenerateFallbackPhysicsShape: 1 + alphaUsage: 1 + alphaIsTransparency: 0 + spriteTessellationDetail: -1 + textureType: 0 + textureShape: 1 + singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + platformSettings: + - serializedVersion: 3 + buildTarget: DefaultTexturePlatform + maxTextureSize: 1024 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + bones: [] + spriteID: + internalID: 0 + vertices: [] + indices: + edges: [] + weights: [] + secondaryTextures: [] + spritePackingTag: + pSDRemoveMatte: 0 + pSDShowRemoveMatteOption: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_alert.png b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_alert.png new file mode 100644 index 0000000..9242a22 Binary files /dev/null and b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_alert.png differ diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_alert.png.meta b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_alert.png.meta new file mode 100644 index 0000000..f7eed38 --- /dev/null +++ b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_alert.png.meta @@ -0,0 +1,96 @@ +fileFormatVersion: 2 +guid: 39cacc93c6c183f44992bf2421362f78 +TextureImporter: + internalIDToNameTable: [] + externalObjects: {} + serializedVersion: 11 + mipmaps: + mipMapMode: 0 + enableMipMap: 1 + sRGBTexture: 1 + linearTexture: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + streamingMipmaps: 0 + streamingMipmapsPriority: 0 + vTOnly: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: -1 + maxTextureSize: 1024 + textureSettings: + serializedVersion: 2 + filterMode: 1 + aniso: 1 + mipBias: 0 + wrapU: 0 + wrapV: 0 + wrapW: 0 + nPOTScale: 1 + lightmap: 0 + compressionQuality: 50 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spritePixelsToUnits: 100 + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spriteGenerateFallbackPhysicsShape: 1 + alphaUsage: 1 + alphaIsTransparency: 0 + spriteTessellationDetail: -1 + textureType: 0 + textureShape: 1 + singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + platformSettings: + - serializedVersion: 3 + buildTarget: DefaultTexturePlatform + maxTextureSize: 1024 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + bones: [] + spriteID: + internalID: 0 + vertices: [] + indices: + edges: [] + weights: [] + secondaryTextures: [] + spritePackingTag: + pSDRemoveMatte: 0 + pSDShowRemoveMatteOption: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_alignB.png b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_alignB.png new file mode 100644 index 0000000..c06e167 Binary files /dev/null and b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_alignB.png differ diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_alignB.png.meta b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_alignB.png.meta new file mode 100644 index 0000000..7cb8b75 --- /dev/null +++ b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_alignB.png.meta @@ -0,0 +1,96 @@ +fileFormatVersion: 2 +guid: 8b6b31f71cd528243b053cfc488e73f5 +TextureImporter: + internalIDToNameTable: [] + externalObjects: {} + serializedVersion: 11 + mipmaps: + mipMapMode: 0 + enableMipMap: 1 + sRGBTexture: 1 + linearTexture: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + streamingMipmaps: 0 + streamingMipmapsPriority: 0 + vTOnly: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: -1 + maxTextureSize: 1024 + textureSettings: + serializedVersion: 2 + filterMode: 1 + aniso: 1 + mipBias: 0 + wrapU: 0 + wrapV: 0 + wrapW: 0 + nPOTScale: 1 + lightmap: 0 + compressionQuality: 50 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spritePixelsToUnits: 100 + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spriteGenerateFallbackPhysicsShape: 1 + alphaUsage: 1 + alphaIsTransparency: 0 + spriteTessellationDetail: -1 + textureType: 0 + textureShape: 1 + singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + platformSettings: + - serializedVersion: 3 + buildTarget: DefaultTexturePlatform + maxTextureSize: 1024 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + bones: [] + spriteID: + internalID: 0 + vertices: [] + indices: + edges: [] + weights: [] + secondaryTextures: [] + spritePackingTag: + pSDRemoveMatte: 0 + pSDShowRemoveMatteOption: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_alignBC.png b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_alignBC.png new file mode 100644 index 0000000..3118ab1 Binary files /dev/null and b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_alignBC.png differ diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_alignBC.png.meta b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_alignBC.png.meta new file mode 100644 index 0000000..5c42436 --- /dev/null +++ b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_alignBC.png.meta @@ -0,0 +1,96 @@ +fileFormatVersion: 2 +guid: 2cdc0bc527f7a434496c6be9236e636f +TextureImporter: + internalIDToNameTable: [] + externalObjects: {} + serializedVersion: 11 + mipmaps: + mipMapMode: 0 + enableMipMap: 1 + sRGBTexture: 1 + linearTexture: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + streamingMipmaps: 0 + streamingMipmapsPriority: 0 + vTOnly: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: -1 + maxTextureSize: 1024 + textureSettings: + serializedVersion: 2 + filterMode: 1 + aniso: 1 + mipBias: 0 + wrapU: 0 + wrapV: 0 + wrapW: 0 + nPOTScale: 1 + lightmap: 0 + compressionQuality: 50 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spritePixelsToUnits: 100 + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spriteGenerateFallbackPhysicsShape: 1 + alphaUsage: 1 + alphaIsTransparency: 0 + spriteTessellationDetail: -1 + textureType: 0 + textureShape: 1 + singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + platformSettings: + - serializedVersion: 3 + buildTarget: DefaultTexturePlatform + maxTextureSize: 1024 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + bones: [] + spriteID: + internalID: 0 + vertices: [] + indices: + edges: [] + weights: [] + secondaryTextures: [] + spritePackingTag: + pSDRemoveMatte: 0 + pSDShowRemoveMatteOption: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_alignBL.png b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_alignBL.png new file mode 100644 index 0000000..3ee1a48 Binary files /dev/null and b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_alignBL.png differ diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_alignBL.png.meta b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_alignBL.png.meta new file mode 100644 index 0000000..8ce34fa --- /dev/null +++ b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_alignBL.png.meta @@ -0,0 +1,96 @@ +fileFormatVersion: 2 +guid: abf8a615f379ef44b9ac872a13b7712f +TextureImporter: + internalIDToNameTable: [] + externalObjects: {} + serializedVersion: 11 + mipmaps: + mipMapMode: 0 + enableMipMap: 1 + sRGBTexture: 1 + linearTexture: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + streamingMipmaps: 0 + streamingMipmapsPriority: 0 + vTOnly: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: -1 + maxTextureSize: 1024 + textureSettings: + serializedVersion: 2 + filterMode: 1 + aniso: 1 + mipBias: 0 + wrapU: 0 + wrapV: 0 + wrapW: 0 + nPOTScale: 1 + lightmap: 0 + compressionQuality: 50 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spritePixelsToUnits: 100 + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spriteGenerateFallbackPhysicsShape: 1 + alphaUsage: 1 + alphaIsTransparency: 0 + spriteTessellationDetail: -1 + textureType: 0 + textureShape: 1 + singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + platformSettings: + - serializedVersion: 3 + buildTarget: DefaultTexturePlatform + maxTextureSize: 1024 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + bones: [] + spriteID: + internalID: 0 + vertices: [] + indices: + edges: [] + weights: [] + secondaryTextures: [] + spritePackingTag: + pSDRemoveMatte: 0 + pSDShowRemoveMatteOption: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_alignBR.png b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_alignBR.png new file mode 100644 index 0000000..ce4cf47 Binary files /dev/null and b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_alignBR.png differ diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_alignBR.png.meta b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_alignBR.png.meta new file mode 100644 index 0000000..c3270e5 --- /dev/null +++ b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_alignBR.png.meta @@ -0,0 +1,96 @@ +fileFormatVersion: 2 +guid: eeac3acbf7d1cd54fabfb1c4a12f9fc8 +TextureImporter: + internalIDToNameTable: [] + externalObjects: {} + serializedVersion: 11 + mipmaps: + mipMapMode: 0 + enableMipMap: 1 + sRGBTexture: 1 + linearTexture: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + streamingMipmaps: 0 + streamingMipmapsPriority: 0 + vTOnly: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: -1 + maxTextureSize: 1024 + textureSettings: + serializedVersion: 2 + filterMode: 1 + aniso: 1 + mipBias: 0 + wrapU: 0 + wrapV: 0 + wrapW: 0 + nPOTScale: 1 + lightmap: 0 + compressionQuality: 50 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spritePixelsToUnits: 100 + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spriteGenerateFallbackPhysicsShape: 1 + alphaUsage: 1 + alphaIsTransparency: 0 + spriteTessellationDetail: -1 + textureType: 0 + textureShape: 1 + singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + platformSettings: + - serializedVersion: 3 + buildTarget: DefaultTexturePlatform + maxTextureSize: 1024 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + bones: [] + spriteID: + internalID: 0 + vertices: [] + indices: + edges: [] + weights: [] + secondaryTextures: [] + spritePackingTag: + pSDRemoveMatte: 0 + pSDShowRemoveMatteOption: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_alignCC.png b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_alignCC.png new file mode 100644 index 0000000..c5f85cc Binary files /dev/null and b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_alignCC.png differ diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_alignCC.png.meta b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_alignCC.png.meta new file mode 100644 index 0000000..6186934 --- /dev/null +++ b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_alignCC.png.meta @@ -0,0 +1,96 @@ +fileFormatVersion: 2 +guid: 8f0cb66458819764b94b93250bae94b6 +TextureImporter: + internalIDToNameTable: [] + externalObjects: {} + serializedVersion: 11 + mipmaps: + mipMapMode: 0 + enableMipMap: 1 + sRGBTexture: 1 + linearTexture: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + streamingMipmaps: 0 + streamingMipmapsPriority: 0 + vTOnly: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: -1 + maxTextureSize: 1024 + textureSettings: + serializedVersion: 2 + filterMode: 1 + aniso: 1 + mipBias: 0 + wrapU: 0 + wrapV: 0 + wrapW: 0 + nPOTScale: 1 + lightmap: 0 + compressionQuality: 50 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spritePixelsToUnits: 100 + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spriteGenerateFallbackPhysicsShape: 1 + alphaUsage: 1 + alphaIsTransparency: 0 + spriteTessellationDetail: -1 + textureType: 0 + textureShape: 1 + singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + platformSettings: + - serializedVersion: 3 + buildTarget: DefaultTexturePlatform + maxTextureSize: 1024 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + bones: [] + spriteID: + internalID: 0 + vertices: [] + indices: + edges: [] + weights: [] + secondaryTextures: [] + spritePackingTag: + pSDRemoveMatte: 0 + pSDShowRemoveMatteOption: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_alignCL.png b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_alignCL.png new file mode 100644 index 0000000..39e1546 Binary files /dev/null and b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_alignCL.png differ diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_alignCL.png.meta b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_alignCL.png.meta new file mode 100644 index 0000000..855aa57 --- /dev/null +++ b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_alignCL.png.meta @@ -0,0 +1,96 @@ +fileFormatVersion: 2 +guid: 2a8208d8e80f90944b8ff2978292b03b +TextureImporter: + internalIDToNameTable: [] + externalObjects: {} + serializedVersion: 11 + mipmaps: + mipMapMode: 0 + enableMipMap: 1 + sRGBTexture: 1 + linearTexture: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + streamingMipmaps: 0 + streamingMipmapsPriority: 0 + vTOnly: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: -1 + maxTextureSize: 1024 + textureSettings: + serializedVersion: 2 + filterMode: 1 + aniso: 1 + mipBias: 0 + wrapU: 0 + wrapV: 0 + wrapW: 0 + nPOTScale: 1 + lightmap: 0 + compressionQuality: 50 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spritePixelsToUnits: 100 + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spriteGenerateFallbackPhysicsShape: 1 + alphaUsage: 1 + alphaIsTransparency: 0 + spriteTessellationDetail: -1 + textureType: 0 + textureShape: 1 + singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + platformSettings: + - serializedVersion: 3 + buildTarget: DefaultTexturePlatform + maxTextureSize: 1024 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + bones: [] + spriteID: + internalID: 0 + vertices: [] + indices: + edges: [] + weights: [] + secondaryTextures: [] + spritePackingTag: + pSDRemoveMatte: 0 + pSDShowRemoveMatteOption: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_alignCR.png b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_alignCR.png new file mode 100644 index 0000000..9ec5557 Binary files /dev/null and b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_alignCR.png differ diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_alignCR.png.meta b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_alignCR.png.meta new file mode 100644 index 0000000..966d00c --- /dev/null +++ b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_alignCR.png.meta @@ -0,0 +1,96 @@ +fileFormatVersion: 2 +guid: 6f504a3fa8848264bb4fb9bb7d582dd5 +TextureImporter: + internalIDToNameTable: [] + externalObjects: {} + serializedVersion: 11 + mipmaps: + mipMapMode: 0 + enableMipMap: 1 + sRGBTexture: 1 + linearTexture: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + streamingMipmaps: 0 + streamingMipmapsPriority: 0 + vTOnly: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: -1 + maxTextureSize: 1024 + textureSettings: + serializedVersion: 2 + filterMode: 1 + aniso: 1 + mipBias: 0 + wrapU: 0 + wrapV: 0 + wrapW: 0 + nPOTScale: 1 + lightmap: 0 + compressionQuality: 50 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spritePixelsToUnits: 100 + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spriteGenerateFallbackPhysicsShape: 1 + alphaUsage: 1 + alphaIsTransparency: 0 + spriteTessellationDetail: -1 + textureType: 0 + textureShape: 1 + singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + platformSettings: + - serializedVersion: 3 + buildTarget: DefaultTexturePlatform + maxTextureSize: 1024 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + bones: [] + spriteID: + internalID: 0 + vertices: [] + indices: + edges: [] + weights: [] + secondaryTextures: [] + spritePackingTag: + pSDRemoveMatte: 0 + pSDShowRemoveMatteOption: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_alignHC.png b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_alignHC.png new file mode 100644 index 0000000..dc638a7 Binary files /dev/null and b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_alignHC.png differ diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_alignHC.png.meta b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_alignHC.png.meta new file mode 100644 index 0000000..bb24009 --- /dev/null +++ b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_alignHC.png.meta @@ -0,0 +1,96 @@ +fileFormatVersion: 2 +guid: b9e0e5a8836018e4c810fbceba55a1b4 +TextureImporter: + internalIDToNameTable: [] + externalObjects: {} + serializedVersion: 11 + mipmaps: + mipMapMode: 0 + enableMipMap: 1 + sRGBTexture: 1 + linearTexture: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + streamingMipmaps: 0 + streamingMipmapsPriority: 0 + vTOnly: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: -1 + maxTextureSize: 1024 + textureSettings: + serializedVersion: 2 + filterMode: 1 + aniso: 1 + mipBias: 0 + wrapU: 0 + wrapV: 0 + wrapW: 0 + nPOTScale: 1 + lightmap: 0 + compressionQuality: 50 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spritePixelsToUnits: 100 + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spriteGenerateFallbackPhysicsShape: 1 + alphaUsage: 1 + alphaIsTransparency: 0 + spriteTessellationDetail: -1 + textureType: 0 + textureShape: 1 + singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + platformSettings: + - serializedVersion: 3 + buildTarget: DefaultTexturePlatform + maxTextureSize: 1024 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + bones: [] + spriteID: + internalID: 0 + vertices: [] + indices: + edges: [] + weights: [] + secondaryTextures: [] + spritePackingTag: + pSDRemoveMatte: 0 + pSDShowRemoveMatteOption: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_alignL.png b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_alignL.png new file mode 100644 index 0000000..93c1812 Binary files /dev/null and b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_alignL.png differ diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_alignL.png.meta b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_alignL.png.meta new file mode 100644 index 0000000..9a74a45 --- /dev/null +++ b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_alignL.png.meta @@ -0,0 +1,96 @@ +fileFormatVersion: 2 +guid: d18ceface0c20014b8db4bba05a41b83 +TextureImporter: + internalIDToNameTable: [] + externalObjects: {} + serializedVersion: 11 + mipmaps: + mipMapMode: 0 + enableMipMap: 1 + sRGBTexture: 1 + linearTexture: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + streamingMipmaps: 0 + streamingMipmapsPriority: 0 + vTOnly: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: -1 + maxTextureSize: 1024 + textureSettings: + serializedVersion: 2 + filterMode: 1 + aniso: 1 + mipBias: 0 + wrapU: 0 + wrapV: 0 + wrapW: 0 + nPOTScale: 1 + lightmap: 0 + compressionQuality: 50 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spritePixelsToUnits: 100 + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spriteGenerateFallbackPhysicsShape: 1 + alphaUsage: 1 + alphaIsTransparency: 0 + spriteTessellationDetail: -1 + textureType: 0 + textureShape: 1 + singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + platformSettings: + - serializedVersion: 3 + buildTarget: DefaultTexturePlatform + maxTextureSize: 1024 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + bones: [] + spriteID: + internalID: 0 + vertices: [] + indices: + edges: [] + weights: [] + secondaryTextures: [] + spritePackingTag: + pSDRemoveMatte: 0 + pSDShowRemoveMatteOption: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_alignR.png b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_alignR.png new file mode 100644 index 0000000..c1aca04 Binary files /dev/null and b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_alignR.png differ diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_alignR.png.meta b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_alignR.png.meta new file mode 100644 index 0000000..499d2e5 --- /dev/null +++ b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_alignR.png.meta @@ -0,0 +1,96 @@ +fileFormatVersion: 2 +guid: 727ba41e4cc95fe4a98b07301e3ebfc8 +TextureImporter: + internalIDToNameTable: [] + externalObjects: {} + serializedVersion: 11 + mipmaps: + mipMapMode: 0 + enableMipMap: 1 + sRGBTexture: 1 + linearTexture: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + streamingMipmaps: 0 + streamingMipmapsPriority: 0 + vTOnly: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: -1 + maxTextureSize: 1024 + textureSettings: + serializedVersion: 2 + filterMode: 1 + aniso: 1 + mipBias: 0 + wrapU: 0 + wrapV: 0 + wrapW: 0 + nPOTScale: 1 + lightmap: 0 + compressionQuality: 50 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spritePixelsToUnits: 100 + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spriteGenerateFallbackPhysicsShape: 1 + alphaUsage: 1 + alphaIsTransparency: 0 + spriteTessellationDetail: -1 + textureType: 0 + textureShape: 1 + singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + platformSettings: + - serializedVersion: 3 + buildTarget: DefaultTexturePlatform + maxTextureSize: 1024 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + bones: [] + spriteID: + internalID: 0 + vertices: [] + indices: + edges: [] + weights: [] + secondaryTextures: [] + spritePackingTag: + pSDRemoveMatte: 0 + pSDShowRemoveMatteOption: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_alignT.png b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_alignT.png new file mode 100644 index 0000000..b4397c6 Binary files /dev/null and b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_alignT.png differ diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_alignT.png.meta b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_alignT.png.meta new file mode 100644 index 0000000..658e6ee --- /dev/null +++ b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_alignT.png.meta @@ -0,0 +1,96 @@ +fileFormatVersion: 2 +guid: b4785ec6d937dab4fa59da70b69afc9d +TextureImporter: + internalIDToNameTable: [] + externalObjects: {} + serializedVersion: 11 + mipmaps: + mipMapMode: 0 + enableMipMap: 1 + sRGBTexture: 1 + linearTexture: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + streamingMipmaps: 0 + streamingMipmapsPriority: 0 + vTOnly: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: -1 + maxTextureSize: 1024 + textureSettings: + serializedVersion: 2 + filterMode: 1 + aniso: 1 + mipBias: 0 + wrapU: 0 + wrapV: 0 + wrapW: 0 + nPOTScale: 1 + lightmap: 0 + compressionQuality: 50 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spritePixelsToUnits: 100 + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spriteGenerateFallbackPhysicsShape: 1 + alphaUsage: 1 + alphaIsTransparency: 0 + spriteTessellationDetail: -1 + textureType: 0 + textureShape: 1 + singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + platformSettings: + - serializedVersion: 3 + buildTarget: DefaultTexturePlatform + maxTextureSize: 1024 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + bones: [] + spriteID: + internalID: 0 + vertices: [] + indices: + edges: [] + weights: [] + secondaryTextures: [] + spritePackingTag: + pSDRemoveMatte: 0 + pSDShowRemoveMatteOption: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_alignTC.png b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_alignTC.png new file mode 100644 index 0000000..de6a933 Binary files /dev/null and b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_alignTC.png differ diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_alignTC.png.meta b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_alignTC.png.meta new file mode 100644 index 0000000..10418ef --- /dev/null +++ b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_alignTC.png.meta @@ -0,0 +1,96 @@ +fileFormatVersion: 2 +guid: 0f79253104349f44cb73978f6c8e93de +TextureImporter: + internalIDToNameTable: [] + externalObjects: {} + serializedVersion: 11 + mipmaps: + mipMapMode: 0 + enableMipMap: 1 + sRGBTexture: 1 + linearTexture: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + streamingMipmaps: 0 + streamingMipmapsPriority: 0 + vTOnly: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: -1 + maxTextureSize: 1024 + textureSettings: + serializedVersion: 2 + filterMode: 1 + aniso: 1 + mipBias: 0 + wrapU: 0 + wrapV: 0 + wrapW: 0 + nPOTScale: 1 + lightmap: 0 + compressionQuality: 50 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spritePixelsToUnits: 100 + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spriteGenerateFallbackPhysicsShape: 1 + alphaUsage: 1 + alphaIsTransparency: 0 + spriteTessellationDetail: -1 + textureType: 0 + textureShape: 1 + singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + platformSettings: + - serializedVersion: 3 + buildTarget: DefaultTexturePlatform + maxTextureSize: 1024 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + bones: [] + spriteID: + internalID: 0 + vertices: [] + indices: + edges: [] + weights: [] + secondaryTextures: [] + spritePackingTag: + pSDRemoveMatte: 0 + pSDShowRemoveMatteOption: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_alignTL.png b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_alignTL.png new file mode 100644 index 0000000..627b907 Binary files /dev/null and b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_alignTL.png differ diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_alignTL.png.meta b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_alignTL.png.meta new file mode 100644 index 0000000..56ad385 --- /dev/null +++ b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_alignTL.png.meta @@ -0,0 +1,96 @@ +fileFormatVersion: 2 +guid: 6efe1c8569d975640ba0c9f2ac4a9d61 +TextureImporter: + internalIDToNameTable: [] + externalObjects: {} + serializedVersion: 11 + mipmaps: + mipMapMode: 0 + enableMipMap: 1 + sRGBTexture: 1 + linearTexture: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + streamingMipmaps: 0 + streamingMipmapsPriority: 0 + vTOnly: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: -1 + maxTextureSize: 1024 + textureSettings: + serializedVersion: 2 + filterMode: 1 + aniso: 1 + mipBias: 0 + wrapU: 0 + wrapV: 0 + wrapW: 0 + nPOTScale: 1 + lightmap: 0 + compressionQuality: 50 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spritePixelsToUnits: 100 + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spriteGenerateFallbackPhysicsShape: 1 + alphaUsage: 1 + alphaIsTransparency: 0 + spriteTessellationDetail: -1 + textureType: 0 + textureShape: 1 + singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + platformSettings: + - serializedVersion: 3 + buildTarget: DefaultTexturePlatform + maxTextureSize: 1024 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + bones: [] + spriteID: + internalID: 0 + vertices: [] + indices: + edges: [] + weights: [] + secondaryTextures: [] + spritePackingTag: + pSDRemoveMatte: 0 + pSDShowRemoveMatteOption: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_alignTR.png b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_alignTR.png new file mode 100644 index 0000000..6a0d89d Binary files /dev/null and b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_alignTR.png differ diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_alignTR.png.meta b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_alignTR.png.meta new file mode 100644 index 0000000..e98e245 --- /dev/null +++ b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_alignTR.png.meta @@ -0,0 +1,96 @@ +fileFormatVersion: 2 +guid: e01c0b07c87513844ab88bb432bcf85a +TextureImporter: + internalIDToNameTable: [] + externalObjects: {} + serializedVersion: 11 + mipmaps: + mipMapMode: 0 + enableMipMap: 1 + sRGBTexture: 1 + linearTexture: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + streamingMipmaps: 0 + streamingMipmapsPriority: 0 + vTOnly: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: -1 + maxTextureSize: 1024 + textureSettings: + serializedVersion: 2 + filterMode: 1 + aniso: 1 + mipBias: 0 + wrapU: 0 + wrapV: 0 + wrapW: 0 + nPOTScale: 1 + lightmap: 0 + compressionQuality: 50 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spritePixelsToUnits: 100 + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spriteGenerateFallbackPhysicsShape: 1 + alphaUsage: 1 + alphaIsTransparency: 0 + spriteTessellationDetail: -1 + textureType: 0 + textureShape: 1 + singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + platformSettings: + - serializedVersion: 3 + buildTarget: DefaultTexturePlatform + maxTextureSize: 1024 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + bones: [] + spriteID: + internalID: 0 + vertices: [] + indices: + edges: [] + weights: [] + secondaryTextures: [] + spritePackingTag: + pSDRemoveMatte: 0 + pSDShowRemoveMatteOption: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_alignVC.png b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_alignVC.png new file mode 100644 index 0000000..ec87ccf Binary files /dev/null and b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_alignVC.png differ diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_alignVC.png.meta b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_alignVC.png.meta new file mode 100644 index 0000000..8936b4f --- /dev/null +++ b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_alignVC.png.meta @@ -0,0 +1,96 @@ +fileFormatVersion: 2 +guid: d1d45eadab0e41c4a82cdffb6396b1d7 +TextureImporter: + internalIDToNameTable: [] + externalObjects: {} + serializedVersion: 11 + mipmaps: + mipMapMode: 0 + enableMipMap: 1 + sRGBTexture: 1 + linearTexture: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + streamingMipmaps: 0 + streamingMipmapsPriority: 0 + vTOnly: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: -1 + maxTextureSize: 1024 + textureSettings: + serializedVersion: 2 + filterMode: 1 + aniso: 1 + mipBias: 0 + wrapU: 0 + wrapV: 0 + wrapW: 0 + nPOTScale: 1 + lightmap: 0 + compressionQuality: 50 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spritePixelsToUnits: 100 + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spriteGenerateFallbackPhysicsShape: 1 + alphaUsage: 1 + alphaIsTransparency: 0 + spriteTessellationDetail: -1 + textureType: 0 + textureShape: 1 + singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + platformSettings: + - serializedVersion: 3 + buildTarget: DefaultTexturePlatform + maxTextureSize: 1024 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + bones: [] + spriteID: + internalID: 0 + vertices: [] + indices: + edges: [] + weights: [] + secondaryTextures: [] + spritePackingTag: + pSDRemoveMatte: 0 + pSDShowRemoveMatteOption: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_camera.png b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_camera.png new file mode 100644 index 0000000..f146516 Binary files /dev/null and b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_camera.png differ diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_camera.png.meta b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_camera.png.meta new file mode 100644 index 0000000..a1df604 --- /dev/null +++ b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_camera.png.meta @@ -0,0 +1,96 @@ +fileFormatVersion: 2 +guid: 37639be6148186645bca3fce45d5aa22 +TextureImporter: + internalIDToNameTable: [] + externalObjects: {} + serializedVersion: 11 + mipmaps: + mipMapMode: 0 + enableMipMap: 1 + sRGBTexture: 1 + linearTexture: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + streamingMipmaps: 0 + streamingMipmapsPriority: 0 + vTOnly: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: -1 + maxTextureSize: 1024 + textureSettings: + serializedVersion: 2 + filterMode: 1 + aniso: 1 + mipBias: 0 + wrapU: 0 + wrapV: 0 + wrapW: 0 + nPOTScale: 1 + lightmap: 0 + compressionQuality: 50 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spritePixelsToUnits: 100 + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spriteGenerateFallbackPhysicsShape: 1 + alphaUsage: 1 + alphaIsTransparency: 0 + spriteTessellationDetail: -1 + textureType: 0 + textureShape: 1 + singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + platformSettings: + - serializedVersion: 3 + buildTarget: DefaultTexturePlatform + maxTextureSize: 1024 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + bones: [] + spriteID: + internalID: 0 + vertices: [] + indices: + edges: [] + weights: [] + secondaryTextures: [] + spritePackingTag: + pSDRemoveMatte: 0 + pSDShowRemoveMatteOption: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_camera_border.png b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_camera_border.png new file mode 100644 index 0000000..bab977d Binary files /dev/null and b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_camera_border.png differ diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_camera_border.png.meta b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_camera_border.png.meta new file mode 100644 index 0000000..ccb9f8e --- /dev/null +++ b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_camera_border.png.meta @@ -0,0 +1,96 @@ +fileFormatVersion: 2 +guid: 358cddede8023574191e0aae610a4645 +TextureImporter: + internalIDToNameTable: [] + externalObjects: {} + serializedVersion: 11 + mipmaps: + mipMapMode: 0 + enableMipMap: 1 + sRGBTexture: 1 + linearTexture: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + streamingMipmaps: 0 + streamingMipmapsPriority: 0 + vTOnly: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: -1 + maxTextureSize: 1024 + textureSettings: + serializedVersion: 2 + filterMode: 1 + aniso: 1 + mipBias: 0 + wrapU: 0 + wrapV: 0 + wrapW: 0 + nPOTScale: 1 + lightmap: 0 + compressionQuality: 50 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spritePixelsToUnits: 100 + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spriteGenerateFallbackPhysicsShape: 1 + alphaUsage: 1 + alphaIsTransparency: 0 + spriteTessellationDetail: -1 + textureType: 0 + textureShape: 1 + singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + platformSettings: + - serializedVersion: 3 + buildTarget: DefaultTexturePlatform + maxTextureSize: 1024 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + bones: [] + spriteID: + internalID: 0 + vertices: [] + indices: + edges: [] + weights: [] + secondaryTextures: [] + spritePackingTag: + pSDRemoveMatte: 0 + pSDShowRemoveMatteOption: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_cog.png b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_cog.png new file mode 100644 index 0000000..b7f481e Binary files /dev/null and b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_cog.png differ diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_cog.png.meta b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_cog.png.meta new file mode 100644 index 0000000..cf57f83 --- /dev/null +++ b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_cog.png.meta @@ -0,0 +1,96 @@ +fileFormatVersion: 2 +guid: 7c83a08052c9e2f49b47897a637994de +TextureImporter: + internalIDToNameTable: [] + externalObjects: {} + serializedVersion: 11 + mipmaps: + mipMapMode: 0 + enableMipMap: 1 + sRGBTexture: 1 + linearTexture: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + streamingMipmaps: 0 + streamingMipmapsPriority: 0 + vTOnly: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: -1 + maxTextureSize: 1024 + textureSettings: + serializedVersion: 2 + filterMode: 1 + aniso: 1 + mipBias: 0 + wrapU: 0 + wrapV: 0 + wrapW: 0 + nPOTScale: 1 + lightmap: 0 + compressionQuality: 50 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spritePixelsToUnits: 100 + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spriteGenerateFallbackPhysicsShape: 1 + alphaUsage: 1 + alphaIsTransparency: 0 + spriteTessellationDetail: -1 + textureType: 0 + textureShape: 1 + singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + platformSettings: + - serializedVersion: 3 + buildTarget: DefaultTexturePlatform + maxTextureSize: 1024 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + bones: [] + spriteID: + internalID: 0 + vertices: [] + indices: + edges: [] + weights: [] + secondaryTextures: [] + spritePackingTag: + pSDRemoveMatte: 0 + pSDShowRemoveMatteOption: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_cog_border.png b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_cog_border.png new file mode 100644 index 0000000..30bdb8b Binary files /dev/null and b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_cog_border.png differ diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_cog_border.png.meta b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_cog_border.png.meta new file mode 100644 index 0000000..7acc642 --- /dev/null +++ b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_cog_border.png.meta @@ -0,0 +1,96 @@ +fileFormatVersion: 2 +guid: 6862027f2176eae40a3143c562466a1b +TextureImporter: + internalIDToNameTable: [] + externalObjects: {} + serializedVersion: 11 + mipmaps: + mipMapMode: 0 + enableMipMap: 1 + sRGBTexture: 1 + linearTexture: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + streamingMipmaps: 0 + streamingMipmapsPriority: 0 + vTOnly: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: -1 + maxTextureSize: 1024 + textureSettings: + serializedVersion: 2 + filterMode: 1 + aniso: 1 + mipBias: 0 + wrapU: 0 + wrapV: 0 + wrapW: 0 + nPOTScale: 1 + lightmap: 0 + compressionQuality: 50 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spritePixelsToUnits: 100 + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spriteGenerateFallbackPhysicsShape: 1 + alphaUsage: 1 + alphaIsTransparency: 0 + spriteTessellationDetail: -1 + textureType: 0 + textureShape: 1 + singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + platformSettings: + - serializedVersion: 3 + buildTarget: DefaultTexturePlatform + maxTextureSize: 1024 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + bones: [] + spriteID: + internalID: 0 + vertices: [] + indices: + edges: [] + weights: [] + secondaryTextures: [] + spritePackingTag: + pSDRemoveMatte: 0 + pSDShowRemoveMatteOption: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_comment.png b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_comment.png new file mode 100644 index 0000000..8735b7c Binary files /dev/null and b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_comment.png differ diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_comment.png.meta b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_comment.png.meta new file mode 100644 index 0000000..0428c23 --- /dev/null +++ b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_comment.png.meta @@ -0,0 +1,96 @@ +fileFormatVersion: 2 +guid: 622fdb780ae13e840938631c5ed708f2 +TextureImporter: + internalIDToNameTable: [] + externalObjects: {} + serializedVersion: 11 + mipmaps: + mipMapMode: 0 + enableMipMap: 1 + sRGBTexture: 1 + linearTexture: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + streamingMipmaps: 0 + streamingMipmapsPriority: 0 + vTOnly: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: -1 + maxTextureSize: 1024 + textureSettings: + serializedVersion: 2 + filterMode: 1 + aniso: 1 + mipBias: 0 + wrapU: 0 + wrapV: 0 + wrapW: 0 + nPOTScale: 1 + lightmap: 0 + compressionQuality: 50 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spritePixelsToUnits: 100 + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spriteGenerateFallbackPhysicsShape: 1 + alphaUsage: 1 + alphaIsTransparency: 0 + spriteTessellationDetail: -1 + textureType: 0 + textureShape: 1 + singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + platformSettings: + - serializedVersion: 3 + buildTarget: DefaultTexturePlatform + maxTextureSize: 1024 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + bones: [] + spriteID: + internalID: 0 + vertices: [] + indices: + edges: [] + weights: [] + secondaryTextures: [] + spritePackingTag: + pSDRemoveMatte: 0 + pSDShowRemoveMatteOption: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_comment_border.png b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_comment_border.png new file mode 100644 index 0000000..d61a35d Binary files /dev/null and b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_comment_border.png differ diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_comment_border.png.meta b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_comment_border.png.meta new file mode 100644 index 0000000..94651ec --- /dev/null +++ b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_comment_border.png.meta @@ -0,0 +1,96 @@ +fileFormatVersion: 2 +guid: d98b8847646169c4fb5af28dd84c4179 +TextureImporter: + internalIDToNameTable: [] + externalObjects: {} + serializedVersion: 11 + mipmaps: + mipMapMode: 0 + enableMipMap: 1 + sRGBTexture: 1 + linearTexture: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + streamingMipmaps: 0 + streamingMipmapsPriority: 0 + vTOnly: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: -1 + maxTextureSize: 1024 + textureSettings: + serializedVersion: 2 + filterMode: 1 + aniso: 1 + mipBias: 0 + wrapU: 0 + wrapV: 0 + wrapW: 0 + nPOTScale: 1 + lightmap: 0 + compressionQuality: 50 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spritePixelsToUnits: 100 + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spriteGenerateFallbackPhysicsShape: 1 + alphaUsage: 1 + alphaIsTransparency: 0 + spriteTessellationDetail: -1 + textureType: 0 + textureShape: 1 + singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + platformSettings: + - serializedVersion: 3 + buildTarget: DefaultTexturePlatform + maxTextureSize: 1024 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + bones: [] + spriteID: + internalID: 0 + vertices: [] + indices: + edges: [] + weights: [] + secondaryTextures: [] + spritePackingTag: + pSDRemoveMatte: 0 + pSDShowRemoveMatteOption: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_delete.png b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_delete.png new file mode 100644 index 0000000..85bb248 Binary files /dev/null and b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_delete.png differ diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_delete.png.meta b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_delete.png.meta new file mode 100644 index 0000000..d6eaa03 --- /dev/null +++ b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_delete.png.meta @@ -0,0 +1,96 @@ +fileFormatVersion: 2 +guid: 6b1f9e1e1c2cf004b8e3bdd3033a8e75 +TextureImporter: + internalIDToNameTable: [] + externalObjects: {} + serializedVersion: 11 + mipmaps: + mipMapMode: 0 + enableMipMap: 1 + sRGBTexture: 1 + linearTexture: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + streamingMipmaps: 0 + streamingMipmapsPriority: 0 + vTOnly: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: -1 + maxTextureSize: 1024 + textureSettings: + serializedVersion: 2 + filterMode: 1 + aniso: 1 + mipBias: 0 + wrapU: 0 + wrapV: 0 + wrapW: 0 + nPOTScale: 1 + lightmap: 0 + compressionQuality: 50 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spritePixelsToUnits: 100 + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spriteGenerateFallbackPhysicsShape: 1 + alphaUsage: 1 + alphaIsTransparency: 0 + spriteTessellationDetail: -1 + textureType: 0 + textureShape: 1 + singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + platformSettings: + - serializedVersion: 3 + buildTarget: DefaultTexturePlatform + maxTextureSize: 1024 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + bones: [] + spriteID: + internalID: 0 + vertices: [] + indices: + edges: [] + weights: [] + secondaryTextures: [] + spritePackingTag: + pSDRemoveMatte: 0 + pSDShowRemoveMatteOption: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_demigiant.png b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_demigiant.png new file mode 100644 index 0000000..3445065 Binary files /dev/null and b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_demigiant.png differ diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_demigiant.png.meta b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_demigiant.png.meta new file mode 100644 index 0000000..b6c2edd --- /dev/null +++ b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_demigiant.png.meta @@ -0,0 +1,96 @@ +fileFormatVersion: 2 +guid: 229d0d11465a822449f78a50dbf7104d +TextureImporter: + internalIDToNameTable: [] + externalObjects: {} + serializedVersion: 11 + mipmaps: + mipMapMode: 0 + enableMipMap: 1 + sRGBTexture: 1 + linearTexture: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + streamingMipmaps: 0 + streamingMipmapsPriority: 0 + vTOnly: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: -1 + maxTextureSize: 1024 + textureSettings: + serializedVersion: 2 + filterMode: 1 + aniso: 1 + mipBias: 0 + wrapU: 0 + wrapV: 0 + wrapW: 0 + nPOTScale: 1 + lightmap: 0 + compressionQuality: 50 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spritePixelsToUnits: 100 + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spriteGenerateFallbackPhysicsShape: 1 + alphaUsage: 1 + alphaIsTransparency: 0 + spriteTessellationDetail: -1 + textureType: 0 + textureShape: 1 + singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + platformSettings: + - serializedVersion: 3 + buildTarget: DefaultTexturePlatform + maxTextureSize: 1024 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + bones: [] + spriteID: + internalID: 0 + vertices: [] + indices: + edges: [] + weights: [] + secondaryTextures: [] + spritePackingTag: + pSDRemoveMatte: 0 + pSDShowRemoveMatteOption: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_end.png b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_end.png new file mode 100644 index 0000000..b71eefe Binary files /dev/null and b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_end.png differ diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_end.png.meta b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_end.png.meta new file mode 100644 index 0000000..7076d9c --- /dev/null +++ b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_end.png.meta @@ -0,0 +1,96 @@ +fileFormatVersion: 2 +guid: a248c8288afb9184f953d9aa07a696b0 +TextureImporter: + internalIDToNameTable: [] + externalObjects: {} + serializedVersion: 11 + mipmaps: + mipMapMode: 0 + enableMipMap: 1 + sRGBTexture: 1 + linearTexture: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + streamingMipmaps: 0 + streamingMipmapsPriority: 0 + vTOnly: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: -1 + maxTextureSize: 1024 + textureSettings: + serializedVersion: 2 + filterMode: 1 + aniso: 1 + mipBias: 0 + wrapU: 0 + wrapV: 0 + wrapW: 0 + nPOTScale: 1 + lightmap: 0 + compressionQuality: 50 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spritePixelsToUnits: 100 + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spriteGenerateFallbackPhysicsShape: 1 + alphaUsage: 1 + alphaIsTransparency: 0 + spriteTessellationDetail: -1 + textureType: 0 + textureShape: 1 + singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + platformSettings: + - serializedVersion: 3 + buildTarget: DefaultTexturePlatform + maxTextureSize: 1024 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + bones: [] + spriteID: + internalID: 0 + vertices: [] + indices: + edges: [] + weights: [] + secondaryTextures: [] + spritePackingTag: + pSDRemoveMatte: 0 + pSDShowRemoveMatteOption: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_heart.png b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_heart.png new file mode 100644 index 0000000..7ea0c06 Binary files /dev/null and b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_heart.png differ diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_heart.png.meta b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_heart.png.meta new file mode 100644 index 0000000..f0f0978 --- /dev/null +++ b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_heart.png.meta @@ -0,0 +1,96 @@ +fileFormatVersion: 2 +guid: d173388c1d9c32a418b5b777dd89d71a +TextureImporter: + internalIDToNameTable: [] + externalObjects: {} + serializedVersion: 11 + mipmaps: + mipMapMode: 0 + enableMipMap: 1 + sRGBTexture: 1 + linearTexture: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + streamingMipmaps: 0 + streamingMipmapsPriority: 0 + vTOnly: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: -1 + maxTextureSize: 1024 + textureSettings: + serializedVersion: 2 + filterMode: 1 + aniso: 1 + mipBias: 0 + wrapU: 0 + wrapV: 0 + wrapW: 0 + nPOTScale: 1 + lightmap: 0 + compressionQuality: 50 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spritePixelsToUnits: 100 + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spriteGenerateFallbackPhysicsShape: 1 + alphaUsage: 1 + alphaIsTransparency: 0 + spriteTessellationDetail: -1 + textureType: 0 + textureShape: 1 + singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + platformSettings: + - serializedVersion: 3 + buildTarget: DefaultTexturePlatform + maxTextureSize: 1024 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + bones: [] + spriteID: + internalID: 0 + vertices: [] + indices: + edges: [] + weights: [] + secondaryTextures: [] + spritePackingTag: + pSDRemoveMatte: 0 + pSDShowRemoveMatteOption: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_heart_border.png b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_heart_border.png new file mode 100644 index 0000000..a533084 Binary files /dev/null and b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_heart_border.png differ diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_heart_border.png.meta b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_heart_border.png.meta new file mode 100644 index 0000000..81eb146 --- /dev/null +++ b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_heart_border.png.meta @@ -0,0 +1,96 @@ +fileFormatVersion: 2 +guid: 669c487f3c9c5fe4abb6459f9c2628f0 +TextureImporter: + internalIDToNameTable: [] + externalObjects: {} + serializedVersion: 11 + mipmaps: + mipMapMode: 0 + enableMipMap: 1 + sRGBTexture: 1 + linearTexture: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + streamingMipmaps: 0 + streamingMipmapsPriority: 0 + vTOnly: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: -1 + maxTextureSize: 1024 + textureSettings: + serializedVersion: 2 + filterMode: 1 + aniso: 1 + mipBias: 0 + wrapU: 0 + wrapV: 0 + wrapW: 0 + nPOTScale: 1 + lightmap: 0 + compressionQuality: 50 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spritePixelsToUnits: 100 + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spriteGenerateFallbackPhysicsShape: 1 + alphaUsage: 1 + alphaIsTransparency: 0 + spriteTessellationDetail: -1 + textureType: 0 + textureShape: 1 + singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + platformSettings: + - serializedVersion: 3 + buildTarget: DefaultTexturePlatform + maxTextureSize: 1024 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + bones: [] + spriteID: + internalID: 0 + vertices: [] + indices: + edges: [] + weights: [] + secondaryTextures: [] + spritePackingTag: + pSDRemoveMatte: 0 + pSDShowRemoveMatteOption: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_nodeArrow.png b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_nodeArrow.png new file mode 100644 index 0000000..e236c92 Binary files /dev/null and b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_nodeArrow.png differ diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_nodeArrow.png.meta b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_nodeArrow.png.meta new file mode 100644 index 0000000..93fc379 --- /dev/null +++ b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_nodeArrow.png.meta @@ -0,0 +1,96 @@ +fileFormatVersion: 2 +guid: 4aa34055b1d36ef479af3d7b5701b28a +TextureImporter: + internalIDToNameTable: [] + externalObjects: {} + serializedVersion: 11 + mipmaps: + mipMapMode: 0 + enableMipMap: 1 + sRGBTexture: 1 + linearTexture: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + streamingMipmaps: 0 + streamingMipmapsPriority: 0 + vTOnly: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: -1 + maxTextureSize: 1024 + textureSettings: + serializedVersion: 2 + filterMode: 1 + aniso: 1 + mipBias: 0 + wrapU: 0 + wrapV: 0 + wrapW: 0 + nPOTScale: 1 + lightmap: 0 + compressionQuality: 50 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spritePixelsToUnits: 100 + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spriteGenerateFallbackPhysicsShape: 1 + alphaUsage: 1 + alphaIsTransparency: 0 + spriteTessellationDetail: -1 + textureType: 0 + textureShape: 1 + singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + platformSettings: + - serializedVersion: 3 + buildTarget: DefaultTexturePlatform + maxTextureSize: 1024 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + bones: [] + spriteID: + internalID: 0 + vertices: [] + indices: + edges: [] + weights: [] + secondaryTextures: [] + spritePackingTag: + pSDRemoveMatte: 0 + pSDShowRemoveMatteOption: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_play.png b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_play.png new file mode 100644 index 0000000..0608dcb Binary files /dev/null and b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_play.png differ diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_play.png.meta b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_play.png.meta new file mode 100644 index 0000000..cc11bd9 --- /dev/null +++ b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_play.png.meta @@ -0,0 +1,96 @@ +fileFormatVersion: 2 +guid: 2a563a43c33f0f3428d02b3a43886fc2 +TextureImporter: + internalIDToNameTable: [] + externalObjects: {} + serializedVersion: 11 + mipmaps: + mipMapMode: 0 + enableMipMap: 1 + sRGBTexture: 1 + linearTexture: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + streamingMipmaps: 0 + streamingMipmapsPriority: 0 + vTOnly: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: -1 + maxTextureSize: 1024 + textureSettings: + serializedVersion: 2 + filterMode: 1 + aniso: 1 + mipBias: 0 + wrapU: 0 + wrapV: 0 + wrapW: 0 + nPOTScale: 1 + lightmap: 0 + compressionQuality: 50 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spritePixelsToUnits: 100 + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spriteGenerateFallbackPhysicsShape: 1 + alphaUsage: 1 + alphaIsTransparency: 0 + spriteTessellationDetail: -1 + textureType: 0 + textureShape: 1 + singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + platformSettings: + - serializedVersion: 3 + buildTarget: DefaultTexturePlatform + maxTextureSize: 1024 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + bones: [] + spriteID: + internalID: 0 + vertices: [] + indices: + edges: [] + weights: [] + secondaryTextures: [] + spritePackingTag: + pSDRemoveMatte: 0 + pSDShowRemoveMatteOption: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_play_border.png b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_play_border.png new file mode 100644 index 0000000..db4ac28 Binary files /dev/null and b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_play_border.png differ diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_play_border.png.meta b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_play_border.png.meta new file mode 100644 index 0000000..a559d07 --- /dev/null +++ b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_play_border.png.meta @@ -0,0 +1,96 @@ +fileFormatVersion: 2 +guid: 45e128e1cf00555479ee7934ab11cadf +TextureImporter: + internalIDToNameTable: [] + externalObjects: {} + serializedVersion: 11 + mipmaps: + mipMapMode: 0 + enableMipMap: 1 + sRGBTexture: 1 + linearTexture: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + streamingMipmaps: 0 + streamingMipmapsPriority: 0 + vTOnly: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: -1 + maxTextureSize: 1024 + textureSettings: + serializedVersion: 2 + filterMode: 1 + aniso: 1 + mipBias: 0 + wrapU: 0 + wrapV: 0 + wrapW: 0 + nPOTScale: 1 + lightmap: 0 + compressionQuality: 50 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spritePixelsToUnits: 100 + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spriteGenerateFallbackPhysicsShape: 1 + alphaUsage: 1 + alphaIsTransparency: 0 + spriteTessellationDetail: -1 + textureType: 0 + textureShape: 1 + singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + platformSettings: + - serializedVersion: 3 + buildTarget: DefaultTexturePlatform + maxTextureSize: 1024 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + bones: [] + spriteID: + internalID: 0 + vertices: [] + indices: + edges: [] + weights: [] + secondaryTextures: [] + spritePackingTag: + pSDRemoveMatte: 0 + pSDShowRemoveMatteOption: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_skull.png b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_skull.png new file mode 100644 index 0000000..7e53975 Binary files /dev/null and b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_skull.png differ diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_skull.png.meta b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_skull.png.meta new file mode 100644 index 0000000..1177f41 --- /dev/null +++ b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_skull.png.meta @@ -0,0 +1,96 @@ +fileFormatVersion: 2 +guid: 01976ad42d31f494e8040d3e32e283dc +TextureImporter: + internalIDToNameTable: [] + externalObjects: {} + serializedVersion: 11 + mipmaps: + mipMapMode: 0 + enableMipMap: 1 + sRGBTexture: 1 + linearTexture: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + streamingMipmaps: 0 + streamingMipmapsPriority: 0 + vTOnly: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: -1 + maxTextureSize: 1024 + textureSettings: + serializedVersion: 2 + filterMode: 1 + aniso: 1 + mipBias: 0 + wrapU: 0 + wrapV: 0 + wrapW: 0 + nPOTScale: 1 + lightmap: 0 + compressionQuality: 50 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spritePixelsToUnits: 100 + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spriteGenerateFallbackPhysicsShape: 1 + alphaUsage: 1 + alphaIsTransparency: 0 + spriteTessellationDetail: -1 + textureType: 0 + textureShape: 1 + singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + platformSettings: + - serializedVersion: 3 + buildTarget: DefaultTexturePlatform + maxTextureSize: 1024 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + bones: [] + spriteID: + internalID: 0 + vertices: [] + indices: + edges: [] + weights: [] + secondaryTextures: [] + spritePackingTag: + pSDRemoveMatte: 0 + pSDShowRemoveMatteOption: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_skull_border.png b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_skull_border.png new file mode 100644 index 0000000..6cc1c5f Binary files /dev/null and b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_skull_border.png differ diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_skull_border.png.meta b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_skull_border.png.meta new file mode 100644 index 0000000..57959fb --- /dev/null +++ b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_skull_border.png.meta @@ -0,0 +1,96 @@ +fileFormatVersion: 2 +guid: 6dfd924c0ba23844fb5d04ad1560de22 +TextureImporter: + internalIDToNameTable: [] + externalObjects: {} + serializedVersion: 11 + mipmaps: + mipMapMode: 0 + enableMipMap: 1 + sRGBTexture: 1 + linearTexture: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + streamingMipmaps: 0 + streamingMipmapsPriority: 0 + vTOnly: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: -1 + maxTextureSize: 1024 + textureSettings: + serializedVersion: 2 + filterMode: 1 + aniso: 1 + mipBias: 0 + wrapU: 0 + wrapV: 0 + wrapW: 0 + nPOTScale: 1 + lightmap: 0 + compressionQuality: 50 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spritePixelsToUnits: 100 + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spriteGenerateFallbackPhysicsShape: 1 + alphaUsage: 1 + alphaIsTransparency: 0 + spriteTessellationDetail: -1 + textureType: 0 + textureShape: 1 + singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + platformSettings: + - serializedVersion: 3 + buildTarget: DefaultTexturePlatform + maxTextureSize: 1024 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + bones: [] + spriteID: + internalID: 0 + vertices: [] + indices: + edges: [] + weights: [] + secondaryTextures: [] + spritePackingTag: + pSDRemoveMatte: 0 + pSDShowRemoveMatteOption: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_star.png b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_star.png new file mode 100644 index 0000000..d280684 Binary files /dev/null and b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_star.png differ diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_star.png.meta b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_star.png.meta new file mode 100644 index 0000000..d4f8f10 --- /dev/null +++ b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_star.png.meta @@ -0,0 +1,96 @@ +fileFormatVersion: 2 +guid: 645aafe2260b2884a9df05b4bc01b1ec +TextureImporter: + internalIDToNameTable: [] + externalObjects: {} + serializedVersion: 11 + mipmaps: + mipMapMode: 0 + enableMipMap: 1 + sRGBTexture: 1 + linearTexture: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + streamingMipmaps: 0 + streamingMipmapsPriority: 0 + vTOnly: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: -1 + maxTextureSize: 1024 + textureSettings: + serializedVersion: 2 + filterMode: 1 + aniso: 1 + mipBias: 0 + wrapU: 0 + wrapV: 0 + wrapW: 0 + nPOTScale: 1 + lightmap: 0 + compressionQuality: 50 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spritePixelsToUnits: 100 + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spriteGenerateFallbackPhysicsShape: 1 + alphaUsage: 1 + alphaIsTransparency: 0 + spriteTessellationDetail: -1 + textureType: 0 + textureShape: 1 + singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + platformSettings: + - serializedVersion: 3 + buildTarget: DefaultTexturePlatform + maxTextureSize: 1024 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + bones: [] + spriteID: + internalID: 0 + vertices: [] + indices: + edges: [] + weights: [] + secondaryTextures: [] + spritePackingTag: + pSDRemoveMatte: 0 + pSDShowRemoveMatteOption: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_star_border.png b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_star_border.png new file mode 100644 index 0000000..4615829 Binary files /dev/null and b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_star_border.png differ diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_star_border.png.meta b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_star_border.png.meta new file mode 100644 index 0000000..b779145 --- /dev/null +++ b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_star_border.png.meta @@ -0,0 +1,96 @@ +fileFormatVersion: 2 +guid: 18f3a26aa87fccc4cb5e211d4c6de662 +TextureImporter: + internalIDToNameTable: [] + externalObjects: {} + serializedVersion: 11 + mipmaps: + mipMapMode: 0 + enableMipMap: 1 + sRGBTexture: 1 + linearTexture: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + streamingMipmaps: 0 + streamingMipmapsPriority: 0 + vTOnly: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: -1 + maxTextureSize: 1024 + textureSettings: + serializedVersion: 2 + filterMode: 1 + aniso: 1 + mipBias: 0 + wrapU: 0 + wrapV: 0 + wrapW: 0 + nPOTScale: 1 + lightmap: 0 + compressionQuality: 50 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spritePixelsToUnits: 100 + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spriteGenerateFallbackPhysicsShape: 1 + alphaUsage: 1 + alphaIsTransparency: 0 + spriteTessellationDetail: -1 + textureType: 0 + textureShape: 1 + singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + platformSettings: + - serializedVersion: 3 + buildTarget: DefaultTexturePlatform + maxTextureSize: 1024 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + bones: [] + spriteID: + internalID: 0 + vertices: [] + indices: + edges: [] + weights: [] + secondaryTextures: [] + spritePackingTag: + pSDRemoveMatte: 0 + pSDShowRemoveMatteOption: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_ui.png b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_ui.png new file mode 100644 index 0000000..afdcff3 Binary files /dev/null and b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_ui.png differ diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_ui.png.meta b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_ui.png.meta new file mode 100644 index 0000000..9b97cb0 --- /dev/null +++ b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_ui.png.meta @@ -0,0 +1,96 @@ +fileFormatVersion: 2 +guid: cb46e1d925af22d43a6f8bf0e1d459e6 +TextureImporter: + internalIDToNameTable: [] + externalObjects: {} + serializedVersion: 11 + mipmaps: + mipMapMode: 0 + enableMipMap: 1 + sRGBTexture: 1 + linearTexture: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + streamingMipmaps: 0 + streamingMipmapsPriority: 0 + vTOnly: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: -1 + maxTextureSize: 1024 + textureSettings: + serializedVersion: 2 + filterMode: 1 + aniso: 1 + mipBias: 0 + wrapU: 0 + wrapV: 0 + wrapW: 0 + nPOTScale: 1 + lightmap: 0 + compressionQuality: 50 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spritePixelsToUnits: 100 + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spriteGenerateFallbackPhysicsShape: 1 + alphaUsage: 1 + alphaIsTransparency: 0 + spriteTessellationDetail: -1 + textureType: 0 + textureShape: 1 + singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + platformSettings: + - serializedVersion: 3 + buildTarget: DefaultTexturePlatform + maxTextureSize: 1024 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + bones: [] + spriteID: + internalID: 0 + vertices: [] + indices: + edges: [] + weights: [] + secondaryTextures: [] + spritePackingTag: + pSDRemoveMatte: 0 + pSDShowRemoveMatteOption: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_ui_border.png b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_ui_border.png new file mode 100644 index 0000000..6613a3d Binary files /dev/null and b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_ui_border.png differ diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_ui_border.png.meta b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_ui_border.png.meta new file mode 100644 index 0000000..0d81520 --- /dev/null +++ b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/ico_ui_border.png.meta @@ -0,0 +1,96 @@ +fileFormatVersion: 2 +guid: c0c40ceac3c6df146a0fcd4e6b226540 +TextureImporter: + internalIDToNameTable: [] + externalObjects: {} + serializedVersion: 11 + mipmaps: + mipMapMode: 0 + enableMipMap: 1 + sRGBTexture: 1 + linearTexture: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + streamingMipmaps: 0 + streamingMipmapsPriority: 0 + vTOnly: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: -1 + maxTextureSize: 1024 + textureSettings: + serializedVersion: 2 + filterMode: 1 + aniso: 1 + mipBias: 0 + wrapU: 0 + wrapV: 0 + wrapW: 0 + nPOTScale: 1 + lightmap: 0 + compressionQuality: 50 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spritePixelsToUnits: 100 + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spriteGenerateFallbackPhysicsShape: 1 + alphaUsage: 1 + alphaIsTransparency: 0 + spriteTessellationDetail: -1 + textureType: 0 + textureShape: 1 + singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + platformSettings: + - serializedVersion: 3 + buildTarget: DefaultTexturePlatform + maxTextureSize: 1024 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + bones: [] + spriteID: + internalID: 0 + vertices: [] + indices: + edges: [] + weights: [] + secondaryTextures: [] + spritePackingTag: + pSDRemoveMatte: 0 + pSDShowRemoveMatteOption: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/orangeSquare.png b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/orangeSquare.png new file mode 100644 index 0000000..c272180 Binary files /dev/null and b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/orangeSquare.png differ diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/orangeSquare.png.meta b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/orangeSquare.png.meta new file mode 100644 index 0000000..5be4c3a --- /dev/null +++ b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/orangeSquare.png.meta @@ -0,0 +1,96 @@ +fileFormatVersion: 2 +guid: 3e730492361eb6e45be5c5fdafac23be +TextureImporter: + internalIDToNameTable: [] + externalObjects: {} + serializedVersion: 11 + mipmaps: + mipMapMode: 0 + enableMipMap: 0 + sRGBTexture: 1 + linearTexture: 1 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + streamingMipmaps: 0 + streamingMipmapsPriority: 0 + vTOnly: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: -3 + maxTextureSize: 32 + textureSettings: + serializedVersion: 2 + filterMode: 0 + aniso: 1 + mipBias: 0 + wrapU: 1 + wrapV: 1 + wrapW: 1 + nPOTScale: 0 + lightmap: 0 + compressionQuality: 100 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spritePixelsToUnits: 100 + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spriteGenerateFallbackPhysicsShape: 1 + alphaUsage: 1 + alphaIsTransparency: 1 + spriteTessellationDetail: -1 + textureType: 2 + textureShape: 1 + singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + platformSettings: + - serializedVersion: 3 + buildTarget: DefaultTexturePlatform + maxTextureSize: 32 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 0 + compressionQuality: 100 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + bones: [] + spriteID: + internalID: 0 + vertices: [] + indices: + edges: [] + weights: [] + secondaryTextures: [] + spritePackingTag: + pSDRemoveMatte: 0 + pSDShowRemoveMatteOption: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/project.meta b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/project.meta new file mode 100644 index 0000000..5fed64c --- /dev/null +++ b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/project.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 477e8245018164141884dcaea601d230 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/project/ico_atlas.png b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/project/ico_atlas.png new file mode 100644 index 0000000..80dc387 Binary files /dev/null and b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/project/ico_atlas.png differ diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/project/ico_atlas.png.meta b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/project/ico_atlas.png.meta new file mode 100644 index 0000000..6ff261e --- /dev/null +++ b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/project/ico_atlas.png.meta @@ -0,0 +1,96 @@ +fileFormatVersion: 2 +guid: e2279677842a8064fbae0bc889fb85ab +TextureImporter: + internalIDToNameTable: [] + externalObjects: {} + serializedVersion: 11 + mipmaps: + mipMapMode: 0 + enableMipMap: 1 + sRGBTexture: 1 + linearTexture: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + streamingMipmaps: 0 + streamingMipmapsPriority: 0 + vTOnly: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: -1 + maxTextureSize: 1024 + textureSettings: + serializedVersion: 2 + filterMode: 1 + aniso: 1 + mipBias: 0 + wrapU: 0 + wrapV: 0 + wrapW: 0 + nPOTScale: 1 + lightmap: 0 + compressionQuality: 50 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spritePixelsToUnits: 100 + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spriteGenerateFallbackPhysicsShape: 1 + alphaUsage: 1 + alphaIsTransparency: 0 + spriteTessellationDetail: -1 + textureType: 0 + textureShape: 1 + singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + platformSettings: + - serializedVersion: 3 + buildTarget: DefaultTexturePlatform + maxTextureSize: 1024 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + bones: [] + spriteID: + internalID: 0 + vertices: [] + indices: + edges: [] + weights: [] + secondaryTextures: [] + spritePackingTag: + pSDRemoveMatte: 0 + pSDShowRemoveMatteOption: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/project/ico_audio.png b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/project/ico_audio.png new file mode 100644 index 0000000..90c5212 Binary files /dev/null and b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/project/ico_audio.png differ diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/project/ico_audio.png.meta b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/project/ico_audio.png.meta new file mode 100644 index 0000000..1e3de49 --- /dev/null +++ b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/project/ico_audio.png.meta @@ -0,0 +1,96 @@ +fileFormatVersion: 2 +guid: e1af8927fb6f5634896d59aed409a589 +TextureImporter: + internalIDToNameTable: [] + externalObjects: {} + serializedVersion: 11 + mipmaps: + mipMapMode: 0 + enableMipMap: 1 + sRGBTexture: 1 + linearTexture: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + streamingMipmaps: 0 + streamingMipmapsPriority: 0 + vTOnly: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: -1 + maxTextureSize: 1024 + textureSettings: + serializedVersion: 2 + filterMode: 1 + aniso: 1 + mipBias: 0 + wrapU: 0 + wrapV: 0 + wrapW: 0 + nPOTScale: 1 + lightmap: 0 + compressionQuality: 50 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spritePixelsToUnits: 100 + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spriteGenerateFallbackPhysicsShape: 1 + alphaUsage: 1 + alphaIsTransparency: 0 + spriteTessellationDetail: -1 + textureType: 0 + textureShape: 1 + singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + platformSettings: + - serializedVersion: 3 + buildTarget: DefaultTexturePlatform + maxTextureSize: 1024 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + bones: [] + spriteID: + internalID: 0 + vertices: [] + indices: + edges: [] + weights: [] + secondaryTextures: [] + spritePackingTag: + pSDRemoveMatte: 0 + pSDShowRemoveMatteOption: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/project/ico_bundle.png b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/project/ico_bundle.png new file mode 100644 index 0000000..c418038 Binary files /dev/null and b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/project/ico_bundle.png differ diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/project/ico_bundle.png.meta b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/project/ico_bundle.png.meta new file mode 100644 index 0000000..af5a1da --- /dev/null +++ b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/project/ico_bundle.png.meta @@ -0,0 +1,96 @@ +fileFormatVersion: 2 +guid: 58676a985ae875646b7be748cf4499fd +TextureImporter: + internalIDToNameTable: [] + externalObjects: {} + serializedVersion: 11 + mipmaps: + mipMapMode: 0 + enableMipMap: 1 + sRGBTexture: 1 + linearTexture: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + streamingMipmaps: 0 + streamingMipmapsPriority: 0 + vTOnly: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: -1 + maxTextureSize: 1024 + textureSettings: + serializedVersion: 2 + filterMode: 1 + aniso: 1 + mipBias: 0 + wrapU: 0 + wrapV: 0 + wrapW: 0 + nPOTScale: 1 + lightmap: 0 + compressionQuality: 50 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spritePixelsToUnits: 100 + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spriteGenerateFallbackPhysicsShape: 1 + alphaUsage: 1 + alphaIsTransparency: 0 + spriteTessellationDetail: -1 + textureType: 0 + textureShape: 1 + singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + platformSettings: + - serializedVersion: 3 + buildTarget: DefaultTexturePlatform + maxTextureSize: 1024 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + bones: [] + spriteID: + internalID: 0 + vertices: [] + indices: + edges: [] + weights: [] + secondaryTextures: [] + spritePackingTag: + pSDRemoveMatte: 0 + pSDShowRemoveMatteOption: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/project/ico_cog.png b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/project/ico_cog.png new file mode 100644 index 0000000..fd589a0 Binary files /dev/null and b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/project/ico_cog.png differ diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/project/ico_cog.png.meta b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/project/ico_cog.png.meta new file mode 100644 index 0000000..8e8356d --- /dev/null +++ b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/project/ico_cog.png.meta @@ -0,0 +1,96 @@ +fileFormatVersion: 2 +guid: fb605a2688b31194887f2e7a6769235b +TextureImporter: + internalIDToNameTable: [] + externalObjects: {} + serializedVersion: 11 + mipmaps: + mipMapMode: 0 + enableMipMap: 1 + sRGBTexture: 1 + linearTexture: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + streamingMipmaps: 0 + streamingMipmapsPriority: 0 + vTOnly: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: -1 + maxTextureSize: 1024 + textureSettings: + serializedVersion: 2 + filterMode: 1 + aniso: 1 + mipBias: 0 + wrapU: 0 + wrapV: 0 + wrapW: 0 + nPOTScale: 1 + lightmap: 0 + compressionQuality: 50 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spritePixelsToUnits: 100 + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spriteGenerateFallbackPhysicsShape: 1 + alphaUsage: 1 + alphaIsTransparency: 0 + spriteTessellationDetail: -1 + textureType: 0 + textureShape: 1 + singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + platformSettings: + - serializedVersion: 3 + buildTarget: DefaultTexturePlatform + maxTextureSize: 1024 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + bones: [] + spriteID: + internalID: 0 + vertices: [] + indices: + edges: [] + weights: [] + secondaryTextures: [] + spritePackingTag: + pSDRemoveMatte: 0 + pSDShowRemoveMatteOption: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/project/ico_cross.png b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/project/ico_cross.png new file mode 100644 index 0000000..a34a3e8 Binary files /dev/null and b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/project/ico_cross.png differ diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/project/ico_cross.png.meta b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/project/ico_cross.png.meta new file mode 100644 index 0000000..f0deff1 --- /dev/null +++ b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/project/ico_cross.png.meta @@ -0,0 +1,96 @@ +fileFormatVersion: 2 +guid: 3b67e53c8c2f8114b966c0e70d452419 +TextureImporter: + internalIDToNameTable: [] + externalObjects: {} + serializedVersion: 11 + mipmaps: + mipMapMode: 0 + enableMipMap: 1 + sRGBTexture: 1 + linearTexture: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + streamingMipmaps: 0 + streamingMipmapsPriority: 0 + vTOnly: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: -1 + maxTextureSize: 1024 + textureSettings: + serializedVersion: 2 + filterMode: 1 + aniso: 1 + mipBias: 0 + wrapU: 0 + wrapV: 0 + wrapW: 0 + nPOTScale: 1 + lightmap: 0 + compressionQuality: 50 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spritePixelsToUnits: 100 + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spriteGenerateFallbackPhysicsShape: 1 + alphaUsage: 1 + alphaIsTransparency: 0 + spriteTessellationDetail: -1 + textureType: 0 + textureShape: 1 + singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + platformSettings: + - serializedVersion: 3 + buildTarget: DefaultTexturePlatform + maxTextureSize: 1024 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + bones: [] + spriteID: + internalID: 0 + vertices: [] + indices: + edges: [] + weights: [] + secondaryTextures: [] + spritePackingTag: + pSDRemoveMatte: 0 + pSDShowRemoveMatteOption: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/project/ico_demigiant.png b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/project/ico_demigiant.png new file mode 100644 index 0000000..99d0cf9 Binary files /dev/null and b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/project/ico_demigiant.png differ diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/project/ico_demigiant.png.meta b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/project/ico_demigiant.png.meta new file mode 100644 index 0000000..7fa564a --- /dev/null +++ b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/project/ico_demigiant.png.meta @@ -0,0 +1,96 @@ +fileFormatVersion: 2 +guid: f36ab42cc6fcdfd4187033279d3d14a9 +TextureImporter: + internalIDToNameTable: [] + externalObjects: {} + serializedVersion: 11 + mipmaps: + mipMapMode: 0 + enableMipMap: 1 + sRGBTexture: 1 + linearTexture: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + streamingMipmaps: 0 + streamingMipmapsPriority: 0 + vTOnly: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: -1 + maxTextureSize: 1024 + textureSettings: + serializedVersion: 2 + filterMode: 1 + aniso: 1 + mipBias: 0 + wrapU: 0 + wrapV: 0 + wrapW: 0 + nPOTScale: 1 + lightmap: 0 + compressionQuality: 50 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spritePixelsToUnits: 100 + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spriteGenerateFallbackPhysicsShape: 1 + alphaUsage: 1 + alphaIsTransparency: 0 + spriteTessellationDetail: -1 + textureType: 0 + textureShape: 1 + singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + platformSettings: + - serializedVersion: 3 + buildTarget: DefaultTexturePlatform + maxTextureSize: 1024 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + bones: [] + spriteID: + internalID: 0 + vertices: [] + indices: + edges: [] + weights: [] + secondaryTextures: [] + spritePackingTag: + pSDRemoveMatte: 0 + pSDShowRemoveMatteOption: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/project/ico_folder.png b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/project/ico_folder.png new file mode 100644 index 0000000..9bba7d0 Binary files /dev/null and b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/project/ico_folder.png differ diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/project/ico_folder.png.meta b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/project/ico_folder.png.meta new file mode 100644 index 0000000..86d9590 --- /dev/null +++ b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/project/ico_folder.png.meta @@ -0,0 +1,96 @@ +fileFormatVersion: 2 +guid: 4f2c4b43188596b47866d41e1dc13c8a +TextureImporter: + internalIDToNameTable: [] + externalObjects: {} + serializedVersion: 11 + mipmaps: + mipMapMode: 0 + enableMipMap: 1 + sRGBTexture: 1 + linearTexture: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + streamingMipmaps: 0 + streamingMipmapsPriority: 0 + vTOnly: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: -1 + maxTextureSize: 1024 + textureSettings: + serializedVersion: 2 + filterMode: 1 + aniso: 1 + mipBias: 0 + wrapU: 0 + wrapV: 0 + wrapW: 0 + nPOTScale: 1 + lightmap: 0 + compressionQuality: 50 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spritePixelsToUnits: 100 + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spriteGenerateFallbackPhysicsShape: 1 + alphaUsage: 1 + alphaIsTransparency: 0 + spriteTessellationDetail: -1 + textureType: 0 + textureShape: 1 + singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + platformSettings: + - serializedVersion: 3 + buildTarget: DefaultTexturePlatform + maxTextureSize: 1024 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + bones: [] + spriteID: + internalID: 0 + vertices: [] + indices: + edges: [] + weights: [] + secondaryTextures: [] + spritePackingTag: + pSDRemoveMatte: 0 + pSDShowRemoveMatteOption: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/project/ico_fonts.png b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/project/ico_fonts.png new file mode 100644 index 0000000..9ce1a4d Binary files /dev/null and b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/project/ico_fonts.png differ diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/project/ico_fonts.png.meta b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/project/ico_fonts.png.meta new file mode 100644 index 0000000..4ee6b7c --- /dev/null +++ b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/project/ico_fonts.png.meta @@ -0,0 +1,96 @@ +fileFormatVersion: 2 +guid: cf986943c88c2254780c17b2b5e3bc2f +TextureImporter: + internalIDToNameTable: [] + externalObjects: {} + serializedVersion: 11 + mipmaps: + mipMapMode: 0 + enableMipMap: 1 + sRGBTexture: 1 + linearTexture: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + streamingMipmaps: 0 + streamingMipmapsPriority: 0 + vTOnly: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: -1 + maxTextureSize: 1024 + textureSettings: + serializedVersion: 2 + filterMode: 1 + aniso: 1 + mipBias: 0 + wrapU: 0 + wrapV: 0 + wrapW: 0 + nPOTScale: 1 + lightmap: 0 + compressionQuality: 50 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spritePixelsToUnits: 100 + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spriteGenerateFallbackPhysicsShape: 1 + alphaUsage: 1 + alphaIsTransparency: 0 + spriteTessellationDetail: -1 + textureType: 0 + textureShape: 1 + singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + platformSettings: + - serializedVersion: 3 + buildTarget: DefaultTexturePlatform + maxTextureSize: 1024 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + bones: [] + spriteID: + internalID: 0 + vertices: [] + indices: + edges: [] + weights: [] + secondaryTextures: [] + spritePackingTag: + pSDRemoveMatte: 0 + pSDShowRemoveMatteOption: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/project/ico_heart.png b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/project/ico_heart.png new file mode 100644 index 0000000..f7ebe72 Binary files /dev/null and b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/project/ico_heart.png differ diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/project/ico_heart.png.meta b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/project/ico_heart.png.meta new file mode 100644 index 0000000..77f316e --- /dev/null +++ b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/project/ico_heart.png.meta @@ -0,0 +1,96 @@ +fileFormatVersion: 2 +guid: 20794834c0a413f408b80110d0fc73b8 +TextureImporter: + internalIDToNameTable: [] + externalObjects: {} + serializedVersion: 11 + mipmaps: + mipMapMode: 0 + enableMipMap: 1 + sRGBTexture: 1 + linearTexture: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + streamingMipmaps: 0 + streamingMipmapsPriority: 0 + vTOnly: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: -1 + maxTextureSize: 1024 + textureSettings: + serializedVersion: 2 + filterMode: 1 + aniso: 1 + mipBias: 0 + wrapU: 0 + wrapV: 0 + wrapW: 0 + nPOTScale: 1 + lightmap: 0 + compressionQuality: 50 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spritePixelsToUnits: 100 + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spriteGenerateFallbackPhysicsShape: 1 + alphaUsage: 1 + alphaIsTransparency: 0 + spriteTessellationDetail: -1 + textureType: 0 + textureShape: 1 + singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + platformSettings: + - serializedVersion: 3 + buildTarget: DefaultTexturePlatform + maxTextureSize: 1024 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + bones: [] + spriteID: + internalID: 0 + vertices: [] + indices: + edges: [] + weights: [] + secondaryTextures: [] + spritePackingTag: + pSDRemoveMatte: 0 + pSDShowRemoveMatteOption: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/project/ico_play.png b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/project/ico_play.png new file mode 100644 index 0000000..c441add Binary files /dev/null and b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/project/ico_play.png differ diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/project/ico_play.png.meta b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/project/ico_play.png.meta new file mode 100644 index 0000000..80a3feb --- /dev/null +++ b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/project/ico_play.png.meta @@ -0,0 +1,96 @@ +fileFormatVersion: 2 +guid: d8306b1e159c72c4ebc9a4fc31debe60 +TextureImporter: + internalIDToNameTable: [] + externalObjects: {} + serializedVersion: 11 + mipmaps: + mipMapMode: 0 + enableMipMap: 1 + sRGBTexture: 1 + linearTexture: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + streamingMipmaps: 0 + streamingMipmapsPriority: 0 + vTOnly: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: -1 + maxTextureSize: 1024 + textureSettings: + serializedVersion: 2 + filterMode: 1 + aniso: 1 + mipBias: 0 + wrapU: 0 + wrapV: 0 + wrapW: 0 + nPOTScale: 1 + lightmap: 0 + compressionQuality: 50 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spritePixelsToUnits: 100 + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spriteGenerateFallbackPhysicsShape: 1 + alphaUsage: 1 + alphaIsTransparency: 0 + spriteTessellationDetail: -1 + textureType: 0 + textureShape: 1 + singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + platformSettings: + - serializedVersion: 3 + buildTarget: DefaultTexturePlatform + maxTextureSize: 1024 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + bones: [] + spriteID: + internalID: 0 + vertices: [] + indices: + edges: [] + weights: [] + secondaryTextures: [] + spritePackingTag: + pSDRemoveMatte: 0 + pSDShowRemoveMatteOption: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/project/ico_prefab.png b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/project/ico_prefab.png new file mode 100644 index 0000000..abc4353 Binary files /dev/null and b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/project/ico_prefab.png differ diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/project/ico_prefab.png.meta b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/project/ico_prefab.png.meta new file mode 100644 index 0000000..9ffb6ce --- /dev/null +++ b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/project/ico_prefab.png.meta @@ -0,0 +1,96 @@ +fileFormatVersion: 2 +guid: ed3789262161efa4fa33c85ca534590e +TextureImporter: + internalIDToNameTable: [] + externalObjects: {} + serializedVersion: 11 + mipmaps: + mipMapMode: 0 + enableMipMap: 1 + sRGBTexture: 1 + linearTexture: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + streamingMipmaps: 0 + streamingMipmapsPriority: 0 + vTOnly: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: -1 + maxTextureSize: 1024 + textureSettings: + serializedVersion: 2 + filterMode: 1 + aniso: 1 + mipBias: 0 + wrapU: 0 + wrapV: 0 + wrapW: 0 + nPOTScale: 1 + lightmap: 0 + compressionQuality: 50 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spritePixelsToUnits: 100 + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spriteGenerateFallbackPhysicsShape: 1 + alphaUsage: 1 + alphaIsTransparency: 0 + spriteTessellationDetail: -1 + textureType: 0 + textureShape: 1 + singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + platformSettings: + - serializedVersion: 3 + buildTarget: DefaultTexturePlatform + maxTextureSize: 1024 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + bones: [] + spriteID: + internalID: 0 + vertices: [] + indices: + edges: [] + weights: [] + secondaryTextures: [] + spritePackingTag: + pSDRemoveMatte: 0 + pSDShowRemoveMatteOption: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/project/ico_scripts.png b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/project/ico_scripts.png new file mode 100644 index 0000000..c79b668 Binary files /dev/null and b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/project/ico_scripts.png differ diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/project/ico_scripts.png.meta b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/project/ico_scripts.png.meta new file mode 100644 index 0000000..1a4b328 --- /dev/null +++ b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/project/ico_scripts.png.meta @@ -0,0 +1,96 @@ +fileFormatVersion: 2 +guid: 96cbdf605b8ddb34da384703f2d0b849 +TextureImporter: + internalIDToNameTable: [] + externalObjects: {} + serializedVersion: 11 + mipmaps: + mipMapMode: 0 + enableMipMap: 1 + sRGBTexture: 1 + linearTexture: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + streamingMipmaps: 0 + streamingMipmapsPriority: 0 + vTOnly: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: -1 + maxTextureSize: 1024 + textureSettings: + serializedVersion: 2 + filterMode: 1 + aniso: 1 + mipBias: 0 + wrapU: 0 + wrapV: 0 + wrapW: 0 + nPOTScale: 1 + lightmap: 0 + compressionQuality: 50 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spritePixelsToUnits: 100 + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spriteGenerateFallbackPhysicsShape: 1 + alphaUsage: 1 + alphaIsTransparency: 0 + spriteTessellationDetail: -1 + textureType: 0 + textureShape: 1 + singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + platformSettings: + - serializedVersion: 3 + buildTarget: DefaultTexturePlatform + maxTextureSize: 1024 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + bones: [] + spriteID: + internalID: 0 + vertices: [] + indices: + edges: [] + weights: [] + secondaryTextures: [] + spritePackingTag: + pSDRemoveMatte: 0 + pSDShowRemoveMatteOption: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/project/ico_skull.png b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/project/ico_skull.png new file mode 100644 index 0000000..22930f4 Binary files /dev/null and b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/project/ico_skull.png differ diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/project/ico_skull.png.meta b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/project/ico_skull.png.meta new file mode 100644 index 0000000..9b1acad --- /dev/null +++ b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/project/ico_skull.png.meta @@ -0,0 +1,96 @@ +fileFormatVersion: 2 +guid: d563d6ce25cd2ca48b185ec47a74a3fb +TextureImporter: + internalIDToNameTable: [] + externalObjects: {} + serializedVersion: 11 + mipmaps: + mipMapMode: 0 + enableMipMap: 1 + sRGBTexture: 1 + linearTexture: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + streamingMipmaps: 0 + streamingMipmapsPriority: 0 + vTOnly: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: -1 + maxTextureSize: 1024 + textureSettings: + serializedVersion: 2 + filterMode: 1 + aniso: 1 + mipBias: 0 + wrapU: 0 + wrapV: 0 + wrapW: 0 + nPOTScale: 1 + lightmap: 0 + compressionQuality: 50 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spritePixelsToUnits: 100 + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spriteGenerateFallbackPhysicsShape: 1 + alphaUsage: 1 + alphaIsTransparency: 0 + spriteTessellationDetail: -1 + textureType: 0 + textureShape: 1 + singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + platformSettings: + - serializedVersion: 3 + buildTarget: DefaultTexturePlatform + maxTextureSize: 1024 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + bones: [] + spriteID: + internalID: 0 + vertices: [] + indices: + edges: [] + weights: [] + secondaryTextures: [] + spritePackingTag: + pSDRemoveMatte: 0 + pSDShowRemoveMatteOption: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/project/ico_star.png b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/project/ico_star.png new file mode 100644 index 0000000..90483b3 Binary files /dev/null and b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/project/ico_star.png differ diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/project/ico_star.png.meta b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/project/ico_star.png.meta new file mode 100644 index 0000000..a464b6a --- /dev/null +++ b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/project/ico_star.png.meta @@ -0,0 +1,96 @@ +fileFormatVersion: 2 +guid: 21820ec6fc9dd0b4fbf42a3b93fdad4e +TextureImporter: + internalIDToNameTable: [] + externalObjects: {} + serializedVersion: 11 + mipmaps: + mipMapMode: 0 + enableMipMap: 1 + sRGBTexture: 1 + linearTexture: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + streamingMipmaps: 0 + streamingMipmapsPriority: 0 + vTOnly: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: -1 + maxTextureSize: 1024 + textureSettings: + serializedVersion: 2 + filterMode: 1 + aniso: 1 + mipBias: 0 + wrapU: 0 + wrapV: 0 + wrapW: 0 + nPOTScale: 1 + lightmap: 0 + compressionQuality: 50 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spritePixelsToUnits: 100 + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spriteGenerateFallbackPhysicsShape: 1 + alphaUsage: 1 + alphaIsTransparency: 0 + spriteTessellationDetail: -1 + textureType: 0 + textureShape: 1 + singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + platformSettings: + - serializedVersion: 3 + buildTarget: DefaultTexturePlatform + maxTextureSize: 1024 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + bones: [] + spriteID: + internalID: 0 + vertices: [] + indices: + edges: [] + weights: [] + secondaryTextures: [] + spritePackingTag: + pSDRemoveMatte: 0 + pSDShowRemoveMatteOption: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/project/ico_textures.png b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/project/ico_textures.png new file mode 100644 index 0000000..6aae964 Binary files /dev/null and b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/project/ico_textures.png differ diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/project/ico_textures.png.meta b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/project/ico_textures.png.meta new file mode 100644 index 0000000..12b2966 --- /dev/null +++ b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/project/ico_textures.png.meta @@ -0,0 +1,96 @@ +fileFormatVersion: 2 +guid: 3e6b96a975eba1c43b2bad66fb7f8b4a +TextureImporter: + internalIDToNameTable: [] + externalObjects: {} + serializedVersion: 11 + mipmaps: + mipMapMode: 0 + enableMipMap: 1 + sRGBTexture: 1 + linearTexture: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + streamingMipmaps: 0 + streamingMipmapsPriority: 0 + vTOnly: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: -1 + maxTextureSize: 1024 + textureSettings: + serializedVersion: 2 + filterMode: 1 + aniso: 1 + mipBias: 0 + wrapU: 0 + wrapV: 0 + wrapW: 0 + nPOTScale: 1 + lightmap: 0 + compressionQuality: 50 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spritePixelsToUnits: 100 + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spriteGenerateFallbackPhysicsShape: 1 + alphaUsage: 1 + alphaIsTransparency: 0 + spriteTessellationDetail: -1 + textureType: 0 + textureShape: 1 + singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + platformSettings: + - serializedVersion: 3 + buildTarget: DefaultTexturePlatform + maxTextureSize: 1024 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + bones: [] + spriteID: + internalID: 0 + vertices: [] + indices: + edges: [] + weights: [] + secondaryTextures: [] + spritePackingTag: + pSDRemoveMatte: 0 + pSDShowRemoveMatteOption: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/purpleSquare.png b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/purpleSquare.png new file mode 100644 index 0000000..dd219ac Binary files /dev/null and b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/purpleSquare.png differ diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/purpleSquare.png.meta b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/purpleSquare.png.meta new file mode 100644 index 0000000..144764f --- /dev/null +++ b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/purpleSquare.png.meta @@ -0,0 +1,96 @@ +fileFormatVersion: 2 +guid: dc0ca9b32ae9fd049911671cf1a480bf +TextureImporter: + internalIDToNameTable: [] + externalObjects: {} + serializedVersion: 11 + mipmaps: + mipMapMode: 0 + enableMipMap: 1 + sRGBTexture: 1 + linearTexture: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + streamingMipmaps: 0 + streamingMipmapsPriority: 0 + vTOnly: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: -1 + maxTextureSize: 1024 + textureSettings: + serializedVersion: 2 + filterMode: 1 + aniso: 1 + mipBias: 0 + wrapU: 0 + wrapV: 0 + wrapW: 0 + nPOTScale: 1 + lightmap: 0 + compressionQuality: 50 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spritePixelsToUnits: 100 + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spriteGenerateFallbackPhysicsShape: 1 + alphaUsage: 1 + alphaIsTransparency: 0 + spriteTessellationDetail: -1 + textureType: 0 + textureShape: 1 + singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + platformSettings: + - serializedVersion: 3 + buildTarget: DefaultTexturePlatform + maxTextureSize: 1024 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + bones: [] + spriteID: + internalID: 0 + vertices: [] + indices: + edges: [] + weights: [] + secondaryTextures: [] + spritePackingTag: + pSDRemoveMatte: 0 + pSDShowRemoveMatteOption: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/redSquare.png b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/redSquare.png new file mode 100644 index 0000000..798457f Binary files /dev/null and b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/redSquare.png differ diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/redSquare.png.meta b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/redSquare.png.meta new file mode 100644 index 0000000..66ccfbb --- /dev/null +++ b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/redSquare.png.meta @@ -0,0 +1,96 @@ +fileFormatVersion: 2 +guid: fbdd7ecf39c13bf48a5bd02a1159c90b +TextureImporter: + internalIDToNameTable: [] + externalObjects: {} + serializedVersion: 11 + mipmaps: + mipMapMode: 0 + enableMipMap: 1 + sRGBTexture: 1 + linearTexture: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + streamingMipmaps: 0 + streamingMipmapsPriority: 0 + vTOnly: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: -1 + maxTextureSize: 1024 + textureSettings: + serializedVersion: 2 + filterMode: 1 + aniso: 1 + mipBias: 0 + wrapU: 0 + wrapV: 0 + wrapW: 0 + nPOTScale: 1 + lightmap: 0 + compressionQuality: 50 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spritePixelsToUnits: 100 + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spriteGenerateFallbackPhysicsShape: 1 + alphaUsage: 1 + alphaIsTransparency: 0 + spriteTessellationDetail: -1 + textureType: 0 + textureShape: 1 + singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + platformSettings: + - serializedVersion: 3 + buildTarget: DefaultTexturePlatform + maxTextureSize: 1024 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + bones: [] + spriteID: + internalID: 0 + vertices: [] + indices: + edges: [] + weights: [] + secondaryTextures: [] + spritePackingTag: + pSDRemoveMatte: 0 + pSDShowRemoveMatteOption: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/squareBorder.png b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/squareBorder.png new file mode 100644 index 0000000..51afe67 Binary files /dev/null and b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/squareBorder.png differ diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/squareBorder.png.meta b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/squareBorder.png.meta new file mode 100644 index 0000000..5d141de --- /dev/null +++ b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/squareBorder.png.meta @@ -0,0 +1,96 @@ +fileFormatVersion: 2 +guid: afd7d0ddb1d6c744b9cb87ae49b2ce62 +TextureImporter: + internalIDToNameTable: [] + externalObjects: {} + serializedVersion: 11 + mipmaps: + mipMapMode: 0 + enableMipMap: 1 + sRGBTexture: 1 + linearTexture: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + streamingMipmaps: 0 + streamingMipmapsPriority: 0 + vTOnly: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: -1 + maxTextureSize: 1024 + textureSettings: + serializedVersion: 2 + filterMode: 1 + aniso: 1 + mipBias: 0 + wrapU: 0 + wrapV: 0 + wrapW: 0 + nPOTScale: 1 + lightmap: 0 + compressionQuality: 50 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spritePixelsToUnits: 100 + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spriteGenerateFallbackPhysicsShape: 1 + alphaUsage: 1 + alphaIsTransparency: 0 + spriteTessellationDetail: -1 + textureType: 0 + textureShape: 1 + singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + platformSettings: + - serializedVersion: 3 + buildTarget: DefaultTexturePlatform + maxTextureSize: 1024 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + bones: [] + spriteID: + internalID: 0 + vertices: [] + indices: + edges: [] + weights: [] + secondaryTextures: [] + spritePackingTag: + pSDRemoveMatte: 0 + pSDShowRemoveMatteOption: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/squareBorderAlpha15.png b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/squareBorderAlpha15.png new file mode 100644 index 0000000..7000d8f Binary files /dev/null and b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/squareBorderAlpha15.png differ diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/squareBorderAlpha15.png.meta b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/squareBorderAlpha15.png.meta new file mode 100644 index 0000000..9b0637a --- /dev/null +++ b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/squareBorderAlpha15.png.meta @@ -0,0 +1,96 @@ +fileFormatVersion: 2 +guid: dfd33662d9f6f3849bd92f6e159ca226 +TextureImporter: + internalIDToNameTable: [] + externalObjects: {} + serializedVersion: 11 + mipmaps: + mipMapMode: 0 + enableMipMap: 1 + sRGBTexture: 1 + linearTexture: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + streamingMipmaps: 0 + streamingMipmapsPriority: 0 + vTOnly: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: -1 + maxTextureSize: 1024 + textureSettings: + serializedVersion: 2 + filterMode: 1 + aniso: 1 + mipBias: 0 + wrapU: 0 + wrapV: 0 + wrapW: 0 + nPOTScale: 1 + lightmap: 0 + compressionQuality: 50 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spritePixelsToUnits: 100 + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spriteGenerateFallbackPhysicsShape: 1 + alphaUsage: 1 + alphaIsTransparency: 0 + spriteTessellationDetail: -1 + textureType: 0 + textureShape: 1 + singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + platformSettings: + - serializedVersion: 3 + buildTarget: DefaultTexturePlatform + maxTextureSize: 1024 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + bones: [] + spriteID: + internalID: 0 + vertices: [] + indices: + edges: [] + weights: [] + secondaryTextures: [] + spritePackingTag: + pSDRemoveMatte: 0 + pSDShowRemoveMatteOption: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/squareBorderCurved.png b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/squareBorderCurved.png new file mode 100644 index 0000000..768cc82 Binary files /dev/null and b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/squareBorderCurved.png differ diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/squareBorderCurved.png.meta b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/squareBorderCurved.png.meta new file mode 100644 index 0000000..ec132b8 --- /dev/null +++ b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/squareBorderCurved.png.meta @@ -0,0 +1,96 @@ +fileFormatVersion: 2 +guid: 4896b5aa9d63dec498136c21ffce735b +TextureImporter: + internalIDToNameTable: [] + externalObjects: {} + serializedVersion: 11 + mipmaps: + mipMapMode: 0 + enableMipMap: 0 + sRGBTexture: 1 + linearTexture: 1 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + streamingMipmaps: 0 + streamingMipmapsPriority: 0 + vTOnly: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: -3 + maxTextureSize: 32 + textureSettings: + serializedVersion: 2 + filterMode: 0 + aniso: 1 + mipBias: 0 + wrapU: 1 + wrapV: 1 + wrapW: 1 + nPOTScale: 0 + lightmap: 0 + compressionQuality: 100 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spritePixelsToUnits: 100 + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spriteGenerateFallbackPhysicsShape: 1 + alphaUsage: 1 + alphaIsTransparency: 1 + spriteTessellationDetail: -1 + textureType: 2 + textureShape: 1 + singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + platformSettings: + - serializedVersion: 3 + buildTarget: DefaultTexturePlatform + maxTextureSize: 32 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 0 + compressionQuality: 100 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + bones: [] + spriteID: + internalID: 0 + vertices: [] + indices: + edges: [] + weights: [] + secondaryTextures: [] + spritePackingTag: + pSDRemoveMatte: 0 + pSDShowRemoveMatteOption: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/squareBorderCurved02.png b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/squareBorderCurved02.png new file mode 100644 index 0000000..a1ed49d Binary files /dev/null and b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/squareBorderCurved02.png differ diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/squareBorderCurved02.png.meta b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/squareBorderCurved02.png.meta new file mode 100644 index 0000000..d648c5d --- /dev/null +++ b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/squareBorderCurved02.png.meta @@ -0,0 +1,96 @@ +fileFormatVersion: 2 +guid: ff88be84254fb1f4b9a81a27ae0b2e81 +TextureImporter: + internalIDToNameTable: [] + externalObjects: {} + serializedVersion: 11 + mipmaps: + mipMapMode: 0 + enableMipMap: 1 + sRGBTexture: 1 + linearTexture: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + streamingMipmaps: 0 + streamingMipmapsPriority: 0 + vTOnly: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: -1 + maxTextureSize: 1024 + textureSettings: + serializedVersion: 2 + filterMode: 1 + aniso: 1 + mipBias: 0 + wrapU: 0 + wrapV: 0 + wrapW: 0 + nPOTScale: 1 + lightmap: 0 + compressionQuality: 50 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spritePixelsToUnits: 100 + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spriteGenerateFallbackPhysicsShape: 1 + alphaUsage: 1 + alphaIsTransparency: 0 + spriteTessellationDetail: -1 + textureType: 0 + textureShape: 1 + singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + platformSettings: + - serializedVersion: 3 + buildTarget: DefaultTexturePlatform + maxTextureSize: 1024 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + bones: [] + spriteID: + internalID: 0 + vertices: [] + indices: + edges: [] + weights: [] + secondaryTextures: [] + spritePackingTag: + pSDRemoveMatte: 0 + pSDShowRemoveMatteOption: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/squareBorderCurved02_darkBorders.png b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/squareBorderCurved02_darkBorders.png new file mode 100644 index 0000000..2b313e4 Binary files /dev/null and b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/squareBorderCurved02_darkBorders.png differ diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/squareBorderCurved02_darkBorders.png.meta b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/squareBorderCurved02_darkBorders.png.meta new file mode 100644 index 0000000..e40a48a --- /dev/null +++ b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/squareBorderCurved02_darkBorders.png.meta @@ -0,0 +1,96 @@ +fileFormatVersion: 2 +guid: e3ae01f12865ad54ba365963bda55759 +TextureImporter: + internalIDToNameTable: [] + externalObjects: {} + serializedVersion: 11 + mipmaps: + mipMapMode: 0 + enableMipMap: 1 + sRGBTexture: 1 + linearTexture: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + streamingMipmaps: 0 + streamingMipmapsPriority: 0 + vTOnly: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: -1 + maxTextureSize: 1024 + textureSettings: + serializedVersion: 2 + filterMode: 1 + aniso: 1 + mipBias: 0 + wrapU: 0 + wrapV: 0 + wrapW: 0 + nPOTScale: 1 + lightmap: 0 + compressionQuality: 50 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spritePixelsToUnits: 100 + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spriteGenerateFallbackPhysicsShape: 1 + alphaUsage: 1 + alphaIsTransparency: 0 + spriteTessellationDetail: -1 + textureType: 0 + textureShape: 1 + singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + platformSettings: + - serializedVersion: 3 + buildTarget: DefaultTexturePlatform + maxTextureSize: 1024 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + bones: [] + spriteID: + internalID: 0 + vertices: [] + indices: + edges: [] + weights: [] + secondaryTextures: [] + spritePackingTag: + pSDRemoveMatte: 0 + pSDShowRemoveMatteOption: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/squareBorderCurvedAlpha.png b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/squareBorderCurvedAlpha.png new file mode 100644 index 0000000..e56d3b7 Binary files /dev/null and b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/squareBorderCurvedAlpha.png differ diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/squareBorderCurvedAlpha.png.meta b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/squareBorderCurvedAlpha.png.meta new file mode 100644 index 0000000..40d6b50 --- /dev/null +++ b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/squareBorderCurvedAlpha.png.meta @@ -0,0 +1,96 @@ +fileFormatVersion: 2 +guid: a1606d34a052ed3449da93edd229743e +TextureImporter: + internalIDToNameTable: [] + externalObjects: {} + serializedVersion: 11 + mipmaps: + mipMapMode: 0 + enableMipMap: 1 + sRGBTexture: 1 + linearTexture: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + streamingMipmaps: 0 + streamingMipmapsPriority: 0 + vTOnly: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: -1 + maxTextureSize: 1024 + textureSettings: + serializedVersion: 2 + filterMode: 1 + aniso: 1 + mipBias: 0 + wrapU: 0 + wrapV: 0 + wrapW: 0 + nPOTScale: 1 + lightmap: 0 + compressionQuality: 50 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spritePixelsToUnits: 100 + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spriteGenerateFallbackPhysicsShape: 1 + alphaUsage: 1 + alphaIsTransparency: 0 + spriteTessellationDetail: -1 + textureType: 0 + textureShape: 1 + singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + platformSettings: + - serializedVersion: 3 + buildTarget: DefaultTexturePlatform + maxTextureSize: 1024 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + bones: [] + spriteID: + internalID: 0 + vertices: [] + indices: + edges: [] + weights: [] + secondaryTextures: [] + spritePackingTag: + pSDRemoveMatte: 0 + pSDShowRemoveMatteOption: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/squareBorderCurvedEmpty.png b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/squareBorderCurvedEmpty.png new file mode 100644 index 0000000..bbd3158 Binary files /dev/null and b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/squareBorderCurvedEmpty.png differ diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/squareBorderCurvedEmpty.png.meta b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/squareBorderCurvedEmpty.png.meta new file mode 100644 index 0000000..ebafabd --- /dev/null +++ b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/squareBorderCurvedEmpty.png.meta @@ -0,0 +1,96 @@ +fileFormatVersion: 2 +guid: 4578222ee7a511446b0c340551bf8740 +TextureImporter: + internalIDToNameTable: [] + externalObjects: {} + serializedVersion: 11 + mipmaps: + mipMapMode: 0 + enableMipMap: 0 + sRGBTexture: 1 + linearTexture: 1 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + streamingMipmaps: 0 + streamingMipmapsPriority: 0 + vTOnly: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: -3 + maxTextureSize: 32 + textureSettings: + serializedVersion: 2 + filterMode: 0 + aniso: 1 + mipBias: 0 + wrapU: 1 + wrapV: 1 + wrapW: 1 + nPOTScale: 0 + lightmap: 0 + compressionQuality: 100 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spritePixelsToUnits: 100 + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spriteGenerateFallbackPhysicsShape: 1 + alphaUsage: 1 + alphaIsTransparency: 1 + spriteTessellationDetail: -1 + textureType: 2 + textureShape: 1 + singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + platformSettings: + - serializedVersion: 3 + buildTarget: DefaultTexturePlatform + maxTextureSize: 32 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 0 + compressionQuality: 100 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + bones: [] + spriteID: + internalID: 0 + vertices: [] + indices: + edges: [] + weights: [] + secondaryTextures: [] + spritePackingTag: + pSDRemoveMatte: 0 + pSDShowRemoveMatteOption: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/squareBorderCurvedEmpty02.png b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/squareBorderCurvedEmpty02.png new file mode 100644 index 0000000..57714a5 Binary files /dev/null and b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/squareBorderCurvedEmpty02.png differ diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/squareBorderCurvedEmpty02.png.meta b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/squareBorderCurvedEmpty02.png.meta new file mode 100644 index 0000000..b27178c --- /dev/null +++ b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/squareBorderCurvedEmpty02.png.meta @@ -0,0 +1,96 @@ +fileFormatVersion: 2 +guid: 7d504312fad10f040b95bd8836dc6fc6 +TextureImporter: + internalIDToNameTable: [] + externalObjects: {} + serializedVersion: 11 + mipmaps: + mipMapMode: 0 + enableMipMap: 1 + sRGBTexture: 1 + linearTexture: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + streamingMipmaps: 0 + streamingMipmapsPriority: 0 + vTOnly: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: -1 + maxTextureSize: 1024 + textureSettings: + serializedVersion: 2 + filterMode: 1 + aniso: 1 + mipBias: 0 + wrapU: 0 + wrapV: 0 + wrapW: 0 + nPOTScale: 1 + lightmap: 0 + compressionQuality: 50 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spritePixelsToUnits: 100 + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spriteGenerateFallbackPhysicsShape: 1 + alphaUsage: 1 + alphaIsTransparency: 0 + spriteTessellationDetail: -1 + textureType: 0 + textureShape: 1 + singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + platformSettings: + - serializedVersion: 3 + buildTarget: DefaultTexturePlatform + maxTextureSize: 1024 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + bones: [] + spriteID: + internalID: 0 + vertices: [] + indices: + edges: [] + weights: [] + secondaryTextures: [] + spritePackingTag: + pSDRemoveMatte: 0 + pSDShowRemoveMatteOption: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/squareBorderCurvedEmptyThick.png b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/squareBorderCurvedEmptyThick.png new file mode 100644 index 0000000..47b177f Binary files /dev/null and b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/squareBorderCurvedEmptyThick.png differ diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/squareBorderCurvedEmptyThick.png.meta b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/squareBorderCurvedEmptyThick.png.meta new file mode 100644 index 0000000..5331602 --- /dev/null +++ b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/squareBorderCurvedEmptyThick.png.meta @@ -0,0 +1,96 @@ +fileFormatVersion: 2 +guid: fc3b86627d5fe1c4d865b80627e2e37c +TextureImporter: + internalIDToNameTable: [] + externalObjects: {} + serializedVersion: 11 + mipmaps: + mipMapMode: 0 + enableMipMap: 0 + sRGBTexture: 1 + linearTexture: 1 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + streamingMipmaps: 0 + streamingMipmapsPriority: 0 + vTOnly: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: -3 + maxTextureSize: 32 + textureSettings: + serializedVersion: 2 + filterMode: 0 + aniso: 1 + mipBias: 0 + wrapU: 1 + wrapV: 1 + wrapW: 1 + nPOTScale: 0 + lightmap: 0 + compressionQuality: 100 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spritePixelsToUnits: 100 + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spriteGenerateFallbackPhysicsShape: 1 + alphaUsage: 1 + alphaIsTransparency: 1 + spriteTessellationDetail: -1 + textureType: 2 + textureShape: 1 + singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + platformSettings: + - serializedVersion: 3 + buildTarget: DefaultTexturePlatform + maxTextureSize: 32 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 0 + compressionQuality: 100 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + bones: [] + spriteID: + internalID: 0 + vertices: [] + indices: + edges: [] + weights: [] + secondaryTextures: [] + spritePackingTag: + pSDRemoveMatte: 0 + pSDShowRemoveMatteOption: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/squareBorderCurved_darkBorders.png b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/squareBorderCurved_darkBorders.png new file mode 100644 index 0000000..b9450f2 Binary files /dev/null and b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/squareBorderCurved_darkBorders.png differ diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/squareBorderCurved_darkBorders.png.meta b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/squareBorderCurved_darkBorders.png.meta new file mode 100644 index 0000000..a761d3b --- /dev/null +++ b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/squareBorderCurved_darkBorders.png.meta @@ -0,0 +1,96 @@ +fileFormatVersion: 2 +guid: 25da15ac84743244ab4c860cf8798ec8 +TextureImporter: + internalIDToNameTable: [] + externalObjects: {} + serializedVersion: 11 + mipmaps: + mipMapMode: 0 + enableMipMap: 1 + sRGBTexture: 1 + linearTexture: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + streamingMipmaps: 0 + streamingMipmapsPriority: 0 + vTOnly: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: -1 + maxTextureSize: 1024 + textureSettings: + serializedVersion: 2 + filterMode: 1 + aniso: 1 + mipBias: 0 + wrapU: 0 + wrapV: 0 + wrapW: 0 + nPOTScale: 1 + lightmap: 0 + compressionQuality: 50 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spritePixelsToUnits: 100 + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spriteGenerateFallbackPhysicsShape: 1 + alphaUsage: 1 + alphaIsTransparency: 0 + spriteTessellationDetail: -1 + textureType: 0 + textureShape: 1 + singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + platformSettings: + - serializedVersion: 3 + buildTarget: DefaultTexturePlatform + maxTextureSize: 1024 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + bones: [] + spriteID: + internalID: 0 + vertices: [] + indices: + edges: [] + weights: [] + secondaryTextures: [] + spritePackingTag: + pSDRemoveMatte: 0 + pSDShowRemoveMatteOption: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/squareBorderCurved_darkBordersAlpha.png b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/squareBorderCurved_darkBordersAlpha.png new file mode 100644 index 0000000..4ddd37a Binary files /dev/null and b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/squareBorderCurved_darkBordersAlpha.png differ diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/squareBorderCurved_darkBordersAlpha.png.meta b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/squareBorderCurved_darkBordersAlpha.png.meta new file mode 100644 index 0000000..1bac98b --- /dev/null +++ b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/squareBorderCurved_darkBordersAlpha.png.meta @@ -0,0 +1,96 @@ +fileFormatVersion: 2 +guid: f536c51d3da3f2e4ca93ac8773ec2ad8 +TextureImporter: + internalIDToNameTable: [] + externalObjects: {} + serializedVersion: 11 + mipmaps: + mipMapMode: 0 + enableMipMap: 1 + sRGBTexture: 1 + linearTexture: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + streamingMipmaps: 0 + streamingMipmapsPriority: 0 + vTOnly: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: -1 + maxTextureSize: 1024 + textureSettings: + serializedVersion: 2 + filterMode: 1 + aniso: 1 + mipBias: 0 + wrapU: 0 + wrapV: 0 + wrapW: 0 + nPOTScale: 1 + lightmap: 0 + compressionQuality: 50 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spritePixelsToUnits: 100 + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spriteGenerateFallbackPhysicsShape: 1 + alphaUsage: 1 + alphaIsTransparency: 0 + spriteTessellationDetail: -1 + textureType: 0 + textureShape: 1 + singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + platformSettings: + - serializedVersion: 3 + buildTarget: DefaultTexturePlatform + maxTextureSize: 1024 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + bones: [] + spriteID: + internalID: 0 + vertices: [] + indices: + edges: [] + weights: [] + secondaryTextures: [] + spritePackingTag: + pSDRemoveMatte: 0 + pSDShowRemoveMatteOption: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/squareBorderEmpty.png b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/squareBorderEmpty.png new file mode 100644 index 0000000..188ed94 Binary files /dev/null and b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/squareBorderEmpty.png differ diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/squareBorderEmpty.png.meta b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/squareBorderEmpty.png.meta new file mode 100644 index 0000000..cf1a744 --- /dev/null +++ b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/squareBorderEmpty.png.meta @@ -0,0 +1,96 @@ +fileFormatVersion: 2 +guid: 8db54efcce998554c86b796b37a7cdfa +TextureImporter: + internalIDToNameTable: [] + externalObjects: {} + serializedVersion: 11 + mipmaps: + mipMapMode: 0 + enableMipMap: 1 + sRGBTexture: 1 + linearTexture: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + streamingMipmaps: 0 + streamingMipmapsPriority: 0 + vTOnly: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: -1 + maxTextureSize: 1024 + textureSettings: + serializedVersion: 2 + filterMode: 1 + aniso: 1 + mipBias: 0 + wrapU: 0 + wrapV: 0 + wrapW: 0 + nPOTScale: 1 + lightmap: 0 + compressionQuality: 50 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spritePixelsToUnits: 100 + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spriteGenerateFallbackPhysicsShape: 1 + alphaUsage: 1 + alphaIsTransparency: 0 + spriteTessellationDetail: -1 + textureType: 0 + textureShape: 1 + singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + platformSettings: + - serializedVersion: 3 + buildTarget: DefaultTexturePlatform + maxTextureSize: 1024 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + bones: [] + spriteID: + internalID: 0 + vertices: [] + indices: + edges: [] + weights: [] + secondaryTextures: [] + spritePackingTag: + pSDRemoveMatte: 0 + pSDShowRemoveMatteOption: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/squareBorderEmpty01.png b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/squareBorderEmpty01.png new file mode 100644 index 0000000..188ed94 Binary files /dev/null and b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/squareBorderEmpty01.png differ diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/squareBorderEmpty01.png.meta b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/squareBorderEmpty01.png.meta new file mode 100644 index 0000000..2dc755f --- /dev/null +++ b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/squareBorderEmpty01.png.meta @@ -0,0 +1,96 @@ +fileFormatVersion: 2 +guid: aa8dc9238ab21e54ca88fa22698e4679 +TextureImporter: + internalIDToNameTable: [] + externalObjects: {} + serializedVersion: 11 + mipmaps: + mipMapMode: 0 + enableMipMap: 0 + sRGBTexture: 1 + linearTexture: 1 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + streamingMipmaps: 0 + streamingMipmapsPriority: 0 + vTOnly: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: -3 + maxTextureSize: 32 + textureSettings: + serializedVersion: 2 + filterMode: 0 + aniso: 1 + mipBias: 0 + wrapU: 1 + wrapV: 1 + wrapW: 1 + nPOTScale: 0 + lightmap: 0 + compressionQuality: 100 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spritePixelsToUnits: 100 + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spriteGenerateFallbackPhysicsShape: 1 + alphaUsage: 1 + alphaIsTransparency: 1 + spriteTessellationDetail: -1 + textureType: 2 + textureShape: 1 + singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + platformSettings: + - serializedVersion: 3 + buildTarget: DefaultTexturePlatform + maxTextureSize: 32 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 0 + compressionQuality: 100 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + bones: [] + spriteID: + internalID: 0 + vertices: [] + indices: + edges: [] + weights: [] + secondaryTextures: [] + spritePackingTag: + pSDRemoveMatte: 0 + pSDShowRemoveMatteOption: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/squareBorderEmpty02.png b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/squareBorderEmpty02.png new file mode 100644 index 0000000..ec9ead7 Binary files /dev/null and b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/squareBorderEmpty02.png differ diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/squareBorderEmpty02.png.meta b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/squareBorderEmpty02.png.meta new file mode 100644 index 0000000..3af32e8 --- /dev/null +++ b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/squareBorderEmpty02.png.meta @@ -0,0 +1,96 @@ +fileFormatVersion: 2 +guid: 29b0e8156f6fb774faf129c83bc9ee33 +TextureImporter: + internalIDToNameTable: [] + externalObjects: {} + serializedVersion: 11 + mipmaps: + mipMapMode: 0 + enableMipMap: 0 + sRGBTexture: 1 + linearTexture: 1 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + streamingMipmaps: 0 + streamingMipmapsPriority: 0 + vTOnly: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: -3 + maxTextureSize: 32 + textureSettings: + serializedVersion: 2 + filterMode: 0 + aniso: 1 + mipBias: 0 + wrapU: 1 + wrapV: 1 + wrapW: 1 + nPOTScale: 0 + lightmap: 0 + compressionQuality: 100 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spritePixelsToUnits: 100 + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spriteGenerateFallbackPhysicsShape: 1 + alphaUsage: 1 + alphaIsTransparency: 1 + spriteTessellationDetail: -1 + textureType: 2 + textureShape: 1 + singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + platformSettings: + - serializedVersion: 3 + buildTarget: DefaultTexturePlatform + maxTextureSize: 32 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 0 + compressionQuality: 100 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + bones: [] + spriteID: + internalID: 0 + vertices: [] + indices: + edges: [] + weights: [] + secondaryTextures: [] + spritePackingTag: + pSDRemoveMatte: 0 + pSDShowRemoveMatteOption: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/squareBorderEmpty03.png b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/squareBorderEmpty03.png new file mode 100644 index 0000000..ca376a8 Binary files /dev/null and b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/squareBorderEmpty03.png differ diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/squareBorderEmpty03.png.meta b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/squareBorderEmpty03.png.meta new file mode 100644 index 0000000..bebcf2f --- /dev/null +++ b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/squareBorderEmpty03.png.meta @@ -0,0 +1,96 @@ +fileFormatVersion: 2 +guid: c0a56b88a1b449045b3fe5f561aa12fa +TextureImporter: + internalIDToNameTable: [] + externalObjects: {} + serializedVersion: 11 + mipmaps: + mipMapMode: 0 + enableMipMap: 0 + sRGBTexture: 1 + linearTexture: 1 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + streamingMipmaps: 0 + streamingMipmapsPriority: 0 + vTOnly: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: -3 + maxTextureSize: 32 + textureSettings: + serializedVersion: 2 + filterMode: 0 + aniso: 1 + mipBias: 0 + wrapU: 1 + wrapV: 1 + wrapW: 1 + nPOTScale: 0 + lightmap: 0 + compressionQuality: 100 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spritePixelsToUnits: 100 + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spriteGenerateFallbackPhysicsShape: 1 + alphaUsage: 1 + alphaIsTransparency: 1 + spriteTessellationDetail: -1 + textureType: 2 + textureShape: 1 + singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + platformSettings: + - serializedVersion: 3 + buildTarget: DefaultTexturePlatform + maxTextureSize: 32 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 0 + compressionQuality: 100 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + bones: [] + spriteID: + internalID: 0 + vertices: [] + indices: + edges: [] + weights: [] + secondaryTextures: [] + spritePackingTag: + pSDRemoveMatte: 0 + pSDShowRemoveMatteOption: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/squareBorderThickEmpty.png b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/squareBorderThickEmpty.png new file mode 100644 index 0000000..ec9ead7 Binary files /dev/null and b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/squareBorderThickEmpty.png differ diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/squareBorderThickEmpty.png.meta b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/squareBorderThickEmpty.png.meta new file mode 100644 index 0000000..39d0970 --- /dev/null +++ b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/squareBorderThickEmpty.png.meta @@ -0,0 +1,96 @@ +fileFormatVersion: 2 +guid: c456d5ac01d2aa843a63985497b04931 +TextureImporter: + internalIDToNameTable: [] + externalObjects: {} + serializedVersion: 11 + mipmaps: + mipMapMode: 0 + enableMipMap: 1 + sRGBTexture: 1 + linearTexture: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + streamingMipmaps: 0 + streamingMipmapsPriority: 0 + vTOnly: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: -1 + maxTextureSize: 1024 + textureSettings: + serializedVersion: 2 + filterMode: 1 + aniso: 1 + mipBias: 0 + wrapU: 0 + wrapV: 0 + wrapW: 0 + nPOTScale: 1 + lightmap: 0 + compressionQuality: 50 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spritePixelsToUnits: 100 + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spriteGenerateFallbackPhysicsShape: 1 + alphaUsage: 1 + alphaIsTransparency: 0 + spriteTessellationDetail: -1 + textureType: 0 + textureShape: 1 + singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + platformSettings: + - serializedVersion: 3 + buildTarget: DefaultTexturePlatform + maxTextureSize: 1024 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + bones: [] + spriteID: + internalID: 0 + vertices: [] + indices: + edges: [] + weights: [] + secondaryTextures: [] + spritePackingTag: + pSDRemoveMatte: 0 + pSDShowRemoveMatteOption: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/squareBorderThickerEmpty.png b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/squareBorderThickerEmpty.png new file mode 100644 index 0000000..ca376a8 Binary files /dev/null and b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/squareBorderThickerEmpty.png differ diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/squareBorderThickerEmpty.png.meta b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/squareBorderThickerEmpty.png.meta new file mode 100644 index 0000000..2fc3a64 --- /dev/null +++ b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/squareBorderThickerEmpty.png.meta @@ -0,0 +1,96 @@ +fileFormatVersion: 2 +guid: 7acc6bd588627b046bc1c9b3cd78a6c7 +TextureImporter: + internalIDToNameTable: [] + externalObjects: {} + serializedVersion: 11 + mipmaps: + mipMapMode: 0 + enableMipMap: 1 + sRGBTexture: 1 + linearTexture: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + streamingMipmaps: 0 + streamingMipmapsPriority: 0 + vTOnly: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: -1 + maxTextureSize: 1024 + textureSettings: + serializedVersion: 2 + filterMode: 1 + aniso: 1 + mipBias: 0 + wrapU: 0 + wrapV: 0 + wrapW: 0 + nPOTScale: 1 + lightmap: 0 + compressionQuality: 50 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spritePixelsToUnits: 100 + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spriteGenerateFallbackPhysicsShape: 1 + alphaUsage: 1 + alphaIsTransparency: 0 + spriteTessellationDetail: -1 + textureType: 0 + textureShape: 1 + singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + platformSettings: + - serializedVersion: 3 + buildTarget: DefaultTexturePlatform + maxTextureSize: 1024 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + bones: [] + spriteID: + internalID: 0 + vertices: [] + indices: + edges: [] + weights: [] + secondaryTextures: [] + spritePackingTag: + pSDRemoveMatte: 0 + pSDShowRemoveMatteOption: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/squareCorners03.png b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/squareCorners03.png new file mode 100644 index 0000000..38dc1bb Binary files /dev/null and b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/squareCorners03.png differ diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/squareCorners03.png.meta b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/squareCorners03.png.meta new file mode 100644 index 0000000..589aaba --- /dev/null +++ b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/squareCorners03.png.meta @@ -0,0 +1,96 @@ +fileFormatVersion: 2 +guid: dec3ea647707588408ec0d11ab130b73 +TextureImporter: + internalIDToNameTable: [] + externalObjects: {} + serializedVersion: 11 + mipmaps: + mipMapMode: 0 + enableMipMap: 1 + sRGBTexture: 1 + linearTexture: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + streamingMipmaps: 0 + streamingMipmapsPriority: 0 + vTOnly: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: -1 + maxTextureSize: 1024 + textureSettings: + serializedVersion: 2 + filterMode: 1 + aniso: 1 + mipBias: 0 + wrapU: 0 + wrapV: 0 + wrapW: 0 + nPOTScale: 1 + lightmap: 0 + compressionQuality: 50 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spritePixelsToUnits: 100 + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spriteGenerateFallbackPhysicsShape: 1 + alphaUsage: 1 + alphaIsTransparency: 0 + spriteTessellationDetail: -1 + textureType: 0 + textureShape: 1 + singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + platformSettings: + - serializedVersion: 3 + buildTarget: DefaultTexturePlatform + maxTextureSize: 1024 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + bones: [] + spriteID: + internalID: 0 + vertices: [] + indices: + edges: [] + weights: [] + secondaryTextures: [] + spritePackingTag: + pSDRemoveMatte: 0 + pSDShowRemoveMatteOption: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/squareCornersEmpty02.png b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/squareCornersEmpty02.png new file mode 100644 index 0000000..facdba9 Binary files /dev/null and b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/squareCornersEmpty02.png differ diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/squareCornersEmpty02.png.meta b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/squareCornersEmpty02.png.meta new file mode 100644 index 0000000..9ffe1e3 --- /dev/null +++ b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/squareCornersEmpty02.png.meta @@ -0,0 +1,96 @@ +fileFormatVersion: 2 +guid: ca2f91cc405eb144dad970eb23db2f72 +TextureImporter: + internalIDToNameTable: [] + externalObjects: {} + serializedVersion: 11 + mipmaps: + mipMapMode: 0 + enableMipMap: 1 + sRGBTexture: 1 + linearTexture: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + streamingMipmaps: 0 + streamingMipmapsPriority: 0 + vTOnly: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: -1 + maxTextureSize: 1024 + textureSettings: + serializedVersion: 2 + filterMode: 1 + aniso: 1 + mipBias: 0 + wrapU: 0 + wrapV: 0 + wrapW: 0 + nPOTScale: 1 + lightmap: 0 + compressionQuality: 50 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spritePixelsToUnits: 100 + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spriteGenerateFallbackPhysicsShape: 1 + alphaUsage: 1 + alphaIsTransparency: 0 + spriteTessellationDetail: -1 + textureType: 0 + textureShape: 1 + singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + platformSettings: + - serializedVersion: 3 + buildTarget: DefaultTexturePlatform + maxTextureSize: 1024 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + bones: [] + spriteID: + internalID: 0 + vertices: [] + indices: + edges: [] + weights: [] + secondaryTextures: [] + spritePackingTag: + pSDRemoveMatte: 0 + pSDShowRemoveMatteOption: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/tileBars_empty.png b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/tileBars_empty.png new file mode 100644 index 0000000..8e17561 Binary files /dev/null and b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/tileBars_empty.png differ diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/tileBars_empty.png.meta b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/tileBars_empty.png.meta new file mode 100644 index 0000000..a345376 --- /dev/null +++ b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/tileBars_empty.png.meta @@ -0,0 +1,96 @@ +fileFormatVersion: 2 +guid: d1278357b25e10442b6ca6c24edc9781 +TextureImporter: + internalIDToNameTable: [] + externalObjects: {} + serializedVersion: 11 + mipmaps: + mipMapMode: 0 + enableMipMap: 1 + sRGBTexture: 1 + linearTexture: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + streamingMipmaps: 0 + streamingMipmapsPriority: 0 + vTOnly: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: -1 + maxTextureSize: 1024 + textureSettings: + serializedVersion: 2 + filterMode: 1 + aniso: 1 + mipBias: 0 + wrapU: 0 + wrapV: 0 + wrapW: 0 + nPOTScale: 1 + lightmap: 0 + compressionQuality: 50 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spritePixelsToUnits: 100 + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spriteGenerateFallbackPhysicsShape: 1 + alphaUsage: 1 + alphaIsTransparency: 0 + spriteTessellationDetail: -1 + textureType: 0 + textureShape: 1 + singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + platformSettings: + - serializedVersion: 3 + buildTarget: DefaultTexturePlatform + maxTextureSize: 1024 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + bones: [] + spriteID: + internalID: 0 + vertices: [] + indices: + edges: [] + weights: [] + secondaryTextures: [] + spritePackingTag: + pSDRemoveMatte: 0 + pSDShowRemoveMatteOption: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/tileBars_slanted.png b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/tileBars_slanted.png new file mode 100644 index 0000000..c8cfc7f Binary files /dev/null and b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/tileBars_slanted.png differ diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/tileBars_slanted.png.meta b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/tileBars_slanted.png.meta new file mode 100644 index 0000000..ac820c0 --- /dev/null +++ b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/tileBars_slanted.png.meta @@ -0,0 +1,96 @@ +fileFormatVersion: 2 +guid: c99a391f381fe534c80a193fe9f307a0 +TextureImporter: + internalIDToNameTable: [] + externalObjects: {} + serializedVersion: 11 + mipmaps: + mipMapMode: 0 + enableMipMap: 1 + sRGBTexture: 1 + linearTexture: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + streamingMipmaps: 0 + streamingMipmapsPriority: 0 + vTOnly: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: -1 + maxTextureSize: 1024 + textureSettings: + serializedVersion: 2 + filterMode: 1 + aniso: 1 + mipBias: 0 + wrapU: 0 + wrapV: 0 + wrapW: 0 + nPOTScale: 1 + lightmap: 0 + compressionQuality: 50 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spritePixelsToUnits: 100 + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spriteGenerateFallbackPhysicsShape: 1 + alphaUsage: 1 + alphaIsTransparency: 0 + spriteTessellationDetail: -1 + textureType: 0 + textureShape: 1 + singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + platformSettings: + - serializedVersion: 3 + buildTarget: DefaultTexturePlatform + maxTextureSize: 1024 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + bones: [] + spriteID: + internalID: 0 + vertices: [] + indices: + edges: [] + weights: [] + secondaryTextures: [] + spritePackingTag: + pSDRemoveMatte: 0 + pSDShowRemoveMatteOption: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/tileBars_slanted_alpha.png b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/tileBars_slanted_alpha.png new file mode 100644 index 0000000..7763091 Binary files /dev/null and b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/tileBars_slanted_alpha.png differ diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/tileBars_slanted_alpha.png.meta b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/tileBars_slanted_alpha.png.meta new file mode 100644 index 0000000..99b3a4d --- /dev/null +++ b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/tileBars_slanted_alpha.png.meta @@ -0,0 +1,96 @@ +fileFormatVersion: 2 +guid: 018a5623a46db1d49b1e6ff2482b07ab +TextureImporter: + internalIDToNameTable: [] + externalObjects: {} + serializedVersion: 11 + mipmaps: + mipMapMode: 0 + enableMipMap: 1 + sRGBTexture: 1 + linearTexture: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + streamingMipmaps: 0 + streamingMipmapsPriority: 0 + vTOnly: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: -1 + maxTextureSize: 1024 + textureSettings: + serializedVersion: 2 + filterMode: 1 + aniso: 1 + mipBias: 0 + wrapU: 0 + wrapV: 0 + wrapW: 0 + nPOTScale: 1 + lightmap: 0 + compressionQuality: 50 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spritePixelsToUnits: 100 + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spriteGenerateFallbackPhysicsShape: 1 + alphaUsage: 1 + alphaIsTransparency: 0 + spriteTessellationDetail: -1 + textureType: 0 + textureShape: 1 + singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + platformSettings: + - serializedVersion: 3 + buildTarget: DefaultTexturePlatform + maxTextureSize: 1024 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + bones: [] + spriteID: + internalID: 0 + vertices: [] + indices: + edges: [] + weights: [] + secondaryTextures: [] + spritePackingTag: + pSDRemoveMatte: 0 + pSDShowRemoveMatteOption: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/whiteDot.png b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/whiteDot.png new file mode 100644 index 0000000..768a2da Binary files /dev/null and b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/whiteDot.png differ diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/whiteDot.png.meta b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/whiteDot.png.meta new file mode 100644 index 0000000..75b1b0a --- /dev/null +++ b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/whiteDot.png.meta @@ -0,0 +1,96 @@ +fileFormatVersion: 2 +guid: ed7cb8f9a27664e48896c904189f0e2c +TextureImporter: + internalIDToNameTable: [] + externalObjects: {} + serializedVersion: 11 + mipmaps: + mipMapMode: 0 + enableMipMap: 1 + sRGBTexture: 1 + linearTexture: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + streamingMipmaps: 0 + streamingMipmapsPriority: 0 + vTOnly: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: -1 + maxTextureSize: 1024 + textureSettings: + serializedVersion: 2 + filterMode: 1 + aniso: 1 + mipBias: 0 + wrapU: 0 + wrapV: 0 + wrapW: 0 + nPOTScale: 1 + lightmap: 0 + compressionQuality: 50 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spritePixelsToUnits: 100 + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spriteGenerateFallbackPhysicsShape: 1 + alphaUsage: 1 + alphaIsTransparency: 0 + spriteTessellationDetail: -1 + textureType: 0 + textureShape: 1 + singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + platformSettings: + - serializedVersion: 3 + buildTarget: DefaultTexturePlatform + maxTextureSize: 1024 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + bones: [] + spriteID: + internalID: 0 + vertices: [] + indices: + edges: [] + weights: [] + secondaryTextures: [] + spritePackingTag: + pSDRemoveMatte: 0 + pSDShowRemoveMatteOption: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/whiteDot_darkBorder.png b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/whiteDot_darkBorder.png new file mode 100644 index 0000000..705c72b Binary files /dev/null and b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/whiteDot_darkBorder.png differ diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/whiteDot_darkBorder.png.meta b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/whiteDot_darkBorder.png.meta new file mode 100644 index 0000000..5f86d29 --- /dev/null +++ b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/whiteDot_darkBorder.png.meta @@ -0,0 +1,96 @@ +fileFormatVersion: 2 +guid: 27df4ca974a8eaf40803907859421506 +TextureImporter: + internalIDToNameTable: [] + externalObjects: {} + serializedVersion: 11 + mipmaps: + mipMapMode: 0 + enableMipMap: 1 + sRGBTexture: 1 + linearTexture: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + streamingMipmaps: 0 + streamingMipmapsPriority: 0 + vTOnly: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: -1 + maxTextureSize: 1024 + textureSettings: + serializedVersion: 2 + filterMode: 1 + aniso: 1 + mipBias: 0 + wrapU: 0 + wrapV: 0 + wrapW: 0 + nPOTScale: 1 + lightmap: 0 + compressionQuality: 50 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spritePixelsToUnits: 100 + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spriteGenerateFallbackPhysicsShape: 1 + alphaUsage: 1 + alphaIsTransparency: 0 + spriteTessellationDetail: -1 + textureType: 0 + textureShape: 1 + singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + platformSettings: + - serializedVersion: 3 + buildTarget: DefaultTexturePlatform + maxTextureSize: 1024 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + bones: [] + spriteID: + internalID: 0 + vertices: [] + indices: + edges: [] + weights: [] + secondaryTextures: [] + spritePackingTag: + pSDRemoveMatte: 0 + pSDShowRemoveMatteOption: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/whiteDot_whiteBorderAlpha.png b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/whiteDot_whiteBorderAlpha.png new file mode 100644 index 0000000..2a081f6 Binary files /dev/null and b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/whiteDot_whiteBorderAlpha.png differ diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/whiteDot_whiteBorderAlpha.png.meta b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/whiteDot_whiteBorderAlpha.png.meta new file mode 100644 index 0000000..2f46a5a --- /dev/null +++ b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/whiteDot_whiteBorderAlpha.png.meta @@ -0,0 +1,96 @@ +fileFormatVersion: 2 +guid: 039dc89c76661c344b7776f8a47cc5a4 +TextureImporter: + internalIDToNameTable: [] + externalObjects: {} + serializedVersion: 11 + mipmaps: + mipMapMode: 0 + enableMipMap: 1 + sRGBTexture: 1 + linearTexture: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + streamingMipmaps: 0 + streamingMipmapsPriority: 0 + vTOnly: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: -1 + maxTextureSize: 1024 + textureSettings: + serializedVersion: 2 + filterMode: 1 + aniso: 1 + mipBias: 0 + wrapU: 0 + wrapV: 0 + wrapW: 0 + nPOTScale: 1 + lightmap: 0 + compressionQuality: 50 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spritePixelsToUnits: 100 + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spriteGenerateFallbackPhysicsShape: 1 + alphaUsage: 1 + alphaIsTransparency: 0 + spriteTessellationDetail: -1 + textureType: 0 + textureShape: 1 + singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + platformSettings: + - serializedVersion: 3 + buildTarget: DefaultTexturePlatform + maxTextureSize: 1024 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + bones: [] + spriteID: + internalID: 0 + vertices: [] + indices: + edges: [] + weights: [] + secondaryTextures: [] + spritePackingTag: + pSDRemoveMatte: 0 + pSDShowRemoveMatteOption: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/whiteSquare.png b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/whiteSquare.png new file mode 100644 index 0000000..afc2459 Binary files /dev/null and b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/whiteSquare.png differ diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/whiteSquare.png.meta b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/whiteSquare.png.meta new file mode 100644 index 0000000..58bf6aa --- /dev/null +++ b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/whiteSquare.png.meta @@ -0,0 +1,96 @@ +fileFormatVersion: 2 +guid: dfe6e0ac3e5f24740a17e14b65e08406 +TextureImporter: + internalIDToNameTable: [] + externalObjects: {} + serializedVersion: 11 + mipmaps: + mipMapMode: 0 + enableMipMap: 0 + sRGBTexture: 1 + linearTexture: 1 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + streamingMipmaps: 0 + streamingMipmapsPriority: 0 + vTOnly: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: -3 + maxTextureSize: 32 + textureSettings: + serializedVersion: 2 + filterMode: 0 + aniso: 1 + mipBias: 0 + wrapU: 1 + wrapV: 1 + wrapW: 1 + nPOTScale: 0 + lightmap: 0 + compressionQuality: 100 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spritePixelsToUnits: 100 + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spriteGenerateFallbackPhysicsShape: 1 + alphaUsage: 1 + alphaIsTransparency: 1 + spriteTessellationDetail: -1 + textureType: 2 + textureShape: 1 + singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + platformSettings: + - serializedVersion: 3 + buildTarget: DefaultTexturePlatform + maxTextureSize: 32 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 0 + compressionQuality: 100 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + bones: [] + spriteID: + internalID: 0 + vertices: [] + indices: + edges: [] + weights: [] + secondaryTextures: [] + spritePackingTag: + pSDRemoveMatte: 0 + pSDShowRemoveMatteOption: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/whiteSquareAlpha10.png b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/whiteSquareAlpha10.png new file mode 100644 index 0000000..6480ee2 Binary files /dev/null and b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/whiteSquareAlpha10.png differ diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/whiteSquareAlpha10.png.meta b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/whiteSquareAlpha10.png.meta new file mode 100644 index 0000000..708cb1f --- /dev/null +++ b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/whiteSquareAlpha10.png.meta @@ -0,0 +1,96 @@ +fileFormatVersion: 2 +guid: 93b68213089b05943a651574eb7e2fb5 +TextureImporter: + internalIDToNameTable: [] + externalObjects: {} + serializedVersion: 11 + mipmaps: + mipMapMode: 0 + enableMipMap: 0 + sRGBTexture: 1 + linearTexture: 1 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + streamingMipmaps: 0 + streamingMipmapsPriority: 0 + vTOnly: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: -3 + maxTextureSize: 32 + textureSettings: + serializedVersion: 2 + filterMode: 0 + aniso: 1 + mipBias: 0 + wrapU: 1 + wrapV: 1 + wrapW: 1 + nPOTScale: 0 + lightmap: 0 + compressionQuality: 100 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spritePixelsToUnits: 100 + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spriteGenerateFallbackPhysicsShape: 1 + alphaUsage: 1 + alphaIsTransparency: 1 + spriteTessellationDetail: -1 + textureType: 2 + textureShape: 1 + singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + platformSettings: + - serializedVersion: 3 + buildTarget: DefaultTexturePlatform + maxTextureSize: 32 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 0 + compressionQuality: 100 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + bones: [] + spriteID: + internalID: 0 + vertices: [] + indices: + edges: [] + weights: [] + secondaryTextures: [] + spritePackingTag: + pSDRemoveMatte: 0 + pSDShowRemoveMatteOption: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/whiteSquareAlpha15.png b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/whiteSquareAlpha15.png new file mode 100644 index 0000000..e6f3c42 Binary files /dev/null and b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/whiteSquareAlpha15.png differ diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/whiteSquareAlpha15.png.meta b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/whiteSquareAlpha15.png.meta new file mode 100644 index 0000000..9dfa686 --- /dev/null +++ b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/whiteSquareAlpha15.png.meta @@ -0,0 +1,96 @@ +fileFormatVersion: 2 +guid: 5510cdd48a6aaaa439c95ef5b2fe9e28 +TextureImporter: + internalIDToNameTable: [] + externalObjects: {} + serializedVersion: 11 + mipmaps: + mipMapMode: 0 + enableMipMap: 1 + sRGBTexture: 1 + linearTexture: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + streamingMipmaps: 0 + streamingMipmapsPriority: 0 + vTOnly: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: -1 + maxTextureSize: 1024 + textureSettings: + serializedVersion: 2 + filterMode: 1 + aniso: 1 + mipBias: 0 + wrapU: 0 + wrapV: 0 + wrapW: 0 + nPOTScale: 1 + lightmap: 0 + compressionQuality: 50 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spritePixelsToUnits: 100 + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spriteGenerateFallbackPhysicsShape: 1 + alphaUsage: 1 + alphaIsTransparency: 0 + spriteTessellationDetail: -1 + textureType: 0 + textureShape: 1 + singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + platformSettings: + - serializedVersion: 3 + buildTarget: DefaultTexturePlatform + maxTextureSize: 1024 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + bones: [] + spriteID: + internalID: 0 + vertices: [] + indices: + edges: [] + weights: [] + secondaryTextures: [] + spritePackingTag: + pSDRemoveMatte: 0 + pSDShowRemoveMatteOption: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/whiteSquareAlpha25.png b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/whiteSquareAlpha25.png new file mode 100644 index 0000000..5219f2a Binary files /dev/null and b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/whiteSquareAlpha25.png differ diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/whiteSquareAlpha25.png.meta b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/whiteSquareAlpha25.png.meta new file mode 100644 index 0000000..5f8cb8b --- /dev/null +++ b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/whiteSquareAlpha25.png.meta @@ -0,0 +1,96 @@ +fileFormatVersion: 2 +guid: 511f6b24c50557a40a09633b12b8b8ef +TextureImporter: + internalIDToNameTable: [] + externalObjects: {} + serializedVersion: 11 + mipmaps: + mipMapMode: 0 + enableMipMap: 0 + sRGBTexture: 1 + linearTexture: 1 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + streamingMipmaps: 0 + streamingMipmapsPriority: 0 + vTOnly: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: -3 + maxTextureSize: 32 + textureSettings: + serializedVersion: 2 + filterMode: 0 + aniso: 1 + mipBias: 0 + wrapU: 1 + wrapV: 1 + wrapW: 1 + nPOTScale: 0 + lightmap: 0 + compressionQuality: 100 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spritePixelsToUnits: 100 + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spriteGenerateFallbackPhysicsShape: 1 + alphaUsage: 1 + alphaIsTransparency: 1 + spriteTessellationDetail: -1 + textureType: 2 + textureShape: 1 + singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + platformSettings: + - serializedVersion: 3 + buildTarget: DefaultTexturePlatform + maxTextureSize: 32 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 0 + compressionQuality: 100 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + bones: [] + spriteID: + internalID: 0 + vertices: [] + indices: + edges: [] + weights: [] + secondaryTextures: [] + spritePackingTag: + pSDRemoveMatte: 0 + pSDShowRemoveMatteOption: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/whiteSquareAlpha50.png b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/whiteSquareAlpha50.png new file mode 100644 index 0000000..ad90433 Binary files /dev/null and b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/whiteSquareAlpha50.png differ diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/whiteSquareAlpha50.png.meta b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/whiteSquareAlpha50.png.meta new file mode 100644 index 0000000..15c1a15 --- /dev/null +++ b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/whiteSquareAlpha50.png.meta @@ -0,0 +1,96 @@ +fileFormatVersion: 2 +guid: ef40b00a83f7bd34f84851386b3321f0 +TextureImporter: + internalIDToNameTable: [] + externalObjects: {} + serializedVersion: 11 + mipmaps: + mipMapMode: 0 + enableMipMap: 1 + sRGBTexture: 1 + linearTexture: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + streamingMipmaps: 0 + streamingMipmapsPriority: 0 + vTOnly: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: -1 + maxTextureSize: 1024 + textureSettings: + serializedVersion: 2 + filterMode: 1 + aniso: 1 + mipBias: 0 + wrapU: 0 + wrapV: 0 + wrapW: 0 + nPOTScale: 1 + lightmap: 0 + compressionQuality: 50 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spritePixelsToUnits: 100 + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spriteGenerateFallbackPhysicsShape: 1 + alphaUsage: 1 + alphaIsTransparency: 0 + spriteTessellationDetail: -1 + textureType: 0 + textureShape: 1 + singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + platformSettings: + - serializedVersion: 3 + buildTarget: DefaultTexturePlatform + maxTextureSize: 1024 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + bones: [] + spriteID: + internalID: 0 + vertices: [] + indices: + edges: [] + weights: [] + secondaryTextures: [] + spritePackingTag: + pSDRemoveMatte: 0 + pSDShowRemoveMatteOption: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/whiteSquareAlpha80.png b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/whiteSquareAlpha80.png new file mode 100644 index 0000000..def9ea9 Binary files /dev/null and b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/whiteSquareAlpha80.png differ diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/whiteSquareAlpha80.png.meta b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/whiteSquareAlpha80.png.meta new file mode 100644 index 0000000..1b1c585 --- /dev/null +++ b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/whiteSquareAlpha80.png.meta @@ -0,0 +1,96 @@ +fileFormatVersion: 2 +guid: 11848dd30e516d846a02cd302634d317 +TextureImporter: + internalIDToNameTable: [] + externalObjects: {} + serializedVersion: 11 + mipmaps: + mipMapMode: 0 + enableMipMap: 1 + sRGBTexture: 1 + linearTexture: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + streamingMipmaps: 0 + streamingMipmapsPriority: 0 + vTOnly: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: -1 + maxTextureSize: 1024 + textureSettings: + serializedVersion: 2 + filterMode: 1 + aniso: 1 + mipBias: 0 + wrapU: 0 + wrapV: 0 + wrapW: 0 + nPOTScale: 1 + lightmap: 0 + compressionQuality: 50 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spritePixelsToUnits: 100 + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spriteGenerateFallbackPhysicsShape: 1 + alphaUsage: 1 + alphaIsTransparency: 0 + spriteTessellationDetail: -1 + textureType: 0 + textureShape: 1 + singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + platformSettings: + - serializedVersion: 3 + buildTarget: DefaultTexturePlatform + maxTextureSize: 1024 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + bones: [] + spriteID: + internalID: 0 + vertices: [] + indices: + edges: [] + weights: [] + secondaryTextures: [] + spritePackingTag: + pSDRemoveMatte: 0 + pSDShowRemoveMatteOption: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/whiteSquare_fadeOut_bt.png b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/whiteSquare_fadeOut_bt.png new file mode 100644 index 0000000..0f754e5 Binary files /dev/null and b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/whiteSquare_fadeOut_bt.png differ diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/whiteSquare_fadeOut_bt.png.meta b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/whiteSquare_fadeOut_bt.png.meta new file mode 100644 index 0000000..a9988cc --- /dev/null +++ b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/whiteSquare_fadeOut_bt.png.meta @@ -0,0 +1,96 @@ +fileFormatVersion: 2 +guid: a40dc0d6372a9084fb45976308087290 +TextureImporter: + internalIDToNameTable: [] + externalObjects: {} + serializedVersion: 11 + mipmaps: + mipMapMode: 0 + enableMipMap: 1 + sRGBTexture: 1 + linearTexture: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + streamingMipmaps: 0 + streamingMipmapsPriority: 0 + vTOnly: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: -1 + maxTextureSize: 1024 + textureSettings: + serializedVersion: 2 + filterMode: 1 + aniso: 1 + mipBias: 0 + wrapU: 0 + wrapV: 0 + wrapW: 0 + nPOTScale: 1 + lightmap: 0 + compressionQuality: 50 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spritePixelsToUnits: 100 + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spriteGenerateFallbackPhysicsShape: 1 + alphaUsage: 1 + alphaIsTransparency: 0 + spriteTessellationDetail: -1 + textureType: 0 + textureShape: 1 + singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + platformSettings: + - serializedVersion: 3 + buildTarget: DefaultTexturePlatform + maxTextureSize: 1024 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + bones: [] + spriteID: + internalID: 0 + vertices: [] + indices: + edges: [] + weights: [] + secondaryTextures: [] + spritePackingTag: + pSDRemoveMatte: 0 + pSDShowRemoveMatteOption: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/yellowSquare.png b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/yellowSquare.png new file mode 100644 index 0000000..c41f635 Binary files /dev/null and b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/yellowSquare.png differ diff --git a/Assets/Demigiant/DemiLib/Core/Editor/Imgs/yellowSquare.png.meta b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/yellowSquare.png.meta new file mode 100644 index 0000000..f55f89e --- /dev/null +++ b/Assets/Demigiant/DemiLib/Core/Editor/Imgs/yellowSquare.png.meta @@ -0,0 +1,96 @@ +fileFormatVersion: 2 +guid: 517a5bfe18f2ee04d9925db10be034e2 +TextureImporter: + internalIDToNameTable: [] + externalObjects: {} + serializedVersion: 11 + mipmaps: + mipMapMode: 0 + enableMipMap: 1 + sRGBTexture: 1 + linearTexture: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + streamingMipmaps: 0 + streamingMipmapsPriority: 0 + vTOnly: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: -1 + maxTextureSize: 1024 + textureSettings: + serializedVersion: 2 + filterMode: 1 + aniso: 1 + mipBias: 0 + wrapU: 0 + wrapV: 0 + wrapW: 0 + nPOTScale: 1 + lightmap: 0 + compressionQuality: 50 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spritePixelsToUnits: 100 + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spriteGenerateFallbackPhysicsShape: 1 + alphaUsage: 1 + alphaIsTransparency: 0 + spriteTessellationDetail: -1 + textureType: 0 + textureShape: 1 + singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + platformSettings: + - serializedVersion: 3 + buildTarget: DefaultTexturePlatform + maxTextureSize: 1024 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + bones: [] + spriteID: + internalID: 0 + vertices: [] + indices: + edges: [] + weights: [] + secondaryTextures: [] + spritePackingTag: + pSDRemoveMatte: 0 + pSDShowRemoveMatteOption: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Demigiant/readme_DOTweenPro.txt b/Assets/Demigiant/readme_DOTweenPro.txt new file mode 100644 index 0000000..9837c95 --- /dev/null +++ b/Assets/Demigiant/readme_DOTweenPro.txt @@ -0,0 +1,35 @@ +DOTween and DOTween Pro are copyright (c) 2014-2018 Daniele Giardini - Demigiant + +// IMPORTANT!!! ///////////////////////////////////////////// +// Upgrading DOTween from versions older than 1.2.000 /////// +// (or DOTween Pro older than 1.0.000) ////////////////////// +------------------------------------------------------------- +If you're upgrading your project from a version of DOTween older than 1.2.000 (or DOTween Pro older than 1.0.000) please follow these instructions carefully. +1) Import the new version in the same folder as the previous one, overwriting old files. A lot of errors will appear but don't worry +2) Close and reopen Unity (and your project). This is fundamental: skipping this step will cause a bloodbath +3) Open DOTween's Utility Panel (Tools > Demigiant > DOTween Utility Panel) if it doesn't open automatically, then press "Setup DOTween...": this will run the upgrade setup +4) From the Add/Remove Modules panel that opens, activate/deactivate Modules for Unity systems and for external assets (like TextMesh Pro) + +// GET STARTED ////////////////////////////////////////////// + +- After importing a new DOTween update, select DOTween's Utility Panel from the "Tools/Demigiant" menu (if it doesn't open automatically) and press the "Setup DOTween..." button to activate/deactivate Modules. You can also access a Preferences Tab from there to choose default settings for DOTween. + +// VISUAL SCRIPTING (PRO ONLY) +- To animate a gameObject, select it and choose "Add Component > DOTween > DOTween Animation" +- To animate a gameObject along a path, select it and choose "Add Component > DOTween > DOTween Path" + +// SCRIPTING +- In your code, add "using DG.Tweening" to each class where you want to use DOTween. +- You're ready to tween. Check out the links below for full documentation and license info. + + +// LINKS /////////////////////////////////////////////////////// + +DOTween website (documentation, examples, etc): http://dotween.demigiant.com +DOTween license: http://dotween.demigiant.com/license.php +DOTween repository (Google Code): https://code.google.com/p/dotween/ +Demigiant website (documentation, examples, etc): http://www.demigiant.com + +// NOTES ////////////////////////////////////////////////////// + +- DOTween's Utility Panel can be found under "Tools > Demigiant > DOTween Utility Panel" and also contains other useful options, plus a tab to set DOTween's preferences \ No newline at end of file diff --git a/Assets/Demigiant/readme_DOTweenPro.txt.meta b/Assets/Demigiant/readme_DOTweenPro.txt.meta new file mode 100644 index 0000000..2498034 --- /dev/null +++ b/Assets/Demigiant/readme_DOTweenPro.txt.meta @@ -0,0 +1,22 @@ +fileFormatVersion: 2 +guid: 24123b2fcdc15c943bed44e0c6beeec7 +labels: +- Tween +- Tweening +- Animation +- HOTween +- Paths +- VisualScripting +- VisualEditor +- iTween +- LeanTween +- DFTween +- Ease +- Easing +- Shake +- Punch +TextScriptImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus.meta b/Assets/Fungus.meta new file mode 100644 index 0000000..163520c --- /dev/null +++ b/Assets/Fungus.meta @@ -0,0 +1,5 @@ +fileFormatVersion: 2 +guid: 120b23b5240c94aee960b7434706811c +folderAsset: yes +DefaultImporter: + userData: diff --git a/Assets/Fungus/Audio.meta b/Assets/Fungus/Audio.meta new file mode 100644 index 0000000..ebac8dc --- /dev/null +++ b/Assets/Fungus/Audio.meta @@ -0,0 +1,5 @@ +fileFormatVersion: 2 +guid: 50aeb1f91c7cf484e85d48c7370e926f +folderAsset: yes +DefaultImporter: + userData: diff --git a/Assets/Fungus/Audio/Click.wav b/Assets/Fungus/Audio/Click.wav new file mode 100644 index 0000000..c20f06b Binary files /dev/null and b/Assets/Fungus/Audio/Click.wav differ diff --git a/Assets/Fungus/Audio/Click.wav.meta b/Assets/Fungus/Audio/Click.wav.meta new file mode 100644 index 0000000..c8b9390 --- /dev/null +++ b/Assets/Fungus/Audio/Click.wav.meta @@ -0,0 +1,12 @@ +fileFormatVersion: 2 +guid: c18ae2c530c264a6880266d5e0a71337 +AudioImporter: + serializedVersion: 4 + format: -1 + quality: -.280000001 + stream: 1 + 3D: 0 + forceToMono: 0 + useHardware: 0 + loopable: 0 + userData: diff --git a/Assets/Fungus/Audio/Click2.wav b/Assets/Fungus/Audio/Click2.wav new file mode 100644 index 0000000..4c5761c Binary files /dev/null and b/Assets/Fungus/Audio/Click2.wav differ diff --git a/Assets/Fungus/Audio/Click2.wav.meta b/Assets/Fungus/Audio/Click2.wav.meta new file mode 100644 index 0000000..64a8f96 --- /dev/null +++ b/Assets/Fungus/Audio/Click2.wav.meta @@ -0,0 +1,22 @@ +fileFormatVersion: 2 +guid: 14a396b1562834718b2d52b9c4639264 +timeCreated: 1440511211 +licenseType: Store +AudioImporter: + serializedVersion: 6 + defaultSettings: + loadType: 1 + sampleRateSetting: 0 + sampleRateOverride: 0 + compressionFormat: 0 + quality: .5 + conversionMode: 0 + platformSettingOverrides: {} + forceToMono: 0 + normalize: 1 + preloadAudioData: 1 + loadInBackground: 0 + 3D: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Audio/HighVoice.wav b/Assets/Fungus/Audio/HighVoice.wav new file mode 100644 index 0000000..a1ee752 Binary files /dev/null and b/Assets/Fungus/Audio/HighVoice.wav differ diff --git a/Assets/Fungus/Audio/HighVoice.wav.meta b/Assets/Fungus/Audio/HighVoice.wav.meta new file mode 100644 index 0000000..cce040f --- /dev/null +++ b/Assets/Fungus/Audio/HighVoice.wav.meta @@ -0,0 +1,22 @@ +fileFormatVersion: 2 +guid: 774486030b696474e8b3cf7f178123da +timeCreated: 1440509679 +licenseType: Store +AudioImporter: + serializedVersion: 6 + defaultSettings: + loadType: 1 + sampleRateSetting: 0 + sampleRateOverride: 0 + compressionFormat: 0 + quality: .5 + conversionMode: 0 + platformSettingOverrides: {} + forceToMono: 0 + normalize: 1 + preloadAudioData: 1 + loadInBackground: 0 + 3D: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Audio/LowVoice.wav b/Assets/Fungus/Audio/LowVoice.wav new file mode 100644 index 0000000..63293ed Binary files /dev/null and b/Assets/Fungus/Audio/LowVoice.wav differ diff --git a/Assets/Fungus/Audio/LowVoice.wav.meta b/Assets/Fungus/Audio/LowVoice.wav.meta new file mode 100644 index 0000000..0a680f0 --- /dev/null +++ b/Assets/Fungus/Audio/LowVoice.wav.meta @@ -0,0 +1,22 @@ +fileFormatVersion: 2 +guid: c53b7c20372e444c6bd7f2ac0729bbe2 +timeCreated: 1440509678 +licenseType: Store +AudioImporter: + serializedVersion: 6 + defaultSettings: + loadType: 1 + sampleRateSetting: 0 + sampleRateOverride: 0 + compressionFormat: 0 + quality: .5 + conversionMode: 0 + platformSettingOverrides: {} + forceToMono: 0 + normalize: 1 + preloadAudioData: 1 + loadInBackground: 0 + 3D: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Audio/MidVoice.wav b/Assets/Fungus/Audio/MidVoice.wav new file mode 100644 index 0000000..fe6e9a4 Binary files /dev/null and b/Assets/Fungus/Audio/MidVoice.wav differ diff --git a/Assets/Fungus/Audio/MidVoice.wav.meta b/Assets/Fungus/Audio/MidVoice.wav.meta new file mode 100644 index 0000000..4a22ebe --- /dev/null +++ b/Assets/Fungus/Audio/MidVoice.wav.meta @@ -0,0 +1,12 @@ +fileFormatVersion: 2 +guid: f637c5ce9d10e45c7855ed89bfc6b97e +AudioImporter: + serializedVersion: 4 + format: -1 + quality: .5 + stream: 1 + 3D: 0 + forceToMono: 0 + useHardware: 0 + loopable: 0 + userData: diff --git a/Assets/Fungus/Docs.meta b/Assets/Fungus/Docs.meta new file mode 100644 index 0000000..cb9b541 --- /dev/null +++ b/Assets/Fungus/Docs.meta @@ -0,0 +1,9 @@ +fileFormatVersion: 2 +guid: 5441286d76a2f47c7a2ea683709ea59e +folderAsset: yes +timeCreated: 1473781211 +licenseType: Store +DefaultImporter: + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Docs/CHANGELOG.txt b/Assets/Fungus/Docs/CHANGELOG.txt new file mode 100644 index 0000000..070e2b0 --- /dev/null +++ b/Assets/Fungus/Docs/CHANGELOG.txt @@ -0,0 +1,962 @@ +Changelog {#changelog} +========= + +Unreleased +====== + + +v3.13.4 +====== + +## Fixed + + - Set actions on Property commands targeting structs now save changes. Previously the target variable was not being copied back to the internal struct, causing changes to be discarded. Impacts the following Property Commands, Color, Matrix, Quaternion, Vector2, Vector3, Vector4. + - Writer with 0 speed and TMPro text correctly writes at infinite speed, previously was infinite loop. + - Collection Contains* commands now actually show the field to store boolean result. + - Writer with TMPro text now correctly calls NotifyGlyph and less susceptible to nested rich text tag confusion. + +## Changed + + - Conversation System finding character by name now uses an exact match with fallback to previous StartsWith. Thanks to hsandt. + - Flowchart Window labels no longer forced white, to better accomidate dark theme as of Unity 2019.4.8 + + +v3.13.3 +====== + +## Fixed + + - View Gizmo Drawer specifies type of View, no longer tries to run for every object in scene. + - TMProLinkAnim dictionary errors caused by duplicate entries when Domain Reload is disabled, Thanks to yano. + - Divide Equal now uses Unicode characters in place of ASCII slash in menus, so it shows correctly. + +v3.13.2 +====== + +## Fixed + +- Restore string VariableSubstitution in use of AnyVariableDataPair, found in SetVariable and VariableCondition (#841) +- Float variable comparison, typo causing comparison to self instead of rhs(#836) + +v3.13.1 +====== + +## Fixed + +- Build error in JsonChecker caused by missing asmdef in newer Unity versions. (#833) + +v3.13.0 +====== + +## Added + +- Conditional Commands now support multiple comparisons as a chain of && or ||. Thanks to preda2or, and AcademyOfF +- IWriterListener OnAllWorldsWritten fires when there are no words left to be written but writer may still have pending waits +- Entry based NarrativeLog alternate. Thanks to cg-tespy +- Option to grid snap blocks in the FlowchartWindow. +- TMPro Text animation via link text. +- Fungus Collection, varaibles, default types, and commands. +- Github Issue and PR templates. + +## Fixed + +- Portrait image shown as white when cycled through rapidly. +- Flowchart Window Search box steals focus +- Mushroom icon placement incorrect on some versions of Unity. Thanks to TonyJeffree +- Text and Background colour readability across Unity Versions and Pro skin. Thanks to DesperateHouseDev +- VariableData indents incorrect. +- Fix reshow of hidden portrait in Conversation. Thanks to jusw85 +- FlowchartWindow search pop not showing on newer Unity versions. +- VS Solution file fix for Unity 2019.3.12 +- Inspector DeleteSave button now deletes now more aware of target platform. +- Fungus VariableData single and mutliline variable drawing in more recent Unity versions. +- Possible null ref in Conversation editor during variable match check +- Block connections not drawing if origin block is not drawn. + +## Changed + +- Portraits are now all cached when requested under their own gameobjects and toggle active. +- Fungus Docs moved to github wiki +- JSONObject lib updated to newer version. Thanks to qrostar. +- CameraManager and View now use Tween types. +- Dragable EventHandlers now support an array of target dragables. Thanks to SarveshBajaj +- Flowchart GetVariables by type. Thanks to cg-tespy +- A null FungusVariables will now report their string value as Null instead of an empty string. +- Develop updated to Unity 2019.3.13 +- Demo scenes rebuilt in minimum supported Unity version. +- Block selector now orders blocks by name. +- Block search now supports partial matches. +- Update to c#4 +- Updates to Contributing, Code of Conduct. +- Menu command has a button to add a block for it to target. +- Character selector now sorts names. +- Portrait selector now sorts names. +- Update header license +- Writer uses InvariantCulture when parsing floats to avoid unexpected behaviour under changing system cultures. + +v3.12.0 +====== + +## Added + +- Search should search commands, not just block names (#775). Thanks to AcademyOfF +- Debug additions (#777) righclicking context menus additions and improvements on commands, blocks, and variables +- BlockCallers can be seen within the block inspector +- Variable referencers can be seen logged to the console +- Added a custom script importer for lua files. Thanks to Matthew Barnes +- Added Asmdefs +- Fungus Editor Prefs button to locate FungusEditorResources and changelog + +## Fixed + +- Defines and fallbacks for 2017 and 2018 (#781) +- CommandListAdapter sync command selection bidirectionally with selection in underlying reorderablelist +- Command text with 'Error:' shows red +- HighSpeedWriterFix; corrected rate of characters and more than 1 character per frame issue. +- FilterBlocks during SceneChange, now refresh as expected +- Command and Variables outside of Fungus assembly now locate +- Character selection preventing edits bug +- Restore Edit Mode Tests + +## Changed + +- FungusManager.cs Use "double checked locking" algorithm to implement the singleton for "FungusManager" class, which can improve performance. Thanks to AndyHan1001 +- CommandSearchHeightFallback on some versions of Unity editor inspector height is not returning correctly so we make an educated guess if it seems unreliable +- More elaborated use of text in TMPro demo +- Block Inspector forces type at creation. Thanks to Michaelwolf95 +- Warning when requesting menu elements that are not avaialble, such as more menu items that you have created. +- Fungus Docs can now generate in github markdown format + + +v3.11.5 {#v3.11.5} +====== + +## Fixed + +- Mushroom icon for the inspector moved in 2019 as to not overlap the new visibility toggle Unity has added. #745 +- FlowchartWindow MutliSelect now more strictly manages selectedness #744 +- Portrait sprite issue in Unity 2019 #743 + +## Changed + +- Experimental Searchable menus are now enabled by default #746 + +v3.11.4 {#v3.11.4} +====== + +## Changed + +- Updated project to Unity 2019.1.0f2 +- Updated to .NET 4.x +- Updated reference docs + +v3.11.3 {#v3.11.3} +====== + +## Fixed + +- Additional null checks around Flowchart.selectedBlocks and Flowchart.selectedCommands. + +v3.11.2 {#v3.11.2} +====== + +## Fixed + +- Static list caching in editor. + +## Changed + +- Spacing in debug output related to Block find and execute warnings and failures. + +v3.11.1 {#v3.11.1} +====== + +## Fixed + +- Compile error in Unity 2018.3.6f1 + +v3.11.0 {#v3.11.0} +====== + +## Added + +- SetSprite: changes the image on the SpriteRenderer of one or more GameObjects +- SetUIImage: changes the image on the Image of one or more GameObjects (Joerg Burbach) +- Commands to store FungusVariable.ToString into a StringVariable and to parse a string into an Int or Float FungusVariable + +## Fixed + +- #729 VariableEditor popup name and key concat no longer has spaces, allows the PopUp to correctly nest items with the same parent +- #732 BlockInspector correct top panel height in 2018_3 BlockEditor only force unique name if it has changed +- BlockInspector and BlockEditor changes to display correctly in 2019.1.0a13 + +## Changed + +- #728 FlowchartWindow performance for 100s of blocks +- #727 Support use of TMPro in Set Text, Get Text and Narrative Log Menu commands +- #733 Command can now cache a list of referenced variables that are checked by the variablelistadapter for highlighting +- Flowchart can identify add variables found via the substitute regex +- Commands that use SubstituteVariables on their string data use the new caching method so they can highlight variables that will be used during substitution +- #733 HasReference added to many commands that lacked them or had only partially checked vars + +v3.10.0 {#v3_10_0} +====== + +## Added +- #725 Added Stop Then Call mode in Call command. Stops the calling Block immediately, instead of waiting a frame. +- #718 Say and Menu dialogs now support TextMeshPro directly + - TextMeshPro demo scene - A default say dialog but with TextMeshPro Text UI elements in place of uGUI Text + - A default menu dialog but with TextMeshPro Text UI elements in place of uGUI Text + - TextAdapter can be asked to include children in text output search MenuDialogue now uses TextAdapter rather than assuming UI.Text +- #720 Variable reference allows for selecting a flowchart a targeting a specific fungus variable for use from c# +- #705 Added FirstPersonDemo examples +- New audio commands: Play Ambience Sound, Stop Ambience Sound, Play Random sound. + +## Fixed +- #717 Control Audio > Play Loop volume is always 1 +- #723 Unity 2018.3 Warnings +- #711 Beeps in WriterAudio ignores last sound in array +- PLay Sound Effect volume is now independent of Set Music Volume setting +- Correct width calc on smaller width inspectors +- #708 Specifically identify choice blocks as hexagons in documentation + +## Changed +- #721 Conversation text can now contain colons within the text body itself +- #719 Change FlowchartMenuItem.SpawnPrefab to GameObject.Inst rather than PrefabUtil to avoid exception modifications.empty +- #709 Command searchable pop up + - Added Fungus Preferences setting to enable Searchable PopupMenus +- #694 Adding Random Sound Command and Ambiance Sounds - thanks to Hector Castelli +- #704 Replaced Rotorz Reorderable List with Unity's InternalReorderable list +- ExceuteOnEvent dropdown is searchable -can double click to circumvent the search drop down -can remove event by setting None -use search similar to add command method + +Changelog {#changelog} +========= +[TOC] + +v3.9.1 {#v3_9_1} +====== + +## Added +- Text Variation Handler: Adds Ink-style text variation in Say, Menu and Conversation commands. #695 + +## Fixed +- Fixed Reorderable List control errors in 2018.2. Compatible with 2017.4, 2018.1 2018.2 #697 + +v3.9.0 {#v3_9_0} +====== + +## Added +- Conversation command supports setting default clear, wait for input and fade options #673 +- Added Fungus Priority Signals #671 #670 + - allows fungus to notify the outside world that it is doing something of priority so the outside world can pause +- Added GetKey fungus command. #683 + - Supports positive and negative keybindings output to a bool, float or int variable + - Supports checking for pressed, release and current state + - Uses keycode with optional fallback to key name +- Disabled Flowcharts and EventHandlers. #682 +- Added Dialog history on Save Menu UI #675 +- Added BlockReference, a simple data type with a property drawer that makes it easier to select a target fungus block from external c# scripts. #669 +- Added comparison (equals and not equals) as well as assign functionality to most variable types. #668 + +## Changed +- Updated to Unity 2018.1 #681 +- Conversation Manager Regex now allows - and _ within say params group. #692 +- Conversation example scene makes some basic use of new Conversation features +- Update LeanTween to 2.46 #689 +- PortraitController forces alpha and color tweens to be non recursive. +- Updated playground demos + - Football uses GetKey instead of GetAxis (get axis was failing in some packages as inputmanager axis were not imported) + - Defender had a bug due to a change in how unity syncs 'up' between transform and rb2d + +## Fixed +- ElseIfs now confirm that the previous condition was at the same indent as themselves. #693 +- NarrativeLog is tolerant of null Name or Story fields #690 +- Force the hierarchy icon list to refresh when a script a is loaded/changed #672 +- Eventhandlers no longer fire when the flowchart is disabled #682 +- StopFlowchart can continue now #685 +- Fixed stray \\ that were not being stripped on Mac OS, when importing editor resources. #686 + +v3.8.0 {#v3_8_0} +====== + +Many thanks to contributors stevehalliwell, FrederickKDP, MeMark2, KVinS, charblar, FatPuzo for their work on this release! + +## Added +- Added Flowchart.HasBlock() and ExecuteIfHasBlock() methods +- Added Global Variable support. Variables have new 'Global' variable scope. +- Added GlobalVar demo scene + +## Changed +- Updated project version to Unity 2017.4.0f1 +- Refactored the set variable system to make it easier to add variable comparison options +- Added comparison and setting of GameObjects variables +- Updated Batch for newer versions of Unity3D web player #650 + +## Fixed +- Fixed compile errors in Unity 2018.1 beta +- Fixed compiler warnings in Untity2017.3 +- Fixed repeat play of music #659 +- Fixed conflicting EditorResource folder issue #664 +- Fixed SaveMenu DontDestroyOnLoad problems #661 +- Fixed docs: the block name in 6 of "Connections between Blocks" section from "Block2" to "Start" #663 +- Fixed lua say() function to match new say method parameters + +v3.7.0 {#v3_7_0} +====== + +Many thanks to maintainer Steve Halliwell for all the amazing new functionality in this release! + +## Added +- Added Playground examples showing 3 simple arcade games made using Fungus +- Added Rigidbody2D variable type +- Added Vector3 FungusCommands - Fields, Normalise, Convert to Vector2, Arithetic +- Added TransformProperty FungusCommand. Get and Set a transform's fields and properties. Does not currently support rotation, localRotation nor the Mat4x4 commands as we do not have the appropriate FungusVariables to store them in +- Added FungusCommand to Reload Current Scene +- Added Rigidbody2D FungusCommands - AddForce, AddTorque, StopMotion +- Added Input GetAxis fungusCommand, fetch Input.GetAxis and store in a FloatData +- SpawnObject FungusCommand can now store the gameobject it instantiates and can spawn at itself +- Destroy FungusCommand can now be told to pass down a delay to Destroy +- Added Fungus Commands for most of MathF +- Added Math demo scene +- Added Mouse fungus event demo scene +- Added Monobehaviour fungus event handlers and physics demo scene +- Added LeanTween commands and demo scene that approximates the old iTween demo +- Added SpeakingCharacter property to SayDialog +- Added Fungus panel in editor preferences +- Added option to toggle off the fungus icon in the hierarchy in case it conflicts with other tools or is just undesired +- Added TextTag WVO WaitForVoiceOver #572 +- Added ability to show variable list in the Flowchart Inspector #643 +- OpenURL FungusCommand renamed, fixes #554 #642 + +## Changed +- SaveManager now uses json files in a FungusSaves sub directory for all platforms but webplayer & webgl which still use playerprefs +- GetCommandInfo returns the highest priority CommandInfo to better support multiple names while maintaining what is shown in the inspector +- Allow multiple CommandInfos to be added to a class SpawnObject can now also be found under GameObject/Instantiate +- Changed Fungus icon loading to use FungusEditorResources + +## Fixed +- Fixed typo in BlockEditor.BlockField() #633 +- Fixed custom editor for ElseIf command #630 +- Fixed Prefab Variable Dereferencing #618 +- Fixed typo in Set Interactable description #647 +- Fixed choice dialogues were not set to stay during the MenuDialogue #640 +- Fixed camera fading and panning at the same time (thanks to iBicha!) #624 +- Fixed warnings on Unity 2017.2 + +v3.6.0 {#v3_6_0} +====== + +## Added +- Support use of \n newline character in Say and Conversation text +- Added Fungus-Playmaker integration package in Fungus/Integrations/PlayMaker #602 - thanks Nilihum +- Added Delete Save Data button to Save Menu inspector. +- Variable substitution works in Set Variable (String) command +- New "BlockNameAndCustom" Keymode for Save Point command, use both block name and custom key together. #597 - thanks Trieger +- Added portrait DimColor #601 - thanks MorningFunGame +- Lua If and Lua Else If commands #609 - thanks PillowFightIo +- Stop a named Block in a Flowchart +- Added utility to convert all files to Mac line endings + +## Changed +- Made all methods virtual in SayDialog.cs #607 thanks PillowFightIo +- Updated project to Unity 5.6.1, fixed some warnings. +- Use transform.Find instead of deprecated transform.FindChild +- Replaced some uses of slow GameObject.FindObjectOfType() and FindDerivedTypes() + +## Fixed +- Fixed Write command "Clear Text" option not working #594 +- Fixed portrait hide bug in conversation #590 - thanks to lealeelu +- Fixed stopping audio in conversation #592 - thanks to lealeelu +- Fixed can't use FungusLua separately to rest of Fungus #596 +- Fixed can't inspect disabled Flowchart #598 +- Fixed Cmd+Left Click doesn't register as right click on OSX #595 +- Fixed luautils won't work on FungusLua standalone #604 +- Fixed Save Menu: clicking to left of collapsed menu clicks hidden buttons #615 +- Fixed Localization only localizes character name, not story text #611, #614 + +v3.5.1 {#v3_5_1} +====== + +## Changed +- Added Save Data Key property to Save Menu to support multiple games in the same Unity project. + +v3.5.0 {#v3_5_0} +====== + +## Added +- Save game system. Use Save Point command and Save Menu prefab to easily add saving support with rewind / fast forward support. +- Added new menu options for spawning SaveMenu and SavedObjects prefabs +- New Save Game example scene +- Added documentation for Save System. +- Option to Close Other Say Dialogs when one Say Dialog becomes active. +- Select a start Label in Call command properties + +Thanks to contributor [zvinless](https://github.com/zvinless): +- Custom block tints can now be toggled per block in the block inspector. +- Added multi-select feature for blocks via action key/shift+click and click+drag +- Block movement and context menu options now affect all selected blocks +- Added Flowchart window toolbar in place of floating UI +- Flowchart window search filter to quickly find Blocks +- Added keyboard shortcuts and more context menu options for Blocks (copy, cut, duplicate, delete, select all) + +Thanks to contributor [sp-francisco-ruiz](https://github.com/sp-francisco-ruiz): +- Add a new Event Dispatcher to the FungusManager singleton +- Change Draggable2D and Clickable2D to use the new EventDispatcher for efficient calls for events. + +## Changed +- Moved Center button from Flowchart properties to new Flowchart window toolbar +- Flowchart’s SelectedBlock property now refers to the active selected block rather than the sole selected block. +- Updated coding standard with backwards compatibility & contributing notes +- Flowchart window now zoom in/out by mouse cursor or center rather than upper left corner +- All editor textures are now be accessible as properties in FungusEditorResources. +- Use Tools -> Fungus -> Utilities -> UpdateEditorResourcesScript to automatically update these editor textures +- Increased height of multi-line text box for StringDataMulti +- Updated curves, connection points, and grid background rendering with better approach +- Refactored Flowchart window to simplify event handling +- Bumped flowchart version to 2 to upgrade previously serialized selected blocks +- Flowchart context menu now appears on mouse up to better support panning + +## Fixed +- Fixed nested while loops don't loop correctly #562 +- Fixed Sprite Object click skips writing Say Text #576 +- Fixed setmenudialog() lua function does not set main active menu dialog #578 +- Fixed Unity Test Tools compatibility issue with Unity 5.5.0f +- Fixed spine integration to work with latest version of Spine runtime +- Fixed Block connections not highlighting when command selected +- Fixed centered text shifts position when written by Say command #569 +- Fixed Say text appears for single frame when using Say command #575 +- Fixed MenuDialog Lua Bug #565 +- Fixed using say in lua doesn't automatically spawn an EventSystem #571 +- Fixed cannot divide an integer by an integer using Set Variable #579 +- Fixed tabs in conversation text from Lua #574 +- Fixed Flowchart prefab's block show as empty on the Inspector #583 +- Fixed typo in Game Started Wait Frames property name +- Fixed Fungus ignores existing “SayDialog” and creates another one #555 +- Change CSVParser to use Regex.Split (way faster for large CSV files) +- Fixed missing sprite assets in Asset Store version. +- Fixed onComplete callback in MusicManager.SetAudioVolume when duration is 0 +- Removed TestRunner game objects from DragAndDrop examples. + +v3.4.0 {#v3_4_0} +====== + +## Known Issues +- FungusLua generates runtime errors running Lua when using .NET scripting backend. The IL2CPP backend works fine. + +## Added +- Added accessors for GameObject and Transform variables in Flowchart.cs +- Added Flowchart.HasVariable() and GetVariableNames() - thanks murnyipl! +- Added WaitForFrames property to GameStarted event handler. Default is wait for 1 frame (should reduce startup order issues). + +## Changed +- Upgraded to Moonsharp 2.0. Moonsharp source code is now included in Fungus/Thirdparty/MoonSharp +- Removed MoonSharp assembly from link.xml +- Converted MoonSharp line endings to OSX for consistency with rest of project. +- Updated documentation for Lua debugger (using VS Code) +- Removed LuaEnvironment Remote Debugger option. A VS Code debug server always starts when running in the editor. +- SayDialog now supports full variable substitution when setting character names. + +## Fixed + +- Fixed Command properties not copied when copying commands #546 +- Fixed PODTypeFactory and FungusPrefs classes are not registered #549 +- Fixed for compile errors on .NET Core scripting backend +- Fixed LuaBindings registered types in example scenes +- Fixed MoonSharp warning when not building for an AOT platform +- Fixed minor issues in some example scenes (e.g. missing sprite refs) + +v3.3.0 {#v3_3_0} +====== + +## Known Issues +- FungusLua does not work in WebGL builds due to issues in MoonSharp 1.8.0.0 +- Forum thread: http://fungusgames.com/forum/#!/general:fungus-lua-and-web-gl-uni +- FungusLua does not compile for Windows Store platform using .net scripting backend. Use the IL2CPP backend instead. + +## Added +- Added test for StopTweens does not stop a Tween with loop enabled #529 +- Added signals (pub-sub system) for Writer and Block events #539 +- All interfaces now have their own source files. +- Added monodevelop project for editing docs files. +- Added Flip option (<<< and >>>) to conversation system #527 +- Added WaitFrames command to wait for a number of frames +- Added GetToggleState, SetToggleState commands and ToggleChanged event handler +- Added Writer.Paused property to pause a writer from code. + +## Changed + +- Tidied up Fungus folder structure to organize scripts more logically +- Migrated documentation to use Doxygen for help and API docs +- Lots of misc improvements to documentation +- Updated to MoonSharp 1.8.0.0 +- Documented using string facing parameter in stage.show() Lua function. +- Documented <<< and >>> tags for conversation system. +- Documented all public members for API docs. +- All serialized fields are now protected, exposed via public properties as needed. +- Moved all enums to namespace scope. +- Moved global constants to FungusConstants static class. +- Moved editor resources to the main resources folder +- Fungus editor code moved to Fungus.EditorUtils namespace +- Convert singletons to use a single FungusManager singleton #540 +- Renamed CameraController to CameraManager and MusicController to MusicManager +- Changed float constant comparisons to use Mathf.Approximately +- Added #region Public members to all non-editor classes +- StringFormatter, TextTagParser and FungusPrefs classes are now static +- Merged MenuDialog extension methods (used for Lua) with main MenuDialog class. +- Change all public methods to use virtual +- Removed all unnecessary using statements. +- All class and member comments use standard c# xml comment style +- Replaced foreach loops with for loops (avoids allocation for iterator) +- Added changelog to Doxygen documentation + +## Fixed + +- Fixed Setting facing in lua only works if portraits are set to “FRONT” #528 +- Fixed Say command completes instantly after menu choice #533 +- Fixed broken mouse pointer in WebGL build of Drag and Drop +- Fixed ObjectField nulls reference if object is disabled #536 +- Updated Unity Test Tools to v1.5.9 +- Fixed missing Process class error in Unity5.5b3 +- Fixed Spine.Unity namespace problem in integration scripts +- Fix Regex for character names with "." & "'" #531 (thanks to Sercan Altun) + Old Regex expression did not capture Character names with "." and "'". As a result characters with names like "Mr. Jones" or "Ab'ar" were not registering correctly. +- Fixed Lua setlanguage() function +- Fixed namespace issue in Spine integration. +- Fixes all integration tests to pass when run on Windows Standalone. +- Fixed Block inspector displayed for inactive flowchart #544 + +v3.2.0 {#v3_2_0} +====== + +## Known Issues +- FungusLua does not work in WebGL builds due to issues in MoonSharp 1.6.0.0 + Forum thread: http://fungusgames.com/forum/#!/general:fungus-lua-and-web-gl-uni + +## Added +- Added choose() and choosetimer() Lua functions for displaying list of menu options. +- Added Conversation command and Lua function to perform long dialogue exchanges in a single command. +- Added new Conversation examples + +## Changed +- Clickable2D and Dragable2D components can now use legacy input or EventSystem events / raycasts. +- Added DragAndDrop(EventSystem) example scene to show how to use the EventSystem option. +- Made it easier to resize the default SayDialog +- Updated Narrative examples to use the easier choose() function instead of menu() +- Force MenuDialog to become active when using AddOption from Lua. +- Converted tabs to spaces in all source files +- Ensure the character cache is populated before accessing it +- Added Serializable attribute to all variable classes. + +## Fixed +- Added link.xml file to fix FungusLua not running on iOS builds +- Portrait hide bug in Conversation Function #526 +- Unresponsive SayDialog after ClearMenu or *.StopAllBlocks(); #518 +- Can't select a Public variable from another flowchart #522 +- NullReferenceException with nameText in SayDialog #517 +- StackOverflowException in Writer with customized text object #516 +- stage.Show() not fading in a previously faded out character if portrait hasn't changed. +- Missing .Value on _parameterName property. +- Fixed missing component warnings +- Updated MoonSharp to v1.6.0.0 (this time without changing the meta files). + +v3.1.0 {#v3_1_0} +====== + +## Added + +- Flowchart automatically registers with LuaEnvironment for ExecuteLua commands #485 +- Clickable2D and Draggable2D can now use EventSystem events to block clicks on UI elements. Added new drag and drop demo scene to illustrate. + +## Changed + +- Default dialog image is now sliced, so can be resized to any width / height required. +- Upgraded MoonSharp to v1.6.0.0 +- Added [System.Serializable] attribute to all Variable classes. + +## Fixed + +- Default dialog box now fits in a 5:4 ratio display #515 +- Dialog input causing an exception if no Event System is present in scene. +- Missing module variable on round() function +- Menu() Lua function only works once #511 +- Compile error for folks upgrading using the Fungus 3 unitypackage + +v3.0.0 {#v3_0_0} +====== + +Major release with powerful new Lua scripting support and many small improvements and fixes. +This release should be backwards compatible with projects created using Fungus 2. If you have any upgrading issues let us know on the forum. + +Many thanks to the amazing Fungus community for all the suggestions, bug reports and encouragement! + +Awesome github contributors: +- Leah Lee: https://github.com/lealeelu +- Gerardo Marset: https://github.com/ideka +- Konrad Gadzina: https://github.com/FeniXb3 +- Kal O' Brien: https://github.com/kalenobrien15 +- Hawmalt: https://github.com/hawmalt + +## Added +- FungusLua: Lua scripting support for Fungus via wrapper components for using MoonSharp in Unity. #281, #317, #334, #237, #235, #232, #224 + - LuaEnvironment component: Execution environment for running Lua scripts. + - LuaUtils component: Extends LuaEnvironment with lots of useful features. + - LuaBindings: Maps Unity objects & components to Lua variables for use in Lua scripts. + - LuaScript: Runs Lua code from a text file or from a string property. + - LuaStore: Stores variables in a global table which persists across scene loads. + - FungusModule: A set of utility functions for scripting Unity and Fungus from Lua. + - FungusPrefs: An improved version of PlayerPrefs that can be easily used from Lua. + - ExecuteHandler: Listens for any standard Unity event and calls a method on a component in the gameobject. #247 + - ExecuteLua command: Run some Lua script in a Fungus command. Return values can be stored in Fungus variables. + - PODTypeFactory: Utility factory class for instantiating Plain-Old-Data (POD) types like Color, Vector3, etc. + - Lots of FungusLua example scenes + - Fungus documentation now has an extensive section on LuaScripting. +- StringDataMulti: Like StringData, but uses a multi-line textbox in the inspector. +- StopBlock command: Stop executing the named block. +- Improved string substitution system. Now works with Lua global variables and Lua string table, as well as Flowchart variables. +- Extend the string substitution system yourself using the new ISubstitutionHandler interface. +- Added TaskManager library to Thirdparty folder. Allows better control over coroutine execution. +- Show Line Numbers option in Flowchart. Shows the command index in the inspector (off by default). #231 +- Play Animation State command. Plays an animation state directly without a transition. #378 +- Open URL command #382 +- Links to community articles in the help docs #385 +- InfoText.cs component for displaying help information in the top-left of screen +- "Play from Selected" and "Stop All and Play" context menu options in Block command list +- Added Command Index property to Call command +- LuaStore example scene to demonstrate persisting Lua variables between scene loads +- Use stage.show(), stage.showPortrait & stage.hide() to control stage & portraits from Lua #490 + See FungusExamples/FungusLua/Narrative/PortraitController.unity example scene +- Portrait functionality moved to new PortraitController utility class for easier scripting. +- Say and Menu Dialogs now support standard input manager (joystick / controller support) #507 #210 +- Menu options can now be picked with keyboard only +- Fast forward using Shift in Say Dialogs is now done using the Cancel input (Escape key by default). + +## Changed +- Draggable sprite anchors at exact point user clicked. +- Replaced string with StringData, int with IntegerData, etc. in many command properties. Use variables or constants. +- Block.Execute renamed to Block.StartExecute, can now specify a command index to start at. +- Say command: Set the Character using an object field or the dropdown menu. Can now select Character prefabs. +- Improved Flowchart UpdateVersion system +- Portrait image is now hidden at startup in SayDialog +- Use DialogAudio volume property for starting volume on voiceover audio +- WriterAudio now respects the volume property in all cases +- Added short open source license info header to all source files +- SetAudioVolume.waitUntilFinished property #495 +- String substitution uses StringBuilder to avoid string allocations (reduce garbage collection) #490 +- Embed string substitution keys in substitution text (recursive substitution up to 5 levels) #488 + +## Fixed +- SetDraggable2D filename now matches class name. +- Unity 5.4 beta errors & warnings +- CsvParser.cs and InvokeMethod lineendings should be consistent with rest of project. +- Faulty indent levels when inspector is not displayed #380 +- Hide Portrait before Show Portrait breaks portrait system #384 +- Private variable values being reset with multiple flowcharts #389 +- Stage objects blocking raycasts #391 +- Writer voiceover clip always stops when text stops #393 +- Size tag in UI text is not supported #400 +- Clickable sprites can be clicked through UI objects #377 +- Don't destroy sprite objects in Scene Loader #386 +- Add links to community articles in the help docs #385 +- Control volume bug #464 +- Unity Test Tools compile errors in Unity 5.0 +- Edge of inspector window clipped incorreclty in Unity 5.4 beta #425 +- Child Object gets deleted when having a flowchart on parent and child. #475 +- Fixed command summary incorrect for Fade UI command #486 +- No Music clip selected error summary in Play Sound command +- Jump command properties incorrect when block duplicated #504 +- menu() Lua command interactable param has no effect #493 +- Set Anim Integer/Float/Bool lose property settings #492 +- Can't select ExecuteBlock from Unity Event #496 +- Fixed aliased commandIndex property in Call command. + +## Other closed issues +- GameObjects get duplicated when flowchart is on a different scene #373 +- TextMesh Pro integration #214 +- Clickable3D component #195 + +v2.4.0 {#v2_4_0} +====== + +## Added +- FungusLua: Lua scripting support for Fungus via wrapper components for using MoonSharp in Unity. #281, #317, #334, #237, #235, #232, #224 + - LuaEnvironment component: Execution environment for running Lua scripts. + - LuaUtils component: Extends LuaEnvironment with lots of useful features. + - LuaBindings: Maps Unity objects & components to Lua variables for use in Lua scripts. + - LuaScript: Runs Lua code from a text file or from a string property. + - LuaStore: Stores variables in a global table which persists across scene loads. + - FungusModule: A set of utility functions for scripting Unity and Fungus from Lua. + - FungusPrefs: An improved version of PlayerPrefs that can be easily used from Lua. + - ExecuteHandler: Listens for any standard Unity event and calls a method on a component in the gameobject. #247 + - ExecuteLua command: Run some Lua script in a Fungus command. Return values can be stored in Fungus variables. + - PODTypeFactory: Utility factory class for instantiating Plain-Old-Data (POD) types like Color, Vector3, etc. + - Lots of FungusLua example scenes + - Fungus documentation now has an extensive section on LuaScripting. +- StringDataMulti: Like StringData, but uses a multi-line textbox in the inspector. +- StopBlock command: Stop executing the named block. +- Improved string substitution system. Now works with Lua global variables and Lua string table. +- Extend the string substitution system yourself using the new ISubstitutionHandler interface. +- Added TaskManager library to Thirdparty folder. Allows better control over coroutine execution. +- Show Line Numbers option in Flowchart. Shows the command index in the inspector (off by default). #231 +- Play Animation State command. Plays an animation state directly without a transition. #378 +- Open URL command #382 +- Links to community articles in the help docs #385 +- InfoText.cs component for displaying help information in the top-left of screen +- "Play from Selected" and "Stop All and Play" context menu options in Block command list + +## Changed +- Draggable sprite anchors at exact point user clicked. +- Replaced string with StringData, int with IntegerData, etc. in many command properties. +- Bock.Execute renamed to Block.StartExecute, can now specify a command index to start at. +- Say command: Set the Character using an object field or the dropdown menu. Can now select Character prefabs. +- Improved Flowchart UpdateVersion system +- Portrait image is now hidden at startup in SayDialog +- Use DialogAudio volume property for starting volume on voiceover audio +- WriterAudio now respects the volume property in all cases + +## Fixed +- SetDraggable2D filename now matches class name. +- Unity 5.4 beta errors & warnings +- CsvParser.cs and InvokeMethod lineendings should be consistent with rest of project. +- Faulty indent levels when inspector is not displayed #380 +- Hide Portrait before Show Portrait breaks portrait system #384 +- Private variable values being reset with multiple flowcharts #389 +- Stage objects blocking raycasts #391 +- Writer voiceover clip always stops when text stops #393 +- Size tag in UI text is not supported #400 +- Clickable sprites can be clicked through UI objects #377 +- Don't destroy sprite objects in Scene Loader #386 +- Add links to community articles in the help docs #385 +- Control volume bug #464 +- Unity Test Tools compile errors in Unity 5.0 +- Edge of inspector window clipped incorreclty in Unity 5.4 beta #425 + +## Other closed issues +- GameObjects get duplicated when flowchart is on a different scene #373 +- TextMesh Pro integration #214 +- Clickable3D component #195 + +v2.3.1 {#v2_3_1} +====== + +## Fixed +- Can't click on Say Dialog when a Menu Dialog is active #374 +- Set Audio Pitch: OnComplete not called when duration = 0 #369 +- Fade To View can sometimes not work in Unity 5.3 #370 + +v2.3.0 {#v2_3_0} +====== + +## Added +- SetDraggable2D command #191 +- WaitInput command #276 +- Fade UI command to fade UI objects #349 +- Read Text File command to read a text file into a string variable #344 +- Added Set Audio Pitch command #340 +- 'Center View' button to center Flowchart window on all Blocks #302 +- Added Clear Menu command #300 +- Set Slider Value command #297 +- Stop Flowchart command #289 +- Integration with Esoteric Spine animation system (available in Fungus/Integrations/Spine folder) + +## Changed +- Added null checks in Flowchart variable accessors +- Set Say Dialog property for characters +- Can now specify the gameobject to shake for punch tag in Writer component +- PlayMusic command has a loop property +- Updated reorderable list control to v0.4.3 +- Updated to LeanTween 2.30 +- Added HasExecutingBlocks() and GetExecutingBlocks() to Flowchart class +- Remove unused Text Width Scale property on Say Dialog +- Can now specify a camera to use with Camera command (not just main) #319 #307 +- Can now disable Camera Z being forced by View commands #319 +- Text tags now support multiple parameters. +- Write command now works with Text Mesh Pro text objects. +- Writer.InstantComplete property controls click-to-complete writing. +- Shake tag shakes camera instead of Writer game object. + +## Fixed +- Ensure parentBlock is set when block executes #320 +- While loop with following If doesn't loop correctly #354 +- Auto cross fade music in Play Music command #199 +- Play Music call doesn't restart if same music already playing +- Play Music call doesn't restart if same music already playing +- Concurrent Say commands on same Say Dialog should interrupt #356 +- CustomGUI class not in Fungus namespace #353 +- Whitespace trimming after {wc} & {c} tags #346 +- iTween commands on the same gameobject can conflict #342 #303 +- Show Sprite should affect child sprites #338 +- Null reference if command classes have same name #312 +- End command indents when not matched with an If #308 +- Draggable objects behaving incorrectly #310 +- Inactive localizeable game objects are now also cached #322 +- SceneManager warnings in Unity 5.3 +- Fixed Windows store build 268 +- Fixed Writer beep timing issues in WebGL #295 +- Removed say command from Flowchart prefab + +v2.2.2 {#v2_2_2} +====== + +## Added + +- Stop Flowchart command and Flowchart.StopAllBlocks() method #288 + +## Changed + +- Only the first Flowchart added to a scene will have a default GameStarted event handler. +- Null items in variable list are cleaned up on enable. + +## Fixed + +- Flowchart objects break when made into a prefab #275 +- Localization language does not persist between scenes #271 +- Voiceover clips not playing correctly in Say command #273 +- Changing portrait facing flips incorrectly #190 +- Variable substitution in Menu command #263 +- Null variable reference when substituting variables #278 +- Removed empty gameobject in sherlock demo +- Removed unused GameStarted component from built-in Flowchart prefab + +v2.2.1 {#v2_2_1} +====== + +## Added + +- Set Interactable command to control UI button, input field, etc. interactivity #178 +- Button Clicked event handler to execute a block when a UI button is clicked +- End Edit event handler to execute a block when user presses enter in an input field +- Hide specific commands & categories in the Add Command menu by setting the Hide Commands property on Flowchart + +## Changed + +- Improved Enter Name example to demonstrate the new Write, Get Text, Set Text, Set Interactable, etc. commands. +- Removed punctuation pause for last character in a sentence #168 +- Removed unsupported 'shiver' item from tag help description in Say and Write commands +- Moved LICENSE and README inside the Fungus folder #185 + +## Fixed + +- Concurrent Say calls cause Say Dialog to freeze up #156 +- Null reference error after editing Flowchart code #181 +- Markup text visible if rich text not enabled when using Write command #176 +- ControlAudio waitUntilFinished property doesn't wait for correct time #174 +- Removed legacy hidden objects in example scenes #159 +- Undo for delete command doesn't work #161 +- Flowchart in The Hunter example has Hide Components set to false #150 + +v2.2.0 {#v2_2_0} +====== + +## Added + +- Write command for writing text to any text object +- Writer, Writer Audio components for writing text to any text object with lots of new configuration options. +- Say Dialog class has been split into Say Dialog, Dialog Input components +- Dialog Input supports multiple input types; clicks & key presses +- Can hold down shift while pressing a key to fast forward through dialog text +- Say Dialog now adjusts Story Text rect when character image is visible. +- Added Stop() method to Say Dialog and Writer to cancel writing immediately +- Fullscreen command. https://trello.com/c/aA5GQlua +- InputText example in FungusExamples +- Localization support for the Set Text and Write commands. +- Custom commands can integrate with the localisation system by implementing the ILocalizable interface. +- Invoke Event command for calling script methods with a parameter using Unity's EventSystem. +- Invoke Method command for calling script methods with multiple parameters using reflection. +- Can now use UnityEvent variables in custom commands +- Flowchart versioning and initialization +- Menu command now has an Interactable property to add disabled menu options. https://trello.com/c/bFjmGfBc +- Set Sprite Order command. https://trello.com/c/5yZ88Rh0 +- Added Set Sorting Layer command to set renderer sorting layer +- Set Mouse Cursor command and drag and drop support +- Constructors and implicit operators for all Fungus variable types +- Quit command to quit application - https://trello.com/c/qIVLgrDx +- New Fungus/UI command category +- Added ComboBox to Thirdparty folder +- Added Tools > Fungus > Create > Fungus Logo menu option + +## Changed + +- Simplifed Say Dialog hierarchy structure to be easier to customise +- Say Dialog continue image is now a UI button +- Say Dialog automatically fades in / out when writing +- Updated The Facility example to work with new Say Dialog design +- Updated Drag And Drop example to use new Set Mouse Cursor command +- Improved rendering efficiency of Block inspector window. +- Improved shift-selecting commands in Block inspector. +- Portrait command now moves portraits using world position instead of anchored position +- Portrait cross fading is now done using image alpha instead of a custom shader +- Stage Show / Hide is now done by tweening the CanvasGroup alpha. +- Portrait MoveSpeed is now MoveDuration +- Portrait WaitUntilFinished option now works robustly +- Additional flowcharts added to the scene no longer have their initial block start with the default 'Game Started' event. +- Command array properties can now be flagged to use the reorderable list control +- Custom commands can override IsPropertyVisible() to hide specific properties as needed. +- SetActive command shows state in summary +- Block Event Handler for additional Flowcharts now defaults to none. +- Can assign default values to public Fungus variable properties +- Can access Fungus variable values directly without using .Value accessor. +- Say Command fade in / out replaced with automatic fading and Fade When Done property +- Get Text and Set Text command now work on any text object (UI text, UI input fields & 3D text mesh) + +## Fixed + +- Shake Camera command timing issue #137 +- CSV parser doesn't handle Windows-style line endings #131 +- Intermittent init order issue with caching localizeable objects +- Control Audio stopping all untagged audiosources #132 +- Intermittent null reference error from command editors +- Draggable objects don't return to start pos if drag completes #130 +- Moving and fading portraits at the same time +- Character portrait images have display artefacts #92 +- Duplicate Block option does not do a deep copy #129 +- Event System not created after Load Scene #121 +- Voice over audio only works every second time #126 +- Editing multiline command properties in block inspector. +- Compile error when Fungus is used with "Draw On Screen" asset #120 +- Null reference exception when spawning Fungus objects in Unity 5.1 +- Story text box width is restored when using a character with no portrait #141 +- Block inspector window resizes when using cut, copy, paste shortcuts #145 +- Objects spawned from Tools > Fungus > Create menu center correctly in Unity 5.1.3f + +## Process Changes + +We are now using the Unity Test Tools framework for unit and integration testing. +All new features and bug fixes now have automated tests where possible. + +## Upgrade Notes + +We made a LOT of improvements to the Say Dialogs in this release. Unfortunately these changes are likely to break existing customised Say Dialogs. If you upgrade an existing Fungus project and find the Say Dialog are no longer working you will need to delete your Say Dialogs and create new ones. + +v2.1.0 {#v2_1_0} +====== + +First release on Unity Asset Store! + +## Added + +- Added Flowchart.FindBlock so you can check if a Block is executing before you try to execute it. +- Cleanup any unreferenced components in Flowchart when scene loads + +## Changed + +- Call Method can now execute after a delay +https://trello.com/c/a333r2QA + +- Can now control swipe pan speed in Start Swipe command +https://trello.com/c/TmG9SiIa + +- Improved layout of Flowchart name and description +https://trello.com/c/vwnzaOh2 + +## Removed + +- Removed obsolete commands and other dead code + +## Fixed +- Fixed using iTween and Portrait commands in same Flowchart causes null exception #116 +- Fixed whitespace and newlines not being trimmed after {wc} & {c} tags in story text #115 +- Fixed Standard Text import strips out newline characters #114 +- Fixed {x} text tag causing a null reference error #113 +- Fixed Flowchart.ExecuteBlock() not being usable with UI events (e.g. a UI button event) #112 +- Fixed Set Draggable command causing null exception error #111 +- Fixed conflicting Block & command item ids (was breaking localization text export) #110 diff --git a/Assets/Fungus/Docs/CHANGELOG.txt.meta b/Assets/Fungus/Docs/CHANGELOG.txt.meta new file mode 100644 index 0000000..f581418 --- /dev/null +++ b/Assets/Fungus/Docs/CHANGELOG.txt.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: c35cb3df0536b47ab858a7af04b14164 +timeCreated: 1433597476 +licenseType: Store +TextScriptImporter: + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Docs/LICENSE.txt b/Assets/Fungus/Docs/LICENSE.txt new file mode 100644 index 0000000..006576c --- /dev/null +++ b/Assets/Fungus/Docs/LICENSE.txt @@ -0,0 +1,21 @@ +The MIT License (MIT) + +Copyright (c) 2014 Chris Gregan + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. diff --git a/Assets/Fungus/Docs/LICENSE.txt.meta b/Assets/Fungus/Docs/LICENSE.txt.meta new file mode 100644 index 0000000..16bbde7 --- /dev/null +++ b/Assets/Fungus/Docs/LICENSE.txt.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 5f60cf750399a4be5b3e3bea9a57a3f8 +timeCreated: 1432311050 +licenseType: Store +TextScriptImporter: + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Docs/README.txt b/Assets/Fungus/Docs/README.txt new file mode 100644 index 0000000..723f8bd --- /dev/null +++ b/Assets/Fungus/Docs/README.txt @@ -0,0 +1,37 @@ +Fungus +====== + +The goal of Fungus is to provide a free, open source tool for creating interactive storytelling games in Unity 3D. +Fungus is designed to be easy to learn for beginners to Unity 3D, especially for people with no coding experience. + +For power users, it provides an intuitive, fast workflow for visual scripting and interactive storytelling. +Fungus is being used to create Visual Novels, Point and Click Adventure Games, Childrens Stories, Hidden Object Games, +eLearning apps and also some frankly weird stuff which defies classification :) + +- Author: Chris Gregan +- Website: fungusgames.com +- Email: chris@snozbot.com +- Twitter: @gofungus +- Facebook: facebook.com/fungusgames + +Instructions +============ + +Installation instructions and tutorial videos are available on the official Fungus website. +http://fungusgames.com/learn + +Support +======= + +If you have questions about Fungus, please search our forum first as someone may have had the same issue already. If you can't find an answer please start a new discussion and we'll answer you as soon as we can. Fungus is designed for beginners and we love to hear from users so please don't be shy about posting! +http://fungusgames.com/forum + +Contributing +============ + +Many thanks to everyone who has contributed code to the project. +https://github.com/snozbot/fungus/graphs/contributors + +If you would like to contribute a bug fix or new feature, please submit a pull request on github (https://github.com/snozbot/fungus) + +And if you are interested in contributing in some other way (art, audio, documentation, pizza) just email me at chris@snozbot.com. diff --git a/Assets/Fungus/Docs/README.txt.meta b/Assets/Fungus/Docs/README.txt.meta new file mode 100644 index 0000000..b06ed27 --- /dev/null +++ b/Assets/Fungus/Docs/README.txt.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: b21045f2b204b490c8d7595b4def46fd +timeCreated: 1431619113 +licenseType: Store +TextScriptImporter: + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/EditorResources.meta b/Assets/Fungus/EditorResources.meta new file mode 100644 index 0000000..8eab26f --- /dev/null +++ b/Assets/Fungus/EditorResources.meta @@ -0,0 +1,9 @@ +fileFormatVersion: 2 +guid: 5ff164265158945c18b7d438b570ba22 +folderAsset: yes +timeCreated: 1478502248 +licenseType: Store +DefaultImporter: + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/EditorResources/FungusEditorResources.asset b/Assets/Fungus/EditorResources/FungusEditorResources.asset new file mode 100644 index 0000000..6cda160 --- /dev/null +++ b/Assets/Fungus/EditorResources/FungusEditorResources.asset @@ -0,0 +1,69 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!114 &11400000 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 0} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: d2af387304e4b454b9ce8b815799cad0, type: 3} + m_Name: FungusEditorResources + m_EditorClassIdentifier: + updateOnReloadScripts: 0 + add: + free: {fileID: 2800000, guid: 24a867d6b4cdda04cb3aa3350f9ec7d0, type: 3} + pro: {fileID: 2800000, guid: 4e43c476b4a7a49a08c37378fb01ce99, type: 3} + add_small: + free: {fileID: 2800000, guid: 288aff1a0e5c14fd3a0039d24149df73, type: 3} + pro: {fileID: 2800000, guid: 64534dfaa17844231a9a9dd2df89d0db, type: 3} + delete: + free: {fileID: 2800000, guid: d6fc8a97e8a5b0947a49b780f787e504, type: 3} + pro: {fileID: 2800000, guid: 29c4d29b1678042a5b3516c732ccc507, type: 3} + down: + free: {fileID: 2800000, guid: 51a973f446c2e664582861480cce6215, type: 3} + pro: {fileID: 2800000, guid: 5a87a7d3683164a238377d948572805f, type: 3} + duplicate: + free: {fileID: 2800000, guid: c97f334c466215a4f93eff31de3c1591, type: 3} + pro: {fileID: 2800000, guid: 2f17490d993c84bd7872ef6588ffba47, type: 3} + fungus_mushroom: + free: {fileID: 2800000, guid: 1c99c9bf7557e23469ed5dfce00504c0, type: 3} + pro: {fileID: 2800000, guid: 6368c1c16ebb1694091262337e4f8c44, type: 3} + up: + free: {fileID: 2800000, guid: 8f1242ad894201f43b2b6d52fd990f77, type: 3} + pro: {fileID: 2800000, guid: 2a76a781db2994b33b83cd84b8835da7, type: 3} + bullet_point: + free: {fileID: 2800000, guid: 4ef739c68bb234717a60a2bb83ff8602, type: 3} + pro: {fileID: 0} + choice_node_off: + free: {fileID: 2800000, guid: 7b6fc04aac74540e39e9502da5312ce7, type: 3} + pro: {fileID: 0} + choice_node_on: + free: {fileID: 2800000, guid: cfc05494b71a0446182868aab5f7febf, type: 3} + pro: {fileID: 0} + command_background: + free: {fileID: 2800000, guid: a5c9a4271b3de4e4f86eff7f8a1bd768, type: 3} + pro: {fileID: 0} + connection_point: + free: {fileID: 2800000, guid: f08a4c27d7efe4aa6a35348a4e8aec8f, type: 3} + pro: {fileID: 0} + event_node_off: + free: {fileID: 2800000, guid: 0e16a209826864df7b05f6d3901aae7a, type: 3} + pro: {fileID: 0} + event_node_on: + free: {fileID: 2800000, guid: 9434488a4efb54da5986eba5d5619baf, type: 3} + pro: {fileID: 0} + play_big: + free: {fileID: 2800000, guid: bff2ba39f5f4448589e80522ebfcd0a0, type: 3} + pro: {fileID: 0} + play_small: + free: {fileID: 2800000, guid: a48a2b9b06deb469d9da1777b094521b, type: 3} + pro: {fileID: 0} + process_node_off: + free: {fileID: 2800000, guid: ea3a4228e6c214149bfe5c741b56ae0c, type: 3} + pro: {fileID: 0} + process_node_on: + free: {fileID: 2800000, guid: c2dceb780784240ccbe8d3cde89f7671, type: 3} + pro: {fileID: 0} diff --git a/Assets/Fungus/EditorResources/FungusEditorResources.asset.meta b/Assets/Fungus/EditorResources/FungusEditorResources.asset.meta new file mode 100644 index 0000000..1cdb5d0 --- /dev/null +++ b/Assets/Fungus/EditorResources/FungusEditorResources.asset.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 29cae11326cb84802b83fc3ff25a47e8 +NativeFormatImporter: + externalObjects: {} + mainObjectFileID: 11400000 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/EditorResources/Icons.meta b/Assets/Fungus/EditorResources/Icons.meta new file mode 100644 index 0000000..bd6c0d5 --- /dev/null +++ b/Assets/Fungus/EditorResources/Icons.meta @@ -0,0 +1,5 @@ +fileFormatVersion: 2 +guid: 6ae11e36c1f504a5db97beed10849329 +folderAsset: yes +DefaultImporter: + userData: diff --git a/Assets/Fungus/EditorResources/Icons/Pro.meta b/Assets/Fungus/EditorResources/Icons/Pro.meta new file mode 100644 index 0000000..e6bbb01 --- /dev/null +++ b/Assets/Fungus/EditorResources/Icons/Pro.meta @@ -0,0 +1,9 @@ +fileFormatVersion: 2 +guid: 5e5a1319ef7f546a7affe3baabd5fba6 +folderAsset: yes +timeCreated: 1478502692 +licenseType: Store +DefaultImporter: + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/EditorResources/Icons/Pro/add.png b/Assets/Fungus/EditorResources/Icons/Pro/add.png new file mode 100644 index 0000000..23646d9 Binary files /dev/null and b/Assets/Fungus/EditorResources/Icons/Pro/add.png differ diff --git a/Assets/Fungus/EditorResources/Icons/Pro/add.png.meta b/Assets/Fungus/EditorResources/Icons/Pro/add.png.meta new file mode 100644 index 0000000..59749f6 --- /dev/null +++ b/Assets/Fungus/EditorResources/Icons/Pro/add.png.meta @@ -0,0 +1,59 @@ +fileFormatVersion: 2 +guid: 4e43c476b4a7a49a08c37378fb01ce99 +timeCreated: 1478502692 +licenseType: Store +TextureImporter: + fileIDToRecycleName: {} + serializedVersion: 2 + mipmaps: + mipMapMode: 0 + enableMipMap: 0 + linearTexture: 1 + correctGamma: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + grayScaleToAlpha: 0 + generateCubemap: 0 + cubemapConvolution: 0 + cubemapConvolutionSteps: 7 + cubemapConvolutionExponent: 1.5 + seamlessCubemap: 0 + textureFormat: -3 + maxTextureSize: 2048 + textureSettings: + filterMode: -1 + aniso: 1 + mipBias: -1 + wrapMode: 1 + nPOTScale: 0 + lightmap: 0 + rGBM: 0 + compressionQuality: 50 + allowsAlphaSplitting: 0 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spritePixelsToUnits: 100 + alphaIsTransparency: 1 + spriteTessellationDetail: -1 + textureType: 2 + buildTargetSettings: [] + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + spritePackingTag: + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/EditorResources/Icons/Pro/add_small.png b/Assets/Fungus/EditorResources/Icons/Pro/add_small.png new file mode 100644 index 0000000..cf6b201 Binary files /dev/null and b/Assets/Fungus/EditorResources/Icons/Pro/add_small.png differ diff --git a/Assets/Fungus/EditorResources/Icons/Pro/add_small.png.meta b/Assets/Fungus/EditorResources/Icons/Pro/add_small.png.meta new file mode 100644 index 0000000..8093494 --- /dev/null +++ b/Assets/Fungus/EditorResources/Icons/Pro/add_small.png.meta @@ -0,0 +1,59 @@ +fileFormatVersion: 2 +guid: 64534dfaa17844231a9a9dd2df89d0db +timeCreated: 1478502692 +licenseType: Store +TextureImporter: + fileIDToRecycleName: {} + serializedVersion: 2 + mipmaps: + mipMapMode: 0 + enableMipMap: 0 + linearTexture: 1 + correctGamma: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + grayScaleToAlpha: 0 + generateCubemap: 0 + cubemapConvolution: 0 + cubemapConvolutionSteps: 7 + cubemapConvolutionExponent: 1.5 + seamlessCubemap: 0 + textureFormat: -3 + maxTextureSize: 2048 + textureSettings: + filterMode: -1 + aniso: 1 + mipBias: -1 + wrapMode: 1 + nPOTScale: 0 + lightmap: 0 + rGBM: 0 + compressionQuality: 50 + allowsAlphaSplitting: 0 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spritePixelsToUnits: 100 + alphaIsTransparency: 1 + spriteTessellationDetail: -1 + textureType: 2 + buildTargetSettings: [] + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + spritePackingTag: + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/EditorResources/Icons/Pro/delete.png b/Assets/Fungus/EditorResources/Icons/Pro/delete.png new file mode 100644 index 0000000..5cba698 Binary files /dev/null and b/Assets/Fungus/EditorResources/Icons/Pro/delete.png differ diff --git a/Assets/Fungus/EditorResources/Icons/Pro/delete.png.meta b/Assets/Fungus/EditorResources/Icons/Pro/delete.png.meta new file mode 100644 index 0000000..870542c --- /dev/null +++ b/Assets/Fungus/EditorResources/Icons/Pro/delete.png.meta @@ -0,0 +1,59 @@ +fileFormatVersion: 2 +guid: 29c4d29b1678042a5b3516c732ccc507 +timeCreated: 1478502692 +licenseType: Store +TextureImporter: + fileIDToRecycleName: {} + serializedVersion: 2 + mipmaps: + mipMapMode: 0 + enableMipMap: 0 + linearTexture: 1 + correctGamma: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + grayScaleToAlpha: 0 + generateCubemap: 0 + cubemapConvolution: 0 + cubemapConvolutionSteps: 7 + cubemapConvolutionExponent: 1.5 + seamlessCubemap: 0 + textureFormat: -3 + maxTextureSize: 2048 + textureSettings: + filterMode: -1 + aniso: 1 + mipBias: -1 + wrapMode: 1 + nPOTScale: 0 + lightmap: 0 + rGBM: 0 + compressionQuality: 50 + allowsAlphaSplitting: 0 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spritePixelsToUnits: 100 + alphaIsTransparency: 1 + spriteTessellationDetail: -1 + textureType: 2 + buildTargetSettings: [] + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + spritePackingTag: + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/EditorResources/Icons/Pro/down.png b/Assets/Fungus/EditorResources/Icons/Pro/down.png new file mode 100644 index 0000000..b84dbd5 Binary files /dev/null and b/Assets/Fungus/EditorResources/Icons/Pro/down.png differ diff --git a/Assets/Fungus/EditorResources/Icons/Pro/down.png.meta b/Assets/Fungus/EditorResources/Icons/Pro/down.png.meta new file mode 100644 index 0000000..d7096b9 --- /dev/null +++ b/Assets/Fungus/EditorResources/Icons/Pro/down.png.meta @@ -0,0 +1,59 @@ +fileFormatVersion: 2 +guid: 5a87a7d3683164a238377d948572805f +timeCreated: 1478502692 +licenseType: Store +TextureImporter: + fileIDToRecycleName: {} + serializedVersion: 2 + mipmaps: + mipMapMode: 0 + enableMipMap: 0 + linearTexture: 1 + correctGamma: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + grayScaleToAlpha: 0 + generateCubemap: 0 + cubemapConvolution: 0 + cubemapConvolutionSteps: 7 + cubemapConvolutionExponent: 1.5 + seamlessCubemap: 0 + textureFormat: -3 + maxTextureSize: 2048 + textureSettings: + filterMode: -1 + aniso: 1 + mipBias: -1 + wrapMode: 1 + nPOTScale: 0 + lightmap: 0 + rGBM: 0 + compressionQuality: 50 + allowsAlphaSplitting: 0 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spritePixelsToUnits: 100 + alphaIsTransparency: 1 + spriteTessellationDetail: -1 + textureType: 2 + buildTargetSettings: [] + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + spritePackingTag: + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/EditorResources/Icons/Pro/duplicate.png b/Assets/Fungus/EditorResources/Icons/Pro/duplicate.png new file mode 100644 index 0000000..7a36f57 Binary files /dev/null and b/Assets/Fungus/EditorResources/Icons/Pro/duplicate.png differ diff --git a/Assets/Fungus/EditorResources/Icons/Pro/duplicate.png.meta b/Assets/Fungus/EditorResources/Icons/Pro/duplicate.png.meta new file mode 100644 index 0000000..4bff8d7 --- /dev/null +++ b/Assets/Fungus/EditorResources/Icons/Pro/duplicate.png.meta @@ -0,0 +1,59 @@ +fileFormatVersion: 2 +guid: 2f17490d993c84bd7872ef6588ffba47 +timeCreated: 1478502692 +licenseType: Store +TextureImporter: + fileIDToRecycleName: {} + serializedVersion: 2 + mipmaps: + mipMapMode: 0 + enableMipMap: 0 + linearTexture: 1 + correctGamma: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + grayScaleToAlpha: 0 + generateCubemap: 0 + cubemapConvolution: 0 + cubemapConvolutionSteps: 7 + cubemapConvolutionExponent: 1.5 + seamlessCubemap: 0 + textureFormat: -3 + maxTextureSize: 2048 + textureSettings: + filterMode: -1 + aniso: 1 + mipBias: -1 + wrapMode: 1 + nPOTScale: 0 + lightmap: 0 + rGBM: 0 + compressionQuality: 50 + allowsAlphaSplitting: 0 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spritePixelsToUnits: 100 + alphaIsTransparency: 1 + spriteTessellationDetail: -1 + textureType: 2 + buildTargetSettings: [] + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + spritePackingTag: + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/EditorResources/Icons/Pro/fungus_mushroom.png b/Assets/Fungus/EditorResources/Icons/Pro/fungus_mushroom.png new file mode 100644 index 0000000..ab22ce9 Binary files /dev/null and b/Assets/Fungus/EditorResources/Icons/Pro/fungus_mushroom.png differ diff --git a/Assets/Fungus/EditorResources/Icons/Pro/fungus_mushroom.png.meta b/Assets/Fungus/EditorResources/Icons/Pro/fungus_mushroom.png.meta new file mode 100644 index 0000000..59db87a --- /dev/null +++ b/Assets/Fungus/EditorResources/Icons/Pro/fungus_mushroom.png.meta @@ -0,0 +1,92 @@ +fileFormatVersion: 2 +guid: 6368c1c16ebb1694091262337e4f8c44 +timeCreated: 1500456217 +licenseType: Store +TextureImporter: + fileIDToRecycleName: {} + serializedVersion: 4 + mipmaps: + mipMapMode: 0 + enableMipMap: 0 + sRGBTexture: 0 + linearTexture: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: 1 + maxTextureSize: 2048 + textureSettings: + filterMode: 1 + aniso: -1 + mipBias: -1 + wrapMode: 1 + nPOTScale: 0 + lightmap: 0 + compressionQuality: 50 + spriteMode: 1 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spritePixelsToUnits: 100 + alphaUsage: 1 + alphaIsTransparency: 1 + spriteTessellationDetail: -1 + textureType: 2 + textureShape: 1 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + platformSettings: + - buildTarget: DefaultTexturePlatform + maxTextureSize: 1024 + textureFormat: -1 + textureCompression: 0 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + - buildTarget: Standalone + maxTextureSize: 1024 + textureFormat: -1 + textureCompression: 0 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + - buildTarget: Android + maxTextureSize: 1024 + textureFormat: -1 + textureCompression: 0 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + - buildTarget: WebGL + maxTextureSize: 1024 + textureFormat: -1 + textureCompression: 0 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + spritePackingTag: + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/EditorResources/Icons/Pro/up.png b/Assets/Fungus/EditorResources/Icons/Pro/up.png new file mode 100644 index 0000000..e88161c Binary files /dev/null and b/Assets/Fungus/EditorResources/Icons/Pro/up.png differ diff --git a/Assets/Fungus/EditorResources/Icons/Pro/up.png.meta b/Assets/Fungus/EditorResources/Icons/Pro/up.png.meta new file mode 100644 index 0000000..bccae0c --- /dev/null +++ b/Assets/Fungus/EditorResources/Icons/Pro/up.png.meta @@ -0,0 +1,59 @@ +fileFormatVersion: 2 +guid: 2a76a781db2994b33b83cd84b8835da7 +timeCreated: 1478502692 +licenseType: Store +TextureImporter: + fileIDToRecycleName: {} + serializedVersion: 2 + mipmaps: + mipMapMode: 0 + enableMipMap: 0 + linearTexture: 1 + correctGamma: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + grayScaleToAlpha: 0 + generateCubemap: 0 + cubemapConvolution: 0 + cubemapConvolutionSteps: 7 + cubemapConvolutionExponent: 1.5 + seamlessCubemap: 0 + textureFormat: -3 + maxTextureSize: 2048 + textureSettings: + filterMode: -1 + aniso: 1 + mipBias: -1 + wrapMode: 1 + nPOTScale: 0 + lightmap: 0 + rGBM: 0 + compressionQuality: 50 + allowsAlphaSplitting: 0 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spritePixelsToUnits: 100 + alphaIsTransparency: 1 + spriteTessellationDetail: -1 + textureType: 2 + buildTargetSettings: [] + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + spritePackingTag: + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/EditorResources/Icons/add.png b/Assets/Fungus/EditorResources/Icons/add.png new file mode 100644 index 0000000..b53da01 Binary files /dev/null and b/Assets/Fungus/EditorResources/Icons/add.png differ diff --git a/Assets/Fungus/EditorResources/Icons/add.png.meta b/Assets/Fungus/EditorResources/Icons/add.png.meta new file mode 100644 index 0000000..9e3f7df --- /dev/null +++ b/Assets/Fungus/EditorResources/Icons/add.png.meta @@ -0,0 +1,53 @@ +fileFormatVersion: 2 +guid: 24a867d6b4cdda04cb3aa3350f9ec7d0 +TextureImporter: + fileIDToRecycleName: {} + serializedVersion: 2 + mipmaps: + mipMapMode: 0 + enableMipMap: 0 + linearTexture: 1 + correctGamma: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: .25 + normalMapFilter: 0 + isReadable: 0 + grayScaleToAlpha: 0 + generateCubemap: 0 + cubemapConvolution: 0 + cubemapConvolutionSteps: 8 + cubemapConvolutionExponent: 1.5 + seamlessCubemap: 0 + textureFormat: -3 + maxTextureSize: 1024 + textureSettings: + filterMode: -1 + aniso: 1 + mipBias: -1 + wrapMode: 1 + nPOTScale: 0 + lightmap: 0 + rGBM: 0 + compressionQuality: 50 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: .5, y: .5} + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spritePixelsToUnits: 100 + alphaIsTransparency: 1 + textureType: 2 + buildTargetSettings: [] + spriteSheet: + sprites: [] + spritePackingTag: + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/EditorResources/Icons/add_small.png b/Assets/Fungus/EditorResources/Icons/add_small.png new file mode 100644 index 0000000..bd4e001 Binary files /dev/null and b/Assets/Fungus/EditorResources/Icons/add_small.png differ diff --git a/Assets/Fungus/EditorResources/Icons/add_small.png.meta b/Assets/Fungus/EditorResources/Icons/add_small.png.meta new file mode 100644 index 0000000..caa837c --- /dev/null +++ b/Assets/Fungus/EditorResources/Icons/add_small.png.meta @@ -0,0 +1,55 @@ +fileFormatVersion: 2 +guid: 288aff1a0e5c14fd3a0039d24149df73 +timeCreated: 1434110599 +licenseType: Store +TextureImporter: + fileIDToRecycleName: {} + serializedVersion: 2 + mipmaps: + mipMapMode: 0 + enableMipMap: 0 + linearTexture: 1 + correctGamma: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: .25 + normalMapFilter: 0 + isReadable: 0 + grayScaleToAlpha: 0 + generateCubemap: 0 + cubemapConvolution: 0 + cubemapConvolutionSteps: 8 + cubemapConvolutionExponent: 1.5 + seamlessCubemap: 0 + textureFormat: -3 + maxTextureSize: 2048 + textureSettings: + filterMode: -1 + aniso: 1 + mipBias: -1 + wrapMode: 1 + nPOTScale: 0 + lightmap: 0 + rGBM: 0 + compressionQuality: 50 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: .5, y: .5} + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spritePixelsToUnits: 100 + alphaIsTransparency: 1 + textureType: 2 + buildTargetSettings: [] + spriteSheet: + sprites: [] + spritePackingTag: + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/EditorResources/Icons/delete.png b/Assets/Fungus/EditorResources/Icons/delete.png new file mode 100644 index 0000000..12aa318 Binary files /dev/null and b/Assets/Fungus/EditorResources/Icons/delete.png differ diff --git a/Assets/Fungus/EditorResources/Icons/delete.png.meta b/Assets/Fungus/EditorResources/Icons/delete.png.meta new file mode 100644 index 0000000..540f115 --- /dev/null +++ b/Assets/Fungus/EditorResources/Icons/delete.png.meta @@ -0,0 +1,53 @@ +fileFormatVersion: 2 +guid: d6fc8a97e8a5b0947a49b780f787e504 +TextureImporter: + fileIDToRecycleName: {} + serializedVersion: 2 + mipmaps: + mipMapMode: 0 + enableMipMap: 0 + linearTexture: 1 + correctGamma: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: .25 + normalMapFilter: 0 + isReadable: 0 + grayScaleToAlpha: 0 + generateCubemap: 0 + cubemapConvolution: 0 + cubemapConvolutionSteps: 8 + cubemapConvolutionExponent: 1.5 + seamlessCubemap: 0 + textureFormat: -3 + maxTextureSize: 1024 + textureSettings: + filterMode: -1 + aniso: 1 + mipBias: -1 + wrapMode: 1 + nPOTScale: 0 + lightmap: 0 + rGBM: 0 + compressionQuality: 50 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: .5, y: .5} + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spritePixelsToUnits: 100 + alphaIsTransparency: 1 + textureType: 2 + buildTargetSettings: [] + spriteSheet: + sprites: [] + spritePackingTag: + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/EditorResources/Icons/down.png b/Assets/Fungus/EditorResources/Icons/down.png new file mode 100644 index 0000000..082e3bd Binary files /dev/null and b/Assets/Fungus/EditorResources/Icons/down.png differ diff --git a/Assets/Fungus/EditorResources/Icons/down.png.meta b/Assets/Fungus/EditorResources/Icons/down.png.meta new file mode 100644 index 0000000..86e4046 --- /dev/null +++ b/Assets/Fungus/EditorResources/Icons/down.png.meta @@ -0,0 +1,53 @@ +fileFormatVersion: 2 +guid: 51a973f446c2e664582861480cce6215 +TextureImporter: + fileIDToRecycleName: {} + serializedVersion: 2 + mipmaps: + mipMapMode: 0 + enableMipMap: 0 + linearTexture: 1 + correctGamma: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: .25 + normalMapFilter: 0 + isReadable: 0 + grayScaleToAlpha: 0 + generateCubemap: 0 + cubemapConvolution: 0 + cubemapConvolutionSteps: 8 + cubemapConvolutionExponent: 1.5 + seamlessCubemap: 0 + textureFormat: -3 + maxTextureSize: 1024 + textureSettings: + filterMode: -1 + aniso: 1 + mipBias: -1 + wrapMode: 1 + nPOTScale: 0 + lightmap: 0 + rGBM: 0 + compressionQuality: 50 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: .5, y: .5} + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spritePixelsToUnits: 100 + alphaIsTransparency: 1 + textureType: 2 + buildTargetSettings: [] + spriteSheet: + sprites: [] + spritePackingTag: + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/EditorResources/Icons/duplicate.png b/Assets/Fungus/EditorResources/Icons/duplicate.png new file mode 100644 index 0000000..19fdf96 Binary files /dev/null and b/Assets/Fungus/EditorResources/Icons/duplicate.png differ diff --git a/Assets/Fungus/EditorResources/Icons/duplicate.png.meta b/Assets/Fungus/EditorResources/Icons/duplicate.png.meta new file mode 100644 index 0000000..9be12c7 --- /dev/null +++ b/Assets/Fungus/EditorResources/Icons/duplicate.png.meta @@ -0,0 +1,53 @@ +fileFormatVersion: 2 +guid: c97f334c466215a4f93eff31de3c1591 +TextureImporter: + fileIDToRecycleName: {} + serializedVersion: 2 + mipmaps: + mipMapMode: 0 + enableMipMap: 0 + linearTexture: 1 + correctGamma: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: .25 + normalMapFilter: 0 + isReadable: 0 + grayScaleToAlpha: 0 + generateCubemap: 0 + cubemapConvolution: 0 + cubemapConvolutionSteps: 8 + cubemapConvolutionExponent: 1.5 + seamlessCubemap: 0 + textureFormat: -3 + maxTextureSize: 1024 + textureSettings: + filterMode: -1 + aniso: 1 + mipBias: -1 + wrapMode: 1 + nPOTScale: 0 + lightmap: 0 + rGBM: 0 + compressionQuality: 50 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: .5, y: .5} + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spritePixelsToUnits: 100 + alphaIsTransparency: 1 + textureType: 2 + buildTargetSettings: [] + spriteSheet: + sprites: [] + spritePackingTag: + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/EditorResources/Icons/fungus_mushroom.png b/Assets/Fungus/EditorResources/Icons/fungus_mushroom.png new file mode 100644 index 0000000..ab22ce9 Binary files /dev/null and b/Assets/Fungus/EditorResources/Icons/fungus_mushroom.png differ diff --git a/Assets/Fungus/EditorResources/Icons/fungus_mushroom.png.meta b/Assets/Fungus/EditorResources/Icons/fungus_mushroom.png.meta new file mode 100644 index 0000000..8125461 --- /dev/null +++ b/Assets/Fungus/EditorResources/Icons/fungus_mushroom.png.meta @@ -0,0 +1,92 @@ +fileFormatVersion: 2 +guid: 1c99c9bf7557e23469ed5dfce00504c0 +timeCreated: 1500455974 +licenseType: Store +TextureImporter: + fileIDToRecycleName: {} + serializedVersion: 4 + mipmaps: + mipMapMode: 0 + enableMipMap: 0 + sRGBTexture: 0 + linearTexture: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: 1 + maxTextureSize: 2048 + textureSettings: + filterMode: 1 + aniso: -1 + mipBias: -1 + wrapMode: 1 + nPOTScale: 0 + lightmap: 0 + compressionQuality: 50 + spriteMode: 1 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spritePixelsToUnits: 100 + alphaUsage: 1 + alphaIsTransparency: 1 + spriteTessellationDetail: -1 + textureType: 2 + textureShape: 1 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + platformSettings: + - buildTarget: DefaultTexturePlatform + maxTextureSize: 1024 + textureFormat: -1 + textureCompression: 0 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + - buildTarget: Standalone + maxTextureSize: 1024 + textureFormat: -1 + textureCompression: 0 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + - buildTarget: Android + maxTextureSize: 1024 + textureFormat: -1 + textureCompression: 0 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + - buildTarget: WebGL + maxTextureSize: 1024 + textureFormat: -1 + textureCompression: 0 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + spritePackingTag: + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/EditorResources/Icons/up.png b/Assets/Fungus/EditorResources/Icons/up.png new file mode 100644 index 0000000..031add3 Binary files /dev/null and b/Assets/Fungus/EditorResources/Icons/up.png differ diff --git a/Assets/Fungus/EditorResources/Icons/up.png.meta b/Assets/Fungus/EditorResources/Icons/up.png.meta new file mode 100644 index 0000000..0a7f9f8 --- /dev/null +++ b/Assets/Fungus/EditorResources/Icons/up.png.meta @@ -0,0 +1,53 @@ +fileFormatVersion: 2 +guid: 8f1242ad894201f43b2b6d52fd990f77 +TextureImporter: + fileIDToRecycleName: {} + serializedVersion: 2 + mipmaps: + mipMapMode: 0 + enableMipMap: 0 + linearTexture: 1 + correctGamma: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: .25 + normalMapFilter: 0 + isReadable: 0 + grayScaleToAlpha: 0 + generateCubemap: 0 + cubemapConvolution: 0 + cubemapConvolutionSteps: 8 + cubemapConvolutionExponent: 1.5 + seamlessCubemap: 0 + textureFormat: -3 + maxTextureSize: 1024 + textureSettings: + filterMode: -1 + aniso: 1 + mipBias: -1 + wrapMode: 1 + nPOTScale: 0 + lightmap: 0 + rGBM: 0 + compressionQuality: 50 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: .5, y: .5} + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spritePixelsToUnits: 100 + alphaIsTransparency: 1 + textureType: 2 + buildTargetSettings: [] + spriteSheet: + sprites: [] + spritePackingTag: + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/EditorResources/Textures.meta b/Assets/Fungus/EditorResources/Textures.meta new file mode 100644 index 0000000..5e36a48 --- /dev/null +++ b/Assets/Fungus/EditorResources/Textures.meta @@ -0,0 +1,9 @@ +fileFormatVersion: 2 +guid: ad80fa4e16e424c1baf05fbd3125b7fa +folderAsset: yes +timeCreated: 1477810347 +licenseType: Store +DefaultImporter: + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/EditorResources/Textures/bullet_point.png b/Assets/Fungus/EditorResources/Textures/bullet_point.png new file mode 100644 index 0000000..bcafc73 Binary files /dev/null and b/Assets/Fungus/EditorResources/Textures/bullet_point.png differ diff --git a/Assets/Fungus/EditorResources/Textures/bullet_point.png.meta b/Assets/Fungus/EditorResources/Textures/bullet_point.png.meta new file mode 100644 index 0000000..40ebd06 --- /dev/null +++ b/Assets/Fungus/EditorResources/Textures/bullet_point.png.meta @@ -0,0 +1,55 @@ +fileFormatVersion: 2 +guid: 4ef739c68bb234717a60a2bb83ff8602 +timeCreated: 1479950896 +licenseType: Store +TextureImporter: + fileIDToRecycleName: {} + serializedVersion: 2 + mipmaps: + mipMapMode: 0 + enableMipMap: 0 + linearTexture: 1 + correctGamma: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: .25 + normalMapFilter: 0 + isReadable: 0 + grayScaleToAlpha: 0 + generateCubemap: 0 + cubemapConvolution: 0 + cubemapConvolutionSteps: 7 + cubemapConvolutionExponent: 1.5 + seamlessCubemap: 0 + textureFormat: -3 + maxTextureSize: 2048 + textureSettings: + filterMode: 0 + aniso: 1 + mipBias: -1 + wrapMode: 1 + nPOTScale: 0 + lightmap: 0 + rGBM: 0 + compressionQuality: 50 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: .5, y: .5} + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spritePixelsToUnits: 100 + alphaIsTransparency: 1 + textureType: 2 + buildTargetSettings: [] + spriteSheet: + sprites: [] + spritePackingTag: + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/EditorResources/Textures/choice_node_off.png b/Assets/Fungus/EditorResources/Textures/choice_node_off.png new file mode 100644 index 0000000..9be699d Binary files /dev/null and b/Assets/Fungus/EditorResources/Textures/choice_node_off.png differ diff --git a/Assets/Fungus/EditorResources/Textures/choice_node_off.png.meta b/Assets/Fungus/EditorResources/Textures/choice_node_off.png.meta new file mode 100644 index 0000000..78fed83 --- /dev/null +++ b/Assets/Fungus/EditorResources/Textures/choice_node_off.png.meta @@ -0,0 +1,59 @@ +fileFormatVersion: 2 +guid: 7b6fc04aac74540e39e9502da5312ce7 +timeCreated: 1477811818 +licenseType: Store +TextureImporter: + fileIDToRecycleName: {} + serializedVersion: 2 + mipmaps: + mipMapMode: 0 + enableMipMap: 0 + linearTexture: 1 + correctGamma: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + grayScaleToAlpha: 0 + generateCubemap: 0 + cubemapConvolution: 0 + cubemapConvolutionSteps: 7 + cubemapConvolutionExponent: 1.5 + seamlessCubemap: 0 + textureFormat: -3 + maxTextureSize: 2048 + textureSettings: + filterMode: 0 + aniso: 1 + mipBias: -1 + wrapMode: 1 + nPOTScale: 0 + lightmap: 0 + rGBM: 0 + compressionQuality: 50 + allowsAlphaSplitting: 0 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spritePixelsToUnits: 100 + alphaIsTransparency: 1 + spriteTessellationDetail: -1 + textureType: 2 + buildTargetSettings: [] + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + spritePackingTag: + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/EditorResources/Textures/choice_node_on.png b/Assets/Fungus/EditorResources/Textures/choice_node_on.png new file mode 100644 index 0000000..a41445f Binary files /dev/null and b/Assets/Fungus/EditorResources/Textures/choice_node_on.png differ diff --git a/Assets/Fungus/EditorResources/Textures/choice_node_on.png.meta b/Assets/Fungus/EditorResources/Textures/choice_node_on.png.meta new file mode 100644 index 0000000..9ea0157 --- /dev/null +++ b/Assets/Fungus/EditorResources/Textures/choice_node_on.png.meta @@ -0,0 +1,59 @@ +fileFormatVersion: 2 +guid: cfc05494b71a0446182868aab5f7febf +timeCreated: 1477811867 +licenseType: Store +TextureImporter: + fileIDToRecycleName: {} + serializedVersion: 2 + mipmaps: + mipMapMode: 0 + enableMipMap: 0 + linearTexture: 1 + correctGamma: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + grayScaleToAlpha: 0 + generateCubemap: 0 + cubemapConvolution: 0 + cubemapConvolutionSteps: 7 + cubemapConvolutionExponent: 1.5 + seamlessCubemap: 0 + textureFormat: -3 + maxTextureSize: 2048 + textureSettings: + filterMode: 0 + aniso: 1 + mipBias: -1 + wrapMode: 1 + nPOTScale: 0 + lightmap: 0 + rGBM: 0 + compressionQuality: 50 + allowsAlphaSplitting: 0 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spritePixelsToUnits: 100 + alphaIsTransparency: 1 + spriteTessellationDetail: -1 + textureType: 2 + buildTargetSettings: [] + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + spritePackingTag: + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/EditorResources/Textures/command_background.png b/Assets/Fungus/EditorResources/Textures/command_background.png new file mode 100644 index 0000000..23017f5 Binary files /dev/null and b/Assets/Fungus/EditorResources/Textures/command_background.png differ diff --git a/Assets/Fungus/EditorResources/Textures/command_background.png.meta b/Assets/Fungus/EditorResources/Textures/command_background.png.meta new file mode 100644 index 0000000..12ce26d --- /dev/null +++ b/Assets/Fungus/EditorResources/Textures/command_background.png.meta @@ -0,0 +1,59 @@ +fileFormatVersion: 2 +guid: a5c9a4271b3de4e4f86eff7f8a1bd768 +timeCreated: 1477809339 +licenseType: Store +TextureImporter: + fileIDToRecycleName: {} + serializedVersion: 2 + mipmaps: + mipMapMode: 0 + enableMipMap: 0 + linearTexture: 1 + correctGamma: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + grayScaleToAlpha: 0 + generateCubemap: 0 + cubemapConvolution: 0 + cubemapConvolutionSteps: 7 + cubemapConvolutionExponent: 1.5 + seamlessCubemap: 0 + textureFormat: -3 + maxTextureSize: 2048 + textureSettings: + filterMode: 0 + aniso: 1 + mipBias: -1 + wrapMode: 1 + nPOTScale: 0 + lightmap: 0 + rGBM: 0 + compressionQuality: 50 + allowsAlphaSplitting: 0 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spritePixelsToUnits: 100 + alphaIsTransparency: 1 + spriteTessellationDetail: -1 + textureType: 2 + buildTargetSettings: [] + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + spritePackingTag: + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/EditorResources/Textures/connection_point.png b/Assets/Fungus/EditorResources/Textures/connection_point.png new file mode 100644 index 0000000..5a6719e Binary files /dev/null and b/Assets/Fungus/EditorResources/Textures/connection_point.png differ diff --git a/Assets/Fungus/EditorResources/Textures/connection_point.png.meta b/Assets/Fungus/EditorResources/Textures/connection_point.png.meta new file mode 100644 index 0000000..b6e7ddf --- /dev/null +++ b/Assets/Fungus/EditorResources/Textures/connection_point.png.meta @@ -0,0 +1,59 @@ +fileFormatVersion: 2 +guid: f08a4c27d7efe4aa6a35348a4e8aec8f +timeCreated: 1478932274 +licenseType: Store +TextureImporter: + fileIDToRecycleName: {} + serializedVersion: 2 + mipmaps: + mipMapMode: 0 + enableMipMap: 0 + linearTexture: 1 + correctGamma: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + grayScaleToAlpha: 0 + generateCubemap: 0 + cubemapConvolution: 0 + cubemapConvolutionSteps: 7 + cubemapConvolutionExponent: 1.5 + seamlessCubemap: 0 + textureFormat: -3 + maxTextureSize: 2048 + textureSettings: + filterMode: -1 + aniso: 1 + mipBias: -1 + wrapMode: 1 + nPOTScale: 0 + lightmap: 0 + rGBM: 0 + compressionQuality: 50 + allowsAlphaSplitting: 0 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spritePixelsToUnits: 100 + alphaIsTransparency: 1 + spriteTessellationDetail: -1 + textureType: 2 + buildTargetSettings: [] + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + spritePackingTag: + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/EditorResources/Textures/event_node_off.png b/Assets/Fungus/EditorResources/Textures/event_node_off.png new file mode 100644 index 0000000..cc1379e Binary files /dev/null and b/Assets/Fungus/EditorResources/Textures/event_node_off.png differ diff --git a/Assets/Fungus/EditorResources/Textures/event_node_off.png.meta b/Assets/Fungus/EditorResources/Textures/event_node_off.png.meta new file mode 100644 index 0000000..d5a7072 --- /dev/null +++ b/Assets/Fungus/EditorResources/Textures/event_node_off.png.meta @@ -0,0 +1,59 @@ +fileFormatVersion: 2 +guid: 0e16a209826864df7b05f6d3901aae7a +timeCreated: 1477810004 +licenseType: Store +TextureImporter: + fileIDToRecycleName: {} + serializedVersion: 2 + mipmaps: + mipMapMode: 0 + enableMipMap: 0 + linearTexture: 1 + correctGamma: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + grayScaleToAlpha: 0 + generateCubemap: 0 + cubemapConvolution: 0 + cubemapConvolutionSteps: 7 + cubemapConvolutionExponent: 1.5 + seamlessCubemap: 0 + textureFormat: -3 + maxTextureSize: 2048 + textureSettings: + filterMode: 0 + aniso: 1 + mipBias: -1 + wrapMode: 1 + nPOTScale: 0 + lightmap: 0 + rGBM: 0 + compressionQuality: 50 + allowsAlphaSplitting: 0 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spritePixelsToUnits: 100 + alphaIsTransparency: 1 + spriteTessellationDetail: -1 + textureType: 2 + buildTargetSettings: [] + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + spritePackingTag: + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/EditorResources/Textures/event_node_on.png b/Assets/Fungus/EditorResources/Textures/event_node_on.png new file mode 100644 index 0000000..23e997c Binary files /dev/null and b/Assets/Fungus/EditorResources/Textures/event_node_on.png differ diff --git a/Assets/Fungus/EditorResources/Textures/event_node_on.png.meta b/Assets/Fungus/EditorResources/Textures/event_node_on.png.meta new file mode 100644 index 0000000..6ff088a --- /dev/null +++ b/Assets/Fungus/EditorResources/Textures/event_node_on.png.meta @@ -0,0 +1,59 @@ +fileFormatVersion: 2 +guid: 9434488a4efb54da5986eba5d5619baf +timeCreated: 1477809339 +licenseType: Store +TextureImporter: + fileIDToRecycleName: {} + serializedVersion: 2 + mipmaps: + mipMapMode: 0 + enableMipMap: 0 + linearTexture: 1 + correctGamma: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + grayScaleToAlpha: 0 + generateCubemap: 0 + cubemapConvolution: 0 + cubemapConvolutionSteps: 7 + cubemapConvolutionExponent: 1.5 + seamlessCubemap: 0 + textureFormat: -3 + maxTextureSize: 2048 + textureSettings: + filterMode: 0 + aniso: 1 + mipBias: -1 + wrapMode: 1 + nPOTScale: 0 + lightmap: 0 + rGBM: 0 + compressionQuality: 50 + allowsAlphaSplitting: 0 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spritePixelsToUnits: 100 + alphaIsTransparency: 1 + spriteTessellationDetail: -1 + textureType: 2 + buildTargetSettings: [] + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + spritePackingTag: + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/EditorResources/Textures/play_big.png b/Assets/Fungus/EditorResources/Textures/play_big.png new file mode 100644 index 0000000..6987c7a Binary files /dev/null and b/Assets/Fungus/EditorResources/Textures/play_big.png differ diff --git a/Assets/Fungus/EditorResources/Textures/play_big.png.meta b/Assets/Fungus/EditorResources/Textures/play_big.png.meta new file mode 100644 index 0000000..dd72d1e --- /dev/null +++ b/Assets/Fungus/EditorResources/Textures/play_big.png.meta @@ -0,0 +1,59 @@ +fileFormatVersion: 2 +guid: bff2ba39f5f4448589e80522ebfcd0a0 +timeCreated: 1477809339 +licenseType: Store +TextureImporter: + fileIDToRecycleName: {} + serializedVersion: 2 + mipmaps: + mipMapMode: 0 + enableMipMap: 0 + linearTexture: 1 + correctGamma: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + grayScaleToAlpha: 0 + generateCubemap: 0 + cubemapConvolution: 0 + cubemapConvolutionSteps: 7 + cubemapConvolutionExponent: 1.5 + seamlessCubemap: 0 + textureFormat: -3 + maxTextureSize: 2048 + textureSettings: + filterMode: 0 + aniso: 1 + mipBias: -1 + wrapMode: 1 + nPOTScale: 0 + lightmap: 0 + rGBM: 0 + compressionQuality: 50 + allowsAlphaSplitting: 0 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spritePixelsToUnits: 100 + alphaIsTransparency: 1 + spriteTessellationDetail: -1 + textureType: 2 + buildTargetSettings: [] + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + spritePackingTag: + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/EditorResources/Textures/play_small.png b/Assets/Fungus/EditorResources/Textures/play_small.png new file mode 100644 index 0000000..781d267 Binary files /dev/null and b/Assets/Fungus/EditorResources/Textures/play_small.png differ diff --git a/Assets/Fungus/EditorResources/Textures/play_small.png.meta b/Assets/Fungus/EditorResources/Textures/play_small.png.meta new file mode 100644 index 0000000..03724e2 --- /dev/null +++ b/Assets/Fungus/EditorResources/Textures/play_small.png.meta @@ -0,0 +1,59 @@ +fileFormatVersion: 2 +guid: a48a2b9b06deb469d9da1777b094521b +timeCreated: 1477809339 +licenseType: Store +TextureImporter: + fileIDToRecycleName: {} + serializedVersion: 2 + mipmaps: + mipMapMode: 0 + enableMipMap: 0 + linearTexture: 1 + correctGamma: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + grayScaleToAlpha: 0 + generateCubemap: 0 + cubemapConvolution: 0 + cubemapConvolutionSteps: 7 + cubemapConvolutionExponent: 1.5 + seamlessCubemap: 0 + textureFormat: -3 + maxTextureSize: 2048 + textureSettings: + filterMode: 0 + aniso: 1 + mipBias: -1 + wrapMode: 1 + nPOTScale: 0 + lightmap: 0 + rGBM: 0 + compressionQuality: 50 + allowsAlphaSplitting: 0 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spritePixelsToUnits: 100 + alphaIsTransparency: 1 + spriteTessellationDetail: -1 + textureType: 2 + buildTargetSettings: [] + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + spritePackingTag: + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/EditorResources/Textures/process_node_off.png b/Assets/Fungus/EditorResources/Textures/process_node_off.png new file mode 100644 index 0000000..a395371 Binary files /dev/null and b/Assets/Fungus/EditorResources/Textures/process_node_off.png differ diff --git a/Assets/Fungus/EditorResources/Textures/process_node_off.png.meta b/Assets/Fungus/EditorResources/Textures/process_node_off.png.meta new file mode 100644 index 0000000..7c3ca3d --- /dev/null +++ b/Assets/Fungus/EditorResources/Textures/process_node_off.png.meta @@ -0,0 +1,59 @@ +fileFormatVersion: 2 +guid: ea3a4228e6c214149bfe5c741b56ae0c +timeCreated: 1477809339 +licenseType: Store +TextureImporter: + fileIDToRecycleName: {} + serializedVersion: 2 + mipmaps: + mipMapMode: 0 + enableMipMap: 0 + linearTexture: 1 + correctGamma: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + grayScaleToAlpha: 0 + generateCubemap: 0 + cubemapConvolution: 0 + cubemapConvolutionSteps: 7 + cubemapConvolutionExponent: 1.5 + seamlessCubemap: 0 + textureFormat: -3 + maxTextureSize: 2048 + textureSettings: + filterMode: 0 + aniso: 1 + mipBias: -1 + wrapMode: 1 + nPOTScale: 0 + lightmap: 0 + rGBM: 0 + compressionQuality: 50 + allowsAlphaSplitting: 0 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spritePixelsToUnits: 100 + alphaIsTransparency: 1 + spriteTessellationDetail: -1 + textureType: 2 + buildTargetSettings: [] + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + spritePackingTag: + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/EditorResources/Textures/process_node_on.png b/Assets/Fungus/EditorResources/Textures/process_node_on.png new file mode 100644 index 0000000..426fc7f Binary files /dev/null and b/Assets/Fungus/EditorResources/Textures/process_node_on.png differ diff --git a/Assets/Fungus/EditorResources/Textures/process_node_on.png.meta b/Assets/Fungus/EditorResources/Textures/process_node_on.png.meta new file mode 100644 index 0000000..995216b --- /dev/null +++ b/Assets/Fungus/EditorResources/Textures/process_node_on.png.meta @@ -0,0 +1,59 @@ +fileFormatVersion: 2 +guid: c2dceb780784240ccbe8d3cde89f7671 +timeCreated: 1477809339 +licenseType: Store +TextureImporter: + fileIDToRecycleName: {} + serializedVersion: 2 + mipmaps: + mipMapMode: 0 + enableMipMap: 0 + linearTexture: 1 + correctGamma: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + grayScaleToAlpha: 0 + generateCubemap: 0 + cubemapConvolution: 0 + cubemapConvolutionSteps: 7 + cubemapConvolutionExponent: 1.5 + seamlessCubemap: 0 + textureFormat: -3 + maxTextureSize: 2048 + textureSettings: + filterMode: 0 + aniso: 1 + mipBias: -1 + wrapMode: 1 + nPOTScale: 0 + lightmap: 0 + rGBM: 0 + compressionQuality: 50 + allowsAlphaSplitting: 0 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spritePixelsToUnits: 100 + alphaIsTransparency: 1 + spriteTessellationDetail: -1 + textureType: 2 + buildTargetSettings: [] + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + spritePackingTag: + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Fonts.meta b/Assets/Fungus/Fonts.meta new file mode 100644 index 0000000..42a4ef0 --- /dev/null +++ b/Assets/Fungus/Fonts.meta @@ -0,0 +1,5 @@ +fileFormatVersion: 2 +guid: a316c7b38ecb7431a8e6e953b048ba66 +folderAsset: yes +DefaultImporter: + userData: diff --git a/Assets/Fungus/Fonts/Amaranth.meta b/Assets/Fungus/Fonts/Amaranth.meta new file mode 100644 index 0000000..2bd0514 --- /dev/null +++ b/Assets/Fungus/Fonts/Amaranth.meta @@ -0,0 +1,5 @@ +fileFormatVersion: 2 +guid: 617f3657eb270446596b1d50e54a600f +folderAsset: yes +DefaultImporter: + userData: diff --git a/Assets/Fungus/Fonts/Amaranth/Amaranth-Bold.otf b/Assets/Fungus/Fonts/Amaranth/Amaranth-Bold.otf new file mode 100644 index 0000000..b8b09a8 Binary files /dev/null and b/Assets/Fungus/Fonts/Amaranth/Amaranth-Bold.otf differ diff --git a/Assets/Fungus/Fonts/Amaranth/Amaranth-Bold.otf.meta b/Assets/Fungus/Fonts/Amaranth/Amaranth-Bold.otf.meta new file mode 100644 index 0000000..c928dab --- /dev/null +++ b/Assets/Fungus/Fonts/Amaranth/Amaranth-Bold.otf.meta @@ -0,0 +1,14 @@ +fileFormatVersion: 2 +guid: 64bd3e45f7a714f16b3c213f55f17fea +TrueTypeFontImporter: + serializedVersion: 2 + fontSize: 16 + forceTextureCase: -2 + characterSpacing: 1 + characterPadding: 0 + includeFontData: 1 + use2xBehaviour: 0 + fontNames: [] + customCharacters: + fontRenderingMode: 0 + userData: diff --git a/Assets/Fungus/Fonts/Amaranth/Amaranth-BoldItalic.otf b/Assets/Fungus/Fonts/Amaranth/Amaranth-BoldItalic.otf new file mode 100644 index 0000000..610667d Binary files /dev/null and b/Assets/Fungus/Fonts/Amaranth/Amaranth-BoldItalic.otf differ diff --git a/Assets/Fungus/Fonts/Amaranth/Amaranth-BoldItalic.otf.meta b/Assets/Fungus/Fonts/Amaranth/Amaranth-BoldItalic.otf.meta new file mode 100644 index 0000000..ee237e6 --- /dev/null +++ b/Assets/Fungus/Fonts/Amaranth/Amaranth-BoldItalic.otf.meta @@ -0,0 +1,14 @@ +fileFormatVersion: 2 +guid: 30083fe2d35a6490b8f1e57e0d830527 +TrueTypeFontImporter: + serializedVersion: 2 + fontSize: 16 + forceTextureCase: -2 + characterSpacing: 1 + characterPadding: 0 + includeFontData: 1 + use2xBehaviour: 0 + fontNames: [] + customCharacters: + fontRenderingMode: 0 + userData: diff --git a/Assets/Fungus/Fonts/Amaranth/Amaranth-Italic.otf b/Assets/Fungus/Fonts/Amaranth/Amaranth-Italic.otf new file mode 100644 index 0000000..2dfaca7 Binary files /dev/null and b/Assets/Fungus/Fonts/Amaranth/Amaranth-Italic.otf differ diff --git a/Assets/Fungus/Fonts/Amaranth/Amaranth-Italic.otf.meta b/Assets/Fungus/Fonts/Amaranth/Amaranth-Italic.otf.meta new file mode 100644 index 0000000..61f9cf9 --- /dev/null +++ b/Assets/Fungus/Fonts/Amaranth/Amaranth-Italic.otf.meta @@ -0,0 +1,14 @@ +fileFormatVersion: 2 +guid: b4e86052de8904394807b3f10e18a9f6 +TrueTypeFontImporter: + serializedVersion: 2 + fontSize: 16 + forceTextureCase: -2 + characterSpacing: 1 + characterPadding: 0 + includeFontData: 1 + use2xBehaviour: 0 + fontNames: [] + customCharacters: + fontRenderingMode: 0 + userData: diff --git a/Assets/Fungus/Fonts/Amaranth/Amaranth-Regular.otf b/Assets/Fungus/Fonts/Amaranth/Amaranth-Regular.otf new file mode 100644 index 0000000..22b38fd Binary files /dev/null and b/Assets/Fungus/Fonts/Amaranth/Amaranth-Regular.otf differ diff --git a/Assets/Fungus/Fonts/Amaranth/Amaranth-Regular.otf.meta b/Assets/Fungus/Fonts/Amaranth/Amaranth-Regular.otf.meta new file mode 100644 index 0000000..ee057ab --- /dev/null +++ b/Assets/Fungus/Fonts/Amaranth/Amaranth-Regular.otf.meta @@ -0,0 +1,14 @@ +fileFormatVersion: 2 +guid: bb145366ce7024469a5758b08d31802c +TrueTypeFontImporter: + serializedVersion: 2 + fontSize: 16 + forceTextureCase: -2 + characterSpacing: 1 + characterPadding: 0 + includeFontData: 1 + use2xBehaviour: 0 + fontNames: [] + customCharacters: + fontRenderingMode: 0 + userData: diff --git a/Assets/Fungus/Fonts/Amaranth/SIL Open Font License.txt b/Assets/Fungus/Fonts/Amaranth/SIL Open Font License.txt new file mode 100644 index 0000000..87b92c4 --- /dev/null +++ b/Assets/Fungus/Fonts/Amaranth/SIL Open Font License.txt @@ -0,0 +1,44 @@ +Copyright (c) 2011, Gesine Todt (hallo@gesine-todt.de), +with Reserved Font Name Amaranth. + +This Font Software is licensed under the SIL Open Font License, Version 1.1. +This license is copied below, and is also available with a FAQ at: http://scripts.sil.org/OFL + +----------------------------------------------------------- +SIL OPEN FONT LICENSE Version 1.1 - 26 February 2007 +----------------------------------------------------------- + +PREAMBLE +The goals of the Open Font License (OFL) are to stimulate worldwide development of collaborative font projects, to support the font creation efforts of academic and linguistic communities, and to provide a free and open framework in which fonts may be shared and improved in partnership with others. + +The OFL allows the licensed fonts to be used, studied, modified and redistributed freely as long as they are not sold by themselves. The fonts, including any derivative works, can be bundled, embedded, redistributed and/or sold with any software provided that any reserved names are not used by derivative works. The fonts and derivatives, however, cannot be released under any other type of license. The requirement for fonts to remain under this license does not apply to any document created using the fonts or their derivatives. + +DEFINITIONS +"Font Software" refers to the set of files released by the Copyright Holder(s) under this license and clearly marked as such. This may include source files, build scripts and documentation. + +"Reserved Font Name" refers to any names specified as such after the copyright statement(s). + +"Original Version" refers to the collection of Font Software components as distributed by the Copyright Holder(s). + +"Modified Version" refers to any derivative made by adding to, deleting, or substituting -- in part or in whole -- any of the components of the Original Version, by changing formats or by porting the Font Software to a new environment. + +"Author" refers to any designer, engineer, programmer, technical writer or other person who contributed to the Font Software. + +PERMISSION & CONDITIONS +Permission is hereby granted, free of charge, to any person obtaining a copy of the Font Software, to use, study, copy, merge, embed, modify, redistribute, and sell modified and unmodified copies of the Font Software, subject to the following conditions: + +1) Neither the Font Software nor any of its individual components, in Original or Modified Versions, may be sold by itself. + +2) Original or Modified Versions of the Font Software may be bundled, redistributed and/or sold with any software, provided that each copy contains the above copyright notice and this license. These can be included either as stand-alone text files, human-readable headers or in the appropriate machine-readable metadata fields within text or binary files as long as those fields can be easily viewed by the user. + +3) No Modified Version of the Font Software may use the Reserved Font Name(s) unless explicit written permission is granted by the corresponding Copyright Holder. This restriction only applies to the primary font name as presented to the users. + +4) The name(s) of the Copyright Holder(s) or the Author(s) of the Font Software shall not be used to promote, endorse or advertise any Modified Version, except to acknowledge the contribution(s) of the Copyright Holder(s) and the Author(s) or with their explicit written permission. + +5) The Font Software, modified or unmodified, in part or in whole, must be distributed entirely under this license, and must not be distributed under any other license. The requirement for fonts to remain under this license does not apply to any document created using the Font Software. + +TERMINATION +This license becomes null and void if any of the above conditions are not met. + +DISCLAIMER +THE FONT SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT OF COPYRIGHT, PATENT, TRADEMARK, OR OTHER RIGHT. IN NO EVENT SHALL THE COPYRIGHT HOLDER BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, INCLUDING ANY GENERAL, SPECIAL, INDIRECT, INCIDENTAL, OR CONSEQUENTIAL DAMAGES, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF THE USE OR INABILITY TO USE THE FONT SOFTWARE OR FROM OTHER DEALINGS IN THE FONT SOFTWARE. \ No newline at end of file diff --git a/Assets/Fungus/Fonts/Amaranth/SIL Open Font License.txt.meta b/Assets/Fungus/Fonts/Amaranth/SIL Open Font License.txt.meta new file mode 100644 index 0000000..fd8a662 --- /dev/null +++ b/Assets/Fungus/Fonts/Amaranth/SIL Open Font License.txt.meta @@ -0,0 +1,4 @@ +fileFormatVersion: 2 +guid: 6ae07f4b9d83d4662825fefe8ff30d45 +TextScriptImporter: + userData: diff --git a/Assets/Fungus/Fonts/Exo2.meta b/Assets/Fungus/Fonts/Exo2.meta new file mode 100644 index 0000000..67bed7d --- /dev/null +++ b/Assets/Fungus/Fonts/Exo2.meta @@ -0,0 +1,5 @@ +fileFormatVersion: 2 +guid: e3712f6aa5daa46efa690a7288358254 +folderAsset: yes +DefaultImporter: + userData: diff --git a/Assets/Fungus/Fonts/Exo2/Exo2-Bold.ttf b/Assets/Fungus/Fonts/Exo2/Exo2-Bold.ttf new file mode 100644 index 0000000..5e0913f Binary files /dev/null and b/Assets/Fungus/Fonts/Exo2/Exo2-Bold.ttf differ diff --git a/Assets/Fungus/Fonts/Exo2/Exo2-Bold.ttf.meta b/Assets/Fungus/Fonts/Exo2/Exo2-Bold.ttf.meta new file mode 100644 index 0000000..99e8ac2 --- /dev/null +++ b/Assets/Fungus/Fonts/Exo2/Exo2-Bold.ttf.meta @@ -0,0 +1,14 @@ +fileFormatVersion: 2 +guid: 38fb69338d588b64ea5f2c219db3056b +TrueTypeFontImporter: + serializedVersion: 2 + fontSize: 16 + forceTextureCase: -2 + characterSpacing: 1 + characterPadding: 0 + includeFontData: 1 + use2xBehaviour: 0 + fontNames: [] + customCharacters: + fontRenderingMode: 0 + userData: diff --git a/Assets/Fungus/Fonts/Exo2/Exo2-Regular.ttf b/Assets/Fungus/Fonts/Exo2/Exo2-Regular.ttf new file mode 100644 index 0000000..8e09f6f Binary files /dev/null and b/Assets/Fungus/Fonts/Exo2/Exo2-Regular.ttf differ diff --git a/Assets/Fungus/Fonts/Exo2/Exo2-Regular.ttf.meta b/Assets/Fungus/Fonts/Exo2/Exo2-Regular.ttf.meta new file mode 100644 index 0000000..c713bfe --- /dev/null +++ b/Assets/Fungus/Fonts/Exo2/Exo2-Regular.ttf.meta @@ -0,0 +1,14 @@ +fileFormatVersion: 2 +guid: 79197ecfbc3a4294a89ce589dac02cf2 +TrueTypeFontImporter: + serializedVersion: 2 + fontSize: 16 + forceTextureCase: -2 + characterSpacing: 1 + characterPadding: 0 + includeFontData: 1 + use2xBehaviour: 0 + fontNames: [] + customCharacters: + fontRenderingMode: 0 + userData: diff --git a/Assets/Fungus/Fonts/Exo2/OFL.txt b/Assets/Fungus/Fonts/Exo2/OFL.txt new file mode 100644 index 0000000..1456c18 --- /dev/null +++ b/Assets/Fungus/Fonts/Exo2/OFL.txt @@ -0,0 +1,97 @@ +Copyright (c) , (), +with Reserved Font Name . +Copyright (c) , (), +with Reserved Font Name . +Copyright (c) , (). + +This Font Software is licensed under the SIL Open Font License, Version 1.1. +This license is copied below, and is also available with a FAQ at: +http://scripts.sil.org/OFL + + +----------------------------------------------------------- +SIL OPEN FONT LICENSE Version 1.1 - 26 February 2007 +----------------------------------------------------------- + +PREAMBLE +The goals of the Open Font License (OFL) are to stimulate worldwide +development of collaborative font projects, to support the font creation +efforts of academic and linguistic communities, and to provide a free and +open framework in which fonts may be shared and improved in partnership +with others. + +The OFL allows the licensed fonts to be used, studied, modified and +redistributed freely as long as they are not sold by themselves. The +fonts, including any derivative works, can be bundled, embedded, +redistributed and/or sold with any software provided that any reserved +names are not used by derivative works. The fonts and derivatives, +however, cannot be released under any other type of license. The +requirement for fonts to remain under this license does not apply +to any document created using the fonts or their derivatives. + +DEFINITIONS +"Font Software" refers to the set of files released by the Copyright +Holder(s) under this license and clearly marked as such. This may +include source files, build scripts and documentation. + +"Reserved Font Name" refers to any names specified as such after the +copyright statement(s). + +"Original Version" refers to the collection of Font Software components as +distributed by the Copyright Holder(s). + +"Modified Version" refers to any derivative made by adding to, deleting, +or substituting -- in part or in whole -- any of the components of the +Original Version, by changing formats or by porting the Font Software to a +new environment. + +"Author" refers to any designer, engineer, programmer, technical +writer or other person who contributed to the Font Software. + +PERMISSION & CONDITIONS +Permission is hereby granted, free of charge, to any person obtaining +a copy of the Font Software, to use, study, copy, merge, embed, modify, +redistribute, and sell modified and unmodified copies of the Font +Software, subject to the following conditions: + +1) Neither the Font Software nor any of its individual components, +in Original or Modified Versions, may be sold by itself. + +2) Original or Modified Versions of the Font Software may be bundled, +redistributed and/or sold with any software, provided that each copy +contains the above copyright notice and this license. These can be +included either as stand-alone text files, human-readable headers or +in the appropriate machine-readable metadata fields within text or +binary files as long as those fields can be easily viewed by the user. + +3) No Modified Version of the Font Software may use the Reserved Font +Name(s) unless explicit written permission is granted by the corresponding +Copyright Holder. This restriction only applies to the primary font name as +presented to the users. + +4) The name(s) of the Copyright Holder(s) or the Author(s) of the Font +Software shall not be used to promote, endorse or advertise any +Modified Version, except to acknowledge the contribution(s) of the +Copyright Holder(s) and the Author(s) or with their explicit written +permission. + +5) The Font Software, modified or unmodified, in part or in whole, +must be distributed entirely under this license, and must not be +distributed under any other license. The requirement for fonts to +remain under this license does not apply to any document created +using the Font Software. + +TERMINATION +This license becomes null and void if any of the above conditions are +not met. + +DISCLAIMER +THE FONT SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, +EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OF +MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT +OF COPYRIGHT, PATENT, TRADEMARK, OR OTHER RIGHT. IN NO EVENT SHALL THE +COPYRIGHT HOLDER BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, +INCLUDING ANY GENERAL, SPECIAL, INDIRECT, INCIDENTAL, OR CONSEQUENTIAL +DAMAGES, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING +FROM, OUT OF THE USE OR INABILITY TO USE THE FONT SOFTWARE OR FROM +OTHER DEALINGS IN THE FONT SOFTWARE. diff --git a/Assets/Fungus/Fonts/Exo2/OFL.txt.meta b/Assets/Fungus/Fonts/Exo2/OFL.txt.meta new file mode 100644 index 0000000..f2c4508 --- /dev/null +++ b/Assets/Fungus/Fonts/Exo2/OFL.txt.meta @@ -0,0 +1,4 @@ +fileFormatVersion: 2 +guid: 7d156fd4f9c8d4276bddbf2e3c0e820b +TextScriptImporter: + userData: diff --git a/Assets/Fungus/Fungus.asmdef b/Assets/Fungus/Fungus.asmdef new file mode 100644 index 0000000..3c6ad2a --- /dev/null +++ b/Assets/Fungus/Fungus.asmdef @@ -0,0 +1,15 @@ +{ + "name": "Fungus", + "references": [ + "GUID:6055be8ebefd69e48b49212b09b47b2f" + ], + "optionalUnityReferences": [], + "includePlatforms": [], + "excludePlatforms": [], + "allowUnsafeCode": false, + "overrideReferences": false, + "precompiledReferences": [], + "autoReferenced": true, + "defineConstraints": [], + "versionDefines": [] +} \ No newline at end of file diff --git a/Assets/Fungus/Fungus.asmdef.meta b/Assets/Fungus/Fungus.asmdef.meta new file mode 100644 index 0000000..a0675e2 --- /dev/null +++ b/Assets/Fungus/Fungus.asmdef.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: 007db7f7a4c8f944990d71603a110f82 +AssemblyDefinitionImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Integrations.meta b/Assets/Fungus/Integrations.meta new file mode 100644 index 0000000..2189419 --- /dev/null +++ b/Assets/Fungus/Integrations.meta @@ -0,0 +1,9 @@ +fileFormatVersion: 2 +guid: 441eed542dc8247b39df32118724f695 +folderAsset: yes +timeCreated: 1453725747 +licenseType: Store +DefaultImporter: + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Integrations/Playmaker.meta b/Assets/Fungus/Integrations/Playmaker.meta new file mode 100644 index 0000000..6ccbf14 --- /dev/null +++ b/Assets/Fungus/Integrations/Playmaker.meta @@ -0,0 +1,9 @@ +fileFormatVersion: 2 +guid: f24b15e84ed1f42e39fd80dd9042c882 +folderAsset: yes +timeCreated: 1489513669 +licenseType: Store +DefaultImporter: + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Integrations/Playmaker/Fungus-PlayMaker.unitypackage.meta b/Assets/Fungus/Integrations/Playmaker/Fungus-PlayMaker.unitypackage.meta new file mode 100644 index 0000000..eb79187 --- /dev/null +++ b/Assets/Fungus/Integrations/Playmaker/Fungus-PlayMaker.unitypackage.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 81dbcde0f90df4e9ba9ca2794490e57a +timeCreated: 1491251885 +licenseType: Store +DefaultImporter: + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Integrations/Playmaker/ReadMe.txt b/Assets/Fungus/Integrations/Playmaker/ReadMe.txt new file mode 100644 index 0000000..95a395b --- /dev/null +++ b/Assets/Fungus/Integrations/Playmaker/ReadMe.txt @@ -0,0 +1,25 @@ +Playmaker +============ +Playmaker is a Finite State Machine plugin for Unity that allows developers to create games using a visual scripting methodology that does away with writing code in a manner similar to Fungus. +The FSM allows the creation of various states and events for a given object that allows for the wuick and easy creation of object behaviours and AI for NPCs and enemies. +By combining the Playmaker FSM with Fungus' ability to create engaging, character driven story based games, it is hoped that developers will be able to create games that combine the best features of both. + +Installation +============ + +1. Download and install the Playmaker runtime unitypackage in your Unity project +http://sites.fastspring.com/hutonggames/product/playmaker +https://www.assetstore.unity3d.com/en/#!/content/368 + +2. Install the Fungus-PlayMaker.unitypackage in your Unity project. This file is located in the same folder as this text file. + +3. Open the Fungus-PlayMaker/Scenes/Fungus Playmaker Example Scene for an example of how to use the Spine commands + +Usage +============ + +To write Playmaker variable values to Fungus Variables, use the Action Browser > ScriptControl > Write To Fungus command. +To execute a block in a Fungus flowchart from , use the Action Browser > ScriptControl > Playmaker Execute Block command. +To trigger a global state transition in Playmaker from Fungus, use the Playmaker > Global State Transition command. +To read Fungus variable values into Playmaker Variables, use the Action Browser > ScriptControl > Receive Fungus Variable command. +To write Fungus variable values from the inspector into Playmaker global variables, use the Playmaker > Write To Playmaker command. \ No newline at end of file diff --git a/Assets/Fungus/Integrations/Playmaker/ReadMe.txt.meta b/Assets/Fungus/Integrations/Playmaker/ReadMe.txt.meta new file mode 100644 index 0000000..65c441b --- /dev/null +++ b/Assets/Fungus/Integrations/Playmaker/ReadMe.txt.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 1cd4689522982464db8b5de6a590db9b +timeCreated: 1491251886 +licenseType: Store +TextScriptImporter: + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Integrations/Spine.meta b/Assets/Fungus/Integrations/Spine.meta new file mode 100644 index 0000000..1ac1889 --- /dev/null +++ b/Assets/Fungus/Integrations/Spine.meta @@ -0,0 +1,9 @@ +fileFormatVersion: 2 +guid: 86a1109db01dd4b5e98b187cea887e04 +folderAsset: yes +timeCreated: 1453725835 +licenseType: Store +DefaultImporter: + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Integrations/Spine/Fungus-Spine.unitypackage.meta b/Assets/Fungus/Integrations/Spine/Fungus-Spine.unitypackage.meta new file mode 100644 index 0000000..8af41c3 --- /dev/null +++ b/Assets/Fungus/Integrations/Spine/Fungus-Spine.unitypackage.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: fd02c799f3f5c4c83b2fc26c105a3821 +timeCreated: 1453725747 +licenseType: Store +DefaultImporter: + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Integrations/Spine/Readme.txt b/Assets/Fungus/Integrations/Spine/Readme.txt new file mode 100644 index 0000000..f5de5cd --- /dev/null +++ b/Assets/Fungus/Integrations/Spine/Readme.txt @@ -0,0 +1,18 @@ +This package contains Fungus Commands to support Spine by Esoteric Software +http://esotericsoftware.com/ + +Installation +============ + +1. Download and install the Spine runtime unitypackage in your Unity project +http://esotericsoftware.com/files/runtimes/unity/spine-unity.unitypackage + +2. Install the spine.unitypackage in your Unity project. This file is located in the same folder as this text file. + +3. Open the Fungus-Spine/Scenes/Dr Jeckle scene for an example of how to use the Spine commands + +Usage +============ + +Use the Spine > Play Spine Animation command to play an animation on a Spine object. +Use the Spine > Stop Animation command to stop a playing animation on a Spine object. diff --git a/Assets/Fungus/Integrations/Spine/Readme.txt.meta b/Assets/Fungus/Integrations/Spine/Readme.txt.meta new file mode 100644 index 0000000..c949195 --- /dev/null +++ b/Assets/Fungus/Integrations/Spine/Readme.txt.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 56e461aab09c846b6a6ac22f1514516c +timeCreated: 1453725792 +licenseType: Store +TextScriptImporter: + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Resources.meta b/Assets/Fungus/Resources.meta new file mode 100644 index 0000000..6726dc9 --- /dev/null +++ b/Assets/Fungus/Resources.meta @@ -0,0 +1,9 @@ +fileFormatVersion: 2 +guid: 6cc28e50d85784bb3bb7aa82a3091385 +folderAsset: yes +timeCreated: 1427468269 +licenseType: Store +DefaultImporter: + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Resources/Prefabs.meta b/Assets/Fungus/Resources/Prefabs.meta new file mode 100644 index 0000000..1062a6d --- /dev/null +++ b/Assets/Fungus/Resources/Prefabs.meta @@ -0,0 +1,9 @@ +fileFormatVersion: 2 +guid: fc921ee1d765948f0b788694e06b4a4a +folderAsset: yes +timeCreated: 1473780677 +licenseType: Store +DefaultImporter: + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Resources/Prefabs/AudioTag.prefab b/Assets/Fungus/Resources/Prefabs/AudioTag.prefab new file mode 100644 index 0000000..02afd71 --- /dev/null +++ b/Assets/Fungus/Resources/Prefabs/AudioTag.prefab @@ -0,0 +1,132 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!1 &177196 +GameObject: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + serializedVersion: 4 + m_Component: + - 4: {fileID: 477196} + - 114: {fileID: 11477196} + - 82: {fileID: 8249370} + m_Layer: 0 + m_Name: AudioTag + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &477196 +Transform: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 177196} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: 0.038905814, y: -4.395596, z: 0} + m_LocalScale: {x: 1, y: 1, z: 1} + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_Children: [] + m_Father: {fileID: 0} + m_RootOrder: 0 +--- !u!82 &8249370 +AudioSource: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 177196} + m_Enabled: 1 + serializedVersion: 4 + OutputAudioMixerGroup: {fileID: 0} + m_audioClip: {fileID: 0} + m_PlayOnAwake: 0 + m_Volume: 1 + m_Pitch: 1 + Loop: 0 + Mute: 0 + Spatialize: 0 + Priority: 128 + DopplerLevel: 1 + MinDistance: 1 + MaxDistance: 500 + Pan2D: 0 + rolloffMode: 0 + BypassEffects: 0 + BypassListenerEffects: 0 + BypassReverbZones: 0 + rolloffCustomCurve: + serializedVersion: 2 + m_Curve: + - time: 0 + value: 1 + inSlope: 0 + outSlope: 0 + tangentMode: 0 + - time: 1 + value: 0 + inSlope: 0 + outSlope: 0 + tangentMode: 0 + m_PreInfinity: 2 + m_PostInfinity: 2 + m_RotationOrder: 4 + panLevelCustomCurve: + serializedVersion: 2 + m_Curve: + - time: 0 + value: 1 + inSlope: 0 + outSlope: 0 + tangentMode: 0 + m_PreInfinity: 2 + m_PostInfinity: 2 + m_RotationOrder: 0 + spreadCustomCurve: + serializedVersion: 2 + m_Curve: + - time: 0 + value: 0 + inSlope: 0 + outSlope: 0 + tangentMode: 0 + m_PreInfinity: 2 + m_PostInfinity: 2 + m_RotationOrder: 4 + reverbZoneMixCustomCurve: + serializedVersion: 2 + m_Curve: + - time: 0 + value: 1 + inSlope: 0 + outSlope: 0 + tangentMode: 0 + m_PreInfinity: 2 + m_PostInfinity: 2 + m_RotationOrder: 0 +--- !u!114 &11477196 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 177196} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 335e04fbdd5260043abb299a991dcbe8, type: 3} + m_Name: + m_EditorClassIdentifier: + tagStartSymbol: '{customName}' + tagEndSymbol: '{/customName}' + replaceTagStartWith: '{audio=AudioTag}' + replaceTagEndWith: '{/audio}' +--- !u!1001 &100100000 +Prefab: + m_ObjectHideFlags: 1 + serializedVersion: 2 + m_Modification: + m_TransformParent: {fileID: 0} + m_Modifications: [] + m_RemovedComponents: [] + m_ParentPrefab: {fileID: 0} + m_RootGameObject: {fileID: 177196} + m_IsPrefabParent: 1 diff --git a/Assets/Fungus/Resources/Prefabs/AudioTag.prefab.meta b/Assets/Fungus/Resources/Prefabs/AudioTag.prefab.meta new file mode 100644 index 0000000..8013ddf --- /dev/null +++ b/Assets/Fungus/Resources/Prefabs/AudioTag.prefab.meta @@ -0,0 +1,4 @@ +fileFormatVersion: 2 +guid: 8a19432eef4e44247949edb78c590f64 +NativeFormatImporter: + userData: diff --git a/Assets/Fungus/Resources/Prefabs/Character.prefab b/Assets/Fungus/Resources/Prefabs/Character.prefab new file mode 100644 index 0000000..6f3d43f --- /dev/null +++ b/Assets/Fungus/Resources/Prefabs/Character.prefab @@ -0,0 +1,60 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!1 &100000 +GameObject: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + serializedVersion: 4 + m_Component: + - 4: {fileID: 400000} + - 114: {fileID: 11400000} + m_Layer: 0 + m_Name: Character + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &400000 +Transform: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 100000} + 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_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_Children: [] + m_Father: {fileID: 0} + m_RootOrder: 0 +--- !u!114 &11400000 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 100000} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 25fb867d2049d41f597aefdd6b19f598, type: 3} + m_Name: + m_EditorClassIdentifier: + nameText: Character Name + nameColor: {r: 1, g: 1, b: 1, a: 1} + soundEffect: {fileID: 0} + portraits: [] + portraitsFace: 0 + setSayDialog: {fileID: 0} + description: +--- !u!1001 &100100000 +Prefab: + m_ObjectHideFlags: 1 + serializedVersion: 2 + m_Modification: + m_TransformParent: {fileID: 0} + m_Modifications: [] + m_RemovedComponents: [] + m_ParentPrefab: {fileID: 0} + m_RootGameObject: {fileID: 100000} + m_IsPrefabParent: 1 diff --git a/Assets/Fungus/Resources/Prefabs/Character.prefab.meta b/Assets/Fungus/Resources/Prefabs/Character.prefab.meta new file mode 100644 index 0000000..0f1ecb9 --- /dev/null +++ b/Assets/Fungus/Resources/Prefabs/Character.prefab.meta @@ -0,0 +1,4 @@ +fileFormatVersion: 2 +guid: b20518d45890e4be59ba82946f88026c +NativeFormatImporter: + userData: diff --git a/Assets/Fungus/Resources/Prefabs/ClickableSprite.prefab b/Assets/Fungus/Resources/Prefabs/ClickableSprite.prefab new file mode 100644 index 0000000..9d8039b --- /dev/null +++ b/Assets/Fungus/Resources/Prefabs/ClickableSprite.prefab @@ -0,0 +1,105 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!1 &100000 +GameObject: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + serializedVersion: 4 + m_Component: + - 4: {fileID: 400000} + - 212: {fileID: 21200000} + - 61: {fileID: 6100000} + - 114: {fileID: 11400000} + m_Layer: 0 + m_Name: ClickableSprite + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &400000 +Transform: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 100000} + 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_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_Children: [] + m_Father: {fileID: 0} + m_RootOrder: 0 +--- !u!61 &6100000 +BoxCollider2D: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 100000} + m_Enabled: 1 + m_Density: 1 + m_Material: {fileID: 0} + m_IsTrigger: 0 + m_UsedByEffector: 0 + m_Offset: {x: 0, y: 0} + serializedVersion: 2 + m_Size: {x: 3, y: 3} +--- !u!114 &11400000 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 100000} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: cc03961113fa349c09cb06ef2911013d, type: 3} + m_Name: + m_EditorClassIdentifier: + clickEnabled: 1 + hoverCursor: {fileID: 0} + useEventSystem: 0 +--- !u!212 &21200000 +SpriteRenderer: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 100000} + m_Enabled: 1 + m_CastShadows: 0 + m_ReceiveShadows: 0 + m_MotionVectors: 1 + m_LightProbeUsage: 0 + m_ReflectionProbeUsage: 0 + m_Materials: + - {fileID: 10754, guid: 0000000000000000f000000000000000, type: 0} + m_SubsetIndices: + 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_SelectedWireframeHidden: 1 + m_MinimumChartSize: 4 + m_AutoUVMaxDistance: 0.5 + m_AutoUVMaxAngle: 89 + m_LightmapParameters: {fileID: 0} + m_SortingLayerID: 0 + m_SortingOrder: 0 + m_Sprite: {fileID: 21300000, guid: ea8f56c43254d41728f5ac4e8299b6c9, type: 3} + m_Color: {r: 1, g: 1, b: 1, a: 1} + m_FlipX: 0 + m_FlipY: 0 +--- !u!1001 &100100000 +Prefab: + m_ObjectHideFlags: 1 + serializedVersion: 2 + m_Modification: + m_TransformParent: {fileID: 0} + m_Modifications: [] + m_RemovedComponents: [] + m_ParentPrefab: {fileID: 0} + m_RootGameObject: {fileID: 100000} + m_IsPrefabParent: 1 diff --git a/Assets/Fungus/Resources/Prefabs/ClickableSprite.prefab.meta b/Assets/Fungus/Resources/Prefabs/ClickableSprite.prefab.meta new file mode 100644 index 0000000..aa41afa --- /dev/null +++ b/Assets/Fungus/Resources/Prefabs/ClickableSprite.prefab.meta @@ -0,0 +1,4 @@ +fileFormatVersion: 2 +guid: 0e6bcf37a2876432fa58eff8888bf177 +NativeFormatImporter: + userData: diff --git a/Assets/Fungus/Resources/Prefabs/DragTargetSprite.prefab b/Assets/Fungus/Resources/Prefabs/DragTargetSprite.prefab new file mode 100644 index 0000000..452249d --- /dev/null +++ b/Assets/Fungus/Resources/Prefabs/DragTargetSprite.prefab @@ -0,0 +1,90 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!1 &100000 +GameObject: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + serializedVersion: 4 + m_Component: + - 4: {fileID: 400000} + - 212: {fileID: 21200000} + - 58: {fileID: 5800000} + m_Layer: 0 + m_Name: DragTargetSprite + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &400000 +Transform: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 100000} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: -8.61, y: -4.47, z: 0} + m_LocalScale: {x: 1, y: 1, z: 1} + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_Children: [] + m_Father: {fileID: 0} + m_RootOrder: 0 +--- !u!58 &5800000 +CircleCollider2D: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 100000} + m_Enabled: 1 + m_Density: 1 + m_Material: {fileID: 0} + m_IsTrigger: 0 + m_UsedByEffector: 0 + m_Offset: {x: 0, y: 0} + serializedVersion: 2 + m_Radius: 1.5 +--- !u!212 &21200000 +SpriteRenderer: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 100000} + m_Enabled: 1 + m_CastShadows: 0 + m_ReceiveShadows: 0 + m_MotionVectors: 1 + m_LightProbeUsage: 0 + m_ReflectionProbeUsage: 0 + m_Materials: + - {fileID: 10754, guid: 0000000000000000f000000000000000, type: 0} + m_SubsetIndices: + 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_SelectedWireframeHidden: 1 + m_MinimumChartSize: 4 + m_AutoUVMaxDistance: 0.5 + m_AutoUVMaxAngle: 89 + m_LightmapParameters: {fileID: 0} + m_SortingLayerID: 0 + m_SortingOrder: 0 + m_Sprite: {fileID: 21300000, guid: ea8f56c43254d41728f5ac4e8299b6c9, type: 3} + m_Color: {r: 1, g: 1, b: 1, a: 1} + m_FlipX: 0 + m_FlipY: 0 +--- !u!1001 &100100000 +Prefab: + m_ObjectHideFlags: 1 + serializedVersion: 2 + m_Modification: + m_TransformParent: {fileID: 0} + m_Modifications: [] + m_RemovedComponents: [] + m_ParentPrefab: {fileID: 0} + m_RootGameObject: {fileID: 100000} + m_IsPrefabParent: 1 diff --git a/Assets/Fungus/Resources/Prefabs/DragTargetSprite.prefab.meta b/Assets/Fungus/Resources/Prefabs/DragTargetSprite.prefab.meta new file mode 100644 index 0000000..5b09e83 --- /dev/null +++ b/Assets/Fungus/Resources/Prefabs/DragTargetSprite.prefab.meta @@ -0,0 +1,4 @@ +fileFormatVersion: 2 +guid: 4442b79fcbcbb4aac97f42d6dc3d4e0b +NativeFormatImporter: + userData: diff --git a/Assets/Fungus/Resources/Prefabs/DraggableSprite.prefab b/Assets/Fungus/Resources/Prefabs/DraggableSprite.prefab new file mode 100644 index 0000000..106fd6a --- /dev/null +++ b/Assets/Fungus/Resources/Prefabs/DraggableSprite.prefab @@ -0,0 +1,126 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!1 &100000 +GameObject: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + serializedVersion: 4 + m_Component: + - 4: {fileID: 400000} + - 212: {fileID: 21200000} + - 61: {fileID: 6100000} + - 50: {fileID: 5000000} + - 114: {fileID: 11400000} + m_Layer: 0 + m_Name: DraggableSprite + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &400000 +Transform: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 100000} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: -0.73, y: 0.36, z: 0} + m_LocalScale: {x: 1, y: 1, z: 1} + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_Children: [] + m_Father: {fileID: 0} + m_RootOrder: 0 +--- !u!50 &5000000 +Rigidbody2D: + serializedVersion: 2 + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 100000} + m_UseAutoMass: 0 + m_Mass: 1 + m_LinearDrag: 0 + m_AngularDrag: 0.05 + m_GravityScale: 1 + m_IsKinematic: 1 + m_Interpolate: 0 + m_SleepingMode: 1 + m_CollisionDetection: 0 + m_Constraints: 0 +--- !u!61 &6100000 +BoxCollider2D: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 100000} + m_Enabled: 1 + m_Density: 1 + m_Material: {fileID: 0} + m_IsTrigger: 1 + m_UsedByEffector: 0 + m_Offset: {x: 0, y: 0} + serializedVersion: 2 + m_Size: {x: 3, y: 3} +--- !u!114 &11400000 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 100000} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 18a0e492e94664ec0ac44d252c40e3a7, type: 3} + m_Name: + m_EditorClassIdentifier: + dragEnabled: 1 + returnOnCancelled: 1 + returnOnCompleted: 1 + returnDuration: 1 + hoverCursor: {fileID: 0} + useEventSystem: 0 +--- !u!212 &21200000 +SpriteRenderer: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 100000} + m_Enabled: 1 + m_CastShadows: 0 + m_ReceiveShadows: 0 + m_MotionVectors: 1 + m_LightProbeUsage: 0 + m_ReflectionProbeUsage: 0 + m_Materials: + - {fileID: 10754, guid: 0000000000000000f000000000000000, type: 0} + m_SubsetIndices: + 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_SelectedWireframeHidden: 1 + m_MinimumChartSize: 4 + m_AutoUVMaxDistance: 0.5 + m_AutoUVMaxAngle: 89 + m_LightmapParameters: {fileID: 0} + m_SortingLayerID: 0 + m_SortingOrder: 0 + m_Sprite: {fileID: 21300000, guid: ea8f56c43254d41728f5ac4e8299b6c9, type: 3} + m_Color: {r: 1, g: 1, b: 1, a: 1} + m_FlipX: 0 + m_FlipY: 0 +--- !u!1001 &100100000 +Prefab: + m_ObjectHideFlags: 1 + serializedVersion: 2 + m_Modification: + m_TransformParent: {fileID: 0} + m_Modifications: [] + m_RemovedComponents: [] + m_ParentPrefab: {fileID: 0} + m_RootGameObject: {fileID: 100000} + m_IsPrefabParent: 1 diff --git a/Assets/Fungus/Resources/Prefabs/DraggableSprite.prefab.meta b/Assets/Fungus/Resources/Prefabs/DraggableSprite.prefab.meta new file mode 100644 index 0000000..4ab928f --- /dev/null +++ b/Assets/Fungus/Resources/Prefabs/DraggableSprite.prefab.meta @@ -0,0 +1,4 @@ +fileFormatVersion: 2 +guid: 4d55f86cf3b124c8fb1158da26ffa96d +NativeFormatImporter: + userData: diff --git a/Assets/Fungus/Resources/Prefabs/EventSystem.prefab b/Assets/Fungus/Resources/Prefabs/EventSystem.prefab new file mode 100644 index 0000000..0338c55 --- /dev/null +++ b/Assets/Fungus/Resources/Prefabs/EventSystem.prefab @@ -0,0 +1,88 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!1 &179528 +GameObject: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + serializedVersion: 4 + m_Component: + - 4: {fileID: 479528} + - 114: {fileID: 11479524} + - 114: {fileID: 11479526} + - 114: {fileID: 11479528} + m_Layer: 0 + m_Name: EventSystem + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &479528 +Transform: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 179528} + 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_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_Children: [] + m_Father: {fileID: 0} + m_RootOrder: 0 +--- !u!114 &11479524 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 179528} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: -619905303, guid: f5f67c52d1564df4a8936ccd202a3bd8, type: 3} + m_Name: + m_EditorClassIdentifier: + m_FirstSelected: {fileID: 0} + m_sendNavigationEvents: 1 + m_DragThreshold: 5 +--- !u!114 &11479526 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 179528} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 1077351063, guid: f5f67c52d1564df4a8936ccd202a3bd8, 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 &11479528 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 179528} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 1997211142, guid: f5f67c52d1564df4a8936ccd202a3bd8, type: 3} + m_Name: + m_EditorClassIdentifier: + m_ForceModuleActive: 0 +--- !u!1001 &100100000 +Prefab: + m_ObjectHideFlags: 1 + serializedVersion: 2 + m_Modification: + m_TransformParent: {fileID: 0} + m_Modifications: [] + m_RemovedComponents: [] + m_ParentPrefab: {fileID: 0} + m_RootGameObject: {fileID: 179528} + m_IsPrefabParent: 1 diff --git a/Assets/Fungus/Resources/Prefabs/EventSystem.prefab.meta b/Assets/Fungus/Resources/Prefabs/EventSystem.prefab.meta new file mode 100644 index 0000000..64bd8b5 --- /dev/null +++ b/Assets/Fungus/Resources/Prefabs/EventSystem.prefab.meta @@ -0,0 +1,4 @@ +fileFormatVersion: 2 +guid: 6ba8287b46c1545a789e1b569cad35eb +NativeFormatImporter: + userData: diff --git a/Assets/Fungus/Resources/Prefabs/Flowchart.prefab b/Assets/Fungus/Resources/Prefabs/Flowchart.prefab new file mode 100644 index 0000000..b46f5b8 --- /dev/null +++ b/Assets/Fungus/Resources/Prefabs/Flowchart.prefab @@ -0,0 +1,138 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!1 &142980 +GameObject: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + serializedVersion: 4 + m_Component: + - 4: {fileID: 467082} + - 114: {fileID: 11430050} + - 114: {fileID: 11433304} + - 114: {fileID: 11462346} + m_Layer: 0 + m_Name: Flowchart + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &467082 +Transform: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 142980} + 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_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_Children: [] + m_Father: {fileID: 0} + m_RootOrder: 0 +--- !u!114 &11430050 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 142980} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 7a334fe2ffb574b3583ff3b18b4792d3, type: 3} + m_Name: + m_EditorClassIdentifier: + version: 1 + scrollPos: {x: 0, y: 0} + variablesScrollPos: {x: 0, y: 0} + variablesExpanded: 1 + blockViewHeight: 400 + zoom: 1 + scrollViewRect: + serializedVersion: 2 + x: -343 + y: -340 + width: 1114 + height: 859 + selectedBlock: {fileID: 11433304} + selectedCommands: [] + variables: [] + description: + stepPause: 0 + colorCommands: 1 + hideComponents: 1 + saveSelection: 1 + localizationId: + showLineNumbers: 0 + hideCommands: [] + luaEnvironment: {fileID: 0} + luaBindingName: flowchart +--- !u!114 &11433304 +MonoBehaviour: + m_ObjectHideFlags: 2 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 142980} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 3d3d73aef2cfc4f51abf34ac00241f60, type: 3} + m_Name: + m_EditorClassIdentifier: + nodeRect: + serializedVersion: 2 + x: 67 + y: 70 + width: 120 + height: 40 + itemId: 0 + blockName: New Block + description: + eventHandler: {fileID: 11462346} + commandList: [] +--- !u!114 &11462346 +MonoBehaviour: + m_ObjectHideFlags: 2 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 142980} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: d2f6487d21a03404cb21b245f0242e79, type: 3} + m_Name: + m_EditorClassIdentifier: + parentBlock: {fileID: 11433304} +--- !u!1001 &100100000 +Prefab: + m_ObjectHideFlags: 1 + serializedVersion: 2 + m_Modification: + m_TransformParent: {fileID: 0} + m_Modifications: + - target: {fileID: 0} + propertyPath: commandList.Array.size + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 0} + propertyPath: selectedCommands.Array.size + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 0} + propertyPath: hideComponents + value: 1 + objectReference: {fileID: 0} + - target: {fileID: 0} + propertyPath: selectedBlock + value: + objectReference: {fileID: 11433304} + - target: {fileID: 0} + propertyPath: commandList.Array.data[0] + value: + objectReference: {fileID: 0} + - target: {fileID: 0} + propertyPath: selectedCommands.Array.data[0] + value: + objectReference: {fileID: 0} + m_RemovedComponents: [] + m_ParentPrefab: {fileID: 0} + m_RootGameObject: {fileID: 142980} + m_IsPrefabParent: 1 diff --git a/Assets/Fungus/Resources/Prefabs/Flowchart.prefab.meta b/Assets/Fungus/Resources/Prefabs/Flowchart.prefab.meta new file mode 100644 index 0000000..5e8d644 --- /dev/null +++ b/Assets/Fungus/Resources/Prefabs/Flowchart.prefab.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 5e7fbc8d4eb714b279eeeef2262c1e1a +timeCreated: 1427386150 +licenseType: Store +NativeFormatImporter: + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Resources/Prefabs/FungusLogo.prefab b/Assets/Fungus/Resources/Prefabs/FungusLogo.prefab new file mode 100644 index 0000000..f9b7741 --- /dev/null +++ b/Assets/Fungus/Resources/Prefabs/FungusLogo.prefab @@ -0,0 +1,138 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!1 &158064 +GameObject: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + serializedVersion: 4 + m_Component: + - 4: {fileID: 406310} + - 212: {fileID: 21216416} + m_Layer: 0 + m_Name: FungusLogo + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!1 &181890 +GameObject: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + serializedVersion: 4 + m_Component: + - 4: {fileID: 454942} + - 212: {fileID: 21226848} + m_Layer: 0 + m_Name: CreatedWith + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &406310 +Transform: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 158064} + 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_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_Children: + - {fileID: 454942} + m_Father: {fileID: 0} + m_RootOrder: 0 +--- !u!4 &454942 +Transform: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 181890} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: 0.48, y: 2.02, z: 0} + m_LocalScale: {x: 1, y: 1, z: 1} + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_Children: [] + m_Father: {fileID: 406310} + m_RootOrder: 0 +--- !u!212 &21216416 +SpriteRenderer: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 158064} + m_Enabled: 1 + m_CastShadows: 0 + m_ReceiveShadows: 0 + m_MotionVectors: 1 + m_LightProbeUsage: 0 + m_ReflectionProbeUsage: 0 + m_Materials: + - {fileID: 10754, guid: 0000000000000000f000000000000000, type: 0} + m_SubsetIndices: + 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_SelectedWireframeHidden: 1 + m_MinimumChartSize: 4 + m_AutoUVMaxDistance: 0.5 + m_AutoUVMaxAngle: 89 + m_LightmapParameters: {fileID: 0} + m_SortingLayerID: 0 + m_SortingOrder: 0 + m_Sprite: {fileID: 21300000, guid: 1b656a189e6154422a74e05a56c3f245, type: 3} + m_Color: {r: 1, g: 1, b: 1, a: 1} + m_FlipX: 0 + m_FlipY: 0 +--- !u!212 &21226848 +SpriteRenderer: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 181890} + m_Enabled: 1 + m_CastShadows: 0 + m_ReceiveShadows: 0 + m_MotionVectors: 1 + m_LightProbeUsage: 0 + m_ReflectionProbeUsage: 0 + m_Materials: + - {fileID: 10754, guid: 0000000000000000f000000000000000, type: 0} + m_SubsetIndices: + 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_SelectedWireframeHidden: 1 + m_MinimumChartSize: 4 + m_AutoUVMaxDistance: 0.5 + m_AutoUVMaxAngle: 89 + m_LightmapParameters: {fileID: 0} + m_SortingLayerID: 0 + m_SortingOrder: 0 + m_Sprite: {fileID: 21300000, guid: 7adcbbe62d6554d81affcab2c56ad5ac, type: 3} + m_Color: {r: 1, g: 1, b: 1, a: 1} + m_FlipX: 0 + m_FlipY: 0 +--- !u!1001 &100100000 +Prefab: + m_ObjectHideFlags: 1 + serializedVersion: 2 + m_Modification: + m_TransformParent: {fileID: 0} + m_Modifications: [] + m_RemovedComponents: [] + m_ParentPrefab: {fileID: 0} + m_RootGameObject: {fileID: 158064} + m_IsPrefabParent: 1 diff --git a/Assets/Fungus/Resources/Prefabs/FungusLogo.prefab.meta b/Assets/Fungus/Resources/Prefabs/FungusLogo.prefab.meta new file mode 100644 index 0000000..3e0a6e7 --- /dev/null +++ b/Assets/Fungus/Resources/Prefabs/FungusLogo.prefab.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 613b99a82fe95405db46062e1c071434 +timeCreated: 1441210481 +licenseType: Store +NativeFormatImporter: + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Resources/Prefabs/Localization.prefab b/Assets/Fungus/Resources/Prefabs/Localization.prefab new file mode 100644 index 0000000..570bbad --- /dev/null +++ b/Assets/Fungus/Resources/Prefabs/Localization.prefab @@ -0,0 +1,55 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!1 &149266 +GameObject: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + serializedVersion: 4 + m_Component: + - 4: {fileID: 480768} + - 114: {fileID: 11438504} + m_Layer: 0 + m_Name: Localization + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &480768 +Transform: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 149266} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: 2.0554607, y: -3.1648574, z: 0} + m_LocalScale: {x: 1, y: 1, z: 1} + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_Children: [] + m_Father: {fileID: 0} + m_RootOrder: 0 +--- !u!114 &11438504 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 149266} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: e5724422a635e425bae0af9ffe2615d6, type: 3} + m_Name: + m_EditorClassIdentifier: + activeLanguage: + localizationFile: {fileID: 0} +--- !u!1001 &100100000 +Prefab: + m_ObjectHideFlags: 1 + serializedVersion: 2 + m_Modification: + m_TransformParent: {fileID: 0} + m_Modifications: [] + m_RemovedComponents: [] + m_ParentPrefab: {fileID: 0} + m_RootGameObject: {fileID: 149266} + m_IsPrefabParent: 1 diff --git a/Assets/Fungus/Resources/Prefabs/Localization.prefab.meta b/Assets/Fungus/Resources/Prefabs/Localization.prefab.meta new file mode 100644 index 0000000..19fd480 --- /dev/null +++ b/Assets/Fungus/Resources/Prefabs/Localization.prefab.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: ffbd0831d997545eab75c364da082c1b +timeCreated: 1428580452 +licenseType: Store +NativeFormatImporter: + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Resources/Prefabs/MenuDialog.prefab b/Assets/Fungus/Resources/Prefabs/MenuDialog.prefab new file mode 100644 index 0000000..e7bf7e8 --- /dev/null +++ b/Assets/Fungus/Resources/Prefabs/MenuDialog.prefab @@ -0,0 +1,1758 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!1 &115094 +GameObject: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + serializedVersion: 4 + m_Component: + - 224: {fileID: 22415094} + - 222: {fileID: 22215100} + - 114: {fileID: 11415072} + - 114: {fileID: 11415074} + - 114: {fileID: 11415076} + m_Layer: 5 + m_Name: OptionButton5 + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!1 &115102 +GameObject: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + serializedVersion: 4 + m_Component: + - 224: {fileID: 22415102} + - 223: {fileID: 22315124} + - 114: {fileID: 11415088} + - 225: {fileID: 22515124} + - 114: {fileID: 11415064} + - 114: {fileID: 11415124} + m_Layer: 5 + m_Name: MenuDialog + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!1 &115108 +GameObject: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + serializedVersion: 4 + m_Component: + - 224: {fileID: 22415108} + - 222: {fileID: 22215112} + - 114: {fileID: 11415102} + - 114: {fileID: 11415104} + - 114: {fileID: 11404784} + m_Layer: 5 + m_Name: TimeoutSlider + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!1 &115112 +GameObject: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + serializedVersion: 4 + m_Component: + - 224: {fileID: 22415112} + - 114: {fileID: 11404786} + - 114: {fileID: 11404782} + m_Layer: 0 + m_Name: ButtonGroup + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!1 &115116 +GameObject: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + serializedVersion: 4 + m_Component: + - 224: {fileID: 22415116} + m_Layer: 5 + m_Name: Fill Area + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!1 &115120 +GameObject: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + serializedVersion: 4 + m_Component: + - 224: {fileID: 22415120} + - 222: {fileID: 22215120} + - 114: {fileID: 11415118} + m_Layer: 5 + m_Name: Text + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!1 &115122 +GameObject: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + serializedVersion: 4 + m_Component: + - 224: {fileID: 22415122} + - 222: {fileID: 22215122} + - 114: {fileID: 11415120} + m_Layer: 5 + m_Name: Fill + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!1 &141170 +GameObject: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + serializedVersion: 4 + m_Component: + - 224: {fileID: 22470986} + - 114: {fileID: 11451014} + - 114: {fileID: 11432608} + m_Layer: 5 + m_Name: DefaultSelectable + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!1 &172108 +GameObject: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + serializedVersion: 4 + m_Component: + - 224: {fileID: 22472108} + - 222: {fileID: 22272108} + - 114: {fileID: 11472108} + m_Layer: 5 + m_Name: Text + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!1 &172110 +GameObject: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + serializedVersion: 4 + m_Component: + - 224: {fileID: 22472110} + - 222: {fileID: 22272110} + - 114: {fileID: 11472114} + - 114: {fileID: 11472112} + - 114: {fileID: 11472110} + m_Layer: 5 + m_Name: OptionButton4 + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!1 &172112 +GameObject: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + serializedVersion: 4 + m_Component: + - 224: {fileID: 22472112} + - 222: {fileID: 22272112} + - 114: {fileID: 11472116} + - 114: {fileID: 11472118} + - 114: {fileID: 11472120} + m_Layer: 5 + m_Name: OptionButton3 + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!1 &172114 +GameObject: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + serializedVersion: 4 + m_Component: + - 224: {fileID: 22472114} + - 222: {fileID: 22272114} + - 114: {fileID: 11472122} + m_Layer: 5 + m_Name: Text + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!1 &172116 +GameObject: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + serializedVersion: 4 + m_Component: + - 224: {fileID: 22472116} + - 222: {fileID: 22272116} + - 114: {fileID: 11472124} + m_Layer: 5 + m_Name: Text + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!1 &172118 +GameObject: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + serializedVersion: 4 + m_Component: + - 224: {fileID: 22472118} + - 222: {fileID: 22272118} + - 114: {fileID: 11472130} + - 114: {fileID: 11472128} + - 114: {fileID: 11472126} + m_Layer: 5 + m_Name: OptionButton2 + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!1 &172120 +GameObject: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + serializedVersion: 4 + m_Component: + - 224: {fileID: 22472120} + - 222: {fileID: 22272120} + - 114: {fileID: 11472132} + - 114: {fileID: 11472134} + - 114: {fileID: 11472136} + m_Layer: 5 + m_Name: OptionButton1 + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!1 &172122 +GameObject: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + serializedVersion: 4 + m_Component: + - 224: {fileID: 22472122} + - 222: {fileID: 22272122} + - 114: {fileID: 11472138} + m_Layer: 5 + m_Name: Text + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!1 &172124 +GameObject: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + serializedVersion: 4 + m_Component: + - 224: {fileID: 22472124} + - 222: {fileID: 22272124} + - 114: {fileID: 11472140} + m_Layer: 5 + m_Name: Text + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!1 &172126 +GameObject: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + serializedVersion: 4 + m_Component: + - 224: {fileID: 22472126} + - 222: {fileID: 22272126} + - 114: {fileID: 11472146} + - 114: {fileID: 11472144} + - 114: {fileID: 11472142} + m_Layer: 5 + m_Name: OptionButton0 + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!114 &11404782 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 115112} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 1741964061, guid: f5f67c52d1564df4a8936ccd202a3bd8, type: 3} + m_Name: + m_EditorClassIdentifier: + m_HorizontalFit: 0 + m_VerticalFit: 2 +--- !u!114 &11404784 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 115108} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 1679637790, guid: f5f67c52d1564df4a8936ccd202a3bd8, type: 3} + m_Name: + m_EditorClassIdentifier: + m_IgnoreLayout: 0 + m_MinWidth: -1 + m_MinHeight: -1 + m_PreferredWidth: -1 + m_PreferredHeight: 50 + m_FlexibleWidth: -1 + m_FlexibleHeight: -1 +--- !u!114 &11404786 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 115112} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 1297475563, guid: f5f67c52d1564df4a8936ccd202a3bd8, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Padding: + m_Left: 0 + m_Right: 0 + m_Top: 0 + m_Bottom: 0 + m_ChildAlignment: 4 + m_Spacing: 5 + m_ChildForceExpandWidth: 1 + m_ChildForceExpandHeight: 0 +--- !u!114 &11415064 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 115102} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 1301386320, guid: f5f67c52d1564df4a8936ccd202a3bd8, type: 3} + m_Name: + m_EditorClassIdentifier: + m_IgnoreReversedGraphics: 1 + m_BlockingObjects: 0 + m_BlockingMask: + serializedVersion: 2 + m_Bits: 4294967295 +--- !u!114 &11415072 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 115094} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: -765806418, guid: f5f67c52d1564df4a8936ccd202a3bd8, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 10754, guid: 0000000000000000f000000000000000, type: 0} + m_Color: {r: 1, g: 1, b: 1, a: 0.8627451} + 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: c207de86481ff7d48a2fba2fcc374723, type: 3} + m_Type: 1 + m_PreserveAspect: 0 + m_FillCenter: 1 + m_FillMethod: 4 + m_FillAmount: 1 + m_FillClockwise: 1 + m_FillOrigin: 0 +--- !u!114 &11415074 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 115094} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 1392445389, guid: f5f67c52d1564df4a8936ccd202a3bd8, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Navigation: + m_Mode: 3 + m_SelectOnUp: {fileID: 0} + m_SelectOnDown: {fileID: 0} + m_SelectOnLeft: {fileID: 0} + m_SelectOnRight: {fileID: 0} + m_Transition: 2 + m_Colors: + m_NormalColor: {r: 1, g: 1, b: 1, a: 1} + m_HighlightedColor: {r: 0.14509805, g: 0.75686276, b: 0.8784314, a: 0.69803923} + m_PressedColor: {r: 0.078431375, g: 0.5137255, b: 0.6, a: 1} + m_DisabledColor: {r: 0.5882353, g: 0.64705884, b: 0.6666667, a: 0.5019608} + m_ColorMultiplier: 2 + m_FadeDuration: 0.1 + m_SpriteState: + m_HighlightedSprite: {fileID: 21300000, guid: 888feb4a32e3b564fb7e6f9b28cc8e10, + type: 3} + m_PressedSprite: {fileID: 21300000, guid: 2e33a3f531b6adc4f9d8a99c83e2ba2d, type: 3} + m_DisabledSprite: {fileID: 21300000, guid: 49d5ccdda7b99e24787c2abc3891294c, type: 3} + m_AnimationTriggers: + m_NormalTrigger: Normal + m_HighlightedTrigger: Highlighted + m_PressedTrigger: Pressed + m_DisabledTrigger: Disabled + m_Interactable: 1 + m_TargetGraphic: {fileID: 11415072} + m_OnClick: + m_PersistentCalls: + m_Calls: [] + m_TypeName: UnityEngine.UI.Button+ButtonClickedEvent, UnityEngine.UI, Version=1.0.0.0, + Culture=neutral, PublicKeyToken=null +--- !u!114 &11415076 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 115094} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 1679637790, guid: f5f67c52d1564df4a8936ccd202a3bd8, type: 3} + m_Name: + m_EditorClassIdentifier: + m_IgnoreLayout: 0 + m_MinWidth: -1 + m_MinHeight: -1 + m_PreferredWidth: -1 + m_PreferredHeight: 100 + m_FlexibleWidth: -1 + m_FlexibleHeight: -1 +--- !u!114 &11415088 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 115102} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 1980459831, guid: f5f67c52d1564df4a8936ccd202a3bd8, type: 3} + m_Name: + m_EditorClassIdentifier: + m_UiScaleMode: 1 + m_ReferencePixelsPerUnit: 32 + m_ScaleFactor: 1 + m_ReferenceResolution: {x: 1600, y: 1200} + m_ScreenMatchMode: 0 + m_MatchWidthOrHeight: 1 + m_PhysicalUnit: 3 + m_FallbackScreenDPI: 96 + m_DefaultSpriteDPI: 96 + m_DynamicPixelsPerUnit: 1 +--- !u!114 &11415102 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 115108} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: -765806418, guid: f5f67c52d1564df4a8936ccd202a3bd8, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 1, g: 1, b: 1, a: 0.588} + 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: 10907, guid: 0000000000000000f000000000000000, type: 0} + m_Type: 1 + m_PreserveAspect: 0 + m_FillCenter: 1 + m_FillMethod: 4 + m_FillAmount: 1 + m_FillClockwise: 1 + m_FillOrigin: 0 +--- !u!114 &11415104 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 115108} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: -113659843, guid: f5f67c52d1564df4a8936ccd202a3bd8, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Navigation: + m_Mode: 3 + m_SelectOnUp: {fileID: 0} + m_SelectOnDown: {fileID: 0} + m_SelectOnLeft: {fileID: 0} + m_SelectOnRight: {fileID: 0} + m_Transition: 1 + m_Colors: + m_NormalColor: {r: 0.2509804, g: 0.2509804, b: 0.2509804, a: 0.5019608} + m_HighlightedColor: {r: 0.5019608, g: 0.5019608, b: 0.5019608, a: 0.69803923} + m_PressedColor: {r: 0.34509805, g: 0.34509805, b: 0.34509805, a: 0.69803923} + m_DisabledColor: {r: 0.2509804, g: 0.2509804, b: 0.2509804, a: 0.5019608} + m_ColorMultiplier: 2 + m_FadeDuration: 0.1 + m_SpriteState: + m_HighlightedSprite: {fileID: 0} + m_PressedSprite: {fileID: 0} + m_DisabledSprite: {fileID: 0} + m_AnimationTriggers: + m_NormalTrigger: Normal + m_HighlightedTrigger: Highlighted + m_PressedTrigger: Pressed + m_DisabledTrigger: Disabled + m_Interactable: 0 + m_TargetGraphic: {fileID: 11415102} + m_FillRect: {fileID: 22415122} + m_HandleRect: {fileID: 0} + m_Direction: 1 + m_MinValue: 0 + m_MaxValue: 1 + m_WholeNumbers: 0 + m_Value: 1 + m_OnValueChanged: + m_PersistentCalls: + m_Calls: [] + m_TypeName: UnityEngine.UI.Slider+SliderEvent, UnityEngine.UI, Version=1.0.0.0, + Culture=neutral, PublicKeyToken=null +--- !u!114 &11415118 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 115120} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 708705254, guid: f5f67c52d1564df4a8936ccd202a3bd8, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 1, g: 1, b: 1, 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_FontData: + m_Font: {fileID: 12800000, guid: bb145366ce7024469a5758b08d31802c, type: 3} + m_FontSize: 40 + m_FontStyle: 0 + m_BestFit: 1 + m_MinSize: 30 + m_MaxSize: 40 + m_Alignment: 4 + m_AlignByGeometry: 0 + m_RichText: 1 + m_HorizontalOverflow: 0 + m_VerticalOverflow: 0 + m_LineSpacing: 1 + m_Text: Continue +--- !u!114 &11415120 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 115122} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: -765806418, guid: f5f67c52d1564df4a8936ccd202a3bd8, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 0.2, g: 0.70980394, b: 0.8980392, a: 0.94509804} + 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: 10905, guid: 0000000000000000f000000000000000, type: 0} + m_Type: 1 + m_PreserveAspect: 0 + m_FillCenter: 1 + m_FillMethod: 4 + m_FillAmount: 1 + m_FillClockwise: 1 + m_FillOrigin: 0 +--- !u!114 &11415124 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 115102} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: ee8371d2b2fe14a9ca0a9465140027de, type: 3} + m_Name: + m_EditorClassIdentifier: + autoSelectFirstButton: 0 +--- !u!114 &11432608 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 141170} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 1cbf240ac6442144f90a023c1b64d868, type: 3} + m_Name: + m_EditorClassIdentifier: +--- !u!114 &11451014 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 141170} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: -234403039, guid: f5f67c52d1564df4a8936ccd202a3bd8, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Navigation: + m_Mode: 3 + m_SelectOnUp: {fileID: 11472144} + m_SelectOnDown: {fileID: 11472144} + m_SelectOnLeft: {fileID: 11472144} + m_SelectOnRight: {fileID: 11472144} + m_Transition: 0 + m_Colors: + m_NormalColor: {r: 1, g: 1, b: 1, a: 1} + m_HighlightedColor: {r: 0.9607843, g: 0.9607843, b: 0.9607843, a: 1} + m_PressedColor: {r: 0.78431374, g: 0.78431374, b: 0.78431374, a: 1} + m_DisabledColor: {r: 0.78431374, g: 0.78431374, b: 0.78431374, a: 0.5019608} + m_ColorMultiplier: 1 + m_FadeDuration: 0.1 + m_SpriteState: + m_HighlightedSprite: {fileID: 0} + m_PressedSprite: {fileID: 0} + m_DisabledSprite: {fileID: 0} + m_AnimationTriggers: + m_NormalTrigger: Normal + m_HighlightedTrigger: Highlighted + m_PressedTrigger: Pressed + m_DisabledTrigger: Disabled + m_Interactable: 0 + m_TargetGraphic: {fileID: 0} +--- !u!114 &11472108 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 172108} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 708705254, guid: f5f67c52d1564df4a8936ccd202a3bd8, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 1, g: 1, b: 1, 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_FontData: + m_Font: {fileID: 12800000, guid: bb145366ce7024469a5758b08d31802c, type: 3} + m_FontSize: 40 + m_FontStyle: 0 + m_BestFit: 1 + m_MinSize: 30 + m_MaxSize: 40 + m_Alignment: 4 + m_AlignByGeometry: 0 + m_RichText: 1 + m_HorizontalOverflow: 0 + m_VerticalOverflow: 0 + m_LineSpacing: 1 + m_Text: Continue +--- !u!114 &11472110 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 172110} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 1679637790, guid: f5f67c52d1564df4a8936ccd202a3bd8, type: 3} + m_Name: + m_EditorClassIdentifier: + m_IgnoreLayout: 0 + m_MinWidth: -1 + m_MinHeight: -1 + m_PreferredWidth: -1 + m_PreferredHeight: 100 + m_FlexibleWidth: -1 + m_FlexibleHeight: -1 +--- !u!114 &11472112 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 172110} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 1392445389, guid: f5f67c52d1564df4a8936ccd202a3bd8, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Navigation: + m_Mode: 3 + m_SelectOnUp: {fileID: 0} + m_SelectOnDown: {fileID: 0} + m_SelectOnLeft: {fileID: 0} + m_SelectOnRight: {fileID: 0} + m_Transition: 2 + m_Colors: + m_NormalColor: {r: 1, g: 1, b: 1, a: 1} + m_HighlightedColor: {r: 0.14509805, g: 0.75686276, b: 0.8784314, a: 0.69803923} + m_PressedColor: {r: 0.078431375, g: 0.5137255, b: 0.6, a: 1} + m_DisabledColor: {r: 0.5882353, g: 0.64705884, b: 0.6666667, a: 0.5019608} + m_ColorMultiplier: 2 + m_FadeDuration: 0.1 + m_SpriteState: + m_HighlightedSprite: {fileID: 21300000, guid: 888feb4a32e3b564fb7e6f9b28cc8e10, + type: 3} + m_PressedSprite: {fileID: 21300000, guid: 2e33a3f531b6adc4f9d8a99c83e2ba2d, type: 3} + m_DisabledSprite: {fileID: 21300000, guid: 49d5ccdda7b99e24787c2abc3891294c, type: 3} + m_AnimationTriggers: + m_NormalTrigger: Normal + m_HighlightedTrigger: Highlighted + m_PressedTrigger: Pressed + m_DisabledTrigger: Disabled + m_Interactable: 1 + m_TargetGraphic: {fileID: 11472114} + m_OnClick: + m_PersistentCalls: + m_Calls: [] + m_TypeName: UnityEngine.UI.Button+ButtonClickedEvent, UnityEngine.UI, Version=1.0.0.0, + Culture=neutral, PublicKeyToken=null +--- !u!114 &11472114 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 172110} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: -765806418, guid: f5f67c52d1564df4a8936ccd202a3bd8, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 10754, guid: 0000000000000000f000000000000000, type: 0} + m_Color: {r: 1, g: 1, b: 1, a: 0.8627451} + 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: c207de86481ff7d48a2fba2fcc374723, type: 3} + m_Type: 1 + m_PreserveAspect: 0 + m_FillCenter: 1 + m_FillMethod: 4 + m_FillAmount: 1 + m_FillClockwise: 1 + m_FillOrigin: 0 +--- !u!114 &11472116 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 172112} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: -765806418, guid: f5f67c52d1564df4a8936ccd202a3bd8, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 10754, guid: 0000000000000000f000000000000000, type: 0} + m_Color: {r: 1, g: 1, b: 1, a: 0.8627451} + 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: c207de86481ff7d48a2fba2fcc374723, type: 3} + m_Type: 1 + m_PreserveAspect: 0 + m_FillCenter: 1 + m_FillMethod: 4 + m_FillAmount: 1 + m_FillClockwise: 1 + m_FillOrigin: 0 +--- !u!114 &11472118 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 172112} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 1392445389, guid: f5f67c52d1564df4a8936ccd202a3bd8, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Navigation: + m_Mode: 3 + m_SelectOnUp: {fileID: 0} + m_SelectOnDown: {fileID: 0} + m_SelectOnLeft: {fileID: 0} + m_SelectOnRight: {fileID: 0} + m_Transition: 2 + m_Colors: + m_NormalColor: {r: 1, g: 1, b: 1, a: 1} + m_HighlightedColor: {r: 0.14509805, g: 0.75686276, b: 0.8784314, a: 0.69803923} + m_PressedColor: {r: 0.078431375, g: 0.5137255, b: 0.6, a: 1} + m_DisabledColor: {r: 0.5882353, g: 0.64705884, b: 0.6666667, a: 0.5019608} + m_ColorMultiplier: 2 + m_FadeDuration: 0.1 + m_SpriteState: + m_HighlightedSprite: {fileID: 21300000, guid: 888feb4a32e3b564fb7e6f9b28cc8e10, + type: 3} + m_PressedSprite: {fileID: 21300000, guid: 2e33a3f531b6adc4f9d8a99c83e2ba2d, type: 3} + m_DisabledSprite: {fileID: 21300000, guid: 49d5ccdda7b99e24787c2abc3891294c, type: 3} + m_AnimationTriggers: + m_NormalTrigger: Normal + m_HighlightedTrigger: Highlighted + m_PressedTrigger: Pressed + m_DisabledTrigger: Disabled + m_Interactable: 1 + m_TargetGraphic: {fileID: 11472116} + m_OnClick: + m_PersistentCalls: + m_Calls: [] + m_TypeName: UnityEngine.UI.Button+ButtonClickedEvent, UnityEngine.UI, Version=1.0.0.0, + Culture=neutral, PublicKeyToken=null +--- !u!114 &11472120 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 172112} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 1679637790, guid: f5f67c52d1564df4a8936ccd202a3bd8, type: 3} + m_Name: + m_EditorClassIdentifier: + m_IgnoreLayout: 0 + m_MinWidth: -1 + m_MinHeight: -1 + m_PreferredWidth: -1 + m_PreferredHeight: 100 + m_FlexibleWidth: -1 + m_FlexibleHeight: -1 +--- !u!114 &11472122 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 172114} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 708705254, guid: f5f67c52d1564df4a8936ccd202a3bd8, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 1, g: 1, b: 1, 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_FontData: + m_Font: {fileID: 12800000, guid: bb145366ce7024469a5758b08d31802c, type: 3} + m_FontSize: 40 + m_FontStyle: 0 + m_BestFit: 1 + m_MinSize: 30 + m_MaxSize: 40 + m_Alignment: 4 + m_AlignByGeometry: 0 + m_RichText: 1 + m_HorizontalOverflow: 0 + m_VerticalOverflow: 0 + m_LineSpacing: 1 + m_Text: Continue +--- !u!114 &11472124 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 172116} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 708705254, guid: f5f67c52d1564df4a8936ccd202a3bd8, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 1, g: 1, b: 1, 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_FontData: + m_Font: {fileID: 12800000, guid: bb145366ce7024469a5758b08d31802c, type: 3} + m_FontSize: 40 + m_FontStyle: 0 + m_BestFit: 1 + m_MinSize: 30 + m_MaxSize: 40 + m_Alignment: 4 + m_AlignByGeometry: 0 + m_RichText: 1 + m_HorizontalOverflow: 0 + m_VerticalOverflow: 0 + m_LineSpacing: 1 + m_Text: Continue +--- !u!114 &11472126 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 172118} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 1679637790, guid: f5f67c52d1564df4a8936ccd202a3bd8, type: 3} + m_Name: + m_EditorClassIdentifier: + m_IgnoreLayout: 0 + m_MinWidth: -1 + m_MinHeight: -1 + m_PreferredWidth: -1 + m_PreferredHeight: 100 + m_FlexibleWidth: -1 + m_FlexibleHeight: -1 +--- !u!114 &11472128 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 172118} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 1392445389, guid: f5f67c52d1564df4a8936ccd202a3bd8, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Navigation: + m_Mode: 3 + m_SelectOnUp: {fileID: 0} + m_SelectOnDown: {fileID: 0} + m_SelectOnLeft: {fileID: 0} + m_SelectOnRight: {fileID: 0} + m_Transition: 2 + m_Colors: + m_NormalColor: {r: 1, g: 1, b: 1, a: 1} + m_HighlightedColor: {r: 0.14509805, g: 0.75686276, b: 0.8784314, a: 0.69803923} + m_PressedColor: {r: 0.078431375, g: 0.5137255, b: 0.6, a: 1} + m_DisabledColor: {r: 0.5882353, g: 0.64705884, b: 0.6666667, a: 0.5019608} + m_ColorMultiplier: 2 + m_FadeDuration: 0.1 + m_SpriteState: + m_HighlightedSprite: {fileID: 21300000, guid: 888feb4a32e3b564fb7e6f9b28cc8e10, + type: 3} + m_PressedSprite: {fileID: 21300000, guid: 2e33a3f531b6adc4f9d8a99c83e2ba2d, type: 3} + m_DisabledSprite: {fileID: 21300000, guid: 49d5ccdda7b99e24787c2abc3891294c, type: 3} + m_AnimationTriggers: + m_NormalTrigger: Normal + m_HighlightedTrigger: Highlighted + m_PressedTrigger: Pressed + m_DisabledTrigger: Disabled + m_Interactable: 1 + m_TargetGraphic: {fileID: 11472130} + m_OnClick: + m_PersistentCalls: + m_Calls: [] + m_TypeName: UnityEngine.UI.Button+ButtonClickedEvent, UnityEngine.UI, Version=1.0.0.0, + Culture=neutral, PublicKeyToken=null +--- !u!114 &11472130 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 172118} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: -765806418, guid: f5f67c52d1564df4a8936ccd202a3bd8, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 10754, guid: 0000000000000000f000000000000000, type: 0} + m_Color: {r: 1, g: 1, b: 1, a: 0.8627451} + 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: c207de86481ff7d48a2fba2fcc374723, type: 3} + m_Type: 1 + m_PreserveAspect: 0 + m_FillCenter: 1 + m_FillMethod: 4 + m_FillAmount: 1 + m_FillClockwise: 1 + m_FillOrigin: 0 +--- !u!114 &11472132 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 172120} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: -765806418, guid: f5f67c52d1564df4a8936ccd202a3bd8, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 10754, guid: 0000000000000000f000000000000000, type: 0} + m_Color: {r: 1, g: 1, b: 1, a: 0.8627451} + 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: c207de86481ff7d48a2fba2fcc374723, type: 3} + m_Type: 1 + m_PreserveAspect: 0 + m_FillCenter: 1 + m_FillMethod: 4 + m_FillAmount: 1 + m_FillClockwise: 1 + m_FillOrigin: 0 +--- !u!114 &11472134 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 172120} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 1392445389, guid: f5f67c52d1564df4a8936ccd202a3bd8, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Navigation: + m_Mode: 3 + m_SelectOnUp: {fileID: 0} + m_SelectOnDown: {fileID: 0} + m_SelectOnLeft: {fileID: 0} + m_SelectOnRight: {fileID: 0} + m_Transition: 2 + m_Colors: + m_NormalColor: {r: 1, g: 1, b: 1, a: 1} + m_HighlightedColor: {r: 0.14509805, g: 0.75686276, b: 0.8784314, a: 0.69803923} + m_PressedColor: {r: 0.078431375, g: 0.5137255, b: 0.6, a: 1} + m_DisabledColor: {r: 0.5882353, g: 0.64705884, b: 0.6666667, a: 0.5019608} + m_ColorMultiplier: 2 + m_FadeDuration: 0.1 + m_SpriteState: + m_HighlightedSprite: {fileID: 21300000, guid: 888feb4a32e3b564fb7e6f9b28cc8e10, + type: 3} + m_PressedSprite: {fileID: 21300000, guid: 2e33a3f531b6adc4f9d8a99c83e2ba2d, type: 3} + m_DisabledSprite: {fileID: 21300000, guid: 49d5ccdda7b99e24787c2abc3891294c, type: 3} + m_AnimationTriggers: + m_NormalTrigger: Normal + m_HighlightedTrigger: Highlighted + m_PressedTrigger: Pressed + m_DisabledTrigger: Disabled + m_Interactable: 1 + m_TargetGraphic: {fileID: 11472132} + m_OnClick: + m_PersistentCalls: + m_Calls: [] + m_TypeName: UnityEngine.UI.Button+ButtonClickedEvent, UnityEngine.UI, Version=1.0.0.0, + Culture=neutral, PublicKeyToken=null +--- !u!114 &11472136 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 172120} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 1679637790, guid: f5f67c52d1564df4a8936ccd202a3bd8, type: 3} + m_Name: + m_EditorClassIdentifier: + m_IgnoreLayout: 0 + m_MinWidth: -1 + m_MinHeight: -1 + m_PreferredWidth: -1 + m_PreferredHeight: 100 + m_FlexibleWidth: -1 + m_FlexibleHeight: -1 +--- !u!114 &11472138 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 172122} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 708705254, guid: f5f67c52d1564df4a8936ccd202a3bd8, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 1, g: 1, b: 1, 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_FontData: + m_Font: {fileID: 12800000, guid: bb145366ce7024469a5758b08d31802c, type: 3} + m_FontSize: 40 + m_FontStyle: 0 + m_BestFit: 1 + m_MinSize: 30 + m_MaxSize: 40 + m_Alignment: 4 + m_AlignByGeometry: 0 + m_RichText: 1 + m_HorizontalOverflow: 0 + m_VerticalOverflow: 0 + m_LineSpacing: 1 + m_Text: Continue +--- !u!114 &11472140 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 172124} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 708705254, guid: f5f67c52d1564df4a8936ccd202a3bd8, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 1, g: 1, b: 1, 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_FontData: + m_Font: {fileID: 12800000, guid: bb145366ce7024469a5758b08d31802c, type: 3} + m_FontSize: 40 + m_FontStyle: 0 + m_BestFit: 1 + m_MinSize: 30 + m_MaxSize: 40 + m_Alignment: 4 + m_AlignByGeometry: 0 + m_RichText: 1 + m_HorizontalOverflow: 0 + m_VerticalOverflow: 0 + m_LineSpacing: 1 + m_Text: Continue +--- !u!114 &11472142 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 172126} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 1679637790, guid: f5f67c52d1564df4a8936ccd202a3bd8, type: 3} + m_Name: + m_EditorClassIdentifier: + m_IgnoreLayout: 0 + m_MinWidth: -1 + m_MinHeight: -1 + m_PreferredWidth: -1 + m_PreferredHeight: 100 + m_FlexibleWidth: -1 + m_FlexibleHeight: -1 +--- !u!114 &11472144 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 172126} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 1392445389, guid: f5f67c52d1564df4a8936ccd202a3bd8, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Navigation: + m_Mode: 3 + m_SelectOnUp: {fileID: 0} + m_SelectOnDown: {fileID: 0} + m_SelectOnLeft: {fileID: 0} + m_SelectOnRight: {fileID: 0} + m_Transition: 2 + m_Colors: + m_NormalColor: {r: 1, g: 1, b: 1, a: 1} + m_HighlightedColor: {r: 0.14509805, g: 0.75686276, b: 0.8784314, a: 0.69803923} + m_PressedColor: {r: 0.078431375, g: 0.5137255, b: 0.6, a: 1} + m_DisabledColor: {r: 0.5882353, g: 0.64705884, b: 0.6666667, a: 0.5019608} + m_ColorMultiplier: 2 + m_FadeDuration: 0.1 + m_SpriteState: + m_HighlightedSprite: {fileID: 21300000, guid: 888feb4a32e3b564fb7e6f9b28cc8e10, + type: 3} + m_PressedSprite: {fileID: 21300000, guid: 2e33a3f531b6adc4f9d8a99c83e2ba2d, type: 3} + m_DisabledSprite: {fileID: 21300000, guid: 49d5ccdda7b99e24787c2abc3891294c, type: 3} + m_AnimationTriggers: + m_NormalTrigger: Normal + m_HighlightedTrigger: Highlighted + m_PressedTrigger: Pressed + m_DisabledTrigger: Disabled + m_Interactable: 1 + m_TargetGraphic: {fileID: 11472146} + m_OnClick: + m_PersistentCalls: + m_Calls: [] + m_TypeName: UnityEngine.UI.Button+ButtonClickedEvent, UnityEngine.UI, Version=1.0.0.0, + Culture=neutral, PublicKeyToken=null +--- !u!114 &11472146 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 172126} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: -765806418, guid: f5f67c52d1564df4a8936ccd202a3bd8, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 10754, guid: 0000000000000000f000000000000000, type: 0} + m_Color: {r: 1, g: 1, b: 1, a: 0.8627451} + 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: c207de86481ff7d48a2fba2fcc374723, type: 3} + m_Type: 1 + m_PreserveAspect: 0 + m_FillCenter: 1 + m_FillMethod: 4 + m_FillAmount: 1 + m_FillClockwise: 1 + m_FillOrigin: 0 +--- !u!222 &22215100 +CanvasRenderer: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 115094} +--- !u!222 &22215112 +CanvasRenderer: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 115108} +--- !u!222 &22215120 +CanvasRenderer: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 115120} +--- !u!222 &22215122 +CanvasRenderer: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 115122} +--- !u!222 &22272108 +CanvasRenderer: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 172108} +--- !u!222 &22272110 +CanvasRenderer: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 172110} +--- !u!222 &22272112 +CanvasRenderer: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 172112} +--- !u!222 &22272114 +CanvasRenderer: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 172114} +--- !u!222 &22272116 +CanvasRenderer: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 172116} +--- !u!222 &22272118 +CanvasRenderer: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 172118} +--- !u!222 &22272120 +CanvasRenderer: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 172120} +--- !u!222 &22272122 +CanvasRenderer: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 172122} +--- !u!222 &22272124 +CanvasRenderer: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 172124} +--- !u!222 &22272126 +CanvasRenderer: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 172126} +--- !u!223 &22315124 +Canvas: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 115102} + m_Enabled: 1 + serializedVersion: 2 + m_RenderMode: 0 + m_Camera: {fileID: 0} + m_PlaneDistance: 100 + m_PixelPerfect: 1 + m_ReceivesEvents: 1 + m_OverrideSorting: 0 + m_OverridePixelPerfect: 0 + m_SortingBucketNormalizedSize: 0 + m_SortingLayerID: 0 + m_SortingOrder: 1 + m_TargetDisplay: 0 +--- !u!224 &22415094 +RectTransform: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 115094} + 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_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_Children: + - {fileID: 22415120} + m_Father: {fileID: 22415112} + m_RootOrder: 5 + 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.5, y: 0.5} +--- !u!224 &22415102 +RectTransform: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 115102} + 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_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_Children: + - {fileID: 22470986} + - {fileID: 22415112} + m_Father: {fileID: 0} + m_RootOrder: 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!224 &22415108 +RectTransform: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 115108} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: 0, y: 0, z: 0} + m_LocalScale: {x: 0.9, y: 1, z: 1} + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_Children: + - {fileID: 22415116} + m_Father: {fileID: 22415112} + m_RootOrder: 6 + 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.5, y: 0.5} +--- !u!224 &22415112 +RectTransform: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 115112} + 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_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_Children: + - {fileID: 22472126} + - {fileID: 22472120} + - {fileID: 22472118} + - {fileID: 22472112} + - {fileID: 22472110} + - {fileID: 22415094} + - {fileID: 22415108} + m_Father: {fileID: 22415102} + m_RootOrder: 1 + m_AnchorMin: {x: 0.5, y: 0.5} + m_AnchorMax: {x: 0.5, y: 0.5} + m_AnchoredPosition: {x: -0.000018477, y: 191} + m_SizeDelta: {x: 1300, y: 0} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!224 &22415116 +RectTransform: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 115116} + 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_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_Children: + - {fileID: 22415122} + m_Father: {fileID: 22415108} + m_RootOrder: 0 + m_AnchorMin: {x: 0, y: 0} + m_AnchorMax: {x: 1, y: 1} + m_AnchoredPosition: {x: 0, y: 0} + m_SizeDelta: {x: -20, y: -10} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!224 &22415120 +RectTransform: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 115120} + 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_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_Children: [] + m_Father: {fileID: 22415094} + m_RootOrder: 0 + m_AnchorMin: {x: 0, y: 0} + m_AnchorMax: {x: 1, y: 1} + m_AnchoredPosition: {x: 0, y: 0} + m_SizeDelta: {x: 0, y: 0} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!224 &22415122 +RectTransform: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 115122} + 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_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_Children: [] + m_Father: {fileID: 22415116} + m_RootOrder: 0 + m_AnchorMin: {x: 0, y: 0} + m_AnchorMax: {x: 0, y: 0} + m_AnchoredPosition: {x: 0, y: 0} + m_SizeDelta: {x: 10, y: 0} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!224 &22470986 +RectTransform: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 141170} + 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_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_Children: [] + m_Father: {fileID: 22415102} + m_RootOrder: 0 + m_AnchorMin: {x: 0.5, y: 1} + m_AnchorMax: {x: 0.5, y: 1} + m_AnchoredPosition: {x: 0, y: 0} + m_SizeDelta: {x: 100, y: 100} + m_Pivot: {x: 0.5, y: 1} +--- !u!224 &22472108 +RectTransform: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 172108} + 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_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_Children: [] + m_Father: {fileID: 22472110} + m_RootOrder: 0 + m_AnchorMin: {x: 0, y: 0} + m_AnchorMax: {x: 1, y: 1} + m_AnchoredPosition: {x: 0, y: 0} + m_SizeDelta: {x: 0, y: 0} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!224 &22472110 +RectTransform: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 172110} + 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_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_Children: + - {fileID: 22472108} + m_Father: {fileID: 22415112} + m_RootOrder: 4 + 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.5, y: 0.5} +--- !u!224 &22472112 +RectTransform: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 172112} + 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_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_Children: + - {fileID: 22472114} + m_Father: {fileID: 22415112} + m_RootOrder: 3 + 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.5, y: 0.5} +--- !u!224 &22472114 +RectTransform: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 172114} + 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_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_Children: [] + m_Father: {fileID: 22472112} + m_RootOrder: 0 + m_AnchorMin: {x: 0, y: 0} + m_AnchorMax: {x: 1, y: 1} + m_AnchoredPosition: {x: 0, y: 0} + m_SizeDelta: {x: 0, y: 0} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!224 &22472116 +RectTransform: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 172116} + 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_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_Children: [] + m_Father: {fileID: 22472118} + m_RootOrder: 0 + m_AnchorMin: {x: 0, y: 0} + m_AnchorMax: {x: 1, y: 1} + m_AnchoredPosition: {x: 0, y: 0} + m_SizeDelta: {x: 0, y: 0} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!224 &22472118 +RectTransform: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 172118} + 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_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_Children: + - {fileID: 22472116} + m_Father: {fileID: 22415112} + m_RootOrder: 2 + 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.5, y: 0.5} +--- !u!224 &22472120 +RectTransform: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 172120} + 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_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_Children: + - {fileID: 22472122} + m_Father: {fileID: 22415112} + m_RootOrder: 1 + 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.5, y: 0.5} +--- !u!224 &22472122 +RectTransform: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 172122} + 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_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_Children: [] + m_Father: {fileID: 22472120} + m_RootOrder: 0 + m_AnchorMin: {x: 0, y: 0} + m_AnchorMax: {x: 1, y: 1} + m_AnchoredPosition: {x: 0, y: 0} + m_SizeDelta: {x: 0, y: 0} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!224 &22472124 +RectTransform: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 172124} + 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_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_Children: [] + m_Father: {fileID: 22472126} + m_RootOrder: 0 + m_AnchorMin: {x: 0, y: 0} + m_AnchorMax: {x: 1, y: 1} + m_AnchoredPosition: {x: 0, y: 0} + m_SizeDelta: {x: 0, y: 0} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!224 &22472126 +RectTransform: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 172126} + 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_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_Children: + - {fileID: 22472124} + m_Father: {fileID: 22415112} + m_RootOrder: 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.5, y: 0.5} +--- !u!225 &22515124 +CanvasGroup: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 115102} + m_Enabled: 1 + m_Alpha: 1 + m_Interactable: 1 + m_BlocksRaycasts: 1 + m_IgnoreParentGroups: 0 +--- !u!1001 &100100000 +Prefab: + m_ObjectHideFlags: 1 + serializedVersion: 2 + m_Modification: + m_TransformParent: {fileID: 0} + m_Modifications: [] + m_RemovedComponents: [] + m_ParentPrefab: {fileID: 0} + m_RootGameObject: {fileID: 115102} + m_IsPrefabParent: 1 diff --git a/Assets/Fungus/Resources/Prefabs/MenuDialog.prefab.meta b/Assets/Fungus/Resources/Prefabs/MenuDialog.prefab.meta new file mode 100644 index 0000000..a7c1a4f --- /dev/null +++ b/Assets/Fungus/Resources/Prefabs/MenuDialog.prefab.meta @@ -0,0 +1,4 @@ +fileFormatVersion: 2 +guid: 9bb64c8df70904eecac3f71f81bf339b +NativeFormatImporter: + userData: diff --git a/Assets/Fungus/Resources/Prefabs/NarrativeLog.prefab b/Assets/Fungus/Resources/Prefabs/NarrativeLog.prefab new file mode 100644 index 0000000..9c94da3 --- /dev/null +++ b/Assets/Fungus/Resources/Prefabs/NarrativeLog.prefab @@ -0,0 +1,434 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!1 &3892339027384508655 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 3892339027384508654} + - component: {fileID: 3892339027384508652} + - component: {fileID: 3892339027384508653} + m_Layer: 5 + m_Name: Background + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!224 &3892339027384508654 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 3892339027384508655} + 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: 3892339028978780123} + m_RootOrder: 0 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0, y: 0} + m_AnchorMax: {x: 1, y: 1} + m_AnchoredPosition: {x: 0, y: 0} + m_SizeDelta: {x: 0, y: 0} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!222 &3892339027384508652 +CanvasRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 3892339027384508655} + m_CullTransparentMesh: 0 +--- !u!114 &3892339027384508653 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 3892339027384508655} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 1344c3c82d62a2a41a3576d8abb8e3ea, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 0.2783019, g: 0.50158674, b: 1, a: 1} + m_RaycastTarget: 1 + m_OnCullStateChanged: + m_PersistentCalls: + m_Calls: [] + m_Texture: {fileID: 0} + m_UVRect: + serializedVersion: 2 + x: 0 + y: 0 + width: 1 + height: 1 +--- !u!1 &3892339028022738724 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 3892339028022738723} + - component: {fileID: 3892339028022738735} + - component: {fileID: 3892339028022738720} + - component: {fileID: 3892339028022738721} + - component: {fileID: 3892339028022738722} + m_Layer: 5 + m_Name: EntryDisplayHolder + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!224 &3892339028022738723 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 3892339028022738724} + 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: 3892339028978780123} + m_RootOrder: 1 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0, y: 1} + m_AnchorMax: {x: 0, y: 1} + m_AnchoredPosition: {x: 0, y: 0.000015258789} + m_SizeDelta: {x: 600, y: 0} + m_Pivot: {x: 0, y: 1} +--- !u!222 &3892339028022738735 +CanvasRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 3892339028022738724} + m_CullTransparentMesh: 0 +--- !u!114 &3892339028022738720 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 3892339028022738724} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: fe87c0e1cc204ed48ad3b37840f39efc, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 0.2783019, g: 0.50158674, b: 1, a: 1} + m_RaycastTarget: 1 + m_OnCullStateChanged: + m_PersistentCalls: + m_Calls: [] + m_Sprite: {fileID: 10907, guid: 0000000000000000f000000000000000, type: 0} + m_Type: 1 + m_PreserveAspect: 0 + m_FillCenter: 1 + m_FillMethod: 4 + m_FillAmount: 1 + m_FillClockwise: 1 + m_FillOrigin: 0 + m_UseSpriteMesh: 0 + m_PixelsPerUnitMultiplier: 1 +--- !u!114 &3892339028022738721 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 3892339028022738724} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 59f8146938fff824cb5fd77236b75775, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Padding: + m_Left: 0 + m_Right: 0 + m_Top: 0 + m_Bottom: 0 + m_ChildAlignment: 0 + m_Spacing: 0 + m_ChildForceExpandWidth: 1 + m_ChildForceExpandHeight: 0 + m_ChildControlWidth: 1 + m_ChildControlHeight: 1 + m_ChildScaleWidth: 0 + m_ChildScaleHeight: 0 +--- !u!114 &3892339028022738722 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 3892339028022738724} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 3245ec927659c4140ac4f8d17403cc18, type: 3} + m_Name: + m_EditorClassIdentifier: + m_HorizontalFit: 0 + m_VerticalFit: 2 +--- !u!1 &3892339028774243865 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 3892339028774243842} + - component: {fileID: 3892339028774243843} + - component: {fileID: 3892339028774243844} + - component: {fileID: 3892339028774243845} + - component: {fileID: 3892339028774243846} + - component: {fileID: 3892339028774243864} + m_Layer: 5 + m_Name: NarrativeLog + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!224 &3892339028774243842 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 3892339028774243865} + 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: 3892339028978780123} + m_Father: {fileID: 0} + m_RootOrder: 0 + 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!223 &3892339028774243843 +Canvas: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 3892339028774243865} + 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!114 &3892339028774243844 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 3892339028774243865} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 0cd44c1031e13a943bb63640046fad76, 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!114 &3892339028774243845 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 3892339028774243865} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: dc42784cf147c0c48a680349fa168899, type: 3} + m_Name: + m_EditorClassIdentifier: + m_IgnoreReversedGraphics: 1 + m_BlockingObjects: 0 + m_BlockingMask: + serializedVersion: 2 + m_Bits: 4294967295 +--- !u!225 &3892339028774243846 +CanvasGroup: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 3892339028774243865} + m_Enabled: 1 + m_Alpha: 1 + m_Interactable: 1 + m_BlocksRaycasts: 1 + m_IgnoreParentGroups: 0 +--- !u!114 &3892339028774243864 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 3892339028774243865} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: fde579c9edfbe7e469349e39e2a87a48, type: 3} + m_Name: + m_EditorClassIdentifier: + entryDisplayPrefab: {fileID: 2879084013005042991, guid: 243a94cf6d8dda84f8351f4289587571, + type: 3} + entryHolder: {fileID: 3892339028022738723} +--- !u!1 &3892339028978780124 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 3892339028978780123} + - component: {fileID: 3892339028978780103} + - component: {fileID: 3892339028978780120} + - component: {fileID: 3892339028978780121} + - component: {fileID: 3892339028978780122} + m_Layer: 5 + m_Name: MainWindow + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!224 &3892339028978780123 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 3892339028978780124} + 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: + - {fileID: 3892339027384508654} + - {fileID: 3892339028022738723} + m_Father: {fileID: 3892339028774243842} + m_RootOrder: 0 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0.5, y: 0.5} + m_AnchorMax: {x: 0.5, y: 0.5} + m_AnchoredPosition: {x: 0, y: 108.70001} + m_SizeDelta: {x: 600, y: 300} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!222 &3892339028978780103 +CanvasRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 3892339028978780124} + m_CullTransparentMesh: 0 +--- !u!114 &3892339028978780120 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 3892339028978780124} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: fe87c0e1cc204ed48ad3b37840f39efc, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 1, g: 1, b: 1, a: 0.392} + m_RaycastTarget: 1 + m_OnCullStateChanged: + m_PersistentCalls: + m_Calls: [] + m_Sprite: {fileID: 10907, guid: 0000000000000000f000000000000000, type: 0} + m_Type: 1 + m_PreserveAspect: 0 + m_FillCenter: 1 + m_FillMethod: 4 + m_FillAmount: 1 + m_FillClockwise: 1 + m_FillOrigin: 0 + m_UseSpriteMesh: 0 + m_PixelsPerUnitMultiplier: 1 +--- !u!114 &3892339028978780121 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 3892339028978780124} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 1aa08ab6e0800fa44ae55d278d1423e3, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Content: {fileID: 3892339028022738723} + m_Horizontal: 0 + m_Vertical: 1 + m_MovementType: 2 + m_Elasticity: 0.1 + m_Inertia: 1 + m_DecelerationRate: 0.135 + m_ScrollSensitivity: 1 + m_Viewport: {fileID: 0} + m_HorizontalScrollbar: {fileID: 0} + m_VerticalScrollbar: {fileID: 0} + m_HorizontalScrollbarVisibility: 0 + m_VerticalScrollbarVisibility: 0 + m_HorizontalScrollbarSpacing: 0 + m_VerticalScrollbarSpacing: 0 + m_OnValueChanged: + m_PersistentCalls: + m_Calls: [] +--- !u!114 &3892339028978780122 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 3892339028978780124} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 31a19414c41e5ae4aae2af33fee712f6, type: 3} + m_Name: + m_EditorClassIdentifier: + m_ShowMaskGraphic: 1 diff --git a/Assets/Fungus/Resources/Prefabs/NarrativeLog.prefab.meta b/Assets/Fungus/Resources/Prefabs/NarrativeLog.prefab.meta new file mode 100644 index 0000000..d675b9f --- /dev/null +++ b/Assets/Fungus/Resources/Prefabs/NarrativeLog.prefab.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: bffd475e4bfb82f49810ceafe8d17b78 +PrefabImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Resources/Prefabs/NarrativeLogEntryDisplay.prefab b/Assets/Fungus/Resources/Prefabs/NarrativeLogEntryDisplay.prefab new file mode 100644 index 0000000..6f602b6 --- /dev/null +++ b/Assets/Fungus/Resources/Prefabs/NarrativeLogEntryDisplay.prefab @@ -0,0 +1,269 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!1 &2333275596563789949 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 8885489252217067950} + - component: {fileID: 7933068750079926288} + - component: {fileID: 4379489694222926579} + m_Layer: 5 + m_Name: NameText + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!224 &8885489252217067950 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 2333275596563789949} + 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: 2481548615123137394} + m_RootOrder: 0 + 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.5, y: 0.5} +--- !u!222 &7933068750079926288 +CanvasRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 2333275596563789949} + m_CullTransparentMesh: 0 +--- !u!114 &4379489694222926579 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 2333275596563789949} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 5f7201a12d95ffc409449d95f23cf332, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 1, g: 1, b: 1, a: 1} + m_RaycastTarget: 1 + m_OnCullStateChanged: + m_PersistentCalls: + m_Calls: [] + m_FontData: + m_Font: {fileID: 12800000, guid: 64bd3e45f7a714f16b3c213f55f17fea, type: 3} + m_FontSize: 18 + m_FontStyle: 0 + m_BestFit: 0 + m_MinSize: 1 + m_MaxSize: 40 + m_Alignment: 0 + m_AlignByGeometry: 0 + m_RichText: 1 + m_HorizontalOverflow: 0 + m_VerticalOverflow: 0 + m_LineSpacing: 1 + m_Text: Name +--- !u!1 &3511986559566215052 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 3365827255933976305} + - component: {fileID: 3857872114285753493} + - component: {fileID: 19882628764411882} + m_Layer: 5 + m_Name: StoryText + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!224 &3365827255933976305 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 3511986559566215052} + 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: 2481548615123137394} + m_RootOrder: 1 + 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.5, y: 0.5} +--- !u!222 &3857872114285753493 +CanvasRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 3511986559566215052} + m_CullTransparentMesh: 0 +--- !u!114 &19882628764411882 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 3511986559566215052} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 5f7201a12d95ffc409449d95f23cf332, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 0.19607843, g: 0.19607843, b: 0.19607843, a: 1} + m_RaycastTarget: 1 + m_OnCullStateChanged: + m_PersistentCalls: + m_Calls: [] + m_FontData: + m_Font: {fileID: 12800000, guid: 64bd3e45f7a714f16b3c213f55f17fea, type: 3} + m_FontSize: 22 + m_FontStyle: 0 + m_BestFit: 0 + m_MinSize: 2 + m_MaxSize: 40 + m_Alignment: 0 + m_AlignByGeometry: 0 + m_RichText: 1 + m_HorizontalOverflow: 0 + m_VerticalOverflow: 0 + m_LineSpacing: 1 + m_Text: New Text +--- !u!1 &9061313995661533662 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 2481548615123137394} + - component: {fileID: 3382758035194104851} + - component: {fileID: 819304301769093009} + - component: {fileID: 5508376540251964814} + - component: {fileID: 2879084013005042991} + m_Layer: 5 + m_Name: NarrativeLogEntryDisplay + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!224 &2481548615123137394 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 9061313995661533662} + 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: + - {fileID: 8885489252217067950} + - {fileID: 3365827255933976305} + m_Father: {fileID: 0} + m_RootOrder: 0 + 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: 278} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!222 &3382758035194104851 +CanvasRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 9061313995661533662} + m_CullTransparentMesh: 0 +--- !u!114 &819304301769093009 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 9061313995661533662} + m_Enabled: 0 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 1344c3c82d62a2a41a3576d8abb8e3ea, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 1, g: 1, b: 1, a: 1} + m_RaycastTarget: 1 + m_OnCullStateChanged: + m_PersistentCalls: + m_Calls: [] + m_Texture: {fileID: 0} + m_UVRect: + serializedVersion: 2 + x: 0 + y: 0 + width: 1 + height: 1 +--- !u!114 &5508376540251964814 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 9061313995661533662} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 59f8146938fff824cb5fd77236b75775, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Padding: + m_Left: 10 + m_Right: 10 + m_Top: 10 + m_Bottom: 10 + m_ChildAlignment: 0 + m_Spacing: 0 + m_ChildForceExpandWidth: 1 + m_ChildForceExpandHeight: 1 + m_ChildControlWidth: 1 + m_ChildControlHeight: 1 + m_ChildScaleWidth: 0 + m_ChildScaleHeight: 0 +--- !u!114 &2879084013005042991 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 9061313995661533662} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 824b58b7741a0dd4e9b43693c47b24f7, type: 3} + m_Name: + m_EditorClassIdentifier: + nameTextField: {fileID: 4379489694222926579} + storyTextField: {fileID: 19882628764411882} diff --git a/Assets/Fungus/Resources/Prefabs/NarrativeLogEntryDisplay.prefab.meta b/Assets/Fungus/Resources/Prefabs/NarrativeLogEntryDisplay.prefab.meta new file mode 100644 index 0000000..cad28ab --- /dev/null +++ b/Assets/Fungus/Resources/Prefabs/NarrativeLogEntryDisplay.prefab.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: 243a94cf6d8dda84f8351f4289587571 +PrefabImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Resources/Prefabs/ParallaxSprite.prefab b/Assets/Fungus/Resources/Prefabs/ParallaxSprite.prefab new file mode 100644 index 0000000..80469ba --- /dev/null +++ b/Assets/Fungus/Resources/Prefabs/ParallaxSprite.prefab @@ -0,0 +1,90 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!1 &100000 +GameObject: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + serializedVersion: 4 + m_Component: + - 4: {fileID: 400000} + - 212: {fileID: 21200000} + - 114: {fileID: 11400000} + m_Layer: 0 + m_Name: ParallaxSprite + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &400000 +Transform: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 100000} + 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_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_Children: [] + m_Father: {fileID: 0} + m_RootOrder: 0 +--- !u!114 &11400000 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 100000} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 3afab7986c14e4b7cbd982245a28b9a5, type: 3} + m_Name: + m_EditorClassIdentifier: + backgroundSprite: {fileID: 0} + parallaxScale: {x: 0.25, y: 0} + accelerometerScale: 0.5 +--- !u!212 &21200000 +SpriteRenderer: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 100000} + m_Enabled: 1 + m_CastShadows: 0 + m_ReceiveShadows: 0 + m_MotionVectors: 1 + m_LightProbeUsage: 0 + m_ReflectionProbeUsage: 0 + m_Materials: + - {fileID: 10754, guid: 0000000000000000f000000000000000, type: 0} + m_SubsetIndices: + 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_SelectedWireframeHidden: 1 + m_MinimumChartSize: 4 + m_AutoUVMaxDistance: 0.5 + m_AutoUVMaxAngle: 89 + m_LightmapParameters: {fileID: 0} + m_SortingLayerID: 0 + m_SortingOrder: 1 + m_Sprite: {fileID: 21300000, guid: ea8f56c43254d41728f5ac4e8299b6c9, type: 3} + m_Color: {r: 1, g: 1, b: 1, a: 1} + m_FlipX: 0 + m_FlipY: 0 +--- !u!1001 &100100000 +Prefab: + m_ObjectHideFlags: 1 + serializedVersion: 2 + m_Modification: + m_TransformParent: {fileID: 0} + m_Modifications: [] + m_RemovedComponents: [] + m_ParentPrefab: {fileID: 0} + m_RootGameObject: {fileID: 100000} + m_IsPrefabParent: 1 diff --git a/Assets/Fungus/Resources/Prefabs/ParallaxSprite.prefab.meta b/Assets/Fungus/Resources/Prefabs/ParallaxSprite.prefab.meta new file mode 100644 index 0000000..ad410e4 --- /dev/null +++ b/Assets/Fungus/Resources/Prefabs/ParallaxSprite.prefab.meta @@ -0,0 +1,4 @@ +fileFormatVersion: 2 +guid: fbafb8431307c42c9b1bfb9b27f6bd98 +NativeFormatImporter: + userData: diff --git a/Assets/Fungus/Resources/Prefabs/SaveData.prefab b/Assets/Fungus/Resources/Prefabs/SaveData.prefab new file mode 100644 index 0000000..f80bbcb --- /dev/null +++ b/Assets/Fungus/Resources/Prefabs/SaveData.prefab @@ -0,0 +1,54 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!1001 &100100000 +Prefab: + m_ObjectHideFlags: 1 + serializedVersion: 2 + m_Modification: + m_TransformParent: {fileID: 0} + m_Modifications: [] + m_RemovedComponents: [] + m_ParentPrefab: {fileID: 0} + m_RootGameObject: {fileID: 1310974650352510} + m_IsPrefabParent: 1 +--- !u!1 &1310974650352510 +GameObject: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + serializedVersion: 5 + m_Component: + - component: {fileID: 4704521519618994} + - component: {fileID: 114272980009688704} + m_Layer: 0 + m_Name: SaveData + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &4704521519618994 +Transform: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1310974650352510} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: 1079.5829, y: 593.8655, z: 0} + 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!114 &114272980009688704 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1310974650352510} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 60d92858185944732937980806717234, type: 3} + m_Name: + m_EditorClassIdentifier: + flowcharts: [] diff --git a/Assets/Fungus/Resources/Prefabs/SaveData.prefab.meta b/Assets/Fungus/Resources/Prefabs/SaveData.prefab.meta new file mode 100644 index 0000000..cc54c79 --- /dev/null +++ b/Assets/Fungus/Resources/Prefabs/SaveData.prefab.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: eae76c041b933476bbe9bdd4c3d80793 +timeCreated: 1483972230 +licenseType: Store +NativeFormatImporter: + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Resources/Prefabs/SaveMenu.prefab b/Assets/Fungus/Resources/Prefabs/SaveMenu.prefab new file mode 100644 index 0000000..0e43163 --- /dev/null +++ b/Assets/Fungus/Resources/Prefabs/SaveMenu.prefab @@ -0,0 +1,3244 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!1001 &100100000 +Prefab: + m_ObjectHideFlags: 1 + serializedVersion: 2 + m_Modification: + m_TransformParent: {fileID: 0} + m_Modifications: [] + m_RemovedComponents: [] + m_ParentPrefab: {fileID: 0} + m_RootGameObject: {fileID: 1000012899462148} + m_IsPrefabParent: 1 +--- !u!1 &1000010010131774 +GameObject: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + serializedVersion: 5 + m_Component: + - component: {fileID: 224000012272122410} + - component: {fileID: 222000011100116716} + - component: {fileID: 114000010632254224} + m_Layer: 5 + m_Name: Text + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!1 &1000010142133612 +GameObject: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + serializedVersion: 5 + m_Component: + - component: {fileID: 224000013492386186} + - component: {fileID: 222000013799985356} + - component: {fileID: 114000010080207576} + m_Layer: 5 + m_Name: Text + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!1 &1000011114926160 +GameObject: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + serializedVersion: 5 + m_Component: + - component: {fileID: 224000013898185038} + - component: {fileID: 222000010789171018} + - component: {fileID: 114000013665828214} + - component: {fileID: 114000011771453486} + m_Layer: 5 + m_Name: LoadButton + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!1 &1000011815857470 +GameObject: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + serializedVersion: 5 + m_Component: + - component: {fileID: 224000012687811630} + - component: {fileID: 222000010636408894} + - component: {fileID: 114000014272909388} + - component: {fileID: 114000012958020502} + m_Layer: 5 + m_Name: RestartButton + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!1 &1000012178065012 +GameObject: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + serializedVersion: 5 + m_Component: + - component: {fileID: 224000012150207008} + - component: {fileID: 222000013070489478} + - component: {fileID: 114000011397682902} + - component: {fileID: 114000010610974372} + m_Layer: 5 + m_Name: SaveButton + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!1 &1000012899462148 +GameObject: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + serializedVersion: 5 + m_Component: + - component: {fileID: 224000011191842766} + - component: {fileID: 114000010566872590} + - component: {fileID: 114232099891880756} + - component: {fileID: 223000014176703286} + - component: {fileID: 114000011070993724} + - component: {fileID: 114000011308786264} + - component: {fileID: 82000012749735044} + - component: {fileID: 114653612942904624} + m_Layer: 5 + m_Name: SaveMenu + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!1 &1000013007313816 +GameObject: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + serializedVersion: 5 + m_Component: + - component: {fileID: 224000012525218478} + - component: {fileID: 222000010752835546} + - component: {fileID: 114000013144661380} + - component: {fileID: 114000013850039374} + - component: {fileID: 225000012423540070} + m_Layer: 5 + m_Name: Panel + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!1 &1000013032760896 +GameObject: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + serializedVersion: 5 + m_Component: + - component: {fileID: 224000013719675004} + - component: {fileID: 222000011515314216} + - component: {fileID: 114000010615359398} + m_Layer: 5 + m_Name: Text + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!1 &1000013089762296 +GameObject: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + serializedVersion: 5 + m_Component: + - component: {fileID: 224000012590701094} + - component: {fileID: 222000012009353026} + - component: {fileID: 114000013129043042} + - component: {fileID: 114000013791261618} + m_Layer: 5 + m_Name: RewindButton + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!1 &1000013166397642 +GameObject: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + serializedVersion: 5 + m_Component: + - component: {fileID: 224000013748593462} + - component: {fileID: 222000010966400006} + - component: {fileID: 114000012438047488} + - component: {fileID: 114000012074514418} + - component: {fileID: 114000010366395696} + m_Layer: 5 + m_Name: MenuButton + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!1 &1000013328246242 +GameObject: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + serializedVersion: 5 + m_Component: + - component: {fileID: 224000013149320576} + - component: {fileID: 222000011280725060} + - component: {fileID: 114000011862434686} + - component: {fileID: 114000014122010370} + m_Layer: 5 + m_Name: FastForwardButton + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!1 &1016451151234458 +GameObject: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + serializedVersion: 5 + m_Component: + - component: {fileID: 224054090195745834} + m_Layer: 5 + m_Name: Sliding Area + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!1 &1017909244067428 +GameObject: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + serializedVersion: 5 + m_Component: + - component: {fileID: 224756314496247326} + - component: {fileID: 222346054301214274} + - component: {fileID: 114625242687138120} + - component: {fileID: 114305052877464294} + m_Layer: 5 + m_Name: Scrollbar Horizontal + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!1 &1064076235247030 +GameObject: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + serializedVersion: 5 + m_Component: + - component: {fileID: 224656606278108370} + - component: {fileID: 222989954932444316} + - component: {fileID: 114511501333539900} + m_Layer: 5 + m_Name: Handle + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!1 &1088690678392472 +GameObject: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + serializedVersion: 5 + m_Component: + - component: {fileID: 224865476632621786} + - component: {fileID: 114522020581970318} + - component: {fileID: 222356757625515164} + - component: {fileID: 114478888494047242} + - component: {fileID: 114283909382663090} + m_Layer: 5 + m_Name: DebugView + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 0 +--- !u!1 &1134525095276268 +GameObject: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + serializedVersion: 5 + m_Component: + - component: {fileID: 224506178468526888} + m_Layer: 5 + m_Name: Sliding Area + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!1 &1142916231164870 +GameObject: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + serializedVersion: 5 + m_Component: + - component: {fileID: 224160472953040096} + - component: {fileID: 222114849256167646} + - component: {fileID: 114632310104905278} + m_Layer: 5 + m_Name: Handle + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!1 &1171231265388170 +GameObject: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + serializedVersion: 5 + m_Component: + - component: {fileID: 224258996373127644} + - component: {fileID: 222243915251368484} + - component: {fileID: 114119135089980988} + - component: {fileID: 114993625917992760} + m_Layer: 5 + m_Name: Scrollbar Vertical + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!1 &1210356177377382 +GameObject: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + serializedVersion: 5 + m_Component: + - component: {fileID: 224353886759344458} + m_Layer: 5 + m_Name: Sliding Area + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!1 &1213721919401690 +GameObject: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + serializedVersion: 5 + m_Component: + - component: {fileID: 224148166873360954} + - component: {fileID: 222706451263006018} + - component: {fileID: 114820767466158250} + - component: {fileID: 114795890241856860} + m_Layer: 5 + m_Name: Viewport + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!1 &1216016164557284 +GameObject: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + serializedVersion: 5 + m_Component: + - component: {fileID: 224259322050551826} + - component: {fileID: 114302650921901322} + - component: {fileID: 222328673954104156} + - component: {fileID: 114044970116333216} + m_Layer: 5 + m_Name: Viewport + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!1 &1333170469647788 +GameObject: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + serializedVersion: 5 + m_Component: + - component: {fileID: 224819725728513600} + - component: {fileID: 222271235964525112} + - component: {fileID: 114920314574492042} + m_Layer: 5 + m_Name: Image + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!1 &1446634631688098 +GameObject: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + serializedVersion: 5 + m_Component: + - component: {fileID: 224900434480553846} + - component: {fileID: 222213165252159728} + - component: {fileID: 114723389948375156} + - component: {fileID: 114881856777117484} + m_Layer: 5 + m_Name: Scrollbar Vertical + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!1 &1562890099353150 +GameObject: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + serializedVersion: 5 + m_Component: + - component: {fileID: 224331103297166980} + - component: {fileID: 222091168920081386} + - component: {fileID: 114738251385494794} + m_Layer: 5 + m_Name: Content + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!1 &1563859998553076 +GameObject: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + serializedVersion: 5 + m_Component: + - component: {fileID: 224670260353415052} + - component: {fileID: 114162492929892552} + - component: {fileID: 222849644082718540} + - component: {fileID: 114697660017191064} + - component: {fileID: 225545614455694522} + m_Layer: 5 + m_Name: NarrativeLogView + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!1 &1575375668969800 +GameObject: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + serializedVersion: 5 + m_Component: + - component: {fileID: 224304764365683998} + - component: {fileID: 222516594292902920} + - component: {fileID: 114763048961342110} + - component: {fileID: 114193710787652350} + - component: {fileID: 114818094421102834} + - component: {fileID: 225210578159906698} + - component: {fileID: 114454498723883902} + m_Layer: 5 + m_Name: NarrativeLog + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!1 &1662928791296828 +GameObject: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + serializedVersion: 5 + m_Component: + - component: {fileID: 224813276203911662} + - component: {fileID: 222583787261386450} + - component: {fileID: 114153843942322126} + m_Layer: 5 + m_Name: Handle + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!1 &1685645919552228 +GameObject: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + serializedVersion: 5 + m_Component: + - component: {fileID: 224902324276391688} + m_Layer: 5 + m_Name: Sliding Area + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!1 &1791663633598476 +GameObject: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + serializedVersion: 5 + m_Component: + - component: {fileID: 224673677253739666} + - component: {fileID: 222976103522131750} + - component: {fileID: 114278905042580584} + - component: {fileID: 114197002012117692} + m_Layer: 5 + m_Name: Scrollbar Horizontal + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!1 &1801582794521622 +GameObject: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + serializedVersion: 5 + m_Component: + - component: {fileID: 224682822578024892} + - component: {fileID: 222456543252686318} + - component: {fileID: 114875751214506758} + m_Layer: 5 + m_Name: Image + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!1 &1898064487847954 +GameObject: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + serializedVersion: 5 + m_Component: + - component: {fileID: 224255369405830710} + - component: {fileID: 222529376750664854} + - component: {fileID: 114491427777887672} + m_Layer: 5 + m_Name: Image + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!1 &1943371609894262 +GameObject: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + serializedVersion: 5 + m_Component: + - component: {fileID: 224058802661620446} + - component: {fileID: 222870937324826524} + - component: {fileID: 114625077397298586} + - component: {fileID: 114741111563894306} + m_Layer: 5 + m_Name: Content + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!1 &1949168787226118 +GameObject: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + serializedVersion: 5 + m_Component: + - component: {fileID: 224147037515329490} + - component: {fileID: 222905370124457276} + - component: {fileID: 114180359308419172} + - component: {fileID: 114153967484647106} + - component: {fileID: 114162572505854518} + m_Layer: 5 + m_Name: Buttons + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!1 &1997369251198830 +GameObject: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + serializedVersion: 5 + m_Component: + - component: {fileID: 224880810258273170} + - component: {fileID: 222800070994067700} + - component: {fileID: 114056508902046002} + m_Layer: 5 + m_Name: Handle + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!82 &82000012749735044 +AudioSource: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1000012899462148} + m_Enabled: 1 + serializedVersion: 4 + OutputAudioMixerGroup: {fileID: 0} + m_audioClip: {fileID: 8300000, guid: 14a396b1562834718b2d52b9c4639264, type: 3} + m_PlayOnAwake: 0 + m_Volume: 1 + m_Pitch: 1 + Loop: 0 + Mute: 0 + Spatialize: 0 + SpatializePostEffects: 0 + Priority: 128 + DopplerLevel: 1 + MinDistance: 1 + MaxDistance: 500 + Pan2D: 0 + rolloffMode: 0 + BypassEffects: 0 + BypassListenerEffects: 0 + BypassReverbZones: 1 + rolloffCustomCurve: + serializedVersion: 2 + m_Curve: + - serializedVersion: 2 + time: 0 + value: 1 + inSlope: 0 + outSlope: 0 + tangentMode: 0 + - serializedVersion: 2 + time: 1 + value: 0 + inSlope: 0 + outSlope: 0 + tangentMode: 0 + m_PreInfinity: 2 + m_PostInfinity: 2 + m_RotationOrder: 4 + panLevelCustomCurve: + serializedVersion: 2 + m_Curve: + - serializedVersion: 2 + time: 0 + value: 0 + inSlope: 0 + outSlope: 0 + tangentMode: 0 + m_PreInfinity: 2 + m_PostInfinity: 2 + m_RotationOrder: 0 + spreadCustomCurve: + serializedVersion: 2 + m_Curve: + - serializedVersion: 2 + time: 0 + value: 0 + inSlope: 0 + outSlope: 0 + tangentMode: 0 + m_PreInfinity: 2 + m_PostInfinity: 2 + m_RotationOrder: 0 + reverbZoneMixCustomCurve: + serializedVersion: 2 + m_Curve: + - serializedVersion: 2 + time: 0 + value: 1 + inSlope: 0 + outSlope: 0 + tangentMode: 0 + m_PreInfinity: 2 + m_PostInfinity: 2 + m_RotationOrder: 0 +--- !u!114 &114000010080207576 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1000010142133612} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 708705254, guid: f5f67c52d1564df4a8936ccd202a3bd8, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 0.19607843, g: 0.19607843, b: 0.19607843, 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_FontData: + m_Font: {fileID: 10102, guid: 0000000000000000e000000000000000, type: 0} + m_FontSize: 14 + m_FontStyle: 0 + m_BestFit: 0 + m_MinSize: 1 + m_MaxSize: 40 + m_Alignment: 4 + m_AlignByGeometry: 0 + m_RichText: 1 + m_HorizontalOverflow: 0 + m_VerticalOverflow: 0 + m_LineSpacing: 1 + m_Text: Load +--- !u!114 &114000010366395696 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1000013166397642} + m_Enabled: 0 + m_EditorHideFlags: 0 + m_Script: {fileID: 1679637790, guid: f5f67c52d1564df4a8936ccd202a3bd8, type: 3} + m_Name: + m_EditorClassIdentifier: + m_IgnoreLayout: 0 + m_MinWidth: -1 + m_MinHeight: -1 + m_PreferredWidth: -1 + m_PreferredHeight: -1 + m_FlexibleWidth: -1 + m_FlexibleHeight: -1 +--- !u!114 &114000010566872590 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1000012899462148} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: abe25ebf9ddc8416ead6f30d4671fdbf, type: 3} + m_Name: + m_EditorClassIdentifier: + saveDataKey: save_data + loadOnStart: 0 + autoSave: 0 + restartDeletesSave: 1 + saveMenuGroup: {fileID: 225000012423540070} + saveMenuButton: {fileID: 114000012074514418} + saveButton: {fileID: 114000010610974372} + loadButton: {fileID: 114000011771453486} + rewindButton: {fileID: 114000013791261618} + forwardButton: {fileID: 114000014122010370} + restartButton: {fileID: 114000012958020502} + debugView: {fileID: 114522020581970318} +--- !u!114 &114000010610974372 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1000012178065012} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 1392445389, guid: f5f67c52d1564df4a8936ccd202a3bd8, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Navigation: + m_Mode: 3 + m_SelectOnUp: {fileID: 0} + m_SelectOnDown: {fileID: 0} + m_SelectOnLeft: {fileID: 0} + m_SelectOnRight: {fileID: 0} + m_Transition: 1 + m_Colors: + m_NormalColor: {r: 1, g: 1, b: 1, a: 1} + m_HighlightedColor: {r: 0.9607843, g: 0.9607843, b: 0.9607843, a: 1} + m_PressedColor: {r: 0.78431374, g: 0.78431374, b: 0.78431374, a: 1} + m_DisabledColor: {r: 0.78431374, g: 0.78431374, b: 0.78431374, a: 0.5019608} + m_ColorMultiplier: 1 + m_FadeDuration: 0.1 + m_SpriteState: + m_HighlightedSprite: {fileID: 0} + m_PressedSprite: {fileID: 0} + m_DisabledSprite: {fileID: 0} + m_AnimationTriggers: + m_NormalTrigger: Normal + m_HighlightedTrigger: Highlighted + m_PressedTrigger: Pressed + m_DisabledTrigger: Disabled + m_Interactable: 1 + m_TargetGraphic: {fileID: 114000011397682902} + m_OnClick: + m_PersistentCalls: + m_Calls: + - m_Target: {fileID: 114000010566872590} + m_MethodName: Save + m_Mode: 1 + m_Arguments: + m_ObjectArgument: {fileID: 0} + m_ObjectArgumentAssemblyTypeName: UnityEngine.Object, UnityEngine + m_IntArgument: 0 + m_FloatArgument: 0 + m_StringArgument: + m_BoolArgument: 0 + m_CallState: 2 + m_TypeName: UnityEngine.UI.Button+ButtonClickedEvent, UnityEngine.UI, Version=1.0.0.0, + Culture=neutral, PublicKeyToken=null +--- !u!114 &114000010615359398 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1000013032760896} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 708705254, guid: f5f67c52d1564df4a8936ccd202a3bd8, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 0.19607843, g: 0.19607843, b: 0.19607843, 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_FontData: + m_Font: {fileID: 10102, guid: 0000000000000000e000000000000000, type: 0} + m_FontSize: 14 + m_FontStyle: 0 + m_BestFit: 0 + m_MinSize: 1 + m_MaxSize: 40 + m_Alignment: 4 + m_AlignByGeometry: 0 + m_RichText: 1 + m_HorizontalOverflow: 0 + m_VerticalOverflow: 0 + m_LineSpacing: 1 + m_Text: Restart +--- !u!114 &114000010632254224 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1000010010131774} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 708705254, guid: f5f67c52d1564df4a8936ccd202a3bd8, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 0.19607843, g: 0.19607843, b: 0.19607843, 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_FontData: + m_Font: {fileID: 10102, guid: 0000000000000000e000000000000000, type: 0} + m_FontSize: 14 + m_FontStyle: 0 + m_BestFit: 0 + m_MinSize: 1 + m_MaxSize: 40 + m_Alignment: 4 + m_AlignByGeometry: 0 + m_RichText: 1 + m_HorizontalOverflow: 0 + m_VerticalOverflow: 0 + m_LineSpacing: 1 + m_Text: Save +--- !u!114 &114000011070993724 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1000012899462148} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 1980459831, guid: f5f67c52d1564df4a8936ccd202a3bd8, type: 3} + m_Name: + m_EditorClassIdentifier: + m_UiScaleMode: 1 + m_ReferencePixelsPerUnit: 100 + m_ScaleFactor: 1 + m_ReferenceResolution: {x: 800, y: 600} + m_ScreenMatchMode: 0 + m_MatchWidthOrHeight: 0.5 + m_PhysicalUnit: 3 + m_FallbackScreenDPI: 96 + m_DefaultSpriteDPI: 96 + m_DynamicPixelsPerUnit: 1 +--- !u!114 &114000011308786264 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1000012899462148} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 1301386320, guid: f5f67c52d1564df4a8936ccd202a3bd8, type: 3} + m_Name: + m_EditorClassIdentifier: + m_IgnoreReversedGraphics: 1 + m_BlockingObjects: 0 + m_BlockingMask: + serializedVersion: 2 + m_Bits: 4294967295 +--- !u!114 &114000011397682902 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1000012178065012} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: -765806418, guid: f5f67c52d1564df4a8936ccd202a3bd8, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 1, g: 1, b: 1, 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: 9bdedfa4650174106a3115624f193b99, type: 3} + m_Type: 1 + m_PreserveAspect: 0 + m_FillCenter: 1 + m_FillMethod: 4 + m_FillAmount: 1 + m_FillClockwise: 1 + m_FillOrigin: 0 +--- !u!114 &114000011771453486 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1000011114926160} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 1392445389, guid: f5f67c52d1564df4a8936ccd202a3bd8, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Navigation: + m_Mode: 3 + m_SelectOnUp: {fileID: 0} + m_SelectOnDown: {fileID: 0} + m_SelectOnLeft: {fileID: 0} + m_SelectOnRight: {fileID: 0} + m_Transition: 1 + m_Colors: + m_NormalColor: {r: 1, g: 1, b: 1, a: 1} + m_HighlightedColor: {r: 0.9607843, g: 0.9607843, b: 0.9607843, a: 1} + m_PressedColor: {r: 0.78431374, g: 0.78431374, b: 0.78431374, a: 1} + m_DisabledColor: {r: 0.78431374, g: 0.78431374, b: 0.78431374, a: 0.5019608} + m_ColorMultiplier: 1 + m_FadeDuration: 0.1 + m_SpriteState: + m_HighlightedSprite: {fileID: 0} + m_PressedSprite: {fileID: 0} + m_DisabledSprite: {fileID: 0} + m_AnimationTriggers: + m_NormalTrigger: Normal + m_HighlightedTrigger: Highlighted + m_PressedTrigger: Pressed + m_DisabledTrigger: Disabled + m_Interactable: 1 + m_TargetGraphic: {fileID: 114000013665828214} + m_OnClick: + m_PersistentCalls: + m_Calls: + - m_Target: {fileID: 114000010566872590} + m_MethodName: Load + m_Mode: 1 + m_Arguments: + m_ObjectArgument: {fileID: 0} + m_ObjectArgumentAssemblyTypeName: UnityEngine.Object, UnityEngine + m_IntArgument: 0 + m_FloatArgument: 0 + m_StringArgument: + m_BoolArgument: 0 + m_CallState: 2 + m_TypeName: UnityEngine.UI.Button+ButtonClickedEvent, UnityEngine.UI, Version=1.0.0.0, + Culture=neutral, PublicKeyToken=null +--- !u!114 &114000011862434686 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1000013328246242} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: -765806418, guid: f5f67c52d1564df4a8936ccd202a3bd8, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 1, g: 1, b: 1, 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: 9bdedfa4650174106a3115624f193b99, type: 3} + m_Type: 1 + m_PreserveAspect: 0 + m_FillCenter: 1 + m_FillMethod: 4 + m_FillAmount: 1 + m_FillClockwise: 1 + m_FillOrigin: 0 +--- !u!114 &114000012074514418 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1000013166397642} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 1392445389, guid: f5f67c52d1564df4a8936ccd202a3bd8, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Navigation: + m_Mode: 3 + m_SelectOnUp: {fileID: 0} + m_SelectOnDown: {fileID: 0} + m_SelectOnLeft: {fileID: 0} + m_SelectOnRight: {fileID: 0} + m_Transition: 1 + m_Colors: + m_NormalColor: {r: 1, g: 1, b: 1, a: 1} + m_HighlightedColor: {r: 0.9607843, g: 0.9607843, b: 0.9607843, a: 1} + m_PressedColor: {r: 0.78431374, g: 0.78431374, b: 0.78431374, a: 1} + m_DisabledColor: {r: 0.78431374, g: 0.78431374, b: 0.78431374, a: 0.5019608} + m_ColorMultiplier: 1 + m_FadeDuration: 0.1 + m_SpriteState: + m_HighlightedSprite: {fileID: 0} + m_PressedSprite: {fileID: 0} + m_DisabledSprite: {fileID: 0} + m_AnimationTriggers: + m_NormalTrigger: Normal + m_HighlightedTrigger: Highlighted + m_PressedTrigger: Pressed + m_DisabledTrigger: Disabled + m_Interactable: 1 + m_TargetGraphic: {fileID: 114000012438047488} + m_OnClick: + m_PersistentCalls: + m_Calls: + - m_Target: {fileID: 114000010566872590} + m_MethodName: ToggleSaveMenu + m_Mode: 1 + m_Arguments: + m_ObjectArgument: {fileID: 0} + m_ObjectArgumentAssemblyTypeName: UnityEngine.Object, UnityEngine + m_IntArgument: 0 + m_FloatArgument: 0 + m_StringArgument: + m_BoolArgument: 0 + m_CallState: 2 + - m_Target: {fileID: 114232099891880756} + m_MethodName: ToggleNarrativeLogView + m_Mode: 1 + m_Arguments: + m_ObjectArgument: {fileID: 0} + m_ObjectArgumentAssemblyTypeName: UnityEngine.Object, UnityEngine + m_IntArgument: 0 + m_FloatArgument: 0 + m_StringArgument: + m_BoolArgument: 0 + m_CallState: 2 + m_TypeName: UnityEngine.UI.Button+ButtonClickedEvent, UnityEngine.UI, Version=1.0.0.0, + Culture=neutral, PublicKeyToken=null +--- !u!114 &114000012438047488 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1000013166397642} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: -765806418, guid: f5f67c52d1564df4a8936ccd202a3bd8, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 1, g: 1, b: 1, 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: 9bdedfa4650174106a3115624f193b99, type: 3} + m_Type: 1 + m_PreserveAspect: 0 + m_FillCenter: 1 + m_FillMethod: 4 + m_FillAmount: 1 + m_FillClockwise: 1 + m_FillOrigin: 0 +--- !u!114 &114000012958020502 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1000011815857470} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 1392445389, guid: f5f67c52d1564df4a8936ccd202a3bd8, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Navigation: + m_Mode: 3 + m_SelectOnUp: {fileID: 0} + m_SelectOnDown: {fileID: 0} + m_SelectOnLeft: {fileID: 0} + m_SelectOnRight: {fileID: 0} + m_Transition: 1 + m_Colors: + m_NormalColor: {r: 1, g: 1, b: 1, a: 1} + m_HighlightedColor: {r: 0.9607843, g: 0.9607843, b: 0.9607843, a: 1} + m_PressedColor: {r: 0.78431374, g: 0.78431374, b: 0.78431374, a: 1} + m_DisabledColor: {r: 0.78431374, g: 0.78431374, b: 0.78431374, a: 0.5019608} + m_ColorMultiplier: 1 + m_FadeDuration: 0.1 + m_SpriteState: + m_HighlightedSprite: {fileID: 0} + m_PressedSprite: {fileID: 0} + m_DisabledSprite: {fileID: 0} + m_AnimationTriggers: + m_NormalTrigger: Normal + m_HighlightedTrigger: Highlighted + m_PressedTrigger: Pressed + m_DisabledTrigger: Disabled + m_Interactable: 1 + m_TargetGraphic: {fileID: 114000014272909388} + m_OnClick: + m_PersistentCalls: + m_Calls: + - m_Target: {fileID: 114000010566872590} + m_MethodName: Restart + m_Mode: 1 + m_Arguments: + m_ObjectArgument: {fileID: 0} + m_ObjectArgumentAssemblyTypeName: UnityEngine.Object, UnityEngine + m_IntArgument: 0 + m_FloatArgument: 0 + m_StringArgument: + m_BoolArgument: 0 + m_CallState: 2 + m_TypeName: UnityEngine.UI.Button+ButtonClickedEvent, UnityEngine.UI, Version=1.0.0.0, + Culture=neutral, PublicKeyToken=null +--- !u!114 &114000013129043042 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1000013089762296} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: -765806418, guid: f5f67c52d1564df4a8936ccd202a3bd8, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 1, g: 1, b: 1, 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: 9bdedfa4650174106a3115624f193b99, type: 3} + m_Type: 1 + m_PreserveAspect: 0 + m_FillCenter: 1 + m_FillMethod: 4 + m_FillAmount: 1 + m_FillClockwise: 1 + m_FillOrigin: 0 +--- !u!114 &114000013144661380 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1000013007313816} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: -765806418, guid: f5f67c52d1564df4a8936ccd202a3bd8, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 1, g: 1, b: 1, a: 0.392} + 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: 10907, guid: 0000000000000000f000000000000000, type: 0} + m_Type: 1 + m_PreserveAspect: 0 + m_FillCenter: 1 + m_FillMethod: 4 + m_FillAmount: 1 + m_FillClockwise: 1 + m_FillOrigin: 0 +--- !u!114 &114000013665828214 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1000011114926160} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: -765806418, guid: f5f67c52d1564df4a8936ccd202a3bd8, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 1, g: 1, b: 1, 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: 9bdedfa4650174106a3115624f193b99, type: 3} + m_Type: 1 + m_PreserveAspect: 0 + m_FillCenter: 1 + m_FillMethod: 4 + m_FillAmount: 1 + m_FillClockwise: 1 + m_FillOrigin: 0 +--- !u!114 &114000013791261618 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1000013089762296} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 1392445389, guid: f5f67c52d1564df4a8936ccd202a3bd8, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Navigation: + m_Mode: 3 + m_SelectOnUp: {fileID: 0} + m_SelectOnDown: {fileID: 0} + m_SelectOnLeft: {fileID: 0} + m_SelectOnRight: {fileID: 0} + m_Transition: 1 + m_Colors: + m_NormalColor: {r: 1, g: 1, b: 1, a: 1} + m_HighlightedColor: {r: 0.9607843, g: 0.9607843, b: 0.9607843, a: 1} + m_PressedColor: {r: 0.78431374, g: 0.78431374, b: 0.78431374, a: 1} + m_DisabledColor: {r: 0.78431374, g: 0.78431374, b: 0.78431374, a: 0.5019608} + m_ColorMultiplier: 1 + m_FadeDuration: 0.1 + m_SpriteState: + m_HighlightedSprite: {fileID: 0} + m_PressedSprite: {fileID: 0} + m_DisabledSprite: {fileID: 0} + m_AnimationTriggers: + m_NormalTrigger: Normal + m_HighlightedTrigger: Highlighted + m_PressedTrigger: Pressed + m_DisabledTrigger: Disabled + m_Interactable: 1 + m_TargetGraphic: {fileID: 114000013129043042} + m_OnClick: + m_PersistentCalls: + m_Calls: + - m_Target: {fileID: 114000010566872590} + m_MethodName: Rewind + m_Mode: 1 + m_Arguments: + m_ObjectArgument: {fileID: 0} + m_ObjectArgumentAssemblyTypeName: UnityEngine.Object, UnityEngine + m_IntArgument: 0 + m_FloatArgument: 0 + m_StringArgument: + m_BoolArgument: 0 + m_CallState: 2 + m_TypeName: UnityEngine.UI.Button+ButtonClickedEvent, UnityEngine.UI, Version=1.0.0.0, + Culture=neutral, PublicKeyToken=null +--- !u!114 &114000013850039374 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1000013007313816} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: -405508275, guid: f5f67c52d1564df4a8936ccd202a3bd8, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Padding: + m_Left: 0 + m_Right: 0 + m_Top: 0 + m_Bottom: 0 + m_ChildAlignment: 0 + m_Spacing: 2 + m_ChildForceExpandWidth: 1 + m_ChildForceExpandHeight: 1 + m_ChildControlWidth: 1 + m_ChildControlHeight: 1 +--- !u!114 &114000014122010370 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1000013328246242} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 1392445389, guid: f5f67c52d1564df4a8936ccd202a3bd8, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Navigation: + m_Mode: 3 + m_SelectOnUp: {fileID: 0} + m_SelectOnDown: {fileID: 0} + m_SelectOnLeft: {fileID: 0} + m_SelectOnRight: {fileID: 0} + m_Transition: 1 + m_Colors: + m_NormalColor: {r: 1, g: 1, b: 1, a: 1} + m_HighlightedColor: {r: 0.9607843, g: 0.9607843, b: 0.9607843, a: 1} + m_PressedColor: {r: 0.78431374, g: 0.78431374, b: 0.78431374, a: 1} + m_DisabledColor: {r: 0.78431374, g: 0.78431374, b: 0.78431374, a: 0.5019608} + m_ColorMultiplier: 1 + m_FadeDuration: 0.1 + m_SpriteState: + m_HighlightedSprite: {fileID: 0} + m_PressedSprite: {fileID: 0} + m_DisabledSprite: {fileID: 0} + m_AnimationTriggers: + m_NormalTrigger: Normal + m_HighlightedTrigger: Highlighted + m_PressedTrigger: Pressed + m_DisabledTrigger: Disabled + m_Interactable: 1 + m_TargetGraphic: {fileID: 114000011862434686} + m_OnClick: + m_PersistentCalls: + m_Calls: + - m_Target: {fileID: 114000010566872590} + m_MethodName: FastForward + m_Mode: 1 + m_Arguments: + m_ObjectArgument: {fileID: 0} + m_ObjectArgumentAssemblyTypeName: UnityEngine.Object, UnityEngine + m_IntArgument: 0 + m_FloatArgument: 0 + m_StringArgument: + m_BoolArgument: 0 + m_CallState: 2 + m_TypeName: UnityEngine.UI.Button+ButtonClickedEvent, UnityEngine.UI, Version=1.0.0.0, + Culture=neutral, PublicKeyToken=null +--- !u!114 &114000014272909388 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1000011815857470} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: -765806418, guid: f5f67c52d1564df4a8936ccd202a3bd8, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 1, g: 1, b: 1, 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: 9bdedfa4650174106a3115624f193b99, type: 3} + m_Type: 1 + m_PreserveAspect: 0 + m_FillCenter: 1 + m_FillMethod: 4 + m_FillAmount: 1 + m_FillClockwise: 1 + m_FillOrigin: 0 +--- !u!114 &114044970116333216 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1216016164557284} + 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: 1, g: 1, b: 1, 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: 10917, guid: 0000000000000000f000000000000000, type: 0} + m_Type: 1 + m_PreserveAspect: 0 + m_FillCenter: 1 + m_FillMethod: 4 + m_FillAmount: 1 + m_FillClockwise: 1 + m_FillOrigin: 0 +--- !u!114 &114056508902046002 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1997369251198830} + 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: 1, g: 1, b: 1, 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: 10905, guid: 0000000000000000f000000000000000, type: 0} + m_Type: 1 + m_PreserveAspect: 0 + m_FillCenter: 1 + m_FillMethod: 4 + m_FillAmount: 1 + m_FillClockwise: 1 + m_FillOrigin: 0 +--- !u!114 &114119135089980988 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1171231265388170} + 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: 1, g: 1, b: 1, 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: 10907, guid: 0000000000000000f000000000000000, type: 0} + m_Type: 1 + m_PreserveAspect: 0 + m_FillCenter: 1 + m_FillMethod: 4 + m_FillAmount: 1 + m_FillClockwise: 1 + m_FillOrigin: 0 +--- !u!114 &114153843942322126 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1662928791296828} + 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: 1, g: 1, b: 1, 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: 10905, guid: 0000000000000000f000000000000000, type: 0} + m_Type: 1 + m_PreserveAspect: 0 + m_FillCenter: 1 + m_FillMethod: 4 + m_FillAmount: 1 + m_FillClockwise: 1 + m_FillOrigin: 0 +--- !u!114 &114153967484647106 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1949168787226118} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: -2095666955, guid: f70555f144d8491a825f0804e09c671c, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Padding: + m_Left: 0 + m_Right: 0 + m_Top: 0 + m_Bottom: 0 + m_ChildAlignment: 1 + m_StartCorner: 1 + m_StartAxis: 0 + m_CellSize: {x: 35, y: 30} + m_Spacing: {x: 2, y: 2} + m_Constraint: 0 + m_ConstraintCount: 2 +--- !u!114 &114162492929892552 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1563859998553076} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 1367256648, guid: f70555f144d8491a825f0804e09c671c, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Content: {fileID: 224058802661620446} + m_Horizontal: 0 + m_Vertical: 1 + m_MovementType: 2 + m_Elasticity: 0.1 + m_Inertia: 1 + m_DecelerationRate: 0.135 + m_ScrollSensitivity: 8.39 + m_Viewport: {fileID: 224148166873360954} + m_HorizontalScrollbar: {fileID: 114197002012117692} + m_VerticalScrollbar: {fileID: 114881856777117484} + m_HorizontalScrollbarVisibility: 2 + m_VerticalScrollbarVisibility: 2 + m_HorizontalScrollbarSpacing: -3 + m_VerticalScrollbarSpacing: -3 + m_OnValueChanged: + m_PersistentCalls: + m_Calls: [] + m_TypeName: UnityEngine.UI.ScrollRect+ScrollRectEvent, UnityEngine.UI, Version=1.0.0.0, + Culture=neutral, PublicKeyToken=null +--- !u!114 &114162572505854518 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1949168787226118} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 1679637790, guid: f70555f144d8491a825f0804e09c671c, type: 3} + m_Name: + m_EditorClassIdentifier: + m_IgnoreLayout: 0 + m_MinWidth: -1 + m_MinHeight: -1 + m_PreferredWidth: -1 + m_PreferredHeight: -1 + m_FlexibleWidth: -1 + m_FlexibleHeight: -1 +--- !u!114 &114180359308419172 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1949168787226118} + 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: 1, g: 1, b: 1, a: 0} + 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: 10907, guid: 0000000000000000f000000000000000, type: 0} + m_Type: 1 + m_PreserveAspect: 0 + m_FillCenter: 1 + m_FillMethod: 4 + m_FillAmount: 1 + m_FillClockwise: 1 + m_FillOrigin: 0 +--- !u!114 &114193710787652350 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1575375668969800} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 1679637790, guid: f70555f144d8491a825f0804e09c671c, type: 3} + m_Name: + m_EditorClassIdentifier: + m_IgnoreLayout: 1 + m_MinWidth: -1 + m_MinHeight: -1 + m_PreferredWidth: -1 + m_PreferredHeight: -1 + m_FlexibleWidth: -1 + m_FlexibleHeight: -1 +--- !u!114 &114197002012117692 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1791663633598476} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: -2061169968, guid: f70555f144d8491a825f0804e09c671c, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Navigation: + m_Mode: 3 + m_SelectOnUp: {fileID: 0} + m_SelectOnDown: {fileID: 0} + m_SelectOnLeft: {fileID: 0} + m_SelectOnRight: {fileID: 0} + m_Transition: 1 + m_Colors: + m_NormalColor: {r: 1, g: 1, b: 1, a: 1} + m_HighlightedColor: {r: 0.9607843, g: 0.9607843, b: 0.9607843, a: 1} + m_PressedColor: {r: 0.78431374, g: 0.78431374, b: 0.78431374, a: 1} + m_DisabledColor: {r: 0.78431374, g: 0.78431374, b: 0.78431374, a: 0.5019608} + m_ColorMultiplier: 1 + m_FadeDuration: 0.1 + m_SpriteState: + m_HighlightedSprite: {fileID: 0} + m_PressedSprite: {fileID: 0} + m_DisabledSprite: {fileID: 0} + m_AnimationTriggers: + m_NormalTrigger: Normal + m_HighlightedTrigger: Highlighted + m_PressedTrigger: Pressed + m_DisabledTrigger: Disabled + m_Interactable: 1 + m_TargetGraphic: {fileID: 114056508902046002} + m_HandleRect: {fileID: 224880810258273170} + m_Direction: 0 + m_Value: 1 + m_Size: 1 + m_NumberOfSteps: 0 + m_OnValueChanged: + m_PersistentCalls: + m_Calls: [] + m_TypeName: UnityEngine.UI.Scrollbar+ScrollEvent, UnityEngine.UI, Version=1.0.0.0, + Culture=neutral, PublicKeyToken=null +--- !u!114 &114232099891880756 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1000012899462148} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 76befdada4ed8754db75aeb0b0d42976, type: 3} + m_Name: + m_EditorClassIdentifier: + showLog: 1 + previousLines: 1 + narrativeLogView: {fileID: 114162492929892552} + narrativeLogMenuGroup: {fileID: 225210578159906698} +--- !u!114 &114278905042580584 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1791663633598476} + 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: 1, g: 1, b: 1, 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: 10907, guid: 0000000000000000f000000000000000, type: 0} + m_Type: 1 + m_PreserveAspect: 0 + m_FillCenter: 1 + m_FillMethod: 4 + m_FillAmount: 1 + m_FillClockwise: 1 + m_FillOrigin: 0 +--- !u!114 &114283909382663090 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1088690678392472} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 1679637790, guid: f70555f144d8491a825f0804e09c671c, type: 3} + m_Name: + m_EditorClassIdentifier: + m_IgnoreLayout: 1 + m_MinWidth: -1 + m_MinHeight: -1 + m_PreferredWidth: -1 + m_PreferredHeight: -1 + m_FlexibleWidth: -1 + m_FlexibleHeight: -1 +--- !u!114 &114302650921901322 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1216016164557284} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: -1200242548, guid: f70555f144d8491a825f0804e09c671c, type: 3} + m_Name: + m_EditorClassIdentifier: + m_ShowMaskGraphic: 0 +--- !u!114 &114305052877464294 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1017909244067428} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: -2061169968, guid: f70555f144d8491a825f0804e09c671c, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Navigation: + m_Mode: 3 + m_SelectOnUp: {fileID: 0} + m_SelectOnDown: {fileID: 0} + m_SelectOnLeft: {fileID: 0} + m_SelectOnRight: {fileID: 0} + m_Transition: 1 + m_Colors: + m_NormalColor: {r: 1, g: 1, b: 1, a: 1} + m_HighlightedColor: {r: 0.9607843, g: 0.9607843, b: 0.9607843, a: 1} + m_PressedColor: {r: 0.78431374, g: 0.78431374, b: 0.78431374, a: 1} + m_DisabledColor: {r: 0.78431374, g: 0.78431374, b: 0.78431374, a: 0.5019608} + m_ColorMultiplier: 1 + m_FadeDuration: 0.1 + m_SpriteState: + m_HighlightedSprite: {fileID: 0} + m_PressedSprite: {fileID: 0} + m_DisabledSprite: {fileID: 0} + m_AnimationTriggers: + m_NormalTrigger: Normal + m_HighlightedTrigger: Highlighted + m_PressedTrigger: Pressed + m_DisabledTrigger: Disabled + m_Interactable: 1 + m_TargetGraphic: {fileID: 114511501333539900} + m_HandleRect: {fileID: 224656606278108370} + m_Direction: 0 + m_Value: 0 + m_Size: 0.99999994 + m_NumberOfSteps: 0 + m_OnValueChanged: + m_PersistentCalls: + m_Calls: [] + m_TypeName: UnityEngine.UI.Scrollbar+ScrollEvent, UnityEngine.UI, Version=1.0.0.0, + Culture=neutral, PublicKeyToken=null +--- !u!114 &114454498723883902 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1575375668969800} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 1297475563, guid: f70555f144d8491a825f0804e09c671c, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Padding: + m_Left: 15 + m_Right: 15 + m_Top: 3 + m_Bottom: 1 + m_ChildAlignment: 0 + m_Spacing: 1 + m_ChildForceExpandWidth: 1 + m_ChildForceExpandHeight: 1 + m_ChildControlWidth: 0 + m_ChildControlHeight: 0 +--- !u!114 &114478888494047242 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1088690678392472} + 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: 1, g: 1, b: 1, a: 0.392} + 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: 10907, guid: 0000000000000000f000000000000000, type: 0} + m_Type: 1 + m_PreserveAspect: 0 + m_FillCenter: 1 + m_FillMethod: 4 + m_FillAmount: 1 + m_FillClockwise: 1 + m_FillOrigin: 0 +--- !u!114 &114491427777887672 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1898064487847954} + 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: 1, g: 1, b: 1, a: 0.9411765} + 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: 62573ea76cbf34643bf28a259a6c901c, type: 3} + m_Type: 0 + m_PreserveAspect: 0 + m_FillCenter: 1 + m_FillMethod: 4 + m_FillAmount: 1 + m_FillClockwise: 1 + m_FillOrigin: 0 +--- !u!114 &114511501333539900 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1064076235247030} + 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: 1, g: 1, b: 1, 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: 10905, guid: 0000000000000000f000000000000000, type: 0} + m_Type: 1 + m_PreserveAspect: 0 + m_FillCenter: 1 + m_FillMethod: 4 + m_FillAmount: 1 + m_FillClockwise: 1 + m_FillOrigin: 0 +--- !u!114 &114522020581970318 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1088690678392472} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 1367256648, guid: f70555f144d8491a825f0804e09c671c, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Content: {fileID: 224331103297166980} + m_Horizontal: 1 + m_Vertical: 1 + m_MovementType: 1 + m_Elasticity: 0.1 + m_Inertia: 1 + m_DecelerationRate: 0.135 + m_ScrollSensitivity: 1 + m_Viewport: {fileID: 224259322050551826} + m_HorizontalScrollbar: {fileID: 114305052877464294} + m_VerticalScrollbar: {fileID: 114993625917992760} + m_HorizontalScrollbarVisibility: 2 + m_VerticalScrollbarVisibility: 2 + m_HorizontalScrollbarSpacing: -3 + m_VerticalScrollbarSpacing: -3 + m_OnValueChanged: + m_PersistentCalls: + m_Calls: [] + m_TypeName: UnityEngine.UI.ScrollRect+ScrollRectEvent, UnityEngine.UI, Version=1.0.0.0, + Culture=neutral, PublicKeyToken=null +--- !u!114 &114625077397298586 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1943371609894262} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 708705254, guid: f70555f144d8491a825f0804e09c671c, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 1, g: 1, b: 1, 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_FontData: + m_Font: {fileID: 10102, guid: 0000000000000000e000000000000000, type: 0} + m_FontSize: 14 + m_FontStyle: 0 + m_BestFit: 0 + m_MinSize: 10 + m_MaxSize: 40 + m_Alignment: 0 + m_AlignByGeometry: 0 + m_RichText: 1 + m_HorizontalOverflow: 0 + m_VerticalOverflow: 1 + m_LineSpacing: 1 + m_Text: 'Lorem + + Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor + incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud + exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute + irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla + pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia + deserunt mollit anim id est laborum. + + + Ipsum + + Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor + incididunt ut labore et dolore magna aliqua. + + + Lorem + + Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip + ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit + esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat + non proident, sunt in culpa qui officia deserunt mollit anim id est laborum. + + + Ipsum + + Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip + ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit + esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat + non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.' +--- !u!114 &114625242687138120 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1017909244067428} + 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: 1, g: 1, b: 1, 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: 10907, guid: 0000000000000000f000000000000000, type: 0} + m_Type: 1 + m_PreserveAspect: 0 + m_FillCenter: 1 + m_FillMethod: 4 + m_FillAmount: 1 + m_FillClockwise: 1 + m_FillOrigin: 0 +--- !u!114 &114632310104905278 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1142916231164870} + 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: 1, g: 1, b: 1, 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: 10905, guid: 0000000000000000f000000000000000, type: 0} + m_Type: 1 + m_PreserveAspect: 0 + m_FillCenter: 1 + m_FillMethod: 4 + m_FillAmount: 1 + m_FillClockwise: 1 + m_FillOrigin: 0 +--- !u!114 &114653612942904624 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1000012899462148} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: -405508275, guid: f70555f144d8491a825f0804e09c671c, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Padding: + m_Left: 0 + m_Right: 0 + m_Top: 0 + m_Bottom: 0 + m_ChildAlignment: 2 + m_Spacing: 2 + m_ChildForceExpandWidth: 0 + m_ChildForceExpandHeight: 0 + m_ChildControlWidth: 0 + m_ChildControlHeight: 0 +--- !u!114 &114697660017191064 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1563859998553076} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 1679637790, guid: f70555f144d8491a825f0804e09c671c, type: 3} + m_Name: + m_EditorClassIdentifier: + m_IgnoreLayout: 0 + m_MinWidth: -1 + m_MinHeight: -1 + m_PreferredWidth: -1 + m_PreferredHeight: -1 + m_FlexibleWidth: -1 + m_FlexibleHeight: -1 +--- !u!114 &114723389948375156 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1446634631688098} + 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: 1, g: 1, b: 1, 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: 10907, guid: 0000000000000000f000000000000000, type: 0} + m_Type: 1 + m_PreserveAspect: 0 + m_FillCenter: 1 + m_FillMethod: 4 + m_FillAmount: 1 + m_FillClockwise: 1 + m_FillOrigin: 0 +--- !u!114 &114738251385494794 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1562890099353150} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 708705254, guid: f70555f144d8491a825f0804e09c671c, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 1, g: 1, b: 1, 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_FontData: + m_Font: {fileID: 10102, guid: 0000000000000000e000000000000000, type: 0} + m_FontSize: 14 + m_FontStyle: 0 + m_BestFit: 0 + m_MinSize: 10 + m_MaxSize: 40 + m_Alignment: 0 + m_AlignByGeometry: 0 + m_RichText: 0 + m_HorizontalOverflow: 0 + m_VerticalOverflow: 0 + m_LineSpacing: 1 + m_Text: +--- !u!114 &114741111563894306 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1943371609894262} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 1741964061, guid: f70555f144d8491a825f0804e09c671c, type: 3} + m_Name: + m_EditorClassIdentifier: + m_HorizontalFit: 0 + m_VerticalFit: 2 +--- !u!114 &114763048961342110 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1575375668969800} + 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: 1, g: 1, b: 1, a: 0.392} + 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: 10907, guid: 0000000000000000f000000000000000, type: 0} + m_Type: 1 + m_PreserveAspect: 0 + m_FillCenter: 1 + m_FillMethod: 4 + m_FillAmount: 1 + m_FillClockwise: 1 + m_FillOrigin: 0 +--- !u!114 &114795890241856860 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1213721919401690} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 1679637790, guid: f70555f144d8491a825f0804e09c671c, type: 3} + m_Name: + m_EditorClassIdentifier: + m_IgnoreLayout: 0 + m_MinWidth: -1 + m_MinHeight: -1 + m_PreferredWidth: -1 + m_PreferredHeight: -1 + m_FlexibleWidth: -1 + m_FlexibleHeight: -1 +--- !u!114 &114818094421102834 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1575375668969800} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: -900027084, guid: f70555f144d8491a825f0804e09c671c, type: 3} + m_Name: + m_EditorClassIdentifier: + m_EffectColor: {r: 0, g: 0, b: 0, a: 0.5} + m_EffectDistance: {x: 1, y: -1} + m_UseGraphicAlpha: 1 +--- !u!114 &114820767466158250 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1213721919401690} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: -146154839, guid: f70555f144d8491a825f0804e09c671c, type: 3} + m_Name: + m_EditorClassIdentifier: +--- !u!114 &114875751214506758 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1801582794521622} + 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: 1, g: 1, b: 1, a: 0.9411765} + 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: 62573ea76cbf34643bf28a259a6c901c, type: 3} + m_Type: 0 + m_PreserveAspect: 0 + m_FillCenter: 1 + m_FillMethod: 4 + m_FillAmount: 1 + m_FillClockwise: 1 + m_FillOrigin: 0 +--- !u!114 &114881856777117484 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1446634631688098} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: -2061169968, guid: f70555f144d8491a825f0804e09c671c, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Navigation: + m_Mode: 2 + m_SelectOnUp: {fileID: 0} + m_SelectOnDown: {fileID: 0} + m_SelectOnLeft: {fileID: 0} + m_SelectOnRight: {fileID: 0} + m_Transition: 1 + m_Colors: + m_NormalColor: {r: 1, g: 1, b: 1, a: 1} + m_HighlightedColor: {r: 0.9607843, g: 0.9607843, b: 0.9607843, a: 1} + m_PressedColor: {r: 0.78431374, g: 0.78431374, b: 0.78431374, a: 1} + m_DisabledColor: {r: 0.78431374, g: 0.78431374, b: 0.78431374, a: 0.5019608} + m_ColorMultiplier: 1 + m_FadeDuration: 0.1 + m_SpriteState: + m_HighlightedSprite: {fileID: 0} + m_PressedSprite: {fileID: 0} + m_DisabledSprite: {fileID: 0} + m_AnimationTriggers: + m_NormalTrigger: Normal + m_HighlightedTrigger: Highlighted + m_PressedTrigger: Pressed + m_DisabledTrigger: Disabled + m_Interactable: 1 + m_TargetGraphic: {fileID: 114153843942322126} + m_HandleRect: {fileID: 224813276203911662} + m_Direction: 2 + m_Value: 1 + m_Size: 0.67653704 + m_NumberOfSteps: 0 + m_OnValueChanged: + m_PersistentCalls: + m_Calls: [] + m_TypeName: UnityEngine.UI.Scrollbar+ScrollEvent, UnityEngine.UI, Version=1.0.0.0, + Culture=neutral, PublicKeyToken=null +--- !u!114 &114920314574492042 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1333170469647788} + 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: 1, g: 1, b: 1, a: 0.778} + 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: 240416d45df4c6c4daec987220246861, type: 3} + m_Type: 0 + m_PreserveAspect: 0 + m_FillCenter: 1 + m_FillMethod: 4 + m_FillAmount: 1 + m_FillClockwise: 1 + m_FillOrigin: 0 +--- !u!114 &114993625917992760 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1171231265388170} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: -2061169968, guid: f70555f144d8491a825f0804e09c671c, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Navigation: + m_Mode: 3 + m_SelectOnUp: {fileID: 0} + m_SelectOnDown: {fileID: 0} + m_SelectOnLeft: {fileID: 0} + m_SelectOnRight: {fileID: 0} + m_Transition: 1 + m_Colors: + m_NormalColor: {r: 1, g: 1, b: 1, a: 1} + m_HighlightedColor: {r: 0.9607843, g: 0.9607843, b: 0.9607843, a: 1} + m_PressedColor: {r: 0.78431374, g: 0.78431374, b: 0.78431374, a: 1} + m_DisabledColor: {r: 0.78431374, g: 0.78431374, b: 0.78431374, a: 0.5019608} + m_ColorMultiplier: 1 + m_FadeDuration: 0.1 + m_SpriteState: + m_HighlightedSprite: {fileID: 0} + m_PressedSprite: {fileID: 0} + m_DisabledSprite: {fileID: 0} + m_AnimationTriggers: + m_NormalTrigger: Normal + m_HighlightedTrigger: Highlighted + m_PressedTrigger: Pressed + m_DisabledTrigger: Disabled + m_Interactable: 1 + m_TargetGraphic: {fileID: 114632310104905278} + m_HandleRect: {fileID: 224160472953040096} + m_Direction: 2 + m_Value: 1 + m_Size: 1 + m_NumberOfSteps: 0 + m_OnValueChanged: + m_PersistentCalls: + m_Calls: [] + m_TypeName: UnityEngine.UI.Scrollbar+ScrollEvent, UnityEngine.UI, Version=1.0.0.0, + Culture=neutral, PublicKeyToken=null +--- !u!222 &222000010636408894 +CanvasRenderer: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1000011815857470} +--- !u!222 &222000010752835546 +CanvasRenderer: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1000013007313816} +--- !u!222 &222000010789171018 +CanvasRenderer: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1000011114926160} +--- !u!222 &222000010966400006 +CanvasRenderer: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1000013166397642} +--- !u!222 &222000011100116716 +CanvasRenderer: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1000010010131774} +--- !u!222 &222000011280725060 +CanvasRenderer: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1000013328246242} +--- !u!222 &222000011515314216 +CanvasRenderer: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1000013032760896} +--- !u!222 &222000012009353026 +CanvasRenderer: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1000013089762296} +--- !u!222 &222000013070489478 +CanvasRenderer: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1000012178065012} +--- !u!222 &222000013799985356 +CanvasRenderer: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1000010142133612} +--- !u!222 &222091168920081386 +CanvasRenderer: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1562890099353150} +--- !u!222 &222114849256167646 +CanvasRenderer: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1142916231164870} +--- !u!222 &222213165252159728 +CanvasRenderer: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1446634631688098} +--- !u!222 &222243915251368484 +CanvasRenderer: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1171231265388170} +--- !u!222 &222271235964525112 +CanvasRenderer: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1333170469647788} +--- !u!222 &222328673954104156 +CanvasRenderer: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1216016164557284} +--- !u!222 &222346054301214274 +CanvasRenderer: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1017909244067428} +--- !u!222 &222356757625515164 +CanvasRenderer: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1088690678392472} +--- !u!222 &222456543252686318 +CanvasRenderer: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1801582794521622} +--- !u!222 &222516594292902920 +CanvasRenderer: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1575375668969800} +--- !u!222 &222529376750664854 +CanvasRenderer: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1898064487847954} +--- !u!222 &222583787261386450 +CanvasRenderer: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1662928791296828} +--- !u!222 &222706451263006018 +CanvasRenderer: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1213721919401690} +--- !u!222 &222800070994067700 +CanvasRenderer: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1997369251198830} +--- !u!222 &222849644082718540 +CanvasRenderer: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1563859998553076} +--- !u!222 &222870937324826524 +CanvasRenderer: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1943371609894262} +--- !u!222 &222905370124457276 +CanvasRenderer: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1949168787226118} +--- !u!222 &222976103522131750 +CanvasRenderer: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1791663633598476} +--- !u!222 &222989954932444316 +CanvasRenderer: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1064076235247030} +--- !u!223 &223000014176703286 +Canvas: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1000012899462148} + m_Enabled: 1 + serializedVersion: 2 + 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_SortingLayerID: 0 + m_SortingOrder: 0 + m_TargetDisplay: 0 +--- !u!224 &224000011191842766 +RectTransform: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1000012899462148} + 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: 224000012525218478} + - {fileID: 224304764365683998} + - {fileID: 224147037515329490} + m_Father: {fileID: 0} + m_RootOrder: 0 + 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!224 &224000012150207008 +RectTransform: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1000012178065012} + 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: + - {fileID: 224000012272122410} + m_Father: {fileID: 224000012525218478} + m_RootOrder: 0 + 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.5, y: 0.5} +--- !u!224 &224000012272122410 +RectTransform: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1000010010131774} + 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: 224000012150207008} + m_RootOrder: 0 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0, y: 0} + m_AnchorMax: {x: 1, y: 1} + m_AnchoredPosition: {x: 0, y: 0} + m_SizeDelta: {x: 0, y: 0} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!224 &224000012525218478 +RectTransform: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1000013007313816} + 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: + - {fileID: 224000012150207008} + - {fileID: 224000013898185038} + - {fileID: 224000012687811630} + - {fileID: 224000012590701094} + - {fileID: 224000013149320576} + - {fileID: 224865476632621786} + m_Father: {fileID: 224000011191842766} + m_RootOrder: 0 + 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: 302, y: 30} + m_Pivot: {x: 1, y: 1} +--- !u!224 &224000012590701094 +RectTransform: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1000013089762296} + 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: + - {fileID: 224255369405830710} + m_Father: {fileID: 224000012525218478} + m_RootOrder: 3 + 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.5, y: 0.5} +--- !u!224 &224000012687811630 +RectTransform: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1000011815857470} + 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: + - {fileID: 224000013719675004} + m_Father: {fileID: 224000012525218478} + 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.5, y: 0.5} +--- !u!224 &224000013149320576 +RectTransform: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1000013328246242} + 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: + - {fileID: 224682822578024892} + m_Father: {fileID: 224000012525218478} + m_RootOrder: 4 + 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.5, y: 0.5} +--- !u!224 &224000013492386186 +RectTransform: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1000010142133612} + 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: 224000013898185038} + m_RootOrder: 0 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0, y: 0} + m_AnchorMax: {x: 1, y: 1} + m_AnchoredPosition: {x: 0, y: 0} + m_SizeDelta: {x: 0, y: 0} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!224 &224000013719675004 +RectTransform: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1000013032760896} + 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: 224000012687811630} + m_RootOrder: 0 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0, y: 0} + m_AnchorMax: {x: 1, y: 1} + m_AnchoredPosition: {x: 0, y: 0} + m_SizeDelta: {x: 0, y: 0} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!224 &224000013748593462 +RectTransform: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1000013166397642} + 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: + - {fileID: 224819725728513600} + m_Father: {fileID: 224147037515329490} + m_RootOrder: 0 + 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: 1, y: 1} +--- !u!224 &224000013898185038 +RectTransform: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1000011114926160} + 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: + - {fileID: 224000013492386186} + m_Father: {fileID: 224000012525218478} + m_RootOrder: 1 + 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.5, y: 0.5} +--- !u!224 &224054090195745834 +RectTransform: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1016451151234458} + 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: + - {fileID: 224813276203911662} + m_Father: {fileID: 224900434480553846} + m_RootOrder: 0 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0, y: 0} + m_AnchorMax: {x: 1, y: 1} + m_AnchoredPosition: {x: 0, y: 0} + m_SizeDelta: {x: -20, y: -20} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!224 &224058802661620446 +RectTransform: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1943371609894262} + 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: 224148166873360954} + m_RootOrder: 0 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0, y: 0} + m_AnchorMax: {x: 1, y: 1} + m_AnchoredPosition: {x: 0.000030518, y: 0} + m_SizeDelta: {x: -14.299988, y: 0} + m_Pivot: {x: 0, y: 1} +--- !u!224 &224147037515329490 +RectTransform: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1949168787226118} + 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: + - {fileID: 224000013748593462} + m_Father: {fileID: 224000011191842766} + 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: 40, y: 215} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!224 &224148166873360954 +RectTransform: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1213721919401690} + 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: + - {fileID: 224058802661620446} + m_Father: {fileID: 224670260353415052} + m_RootOrder: 0 + 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: 1} +--- !u!224 &224160472953040096 +RectTransform: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1142916231164870} + 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: 224506178468526888} + m_RootOrder: 0 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0, y: 0} + m_AnchorMax: {x: 1, y: 1} + m_AnchoredPosition: {x: 0, y: 0} + m_SizeDelta: {x: 20, y: 20} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!224 &224255369405830710 +RectTransform: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1898064487847954} + 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: 224000012590701094} + m_RootOrder: 0 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0.5, y: 0.5} + m_AnchorMax: {x: 0.5, y: 0.5} + m_AnchoredPosition: {x: -0.000025272, y: 0.000025272} + m_SizeDelta: {x: 21, y: 21} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!224 &224258996373127644 +RectTransform: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1171231265388170} + 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: + - {fileID: 224506178468526888} + m_Father: {fileID: 224865476632621786} + m_RootOrder: 2 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 1, y: 0} + m_AnchorMax: {x: 1, y: 1} + m_AnchoredPosition: {x: 0, y: 0} + m_SizeDelta: {x: 20, y: -17} + m_Pivot: {x: 1, y: 1} +--- !u!224 &224259322050551826 +RectTransform: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1216016164557284} + 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: + - {fileID: 224331103297166980} + m_Father: {fileID: 224865476632621786} + m_RootOrder: 0 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0, y: 0} + m_AnchorMax: {x: 1, y: 1} + m_AnchoredPosition: {x: 0, y: 0} + m_SizeDelta: {x: -17, y: -17} + m_Pivot: {x: 0, y: 1} +--- !u!224 &224304764365683998 +RectTransform: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1575375668969800} + m_LocalRotation: {x: -0, y: -0, z: -0, w: 1} + m_LocalPosition: {x: 0, y: 0, z: 0} + m_LocalScale: {x: 0.9999986, y: 0.9999986, z: 0.9999986} + m_Children: + - {fileID: 224670260353415052} + m_Father: {fileID: 224000011191842766} + m_RootOrder: 1 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0, y: 1} + m_AnchorMax: {x: 0, y: 1} + m_AnchoredPosition: {x: 687.5, y: -194.99997} + m_SizeDelta: {x: 391, y: 330} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!224 &224331103297166980 +RectTransform: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1562890099353150} + 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: 224259322050551826} + m_RootOrder: 0 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0, y: 1} + m_AnchorMax: {x: 1, y: 1} + m_AnchoredPosition: {x: 0, y: -0.000030517578} + m_SizeDelta: {x: 0, y: 300} + m_Pivot: {x: 0, y: 1} +--- !u!224 &224353886759344458 +RectTransform: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1210356177377382} + 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: + - {fileID: 224656606278108370} + m_Father: {fileID: 224756314496247326} + m_RootOrder: 0 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0, y: 0} + m_AnchorMax: {x: 1, y: 1} + m_AnchoredPosition: {x: 0, y: 0} + m_SizeDelta: {x: -20, y: -20} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!224 &224506178468526888 +RectTransform: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1134525095276268} + 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: + - {fileID: 224160472953040096} + m_Father: {fileID: 224258996373127644} + m_RootOrder: 0 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0, y: 0} + m_AnchorMax: {x: 1, y: 1} + m_AnchoredPosition: {x: 0, y: 0} + m_SizeDelta: {x: -20, y: -20} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!224 &224656606278108370 +RectTransform: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1064076235247030} + 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: 224353886759344458} + m_RootOrder: 0 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0, y: 0} + m_AnchorMax: {x: 0.99999994, y: 1} + m_AnchoredPosition: {x: 0, y: 0} + m_SizeDelta: {x: 20, y: 20} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!224 &224670260353415052 +RectTransform: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1563859998553076} + 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: + - {fileID: 224148166873360954} + - {fileID: 224673677253739666} + - {fileID: 224900434480553846} + m_Father: {fileID: 224304764365683998} + m_RootOrder: 0 + 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: 376, y: 325} + m_Pivot: {x: 0.1, y: 0.1} +--- !u!224 &224673677253739666 +RectTransform: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1791663633598476} + 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: + - {fileID: 224902324276391688} + m_Father: {fileID: 224670260353415052} + m_RootOrder: 1 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0, y: 1} + m_AnchorMax: {x: 0, y: 1} + m_AnchoredPosition: {x: 0, y: -329.51} + m_SizeDelta: {x: 0, y: 20} + m_Pivot: {x: 0, y: 0} +--- !u!224 &224682822578024892 +RectTransform: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1801582794521622} + 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: 224000013149320576} + m_RootOrder: 0 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0.5, y: 0.5} + m_AnchorMax: {x: 0.5, y: 0.5} + m_AnchoredPosition: {x: 0.0000076294, y: 0} + m_SizeDelta: {x: 21, y: 21} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!224 &224756314496247326 +RectTransform: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1017909244067428} + 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: + - {fileID: 224353886759344458} + m_Father: {fileID: 224865476632621786} + m_RootOrder: 1 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0, y: 0} + m_AnchorMax: {x: 1, y: 0} + m_AnchoredPosition: {x: 0, y: 0} + m_SizeDelta: {x: -17, y: 20} + m_Pivot: {x: 0, y: 0} +--- !u!224 &224813276203911662 +RectTransform: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1662928791296828} + 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: 224054090195745834} + m_RootOrder: 0 + 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: 20, y: 20} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!224 &224819725728513600 +RectTransform: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1333170469647788} + 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: 224000013748593462} + m_RootOrder: 0 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0.5, y: 0.5} + m_AnchorMax: {x: 0.5, y: 0.5} + m_AnchoredPosition: {x: 0.0000046492, y: 0.0000046492} + m_SizeDelta: {x: 22.5, y: 20} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!224 &224865476632621786 +RectTransform: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1088690678392472} + 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: + - {fileID: 224259322050551826} + - {fileID: 224756314496247326} + - {fileID: 224258996373127644} + m_Father: {fileID: 224000012525218478} + m_RootOrder: 5 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 1, y: 1} + m_AnchorMax: {x: 1, y: 1} + m_AnchoredPosition: {x: -186.18002, y: -212.91998} + m_SizeDelta: {x: 427, y: 366} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!224 &224880810258273170 +RectTransform: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1997369251198830} + 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: 224902324276391688} + m_RootOrder: 0 + 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: 20, y: 20} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!224 &224900434480553846 +RectTransform: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1446634631688098} + 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: + - {fileID: 224054090195745834} + m_Father: {fileID: 224670260353415052} + m_RootOrder: 2 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 1, y: 0} + m_AnchorMax: {x: 1, y: 0} + m_AnchoredPosition: {x: 0, y: 0} + m_SizeDelta: {x: 20, y: 0} + m_Pivot: {x: 1, y: 1} +--- !u!224 &224902324276391688 +RectTransform: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1685645919552228} + 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: + - {fileID: 224880810258273170} + m_Father: {fileID: 224673677253739666} + m_RootOrder: 0 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0, y: 0} + m_AnchorMax: {x: 1, y: 1} + m_AnchoredPosition: {x: 0, y: 0} + m_SizeDelta: {x: -20, y: -20} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!225 &225000012423540070 +CanvasGroup: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1000013007313816} + m_Enabled: 1 + m_Alpha: 1 + m_Interactable: 1 + m_BlocksRaycasts: 1 + m_IgnoreParentGroups: 0 +--- !u!225 &225210578159906698 +CanvasGroup: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1575375668969800} + m_Enabled: 1 + m_Alpha: 1 + m_Interactable: 1 + m_BlocksRaycasts: 1 + m_IgnoreParentGroups: 0 +--- !u!225 &225545614455694522 +CanvasGroup: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1563859998553076} + m_Enabled: 1 + m_Alpha: 1 + m_Interactable: 1 + m_BlocksRaycasts: 1 + m_IgnoreParentGroups: 0 diff --git a/Assets/Fungus/Resources/Prefabs/SaveMenu.prefab.meta b/Assets/Fungus/Resources/Prefabs/SaveMenu.prefab.meta new file mode 100644 index 0000000..cd322a5 --- /dev/null +++ b/Assets/Fungus/Resources/Prefabs/SaveMenu.prefab.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: bd2b99773f3e0489aae9f9b5053ad360 +timeCreated: 1481298777 +licenseType: Store +NativeFormatImporter: + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Resources/Prefabs/SayDialog.prefab b/Assets/Fungus/Resources/Prefabs/SayDialog.prefab new file mode 100644 index 0000000..ac761bf --- /dev/null +++ b/Assets/Fungus/Resources/Prefabs/SayDialog.prefab @@ -0,0 +1,835 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!1 &148914 +GameObject: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + serializedVersion: 4 + m_Component: + - 224: {fileID: 22448914} + - 222: {fileID: 22248914} + - 114: {fileID: 11448914} + - 114: {fileID: 11439142} + m_Layer: 5 + m_Name: Image + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!1 &155030 +GameObject: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + serializedVersion: 4 + m_Component: + - 224: {fileID: 22443574} + - 222: {fileID: 22257884} + - 114: {fileID: 11431470} + m_Layer: 5 + m_Name: Text + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!1 &180152 +GameObject: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + serializedVersion: 4 + m_Component: + - 224: {fileID: 22433354} + - 222: {fileID: 22268826} + - 114: {fileID: 11493918} + - 114: {fileID: 11419088} + m_Layer: 5 + m_Name: Continue + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!1 &188894 +GameObject: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + serializedVersion: 4 + m_Component: + - 224: {fileID: 22488896} + - 222: {fileID: 22288894} + - 114: {fileID: 11488896} + - 114: {fileID: 11439138} + m_Layer: 5 + m_Name: StoryText + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!1 &188898 +GameObject: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + serializedVersion: 4 + m_Component: + - 224: {fileID: 22488894} + - 222: {fileID: 22288898} + - 114: {fileID: 11488900} + m_Layer: 5 + m_Name: NameText + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!1 &188900 +GameObject: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + serializedVersion: 4 + m_Component: + - 224: {fileID: 22488900} + - 222: {fileID: 22288900} + - 114: {fileID: 11488904} + - 225: {fileID: 22583964} + - 114: {fileID: 11478524} + m_Layer: 5 + m_Name: Panel + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!1 &188902 +GameObject: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + serializedVersion: 4 + m_Component: + - 224: {fileID: 22488902} + - 223: {fileID: 22388894} + - 114: {fileID: 11488906} + - 225: {fileID: 22588896} + - 114: {fileID: 11486804} + - 114: {fileID: 11488894} + - 114: {fileID: 11487070} + - 114: {fileID: 11404316} + - 114: {fileID: 11481894} + - 82: {fileID: 8294266} + m_Layer: 5 + m_Name: SayDialog + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!82 &8294266 +AudioSource: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 188902} + m_Enabled: 1 + serializedVersion: 4 + OutputAudioMixerGroup: {fileID: 0} + m_audioClip: {fileID: 0} + m_PlayOnAwake: 0 + m_Volume: 1 + m_Pitch: 1 + Loop: 0 + Mute: 0 + Spatialize: 0 + Priority: 128 + DopplerLevel: 1 + MinDistance: 1 + MaxDistance: 500 + Pan2D: 0 + rolloffMode: 0 + BypassEffects: 0 + BypassListenerEffects: 0 + BypassReverbZones: 0 + rolloffCustomCurve: + serializedVersion: 2 + m_Curve: + - time: 0 + value: 1 + inSlope: 0 + outSlope: 0 + tangentMode: 0 + - time: 1 + value: 0 + inSlope: 0 + outSlope: 0 + tangentMode: 0 + m_PreInfinity: 2 + m_PostInfinity: 2 + m_RotationOrder: 4 + panLevelCustomCurve: + serializedVersion: 2 + m_Curve: + - time: 0 + value: 0 + inSlope: 0 + outSlope: 0 + tangentMode: 0 + m_PreInfinity: 2 + m_PostInfinity: 2 + m_RotationOrder: 0 + spreadCustomCurve: + serializedVersion: 2 + m_Curve: + - time: 0 + value: 0 + inSlope: 0 + outSlope: 0 + tangentMode: 0 + m_PreInfinity: 2 + m_PostInfinity: 2 + m_RotationOrder: 4 + reverbZoneMixCustomCurve: + serializedVersion: 2 + m_Curve: + - time: 0 + value: 1 + inSlope: 0 + outSlope: 0 + tangentMode: 0 + m_PreInfinity: 2 + m_PostInfinity: 2 + m_RotationOrder: 0 +--- !u!114 &11404316 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 188902} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: c4782cf42f2644447b9631f6e522160b, type: 3} + m_Name: + m_EditorClassIdentifier: + volume: 1 + loop: 1 + targetAudioSource: {fileID: 0} + audioMode: 0 + beepSounds: + - {fileID: 8300000, guid: 774486030b696474e8b3cf7f178123da, type: 3} + - {fileID: 8300000, guid: f637c5ce9d10e45c7855ed89bfc6b97e, type: 3} + - {fileID: 8300000, guid: c53b7c20372e444c6bd7f2ac0729bbe2, type: 3} + soundEffect: {fileID: 0} + inputSound: {fileID: 8300000, guid: 14a396b1562834718b2d52b9c4639264, type: 3} +--- !u!114 &11419088 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 180152} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 1392445389, guid: f5f67c52d1564df4a8936ccd202a3bd8, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Navigation: + m_Mode: 3 + m_SelectOnUp: {fileID: 0} + m_SelectOnDown: {fileID: 0} + m_SelectOnLeft: {fileID: 0} + m_SelectOnRight: {fileID: 0} + m_Transition: 1 + m_Colors: + m_NormalColor: {r: 1, g: 1, b: 1, a: 1} + m_HighlightedColor: {r: 0.9607843, g: 0.9607843, b: 0.9607843, a: 1} + m_PressedColor: {r: 0.78431374, g: 0.78431374, b: 0.78431374, a: 1} + m_DisabledColor: {r: 0.78431374, g: 0.78431374, b: 0.78431374, a: 0.5019608} + m_ColorMultiplier: 1 + m_FadeDuration: 0.1 + m_SpriteState: + m_HighlightedSprite: {fileID: 0} + m_PressedSprite: {fileID: 0} + m_DisabledSprite: {fileID: 0} + m_AnimationTriggers: + m_NormalTrigger: Normal + m_HighlightedTrigger: Highlighted + m_PressedTrigger: Pressed + m_DisabledTrigger: Disabled + m_Interactable: 1 + m_TargetGraphic: {fileID: 11493918} + m_OnClick: + m_PersistentCalls: + m_Calls: + - m_Target: {fileID: 11481894} + m_MethodName: SetButtonClickedFlag + m_Mode: 1 + m_Arguments: + m_ObjectArgument: {fileID: 0} + m_ObjectArgumentAssemblyTypeName: UnityEngine.Object, UnityEngine + m_IntArgument: 0 + m_FloatArgument: 0 + m_StringArgument: + m_BoolArgument: 0 + m_CallState: 2 + m_TypeName: UnityEngine.UI.Button+ButtonClickedEvent, UnityEngine.UI, Version=1.0.0.0, + Culture=neutral, PublicKeyToken=null +--- !u!114 &11431470 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 155030} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 708705254, guid: f5f67c52d1564df4a8936ccd202a3bd8, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 0.19607843, g: 0.19607843, b: 0.19607843, 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_FontData: + m_Font: {fileID: 10102, guid: 0000000000000000e000000000000000, type: 0} + m_FontSize: 14 + m_FontStyle: 0 + m_BestFit: 0 + m_MinSize: 10 + m_MaxSize: 40 + m_Alignment: 4 + m_AlignByGeometry: 0 + m_RichText: 1 + m_HorizontalOverflow: 0 + m_VerticalOverflow: 0 + m_LineSpacing: 1 + m_Text: +--- !u!114 &11439138 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 188894} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 1679637790, guid: f5f67c52d1564df4a8936ccd202a3bd8, type: 3} + m_Name: + m_EditorClassIdentifier: + m_IgnoreLayout: 0 + m_MinWidth: -1 + m_MinHeight: -1 + m_PreferredWidth: 1150 + m_PreferredHeight: 200 + m_FlexibleWidth: 1 + m_FlexibleHeight: -1 +--- !u!114 &11439142 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 148914} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 1679637790, guid: f5f67c52d1564df4a8936ccd202a3bd8, type: 3} + m_Name: + m_EditorClassIdentifier: + m_IgnoreLayout: 0 + m_MinWidth: -1 + m_MinHeight: -1 + m_PreferredWidth: 350 + m_PreferredHeight: 350 + m_FlexibleWidth: -1 + m_FlexibleHeight: -1 +--- !u!114 &11448914 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 148914} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: -765806418, guid: f5f67c52d1564df4a8936ccd202a3bd8, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 1, g: 1, b: 1, 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: ea8f56c43254d41728f5ac4e8299b6c9, type: 3} + m_Type: 0 + m_PreserveAspect: 1 + m_FillCenter: 1 + m_FillMethod: 4 + m_FillAmount: 1 + m_FillClockwise: 1 + m_FillOrigin: 0 +--- !u!114 &11478524 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 188900} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: -1862395651, guid: f5f67c52d1564df4a8936ccd202a3bd8, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Delegates: + - eventID: 4 + callback: + m_PersistentCalls: + m_Calls: + - m_Target: {fileID: 11481894} + m_MethodName: SetDialogClickedFlag + m_Mode: 1 + m_Arguments: + m_ObjectArgument: {fileID: 0} + m_ObjectArgumentAssemblyTypeName: UnityEngine.Object, UnityEngine + m_IntArgument: 0 + m_FloatArgument: 0 + m_StringArgument: + m_BoolArgument: 0 + m_CallState: 2 + m_TypeName: UnityEngine.EventSystems.EventTrigger+TriggerEvent, UnityEngine.UI, + Version=1.0.0.0, Culture=neutral, PublicKeyToken=null + delegates: [] +--- !u!114 &11481894 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 188902} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 43b85556abd314f3f870c18c013fdcef, type: 3} + m_Name: + m_EditorClassIdentifier: + clickMode: 1 + nextClickDelay: 0 + cancelEnabled: 1 + ignoreMenuClicks: 1 +--- !u!114 &11486804 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 188902} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 1301386320, guid: f5f67c52d1564df4a8936ccd202a3bd8, type: 3} + m_Name: + m_EditorClassIdentifier: + m_IgnoreReversedGraphics: 1 + m_BlockingObjects: 0 + m_BlockingMask: + serializedVersion: 2 + m_Bits: 4294967295 +--- !u!114 &11487070 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 188902} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: a676940fce6344af1a70043b089a6c14, type: 3} + m_Name: + m_EditorClassIdentifier: + targetTextObject: {fileID: 188894} + punchObject: {fileID: 188900} + writingSpeed: 60 + punctuationPause: 0.25 + hiddenTextColor: {r: 1, g: 1, b: 1, a: 0} + writeWholeWords: 0 + forceRichText: 1 + instantComplete: 1 +--- !u!114 &11488894 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 188902} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 3a0bbe22c246e4c78ad8e9816cbae9d5, type: 3} + m_Name: + m_EditorClassIdentifier: + fadeDuration: 0.25 + continueButton: {fileID: 11419088} + dialogCanvas: {fileID: 22388894} + nameText: {fileID: 11488900} + storyText: {fileID: 11488896} + characterImage: {fileID: 11448914} + fitTextWithImage: 1 +--- !u!114 &11488896 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 188894} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 708705254, guid: f5f67c52d1564df4a8936ccd202a3bd8, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 1, g: 1, b: 1, 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_FontData: + m_Font: {fileID: 12800000, guid: 79197ecfbc3a4294a89ce589dac02cf2, type: 3} + m_FontSize: 45 + m_FontStyle: 0 + m_BestFit: 0 + m_MinSize: 4 + m_MaxSize: 50 + m_Alignment: 0 + m_AlignByGeometry: 0 + m_RichText: 1 + m_HorizontalOverflow: 0 + m_VerticalOverflow: 0 + m_LineSpacing: 1 + m_Text: Story text +--- !u!114 &11488900 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 188898} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 708705254, guid: f5f67c52d1564df4a8936ccd202a3bd8, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 0.25882354, g: 0.25490198, b: 0.2627451, 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_FontData: + m_Font: {fileID: 12800000, guid: bb145366ce7024469a5758b08d31802c, type: 3} + m_FontSize: 50 + m_FontStyle: 0 + m_BestFit: 0 + m_MinSize: 10 + m_MaxSize: 50 + m_Alignment: 3 + m_AlignByGeometry: 0 + m_RichText: 1 + m_HorizontalOverflow: 1 + m_VerticalOverflow: 0 + m_LineSpacing: 1 + m_Text: Character Name +--- !u!114 &11488904 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 188900} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: -765806418, guid: f5f67c52d1564df4a8936ccd202a3bd8, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 1, g: 1, b: 1, 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: e8ab00ef0d9684dcb9deb52811d91218, type: 3} + m_Type: 1 + m_PreserveAspect: 1 + m_FillCenter: 1 + m_FillMethod: 0 + m_FillAmount: 1 + m_FillClockwise: 1 + m_FillOrigin: 0 +--- !u!114 &11488906 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 188902} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 1980459831, guid: f5f67c52d1564df4a8936ccd202a3bd8, type: 3} + m_Name: + m_EditorClassIdentifier: + m_UiScaleMode: 1 + m_ReferencePixelsPerUnit: 32 + m_ScaleFactor: 1 + m_ReferenceResolution: {x: 1600, y: 1200} + m_ScreenMatchMode: 0 + m_MatchWidthOrHeight: 1 + m_PhysicalUnit: 3 + m_FallbackScreenDPI: 96 + m_DefaultSpriteDPI: 96 + m_DynamicPixelsPerUnit: 1 +--- !u!114 &11493918 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 180152} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: -765806418, guid: f5f67c52d1564df4a8936ccd202a3bd8, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 1, g: 1, b: 1, 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: 226248ac6f184e448af731df91b91958, type: 3} + m_Type: 0 + m_PreserveAspect: 0 + m_FillCenter: 1 + m_FillMethod: 4 + m_FillAmount: 1 + m_FillClockwise: 1 + m_FillOrigin: 0 +--- !u!222 &22248914 +CanvasRenderer: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 148914} +--- !u!222 &22257884 +CanvasRenderer: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 155030} +--- !u!222 &22268826 +CanvasRenderer: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 180152} +--- !u!222 &22288894 +CanvasRenderer: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 188894} +--- !u!222 &22288898 +CanvasRenderer: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 188898} +--- !u!222 &22288900 +CanvasRenderer: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 188900} +--- !u!223 &22388894 +Canvas: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 188902} + m_Enabled: 1 + serializedVersion: 2 + m_RenderMode: 0 + m_Camera: {fileID: 0} + m_PlaneDistance: 100 + m_PixelPerfect: 1 + m_ReceivesEvents: 1 + m_OverrideSorting: 0 + m_OverridePixelPerfect: 0 + m_SortingBucketNormalizedSize: 0 + m_SortingLayerID: 0 + m_SortingOrder: 1 + m_TargetDisplay: 0 +--- !u!224 &22433354 +RectTransform: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 180152} + 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_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_Children: + - {fileID: 22443574} + m_Father: {fileID: 22488896} + m_RootOrder: 0 + m_AnchorMin: {x: 1, y: 0} + m_AnchorMax: {x: 1, y: 0} + m_AnchoredPosition: {x: -38.900024, y: 38.074993} + m_SizeDelta: {x: 77.900024, y: 77} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!224 &22443574 +RectTransform: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 155030} + 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_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_Children: [] + m_Father: {fileID: 22433354} + m_RootOrder: 0 + m_AnchorMin: {x: 0, y: 0} + m_AnchorMax: {x: 1, y: 1} + m_AnchoredPosition: {x: 0, y: 0} + m_SizeDelta: {x: 0, y: 0} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!224 &22448914 +RectTransform: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 148914} + 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_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_Children: [] + m_Father: {fileID: 22488900} + m_RootOrder: 1 + m_AnchorMin: {x: 1, y: 0} + m_AnchorMax: {x: 1, y: 0} + m_AnchoredPosition: {x: -178.5, y: 263.13} + m_SizeDelta: {x: 357, y: 435} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!224 &22488894 +RectTransform: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 188898} + 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_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_Children: [] + m_Father: {fileID: 22488900} + m_RootOrder: 0 + m_AnchorMin: {x: 0, y: 1} + m_AnchorMax: {x: 0, y: 1} + m_AnchoredPosition: {x: 586.5, y: -38.369995} + m_SizeDelta: {x: 1106, y: 71} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!224 &22488896 +RectTransform: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 188894} + 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_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_Children: + - {fileID: 22433354} + m_Father: {fileID: 22488900} + m_RootOrder: 2 + m_AnchorMin: {x: 0, y: 0} + m_AnchorMax: {x: 1, y: 0.78700006} + m_AnchoredPosition: {x: 3, y: 14.130005} + m_SizeDelta: {x: -61, y: -63} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!224 &22488900 +RectTransform: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 188900} + 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_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_Children: + - {fileID: 22488894} + - {fileID: 22448914} + - {fileID: 22488896} + m_Father: {fileID: 22488902} + m_RootOrder: 0 + m_AnchorMin: {x: 0.5, y: 0} + m_AnchorMax: {x: 0.5, y: 0} + m_AnchoredPosition: {x: -750.0001, y: 0} + m_SizeDelta: {x: 1500, y: 335} + m_Pivot: {x: 0, y: 0} +--- !u!224 &22488902 +RectTransform: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 188902} + 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_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_Children: + - {fileID: 22488900} + m_Father: {fileID: 0} + m_RootOrder: 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!225 &22583964 +CanvasGroup: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 188900} + m_Enabled: 1 + m_Alpha: 1 + m_Interactable: 1 + m_BlocksRaycasts: 1 + m_IgnoreParentGroups: 0 +--- !u!225 &22588896 +CanvasGroup: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 188902} + m_Enabled: 1 + m_Alpha: 1 + m_Interactable: 1 + m_BlocksRaycasts: 1 + m_IgnoreParentGroups: 0 +--- !u!1001 &100100000 +Prefab: + m_ObjectHideFlags: 1 + serializedVersion: 2 + m_Modification: + m_TransformParent: {fileID: 0} + m_Modifications: [] + m_RemovedComponents: [] + m_ParentPrefab: {fileID: 0} + m_RootGameObject: {fileID: 188902} + m_IsPrefabParent: 1 diff --git a/Assets/Fungus/Resources/Prefabs/SayDialog.prefab.meta b/Assets/Fungus/Resources/Prefabs/SayDialog.prefab.meta new file mode 100644 index 0000000..0305b76 --- /dev/null +++ b/Assets/Fungus/Resources/Prefabs/SayDialog.prefab.meta @@ -0,0 +1,4 @@ +fileFormatVersion: 2 +guid: 8a005a9e0713f4cc1b5ad29fb07657d3 +NativeFormatImporter: + userData: diff --git a/Assets/Fungus/Resources/Prefabs/Stage.prefab b/Assets/Fungus/Resources/Prefabs/Stage.prefab new file mode 100644 index 0000000..9b66d21 --- /dev/null +++ b/Assets/Fungus/Resources/Prefabs/Stage.prefab @@ -0,0 +1,516 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!1 &110270 +GameObject: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + serializedVersion: 4 + m_Component: + - 224: {fileID: 22410270} + - 222: {fileID: 22210270} + - 114: {fileID: 11410270} + m_Layer: 0 + m_Name: Right + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!1 &110272 +GameObject: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + serializedVersion: 4 + m_Component: + - 224: {fileID: 22410272} + - 222: {fileID: 22210272} + - 114: {fileID: 11410272} + m_Layer: 0 + m_Name: Offscreen Left + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!1 &110274 +GameObject: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + serializedVersion: 4 + m_Component: + - 4: {fileID: 410270} + - 114: {fileID: 11410274} + m_Layer: 0 + m_Name: Stage + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!1 &110276 +GameObject: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + serializedVersion: 4 + m_Component: + - 224: {fileID: 22410274} + - 223: {fileID: 22310270} + - 114: {fileID: 11410278} + - 114: {fileID: 11410276} + - 225: {fileID: 22510270} + m_Layer: 5 + m_Name: Canvas + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!1 &110278 +GameObject: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + serializedVersion: 4 + m_Component: + - 224: {fileID: 22410276} + - 222: {fileID: 22210274} + - 114: {fileID: 11410280} + m_Layer: 0 + m_Name: Middle + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!1 &110280 +GameObject: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + serializedVersion: 4 + m_Component: + - 224: {fileID: 22410278} + - 222: {fileID: 22210276} + - 114: {fileID: 11410282} + m_Layer: 0 + m_Name: Offscreen Right + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!1 &110282 +GameObject: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + serializedVersion: 4 + m_Component: + - 224: {fileID: 22410280} + - 222: {fileID: 22210278} + - 114: {fileID: 11410284} + m_Layer: 0 + m_Name: Left + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &410270 +Transform: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 110274} + 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_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_Children: + - {fileID: 22410274} + m_Father: {fileID: 0} + m_RootOrder: 0 +--- !u!114 &11410270 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 110270} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: -765806418, guid: f5f67c52d1564df4a8936ccd202a3bd8, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 1, g: 1, b: 1, a: 0} + 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: ea8f56c43254d41728f5ac4e8299b6c9, type: 3} + m_Type: 0 + m_PreserveAspect: 1 + m_FillCenter: 1 + m_FillMethod: 4 + m_FillAmount: 1 + m_FillClockwise: 1 + m_FillOrigin: 0 +--- !u!114 &11410272 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 110272} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: -765806418, guid: f5f67c52d1564df4a8936ccd202a3bd8, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 1, g: 1, b: 1, a: 0} + 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: ea8f56c43254d41728f5ac4e8299b6c9, type: 3} + m_Type: 0 + m_PreserveAspect: 1 + m_FillCenter: 1 + m_FillMethod: 4 + m_FillAmount: 1 + m_FillClockwise: 1 + m_FillOrigin: 0 +--- !u!114 &11410274 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 110274} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 6f6478b25a400c642b2dee75f022ab12, type: 3} + m_Name: + m_EditorClassIdentifier: + portraitCanvas: {fileID: 22310270} + dimPortraits: 1 + fadeDuration: 0.75 + moveDuration: 1 + fadeEaseType: 4 + shiftOffset: {x: 0, y: 0} + defaultPosition: {fileID: 11410280} + positions: + - {fileID: 22410280} + - {fileID: 22410276} + - {fileID: 22410270} + - {fileID: 22410272} + - {fileID: 22410278} +--- !u!114 &11410276 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 110276} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 1980459831, guid: f5f67c52d1564df4a8936ccd202a3bd8, type: 3} + m_Name: + m_EditorClassIdentifier: + m_UiScaleMode: 1 + m_ReferencePixelsPerUnit: 100 + m_ScaleFactor: 1 + m_ReferenceResolution: {x: 1600, y: 1200} + m_ScreenMatchMode: 0 + m_MatchWidthOrHeight: 1 + m_PhysicalUnit: 3 + m_FallbackScreenDPI: 96 + m_DefaultSpriteDPI: 96 + m_DynamicPixelsPerUnit: 1 +--- !u!114 &11410278 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 110276} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 1301386320, guid: f5f67c52d1564df4a8936ccd202a3bd8, type: 3} + m_Name: + m_EditorClassIdentifier: + m_IgnoreReversedGraphics: 1 + m_BlockingObjects: 0 + m_BlockingMask: + serializedVersion: 2 + m_Bits: 4294967295 +--- !u!114 &11410280 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 110278} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: -765806418, guid: f5f67c52d1564df4a8936ccd202a3bd8, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 1, g: 1, b: 1, a: 0} + 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: ea8f56c43254d41728f5ac4e8299b6c9, type: 3} + m_Type: 0 + m_PreserveAspect: 1 + m_FillCenter: 1 + m_FillMethod: 4 + m_FillAmount: 1 + m_FillClockwise: 1 + m_FillOrigin: 0 +--- !u!114 &11410282 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 110280} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: -765806418, guid: f5f67c52d1564df4a8936ccd202a3bd8, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 1, g: 1, b: 1, a: 0} + 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: ea8f56c43254d41728f5ac4e8299b6c9, type: 3} + m_Type: 0 + m_PreserveAspect: 1 + m_FillCenter: 1 + m_FillMethod: 4 + m_FillAmount: 1 + m_FillClockwise: 1 + m_FillOrigin: 0 +--- !u!114 &11410284 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 110282} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: -765806418, guid: f5f67c52d1564df4a8936ccd202a3bd8, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 1, g: 1, b: 1, a: 0} + 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: ea8f56c43254d41728f5ac4e8299b6c9, type: 3} + m_Type: 0 + m_PreserveAspect: 1 + m_FillCenter: 1 + m_FillMethod: 4 + m_FillAmount: 1 + m_FillClockwise: 1 + m_FillOrigin: 0 +--- !u!222 &22210270 +CanvasRenderer: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 110270} +--- !u!222 &22210272 +CanvasRenderer: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 110272} +--- !u!222 &22210274 +CanvasRenderer: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 110278} +--- !u!222 &22210276 +CanvasRenderer: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 110280} +--- !u!222 &22210278 +CanvasRenderer: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 110282} +--- !u!223 &22310270 +Canvas: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 110276} + m_Enabled: 1 + serializedVersion: 2 + m_RenderMode: 0 + m_Camera: {fileID: 0} + m_PlaneDistance: 100 + m_PixelPerfect: 1 + m_ReceivesEvents: 1 + m_OverrideSorting: 0 + m_OverridePixelPerfect: 0 + m_SortingBucketNormalizedSize: 0 + m_SortingLayerID: 0 + m_SortingOrder: 0 + m_TargetDisplay: 0 +--- !u!224 &22410270 +RectTransform: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 110270} + 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_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_Children: [] + m_Father: {fileID: 22410274} + m_RootOrder: 2 + m_AnchorMin: {x: 0.5, y: 1} + m_AnchorMax: {x: 0.5, y: 1} + m_AnchoredPosition: {x: 460.43, y: -1000} + m_SizeDelta: {x: 1000, y: 1000} + m_Pivot: {x: 0.5, y: 0} +--- !u!224 &22410272 +RectTransform: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 110272} + 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_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_Children: [] + m_Father: {fileID: 22410274} + m_RootOrder: 3 + m_AnchorMin: {x: 0.5, y: 1} + m_AnchorMax: {x: 0.5, y: 1} + m_AnchoredPosition: {x: -1300, y: -1000} + m_SizeDelta: {x: 1000, y: 1000} + m_Pivot: {x: 0.5, y: 0} +--- !u!224 &22410274 +RectTransform: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 110276} + 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_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_Children: + - {fileID: 22410276} + - {fileID: 22410280} + - {fileID: 22410270} + - {fileID: 22410272} + - {fileID: 22410278} + m_Father: {fileID: 410270} + m_RootOrder: 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!224 &22410276 +RectTransform: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 110278} + 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_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_Children: [] + m_Father: {fileID: 22410274} + m_RootOrder: 0 + m_AnchorMin: {x: 0.5, y: 1} + m_AnchorMax: {x: 0.5, y: 1} + m_AnchoredPosition: {x: 0, y: -1000} + m_SizeDelta: {x: 1000, y: 1000} + m_Pivot: {x: 0.5, y: 0} +--- !u!224 &22410278 +RectTransform: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 110280} + 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_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_Children: [] + m_Father: {fileID: 22410274} + m_RootOrder: 4 + m_AnchorMin: {x: 0.5, y: 1} + m_AnchorMax: {x: 0.5, y: 1} + m_AnchoredPosition: {x: 1300, y: -1000} + m_SizeDelta: {x: 1000, y: 1000} + m_Pivot: {x: 0.5, y: 0} +--- !u!224 &22410280 +RectTransform: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 110282} + 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_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_Children: [] + m_Father: {fileID: 22410274} + m_RootOrder: 1 + m_AnchorMin: {x: 0.5, y: 1} + m_AnchorMax: {x: 0.5, y: 1} + m_AnchoredPosition: {x: -460.43, y: -1000} + m_SizeDelta: {x: 1000, y: 1000} + m_Pivot: {x: 0.5, y: 0} +--- !u!225 &22510270 +CanvasGroup: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 110276} + m_Enabled: 1 + m_Alpha: 1 + m_Interactable: 1 + m_BlocksRaycasts: 0 + m_IgnoreParentGroups: 0 +--- !u!1001 &100100000 +Prefab: + m_ObjectHideFlags: 1 + serializedVersion: 2 + m_Modification: + m_TransformParent: {fileID: 0} + m_Modifications: [] + m_RemovedComponents: [] + m_ParentPrefab: {fileID: 0} + m_RootGameObject: {fileID: 110274} + m_IsPrefabParent: 1 diff --git a/Assets/Fungus/Resources/Prefabs/Stage.prefab.meta b/Assets/Fungus/Resources/Prefabs/Stage.prefab.meta new file mode 100644 index 0000000..91a40ab --- /dev/null +++ b/Assets/Fungus/Resources/Prefabs/Stage.prefab.meta @@ -0,0 +1,4 @@ +fileFormatVersion: 2 +guid: c6289d5f8fa843145a2355af9cb09719 +NativeFormatImporter: + userData: diff --git a/Assets/Fungus/Resources/Prefabs/StagePosition.prefab b/Assets/Fungus/Resources/Prefabs/StagePosition.prefab new file mode 100644 index 0000000..c8cf179 --- /dev/null +++ b/Assets/Fungus/Resources/Prefabs/StagePosition.prefab @@ -0,0 +1,81 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!1 &195640 +GameObject: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + serializedVersion: 4 + m_Component: + - 224: {fileID: 22495640} + - 222: {fileID: 22295640} + - 114: {fileID: 11495640} + m_Layer: 0 + m_Name: StagePosition + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!114 &11495640 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 195640} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: -765806418, guid: f5f67c52d1564df4a8936ccd202a3bd8, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 1, g: 1, b: 1, a: 0} + 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: ea8f56c43254d41728f5ac4e8299b6c9, type: 3} + m_Type: 0 + m_PreserveAspect: 1 + m_FillCenter: 1 + m_FillMethod: 4 + m_FillAmount: 1 + m_FillClockwise: 1 + m_FillOrigin: 0 +--- !u!222 &22295640 +CanvasRenderer: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 195640} +--- !u!224 &22495640 +RectTransform: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 195640} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: 0, y: 0, z: 0} + m_LocalScale: {x: 2.3166022, y: 2.3166022, z: 2.3166022} + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_Children: [] + m_Father: {fileID: 0} + m_RootOrder: 0 + m_AnchorMin: {x: 0.5, y: 0} + m_AnchorMax: {x: 0.5, y: 0} + m_AnchoredPosition: {x: -590.7334, y: 483.45358} + m_SizeDelta: {x: 1000, y: 1000} + m_Pivot: {x: 0.5, y: 0} +--- !u!1001 &100100000 +Prefab: + m_ObjectHideFlags: 1 + serializedVersion: 2 + m_Modification: + m_TransformParent: {fileID: 0} + m_Modifications: [] + m_RemovedComponents: [] + m_ParentPrefab: {fileID: 0} + m_RootGameObject: {fileID: 195640} + m_IsPrefabParent: 1 diff --git a/Assets/Fungus/Resources/Prefabs/StagePosition.prefab.meta b/Assets/Fungus/Resources/Prefabs/StagePosition.prefab.meta new file mode 100644 index 0000000..972aa52 --- /dev/null +++ b/Assets/Fungus/Resources/Prefabs/StagePosition.prefab.meta @@ -0,0 +1,4 @@ +fileFormatVersion: 2 +guid: 7a4c270a5c18f6549a7683844dbf9f22 +NativeFormatImporter: + userData: diff --git a/Assets/Fungus/Resources/Prefabs/Tag.prefab b/Assets/Fungus/Resources/Prefabs/Tag.prefab new file mode 100644 index 0000000..21e8fd3 --- /dev/null +++ b/Assets/Fungus/Resources/Prefabs/Tag.prefab @@ -0,0 +1,57 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!1 &177196 +GameObject: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + serializedVersion: 4 + m_Component: + - 4: {fileID: 477196} + - 114: {fileID: 11477196} + m_Layer: 0 + m_Name: Tag + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &477196 +Transform: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 177196} + 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_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_Children: [] + m_Father: {fileID: 0} + m_RootOrder: 0 +--- !u!114 &11477196 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 177196} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 335e04fbdd5260043abb299a991dcbe8, type: 3} + m_Name: + m_EditorClassIdentifier: + tagStartSymbol: '{customName}' + tagEndSymbol: '{/customName}' + replaceTagStartWith: '{color=blue}' + replaceTagEndWith: '{/color}' +--- !u!1001 &100100000 +Prefab: + m_ObjectHideFlags: 1 + serializedVersion: 2 + m_Modification: + m_TransformParent: {fileID: 0} + m_Modifications: [] + m_RemovedComponents: [] + m_ParentPrefab: {fileID: 0} + m_RootGameObject: {fileID: 177196} + m_IsPrefabParent: 1 diff --git a/Assets/Fungus/Resources/Prefabs/Tag.prefab.meta b/Assets/Fungus/Resources/Prefabs/Tag.prefab.meta new file mode 100644 index 0000000..74bb9cb --- /dev/null +++ b/Assets/Fungus/Resources/Prefabs/Tag.prefab.meta @@ -0,0 +1,4 @@ +fileFormatVersion: 2 +guid: 8345c33c7c8ada64083f41d452b315eb +NativeFormatImporter: + userData: diff --git a/Assets/Fungus/Resources/Prefabs/View.prefab b/Assets/Fungus/Resources/Prefabs/View.prefab new file mode 100644 index 0000000..d4f6a3b --- /dev/null +++ b/Assets/Fungus/Resources/Prefabs/View.prefab @@ -0,0 +1,56 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!1 &100000 +GameObject: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + serializedVersion: 4 + m_Component: + - 4: {fileID: 400000} + - 114: {fileID: 11400000} + m_Layer: 0 + m_Name: View + m_TagString: Untagged + m_Icon: {fileID: 5721338939258241955, guid: 0000000000000000d000000000000000, type: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &400000 +Transform: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 100000} + 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_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_Children: [] + m_Father: {fileID: 0} + m_RootOrder: 0 +--- !u!114 &11400000 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 100000} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 95c387d3e32404bcc91c60318d766bb1, type: 3} + m_Name: + m_EditorClassIdentifier: + viewSize: 1 + primaryAspectRatio: {x: 4, y: 3} + secondaryAspectRatio: {x: 2, y: 1} +--- !u!1001 &100100000 +Prefab: + m_ObjectHideFlags: 1 + serializedVersion: 2 + m_Modification: + m_TransformParent: {fileID: 0} + m_Modifications: [] + m_RemovedComponents: [] + m_ParentPrefab: {fileID: 0} + m_RootGameObject: {fileID: 100000} + m_IsPrefabParent: 1 diff --git a/Assets/Fungus/Resources/Prefabs/View.prefab.meta b/Assets/Fungus/Resources/Prefabs/View.prefab.meta new file mode 100644 index 0000000..3bef407 --- /dev/null +++ b/Assets/Fungus/Resources/Prefabs/View.prefab.meta @@ -0,0 +1,4 @@ +fileFormatVersion: 2 +guid: e0d427add844a4d9faf970a3afa07583 +NativeFormatImporter: + userData: diff --git a/Assets/Fungus/Resources/Sprites.meta b/Assets/Fungus/Resources/Sprites.meta new file mode 100644 index 0000000..c8d3811 --- /dev/null +++ b/Assets/Fungus/Resources/Sprites.meta @@ -0,0 +1,9 @@ +fileFormatVersion: 2 +guid: 32f062c580ee140fdb01e9a7354fd1dc +folderAsset: yes +timeCreated: 1473780777 +licenseType: Store +DefaultImporter: + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Resources/Sprites/Background.png b/Assets/Fungus/Resources/Sprites/Background.png new file mode 100644 index 0000000..fe1f199 Binary files /dev/null and b/Assets/Fungus/Resources/Sprites/Background.png differ diff --git a/Assets/Fungus/Resources/Sprites/Background.png.meta b/Assets/Fungus/Resources/Sprites/Background.png.meta new file mode 100644 index 0000000..e5172ed --- /dev/null +++ b/Assets/Fungus/Resources/Sprites/Background.png.meta @@ -0,0 +1,94 @@ +fileFormatVersion: 2 +guid: 78bc8db714c3749cc8bd8c0b7e525b85 +TextureImporter: + internalIDToNameTable: + - first: + 213: 21300000 + second: Background + externalObjects: {} + serializedVersion: 10 + mipmaps: + mipMapMode: 0 + enableMipMap: 0 + sRGBTexture: 1 + linearTexture: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + streamingMipmaps: 0 + streamingMipmapsPriority: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: -3 + maxTextureSize: 1024 + textureSettings: + serializedVersion: 2 + filterMode: 0 + aniso: 1 + mipBias: -100 + wrapU: 1 + wrapV: 1 + wrapW: 1 + nPOTScale: 0 + lightmap: 0 + compressionQuality: 50 + spriteMode: 1 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spritePixelsToUnits: 100 + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spriteGenerateFallbackPhysicsShape: 1 + alphaUsage: 1 + alphaIsTransparency: 1 + spriteTessellationDetail: -1 + textureType: 8 + textureShape: 1 + singleChannelComponent: 0 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + platformSettings: + - serializedVersion: 3 + buildTarget: DefaultTexturePlatform + maxTextureSize: 1024 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 0 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + bones: [] + spriteID: 5e97eb03825dee720800000000000000 + internalID: 0 + vertices: [] + indices: + edges: [] + weights: [] + secondaryTextures: [] + spritePackingTag: + pSDRemoveMatte: 0 + pSDShowRemoveMatteOption: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Resources/Sprites/HandPointer.png b/Assets/Fungus/Resources/Sprites/HandPointer.png new file mode 100644 index 0000000..7a8eeae Binary files /dev/null and b/Assets/Fungus/Resources/Sprites/HandPointer.png differ diff --git a/Assets/Fungus/Resources/Sprites/HandPointer.png.meta b/Assets/Fungus/Resources/Sprites/HandPointer.png.meta new file mode 100644 index 0000000..4e9ad24 --- /dev/null +++ b/Assets/Fungus/Resources/Sprites/HandPointer.png.meta @@ -0,0 +1,59 @@ +fileFormatVersion: 2 +guid: 22eb050bacf8c401ca8503e24bff3570 +timeCreated: 1439303347 +licenseType: Store +TextureImporter: + fileIDToRecycleName: {} + serializedVersion: 2 + mipmaps: + mipMapMode: 0 + enableMipMap: 0 + linearTexture: 1 + correctGamma: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 1 + grayScaleToAlpha: 0 + generateCubemap: 0 + cubemapConvolution: 0 + cubemapConvolutionSteps: 8 + cubemapConvolutionExponent: 1.5 + seamlessCubemap: 0 + textureFormat: -3 + maxTextureSize: 512 + textureSettings: + filterMode: -1 + aniso: 1 + mipBias: -1 + wrapMode: 1 + nPOTScale: 0 + lightmap: 0 + rGBM: 0 + compressionQuality: 50 + allowsAlphaSplitting: 0 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spritePixelsToUnits: 100 + alphaIsTransparency: 1 + spriteTessellationDetail: -1 + textureType: 7 + buildTargetSettings: [] + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + spritePackingTag: + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Resources/Sprites/MousePointer.png b/Assets/Fungus/Resources/Sprites/MousePointer.png new file mode 100644 index 0000000..67f8052 Binary files /dev/null and b/Assets/Fungus/Resources/Sprites/MousePointer.png differ diff --git a/Assets/Fungus/Resources/Sprites/MousePointer.png.meta b/Assets/Fungus/Resources/Sprites/MousePointer.png.meta new file mode 100644 index 0000000..f29f9cc --- /dev/null +++ b/Assets/Fungus/Resources/Sprites/MousePointer.png.meta @@ -0,0 +1,59 @@ +fileFormatVersion: 2 +guid: 502e0c9b755f34db0b90bf78857d8a1c +timeCreated: 1439303347 +licenseType: Store +TextureImporter: + fileIDToRecycleName: {} + serializedVersion: 2 + mipmaps: + mipMapMode: 0 + enableMipMap: 0 + linearTexture: 1 + correctGamma: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 1 + grayScaleToAlpha: 0 + generateCubemap: 0 + cubemapConvolution: 0 + cubemapConvolutionSteps: 8 + cubemapConvolutionExponent: 1.5 + seamlessCubemap: 0 + textureFormat: -3 + maxTextureSize: 2048 + textureSettings: + filterMode: -1 + aniso: 1 + mipBias: -1 + wrapMode: 1 + nPOTScale: 0 + lightmap: 0 + rGBM: 0 + compressionQuality: 50 + allowsAlphaSplitting: 0 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spritePixelsToUnits: 100 + alphaIsTransparency: 1 + spriteTessellationDetail: -1 + textureType: 7 + buildTargetSettings: [] + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + spritePackingTag: + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts.meta b/Assets/Fungus/Scripts.meta new file mode 100644 index 0000000..0db8fdc --- /dev/null +++ b/Assets/Fungus/Scripts.meta @@ -0,0 +1,9 @@ +fileFormatVersion: 2 +guid: fa184a0dd8f1c46cbb12b7fcf9b1b06a +folderAsset: yes +timeCreated: 1473770354 +licenseType: Store +DefaultImporter: + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands.meta b/Assets/Fungus/Scripts/Commands.meta new file mode 100644 index 0000000..d9ffdb2 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands.meta @@ -0,0 +1,9 @@ +fileFormatVersion: 2 +guid: d957a50af081d49998801a81811881fe +folderAsset: yes +timeCreated: 1473770383 +licenseType: Store +DefaultImporter: + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/AssertCommand.cs b/Assets/Fungus/Scripts/Commands/AssertCommand.cs new file mode 100644 index 0000000..229c3db --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/AssertCommand.cs @@ -0,0 +1,70 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; +using UnityEngine.Assertions; + +namespace Fungus +{ + /// + /// Assert on 2 Fungus variable values. + /// + [CommandInfo("Scripting", + "Assert", + "Assert based on compared values.")] + [AddComponentMenu("")] + public class AssertCommand : Command + { + [SerializeField] + protected StringData message; + + [SerializeField] + [VariableProperty(AllVariableTypes.VariableAny.Any)] + protected Variable a, b; + + public enum Method + { + AreEqual, + AreNotEqual, + } + + [SerializeField] + protected Method method; + + public override void OnEnter() + { + switch (method) + { + case Method.AreEqual: + Assert.AreEqual(a.GetValue(), b.GetValue()); + break; + + case Method.AreNotEqual: + Assert.AreNotEqual(a.GetValue(), b.GetValue()); + break; + + default: + break; + } + + Continue(); + } + + public override string GetSummary() + { + if (a == null) + return "Error: No A variable"; + if (b == null) + return "Error: No B variable"; + + return a.Key + " " + method.ToString() + " " + b.Key; + } + + public override bool HasReference(Variable variable) + { + return variable == message.stringRef || + variable == a || variable == b || + base.HasReference(variable); + } + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/AssertCommand.cs.meta b/Assets/Fungus/Scripts/Commands/AssertCommand.cs.meta new file mode 100644 index 0000000..a16fc06 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/AssertCommand.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: c40b126bd148ae743b56bc8c00162589 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/Break.cs b/Assets/Fungus/Scripts/Commands/Break.cs new file mode 100644 index 0000000..b1f3603 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Break.cs @@ -0,0 +1,53 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; + +namespace Fungus +{ + /// + /// Force a loop to terminate immediately. + /// + [CommandInfo("Flow", + "Break", + "Force a loop to terminate immediately.")] + [AddComponentMenu("")] + public class Break : Command + { + #region Public members + + //located the containing loop and tell it to end + public override void OnEnter() + { + Condition loopingCond = null; + // Find index of previous looping command + for (int i = CommandIndex - 1; i >= 0; --i) + { + Condition cond = ParentBlock.CommandList[i] as Condition; + if (cond != null && cond.IsLooping) + { + loopingCond = cond; + break; + } + } + + if (loopingCond == null) + { + // No enclosing loop command found, just continue + Debug.LogError("Break called but found no enclosing looping construct." + GetLocationIdentifier()); + Continue(); + } + else + { + loopingCond.MoveToEnd(); + } + } + + public override Color GetButtonColor() + { + return new Color32(253, 253, 150, 255); + } + + #endregion + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/Break.cs.meta b/Assets/Fungus/Scripts/Commands/Break.cs.meta new file mode 100644 index 0000000..0f24a0d --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Break.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: c9b9c7a9785c34fc889da2b3a40344db +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Fungus/Scripts/Commands/Call.cs b/Assets/Fungus/Scripts/Commands/Call.cs new file mode 100644 index 0000000..12a5ff5 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Call.cs @@ -0,0 +1,166 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; +using UnityEngine.Serialization; +using System.Collections.Generic; +using System; + +namespace Fungus +{ + /// + /// Supported modes for calling a block. + /// + public enum CallMode + { + /// Stop executing the current block after calling. + Stop, + /// Continue executing the current block after calling + Continue, + /// Wait until the called block finishes executing, then continue executing current block. + WaitUntilFinished, + /// Stop executing the current block before attempting to call. This allows for circular calls within the same frame + StopThenCall + } + + /// + /// Execute another block in the same Flowchart as the command, or in a different Flowchart. + /// + [CommandInfo("Flow", + "Call", + "Execute another block in the same Flowchart as the command, or in a different Flowchart.")] + [AddComponentMenu("")] + public class Call : Command, IBlockCaller + { + [Tooltip("Flowchart which contains the block to execute. If none is specified then the current Flowchart is used.")] + [SerializeField] protected Flowchart targetFlowchart; + + [FormerlySerializedAs("targetSequence")] + [Tooltip("Block to start executing")] + [SerializeField] protected Block targetBlock; + + [Tooltip("Label to start execution at. Takes priority over startIndex.")] + [SerializeField] protected StringData startLabel = new StringData(); + + [Tooltip("Command index to start executing")] + [FormerlySerializedAs("commandIndex")] + [SerializeField] protected int startIndex; + + [Tooltip("Select if the calling block should stop or continue executing commands, or wait until the called block finishes.")] + [SerializeField] protected CallMode callMode; + + #region Public members + + public override void OnEnter() + { + if (targetBlock != null) + { + // Check if calling your own parent block + if (ParentBlock != null && ParentBlock.Equals(targetBlock)) + { + // Just ignore the callmode in this case, and jump to first command in list + Continue(0); + return; + } + + if(targetBlock.IsExecuting()) + { + Debug.LogWarning(targetBlock.BlockName + " cannot be called/executed, it is already running."); + Continue(); + return; + } + + // Callback action for Wait Until Finished mode + Action onComplete = null; + if (callMode == CallMode.WaitUntilFinished) + { + onComplete = delegate { + Continue(); + }; + } + + // Find the command index to start execution at + int index = startIndex; + if (startLabel.Value != "") + { + int labelIndex = targetBlock.GetLabelIndex(startLabel.Value); + if (labelIndex != -1) + { + index = labelIndex; + } + } + + if (targetFlowchart == null || + targetFlowchart.Equals(GetFlowchart())) + { + if (callMode == CallMode.StopThenCall) + { + StopParentBlock(); + } + StartCoroutine(targetBlock.Execute(index, onComplete)); + } + else + { + if (callMode == CallMode.StopThenCall) + { + StopParentBlock(); + } + // Execute block in another Flowchart + targetFlowchart.ExecuteBlock(targetBlock, index, onComplete); + } + } + + if (callMode == CallMode.Stop) + { + StopParentBlock(); + } + else if (callMode == CallMode.Continue) + { + Continue(); + } + } + + public override void GetConnectedBlocks(ref List connectedBlocks) + { + if (targetBlock != null) + { + connectedBlocks.Add(targetBlock); + } + } + + public override string GetSummary() + { + string summary = ""; + + if (targetBlock == null) + { + summary = ""; + } + else + { + summary = targetBlock.BlockName; + } + + summary += " : " + callMode.ToString(); + + return summary; + } + + public override Color GetButtonColor() + { + return new Color32(235, 191, 217, 255); + } + + public override bool HasReference(Variable variable) + { + return startLabel.stringRef == variable || base.HasReference(variable); + } + + public bool MayCallBlock(Block block) + { + return block == targetBlock; + } + + #endregion + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/Call.cs.meta b/Assets/Fungus/Scripts/Commands/Call.cs.meta new file mode 100644 index 0000000..21288ec --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Call.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 050fb9e6e72f442b3b883da8a965bdeb +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Fungus/Scripts/Commands/CallMethod.cs b/Assets/Fungus/Scripts/Commands/CallMethod.cs new file mode 100644 index 0000000..107a143 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/CallMethod.cs @@ -0,0 +1,78 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; + +namespace Fungus +{ + /// + /// Calls a named method on a GameObject using the GameObject.SendMessage() system. + /// This command is called "Call Method" because a) it's more descriptive than Send Message and we're already have + /// a Send Message command for sending messages to trigger block execution. + /// + [CommandInfo("Scripting", + "Call Method", + "Calls a named method on a GameObject using the GameObject.SendMessage() system.")] + [AddComponentMenu("")] + public class CallMethod : Command + { + [Tooltip("Target monobehavior which contains the method we want to call")] + [SerializeField] protected GameObject targetObject; + + [Tooltip("Name of the method to call")] + [SerializeField] protected string methodName = ""; + + [Tooltip("Delay (in seconds) before the method will be called")] + [SerializeField] protected float delay; + + protected virtual void CallTheMethod() + { + targetObject.SendMessage(methodName, SendMessageOptions.DontRequireReceiver); + } + + #region Public members + + public override void OnEnter() + { + if (targetObject == null || + methodName.Length == 0) + { + Continue(); + return; + } + + if (Mathf.Approximately(delay, 0f)) + { + CallTheMethod(); + } + else + { + Invoke("CallTheMethod", delay); + } + + Continue(); + } + + public override string GetSummary() + { + if (targetObject == null) + { + return "Error: No target GameObject specified"; + } + + if (methodName.Length == 0) + { + return "Error: No named method specified"; + } + + return targetObject.name + " : " + methodName; + } + + public override Color GetButtonColor() + { + return new Color32(235, 191, 217, 255); + } + + #endregion + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/CallMethod.cs.meta b/Assets/Fungus/Scripts/Commands/CallMethod.cs.meta new file mode 100644 index 0000000..253dfa5 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/CallMethod.cs.meta @@ -0,0 +1,12 @@ +fileFormatVersion: 2 +guid: 17a200dbd67304446a3019434503338a +timeCreated: 1430927467 +licenseType: Store +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/ClearMenu.cs b/Assets/Fungus/Scripts/Commands/ClearMenu.cs new file mode 100644 index 0000000..1c53c46 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/ClearMenu.cs @@ -0,0 +1,45 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; + +namespace Fungus +{ + /// + /// Clears the options from a menu dialogue. + /// + [CommandInfo("Narrative", + "Clear Menu", + "Clears the options from a menu dialogue")] + public class ClearMenu : Command + { + [Tooltip("Menu Dialog to clear the options on")] + [SerializeField] protected MenuDialog menuDialog; + + #region Public members + + public override void OnEnter() + { + menuDialog.Clear(); + + Continue(); + } + + public override string GetSummary() + { + if (menuDialog == null) + { + return "Error: No menu dialog object selected"; + } + + return menuDialog.name; + } + + public override Color GetButtonColor() + { + return new Color32(184, 210, 235, 255); + } + + #endregion + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/ClearMenu.cs.meta b/Assets/Fungus/Scripts/Commands/ClearMenu.cs.meta new file mode 100644 index 0000000..9433170 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/ClearMenu.cs.meta @@ -0,0 +1,12 @@ +fileFormatVersion: 2 +guid: 430ab3c61eef444b2aec02aee7f809bf +timeCreated: 1445258294 +licenseType: Store +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/Collection.meta b/Assets/Fungus/Scripts/Commands/Collection.meta new file mode 100644 index 0000000..ee30b8f --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Collection.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 7d7820abad934b747ae1797c3aa82197 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/Collection/CollectionBaseCommand.cs b/Assets/Fungus/Scripts/Commands/Collection/CollectionBaseCommand.cs new file mode 100644 index 0000000..4932255 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Collection/CollectionBaseCommand.cs @@ -0,0 +1,35 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; + +namespace Fungus +{ + /// + /// Base class for all FungusCollection commands + /// + [AddComponentMenu("")] + public abstract class CollectionBaseCommand : Command + { + [SerializeField] + protected CollectionData collection; + + public override Color GetButtonColor() + { + return new Color32(191, 217, 235, 255); + } + + public override bool HasReference(Variable variable) + { + return variable == collection.collectionRef; + } + + public override string GetSummary() + { + if (collection.Value == null) + return "Error: no collection selected"; + + return collection.Value.name; + } + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/Collection/CollectionBaseCommand.cs.meta b/Assets/Fungus/Scripts/Commands/Collection/CollectionBaseCommand.cs.meta new file mode 100644 index 0000000..68f6899 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Collection/CollectionBaseCommand.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: dab2b4efcfae62841b5070c4cfec8c4a +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/Collection/CollectionBaseIntCommand.cs b/Assets/Fungus/Scripts/Commands/Collection/CollectionBaseIntCommand.cs new file mode 100644 index 0000000..b5f790a --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Collection/CollectionBaseIntCommand.cs @@ -0,0 +1,42 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; + +namespace Fungus +{ + /// + /// Base class for all FungusCollection commands that use an intvar + /// + [AddComponentMenu("")] + public abstract class CollectionBaseIntCommand : CollectionBaseCommand + { + [SerializeField] + protected IntegerData integer; + + public override void OnEnter() + { + if (collection.Value != null) + { + OnEnterInner(); + } + + Continue(); + } + + protected abstract void OnEnterInner(); + + public override bool HasReference(Variable variable) + { + return variable == integer.integerRef || base.HasReference(variable); + } + + public override string GetSummary() + { + if (collection.Value == null) + return "Error: no collection selected"; + + return integer.Value.ToString() + " on " + collection.Value.name; + } + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/Collection/CollectionBaseIntCommand.cs.meta b/Assets/Fungus/Scripts/Commands/Collection/CollectionBaseIntCommand.cs.meta new file mode 100644 index 0000000..f9e3883 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Collection/CollectionBaseIntCommand.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 328b7e125f24d5349be4fe583267ba1d +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/Collection/CollectionBaseTwoCollectionCommand.cs b/Assets/Fungus/Scripts/Commands/Collection/CollectionBaseTwoCollectionCommand.cs new file mode 100644 index 0000000..0183a54 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Collection/CollectionBaseTwoCollectionCommand.cs @@ -0,0 +1,50 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; + +namespace Fungus +{ + /// + /// Base class for all FungusCollection commands that require a second collection of the same type + /// + [AddComponentMenu("")] + public abstract class CollectionBaseTwoCollectionCommand : CollectionBaseCommand + { + [SerializeField] + protected CollectionData rhsCollection; + + public override void OnEnter() + { + if (collection.Value != null && rhsCollection.Value != null) + { + OnEnterInner(); + } + + Continue(); + } + + protected abstract void OnEnterInner(); + + public override bool HasReference(Variable variable) + { + return variable == rhsCollection.collectionRef || base.HasReference(variable); + } + + public override string GetSummary() + { + if (collection.Value == null) + return "Error: no collection selected"; + + if (rhsCollection.Value == null) + return "Error: no variable selected"; + + if (collection.Value.ContainedType() != rhsCollection.Value.ContainedType()) + { + return "Error: Collection types do not match. " + collection.Value.ContainedType().Name + " != " + rhsCollection.Value.ContainedType().Name; + } + + return collection.Value.name + " , " + rhsCollection.Value.name; + } + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/Collection/CollectionBaseTwoCollectionCommand.cs.meta b/Assets/Fungus/Scripts/Commands/Collection/CollectionBaseTwoCollectionCommand.cs.meta new file mode 100644 index 0000000..593556c --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Collection/CollectionBaseTwoCollectionCommand.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: c4010b5577069fc4cb9480f87ed3f73e +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/Collection/CollectionBaseVarAndIntCommand.cs b/Assets/Fungus/Scripts/Commands/Collection/CollectionBaseVarAndIntCommand.cs new file mode 100644 index 0000000..6744aaa --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Collection/CollectionBaseVarAndIntCommand.cs @@ -0,0 +1,47 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; + +namespace Fungus +{ + /// + /// Base class for all FungusCollection commands that require a compatible variable and an integer + /// + [AddComponentMenu("")] + public abstract class CollectionBaseVarAndIntCommand : CollectionBaseVarCommand + { + [SerializeField] + [VariableProperty(typeof(IntegerVariable))] + protected IntegerVariable integer; + + public override void OnEnter() + { + if (collection.Value != null && variableToUse != null && integer != null) + { + OnEnterInner(); + } + + Continue(); + } + + public override bool HasReference(Variable variable) + { + return variable == integer || base.HasReference(variable); + } + + public override string GetSummary() + { + if (collection.Value == null) + return "Error: no collection selected"; + + if (variableToUse == null) + return "Error: no variable selected"; + + if (integer == null) + return "Error: no integer selected"; + + return integer.Key + " on " + variableToUse.Key + " in " + collection.Value.name; + } + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/Collection/CollectionBaseVarAndIntCommand.cs.meta b/Assets/Fungus/Scripts/Commands/Collection/CollectionBaseVarAndIntCommand.cs.meta new file mode 100644 index 0000000..2cb1e4c --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Collection/CollectionBaseVarAndIntCommand.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 561b53abc515d704d8845caa3b3ee26f +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/Collection/CollectionBaseVarCommand.cs b/Assets/Fungus/Scripts/Commands/Collection/CollectionBaseVarCommand.cs new file mode 100644 index 0000000..249e2d2 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Collection/CollectionBaseVarCommand.cs @@ -0,0 +1,54 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; + +namespace Fungus +{ + /// + /// Base class for all FungusCollection commands that require a compatible variable type + /// + [AddComponentMenu("")] + public abstract class CollectionBaseVarCommand : CollectionBaseCommand, ICollectionCompatible + { + [SerializeField] + [VariableProperty(compatibleVariableName = "collection")] + protected Variable variableToUse; + + public override void OnEnter() + { + if (collection.Value != null && variableToUse != null) + { + OnEnterInner(); + } + + Continue(); + } + + protected abstract void OnEnterInner(); + + public override bool HasReference(Variable variable) + { + return variable == variableToUse || base.HasReference(variable); + } + + public override string GetSummary() + { + if (collection.Value == null) + return "Error: no collection selected"; + + if (variableToUse == null) + return "Error: no variable selected"; + + return variableToUse.Key + " to " + collection.Value.name; + } + + bool ICollectionCompatible.IsVarCompatibleWithCollection(Variable variable, string compatibleWith) + { + if (compatibleWith == "collection") + return collection.Value == null ? false : collection.Value.IsElementCompatible(variable); + else + return true; + } + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/Collection/CollectionBaseVarCommand.cs.meta b/Assets/Fungus/Scripts/Commands/Collection/CollectionBaseVarCommand.cs.meta new file mode 100644 index 0000000..ee8dd1b --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Collection/CollectionBaseVarCommand.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: fe12b6eb87e59984cb4122f978f11e45 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandAdd.cs b/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandAdd.cs new file mode 100644 index 0000000..82c3b1c --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandAdd.cs @@ -0,0 +1,39 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; + +namespace Fungus +{ + /// + /// Add an item to a collection + /// + [CommandInfo("Collection", + "Add", + "Add an item to a collection")] + [AddComponentMenu("")] + public class CollectionCommandAdd : CollectionBaseVarCommand + { + [Tooltip("Only add if the item does not already exist in the collection")] + [SerializeField] + protected BooleanData onlyIfUnique = new BooleanData(false); + + protected override void OnEnterInner() + { + if (onlyIfUnique.Value) + collection.Value.AddUnique(variableToUse); + else + collection.Value.Add(variableToUse); + } + + public override bool HasReference(Variable variable) + { + return onlyIfUnique.booleanRef == variable || base.HasReference(variable); + } + + public override string GetSummary() + { + return base.GetSummary() + (onlyIfUnique.Value ? " Unique" : ""); + } + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandAdd.cs.meta b/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandAdd.cs.meta new file mode 100644 index 0000000..9b6b035 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandAdd.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: a30a3b6902ecde54ea81d503f6a2b27e +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandAddAll.cs b/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandAddAll.cs new file mode 100644 index 0000000..e31ae98 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandAddAll.cs @@ -0,0 +1,39 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; + +namespace Fungus +{ + /// + /// Add all items in given rhs collection to target collection + /// + [CommandInfo("Collection", + "Add All", + "Add all items in given rhs collection to target collection")] + [AddComponentMenu("")] + public class CollectionCommandAddAll : CollectionBaseTwoCollectionCommand + { + [Tooltip("Only add if the item does not already exist in the collection")] + [SerializeField] + protected BooleanData onlyIfUnique = new BooleanData(false); + + protected override void OnEnterInner() + { + if (onlyIfUnique.Value) + collection.Value.AddUnique(rhsCollection); + else + collection.Value.Add(rhsCollection); + } + + public override bool HasReference(Variable variable) + { + return onlyIfUnique.booleanRef == variable || base.HasReference(variable); + } + + public override string GetSummary() + { + return base.GetSummary() + (onlyIfUnique.Value ? " Unique" : ""); + } + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandAddAll.cs.meta b/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandAddAll.cs.meta new file mode 100644 index 0000000..7f10b77 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandAddAll.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 5688faa1580d8d147b59e18fcdd888ad +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandClear.cs b/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandClear.cs new file mode 100644 index 0000000..19450f9 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandClear.cs @@ -0,0 +1,27 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; + +namespace Fungus +{ + /// + /// Clears a target collection + /// + [CommandInfo("Collection", + "Clear", + "Clears a target collection")] + [AddComponentMenu("")] + public class CollectionCommandClear : CollectionBaseCommand + { + public override void OnEnter() + { + if (collection.Value != null) + { + collection.Value.Clear(); + } + + Continue(); + } + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandClear.cs.meta b/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandClear.cs.meta new file mode 100644 index 0000000..70c94b5 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandClear.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 8b071472a9dcdc7469059042e2e6e50d +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandContains.cs b/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandContains.cs new file mode 100644 index 0000000..bcbd0bc --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandContains.cs @@ -0,0 +1,37 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; + +namespace Fungus +{ + /// + /// Does the collection contain the given variable + /// + [CommandInfo("Collection", + "Contains", + "Does the collection contain the given variable")] + [AddComponentMenu("")] + public class CollectionCommandContains : CollectionBaseVarCommand + { + [VariableProperty(typeof(BooleanVariable))] + [SerializeField] protected BooleanVariable result; + + protected override void OnEnterInner() + { + if (result == null) + { + Debug.LogWarning("No result var set"); + } + else + { + result.Value = collection.Value.Contains(variableToUse); + } + } + + public override bool HasReference(Variable variable) + { + return result == variable || base.HasReference(variable); + } + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandContains.cs.meta b/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandContains.cs.meta new file mode 100644 index 0000000..16c6438 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandContains.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 6bd67ee6ac8134b4e9aea26299040034 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandContainsAll.cs b/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandContainsAll.cs new file mode 100644 index 0000000..834795c --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandContainsAll.cs @@ -0,0 +1,53 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; + +namespace Fungus +{ + /// + /// Does target collection, contain all rhs collection items + /// + [CommandInfo("Collection", + "Contains All Of", + "Does target collection, contain all rhs collection items")] + [AddComponentMenu("")] + public class CollectionCommandContainsAll : CollectionBaseTwoCollectionCommand + { + [Tooltip("Do they have to be in the same order?")] + [SerializeField] + protected BooleanData inSameOrder = new BooleanData(false); + + [VariableProperty(typeof(BooleanVariable))] + [SerializeField] protected BooleanVariable result; + + protected override void OnEnterInner() + { + if (result == null) + { + Debug.LogWarning("No result var set"); + } + else + { + if (inSameOrder.Value) + { + result.Value = collection.Value.ContainsAllOfOrdered(rhsCollection.Value); + } + else + { + result.Value = collection.Value.ContainsAllOf(rhsCollection.Value); + } + } + } + + public override bool HasReference(Variable variable) + { + return result == variable || inSameOrder.booleanRef == variable || base.HasReference(variable); + } + + public override string GetSummary() + { + return base.GetSummary() + (inSameOrder.Value ? " Ordered" : ""); + } + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandContainsAll.cs.meta b/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandContainsAll.cs.meta new file mode 100644 index 0000000..31913de --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandContainsAll.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 1df2de5cf986f9d419a124bb9d834b11 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandContainsAny.cs b/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandContainsAny.cs new file mode 100644 index 0000000..1450f16 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandContainsAny.cs @@ -0,0 +1,37 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; + +namespace Fungus +{ + /// + /// Does target collection, contain any of the items in the rhs collection items + /// + [CommandInfo("Collection", + "Contains Any Of", + "Does target collection, contain any of the items in the rhs collection items")] + [AddComponentMenu("")] + public class CollectionCommandContainsAny : CollectionBaseTwoCollectionCommand + { + [VariableProperty(typeof(BooleanVariable))] + [SerializeField] protected BooleanVariable result; + + protected override void OnEnterInner() + { + if (result == null) + { + Debug.LogWarning("No result var set"); + } + else + { + result.Value = collection.Value.ContainsAnyOf(rhsCollection.Value); + } + } + + public override bool HasReference(Variable variable) + { + return result == variable || base.HasReference(variable); + } + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandContainsAny.cs.meta b/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandContainsAny.cs.meta new file mode 100644 index 0000000..9522c29 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandContainsAny.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: c4e05f36271510b41a7d7889025e180e +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandCopy.cs b/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandCopy.cs new file mode 100644 index 0000000..09663e3 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandCopy.cs @@ -0,0 +1,22 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; + +namespace Fungus +{ + /// + /// Clears target and then adds all of rhs to target. + /// + [CommandInfo("Collection", + "Copy", + "Clears target and then adds all of rhs to target.")] + [AddComponentMenu("")] + public class CollectionCommandCopy : CollectionBaseTwoCollectionCommand + { + protected override void OnEnterInner() + { + collection.Value.CopyFrom(rhsCollection.Value); + } + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandCopy.cs.meta b/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandCopy.cs.meta new file mode 100644 index 0000000..e0a122e --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandCopy.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 820324be5b6a927469519df54a9bbad0 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandCount.cs b/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandCount.cs new file mode 100644 index 0000000..81a4d22 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandCount.cs @@ -0,0 +1,25 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; + +namespace Fungus +{ + /// + /// Number of items in the collection + /// + [CommandInfo("Collection", + "Count", + "Number of items in the collection")] + [CommandInfo("Collection", + "Length", + "Number of items in the collection")] + [AddComponentMenu("")] + public class CollectionCommandCount : CollectionBaseIntCommand + { + protected override void OnEnterInner() + { + integer.Value = collection.Value.Count; + } + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandCount.cs.meta b/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandCount.cs.meta new file mode 100644 index 0000000..d264f4a --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandCount.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 31765259d3ac50e4993fd654cd7ea78b +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandElement.cs b/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandElement.cs new file mode 100644 index 0000000..8183141 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandElement.cs @@ -0,0 +1,53 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; + +namespace Fungus +{ + /// + /// Get or Set, an element in a collection + /// + [CommandInfo("Collection", + "Element", + "Get or Set, an element in a collection")] + [AddComponentMenu("")] + public class CollectionCommandElement : CollectionBaseVarCommand + { + public enum GetSet + { + Get, + Set, + } + + [SerializeField] + protected IntegerData index; + + [SerializeField] + protected GetSet getset = GetSet.Get; + + protected override void OnEnterInner() + { + if (index.Value >= 0 && index.Value < collection.Value.Count) + { + if (getset == GetSet.Get) + { + collection.Value.Get(index.Value, ref variableToUse); + } + else + { + collection.Value.Set(index.Value, variableToUse); + } + } + else + { + throw new System.ArgumentOutOfRangeException(); + } + } + + public override string GetSummary() + { + return base.GetSummary() + " " + getset.ToString(); + } + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandElement.cs.meta b/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandElement.cs.meta new file mode 100644 index 0000000..d2b1137 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandElement.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: bf40659a274400d40856f146223798ac +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandExclusive.cs b/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandExclusive.cs new file mode 100644 index 0000000..dcc396b --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandExclusive.cs @@ -0,0 +1,24 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; + +namespace Fungus +{ + /// + /// Remove all items from collection that are also in RHS and add all the items in RHS that are not already + /// in target. Similar to a xor + /// + [CommandInfo("Collection", + "Exclusive", + "Remove all items from collection that are also in RHS and add all the items in RHS that are not already in target. " + + "Similar to a xor")] + [AddComponentMenu("")] + public class CollectionCommandExclusive : CollectionBaseTwoCollectionCommand + { + protected override void OnEnterInner() + { + collection.Value.Exclusive(rhsCollection.Value); + } + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandExclusive.cs.meta b/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandExclusive.cs.meta new file mode 100644 index 0000000..e4730cf --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandExclusive.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 824e24d12ca84774ea135507417e94a1 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandFind.cs b/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandFind.cs new file mode 100644 index 0000000..b4927e6 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandFind.cs @@ -0,0 +1,41 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; + +namespace Fungus +{ + /// + /// Find an item in a collection + /// + [CommandInfo("Collection", + "Find", + "Find an item in a collection")] + [CommandInfo("Collection", + "IndexOf", + "Find an item in a collection")] + [AddComponentMenu("")] + public class CollectionCommandFind : CollectionBaseVarAndIntCommand + { + [Tooltip("If true, will find the last occurance rather than first occurance.")] + [SerializeField] + protected BooleanData lastInsteadOfFirst = new BooleanData(false); + + protected override void OnEnterInner() + { + integer.Value = !lastInsteadOfFirst.Value ? + collection.Value.IndexOf(variableToUse) + : collection.Value.LastIndexOf(variableToUse); + } + + public override bool HasReference(Variable variable) + { + return lastInsteadOfFirst.booleanRef == variable || base.HasReference(variable); + } + + public override string GetSummary() + { + return base.GetSummary() + (lastInsteadOfFirst.Value ? " Last" : ""); + } + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandFind.cs.meta b/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandFind.cs.meta new file mode 100644 index 0000000..cc1ad6b --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandFind.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 59afe81b26e37ea4ea10dd91dfeee937 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandInsert.cs b/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandInsert.cs new file mode 100644 index 0000000..9a4fe83 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandInsert.cs @@ -0,0 +1,22 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; + +namespace Fungus +{ + /// + /// Add at a specific location in the collection + /// + [CommandInfo("Collection", + "Insert", + "Add at a specific location in the collection")] + [AddComponentMenu("")] + public class CollectionCommandInsert : CollectionBaseVarAndIntCommand + { + protected override void OnEnterInner() + { + collection.Value.Insert(integer.Value, variableToUse); + } + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandInsert.cs.meta b/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandInsert.cs.meta new file mode 100644 index 0000000..6623d38 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandInsert.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: dd126ef47d8264a4d8a6aac5b4f3fb12 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandIntersection.cs b/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandIntersection.cs new file mode 100644 index 0000000..433560e --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandIntersection.cs @@ -0,0 +1,22 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; + +namespace Fungus +{ + /// + /// Remove all items from collection that aren't also in RHS, similar to an overlap. + /// + [CommandInfo("Collection", + "Intersection", + "Remove all items from collection that aren't also in RHS, similar to an overlap.")] + [AddComponentMenu("")] + public class CollectionCommandIntersection : CollectionBaseTwoCollectionCommand + { + protected override void OnEnterInner() + { + collection.Value.Intersection(rhsCollection.Value); + } + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandIntersection.cs.meta b/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandIntersection.cs.meta new file mode 100644 index 0000000..6fefadb --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandIntersection.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 586c189d813b1b045ba358c612f4a6eb +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandOccurrences.cs b/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandOccurrences.cs new file mode 100644 index 0000000..da2034b --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandOccurrences.cs @@ -0,0 +1,22 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; + +namespace Fungus +{ + /// + /// How many occurrences of a given variable exist in a target collection + /// + [CommandInfo("Collection", + "Occurrences", + "How many occurrences of a given variable exist in a target collection")] + [AddComponentMenu("")] + public class CollectionCommandOccurrences : CollectionBaseVarAndIntCommand + { + protected override void OnEnterInner() + { + integer.Value = collection.Value.Occurrences(variableToUse); + } + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandOccurrences.cs.meta b/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandOccurrences.cs.meta new file mode 100644 index 0000000..b1b5323 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandOccurrences.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 75a3711bc9cd44e429e15e10f6029fae +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandRemove.cs b/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandRemove.cs new file mode 100644 index 0000000..4850687 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandRemove.cs @@ -0,0 +1,39 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; + +namespace Fungus +{ + /// + /// Remove an item to a collection + /// + [CommandInfo("Collection", + "Remove", + "Remove an item to a collection")] + [AddComponentMenu("")] + public class CollectionCommandRemove : CollectionBaseVarCommand + { + [Tooltip("Should it remove ALL occurances of variable")] + [SerializeField] + protected BooleanData allOccurances = new BooleanData(false); + + protected override void OnEnterInner() + { + if (allOccurances.Value) + collection.Value.RemoveAll(variableToUse); + else + collection.Value.Remove(variableToUse); + } + + public override bool HasReference(Variable variable) + { + return allOccurances.booleanRef == variable || base.HasReference(variable); + } + + public override string GetSummary() + { + return base.GetSummary() + (allOccurances.Value ? " ALL" : ""); + } + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandRemove.cs.meta b/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandRemove.cs.meta new file mode 100644 index 0000000..6eb7896 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandRemove.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 6e2313a05ce56ea49bbf1922b58d793a +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandRemoveAllOf.cs b/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandRemoveAllOf.cs new file mode 100644 index 0000000..729f8ee --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandRemoveAllOf.cs @@ -0,0 +1,22 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; + +namespace Fungus +{ + /// + /// Remove all items in given rhs collection to target collection + /// + [CommandInfo("Collection", + "Remove All Of", + "Remove all items in given rhs collection to target collection")] + [AddComponentMenu("")] + public class CollectionCommandRemoveAllOf : CollectionBaseTwoCollectionCommand + { + protected override void OnEnterInner() + { + collection.Value.RemoveAll(rhsCollection); + } + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandRemoveAllOf.cs.meta b/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandRemoveAllOf.cs.meta new file mode 100644 index 0000000..ea63a58 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandRemoveAllOf.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 2bb49f43c99a0af4db604a1770b31e83 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandRemoveAt.cs b/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandRemoveAt.cs new file mode 100644 index 0000000..2464277 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandRemoveAt.cs @@ -0,0 +1,22 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; + +namespace Fungus +{ + /// + /// Remove item at given index + /// + [CommandInfo("Collection", + "Remove At", + "Remove item at given index")] + [AddComponentMenu("")] + public class CollectionCommandRemoveAt : CollectionBaseIntCommand + { + protected override void OnEnterInner() + { + collection.Value.RemoveAt(integer.Value); + } + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandRemoveAt.cs.meta b/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandRemoveAt.cs.meta new file mode 100644 index 0000000..d2f4ff5 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandRemoveAt.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: c8ee8f64433f29a4f82b03a8e6550ae2 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandReserve.cs b/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandReserve.cs new file mode 100644 index 0000000..71c287d --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandReserve.cs @@ -0,0 +1,22 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; + +namespace Fungus +{ + /// + /// Reserve space for given number of items in the collection + /// + [CommandInfo("Collection", + "Reserve", + "Reserve space for given number of items in the collection")] + [AddComponentMenu("")] + public class CollectionCommandReserve : CollectionBaseIntCommand + { + protected override void OnEnterInner() + { + collection.Value.Reserve(integer.Value); + } + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandReserve.cs.meta b/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandReserve.cs.meta new file mode 100644 index 0000000..8c44313 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandReserve.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 4672406760fa8f340aabac4528f04c1c +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandResize.cs b/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandResize.cs new file mode 100644 index 0000000..108b37f --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandResize.cs @@ -0,0 +1,22 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; + +namespace Fungus +{ + /// + /// Resize will grow the collection to be the given size, will not remove items to shrink + /// + [CommandInfo("Collection", + "Resize", + "Resize will grow the collection to be the given size, will not remove items to shrink")] + [AddComponentMenu("")] + public class CollectionCommandResize : CollectionBaseIntCommand + { + protected override void OnEnterInner() + { + collection.Value.Resize(integer.Value); + } + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandResize.cs.meta b/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandResize.cs.meta new file mode 100644 index 0000000..413f91f --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandResize.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 3ce11d7cce59a3340937a8d112cd4ad5 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandReverse.cs b/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandReverse.cs new file mode 100644 index 0000000..6a0623d --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandReverse.cs @@ -0,0 +1,27 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; + +namespace Fungus +{ + /// + /// Reverse the current order of a target collection + /// + [CommandInfo("Collection", + "Reverse", + "Reverse the current order of a target collection")] + [AddComponentMenu("")] + public class CollectionCommandReverse : CollectionBaseCommand + { + public override void OnEnter() + { + if (collection.Value != null) + { + collection.Value.Reverse(); + } + + Continue(); + } + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandReverse.cs.meta b/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandReverse.cs.meta new file mode 100644 index 0000000..20b9f67 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandReverse.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: d7359fcb744d14a41acae4b3a2e34b73 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandShuffle.cs b/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandShuffle.cs new file mode 100644 index 0000000..2874992 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandShuffle.cs @@ -0,0 +1,27 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; + +namespace Fungus +{ + /// + /// Randomly reorders all elements of a target collection + /// + [CommandInfo("Collection", + "Shuffle", + "Randomly reorders all elements of a target collection")] + [AddComponentMenu("")] + public class CollectionCommandShuffle : CollectionBaseCommand + { + public override void OnEnter() + { + if (collection.Value != null) + { + collection.Value.Shuffle(); + } + + Continue(); + } + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandShuffle.cs.meta b/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandShuffle.cs.meta new file mode 100644 index 0000000..253917e --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandShuffle.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: a15d511e013edfe45a0a4726bda90c8f +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandSort.cs b/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandSort.cs new file mode 100644 index 0000000..a03926b --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandSort.cs @@ -0,0 +1,27 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; + +namespace Fungus +{ + /// + /// Sort a target collection + /// + [CommandInfo("Collection", + "Sort", + "Sort a target collection")] + [AddComponentMenu("")] + public class CollectionCommandSort : CollectionBaseCommand + { + public override void OnEnter() + { + if (collection.Value != null) + { + collection.Value.Sort(); + } + + Continue(); + } + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandSort.cs.meta b/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandSort.cs.meta new file mode 100644 index 0000000..69fe1e7 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandSort.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 00093f39e8583954ba5935bca806f0f1 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandUnique.cs b/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandUnique.cs new file mode 100644 index 0000000..40ab260 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandUnique.cs @@ -0,0 +1,27 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; + +namespace Fungus +{ + /// + /// Removes all duplicates. + /// + [CommandInfo("Collection", + "Unique", + "Removes all duplicates.")] + [AddComponentMenu("")] + public class CollectionCommandUnique : CollectionBaseCommand + { + public override void OnEnter() + { + if (collection.Value != null) + { + collection.Value.Unique(); + } + + Continue(); + } + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandUnique.cs.meta b/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandUnique.cs.meta new file mode 100644 index 0000000..a8c45c3 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Collection/CollectionCommandUnique.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 59ae026a39db9cf4d8453309fa6192db +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/Collection/CollectionRandom.cs b/Assets/Fungus/Scripts/Commands/Collection/CollectionRandom.cs new file mode 100644 index 0000000..2a149cd --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Collection/CollectionRandom.cs @@ -0,0 +1,22 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; + +namespace Fungus +{ + /// + /// Use the collection as a source of random selection. Picking a random item each run. + /// + [CommandInfo("Collection", + "RandomItem", + "Use the collection as a source of random selection. Picking a random item each run.")] + [AddComponentMenu("")] + public class CollectionRandom : CollectionBaseVarCommand + { + protected override void OnEnterInner() + { + collection.Value.Get(Random.Range(0, collection.Value.Count - 1), ref variableToUse); + } + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/Collection/CollectionRandom.cs.meta b/Assets/Fungus/Scripts/Commands/Collection/CollectionRandom.cs.meta new file mode 100644 index 0000000..0b58949 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Collection/CollectionRandom.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: d58ddca8952c1a149a39835e2eeac9a7 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/Collection/CollectionRandomBag.cs b/Assets/Fungus/Scripts/Commands/Collection/CollectionRandomBag.cs new file mode 100644 index 0000000..3a95c85 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Collection/CollectionRandomBag.cs @@ -0,0 +1,80 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; + +namespace Fungus +{ + /// + /// Use the collection as a source of random items and turn it into a random bag. Drawing the + /// next random item until out of items and then reshuffling them. + /// + [CommandInfo("Collection", + "RandomBag", + "Use the collection as a source of random items and turn it into a random bag. " + + "Drawing the next random item until out of items and then reshuffling them.")] + [AddComponentMenu("")] + public class CollectionRandomBag : CollectionBaseVarCommand + { + [SerializeField] + [Tooltip("Will add this many copies to the bag. If you want 5 of everything, you want 4 copies.")] + protected IntegerData duplicatesToPutInBag = new IntegerData(0); + + [SerializeField] + protected IntegerData currentIndex = new IntegerData(int.MaxValue); + + protected bool isInit = false; + + protected override void OnEnterInner() + { + if (!isInit) + { + Init(); + } + + currentIndex.Value++; + + if (currentIndex.Value >= collection.Value.Count) + { + Reshuffle(); + } + + collection.Value.Get(currentIndex.Value, ref variableToUse); + } + + protected void Init() + { + var startingCount = collection.Value.Count; + for (int i = 0; i < duplicatesToPutInBag.Value; i++) + { + for (int j = 0; j < startingCount; j++) + { + collection.Value.Add(collection.Value.Get(j)); + } + } + + //force invalid index + currentIndex.Value = collection.Value.Count; + + isInit = true; + } + + protected void Reshuffle() + { + currentIndex.Value = 0; + collection.Value.Shuffle(); + } + + public override bool HasReference(Variable variable) + { + return base.HasReference(variable) || duplicatesToPutInBag.integerRef == variable || currentIndex.integerRef; + } + + public override string GetSummary() + { + return base.GetSummary() + + (duplicatesToPutInBag.integerRef != null ? " " + duplicatesToPutInBag.integerRef.Key : "") + + (currentIndex.integerRef != null ? " " + currentIndex.integerRef.Key : ""); ; + } + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/Collection/CollectionRandomBag.cs.meta b/Assets/Fungus/Scripts/Commands/Collection/CollectionRandomBag.cs.meta new file mode 100644 index 0000000..2b99219 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Collection/CollectionRandomBag.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 56176eef6b396a442b08b88220304436 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/Collection/ForEach.cs b/Assets/Fungus/Scripts/Commands/Collection/ForEach.cs new file mode 100644 index 0000000..f3f27ce --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Collection/ForEach.cs @@ -0,0 +1,90 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; + +namespace Fungus +{ + /// + /// Loop over each element in the given collection. + /// + [CommandInfo("Collection", + "For Each", + "Loop over each element in the given collection, similar to a foreach but internally uses indicies")] + [AddComponentMenu("")] + public class ForEach : Condition, ICollectionCompatible + { + [SerializeField] + protected CollectionData collection; + + [SerializeField] + [VariableProperty(compatibleVariableName = "collection")] + protected Variable item; + + [SerializeField] + [Tooltip("Optional")] + protected IntegerData curIndex; + + #region Public members + + public override bool IsLooping { get { return true; } } + + protected override void PreEvaluate() + { + //if we came from the end then we are already looping, if not this is first loop so prep + if (ParentBlock.PreviousActiveCommandIndex != endCommand.CommandIndex) + { + curIndex.Value = -1; + } + } + + protected override bool EvaluateCondition() + { + var col = collection.Value; + curIndex.Value++; + if (curIndex < col.Count) + { + col.Get(curIndex, ref item); + return true; + } + + return false; + } + + protected override void OnFalse() + { + MoveToEnd(); + } + + protected override bool HasNeededProperties() + { + return collection.Value != null && item != null; + } + + public override bool HasReference(Variable variable) + { + return collection.collectionRef == variable || item == variable || + base.HasReference(variable); + } + + bool ICollectionCompatible.IsVarCompatibleWithCollection(Variable variable, string compatibleWith) + { + if (compatibleWith == "collection") + return collection.Value == null ? false : collection.Value.IsElementCompatible(variable); + else + return true; + } + + public override string GetSummary() + { + if (item == null) + return "Error: No item var"; + if (collection.Value == null) + return "Error: No collection"; + + return item.Key + " in " + collection.Value.name; + } + + #endregion Public members + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/Collection/ForEach.cs.meta b/Assets/Fungus/Scripts/Commands/Collection/ForEach.cs.meta new file mode 100644 index 0000000..2c7276c --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Collection/ForEach.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 1ce547d5384ce3a41b7142cab8ab41dd +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/Collection/GameObjectFind.cs b/Assets/Fungus/Scripts/Commands/Collection/GameObjectFind.cs new file mode 100644 index 0000000..7236def --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Collection/GameObjectFind.cs @@ -0,0 +1,51 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; + +namespace Fungus +{ + [CommandInfo("GameObject", + "FindAll", + "Find all gameobjects by tag and store in a collection")] + [AddComponentMenu("")] + public class GameObjectFind : CollectionBaseCommand + { + [Tooltip("Find all gameobjects of tag")] + [SerializeField] + protected StringData tagString; + + public override void OnEnter() + { + var col = collection.Value; + + if (col != null) + { + var res = GameObject.FindGameObjectsWithTag(tagString.Value); + + for (int i = 0; i < res.Length; i++) + { + col.Add(res[i]); + } + } + + Continue(); + } + + public override bool HasReference(Variable variable) + { + return variable == tagString.stringRef || base.HasReference(variable); + } + + public override string GetSummary() + { + if (collection.Value == null) + return "Error: no collection selected"; + + if (!(collection.Value is GameObjectCollection)) + return "Error: collection is not GameObjectCollection"; + + return tagString.Value + " GOs, store in " + collection.Value.name; + } + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/Collection/GameObjectFind.cs.meta b/Assets/Fungus/Scripts/Commands/Collection/GameObjectFind.cs.meta new file mode 100644 index 0000000..7a5bb5c --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Collection/GameObjectFind.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 8509f58e038dd8c46b98cab78d34e06a +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/Collection/Physics2DCast.cs b/Assets/Fungus/Scripts/Commands/Collection/Physics2DCast.cs new file mode 100644 index 0000000..84e753d --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Collection/Physics2DCast.cs @@ -0,0 +1,162 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; + +namespace Fungus +{ + [CommandInfo("Physics2D", + "Cast2D", + "Find all gameobjects hit by given physics shape overlap")] + [AddComponentMenu("")] + public class Physics2DCast : CollectionBaseCommand + { + public enum CastType + { + Box, + Capsule, + Circle, + Line, + Ray, + } + + [Tooltip("")] + [SerializeField] + protected CastType castType = CastType.Ray; + + [Tooltip("Starting point or centre of shape")] + [SerializeField] + protected Vector3Data position1; + + [Tooltip("")] + [SerializeField] + protected Vector3Data direction; + + [Tooltip("")] + [SerializeField] + protected FloatData maxDistance = new FloatData(float.PositiveInfinity); + + [Tooltip("CAPSULE & Circle ONLY")] + [SerializeField] + protected FloatData radius = new FloatData(0.5f); + + [Tooltip("BOX & CAPSULE ONLY")] + [SerializeField] + protected Vector3Data shapeSize = new Vector3Data(Vector3.one * 0.5f); + + [Tooltip("BOX & CAPSULE ONLY")] + [SerializeField] + protected FloatData shapeAngle; + + [Tooltip("LINE ONLY")] + [SerializeField] + protected Vector3Data lineEnd; + + [Tooltip("")] + [SerializeField] + protected LayerMask layerMask = ~0; + + [Tooltip("")] + [SerializeField] + protected FloatData minDepth = new FloatData(float.NegativeInfinity), maxDepth = new FloatData(float.PositiveInfinity); + + [SerializeField] + protected CapsuleDirection2D capsuleDirection; + + public override void OnEnter() + { + var col = collection.Value; + + if (col != null) + { + RaycastHit2D[] resHits = null; + + switch (castType) + { + case CastType.Box: + resHits = Physics2D.BoxCastAll(position1.Value, shapeSize.Value, shapeAngle.Value, direction.Value, maxDistance.Value, layerMask.value, minDepth.Value, maxDepth.Value); + break; + + case CastType.Capsule: + resHits = Physics2D.CapsuleCastAll(position1.Value, shapeSize.Value, capsuleDirection, shapeAngle.Value, direction.Value, maxDistance.Value, layerMask.value, minDepth.Value, maxDepth.Value); + break; + + case CastType.Circle: + resHits = Physics2D.CircleCastAll(position1.Value, radius.Value, direction.Value, maxDistance.Value, layerMask.value, minDepth.Value, maxDepth.Value); + break; + + case CastType.Line: + resHits = Physics2D.LinecastAll(position1.Value, lineEnd.Value, layerMask.value, minDepth.Value, maxDepth.Value); + break; + + case CastType.Ray: + resHits = Physics2D.RaycastAll(position1.Value, direction.Value, maxDistance.Value, layerMask.value, minDepth.Value, maxDepth.Value); + break; + + default: + break; + } + + PutCollidersIntoGameObjectCollection(resHits); + } + + Continue(); + } + + protected void PutCollidersIntoGameObjectCollection(RaycastHit2D[] resColliders) + { + if (resColliders != null) + { + var col = collection.Value; + for (int i = 0; i < resColliders.Length; i++) + { + col.Add(resColliders[i].collider.gameObject); + } + } + } + + public override bool HasReference(Variable variable) + { + return variable == position1.vector3Ref || + variable == radius.floatRef || + variable == shapeSize.vector3Ref || + variable == shapeAngle.floatRef || + variable == minDepth.floatRef || + variable == maxDepth.floatRef || + variable == direction.vector3Ref || + variable == maxDistance.floatRef || + variable == lineEnd.vector3Ref || + base.HasReference(variable); + } + + public override string GetSummary() + { + if (collection.Value == null) + return "Error: no collection selected"; + + //TODO we could support more than just GOs + if (!(collection.Value is GameObjectCollection)) + return "Error: collection is not GameObjectCollection"; + + return castType.ToString() + ", store in " + collection.Value.name; + } + + public override bool IsPropertyVisible(string propertyName) + { + if (castType == CastType.Capsule && propertyName == "capsulePosition2") + return true; + + if (castType == CastType.Line && propertyName == "lineEnd") + return true; + + if ((castType == CastType.Capsule || castType == CastType.Circle) && propertyName == "radius") + return true; + + if ((castType == CastType.Capsule || castType == CastType.Box) && + (propertyName == "shapeAngle" || propertyName == "shapeSize")) + return true; + + return base.IsPropertyVisible(propertyName); + } + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/Collection/Physics2DCast.cs.meta b/Assets/Fungus/Scripts/Commands/Collection/Physics2DCast.cs.meta new file mode 100644 index 0000000..994c591 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Collection/Physics2DCast.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: da8de59f5960f5c4b9d61002cc912b37 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/Collection/Physics2DOverlap.cs b/Assets/Fungus/Scripts/Commands/Collection/Physics2DOverlap.cs new file mode 100644 index 0000000..24da654 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Collection/Physics2DOverlap.cs @@ -0,0 +1,154 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; + +namespace Fungus +{ + [CommandInfo("Physics2D", + "Overlap2D", + "Find all gameobjects hit by given physics shape overlap")] + [AddComponentMenu("")] + public class Physics2DOverlap : CollectionBaseCommand + { + public enum Shape + { + Point, + Area, + Box, + Circle, + Capsule, + } + + [Tooltip("")] + [SerializeField] + protected Shape shape = Shape.Box; + + [Tooltip("Starting point or centre of shape")] + [SerializeField] + protected Vector3Data position1; + + [Tooltip("AREA ONLY")] + [SerializeField] + protected Vector3Data areaEndPosition; + + [Tooltip("CAPSULE & Circle ONLY")] + [SerializeField] + protected FloatData radius = new FloatData(0.5f); + + [Tooltip("BOX & CAPSULE ONLY")] + [SerializeField] + protected Vector3Data shapeSize = new Vector3Data(Vector3.one * 0.5f); + + [Tooltip("BOX & CAPSULE ONLY")] + [SerializeField] + protected FloatData shapeAngle; + + [Tooltip("")] + [SerializeField] + protected LayerMask layerMask = ~0; + + [Tooltip("")] + [SerializeField] + protected FloatData minDepth = new FloatData(float.NegativeInfinity), maxDepth = new FloatData(float.PositiveInfinity); + + [SerializeField] + protected CapsuleDirection2D capsuleDirection; + + public override void OnEnter() + { + var col = collection.Value; + + if (col != null) + { + Collider2D[] resColliders = null; + + switch (shape) + { + case Shape.Area: + resColliders = Physics2D.OverlapAreaAll(position1.Value, areaEndPosition.Value, layerMask.value, minDepth.Value, maxDepth.Value); + break; + + case Shape.Box: + resColliders = Physics2D.OverlapBoxAll(position1.Value, shapeSize.Value, shapeAngle.Value, layerMask.value, minDepth.Value, maxDepth.Value); + break; + + case Shape.Circle: + resColliders = Physics2D.OverlapCircleAll(position1.Value, radius.Value, layerMask.value, minDepth.Value, maxDepth.Value); + break; + + case Shape.Capsule: + resColliders = Physics2D.OverlapCapsuleAll(position1.Value, shapeSize.Value, capsuleDirection, shapeAngle.Value, layerMask.value, minDepth.Value, maxDepth.Value); + break; + + case Shape.Point: + resColliders = Physics2D.OverlapPointAll(position1.Value, layerMask.value, minDepth.Value, maxDepth.Value); + break; + + default: + break; + } + + PutCollidersIntoGameObjectCollection(resColliders); + } + + Continue(); + } + + protected void PutCollidersIntoGameObjectCollection(Collider2D[] resColliders) + { + if (resColliders != null) + { + var col = collection.Value; + for (int i = 0; i < resColliders.Length; i++) + { + col.Add(resColliders[i].gameObject); + } + } + } + + public override bool HasReference(Variable variable) + { + return variable == position1.vector3Ref || + variable == areaEndPosition.vector3Ref || + variable == radius.floatRef || + variable == shapeSize.vector3Ref || + variable == shapeAngle.floatRef || + variable == minDepth.floatRef || + variable == maxDepth.floatRef || + base.HasReference(variable); + } + + public override string GetSummary() + { + if (collection.Value == null) + return "Error: no collection selected"; + + //TODO we could support more than just GOs + if (!(collection.Value is GameObjectCollection)) + return "Error: collection is not GameObjectCollection"; + + return shape.ToString() + ", store in " + collection.Value.name; + } + + public override bool IsPropertyVisible(string propertyName) + { + if (shape == Shape.Capsule && propertyName == "capsulePosition2") + return true; + + if (shape == Shape.Area && propertyName == "areaEndPosition") + return true; + + if ((shape == Shape.Capsule || shape == Shape.Circle) && propertyName == "radius") + return true; + + if ((shape == Shape.Capsule || shape == Shape.Box) && propertyName == "shapeAngle") + return true; + + if (shape == Shape.Box && (propertyName == "boxHalfExtends" || propertyName == "boxOrientation")) + return true; + + return base.IsPropertyVisible(propertyName); + } + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/Collection/Physics2DOverlap.cs.meta b/Assets/Fungus/Scripts/Commands/Collection/Physics2DOverlap.cs.meta new file mode 100644 index 0000000..2369aac --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Collection/Physics2DOverlap.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: c27aec18d802f45429190093660305e4 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/Collection/PhysicsCast.cs b/Assets/Fungus/Scripts/Commands/Collection/PhysicsCast.cs new file mode 100644 index 0000000..f5b145e --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Collection/PhysicsCast.cs @@ -0,0 +1,147 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; + +namespace Fungus +{ + [CommandInfo("Physics", + "Cast", + "Find all gameobjects hit by given physics shape cast")] + [AddComponentMenu("")] + public class PhysicsCast : CollectionBaseCommand + { + public enum CastType + { + Box, + Capsule, + Ray, + Sphere, + } + + [SerializeField] + protected CastType castType = CastType.Ray; + + [Tooltip("Starting point/origin or centre of shape")] + [SerializeField] + protected Vector3Data position1; + + [Tooltip("")] + [SerializeField] + protected Vector3Data direction; + + [Tooltip("")] + [SerializeField] + protected FloatData maxDistance = new FloatData(float.PositiveInfinity); + + [Tooltip("CAPSULE ONLY; end point of the capsule")] + [SerializeField] + protected Vector3Data capsulePosition2; + + [Tooltip("CAPSULE & SPHERE ONLY")] + [SerializeField] + protected FloatData radius = new FloatData(0.5f); + + [Tooltip("BOX ONLY")] + [SerializeField] + protected Vector3Data boxHalfExtends = new Vector3Data(Vector3.one * 0.5f); + + [Tooltip("BOX ONLY")] + [SerializeField] + protected QuaternionData boxOrientation = new QuaternionData(Quaternion.identity); + + [Tooltip("")] + [SerializeField] + protected LayerMask layerMask = ~0; + + [Tooltip("")] + [SerializeField] + protected QueryTriggerInteraction queryTriggerInteraction = QueryTriggerInteraction.UseGlobal; + + public override void OnEnter() + { + var col = collection.Value; + + if (col != null) + { + RaycastHit[] resHits = null; + + switch (castType) + { + case CastType.Ray: + resHits = Physics.RaycastAll(position1.Value, direction.Value, maxDistance.Value, layerMask.value, queryTriggerInteraction); + break; + + case CastType.Sphere: + resHits = Physics.SphereCastAll(position1.Value, radius.Value, direction.Value, maxDistance.Value, layerMask.value, queryTriggerInteraction); + break; + + case CastType.Box: + resHits = Physics.BoxCastAll(position1.Value, boxHalfExtends.Value, direction.Value, boxOrientation.Value, maxDistance.Value, layerMask.value, queryTriggerInteraction); + break; + + case CastType.Capsule: + resHits = Physics.CapsuleCastAll(position1.Value, capsulePosition2.Value, radius.Value, direction.Value, maxDistance.Value, layerMask.value, queryTriggerInteraction); + break; + + default: + break; + } + + PutCollidersIntoGameObjectCollection(resHits); + } + + Continue(); + } + + protected void PutCollidersIntoGameObjectCollection(RaycastHit[] resHits) + { + if (resHits != null) + { + var col = collection.Value; + for (int i = 0; i < resHits.Length; i++) + { + col.Add(resHits[i].collider.gameObject); + } + } + } + + public override bool HasReference(Variable variable) + { + return variable == direction.vector3Ref || + variable == maxDistance.floatRef || + variable == position1.vector3Ref || + variable == capsulePosition2.vector3Ref || + variable == radius.floatRef || + variable == boxHalfExtends.vector3Ref || + variable == boxOrientation.quaternionRef || + base.HasReference(variable); + } + + public override string GetSummary() + { + if (collection.Value == null) + return "Error: no collection selected"; + + //TODO we could support more than just GOs + if (!(collection.Value is GameObjectCollection)) + return "Error: collection is not GameObjectCollection"; + + return castType.ToString() + ", store in " + collection.Value.name; + } + + public override bool IsPropertyVisible(string propertyName) + { + if (castType == CastType.Capsule && propertyName == "capsulePosition2") + return true; + + if ((castType == CastType.Capsule || castType == CastType.Sphere) && propertyName == "radius") + return true; + + if (castType == CastType.Box && (propertyName == "boxHalfExtends" || propertyName == "boxOrientation")) + return true; + + return base.IsPropertyVisible(propertyName); + } + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/Collection/PhysicsCast.cs.meta b/Assets/Fungus/Scripts/Commands/Collection/PhysicsCast.cs.meta new file mode 100644 index 0000000..272dbd8 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Collection/PhysicsCast.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 44a4b238cb3af004bbae4a6145089ea2 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/Collection/PhysicsOverlap.cs b/Assets/Fungus/Scripts/Commands/Collection/PhysicsOverlap.cs new file mode 100644 index 0000000..1cb6e79 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Collection/PhysicsOverlap.cs @@ -0,0 +1,136 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; + +namespace Fungus +{ + /// + /// + /// + [CommandInfo("Physics", + "Overlap", + "Find all gameobjects hit by given physics shape overlap")] + [AddComponentMenu("")] + public class PhysicsOverlap : CollectionBaseCommand + { + public enum Shape + { + Box, + Capsule, + Sphere, + } + + [Tooltip("")] + [SerializeField] + protected Shape shape = Shape.Box; + + [Tooltip("Starting point or centre of shape")] + [SerializeField] + protected Vector3Data position1; + + [Tooltip("CAPSULE ONLY; end point of the capsule")] + [SerializeField] + protected Vector3Data capsulePosition2; + + [Tooltip("CAPSULE & SPHERE ONLY")] + [SerializeField] + protected FloatData radius = new FloatData(0.5f); + + [Tooltip("BOX ONLY")] + [SerializeField] + protected Vector3Data boxHalfExtends = new Vector3Data(Vector3.one * 0.5f); + + [Tooltip("BOX ONLY")] + [SerializeField] + protected QuaternionData boxOrientation = new QuaternionData(Quaternion.identity); + + [Tooltip("")] + [SerializeField] + protected LayerMask layerMask = ~0; + + [Tooltip("")] + [SerializeField] + protected QueryTriggerInteraction queryTriggerInteraction = QueryTriggerInteraction.UseGlobal; + + public override void OnEnter() + { + var col = collection.Value; + + if (col != null) + { + Collider[] resColliders = null; + + switch (shape) + { + case Shape.Box: + resColliders = Physics.OverlapBox(position1.Value, boxHalfExtends.Value, boxOrientation.Value, layerMask.value, queryTriggerInteraction); + break; + + case Shape.Sphere: + resColliders = Physics.OverlapSphere(position1.Value, radius.Value, layerMask.value, queryTriggerInteraction); + break; + + case Shape.Capsule: + resColliders = Physics.OverlapCapsule(position1.Value, capsulePosition2.Value, radius.Value, layerMask.value, queryTriggerInteraction); + break; + + default: + break; + } + + PutCollidersIntoGameObjectCollection(resColliders); + } + + Continue(); + } + + protected void PutCollidersIntoGameObjectCollection(Collider[] resColliders) + { + if (resColliders != null) + { + var col = collection.Value; + for (int i = 0; i < resColliders.Length; i++) + { + col.Add(resColliders[i].gameObject); + } + } + } + + public override bool HasReference(Variable variable) + { + return variable == position1.vector3Ref || + variable == capsulePosition2.vector3Ref || + variable == radius.floatRef || + variable == boxHalfExtends.vector3Ref || + variable == boxOrientation.quaternionRef || + base.HasReference(variable); + } + + public override string GetSummary() + { + if (collection.Value == null) + return "Error: no collection selected"; + + //TODO we could support more than just GOs + if (!(collection.Value is GameObjectCollection)) + return "Error: collection is not GameObjectCollection"; + + return shape.ToString() + ", store in " + collection.Value.name; + } + + public override bool IsPropertyVisible(string propertyName) + { + if (shape == Shape.Capsule && propertyName == "capsulePosition2") + return true; + + if ((shape == Shape.Capsule || shape == Shape.Sphere) && propertyName == "radius") + return true; + + if (shape == Shape.Box && (propertyName == "boxHalfExtends" || propertyName == "boxOrientation")) + return true; + + return base.IsPropertyVisible(propertyName); + } + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/Collection/PhysicsOverlap.cs.meta b/Assets/Fungus/Scripts/Commands/Collection/PhysicsOverlap.cs.meta new file mode 100644 index 0000000..57665f6 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Collection/PhysicsOverlap.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 5996bc0e902a19f4fa257341b0691de3 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/Comment.cs b/Assets/Fungus/Scripts/Commands/Comment.cs new file mode 100644 index 0000000..ac6bd3f --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Comment.cs @@ -0,0 +1,47 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; + +namespace Fungus +{ + /// + /// Use comments to record design notes and reminders about your game. + /// + [CommandInfo("", + "Comment", + "Use comments to record design notes and reminders about your game.")] + [AddComponentMenu("")] + public class Comment : Command + { + [Tooltip("Name of Commenter")] + [SerializeField] protected string commenterName = ""; + + [Tooltip("Text to display for this comment")] + [TextArea(2,4)] + [SerializeField] protected string commentText = ""; + + #region Public members + + public override void OnEnter() + { + Continue(); + } + + public override string GetSummary() + { + if (commenterName != "") + { + return commenterName + ": " + commentText; + } + return commentText; + } + + public override Color GetButtonColor() + { + return new Color32(220, 220, 220, 255); + } + + #endregion + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/Comment.cs.meta b/Assets/Fungus/Scripts/Commands/Comment.cs.meta new file mode 100644 index 0000000..b265a61 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Comment.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: ea6e8f632db87477eb750446b28d73a3 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Fungus/Scripts/Commands/Condition.cs b/Assets/Fungus/Scripts/Commands/Condition.cs new file mode 100644 index 0000000..5af13b8 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Condition.cs @@ -0,0 +1,285 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; + +namespace Fungus +{ + /// + /// Base for all Conditional based Commands, Ifs, Loops, and so on. + /// + [AddComponentMenu("")] + public abstract class Condition : Command + { + protected End endCommand; + + public override void OnEnter() + { + if (ParentBlock == null) + { + return; + } + + //if looping we need the end command in order to work + if(IsLooping && !EnsureRequiredEnd()) + { + Debug.LogError(GetLocationIdentifier() + " is looping but has no matching End command"); + Continue(); + return; + } + + if ( !HasNeededProperties() ) + { + Debug.LogError(GetLocationIdentifier() + " cannot run due to missing required properties"); + Continue(); + return; + } + + //Ensuring we arrived at this elif honestly, not incorrectly due to fall through from a previous command + if (this.IsElseIf && !DoesPassElifSanityCheck()) + { + //elif is being asked to run but didn't come from a previously failing if or elif, this isn't allowed + MoveToEnd(); + return; + } + + EvaluateAndContinue(); + } + + public override bool OpenBlock() + { + return true; + } + + public override Color GetButtonColor() + { + return new Color32(253, 253, 150, 255); + } + + public virtual bool IsLooping { get { return false; } } + + + /// + /// Moves execution to the closing End of the current command, attempts to locate end if not + /// already known and if no closing End exists. + /// + public virtual void MoveToEnd() + { + if(endCommand == null) + { + endCommand = FindOurEndCommand(); + } + + if (endCommand != null) + { + // Continue at next command after End + // and make the end non looping incase it gets run via index etc. + endCommand.Loop = false; + Continue(endCommand.CommandIndex + 1); + } + else + { + //nowhere to go, so we assume the block wants to stop but is missing and end, this + // is also ensures back compat + Debug.LogWarning("Condition wants to move to end but no End command found, stopping block. " + GetLocationIdentifier()); + StopParentBlock(); + } + } + + + protected End FindOurEndCommand() + { + return FindMatchingEndCommand(this); + } + + /// + /// Helper to find the paired End Command for the given command. + /// + /// + /// Mathcing End Command or null if not found + public static End FindMatchingEndCommand(Command startCommand) + { + if (startCommand.ParentBlock == null) + return null; + + int indent = startCommand.IndentLevel; + for (int i = startCommand.CommandIndex + 1; i < startCommand.ParentBlock.CommandList.Count; ++i) + { + var command = startCommand.ParentBlock.CommandList[i]; + + if (command.IndentLevel == indent) + { + if (command is End) + { + return command as End; + } + } + else if (command.IndentLevel < indent) + { + //managed to be less indent than the inner but not find and end, this shouldn't occur + // but may be user error or bad data, makes sense for completeness here + return null; + } + } + + return null; + } + + /// + /// Helper for child classes that require an End command to function. For IsLooping commands + /// this also configures the loopback within the End command. + /// + /// + protected virtual bool EnsureRequiredEnd() + { + if (endCommand == null) + { + endCommand = FindOurEndCommand(); + + if (endCommand == null) + { + Debug.LogError( GetLocationIdentifier() + "', could not find closing End command and thus cannot loop."); + //StopParentBlock(); + return false; + } + } + + if (IsLooping) + { + // Tell the following end command to loop back + endCommand.Loop = true; + endCommand.LoopBackIndex = CommandIndex; + } + return true; + } + + /// + /// Called by OnEnter when the condition is needed to evaluate and continue execution. + /// Means child classes do not have to deal with erronuous execution conditions, like fall through. + /// + protected virtual void EvaluateAndContinue() + { + PreEvaluate(); + + if (EvaluateCondition()) + { + OnTrue(); + } + else + { + OnFalse(); + } + } + + /// + /// Called when the condition is run and EvaluateCondition returns true + /// + protected virtual void OnTrue() + { + Continue(); + } + + /// + /// Called when the condition is run and EvaluateCondition returns false + /// + protected virtual void OnFalse() + { + //looping constructs only care about the end + if(IsLooping) + { + MoveToEnd(); + return; + } + + // Find the next Else, ElseIf or End command at the same indent level as this If command + for (int i = CommandIndex + 1; i < ParentBlock.CommandList.Count; ++i) + { + Command nextCommand = ParentBlock.CommandList[i]; + + if (nextCommand == null) + { + continue; + } + + // Find next command at same indent level as this If command + // Skip disabled commands, comments & labels + if (!((Command)nextCommand).enabled || + nextCommand.GetType() == typeof(Comment) || + nextCommand.GetType() == typeof(Label) || + nextCommand.IndentLevel != indentLevel) + { + continue; + } + + System.Type type = nextCommand.GetType(); + if (type == typeof(Else) || + type == typeof(End)) + { + if (i >= ParentBlock.CommandList.Count - 1) + { + // Last command in Block, so stop + StopParentBlock(); + } + else + { + // Execute command immediately after the Else or End command + Continue(nextCommand.CommandIndex + 1); + return; + } + } + else if (type.IsSubclassOf(typeof(Condition)) && (nextCommand as Condition).IsElseIf) + { + // Execute the Else If command + Continue(i); + return; + } + } + + // No matching End command found, so just stop the block + StopParentBlock(); + } + + /// + /// Sits in the if within EvaluateAndContinue, if returns true, OnTrue will run, if false, OnFalse will run. + /// + protected abstract bool EvaluateCondition(); + + /// + /// Child classes are required to report if it is possible for them to be evaulated. + /// + protected virtual bool HasNeededProperties() { return true; } + + /// + /// Declare if the child class is implementing an 'else if' command, which requires some special handling + /// + protected virtual bool IsElseIf { get { return false; } } + + /// + /// Called before EvaluateCondition, allowing for child classes to gather required data + /// + protected virtual void PreEvaluate() { } + + /// + /// Ensure that this condition didn't come from a non matching if/elif. + /// + /// + protected virtual bool DoesPassElifSanityCheck() + { + System.Type previousCommandType = ParentBlock.GetPreviousActiveCommandType(); + var prevCmdIndent = ParentBlock.GetPreviousActiveCommandIndent(); + var prevCmd = ParentBlock.GetPreviousActiveCommand(); + + //handle our matching if or else if in the chain failing and moving to us, + // need to make sure it is the same indent level + if (prevCmd == null || + prevCmdIndent != IndentLevel || + !previousCommandType.IsSubclassOf(typeof(Condition)) || + (prevCmd as Condition).IsLooping) + { + return false; + } + + return true; + } + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/Condition.cs.meta b/Assets/Fungus/Scripts/Commands/Condition.cs.meta new file mode 100644 index 0000000..1a3eefd --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Condition.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: a5a19bbd99c314af6aa3f3319ca323b2 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Fungus/Scripts/Commands/ControlAudio.cs b/Assets/Fungus/Scripts/Commands/ControlAudio.cs new file mode 100644 index 0000000..ef14850 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/ControlAudio.cs @@ -0,0 +1,309 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; +using UnityEngine.Serialization; +using System.Collections; + +namespace Fungus +{ + /// + /// The type of audio control to perform. + /// + public enum ControlAudioType + { + /// Play the audiosource once. + PlayOnce, + /// Play the audiosource in a loop. + PlayLoop, + /// Pause a looping audiosource. + PauseLoop, + /// Stop a looping audiosource. + StopLoop, + /// Change the volume level of an audiosource. + ChangeVolume + } + + /// + /// Plays, loops, or stops an audiosource. Any AudioSources with the same tag as the target Audio Source will automatically be stoped. + /// + [CommandInfo("Audio", + "Control Audio", + "Plays, loops, or stops an audiosource. Any AudioSources with the same tag as the target Audio Source will automatically be stoped.")] + [ExecuteInEditMode] + public class ControlAudio : Command + { + [Tooltip("What to do to audio")] + [SerializeField] protected ControlAudioType control; + public virtual ControlAudioType Control { get { return control; } } + + [Tooltip("Audio clip to play")] + [SerializeField] protected AudioSourceData _audioSource; + + [Range(0,1)] + [Tooltip("Start audio at this volume")] + [SerializeField] protected float startVolume = 1; + + [Range(0,1)] + [Tooltip("End audio at this volume")] + [SerializeField] protected float endVolume = 1; + + [Tooltip("Time to fade between current volume level and target volume level.")] + [SerializeField] protected float fadeDuration; + + [Tooltip("Wait until this command has finished before executing the next command.")] + [SerializeField] protected bool waitUntilFinished = false; + + // If there's other music playing in the scene, assign it the same tag as the new music you want to play and + // the old music will be automatically stopped. + protected virtual void StopAudioWithSameTag() + { + // Don't stop audio if there's no tag assigned + if (_audioSource.Value == null || + _audioSource.Value.tag == "Untagged") + { + return; + } + + var audioSources = GameObject.FindObjectsOfType(); + for (int i = 0; i < audioSources.Length; i++) + { + var a = audioSources[i]; + if (a != _audioSource.Value && a.tag == _audioSource.Value.tag) + { + StopLoop(a); + } + } + } + + protected virtual void PlayOnce() + { + if (fadeDuration > 0) + { + // Fade volume in + LeanTween.value(_audioSource.Value.gameObject, + _audioSource.Value.volume, + endVolume, + fadeDuration + ).setOnUpdate( + (float updateVolume)=>{ + _audioSource.Value.volume = updateVolume; + }); + } + + _audioSource.Value.PlayOneShot(_audioSource.Value.clip); + + if (waitUntilFinished) + { + StartCoroutine(WaitAndContinue()); + } + } + + protected virtual IEnumerator WaitAndContinue() + { + // Poll the audiosource until playing has finished + // This allows for things like effects added to the audiosource. + while (_audioSource.Value.isPlaying) + { + yield return null; + } + + Continue(); + } + + protected virtual void PlayLoop() + { + if (fadeDuration > 0) + { + _audioSource.Value.volume = 0; + _audioSource.Value.loop = true; + _audioSource.Value.GetComponent().Play(); + LeanTween.value(_audioSource.Value.gameObject,0,endVolume,fadeDuration + ).setOnUpdate( + (float updateVolume)=>{ + _audioSource.Value.volume = updateVolume; + } + ).setOnComplete( + ()=>{ + if (waitUntilFinished) + { + Continue(); + } + } + ); + } + else + { + _audioSource.Value.volume = endVolume; + _audioSource.Value.loop = true; + _audioSource.Value.GetComponent().Play(); + } + } + + protected virtual void PauseLoop() + { + if (fadeDuration > 0) + { + LeanTween.value(_audioSource.Value.gameObject,_audioSource.Value.volume,0,fadeDuration + ).setOnUpdate( + (float updateVolume)=>{ + _audioSource.Value.volume = updateVolume; + } + ).setOnComplete( + ()=>{ + + _audioSource.Value.GetComponent().Pause(); + if (waitUntilFinished) + { + Continue(); + } + } + ); + } + else + { + _audioSource.Value.GetComponent().Pause(); + } + } + + protected virtual void StopLoop(AudioSource source) + { + if (fadeDuration > 0) + { + LeanTween.value(source.gameObject,_audioSource.Value.volume,0,fadeDuration + ).setOnUpdate( + (float updateVolume)=>{ + source.volume = updateVolume; + } + ).setOnComplete( + ()=>{ + + source.GetComponent().Stop(); + if (waitUntilFinished) + { + Continue(); + } + } + ); + } + else + { + source.GetComponent().Stop(); + } + } + + protected virtual void ChangeVolume() + { + LeanTween.value(_audioSource.Value.gameObject,_audioSource.Value.volume,endVolume,fadeDuration + ).setOnUpdate( + (float updateVolume)=>{ + _audioSource.Value.volume = updateVolume; + }).setOnComplete( + ()=>{ + if (waitUntilFinished) + { + Continue(); + } + }); + } + + protected virtual void AudioFinished() + { + if (waitUntilFinished) + { + Continue(); + } + } + + #region Public members + + public override void OnEnter() + { + if (_audioSource.Value == null) + { + Continue(); + return; + } + + if (control != ControlAudioType.ChangeVolume) + { + _audioSource.Value.volume = endVolume; + } + + switch(control) + { + case ControlAudioType.PlayOnce: + StopAudioWithSameTag(); + PlayOnce(); + break; + case ControlAudioType.PlayLoop: + StopAudioWithSameTag(); + PlayLoop(); + break; + case ControlAudioType.PauseLoop: + PauseLoop(); + break; + case ControlAudioType.StopLoop: + StopLoop(_audioSource.Value); + break; + case ControlAudioType.ChangeVolume: + ChangeVolume(); + break; + } + if (!waitUntilFinished) + { + Continue(); + } + } + + public override string GetSummary() + { + if (_audioSource.Value == null) + { + return "Error: No sound clip selected"; + } + string fadeType = ""; + if (fadeDuration > 0) + { + fadeType = " Fade out"; + if (control != ControlAudioType.StopLoop) + { + fadeType = " Fade in volume to " + endVolume; + } + if (control == ControlAudioType.ChangeVolume) + { + fadeType = " to " + endVolume; + } + fadeType += " over " + fadeDuration + " seconds."; + } + return control.ToString() + " \"" + _audioSource.Value.name + "\"" + fadeType; + } + + public override Color GetButtonColor() + { + return new Color32(242, 209, 176, 255); + } + + public override bool HasReference(Variable variable) + { + return _audioSource.audioSourceRef == variable || base.HasReference(variable); + } + + #endregion + + #region Backwards compatibility + + [HideInInspector] [FormerlySerializedAs("audioSource")] public AudioSource audioSourceOLD; + + protected virtual void OnEnable() + { + if (audioSourceOLD != null) + { + _audioSource.Value = audioSourceOLD; + audioSourceOLD = null; + } + } + + #endregion + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/ControlAudio.cs.meta b/Assets/Fungus/Scripts/Commands/ControlAudio.cs.meta new file mode 100644 index 0000000..1b4fb1e --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/ControlAudio.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: bc30c92f7ffe3d746ac76cd528d616e5 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Fungus/Scripts/Commands/ControlStage.cs b/Assets/Fungus/Scripts/Commands/ControlStage.cs new file mode 100644 index 0000000..06ccb02 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/ControlStage.cs @@ -0,0 +1,219 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; + +namespace Fungus +{ + /// + /// Supported display operations for Stage. + /// + public enum StageDisplayType + { + /// No operation + None, + /// Show the stage and all portraits. + Show, + /// Hide the stage and all portraits. + Hide, + /// Swap the stage and all portraits with another stage. + Swap, + /// Move stage to the front. + MoveToFront, + /// Undim all portraits on the stage. + UndimAllPortraits, + /// Dim all non-speaking portraits on the stage. + DimNonSpeakingPortraits + } + + /// + /// Controls the stage on which character portraits are displayed. + /// + [CommandInfo("Narrative", + "Control Stage", + "Controls the stage on which character portraits are displayed.")] + public class ControlStage : ControlWithDisplay + { + [Tooltip("Stage to display characters on")] + [SerializeField] protected Stage stage; + public virtual Stage _Stage { get { return stage; } } + + [Tooltip("Stage to swap with")] + [SerializeField] protected Stage replacedStage; + + [Tooltip("Use Default Settings")] + [SerializeField] protected bool useDefaultSettings = true; + public virtual bool UseDefaultSettings { get { return useDefaultSettings; } } + + [Tooltip("Fade Duration")] + [SerializeField] protected float fadeDuration; + + [Tooltip("Wait until the tween has finished before executing the next command")] + [SerializeField] protected bool waitUntilFinished = false; + + protected virtual void Show(Stage stage, bool visible) + { + float duration = (fadeDuration == 0) ? float.Epsilon : fadeDuration; + float targetAlpha = visible ? 1f : 0f; + + CanvasGroup canvasGroup = stage.GetComponentInChildren(); + if (canvasGroup == null) + { + Continue(); + return; + } + + LeanTween.value(canvasGroup.gameObject, canvasGroup.alpha, targetAlpha, duration).setOnUpdate( (float alpha) => { + canvasGroup.alpha = alpha; + }).setOnComplete( () => { + OnComplete(); + }); + } + + protected virtual void MoveToFront(Stage stage) + { + var activeStages = Stage.ActiveStages; + for (int i = 0; i < activeStages.Count; i++) + { + var s = activeStages[i]; + if (s == stage) + { + s.PortraitCanvas.sortingOrder = 1; + } + else + { + s.PortraitCanvas.sortingOrder = 0; + } + } + } + + protected virtual void UndimAllPortraits(Stage stage) + { + stage.DimPortraits = false; + var charactersOnStage = stage.CharactersOnStage; + for (int i = 0; i < charactersOnStage.Count; i++) + { + var character = charactersOnStage[i]; + stage.SetDimmed(character, false); + } + } + + protected virtual void DimNonSpeakingPortraits(Stage stage) + { + stage.DimPortraits = true; + } + + protected virtual void OnComplete() + { + if (waitUntilFinished) + { + Continue(); + } + } + + #region Public members + + public override void OnEnter() + { + // If no display specified, do nothing + if (IsDisplayNone(display)) + { + Continue(); + return; + } + + // Selected "use default Portrait Stage" + if (stage == null) + { + // If no default specified, try to get any portrait stage in the scene + stage = FindObjectOfType(); + + // If portrait stage does not exist, do nothing + if (stage == null) + { + Continue(); + return; + } + } + + // Selected "use default Portrait Stage" + if (display == StageDisplayType.Swap) // Default portrait stage selected + { + if (replacedStage == null) // If no default specified, try to get any portrait stage in the scene + { + replacedStage = GameObject.FindObjectOfType(); + } + // If portrait stage does not exist, do nothing + if (replacedStage == null) + { + Continue(); + return; + } + } + // Use default settings + if (useDefaultSettings) + { + fadeDuration = stage.FadeDuration; + } + switch(display) + { + case (StageDisplayType.Show): + Show(stage, true); + break; + case (StageDisplayType.Hide): + Show(stage, false); + break; + case (StageDisplayType.Swap): + Show(stage, true); + Show(replacedStage, false); + break; + case (StageDisplayType.MoveToFront): + MoveToFront(stage); + break; + case (StageDisplayType.UndimAllPortraits): + UndimAllPortraits(stage); + break; + case (StageDisplayType.DimNonSpeakingPortraits): + DimNonSpeakingPortraits(stage); + break; + } + + if (!waitUntilFinished) + { + Continue(); + } + } + + public override string GetSummary() + { + string displaySummary = ""; + if (display != StageDisplayType.None) + { + displaySummary = StringFormatter.SplitCamelCase(display.ToString()); + } + else + { + return "Error: No display selected"; + } + string stageSummary = ""; + if (stage != null) + { + stageSummary = " \"" + stage.name + "\""; + } + return displaySummary + stageSummary; + } + + public override Color GetButtonColor() + { + return new Color32(230, 200, 250, 255); + } + + public override void OnCommandAdded(Block parentBlock) + { + //Default to display type: show + display = StageDisplayType.Show; + } + + #endregion + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/ControlStage.cs.meta b/Assets/Fungus/Scripts/Commands/ControlStage.cs.meta new file mode 100644 index 0000000..15b28d7 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/ControlStage.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: f1ff0f540016ff64ab1556db6fe1e10f +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Fungus/Scripts/Commands/ControlWithDisplay.cs b/Assets/Fungus/Scripts/Commands/ControlWithDisplay.cs new file mode 100644 index 0000000..3357d45 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/ControlWithDisplay.cs @@ -0,0 +1,26 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using System; +using UnityEngine; + +namespace Fungus +{ + public class ControlWithDisplay : Command + { + [Tooltip("Display type")] + [SerializeField] protected TDisplayEnum display; + + protected virtual bool IsDisplayNone(TEnum enumValue) + { + string displayTypeStr = Enum.GetName(typeof (TEnum), enumValue); + return displayTypeStr == "None"; + } + + #region Public members + + public virtual TDisplayEnum Display { get { return display; } } + + #endregion + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/ControlWithDisplay.cs.meta b/Assets/Fungus/Scripts/Commands/ControlWithDisplay.cs.meta new file mode 100644 index 0000000..3cb3a56 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/ControlWithDisplay.cs.meta @@ -0,0 +1,12 @@ +fileFormatVersion: 2 +guid: 6b4717bbde4a5e64893724b3db7eb32c +timeCreated: 1463225157 +licenseType: Store +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/Conversation.cs b/Assets/Fungus/Scripts/Commands/Conversation.cs new file mode 100644 index 0000000..2ebcda9 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Conversation.cs @@ -0,0 +1,90 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; +using System.Collections; + +namespace Fungus +{ + /// + /// Do multiple say and portrait commands in a single block of text. Format is: [character] [portrait] [stage position] [hide] [<<< | >>>] [clear | noclear] [wait | nowait] [fade | nofade] [: Story text]. + /// + [CommandInfo("Narrative", + "Conversation", + "Do multiple say and portrait commands in a single block of text. Format is: [character] [portrait] [stage position] [hide] [<<< | >>>] [clear | noclear] [wait | nowait] [fade | nofade] [: Story text]")] + [AddComponentMenu("")] + [ExecuteInEditMode] + public class Conversation : Command + { + [SerializeField] protected StringDataMulti conversationText; + + protected ConversationManager conversationManager = new ConversationManager(); + + [SerializeField] protected BooleanData clearPrevious = new BooleanData(true); + [SerializeField] protected BooleanData waitForInput = new BooleanData(true); + [Tooltip("a wait for seconds added to each item of the conversation.")] + [SerializeField] protected FloatData waitForSeconds = new FloatData(0); + [SerializeField] protected BooleanData fadeWhenDone = new BooleanData(true); + + protected virtual void Start() + { + conversationManager.PopulateCharacterCache(); + } + + protected virtual IEnumerator DoConversation() + { + var flowchart = GetFlowchart(); + string subbedText = flowchart.SubstituteVariables(conversationText.Value); + + conversationManager.ClearPrev = clearPrevious; + conversationManager.WaitForInput = waitForInput; + conversationManager.FadeDone = fadeWhenDone; + conversationManager.WaitForSeconds = waitForSeconds; + + yield return StartCoroutine(conversationManager.DoConversation(subbedText)); + + Continue(); + } + + #region Public members + + public override void OnEnter() + { + StartCoroutine(DoConversation()); + } + + public override string GetSummary() + { + return conversationText.Value; + } + + public override Color GetButtonColor() + { + return new Color32(184, 210, 235, 255); + } + + public override bool HasReference(Variable variable) + { + return clearPrevious.booleanRef == variable || waitForInput.booleanRef == variable || + waitForSeconds.floatRef == variable || fadeWhenDone.booleanRef == variable || + base.HasReference(variable); + } + + #endregion + + + #region Editor caches +#if UNITY_EDITOR + protected override void RefreshVariableCache() + { + base.RefreshVariableCache(); + + var f = GetFlowchart(); + + if(!string.IsNullOrEmpty(conversationText.Value)) + f.DetermineSubstituteVariables(conversationText, referencedVariables); + } +#endif + #endregion Editor caches + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/Conversation.cs.meta b/Assets/Fungus/Scripts/Commands/Conversation.cs.meta new file mode 100644 index 0000000..8f601a9 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Conversation.cs.meta @@ -0,0 +1,12 @@ +fileFormatVersion: 2 +guid: f608b8c9fb3044200aac956492d8d586 +timeCreated: 1469542178 +licenseType: Store +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/DebugBreak.cs b/Assets/Fungus/Scripts/Commands/DebugBreak.cs new file mode 100644 index 0000000..2dd31d7 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/DebugBreak.cs @@ -0,0 +1,42 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; + +namespace Fungus +{ + /// + /// Writes a log message to the debug console. + /// + [CommandInfo("Scripting", + "Debug Break", + "Calls Debug.Break if enabled. Also useful for putting a visual studio breakbpoint within.")] + [AddComponentMenu("")] + public class DebugBreak : Command + { + [SerializeField] new protected BooleanData enabled = new BooleanData(true); + + public override void OnEnter() + { + if (enabled.Value) + Debug.Break(); + + Continue(); + } + + public override string GetSummary() + { + return enabled.Value ? "enabled" : "disabled"; + } + + public override bool HasReference(Variable variable) + { + return variable == enabled.booleanRef; + } + + public override Color GetButtonColor() + { + return new Color32(235, 191, 217, 255); + } + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/DebugBreak.cs.meta b/Assets/Fungus/Scripts/Commands/DebugBreak.cs.meta new file mode 100644 index 0000000..cc5c158 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/DebugBreak.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: a14b04da97ec217478d0809feef89ec8 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/DebugLog.cs b/Assets/Fungus/Scripts/Commands/DebugLog.cs new file mode 100644 index 0000000..d67c4c4 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/DebugLog.cs @@ -0,0 +1,89 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; + +namespace Fungus +{ + /// + /// Type of log message. Maps directly to Unity's log types. + /// + public enum DebugLogType + { + /// Informative log message. + Info, + /// Warning log message. + Warning, + /// Error log message. + Error + } + + /// + /// Writes a log message to the debug console. + /// + [CommandInfo("Scripting", + "Debug Log", + "Writes a log message to the debug console.")] + [AddComponentMenu("")] + public class DebugLog : Command + { + [Tooltip("Display type of debug log info")] + [SerializeField] protected DebugLogType logType; + + [Tooltip("Text to write to the debug log. Supports variable substitution, e.g. {$Myvar}")] + [SerializeField] protected StringDataMulti logMessage; + + #region Public members + + public override void OnEnter () + { + var flowchart = GetFlowchart(); + string message = flowchart.SubstituteVariables(logMessage.Value); + + switch (logType) + { + case DebugLogType.Info: + Debug.Log(message); + break; + case DebugLogType.Warning: + Debug.LogWarning(message); + break; + case DebugLogType.Error: + Debug.LogError(message); + break; + } + + Continue(); + } + + public override string GetSummary() + { + return logMessage.GetDescription(); + } + + public override Color GetButtonColor() + { + return new Color32(235, 191, 217, 255); + } + + public override bool HasReference(Variable variable) + { + return logMessage.stringRef == variable || base.HasReference(variable); + } + + #endregion + + #region Editor caches +#if UNITY_EDITOR + protected override void RefreshVariableCache() + { + base.RefreshVariableCache(); + + var f = GetFlowchart(); + + f.DetermineSubstituteVariables(logMessage.Value, referencedVariables); + } +#endif + #endregion Editor caches + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/DebugLog.cs.meta b/Assets/Fungus/Scripts/Commands/DebugLog.cs.meta new file mode 100644 index 0000000..0f1e38d --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/DebugLog.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 2fab8abf0343545abbfebd9a7b7b34bd +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Fungus/Scripts/Commands/DeleteSaveKey.cs b/Assets/Fungus/Scripts/Commands/DeleteSaveKey.cs new file mode 100644 index 0000000..a1d969d --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/DeleteSaveKey.cs @@ -0,0 +1,70 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; + +namespace Fungus +{ + /// + /// Deletes a saved value from permanent storage. + /// + [CommandInfo("Variable", + "Delete Save Key", + "Deletes a saved value from permanent storage.")] + [AddComponentMenu("")] + public class DeleteSaveKey : Command + { + [Tooltip("Name of the saved value. Supports variable substition e.g. \"player_{$PlayerNumber}")] + [SerializeField] protected string key = ""; + + #region Public members + + public override void OnEnter() + { + if (key == "") + { + Continue(); + return; + } + + var flowchart = GetFlowchart(); + + // Prepend the current save profile (if any) + string prefsKey = SetSaveProfile.SaveProfile + "_" + flowchart.SubstituteVariables(key); + + PlayerPrefs.DeleteKey(prefsKey); + + Continue(); + } + + public override string GetSummary() + { + if (key.Length == 0) + { + return "Error: No stored value key selected"; + } + + return key; + } + + public override Color GetButtonColor() + { + return new Color32(235, 191, 217, 255); + } + + #endregion + + #region Editor caches +#if UNITY_EDITOR + protected override void RefreshVariableCache() + { + base.RefreshVariableCache(); + + var f = GetFlowchart(); + + f.DetermineSubstituteVariables(key, referencedVariables); + } +#endif + #endregion Editor caches + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/DeleteSaveKey.cs.meta b/Assets/Fungus/Scripts/Commands/DeleteSaveKey.cs.meta new file mode 100644 index 0000000..5cc3ac7 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/DeleteSaveKey.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: e1205d6641f2146b19d496037f937ba0 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Fungus/Scripts/Commands/Destroy.cs b/Assets/Fungus/Scripts/Commands/Destroy.cs new file mode 100644 index 0000000..27ed738 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Destroy.cs @@ -0,0 +1,81 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; +using UnityEngine.Serialization; + +namespace Fungus +{ + /// + /// Destroys a specified game object in the scene. + /// + [CommandInfo("Scripting", + "Destroy", + "Destroys a specified game object in the scene.")] + [AddComponentMenu("")] + [ExecuteInEditMode] + public class Destroy : Command + { + [Tooltip("Reference to game object to destroy")] + [SerializeField] protected GameObjectData _targetGameObject; + + [Tooltip("Optional delay given to destroy")] + [SerializeField] + protected FloatData destroyInXSeconds = new FloatData(0); + + #region Public members + + public override void OnEnter() + { + if (_targetGameObject.Value != null) + { + if (destroyInXSeconds.Value != 0) + Destroy(_targetGameObject, destroyInXSeconds.Value); + else + Destroy(_targetGameObject.Value); + } + + Continue(); + } + + public override string GetSummary() + { + if (_targetGameObject.Value == null) + { + return "Error: No game object selected"; + } + + return _targetGameObject.Value.name + (destroyInXSeconds.Value == 0 ? "" : " in " + destroyInXSeconds.Value.ToString()); + } + + public override Color GetButtonColor() + { + return new Color32(235, 191, 217, 255); + } + + public override bool HasReference(Variable variable) + { + if (_targetGameObject.gameObjectRef == variable || destroyInXSeconds.floatRef == variable) + return true; + + return false; + } + + #endregion + + #region Backwards compatibility + + [HideInInspector] [FormerlySerializedAs("targetGameObject")] public GameObject targetGameObjectOLD; + + protected virtual void OnEnable() + { + if (targetGameObjectOLD != null) + { + _targetGameObject.Value = targetGameObjectOLD; + targetGameObjectOLD = null; + } + } + + #endregion + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/Destroy.cs.meta b/Assets/Fungus/Scripts/Commands/Destroy.cs.meta new file mode 100644 index 0000000..df4110b --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Destroy.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: d81be3d7e84da460788dccea95a3313a +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Fungus/Scripts/Commands/DestroyOnLoad.cs b/Assets/Fungus/Scripts/Commands/DestroyOnLoad.cs new file mode 100644 index 0000000..91e411b --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/DestroyOnLoad.cs @@ -0,0 +1,41 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; + +namespace Fungus +{ + /// + /// Calls DontDestroyOnLoad on the target gameobject. + /// + [CommandInfo("Scripting", + "DestroyOnLoad", + "Calls DontDestroyOnLoad on the target gameobject")] + [AddComponentMenu("")] + public class DestroyOnLoad : Command + { + [SerializeField] protected GameObjectData target; + + public override void OnEnter() + { + DontDestroyOnLoad(target.Value); + + Continue(); + } + + public override string GetSummary() + { + return target.Value != null ? target.Value.name : "Error: no target set"; + } + + public override bool HasReference(Variable variable) + { + return variable == target.gameObjectRef; + } + + public override Color GetButtonColor() + { + return new Color32(235, 191, 217, 255); + } + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/DestroyOnLoad.cs.meta b/Assets/Fungus/Scripts/Commands/DestroyOnLoad.cs.meta new file mode 100644 index 0000000..957b041 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/DestroyOnLoad.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 779fdb236b4ca6343a6d631108388e42 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/Else.cs b/Assets/Fungus/Scripts/Commands/Else.cs new file mode 100644 index 0000000..dd31126 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Else.cs @@ -0,0 +1,52 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; + +namespace Fungus +{ + /// + /// Marks the start of a command block to be executed when the preceding If statement is False. + /// + [CommandInfo("Flow", + "Else", + "Marks the start of a command block to be executed when the preceding If statement is False.")] + [AddComponentMenu("")] + public class Else : Command + { + #region Public members + + public override void OnEnter() + { + // Find the next End command at the same indent level as this Else command + var matchingEnd = Condition.FindMatchingEndCommand(this); + if (matchingEnd != null) + { + // Execute command immediately after the EndIf command + Continue(matchingEnd.CommandIndex + 1); + } + else + { + // No End command found + StopParentBlock(); + } + } + + public override bool OpenBlock() + { + return true; + } + + public override bool CloseBlock() + { + return true; + } + + public override Color GetButtonColor() + { + return new Color32(253, 253, 150, 255); + } + + #endregion + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/Else.cs.meta b/Assets/Fungus/Scripts/Commands/Else.cs.meta new file mode 100644 index 0000000..ec7a31f --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Else.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 3fa968f01a7f9496bb50e13dfe16760d +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Fungus/Scripts/Commands/ElseIf.cs b/Assets/Fungus/Scripts/Commands/ElseIf.cs new file mode 100644 index 0000000..c5df382 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/ElseIf.cs @@ -0,0 +1,28 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; + +namespace Fungus +{ + /// + /// Marks the start of a command block to be executed when the preceding If statement is False and the test expression is true. + /// + [CommandInfo("Flow", + "Else If", + "Marks the start of a command block to be executed when the preceding If statement is False and the test expression is true.")] + [AddComponentMenu("")] + public class ElseIf : VariableCondition + { + protected override bool IsElseIf { get { return true; } } + + #region Public members + + public override bool CloseBlock() + { + return true; + } + + #endregion + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/ElseIf.cs.meta b/Assets/Fungus/Scripts/Commands/ElseIf.cs.meta new file mode 100644 index 0000000..343d868 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/ElseIf.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 18c5e8d46183346b59f64b820e71f97f +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Fungus/Scripts/Commands/End.cs b/Assets/Fungus/Scripts/Commands/End.cs new file mode 100644 index 0000000..1258bac --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/End.cs @@ -0,0 +1,52 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; + +namespace Fungus +{ + /// + /// Marks the end of a conditional block. + /// + [CommandInfo("Flow", + "End", + "Marks the end of a conditional block.")] + [AddComponentMenu("")] + public class End : Command + { + #region Public members + + /// + /// Set to true by looping constructs to allow for loops to occur + /// + public virtual bool Loop { get; set; } + + /// + /// Set to the index of the owning looping construct + /// + public virtual int LoopBackIndex { get; set; } + + public override void OnEnter() + { + if (Loop) + { + Continue(LoopBackIndex); + return; + } + + Continue(); + } + + public override bool CloseBlock() + { + return true; + } + + public override Color GetButtonColor() + { + return new Color32(253, 253, 150, 255); + } + + #endregion + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/End.cs.meta b/Assets/Fungus/Scripts/Commands/End.cs.meta new file mode 100644 index 0000000..b2c4160 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/End.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 93cb9773f2ca04e2bbf7a68ccfc23267 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Fungus/Scripts/Commands/ExecuteLua.cs b/Assets/Fungus/Scripts/Commands/ExecuteLua.cs new file mode 100644 index 0000000..8f1c058 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/ExecuteLua.cs @@ -0,0 +1,213 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; +using MoonSharp.Interpreter; + +namespace Fungus +{ + /// + /// Executes a Lua code chunk using a Lua Environment. + /// + [CommandInfo("Scripting", + "Execute Lua", + "Executes a Lua code chunk using a Lua Environment.")] + public class ExecuteLua : Command + { + [Tooltip("Lua Environment to use to execute this Lua script")] + [SerializeField] protected LuaEnvironment luaEnvironment; + + [Tooltip("A text file containing Lua script to execute.")] + [SerializeField] protected TextAsset luaFile; + + [TextArea(10,100)] + [Tooltip("Lua script to execute. This text is appended to the contents of Lua file (if one is specified).")] + [SerializeField] protected string luaScript; + + [Tooltip("Execute this Lua script as a Lua coroutine")] + [SerializeField] protected bool runAsCoroutine = true; + + [Tooltip("Pause command execution until the Lua script has finished execution")] + [SerializeField] protected bool waitUntilFinished = true; + + [Tooltip("A Flowchart variable to store the returned value in.")] + [VariableProperty()] + [SerializeField] protected Variable returnVariable; + + protected string friendlyName = ""; + + protected bool initialised; + + // Stores the compiled Lua code for fast execution later. + protected Closure luaFunction; + + protected virtual void Start() + { + InitExecuteLua(); + } + + /// + /// Initialises the Lua environment and compiles the Lua string for execution later on. + /// + protected virtual void InitExecuteLua() + { + if (initialised) + { + return; + } + + // Cache a descriptive name to use in Lua error messages + friendlyName = gameObject.name + "." + ParentBlock.BlockName + "." + "ExecuteLua #" + CommandIndex.ToString(); + + var flowchart = GetFlowchart(); + + // See if a Lua Environment has been assigned to this Flowchart + if (luaEnvironment == null) + { + luaEnvironment = flowchart.LuaEnv; + } + + if (luaEnvironment == null) + { + // No Lua Environment specified so just use any available or create one. + luaEnvironment = LuaEnvironment.GetLua(); + } + + string s = GetLuaString(); + luaFunction = luaEnvironment.LoadLuaFunction(s, friendlyName); + + // Add a binding to the parent flowchart + if (flowchart.LuaBindingName != "") + { + Table globals = luaEnvironment.Interpreter.Globals; + if (globals != null) + { + globals[flowchart.LuaBindingName] = flowchart; + } + } + + // Always initialise when playing in the editor. + // Allows the user to edit the Lua script while the game is playing. + if ( !(Application.isPlaying && Application.isEditor) ) + { + initialised = true; + } + + } + + protected virtual string GetLuaString() + { + if (luaFile == null) + { + return luaScript; + } + + return luaFile.text + "\n" + luaScript; + } + + protected virtual void StoreReturnVariable(DynValue returnValue) + { + if (returnVariable == null || returnValue == null) + { + return; + } + + // Store the return value in a Fungus Variable + System.Type variableType = returnVariable.GetType(); + if (variableType == typeof(BooleanVariable) && returnValue.Type == DataType.Boolean) + { + (returnVariable as BooleanVariable).Value = returnValue.Boolean; + } + else if (variableType == typeof(IntegerVariable) && returnValue.Type == DataType.Number) + { + (returnVariable as IntegerVariable).Value = (int)returnValue.Number; + } + else if (variableType == typeof(FloatVariable) && returnValue.Type == DataType.Number) + { + (returnVariable as FloatVariable).Value = (float)returnValue.Number; + } + else if (variableType == typeof(StringVariable) && returnValue.Type == DataType.String) + { + (returnVariable as StringVariable).Value = returnValue.String; + } + else if (variableType == typeof(ColorVariable) && returnValue.Type == DataType.UserData) + { + (returnVariable as ColorVariable).Value = returnValue.CheckUserDataType("ExecuteLua.StoreReturnVariable"); + } + else if (variableType == typeof(GameObjectVariable) && returnValue.Type == DataType.UserData) + { + (returnVariable as GameObjectVariable).Value = returnValue.CheckUserDataType("ExecuteLua.StoreReturnVariable"); + } + else if (variableType == typeof(MaterialVariable) && returnValue.Type == DataType.UserData) + { + (returnVariable as MaterialVariable).Value = returnValue.CheckUserDataType("ExecuteLua.StoreReturnVariable"); + } + else if (variableType == typeof(ObjectVariable) && returnValue.Type == DataType.UserData) + { + (returnVariable as ObjectVariable).Value = returnValue.CheckUserDataType("ExecuteLua.StoreReturnVariable"); + } + else if (variableType == typeof(SpriteVariable) && returnValue.Type == DataType.UserData) + { + (returnVariable as SpriteVariable).Value = returnValue.CheckUserDataType("ExecuteLua.StoreReturnVariable"); + } + else if (variableType == typeof(TextureVariable) && returnValue.Type == DataType.UserData) + { + (returnVariable as TextureVariable).Value = returnValue.CheckUserDataType("ExecuteLua.StoreReturnVariable"); + } + else if (variableType == typeof(Vector2Variable) && returnValue.Type == DataType.UserData) + { + (returnVariable as Vector2Variable).Value = returnValue.CheckUserDataType("ExecuteLua.StoreReturnVariable"); + } + else if (variableType == typeof(Vector3Variable) && returnValue.Type == DataType.UserData) + { + (returnVariable as Vector3Variable).Value = returnValue.CheckUserDataType("ExecuteLua.StoreReturnVariable"); + } + else + { + Debug.LogError("Failed to convert " + returnValue.Type.ToLuaTypeString() + " return type to " + variableType.ToString()); + } + } + + #region Public members + + public override void OnEnter() + { + InitExecuteLua(); + + if (luaFunction == null) + { + Continue(); + } + + luaEnvironment.RunLuaFunction(luaFunction, runAsCoroutine, (returnValue) => { + StoreReturnVariable(returnValue); + if (waitUntilFinished) + { + Continue(); + } + }); + + if (!waitUntilFinished) + { + Continue(); + } + } + + public override string GetSummary() + { + return luaScript; + } + + public override Color GetButtonColor() + { + return new Color32(235, 191, 217, 255); + } + + public override bool HasReference(Variable variable) + { + return returnVariable == variable || base.HasReference(variable); + } + + #endregion + } +} diff --git a/Assets/Fungus/Scripts/Commands/ExecuteLua.cs.meta b/Assets/Fungus/Scripts/Commands/ExecuteLua.cs.meta new file mode 100644 index 0000000..e85e115 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/ExecuteLua.cs.meta @@ -0,0 +1,12 @@ +fileFormatVersion: 2 +guid: 71f455683d4ba4405b8dbba457159620 +timeCreated: 1456398214 +licenseType: Store +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/FadeScreen.cs b/Assets/Fungus/Scripts/Commands/FadeScreen.cs new file mode 100644 index 0000000..a84fb48 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/FadeScreen.cs @@ -0,0 +1,76 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; + +namespace Fungus +{ + /// + /// Draws a fullscreen texture over the scene to give a fade effect. Setting Target Alpha to 1 will obscure the screen, alpha 0 will reveal the screen. + /// If no Fade Texture is provided then a default flat color texture is used. + /// + [CommandInfo("Camera", + "Fade Screen", + "Draws a fullscreen texture over the scene to give a fade effect. Setting Target Alpha to 1 will obscure the screen, alpha 0 will reveal the screen. " + + "If no Fade Texture is provided then a default flat color texture is used.")] + [AddComponentMenu("")] + public class FadeScreen : Command + { + [Tooltip("Time for fade effect to complete")] + [SerializeField] protected float duration = 1f; + + [Tooltip("Current target alpha transparency value. The fade gradually adjusts the alpha to approach this target value.")] + [SerializeField] protected float targetAlpha = 1f; + + [Tooltip("Wait until the fade has finished before executing next command")] + [SerializeField] protected bool waitUntilFinished = true; + + [Tooltip("Color to render fullscreen fade texture with when screen is obscured.")] + [SerializeField] protected Color fadeColor = Color.black; + + [Tooltip("Optional texture to use when rendering the fullscreen fade effect.")] + [SerializeField] protected Texture2D fadeTexture; + + [SerializeField] protected LeanTweenType fadeTweenType = LeanTweenType.easeInOutQuad; + + #region Public members + + public override void OnEnter() + { + var cameraManager = FungusManager.Instance.CameraManager; + + if (fadeTexture) + { + cameraManager.ScreenFadeTexture = fadeTexture; + } + else + { + cameraManager.ScreenFadeTexture = CameraManager.CreateColorTexture(fadeColor, 32, 32); + } + + cameraManager.Fade(targetAlpha, duration, delegate { + if (waitUntilFinished) + { + Continue(); + } + }, fadeTweenType); + + if (!waitUntilFinished) + { + Continue(); + } + } + + public override string GetSummary() + { + return "Fade to " + targetAlpha + " over " + duration + " seconds"; + } + + public override Color GetButtonColor() + { + return new Color32(216, 228, 170, 255); + } + + #endregion + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/FadeScreen.cs.meta b/Assets/Fungus/Scripts/Commands/FadeScreen.cs.meta new file mode 100644 index 0000000..176a491 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/FadeScreen.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 207aecf668a0345388087ccf522f9957 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Fungus/Scripts/Commands/FadeSprite.cs b/Assets/Fungus/Scripts/Commands/FadeSprite.cs new file mode 100644 index 0000000..8c8dadd --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/FadeSprite.cs @@ -0,0 +1,98 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; +using UnityEngine.Serialization; + +namespace Fungus +{ + /// + /// Fades a sprite to a target color over a period of time. + /// + [CommandInfo("Sprite", + "Fade Sprite", + "Fades a sprite to a target color over a period of time.")] + [AddComponentMenu("")] + [ExecuteInEditMode] + public class FadeSprite : Command + { + [Tooltip("Sprite object to be faded")] + [SerializeField] protected SpriteRenderer spriteRenderer; + + [Tooltip("Length of time to perform the fade")] + [SerializeField] protected FloatData _duration = new FloatData(1f); + + [Tooltip("Target color to fade to. To only fade transparency level, set the color to white and set the alpha to required transparency.")] + [SerializeField] protected ColorData _targetColor = new ColorData(Color.white); + + [Tooltip("Wait until the fade has finished before executing the next command")] + [SerializeField] protected bool waitUntilFinished = true; + + #region Public members + + public override void OnEnter() + { + if (spriteRenderer == null) + { + Continue(); + return; + } + + SpriteFader.FadeSprite(spriteRenderer, _targetColor.Value, _duration.Value, Vector2.zero, delegate { + if (waitUntilFinished) + { + Continue(); + } + }); + + if (!waitUntilFinished) + { + Continue(); + } + } + + public override string GetSummary() + { + if (spriteRenderer == null) + { + return "Error: No sprite renderer selected"; + } + + return spriteRenderer.name + " to " + _targetColor.Value.ToString(); + } + + public override Color GetButtonColor() + { + return new Color32(221, 184, 169, 255); + } + + public override bool HasReference(Variable variable) + { + return _duration.floatRef == variable || _targetColor.colorRef == variable || + base.HasReference(variable); + } + + #endregion + + #region Backwards compatibility + + [HideInInspector] [FormerlySerializedAs("duration")] public float durationOLD; + [HideInInspector] [FormerlySerializedAs("targetColor")] public Color targetColorOLD; + + protected virtual void OnEnable() + { + if (durationOLD != default(float)) + { + _duration.Value = durationOLD; + durationOLD = default(float); + } + if (targetColorOLD != default(Color)) + { + _targetColor.Value = targetColorOLD; + targetColorOLD = default(Color); + } + } + + #endregion + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/FadeSprite.cs.meta b/Assets/Fungus/Scripts/Commands/FadeSprite.cs.meta new file mode 100644 index 0000000..a02bdc1 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/FadeSprite.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: accc065c3e9a6457496f075b1bd49adc +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Fungus/Scripts/Commands/FadeToView.cs b/Assets/Fungus/Scripts/Commands/FadeToView.cs new file mode 100644 index 0000000..5af59d3 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/FadeToView.cs @@ -0,0 +1,129 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; + +namespace Fungus +{ + /// + /// Fades the camera out and in again at a position specified by a View object. + /// + [CommandInfo("Camera", + "Fade To View", + "Fades the camera out and in again at a position specified by a View object.")] + [AddComponentMenu("")] + public class FadeToView : Command + { + [Tooltip("Time for fade effect to complete")] + [SerializeField] protected float duration = 1f; + + [Tooltip("Fade from fully visible to opaque at start of fade")] + [SerializeField] protected bool fadeOut = true; + + [Tooltip("View to transition to when Fade is complete")] + [SerializeField] protected View targetView; + + [Tooltip("Wait until the fade has finished before executing next command")] + [SerializeField] protected bool waitUntilFinished = true; + + [Tooltip("Color to render fullscreen fade texture with when screen is obscured.")] + [SerializeField] protected Color fadeColor = Color.black; + + [Tooltip("Optional texture to use when rendering the fullscreen fade effect.")] + [SerializeField] protected Texture2D fadeTexture; + + [Tooltip("Camera to use for the fade. Will use main camera if set to none.")] + [SerializeField] protected Camera targetCamera; + + [SerializeField] protected LeanTweenType fadeTweenType = LeanTweenType.easeInOutQuad; + [SerializeField] protected LeanTweenType orthoSizeTweenType = LeanTweenType.easeInOutQuad; + [SerializeField] protected LeanTweenType posTweenType = LeanTweenType.easeInOutQuad; + [SerializeField] protected LeanTweenType rotTweenType = LeanTweenType.easeInOutQuad; + + protected virtual void Start() + { + AcquireCamera(); + } + + protected virtual void AcquireCamera() + { + if (targetCamera != null) + { + return; + } + + targetCamera = Camera.main; + if (targetCamera == null) + { + targetCamera = GameObject.FindObjectOfType(); + } + } + + #region Public members + + /// + /// View to transition to when Fade is complete + /// + public virtual View TargetView { get { return targetView; } } + + public override void OnEnter() + { + AcquireCamera(); + if (targetCamera == null || + targetView == null) + { + Continue(); + return; + } + + var cameraManager = FungusManager.Instance.CameraManager; + + if (fadeTexture) + { + cameraManager.ScreenFadeTexture = fadeTexture; + } + else + { + cameraManager.ScreenFadeTexture = CameraManager.CreateColorTexture(fadeColor, 32, 32); + } + + cameraManager.FadeToView(targetCamera, targetView, duration, fadeOut, delegate { + if (waitUntilFinished) + { + Continue(); + } + }, fadeTweenType, orthoSizeTweenType, posTweenType, rotTweenType); + + if (!waitUntilFinished) + { + Continue(); + } + } + + public override void OnStopExecuting() + { + var cameraManager = FungusManager.Instance.CameraManager; + + cameraManager.Stop(); + } + + public override string GetSummary() + { + if (targetView == null) + { + return "Error: No view selected"; + } + else + { + return targetView.name; + } + } + + public override Color GetButtonColor() + { + return new Color32(216, 228, 170, 255); + } + + #endregion + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/FadeToView.cs.meta b/Assets/Fungus/Scripts/Commands/FadeToView.cs.meta new file mode 100644 index 0000000..c4c1844 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/FadeToView.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 437f9a4e3dbc647f9bdce95308418bff +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Fungus/Scripts/Commands/FadeUI.cs b/Assets/Fungus/Scripts/Commands/FadeUI.cs new file mode 100644 index 0000000..2124a2a --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/FadeUI.cs @@ -0,0 +1,251 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; +using UnityEngine.UI; + +namespace Fungus +{ + /// + /// Select which type of fade will be applied. + /// + public enum FadeMode + { + /// Fade the alpha color component only. + Alpha, + /// Fade all color components (RGBA). + Color + } + + /// + /// Fades a UI object. + /// + [CommandInfo("UI", + "Fade UI", + "Fades a UI object")] + public class FadeUI : TweenUI + { + [SerializeField] protected FadeMode fadeMode = FadeMode.Alpha; + + [SerializeField] protected ColorData targetColor = new ColorData(Color.white); + + [SerializeField] protected FloatData targetAlpha = new FloatData(1f); + + protected override void ApplyTween(GameObject go) + { + var images = go.GetComponentsInChildren(); + for (int i = 0; i < images.Length; i++) + { + var image = images[i]; + if (Mathf.Approximately(duration, 0f)) + { + switch (fadeMode) + { + case FadeMode.Alpha: + Color tempColor = image.color; + tempColor.a = targetAlpha; + image.color = tempColor; + break; + case FadeMode.Color: + image.color = targetColor; + break; + } + } + else + { + switch (fadeMode) + { + case FadeMode.Alpha: + LeanTween.alpha(image.rectTransform, targetAlpha, duration).setEase(tweenType).setEase(tweenType); + break; + case FadeMode.Color: + LeanTween.color(image.rectTransform, targetColor, duration).setEase(tweenType).setEase(tweenType); + break; + } + } + } + + var texts = go.GetComponentsInChildren(); + for (int i = 0; i < texts.Length; i++) + { + var text = texts[i]; + if (Mathf.Approximately(duration, 0f)) + { + switch (fadeMode) + { + case FadeMode.Alpha: + Color tempColor = text.color; + tempColor.a = targetAlpha; + text.color = tempColor; + break; + case FadeMode.Color: + text.color = targetColor; + break; + } + } + else + { + switch (fadeMode) + { + case FadeMode.Alpha: + LeanTween.textAlpha(text.rectTransform, targetAlpha, duration).setEase(tweenType); + break; + case FadeMode.Color: + LeanTween.textColor(text.rectTransform, targetColor, duration).setEase(tweenType); + break; + } + } + } + + var textMeshes = go.GetComponentsInChildren(); + for (int i = 0; i < textMeshes.Length; i++) + { + var textMesh = textMeshes[i]; + if (Mathf.Approximately(duration, 0f)) + { + switch (fadeMode) + { + case FadeMode.Alpha: + Color tempColor = textMesh.color; + tempColor.a = targetAlpha; + textMesh.color = tempColor; + break; + case FadeMode.Color: + textMesh.color = targetColor; + break; + } + } + else + { + switch (fadeMode) + { + case FadeMode.Alpha: + LeanTween.alpha(go, targetAlpha, duration).setEase(tweenType); + break; + case FadeMode.Color: + LeanTween.color(go, targetColor, duration).setEase(tweenType); + break; + } + } + } + +#if UNITY_2018_1_OR_NEWER + var tmpros = go.GetComponentsInChildren(); + for (int i = 0; i < tmpros.Length; i++) + { + + var tmpro = tmpros[i]; + if (Mathf.Approximately(duration, 0f)) + { + switch (fadeMode) + { + case FadeMode.Alpha: + Color tempColor = tmpro.color; + tempColor.a = targetAlpha; + tmpro.color = tempColor; + break; + case FadeMode.Color: + tmpro.color = targetColor; + break; + } + } + else + { + switch (fadeMode) + { + case FadeMode.Alpha: + LeanTween.value(tmpro.gameObject, tmpro.color.a, targetAlpha.Value, duration) + .setEase(tweenType) + .setOnUpdate((float alphaValue) => + { + Color tempColor = tmpro.color; + tempColor.a = alphaValue; + tmpro.color = tempColor; + }); + break; + case FadeMode.Color: + LeanTween.value(tmpro.gameObject, tmpro.color, targetColor.Value, duration) + .setEase(tweenType) + .setOnUpdate((Color colorValue) => + { + tmpro.color = colorValue; + }); + break; + } + } + } +#endif + //canvas groups don't support color but we can anim the alpha IN the color + var canvasGroups = go.GetComponentsInChildren(); + for (int i = 0; i < canvasGroups.Length; i++) + { + var canvasGroup = canvasGroups[i]; + if (Mathf.Approximately(duration, 0f)) + { + switch (fadeMode) + { + case FadeMode.Alpha: + canvasGroup.alpha = targetAlpha.Value; + break; + case FadeMode.Color: + canvasGroup.alpha = targetColor.Value.a; + break; + } + } + else + { + switch (fadeMode) + { + case FadeMode.Alpha: + LeanTween.alphaCanvas(canvasGroup, targetAlpha, duration).setEase(tweenType); + break; + case FadeMode.Color: + LeanTween.alphaCanvas(canvasGroup, targetColor.Value.a, duration).setEase(tweenType); + break; + } + } + } + } + + protected override string GetSummaryValue() + { + if (fadeMode == FadeMode.Alpha) + { + return targetAlpha.Value.ToString() + " alpha"; + } + else if (fadeMode == FadeMode.Color) + { + return targetColor.Value.ToString() + " color"; + } + + return ""; + } + + #region Public members + + public override bool IsPropertyVisible(string propertyName) + { + if (fadeMode == FadeMode.Alpha && + propertyName == "targetColor") + { + return false; + } + + if (fadeMode == FadeMode.Color && + propertyName == "targetAlpha") + { + return false; + } + + return true; + } + + public override bool HasReference(Variable variable) + { + return targetColor.colorRef == variable || targetAlpha.floatRef == variable || + base.HasReference(variable); + } + + #endregion + } +} diff --git a/Assets/Fungus/Scripts/Commands/FadeUI.cs.meta b/Assets/Fungus/Scripts/Commands/FadeUI.cs.meta new file mode 100644 index 0000000..5650151 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/FadeUI.cs.meta @@ -0,0 +1,12 @@ +fileFormatVersion: 2 +guid: 5c6dd8d3a780f4d1ea772e3daf10c372 +timeCreated: 1444819884 +licenseType: Store +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/FromString.cs b/Assets/Fungus/Scripts/Commands/FromString.cs new file mode 100644 index 0000000..6ce8316 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/FromString.cs @@ -0,0 +1,82 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; + +namespace Fungus +{ + /// + /// Attempts to parse a string into a given fungus variable type, such as integer or float + /// + [CommandInfo("Variable", + "From String", + "Attempts to parse a string into a given fungus variable type, such as integer or float")] + [AddComponentMenu("")] + public class FromString : Command + { + [Tooltip("Source of string data to parse into another variables value")] + [VariableProperty(typeof(StringVariable))] + [SerializeField] protected StringVariable sourceString; + + [Tooltip("The variable type to be parsed and value stored within")] + [VariableProperty(typeof(IntegerVariable), typeof(FloatVariable))] + [SerializeField] protected Variable outValue; + + public override void OnEnter() + { + if (sourceString != null && outValue != null) + { + double asDouble = 0; + try + { + asDouble = System.Convert.ToDouble(sourceString.Value, System.Globalization.CultureInfo.CurrentCulture); + } + catch (System.Exception) + { + Debug.LogWarning("Failed to parse as number: " + sourceString.Value); + } + + IntegerVariable intOutVar = outValue as IntegerVariable; + if (intOutVar != null) + { + intOutVar.Value = (int)asDouble; + } + else + { + FloatVariable floatOutVar = outValue as FloatVariable; + if (floatOutVar != null) + { + floatOutVar.Value = (float)asDouble; + } + } + } + + Continue(); + } + + public override string GetSummary() + { + if (sourceString == null) + { + return "Error: No source string selected"; + } + + if (outValue == null) + { + return "Error: No type and storage variable selected"; + } + + return outValue.Key + ".Parse " + sourceString.Key; + } + + public override bool HasReference(Variable variable) + { + return (variable == sourceString) || (variable == outValue); + } + + public override Color GetButtonColor() + { + return new Color32(253, 253, 150, 255); + } + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/FromString.cs.meta b/Assets/Fungus/Scripts/Commands/FromString.cs.meta new file mode 100644 index 0000000..a565d24 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/FromString.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 51296c2a224eea64daa8c7b9c5c644fa +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/Fullscreen.cs b/Assets/Fungus/Scripts/Commands/Fullscreen.cs new file mode 100644 index 0000000..487faab --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Fullscreen.cs @@ -0,0 +1,64 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; + +namespace Fungus +{ + /// + /// Fullscreen mode options. + /// + public enum FullscreenMode + { + /// Toggle the current mode between fullscreen and windowed. + Toggle, + /// Switch to fullscreen mode. + Fullscreen, + /// Switch to windowed mode. + Windowed + } + + /// + /// Sets the application to fullscreen, windowed or toggles the current state. + /// + [CommandInfo("Camera", + "Fullscreen", + "Sets the application to fullscreen, windowed or toggles the current state.")] + [AddComponentMenu("")] + public class Fullscreen : Command + { + [SerializeField] protected FullscreenMode fullscreenMode; + + #region Public members + + public override void OnEnter() + { + switch (fullscreenMode) + { + case FullscreenMode.Toggle: + Screen.fullScreen = !Screen.fullScreen; + break; + case FullscreenMode.Fullscreen: + Screen.fullScreen = true; + break; + case FullscreenMode.Windowed: + Screen.fullScreen = false; + break; + } + + Continue(); + } + + public override string GetSummary() + { + return fullscreenMode.ToString(); + } + + public override Color GetButtonColor() + { + return new Color32(216, 228, 170, 255); + } + + #endregion + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/Fullscreen.cs.meta b/Assets/Fungus/Scripts/Commands/Fullscreen.cs.meta new file mode 100644 index 0000000..f146f29 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Fullscreen.cs.meta @@ -0,0 +1,12 @@ +fileFormatVersion: 2 +guid: 083836d4b33584c1aaf7d1eb57b02ba0 +timeCreated: 1434460163 +licenseType: Store +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/GetText.cs b/Assets/Fungus/Scripts/Commands/GetText.cs new file mode 100644 index 0000000..affcc89 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/GetText.cs @@ -0,0 +1,91 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; +using UnityEngine.UI; +using UnityEngine.Serialization; + +namespace Fungus +{ + /// + /// Gets the text property from a UI Text object and stores it in a string variable. + /// + [CommandInfo("UI", + "Get Text", + "Gets the text property from a UI Text object and stores it in a string variable.")] + [AddComponentMenu("")] + public class GetText : Command + { + [Tooltip("Text object to get text value from")] + [SerializeField] protected GameObject targetTextObject; + + [Tooltip("String variable to store the text value in")] + [VariableProperty(typeof(StringVariable))] + [SerializeField] protected StringVariable stringVariable; + + #region Public members + + public override void OnEnter() + { + if (stringVariable == null) + { + Continue(); + return; + } + + TextAdapter textAdapter = new TextAdapter(); + textAdapter.InitFromGameObject(targetTextObject); + + if (textAdapter.HasTextObject()) + { + stringVariable.Value = textAdapter.Text; + } + + Continue(); + } + + public override string GetSummary() + { + if (targetTextObject == null) + { + return "Error: No text object selected"; + } + + if (stringVariable == null) + { + return "Error: No variable selected"; + } + + return targetTextObject.name + " : " + stringVariable.name; + } + + public override Color GetButtonColor() + { + return new Color32(235, 191, 217, 255); + } + + public override bool HasReference(Variable variable) + { + return stringVariable == variable || + base.HasReference(variable); + } + + #endregion + + #region Backwards compatibility + + // Backwards compatibility with Fungus v2.1.2 + [HideInInspector] + [FormerlySerializedAs("textObject")] + public Text _textObjectObsolete; + protected virtual void OnEnable() + { + if (_textObjectObsolete != null) + { + targetTextObject = _textObjectObsolete.gameObject; + } + } + + #endregion + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/GetText.cs.meta b/Assets/Fungus/Scripts/Commands/GetText.cs.meta new file mode 100644 index 0000000..8d0a539 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/GetText.cs.meta @@ -0,0 +1,12 @@ +fileFormatVersion: 2 +guid: e889853a4ba0b446d97008a78fa4cf1e +timeCreated: 1438782803 +licenseType: Store +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/GetToggleState.cs b/Assets/Fungus/Scripts/Commands/GetToggleState.cs new file mode 100644 index 0000000..e876118 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/GetToggleState.cs @@ -0,0 +1,65 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; +using UnityEngine.UI; + +namespace Fungus +{ + /// + /// Gets the state of a toggle UI object and stores it in a boolean variable. + /// + [CommandInfo("UI", + "Get Toggle State", + "Gets the state of a toggle UI object and stores it in a boolean variable.")] + public class GetToggleState : Command + { + [Tooltip("Target toggle object to get the value from")] + [SerializeField] protected Toggle toggle; + + [Tooltip("Boolean variable to store the state of the toggle value in.")] + [VariableProperty(typeof(BooleanVariable))] + [SerializeField] protected BooleanVariable toggleState; + + #region Public members + + public override void OnEnter() + { + if (toggle != null && + toggleState != null) + { + toggleState.Value = toggle.isOn; + } + + Continue(); + } + + public override Color GetButtonColor() + { + return new Color32(235, 191, 217, 255); + } + + public override string GetSummary() + { + if (toggle == null) + { + return "Error: Toggle object not selected"; + } + + if (toggleState == null) + { + return "Error: Toggle state variable not selected"; + } + + return toggle.name; + } + + public override bool HasReference(Variable variable) + { + return toggleState == variable || + base.HasReference(variable); + } + + #endregion + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/GetToggleState.cs.meta b/Assets/Fungus/Scripts/Commands/GetToggleState.cs.meta new file mode 100644 index 0000000..334b018 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/GetToggleState.cs.meta @@ -0,0 +1,12 @@ +fileFormatVersion: 2 +guid: 9750f780c39234a028f87c0016c2d9c0 +timeCreated: 1476363990 +licenseType: Store +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/If.cs b/Assets/Fungus/Scripts/Commands/If.cs new file mode 100644 index 0000000..efeb850 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/If.cs @@ -0,0 +1,18 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; + +namespace Fungus +{ + /// + /// If the test expression is true, execute the following command block. + /// + [CommandInfo("Flow", + "If", + "If the test expression is true, execute the following command block.")] + [AddComponentMenu("")] + public class If : VariableCondition + { + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/If.cs.meta b/Assets/Fungus/Scripts/Commands/If.cs.meta new file mode 100644 index 0000000..c0814d7 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/If.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 70c5622b8a80845c980954170295f292 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Fungus/Scripts/Commands/Input.meta b/Assets/Fungus/Scripts/Commands/Input.meta new file mode 100644 index 0000000..22fcfea --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Input.meta @@ -0,0 +1,9 @@ +fileFormatVersion: 2 +guid: 90098f8abed37d1418f36896e7e1279d +folderAsset: yes +timeCreated: 1503744400 +licenseType: Store +DefaultImporter: + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/Input/GetAxis.cs b/Assets/Fungus/Scripts/Commands/Input/GetAxis.cs new file mode 100644 index 0000000..364271a --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Input/GetAxis.cs @@ -0,0 +1,63 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using System.Collections; +using System.Collections.Generic; +using UnityEngine; + +namespace Fungus +{ + // + /// Store Input.GetAxis in a variable + /// + [CommandInfo("Input", + "GetAxis", + "Store Input.GetAxis in a variable")] + [AddComponentMenu("")] + public class GetAxis : Command + { + [SerializeField] + protected StringData axisName; + + [Tooltip("If true, calls GetAxisRaw instead of GetAxis")] + [SerializeField] + protected bool axisRaw = false; + + [Tooltip("Float to store the value of the GetAxis")] + [SerializeField] + protected FloatData outValue; + + public override void OnEnter() + { + if (axisRaw) + { + outValue.Value = Input.GetAxisRaw(axisName.Value); + } + else + { + outValue.Value = Input.GetAxis(axisName.Value); + } + + Continue(); + } + + public override string GetSummary() + { + return axisName + (axisRaw ? " Raw" : ""); + } + + public override Color GetButtonColor() + { + return new Color32(235, 191, 217, 255); + } + + public override bool HasReference(Variable variable) + { + if (axisName.stringRef == variable || outValue.floatRef == variable) + return true; + + return false; + } + + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/Input/GetAxis.cs.meta b/Assets/Fungus/Scripts/Commands/Input/GetAxis.cs.meta new file mode 100644 index 0000000..0c7e6c7 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Input/GetAxis.cs.meta @@ -0,0 +1,12 @@ +fileFormatVersion: 2 +guid: bb18ee740f55ba24680c15466ff13ece +timeCreated: 1503744409 +licenseType: Store +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/Input/GetKey.cs b/Assets/Fungus/Scripts/Commands/Input/GetKey.cs new file mode 100644 index 0000000..4a7f31f --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Input/GetKey.cs @@ -0,0 +1,177 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; + +namespace Fungus +{ + // + /// Store Input.GetKey in a variable. Supports an optional Negative key input. A negative value will be overridden by a positive one, they do not add. + /// + [CommandInfo("Input", + "GetKey", + "Store Input.GetKey in a variable. Supports an optional Negative key input. A negative value will be overridden by a positive one, they do not add.")] + [AddComponentMenu("")] + public class GetKey : Command + { + [SerializeField] + protected KeyCode keyCode = KeyCode.None; + + [Tooltip("Optional, secondary or negative keycode. For booleans will also set to true, for int and float will set to -1.")] + [SerializeField] + protected KeyCode keyCodeNegative = KeyCode.None; + + [SerializeField] + [Tooltip("Only used if KeyCode is KeyCode.None, expects a name of the key to use.")] + protected StringData keyCodeName = new StringData(string.Empty); + + [SerializeField] + [Tooltip("Optional, secondary or negative keycode. For booleans will also set to true, for int and float will set to -1." + + "Only used if KeyCode is KeyCode.None, expects a name of the key to use.")] + protected StringData keyCodeNameNegative = new StringData(string.Empty); + + public enum InputKeyQueryType + { + Down, + Up, + State + } + + [Tooltip("Do we want an Input.GetKeyDown, GetKeyUp or GetKey")] + [SerializeField] + protected InputKeyQueryType keyQueryType = InputKeyQueryType.State; + + [Tooltip("Will store true or false or 0 or 1 depending on type. Sets true or -1 for negative key values.")] + [SerializeField] + [VariableProperty(typeof(FloatVariable), typeof(BooleanVariable), typeof(IntegerVariable))] + protected Variable outValue; + + public override void OnEnter() + { + FillOutValue(0); + + if (keyCodeNegative != KeyCode.None) + { + DoKeyCode(keyCodeNegative, -1); + } + else if (!string.IsNullOrEmpty(keyCodeNameNegative)) + { + DoKeyName(keyCodeNameNegative, -1); + } + + + if (keyCode != KeyCode.None) + { + DoKeyCode(keyCode, 1); + } + else if (!string.IsNullOrEmpty(keyCodeName)) + { + DoKeyName(keyCodeName, 1); + } + + Continue(); + } + + private void DoKeyCode(KeyCode key, int trueVal) + { + switch (keyQueryType) + { + case InputKeyQueryType.Down: + if (Input.GetKeyDown(key)) + { + FillOutValue(trueVal); + } + break; + case InputKeyQueryType.Up: + if (Input.GetKeyUp(key)) + { + FillOutValue(trueVal); + } + break; + case InputKeyQueryType.State: + if (Input.GetKey(key)) + { + FillOutValue(trueVal); + } + break; + default: + break; + } + } + + private void DoKeyName(string key, int trueVal) + { + switch (keyQueryType) + { + case InputKeyQueryType.Down: + if (Input.GetKeyDown(key)) + { + FillOutValue(trueVal); + } + break; + case InputKeyQueryType.Up: + if (Input.GetKeyUp(key)) + { + FillOutValue(trueVal); + } + break; + case InputKeyQueryType.State: + if (Input.GetKey(key)) + { + FillOutValue(trueVal); + } + break; + default: + break; + } + } + + private void FillOutValue(int v) + { + FloatVariable fvar = outValue as FloatVariable; + if (fvar != null) + { + fvar.Value = v; + return; + } + + BooleanVariable bvar = outValue as BooleanVariable; + if (bvar != null) + { + bvar.Value = v == 0 ? false : true; + return; + } + + IntegerVariable ivar = outValue as IntegerVariable; + if (ivar != null) + { + ivar.Value = v; + return; + } + } + + public override string GetSummary() + { + if (outValue == null) + { + return "Error: no outvalue set"; + } + + return (keyCode != KeyCode.None ? keyCode.ToString() : keyCodeName) + " in " + outValue.Key; + } + + public override Color GetButtonColor() + { + return new Color32(235, 191, 217, 255); + } + + public override bool HasReference(Variable variable) + { + if (keyCodeName.stringRef == variable || outValue == variable || keyCodeNameNegative.stringRef == variable) + return true; + + return false; + } + + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/Input/GetKey.cs.meta b/Assets/Fungus/Scripts/Commands/Input/GetKey.cs.meta new file mode 100644 index 0000000..d821cc1 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Input/GetKey.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: abf9e2e4334293449850759c812dd9db +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/Input/GetMousePosition.cs b/Assets/Fungus/Scripts/Commands/Input/GetMousePosition.cs new file mode 100644 index 0000000..d2325f3 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Input/GetMousePosition.cs @@ -0,0 +1,89 @@ +using UnityEngine; + +namespace Fungus +{ + // + /// Store Input.mousePosition and mouse screen conversions in a variable(s) + /// + [CommandInfo("Input", + "Get Mouse Position", + "Store various interpretations of Input.mousePosition")] + [AddComponentMenu("")] + public class GetMousePosition : Command + { + [VariableProperty(typeof(Vector2Variable))] + [SerializeField] + protected Vector2Variable screenPosition; + + [Tooltip("If null, Camera.main is used")] + protected Camera castCamera; + + [VariableProperty(typeof(Vector2Variable))] + [SerializeField] + protected Vector2Variable viewPosition; + + [VariableProperty(typeof(Vector3Variable))] + [SerializeField] + protected Vector3Variable worldPosition; + + [VariableProperty(typeof(Vector3Variable))] + [SerializeField] + protected Vector3Variable worldDirection; + + public override void OnEnter() + { + if (castCamera == null) + { + castCamera = Camera.main; + } + + if (screenPosition != null) + { + screenPosition.Value = Input.mousePosition; + } + + if (viewPosition != null) + { + viewPosition.Value = castCamera.ScreenToViewportPoint(Input.mousePosition); + } + + if (worldPosition != null) + { + var screenWithZ = Input.mousePosition; + screenWithZ.z = castCamera.nearClipPlane; + worldPosition.Value = castCamera.ScreenToWorldPoint(screenWithZ); + } + + if (worldDirection != null) + { + var screenWithZ = Input.mousePosition; + screenWithZ.z = castCamera.nearClipPlane; + worldDirection.Value = castCamera.ScreenPointToRay(screenWithZ).direction; + } + + Continue(); + } + + public override string GetSummary() + { + return (screenPosition != null ? screenPosition.Key + " " : "") + + (castCamera != null ? castCamera.name + " " : "MainCam") + + (viewPosition != null ? viewPosition.Key + " " : "") + + (worldPosition != null ? worldPosition.Key + " " : "") + + (worldDirection != null ? worldDirection.Key + " " : ""); + } + + public override Color GetButtonColor() + { + return new Color32(235, 191, 217, 255); + } + + public override bool HasReference(Variable variable) + { + return (screenPosition == variable || + viewPosition == variable || + worldPosition == variable || + worldDirection == variable); + } + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/Input/GetMousePosition.cs.meta b/Assets/Fungus/Scripts/Commands/Input/GetMousePosition.cs.meta new file mode 100644 index 0000000..8ac8911 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Input/GetMousePosition.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: fb32240870e5bf545a0dafba446d3990 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/InvokeEvent.cs b/Assets/Fungus/Scripts/Commands/InvokeEvent.cs new file mode 100644 index 0000000..f84465c --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/InvokeEvent.cs @@ -0,0 +1,165 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; +using System; +using UnityEngine.Events; + +namespace Fungus +{ + /// + /// Supported types of method invocation. + /// + public enum InvokeType + { + /// Call a method with an optional constant value parameter. + Static, // + /// Call a method with an optional boolean constant / variable parameter. + DynamicBoolean, + /// Call a method with an optional integer constant / variable parameter. + DynamicInteger, + /// Call a method with an optional float constant / variable parameter. + DynamicFloat, + /// Call a method with an optional string constant / variable parameter. + DynamicString + } + + /// + /// Calls a list of component methods via the Unity Event System (as used in the Unity UI) + /// This command is more efficient than the Invoke Method command but can only pass a single parameter and doesn't support return values. + /// This command uses the UnityEvent system to call methods in script. http://docs.unity3d.com/Manual/UnityEvents.html + /// + [CommandInfo("Scripting", + "Invoke Event", + "Calls a list of component methods via the Unity Event System (as used in the Unity UI). " + + "This command is more efficient than the Invoke Method command but can only pass a single parameter and doesn't support return values.")] + [AddComponentMenu("")] + public class InvokeEvent : Command + { + [Tooltip("A description of what this command does. Appears in the command summary.")] + [SerializeField] protected string description = ""; + + [Tooltip("Delay (in seconds) before the methods will be called")] + [SerializeField] protected float delay; + + [Tooltip("Selects type of method parameter to pass")] + [SerializeField] protected InvokeType invokeType; + + [Tooltip("List of methods to call. Supports methods with no parameters or exactly one string, int, float or object parameter.")] + [SerializeField] protected UnityEvent staticEvent = new UnityEvent(); + + [Tooltip("Boolean parameter to pass to the invoked methods.")] + [SerializeField] protected BooleanData booleanParameter; + + [Tooltip("List of methods to call. Supports methods with one boolean parameter.")] + [SerializeField] protected BooleanEvent booleanEvent = new BooleanEvent(); + + [Tooltip("Integer parameter to pass to the invoked methods.")] + [SerializeField] protected IntegerData integerParameter; + + [Tooltip("List of methods to call. Supports methods with one integer parameter.")] + [SerializeField] protected IntegerEvent integerEvent = new IntegerEvent(); + + [Tooltip("Float parameter to pass to the invoked methods.")] + [SerializeField] protected FloatData floatParameter; + + [Tooltip("List of methods to call. Supports methods with one float parameter.")] + [SerializeField] protected FloatEvent floatEvent = new FloatEvent(); + + [Tooltip("String parameter to pass to the invoked methods.")] + [SerializeField] protected StringDataMulti stringParameter; + + [Tooltip("List of methods to call. Supports methods with one string parameter.")] + [SerializeField] protected StringEvent stringEvent = new StringEvent(); + + protected virtual void DoInvoke() + { + switch (invokeType) + { + default: + case InvokeType.Static: + staticEvent.Invoke(); + break; + case InvokeType.DynamicBoolean: + booleanEvent.Invoke(booleanParameter.Value); + break; + case InvokeType.DynamicInteger: + integerEvent.Invoke(integerParameter.Value); + break; + case InvokeType.DynamicFloat: + floatEvent.Invoke(floatParameter.Value); + break; + case InvokeType.DynamicString: + stringEvent.Invoke(stringParameter.Value); + break; + } + } + + #region Public members + + [Serializable] public class BooleanEvent : UnityEvent {} + [Serializable] public class IntegerEvent : UnityEvent {} + [Serializable] public class FloatEvent : UnityEvent {} + [Serializable] public class StringEvent : UnityEvent {} + + public override void OnEnter() + { + if (Mathf.Approximately(delay, 0f)) + { + DoInvoke(); + } + else + { + Invoke("DoInvoke", delay); + } + + Continue(); + } + + public override string GetSummary() + { + if (!string.IsNullOrEmpty(description)) + { + return description; + } + + string summary = invokeType.ToString() + " "; + + switch (invokeType) + { + default: + case InvokeType.Static: + summary += staticEvent.GetPersistentEventCount(); + break; + case InvokeType.DynamicBoolean: + summary += booleanEvent.GetPersistentEventCount(); + break; + case InvokeType.DynamicInteger: + summary += integerEvent.GetPersistentEventCount(); + break; + case InvokeType.DynamicFloat: + summary += floatEvent.GetPersistentEventCount(); + break; + case InvokeType.DynamicString: + summary += stringEvent.GetPersistentEventCount(); + break; + } + + return summary + " methods"; + } + + public override Color GetButtonColor() + { + return new Color32(235, 191, 217, 255); + } + + public override bool HasReference(Variable variable) + { + return booleanParameter.booleanRef == variable || integerParameter.integerRef == variable || + floatParameter.floatRef == variable || stringParameter.stringRef == variable || + base.HasReference(variable); + } + + #endregion + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/InvokeEvent.cs.meta b/Assets/Fungus/Scripts/Commands/InvokeEvent.cs.meta new file mode 100644 index 0000000..9c0d5ad --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/InvokeEvent.cs.meta @@ -0,0 +1,12 @@ +fileFormatVersion: 2 +guid: 95d9ff288f3904c05ada7ac9c9a075bb +timeCreated: 1436969477 +licenseType: Store +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/InvokeMethod.cs b/Assets/Fungus/Scripts/Commands/InvokeMethod.cs new file mode 100644 index 0000000..22328be --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/InvokeMethod.cs @@ -0,0 +1,416 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; +using System.Collections; +using System.Reflection; +using System.Collections.Generic; +using System; +using UnityEngine.Events; +using MarkerMetro.Unity.WinLegacy.Reflection; + +namespace Fungus +{ + /// + /// Invokes a method of a component via reflection. Supports passing multiple parameters and storing returned values in a Fungus variable. + /// + [CommandInfo("Scripting", + "Invoke Method", + "Invokes a method of a component via reflection. Supports passing multiple parameters and storing returned values in a Fungus variable.")] + public class InvokeMethod : Command + { + [Tooltip("A description of what this command does. Appears in the command summary.")] + [SerializeField] protected string description = ""; + + [Tooltip("GameObject containing the component method to be invoked")] + [SerializeField] protected GameObject targetObject; + + [HideInInspector] + [Tooltip("Name of assembly containing the target component")] + [SerializeField] protected string targetComponentAssemblyName; + + [HideInInspector] + [Tooltip("Full name of the target component")] + [SerializeField] protected string targetComponentFullname; + + [HideInInspector] + [Tooltip("Display name of the target component")] + [SerializeField] protected string targetComponentText; + + [HideInInspector] + [Tooltip("Name of target method to invoke on the target component")] + [SerializeField] protected string targetMethod; + + [HideInInspector] + [Tooltip("Display name of target method to invoke on the target component")] + [SerializeField] protected string targetMethodText; + + [HideInInspector] + [Tooltip("List of parameters to pass to the invoked method")] + [SerializeField] protected InvokeMethodParameter[] methodParameters; + + [HideInInspector] + [Tooltip("If true, store the return value in a flowchart variable of the same type.")] + [SerializeField] protected bool saveReturnValue; + + [HideInInspector] + [Tooltip("Name of Fungus variable to store the return value in")] + [SerializeField] protected string returnValueVariableKey; + + [HideInInspector] + [Tooltip("The type of the return value")] + [SerializeField] protected string returnValueType; + + [HideInInspector] + [Tooltip("If true, list all inherited methods for the component")] + [SerializeField] protected bool showInherited; + + [HideInInspector] + [Tooltip("The coroutine call behavior for methods that return IEnumerator")] + [SerializeField] protected CallMode callMode; + + protected Type componentType; + protected Component objComponent; + protected Type[] parameterTypes = null; + protected MethodInfo objMethod; + + protected virtual void Awake() + { + if (componentType == null) + { + componentType = ReflectionHelper.GetType(targetComponentAssemblyName); + } + + if (objComponent == null) + { + objComponent = targetObject.GetComponent(componentType); + } + + if (parameterTypes == null) + { + parameterTypes = GetParameterTypes(); + } + + if (objMethod == null) + { + objMethod = UnityEvent.GetValidMethodInfo(objComponent, targetMethod, parameterTypes); + } + } + + protected virtual IEnumerator ExecuteCoroutine() + { + yield return StartCoroutine((IEnumerator)objMethod.Invoke(objComponent, GetParameterValues())); + + if (callMode == CallMode.WaitUntilFinished) + { + Continue(); + } + } + + protected virtual System.Type[] GetParameterTypes() + { + System.Type[] types = new System.Type[methodParameters.Length]; + + for (int i = 0; i < methodParameters.Length; i++) + { + var item = methodParameters[i]; + var objType = ReflectionHelper.GetType(item.objValue.typeAssemblyname); + + types[i] = objType; + } + + return types; + } + + protected virtual object[] GetParameterValues() + { + object[] values = new object[methodParameters.Length]; + var flowChart = GetFlowchart(); + + for (int i = 0; i < methodParameters.Length; i++) + { + var item = methodParameters[i]; + + if (string.IsNullOrEmpty(item.variableKey)) + { + values[i] = item.objValue.GetValue(); + } + else + { + object objValue = null; + + switch (item.objValue.typeFullname) + { + case "System.Int32": + var intvalue = flowChart.GetVariable(item.variableKey); + if (intvalue != null) + objValue = intvalue.Value; + break; + case "System.Boolean": + var boolean = flowChart.GetVariable(item.variableKey); + if (boolean != null) + objValue = boolean.Value; + break; + case "System.Single": + var floatvalue = flowChart.GetVariable(item.variableKey); + if (floatvalue != null) + objValue = floatvalue.Value; + break; + case "System.String": + var stringvalue = flowChart.GetVariable(item.variableKey); + if (stringvalue != null) + objValue = stringvalue.Value; + break; + case "UnityEngine.Color": + var color = flowChart.GetVariable(item.variableKey); + if (color != null) + objValue = color.Value; + break; + case "UnityEngine.GameObject": + var gameObject = flowChart.GetVariable(item.variableKey); + if (gameObject != null) + objValue = gameObject.Value; + break; + case "UnityEngine.Material": + var material = flowChart.GetVariable(item.variableKey); + if (material != null) + objValue = material.Value; + break; + case "UnityEngine.Sprite": + var sprite = flowChart.GetVariable(item.variableKey); + if (sprite != null) + objValue = sprite.Value; + break; + case "UnityEngine.Texture": + var texture = flowChart.GetVariable(item.variableKey); + if (texture != null) + objValue = texture.Value; + break; + case "UnityEngine.Vector2": + var vector2 = flowChart.GetVariable(item.variableKey); + if (vector2 != null) + objValue = vector2.Value; + break; + case "UnityEngine.Vector3": + var vector3 = flowChart.GetVariable(item.variableKey); + if (vector3 != null) + objValue = vector3.Value; + break; + default: + var obj = flowChart.GetVariable(item.variableKey); + if (obj != null) + objValue = obj.Value; + break; + } + + values[i] = objValue; + } + } + + return values; + } + + protected virtual void SetVariable(string key, object value, string returnType) + { + var flowChart = GetFlowchart(); + + switch (returnType) + { + case "System.Int32": + flowChart.GetVariable(key).Value = (int)value; + break; + case "System.Boolean": + flowChart.GetVariable(key).Value = (bool)value; + break; + case "System.Single": + flowChart.GetVariable(key).Value = (float)value; + break; + case "System.String": + flowChart.GetVariable(key).Value = (string)value; + break; + case "UnityEngine.Color": + flowChart.GetVariable(key).Value = (UnityEngine.Color)value; + break; + case "UnityEngine.GameObject": + flowChart.GetVariable(key).Value = (UnityEngine.GameObject)value; + break; + case "UnityEngine.Material": + flowChart.GetVariable(key).Value = (UnityEngine.Material)value; + break; + case "UnityEngine.Sprite": + flowChart.GetVariable(key).Value = (UnityEngine.Sprite)value; + break; + case "UnityEngine.Texture": + flowChart.GetVariable(key).Value = (UnityEngine.Texture)value; + break; + case "UnityEngine.Vector2": + flowChart.GetVariable(key).Value = (UnityEngine.Vector2)value; + break; + case "UnityEngine.Vector3": + flowChart.GetVariable(key).Value = (UnityEngine.Vector3)value; + break; + default: + flowChart.GetVariable(key).Value = (UnityEngine.Object)value; + break; + } + } + + #region Public members + + /// + /// GameObject containing the component method to be invoked. + /// + public virtual GameObject TargetObject { get { return targetObject; } } + + public override void OnEnter() + { + try + { + if (targetObject == null || string.IsNullOrEmpty(targetComponentAssemblyName) || string.IsNullOrEmpty(targetMethod)) + { + Continue(); + return; + } + + if (returnValueType != "System.Collections.IEnumerator") + { + var objReturnValue = objMethod.Invoke(objComponent, GetParameterValues()); + + if (saveReturnValue) + { + SetVariable(returnValueVariableKey, objReturnValue, returnValueType); + } + + Continue(); + } + else + { + StartCoroutine(ExecuteCoroutine()); + + if (callMode == CallMode.Continue) + { + Continue(); + } + else if(callMode == CallMode.Stop) + { + StopParentBlock(); + } + } + } + catch (System.Exception ex) + { + Debug.LogError("Error: " + ex.Message); + } + } + + public override Color GetButtonColor() + { + return new Color32(235, 191, 217, 255); + } + + public override string GetSummary() + { + if (targetObject == null) + { + return "Error: targetObject is not assigned"; + } + + if (!string.IsNullOrEmpty(description)) + { + return description; + } + + return targetObject.name + "." + targetComponentText + "." + targetMethodText; + } + + #endregion + } + + [System.Serializable] + public class InvokeMethodParameter + { + [SerializeField] + public ObjectValue objValue; + + [SerializeField] + public string variableKey; + } + + [System.Serializable] + public class ObjectValue + { + public string typeAssemblyname; + public string typeFullname; + + public int intValue; + public bool boolValue; + public float floatValue; + public string stringValue; + + public Color colorValue; + public GameObject gameObjectValue; + public Material materialValue; + public UnityEngine.Object objectValue; + public Sprite spriteValue; + public Texture textureValue; + public Vector2 vector2Value; + public Vector3 vector3Value; + + public object GetValue() + { + switch (typeFullname) + { + case "System.Int32": + return intValue; + case "System.Boolean": + return boolValue; + case "System.Single": + return floatValue; + case "System.String": + return stringValue; + case "UnityEngine.Color": + return colorValue; + case "UnityEngine.GameObject": + return gameObjectValue; + case "UnityEngine.Material": + return materialValue; + case "UnityEngine.Sprite": + return spriteValue; + case "UnityEngine.Texture": + return textureValue; + case "UnityEngine.Vector2": + return vector2Value; + case "UnityEngine.Vector3": + return vector3Value; + default: + var objType = ReflectionHelper.GetType(typeAssemblyname); + + if (objType.IsSubclassOf(typeof(UnityEngine.Object))) + { + return objectValue; + } + else if (objType.IsEnum()) + return System.Enum.ToObject(objType, intValue); + + break; + } + + return null; + } + } + + public static class ReflectionHelper + { + static Dictionary types = new Dictionary(); + + public static System.Type GetType(string typeName) + { + if (types.ContainsKey(typeName)) + return types[typeName]; + + types[typeName] = System.Type.GetType(typeName); + + return types[typeName]; + } + } +} diff --git a/Assets/Fungus/Scripts/Commands/InvokeMethod.cs.meta b/Assets/Fungus/Scripts/Commands/InvokeMethod.cs.meta new file mode 100644 index 0000000..f3e12cc --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/InvokeMethod.cs.meta @@ -0,0 +1,12 @@ +fileFormatVersion: 2 +guid: 688e35811870d403f9e2b1ab2a699d98 +timeCreated: 1439307694 +licenseType: Store +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/Jump.cs b/Assets/Fungus/Scripts/Commands/Jump.cs new file mode 100644 index 0000000..64e448b --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Jump.cs @@ -0,0 +1,87 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; +using UnityEngine.Serialization; + +namespace Fungus +{ + /// + /// Move execution to a specific Label command in the same block. + /// + [CommandInfo("Flow", + "Jump", + "Move execution to a specific Label command in the same block")] + [AddComponentMenu("")] + [ExecuteInEditMode] + public class Jump : Command + { + [Tooltip("Name of a label in this block to jump to")] + [SerializeField] protected StringData _targetLabel = new StringData(""); + + #region Public members + + public override void OnEnter() + { + if (_targetLabel.Value == "") + { + Continue(); + return; + } + + var commandList = ParentBlock.CommandList; + for (int i = 0; i < commandList.Count; i++) + { + var command = commandList[i]; + Label label = command as Label; + if (label != null && label.Key == _targetLabel.Value) + { + Continue(label.CommandIndex + 1); + return; + } + } + + // Label not found + Debug.LogWarning("Label not found: " + _targetLabel.Value); + Continue(); + } + + public override string GetSummary() + { + if (_targetLabel.Value == "") + { + return "Error: No label selected"; + } + + return _targetLabel.Value; + } + + public override Color GetButtonColor() + { + return new Color32(253, 253, 150, 255); + } + + public override bool HasReference(Variable variable) + { + return _targetLabel.stringRef == variable || + base.HasReference(variable); + } + + #endregion + + #region Backwards compatibility + + [HideInInspector] [FormerlySerializedAs("targetLabel")] public Label targetLabelOLD; + + protected virtual void OnEnable() + { + if (targetLabelOLD != null) + { + _targetLabel.Value = targetLabelOLD.Key; + targetLabelOLD = null; + } + } + + #endregion + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/Jump.cs.meta b/Assets/Fungus/Scripts/Commands/Jump.cs.meta new file mode 100644 index 0000000..9e08f0c --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Jump.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: ae9ac2fcbd1d542619ab0bc7549fb264 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Fungus/Scripts/Commands/Label.cs b/Assets/Fungus/Scripts/Commands/Label.cs new file mode 100644 index 0000000..cb4fa83 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Label.cs @@ -0,0 +1,44 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; + +namespace Fungus +{ + /// + /// Marks a position in the command list for execution to jump to. + /// + [CommandInfo("Flow", + "Label", + "Marks a position in the command list for execution to jump to.")] + [AddComponentMenu("")] + public class Label : Command + { + [Tooltip("Display name for the label")] + [SerializeField] protected string key = ""; + + #region Public members + + /// + /// Display name for the label + /// + public virtual string Key { get { return key; } } + + public override void OnEnter() + { + Continue(); + } + + public override string GetSummary() + { + return key; + } + + public override Color GetButtonColor() + { + return new Color32(200, 200, 253, 255); + } + + #endregion + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/Label.cs.meta b/Assets/Fungus/Scripts/Commands/Label.cs.meta new file mode 100644 index 0000000..c40c691 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Label.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: ea4da378c47144a86979765ac5e9690c +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Fungus/Scripts/Commands/LeanTween.meta b/Assets/Fungus/Scripts/Commands/LeanTween.meta new file mode 100644 index 0000000..62c27f6 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/LeanTween.meta @@ -0,0 +1,9 @@ +fileFormatVersion: 2 +guid: 53bec3476dd0fa945af5703dda0cd24f +folderAsset: yes +timeCreated: 1501401094 +licenseType: Store +DefaultImporter: + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/LeanTween/BaseLeanTweenCommand.cs b/Assets/Fungus/Scripts/Commands/LeanTween/BaseLeanTweenCommand.cs new file mode 100644 index 0000000..ddac35e --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/LeanTween/BaseLeanTweenCommand.cs @@ -0,0 +1,124 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; +using UnityEngine.Serialization; + +namespace Fungus +{ + /// + /// Abstract base class for LeanTween commands. + /// + [ExecuteInEditMode] + public abstract class BaseLeanTweenCommand : Command + { + [Tooltip("Target game object to apply the Tween to")] + [SerializeField] + protected GameObjectData _targetObject; + + [Tooltip("The time in seconds the animation will take to complete")] + [SerializeField] + protected FloatData _duration = new FloatData(1f); + + public enum ToFrom { To, From } + [Tooltip("Does the tween act from current TO destination or is it reversed and act FROM destination to its current")] + [SerializeField] + protected ToFrom _toFrom; + public bool IsInFromMode { get { return _toFrom == ToFrom.From; } } + + public enum AbsAdd { Absolute, Additive } + [Tooltip("Does the tween use the value as a target or as a delta to be added to current.")] + [SerializeField] + protected AbsAdd _absAdd; + public bool IsInAddativeMode { get { return _absAdd == AbsAdd.Additive; } } + + + [Tooltip("The shape of the easing curve applied to the animation")] + [SerializeField] + protected LeanTweenType easeType = LeanTweenType.easeInOutQuad; + + [Tooltip("The type of loop to apply once the animation has completed")] + [SerializeField] + protected LeanTweenType loopType = LeanTweenType.once; + + [Tooltip("Number of times to repeat the tween, -1 is infinite.")] + [SerializeField] + protected int repeats = 0; + + [Tooltip("Stop any previously LeanTweens on this object before adding this one. Warning; expensive.")] + [SerializeField] + protected bool stopPreviousTweens = false; + + [Tooltip("Wait until the tween has finished before executing the next command")] + [SerializeField] + protected bool waitUntilFinished = true; + + + [HideInInspector] protected LTDescr ourTween; + + + protected virtual void OnTweenComplete() + { + Continue(); + } + + #region Public members + + public override void OnEnter() + { + if (_targetObject.Value == null) + { + Continue(); + return; + } + + if (stopPreviousTweens) + { + LeanTween.cancel(_targetObject.Value); + } + + ourTween = ExecuteTween(); + + ourTween.setEase(easeType) + .setRepeat(repeats) + .setLoopType(loopType); + + if (waitUntilFinished) + { + if(ourTween != null) + { + ourTween.setOnComplete(OnTweenComplete); + } + } + else + { + Continue(); + } + } + + public abstract LTDescr ExecuteTween(); + + public override string GetSummary() + { + if (_targetObject.Value == null) + { + return "Error: No target object selected"; + } + + return _targetObject.Value.name + " over " + _duration.Value + " seconds"; + } + + public override Color GetButtonColor() + { + return new Color32(233, 163, 180, 255); + } + + public override bool HasReference(Variable variable) + { + return variable == _targetObject.gameObjectRef || variable == _duration.floatRef; + } + + #endregion + + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/LeanTween/BaseLeanTweenCommand.cs.meta b/Assets/Fungus/Scripts/Commands/LeanTween/BaseLeanTweenCommand.cs.meta new file mode 100644 index 0000000..b321d7b --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/LeanTween/BaseLeanTweenCommand.cs.meta @@ -0,0 +1,12 @@ +fileFormatVersion: 2 +guid: 22379d19093ceb34098232d6f1b848a0 +timeCreated: 1499564933 +licenseType: Store +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/LeanTween/MoveLean.cs b/Assets/Fungus/Scripts/Commands/LeanTween/MoveLean.cs new file mode 100644 index 0000000..81d7753 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/LeanTween/MoveLean.cs @@ -0,0 +1,61 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; +using UnityEngine.Serialization; +using System.Collections; +using System; + +namespace Fungus +{ + /// + /// Moves a game object to a specified position over time. The position can be defined by a transform in another object (using To Transform) or by setting an absolute position (using To Position, if To Transform is set to None). + /// + [CommandInfo("LeanTween", + "Move", + "Moves a game object to a specified position over time. The position can be defined by a transform in another object (using To Transform) or by setting an absolute position (using To Position, if To Transform is set to None).")] + [AddComponentMenu("")] + [ExecuteInEditMode] + public class MoveLean : BaseLeanTweenCommand + { + [Tooltip("Target transform that the GameObject will move to")] + [SerializeField] + protected TransformData _toTransform; + + [Tooltip("Target world position that the GameObject will move to, if no From Transform is set")] + [SerializeField] + protected Vector3Data _toPosition; + + [Tooltip("Whether to animate in world space or relative to the parent. False by default.")] + [SerializeField] + protected bool isLocal; + + + public override LTDescr ExecuteTween() + { + var loc = _toTransform.Value == null ? _toPosition.Value : _toTransform.Value.position; + + if(IsInAddativeMode) + { + loc += _targetObject.Value.transform.position; + } + + if(IsInFromMode) + { + var cur = _targetObject.Value.transform.position; + _targetObject.Value.transform.position = loc; + loc = cur; + } + + if (isLocal) + return LeanTween.moveLocal(_targetObject.Value, loc, _duration); + else + return LeanTween.move(_targetObject.Value, loc, _duration); + } + + public override bool HasReference(Variable variable) + { + return _toTransform.transformRef == variable || _toPosition.vector3Ref == variable || base.HasReference(variable); + } + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/LeanTween/MoveLean.cs.meta b/Assets/Fungus/Scripts/Commands/LeanTween/MoveLean.cs.meta new file mode 100644 index 0000000..e37e20c --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/LeanTween/MoveLean.cs.meta @@ -0,0 +1,12 @@ +fileFormatVersion: 2 +guid: 3ca31fffe1be42a49b96bbb8b7ff5a50 +timeCreated: 1499566229 +licenseType: Store +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/LeanTween/RotateLean.cs b/Assets/Fungus/Scripts/Commands/LeanTween/RotateLean.cs new file mode 100644 index 0000000..5a631cd --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/LeanTween/RotateLean.cs @@ -0,0 +1,81 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; +using UnityEngine.Serialization; +using System.Collections; +using System; + +namespace Fungus +{ + /// + /// Rotates a game object to the specified angles over time. + /// + [CommandInfo("LeanTween", + "Rotate", + "Rotates a game object to the specified angles over time.")] + [AddComponentMenu("")] + [ExecuteInEditMode] + public class RotateLean : BaseLeanTweenCommand + { + [Tooltip("Target transform that the GameObject will rotate to")] + [SerializeField] + protected TransformData _toTransform; + + [Tooltip("Target rotation that the GameObject will rotate to, if no To Transform is set")] + [SerializeField] + protected Vector3Data _toRotation; + + [Tooltip("Whether to animate in world space or relative to the parent. False by default.")] + [SerializeField] + protected bool isLocal; + + public enum RotateMode { PureRotate, LookAt2D, LookAt3D} + [Tooltip("Whether to use the provided Transform or Vector as a target to look at rather than a euler to match.")] + [SerializeField] + protected RotateMode rotateMode = RotateMode.PureRotate; + + + public override LTDescr ExecuteTween() + { + var rot = _toTransform.Value == null ? _toRotation.Value : _toTransform.Value.rotation.eulerAngles; + + if(rotateMode == RotateMode.LookAt3D) + { + var pos = _toTransform.Value == null ? _toRotation.Value : _toTransform.Value.position; + var dif = pos - _targetObject.Value.transform.position; + rot = Quaternion.LookRotation(dif.normalized).eulerAngles; + } + else if(rotateMode == RotateMode.LookAt2D) + { + var pos = _toTransform.Value == null ? _toRotation.Value : _toTransform.Value.position; + var dif = pos - _targetObject.Value.transform.position; + dif.z = 0; + + rot = Quaternion.FromToRotation(_targetObject.Value.transform.up, dif.normalized).eulerAngles; + } + + if (IsInAddativeMode) + { + rot += _targetObject.Value.transform.rotation.eulerAngles; + } + + if (IsInFromMode) + { + var cur = _targetObject.Value.transform.rotation.eulerAngles; + _targetObject.Value.transform.rotation = Quaternion.Euler(rot); + rot = cur; + } + + if (isLocal) + return LeanTween.rotateLocal(_targetObject.Value, rot, _duration); + else + return LeanTween.rotate(_targetObject.Value, rot, _duration); + } + + public override bool HasReference(Variable variable) + { + return variable == _toTransform.transformRef || _toRotation.vector3Ref == variable || base.HasReference(variable); + } + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/LeanTween/RotateLean.cs.meta b/Assets/Fungus/Scripts/Commands/LeanTween/RotateLean.cs.meta new file mode 100644 index 0000000..1e514c2 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/LeanTween/RotateLean.cs.meta @@ -0,0 +1,12 @@ +fileFormatVersion: 2 +guid: b8feaa22bae049c43a1c6dfe095c498c +timeCreated: 1499583595 +licenseType: Store +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/LeanTween/ScaleLean.cs b/Assets/Fungus/Scripts/Commands/LeanTween/ScaleLean.cs new file mode 100644 index 0000000..7a6d470 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/LeanTween/ScaleLean.cs @@ -0,0 +1,53 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; +using UnityEngine.Serialization; +using System.Collections; +using System; + +namespace Fungus +{ + /// + /// Changes a game object's scale to a specified value over time. + /// + [CommandInfo("LeanTween", + "Scale", + "Changes a game object's scale to a specified value over time.")] + [AddComponentMenu("")] + [ExecuteInEditMode] + public class ScaleLean : BaseLeanTweenCommand + { + [Tooltip("Target transform that the GameObject will scale to")] + [SerializeField] + protected TransformData _toTransform; + + [Tooltip("Target scale that the GameObject will scale to, if no To Transform is set")] + [SerializeField] + protected Vector3Data _toScale = new Vector3Data(Vector3.one); + + public override LTDescr ExecuteTween() + { + var sc = _toTransform.Value == null ? _toScale.Value : _toTransform.Value.localScale; + + if (IsInAddativeMode) + { + sc += _targetObject.Value.transform.localScale; + } + + if (IsInFromMode) + { + var cur = _targetObject.Value.transform.localScale; + _targetObject.Value.transform.localScale = sc; + sc = cur; + } + + return LeanTween.scale(_targetObject.Value, sc, _duration); + } + + public override bool HasReference(Variable variable) + { + return variable == _toTransform.transformRef || _toScale.vector3Ref == variable || base.HasReference(variable); + } + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/LeanTween/ScaleLean.cs.meta b/Assets/Fungus/Scripts/Commands/LeanTween/ScaleLean.cs.meta new file mode 100644 index 0000000..bc45905 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/LeanTween/ScaleLean.cs.meta @@ -0,0 +1,12 @@ +fileFormatVersion: 2 +guid: 30cbb61ab588b1a4093d2ef0254045b0 +timeCreated: 1499585056 +licenseType: Store +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/LeanTween/StopTweensLean.cs b/Assets/Fungus/Scripts/Commands/LeanTween/StopTweensLean.cs new file mode 100644 index 0000000..bd9ce12 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/LeanTween/StopTweensLean.cs @@ -0,0 +1,55 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using System.Collections; +using System.Collections.Generic; +using UnityEngine; + + +namespace Fungus +{ + /// + /// + /// + [CommandInfo("LeanTween", + "StopTweens", + "Stops the LeanTweens on a target GameObject")] + [AddComponentMenu("")] + [ExecuteInEditMode] + public class StopTweensLean : Command + { + [Tooltip("Target game object stop LeanTweens on")] + [SerializeField] + protected GameObjectData _targetObject; + + public override void OnEnter() + { + if (_targetObject.Value != null) + { + LeanTween.cancel(_targetObject.Value); + } + + Continue(); + } + + public override string GetSummary() + { + if (_targetObject.Value == null) + { + return "Error: No target object selected"; + } + + return "Stop all LeanTweens on " + _targetObject.Value.name; + } + + public override Color GetButtonColor() + { + return new Color32(233, 163, 180, 255); + } + + public override bool HasReference(Variable variable) + { + return _targetObject.gameObjectRef == variable; + } + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/LeanTween/StopTweensLean.cs.meta b/Assets/Fungus/Scripts/Commands/LeanTween/StopTweensLean.cs.meta new file mode 100644 index 0000000..6b9ad18 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/LeanTween/StopTweensLean.cs.meta @@ -0,0 +1,12 @@ +fileFormatVersion: 2 +guid: d998218fa600bac43adbc431e9dd6c0c +timeCreated: 1499761355 +licenseType: Store +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/LoadScene.cs b/Assets/Fungus/Scripts/Commands/LoadScene.cs new file mode 100644 index 0000000..fd1c6f5 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/LoadScene.cs @@ -0,0 +1,76 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; +using UnityEngine.Serialization; + +namespace Fungus +{ + /// + /// Loads a new Unity scene and displays an optional loading image. This is useful + /// for splitting a large game across multiple scene files to reduce peak memory + /// usage. Previously loaded assets will be released before loading the scene to free up memory. + /// The scene to be loaded must be added to the scene list in Build Settings.")] + /// + [CommandInfo("Flow", + "Load Scene", + "Loads a new Unity scene and displays an optional loading image. This is useful " + + "for splitting a large game across multiple scene files to reduce peak memory " + + "usage. Previously loaded assets will be released before loading the scene to free up memory." + + "The scene to be loaded must be added to the scene list in Build Settings.")] + [AddComponentMenu("")] + [ExecuteInEditMode] + public class LoadScene : Command + { + [Tooltip("Name of the scene to load. The scene must also be added to the build settings.")] + [SerializeField] protected StringData _sceneName = new StringData(""); + + [Tooltip("Image to display while loading the scene")] + [SerializeField] protected Texture2D loadingImage; + + #region Public members + + public override void OnEnter() + { + SceneLoader.LoadScene(_sceneName.Value, loadingImage); + } + + public override string GetSummary() + { + if (_sceneName.Value.Length == 0) + { + return "Error: No scene name selected"; + } + + return _sceneName.Value; + } + + public override Color GetButtonColor() + { + return new Color32(235, 191, 217, 255); + } + + public override bool HasReference(Variable variable) + { + return _sceneName.stringRef == variable || + base.HasReference(variable); + } + + #endregion + + #region Backwards compatibility + + [HideInInspector] [FormerlySerializedAs("sceneName")] public string sceneNameOLD = ""; + + protected virtual void OnEnable() + { + if (sceneNameOLD != "") + { + _sceneName.Value = sceneNameOLD; + sceneNameOLD = ""; + } + } + + #endregion + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/LoadScene.cs.meta b/Assets/Fungus/Scripts/Commands/LoadScene.cs.meta new file mode 100644 index 0000000..0ee9205 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/LoadScene.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 00d03ae0919f04264b018681ed534177 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Fungus/Scripts/Commands/LoadVariable.cs b/Assets/Fungus/Scripts/Commands/LoadVariable.cs new file mode 100644 index 0000000..0638022 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/LoadVariable.cs @@ -0,0 +1,122 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; + +namespace Fungus +{ + /// + /// Loads a saved value and stores it in a Boolean, Integer, Float or String variable. If the key is not found then the variable is not modified. + /// + [CommandInfo("Variable", + "Load Variable", + "Loads a saved value and stores it in a Boolean, Integer, Float or String variable. If the key is not found then the variable is not modified.")] + [AddComponentMenu("")] + public class LoadVariable : Command + { + [Tooltip("Name of the saved value. Supports variable substition e.g. \"player_{$PlayerNumber}\"")] + [SerializeField] protected string key = ""; + + [Tooltip("Variable to store the value in.")] + [VariableProperty(typeof(BooleanVariable), + typeof(IntegerVariable), + typeof(FloatVariable), + typeof(StringVariable))] + [SerializeField] protected Variable variable; + + #region Public members + + public override void OnEnter() + { + if (key == "" || + variable == null) + { + Continue(); + return; + } + + var flowchart = GetFlowchart(); + + // Prepend the current save profile (if any) + string prefsKey = SetSaveProfile.SaveProfile + "_" + flowchart.SubstituteVariables(key); + + System.Type variableType = variable.GetType(); + + if (variableType == typeof(BooleanVariable)) + { + BooleanVariable booleanVariable = variable as BooleanVariable; + if (booleanVariable != null) + { + // PlayerPrefs does not have bool accessors, so just use int + booleanVariable.Value = (PlayerPrefs.GetInt(prefsKey) == 1); + } + } + else if (variableType == typeof(IntegerVariable)) + { + IntegerVariable integerVariable = variable as IntegerVariable; + if (integerVariable != null) + { + integerVariable.Value = PlayerPrefs.GetInt(prefsKey); + } + } + else if (variableType == typeof(FloatVariable)) + { + FloatVariable floatVariable = variable as FloatVariable; + if (floatVariable != null) + { + floatVariable.Value = PlayerPrefs.GetFloat(prefsKey); + } + } + else if (variableType == typeof(StringVariable)) + { + StringVariable stringVariable = variable as StringVariable; + if (stringVariable != null) + { + stringVariable.Value = PlayerPrefs.GetString(prefsKey); + } + } + + Continue(); + } + + public override string GetSummary() + { + if (key.Length == 0) + { + return "Error: No stored value key selected"; + } + + if (variable == null) + { + return "Error: No variable selected"; + } + + return "'" + key + "' into " + variable.Key; + } + + public override Color GetButtonColor() + { + return new Color32(235, 191, 217, 255); + } + + public override bool HasReference(Variable in_variable) + { + return this.variable == in_variable || + base.HasReference(in_variable); + } + + #endregion + #region Editor caches +#if UNITY_EDITOR + protected override void RefreshVariableCache() + { + base.RefreshVariableCache(); + + var f = GetFlowchart(); + + f.DetermineSubstituteVariables(key, referencedVariables); + } +#endif + #endregion Editor caches + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/LoadVariable.cs.meta b/Assets/Fungus/Scripts/Commands/LoadVariable.cs.meta new file mode 100644 index 0000000..d0b8592 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/LoadVariable.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 23c657364a3b24e16bdf5946729a8b7b +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Fungus/Scripts/Commands/LookFrom.cs b/Assets/Fungus/Scripts/Commands/LookFrom.cs new file mode 100644 index 0000000..fe02c69 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/LookFrom.cs @@ -0,0 +1,96 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; +using UnityEngine.Serialization; +using System.Collections; + +namespace Fungus +{ + /// + /// Instantly rotates a GameObject to look at the supplied Vector3 then returns it to it's starting rotation over time. + /// + [CommandInfo("iTween", + "Look From", + "Instantly rotates a GameObject to look at the supplied Vector3 then returns it to it's starting rotation over time.")] + [AddComponentMenu("")] + [ExecuteInEditMode] + public class LookFrom : iTweenCommand + { + [Tooltip("Target transform that the GameObject will look at")] + [SerializeField] protected TransformData _fromTransform; + + [Tooltip("Target world position that the GameObject will look at, if no From Transform is set")] + [SerializeField] protected Vector3Data _fromPosition; + + [Tooltip("Restricts rotation to the supplied axis only")] + [SerializeField] protected iTweenAxis axis; + + #region Public members + + public override void DoTween() + { + Hashtable tweenParams = new Hashtable(); + tweenParams.Add("name", _tweenName.Value); + if (_fromTransform.Value == null) + { + tweenParams.Add("looktarget", _fromPosition.Value); + } + else + { + tweenParams.Add("looktarget", _fromTransform.Value); + } + switch (axis) + { + case iTweenAxis.X: + tweenParams.Add("axis", "x"); + break; + case iTweenAxis.Y: + tweenParams.Add("axis", "y"); + break; + case iTweenAxis.Z: + tweenParams.Add("axis", "z"); + break; + } + tweenParams.Add("time", _duration.Value); + tweenParams.Add("easetype", easeType); + tweenParams.Add("looptype", loopType); + tweenParams.Add("oncomplete", "OniTweenComplete"); + tweenParams.Add("oncompletetarget", gameObject); + tweenParams.Add("oncompleteparams", this); + iTween.LookFrom(_targetObject.Value, tweenParams); + } + + public override bool HasReference(Variable variable) + { + return _fromTransform.transformRef == variable || _fromPosition.vector3Ref == variable || + base.HasReference(variable); + } + + #endregion + + #region Backwards compatibility + + [HideInInspector] [FormerlySerializedAs("fromTransform")] public Transform fromTransformOLD; + [HideInInspector] [FormerlySerializedAs("fromPosition")] public Vector3 fromPositionOLD; + + protected override void OnEnable() + { + base.OnEnable(); + + if (fromTransformOLD != null) + { + _fromTransform.Value = fromTransformOLD; + fromTransformOLD = null; + } + + if (fromPositionOLD != default(Vector3)) + { + _fromPosition.Value = fromPositionOLD; + fromPositionOLD = default(Vector3); + } + } + + #endregion + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/LookFrom.cs.meta b/Assets/Fungus/Scripts/Commands/LookFrom.cs.meta new file mode 100644 index 0000000..b11105d --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/LookFrom.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 433657382cf894ff2973ee118eed40ea +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Fungus/Scripts/Commands/LookTo.cs b/Assets/Fungus/Scripts/Commands/LookTo.cs new file mode 100644 index 0000000..0c29038 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/LookTo.cs @@ -0,0 +1,96 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; +using UnityEngine.Serialization; +using System.Collections; + +namespace Fungus +{ + /// + /// Rotates a GameObject to look at a supplied Transform or Vector3 over time. + /// + [CommandInfo("iTween", + "Look To", + "Rotates a GameObject to look at a supplied Transform or Vector3 over time.")] + [AddComponentMenu("")] + [ExecuteInEditMode] + public class LookTo : iTweenCommand + { + [Tooltip("Target transform that the GameObject will look at")] + [SerializeField] protected TransformData _toTransform; + + [Tooltip("Target world position that the GameObject will look at, if no From Transform is set")] + [SerializeField] protected Vector3Data _toPosition; + + [Tooltip("Restricts rotation to the supplied axis only")] + [SerializeField] protected iTweenAxis axis; + + #region Public members + + public override void DoTween() + { + Hashtable tweenParams = new Hashtable(); + tweenParams.Add("name", _tweenName.Value); + if (_toTransform.Value == null) + { + tweenParams.Add("looktarget", _toPosition.Value); + } + else + { + tweenParams.Add("looktarget", _toTransform.Value); + } + switch (axis) + { + case iTweenAxis.X: + tweenParams.Add("axis", "x"); + break; + case iTweenAxis.Y: + tweenParams.Add("axis", "y"); + break; + case iTweenAxis.Z: + tweenParams.Add("axis", "z"); + break; + } + tweenParams.Add("time", _duration.Value); + tweenParams.Add("easetype", easeType); + tweenParams.Add("looptype", loopType); + tweenParams.Add("oncomplete", "OniTweenComplete"); + tweenParams.Add("oncompletetarget", gameObject); + tweenParams.Add("oncompleteparams", this); + iTween.LookTo(_targetObject.Value, tweenParams); + } + + public override bool HasReference(Variable variable) + { + return _toTransform.transformRef == variable || _toPosition.vector3Ref == variable || + base.HasReference(variable); + } + + #endregion + + #region Backwards compatibility + + [HideInInspector] [FormerlySerializedAs("toTransform")] public Transform toTransformOLD; + [HideInInspector] [FormerlySerializedAs("toPosition")] public Vector3 toPositionOLD; + + protected override void OnEnable() + { + base.OnEnable(); + + if (toTransformOLD != null) + { + _toTransform.Value = toTransformOLD; + toTransformOLD = null; + } + + if (toPositionOLD != default(Vector3)) + { + _toPosition.Value = toPositionOLD; + toPositionOLD = default(Vector3); + } + } + + #endregion + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/LookTo.cs.meta b/Assets/Fungus/Scripts/Commands/LookTo.cs.meta new file mode 100644 index 0000000..8d79a61 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/LookTo.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 3ec82c445301b4e9fb9b89cb2eb6a666 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Fungus/Scripts/Commands/LoopRange.cs b/Assets/Fungus/Scripts/Commands/LoopRange.cs new file mode 100644 index 0000000..645e11b --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/LoopRange.cs @@ -0,0 +1,84 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) maintained by Chris Gregan (http://twitter.com/gofungus). +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; + +namespace Fungus +{ + /// + /// Loop over a fixed integer range, similar to a common for loop. + /// + [CommandInfo("Flow", + "Loop Range", + "Loop over a fixed integer range, similar to a common for loop.")] + [CommandInfo("Flow", + "For", + "Loop over a fixed integer range, similar to a common for loop.")] + [AddComponentMenu("")] + public class LoopRange : Condition + { + [Tooltip("Starting value for the counter variable")] + [SerializeField] + protected IntegerData startingValue; + + [Tooltip("End value for the counter variable, exclusive")] + [SerializeField] + protected IntegerData endValue; + + [Tooltip("Optional int var to hold the current loop counter.")] + [SerializeField] + protected IntegerData counter; + + [Tooltip("Step size for the counter, how much does it go up by each loop. Default 1")] + [SerializeField] + protected IntegerData step = new IntegerData(1); + + #region Public members + + public override bool IsLooping { get { return true; } } + + protected override void PreEvaluate() + { + //if we came from the end then we are already looping, if not this is first loop so prep + if (ParentBlock.PreviousActiveCommandIndex != endCommand.CommandIndex) + { + counter.Value = startingValue.Value; + } + else + { + counter.Value += (startingValue.Value <= endValue.Value ? step.Value : -step.Value); + } + } + + protected override bool EvaluateCondition() + { + return (startingValue.Value <= endValue.Value ? + counter.Value < endValue.Value : + counter.Value > endValue.Value); + } + + protected override void OnFalse() + { + MoveToEnd(); + } + + public override void OnValidate() + { + // no infinite loops + if (step.Value == 0) + step.Value = 1; + + //no negative steps, we do that automatically + step.Value = Mathf.Abs(step.Value); + } + + public override bool HasReference(Variable variable) + { + return startingValue.integerRef == variable || endValue.integerRef == variable || + counter.integerRef == variable || step.integerRef == variable || + base.HasReference(variable); + } + + #endregion + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/LoopRange.cs.meta b/Assets/Fungus/Scripts/Commands/LoopRange.cs.meta new file mode 100644 index 0000000..ca43b9d --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/LoopRange.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: b0eebb5bf2fc1e542a35e2e5332e60d4 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/LuaCondition.cs b/Assets/Fungus/Scripts/Commands/LuaCondition.cs new file mode 100644 index 0000000..5495015 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/LuaCondition.cs @@ -0,0 +1,118 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using System.Collections; +using System.Collections.Generic; +using UnityEngine; +using Fungus; +using MoonSharp.Interpreter; + +namespace Fungus +{ + public class LuaCondition : Condition + { + [Tooltip("Lua Environment to use to execute this Lua script (null for global)")] + [SerializeField] protected LuaEnvironment luaEnvironment; + + [Tooltip("The lua comparison string to run; implicitly prepends 'return' onto this")] + [TextArea] + public string luaCompareString; + protected bool initialised; + protected string friendlyName = ""; + protected Closure luaFunction; + + protected override bool EvaluateCondition() + { + bool condition = false; + luaEnvironment.RunLuaFunction(luaFunction, false, (returnValue) => { + if( returnValue != null ) + { + condition = returnValue.Boolean; + } + else + { + Debug.LogWarning("No return value from " + friendlyName); + } + }); + return condition; + } + + protected override bool HasNeededProperties() + { + return !string.IsNullOrEmpty(luaCompareString); + } + + protected virtual void Start() + { + InitExecuteLua(); + } + + protected virtual string GetLuaString() + { + return "return not not (" + luaCompareString + ")"; + } + + /// + /// Initialises the Lua environment and compiles the Lua string for execution later on. + /// + protected virtual void InitExecuteLua() + { + if (initialised) + { + return; + } + + // Cache a descriptive name to use in Lua error messages + friendlyName = GetLocationIdentifier(); + + Flowchart flowchart = GetFlowchart(); + + // See if a Lua Environment has been assigned to this Flowchart + if (luaEnvironment == null) + { + luaEnvironment = flowchart.LuaEnv; + } + + // No Lua Environment specified so just use any available or create one. + if (luaEnvironment == null) + { + luaEnvironment = LuaEnvironment.GetLua(); + } + + string s = GetLuaString(); + luaFunction = luaEnvironment.LoadLuaFunction(s, friendlyName); + + // Add a binding to the parent flowchart + if (flowchart.LuaBindingName != "") + { + Table globals = luaEnvironment.Interpreter.Globals; + if (globals != null) + { + globals[flowchart.LuaBindingName] = flowchart; + } + } + + // Always initialise when playing in the editor. + // Allows the user to edit the Lua script while the game is playing. + if ( !(Application.isPlaying && Application.isEditor) ) + { + initialised = true; + } + + } + + #region Public members + + public override string GetSummary() + { + if (string.IsNullOrEmpty(luaCompareString)) + { + return "Error: no lua compare string provided"; + } + + return luaCompareString; + } + + #endregion + } +} diff --git a/Assets/Fungus/Scripts/Commands/LuaCondition.cs.meta b/Assets/Fungus/Scripts/Commands/LuaCondition.cs.meta new file mode 100644 index 0000000..690f75a --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/LuaCondition.cs.meta @@ -0,0 +1,12 @@ +fileFormatVersion: 2 +guid: 75ddfadd68d3d4713803a6b170cb0b51 +timeCreated: 1493078204 +licenseType: Store +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/LuaElseIf.cs b/Assets/Fungus/Scripts/Commands/LuaElseIf.cs new file mode 100644 index 0000000..440c125 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/LuaElseIf.cs @@ -0,0 +1,28 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; + +namespace Fungus +{ + /// + /// Marks the start of a command block to be executed when the preceding If statement is False and the test expression is true. + /// + [CommandInfo("Flow", + "Lua Else If", + "Marks the start of a command block to be executed when the preceding If statement is False and the test expression is true.")] + [AddComponentMenu("")] + public class LuaElseIf : LuaCondition + { + protected override bool IsElseIf { get { return true; } } + + #region Public members + + public override bool CloseBlock() + { + return true; + } + + #endregion + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/LuaElseIf.cs.meta b/Assets/Fungus/Scripts/Commands/LuaElseIf.cs.meta new file mode 100644 index 0000000..ec99b9b --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/LuaElseIf.cs.meta @@ -0,0 +1,12 @@ +fileFormatVersion: 2 +guid: 9739de3269e5246b399e3a1cd41b94de +timeCreated: 1493078204 +licenseType: Store +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/LuaIf.cs b/Assets/Fungus/Scripts/Commands/LuaIf.cs new file mode 100644 index 0000000..5787a9e --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/LuaIf.cs @@ -0,0 +1,21 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; + +namespace Fungus +{ + /// + /// If the test expression is true, execute the following command block. + /// + [CommandInfo("Flow", + "Lua If", + "If the test expression is true, execute the following command block.")] + [AddComponentMenu("")] + public class LuaIf : LuaCondition + { + #region Public members + + #endregion + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/LuaIf.cs.meta b/Assets/Fungus/Scripts/Commands/LuaIf.cs.meta new file mode 100644 index 0000000..27f784e --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/LuaIf.cs.meta @@ -0,0 +1,12 @@ +fileFormatVersion: 2 +guid: a8d396bcbf372485cad471c0bb64bb44 +timeCreated: 1493078204 +licenseType: Store +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/Math.meta b/Assets/Fungus/Scripts/Commands/Math.meta new file mode 100644 index 0000000..f4de1e2 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Math.meta @@ -0,0 +1,9 @@ +fileFormatVersion: 2 +guid: 09c52cfe3a6ff4747a9c207bec24ba11 +folderAsset: yes +timeCreated: 1503202781 +licenseType: Store +DefaultImporter: + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/Math/Abs.cs b/Assets/Fungus/Scripts/Commands/Math/Abs.cs new file mode 100644 index 0000000..a62fadf --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Math/Abs.cs @@ -0,0 +1,24 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; + +namespace Fungus +{ + /// + /// Command to execute and store the result of a Abs + /// + [CommandInfo("Math", + "Abs", + "Command to execute and store the result of a Abs")] + [AddComponentMenu("")] + public class Abs : BaseUnaryMathCommand + { + public override void OnEnter() + { + outValue.Value = Mathf.Abs(inValue.Value); + + Continue(); + } + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/Math/Abs.cs.meta b/Assets/Fungus/Scripts/Commands/Math/Abs.cs.meta new file mode 100644 index 0000000..c5e6d5a --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Math/Abs.cs.meta @@ -0,0 +1,12 @@ +fileFormatVersion: 2 +guid: 6d11e978db36df445816ec2535d381ce +timeCreated: 1501211592 +licenseType: Store +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/Math/BaseUnaryMathCommand.cs b/Assets/Fungus/Scripts/Commands/Math/BaseUnaryMathCommand.cs new file mode 100644 index 0000000..6c45908 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Math/BaseUnaryMathCommand.cs @@ -0,0 +1,38 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; + +namespace Fungus +{ + /// + /// Base class for all simple Unary + /// + [AddComponentMenu("")] + public abstract class BaseUnaryMathCommand : Command + { + [Tooltip("Value to be passed in to the function.")] + [SerializeField] + protected FloatData inValue; + + [Tooltip("Where the result of the function is stored.")] + [SerializeField] + protected FloatData outValue; + + public override Color GetButtonColor() + { + return new Color32(235, 191, 217, 255); + } + + public override string GetSummary() + { + return "in: " + (inValue.floatRef != null ? inValue.floatRef.Key : inValue.Value.ToString()) + + ", out: " + (outValue.floatRef != null ? outValue.floatRef.Key : outValue.Value.ToString()); + } + + public override bool HasReference(Variable variable) + { + return variable == inValue.floatRef || variable == outValue.floatRef; + } + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/Math/BaseUnaryMathCommand.cs.meta b/Assets/Fungus/Scripts/Commands/Math/BaseUnaryMathCommand.cs.meta new file mode 100644 index 0000000..d5c5234 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Math/BaseUnaryMathCommand.cs.meta @@ -0,0 +1,12 @@ +fileFormatVersion: 2 +guid: 513a02811ba512d4ab54d157a15ae8c2 +timeCreated: 1501211592 +licenseType: Store +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/Math/Clamp.cs b/Assets/Fungus/Scripts/Commands/Math/Clamp.cs new file mode 100644 index 0000000..345994e --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Math/Clamp.cs @@ -0,0 +1,78 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; + +namespace Fungus +{ + /// + /// Command to contain a value between a lower and upper bound, with optional wrapping modes + /// + [CommandInfo("Math", + "Clamp", + "Command to contain a value between a lower and upper bound, with optional wrapping modes")] + [AddComponentMenu("")] + public class Clamp : Command + { + public enum Mode + { + Clamp, + Repeat, + PingPong + } + + [SerializeField] + protected Mode mode = Mode.Clamp; + + //[Tooltip("LHS Value ")] + [SerializeField] + protected FloatData lower, upper, value; + + [Tooltip("Result put here, if using pingpong don't use the same var for value as outValue.")] + [SerializeField] + protected FloatData outValue; + + public override void OnEnter() + { + var l = lower.Value; + var u = upper.Value; + var v = value.Value; + + switch (mode) + { + case Mode.Clamp: + outValue.Value = Mathf.Clamp(value.Value, lower.Value, upper.Value); + break; + case Mode.Repeat: + outValue.Value = (Mathf.Repeat(v - l, u - l)) + l; + break; + case Mode.PingPong: + outValue.Value = (Mathf.PingPong(v - l, u - l)) + l; + break; + default: + break; + } + + Continue(); + } + + public override string GetSummary() + { + if (outValue.floatRef == null) + return "Error: no output value selected"; + + return outValue.floatRef.Key + " = " + Mode.Clamp.ToString() + (mode != Mode.Clamp ? " & " + mode.ToString() : ""); + } + + public override bool HasReference(Variable variable) + { + return lower.floatRef == variable || upper.floatRef == variable || value.floatRef == variable || + outValue.floatRef == variable; + } + + public override Color GetButtonColor() + { + return new Color32(235, 191, 217, 255); + } + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/Math/Clamp.cs.meta b/Assets/Fungus/Scripts/Commands/Math/Clamp.cs.meta new file mode 100644 index 0000000..d4ff094 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Math/Clamp.cs.meta @@ -0,0 +1,12 @@ +fileFormatVersion: 2 +guid: 2929f1e90a24b6446a70d27316cff20a +timeCreated: 1501225403 +licenseType: Store +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/Math/Curve.cs b/Assets/Fungus/Scripts/Commands/Math/Curve.cs new file mode 100644 index 0000000..6e754f1 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Math/Curve.cs @@ -0,0 +1,27 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; + +namespace Fungus +{ + /// + /// Pass a value through an AnimationCurve + /// + [CommandInfo("Math", + "Curve", + "Pass a value through an AnimationCurve")] + [AddComponentMenu("")] + public class Curve : BaseUnaryMathCommand + { + [SerializeField] + protected AnimationCurve curve = AnimationCurve.Linear(0, 0, 1, 1); + + public override void OnEnter() + { + outValue.Value = curve.Evaluate(inValue.Value); + + Continue(); + } + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/Math/Curve.cs.meta b/Assets/Fungus/Scripts/Commands/Math/Curve.cs.meta new file mode 100644 index 0000000..6c6dfab --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Math/Curve.cs.meta @@ -0,0 +1,12 @@ +fileFormatVersion: 2 +guid: c03f48fc50d3747478ad85653a21a5f5 +timeCreated: 1501226831 +licenseType: Store +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/Math/Exp.cs b/Assets/Fungus/Scripts/Commands/Math/Exp.cs new file mode 100644 index 0000000..4454361 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Math/Exp.cs @@ -0,0 +1,24 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; + +namespace Fungus +{ + /// + /// Command to execute and store the result of a Exp + /// + [CommandInfo("Math", + "Exp", + "Command to execute and store the result of a Exp")] + [AddComponentMenu("")] + public class Exp : BaseUnaryMathCommand + { + public override void OnEnter() + { + outValue.Value = Mathf.Exp(inValue.Value); + + Continue(); + } + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/Math/Exp.cs.meta b/Assets/Fungus/Scripts/Commands/Math/Exp.cs.meta new file mode 100644 index 0000000..a09f9e7 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Math/Exp.cs.meta @@ -0,0 +1,12 @@ +fileFormatVersion: 2 +guid: f28df8ed8a80fa345b3b5e3dcacdea65 +timeCreated: 1501211938 +licenseType: Store +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/Math/Inv.cs b/Assets/Fungus/Scripts/Commands/Math/Inv.cs new file mode 100644 index 0000000..a900cf5 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Math/Inv.cs @@ -0,0 +1,26 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; + +namespace Fungus +{ + /// + /// Multiplicative Inverse of a float (1/f) + /// + [CommandInfo("Math", + "Inverse", + "Multiplicative Inverse of a float (1/f)")] + [AddComponentMenu("")] + public class Inv : BaseUnaryMathCommand + { + public override void OnEnter() + { + var v = inValue.Value; + + outValue.Value = v != 0 ? (1.0f / inValue.Value) : 0.0f; + + Continue(); + } + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/Math/Inv.cs.meta b/Assets/Fungus/Scripts/Commands/Math/Inv.cs.meta new file mode 100644 index 0000000..e6330b6 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Math/Inv.cs.meta @@ -0,0 +1,12 @@ +fileFormatVersion: 2 +guid: 36d3a877e83b1d1478f1ac099414d17a +timeCreated: 1501213679 +licenseType: Store +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/Math/InvLerp.cs b/Assets/Fungus/Scripts/Commands/Math/InvLerp.cs new file mode 100644 index 0000000..1932999 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Math/InvLerp.cs @@ -0,0 +1,58 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; + +namespace Fungus +{ + /// + /// Calculates the inverse lerp, the percentage a value is between two others. + /// + [CommandInfo("Math", + "InvLerp", + "Calculates the inverse lerp, the percentage a value is between two others.")] + [AddComponentMenu("")] + public class InvLerp : Command + { + [Tooltip("Clamp percentage to 0-1?")] + [SerializeField] + protected bool clampResult = true; + + //[Tooltip("LHS Value ")] + [SerializeField] + protected FloatData a, b, value; + + //[Tooltip("Where the result of the function is stored.")] + [SerializeField] + protected FloatData outValue; + + public override void OnEnter() + { + if (clampResult) + outValue.Value = Mathf.InverseLerp(a.Value, b.Value, value.Value); + else + outValue.Value = (value.Value - a.Value) / (b.Value - a.Value); + + Continue(); + } + + public override string GetSummary() + { + if (outValue.floatRef == null) + return "Error: no out value selected"; + + return outValue.floatRef.Key + " = [" + a.Value.ToString() + "-" + b.Value.ToString() + "]"; + } + + public override bool HasReference(Variable variable) + { + return a.floatRef == variable || b.floatRef == variable || value.floatRef == variable || + outValue.floatRef == variable; + } + + public override Color GetButtonColor() + { + return new Color32(235, 191, 217, 255); + } + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/Math/InvLerp.cs.meta b/Assets/Fungus/Scripts/Commands/Math/InvLerp.cs.meta new file mode 100644 index 0000000..1d4f237 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Math/InvLerp.cs.meta @@ -0,0 +1,12 @@ +fileFormatVersion: 2 +guid: 80c88869f66a81f4b95e843c36724e65 +timeCreated: 1501213063 +licenseType: Store +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/Math/Lerp.cs b/Assets/Fungus/Scripts/Commands/Math/Lerp.cs new file mode 100644 index 0000000..2bcae56 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Math/Lerp.cs @@ -0,0 +1,72 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; + +namespace Fungus +{ + /// + /// Linearly Interpolate from A to B + /// + [CommandInfo("Math", + "Lerp", + "Linearly Interpolate from A to B")] + [AddComponentMenu("")] + public class Lerp : Command + { + public enum Mode + { + Lerp, + LerpUnclamped, + LerpAngle + } + + [SerializeField] + protected Mode mode = Mode.Lerp; + + //[Tooltip("LHS Value ")] + [SerializeField] + protected FloatData a = new FloatData(0), b = new FloatData(1), percentage; + + //[Tooltip("Where the result of the function is stored.")] + [SerializeField] + protected FloatData outValue; + + public override void OnEnter() + { + switch (mode) + { + case Mode.Lerp: + outValue.Value = Mathf.Lerp(a.Value, b.Value, percentage.Value); + break; + case Mode.LerpUnclamped: + outValue.Value = Mathf.LerpUnclamped(a.Value, b.Value, percentage.Value); + break; + case Mode.LerpAngle: + outValue.Value = Mathf.LerpAngle(a.Value, b.Value, percentage.Value); + break; + default: + break; + } + + Continue(); + } + + public override string GetSummary() + { + return mode.ToString() + " [" + a.Value.ToString() + "-" + b.Value.ToString() + "]"; + } + + public override bool HasReference(Variable variable) + { + return a.floatRef == variable || b.floatRef == variable || percentage.floatRef == variable || + outValue.floatRef == variable; + } + + public override Color GetButtonColor() + { + return new Color32(235, 191, 217, 255); + } + + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/Math/Lerp.cs.meta b/Assets/Fungus/Scripts/Commands/Math/Lerp.cs.meta new file mode 100644 index 0000000..caf41ea --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Math/Lerp.cs.meta @@ -0,0 +1,12 @@ +fileFormatVersion: 2 +guid: b44d8d3a71d3e7b45a89437c8f84e687 +timeCreated: 1501212773 +licenseType: Store +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/Math/Log.cs b/Assets/Fungus/Scripts/Commands/Math/Log.cs new file mode 100644 index 0000000..fa85bfc --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Math/Log.cs @@ -0,0 +1,49 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; + +namespace Fungus +{ + /// + /// Command to execute and store the result of a Log + /// + [CommandInfo("Math", + "Log", + "Command to execute and store the result of a Log")] + [AddComponentMenu("")] + public class Log : BaseUnaryMathCommand + { + public enum Mode + { + Base10, + Natural + } + + [Tooltip("Which log to use, natural or base 10")] + [SerializeField] + protected Mode mode = Mode.Natural; + + public override void OnEnter() + { + switch (mode) + { + case Mode.Base10: + outValue.Value = Mathf.Log10(inValue.Value); + break; + case Mode.Natural: + outValue.Value = Mathf.Log(inValue.Value); + break; + default: + break; + } + + Continue(); + } + + public override string GetSummary() + { + return mode.ToString() + " " + base.GetSummary(); + } + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/Math/Log.cs.meta b/Assets/Fungus/Scripts/Commands/Math/Log.cs.meta new file mode 100644 index 0000000..215bc83 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Math/Log.cs.meta @@ -0,0 +1,12 @@ +fileFormatVersion: 2 +guid: 47ecda391b679d8449893d4466f41b13 +timeCreated: 1501211938 +licenseType: Store +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/Math/Map.cs b/Assets/Fungus/Scripts/Commands/Math/Map.cs new file mode 100644 index 0000000..d7cba73 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Math/Map.cs @@ -0,0 +1,58 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; + +namespace Fungus +{ + /// + /// Map a value that exists in 1 range of numbers to another. + /// + [CommandInfo("Math", + "Map", + "Map a value that exists in 1 range of numbers to another.")] + [AddComponentMenu("")] + public class Map : Command + { + //[Tooltip("LHS Value ")] + [SerializeField] + protected FloatData initialRangeLower = new FloatData(0), initialRangeUpper = new FloatData(1), value; + + [SerializeField] + protected FloatData newRangeLower = new FloatData(0), newRangeUpper = new FloatData(1); + + [SerializeField] + protected FloatData outValue; + + public override void OnEnter() + { + var p = value.Value - initialRangeLower.Value; + p /= initialRangeUpper.Value - initialRangeLower.Value; + + var res = p * (newRangeUpper.Value - newRangeLower.Value); + res += newRangeLower.Value; + + outValue.Value = res; + + Continue(); + } + + public override string GetSummary() + { + return "Map [" + initialRangeLower.Value.ToString() + "-" + initialRangeUpper.Value.ToString() + "] to [" + + newRangeLower.Value.ToString() + "-" + newRangeUpper.Value.ToString() + "]"; + } + + public override bool HasReference(Variable variable) + { + return initialRangeLower.floatRef == variable || initialRangeUpper.floatRef == variable || value.floatRef == variable || + newRangeLower.floatRef == variable || newRangeUpper.floatRef == variable || + outValue.floatRef == variable; + } + + public override Color GetButtonColor() + { + return new Color32(235, 191, 217, 255); + } + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/Math/Map.cs.meta b/Assets/Fungus/Scripts/Commands/Math/Map.cs.meta new file mode 100644 index 0000000..e7b203c --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Math/Map.cs.meta @@ -0,0 +1,12 @@ +fileFormatVersion: 2 +guid: 78d80bb5401d8044eb9eee0d4eb0b645 +timeCreated: 1501226122 +licenseType: Store +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/Math/MinMax.cs b/Assets/Fungus/Scripts/Commands/Math/MinMax.cs new file mode 100644 index 0000000..28a1d36 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Math/MinMax.cs @@ -0,0 +1,69 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; + +namespace Fungus +{ + /// + /// Command to store the min or max of 2 values + /// + [CommandInfo("Math", + "MinMax", + "Command to store the min or max of 2 values")] + [AddComponentMenu("")] + public class MinMax : Command + { + public enum Function + { + Min, + Max + } + + [Tooltip("Min Or Max")] + [SerializeField] + protected Function function = Function.Min; + + //[Tooltip("LHS Value ")] + [SerializeField] + protected FloatData inLHSValue, inRHSValue; + + //[Tooltip("Where the result of the function is stored.")] + [SerializeField] + protected FloatData outValue; + + public override void OnEnter() + { + switch (function) + { + case Function.Min: + outValue.Value = Mathf.Min(inLHSValue.Value, inRHSValue.Value); + break; + case Function.Max: + outValue.Value = Mathf.Max(inLHSValue.Value, inRHSValue.Value); + break; + default: + break; + } + + Continue(); + } + + public override string GetSummary() + { + return function.ToString() + " " + + "out: " + (outValue.floatRef != null ? outValue.floatRef.Key : outValue.Value.ToString()) + + " [" + inLHSValue.Value.ToString() + " - " + inRHSValue.Value.ToString() + "]"; + } + + public override bool HasReference(Variable variable) + { + return inLHSValue.floatRef == variable || inRHSValue.floatRef == variable || outValue.floatRef == variable; + } + + public override Color GetButtonColor() + { + return new Color32(235, 191, 217, 255); + } + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/Math/MinMax.cs.meta b/Assets/Fungus/Scripts/Commands/Math/MinMax.cs.meta new file mode 100644 index 0000000..e7dc835 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Math/MinMax.cs.meta @@ -0,0 +1,12 @@ +fileFormatVersion: 2 +guid: 514ec18f5085cba48bbe6701e4697eb0 +timeCreated: 1501212523 +licenseType: Store +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/Math/Neg.cs b/Assets/Fungus/Scripts/Commands/Math/Neg.cs new file mode 100644 index 0000000..85ab31b --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Math/Neg.cs @@ -0,0 +1,24 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; + +namespace Fungus +{ + /// + /// Negate a float + /// + [CommandInfo("Math", + "Negate", + "Negate a float")] + [AddComponentMenu("")] + public class Neg : BaseUnaryMathCommand + { + public override void OnEnter() + { + outValue.Value = -(inValue.Value); + + Continue(); + } + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/Math/Neg.cs.meta b/Assets/Fungus/Scripts/Commands/Math/Neg.cs.meta new file mode 100644 index 0000000..22896ad --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Math/Neg.cs.meta @@ -0,0 +1,12 @@ +fileFormatVersion: 2 +guid: ff146879925212d4988aa4318efcbbd5 +timeCreated: 1501213679 +licenseType: Store +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/Math/Pow.cs b/Assets/Fungus/Scripts/Commands/Math/Pow.cs new file mode 100644 index 0000000..52a480c --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Math/Pow.cs @@ -0,0 +1,50 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; + +namespace Fungus +{ + /// + /// Raise a value to the power of another + /// + [CommandInfo("Math", + "Pow", + "Raise a value to the power of another.")] + [AddComponentMenu("")] + public class Pow : Command + { + [SerializeField] + protected FloatData baseValue, exponentValue; + + [Tooltip("Where the result of the function is stored.")] + [SerializeField] + protected FloatData outValue; + + public override void OnEnter() + { + outValue.Value = Mathf.Pow(baseValue.Value, exponentValue.Value); + + Continue(); + } + + public override string GetSummary() + { + if (outValue.floatRef == null) + return "Error: No out value selected"; + + return outValue.floatRef.Key + " = " + baseValue.Value.ToString() + "^" + exponentValue.Value.ToString(); + } + + public override Color GetButtonColor() + { + return new Color32(235, 191, 217, 255); + } + + public override bool HasReference(Variable variable) + { + return baseValue.floatRef == variable || exponentValue.floatRef == variable || + outValue.floatRef == variable; + } + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/Math/Pow.cs.meta b/Assets/Fungus/Scripts/Commands/Math/Pow.cs.meta new file mode 100644 index 0000000..23863f3 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Math/Pow.cs.meta @@ -0,0 +1,12 @@ +fileFormatVersion: 2 +guid: 23b09e2ab627fec4cb0200f7252dbc90 +timeCreated: 1501497818 +licenseType: Store +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/Math/Round.cs b/Assets/Fungus/Scripts/Commands/Math/Round.cs new file mode 100644 index 0000000..2a96990 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Math/Round.cs @@ -0,0 +1,53 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; + +namespace Fungus +{ + /// + /// Command to execute and store the result of a Round + /// + [CommandInfo("Math", + "Round", + "Command to execute and store the result of a Round")] + [AddComponentMenu("")] + public class Round : BaseUnaryMathCommand + { + public enum Mode + { + Round, + Floor, + Ceil + } + + [Tooltip("Mode; Round (closest), floor(smaller) or ceil(bigger).")] + [SerializeField] + protected Mode function = Mode.Round; + + public override void OnEnter() + { + switch (function) + { + case Mode.Round: + outValue.Value = Mathf.Round(inValue.Value); + break; + case Mode.Floor: + outValue.Value = Mathf.Floor(inValue.Value); + break; + case Mode.Ceil: + outValue.Value = Mathf.Ceil(inValue.Value); + break; + default: + break; + } + + Continue(); + } + + public override string GetSummary() + { + return function.ToString() + " " + base.GetSummary(); + } + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/Math/Round.cs.meta b/Assets/Fungus/Scripts/Commands/Math/Round.cs.meta new file mode 100644 index 0000000..5b1397f --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Math/Round.cs.meta @@ -0,0 +1,12 @@ +fileFormatVersion: 2 +guid: b9c834185b491334d8e41ca4fc49a56e +timeCreated: 1501212403 +licenseType: Store +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/Math/Sign.cs b/Assets/Fungus/Scripts/Commands/Math/Sign.cs new file mode 100644 index 0000000..771d6d1 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Math/Sign.cs @@ -0,0 +1,24 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; + +namespace Fungus +{ + /// + /// Command to execute and store the result of a Sign + /// + [CommandInfo("Math", + "Sign", + "Command to execute and store the result of a Sign")] + [AddComponentMenu("")] + public class Sign : BaseUnaryMathCommand + { + public override void OnEnter() + { + outValue.Value = Mathf.Sign(inValue.Value); + + Continue(); + } + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/Math/Sign.cs.meta b/Assets/Fungus/Scripts/Commands/Math/Sign.cs.meta new file mode 100644 index 0000000..049f719 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Math/Sign.cs.meta @@ -0,0 +1,12 @@ +fileFormatVersion: 2 +guid: 6a03542258f6b654b8a6d64938803f71 +timeCreated: 1501211938 +licenseType: Store +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/Math/Sqrt.cs b/Assets/Fungus/Scripts/Commands/Math/Sqrt.cs new file mode 100644 index 0000000..71633f4 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Math/Sqrt.cs @@ -0,0 +1,24 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; + +namespace Fungus +{ + /// + /// Command to execute and store the result of a Sqrt + /// + [CommandInfo("Math", + "Sqrt", + "Command to execute and store the result of a Sqrt")] + [AddComponentMenu("")] + public class Sqrt : BaseUnaryMathCommand + { + public override void OnEnter() + { + outValue.Value = Mathf.Sqrt(inValue.Value); + + Continue(); + } + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/Math/Sqrt.cs.meta b/Assets/Fungus/Scripts/Commands/Math/Sqrt.cs.meta new file mode 100644 index 0000000..d23b86c --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Math/Sqrt.cs.meta @@ -0,0 +1,12 @@ +fileFormatVersion: 2 +guid: 6e52daa13ab8fe7499a7774ebc194fc5 +timeCreated: 1501211938 +licenseType: Store +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/Math/ToInt.cs b/Assets/Fungus/Scripts/Commands/Math/ToInt.cs new file mode 100644 index 0000000..1231e2e --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Math/ToInt.cs @@ -0,0 +1,74 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; + +namespace Fungus +{ + /// + /// Command to execute and store the result of a float to int conversion + /// + [CommandInfo("Math", + "ToInt", + "Command to execute and store the result of a float to int conversion")] + [AddComponentMenu("")] + public class ToInt : Command + { + public enum Mode + { + RoundToInt, + FloorToInt, + CeilToInt, + } + + + [Tooltip("To integer mode; round, floor or ceil.")] + [SerializeField] + protected Mode function = Mode.RoundToInt; + + [Tooltip("Value to be passed in to the function.")] + [SerializeField] + protected FloatData inValue; + + [Tooltip("Where the result of the function is stored.")] + [SerializeField] + protected IntegerData outValue; + + public override void OnEnter() + { + switch (function) + { + case Mode.RoundToInt: + outValue.Value = Mathf.RoundToInt(inValue.Value); + break; + case Mode.FloorToInt: + outValue.Value = Mathf.FloorToInt(inValue.Value); + break; + case Mode.CeilToInt: + outValue.Value = Mathf.CeilToInt(inValue.Value); + break; + default: + break; + } + + Continue(); + } + + public override string GetSummary() + { + return function.ToString() + + " in: " + (inValue.floatRef != null ? inValue.floatRef.Key : inValue.Value.ToString()) + + ", out: " + (outValue.integerRef != null ? outValue.integerRef.Key : outValue.Value.ToString()); ; + } + + public override Color GetButtonColor() + { + return new Color32(235, 191, 217, 255); + } + + public override bool HasReference(Variable variable) + { + return variable == inValue.floatRef || variable == outValue.integerRef; + } + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/Math/ToInt.cs.meta b/Assets/Fungus/Scripts/Commands/Math/ToInt.cs.meta new file mode 100644 index 0000000..c2b2d3a --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Math/ToInt.cs.meta @@ -0,0 +1,12 @@ +fileFormatVersion: 2 +guid: 209dba259f0c4134daa0ec3b64c78062 +timeCreated: 1501210911 +licenseType: Store +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/Math/Trig.cs b/Assets/Fungus/Scripts/Commands/Math/Trig.cs new file mode 100644 index 0000000..881b039 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Math/Trig.cs @@ -0,0 +1,73 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; + +namespace Fungus +{ + /// + /// Command to execute and store the result of basic trigonometry + /// + [CommandInfo("Math", + "Trig", + "Command to execute and store the result of basic trigonometry")] + [AddComponentMenu("")] + public class Trig : BaseUnaryMathCommand + { + public enum Function + { + Rad2Deg, + Deg2Rad, + ACos, + ASin, + ATan, + Cos, + Sin, + Tan + } + + [Tooltip("Trigonometric function to run.")] + [SerializeField] + protected Function function = Function.Sin; + + public override void OnEnter() + { + switch (function) + { + case Function.Rad2Deg: + outValue.Value = inValue.Value * Mathf.Rad2Deg; + break; + case Function.Deg2Rad: + outValue.Value = inValue.Value * Mathf.Deg2Rad; + break; + case Function.ACos: + outValue.Value = Mathf.Acos(inValue.Value); + break; + case Function.ASin: + outValue.Value = Mathf.Asin(inValue.Value); + break; + case Function.ATan: + outValue.Value = Mathf.Atan(inValue.Value); + break; + case Function.Cos: + outValue.Value = Mathf.Cos(inValue.Value); + break; + case Function.Sin: + outValue.Value = Mathf.Sin(inValue.Value); + break; + case Function.Tan: + outValue.Value = Mathf.Tan(inValue.Value); + break; + default: + break; + } + + Continue(); + } + + public override string GetSummary() + { + return function.ToString() + " " + base.GetSummary(); + } + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/Math/Trig.cs.meta b/Assets/Fungus/Scripts/Commands/Math/Trig.cs.meta new file mode 100644 index 0000000..06bdd13 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Math/Trig.cs.meta @@ -0,0 +1,12 @@ +fileFormatVersion: 2 +guid: ee9ab1525ab1b794489f2517aab1d5e2 +timeCreated: 1501148787 +licenseType: Store +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/Menu.cs b/Assets/Fungus/Scripts/Commands/Menu.cs new file mode 100644 index 0000000..b9993ff --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Menu.cs @@ -0,0 +1,149 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; +using UnityEngine.Serialization; +using System.Collections.Generic; + +namespace Fungus +{ + /// + /// Displays a button in a multiple choice menu. + /// + [CommandInfo("Narrative", + "Menu", + "Displays a button in a multiple choice menu")] + [AddComponentMenu("")] + public class Menu : Command, ILocalizable, IBlockCaller + { + [Tooltip("Text to display on the menu button")] + [TextArea()] + [SerializeField] protected string text = "Option Text"; + + [Tooltip("Notes about the option text for other authors, localization, etc.")] + [SerializeField] protected string description = ""; + + [FormerlySerializedAs("targetSequence")] + [Tooltip("Block to execute when this option is selected")] + [SerializeField] protected Block targetBlock; + + [Tooltip("Hide this option if the target block has been executed previously")] + [SerializeField] protected bool hideIfVisited; + + [Tooltip("If false, the menu option will be displayed but will not be selectable")] + [SerializeField] protected BooleanData interactable = new BooleanData(true); + + [Tooltip("A custom Menu Dialog to use to display this menu. All subsequent Menu commands will use this dialog.")] + [SerializeField] protected MenuDialog setMenuDialog; + + [Tooltip("If true, this option will be passed to the Menu Dialogue but marked as hidden, this can be used to hide options while maintaining a Menu Shuffle.")] + [SerializeField] protected BooleanData hideThisOption = new BooleanData(false); + + #region Public members + + public MenuDialog SetMenuDialog { get { return setMenuDialog; } set { setMenuDialog = value; } } + + public override void OnEnter() + { + if (setMenuDialog != null) + { + // Override the active menu dialog + MenuDialog.ActiveMenuDialog = setMenuDialog; + } + + bool hideOption = (hideIfVisited && targetBlock != null && targetBlock.GetExecutionCount() > 0) || hideThisOption.Value; + + var menuDialog = MenuDialog.GetMenuDialog(); + if (menuDialog != null) + { + menuDialog.SetActive(true); + + var flowchart = GetFlowchart(); + string displayText = flowchart.SubstituteVariables(text); + + menuDialog.AddOption(displayText, interactable, hideOption, targetBlock); + } + + Continue(); + } + + public override void GetConnectedBlocks(ref List connectedBlocks) + { + if (targetBlock != null) + { + connectedBlocks.Add(targetBlock); + } + } + + public override string GetSummary() + { + if (targetBlock == null) + { + return "Error: No target block selected"; + } + + if (text == "") + { + return "Error: No button text selected"; + } + + return text + " : " + targetBlock.BlockName; + } + + public override Color GetButtonColor() + { + return new Color32(184, 210, 235, 255); + } + + public override bool HasReference(Variable variable) + { + return interactable.booleanRef == variable || hideThisOption.booleanRef == variable || + base.HasReference(variable); + } + + public bool MayCallBlock(Block block) + { + return block == targetBlock; + } + + #endregion + + #region ILocalizable implementation + + public virtual string GetStandardText() + { + return text; + } + + public virtual void SetStandardText(string standardText) + { + text = standardText; + } + + public virtual string GetDescription() + { + return description; + } + + public virtual string GetStringId() + { + // String id for Menu commands is MENU.. + return "MENU." + GetFlowchartLocalizationId() + "." + itemId; + } + + #endregion + + #region Editor caches +#if UNITY_EDITOR + protected override void RefreshVariableCache() + { + base.RefreshVariableCache(); + + var f = GetFlowchart(); + + f.DetermineSubstituteVariables(text, referencedVariables); + } +#endif + #endregion Editor caches + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/Menu.cs.meta b/Assets/Fungus/Scripts/Commands/Menu.cs.meta new file mode 100644 index 0000000..572fcb3 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Menu.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 841589fc622bc494aa5405f416fa1301 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Fungus/Scripts/Commands/MenuShuffle.cs b/Assets/Fungus/Scripts/Commands/MenuShuffle.cs new file mode 100644 index 0000000..f198318 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/MenuShuffle.cs @@ -0,0 +1,59 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; +using UnityEngine.Serialization; +using System.Collections.Generic; + +namespace Fungus +{ + /// + /// Shuffle the order of the items in a Fungus Menu + /// + [CommandInfo("Narrative", + "Menu Shuffle", + "Shuffle the order of the items in a Fungus Menu")] + [AddComponentMenu("")] + [ExecuteInEditMode] + public class MenuShuffle : Command + { + public enum Mode + { + Every, + Once + } + [SerializeField] + [Tooltip("Determines if the order is shuffled everytime this command is it (Every) or if it is consistent when returned to but random (Once)")] + protected Mode shuffleMode = Mode.Once; + + private int seed = -1; + + public override void OnEnter() + { + var menuDialog = MenuDialog.GetMenuDialog(); + + //if we shuffle every time or we haven't shuffled yet + if(shuffleMode == Mode.Every || seed == -1) + { + seed = Random.Range(0,1000000); + } + + if (menuDialog != null) + { + menuDialog.Shuffle(new System.Random(seed)); + } + + Continue(); + } + + public override string GetSummary() + { + return shuffleMode.ToString(); + } + + public override Color GetButtonColor() + { + return new Color32(184, 210, 235, 255); + } + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/MenuShuffle.cs.meta b/Assets/Fungus/Scripts/Commands/MenuShuffle.cs.meta new file mode 100644 index 0000000..7e4ba73 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/MenuShuffle.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 4d88125c88dab4a44851835e94ff4d90 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Fungus/Scripts/Commands/MenuTimer.cs b/Assets/Fungus/Scripts/Commands/MenuTimer.cs new file mode 100644 index 0000000..a8542c9 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/MenuTimer.cs @@ -0,0 +1,93 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; +using UnityEngine.Serialization; +using System.Collections.Generic; + +namespace Fungus +{ + /// + /// Displays a timer bar and executes a target block if the player fails to select a menu option in time. + /// + [CommandInfo("Narrative", + "Menu Timer", + "Displays a timer bar and executes a target block if the player fails to select a menu option in time.")] + [AddComponentMenu("")] + [ExecuteInEditMode] + public class MenuTimer : Command, IBlockCaller + { + [Tooltip("Length of time to display the timer for")] + [SerializeField] protected FloatData _duration = new FloatData(1); + + [FormerlySerializedAs("targetSequence")] + [Tooltip("Block to execute when the timer expires")] + [SerializeField] protected Block targetBlock; + + #region Public members + + public override void OnEnter() + { + var menuDialog = MenuDialog.GetMenuDialog(); + + if (menuDialog != null && + targetBlock != null) + { + menuDialog.ShowTimer(_duration.Value, targetBlock); + } + + Continue(); + } + + public override void GetConnectedBlocks(ref List connectedBlocks) + { + if (targetBlock != null) + { + connectedBlocks.Add(targetBlock); + } + } + + public override string GetSummary() + { + if (targetBlock == null) + { + return "Error: No target block selected"; + } + + return targetBlock.BlockName; + } + + public override Color GetButtonColor() + { + return new Color32(184, 210, 235, 255); + } + + public override bool HasReference(Variable variable) + { + return _duration.floatRef == variable || + base.HasReference(variable); + } + + public bool MayCallBlock(Block block) + { + return block == targetBlock; + } + + #endregion + + #region Backwards compatibility + + [HideInInspector] [FormerlySerializedAs("duration")] public float durationOLD; + + protected virtual void OnEnable() + { + if (durationOLD != default(float)) + { + _duration.Value = durationOLD; + durationOLD = default(float); + } + } + + #endregion + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/MenuTimer.cs.meta b/Assets/Fungus/Scripts/Commands/MenuTimer.cs.meta new file mode 100644 index 0000000..31d25c1 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/MenuTimer.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: ab54728d981544842843ba6609b9a80a +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Fungus/Scripts/Commands/MoveAdd.cs b/Assets/Fungus/Scripts/Commands/MoveAdd.cs new file mode 100644 index 0000000..cabb8b3 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/MoveAdd.cs @@ -0,0 +1,68 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; +using UnityEngine.Serialization; +using System.Collections; + +namespace Fungus +{ + /// + /// Moves a game object by a specified offset over time. + /// + [CommandInfo("iTween", + "Move Add", + "Moves a game object by a specified offset over time.")] + [AddComponentMenu("")] + [ExecuteInEditMode] + public class MoveAdd : iTweenCommand + { + [Tooltip("A translation offset in space the GameObject will animate to")] + [SerializeField] protected Vector3Data _offset; + + [Tooltip("Apply the transformation in either the world coordinate or local cordinate system")] + [SerializeField] protected Space space = Space.Self; + + #region Public members + + public override void DoTween() + { + Hashtable tweenParams = new Hashtable(); + tweenParams.Add("name", _tweenName.Value); + tweenParams.Add("amount", _offset.Value); + tweenParams.Add("space", space); + tweenParams.Add("time", _duration.Value); + tweenParams.Add("easetype", easeType); + tweenParams.Add("looptype", loopType); + tweenParams.Add("oncomplete", "OniTweenComplete"); + tweenParams.Add("oncompletetarget", gameObject); + tweenParams.Add("oncompleteparams", this); + iTween.MoveAdd(_targetObject.Value, tweenParams); + } + + public override bool HasReference(Variable variable) + { + return _offset.vector3Ref == variable || + base.HasReference(variable); + } + + #endregion + + #region Backwards compatibility + + [HideInInspector] [FormerlySerializedAs("offset")] public Vector3 offsetOLD; + + protected override void OnEnable() + { + base.OnEnable(); + + if (offsetOLD != default(Vector3)) + { + _offset.Value = offsetOLD; + offsetOLD = default(Vector3); + } + } + + #endregion + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/MoveAdd.cs.meta b/Assets/Fungus/Scripts/Commands/MoveAdd.cs.meta new file mode 100644 index 0000000..5c940fd --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/MoveAdd.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 598f181ee459641a9b0a5849fbc3240c +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Fungus/Scripts/Commands/MoveFrom.cs b/Assets/Fungus/Scripts/Commands/MoveFrom.cs new file mode 100644 index 0000000..a645302 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/MoveFrom.cs @@ -0,0 +1,85 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; +using UnityEngine.Serialization; +using System.Collections; + +namespace Fungus +{ + /// + /// Moves a game object from a specified position back to its starting position over time. The position can be defined by a transform in another object (using To Transform) or by setting an absolute position (using To Position, if To Transform is set to None). + /// + [CommandInfo("iTween", + "Move From", + "Moves a game object from a specified position back to its starting position over time. The position can be defined by a transform in another object (using To Transform) or by setting an absolute position (using To Position, if To Transform is set to None).")] + [AddComponentMenu("")] + [ExecuteInEditMode] + public class MoveFrom : iTweenCommand + { + [Tooltip("Target transform that the GameObject will move from")] + [SerializeField] protected TransformData _fromTransform; + + [Tooltip("Target world position that the GameObject will move from, if no From Transform is set")] + [SerializeField] protected Vector3Data _fromPosition; + + [Tooltip("Whether to animate in world space or relative to the parent. False by default.")] + [SerializeField] protected bool isLocal; + + #region Public members + + public override void DoTween() + { + Hashtable tweenParams = new Hashtable(); + tweenParams.Add("name", _tweenName.Value); + if (_fromTransform.Value == null) + { + tweenParams.Add("position", _fromPosition.Value); + } + else + { + tweenParams.Add("position", _fromTransform.Value); + } + tweenParams.Add("time", _duration.Value); + tweenParams.Add("easetype", easeType); + tweenParams.Add("looptype", loopType); + tweenParams.Add("isLocal", isLocal); + tweenParams.Add("oncomplete", "OniTweenComplete"); + tweenParams.Add("oncompletetarget", gameObject); + tweenParams.Add("oncompleteparams", this); + iTween.MoveFrom(_targetObject.Value, tweenParams); + } + + public override bool HasReference(Variable variable) + { + return _fromTransform.transformRef == variable || _fromPosition.vector3Ref == variable || + base.HasReference(variable); + } + + #endregion + + #region Backwards compatibility + + [HideInInspector] [FormerlySerializedAs("fromTransform")] public Transform fromTransformOLD; + [HideInInspector] [FormerlySerializedAs("fromPosition")] public Vector3 fromPositionOLD; + + protected override void OnEnable() + { + base.OnEnable(); + + if (fromTransformOLD != null) + { + _fromTransform.Value = fromTransformOLD; + fromTransformOLD = null; + } + + if (fromPositionOLD != default(Vector3)) + { + _fromPosition.Value = fromPositionOLD; + fromPositionOLD = default(Vector3); + } + } + + #endregion + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/MoveFrom.cs.meta b/Assets/Fungus/Scripts/Commands/MoveFrom.cs.meta new file mode 100644 index 0000000..f25b007 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/MoveFrom.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: d5ca001b90bd14834b7268b48a44c6de +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Fungus/Scripts/Commands/MoveTo.cs b/Assets/Fungus/Scripts/Commands/MoveTo.cs new file mode 100644 index 0000000..80a6a7a --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/MoveTo.cs @@ -0,0 +1,85 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; +using UnityEngine.Serialization; +using System.Collections; + +namespace Fungus +{ + /// + /// Moves a game object to a specified position over time. The position can be defined by a transform in another object (using To Transform) or by setting an absolute position (using To Position, if To Transform is set to None). + /// + [CommandInfo("iTween", + "Move To", + "Moves a game object to a specified position over time. The position can be defined by a transform in another object (using To Transform) or by setting an absolute position (using To Position, if To Transform is set to None).")] + [AddComponentMenu("")] + [ExecuteInEditMode] + public class MoveTo : iTweenCommand + { + [Tooltip("Target transform that the GameObject will move to")] + [SerializeField] protected TransformData _toTransform; + + [Tooltip("Target world position that the GameObject will move to, if no From Transform is set")] + [SerializeField] protected Vector3Data _toPosition; + + [Tooltip("Whether to animate in world space or relative to the parent. False by default.")] + [SerializeField] protected bool isLocal; + + #region Public members + + public override void DoTween() + { + Hashtable tweenParams = new Hashtable(); + tweenParams.Add("name", _tweenName.Value); + if (_toTransform.Value == null) + { + tweenParams.Add("position", _toPosition.Value); + } + else + { + tweenParams.Add("position", _toTransform.Value); + } + tweenParams.Add("time", _duration.Value); + tweenParams.Add("easetype", easeType); + tweenParams.Add("looptype", loopType); + tweenParams.Add("isLocal", isLocal); + tweenParams.Add("oncomplete", "OniTweenComplete"); + tweenParams.Add("oncompletetarget", gameObject); + tweenParams.Add("oncompleteparams", this); + iTween.MoveTo(_targetObject.Value, tweenParams); + } + + public override bool HasReference(Variable variable) + { + return _toTransform.transformRef == variable || _toPosition.vector3Ref == variable || + base.HasReference(variable); + } + + #endregion + + #region Backwards compatibility + + [HideInInspector] [FormerlySerializedAs("toTransform")] public Transform toTransformOLD; + [HideInInspector] [FormerlySerializedAs("toPosition")] public Vector3 toPositionOLD; + + protected override void OnEnable() + { + base.OnEnable(); + + if (toTransformOLD != null) + { + _toTransform.Value = toTransformOLD; + toTransformOLD = null; + } + + if (toPositionOLD != default(Vector3)) + { + _toPosition.Value = toPositionOLD; + toPositionOLD = default(Vector3); + } + } + + #endregion + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/MoveTo.cs.meta b/Assets/Fungus/Scripts/Commands/MoveTo.cs.meta new file mode 100644 index 0000000..26c5f7d --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/MoveTo.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 445c07472dafe4e0ead0e88c4b757401 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Fungus/Scripts/Commands/MoveToView.cs b/Assets/Fungus/Scripts/Commands/MoveToView.cs new file mode 100644 index 0000000..19bf5c2 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/MoveToView.cs @@ -0,0 +1,110 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; + +namespace Fungus +{ + /// + /// Moves the camera to a location specified by a View object. + /// + [CommandInfo("Camera", + "Move To View", + "Moves the camera to a location specified by a View object.")] + [AddComponentMenu("")] + public class MoveToView : Command + { + [Tooltip("Time for move effect to complete")] + [SerializeField] protected float duration = 1; + + [Tooltip("View to transition to when move is complete")] + [SerializeField] protected View targetView; + public virtual View TargetView { get { return targetView; } } + + [Tooltip("Wait until the fade has finished before executing next command")] + [SerializeField] protected bool waitUntilFinished = true; + + [Tooltip("Camera to use for the pan. Will use main camera if set to none.")] + [SerializeField] protected Camera targetCamera; + + [SerializeField] protected LeanTweenType orthoSizeTweenType = LeanTweenType.easeInOutQuad; + [SerializeField] protected LeanTweenType posTweenType = LeanTweenType.easeInOutQuad; + [SerializeField] protected LeanTweenType rotTweenType = LeanTweenType.easeInOutQuad; + + protected virtual void AcquireCamera() + { + if (targetCamera != null) + { + return; + } + + targetCamera = Camera.main; + if (targetCamera == null) + { + targetCamera = GameObject.FindObjectOfType(); + } + } + + public virtual void Start() + { + AcquireCamera(); + } + + #region Public members + + public override void OnEnter() + { + AcquireCamera(); + if (targetCamera == null || + targetView == null) + { + Continue(); + return; + } + + var cameraManager = FungusManager.Instance.CameraManager; + + Vector3 targetPosition = targetView.transform.position; + Quaternion targetRotation = targetView.transform.rotation; + float targetSize = targetView.ViewSize; + + cameraManager.PanToPosition(targetCamera, targetPosition, targetRotation, targetSize, duration, delegate { + if (waitUntilFinished) + { + Continue(); + } + }, orthoSizeTweenType, posTweenType, rotTweenType); + + if (!waitUntilFinished) + { + Continue(); + } + } + + public override void OnStopExecuting() + { + var cameraManager = FungusManager.Instance.CameraManager; + + cameraManager.Stop(); + } + + public override string GetSummary() + { + if (targetView == null) + { + return "Error: No view selected"; + } + else + { + return targetView.name; + } + } + + public override Color GetButtonColor() + { + return new Color32(216, 228, 170, 255); + } + + #endregion + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/MoveToView.cs.meta b/Assets/Fungus/Scripts/Commands/MoveToView.cs.meta new file mode 100644 index 0000000..22315d0 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/MoveToView.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 45c952ea1ad444e479b570fa242679c5 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Fungus/Scripts/Commands/OpenURL.cs b/Assets/Fungus/Scripts/Commands/OpenURL.cs new file mode 100644 index 0000000..b7190e3 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/OpenURL.cs @@ -0,0 +1,46 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; +using Fungus; + +namespace Fungus +{ + /// + /// Opens the specified URL in the browser. + /// + [CommandInfo("Scripting", + "Open URL", + "Opens the specified URL in the browser.")] + public class OpenURL : Command + { + [Tooltip("URL to open in the browser")] + [SerializeField] protected StringData url = new StringData(); + + #region Public members + + public override void OnEnter() + { + Application.OpenURL(url.Value); + + Continue(); + } + + public override string GetSummary() + { + return url.Value; + } + + public override Color GetButtonColor() + { + return new Color32(235, 191, 217, 255); + } + + public override bool HasReference(Variable variable) + { + return url.stringRef == variable || base.HasReference(variable); + } + + #endregion + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/OpenURL.cs.meta b/Assets/Fungus/Scripts/Commands/OpenURL.cs.meta new file mode 100644 index 0000000..5829198 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/OpenURL.cs.meta @@ -0,0 +1,12 @@ +fileFormatVersion: 2 +guid: 1447088810b484e0a9cf0237b2e96b82 +timeCreated: 1456439090 +licenseType: Store +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/PlayAmbianceSound.cs b/Assets/Fungus/Scripts/Commands/PlayAmbianceSound.cs new file mode 100644 index 0000000..7f3b5e6 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/PlayAmbianceSound.cs @@ -0,0 +1,69 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; + +namespace Fungus +{ + /// + /// Plays a once-off sound effect. Multiple sound effects can be played at the same time. + /// + [CommandInfo("Audio", + "Play Ambiance Sound", + "Plays a background sound to be overlayed on top of the music. Only one Ambiance can be played at a time.")] + [AddComponentMenu("")] + public class PlayAmbianceSound : Command + { + [Tooltip("Sound effect clip to play")] + [SerializeField] + protected AudioClip soundClip; + + [Range(0, 1)] + [Tooltip("Volume level of the sound effect")] + [SerializeField] + protected float volume = 1; + + [Tooltip("Sound effect clip to play")] + [SerializeField] + protected bool loop; + + protected virtual void DoWait() + { + Continue(); + } + + #region Public members + + public override void OnEnter() + { + if (soundClip == null) + { + Continue(); + return; + } + + var musicManager = FungusManager.Instance.MusicManager; + + musicManager.PlayAmbianceSound(soundClip, loop, volume); + + Continue(); + } + + public override string GetSummary() + { + if (soundClip == null) + { + return "Error: No sound clip selected"; + } + + return soundClip.name; + } + + public override Color GetButtonColor() + { + return new Color32(242, 209, 176, 255); + } + + #endregion + } +} diff --git a/Assets/Fungus/Scripts/Commands/PlayAmbianceSound.cs.meta b/Assets/Fungus/Scripts/Commands/PlayAmbianceSound.cs.meta new file mode 100644 index 0000000..6465ec8 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/PlayAmbianceSound.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 831c208af3cccf24b80cc6f3768919bc +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/PlayAnimState.cs b/Assets/Fungus/Scripts/Commands/PlayAnimState.cs new file mode 100644 index 0000000..a94472d --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/PlayAnimState.cs @@ -0,0 +1,66 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; + +namespace Fungus +{ + /// + /// Plays a state of an animator according to the state name. + /// + [CommandInfo("Animation", + "Play Anim State", + "Plays a state of an animator according to the state name")] + [AddComponentMenu("")] + public class PlayAnimState : Command + { + [Tooltip("Reference to an Animator component in a game object")] + [SerializeField] protected AnimatorData animator = new AnimatorData(); + + [Tooltip("Name of the state you want to play")] + [SerializeField] protected StringData stateName = new StringData(); + + [Tooltip("Layer to play animation on")] + [SerializeField] protected IntegerData layer = new IntegerData(-1); + + [Tooltip("Start time of animation")] + [SerializeField] protected FloatData time = new FloatData(0f); + + #region Public members + + public override void OnEnter() + { + if (animator.Value != null) + { + animator.Value.Play(stateName.Value, layer.Value, time.Value); + } + + Continue(); + } + + public override string GetSummary() + { + if (animator.Value == null) + { + return "Error: No animator selected"; + } + + return animator.Value.name + " (" + stateName.Value + ")"; + } + + public override Color GetButtonColor() + { + return new Color32(170, 204, 169, 255); + } + + public override bool HasReference(Variable variable) + { + return animator.animatorRef == variable || stateName.stringRef == variable || + layer.integerRef == variable || time.floatRef == variable || + base.HasReference(variable); + } + + #endregion + } +} + diff --git a/Assets/Fungus/Scripts/Commands/PlayAnimState.cs.meta b/Assets/Fungus/Scripts/Commands/PlayAnimState.cs.meta new file mode 100644 index 0000000..0ffbbb9 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/PlayAnimState.cs.meta @@ -0,0 +1,12 @@ +fileFormatVersion: 2 +guid: 5316d953c7abe498799575550c973535 +timeCreated: 1458814204 +licenseType: Store +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/PlayMusic.cs b/Assets/Fungus/Scripts/Commands/PlayMusic.cs new file mode 100644 index 0000000..806c64d --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/PlayMusic.cs @@ -0,0 +1,58 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; + +namespace Fungus +{ + /// + /// Plays looping game music. If any game music is already playing, it is stopped. Game music will continue playing across scene loads. + /// + [CommandInfo("Audio", + "Play Music", + "Plays looping game music. If any game music is already playing, it is stopped. Game music will continue playing across scene loads.")] + [AddComponentMenu("")] + public class PlayMusic : Command + { + [Tooltip("Music sound clip to play")] + [SerializeField] protected AudioClip musicClip; + + [Tooltip("Time to begin playing in seconds. If the audio file is compressed, the time index may be inaccurate.")] + [SerializeField] protected float atTime; + + [Tooltip("The music will start playing again at end.")] + [SerializeField] protected bool loop = true; + + [Tooltip("Length of time to fade out previous playing music.")] + [SerializeField] protected float fadeDuration = 1f; + + #region Public members + + public override void OnEnter() + { + var musicManager = FungusManager.Instance.MusicManager; + + float startTime = Mathf.Max(0, atTime); + musicManager.PlayMusic(musicClip, loop, fadeDuration, startTime); + + Continue(); + } + + public override string GetSummary() + { + if (musicClip == null) + { + return "Error: No music clip selected"; + } + + return musicClip.name; + } + + public override Color GetButtonColor() + { + return new Color32(242, 209, 176, 255); + } + + #endregion + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/PlayMusic.cs.meta b/Assets/Fungus/Scripts/Commands/PlayMusic.cs.meta new file mode 100644 index 0000000..d8381fe --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/PlayMusic.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 1902400ccc99b45d69ad01cb86b57d0f +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Fungus/Scripts/Commands/PlayRandomSound.cs b/Assets/Fungus/Scripts/Commands/PlayRandomSound.cs new file mode 100644 index 0000000..7eb7c63 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/PlayRandomSound.cs @@ -0,0 +1,84 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; + +namespace Fungus +{ + /// + /// Plays a once-off sound effect. Multiple sound effects can be played at the same time. + /// + [CommandInfo("Audio", + "Play Random Sound", + "Plays a once-off sound effect from a list of available sound effects. Multiple sound effects can be played at the same time.")] + [AddComponentMenu("")] + public class PlayRandomSound : Command + { + [Tooltip("Sound effect clip to play")] + [SerializeField] + protected AudioClip[] soundClip; + + [Range(0, 1)] + [Tooltip("Volume level of the sound effect")] + [SerializeField] + protected float volume = 1; + + [Tooltip("Wait until the sound has finished playing before continuing execution.")] + [SerializeField] + protected bool waitUntilFinished; + + protected virtual void DoWait() + { + Continue(); + } + + #region Public members + + public override void OnEnter() + { + int rand = Random.Range(0, soundClip.Length); + if (soundClip == null) + { + Continue(); + return; + } + + var musicManager = FungusManager.Instance.MusicManager; + + musicManager.PlaySound(soundClip[rand], volume); + + if (waitUntilFinished) + { + Invoke("DoWait", soundClip[rand].length); + } + else + { + Continue(); + } + } + + public override string GetSummary() + { + if (soundClip == null) + { + return "Error: No sound clip selected"; + } + + string sounds = "["; + foreach (AudioClip ac in soundClip) { + if(ac!=null) + sounds+=ac.name+" ,"; + } + sounds = sounds.TrimEnd(' ', ','); + sounds += "]"; + return "Random sounds "+sounds; + } + + public override Color GetButtonColor() + { + return new Color32(242, 209, 176, 255); + } + + #endregion + } +} diff --git a/Assets/Fungus/Scripts/Commands/PlayRandomSound.cs.meta b/Assets/Fungus/Scripts/Commands/PlayRandomSound.cs.meta new file mode 100644 index 0000000..a5c778b --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/PlayRandomSound.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 04659f7200983fe40b49cc144086844b +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/PlaySound.cs b/Assets/Fungus/Scripts/Commands/PlaySound.cs new file mode 100644 index 0000000..c560785 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/PlaySound.cs @@ -0,0 +1,73 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; + +namespace Fungus +{ + /// + /// Plays a once-off sound effect. Multiple sound effects can be played at the same time. + /// + [CommandInfo("Audio", + "Play Sound", + "Plays a once-off sound effect. Multiple sound effects can be played at the same time.")] + [AddComponentMenu("")] + public class PlaySound : Command + { + [Tooltip("Sound effect clip to play")] + [SerializeField] protected AudioClip soundClip; + + [Range(0,1)] + [Tooltip("Volume level of the sound effect")] + [SerializeField] protected float volume = 1; + + [Tooltip("Wait until the sound has finished playing before continuing execution.")] + [SerializeField] protected bool waitUntilFinished; + + protected virtual void DoWait() + { + Continue(); + } + + #region Public members + + public override void OnEnter() + { + if (soundClip == null) + { + Continue(); + return; + } + + var musicManager = FungusManager.Instance.MusicManager; + + musicManager.PlaySound(soundClip, volume); + + if (waitUntilFinished) + { + Invoke("DoWait", soundClip.length); + } + else + { + Continue(); + } + } + + public override string GetSummary() + { + if (soundClip == null) + { + return "Error: No sound clip selected"; + } + + return soundClip.name; + } + + public override Color GetButtonColor() + { + return new Color32(242, 209, 176, 255); + } + + #endregion + } +} diff --git a/Assets/Fungus/Scripts/Commands/PlaySound.cs.meta b/Assets/Fungus/Scripts/Commands/PlaySound.cs.meta new file mode 100644 index 0000000..7070dcd --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/PlaySound.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: bd2f6be51b3d7490ba5633ee095d0391 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Fungus/Scripts/Commands/PlayUsfxrSound.cs b/Assets/Fungus/Scripts/Commands/PlayUsfxrSound.cs new file mode 100644 index 0000000..7436071 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/PlayUsfxrSound.cs @@ -0,0 +1,114 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using System; +using UnityEngine; +using UnityEngine.Serialization; + +namespace Fungus +{ + /// + /// Plays a usfxr synth sound. Use the usfxr editor [Tools > Fungus > Utilities > Generate usfxr Sound Effects] to create the SettingsString. Set a ParentTransform if using positional sound. See https://github.com/zeh/usfxr for more information about usfxr. + /// + [CommandInfo("Audio", + "Play Usfxr Sound", + "Plays a usfxr synth sound. Use the usfxr editor [Tools > Fungus > Utilities > Generate usfxr Sound Effects] to create the SettingsString. Set a ParentTransform if using positional sound. See https://github.com/zeh/usfxr for more information about usfxr.")] + [AddComponentMenu("")] + //[ExecuteInEditMode] + public class PlayUsfxrSound : Command + { + [Tooltip("Transform to use for positional audio")] + [SerializeField] protected Transform ParentTransform = null; + + [Tooltip("Settings string which describes the audio")] + [SerializeField] protected StringDataMulti _SettingsString = new StringDataMulti(""); + + [Tooltip("Time to wait before executing the next command")] + [SerializeField] protected float waitDuration = 0; + + protected SfxrSynth _synth = new SfxrSynth(); + + //Call this if the settings have changed + protected virtual void UpdateCache() + { + if (!string.IsNullOrEmpty(_SettingsString.Value)) + { + _synth.parameters.SetSettingsString(_SettingsString.Value); + _synth.CacheSound(); + } + } + + protected virtual void Awake() + { + //Always build the cache on awake + UpdateCache(); + } + + protected void DoWait() + { + Continue(); + } + + #region Public members + + public override void OnEnter() + { + _synth.SetParentTransform(ParentTransform); + _synth.Play(); + if (Mathf.Approximately(waitDuration, 0f)) + { + Continue(); + } + else + { + Invoke ("DoWait", waitDuration); + } + } + + public override string GetSummary() + { + if (String.IsNullOrEmpty(_SettingsString.Value)) + { + return "Settings String hasn't been set!"; + } + if (ParentTransform != null) + { + return "" + ParentTransform.name + ": " + _SettingsString.Value; + } + return "Camera.main: " + _SettingsString.Value; + } + + public override Color GetButtonColor() + { + return new Color32(128, 200, 200, 255); + } + + public override bool HasReference(Variable variable) + { + return variable == _SettingsString.stringRef; + } + + #endregion + + #region Backwards compatibility + + [HideInInspector] [FormerlySerializedAs("SettingsString")] public String SettingsStringOLD = ""; + + protected virtual void OnEnable() + { + if (SettingsStringOLD != "") + { + _SettingsString.Value = SettingsStringOLD; + SettingsStringOLD = ""; + } + } + + public override void OnValidate() + { + OnEnable(); + base.OnValidate(); + } + + #endregion + } +} diff --git a/Assets/Fungus/Scripts/Commands/PlayUsfxrSound.cs.meta b/Assets/Fungus/Scripts/Commands/PlayUsfxrSound.cs.meta new file mode 100644 index 0000000..d999fa8 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/PlayUsfxrSound.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: a3ff412ad89846a47a70a620a222cbf8 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Fungus/Scripts/Commands/Portrait.cs b/Assets/Fungus/Scripts/Commands/Portrait.cs new file mode 100644 index 0000000..0b3b1af --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Portrait.cs @@ -0,0 +1,260 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; + +namespace Fungus +{ + /// + /// Controls a character portrait. + /// + [CommandInfo("Narrative", + "Portrait", + "Controls a character portrait.")] + public class Portrait : ControlWithDisplay + { + [Tooltip("Stage to display portrait on")] + [SerializeField] protected Stage stage; + + [Tooltip("Character to display")] + [SerializeField] protected Character character; + + [Tooltip("Character to swap with")] + [SerializeField] protected Character replacedCharacter; + + [Tooltip("Portrait to display")] + [SerializeField] protected Sprite portrait; + + [Tooltip("Move the portrait from/to this offset position")] + [SerializeField] protected PositionOffset offset; + + [Tooltip("Move the portrait from this position")] + [SerializeField] protected RectTransform fromPosition; + + [Tooltip("Move the portrait to this position")] + [SerializeField] protected RectTransform toPosition; + + [Tooltip("Direction character is facing")] + [SerializeField] protected FacingDirection facing; + + [Tooltip("Use Default Settings")] + [SerializeField] protected bool useDefaultSettings = true; + + [Tooltip("Fade Duration")] + [SerializeField] protected float fadeDuration = 0.5f; + + [Tooltip("Movement Duration")] + [SerializeField] protected float moveDuration = 1f; + + [Tooltip("Shift Offset")] + [SerializeField] protected Vector2 shiftOffset; + + [Tooltip("Move portrait into new position")] + [SerializeField] protected bool move; + + [Tooltip("Start from offset position")] + [SerializeField] protected bool shiftIntoPlace; + + [Tooltip("Wait until the tween has finished before executing the next command")] + [SerializeField] protected bool waitUntilFinished = false; + + #region Public members + + /// + /// Stage to display portrait on. + /// + public virtual Stage _Stage { get { return stage; } set { stage = value; } } + + /// + /// Character to display. + /// + public virtual Character _Character { get { return character; } set { character = value; } } + + /// + /// Portrait to display. + /// + public virtual Sprite _Portrait { get { return portrait; } set { portrait = value; } } + + /// + /// Move the portrait from/to this offset position. + /// + public virtual PositionOffset Offset { get { return offset; } set { offset = value; } } + + /// + /// Move the portrait from this position. + /// + public virtual RectTransform FromPosition { get { return fromPosition; } set { fromPosition = value;} } + + /// + /// Move the portrait to this position. + /// + public virtual RectTransform ToPosition { get { return toPosition; } set { toPosition = value;} } + + /// + /// Direction character is facing. + /// + public virtual FacingDirection Facing { get { return facing; } set { facing = value; } } + + /// + /// Use Default Settings. + /// + public virtual bool UseDefaultSettings { get { return useDefaultSettings; } set { useDefaultSettings = value; } } + + /// + /// Move portrait into new position. + /// + public virtual bool Move { get { return move; } set { move = value; } } + + /// + /// Start from offset position. + /// + public virtual bool ShiftIntoPlace { get { return shiftIntoPlace; } set { shiftIntoPlace = value; } } + + public override void OnEnter() + { + // Selected "use default Portrait Stage" + if (stage == null) + { + // If no default specified, try to get any portrait stage in the scene + stage = Stage.GetActiveStage(); + // If portrait stage does not exist, do nothing + if (stage == null) + { + Continue(); + return; + } + + } + + // If no display specified, do nothing + if (IsDisplayNone(display)) + { + Continue(); + return; + } + + PortraitOptions options = new PortraitOptions(); + + options.character = character; + options.replacedCharacter = replacedCharacter; + options.portrait = portrait; + options.display = display; + options.offset = offset; + options.fromPosition = fromPosition; + options.toPosition = toPosition; + options.facing = facing; + options.useDefaultSettings = useDefaultSettings; + options.fadeDuration = fadeDuration; + options.moveDuration = moveDuration; + options.shiftOffset = shiftOffset; + options.move = move; + options.shiftIntoPlace = shiftIntoPlace; + options.waitUntilFinished = waitUntilFinished; + + stage.RunPortraitCommand(options, Continue); + + } + + public override string GetSummary() + { + if (display == DisplayType.None && character == null) + { + return "Error: No character or display selected"; + } + else if (display == DisplayType.None) + { + return "Error: No display selected"; + } + else if (character == null) + { + return "Error: No character selected"; + } + + string displaySummary = ""; + string characterSummary = ""; + string fromPositionSummary = ""; + string toPositionSummary = ""; + string stageSummary = ""; + string portraitSummary = ""; + string facingSummary = ""; + + displaySummary = StringFormatter.SplitCamelCase(display.ToString()); + + if (display == DisplayType.Replace) + { + if (replacedCharacter != null) + { + displaySummary += " \"" + replacedCharacter.name + "\" with"; + } + } + + characterSummary = character.name; + if (stage != null) + { + stageSummary = " on \"" + stage.name + "\""; + } + + if (portrait != null) + { + portraitSummary = " " + portrait.name; + } + + if (shiftIntoPlace) + { + if (offset != 0) + { + fromPositionSummary = offset.ToString(); + fromPositionSummary = " from " + "\"" + fromPositionSummary + "\""; + } + } + else if (fromPosition != null) + { + fromPositionSummary = " from " + "\"" + fromPosition.name + "\""; + } + + if (toPosition != null) + { + string toPositionPrefixSummary = ""; + if (move) + { + toPositionPrefixSummary = " to "; + } + else + { + toPositionPrefixSummary = " at "; + } + + toPositionSummary = toPositionPrefixSummary + "\"" + toPosition.name + "\""; + } + + if (facing != FacingDirection.None) + { + if (facing == FacingDirection.Left) + { + facingSummary = "<--"; + } + if (facing == FacingDirection.Right) + { + facingSummary = "-->"; + } + + facingSummary = " facing \"" + facingSummary + "\""; + } + + return displaySummary + " \"" + characterSummary + portraitSummary + "\"" + stageSummary + facingSummary + fromPositionSummary + toPositionSummary; + } + + public override Color GetButtonColor() + { + return new Color32(230, 200, 250, 255); + } + + public override void OnCommandAdded(Block parentBlock) + { + //Default to display type: show + display = DisplayType.Show; + } + + #endregion + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/Portrait.cs.meta b/Assets/Fungus/Scripts/Commands/Portrait.cs.meta new file mode 100644 index 0000000..515ec46 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Portrait.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 3ac5ce55bc698fa4290939ef6e426501 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Fungus/Scripts/Commands/Priority.meta b/Assets/Fungus/Scripts/Commands/Priority.meta new file mode 100644 index 0000000..68da95c --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Priority.meta @@ -0,0 +1,10 @@ +fileFormatVersion: 2 +guid: 61d2004f0aa3f1847beb167296c897d8 +folderAsset: yes +timeCreated: 1523180219 +licenseType: Store +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/Priority/FungusPriorityCount.cs b/Assets/Fungus/Scripts/Commands/Priority/FungusPriorityCount.cs new file mode 100644 index 0000000..eaf6dfd --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Priority/FungusPriorityCount.cs @@ -0,0 +1,42 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using System.Collections; +using System.Collections.Generic; +using UnityEngine; + +namespace Fungus +{ + /// + /// Copy the value of the Priority Count to a local IntegerVariable, intended primarily to assist with debugging use of Priority. + /// + [CommandInfo("PrioritySignals", + "Get Priority Count", + "Copy the value of the Priority Count to a local IntegerVariable, intended primarily to assist with debugging use of Priority.")] + public class FungusPriorityCount : Command + { + [VariableProperty(typeof(IntegerVariable))] + public IntegerVariable outVar; + + public override void OnEnter() + { + outVar.Value = FungusPrioritySignals.CurrentPriorityDepth; + + Continue(); + } + + public override string GetSummary() + { + if(outVar == null) + { + return "Error: No out var supplied"; + } + return outVar.Key; + } + + public override bool HasReference(Variable variable) + { + return outVar == variable; + } + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/Priority/FungusPriorityCount.cs.meta b/Assets/Fungus/Scripts/Commands/Priority/FungusPriorityCount.cs.meta new file mode 100644 index 0000000..e24addb --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Priority/FungusPriorityCount.cs.meta @@ -0,0 +1,13 @@ +fileFormatVersion: 2 +guid: a3aeb6a9bd739484080e7965ecaab89e +timeCreated: 1523926493 +licenseType: Store +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/Priority/FungusPriorityDecrease.cs b/Assets/Fungus/Scripts/Commands/Priority/FungusPriorityDecrease.cs new file mode 100644 index 0000000..43ddea3 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Priority/FungusPriorityDecrease.cs @@ -0,0 +1,27 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using System.Collections; +using System.Collections.Generic; +using UnityEngine; + +namespace Fungus +{ + /// + /// Decrease the FungusPriority count, causing the related FungusPrioritySignals to fire. + /// Intended to be used to notify external systems that fungus is doing something important and they should perhaps resume. + /// + [CommandInfo("PrioritySignals", + "Priority Down", + "Decrease the FungusPriority count, causing the related FungusPrioritySignals to fire. " + + "Intended to be used to notify external systems that fungus is doing something important and they should perhaps resume.")] + public class FungusPriorityDecrease : Command + { + public override void OnEnter() + { + FungusPrioritySignals.DoDecreasePriorityDepth(); + + Continue(); + } + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/Priority/FungusPriorityDecrease.cs.meta b/Assets/Fungus/Scripts/Commands/Priority/FungusPriorityDecrease.cs.meta new file mode 100644 index 0000000..793f6fc --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Priority/FungusPriorityDecrease.cs.meta @@ -0,0 +1,13 @@ +fileFormatVersion: 2 +guid: ebc295ba6aed8944fa3974a64f33cc42 +timeCreated: 1523926493 +licenseType: Store +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/Priority/FungusPriorityIncrease.cs b/Assets/Fungus/Scripts/Commands/Priority/FungusPriorityIncrease.cs new file mode 100644 index 0000000..0be68bf --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Priority/FungusPriorityIncrease.cs @@ -0,0 +1,27 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using System.Collections; +using System.Collections.Generic; +using UnityEngine; + +namespace Fungus +{ + /// + /// Increases the FungusPriority count, causing the related FungusPrioritySignals to fire. + /// Intended to be used to notify external systems that fungus is doing something important and they should perhaps pause. + /// + [CommandInfo("PrioritySignals", + "Priority Up", + "Increases the FungusPriority count, causing the related FungusPrioritySignals to fire. " + + "Intended to be used to notify external systems that fungus is doing something important and they should perhaps pause.")] + public class FungusPriorityIncrease : Command + { + public override void OnEnter() + { + FungusPrioritySignals.DoIncreasePriorityDepth(); + + Continue(); + } + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/Priority/FungusPriorityIncrease.cs.meta b/Assets/Fungus/Scripts/Commands/Priority/FungusPriorityIncrease.cs.meta new file mode 100644 index 0000000..71d0f43 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Priority/FungusPriorityIncrease.cs.meta @@ -0,0 +1,13 @@ +fileFormatVersion: 2 +guid: 3d07cf5e706b13a4eb0ae53386c30fbd +timeCreated: 1523926493 +licenseType: Store +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/Priority/FungusPriorityReset.cs b/Assets/Fungus/Scripts/Commands/Priority/FungusPriorityReset.cs new file mode 100644 index 0000000..0ebc39e --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Priority/FungusPriorityReset.cs @@ -0,0 +1,25 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using System.Collections; +using System.Collections.Generic; +using UnityEngine; + +namespace Fungus +{ + /// + /// Resets the FungusPriority count to zero. Useful if you are among logic that is hard to have matching increase and decreases. + /// + [CommandInfo("PrioritySignals", + "Priority Reset", + "Resets the FungusPriority count to zero. Useful if you are among logic that is hard to have matching increase and decreases.")] + public class FungusPriorityReset : Command + { + public override void OnEnter() + { + FungusPrioritySignals.DoResetPriority(); + + Continue(); + } + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/Priority/FungusPriorityReset.cs.meta b/Assets/Fungus/Scripts/Commands/Priority/FungusPriorityReset.cs.meta new file mode 100644 index 0000000..94c03fc --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Priority/FungusPriorityReset.cs.meta @@ -0,0 +1,13 @@ +fileFormatVersion: 2 +guid: b5b98ba2a3006db49959601485049a0d +timeCreated: 1523926493 +licenseType: Store +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/Property.meta b/Assets/Fungus/Scripts/Commands/Property.meta new file mode 100644 index 0000000..7d2d156 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Property.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 8a1a00144f44775449d32d39b5a7185a +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/Property/AnimatorProperty.cs b/Assets/Fungus/Scripts/Commands/Property/AnimatorProperty.cs new file mode 100644 index 0000000..c5be2d1 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Property/AnimatorProperty.cs @@ -0,0 +1,296 @@ +/*This script has been, partially or completely, generated by the Fungus.GenerateVariableWindow*/ +using UnityEngine; + + +namespace Fungus +{ + // + /// Get or Set a property of a Animator component + /// + [CommandInfo("Property", + "Animator", + "Get or Set a property of a Animator component")] + [AddComponentMenu("")] + public class AnimatorProperty : BaseVariableProperty + { + //generated property + public enum Property + { + IsOptimizable, + IsHuman, + HasRootMotion, + HumanScale, + IsInitialized, + DeltaPosition, + DeltaRotation, + Velocity, + AngularVelocity, + RootPosition, + RootRotation, + ApplyRootMotion, + HasTransformHierarchy, + GravityWeight, + BodyPosition, + BodyRotation, + StabilizeFeet, + LayerCount, + ParameterCount, + FeetPivotActive, + PivotWeight, + PivotPosition, + IsMatchingTarget, + Speed, + TargetPosition, + TargetRotation, + PlaybackTime, + RecorderStartTime, + RecorderStopTime, + HasBoundPlayables, + LayersAffectMassCenter, + LeftFeetBottomHeight, + RightFeetBottomHeight, + LogWarnings, + FireEvents, + KeepAnimatorControllerStateOnDisable, + } + + + [SerializeField] + protected Property property; + + [SerializeField] + [VariableProperty(typeof(AnimatorVariable))] + protected AnimatorVariable animatorVar; + + [SerializeField] + [VariableProperty(typeof(BooleanVariable), + typeof(FloatVariable), + typeof(Vector3Variable), + typeof(QuaternionVariable), + typeof(IntegerVariable))] + protected Variable inOutVar; + + public override void OnEnter() + { + var iob = inOutVar as BooleanVariable; + var iof = inOutVar as FloatVariable; + var iov = inOutVar as Vector3Variable; + var ioq = inOutVar as QuaternionVariable; + var ioi = inOutVar as IntegerVariable; + + + var target = animatorVar.Value; + + switch (getOrSet) + { + case GetSet.Get: + switch (property) + { + case Property.IsOptimizable: + iob.Value = target.isOptimizable; + break; + case Property.IsHuman: + iob.Value = target.isHuman; + break; + case Property.HasRootMotion: + iob.Value = target.hasRootMotion; + break; + case Property.HumanScale: + iof.Value = target.humanScale; + break; + case Property.IsInitialized: + iob.Value = target.isInitialized; + break; + case Property.DeltaPosition: + iov.Value = target.deltaPosition; + break; + case Property.DeltaRotation: + ioq.Value = target.deltaRotation; + break; + case Property.Velocity: + iov.Value = target.velocity; + break; + case Property.AngularVelocity: + iov.Value = target.angularVelocity; + break; + case Property.RootPosition: + iov.Value = target.rootPosition; + break; + case Property.RootRotation: + ioq.Value = target.rootRotation; + break; + case Property.ApplyRootMotion: + iob.Value = target.applyRootMotion; + break; + case Property.HasTransformHierarchy: + iob.Value = target.hasTransformHierarchy; + break; + case Property.GravityWeight: + iof.Value = target.gravityWeight; + break; + case Property.BodyPosition: + iov.Value = target.bodyPosition; + break; + case Property.BodyRotation: + ioq.Value = target.bodyRotation; + break; + case Property.StabilizeFeet: + iob.Value = target.stabilizeFeet; + break; + case Property.LayerCount: + ioi.Value = target.layerCount; + break; + case Property.ParameterCount: + ioi.Value = target.parameterCount; + break; + case Property.FeetPivotActive: + iof.Value = target.feetPivotActive; + break; + case Property.PivotWeight: + iof.Value = target.pivotWeight; + break; + case Property.PivotPosition: + iov.Value = target.pivotPosition; + break; + case Property.IsMatchingTarget: + iob.Value = target.isMatchingTarget; + break; + case Property.Speed: + iof.Value = target.speed; + break; + case Property.TargetPosition: + iov.Value = target.targetPosition; + break; + case Property.TargetRotation: + ioq.Value = target.targetRotation; + break; + case Property.PlaybackTime: + iof.Value = target.playbackTime; + break; + case Property.RecorderStartTime: + iof.Value = target.recorderStartTime; + break; + case Property.RecorderStopTime: + iof.Value = target.recorderStopTime; + break; + case Property.HasBoundPlayables: + iob.Value = target.hasBoundPlayables; + break; + case Property.LayersAffectMassCenter: + iob.Value = target.layersAffectMassCenter; + break; + case Property.LeftFeetBottomHeight: + iof.Value = target.leftFeetBottomHeight; + break; + case Property.RightFeetBottomHeight: + iof.Value = target.rightFeetBottomHeight; + break; + case Property.LogWarnings: + iob.Value = target.logWarnings; + break; + case Property.FireEvents: + iob.Value = target.fireEvents; + break; +#if UNITY_2019_2_OR_NEWER + case Property.KeepAnimatorControllerStateOnDisable: + iob.Value = target.keepAnimatorControllerStateOnDisable; + break; +#endif + default: + Debug.Log("Unsupported get or set attempted"); + break; + } + + break; + case GetSet.Set: + switch (property) + { + case Property.RootPosition: + target.rootPosition = iov.Value; + break; + case Property.RootRotation: + target.rootRotation = ioq.Value; + break; + case Property.ApplyRootMotion: + target.applyRootMotion = iob.Value; + break; + case Property.BodyPosition: + target.bodyPosition = iov.Value; + break; + case Property.BodyRotation: + target.bodyRotation = ioq.Value; + break; + case Property.StabilizeFeet: + target.stabilizeFeet = iob.Value; + break; + case Property.FeetPivotActive: + target.feetPivotActive = iof.Value; + break; + case Property.Speed: + target.speed = iof.Value; + break; + case Property.PlaybackTime: + target.playbackTime = iof.Value; + break; + case Property.RecorderStartTime: + target.recorderStartTime = iof.Value; + break; + case Property.RecorderStopTime: + target.recorderStopTime = iof.Value; + break; + case Property.LayersAffectMassCenter: + target.layersAffectMassCenter = iob.Value; + break; + case Property.LogWarnings: + target.logWarnings = iob.Value; + break; + case Property.FireEvents: + target.fireEvents = iob.Value; + break; +#if UNITY_2019_2_OR_NEWER + case Property.KeepAnimatorControllerStateOnDisable: + target.keepAnimatorControllerStateOnDisable = iob.Value; + break; +#endif + default: + Debug.Log("Unsupported get or set attempted"); + break; + } + + break; + default: + break; + } + + Continue(); + } + + public override string GetSummary() + { + if (animatorVar == null) + { + return "Error: no animatorVar set"; + } + if (inOutVar == null) + { + return "Error: no variable set to push or pull data to or from"; + } + + return getOrSet.ToString() + " " + property.ToString(); + } + + public override Color GetButtonColor() + { + return new Color32(235, 191, 217, 255); + } + + public override bool HasReference(Variable variable) + { + if (animatorVar == variable || inOutVar == variable) + return true; + + return false; + } + + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/Property/AnimatorProperty.cs.meta b/Assets/Fungus/Scripts/Commands/Property/AnimatorProperty.cs.meta new file mode 100644 index 0000000..ee1ea32 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Property/AnimatorProperty.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: e4616a794b2245d46970401b3acc492f +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/Property/AudioSourceProperty.cs b/Assets/Fungus/Scripts/Commands/Property/AudioSourceProperty.cs new file mode 100644 index 0000000..3cca2be --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Property/AudioSourceProperty.cs @@ -0,0 +1,261 @@ +/*This script has been, partially or completely, generated by the Fungus.GenerateVariableWindow*/ +using UnityEngine; + + +namespace Fungus +{ + // + /// Get or Set a property of a AudioSource component + /// + [CommandInfo("Property", + "AudioSource", + "Get or Set a property of a AudioSource component")] + [AddComponentMenu("")] + public class AudioSourceProperty : BaseVariableProperty + { + //generated property + public enum Property + { + Volume, + Pitch, + Time, + TimeSamples, + IsPlaying, + IsVirtual, + Loop, + IgnoreListenerVolume, + PlayOnAwake, + IgnoreListenerPause, + PanStereo, + SpatialBlend, + Spatialize, + SpatializePostEffects, + ReverbZoneMix, + BypassEffects, + BypassListenerEffects, + BypassReverbZones, + DopplerLevel, + Spread, + Priority, + Mute, + MinDistance, + MaxDistance, + } + + + [SerializeField] + protected Property property; + + [SerializeField] + [VariableProperty(typeof(AudioSourceVariable))] + protected AudioSourceVariable audioSourceVar; + + [SerializeField] + [VariableProperty(typeof(FloatVariable), + typeof(IntegerVariable), + typeof(BooleanVariable))] + protected Variable inOutVar; + + public override void OnEnter() + { + var iof = inOutVar as FloatVariable; + var ioi = inOutVar as IntegerVariable; + var iob = inOutVar as BooleanVariable; + + + var target = audioSourceVar.Value; + + switch (getOrSet) + { + case GetSet.Get: + switch (property) + { + case Property.Volume: + iof.Value = target.volume; + break; + case Property.Pitch: + iof.Value = target.pitch; + break; + case Property.Time: + iof.Value = target.time; + break; + case Property.TimeSamples: + ioi.Value = target.timeSamples; + break; + case Property.IsPlaying: + iob.Value = target.isPlaying; + break; + case Property.IsVirtual: + iob.Value = target.isVirtual; + break; + case Property.Loop: + iob.Value = target.loop; + break; + case Property.IgnoreListenerVolume: + iob.Value = target.ignoreListenerVolume; + break; + case Property.PlayOnAwake: + iob.Value = target.playOnAwake; + break; + case Property.IgnoreListenerPause: + iob.Value = target.ignoreListenerPause; + break; + case Property.PanStereo: + iof.Value = target.panStereo; + break; + case Property.SpatialBlend: + iof.Value = target.spatialBlend; + break; + case Property.Spatialize: + iob.Value = target.spatialize; + break; + case Property.SpatializePostEffects: + iob.Value = target.spatializePostEffects; + break; + case Property.ReverbZoneMix: + iof.Value = target.reverbZoneMix; + break; + case Property.BypassEffects: + iob.Value = target.bypassEffects; + break; + case Property.BypassListenerEffects: + iob.Value = target.bypassListenerEffects; + break; + case Property.BypassReverbZones: + iob.Value = target.bypassReverbZones; + break; + case Property.DopplerLevel: + iof.Value = target.dopplerLevel; + break; + case Property.Spread: + iof.Value = target.spread; + break; + case Property.Priority: + ioi.Value = target.priority; + break; + case Property.Mute: + iob.Value = target.mute; + break; + case Property.MinDistance: + iof.Value = target.minDistance; + break; + case Property.MaxDistance: + iof.Value = target.maxDistance; + break; + default: + Debug.Log("Unsupported get or set attempted"); + break; + } + + break; + case GetSet.Set: + switch (property) + { + case Property.Volume: + target.volume = iof.Value; + break; + case Property.Pitch: + target.pitch = iof.Value; + break; + case Property.Time: + target.time = iof.Value; + break; + case Property.TimeSamples: + target.timeSamples = ioi.Value; + break; + case Property.Loop: + target.loop = iob.Value; + break; + case Property.IgnoreListenerVolume: + target.ignoreListenerVolume = iob.Value; + break; + case Property.PlayOnAwake: + target.playOnAwake = iob.Value; + break; + case Property.IgnoreListenerPause: + target.ignoreListenerPause = iob.Value; + break; + case Property.PanStereo: + target.panStereo = iof.Value; + break; + case Property.SpatialBlend: + target.spatialBlend = iof.Value; + break; + case Property.Spatialize: + target.spatialize = iob.Value; + break; + case Property.SpatializePostEffects: + target.spatializePostEffects = iob.Value; + break; + case Property.ReverbZoneMix: + target.reverbZoneMix = iof.Value; + break; + case Property.BypassEffects: + target.bypassEffects = iob.Value; + break; + case Property.BypassListenerEffects: + target.bypassListenerEffects = iob.Value; + break; + case Property.BypassReverbZones: + target.bypassReverbZones = iob.Value; + break; + case Property.DopplerLevel: + target.dopplerLevel = iof.Value; + break; + case Property.Spread: + target.spread = iof.Value; + break; + case Property.Priority: + target.priority = ioi.Value; + break; + case Property.Mute: + target.mute = iob.Value; + break; + case Property.MinDistance: + target.minDistance = iof.Value; + break; + case Property.MaxDistance: + target.maxDistance = iof.Value; + break; + default: + Debug.Log("Unsupported get or set attempted"); + break; + } + + break; + default: + break; + } + + Continue(); + } + + public override string GetSummary() + { + if (audioSourceVar == null) + { + return "Error: no audioSourceVar set"; + } + if (inOutVar == null) + { + return "Error: no variable set to push or pull data to or from"; + } + + return getOrSet.ToString() + " " + property.ToString(); + } + + public override Color GetButtonColor() + { + return new Color32(235, 191, 217, 255); + } + + public override bool HasReference(Variable variable) + { + if (audioSourceVar == variable || inOutVar == variable) + return true; + + return false; + } + + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/Property/AudioSourceProperty.cs.meta b/Assets/Fungus/Scripts/Commands/Property/AudioSourceProperty.cs.meta new file mode 100644 index 0000000..533d3d7 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Property/AudioSourceProperty.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 2250cfac690a2b74f8f9dd9be91985c6 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/Property/CollectionProperty.cs b/Assets/Fungus/Scripts/Commands/Property/CollectionProperty.cs new file mode 100644 index 0000000..08792f4 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Property/CollectionProperty.cs @@ -0,0 +1,125 @@ +/*This script has been, partially or completely, generated by the Fungus.GenerateVariableWindow*/ +using UnityEngine; + + +namespace Fungus +{ + // + /// Get or Set a property of a Collection component + /// + [CommandInfo("Property", + "Collection", + "Get or Set a property of a Collection component")] + [AddComponentMenu("")] + public class CollectionProperty : BaseVariableProperty + { + //generated property + public enum Property + { + Capacity, + Count, + IsFixedSize, + IsReadOnly, + IsSynchronized, + Name, + } + + + [SerializeField] + protected Property property; + + [SerializeField] + protected CollectionData collectionData; + + [SerializeField] + [VariableProperty(typeof(IntegerVariable), + typeof(BooleanVariable), + typeof(StringVariable))] + protected Variable inOutVar; + + public override void OnEnter() + { + var ioi = inOutVar as IntegerVariable; + var iob = inOutVar as BooleanVariable; + var ios = inOutVar as StringVariable; + + + var target = collectionData.Value; + + switch (getOrSet) + { + case GetSet.Get: + switch (property) + { + case Property.Capacity: + ioi.Value = target.Capacity; + break; + case Property.Count: + ioi.Value = target.Count; + break; + case Property.IsFixedSize: + iob.Value = target.IsFixedSize; + break; + case Property.IsReadOnly: + iob.Value = target.IsReadOnly; + break; + case Property.IsSynchronized: + iob.Value = target.IsSynchronized; + break; + case Property.Name: + ios.Value = target.Name; + break; + default: + Debug.Log("Unsupported get or set attempted"); + break; + } + + break; + case GetSet.Set: + switch (property) + { + case Property.Capacity: + target.Capacity = ioi.Value; + break; + default: + Debug.Log("Unsupported get or set attempted"); + break; + } + + break; + default: + break; + } + + Continue(); + } + + public override string GetSummary() + { + if (collectionData.Value == null) + { + return "Error: no collection set"; + } + if (inOutVar == null) + { + return "Error: no variable set to push or pull data to or from"; + } + + return getOrSet.ToString() + " " + property.ToString(); + } + + public override Color GetButtonColor() + { + return new Color32(235, 191, 217, 255); + } + + public override bool HasReference(Variable variable) + { + if (collectionData.collectionRef == variable || inOutVar == variable) + return true; + + return false; + } + + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/Property/CollectionProperty.cs.meta b/Assets/Fungus/Scripts/Commands/Property/CollectionProperty.cs.meta new file mode 100644 index 0000000..acc5918 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Property/CollectionProperty.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 6f03dcf7e7a1d2e418e5588731888b5a +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/Property/Collider2DProperty.cs b/Assets/Fungus/Scripts/Commands/Property/Collider2DProperty.cs new file mode 100644 index 0000000..4a8e464 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Property/Collider2DProperty.cs @@ -0,0 +1,153 @@ +/*This script has been, partially or completely, generated by the Fungus.GenerateVariableWindow*/ +using UnityEngine; + + +namespace Fungus +{ + // + /// Get or Set a property of a Collider2D component + /// + [CommandInfo("Property", + "Collider2D", + "Get or Set a property of a Collider2D component")] + [AddComponentMenu("")] + public class Collider2DProperty : BaseVariableProperty + { + //generated property + public enum Property + { + Density, + IsTrigger, + UsedByEffector, + UsedByComposite, + Offset, + AttachedRigidbody, + ShapeCount, + Friction, + Bounciness, + } + + + [SerializeField] + protected Property property; + + [SerializeField] + protected Collider2DData collider2DData; + + [SerializeField] + [VariableProperty(typeof(FloatVariable), + typeof(BooleanVariable), + typeof(Vector2Variable), + typeof(Rigidbody2DVariable), + typeof(IntegerVariable))] + protected Variable inOutVar; + + public override void OnEnter() + { + var iof = inOutVar as FloatVariable; + var iob = inOutVar as BooleanVariable; + var iov2 = inOutVar as Vector2Variable; + var iorb2d = inOutVar as Rigidbody2DVariable; + var ioi = inOutVar as IntegerVariable; + + + var target = collider2DData.Value; + + switch (getOrSet) + { + case GetSet.Get: + switch (property) + { + case Property.Density: + iof.Value = target.density; + break; + case Property.IsTrigger: + iob.Value = target.isTrigger; + break; + case Property.UsedByEffector: + iob.Value = target.usedByEffector; + break; + case Property.UsedByComposite: + iob.Value = target.usedByComposite; + break; + case Property.Offset: + iov2.Value = target.offset; + break; + case Property.AttachedRigidbody: + iorb2d.Value = target.attachedRigidbody; + break; + case Property.ShapeCount: + ioi.Value = target.shapeCount; + break; + case Property.Friction: + iof.Value = target.friction; + break; + case Property.Bounciness: + iof.Value = target.bounciness; + break; + default: + Debug.Log("Unsupported get or set attempted"); + break; + } + + break; + case GetSet.Set: + switch (property) + { + case Property.Density: + target.density = iof.Value; + break; + case Property.IsTrigger: + target.isTrigger = iob.Value; + break; + case Property.UsedByEffector: + target.usedByEffector = iob.Value; + break; + case Property.UsedByComposite: + target.usedByComposite = iob.Value; + break; + case Property.Offset: + target.offset = iov2.Value; + break; + default: + Debug.Log("Unsupported get or set attempted"); + break; + } + + break; + default: + break; + } + + Continue(); + } + + public override string GetSummary() + { + if (collider2DData.Value == null) + { + return "Error: no collider2D set"; + } + if (inOutVar == null) + { + return "Error: no variable set to push or pull data to or from"; + } + + return getOrSet.ToString() + " " + property.ToString(); + } + + public override Color GetButtonColor() + { + return new Color32(235, 191, 217, 255); + } + + public override bool HasReference(Variable variable) + { + if (collider2DData.collider2DRef == variable || inOutVar == variable) + return true; + + return false; + } + + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/Property/Collider2DProperty.cs.meta b/Assets/Fungus/Scripts/Commands/Property/Collider2DProperty.cs.meta new file mode 100644 index 0000000..fcea68b --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Property/Collider2DProperty.cs.meta @@ -0,0 +1,13 @@ +fileFormatVersion: 2 +guid: c5d345b268622414c9bb53e05f4580ed +timeCreated: 1517559095 +licenseType: Store +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/Property/ColliderProperty.cs b/Assets/Fungus/Scripts/Commands/Property/ColliderProperty.cs new file mode 100644 index 0000000..2272ea6 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Property/ColliderProperty.cs @@ -0,0 +1,123 @@ +/*This script has been, partially or completely, generated by the Fungus.GenerateVariableWindow*/ +using UnityEngine; + + +namespace Fungus +{ + // + /// Get or Set a property of a Collider component + /// + [CommandInfo("Property", + "Collider", + "Get or Set a property of a Collider component")] + [AddComponentMenu("")] + public class ColliderProperty : BaseVariableProperty + { + //generated property + public enum Property + { + Enabled, + AttachedRigidbody, + IsTrigger, + ContactOffset, + } + + + [SerializeField] + protected Property property; + + [SerializeField] + protected ColliderData colliderData; + + [SerializeField] + [VariableProperty(typeof(BooleanVariable), + typeof(RigidbodyVariable), + typeof(FloatVariable))] + protected Variable inOutVar; + + public override void OnEnter() + { + var iob = inOutVar as BooleanVariable; + var iorb = inOutVar as RigidbodyVariable; + var iof = inOutVar as FloatVariable; + + + var target = colliderData.Value; + + switch (getOrSet) + { + case GetSet.Get: + switch (property) + { + case Property.Enabled: + iob.Value = target.enabled; + break; + case Property.AttachedRigidbody: + iorb.Value = target.attachedRigidbody; + break; + case Property.IsTrigger: + iob.Value = target.isTrigger; + break; + case Property.ContactOffset: + iof.Value = target.contactOffset; + break; + default: + Debug.Log("Unsupported get or set attempted"); + break; + } + + break; + case GetSet.Set: + switch (property) + { + case Property.Enabled: + target.enabled = iob.Value; + break; + case Property.IsTrigger: + target.isTrigger = iob.Value; + break; + case Property.ContactOffset: + target.contactOffset = iof.Value; + break; + default: + Debug.Log("Unsupported get or set attempted"); + break; + } + + break; + default: + break; + } + + Continue(); + } + + public override string GetSummary() + { + if (colliderData.Value == null) + { + return "Error: no collider set"; + } + if (inOutVar == null) + { + return "Error: no variable set to push or pull data to or from"; + } + + return getOrSet.ToString() + " " + property.ToString(); + } + + public override Color GetButtonColor() + { + return new Color32(235, 191, 217, 255); + } + + public override bool HasReference(Variable variable) + { + if (colliderData.colliderRef == variable || inOutVar == variable) + return true; + + return false; + } + + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/Property/ColliderProperty.cs.meta b/Assets/Fungus/Scripts/Commands/Property/ColliderProperty.cs.meta new file mode 100644 index 0000000..f9faac1 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Property/ColliderProperty.cs.meta @@ -0,0 +1,13 @@ +fileFormatVersion: 2 +guid: ca6e05b34c44a734988887ef775a1a1b +timeCreated: 1517559091 +licenseType: Store +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/Property/Collision2DProperty.cs b/Assets/Fungus/Scripts/Commands/Property/Collision2DProperty.cs new file mode 100644 index 0000000..df50617 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Property/Collision2DProperty.cs @@ -0,0 +1,147 @@ +/*This script has been, partially or completely, generated by the Fungus.GenerateVariableWindow*/ +using UnityEngine; + + +namespace Fungus +{ + // + /// Get or Set a property of a Collision2D component + /// + [CommandInfo("Property", + "Collision2D", + "Get or Set a property of a Collision2D component")] + [AddComponentMenu("")] + public class Collision2DProperty : BaseVariableProperty + { + //generated property + public enum Property + { + Rigidbody, + OtherRigidbody, + Transform, + GameObject, + RelativeVelocity, + Enabled, + Collider, + OtherCollider, + ContactCount, + } + + + [SerializeField] + protected Property property; + + [SerializeField] + [VariableProperty(typeof(Collision2DVariable))] + protected Collision2DVariable collision2DVar; + + [SerializeField] + [VariableProperty(typeof(Collider2DVariable), + typeof(Rigidbody2DVariable), + typeof(TransformVariable), + typeof(GameObjectVariable), + typeof(Vector2Variable), + typeof(BooleanVariable), + typeof(IntegerVariable))] + protected Variable inOutVar; + + public override void OnEnter() + { + var ioc2d = inOutVar as Collider2DVariable; + var iorb2d = inOutVar as Rigidbody2DVariable; + var iot = inOutVar as TransformVariable; + var iogo = inOutVar as GameObjectVariable; + var iov2 = inOutVar as Vector2Variable; + var iob = inOutVar as BooleanVariable; +#if UNITY_2019_2_OR_NEWER + var ioi = inOutVar as IntegerVariable; +#endif + + + var target = collision2DVar.Value; + + switch (getOrSet) + { + case GetSet.Get: + switch (property) + { + case Property.Collider: + ioc2d.Value = target.collider; + break; + case Property.OtherCollider: + ioc2d.Value = target.otherCollider; + break; + case Property.Rigidbody: + iorb2d.Value = target.rigidbody; + break; + case Property.OtherRigidbody: + iorb2d.Value = target.otherRigidbody; + break; + case Property.Transform: + iot.Value = target.transform; + break; + case Property.GameObject: + iogo.Value = target.gameObject; + break; + case Property.RelativeVelocity: + iov2.Value = target.relativeVelocity; + break; + case Property.Enabled: + iob.Value = target.enabled; + break; +#if UNITY_2019_2_OR_NEWER + case Property.ContactCount: + ioi.Value = target.contactCount; + break; +#endif + default: + Debug.Log("Unsupported get or set attempted"); + break; + } + + break; + case GetSet.Set: + switch (property) + { + default: + Debug.Log("Unsupported get or set attempted"); + break; + } + + break; + default: + break; + } + + Continue(); + } + + public override string GetSummary() + { + if (collision2DVar == null) + { + return "Error: no collision2DVar set"; + } + if (inOutVar == null) + { + return "Error: no variable set to push or pull data to or from"; + } + + return getOrSet.ToString() + " " + property.ToString(); + } + + public override Color GetButtonColor() + { + return new Color32(235, 191, 217, 255); + } + + public override bool HasReference(Variable variable) + { + if (collision2DVar == variable || inOutVar == variable) + return true; + + return false; + } + + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/Property/Collision2DProperty.cs.meta b/Assets/Fungus/Scripts/Commands/Property/Collision2DProperty.cs.meta new file mode 100644 index 0000000..a0c950d --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Property/Collision2DProperty.cs.meta @@ -0,0 +1,13 @@ +fileFormatVersion: 2 +guid: 8556e15e3a9145740815675ae531a7cd +timeCreated: 1517559039 +licenseType: Store +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/Property/CollisionProperty.cs b/Assets/Fungus/Scripts/Commands/Property/CollisionProperty.cs new file mode 100644 index 0000000..6343654 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Property/CollisionProperty.cs @@ -0,0 +1,127 @@ +/*This script has been, partially or completely, generated by the Fungus.GenerateVariableWindow*/ +using UnityEngine; + + +namespace Fungus +{ + // + /// Get or Set a property of a Collision component + /// + [CommandInfo("Property", + "Collision", + "Get or Set a property of a Collision component")] + [AddComponentMenu("")] + public class CollisionProperty : BaseVariableProperty + { + //generated property + public enum Property + { + RelativeVelocity, + Rigidbody, + Collider, + Transform, + GameObject, + Impulse, + } + + + [SerializeField] + protected Property property; + + [SerializeField] + [VariableProperty(typeof(CollisionVariable))] + protected CollisionVariable collisionVar; + + [SerializeField] + [VariableProperty(typeof(Vector3Variable), + typeof(RigidbodyVariable), + typeof(ColliderVariable), + typeof(TransformVariable), + typeof(GameObjectVariable))] + protected Variable inOutVar; + + public override void OnEnter() + { + var iov = inOutVar as Vector3Variable; + var iorb = inOutVar as RigidbodyVariable; + var ioc = inOutVar as ColliderVariable; + var iot = inOutVar as TransformVariable; + var iogo = inOutVar as GameObjectVariable; + + + var target = collisionVar.Value; + + switch (getOrSet) + { + case GetSet.Get: + switch (property) + { + case Property.RelativeVelocity: + iov.Value = target.relativeVelocity; + break; + case Property.Rigidbody: + iorb.Value = target.rigidbody; + break; + case Property.Collider: + ioc.Value = target.collider; + break; + case Property.Transform: + iot.Value = target.transform; + break; + case Property.GameObject: + iogo.Value = target.gameObject; + break; + case Property.Impulse: + iov.Value = target.impulse; + break; + default: + Debug.Log("Unsupported get or set attempted"); + break; + } + + break; + case GetSet.Set: + switch (property) + { + default: + Debug.Log("Unsupported get or set attempted"); + break; + } + + break; + default: + break; + } + + Continue(); + } + + public override string GetSummary() + { + if (collisionVar == null) + { + return "Error: no collisionVar set"; + } + if (inOutVar == null) + { + return "Error: no variable set to push or pull data to or from"; + } + + return getOrSet.ToString() + " " + property.ToString(); + } + + public override Color GetButtonColor() + { + return new Color32(235, 191, 217, 255); + } + + public override bool HasReference(Variable variable) + { + if (collisionVar == variable || inOutVar == variable) + return true; + + return false; + } + + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/Property/CollisionProperty.cs.meta b/Assets/Fungus/Scripts/Commands/Property/CollisionProperty.cs.meta new file mode 100644 index 0000000..23fd139 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Property/CollisionProperty.cs.meta @@ -0,0 +1,13 @@ +fileFormatVersion: 2 +guid: 5d7861de0e23aac439a4959cd06b3d09 +timeCreated: 1517559033 +licenseType: Store +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/Property/ColorProperty.cs b/Assets/Fungus/Scripts/Commands/Property/ColorProperty.cs new file mode 100644 index 0000000..ded43cf --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Property/ColorProperty.cs @@ -0,0 +1,139 @@ +/*This script has been, partially or completely, generated by the Fungus.GenerateVariableWindow*/ +using UnityEngine; + + +namespace Fungus +{ + // + /// Get or Set a property of a Color component + /// + [CommandInfo("Property", + "Color", + "Get or Set a property of a Color component")] + [AddComponentMenu("")] + public class ColorProperty : BaseVariableProperty + { + //generated property + public enum Property + { + R, + G, + B, + A, + Grayscale, + Linear, + Gamma, + MaxColorComponent, + } + + + [SerializeField] + protected Property property; + + [SerializeField] + [VariableProperty(typeof(ColorVariable))] + protected ColorVariable colorVar; + + [SerializeField] + [VariableProperty(typeof(FloatVariable), + typeof(ColorVariable))] + protected Variable inOutVar; + + public override void OnEnter() + { + var iof = inOutVar as FloatVariable; + var iocol = inOutVar as ColorVariable; + + + var target = colorVar.Value; + + switch (getOrSet) + { + case GetSet.Get: + switch (property) + { + case Property.R: + iof.Value = target.r; + break; + case Property.G: + iof.Value = target.g; + break; + case Property.B: + iof.Value = target.b; + break; + case Property.A: + iof.Value = target.a; + break; + case Property.Grayscale: + iof.Value = target.grayscale; + break; + case Property.Linear: + iocol.Value = target.linear; + break; + case Property.Gamma: + iocol.Value = target.gamma; + break; + case Property.MaxColorComponent: + iof.Value = target.maxColorComponent; + break; + default: + Debug.Log("Unsupported get or set attempted"); + break; + } + + break; + case GetSet.Set: + switch (property) + { + case Property.R: + target.r = iof.Value; + break; + case Property.G: + target.g = iof.Value; + break; + case Property.B: + target.b = iof.Value; + break; + case Property.A: + target.a = iof.Value; + break; + default: + Debug.Log("Unsupported get or set attempted"); + break; + } + + break; + default: + break; + } + + colorVar.Value = target; + + Continue(); + } + + public override string GetSummary() + { + if (inOutVar == null) + { + return "Error: no variable set to push or pull data to or from"; + } + + return getOrSet.ToString() + " " + property.ToString(); + } + + public override Color GetButtonColor() + { + return new Color32(235, 191, 217, 255); + } + + public override bool HasReference(Variable variable) + { + if (colorVar == variable || inOutVar == variable) + return true; + + return false; + } + + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/Property/ColorProperty.cs.meta b/Assets/Fungus/Scripts/Commands/Property/ColorProperty.cs.meta new file mode 100644 index 0000000..e74334c --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Property/ColorProperty.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 8c9c405ac7b91be439696c5607bddb01 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/Property/ControllerColliderHitProperty.cs b/Assets/Fungus/Scripts/Commands/Property/ControllerColliderHitProperty.cs new file mode 100644 index 0000000..7be49bb --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Property/ControllerColliderHitProperty.cs @@ -0,0 +1,137 @@ +/*This script has been, partially or completely, generated by the Fungus.GenerateVariableWindow*/ +using UnityEngine; + + +namespace Fungus +{ + // + /// Get or Set a property of a ControllerColliderHit component + /// + [CommandInfo("Property", + "ControllerColliderHit", + "Get or Set a property of a ControllerColliderHit component")] + [AddComponentMenu("")] + public class ControllerColliderHitProperty : BaseVariableProperty + { + //generated property + public enum Property + { + Collider, + Rigidbody, + GameObject, + Transform, + Point, + Normal, + MoveDirection, + MoveLength, + } + + + [SerializeField] + protected Property property; + + [SerializeField] + [VariableProperty(typeof(ControllerColliderHitVariable))] + protected ControllerColliderHitVariable controllerColliderHitVar; + + [SerializeField] + [VariableProperty(typeof(ColliderVariable), + typeof(RigidbodyVariable), + typeof(GameObjectVariable), + typeof(TransformVariable), + typeof(Vector3Variable), + typeof(FloatVariable))] + protected Variable inOutVar; + + public override void OnEnter() + { + var ioc = inOutVar as ColliderVariable; + var iorb = inOutVar as RigidbodyVariable; + var iogo = inOutVar as GameObjectVariable; + var iot = inOutVar as TransformVariable; + var iov = inOutVar as Vector3Variable; + var iof = inOutVar as FloatVariable; + + + var target = controllerColliderHitVar.Value; + + switch (getOrSet) + { + case GetSet.Get: + switch (property) + { + case Property.Collider: + ioc.Value = target.collider; + break; + case Property.Rigidbody: + iorb.Value = target.rigidbody; + break; + case Property.GameObject: + iogo.Value = target.gameObject; + break; + case Property.Transform: + iot.Value = target.transform; + break; + case Property.Point: + iov.Value = target.point; + break; + case Property.Normal: + iov.Value = target.normal; + break; + case Property.MoveDirection: + iov.Value = target.moveDirection; + break; + case Property.MoveLength: + iof.Value = target.moveLength; + break; + default: + Debug.Log("Unsupported get or set attempted"); + break; + } + + break; + case GetSet.Set: + switch (property) + { + default: + Debug.Log("Unsupported get or set attempted"); + break; + } + + break; + default: + break; + } + + Continue(); + } + + public override string GetSummary() + { + if (controllerColliderHitVar == null) + { + return "Error: no controllerColliderHitVar set"; + } + if (inOutVar == null) + { + return "Error: no variable set to push or pull data to or from"; + } + + return getOrSet.ToString() + " " + property.ToString(); + } + + public override Color GetButtonColor() + { + return new Color32(235, 191, 217, 255); + } + + public override bool HasReference(Variable variable) + { + if (controllerColliderHitVar == variable || inOutVar == variable) + return true; + + return false; + } + + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/Property/ControllerColliderHitProperty.cs.meta b/Assets/Fungus/Scripts/Commands/Property/ControllerColliderHitProperty.cs.meta new file mode 100644 index 0000000..49532f4 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Property/ControllerColliderHitProperty.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 706c416dcce1daf4188e35d5981ac45f +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/Property/GameObjectProperty.cs b/Assets/Fungus/Scripts/Commands/Property/GameObjectProperty.cs new file mode 100644 index 0000000..6d669fc --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Property/GameObjectProperty.cs @@ -0,0 +1,140 @@ +/*This script has been, partially or completely, generated by the Fungus.GenerateVariableWindow*/ +using UnityEngine; + + +namespace Fungus +{ + // + /// Get or Set a property of a GameObject component + /// + [CommandInfo("Property", + "GameObject", + "Get or Set a property of a GameObject component")] + [AddComponentMenu("")] + public class GameObjectProperty : BaseVariableProperty + { + //generated property + public enum Property + { + Transform, + Layer, + ActiveSelf, + ActiveInHierarchy, + IsStatic, + Tag, + GameObject, + } + + + [SerializeField] + protected Property property; + + [SerializeField] + [VariableProperty(typeof(GameObjectVariable))] + protected GameObjectVariable gameObjectVar; + + [SerializeField] + [VariableProperty(typeof(TransformVariable), + typeof(IntegerVariable), + typeof(BooleanVariable), + typeof(StringVariable), + typeof(GameObjectVariable))] + protected Variable inOutVar; + + public override void OnEnter() + { + var iot = inOutVar as TransformVariable; + var ioi = inOutVar as IntegerVariable; + var iob = inOutVar as BooleanVariable; + var ios = inOutVar as StringVariable; + var iogo = inOutVar as GameObjectVariable; + + + var target = gameObjectVar.Value; + + switch (getOrSet) + { + case GetSet.Get: + switch (property) + { + case Property.Transform: + iot.Value = target.transform; + break; + case Property.Layer: + ioi.Value = target.layer; + break; + case Property.ActiveSelf: + iob.Value = target.activeSelf; + break; + case Property.ActiveInHierarchy: + iob.Value = target.activeInHierarchy; + break; + case Property.IsStatic: + iob.Value = target.isStatic; + break; + case Property.Tag: + ios.Value = target.tag; + break; + case Property.GameObject: + iogo.Value = target.gameObject; + break; + default: + Debug.Log("Unsupported get or set attempted"); + break; + } + + break; + case GetSet.Set: + switch (property) + { + case Property.Layer: + target.layer = ioi.Value; + break; + case Property.IsStatic: + target.isStatic = iob.Value; + break; + case Property.Tag: + target.tag = ios.Value; + break; + default: + Debug.Log("Unsupported get or set attempted"); + break; + } + + break; + default: + break; + } + + Continue(); + } + + public override string GetSummary() + { + if (gameObjectVar == null) + { + return "Error: no gameObjectVar set"; + } + if (inOutVar == null) + { + return "Error: no variable set to push or pull data to or from"; + } + + return getOrSet.ToString() + " " + property.ToString(); + } + + public override Color GetButtonColor() + { + return new Color32(235, 191, 217, 255); + } + + public override bool HasReference(Variable variable) + { + if (gameObjectVar == variable || inOutVar == variable) + return true; + + return false; + } + + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/Property/GameObjectProperty.cs.meta b/Assets/Fungus/Scripts/Commands/Property/GameObjectProperty.cs.meta new file mode 100644 index 0000000..1a6d413 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Property/GameObjectProperty.cs.meta @@ -0,0 +1,13 @@ +fileFormatVersion: 2 +guid: 121c2a4d38c149443adb81911f0fdd61 +timeCreated: 1517613000 +licenseType: Store +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/Property/MaterialProperty.cs b/Assets/Fungus/Scripts/Commands/Property/MaterialProperty.cs new file mode 100644 index 0000000..be1a846 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Property/MaterialProperty.cs @@ -0,0 +1,156 @@ +/*This script has been, partially or completely, generated by the Fungus.GenerateVariableWindow*/ +using UnityEngine; + + +namespace Fungus +{ + // + /// Get or Set a property of a Material component + /// + [CommandInfo("Property", + "Material", + "Get or Set a property of a Material component")] + [AddComponentMenu("")] + public class MaterialProperty : BaseVariableProperty + { + //generated property + public enum Property + { + Color, + MainTexture, + MainTextureOffset, + MainTextureScale, + RenderQueue, + DoubleSidedGI, + EnableInstancing, + PassCount, + } + + + [SerializeField] + protected Property property; + + [SerializeField] + [VariableProperty(typeof(MaterialVariable))] + protected MaterialVariable materialVar; + + [SerializeField] + [VariableProperty(typeof(ColorVariable), + typeof(TextureVariable), + typeof(Vector2Variable), + typeof(IntegerVariable), + typeof(BooleanVariable))] + protected Variable inOutVar; + + public override void OnEnter() + { + var iocol = inOutVar as ColorVariable; + var iotex = inOutVar as TextureVariable; + var iov2 = inOutVar as Vector2Variable; + var ioi = inOutVar as IntegerVariable; + var iob = inOutVar as BooleanVariable; + + + var target = materialVar.Value; + + switch (getOrSet) + { + case GetSet.Get: + switch (property) + { + case Property.Color: + iocol.Value = target.color; + break; + case Property.MainTexture: + iotex.Value = target.mainTexture; + break; + case Property.MainTextureOffset: + iov2.Value = target.mainTextureOffset; + break; + case Property.MainTextureScale: + iov2.Value = target.mainTextureScale; + break; + case Property.RenderQueue: + ioi.Value = target.renderQueue; + break; + case Property.DoubleSidedGI: + iob.Value = target.doubleSidedGI; + break; + case Property.EnableInstancing: + iob.Value = target.enableInstancing; + break; + case Property.PassCount: + ioi.Value = target.passCount; + break; + default: + Debug.Log("Unsupported get or set attempted"); + break; + } + + break; + case GetSet.Set: + switch (property) + { + case Property.Color: + target.color = iocol.Value; + break; + case Property.MainTexture: + target.mainTexture = iotex.Value; + break; + case Property.MainTextureOffset: + target.mainTextureOffset = iov2.Value; + break; + case Property.MainTextureScale: + target.mainTextureScale = iov2.Value; + break; + case Property.RenderQueue: + target.renderQueue = ioi.Value; + break; + case Property.DoubleSidedGI: + target.doubleSidedGI = iob.Value; + break; + case Property.EnableInstancing: + target.enableInstancing = iob.Value; + break; + default: + Debug.Log("Unsupported get or set attempted"); + break; + } + + break; + default: + break; + } + + Continue(); + } + + public override string GetSummary() + { + if (materialVar == null) + { + return "Error: no materialVar set"; + } + if (inOutVar == null) + { + return "Error: no variable set to push or pull data to or from"; + } + + return getOrSet.ToString() + " " + property.ToString(); + } + + public override Color GetButtonColor() + { + return new Color32(235, 191, 217, 255); + } + + public override bool HasReference(Variable variable) + { + if (materialVar == variable || inOutVar == variable) + return true; + + return false; + } + + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/Property/MaterialProperty.cs.meta b/Assets/Fungus/Scripts/Commands/Property/MaterialProperty.cs.meta new file mode 100644 index 0000000..65888d7 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Property/MaterialProperty.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 363b2ba6b0053774884b097fb9312a46 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/Property/Matrix4x4Property.cs b/Assets/Fungus/Scripts/Commands/Property/Matrix4x4Property.cs new file mode 100644 index 0000000..0c05ddd --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Property/Matrix4x4Property.cs @@ -0,0 +1,236 @@ +/*This script has been, partially or completely, generated by the Fungus.GenerateVariableWindow*/ +using UnityEngine; + + +namespace Fungus +{ + // + /// Get or Set a property of a Matrix4x4 component + /// + [CommandInfo("Property", + "Matrix4x4", + "Get or Set a property of a Matrix4x4 component")] + [AddComponentMenu("")] + public class Matrix4x4Property : BaseVariableProperty + { + //generated property + public enum Property + { + M00, + M10, + M20, + M30, + M01, + M11, + M21, + M31, + M02, + M12, + M22, + M32, + M03, + M13, + M23, + M33, + Inverse, + Transpose, + Rotation, + LossyScale, + IsIdentity, + Determinant, + } + + + [SerializeField] + protected Property property; + + [SerializeField] + protected Matrix4x4Data matrix4x4Data; + + [SerializeField] + [VariableProperty(typeof(FloatVariable), + typeof(QuaternionVariable), + typeof(Vector3Variable), + typeof(BooleanVariable), + typeof(Matrix4x4Variable))] + protected Variable inOutVar; + + public override void OnEnter() + { + var iof = inOutVar as FloatVariable; + var ioq = inOutVar as QuaternionVariable; + var iov = inOutVar as Vector3Variable; + var iob = inOutVar as BooleanVariable; + var iom4 = inOutVar as Matrix4x4Variable; + + + var target = matrix4x4Data.Value; + + switch (getOrSet) + { + case GetSet.Get: + switch (property) + { + case Property.M00: + iof.Value = target.m00; + break; + case Property.M10: + iof.Value = target.m10; + break; + case Property.M20: + iof.Value = target.m20; + break; + case Property.M30: + iof.Value = target.m30; + break; + case Property.M01: + iof.Value = target.m01; + break; + case Property.M11: + iof.Value = target.m11; + break; + case Property.M21: + iof.Value = target.m21; + break; + case Property.M31: + iof.Value = target.m31; + break; + case Property.M02: + iof.Value = target.m02; + break; + case Property.M12: + iof.Value = target.m12; + break; + case Property.M22: + iof.Value = target.m22; + break; + case Property.M32: + iof.Value = target.m32; + break; + case Property.M03: + iof.Value = target.m03; + break; + case Property.M13: + iof.Value = target.m13; + break; + case Property.M23: + iof.Value = target.m23; + break; + case Property.M33: + iof.Value = target.m33; + break; + case Property.Rotation: + ioq.Value = target.rotation; + break; + case Property.LossyScale: + iov.Value = target.lossyScale; + break; + case Property.IsIdentity: + iob.Value = target.isIdentity; + break; + case Property.Determinant: + iof.Value = target.determinant; + break; + case Property.Inverse: + iom4.Value = target.inverse; + break; + case Property.Transpose: + iom4.Value = target.transpose; + break; + default: + Debug.Log("Unsupported get or set attempted"); + break; + } + + break; + case GetSet.Set: + switch (property) + { + case Property.M00: + target.m00 = iof.Value; + break; + case Property.M10: + target.m10 = iof.Value; + break; + case Property.M20: + target.m20 = iof.Value; + break; + case Property.M30: + target.m30 = iof.Value; + break; + case Property.M01: + target.m01 = iof.Value; + break; + case Property.M11: + target.m11 = iof.Value; + break; + case Property.M21: + target.m21 = iof.Value; + break; + case Property.M31: + target.m31 = iof.Value; + break; + case Property.M02: + target.m02 = iof.Value; + break; + case Property.M12: + target.m12 = iof.Value; + break; + case Property.M22: + target.m22 = iof.Value; + break; + case Property.M32: + target.m32 = iof.Value; + break; + case Property.M03: + target.m03 = iof.Value; + break; + case Property.M13: + target.m13 = iof.Value; + break; + case Property.M23: + target.m23 = iof.Value; + break; + case Property.M33: + target.m33 = iof.Value; + break; + default: + Debug.Log("Unsupported get or set attempted"); + break; + } + + break; + default: + break; + } + + matrix4x4Data.Value = target; + + Continue(); + } + + public override string GetSummary() + { + if (inOutVar == null) + { + return "Error: no variable set to push or pull data to or from"; + } + + return getOrSet.ToString() + " " + property.ToString(); + } + + public override Color GetButtonColor() + { + return new Color32(235, 191, 217, 255); + } + + public override bool HasReference(Variable variable) + { + if (matrix4x4Data.matrix4x4Ref == variable || inOutVar == variable) + return true; + + return false; + } + + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/Property/Matrix4x4Property.cs.meta b/Assets/Fungus/Scripts/Commands/Property/Matrix4x4Property.cs.meta new file mode 100644 index 0000000..8ba12b8 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Property/Matrix4x4Property.cs.meta @@ -0,0 +1,12 @@ +fileFormatVersion: 2 +guid: 37ada407c7c9fab46abba0d40c27fa96 +timeCreated: 1513287480 +licenseType: Store +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/Property/QuaternionProperty.cs b/Assets/Fungus/Scripts/Commands/Property/QuaternionProperty.cs new file mode 100644 index 0000000..6871ba7 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Property/QuaternionProperty.cs @@ -0,0 +1,139 @@ +/*This script has been, partially or completely, generated by the Fungus.GenerateVariableWindow*/ +using UnityEngine; + + +namespace Fungus +{ + // + /// Get or Set a property of a Quaternion component + /// + [CommandInfo("Property", + "Quaternion", + "Get or Set a property of a Quaternion component")] + [AddComponentMenu("")] + public class QuaternionProperty : BaseVariableProperty + { + //generated property + public enum Property + { + X, + Y, + Z, + W, + EulerAngles, + Normalized, + } + + + [SerializeField] + protected Property property; + + [SerializeField] + protected QuaternionData quaternionData; + + [SerializeField] + [VariableProperty(typeof(FloatVariable), + typeof(Vector3Variable), + typeof(QuaternionVariable))] + protected Variable inOutVar; + + public override void OnEnter() + { + var iof = inOutVar as FloatVariable; + var iov = inOutVar as Vector3Variable; +#if UNITY_2019_2_OR_NEWER + var ioq = inOutVar as QuaternionVariable; +#endif + + + var target = quaternionData.Value; + + switch (getOrSet) + { + case GetSet.Get: + switch (property) + { + case Property.X: + iof.Value = target.x; + break; + case Property.Y: + iof.Value = target.y; + break; + case Property.Z: + iof.Value = target.z; + break; + case Property.W: + iof.Value = target.w; + break; + case Property.EulerAngles: + iov.Value = target.eulerAngles; + break; +#if UNITY_2019_2_OR_NEWER + case Property.Normalized: + ioq.Value = target.normalized; + break; +#endif + default: + Debug.Log("Unsupported get or set attempted"); + break; + } + + break; + case GetSet.Set: + switch (property) + { + case Property.X: + target.x = iof.Value; + break; + case Property.Y: + target.y = iof.Value; + break; + case Property.Z: + target.z = iof.Value; + break; + case Property.W: + target.w = iof.Value; + break; + case Property.EulerAngles: + target.eulerAngles = iov.Value; + break; + default: + Debug.Log("Unsupported get or set attempted"); + break; + } + + break; + default: + break; + } + + quaternionData.Value = target; + + Continue(); + } + + public override string GetSummary() + { + if (inOutVar == null) + { + return "Error: no variable set to push or pull data to or from"; + } + + return getOrSet.ToString() + " " + property.ToString(); + } + + public override Color GetButtonColor() + { + return new Color32(235, 191, 217, 255); + } + + public override bool HasReference(Variable variable) + { + if (quaternionData.quaternionRef == variable || inOutVar == variable) + return true; + + return false; + } + + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/Property/QuaternionProperty.cs.meta b/Assets/Fungus/Scripts/Commands/Property/QuaternionProperty.cs.meta new file mode 100644 index 0000000..313a352 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Property/QuaternionProperty.cs.meta @@ -0,0 +1,12 @@ +fileFormatVersion: 2 +guid: 1082e9a99a168824583a459d59a448a0 +timeCreated: 1513287464 +licenseType: Store +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/Property/Rigidbody2DProperty.cs b/Assets/Fungus/Scripts/Commands/Property/Rigidbody2DProperty.cs new file mode 100644 index 0000000..fd52a10 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Property/Rigidbody2DProperty.cs @@ -0,0 +1,213 @@ +/*This script has been, partially or completely, generated by the Fungus.GenerateVariableWindow*/ +using UnityEngine; + + +namespace Fungus +{ + // + /// Get or Set a property of a Rigidbody2D component + /// + [CommandInfo("Property", + "Rigidbody2D", + "Get or Set a property of a Rigidbody2D component")] + [AddComponentMenu("")] + public class Rigidbody2DProperty : BaseVariableProperty + { + //generated property + public enum Property + { + Position, + Rotation, + Velocity, + AngularVelocity, + UseAutoMass, + Mass, + CenterOfMass, + WorldCenterOfMass, + Inertia, + Drag, + AngularDrag, + GravityScale, + UseFullKinematicContacts, + IsKinematic, + FreezeRotation, + Simulated, + AttachedColliderCount, + } + + + [SerializeField] + protected Property property; + + [SerializeField] + protected Rigidbody2DData rigidbody2DData; + + [SerializeField] + [VariableProperty(typeof(Vector2Variable), + typeof(FloatVariable), + typeof(BooleanVariable), + typeof(IntegerVariable))] + protected Variable inOutVar; + + public override void OnEnter() + { + var iov2 = inOutVar as Vector2Variable; + var iof = inOutVar as FloatVariable; + var iob = inOutVar as BooleanVariable; + var ioi = inOutVar as IntegerVariable; + + + var target = rigidbody2DData.Value; + + switch (getOrSet) + { + case GetSet.Get: + switch (property) + { + case Property.Position: + iov2.Value = target.position; + break; + case Property.Rotation: + iof.Value = target.rotation; + break; + case Property.Velocity: + iov2.Value = target.velocity; + break; + case Property.AngularVelocity: + iof.Value = target.angularVelocity; + break; + case Property.UseAutoMass: + iob.Value = target.useAutoMass; + break; + case Property.Mass: + iof.Value = target.mass; + break; + case Property.CenterOfMass: + iov2.Value = target.centerOfMass; + break; + case Property.WorldCenterOfMass: + iov2.Value = target.worldCenterOfMass; + break; + case Property.Inertia: + iof.Value = target.inertia; + break; + case Property.Drag: + iof.Value = target.drag; + break; + case Property.AngularDrag: + iof.Value = target.angularDrag; + break; + case Property.GravityScale: + iof.Value = target.gravityScale; + break; + case Property.UseFullKinematicContacts: + iob.Value = target.useFullKinematicContacts; + break; + case Property.IsKinematic: + iob.Value = target.isKinematic; + break; + case Property.FreezeRotation: + iob.Value = target.freezeRotation; + break; + case Property.Simulated: + iob.Value = target.simulated; + break; + case Property.AttachedColliderCount: + ioi.Value = target.attachedColliderCount; + break; + default: + Debug.Log("Unsupported get or set attempted"); + break; + } + + break; + case GetSet.Set: + switch (property) + { + case Property.Position: + target.position = iov2.Value; + break; + case Property.Rotation: + target.rotation = iof.Value; + break; + case Property.Velocity: + target.velocity = iov2.Value; + break; + case Property.AngularVelocity: + target.angularVelocity = iof.Value; + break; + case Property.UseAutoMass: + target.useAutoMass = iob.Value; + break; + case Property.Mass: + target.mass = iof.Value; + break; + case Property.CenterOfMass: + target.centerOfMass = iov2.Value; + break; + case Property.Inertia: + target.inertia = iof.Value; + break; + case Property.Drag: + target.drag = iof.Value; + break; + case Property.AngularDrag: + target.angularDrag = iof.Value; + break; + case Property.GravityScale: + target.gravityScale = iof.Value; + break; + case Property.UseFullKinematicContacts: + target.useFullKinematicContacts = iob.Value; + break; + case Property.IsKinematic: + target.isKinematic = iob.Value; + break; + case Property.FreezeRotation: + target.freezeRotation = iob.Value; + break; + case Property.Simulated: + target.simulated = iob.Value; + break; + default: + Debug.Log("Unsupported get or set attempted"); + break; + } + + break; + default: + break; + } + + Continue(); + } + + public override string GetSummary() + { + if (rigidbody2DData.Value == null) + { + return "Error: no rigidbody2D set"; + } + if (inOutVar == null) + { + return "Error: no variable set to push or pull data to or from"; + } + + return getOrSet.ToString() + " " + property.ToString(); + } + + public override Color GetButtonColor() + { + return new Color32(235, 191, 217, 255); + } + + public override bool HasReference(Variable variable) + { + if (rigidbody2DData.rigidbody2DRef == variable || inOutVar == variable) + return true; + + return false; + } + + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/Property/Rigidbody2DProperty.cs.meta b/Assets/Fungus/Scripts/Commands/Property/Rigidbody2DProperty.cs.meta new file mode 100644 index 0000000..2dda967 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Property/Rigidbody2DProperty.cs.meta @@ -0,0 +1,13 @@ +fileFormatVersion: 2 +guid: 3e16d7fb8c3b00d4c969c48110fc69c2 +timeCreated: 1517559027 +licenseType: Store +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/Property/RigidbodyProperty.cs b/Assets/Fungus/Scripts/Commands/Property/RigidbodyProperty.cs new file mode 100644 index 0000000..1506cb4 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Property/RigidbodyProperty.cs @@ -0,0 +1,239 @@ +/*This script has been, partially or completely, generated by the Fungus.GenerateVariableWindow*/ +using UnityEngine; + + +namespace Fungus +{ + // + /// Get or Set a property of a Rigidbody component + /// + [CommandInfo("Property", + "Rigidbody", + "Get or Set a property of a Rigidbody component")] + [AddComponentMenu("")] + public class RigidbodyProperty : BaseVariableProperty + { + //generated property + public enum Property + { + Velocity, + AngularVelocity, + Drag, + AngularDrag, + Mass, + UseGravity, + MaxDepenetrationVelocity, + IsKinematic, + FreezeRotation, + CenterOfMass, + WorldCenterOfMass, + InertiaTensorRotation, + InertiaTensor, + DetectCollisions, + Position, + Rotation, + SolverIterations, + SolverVelocityIterations, + SleepThreshold, + MaxAngularVelocity, + } + + + [SerializeField] + protected Property property; + + [SerializeField] + protected RigidbodyData rigidbodyData; + + [SerializeField] + [VariableProperty(typeof(Vector3Variable), + typeof(FloatVariable), + typeof(BooleanVariable), + typeof(QuaternionVariable), + typeof(IntegerVariable))] + protected Variable inOutVar; + + public override void OnEnter() + { + var iov = inOutVar as Vector3Variable; + var iof = inOutVar as FloatVariable; + var iob = inOutVar as BooleanVariable; + var ioq = inOutVar as QuaternionVariable; + var ioi = inOutVar as IntegerVariable; + + + var target = rigidbodyData.Value; + + switch (getOrSet) + { + case GetSet.Get: + switch (property) + { + case Property.Velocity: + iov.Value = target.velocity; + break; + case Property.AngularVelocity: + iov.Value = target.angularVelocity; + break; + case Property.Drag: + iof.Value = target.drag; + break; + case Property.AngularDrag: + iof.Value = target.angularDrag; + break; + case Property.Mass: + iof.Value = target.mass; + break; + case Property.UseGravity: + iob.Value = target.useGravity; + break; + case Property.MaxDepenetrationVelocity: + iof.Value = target.maxDepenetrationVelocity; + break; + case Property.IsKinematic: + iob.Value = target.isKinematic; + break; + case Property.FreezeRotation: + iob.Value = target.freezeRotation; + break; + case Property.CenterOfMass: + iov.Value = target.centerOfMass; + break; + case Property.WorldCenterOfMass: + iov.Value = target.worldCenterOfMass; + break; + case Property.InertiaTensorRotation: + ioq.Value = target.inertiaTensorRotation; + break; + case Property.InertiaTensor: + iov.Value = target.inertiaTensor; + break; + case Property.DetectCollisions: + iob.Value = target.detectCollisions; + break; + case Property.Position: + iov.Value = target.position; + break; + case Property.Rotation: + ioq.Value = target.rotation; + break; + case Property.SolverIterations: + ioi.Value = target.solverIterations; + break; + case Property.SleepThreshold: + iof.Value = target.sleepThreshold; + break; + case Property.MaxAngularVelocity: + iof.Value = target.maxAngularVelocity; + break; + case Property.SolverVelocityIterations: + ioi.Value = target.solverVelocityIterations; + break; + default: + Debug.Log("Unsupported get or set attempted"); + break; + } + + break; + case GetSet.Set: + switch (property) + { + case Property.Velocity: + target.velocity = iov.Value; + break; + case Property.AngularVelocity: + target.angularVelocity = iov.Value; + break; + case Property.Drag: + target.drag = iof.Value; + break; + case Property.AngularDrag: + target.angularDrag = iof.Value; + break; + case Property.Mass: + target.mass = iof.Value; + break; + case Property.UseGravity: + target.useGravity = iob.Value; + break; + case Property.MaxDepenetrationVelocity: + target.maxDepenetrationVelocity = iof.Value; + break; + case Property.IsKinematic: + target.isKinematic = iob.Value; + break; + case Property.FreezeRotation: + target.freezeRotation = iob.Value; + break; + case Property.CenterOfMass: + target.centerOfMass = iov.Value; + break; + case Property.InertiaTensorRotation: + target.inertiaTensorRotation = ioq.Value; + break; + case Property.InertiaTensor: + target.inertiaTensor = iov.Value; + break; + case Property.DetectCollisions: + target.detectCollisions = iob.Value; + break; + case Property.Position: + target.position = iov.Value; + break; + case Property.Rotation: + target.rotation = ioq.Value; + break; + case Property.SolverIterations: + target.solverIterations = ioi.Value; + break; + case Property.SleepThreshold: + target.sleepThreshold = iof.Value; + break; + case Property.MaxAngularVelocity: + target.maxAngularVelocity = iof.Value; + break; + case Property.SolverVelocityIterations: + target.solverVelocityIterations = ioi.Value; + break; + default: + Debug.Log("Unsupported get or set attempted"); + break; + } + + break; + default: + break; + } + + Continue(); + } + + public override string GetSummary() + { + if (rigidbodyData.Value == null) + { + return "Error: no rigidbody set"; + } + if (inOutVar == null) + { + return "Error: no variable set to push or pull data to or from"; + } + + return getOrSet.ToString() + " " + property.ToString(); + } + + public override Color GetButtonColor() + { + return new Color32(235, 191, 217, 255); + } + + public override bool HasReference(Variable variable) + { + if (rigidbodyData.rigidbodyRef == variable || inOutVar == variable) + return true; + + return false; + } + + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/Property/RigidbodyProperty.cs.meta b/Assets/Fungus/Scripts/Commands/Property/RigidbodyProperty.cs.meta new file mode 100644 index 0000000..2f38b6f --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Property/RigidbodyProperty.cs.meta @@ -0,0 +1,13 @@ +fileFormatVersion: 2 +guid: cdf9b24957fec22439bac2223dd88461 +timeCreated: 1517558732 +licenseType: Store +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/Property/SpriteProperty.cs b/Assets/Fungus/Scripts/Commands/Property/SpriteProperty.cs new file mode 100644 index 0000000..f9f6268 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Property/SpriteProperty.cs @@ -0,0 +1,121 @@ +/*This script has been, partially or completely, generated by the Fungus.GenerateVariableWindow*/ +using UnityEngine; + + +namespace Fungus +{ + // + /// Get or Set a property of a Sprite component + /// + [CommandInfo("Property", + "Sprite", + "Get or Set a property of a Sprite component")] + [AddComponentMenu("")] + public class SpriteProperty : BaseVariableProperty + { + //generated property + public enum Property + { + Border, + PixelsPerUnit, + Pivot, + Packed, + TextureRectOffset, + } + + + [SerializeField] + protected Property property; + + [SerializeField] + [VariableProperty(typeof(SpriteVariable))] + protected SpriteVariable spriteVar; + + [SerializeField] + [VariableProperty(typeof(Vector4Variable), + typeof(FloatVariable), + typeof(Vector2Variable), + typeof(BooleanVariable))] + protected Variable inOutVar; + + public override void OnEnter() + { + var iov4 = inOutVar as Vector4Variable; + var iof = inOutVar as FloatVariable; + var iov2 = inOutVar as Vector2Variable; + var iob = inOutVar as BooleanVariable; + + + var target = spriteVar.Value; + + switch (getOrSet) + { + case GetSet.Get: + switch (property) + { + case Property.Border: + iov4.Value = target.border; + break; + case Property.PixelsPerUnit: + iof.Value = target.pixelsPerUnit; + break; + case Property.Pivot: + iov2.Value = target.pivot; + break; + case Property.Packed: + iob.Value = target.packed; + break; + case Property.TextureRectOffset: + iov2.Value = target.textureRectOffset; + break; + default: + Debug.Log("Unsupported get or set attempted"); + break; + } + + break; + case GetSet.Set: + switch (property) + { + default: + Debug.Log("Unsupported get or set attempted"); + break; + } + + break; + default: + break; + } + + Continue(); + } + + public override string GetSummary() + { + if (spriteVar == null) + { + return "Error: no spriteVar set"; + } + if (inOutVar == null) + { + return "Error: no variable set to push or pull data to or from"; + } + + return getOrSet.ToString() + " " + property.ToString(); + } + + public override Color GetButtonColor() + { + return new Color32(235, 191, 217, 255); + } + + public override bool HasReference(Variable variable) + { + if (spriteVar == variable || inOutVar == variable) + return true; + + return false; + } + + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/Property/SpriteProperty.cs.meta b/Assets/Fungus/Scripts/Commands/Property/SpriteProperty.cs.meta new file mode 100644 index 0000000..6702eb7 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Property/SpriteProperty.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: c95150ec5d3a0374ba617655d4603934 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/Property/TextureProperty.cs b/Assets/Fungus/Scripts/Commands/Property/TextureProperty.cs new file mode 100644 index 0000000..9a293cd --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Property/TextureProperty.cs @@ -0,0 +1,141 @@ +/*This script has been, partially or completely, generated by the Fungus.GenerateVariableWindow*/ +using UnityEngine; + + +namespace Fungus +{ + // + /// Get or Set a property of a Texture component + /// + [CommandInfo("Property", + "Texture", + "Get or Set a property of a Texture component")] + [AddComponentMenu("")] + public class TextureProperty : BaseVariableProperty + { + //generated property + public enum Property + { + Width, + Height, + IsReadable, + AnisoLevel, + MipMapBias, + TexelSize, + } + + + [SerializeField] + protected Property property; + + [SerializeField] + [VariableProperty(typeof(TextureVariable))] + protected TextureVariable textureVar; + + [SerializeField] + [VariableProperty(typeof(IntegerVariable), + typeof(BooleanVariable), + typeof(FloatVariable), + typeof(Vector2Variable))] + protected Variable inOutVar; + + public override void OnEnter() + { + var ioi = inOutVar as IntegerVariable; +#if UNITY_2019_2_OR_NEWER + var iob = inOutVar as BooleanVariable; +#endif + var iof = inOutVar as FloatVariable; + var iov2 = inOutVar as Vector2Variable; + + + var target = textureVar.Value; + + switch (getOrSet) + { + case GetSet.Get: + switch (property) + { + case Property.Width: + ioi.Value = target.width; + break; + case Property.Height: + ioi.Value = target.height; + break; +#if UNITY_2019_2_OR_NEWER + case Property.IsReadable: + iob.Value = target.isReadable; + break; +#endif + case Property.AnisoLevel: + ioi.Value = target.anisoLevel; + break; + case Property.MipMapBias: + iof.Value = target.mipMapBias; + break; + case Property.TexelSize: + iov2.Value = target.texelSize; + break; + default: + Debug.Log("Unsupported get or set attempted"); + break; + } + + break; + case GetSet.Set: + switch (property) + { + case Property.Width: + target.width = ioi.Value; + break; + case Property.Height: + target.height = ioi.Value; + break; + case Property.AnisoLevel: + target.anisoLevel = ioi.Value; + break; + case Property.MipMapBias: + target.mipMapBias = iof.Value; + break; + default: + Debug.Log("Unsupported get or set attempted"); + break; + } + + break; + default: + break; + } + + Continue(); + } + + public override string GetSummary() + { + if (textureVar == null) + { + return "Error: no textureVar set"; + } + if (inOutVar == null) + { + return "Error: no variable set to push or pull data to or from"; + } + + return getOrSet.ToString() + " " + property.ToString(); + } + + public override Color GetButtonColor() + { + return new Color32(235, 191, 217, 255); + } + + public override bool HasReference(Variable variable) + { + if (textureVar == variable || inOutVar == variable) + return true; + + return false; + } + + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/Property/TextureProperty.cs.meta b/Assets/Fungus/Scripts/Commands/Property/TextureProperty.cs.meta new file mode 100644 index 0000000..3da4179 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Property/TextureProperty.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 31b49af150726234597bd728285c18f9 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/Property/TransformProperty.cs b/Assets/Fungus/Scripts/Commands/Property/TransformProperty.cs new file mode 100644 index 0000000..af51c0c --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Property/TransformProperty.cs @@ -0,0 +1,223 @@ +/*This script has been, partially or completely, generated by the Fungus.GenerateVariableWindow*/ + +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using System.Collections; +using System.Collections.Generic; +using UnityEngine; + +namespace Fungus +{ + // + /// Get or Set a property of a Transform component + /// + [CommandInfo("Property", + "Transform", + "Get or Set a property of a Transform component")] + [AddComponentMenu("")] + public class TransformProperty : BaseVariableProperty + { + //generated property + public enum Property + { + ChildCount, + EulerAngles, + Forward, + HasChanged, + HierarchyCapacity, + HierarchyCount, + LocalEulerAngles, + LocalPosition, + LocalScale, + LossyScale, + Parent, + Position, + Right, + Root, + Up, + Rotation, + LocalRotation, + WorldToLocalMatrix, + LocalToWorldMatrix, + } + + + [SerializeField] + protected Property property = Property.Position; + + [SerializeField] + protected TransformData transformData; + + [SerializeField] + [VariableProperty(typeof(Vector3Variable), + typeof(QuaternionVariable), + typeof(TransformVariable), + typeof(Matrix4x4Variable), + typeof(IntegerVariable), + typeof(BooleanVariable))] + protected Variable inOutVar; + + public override void OnEnter() + { + var iov = inOutVar as Vector3Variable; + var ioq = inOutVar as QuaternionVariable; + var iot = inOutVar as TransformVariable; + var iom4 = inOutVar as Matrix4x4Variable; + var ioi = inOutVar as IntegerVariable; + var iob = inOutVar as BooleanVariable; + + var target = transformData.Value; + + switch (getOrSet) + { + case GetSet.Get: + switch (property) + { + case Property.Position: + iov.Value = target.position; + break; + case Property.LocalPosition: + iov.Value = target.localPosition; + break; + case Property.EulerAngles: + iov.Value = target.eulerAngles; + break; + case Property.LocalEulerAngles: + iov.Value = target.localEulerAngles; + break; + case Property.Right: + iov.Value = target.right; + break; + case Property.Up: + iov.Value = target.up; + break; + case Property.Forward: + iov.Value = target.forward; + break; + case Property.Rotation: + ioq.Value = target.rotation; + break; + case Property.LocalRotation: + ioq.Value = target.localRotation; + break; + case Property.LocalScale: + iov.Value = target.localScale; + break; + case Property.Parent: + iot.Value = target.parent; + break; + case Property.WorldToLocalMatrix: + iom4.Value = target.worldToLocalMatrix; + break; + case Property.LocalToWorldMatrix: + iom4.Value = target.localToWorldMatrix; + break; + case Property.Root: + iot.Value = target.root; + break; + case Property.ChildCount: + ioi.Value = target.childCount; + break; + case Property.LossyScale: + iov.Value = target.lossyScale; + break; + case Property.HasChanged: + iob.Value = target.hasChanged; + break; + case Property.HierarchyCapacity: + ioi.Value = target.hierarchyCapacity; + break; + case Property.HierarchyCount: + ioi.Value = target.hierarchyCount; + break; + default: + Debug.Log("Unsupported get or set attempted"); + break; + } + break; + case GetSet.Set: + switch (property) + { + case Property.Position: + target.position = iov.Value; + break; + case Property.LocalPosition: + target.localPosition = iov.Value; + break; + case Property.EulerAngles: + target.eulerAngles = iov.Value; + break; + case Property.LocalEulerAngles: + target.localEulerAngles = iov.Value; + break; + case Property.Right: + target.right = iov.Value; + break; + case Property.Up: + target.up = iov.Value; + break; + case Property.Forward: + target.forward = iov.Value; + break; + case Property.Rotation: + target.rotation = ioq.Value; + break; + case Property.LocalRotation: + target.localRotation = ioq.Value; + break; + case Property.LocalScale: + target.localScale = iov.Value; + break; + case Property.Parent: + target.parent = iot.Value; + break; + case Property.HasChanged: + target.hasChanged = iob.Value; + break; + case Property.HierarchyCapacity: + target.hierarchyCapacity = ioi.Value; + break; + default: + Debug.Log("Unsupported get or set attempted"); + break; + } + break; + default: + break; + } + + Continue(); + } + + public override string GetSummary() + { + if (transformData.Value == null) + { + return "Error: no transform set"; + } + if (inOutVar == null) + { + return "Error: no variable set to push or pull data to or from"; + } + + //We could do further checks here, eg, you have selected childcount but set a vec3variable + + return getOrSet.ToString() + " " + property.ToString(); + } + + public override Color GetButtonColor() + { + return new Color32(235, 191, 217, 255); + } + + public override bool HasReference(Variable variable) + { + if (transformData.transformRef == variable || inOutVar == variable) + return true; + + return false; + } + + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/Property/TransformProperty.cs.meta b/Assets/Fungus/Scripts/Commands/Property/TransformProperty.cs.meta new file mode 100644 index 0000000..55c0827 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Property/TransformProperty.cs.meta @@ -0,0 +1,12 @@ +fileFormatVersion: 2 +guid: 2fb064de1b711a449845627f19b7f7b1 +timeCreated: 1504942828 +licenseType: Store +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/Property/Vector2Property.cs b/Assets/Fungus/Scripts/Commands/Property/Vector2Property.cs new file mode 100644 index 0000000..e4a4f2a --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Property/Vector2Property.cs @@ -0,0 +1,121 @@ +/*This script has been, partially or completely, generated by the Fungus.GenerateVariableWindow*/ +using UnityEngine; + + +namespace Fungus +{ + // + /// Get or Set a property of a Vector2 component + /// + [CommandInfo("Property", + "Vector2", + "Get or Set a property of a Vector2 component")] + [AddComponentMenu("")] + public class Vector2Property : BaseVariableProperty + { + //generated property + public enum Property + { + X, + Y, + Normalized, + Magnitude, + SqrMagnitude, + } + + + [SerializeField] + protected Property property; + + [SerializeField] + [VariableProperty(typeof(Vector2Variable))] + protected Vector2Variable vector2Var; + + [SerializeField] + [VariableProperty(typeof(FloatVariable), + typeof(Vector2Variable))] + protected Variable inOutVar; + + public override void OnEnter() + { + var iof = inOutVar as FloatVariable; + var iov2 = inOutVar as Vector2Variable; + + + var target = vector2Var.Value; + + switch (getOrSet) + { + case GetSet.Get: + switch (property) + { + case Property.X: + iof.Value = target.x; + break; + case Property.Y: + iof.Value = target.y; + break; + case Property.Normalized: + iov2.Value = target.normalized; + break; + case Property.Magnitude: + iof.Value = target.magnitude; + break; + case Property.SqrMagnitude: + iof.Value = target.sqrMagnitude; + break; + default: + Debug.Log("Unsupported get or set attempted"); + break; + } + + break; + case GetSet.Set: + switch (property) + { + case Property.X: + target.x = iof.Value; + break; + case Property.Y: + target.y = iof.Value; + break; + default: + Debug.Log("Unsupported get or set attempted"); + break; + } + + break; + default: + break; + } + + vector2Var.Value = target; + + Continue(); + } + + public override string GetSummary() + { + if (inOutVar == null) + { + return "Error: no variable set to push or pull data to or from"; + } + + return getOrSet.ToString() + " " + property.ToString(); + } + + public override Color GetButtonColor() + { + return new Color32(235, 191, 217, 255); + } + + public override bool HasReference(Variable variable) + { + if (vector2Var == variable || inOutVar == variable) + return true; + + return false; + } + + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/Property/Vector2Property.cs.meta b/Assets/Fungus/Scripts/Commands/Property/Vector2Property.cs.meta new file mode 100644 index 0000000..3f9cb9c --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Property/Vector2Property.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: a7015dec6a71cdd4ba95bb85217200b5 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/Property/Vector3Property.cs b/Assets/Fungus/Scripts/Commands/Property/Vector3Property.cs new file mode 100644 index 0000000..f80e0a8 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Property/Vector3Property.cs @@ -0,0 +1,128 @@ +/*This script has been, partially or completely, generated by the Fungus.GenerateVariableWindow*/ +using UnityEngine; + + +namespace Fungus +{ + // + /// Get or Set a property of a Vector3 component + /// + [CommandInfo("Property", + "Vector3", + "Get or Set a property of a Vector3 component")] + [AddComponentMenu("")] + public class Vector3Property : BaseVariableProperty + { + //generated property + public enum Property + { + X, + Y, + Z, + Normalized, + Magnitude, + SqrMagnitude, + } + + + [SerializeField] + protected Property property; + + [SerializeField] + [VariableProperty(typeof(Vector3Variable))] + protected Vector3Variable vector3Var; + + [SerializeField] + [VariableProperty(typeof(FloatVariable), + typeof(Vector3Variable))] + protected Variable inOutVar; + + public override void OnEnter() + { + var iof = inOutVar as FloatVariable; + var iov = inOutVar as Vector3Variable; + + + var target = vector3Var.Value; + + switch (getOrSet) + { + case GetSet.Get: + switch (property) + { + case Property.X: + iof.Value = target.x; + break; + case Property.Y: + iof.Value = target.y; + break; + case Property.Z: + iof.Value = target.z; + break; + case Property.Normalized: + iov.Value = target.normalized; + break; + case Property.Magnitude: + iof.Value = target.magnitude; + break; + case Property.SqrMagnitude: + iof.Value = target.sqrMagnitude; + break; + default: + Debug.Log("Unsupported get or set attempted"); + break; + } + + break; + case GetSet.Set: + switch (property) + { + case Property.X: + target.x = iof.Value; + break; + case Property.Y: + target.y = iof.Value; + break; + case Property.Z: + target.z = iof.Value; + break; + default: + Debug.Log("Unsupported get or set attempted"); + break; + } + + break; + default: + break; + } + + vector3Var.Value = target; + + Continue(); + } + + public override string GetSummary() + { + if (inOutVar == null) + { + return "Error: no variable set to push or pull data to or from"; + } + + return getOrSet.ToString() + " " + property.ToString(); + } + + public override Color GetButtonColor() + { + return new Color32(235, 191, 217, 255); + } + + public override bool HasReference(Variable variable) + { + if (vector3Var == variable || inOutVar == variable) + return true; + + return false; + } + + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/Property/Vector3Property.cs.meta b/Assets/Fungus/Scripts/Commands/Property/Vector3Property.cs.meta new file mode 100644 index 0000000..79e8c09 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Property/Vector3Property.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: c9d421d283ce7de459ab56214f315618 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/Property/Vector4Property.cs b/Assets/Fungus/Scripts/Commands/Property/Vector4Property.cs new file mode 100644 index 0000000..7720c84 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Property/Vector4Property.cs @@ -0,0 +1,135 @@ +/*This script has been, partially or completely, generated by the Fungus.GenerateVariableWindow*/ +using UnityEngine; + + +namespace Fungus +{ + // + /// Get or Set a property of a Vector4 component + /// + [CommandInfo("Property", + "Vector4", + "Get or Set a property of a Vector4 component")] + [AddComponentMenu("")] + public class Vector4Property : BaseVariableProperty + { + //generated property + public enum Property + { + X, + Y, + Z, + W, + Magnitude, + SqrMagnitude, + Normalized, + } + + + [SerializeField] + protected Property property; + + [SerializeField] + protected Vector4Data vector4Data; + + [SerializeField] + [VariableProperty(typeof(FloatVariable), + typeof(Vector4Variable))] + protected Variable inOutVar; + + public override void OnEnter() + { + var iof = inOutVar as FloatVariable; + var iov4 = inOutVar as Vector4Variable; + + + var target = vector4Data.Value; + + switch (getOrSet) + { + case GetSet.Get: + switch (property) + { + case Property.X: + iof.Value = target.x; + break; + case Property.Y: + iof.Value = target.y; + break; + case Property.Z: + iof.Value = target.z; + break; + case Property.W: + iof.Value = target.w; + break; + case Property.Normalized: + iov4.Value = target.normalized; + break; + case Property.Magnitude: + iof.Value = target.magnitude; + break; + case Property.SqrMagnitude: + iof.Value = target.sqrMagnitude; + break; + default: + Debug.Log("Unsupported get or set attempted"); + break; + } + + break; + case GetSet.Set: + switch (property) + { + case Property.X: + target.x = iof.Value; + break; + case Property.Y: + target.y = iof.Value; + break; + case Property.Z: + target.z = iof.Value; + break; + case Property.W: + target.w = iof.Value; + break; + default: + Debug.Log("Unsupported get or set attempted"); + break; + } + + break; + default: + break; + } + + + vector4Data.Value = target; + + Continue(); + } + + public override string GetSummary() + { + if (inOutVar == null) + { + return "Error: no variable set to push or pull data to or from"; + } + + return getOrSet.ToString() + " " + property.ToString(); + } + + public override Color GetButtonColor() + { + return new Color32(235, 191, 217, 255); + } + + public override bool HasReference(Variable variable) + { + if (vector4Data.vector4Ref == variable || inOutVar == variable) + return true; + + return false; + } + + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/Property/Vector4Property.cs.meta b/Assets/Fungus/Scripts/Commands/Property/Vector4Property.cs.meta new file mode 100644 index 0000000..7722dec --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Property/Vector4Property.cs.meta @@ -0,0 +1,13 @@ +fileFormatVersion: 2 +guid: 218837ae2b5d9ad4cb51c47575ce1ffc +timeCreated: 1517559329 +licenseType: Store +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/PunchPosition.cs b/Assets/Fungus/Scripts/Commands/PunchPosition.cs new file mode 100644 index 0000000..f2250c2 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/PunchPosition.cs @@ -0,0 +1,67 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; +using UnityEngine.Serialization; +using System.Collections; + +namespace Fungus +{ + /// + /// Applies a jolt of force to a GameObject's position and wobbles it back to its initial position. + /// + [CommandInfo("iTween", + "Punch Position", + "Applies a jolt of force to a GameObject's position and wobbles it back to its initial position.")] + [AddComponentMenu("")] + [ExecuteInEditMode] + public class PunchPosition : iTweenCommand + { + [Tooltip("A translation offset in space the GameObject will animate to")] + [SerializeField] protected Vector3Data _amount; + + [Tooltip("Apply the transformation in either the world coordinate or local cordinate system")] + [SerializeField] protected Space space = Space.Self; + + #region Public members + + public override void DoTween() + { + Hashtable tweenParams = new Hashtable(); + tweenParams.Add("name", _tweenName.Value); + tweenParams.Add("amount", _amount.Value); + tweenParams.Add("space", space); + tweenParams.Add("time", _duration.Value); + tweenParams.Add("easetype", easeType); + tweenParams.Add("looptype", loopType); + tweenParams.Add("oncomplete", "OniTweenComplete"); + tweenParams.Add("oncompletetarget", gameObject); + tweenParams.Add("oncompleteparams", this); + iTween.PunchPosition(_targetObject.Value, tweenParams); + } + + public override bool HasReference(Variable variable) + { + return variable == _amount.vector3Ref; + } + + #endregion + + #region Backwards compatibility + + [HideInInspector] [FormerlySerializedAs("amount")] public Vector3 amountOLD; + + protected override void OnEnable() + { + base.OnEnable(); + + if (amountOLD != default(Vector3)) + { + _amount.Value = amountOLD; + amountOLD = default(Vector3); + } + } + + #endregion + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/PunchPosition.cs.meta b/Assets/Fungus/Scripts/Commands/PunchPosition.cs.meta new file mode 100644 index 0000000..b553cf1 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/PunchPosition.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 720f059c883c4402c89fcc507d5f7e0d +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Fungus/Scripts/Commands/PunchRotation.cs b/Assets/Fungus/Scripts/Commands/PunchRotation.cs new file mode 100644 index 0000000..1a04d3d --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/PunchRotation.cs @@ -0,0 +1,67 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; +using UnityEngine.Serialization; +using System.Collections; + +namespace Fungus +{ + /// + /// Applies a jolt of force to a GameObject's rotation and wobbles it back to its initial rotation. + /// + [CommandInfo("iTween", + "Punch Rotation", + "Applies a jolt of force to a GameObject's rotation and wobbles it back to its initial rotation.")] + [AddComponentMenu("")] + [ExecuteInEditMode] + public class PunchRotation : iTweenCommand + { + [Tooltip("A rotation offset in space the GameObject will animate to")] + [SerializeField] protected Vector3Data _amount; + + [Tooltip("Apply the transformation in either the world coordinate or local cordinate system")] + [SerializeField] protected Space space = Space.Self; + + #region Public members + + public override void DoTween() + { + Hashtable tweenParams = new Hashtable(); + tweenParams.Add("name", _tweenName.Value); + tweenParams.Add("amount", _amount.Value); + tweenParams.Add("space", space); + tweenParams.Add("time", _duration.Value); + tweenParams.Add("easetype", easeType); + tweenParams.Add("looptype", loopType); + tweenParams.Add("oncomplete", "OniTweenComplete"); + tweenParams.Add("oncompletetarget", gameObject); + tweenParams.Add("oncompleteparams", this); + iTween.PunchRotation(_targetObject.Value, tweenParams); + } + + public override bool HasReference(Variable variable) + { + return variable == _amount.vector3Ref; + } + + #endregion + + #region Backwards compatibility + + [HideInInspector] [FormerlySerializedAs("amount")] public Vector3 amountOLD; + + protected override void OnEnable() + { + base.OnEnable(); + + if (amountOLD != default(Vector3)) + { + _amount.Value = amountOLD; + amountOLD = default(Vector3); + } + } + + #endregion + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/PunchRotation.cs.meta b/Assets/Fungus/Scripts/Commands/PunchRotation.cs.meta new file mode 100644 index 0000000..106e8f2 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/PunchRotation.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: ea1bc1400ac79424ba3c1aca77fb5d42 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Fungus/Scripts/Commands/PunchScale.cs b/Assets/Fungus/Scripts/Commands/PunchScale.cs new file mode 100644 index 0000000..2d64298 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/PunchScale.cs @@ -0,0 +1,63 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; +using UnityEngine.Serialization; +using System.Collections; + +namespace Fungus +{ + /// + /// Applies a jolt of force to a GameObject's scale and wobbles it back to its initial scale. + /// + [CommandInfo("iTween", + "Punch Scale", + "Applies a jolt of force to a GameObject's scale and wobbles it back to its initial scale.")] + [AddComponentMenu("")] + [ExecuteInEditMode] + public class PunchScale : iTweenCommand + { + [Tooltip("A scale offset in space the GameObject will animate to")] + [SerializeField] protected Vector3Data _amount; + + #region Public members + + public override void DoTween() + { + Hashtable tweenParams = new Hashtable(); + tweenParams.Add("name", _tweenName.Value); + tweenParams.Add("amount", _amount.Value); + tweenParams.Add("time", _duration.Value); + tweenParams.Add("easetype", easeType); + tweenParams.Add("looptype", loopType); + tweenParams.Add("oncomplete", "OniTweenComplete"); + tweenParams.Add("oncompletetarget", gameObject); + tweenParams.Add("oncompleteparams", this); + iTween.PunchScale(_targetObject.Value, tweenParams); + } + + public override bool HasReference(Variable variable) + { + return variable == _amount.vector3Ref; + } + + #endregion + + #region Backwards compatibility + + [HideInInspector] [FormerlySerializedAs("amount")] public Vector3 amountOLD; + + protected override void OnEnable() + { + base.OnEnable(); + + if (amountOLD != default(Vector3)) + { + _amount.Value = amountOLD; + amountOLD = default(Vector3); + } + } + + #endregion + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/PunchScale.cs.meta b/Assets/Fungus/Scripts/Commands/PunchScale.cs.meta new file mode 100644 index 0000000..4e67539 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/PunchScale.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: ea4591c01defd496586e9b7237c966c5 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Fungus/Scripts/Commands/Quit.cs b/Assets/Fungus/Scripts/Commands/Quit.cs new file mode 100644 index 0000000..c017275 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Quit.cs @@ -0,0 +1,34 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; + +namespace Fungus +{ + /// + /// Quits the application. Does not work in Editor or Webplayer builds. Shouldn't generally be used on iOS. + /// + [CommandInfo("Flow", + "Quit", + "Quits the application. Does not work in Editor or Webplayer builds. Shouldn't generally be used on iOS.")] + [AddComponentMenu("")] + public class Quit : Command + { + #region Public members + + public override void OnEnter() + { + Application.Quit(); + + // On platforms that don't support Quit we just continue onto the next command + Continue(); + } + + public override Color GetButtonColor() + { + return new Color32(235, 191, 217, 255); + } + + #endregion + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/Quit.cs.meta b/Assets/Fungus/Scripts/Commands/Quit.cs.meta new file mode 100644 index 0000000..7df3ae9 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Quit.cs.meta @@ -0,0 +1,12 @@ +fileFormatVersion: 2 +guid: 3e1337544a71d4d5dab5510fe86ddca8 +timeCreated: 1434462164 +licenseType: Store +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/RandomFloat.cs b/Assets/Fungus/Scripts/Commands/RandomFloat.cs new file mode 100644 index 0000000..6eec223 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/RandomFloat.cs @@ -0,0 +1,61 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; + +namespace Fungus +{ + /// + /// Sets an float variable to a random value in the defined range. + /// + [CommandInfo("Variable", + "Random Float", + "Sets an float variable to a random value in the defined range.")] + [AddComponentMenu("")] + public class RandomFloat : Command + { + [Tooltip("The variable whos value will be set")] + [VariableProperty(typeof(FloatVariable))] + [SerializeField] protected FloatVariable variable; + + [Tooltip("Minimum value for random range")] + [SerializeField] protected FloatData minValue; + + [Tooltip("Maximum value for random range")] + [SerializeField] protected FloatData maxValue; + + #region Public members + + public override void OnEnter() + { + if (variable != null) + { + variable.Value = Random.Range(minValue.Value, maxValue.Value); + } + + Continue(); + } + + public override string GetSummary() + { + if (variable == null) + { + return "Error: Variable not selected"; + } + + return variable.Key; + } + + public override bool HasReference(Variable variable) + { + return (variable == this.variable) || minValue.floatRef == variable || maxValue.floatRef == variable; + } + + public override Color GetButtonColor() + { + return new Color32(253, 253, 150, 255); + } + + #endregion + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/RandomFloat.cs.meta b/Assets/Fungus/Scripts/Commands/RandomFloat.cs.meta new file mode 100644 index 0000000..74be332 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/RandomFloat.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 0ce1a662ad70c46f4b2de306ed2627a2 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Fungus/Scripts/Commands/RandomInteger.cs b/Assets/Fungus/Scripts/Commands/RandomInteger.cs new file mode 100644 index 0000000..f90b307 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/RandomInteger.cs @@ -0,0 +1,61 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; + +namespace Fungus +{ + /// + /// Sets an integer variable to a random value in the defined range. + /// + [CommandInfo("Variable", + "Random Integer", + "Sets an integer variable to a random value in the defined range.")] + [AddComponentMenu("")] + public class RandomInteger : Command + { + [Tooltip("The variable whos value will be set")] + [VariableProperty(typeof(IntegerVariable))] + [SerializeField] protected IntegerVariable variable; + + [Tooltip("Minimum value for random range")] + [SerializeField] protected IntegerData minValue; + + [Tooltip("Maximum value for random range")] + [SerializeField] protected IntegerData maxValue; + + #region Public members + + public override void OnEnter() + { + if (variable != null) + { + variable.Value = Random.Range(minValue.Value, maxValue.Value); + } + + Continue(); + } + + public override string GetSummary() + { + if (variable == null) + { + return "Error: Variable not selected"; + } + + return variable.Key; + } + + public override bool HasReference(Variable variable) + { + return (variable == this.variable) || minValue.integerRef == variable || maxValue.integerRef == variable; + } + + public override Color GetButtonColor() + { + return new Color32(253, 253, 150, 255); + } + + #endregion + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/RandomInteger.cs.meta b/Assets/Fungus/Scripts/Commands/RandomInteger.cs.meta new file mode 100644 index 0000000..6bee06f --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/RandomInteger.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 6af5dac98b0624702b476c1eac319eab +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Fungus/Scripts/Commands/ReadTextFile.cs b/Assets/Fungus/Scripts/Commands/ReadTextFile.cs new file mode 100644 index 0000000..10f58bb --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/ReadTextFile.cs @@ -0,0 +1,67 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; +using Fungus; + +namespace Fungus +{ + /// + /// Reads in a text file and stores the contents in a string variable. + /// + [CommandInfo("Variable", + "Read Text File", + "Reads in a text file and stores the contents in a string variable")] + public class ReadTextFile : Command + { + [Tooltip("Text file to read into the string variable")] + [SerializeField] protected TextAsset textFile; + + [Tooltip("String variable to store the tex file contents in")] + [VariableProperty(typeof(StringVariable))] + [SerializeField] protected StringVariable stringVariable; + + #region Public members + + public override void OnEnter() + { + if (textFile == null || + stringVariable == null) + { + Continue(); + return; + } + + stringVariable.Value = textFile.text; + + Continue(); + } + + public override string GetSummary() + { + if (stringVariable == null) + { + return "Error: Variable not selected"; + } + + if (textFile == null) + { + return "Error: Text file not selected"; + } + + return stringVariable.Key; + } + + public override bool HasReference(Variable variable) + { + return (variable == stringVariable); + } + + public override Color GetButtonColor() + { + return new Color32(253, 253, 150, 255); + } + + #endregion + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/ReadTextFile.cs.meta b/Assets/Fungus/Scripts/Commands/ReadTextFile.cs.meta new file mode 100644 index 0000000..afcc453 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/ReadTextFile.cs.meta @@ -0,0 +1,12 @@ +fileFormatVersion: 2 +guid: 1c0d03b6eb503400fab7982a48c8a93a +timeCreated: 1445960955 +licenseType: Store +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/Reset.cs b/Assets/Fungus/Scripts/Commands/Reset.cs new file mode 100644 index 0000000..2dce3a3 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Reset.cs @@ -0,0 +1,38 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; + +namespace Fungus +{ + /// + /// Resets the state of all commands and variables in the Flowchart. + /// + [CommandInfo("Variable", + "Reset", + "Resets the state of all commands and variables in the Flowchart.")] + [AddComponentMenu("")] + public class Reset : Command + { + [Tooltip("Reset state of all commands in the script")] + [SerializeField] protected bool resetCommands = true; + + [Tooltip("Reset variables back to their default values")] + [SerializeField] protected bool resetVariables = true; + + #region Public members + + public override void OnEnter() + { + GetFlowchart().Reset(resetCommands, resetVariables); + Continue(); + } + + public override Color GetButtonColor() + { + return new Color32(235, 191, 217, 255); + } + + #endregion + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/Reset.cs.meta b/Assets/Fungus/Scripts/Commands/Reset.cs.meta new file mode 100644 index 0000000..f588609 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Reset.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 0000066e72e484959b6a314a95d0dcd2 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Fungus/Scripts/Commands/ResetAnimTrigger.cs b/Assets/Fungus/Scripts/Commands/ResetAnimTrigger.cs new file mode 100644 index 0000000..56ef180 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/ResetAnimTrigger.cs @@ -0,0 +1,82 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; +using UnityEngine.Serialization; + +namespace Fungus +{ + /// + /// Resets a trigger parameter on an Animator component. + /// + [CommandInfo("Animation", + "Reset Anim Trigger", + "Resets a trigger parameter on an Animator component.")] + [AddComponentMenu("")] + [ExecuteInEditMode] + public class ResetAnimTrigger : Command + { + [Tooltip("Reference to an Animator component in a game object")] + [SerializeField] protected AnimatorData _animator; + + [Tooltip("Name of the trigger Animator parameter that will be reset")] + [SerializeField] protected StringData _parameterName; + + #region Public members + + public override void OnEnter() + { + if (_animator.Value != null) + { + _animator.Value.ResetTrigger(_parameterName.Value); + } + + Continue(); + } + + public override string GetSummary() + { + if (_animator.Value == null) + { + return "Error: No animator selected"; + } + + return _animator.Value.name + " (" + _parameterName.Value + ")"; + } + + public override Color GetButtonColor() + { + return new Color32(170, 204, 169, 255); + } + + public override bool HasReference(Variable variable) + { + return _animator.animatorRef == variable || _parameterName.stringRef == variable || + base.HasReference(variable); + } + + #endregion + + #region Backwards compatibility + + [HideInInspector] [FormerlySerializedAs("animator")] public Animator animatorOLD; + [HideInInspector] [FormerlySerializedAs("parameterName")] public string parameterNameOLD = ""; + + protected virtual void OnEnable() + { + if (animatorOLD != null) + { + _animator.Value = animatorOLD; + animatorOLD = null; + } + + if (parameterNameOLD != "") + { + _parameterName.Value = parameterNameOLD; + parameterNameOLD = ""; + } + } + + #endregion + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/ResetAnimTrigger.cs.meta b/Assets/Fungus/Scripts/Commands/ResetAnimTrigger.cs.meta new file mode 100644 index 0000000..58e2c78 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/ResetAnimTrigger.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: acc125538d5aa46fb95fc7a78036d167 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Fungus/Scripts/Commands/Rigidbody2D.meta b/Assets/Fungus/Scripts/Commands/Rigidbody2D.meta new file mode 100644 index 0000000..e6c4352 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Rigidbody2D.meta @@ -0,0 +1,9 @@ +fileFormatVersion: 2 +guid: 168ad11319df4784eaaf28cf8e564365 +folderAsset: yes +timeCreated: 1503731365 +licenseType: Store +DefaultImporter: + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/Rigidbody2D/AddForce2D.cs b/Assets/Fungus/Scripts/Commands/Rigidbody2D/AddForce2D.cs new file mode 100644 index 0000000..626124b --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Rigidbody2D/AddForce2D.cs @@ -0,0 +1,88 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using System.Collections; +using System.Collections.Generic; +using UnityEngine; + +namespace Fungus +{ + // + /// Add force to a Rigidbody2D + /// + [CommandInfo("Rigidbody2D", + "AddForce2D", + "Add force to a Rigidbody2D")] + [AddComponentMenu("")] + public class AddForce2D : Command + { + [SerializeField] + protected Rigidbody2DData rb; + + [SerializeField] + protected ForceMode2D forceMode = ForceMode2D.Force; + + public enum ForceFunction + { + AddForce, + AddForceAtPosition, + AddRelativeForce + } + + [SerializeField] + protected ForceFunction forceFunction = ForceFunction.AddForce; + + [Tooltip("Vector of force to be added")] + [SerializeField] + protected Vector2Data force; + + [Tooltip("Scale factor to be applied to force as it is used.")] + [SerializeField] + protected FloatData forceScaleFactor = new FloatData(1); + + [Tooltip("World position the force is being applied from. Used only in AddForceAtPosition")] + [SerializeField] + protected Vector2Data atPosition; + + public override void OnEnter() + { + switch (forceFunction) + { + case ForceFunction.AddForce: + rb.Value.AddForce(force.Value * forceScaleFactor.Value, forceMode); + break; + case ForceFunction.AddForceAtPosition: + rb.Value.AddForceAtPosition(force.Value * forceScaleFactor.Value, atPosition.Value, forceMode); + break; + case ForceFunction.AddRelativeForce: + rb.Value.AddRelativeForce(force.Value * forceScaleFactor.Value, forceMode); + break; + default: + break; + } + + + Continue(); + } + + public override string GetSummary() + { + return forceMode.ToString() + ": " + force.ToString(); + } + + public override Color GetButtonColor() + { + return new Color32(235, 191, 217, 255); + } + + public override bool HasReference(Variable variable) + { + if (rb.rigidbody2DRef == variable || force.vector2Ref == variable || forceScaleFactor.floatRef == variable || + atPosition.vector2Ref == variable) + return true; + + return false; + } + + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/Rigidbody2D/AddForce2D.cs.meta b/Assets/Fungus/Scripts/Commands/Rigidbody2D/AddForce2D.cs.meta new file mode 100644 index 0000000..8c5a4be --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Rigidbody2D/AddForce2D.cs.meta @@ -0,0 +1,12 @@ +fileFormatVersion: 2 +guid: 59927941e3d79be4dac4408058904465 +timeCreated: 1503094848 +licenseType: Store +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/Rigidbody2D/AddTorque2D.cs b/Assets/Fungus/Scripts/Commands/Rigidbody2D/AddTorque2D.cs new file mode 100644 index 0000000..bfc2304 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Rigidbody2D/AddTorque2D.cs @@ -0,0 +1,59 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using System.Collections; +using System.Collections.Generic; +using UnityEngine; + +namespace Fungus +{ + // + /// Add Torque to a Rigidbody2D + /// + [CommandInfo("Rigidbody2D", + "AddTorque2D", + "Add Torque to a Rigidbody2D")] + [AddComponentMenu("")] + public class AddTorque2D : Command + { + [SerializeField] + protected Rigidbody2DData rb; + + [SerializeField] + protected ForceMode2D forceMode = ForceMode2D.Force; + + [Tooltip("Amount of torque to be added")] + [SerializeField] + protected FloatData force; + + public override void OnEnter() + { + rb.Value.AddTorque(force.Value, forceMode); + + Continue(); + } + + public override string GetSummary() + { + if (rb.Value == null) + { + return "Error: rb not set"; + } + + return forceMode.ToString() + ": " + force.Value.ToString() + (force.floatRef != null ? " (" + force.floatRef.Key + ")" : ""); + } + + public override Color GetButtonColor() + { + return new Color32(235, 191, 217, 255); + } + + public override bool HasReference(Variable variable) + { + if (rb.rigidbody2DRef == variable || force.floatRef == variable) + return true; + + return false; + } + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/Rigidbody2D/AddTorque2D.cs.meta b/Assets/Fungus/Scripts/Commands/Rigidbody2D/AddTorque2D.cs.meta new file mode 100644 index 0000000..54af337 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Rigidbody2D/AddTorque2D.cs.meta @@ -0,0 +1,12 @@ +fileFormatVersion: 2 +guid: 42fb61d4cee69b244bcf4fcc8e4ae28b +timeCreated: 1503744011 +licenseType: Store +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/Rigidbody2D/StopMotionRigidBody2D.cs b/Assets/Fungus/Scripts/Commands/Rigidbody2D/StopMotionRigidBody2D.cs new file mode 100644 index 0000000..6f5f92b --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Rigidbody2D/StopMotionRigidBody2D.cs @@ -0,0 +1,72 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using System.Collections; +using System.Collections.Generic; +using UnityEngine; + +namespace Fungus +{ + // + /// Stop velocity and angular velocity on a Rigidbody2D + /// + [CommandInfo("Rigidbody2D", + "StopMotion2D", + "Stop velocity and angular velocity on a Rigidbody2D")] + [AddComponentMenu("")] + public class StopMotionRigidBody2D : Command + { + [SerializeField] + protected Rigidbody2DData rb; + + public enum Motion + { + Velocity, + AngularVelocity, + AngularAndLinearVelocity + } + + [SerializeField] + protected Motion motionToStop = Motion.AngularAndLinearVelocity; + + public override void OnEnter() + { + switch (motionToStop) + { + case Motion.Velocity: + rb.Value.velocity = Vector2.zero; + break; + case Motion.AngularVelocity: + rb.Value.angularVelocity = 0; + break; + case Motion.AngularAndLinearVelocity: + rb.Value.angularVelocity = 0; + rb.Value.velocity = Vector2.zero; + break; + default: + break; + } + + Continue(); + } + + public override string GetSummary() + { + return motionToStop.ToString(); + } + + public override Color GetButtonColor() + { + return new Color32(235, 191, 217, 255); + } + + public override bool HasReference(Variable variable) + { + if (rb.rigidbody2DRef == variable) + return true; + + return false; + } + + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/Rigidbody2D/StopMotionRigidBody2D.cs.meta b/Assets/Fungus/Scripts/Commands/Rigidbody2D/StopMotionRigidBody2D.cs.meta new file mode 100644 index 0000000..57bbc2a --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Rigidbody2D/StopMotionRigidBody2D.cs.meta @@ -0,0 +1,12 @@ +fileFormatVersion: 2 +guid: bd2e830ee16360d418acee50d83c9c13 +timeCreated: 1504225685 +licenseType: Store +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/RotateAdd.cs b/Assets/Fungus/Scripts/Commands/RotateAdd.cs new file mode 100644 index 0000000..7bf7ae3 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/RotateAdd.cs @@ -0,0 +1,68 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; +using UnityEngine.Serialization; +using System.Collections; + +namespace Fungus +{ + /// + /// Rotates a game object by the specified angles over time. + /// + [CommandInfo("iTween", + "Rotate Add", + "Rotates a game object by the specified angles over time.")] + [AddComponentMenu("")] + [ExecuteInEditMode] + public class RotateAdd : iTweenCommand + { + [Tooltip("A rotation offset in space the GameObject will animate to")] + [SerializeField] protected Vector3Data _offset; + + [Tooltip("Apply the transformation in either the world coordinate or local cordinate system")] + [SerializeField] protected Space space = Space.Self; + + #region Public members + + public override void DoTween() + { + Hashtable tweenParams = new Hashtable(); + tweenParams.Add("name", _tweenName.Value); + tweenParams.Add("amount", _offset.Value); + tweenParams.Add("space", space); + tweenParams.Add("time", _duration.Value); + tweenParams.Add("easetype", easeType); + tweenParams.Add("looptype", loopType); + tweenParams.Add("oncomplete", "OniTweenComplete"); + tweenParams.Add("oncompletetarget", gameObject); + tweenParams.Add("oncompleteparams", this); + iTween.RotateAdd(_targetObject.Value, tweenParams); + } + + public override bool HasReference(Variable variable) + { + return _offset.vector3Ref == variable || + base.HasReference(variable); + } + + #endregion + + #region Backwards compatibility + + [HideInInspector] [FormerlySerializedAs("offset")] public Vector3 offsetOLD; + + protected override void OnEnable() + { + base.OnEnable(); + + if (offsetOLD != default(Vector3)) + { + _offset.Value = offsetOLD; + offsetOLD = default(Vector3); + } + } + + #endregion + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/RotateAdd.cs.meta b/Assets/Fungus/Scripts/Commands/RotateAdd.cs.meta new file mode 100644 index 0000000..7a747f1 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/RotateAdd.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 1a5d3c95fea3b45a595a9993dd9c3158 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Fungus/Scripts/Commands/RotateFrom.cs b/Assets/Fungus/Scripts/Commands/RotateFrom.cs new file mode 100644 index 0000000..c5fc556 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/RotateFrom.cs @@ -0,0 +1,85 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; +using UnityEngine.Serialization; +using System.Collections; + +namespace Fungus +{ + /// + /// Rotates a game object from the specified angles back to its starting orientation over time. + /// + [CommandInfo("iTween", + "Rotate From", + "Rotates a game object from the specified angles back to its starting orientation over time.")] + [AddComponentMenu("")] + [ExecuteInEditMode] + public class RotateFrom : iTweenCommand + { + [Tooltip("Target transform that the GameObject will rotate from")] + [SerializeField] protected TransformData _fromTransform; + + [Tooltip("Target rotation that the GameObject will rotate from, if no From Transform is set")] + [SerializeField] protected Vector3Data _fromRotation; + + [Tooltip("Whether to animate in world space or relative to the parent. False by default.")] + [SerializeField] protected bool isLocal; + + #region Public members + + public override void DoTween() + { + Hashtable tweenParams = new Hashtable(); + tweenParams.Add("name", _tweenName.Value); + if (_fromTransform.Value == null) + { + tweenParams.Add("rotation", _fromRotation.Value); + } + else + { + tweenParams.Add("rotation", _fromTransform.Value); + } + tweenParams.Add("time", _duration.Value); + tweenParams.Add("easetype", easeType); + tweenParams.Add("looptype", loopType); + tweenParams.Add("isLocal", isLocal); + tweenParams.Add("oncomplete", "OniTweenComplete"); + tweenParams.Add("oncompletetarget", gameObject); + tweenParams.Add("oncompleteparams", this); + iTween.RotateFrom(_targetObject.Value, tweenParams); + } + + public override bool HasReference(Variable variable) + { + return _fromTransform.transformRef == variable || _fromRotation.vector3Ref == variable || + base.HasReference(variable); + } + + #endregion + + #region Backwards compatibility + + [HideInInspector] [FormerlySerializedAs("fromTransform")] public Transform fromTransformOLD; + [HideInInspector] [FormerlySerializedAs("fromRotation")] public Vector3 fromRotationOLD; + + protected override void OnEnable() + { + base.OnEnable(); + + if (fromTransformOLD != null) + { + _fromTransform.Value = fromTransformOLD; + fromTransformOLD = null; + } + + if (fromRotationOLD != default(Vector3)) + { + _fromRotation.Value = fromRotationOLD; + fromRotationOLD = default(Vector3); + } + } + + #endregion + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/RotateFrom.cs.meta b/Assets/Fungus/Scripts/Commands/RotateFrom.cs.meta new file mode 100644 index 0000000..ebed8b1 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/RotateFrom.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 6cfc8560cbecd48adb3950b9dd7f2b82 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Fungus/Scripts/Commands/RotateTo.cs b/Assets/Fungus/Scripts/Commands/RotateTo.cs new file mode 100644 index 0000000..4420af1 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/RotateTo.cs @@ -0,0 +1,85 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; +using UnityEngine.Serialization; +using System.Collections; + +namespace Fungus +{ + /// + /// Rotates a game object to the specified angles over time. + /// + [CommandInfo("iTween", + "Rotate To", + "Rotates a game object to the specified angles over time.")] + [AddComponentMenu("")] + [ExecuteInEditMode] + public class RotateTo : iTweenCommand + { + [Tooltip("Target transform that the GameObject will rotate to")] + [SerializeField] protected TransformData _toTransform; + + [Tooltip("Target rotation that the GameObject will rotate to, if no To Transform is set")] + [SerializeField] protected Vector3Data _toRotation; + + [Tooltip("Whether to animate in world space or relative to the parent. False by default.")] + [SerializeField] protected bool isLocal; + + #region Public members + + public override void DoTween() + { + Hashtable tweenParams = new Hashtable(); + tweenParams.Add("name", _tweenName.Value); + if (_toTransform.Value == null) + { + tweenParams.Add("rotation", _toRotation.Value); + } + else + { + tweenParams.Add("rotation", _toTransform.Value); + } + tweenParams.Add("time", _duration.Value); + tweenParams.Add("easetype", easeType); + tweenParams.Add("looptype", loopType); + tweenParams.Add("isLocal", isLocal); + tweenParams.Add("oncomplete", "OniTweenComplete"); + tweenParams.Add("oncompletetarget", gameObject); + tweenParams.Add("oncompleteparams", this); + iTween.RotateTo(_targetObject.Value, tweenParams); + } + + public override bool HasReference(Variable variable) + { + return _toTransform.transformRef == variable || _toRotation.vector3Ref == variable || + base.HasReference(variable); + } + + #endregion + + #region Backwards compatibility + + [HideInInspector] [FormerlySerializedAs("toTransform")] public Transform toTransformOLD; + [HideInInspector] [FormerlySerializedAs("toRotation")] public Vector3 toRotationOLD; + + protected override void OnEnable() + { + base.OnEnable(); + + if (toTransformOLD != null) + { + _toTransform.Value = toTransformOLD; + toTransformOLD = null; + } + + if (toRotationOLD != default(Vector3)) + { + _toRotation.Value = toRotationOLD; + toRotationOLD = default(Vector3); + } + } + + #endregion + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/RotateTo.cs.meta b/Assets/Fungus/Scripts/Commands/RotateTo.cs.meta new file mode 100644 index 0000000..f8a9f09 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/RotateTo.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: d2dd111db90064d2cb85e3370cdfe3ac +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Fungus/Scripts/Commands/SavePoint.cs b/Assets/Fungus/Scripts/Commands/SavePoint.cs new file mode 100644 index 0000000..2060f66 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/SavePoint.cs @@ -0,0 +1,176 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +#if UNITY_5_3_OR_NEWER + +using UnityEngine; + +namespace Fungus +{ + [CommandInfo("Flow", + "Save Point", + "Creates a Save Point and adds it to the Save History. The player can save the Save History to persistent storage and load it again later using the Save Menu.")] + public class SavePoint : Command + { + /// + /// Supported modes for specifying a Save Point Key. + /// + public enum KeyMode + { + /// Use the parent Block's name as the Save Point Key. N.B. If you change the Block name later it will break the save file! + BlockName, + /// Use a custom string for the key. This allows you to use multiple Save Points in the same block and save files will still work if the Block is renamed later. + Custom, + /// Use both the parent Block's name as well as a custom string for the Save Point key. This allows you to use your custom key every block, provided your Block names are unique./// + BlockNameAndCustom + } + + /// + /// Supported modes for specifying a Save Point Description. + /// + public enum DescriptionMode + { + /// Uses the current date and time as the save point description. + Timestamp, + /// Use a custom string for the save point description. + Custom + } + + [Tooltip("Marks this Save Point as the starting point for Flowchart execution in the scene. Each scene in your game should have exactly one Save Point with this enabled.")] + [SerializeField] protected bool isStartPoint = false; + + [Tooltip("How the Save Point Key for this Save Point is defined.")] + [SerializeField] protected KeyMode keyMode = KeyMode.BlockName; + + [Tooltip("A string key which uniquely identifies this save point.")] + [SerializeField] protected string customKey = ""; + + [Tooltip("A string to seperate the block name and custom key when using KeyMode.Both.")] + [SerializeField] + protected string keySeparator = "_"; + + [Tooltip("How the description for this Save Point is defined.")] + [SerializeField] protected DescriptionMode descriptionMode = DescriptionMode.Timestamp; + + [Tooltip("A short description of this save point.")] + [SerializeField] protected string customDescription; + + [Tooltip("Fire a Save Point Loaded event when this command executes.")] + [SerializeField] protected bool fireEvent = true; + + [Tooltip("Resume execution from this location after loading this Save Point.")] + [SerializeField] protected bool resumeOnLoad = true; + + #region Public members + + /// + /// Marks this Save Point as the starting point for Flowchart execution in the scene. Each scene in your game should have exactly one Save Point with this enabled. + /// + public bool IsStartPoint { get { return isStartPoint; } set { isStartPoint = value; } } + + /// + /// Gets a string key which uniquely identifies this Save Point. + /// + public string SavePointKey + { + get + { + if (keyMode == KeyMode.BlockName) + { + return ParentBlock.BlockName; + } + else if (keyMode == KeyMode.BlockNameAndCustom) + { + return ParentBlock.BlockName + keySeparator + customKey; + } + else + { + return customKey; + } + } + } + + /// + /// Gets the save point description. + /// + public string SavePointDescription + { + get + { + if (descriptionMode == DescriptionMode.Timestamp) + { + return System.DateTime.UtcNow.ToString("HH:mm dd MMMM, yyyy"); + } + else + { + return customDescription; + } + } + } + + /// + /// Resume execution from this location after loading this Save Point. + /// + public bool ResumeOnLoad { get { return resumeOnLoad; } } + + public override void OnEnter() + { + var saveManager = FungusManager.Instance.SaveManager; + + saveManager.AddSavePoint(SavePointKey, SavePointDescription); + + if (fireEvent) + { + SavePointLoaded.NotifyEventHandlers(SavePointKey); + } + + Continue(); + } + + public override string GetSummary() + { + if (keyMode == KeyMode.BlockName) + { + return "key: " + ParentBlock.BlockName; + } + else if (keyMode == KeyMode.BlockNameAndCustom) + { + return "key: " + ParentBlock.BlockName + keySeparator + customKey; + } + + return "key: " + customKey; + } + + public override Color GetButtonColor() + { + return new Color32(235, 191, 217, 255); + } + + public override bool IsPropertyVisible(string propertyName) + { + if (propertyName == "customKey" && + (keyMode != KeyMode.Custom && keyMode != KeyMode.BlockNameAndCustom)) + { + return false; + } + + if (propertyName == "keySeparator" && + keyMode != KeyMode.BlockNameAndCustom) + { + return false; + } + + if (propertyName == "customDescription" && + descriptionMode != DescriptionMode.Custom) + { + return false; + } + + return true; + } + + #endregion + } +} + +#endif \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/SavePoint.cs.meta b/Assets/Fungus/Scripts/Commands/SavePoint.cs.meta new file mode 100644 index 0000000..6cd03aa --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/SavePoint.cs.meta @@ -0,0 +1,12 @@ +fileFormatVersion: 2 +guid: 0b115619cb83b4d6ab8047d0e9407403 +timeCreated: 1478530280 +licenseType: Store +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/SaveVariable.cs b/Assets/Fungus/Scripts/Commands/SaveVariable.cs new file mode 100644 index 0000000..08b3e94 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/SaveVariable.cs @@ -0,0 +1,125 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; + +namespace Fungus +{ + /// + /// Save an Boolean, Integer, Float or String variable to persistent storage using a string key. + /// The value can be loaded again later using the Load Variable command. You can also + /// use the Set Save Profile command to manage separate save profiles for multiple players. + /// + [CommandInfo("Variable", + "Save Variable", + "Save an Boolean, Integer, Float or String variable to persistent storage using a string key. " + + "The value can be loaded again later using the Load Variable command. You can also " + + "use the Set Save Profile command to manage separate save profiles for multiple players.")] + [AddComponentMenu("")] + public class SaveVariable : Command + { + [Tooltip("Name of the saved value. Supports variable substition e.g. \"player_{$PlayerNumber}")] + [SerializeField] protected string key = ""; + + [Tooltip("Variable to read the value from. Only Boolean, Integer, Float and String are supported.")] + [VariableProperty(typeof(BooleanVariable), + typeof(IntegerVariable), + typeof(FloatVariable), + typeof(StringVariable))] + [SerializeField] protected Variable variable; + + #region Public members + + public override void OnEnter() + { + if (key == "" || + variable == null) + { + Continue(); + return; + } + + var flowchart = GetFlowchart(); + + // Prepend the current save profile (if any) + string prefsKey = SetSaveProfile.SaveProfile + "_" + flowchart.SubstituteVariables(key); + + System.Type variableType = variable.GetType(); + + if (variableType == typeof(BooleanVariable)) + { + BooleanVariable booleanVariable = variable as BooleanVariable; + if (booleanVariable != null) + { + // PlayerPrefs does not have bool accessors, so just use int + PlayerPrefs.SetInt(prefsKey, booleanVariable.Value ? 1 : 0); + } + } + else if (variableType == typeof(IntegerVariable)) + { + IntegerVariable integerVariable = variable as IntegerVariable; + if (integerVariable != null) + { + PlayerPrefs.SetInt(prefsKey, integerVariable.Value); + } + } + else if (variableType == typeof(FloatVariable)) + { + FloatVariable floatVariable = variable as FloatVariable; + if (floatVariable != null) + { + PlayerPrefs.SetFloat(prefsKey, floatVariable.Value); + } + } + else if (variableType == typeof(StringVariable)) + { + StringVariable stringVariable = variable as StringVariable; + if (stringVariable != null) + { + PlayerPrefs.SetString(prefsKey, stringVariable.Value); + } + } + + Continue(); + } + + public override string GetSummary() + { + if (key.Length == 0) + { + return "Error: No stored value key selected"; + } + + if (variable == null) + { + return "Error: No variable selected"; + } + + return variable.Key + " into '" + key + "'"; + } + + public override Color GetButtonColor() + { + return new Color32(235, 191, 217, 255); + } + + public override bool HasReference(Variable in_variable) + { + return this.variable == in_variable || base.HasReference(in_variable); + } + + #endregion + #region Editor caches +#if UNITY_EDITOR + protected override void RefreshVariableCache() + { + base.RefreshVariableCache(); + + var f = GetFlowchart(); + + f.DetermineSubstituteVariables(key, referencedVariables); + } +#endif + #endregion Editor caches + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/SaveVariable.cs.meta b/Assets/Fungus/Scripts/Commands/SaveVariable.cs.meta new file mode 100644 index 0000000..cffdea4 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/SaveVariable.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 1bef7966140464bd5a3ef4da2ff236b9 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Fungus/Scripts/Commands/Say.cs b/Assets/Fungus/Scripts/Commands/Say.cs new file mode 100644 index 0000000..451a002 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Say.cs @@ -0,0 +1,201 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; + +namespace Fungus +{ + /// + /// Writes text in a dialog box. + /// + [CommandInfo("Narrative", + "Say", + "Writes text in a dialog box.")] + [AddComponentMenu("")] + public class Say : Command, ILocalizable + { + // Removed this tooltip as users's reported it obscures the text box + [TextArea(5,10)] + [SerializeField] protected string storyText = ""; + + [Tooltip("Notes about this story text for other authors, localization, etc.")] + [SerializeField] protected string description = ""; + + [Tooltip("Character that is speaking")] + [SerializeField] protected Character character; + + [Tooltip("Portrait that represents speaking character")] + [SerializeField] protected Sprite portrait; + + [Tooltip("Voiceover audio to play when writing the text")] + [SerializeField] protected AudioClip voiceOverClip; + + [Tooltip("Always show this Say text when the command is executed multiple times")] + [SerializeField] protected bool showAlways = true; + + [Tooltip("Number of times to show this Say text when the command is executed multiple times")] + [SerializeField] protected int showCount = 1; + + [Tooltip("Type this text in the previous dialog box.")] + [SerializeField] protected bool extendPrevious = false; + + [Tooltip("Fade out the dialog box when writing has finished and not waiting for input.")] + [SerializeField] protected bool fadeWhenDone = true; + + [Tooltip("Wait for player to click before continuing.")] + [SerializeField] protected bool waitForClick = true; + + [Tooltip("Stop playing voiceover when text finishes writing.")] + [SerializeField] protected bool stopVoiceover = true; + + [Tooltip("Wait for the Voice Over to complete before continuing")] + [SerializeField] protected bool waitForVO = false; + + //add wait for vo that overrides stopvo + + [Tooltip("Sets the active Say dialog with a reference to a Say Dialog object in the scene. All story text will now display using this Say Dialog.")] + [SerializeField] protected SayDialog setSayDialog; + + protected int executionCount; + + #region Public members + + /// + /// Character that is speaking. + /// + public virtual Character _Character { get { return character; } } + + /// + /// Portrait that represents speaking character. + /// + public virtual Sprite Portrait { get { return portrait; } set { portrait = value; } } + + /// + /// Type this text in the previous dialog box. + /// + public virtual bool ExtendPrevious { get { return extendPrevious; } } + + public override void OnEnter() + { + if (!showAlways && executionCount >= showCount) + { + Continue(); + return; + } + + executionCount++; + + // Override the active say dialog if needed + if (character != null && character.SetSayDialog != null) + { + SayDialog.ActiveSayDialog = character.SetSayDialog; + } + + if (setSayDialog != null) + { + SayDialog.ActiveSayDialog = setSayDialog; + } + + var sayDialog = SayDialog.GetSayDialog(); + if (sayDialog == null) + { + Continue(); + return; + } + + var flowchart = GetFlowchart(); + + sayDialog.SetActive(true); + + sayDialog.SetCharacter(character); + sayDialog.SetCharacterImage(portrait); + + string displayText = storyText; + + var activeCustomTags = CustomTag.activeCustomTags; + for (int i = 0; i < activeCustomTags.Count; i++) + { + var ct = activeCustomTags[i]; + displayText = displayText.Replace(ct.TagStartSymbol, ct.ReplaceTagStartWith); + if (ct.TagEndSymbol != "" && ct.ReplaceTagEndWith != "") + { + displayText = displayText.Replace(ct.TagEndSymbol, ct.ReplaceTagEndWith); + } + } + + string subbedText = flowchart.SubstituteVariables(displayText); + + sayDialog.Say(subbedText, !extendPrevious, waitForClick, fadeWhenDone, stopVoiceover, waitForVO, voiceOverClip, delegate { + Continue(); + }); + } + + public override string GetSummary() + { + string namePrefix = ""; + if (character != null) + { + namePrefix = character.NameText + ": "; + } + if (extendPrevious) + { + namePrefix = "EXTEND" + ": "; + } + return namePrefix + "\"" + storyText + "\""; + } + + public override Color GetButtonColor() + { + return new Color32(184, 210, 235, 255); + } + + public override void OnReset() + { + executionCount = 0; + } + + public override void OnStopExecuting() + { + var sayDialog = SayDialog.GetSayDialog(); + if (sayDialog == null) + { + return; + } + + sayDialog.Stop(); + } + + #endregion + + #region ILocalizable implementation + + public virtual string GetStandardText() + { + return storyText; + } + + public virtual void SetStandardText(string standardText) + { + storyText = standardText; + } + + public virtual string GetDescription() + { + return description; + } + + public virtual string GetStringId() + { + // String id for Say commands is SAY...[Character Name] + string stringId = "SAY." + GetFlowchartLocalizationId() + "." + itemId + "."; + if (character != null) + { + stringId += character.NameText; + } + + return stringId; + } + + #endregion + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/Say.cs.meta b/Assets/Fungus/Scripts/Commands/Say.cs.meta new file mode 100644 index 0000000..2967a3e --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Say.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: ec422cd568a9c4a31ad7c36d0572b9da +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Fungus/Scripts/Commands/ScaleAdd.cs b/Assets/Fungus/Scripts/Commands/ScaleAdd.cs new file mode 100644 index 0000000..29dbd95 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/ScaleAdd.cs @@ -0,0 +1,64 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; +using UnityEngine.Serialization; +using System.Collections; + +namespace Fungus +{ + /// + /// Changes a game object's scale by a specified offset over time. + /// + [CommandInfo("iTween", + "Scale Add", + "Changes a game object's scale by a specified offset over time.")] + [AddComponentMenu("")] + [ExecuteInEditMode] + public class ScaleAdd : iTweenCommand + { + [Tooltip("A scale offset in space the GameObject will animate to")] + [SerializeField] protected Vector3Data _offset; + + #region Public members + + public override void DoTween() + { + Hashtable tweenParams = new Hashtable(); + tweenParams.Add("name", _tweenName.Value); + tweenParams.Add("amount", _offset.Value); + tweenParams.Add("time", _duration.Value); + tweenParams.Add("easetype", easeType); + tweenParams.Add("looptype", loopType); + tweenParams.Add("oncomplete", "OniTweenComplete"); + tweenParams.Add("oncompletetarget", gameObject); + tweenParams.Add("oncompleteparams", this); + iTween.ScaleAdd(_targetObject.Value, tweenParams); + } + + public override bool HasReference(Variable variable) + { + return _offset.vector3Ref == variable || + base.HasReference(variable); + } + + #endregion + + #region Backwards compatibility + + [HideInInspector] [FormerlySerializedAs("offset")] public Vector3 offsetOLD; + + protected override void OnEnable() + { + base.OnEnable(); + + if (offsetOLD != default(Vector3)) + { + _offset.Value = offsetOLD; + offsetOLD = default(Vector3); + } + } + + #endregion + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/ScaleAdd.cs.meta b/Assets/Fungus/Scripts/Commands/ScaleAdd.cs.meta new file mode 100644 index 0000000..4e7bb02 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/ScaleAdd.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: c4998e756a5d84f4ab55e075dad751b1 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Fungus/Scripts/Commands/ScaleFrom.cs b/Assets/Fungus/Scripts/Commands/ScaleFrom.cs new file mode 100644 index 0000000..335196f --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/ScaleFrom.cs @@ -0,0 +1,81 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; +using UnityEngine.Serialization; +using System.Collections; + +namespace Fungus +{ + /// + /// Changes a game object's scale to the specified value and back to its original scale over time. + /// + [CommandInfo("iTween", + "Scale From", + "Changes a game object's scale to the specified value and back to its original scale over time.")] + [AddComponentMenu("")] + [ExecuteInEditMode] + public class ScaleFrom : iTweenCommand + { + [Tooltip("Target transform that the GameObject will scale from")] + [SerializeField] protected TransformData _fromTransform; + + [Tooltip("Target scale that the GameObject will scale from, if no From Transform is set")] + [SerializeField] protected Vector3Data _fromScale; + + #region Public members + + public override void DoTween() + { + Hashtable tweenParams = new Hashtable(); + tweenParams.Add("name", _tweenName.Value); + if (_fromTransform.Value == null) + { + tweenParams.Add("scale", _fromScale.Value); + } + else + { + tweenParams.Add("scale", _fromTransform.Value); + } + tweenParams.Add("time", _duration.Value); + tweenParams.Add("easetype", easeType); + tweenParams.Add("looptype", loopType); + tweenParams.Add("oncomplete", "OniTweenComplete"); + tweenParams.Add("oncompletetarget", gameObject); + tweenParams.Add("oncompleteparams", this); + iTween.ScaleFrom(_targetObject.Value, tweenParams); + } + + public override bool HasReference(Variable variable) + { + return _fromTransform.transformRef == variable || _fromScale.vector3Ref == variable || + base.HasReference(variable); + } + + #endregion + + #region Backwards compatibility + + [HideInInspector] [FormerlySerializedAs("fromTransform")] public Transform fromTransformOLD; + [HideInInspector] [FormerlySerializedAs("fromScale")] public Vector3 fromScaleOLD; + + protected override void OnEnable() + { + base.OnEnable(); + + if (fromTransformOLD != null) + { + _fromTransform.Value = fromTransformOLD; + fromTransformOLD = null; + } + + if (fromScaleOLD != default(Vector3)) + { + _fromScale.Value = fromScaleOLD; + fromScaleOLD = default(Vector3); + } + } + + #endregion + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/ScaleFrom.cs.meta b/Assets/Fungus/Scripts/Commands/ScaleFrom.cs.meta new file mode 100644 index 0000000..103b49b --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/ScaleFrom.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 0d47cc719ae0d4d62a30b3cfa72b5785 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Fungus/Scripts/Commands/ScaleTo.cs b/Assets/Fungus/Scripts/Commands/ScaleTo.cs new file mode 100644 index 0000000..939176a --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/ScaleTo.cs @@ -0,0 +1,81 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; +using UnityEngine.Serialization; +using System.Collections; + +namespace Fungus +{ + /// + /// Changes a game object's scale to a specified value over time. + /// + [CommandInfo("iTween", + "Scale To", + "Changes a game object's scale to a specified value over time.")] + [AddComponentMenu("")] + [ExecuteInEditMode] + public class ScaleTo : iTweenCommand + { + [Tooltip("Target transform that the GameObject will scale to")] + [SerializeField] protected TransformData _toTransform; + + [Tooltip("Target scale that the GameObject will scale to, if no To Transform is set")] + [SerializeField] protected Vector3Data _toScale = new Vector3Data(Vector3.one); + + #region Public members + + public override void DoTween() + { + Hashtable tweenParams = new Hashtable(); + tweenParams.Add("name", _tweenName.Value); + if (_toTransform.Value == null) + { + tweenParams.Add("scale", _toScale.Value); + } + else + { + tweenParams.Add("scale", _toTransform.Value); + } + tweenParams.Add("time", _duration.Value); + tweenParams.Add("easetype", easeType); + tweenParams.Add("looptype", loopType); + tweenParams.Add("oncomplete", "OniTweenComplete"); + tweenParams.Add("oncompletetarget", gameObject); + tweenParams.Add("oncompleteparams", this); + iTween.ScaleTo(_targetObject.Value, tweenParams); + } + + public override bool HasReference(Variable variable) + { + return _toTransform.transformRef == variable || _toScale.vector3Ref == variable || + base.HasReference(variable); + } + + #endregion + + #region Backwards compatibility + + [HideInInspector] [FormerlySerializedAs("toTransform")] public Transform toTransformOLD; + [HideInInspector] [FormerlySerializedAs("toScale")] public Vector3 toScaleOLD; + + protected override void OnEnable() + { + base.OnEnable(); + + if (toTransformOLD != null) + { + _toTransform.Value = toTransformOLD; + toTransformOLD = null; + } + + if (toScaleOLD != default(Vector3)) + { + _toScale.Value = toScaleOLD; + toScaleOLD = default(Vector3); + } + } + + #endregion + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/ScaleTo.cs.meta b/Assets/Fungus/Scripts/Commands/ScaleTo.cs.meta new file mode 100644 index 0000000..c1eec94 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/ScaleTo.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 665e8847cab3749f597622c6c52997ad +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Fungus/Scripts/Commands/Scene.meta b/Assets/Fungus/Scripts/Commands/Scene.meta new file mode 100644 index 0000000..fbae4c5 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Scene.meta @@ -0,0 +1,9 @@ +fileFormatVersion: 2 +guid: 3c625aa42f45f484cb2a4f4bef7adede +folderAsset: yes +timeCreated: 1501237083 +licenseType: Store +DefaultImporter: + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/Scene/ReloadScene.cs b/Assets/Fungus/Scripts/Commands/Scene/ReloadScene.cs new file mode 100644 index 0000000..86f62a1 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Scene/ReloadScene.cs @@ -0,0 +1,38 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; + +namespace Fungus +{ + /// + /// Reload the current scene + /// + [CommandInfo("Scene", + "Reload", + "Reload the current scene")] + [AddComponentMenu("")] + public class ReloadScene : Command + { + [Tooltip("Image to display while loading the scene")] + [SerializeField] + protected Texture2D loadingImage; + + public override void OnEnter() + { + SceneLoader.LoadScene(UnityEngine.SceneManagement.SceneManager.GetActiveScene().name, loadingImage); + + Continue(); + } + + public override string GetSummary() + { + return ""; + } + + public override Color GetButtonColor() + { + return new Color32(235, 191, 217, 255); + } + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/Scene/ReloadScene.cs.meta b/Assets/Fungus/Scripts/Commands/Scene/ReloadScene.cs.meta new file mode 100644 index 0000000..9b99b00 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Scene/ReloadScene.cs.meta @@ -0,0 +1,12 @@ +fileFormatVersion: 2 +guid: 9c784b19efbe8424fa879e0d6d883281 +timeCreated: 1501237128 +licenseType: Store +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/SendMessage.cs b/Assets/Fungus/Scripts/Commands/SendMessage.cs new file mode 100644 index 0000000..75024e8 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/SendMessage.cs @@ -0,0 +1,109 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; +using UnityEngine.Serialization; + +namespace Fungus +{ + /// + /// Supported target types for messages. + /// + public enum MessageTarget + { + /// + /// Send message to the Flowchart containing the SendMessage command. + /// + SameFlowchart, + /// + /// Broadcast message to all Flowcharts. + /// + AllFlowcharts + } + + /// + /// Sends a message to either the owner Flowchart or all Flowcharts in the scene. Blocks can listen for this message using a Message Received event handler. + /// + [CommandInfo("Flow", + "Send Message", + "Sends a message to either the owner Flowchart or all Flowcharts in the scene. Blocks can listen for this message using a Message Received event handler.")] + [AddComponentMenu("")] + [ExecuteInEditMode] + public class SendMessage : Command + { + [Tooltip("Target flowchart(s) to send the message to")] + [SerializeField] protected MessageTarget messageTarget; + + [Tooltip("Name of the message to send")] + [SerializeField] protected StringData _message = new StringData(""); + + #region Public members + + public override void OnEnter() + { + if (_message.Value.Length == 0) + { + Continue(); + return; + } + + MessageReceived[] receivers = null; + if (messageTarget == MessageTarget.SameFlowchart) + { + receivers = GetComponents(); + } + else + { + receivers = GameObject.FindObjectsOfType(); + } + + if (receivers != null) + { + for (int i = 0; i < receivers.Length; i++) + { + var receiver = receivers[i]; + receiver.OnSendFungusMessage(_message.Value); + } + } + + Continue(); + } + + public override string GetSummary() + { + if (_message.Value.Length == 0) + { + return "Error: No message specified"; + } + + return _message.Value; + } + + public override Color GetButtonColor() + { + return new Color32(235, 191, 217, 255); + } + + public override bool HasReference(Variable variable) + { + return _message.stringRef == variable || base.HasReference(variable); + } + + #endregion + + #region Backwards compatibility + + [HideInInspector] [FormerlySerializedAs("message")] public string messageOLD = ""; + + protected virtual void OnEnable() + { + if (messageOLD != "") + { + _message.Value = messageOLD; + messageOLD = ""; + } + } + + #endregion + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/SendMessage.cs.meta b/Assets/Fungus/Scripts/Commands/SendMessage.cs.meta new file mode 100644 index 0000000..97f1e5c --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/SendMessage.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: c43743931d28f43f89eced820d907351 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Fungus/Scripts/Commands/SetActive.cs b/Assets/Fungus/Scripts/Commands/SetActive.cs new file mode 100644 index 0000000..9013bae --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/SetActive.cs @@ -0,0 +1,75 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; +using UnityEngine.Serialization; + +namespace Fungus +{ + /// + /// Sets a game object in the scene to be active / inactive. + /// + [CommandInfo("Scripting", + "Set Active", + "Sets a game object in the scene to be active / inactive.")] + [AddComponentMenu("")] + [ExecuteInEditMode] + public class SetActive : Command + { + [Tooltip("Reference to game object to enable / disable")] + [SerializeField] protected GameObjectData _targetGameObject; + + [Tooltip("Set to true to enable the game object")] + [SerializeField] protected BooleanData activeState; + + #region Public members + + public override void OnEnter() + { + if (_targetGameObject.Value != null) + { + _targetGameObject.Value.SetActive(activeState.Value); + } + + Continue(); + } + + public override string GetSummary() + { + if (_targetGameObject.Value == null) + { + return "Error: No game object selected"; + } + + return _targetGameObject.Value.name + " = " + activeState.GetDescription(); + } + + public override Color GetButtonColor() + { + return new Color32(235, 191, 217, 255); + } + + public override bool HasReference(Variable variable) + { + return _targetGameObject.gameObjectRef == variable || activeState.booleanRef == variable || + base.HasReference(variable); + } + + #endregion + + #region Backwards compatibility + + [HideInInspector] [FormerlySerializedAs("targetGameObject")] public GameObject targetGameObjectOLD; + + protected virtual void OnEnable() + { + if (targetGameObjectOLD != null) + { + _targetGameObject.Value = targetGameObjectOLD; + targetGameObjectOLD = null; + } + } + + #endregion + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/SetActive.cs.meta b/Assets/Fungus/Scripts/Commands/SetActive.cs.meta new file mode 100644 index 0000000..94fe6f3 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/SetActive.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: dbd8c931f22994b9d90e2037fffaa770 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Fungus/Scripts/Commands/SetAnimBool.cs b/Assets/Fungus/Scripts/Commands/SetAnimBool.cs new file mode 100644 index 0000000..88aae8e --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/SetAnimBool.cs @@ -0,0 +1,85 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; +using UnityEngine.Serialization; + +namespace Fungus +{ + /// + /// Sets a boolean parameter on an Animator component to control a Unity animation" + /// + [CommandInfo("Animation", + "Set Anim Bool", + "Sets a boolean parameter on an Animator component to control a Unity animation")] + [AddComponentMenu("")] + [ExecuteInEditMode] + public class SetAnimBool : Command + { + [Tooltip("Reference to an Animator component in a game object")] + [SerializeField] protected AnimatorData _animator; + + [Tooltip("Name of the boolean Animator parameter that will have its value changed")] + [SerializeField] protected StringData _parameterName; + + [Tooltip("The boolean value to set the parameter to")] + [SerializeField] protected BooleanData value; + + #region Public members + + public override void OnEnter() + { + if (_animator.Value != null) + { + _animator.Value.SetBool(_parameterName.Value, value.Value); + } + + Continue(); + } + + public override string GetSummary() + { + if (_animator.Value == null) + { + return "Error: No animator selected"; + } + + return _animator.Value.name + " (" + _parameterName.Value + ")"; + } + + public override Color GetButtonColor() + { + return new Color32(170, 204, 169, 255); + } + + public override bool HasReference(Variable variable) + { + return _animator.animatorRef == variable || _parameterName.stringRef == variable || value.booleanRef == variable || + base.HasReference(variable); + } + + #endregion + + #region Backwards compatibility + + [HideInInspector] [FormerlySerializedAs("animator")] public Animator animatorOLD; + [HideInInspector] [FormerlySerializedAs("parameterName")] public string parameterNameOLD = ""; + + protected virtual void OnEnable() + { + if (animatorOLD != null) + { + _animator.Value = animatorOLD; + animatorOLD = null; + } + + if (parameterNameOLD != "") + { + _parameterName.Value = parameterNameOLD; + parameterNameOLD = ""; + } + } + + #endregion + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/SetAnimBool.cs.meta b/Assets/Fungus/Scripts/Commands/SetAnimBool.cs.meta new file mode 100644 index 0000000..550898d --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/SetAnimBool.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: ee63e642958494f1ebed8116ae4b1103 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Fungus/Scripts/Commands/SetAnimFloat.cs b/Assets/Fungus/Scripts/Commands/SetAnimFloat.cs new file mode 100644 index 0000000..244d64f --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/SetAnimFloat.cs @@ -0,0 +1,85 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; +using UnityEngine.Serialization; + +namespace Fungus +{ + /// + /// Sets a float parameter on an Animator component to control a Unity animation. + /// + [CommandInfo("Animation", + "Set Anim Float", + "Sets a float parameter on an Animator component to control a Unity animation")] + [AddComponentMenu("")] + [ExecuteInEditMode] + public class SetAnimFloat : Command + { + [Tooltip("Reference to an Animator component in a game object")] + [SerializeField] protected AnimatorData _animator; + + [Tooltip("Name of the float Animator parameter that will have its value changed")] + [SerializeField] protected StringData _parameterName; + + [Tooltip("The float value to set the parameter to")] + [SerializeField] protected FloatData value; + + #region Public members + + public override void OnEnter() + { + if (_animator.Value != null) + { + _animator.Value.SetFloat(_parameterName.Value, value.Value); + } + + Continue(); + } + + public override string GetSummary() + { + if (_animator.Value == null) + { + return "Error: No animator selected"; + } + + return _animator.Value.name + " (" + _parameterName.Value + ")"; + } + + public override Color GetButtonColor() + { + return new Color32(170, 204, 169, 255); + } + + public override bool HasReference(Variable variable) + { + return _animator.animatorRef == variable || _parameterName.stringRef == variable || value.floatRef == variable || + base.HasReference(variable); + } + + #endregion + + #region Backwards compatibility + + [HideInInspector] [FormerlySerializedAs("animator")] public Animator animatorOLD; + [HideInInspector] [FormerlySerializedAs("parameterName")] public string parameterNameOLD = ""; + + protected virtual void OnEnable() + { + if (animatorOLD != null) + { + _animator.Value = animatorOLD; + animatorOLD = null; + } + + if (parameterNameOLD != "") + { + _parameterName.Value = parameterNameOLD; + parameterNameOLD = ""; + } + } + + #endregion + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/SetAnimFloat.cs.meta b/Assets/Fungus/Scripts/Commands/SetAnimFloat.cs.meta new file mode 100644 index 0000000..b3105f5 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/SetAnimFloat.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: fb1f6a369ef8c40bda77241018ab6bd6 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Fungus/Scripts/Commands/SetAnimInteger.cs b/Assets/Fungus/Scripts/Commands/SetAnimInteger.cs new file mode 100644 index 0000000..3429b32 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/SetAnimInteger.cs @@ -0,0 +1,85 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; +using UnityEngine.Serialization; + +namespace Fungus +{ + /// + /// Sets an integer parameter on an Animator component to control a Unity animation. + /// + [CommandInfo("Animation", + "Set Anim Integer", + "Sets an integer parameter on an Animator component to control a Unity animation")] + [AddComponentMenu("")] + [ExecuteInEditMode] + public class SetAnimInteger : Command + { + [Tooltip("Reference to an Animator component in a game object")] + [SerializeField] protected AnimatorData _animator; + + [Tooltip("Name of the integer Animator parameter that will have its value changed")] + [SerializeField] protected StringData _parameterName; + + [Tooltip("The integer value to set the parameter to")] + [SerializeField] protected IntegerData value; + + #region Public members + + public override void OnEnter() + { + if (_animator.Value != null) + { + _animator.Value.SetInteger(_parameterName.Value, value.Value); + } + + Continue(); + } + + public override string GetSummary() + { + if (_animator.Value == null) + { + return "Error: No animator selected"; + } + + return _animator.Value.name + " (" + _parameterName.Value + ")"; + } + + public override Color GetButtonColor() + { + return new Color32(170, 204, 169, 255); + } + + public override bool HasReference(Variable variable) + { + return _animator.animatorRef == variable || _parameterName.stringRef == variable || value.integerRef == variable || + base.HasReference(variable); + } + + #endregion + + #region Backwards compatibility + + [HideInInspector] [FormerlySerializedAs("animator")] public Animator animatorOLD; + [HideInInspector] [FormerlySerializedAs("parameterName")] public string parameterNameOLD = ""; + + protected virtual void OnEnable() + { + if (animatorOLD != null) + { + _animator.Value = animatorOLD; + animatorOLD = null; + } + + if (parameterNameOLD != "") + { + _parameterName.Value = parameterNameOLD; + parameterNameOLD = ""; + } + } + + #endregion + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/SetAnimInteger.cs.meta b/Assets/Fungus/Scripts/Commands/SetAnimInteger.cs.meta new file mode 100644 index 0000000..8da48a9 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/SetAnimInteger.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 76641c2c16481448eb6c0c1184fcdebe +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Fungus/Scripts/Commands/SetAnimTrigger.cs b/Assets/Fungus/Scripts/Commands/SetAnimTrigger.cs new file mode 100644 index 0000000..c8c1e04 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/SetAnimTrigger.cs @@ -0,0 +1,81 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; +using UnityEngine.Serialization; + +namespace Fungus +{ + /// + /// Sets a trigger parameter on an Animator component to control a Unity animation. + /// + [CommandInfo("Animation", + "Set Anim Trigger", + "Sets a trigger parameter on an Animator component to control a Unity animation")] + [AddComponentMenu("")] + [ExecuteInEditMode] + public class SetAnimTrigger : Command + { + [Tooltip("Reference to an Animator component in a game object")] + [SerializeField] protected AnimatorData _animator; + + [Tooltip("Name of the trigger Animator parameter that will have its value changed")] + [SerializeField] protected StringData _parameterName; + + #region Public members + + public override void OnEnter() + { + if (_animator.Value != null) + { + _animator.Value.SetTrigger(_parameterName.Value); + } + + Continue(); + } + + public override string GetSummary() + { + if (_animator.Value == null) + { + return "Error: No animator selected"; + } + + return _animator.Value.name + " (" + _parameterName.Value + ")"; + } + + public override Color GetButtonColor() + { + return new Color32(170, 204, 169, 255); + } + + public override bool HasReference(Variable variable) + { + return _animator.animatorRef == variable || _parameterName.stringRef == variable || base.HasReference(variable); + } + + #endregion + + #region Backwards compatibility + + [HideInInspector] [FormerlySerializedAs("animator")] public Animator animatorOLD; + [HideInInspector] [FormerlySerializedAs("parameterName")] public string parameterNameOLD = ""; + + protected virtual void OnEnable() + { + if (animatorOLD != null) + { + _animator.Value = animatorOLD; + animatorOLD = null; + } + + if (parameterNameOLD != "") + { + _parameterName.Value = parameterNameOLD; + parameterNameOLD = ""; + } + } + + #endregion + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/SetAnimTrigger.cs.meta b/Assets/Fungus/Scripts/Commands/SetAnimTrigger.cs.meta new file mode 100644 index 0000000..ed91e64 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/SetAnimTrigger.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 0729d4f369e6a4241a6e7e3b8b9c1933 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Fungus/Scripts/Commands/SetAudioPitch.cs b/Assets/Fungus/Scripts/Commands/SetAudioPitch.cs new file mode 100644 index 0000000..e13af16 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/SetAudioPitch.cs @@ -0,0 +1,61 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; + +namespace Fungus +{ + /// + /// Sets the global pitch level for audio played with Play Music and Play Sound commands. + /// + [CommandInfo("Audio", + "Set Audio Pitch", + "Sets the global pitch level for audio played with Play Music and Play Sound commands.")] + [AddComponentMenu("")] + public class SetAudioPitch : Command + { + [Range(0,1)] + [Tooltip("Global pitch level for audio played using the Play Music and Play Sound commands")] + [SerializeField] protected float pitch = 1; + + [Range(0,30)] + [Tooltip("Time to fade between current pitch level and target pitch level.")] + [SerializeField] protected float fadeDuration; + + [Tooltip("Wait until the pitch change has finished before executing next command")] + [SerializeField] protected bool waitUntilFinished = true; + + #region Public members + + public override void OnEnter() + { + System.Action onComplete = () => { + if (waitUntilFinished) + { + Continue(); + } + }; + + var musicManager = FungusManager.Instance.MusicManager; + + musicManager.SetAudioPitch(pitch, fadeDuration, onComplete); + + if (!waitUntilFinished) + { + Continue(); + } + } + + public override string GetSummary() + { + return "Set to " + pitch + " over " + fadeDuration + " seconds."; + } + + public override Color GetButtonColor() + { + return new Color32(242, 209, 176, 255); + } + + #endregion + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/SetAudioPitch.cs.meta b/Assets/Fungus/Scripts/Commands/SetAudioPitch.cs.meta new file mode 100644 index 0000000..c7c6874 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/SetAudioPitch.cs.meta @@ -0,0 +1,12 @@ +fileFormatVersion: 2 +guid: 2d3c9751268124c9390e807040e57447 +timeCreated: 1446825167 +licenseType: Store +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/SetAudioVolume.cs b/Assets/Fungus/Scripts/Commands/SetAudioVolume.cs new file mode 100644 index 0000000..80a7362 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/SetAudioVolume.cs @@ -0,0 +1,59 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; + +namespace Fungus +{ + /// + /// Sets the global volume level for audio played with Play Music and Play Sound commands. + /// + [CommandInfo("Audio", + "Set Audio Volume", + "Sets the global volume level for audio played with Play Music and Play Sound commands.")] + [AddComponentMenu("")] + public class SetAudioVolume : Command + { + [Range(0,1)] + [Tooltip("Global volume level for audio played using Play Music and Play Sound")] + [SerializeField] protected float volume = 1f; + + [Range(0,30)] + [Tooltip("Time to fade between current volume level and target volume level.")] + [SerializeField] protected float fadeDuration = 1f; + + [Tooltip("Wait until the volume fade has completed before continuing.")] + [SerializeField] protected bool waitUntilFinished = true; + + #region Public members + + public override void OnEnter() + { + var musicManager = FungusManager.Instance.MusicManager; + + musicManager.SetAudioVolume(volume, fadeDuration, () => { + if (waitUntilFinished) + { + Continue(); + } + }); + + if (!waitUntilFinished) + { + Continue(); + } + } + + public override string GetSummary() + { + return "Set to " + volume + " over " + fadeDuration + " seconds."; + } + + public override Color GetButtonColor() + { + return new Color32(242, 209, 176, 255); + } + + #endregion + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/SetAudioVolume.cs.meta b/Assets/Fungus/Scripts/Commands/SetAudioVolume.cs.meta new file mode 100644 index 0000000..c085875 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/SetAudioVolume.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: a4015e84616cc45cfb498561373899d2 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Fungus/Scripts/Commands/SetClickable2D.cs b/Assets/Fungus/Scripts/Commands/SetClickable2D.cs new file mode 100644 index 0000000..c63e4ec --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/SetClickable2D.cs @@ -0,0 +1,58 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; + +namespace Fungus +{ + /// + /// Sets a Clickable2D component to be clickable / non-clickable. + /// + [CommandInfo("Sprite", + "Set Clickable 2D", + "Sets a Clickable2D component to be clickable / non-clickable.")] + [AddComponentMenu("")] + public class SetClickable2D : Command + { + [Tooltip("Reference to Clickable2D component on a gameobject")] + [SerializeField] protected Clickable2D targetClickable2D; + + [Tooltip("Set to true to enable the component")] + [SerializeField] protected BooleanData activeState; + + #region Public members + + public override void OnEnter() + { + if (targetClickable2D != null) + { + targetClickable2D.ClickEnabled = activeState.Value; + } + + Continue(); + } + + public override string GetSummary() + { + if (targetClickable2D == null) + { + return "Error: No Clickable2D component selected"; + } + + return targetClickable2D.gameObject.name; + } + + public override Color GetButtonColor() + { + return new Color32(235, 191, 217, 255); + } + + public override bool HasReference(Variable variable) + { + return activeState.booleanRef == variable || base.HasReference(variable); + } + + #endregion + } + +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/SetClickable2D.cs.meta b/Assets/Fungus/Scripts/Commands/SetClickable2D.cs.meta new file mode 100644 index 0000000..f3a813c --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/SetClickable2D.cs.meta @@ -0,0 +1,12 @@ +fileFormatVersion: 2 +guid: a598660d01b2343bb92adebcbb629ec5 +timeCreated: 1427811782 +licenseType: Store +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/SetCollider.cs b/Assets/Fungus/Scripts/Commands/SetCollider.cs new file mode 100644 index 0000000..d5a947d --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/SetCollider.cs @@ -0,0 +1,113 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; +using System.Collections.Generic; + +namespace Fungus +{ + /// + /// Sets all collider (2d or 3d) components on the target objects to be active / inactive. + /// + [CommandInfo("Sprite", + "Set Collider", + "Sets all collider (2d or 3d) components on the target objects to be active / inactive")] + [AddComponentMenu("")] + public class SetCollider : Command + { + [Tooltip("A list of gameobjects containing collider components to be set active / inactive")] + [SerializeField] protected List targetObjects = new List(); + + [Tooltip("All objects with this tag will have their collider set active / inactive")] + [SerializeField] protected string targetTag = ""; + + [Tooltip("Set to true to enable the collider components")] + [SerializeField] protected BooleanData activeState; + + protected virtual void SetColliderActive(GameObject go) + { + if (go != null) + { + // 3D objects + var colliders = go.GetComponentsInChildren(); + for (int i = 0; i < colliders.Length; i++) + { + var c = colliders[i]; + c.enabled = activeState.Value; + } + + // 2D objects + var collider2Ds = go.GetComponentsInChildren(); + for (int i = 0; i < collider2Ds.Length; i++) + { + var c = collider2Ds[i]; + c.enabled = activeState.Value; + } + } + } + + #region Public members + + public override void OnEnter() + { + for (int i = 0; i < targetObjects.Count; i++) + { + var go = targetObjects[i]; + SetColliderActive(go); + } + + GameObject[] taggedObjects = null; + try + { + taggedObjects = GameObject.FindGameObjectsWithTag(targetTag); + } + catch + { + // The tag has not been declared in this scene + } + + if (taggedObjects != null) + { + for (int i = 0; i < taggedObjects.Length; i++) + { + var go = taggedObjects[i]; + SetColliderActive(go); + } + } + + Continue(); + } + + public override string GetSummary() + { + int count = targetObjects.Count; + + if (activeState.Value) + { + return "Enable " + count + " collider objects."; + } + else + { + return "Disable " + count + " collider objects."; + } + } + + public override Color GetButtonColor() + { + return new Color32(235, 191, 217, 255); + } + + public override bool IsReorderableArray(string propertyName) + { + return propertyName == "targetObjects"; + } + + public override bool HasReference(Variable variable) + { + return activeState.booleanRef == variable || base.HasReference(variable); + } + + #endregion + } + +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/SetCollider.cs.meta b/Assets/Fungus/Scripts/Commands/SetCollider.cs.meta new file mode 100644 index 0000000..bcc2dd7 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/SetCollider.cs.meta @@ -0,0 +1,12 @@ +fileFormatVersion: 2 +guid: 985454614aca94d16906c0f2bd0b26f6 +timeCreated: 1432220559 +licenseType: Store +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/SetDraggable2D.cs b/Assets/Fungus/Scripts/Commands/SetDraggable2D.cs new file mode 100644 index 0000000..0f24ecd --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/SetDraggable2D.cs @@ -0,0 +1,57 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; + +namespace Fungus +{ + /// + /// Sets a Draggable2D component to be draggable / non-draggable. + /// + [CommandInfo("Sprite", + "Set Draggable 2D", + "Sets a Draggable2D component to be draggable / non-draggable.")] + [AddComponentMenu("")] + public class SetDraggable2D : Command + { + [Tooltip("Reference to Draggable2D component on a gameobject")] + [SerializeField] protected Draggable2D targetDraggable2D; + + [Tooltip("Set to true to enable the component")] + [SerializeField] protected BooleanData activeState; + + #region Public members + + public override void OnEnter() + { + if (targetDraggable2D != null) + { + targetDraggable2D.DragEnabled = activeState.Value; + } + + Continue(); + } + + public override string GetSummary() + { + if (targetDraggable2D == null) + { + return "Error: No Draggable2D component selected"; + } + + return targetDraggable2D.gameObject.name; + } + + public override Color GetButtonColor() + { + return new Color32(235, 191, 217, 255); + } + + public override bool HasReference(Variable variable) + { + return activeState.booleanRef == variable || base.HasReference(variable); + } + + #endregion + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/SetDraggable2D.cs.meta b/Assets/Fungus/Scripts/Commands/SetDraggable2D.cs.meta new file mode 100644 index 0000000..3e43460 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/SetDraggable2D.cs.meta @@ -0,0 +1,12 @@ +fileFormatVersion: 2 +guid: c987b33e737044fb185f6ae869a7bc17 +timeCreated: 1453469154 +licenseType: Store +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/SetInteractable.cs b/Assets/Fungus/Scripts/Commands/SetInteractable.cs new file mode 100644 index 0000000..d6680a4 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/SetInteractable.cs @@ -0,0 +1,111 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; +using UnityEngine.UI; +using System.Collections.Generic; + +namespace Fungus +{ + /// + /// Set the interactable state of selectable objects. + /// + [CommandInfo("UI", + "Set Interactable", + "Set the interactable state of selectable objects.")] + public class SetInteractable : Command + { + [Tooltip("List of objects to be affected by the command")] + [SerializeField] protected List targetObjects = new List(); + + [Tooltip("Controls if the selectable UI object be interactable or not")] + [SerializeField] protected BooleanData interactableState = new BooleanData(true); + + #region Public members + + public override void OnEnter() + { + if (targetObjects.Count == 0) + { + Continue(); + return; + } + + for (int i = 0; i < targetObjects.Count; i++) + { + var targetObject = targetObjects[i]; + var selectables = targetObject.GetComponents(); + for (int j = 0; j < selectables.Length; j++) + { + var selectable = selectables[j]; + selectable.interactable = interactableState.Value; + } + } + + Continue(); + } + + public override string GetSummary() + { + if (targetObjects.Count == 0) + { + return "Error: No targetObjects selected"; + } + else if (targetObjects.Count == 1) + { + if (targetObjects[0] == null) + { + return "Error: No targetObjects selected"; + } + return targetObjects[0].name + " = " + interactableState.Value; + } + + string objectList = ""; + for (int i = 0; i < targetObjects.Count; i++) + { + var go = targetObjects[i]; + if (go == null) + { + continue; + } + if (objectList == "") + { + objectList += go.name; + } + else + { + objectList += ", " + go.name; + } + } + + return objectList + " = " + interactableState.Value; + } + + public override Color GetButtonColor() + { + return new Color32(180, 250, 250, 255); + } + + public override void OnCommandAdded(Block parentBlock) + { + targetObjects.Add(null); + } + + public override bool IsReorderableArray(string propertyName) + { + if (propertyName == "targetObjects") + { + return true; + } + + return false; + } + + public override bool HasReference(Variable variable) + { + return interactableState.booleanRef == variable || base.HasReference(variable); + } + + #endregion + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/SetInteractable.cs.meta b/Assets/Fungus/Scripts/Commands/SetInteractable.cs.meta new file mode 100644 index 0000000..b05cff1 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/SetInteractable.cs.meta @@ -0,0 +1,12 @@ +fileFormatVersion: 2 +guid: ab0d0ed4a2ca94c81a230a0ecce6e6e4 +timeCreated: 1442403493 +licenseType: Store +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/SetLanguage.cs b/Assets/Fungus/Scripts/Commands/SetLanguage.cs new file mode 100644 index 0000000..f1c069a --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/SetLanguage.cs @@ -0,0 +1,73 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; +using UnityEngine.Serialization; + +namespace Fungus +{ + /// + /// Set the active language for the scene. A Localization object with a localization file must be present in the scene. + /// + [CommandInfo("Narrative", + "Set Language", + "Set the active language for the scene. A Localization object with a localization file must be present in the scene.")] + [AddComponentMenu("")] + [ExecuteInEditMode] + public class SetLanguage : Command + { + [Tooltip("Code of the language to set. e.g. ES, DE, JA")] + [SerializeField] protected StringData _languageCode = new StringData(); + + #region Public members + + public static string mostRecentLanguage = ""; + + public override void OnEnter() + { + Localization localization = GameObject.FindObjectOfType(); + if (localization != null) + { + localization.SetActiveLanguage(_languageCode.Value, true); + + // Cache the most recently set language code so we can continue to + // use the same language in subsequent scenes. + mostRecentLanguage = _languageCode.Value; + } + + Continue(); + } + + public override string GetSummary() + { + return _languageCode.Value; + } + + public override Color GetButtonColor() + { + return new Color32(184, 210, 235, 255); + } + + public override bool HasReference(Variable variable) + { + return _languageCode.stringRef == variable || base.HasReference(variable); + } + + #endregion + + #region Backwards compatibility + + [HideInInspector] [FormerlySerializedAs("languageCode")] public string languageCodeOLD = ""; + + protected virtual void OnEnable() + { + if (languageCodeOLD != "") + { + _languageCode.Value = languageCodeOLD; + languageCodeOLD = ""; + } + } + + #endregion + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/SetLanguage.cs.meta b/Assets/Fungus/Scripts/Commands/SetLanguage.cs.meta new file mode 100644 index 0000000..3e9d169 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/SetLanguage.cs.meta @@ -0,0 +1,12 @@ +fileFormatVersion: 2 +guid: 3fc625e237d6048bf86f34835d8266d9 +timeCreated: 1428591017 +licenseType: Store +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/SetLayerOrder.cs b/Assets/Fungus/Scripts/Commands/SetLayerOrder.cs new file mode 100644 index 0000000..9e4e312 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/SetLayerOrder.cs @@ -0,0 +1,68 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; + +namespace Fungus +{ + /// + /// Sets the Renderer sorting layer of every child of a game object. Applies to all Renderers (including mesh, skinned mesh, and sprite). + /// + [CommandInfo("Sprite", + "Set Sorting Layer", + "Sets the Renderer sorting layer of every child of a game object. Applies to all Renderers (including mesh, skinned mesh, and sprite).")] + [AddComponentMenu("")] + public class SetSortingLayer : Command + { + [Tooltip("Root Object that will have the Sorting Layer set. Any children will also be affected")] + [SerializeField] protected GameObject targetObject; + + [Tooltip("The New Layer Name to apply")] + [SerializeField] protected string sortingLayer; + + protected void ApplySortingLayer(Transform target, string layerName) + { + var renderer = target.gameObject.GetComponent(); + if (renderer) + { + renderer.sortingLayerName = layerName; + Debug.Log(target.name); + } + + var targetTransform = target.transform; + foreach (Transform child in targetTransform) + { + ApplySortingLayer(child, layerName); + } + } + + #region Public members + + public override void OnEnter() + { + if (targetObject != null) + { + ApplySortingLayer(targetObject.transform, sortingLayer); + } + + Continue(); + } + + public override string GetSummary() + { + if (targetObject == null) + { + return "Error: No game object selected"; + } + + return targetObject.name; + } + + public override Color GetButtonColor() + { + return new Color32(235, 191, 217, 255); + } + + #endregion + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/SetLayerOrder.cs.meta b/Assets/Fungus/Scripts/Commands/SetLayerOrder.cs.meta new file mode 100644 index 0000000..1c47e96 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/SetLayerOrder.cs.meta @@ -0,0 +1,12 @@ +fileFormatVersion: 2 +guid: 673d76133d8494386801a5efa9dd6b7c +timeCreated: 1441190679 +licenseType: Store +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/SetMenuDialog.cs b/Assets/Fungus/Scripts/Commands/SetMenuDialog.cs new file mode 100644 index 0000000..df5c135 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/SetMenuDialog.cs @@ -0,0 +1,49 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; + +namespace Fungus +{ + /// + /// Sets a custom menu dialog to use when displaying multiple choice menus. + /// + [CommandInfo("Narrative", + "Set Menu Dialog", + "Sets a custom menu dialog to use when displaying multiple choice menus")] + [AddComponentMenu("")] + public class SetMenuDialog : Command + { + [Tooltip("The Menu Dialog to use for displaying menu buttons")] + [SerializeField] protected MenuDialog menuDialog; + + #region Public members + + public override void OnEnter() + { + if (menuDialog != null) + { + MenuDialog.ActiveMenuDialog = menuDialog; + } + + Continue(); + } + + public override string GetSummary() + { + if (menuDialog == null) + { + return "Error: No menu dialog selected"; + } + + return menuDialog.name; + } + + public override Color GetButtonColor() + { + return new Color32(184, 210, 235, 255); + } + + #endregion + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/SetMenuDialog.cs.meta b/Assets/Fungus/Scripts/Commands/SetMenuDialog.cs.meta new file mode 100644 index 0000000..e02c8b6 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/SetMenuDialog.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: b097b9790a8a1456a86bc4d322b487db +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Fungus/Scripts/Commands/SetMouseCursor.cs b/Assets/Fungus/Scripts/Commands/SetMouseCursor.cs new file mode 100644 index 0000000..bb67c57 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/SetMouseCursor.cs @@ -0,0 +1,62 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; + +namespace Fungus +{ + /// + /// Sets the mouse cursor sprite. + /// + [CommandInfo("Sprite", + "Set Mouse Cursor", + "Sets the mouse cursor sprite.")] + [AddComponentMenu("")] + public class SetMouseCursor : Command + { + [Tooltip("Texture to use for cursor. Will use default mouse cursor if no sprite is specified")] + [SerializeField] protected Texture2D cursorTexture; + + [Tooltip("The offset from the top left of the texture to use as the target point")] + [SerializeField] protected Vector2 hotSpot; + + // Cached static cursor settings + protected static Texture2D activeCursorTexture; + protected static Vector2 activeHotspot; + + #region Public members + + public static void ResetMouseCursor() + { + // Change mouse cursor back to most recent settings + Cursor.SetCursor(activeCursorTexture, activeHotspot, CursorMode.Auto); + } + + public override void OnEnter() + { + Cursor.SetCursor(cursorTexture, hotSpot, CursorMode.Auto); + + activeCursorTexture = cursorTexture; + activeHotspot = hotSpot; + + Continue(); + } + + public override string GetSummary() + { + if (cursorTexture == null) + { + return "Error: No cursor sprite selected"; + } + + return cursorTexture.name; + } + + public override Color GetButtonColor() + { + return new Color32(235, 191, 217, 255); + } + + #endregion + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/SetMouseCursor.cs.meta b/Assets/Fungus/Scripts/Commands/SetMouseCursor.cs.meta new file mode 100644 index 0000000..62910a5 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/SetMouseCursor.cs.meta @@ -0,0 +1,12 @@ +fileFormatVersion: 2 +guid: fb6f88496f37c444a91acef47749f723 +timeCreated: 1439302629 +licenseType: Store +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/SetSaveProfile.cs b/Assets/Fungus/Scripts/Commands/SetSaveProfile.cs new file mode 100644 index 0000000..22552f8 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/SetSaveProfile.cs @@ -0,0 +1,50 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; +using System; +using System.Collections; + +namespace Fungus +{ + /// + /// Sets the active profile that the Save Variable and Load Variable commands will use. This is useful to crete multiple player save games. Once set, the profile applies across all Flowcharts and will also persist across scene loads. + /// + [CommandInfo("Variable", + "Set Save Profile", + "Sets the active profile that the Save Variable and Load Variable commands will use. This is useful to crete multiple player save games. Once set, the profile applies across all Flowcharts and will also persist across scene loads.")] + [AddComponentMenu("")] + public class SetSaveProfile : Command + { + [Tooltip("Name of save profile to make active.")] + [SerializeField] protected string saveProfileName = ""; + + /// + /// Shared save profile name used by SaveVariable and LoadVariable. + /// + private static string saveProfile = ""; + + #region Public members + + public static String SaveProfile { get { return saveProfile; } } + + public override void OnEnter() + { + saveProfile = saveProfileName; + + Continue(); + } + + public override string GetSummary() + { + return saveProfileName; + } + + public override Color GetButtonColor() + { + return new Color32(235, 191, 217, 255); + } + + #endregion + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/SetSaveProfile.cs.meta b/Assets/Fungus/Scripts/Commands/SetSaveProfile.cs.meta new file mode 100644 index 0000000..29e82ed --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/SetSaveProfile.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 9a240aa44597844f89e6d1ba15a96b04 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Fungus/Scripts/Commands/SetSayDialog.cs b/Assets/Fungus/Scripts/Commands/SetSayDialog.cs new file mode 100644 index 0000000..8297b2d --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/SetSayDialog.cs @@ -0,0 +1,49 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; + +namespace Fungus +{ + /// + /// Sets a custom say dialog to use when displaying story text. + /// + [CommandInfo("Narrative", + "Set Say Dialog", + "Sets a custom say dialog to use when displaying story text")] + [AddComponentMenu("")] + public class SetSayDialog : Command + { + [Tooltip("The Say Dialog to use for displaying Say story text")] + [SerializeField] protected SayDialog sayDialog; + + #region Public members + + public override void OnEnter() + { + if (sayDialog != null) + { + SayDialog.ActiveSayDialog = sayDialog; + } + + Continue(); + } + + public override string GetSummary() + { + if (sayDialog == null) + { + return "Error: No say dialog selected"; + } + + return sayDialog.name; + } + + public override Color GetButtonColor() + { + return new Color32(184, 210, 235, 255); + } + + #endregion + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/SetSayDialog.cs.meta b/Assets/Fungus/Scripts/Commands/SetSayDialog.cs.meta new file mode 100644 index 0000000..5c3ac7f --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/SetSayDialog.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: d65d551a201c94bc79950076ff3eaf2e +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Fungus/Scripts/Commands/SetSliderValue.cs b/Assets/Fungus/Scripts/Commands/SetSliderValue.cs new file mode 100644 index 0000000..a3e3d93 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/SetSliderValue.cs @@ -0,0 +1,57 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; +using UnityEngine.UI; + +namespace Fungus +{ + /// + /// Sets the value property of a slider object. + /// + [CommandInfo("UI", + "Set Slider Value", + "Sets the value property of a slider object")] + public class SetSliderValue : Command + { + [Tooltip("Target slider object to set the value on")] + [SerializeField] protected Slider slider; + + [Tooltip("Float value to set the slider value to.")] + [SerializeField] protected FloatData value; + + #region Public members + + public override void OnEnter() + { + if (slider != null) + { + slider.value = value; + } + + Continue(); + } + + public override Color GetButtonColor() + { + return new Color32(235, 191, 217, 255); + } + + public override string GetSummary() + { + if (slider == null) + { + return "Error: Slider object not selected"; + } + + return slider.name + " = " + value.GetDescription(); + } + + public override bool HasReference(Variable variable) + { + return value.floatRef == variable || base.HasReference(variable); + } + + #endregion + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/SetSliderValue.cs.meta b/Assets/Fungus/Scripts/Commands/SetSliderValue.cs.meta new file mode 100644 index 0000000..5501ed7 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/SetSliderValue.cs.meta @@ -0,0 +1,12 @@ +fileFormatVersion: 2 +guid: 2d82f2f1b848347c19a48abd65541523 +timeCreated: 1444656241 +licenseType: Store +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/SetSprite.cs b/Assets/Fungus/Scripts/Commands/SetSprite.cs new file mode 100644 index 0000000..1968fc9 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/SetSprite.cs @@ -0,0 +1,87 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +// Snippet added by ducksonthewater, 2019-01-03 - www.ducks-on-the-water.com + +using UnityEngine; +using System.Collections.Generic; + +namespace Fungus +{ + /// + /// Changes the sprite on a SpriteRenderer. + /// + [CommandInfo("Sprite", + "Set Sprite", + "Changes the sprite property of a list of Sprite Renderers.")] + [AddComponentMenu("")] + public class SetSprite : Command + { + [Tooltip("List of sprites to set the sprite property on")] + [SerializeField] protected List spriteRenderers = new List(); + + [Tooltip("The sprite set on the target sprite renderers")] + [SerializeField] protected Sprite sprite; + + #region Public members + + public override void OnEnter() + { + for (int i = 0; i < spriteRenderers.Count; i++) + { + var spriteRenderer = spriteRenderers[i]; + spriteRenderer.sprite = sprite; + } + + Continue(); + } + + public override string GetSummary() + { + string summary = ""; + for (int i = 0; i < spriteRenderers.Count; i++) + { + var spriteRenderer = spriteRenderers[i]; + if (spriteRenderer == null) + { + continue; + } + if (summary.Length > 0) + { + summary += ", "; + } + summary += spriteRenderer.name; + } + + if (summary.Length == 0) + { + return "Error: No sprite selected"; + } + + return summary + " = " + sprite; + } + + public override Color GetButtonColor() + { + return new Color32(235, 191, 217, 255); + } + + public override bool IsReorderableArray(string propertyName) + { + if (propertyName == "spriteRenderers") + { + return true; + } + + return false; + } + + public override void OnCommandAdded(Block parentBlock) + { + // Add a default empty entry + spriteRenderers.Add(null); + } + + #endregion + } +} diff --git a/Assets/Fungus/Scripts/Commands/SetSprite.cs.meta b/Assets/Fungus/Scripts/Commands/SetSprite.cs.meta new file mode 100644 index 0000000..aa8315a --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/SetSprite.cs.meta @@ -0,0 +1,12 @@ +fileFormatVersion: 2 +guid: 8bacd6d8da56644cbb2c9a43f96750c3 +timeCreated: 1439385260 +licenseType: Store +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/SetSpriteOrder.cs b/Assets/Fungus/Scripts/Commands/SetSpriteOrder.cs new file mode 100644 index 0000000..a233f4d --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/SetSpriteOrder.cs @@ -0,0 +1,90 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; +using System.Collections.Generic; + +namespace Fungus +{ + /// + /// Controls the render order of sprites by setting the Order In Layer property of a list of sprites. + /// + [CommandInfo("Sprite", + "Set Sprite Order", + "Controls the render order of sprites by setting the Order In Layer property of a list of sprites.")] + [AddComponentMenu("")] + public class SetSpriteOrder : Command + { + [Tooltip("List of sprites to set the order in layer property on")] + [SerializeField] protected List targetSprites = new List(); + + [Tooltip("The order in layer value to set on the target sprites")] + [SerializeField] protected IntegerData orderInLayer; + + #region Public members + + public override void OnEnter() + { + for (int i = 0; i < targetSprites.Count; i++) + { + var spriteRenderer = targetSprites[i]; + spriteRenderer.sortingOrder = orderInLayer; + } + + Continue(); + } + + public override string GetSummary() + { + string summary = ""; + for (int i = 0; i < targetSprites.Count; i++) + { + var spriteRenderer = targetSprites[i]; + if (spriteRenderer == null) + { + continue; + } + if (summary.Length > 0) + { + summary += ", "; + } + summary += spriteRenderer.name; + } + + if (summary.Length == 0) + { + return "Error: No cursor sprite selected"; + } + + return summary + " = " + orderInLayer.Value; + } + + public override Color GetButtonColor() + { + return new Color32(235, 191, 217, 255); + } + + public override bool IsReorderableArray(string propertyName) + { + if (propertyName == "targetSprites") + { + return true; + } + + return false; + } + + public override void OnCommandAdded(Block parentBlock) + { + // Add a default empty entry + targetSprites.Add(null); + } + + public override bool HasReference(Variable variable) + { + return orderInLayer.integerRef == variable || base.HasReference(variable); + } + + #endregion + } +} diff --git a/Assets/Fungus/Scripts/Commands/SetSpriteOrder.cs.meta b/Assets/Fungus/Scripts/Commands/SetSpriteOrder.cs.meta new file mode 100644 index 0000000..bd46760 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/SetSpriteOrder.cs.meta @@ -0,0 +1,12 @@ +fileFormatVersion: 2 +guid: 5d1724bb98f694376b7653fa24a54541 +timeCreated: 1439385260 +licenseType: Store +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/SetText.cs b/Assets/Fungus/Scripts/Commands/SetText.cs new file mode 100644 index 0000000..2591805 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/SetText.cs @@ -0,0 +1,130 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; +using UnityEngine.UI; +using UnityEngine.Serialization; + +namespace Fungus +{ + /// + /// Sets the text property on a UI Text object and/or an Input Field object. + /// + [CommandInfo("UI", + "Set Text", + "Sets the text property on a UI Text object and/or an Input Field object.")] + [AddComponentMenu("")] + public class SetText : Command, ILocalizable + { + [Tooltip("Text object to set text on. Can be a UI Text, Text Field or Text Mesh object.")] + [SerializeField] protected GameObject targetTextObject; + + [Tooltip("String value to assign to the text object")] + [FormerlySerializedAs("stringData")] + [SerializeField] protected StringDataMulti text; + + [Tooltip("Notes about this story text for other authors, localization, etc.")] + [SerializeField] protected string description; + + #region Public members + + public override void OnEnter() + { + var flowchart = GetFlowchart(); + string newText = flowchart.SubstituteVariables(text.Value); + + if (targetTextObject == null) + { + Continue(); + return; + } + + TextAdapter textAdapter = new TextAdapter(); + textAdapter.InitFromGameObject(targetTextObject); + + if (textAdapter.HasTextObject()) + { + textAdapter.Text = newText; + } + + Continue(); + } + + public override string GetSummary() + { + if (targetTextObject != null) + { + return targetTextObject.name + " : " + text.Value; + } + + return "Error: No text object selected"; + } + + public override Color GetButtonColor() + { + return new Color32(235, 191, 217, 255); + } + + public override bool HasReference(Variable variable) + { + return text.stringRef == variable || base.HasReference(variable); + } + + #endregion + + + #region Editor caches +#if UNITY_EDITOR + protected override void RefreshVariableCache() + { + base.RefreshVariableCache(); + + var f = GetFlowchart(); + + f.DetermineSubstituteVariables(text, referencedVariables); + } +#endif + #endregion Editor caches + + #region ILocalizable implementation + + public virtual string GetStandardText() + { + return text; + } + + public virtual void SetStandardText(string standardText) + { + text.Value = standardText; + } + + public virtual string GetDescription() + { + return description; + } + + public virtual string GetStringId() + { + // String id for Set Text commands is SETTEXT.. + return "SETTEXT." + GetFlowchartLocalizationId() + "." + itemId; + } + + #endregion + + #region Backwards compatibility + + // Backwards compatibility with Fungus v2.1.2 + [HideInInspector] + [FormerlySerializedAs("textObject")] + public Text _textObjectObsolete; + protected virtual void OnEnable() + { + if (_textObjectObsolete != null) + { + targetTextObject = _textObjectObsolete.gameObject; + } + } + + #endregion + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/SetText.cs.meta b/Assets/Fungus/Scripts/Commands/SetText.cs.meta new file mode 100644 index 0000000..f4ca491 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/SetText.cs.meta @@ -0,0 +1,12 @@ +fileFormatVersion: 2 +guid: 78c0367bf08d147bd80b5454de50e9d4 +timeCreated: 1438782798 +licenseType: Store +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/SetToggleState.cs b/Assets/Fungus/Scripts/Commands/SetToggleState.cs new file mode 100644 index 0000000..361f9d4 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/SetToggleState.cs @@ -0,0 +1,57 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; +using UnityEngine.UI; + +namespace Fungus +{ + /// + /// Sets the state of a toggle UI object. + /// + [CommandInfo("UI", + "Set Toggle State", + "Sets the state of a toggle UI object")] + public class SetToggleState : Command + { + [Tooltip("Target toggle object to set the state on")] + [SerializeField] protected Toggle toggle; + + [Tooltip("Boolean value to set the toggle state to.")] + [SerializeField] protected BooleanData value; + + #region Public members + + public override void OnEnter() + { + if (toggle != null) + { + toggle.isOn = value.Value; + } + + Continue(); + } + + public override Color GetButtonColor() + { + return new Color32(235, 191, 217, 255); + } + + public override string GetSummary() + { + if (toggle == null) + { + return "Error: Toggle object not selected"; + } + + return toggle.name + " = " + value.GetDescription(); + } + + public override bool HasReference(Variable variable) + { + return value.booleanRef == variable || base.HasReference(variable); + } + + #endregion + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/SetToggleState.cs.meta b/Assets/Fungus/Scripts/Commands/SetToggleState.cs.meta new file mode 100644 index 0000000..207e6fc --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/SetToggleState.cs.meta @@ -0,0 +1,12 @@ +fileFormatVersion: 2 +guid: 41ef36697f78e4c6e909d158bd8ccc83 +timeCreated: 1444656241 +licenseType: Store +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/SetUIImage.cs b/Assets/Fungus/Scripts/Commands/SetUIImage.cs new file mode 100644 index 0000000..5a811bd --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/SetUIImage.cs @@ -0,0 +1,86 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; +using System.Collections.Generic; +using UnityEngine.UI; + +namespace Fungus +{ + /// + /// Changes the Image property on a UI element. + /// + [CommandInfo("UI", + "Set UI Image", + "Changes the Image property of a list of UI Images.")] + [AddComponentMenu("")] + public class SetUIImage : Command + { + [Tooltip("List of UI Images to set the source image property on")] + [SerializeField] protected List images = new List(); + + [Tooltip("The sprite set on the source image property")] + [SerializeField] protected Sprite sprite; + + #region Public members + + public override void OnEnter() + { + for (int i = 0; i < images.Count; i++) + { + var image = images[i]; + image.sprite = sprite; + } + + Continue(); + } + + public override string GetSummary() + { + string summary = ""; + for (int i = 0; i < images.Count; i++) + { + var targetImage = images[i]; + if (targetImage == null) + { + continue; + } + if (summary.Length > 0) + { + summary += ", "; + } + summary += targetImage.name; + } + + if (summary.Length == 0) + { + return "Error: No sprite selected"; + } + + return summary + " = " + sprite; + } + + public override Color GetButtonColor() + { + return new Color32(235, 191, 217, 255); + } + + public override bool IsReorderableArray(string propertyName) + { + if (propertyName == "images") + { + return true; + } + + return false; + } + + public override void OnCommandAdded(Block parentBlock) + { + // Add a default empty entry + images.Add(null); + } + + #endregion + } +} diff --git a/Assets/Fungus/Scripts/Commands/SetUIImage.cs.meta b/Assets/Fungus/Scripts/Commands/SetUIImage.cs.meta new file mode 100644 index 0000000..39b80dd --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/SetUIImage.cs.meta @@ -0,0 +1,12 @@ +fileFormatVersion: 2 +guid: 82e4c082f762243f6943909a4272096d +timeCreated: 1439385260 +licenseType: Store +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/SetVariable.cs b/Assets/Fungus/Scripts/Commands/SetVariable.cs new file mode 100644 index 0000000..d55650e --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/SetVariable.cs @@ -0,0 +1,245 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; +using System.Collections.Generic; + +namespace Fungus +{ + /// + /// Sets a Boolean, Integer, Float or String variable to a new value using a simple arithmetic operation. The value can be a constant or reference another variable of the same type. + /// + [CommandInfo("Variable", + "Set Variable", + "Sets a Boolean, Integer, Float or String variable to a new value using a simple arithmetic operation. The value can be a constant or reference another variable of the same type.")] + [AddComponentMenu("")] + public class SetVariable : Command, ISerializationCallbackReceiver + { + [SerializeField] protected AnyVariableAndDataPair anyVar = new AnyVariableAndDataPair(); + + [Tooltip("The type of math operation to be performed")] + [SerializeField] protected SetOperator setOperator; + + protected virtual void DoSetOperation() + { + if (anyVar.variable == null) + { + return; + } + + anyVar.SetOp(setOperator); + } + + #region Public members + + /// + /// The type of math operation to be performed. + /// + public virtual SetOperator _SetOperator { get { return setOperator; } } + + public override void OnEnter() + { + DoSetOperation(); + + Continue(); + } + + public override string GetSummary() + { + if (anyVar.variable == null) + { + return "Error: Variable not selected"; + } + + string description = anyVar.variable.Key; + description += " " + VariableUtil.GetSetOperatorDescription(setOperator) + " "; + description += anyVar.GetDataDescription(); + + + return description; + } + + public override bool HasReference(Variable variable) + { + return anyVar.HasReference(variable); + } + + public override Color GetButtonColor() + { + return new Color32(253, 253, 150, 255); + } + + #endregion + + + + #region Editor caches +#if UNITY_EDITOR + protected override void RefreshVariableCache() + { + base.RefreshVariableCache(); + + if(anyVar != null) + anyVar.RefreshVariableCacheHelper(GetFlowchart(), ref referencedVariables); + } +#endif + #endregion Editor caches + + #region backwards compat + + + [Tooltip("Variable to use in expression")] + [VariableProperty(AllVariableTypes.VariableAny.Any)] + [SerializeField] protected Variable variable; + + [Tooltip("Boolean value to compare against")] + [SerializeField] protected BooleanData booleanData; + + [Tooltip("Integer value to compare against")] + [SerializeField] protected IntegerData integerData; + + [Tooltip("Float value to compare against")] + [SerializeField] protected FloatData floatData; + + [Tooltip("String value to compare against")] + [SerializeField] protected StringDataMulti stringData; + + [Tooltip("Animator value to compare against")] + [SerializeField] protected AnimatorData animatorData; + + [Tooltip("AudioSource value to compare against")] + [SerializeField] protected AudioSourceData audioSourceData; + + [Tooltip("Color value to compare against")] + [SerializeField] protected ColorData colorData; + + [Tooltip("GameObject value to compare against")] + [SerializeField] protected GameObjectData gameObjectData; + + [Tooltip("Material value to compare against")] + [SerializeField] protected MaterialData materialData; + + [Tooltip("Object value to compare against")] + [SerializeField] protected ObjectData objectData; + + [Tooltip("Rigidbody2D value to compare against")] + [SerializeField] protected Rigidbody2DData rigidbody2DData; + + [Tooltip("Sprite value to compare against")] + [SerializeField] protected SpriteData spriteData; + + [Tooltip("Texture value to compare against")] + [SerializeField] protected TextureData textureData; + + [Tooltip("Transform value to compare against")] + [SerializeField] protected TransformData transformData; + + [Tooltip("Vector2 value to compare against")] + [SerializeField] protected Vector2Data vector2Data; + + [Tooltip("Vector3 value to compare against")] + [SerializeField] protected Vector3Data vector3Data; + + public void OnBeforeSerialize() + { + } + + void ISerializationCallbackReceiver.OnAfterDeserialize() + { + if (variable == null) + { + return; + } + else + { + anyVar.variable = variable; + } + + if (variable.GetType() == typeof(BooleanVariable) && !booleanData.Equals(new BooleanData())) + { + anyVar.data.booleanData = booleanData; + booleanData = new BooleanData(); + } + else if (variable.GetType() == typeof(IntegerVariable) && !integerData.Equals(new IntegerData())) + { + anyVar.data.integerData = integerData; + integerData = new IntegerData(); + } + else if (variable.GetType() == typeof(FloatVariable) && !floatData.Equals(new FloatData())) + { + anyVar.data.floatData = floatData; + floatData = new FloatData(); + } + else if (variable.GetType() == typeof(StringVariable) && !stringData.Equals(new StringDataMulti())) + { + anyVar.data.stringData.stringRef = stringData.stringRef; + anyVar.data.stringData.stringVal = stringData.stringVal; + stringData = new StringDataMulti(); + } + else if (variable.GetType() == typeof(AnimatorVariable) && !animatorData.Equals(new AnimatorData())) + { + anyVar.data.animatorData = animatorData; + animatorData = new AnimatorData(); + } + else if (variable.GetType() == typeof(AudioSourceVariable) && !audioSourceData.Equals(new AudioSourceData())) + { + anyVar.data.audioSourceData = audioSourceData; + audioSourceData = new AudioSourceData(); + } + else if (variable.GetType() == typeof(ColorVariable) && !colorData.Equals(new ColorData())) + { + anyVar.data.colorData = colorData; + colorData = new ColorData(); + } + else if (variable.GetType() == typeof(GameObjectVariable) && !gameObjectData.Equals(new GameObjectData())) + { + anyVar.data.gameObjectData = gameObjectData; + gameObjectData = new GameObjectData(); + } + else if (variable.GetType() == typeof(MaterialVariable) && !materialData.Equals(new MaterialData())) + { + anyVar.data.materialData = materialData; + materialData = new MaterialData(); + } + else if (variable.GetType() == typeof(ObjectVariable) && !objectData.Equals(new ObjectData())) + { + anyVar.data.objectData = objectData; + objectData = new ObjectData(); + } + else if (variable.GetType() == typeof(Rigidbody2DVariable) && !rigidbody2DData.Equals(new Rigidbody2DData())) + { + anyVar.data.rigidbody2DData = rigidbody2DData; + rigidbody2DData = new Rigidbody2DData(); + } + else if (variable.GetType() == typeof(SpriteVariable) && !spriteData.Equals(new SpriteData())) + { + anyVar.data.spriteData = spriteData; + spriteData = new SpriteData(); + } + else if (variable.GetType() == typeof(TextureVariable) && !textureData.Equals(new TextureData())) + { + anyVar.data.textureData = textureData; + textureData = new TextureData(); + } + else if (variable.GetType() == typeof(TransformVariable) && !transformData.Equals(new TransformData())) + { + anyVar.data.transformData = transformData; + transformData = new TransformData(); + } + else if (variable.GetType() == typeof(Vector2Variable) && !vector2Data.Equals(new Vector2Data())) + { + anyVar.data.vector2Data = vector2Data; + vector2Data = new Vector2Data(); + } + else if (variable.GetType() == typeof(Vector3Variable) && !vector3Data.Equals(new Vector3Data())) + { + anyVar.data.vector3Data = vector3Data; + vector3Data = new Vector3Data(); + } + + //now converted to new AnyVar storage, remove the legacy. + variable = null; + } + #endregion + } +} diff --git a/Assets/Fungus/Scripts/Commands/SetVariable.cs.meta b/Assets/Fungus/Scripts/Commands/SetVariable.cs.meta new file mode 100644 index 0000000..efb68c0 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/SetVariable.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: fb77d0ce495044f6e9feb91b31798e8c +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Fungus/Scripts/Commands/ShakeCamera.cs b/Assets/Fungus/Scripts/Commands/ShakeCamera.cs new file mode 100644 index 0000000..aca845b --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/ShakeCamera.cs @@ -0,0 +1,72 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; +using System.Collections; + +namespace Fungus +{ + /// + /// Applies a camera shake effect to the main camera. + /// + [CommandInfo("Camera", + "Shake Camera", + "Applies a camera shake effect to the main camera.")] + [AddComponentMenu("")] + public class ShakeCamera : Command + { + [Tooltip("Time for camera shake effect to complete")] + [SerializeField] protected float duration = 0.5f; + + [Tooltip("Magnitude of shake effect in x & y axes")] + [SerializeField] protected Vector2 amount = new Vector2(1, 1); + + [Tooltip("Wait until the shake effect has finished before executing next command")] + [SerializeField] protected bool waitUntilFinished; + + protected virtual void OniTweenComplete(object param) + { + Command command = param as Command; + if (command != null && command.Equals(this)) + { + if (waitUntilFinished) + { + Continue(); + } + } + } + + #region Public members + + public override void OnEnter() + { + Vector3 v = new Vector3(); + v = amount; + + Hashtable tweenParams = new Hashtable(); + tweenParams.Add("amount", v); + tweenParams.Add("time", duration); + tweenParams.Add("oncomplete", "OniTweenComplete"); + tweenParams.Add("oncompletetarget", gameObject); + tweenParams.Add("oncompleteparams", this); + iTween.ShakePosition(Camera.main.gameObject, tweenParams); + + if (!waitUntilFinished) + { + Continue(); + } + } + + public override string GetSummary() + { + return "For " + duration + " seconds."; + } + + public override Color GetButtonColor() + { + return new Color32(216, 228, 170, 255); + } + + #endregion + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/ShakeCamera.cs.meta b/Assets/Fungus/Scripts/Commands/ShakeCamera.cs.meta new file mode 100644 index 0000000..e6b9dfa --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/ShakeCamera.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 616cd37e21c7645c58a89edf5abee56f +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Fungus/Scripts/Commands/ShakePosition.cs b/Assets/Fungus/Scripts/Commands/ShakePosition.cs new file mode 100644 index 0000000..86a1c48 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/ShakePosition.cs @@ -0,0 +1,82 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; +using UnityEngine.Serialization; +using System.Collections; + +namespace Fungus +{ + /// + /// Randomly shakes a GameObject's position by a diminishing amount over time. + /// + [CommandInfo("iTween", + "Shake Position", + "Randomly shakes a GameObject's position by a diminishing amount over time.")] + [AddComponentMenu("")] + [ExecuteInEditMode] + public class ShakePosition : iTweenCommand + { + [Tooltip("A translation offset in space the GameObject will animate to")] + [SerializeField] protected Vector3Data _amount; + + [Tooltip("Whether to animate in world space or relative to the parent. False by default.")] + [SerializeField] protected bool isLocal; + + [Tooltip("Restricts rotation to the supplied axis only")] + [SerializeField] protected iTweenAxis axis; + + #region Public members + + public override void DoTween() + { + Hashtable tweenParams = new Hashtable(); + tweenParams.Add("name", _tweenName.Value); + tweenParams.Add("amount", _amount.Value); + switch (axis) + { + case iTweenAxis.X: + tweenParams.Add("axis", "x"); + break; + case iTweenAxis.Y: + tweenParams.Add("axis", "y"); + break; + case iTweenAxis.Z: + tweenParams.Add("axis", "z"); + break; + } + tweenParams.Add("time", _duration.Value); + tweenParams.Add("easetype", easeType); + tweenParams.Add("looptype", loopType); + tweenParams.Add("isLocal", isLocal); + tweenParams.Add("oncomplete", "OniTweenComplete"); + tweenParams.Add("oncompletetarget", gameObject); + tweenParams.Add("oncompleteparams", this); + iTween.ShakePosition(_targetObject.Value, tweenParams); + } + + public override bool HasReference(Variable variable) + { + return _amount.vector3Ref == variable || base.HasReference(variable); + } + + #endregion + + #region Backwards compatibility + + [HideInInspector] [FormerlySerializedAs("amount")] public Vector3 amountOLD; + + protected override void OnEnable() + { + base.OnEnable(); + + if (amountOLD != default(Vector3)) + { + _amount.Value = amountOLD; + amountOLD = default(Vector3); + } + } + + #endregion + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/ShakePosition.cs.meta b/Assets/Fungus/Scripts/Commands/ShakePosition.cs.meta new file mode 100644 index 0000000..012ad42 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/ShakePosition.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 358f65040c3ef4327b70b2813cc197c7 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Fungus/Scripts/Commands/ShakeRotation.cs b/Assets/Fungus/Scripts/Commands/ShakeRotation.cs new file mode 100644 index 0000000..a5982cd --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/ShakeRotation.cs @@ -0,0 +1,67 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; +using UnityEngine.Serialization; +using System.Collections; + +namespace Fungus +{ + /// + /// Randomly shakes a GameObject's rotation by a diminishing amount over time. + /// + [CommandInfo("iTween", + "Shake Rotation", + "Randomly shakes a GameObject's rotation by a diminishing amount over time.")] + [AddComponentMenu("")] + [ExecuteInEditMode] + public class ShakeRotation : iTweenCommand + { + [Tooltip("A rotation offset in space the GameObject will animate to")] + [SerializeField] protected Vector3Data _amount; + + [Tooltip("Apply the transformation in either the world coordinate or local cordinate system")] + [SerializeField] protected Space space = Space.Self; + + #region Public members + + public override void DoTween() + { + Hashtable tweenParams = new Hashtable(); + tweenParams.Add("name", _tweenName.Value); + tweenParams.Add("amount", _amount.Value); + tweenParams.Add("space", space); + tweenParams.Add("time", _duration.Value); + tweenParams.Add("easetype", easeType); + tweenParams.Add("looptype", loopType); + tweenParams.Add("oncomplete", "OniTweenComplete"); + tweenParams.Add("oncompletetarget", gameObject); + tweenParams.Add("oncompleteparams", this); + iTween.ShakeRotation(_targetObject.Value, tweenParams); + } + + public override bool HasReference(Variable variable) + { + return _amount.vector3Ref == variable || base.HasReference(variable); + } + + #endregion + + #region Backwards compatibility + + [HideInInspector] [FormerlySerializedAs("amount")] public Vector3 amountOLD; + + protected override void OnEnable() + { + base.OnEnable(); + + if (amountOLD != default(Vector3)) + { + _amount.Value = amountOLD; + amountOLD = default(Vector3); + } + } + + #endregion + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/ShakeRotation.cs.meta b/Assets/Fungus/Scripts/Commands/ShakeRotation.cs.meta new file mode 100644 index 0000000..419b0fc --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/ShakeRotation.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 82c753a90aa184bd88472f4589167f0b +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Fungus/Scripts/Commands/ShakeScale.cs b/Assets/Fungus/Scripts/Commands/ShakeScale.cs new file mode 100644 index 0000000..5bb96b8 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/ShakeScale.cs @@ -0,0 +1,63 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; +using UnityEngine.Serialization; +using System.Collections; + +namespace Fungus +{ + /// + /// Randomly shakes a GameObject's rotation by a diminishing amount over time. + /// + [CommandInfo("iTween", + "Shake Scale", + "Randomly shakes a GameObject's rotation by a diminishing amount over time.")] + [AddComponentMenu("")] + [ExecuteInEditMode] + public class ShakeScale : iTweenCommand + { + [Tooltip("A scale offset in space the GameObject will animate to")] + [SerializeField] protected Vector3Data _amount; + + #region Public members + + public override void DoTween() + { + Hashtable tweenParams = new Hashtable(); + tweenParams.Add("name", _tweenName.Value); + tweenParams.Add("amount", _amount.Value); + tweenParams.Add("time", _duration.Value); + tweenParams.Add("easetype", easeType); + tweenParams.Add("looptype", loopType); + tweenParams.Add("oncomplete", "OniTweenComplete"); + tweenParams.Add("oncompletetarget", gameObject); + tweenParams.Add("oncompleteparams", this); + iTween.ShakeScale(_targetObject.Value, tweenParams); + } + + public override bool HasReference(Variable variable) + { + return _amount.vector3Ref == variable || base.HasReference(variable); + } + + #endregion + + #region Backwards compatibility + + [HideInInspector] [FormerlySerializedAs("amount")] public Vector3 amountOLD; + + protected override void OnEnable() + { + base.OnEnable(); + + if (amountOLD != default(Vector3)) + { + _amount.Value = amountOLD; + amountOLD = default(Vector3); + } + } + + #endregion + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/ShakeScale.cs.meta b/Assets/Fungus/Scripts/Commands/ShakeScale.cs.meta new file mode 100644 index 0000000..aec79a0 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/ShakeScale.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: e61780d2ea956492a8f59308dae6f12c +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Fungus/Scripts/Commands/ShowSprite.cs b/Assets/Fungus/Scripts/Commands/ShowSprite.cs new file mode 100644 index 0000000..ce4b032 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/ShowSprite.cs @@ -0,0 +1,96 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; +using UnityEngine.Serialization; + +namespace Fungus +{ + /// + /// Makes a sprite visible / invisible by setting the color alpha. + /// + [CommandInfo("Sprite", + "Show Sprite", + "Makes a sprite visible / invisible by setting the color alpha.")] + [AddComponentMenu("")] + [ExecuteInEditMode] + public class ShowSprite : Command + { + [Tooltip("Sprite object to be made visible / invisible")] + [SerializeField] protected SpriteRenderer spriteRenderer; + + [Tooltip("Make the sprite visible or invisible")] + [SerializeField] protected BooleanData _visible = new BooleanData(false); + + [Tooltip("Affect the visibility of child sprites")] + [SerializeField] protected bool affectChildren = true; + + protected virtual void SetSpriteAlpha(SpriteRenderer renderer, bool visible) + { + Color spriteColor = renderer.color; + spriteColor.a = visible ? 1f : 0f; + renderer.color = spriteColor; + } + + #region Public members + + public override void OnEnter() + { + if (spriteRenderer != null) + { + if (affectChildren) + { + var spriteRenderers = spriteRenderer.gameObject.GetComponentsInChildren(); + for (int i = 0; i < spriteRenderers.Length; i++) + { + var sr = spriteRenderers[i]; + SetSpriteAlpha(sr, _visible.Value); + } + } + else + { + SetSpriteAlpha(spriteRenderer, _visible.Value); + } + } + + Continue(); + } + + public override string GetSummary() + { + if (spriteRenderer == null) + { + return "Error: No sprite renderer selected"; + } + + return spriteRenderer.name + " to " + (_visible.Value ? "visible" : "invisible"); + } + + public override Color GetButtonColor() + { + return new Color32(221, 184, 169, 255); + } + + public override bool HasReference(Variable variable) + { + return _visible.booleanRef == variable || base.HasReference(variable); + } + + #endregion + + #region Backwards compatibility + + [HideInInspector] [FormerlySerializedAs("visible")] public bool visibleOLD; + + protected virtual void OnEnable() + { + if (visibleOLD != default(bool)) + { + _visible.Value = visibleOLD; + visibleOLD = default(bool); + } + } + + #endregion + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/ShowSprite.cs.meta b/Assets/Fungus/Scripts/Commands/ShowSprite.cs.meta new file mode 100644 index 0000000..2cf83bf --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/ShowSprite.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 10cd462c89cb047158ccfb8a8df3f60a +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Fungus/Scripts/Commands/SpawnObject.cs b/Assets/Fungus/Scripts/Commands/SpawnObject.cs new file mode 100644 index 0000000..7bff6e2 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/SpawnObject.cs @@ -0,0 +1,140 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; +using UnityEngine.Serialization; + +namespace Fungus +{ + /// + /// Spawns a new object based on a reference to a scene or prefab game object. + /// + [CommandInfo("Scripting", + "Spawn Object", + "Spawns a new object based on a reference to a scene or prefab game object.", + Priority = 10)] + [CommandInfo("GameObject", + "Instantiate", + "Instantiate a game object")] + [AddComponentMenu("")] + [ExecuteInEditMode] + public class SpawnObject : Command + { + [Tooltip("Game object to copy when spawning. Can be a scene object or a prefab.")] + [SerializeField] protected GameObjectData _sourceObject; + + [Tooltip("Transform to use as parent during instantiate.")] + [SerializeField] protected TransformData _parentTransform; + + [Tooltip("If true, will use the Transfrom of this Flowchart for the position and rotation.")] + [SerializeField] protected BooleanData _spawnAtSelf = new BooleanData(false); + + [Tooltip("Local position of newly spawned object.")] + [SerializeField] protected Vector3Data _spawnPosition; + + [Tooltip("Local rotation of newly spawned object.")] + [SerializeField] protected Vector3Data _spawnRotation; + + + + [Tooltip("Optional variable to store the GameObject that was just created.")] + [SerializeField] + protected GameObjectData _newlySpawnedObject; + + #region Public members + + public override void OnEnter() + { + if (_sourceObject.Value == null) + { + Continue(); + return; + } + + GameObject newObject = null; + + if (_parentTransform.Value != null) + { + newObject = GameObject.Instantiate(_sourceObject.Value,_parentTransform.Value); + } + else + { + newObject = GameObject.Instantiate(_sourceObject.Value); + } + + if (!_spawnAtSelf.Value) + { + newObject.transform.localPosition = _spawnPosition.Value; + newObject.transform.localRotation = Quaternion.Euler(_spawnRotation.Value); + } + else + { + newObject.transform.SetPositionAndRotation(transform.position, transform.rotation); + } + + _newlySpawnedObject.Value = newObject; + + Continue(); + } + + public override string GetSummary() + { + if (_sourceObject.Value == null) + { + return "Error: No source GameObject specified"; + } + + return _sourceObject.Value.name; + } + + public override Color GetButtonColor() + { + return new Color32(235, 191, 217, 255); + } + + public override bool HasReference(Variable variable) + { + if (_sourceObject.gameObjectRef == variable || _parentTransform.transformRef == variable || + _spawnAtSelf.booleanRef == variable || _spawnPosition.vector3Ref == variable || + _spawnRotation.vector3Ref == variable) + return true; + + return false; + } + + #endregion + + #region Backwards compatibility + + [HideInInspector] [FormerlySerializedAs("sourceObject")] public GameObject sourceObjectOLD; + [HideInInspector] [FormerlySerializedAs("parentTransform")] public Transform parentTransformOLD; + [HideInInspector] [FormerlySerializedAs("spawnPosition")] public Vector3 spawnPositionOLD; + [HideInInspector] [FormerlySerializedAs("spawnRotation")] public Vector3 spawnRotationOLD; + + protected virtual void OnEnable() + { + if (sourceObjectOLD != null) + { + _sourceObject.Value = sourceObjectOLD; + sourceObjectOLD = null; + } + if (parentTransformOLD != null) + { + _parentTransform.Value = parentTransformOLD; + parentTransformOLD = null; + } + if (spawnPositionOLD != default(Vector3)) + { + _spawnPosition.Value = spawnPositionOLD; + spawnPositionOLD = default(Vector3); + } + if (spawnRotationOLD != default(Vector3)) + { + _spawnRotation.Value = spawnRotationOLD; + spawnRotationOLD = default(Vector3); + } + } + + #endregion + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/SpawnObject.cs.meta b/Assets/Fungus/Scripts/Commands/SpawnObject.cs.meta new file mode 100644 index 0000000..e410bce --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/SpawnObject.cs.meta @@ -0,0 +1,12 @@ +fileFormatVersion: 2 +guid: bb3e86f556e074b84af1cc7eb8f8e5e7 +timeCreated: 1431443741 +licenseType: Store +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/StartSwipe.cs b/Assets/Fungus/Scripts/Commands/StartSwipe.cs new file mode 100644 index 0000000..23281cf --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/StartSwipe.cs @@ -0,0 +1,83 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; + +namespace Fungus +{ + /// + /// Activates swipe panning mode where the player can pan the camera within the area between viewA & viewB. + /// + [CommandInfo("Camera", + "Start Swipe", + "Activates swipe panning mode where the player can pan the camera within the area between viewA & viewB.")] + [AddComponentMenu("")] + public class StartSwipe : Command + { + [Tooltip("Defines one extreme of the scrollable area that the player can pan around")] + [SerializeField] protected View viewA; + + [Tooltip("Defines one extreme of the scrollable area that the player can pan around")] + [SerializeField] protected View viewB; + + [Tooltip("Time to move the camera to a valid starting position between the two views")] + [SerializeField] protected float duration = 0.5f; + + [Tooltip("Multiplier factor for speed of swipe pan")] + [SerializeField] protected float speedMultiplier = 1f; + + [Tooltip("Camera to use for the pan. Will use main camera if set to none.")] + [SerializeField] protected Camera targetCamera; + + #region Public members + + public virtual void Start() + { + if (targetCamera == null) + { + targetCamera = Camera.main; + } + if (targetCamera == null) + { + targetCamera = GameObject.FindObjectOfType(); + } + } + + public override void OnEnter() + { + if (targetCamera == null || + viewA == null || + viewB == null) + { + Continue(); + return; + } + + var cameraManager = FungusManager.Instance.CameraManager; + + cameraManager.StartSwipePan(targetCamera, viewA, viewB, duration, speedMultiplier, () => Continue() ); + } + + public override string GetSummary() + { + if (viewA == null) + { + return "Error: No view selected for View A"; + } + + if (viewB == null) + { + return "Error: No view selected for View B"; + } + + return viewA.name + " to " + viewB.name; + } + + public override Color GetButtonColor() + { + return new Color32(216, 228, 170, 255); + } + + #endregion + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/StartSwipe.cs.meta b/Assets/Fungus/Scripts/Commands/StartSwipe.cs.meta new file mode 100644 index 0000000..177a4fe --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/StartSwipe.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 893af7b9a2a87449e9bb197699aa46b5 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Fungus/Scripts/Commands/Stop.cs b/Assets/Fungus/Scripts/Commands/Stop.cs new file mode 100644 index 0000000..02b6cb1 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Stop.cs @@ -0,0 +1,31 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; + +namespace Fungus +{ + /// + /// Stop executing the Block that contains this command. + /// + [CommandInfo("Flow", + "Stop", + "Stop executing the Block that contains this command.")] + [AddComponentMenu("")] + public class Stop : Command + { + #region Public members + + public override void OnEnter() + { + StopParentBlock(); + } + + public override Color GetButtonColor() + { + return new Color32(235, 191, 217, 255); + } + + #endregion + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/Stop.cs.meta b/Assets/Fungus/Scripts/Commands/Stop.cs.meta new file mode 100644 index 0000000..f9b8c8b --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Stop.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 5f1ca510a57aa47568a5e4ee558ff41f +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Fungus/Scripts/Commands/StopAmbiance.cs b/Assets/Fungus/Scripts/Commands/StopAmbiance.cs new file mode 100644 index 0000000..8aaa4a2 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/StopAmbiance.cs @@ -0,0 +1,35 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; + +namespace Fungus +{ + /// + /// Stops the currently playing game music. + /// + [CommandInfo("Audio", + "Stop Ambiance", + "Stops the currently playing game ambiance.")] + [AddComponentMenu("")] + public class StopAmbiance : Command + { + #region Public members + + public override void OnEnter() + { + var musicManager = FungusManager.Instance.MusicManager; + + musicManager.StopAmbiance(); + + Continue(); + } + + public override Color GetButtonColor() + { + return new Color32(242, 209, 176, 255); + } + + #endregion + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/StopAmbiance.cs.meta b/Assets/Fungus/Scripts/Commands/StopAmbiance.cs.meta new file mode 100644 index 0000000..b4e0d21 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/StopAmbiance.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 4bce3bd679be2c94196f3f6aaeb33f0b +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/StopBlock.cs b/Assets/Fungus/Scripts/Commands/StopBlock.cs new file mode 100644 index 0000000..7cb31a4 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/StopBlock.cs @@ -0,0 +1,72 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; + +namespace Fungus +{ + /// + /// Stops executing the named Block. + /// + [CommandInfo("Flow", + "Stop Block", + "Stops executing the named Block")] + public class StopBlock : Command, IBlockCaller + { + [Tooltip("Flowchart containing the Block. If none is specified, the parent Flowchart is used.")] + [SerializeField] protected Flowchart flowchart; + + [Tooltip("Name of the Block to stop")] + [SerializeField] protected StringData blockName = new StringData(""); + + #region Public members + + public override void OnEnter() + { + if (blockName.Value == "") + { + Continue(); + } + + if (flowchart == null) + { + flowchart = (Flowchart)GetFlowchart(); + } + + var block = flowchart.FindBlock(blockName.Value); + if (block == null || + !block.IsExecuting()) + { + Continue(); + } + + block.Stop(); + + Continue(); + } + + public override string GetSummary() + { + return blockName; + } + + public override Color GetButtonColor() + { + return new Color32(253, 253, 150, 255); + } + + public override bool HasReference(Variable variable) + { + return blockName.stringRef == variable || base.HasReference(variable); + } + + public bool MayCallBlock(Block block) + { + if(flowchart != null) + return block == flowchart.FindBlock(blockName.Value); + return false; + } + + #endregion + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/StopBlock.cs.meta b/Assets/Fungus/Scripts/Commands/StopBlock.cs.meta new file mode 100644 index 0000000..245c2b7 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/StopBlock.cs.meta @@ -0,0 +1,12 @@ +fileFormatVersion: 2 +guid: 0d52ce2dfbc0b4dc4aa04334fc76695e +timeCreated: 1460500129 +licenseType: Store +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/StopFlowchart.cs b/Assets/Fungus/Scripts/Commands/StopFlowchart.cs new file mode 100644 index 0000000..d28b71c --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/StopFlowchart.cs @@ -0,0 +1,64 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; +using System.Collections.Generic; + +namespace Fungus +{ + /// + /// Stops execution of all Blocks in a Flowchart. + /// + [CommandInfo("Flow", + "Stop Flowchart", + "Stops execution of all Blocks in a Flowchart")] + [AddComponentMenu("")] + public class StopFlowchart : Command + { + [Tooltip("Stop all executing Blocks in the Flowchart that contains this command")] + [SerializeField] protected bool stopParentFlowchart; + + [Tooltip("Stop all executing Blocks in a list of target Flowcharts")] + [SerializeField] protected List targetFlowcharts = new List(); + + #region Public members + + public override void OnEnter() + { + var flowchart = GetFlowchart(); + + for (int i = 0; i < targetFlowcharts.Count; i++) + { + var f = targetFlowcharts[i]; + f.StopAllBlocks(); + } + + //current block and command logic doesn't require it in this order but it makes sense to + // stop everything but yourself first + if (stopParentFlowchart) + { + flowchart.StopAllBlocks(); + } + + //you might not be stopping this flowchart so keep going + Continue(); + } + + public override bool IsReorderableArray(string propertyName) + { + if (propertyName == "targetFlowcharts") + { + return true; + } + + return false; + } + + public override Color GetButtonColor() + { + return new Color32(235, 191, 217, 255); + } + + #endregion + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/StopFlowchart.cs.meta b/Assets/Fungus/Scripts/Commands/StopFlowchart.cs.meta new file mode 100644 index 0000000..7d1c15f --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/StopFlowchart.cs.meta @@ -0,0 +1,12 @@ +fileFormatVersion: 2 +guid: ae67a23cb4aa74793b41258ae40bf321 +timeCreated: 1442408419 +licenseType: Store +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/StopMusic.cs b/Assets/Fungus/Scripts/Commands/StopMusic.cs new file mode 100644 index 0000000..fea8a83 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/StopMusic.cs @@ -0,0 +1,35 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; + +namespace Fungus +{ + /// + /// Stops the currently playing game music. + /// + [CommandInfo("Audio", + "Stop Music", + "Stops the currently playing game music.")] + [AddComponentMenu("")] + public class StopMusic : Command + { + #region Public members + + public override void OnEnter() + { + var musicManager = FungusManager.Instance.MusicManager; + + musicManager.StopMusic(); + + Continue(); + } + + public override Color GetButtonColor() + { + return new Color32(242, 209, 176, 255); + } + + #endregion + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/StopMusic.cs.meta b/Assets/Fungus/Scripts/Commands/StopMusic.cs.meta new file mode 100644 index 0000000..93822f1 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/StopMusic.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: b359b09a7ba2e4af981f07c07f8af85a +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Fungus/Scripts/Commands/StopSwipe.cs b/Assets/Fungus/Scripts/Commands/StopSwipe.cs new file mode 100644 index 0000000..0201244 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/StopSwipe.cs @@ -0,0 +1,35 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; + +namespace Fungus +{ + /// + /// Deactivates swipe panning mode. + /// + [CommandInfo("Camera", + "Stop Swipe", + "Deactivates swipe panning mode.")] + [AddComponentMenu("")] + public class StopSwipe : Command + { + #region Public members + + public override void OnEnter() + { + var cameraManager = FungusManager.Instance.CameraManager; + + cameraManager.StopSwipePan(); + + Continue(); + } + + public override Color GetButtonColor() + { + return new Color32(216, 228, 170, 255); + } + + #endregion + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/StopSwipe.cs.meta b/Assets/Fungus/Scripts/Commands/StopSwipe.cs.meta new file mode 100644 index 0000000..568fb09 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/StopSwipe.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 3e862766e64934bd1987a5ce891d04fb +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Fungus/Scripts/Commands/StopTween.cs b/Assets/Fungus/Scripts/Commands/StopTween.cs new file mode 100644 index 0000000..431c2fd --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/StopTween.cs @@ -0,0 +1,52 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; +using UnityEngine.Serialization; + +namespace Fungus +{ + /// + /// Stops an active iTween by name. + /// + [CommandInfo("iTween", + "Stop Tween", + "Stops an active iTween by name.")] + [AddComponentMenu("")] + [ExecuteInEditMode] + public class StopTween : Command + { + [Tooltip("Stop and destroy any Tweens in current scene with the supplied name")] + [SerializeField] protected StringData _tweenName; + + #region Public members + + public override void OnEnter() + { + iTween.StopByName(_tweenName.Value); + Continue(); + } + + public override bool HasReference(Variable variable) + { + return _tweenName.stringRef == variable || base.HasReference(variable); + } + + #endregion + + #region Backwards compatibility + + [HideInInspector] [FormerlySerializedAs("tweenName")] public string tweenNameOLD = ""; + + protected virtual void OnEnable() + { + if (tweenNameOLD != "") + { + _tweenName.Value = tweenNameOLD; + tweenNameOLD = ""; + } + } + + #endregion + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/StopTween.cs.meta b/Assets/Fungus/Scripts/Commands/StopTween.cs.meta new file mode 100644 index 0000000..f5b44f8 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/StopTween.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: e7026a0b1ea104ec0af471324ee3daea +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Fungus/Scripts/Commands/StopTweens.cs b/Assets/Fungus/Scripts/Commands/StopTweens.cs new file mode 100644 index 0000000..4615ddc --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/StopTweens.cs @@ -0,0 +1,27 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; + +namespace Fungus +{ + /// + /// Stop all active iTweens in the current scene. + /// + [CommandInfo("iTween", + "Stop Tweens", + "Stop all active iTweens in the current scene.")] + [AddComponentMenu("")] + public class StopTweens : Command + { + #region Public members + + public override void OnEnter() + { + iTween.Stop(); + Continue(); + } + + #endregion + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/StopTweens.cs.meta b/Assets/Fungus/Scripts/Commands/StopTweens.cs.meta new file mode 100644 index 0000000..b5321d7 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/StopTweens.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 46af98f4c7e084a5a96eb982e7271174 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Fungus/Scripts/Commands/ThrowException.cs b/Assets/Fungus/Scripts/Commands/ThrowException.cs new file mode 100644 index 0000000..6d78b8e --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/ThrowException.cs @@ -0,0 +1,59 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; + +namespace Fungus +{ + [System.Serializable] + public class FungusException : System.Exception + { + public FungusException() + { + } + + public FungusException(string message) : base(message) + { + } + + public FungusException(string message, System.Exception inner) : base(message, inner) + { + } + + protected FungusException( + System.Runtime.Serialization.SerializationInfo info, + System.Runtime.Serialization.StreamingContext context) : base(info, context) { } + } + + /// + /// Throw a Fungus.Exception + /// + [CommandInfo("Scripting", + "Throw Exception", + "Throw a fungus exception")] + [AddComponentMenu("")] + public class ThrowException : Command + { + [SerializeField] + protected StringData message; + + public override void OnEnter() + { + throw new FungusException(GetLocationIdentifier() + " " + message.Value); + +#pragma warning disable CS0162 // Unreachable code detected + Continue(); +#pragma warning restore CS0162 // Unreachable code detected + } + + public override string GetSummary() + { + return message.Value; + } + + public override bool HasReference(Variable variable) + { + return variable == message.stringRef || base.HasReference(variable); + } + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/ThrowException.cs.meta b/Assets/Fungus/Scripts/Commands/ThrowException.cs.meta new file mode 100644 index 0000000..4fc1e5a --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/ThrowException.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 8d1a861c2b31cf8488fd9d576d533474 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/ToString.cs b/Assets/Fungus/Scripts/Commands/ToString.cs new file mode 100644 index 0000000..60e6dfa --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/ToString.cs @@ -0,0 +1,63 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; + +namespace Fungus +{ + /// + /// Stores the result of a ToString on given variable in a string. + /// + [CommandInfo("Variable", + "To String", + "Stores the result of a ToString on given variable in a string.")] + [AddComponentMenu("")] + public class ToString : Command + { + [Tooltip("Target variable to get String of.")] + [VariableProperty()] + [SerializeField] protected Variable variable; + + [Tooltip("Variable to store the result of ToString")] + [VariableProperty(typeof(StringVariable))] + [SerializeField] protected StringVariable outValue; + + //[Tooltip("Optional formatting string given to ToString")] + //[SerializeField] protected StringData format; + + public override void OnEnter() + { + if (variable != null && outValue != null) + { + outValue.Value = variable.ToString(); + } + + Continue(); + } + + public override string GetSummary() + { + if (variable == null) + { + return "Error: Variable not selected"; + } + + if (outValue == null) + { + return "Error: outValue not set"; + } + + return outValue.Key + " = " + variable.Key + ".ToString"; + } + + public override bool HasReference(Variable variable) + { + return (variable == this.variable) || outValue == variable; + } + + public override Color GetButtonColor() + { + return new Color32(253, 253, 150, 255); + } + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/ToString.cs.meta b/Assets/Fungus/Scripts/Commands/ToString.cs.meta new file mode 100644 index 0000000..1668c94 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/ToString.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: e76deb01172e9c64c9f78361b06b85bd +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/TweenUI.cs b/Assets/Fungus/Scripts/Commands/TweenUI.cs new file mode 100644 index 0000000..401f523 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/TweenUI.cs @@ -0,0 +1,142 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; +using System.Collections.Generic; +using Fungus; + +namespace Fungus +{ + /// + /// Abstract base class for TweenUI commands. + /// + public abstract class TweenUI : Command + { + [Tooltip("List of objects to be affected by the tween")] + [SerializeField] protected List targetObjects = new List(); + + [Tooltip("Type of tween easing to apply")] + [SerializeField] protected LeanTweenType tweenType = LeanTweenType.easeOutQuad; + + [Tooltip("Wait until this command completes before continuing execution")] + [SerializeField] protected BooleanData waitUntilFinished = new BooleanData(true); + + [Tooltip("Time for the tween to complete")] + [SerializeField] protected FloatData duration = new FloatData(1f); + + protected virtual void ApplyTween() + { + for (int i = 0; i < targetObjects.Count; i++) + { + var targetObject = targetObjects[i]; + if (targetObject == null) + { + continue; + } + ApplyTween(targetObject); + } + + if (waitUntilFinished) + { + LeanTween.value(gameObject, 0f, 1f, duration).setOnComplete(OnComplete); + } + } + + protected abstract void ApplyTween(GameObject go); + + protected virtual void OnComplete() + { + Continue(); + } + + protected virtual string GetSummaryValue() + { + return ""; + } + + #region Public members + + public override void OnEnter() + { + if (targetObjects.Count == 0) + { + Continue(); + return; + } + + ApplyTween(); + + if (!waitUntilFinished) + { + Continue(); + } + } + + public override void OnCommandAdded(Block parentBlock) + { + // Add an empty slot by default. Saves an unnecessary user click. + if (targetObjects.Count == 0) + { + targetObjects.Add(null); + } + } + + public override string GetSummary() + { + if (targetObjects.Count == 0) + { + return "Error: No targetObjects selected"; + } + else if (targetObjects.Count == 1) + { + if (targetObjects[0] == null) + { + return "Error: No targetObjects selected"; + } + return targetObjects[0].name + " = " + GetSummaryValue(); + } + + string objectList = ""; + for (int i = 0; i < targetObjects.Count; i++) + { + var go = targetObjects[i]; + if (go == null) + { + continue; + } + if (objectList == "") + { + objectList += go.name; + } + else + { + objectList += ", " + go.name; + } + } + + return objectList + " = " + GetSummaryValue(); + } + + public override Color GetButtonColor() + { + return new Color32(180, 250, 250, 255); + } + + public override bool IsReorderableArray(string propertyName) + { + if (propertyName == "targetObjects") + { + return true; + } + + return false; + } + + public override bool HasReference(Variable variable) + { + return waitUntilFinished.booleanRef == variable || duration.floatRef == variable || base.HasReference(variable); + } + + #endregion + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/TweenUI.cs.meta b/Assets/Fungus/Scripts/Commands/TweenUI.cs.meta new file mode 100644 index 0000000..0feacff --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/TweenUI.cs.meta @@ -0,0 +1,12 @@ +fileFormatVersion: 2 +guid: c43a65504f4024abaa7581ddfa448f2d +timeCreated: 1444819884 +licenseType: Store +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/VariableCondition.cs b/Assets/Fungus/Scripts/Commands/VariableCondition.cs new file mode 100644 index 0000000..2c64b20 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/VariableCondition.cs @@ -0,0 +1,338 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using System.Collections.Generic; +using System.Text; +using UnityEngine; + +namespace Fungus +{ + /// + /// class for a single condition. A list of this is used for multiple conditions. + /// + [System.Serializable] + public class ConditionExpression + { + [SerializeField] protected CompareOperator compareOperator; + [SerializeField] protected AnyVariableAndDataPair anyVar; + + public virtual AnyVariableAndDataPair AnyVar { get { return anyVar; } } + public virtual CompareOperator CompareOperator { get { return compareOperator; } } + + public ConditionExpression() + { + } + + public ConditionExpression(CompareOperator op, AnyVariableAndDataPair variablePair) + { + compareOperator = op; + anyVar = variablePair; + } + } + + public abstract class VariableCondition : Condition, ISerializationCallbackReceiver + { + public enum AnyOrAll + { + AnyOf_OR,//Use as a chain of ORs + AllOf_AND,//Use as a chain of ANDs + } + + [Tooltip("Selecting AnyOf will result in true if at least one of the conditions is true. Selecting AllOF will result in true only when all the conditions are true.")] + [SerializeField] protected AnyOrAll anyOrAllConditions; + + [SerializeField] protected List conditions = new List(); + + /// + /// Called when the script is loaded or a value is changed in the + /// inspector (Called in the editor only). + /// + public override void OnValidate() + { + base.OnValidate(); + + if (conditions == null) + { + conditions = new List(); + } + + if (conditions.Count == 0) + { + conditions.Add(new ConditionExpression()); + } + } + + protected override bool EvaluateCondition() + { + if (conditions == null || conditions.Count == 0) + { + return false; + } + + bool resultAny = false, resultAll = true; + foreach (ConditionExpression condition in conditions) + { + bool curResult = false; + if (condition.AnyVar == null) + { + resultAll &= curResult; + resultAny |= curResult; + continue; + } + condition.AnyVar.Compare(condition.CompareOperator, ref curResult); + resultAll &= curResult; + resultAny |= curResult; + } + + if (anyOrAllConditions == AnyOrAll.AnyOf_OR) return resultAny; + + return resultAll; + } + + protected override bool HasNeededProperties() + { + if (conditions == null || conditions.Count == 0) + { + return false; + } + + foreach (ConditionExpression condition in conditions) + { + if (condition.AnyVar == null || condition.AnyVar.variable == null) + { + return false; + } + } + return true; + } + + public override string GetSummary() + { + if (!this.HasNeededProperties()) + { + return "Error: No variable selected"; + } + + string connector = ""; + if (anyOrAllConditions == AnyOrAll.AnyOf_OR) + { + connector = " OR "; + } + else + { + connector = " AND "; + } + + StringBuilder summary = new StringBuilder(""); + for (int i = 0; i < conditions.Count; i++) + { + summary.Append(conditions[i].AnyVar.variable.Key + " " + + VariableUtil.GetCompareOperatorDescription(conditions[i].CompareOperator) + " " + + conditions[i].AnyVar.GetDataDescription()); + + if (i < conditions.Count - 1) + { + summary.Append(connector); + } + } + return summary.ToString(); + } + + public override bool HasReference(Variable variable) + { + return anyVar.HasReference(variable); + } + + + + #region Editor caches +#if UNITY_EDITOR + protected override void RefreshVariableCache() + { + base.RefreshVariableCache(); + + if (conditions != null) + { + foreach (var item in conditions) + { + item.AnyVar.RefreshVariableCacheHelper(GetFlowchart(), ref referencedVariables); + } + } + } +#endif + #endregion Editor caches + + #region backwards compat + + [HideInInspector] + [SerializeField] protected CompareOperator compareOperator; + + [HideInInspector] + [SerializeField] protected AnyVariableAndDataPair anyVar; + + [Tooltip("Variable to use in expression")] + [VariableProperty(AllVariableTypes.VariableAny.Any)] + [SerializeField] protected Variable variable; + + [Tooltip("Boolean value to compare against")] + [SerializeField] protected BooleanData booleanData; + + [Tooltip("Integer value to compare against")] + [SerializeField] protected IntegerData integerData; + + [Tooltip("Float value to compare against")] + [SerializeField] protected FloatData floatData; + + [Tooltip("String value to compare against")] + [SerializeField] protected StringDataMulti stringData; + + [Tooltip("Animator value to compare against")] + [SerializeField] protected AnimatorData animatorData; + + [Tooltip("AudioSource value to compare against")] + [SerializeField] protected AudioSourceData audioSourceData; + + [Tooltip("Color value to compare against")] + [SerializeField] protected ColorData colorData; + + [Tooltip("GameObject value to compare against")] + [SerializeField] protected GameObjectData gameObjectData; + + [Tooltip("Material value to compare against")] + [SerializeField] protected MaterialData materialData; + + [Tooltip("Object value to compare against")] + [SerializeField] protected ObjectData objectData; + + [Tooltip("Rigidbody2D value to compare against")] + [SerializeField] protected Rigidbody2DData rigidbody2DData; + + [Tooltip("Sprite value to compare against")] + [SerializeField] protected SpriteData spriteData; + + [Tooltip("Texture value to compare against")] + [SerializeField] protected TextureData textureData; + + [Tooltip("Transform value to compare against")] + [SerializeField] protected TransformData transformData; + + [Tooltip("Vector2 value to compare against")] + [SerializeField] protected Vector2Data vector2Data; + + [Tooltip("Vector3 value to compare against")] + [SerializeField] protected Vector3Data vector3Data; + + void ISerializationCallbackReceiver.OnBeforeSerialize() + { + } + + void ISerializationCallbackReceiver.OnAfterDeserialize() + { + if (variable != null) + { + anyVar.variable = variable; + + if (variable.GetType() == typeof(BooleanVariable) && !booleanData.Equals(new BooleanData())) + { + anyVar.data.booleanData = booleanData; + booleanData = new BooleanData(); + } + else if (variable.GetType() == typeof(IntegerVariable) && !integerData.Equals(new IntegerData())) + { + anyVar.data.integerData = integerData; + integerData = new IntegerData(); + } + else if (variable.GetType() == typeof(FloatVariable) && !floatData.Equals(new FloatData())) + { + anyVar.data.floatData = floatData; + floatData = new FloatData(); + } + else if (variable.GetType() == typeof(StringVariable) && !stringData.Equals(new StringDataMulti())) + { + anyVar.data.stringData.stringRef = stringData.stringRef; + anyVar.data.stringData.stringVal = stringData.stringVal; + stringData = new StringDataMulti(); + } + else if (variable.GetType() == typeof(AnimatorVariable) && !animatorData.Equals(new AnimatorData())) + { + anyVar.data.animatorData = animatorData; + animatorData = new AnimatorData(); + } + else if (variable.GetType() == typeof(AudioSourceVariable) && !audioSourceData.Equals(new AudioSourceData())) + { + anyVar.data.audioSourceData = audioSourceData; + audioSourceData = new AudioSourceData(); + } + else if (variable.GetType() == typeof(ColorVariable) && !colorData.Equals(new ColorData())) + { + anyVar.data.colorData = colorData; + colorData = new ColorData(); + } + else if (variable.GetType() == typeof(GameObjectVariable) && !gameObjectData.Equals(new GameObjectData())) + { + anyVar.data.gameObjectData = gameObjectData; + gameObjectData = new GameObjectData(); + } + else if (variable.GetType() == typeof(MaterialVariable) && !materialData.Equals(new MaterialData())) + { + anyVar.data.materialData = materialData; + materialData = new MaterialData(); + } + else if (variable.GetType() == typeof(ObjectVariable) && !objectData.Equals(new ObjectData())) + { + anyVar.data.objectData = objectData; + objectData = new ObjectData(); + } + else if (variable.GetType() == typeof(Rigidbody2DVariable) && !rigidbody2DData.Equals(new Rigidbody2DData())) + { + anyVar.data.rigidbody2DData = rigidbody2DData; + rigidbody2DData = new Rigidbody2DData(); + } + else if (variable.GetType() == typeof(SpriteVariable) && !spriteData.Equals(new SpriteData())) + { + anyVar.data.spriteData = spriteData; + spriteData = new SpriteData(); + } + else if (variable.GetType() == typeof(TextureVariable) && !textureData.Equals(new TextureData())) + { + anyVar.data.textureData = textureData; + textureData = new TextureData(); + } + else if (variable.GetType() == typeof(TransformVariable) && !transformData.Equals(new TransformData())) + { + anyVar.data.transformData = transformData; + transformData = new TransformData(); + } + else if (variable.GetType() == typeof(Vector2Variable) && !vector2Data.Equals(new Vector2Data())) + { + anyVar.data.vector2Data = vector2Data; + vector2Data = new Vector2Data(); + } + else if (variable.GetType() == typeof(Vector3Variable) && !vector3Data.Equals(new Vector3Data())) + { + anyVar.data.vector3Data = vector3Data; + vector3Data = new Vector3Data(); + } + + //moved to new anyvar storage, clear legacy. + variable = null; + } + + // just checking for anyVar != null fails here. is any var being reintilaized somewhere? + + if (anyVar != null && anyVar.variable != null) + { + ConditionExpression c = new ConditionExpression(compareOperator, anyVar); + if (!conditions.Contains(c)) + { + conditions.Add(c); + } + + anyVar = null; + variable = null; + } + } + + #endregion backwards compat + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/VariableCondition.cs.meta b/Assets/Fungus/Scripts/Commands/VariableCondition.cs.meta new file mode 100644 index 0000000..5c90957 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/VariableCondition.cs.meta @@ -0,0 +1,12 @@ +fileFormatVersion: 2 +guid: b065f7dff8779442ab5841ccc6ae375b +timeCreated: 1493077787 +licenseType: Store +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/Vector3.meta b/Assets/Fungus/Scripts/Commands/Vector3.meta new file mode 100644 index 0000000..b3f8d41 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Vector3.meta @@ -0,0 +1,9 @@ +fileFormatVersion: 2 +guid: 9c57d4347eae5354b8bcf942c2b3468a +folderAsset: yes +timeCreated: 1503030603 +licenseType: Store +DefaultImporter: + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/Vector3/Vector3Arithmetic.cs b/Assets/Fungus/Scripts/Commands/Vector3/Vector3Arithmetic.cs new file mode 100644 index 0000000..748002b --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Vector3/Vector3Arithmetic.cs @@ -0,0 +1,85 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using System.Collections; +using System.Collections.Generic; +using UnityEngine; + +namespace Fungus +{ + /// + /// Vector3 add, sub, mul, div arithmetic + /// + [CommandInfo("Vector3", + "Arithmetic", + "Vector3 add, sub, mul, div arithmetic")] + [AddComponentMenu("")] + public class Vector3Arithmetic : Command + { + [SerializeField] + protected Vector3Data lhs, rhs, output; + + public enum Operation + { + Add, + Sub, + Mul, + Div + } + + [SerializeField] + protected Operation operation = Operation.Add; + + public override void OnEnter() + { + Vector3 tmp; + switch (operation) + { + case Operation.Add: + output.Value = lhs.Value + rhs.Value; + break; + case Operation.Sub: + output.Value = lhs.Value - rhs.Value; + break; + case Operation.Mul: + tmp = lhs.Value; + tmp.Scale(rhs.Value); + output.Value = tmp; + break; + case Operation.Div: + tmp = lhs.Value; + tmp.Scale(new Vector3(1.0f / rhs.Value.x, + 1.0f / rhs.Value.y, + 1.0f / rhs.Value.z)); + output.Value = tmp; + break; + default: + break; + } + Continue(); + } + + public override string GetSummary() + { + if (output.vector3Ref == null) + { + return "Error: no output set"; + } + + return operation.ToString() + ": stored in " + output.vector3Ref.Key; + } + + public override Color GetButtonColor() + { + return new Color32(235, 191, 217, 255); + } + + public override bool HasReference(Variable variable) + { + if (lhs.vector3Ref == variable || rhs.vector3Ref == variable || output.vector3Ref == variable) + return true; + + return false; + } + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/Vector3/Vector3Arithmetic.cs.meta b/Assets/Fungus/Scripts/Commands/Vector3/Vector3Arithmetic.cs.meta new file mode 100644 index 0000000..9abde71 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Vector3/Vector3Arithmetic.cs.meta @@ -0,0 +1,12 @@ +fileFormatVersion: 2 +guid: dfc8e8d5ce363ec43815496d321b4d55 +timeCreated: 1503313996 +licenseType: Store +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/Vector3/Vector3Fields.cs b/Assets/Fungus/Scripts/Commands/Vector3/Vector3Fields.cs new file mode 100644 index 0000000..31db3c9 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Vector3/Vector3Fields.cs @@ -0,0 +1,77 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using System.Collections; +using System.Collections.Generic; +using UnityEngine; + +namespace Fungus +{ + // + /// Get or Set the x,y,z fields of a vector3 via floatvars + /// + [CommandInfo("Vector3", + "Fields", + "Get or Set the x,y,z fields of a vector3 via floatvars")] + [AddComponentMenu("")] + public class Vector3Fields : Command + { + public enum GetSet + { + Get, + Set, + } + public GetSet getOrSet = GetSet.Get; + + [SerializeField] + protected Vector3Data vec3; + + [SerializeField] + protected FloatData x, y, z; + + public override void OnEnter() + { + switch (getOrSet) + { + case GetSet.Get: + + var v = vec3.Value; + + x.Value = v.x; + y.Value = v.y; + z.Value = v.z; + break; + case GetSet.Set: + vec3.Value = new Vector3(x.Value, y.Value, z.Value); + break; + default: + break; + } + + Continue(); + } + + public override string GetSummary() + { + if (vec3.vector3Ref == null) + { + return "Error: vec3 not set"; + } + + return getOrSet.ToString() + " (" + vec3.vector3Ref.Key + ")"; + } + + public override Color GetButtonColor() + { + return new Color32(235, 191, 217, 255); + } + + public override bool HasReference(Variable variable) + { + if (vec3.vector3Ref == variable || x.floatRef == variable || y.floatRef == variable || z.floatRef == variable) + return true; + + return false; + } + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/Vector3/Vector3Fields.cs.meta b/Assets/Fungus/Scripts/Commands/Vector3/Vector3Fields.cs.meta new file mode 100644 index 0000000..407e0c3 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Vector3/Vector3Fields.cs.meta @@ -0,0 +1,12 @@ +fileFormatVersion: 2 +guid: 96fb07b07bec30544a6c3c01df5345ee +timeCreated: 1504933522 +licenseType: Store +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/Vector3/Vector3Normalise.cs b/Assets/Fungus/Scripts/Commands/Vector3/Vector3Normalise.cs new file mode 100644 index 0000000..344c3cc --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Vector3/Vector3Normalise.cs @@ -0,0 +1,50 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using System.Collections; +using System.Collections.Generic; +using UnityEngine; + +namespace Fungus +{ + // + /// Normalise a vector3, output can be the same as the input + /// + [CommandInfo("Vector3", + "Normalise", + "Normalise a Vector3")] + [AddComponentMenu("")] + public class Vector3Normalise : Command + { + [SerializeField] + protected Vector3Data vec3In, vec3Out; + + public override void OnEnter() + { + vec3Out.Value = vec3In.Value.normalized; + + Continue(); + } + + public override string GetSummary() + { + if (vec3Out.vector3Ref == null) + return ""; + else + return vec3Out.vector3Ref.Key; + } + + public override Color GetButtonColor() + { + return new Color32(235, 191, 217, 255); + } + + public override bool HasReference(Variable variable) + { + if (vec3In.vector3Ref == variable || vec3Out.vector3Ref == variable) + return true; + + return false; + } + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/Vector3/Vector3Normalise.cs.meta b/Assets/Fungus/Scripts/Commands/Vector3/Vector3Normalise.cs.meta new file mode 100644 index 0000000..12fafbf --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Vector3/Vector3Normalise.cs.meta @@ -0,0 +1,12 @@ +fileFormatVersion: 2 +guid: b9c975313c082cd43a310bfd62ebb893 +timeCreated: 1504171804 +licenseType: Store +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/Vector3/Vector3ToVector2.cs b/Assets/Fungus/Scripts/Commands/Vector3/Vector3ToVector2.cs new file mode 100644 index 0000000..e29a769 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Vector3/Vector3ToVector2.cs @@ -0,0 +1,57 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using System.Collections; +using System.Collections.Generic; +using UnityEngine; + +namespace Fungus +{ + // + /// Convert fungus vec3 to vec2 + /// + [CommandInfo("Vector3", + "ToVector2", + "Convert Fungus Vector3 to Fungus Vector2")] + [AddComponentMenu("")] + public class Vector3ToVector2 : Command + { + [SerializeField] + protected Vector3Data vec3; + + + [SerializeField] + protected Vector2Data vec2; + + public override void OnEnter() + { + vec2.Value = vec3.Value; + + Continue(); + } + + public override string GetSummary() + { + if (vec3.vector3Ref != null && vec2.vector2Ref != null) + { + return "Converting " + vec3.vector3Ref.Key + " to " + vec2.vector2Ref.Key; + } + + return "Error: variables not set"; + } + + public override Color GetButtonColor() + { + return new Color32(235, 191, 217, 255); + } + + + public override bool HasReference(Variable variable) + { + if (variable == vec3.vector3Ref || variable == vec2.vector2Ref) + return true; + + return false; + } + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/Vector3/Vector3ToVector2.cs.meta b/Assets/Fungus/Scripts/Commands/Vector3/Vector3ToVector2.cs.meta new file mode 100644 index 0000000..c7a51a5 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Vector3/Vector3ToVector2.cs.meta @@ -0,0 +1,12 @@ +fileFormatVersion: 2 +guid: d3b374d347ec80647b7c01956f291a84 +timeCreated: 1504171432 +licenseType: Store +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/Wait.cs b/Assets/Fungus/Scripts/Commands/Wait.cs new file mode 100644 index 0000000..a1d1553 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Wait.cs @@ -0,0 +1,66 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; +using UnityEngine.Serialization; + +namespace Fungus +{ + /// + /// Waits for period of time before executing the next command in the block. + /// + [CommandInfo("Flow", + "Wait", + "Waits for period of time before executing the next command in the block.")] + [AddComponentMenu("")] + [ExecuteInEditMode] + public class Wait : Command + { + [Tooltip("Duration to wait for")] + [SerializeField] protected FloatData _duration = new FloatData(1); + + protected virtual void OnWaitComplete() + { + Continue(); + } + + #region Public members + + public override void OnEnter() + { + Invoke ("OnWaitComplete", _duration.Value); + } + + public override string GetSummary() + { + return _duration.Value.ToString() + " seconds"; + } + + public override Color GetButtonColor() + { + return new Color32(235, 191, 217, 255); + } + + public override bool HasReference(Variable variable) + { + return _duration.floatRef == variable || base.HasReference(variable); + } + + #endregion + + #region Backwards compatibility + + [HideInInspector] [FormerlySerializedAs("duration")] public float durationOLD; + + protected virtual void OnEnable() + { + if (durationOLD != default(float)) + { + _duration.Value = durationOLD; + durationOLD = default(float); + } + } + + #endregion + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/Wait.cs.meta b/Assets/Fungus/Scripts/Commands/Wait.cs.meta new file mode 100644 index 0000000..891ee20 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Wait.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 3315ad2ebb85443909a1203d56d9344e +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Fungus/Scripts/Commands/WaitFrames.cs b/Assets/Fungus/Scripts/Commands/WaitFrames.cs new file mode 100644 index 0000000..2a01089 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/WaitFrames.cs @@ -0,0 +1,59 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; +using UnityEngine.Serialization; +using System.Collections; + +namespace Fungus +{ + /// + /// Waits for a number of frames before executing the next command in the block. + /// + [CommandInfo("Flow", + "Wait Frames", + "Waits for a number of frames before executing the next command in the block.")] + [AddComponentMenu("")] + [ExecuteInEditMode] + public class WaitFrames : Command + { + [Tooltip("Number of frames to wait for")] + [SerializeField] protected IntegerData frameCount = new IntegerData(1); + + protected virtual IEnumerator WaitForFrames() + { + int count = frameCount.Value; + while (count > 0) + { + yield return new WaitForEndOfFrame(); + count--; + } + + Continue(); + } + + #region Public members + + public override void OnEnter() + { + StartCoroutine(WaitForFrames()); + } + + public override string GetSummary() + { + return frameCount.Value.ToString() + " frames"; + } + + public override Color GetButtonColor() + { + return new Color32(235, 191, 217, 255); + } + + public override bool HasReference(Variable variable) + { + return frameCount.integerRef == variable || base.HasReference(variable); + } + + #endregion + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/WaitFrames.cs.meta b/Assets/Fungus/Scripts/Commands/WaitFrames.cs.meta new file mode 100644 index 0000000..fdfd318 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/WaitFrames.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: de9232e9295ed476a8cfb707b5c242b9 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Fungus/Scripts/Commands/While.cs b/Assets/Fungus/Scripts/Commands/While.cs new file mode 100644 index 0000000..6f9c613 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/While.cs @@ -0,0 +1,23 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; + +namespace Fungus +{ + /// + /// Continuously loop through a block of commands while the condition is true. Use the Break command to force the loop to terminate immediately. + /// + [CommandInfo("Flow", + "While", + "Continuously loop through a block of commands while the condition is true. Use the Break command to force the loop to terminate immediately.")] + [AddComponentMenu("")] + public class While : If + { + #region Public members + + public override bool IsLooping { get { return true; } } + + #endregion + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/While.cs.meta b/Assets/Fungus/Scripts/Commands/While.cs.meta new file mode 100644 index 0000000..4ef44e4 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/While.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 663c8a7831a104d16ad7078a4dc2bd10 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Fungus/Scripts/Commands/Write.cs b/Assets/Fungus/Scripts/Commands/Write.cs new file mode 100644 index 0000000..afd483f --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Write.cs @@ -0,0 +1,165 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; + +namespace Fungus +{ + /// + /// Text coloring mode for Write command. + /// + public enum TextColor + { + /// Don't change the text color. + Default, + /// Set the text alpha to 1. + SetVisible, + /// Set the text alpha to a value. + SetAlpha, + /// Set the text color to a value. + SetColor + } + + /// + /// Writes content to a UI Text or Text Mesh object. + /// + [CommandInfo("UI", + "Write", + "Writes content to a UI Text or Text Mesh object.")] + [AddComponentMenu("")] + public class Write : Command, ILocalizable + { + [Tooltip("Text object to set text on. Text, Input Field and Text Mesh objects are supported.")] + [SerializeField] protected GameObject textObject; + + [Tooltip("String value to assign to the text object")] + [SerializeField] protected StringDataMulti text; + + [Tooltip("Notes about this story text for other authors, localization, etc.")] + [SerializeField] protected string description; + + [Tooltip("Clear existing text before writing new text")] + [SerializeField] protected bool clearText = true; + + [Tooltip("Wait until this command finishes before executing the next command")] + [SerializeField] protected bool waitUntilFinished = true; + + [Tooltip("Color mode to apply to the text.")] + [SerializeField] protected TextColor textColor = TextColor.Default; + + [Tooltip("Alpha to apply to the text.")] + [SerializeField] protected FloatData setAlpha = new FloatData(1f); + + [Tooltip("Color to apply to the text.")] + [SerializeField] protected ColorData setColor = new ColorData(Color.white); + + protected Writer GetWriter() + { + var writer = textObject.GetComponent(); + if (writer == null) + { + writer = textObject.AddComponent(); + } + + return writer; + } + + #region Public members + + public override void OnEnter() + { + if (textObject == null) + { + Continue(); + return; + } + + var writer = GetWriter(); + if (writer == null) + { + Continue(); + return; + } + + switch (textColor) + { + case TextColor.SetAlpha: + writer.SetTextAlpha(setAlpha); + break; + case TextColor.SetColor: + writer.SetTextColor(setColor); + break; + case TextColor.SetVisible: + writer.SetTextAlpha(1f); + break; + } + + var flowchart = GetFlowchart(); + string newText = flowchart.SubstituteVariables(text.Value); + + if (!waitUntilFinished) + { + StartCoroutine(writer.Write(newText, clearText, false, true, false, null, null)); + Continue(); + } + else + { + StartCoroutine(writer.Write(newText, clearText, false, true, false, null, + () => { Continue (); } + )); + } + } + + public override string GetSummary() + { + if (textObject != null) + { + return textObject.name + " : " + text.Value; + } + + return "Error: No text object selected"; + } + + public override Color GetButtonColor() + { + return new Color32(235, 191, 217, 255); + } + + public override void OnStopExecuting() + { + GetWriter().Stop(); + } + + #endregion + + #region ILocalizable implementation + + public virtual string GetStandardText() + { + return text; + } + + public virtual void SetStandardText(string standardText) + { + text.Value = standardText; + } + + public virtual string GetDescription() + { + return description; + } + + public virtual string GetStringId() + { + // String id for Write commands is WRITE.. + return "WRITE." + GetFlowchartLocalizationId() + "." + itemId; + } + + public override bool HasReference(Variable variable) + { + return text.stringRef == variable || setAlpha.floatRef == variable || setColor.colorRef == variable || base.HasReference(variable); + } + + #endregion + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/Write.cs.meta b/Assets/Fungus/Scripts/Commands/Write.cs.meta new file mode 100644 index 0000000..6d48592 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/Write.cs.meta @@ -0,0 +1,12 @@ +fileFormatVersion: 2 +guid: ad2261dbe44de43a980e6f7c77c88f7f +timeCreated: 1437682443 +licenseType: Store +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Commands/iTweenCommand.cs b/Assets/Fungus/Scripts/Commands/iTweenCommand.cs new file mode 100644 index 0000000..00b34af --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/iTweenCommand.cs @@ -0,0 +1,148 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; +using UnityEngine.Serialization; + +namespace Fungus +{ + /// + /// Axis to apply the tween on. + /// + public enum iTweenAxis + { + /// Don't specify an axis. + None, + /// Apply the tween on the X axis only. + X, + /// Apply the tween on the Y axis only. + Y, + /// Apply the tween on the Z axis only. + Z + } + + /// + /// Abstract base class for iTween commands. + /// + [ExecuteInEditMode] + public abstract class iTweenCommand : Command + { + [Tooltip("Target game object to apply the Tween to")] + [SerializeField] protected GameObjectData _targetObject; + + [Tooltip("An individual name useful for stopping iTweens by name")] + [SerializeField] protected StringData _tweenName; + + [Tooltip("The time in seconds the animation will take to complete")] + [SerializeField] protected FloatData _duration = new FloatData(1f); + + [Tooltip("The shape of the easing curve applied to the animation")] + [SerializeField] protected iTween.EaseType easeType = iTween.EaseType.easeInOutQuad; + + [Tooltip("The type of loop to apply once the animation has completed")] + [SerializeField] protected iTween.LoopType loopType = iTween.LoopType.none; + + [Tooltip("Stop any previously added iTweens on this object before adding this iTween")] + [SerializeField] protected bool stopPreviousTweens = false; + + [Tooltip("Wait until the tween has finished before executing the next command")] + [SerializeField] protected bool waitUntilFinished = true; + + protected virtual void OniTweenComplete(object param) + { + Command command = param as Command; + if (command != null && command.Equals(this)) + { + if (waitUntilFinished) + { + Continue(); + } + } + } + + #region Public members + + public override void OnEnter() + { + if (_targetObject.Value == null) + { + Continue(); + return; + } + + if (stopPreviousTweens) + { + // Force any existing iTweens on this target object to complete immediately + var tweens = _targetObject.Value.GetComponents(); + for (int i = 0; i < tweens.Length; i++) + { + var tween = tweens[i]; + tween.time = 0; + tween.SendMessage("Update"); + } + } + + DoTween(); + + if (!waitUntilFinished) + { + Continue(); + } + } + + public virtual void DoTween() + {} + + public override string GetSummary() + { + if (_targetObject.Value == null) + { + return "Error: No target object selected"; + } + + return _targetObject.Value.name + " over " + _duration.Value + " seconds"; + } + + public override Color GetButtonColor() + { + return new Color32(233, 163, 180, 255); + } + + public override bool HasReference(Variable variable) + { + return _targetObject.gameObjectRef == variable || _tweenName.stringRef == variable || + base.HasReference(variable); + } + + #endregion + + #region Backwards compatibility + + [HideInInspector] [FormerlySerializedAs("target")] [FormerlySerializedAs("targetObject")] public GameObject targetObjectOLD; + [HideInInspector] [FormerlySerializedAs("tweenName")] public string tweenNameOLD = ""; + [HideInInspector] [FormerlySerializedAs("duration")] public float durationOLD; + + protected virtual void OnEnable() + { + if (targetObjectOLD != null) + { + _targetObject.Value = targetObjectOLD; + targetObjectOLD = null; + } + + if (tweenNameOLD != "") + { + _tweenName.Value = tweenNameOLD; + tweenNameOLD = ""; + } + + if (durationOLD != default(float)) + { + _duration.Value = durationOLD; + durationOLD = default(float); + } + } + + #endregion + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Commands/iTweenCommand.cs.meta b/Assets/Fungus/Scripts/Commands/iTweenCommand.cs.meta new file mode 100644 index 0000000..941a734 --- /dev/null +++ b/Assets/Fungus/Scripts/Commands/iTweenCommand.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: f7826996074154feba94755721eaa9d4 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Fungus/Scripts/Components.meta b/Assets/Fungus/Scripts/Components.meta new file mode 100644 index 0000000..eb1d26b --- /dev/null +++ b/Assets/Fungus/Scripts/Components.meta @@ -0,0 +1,9 @@ +fileFormatVersion: 2 +guid: cd598e3b678e74763876d546c8b0fd9f +folderAsset: yes +timeCreated: 1473770363 +licenseType: Store +DefaultImporter: + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Components/Block.cs b/Assets/Fungus/Scripts/Components/Block.cs new file mode 100644 index 0000000..f727cf0 --- /dev/null +++ b/Assets/Fungus/Scripts/Components/Block.cs @@ -0,0 +1,484 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; +using UnityEngine.Serialization; +using System; +using System.Collections; +using System.Collections.Generic; + +namespace Fungus +{ + /// + /// Execution state of a Block. + /// + public enum ExecutionState + { + /// No command executing + Idle, + /// Executing a command + Executing, + } + + /// + /// A container for a sequence of Fungus comands. + /// + [ExecuteInEditMode] + [RequireComponent(typeof(Flowchart))] + [AddComponentMenu("")] + public class Block : Node + { + [SerializeField] protected int itemId = -1; // Invalid flowchart item id + + [FormerlySerializedAs("sequenceName")] + [Tooltip("The name of the block node as displayed in the Flowchart window")] + [SerializeField] protected string blockName = "New Block"; + + [TextArea(2, 5)] + [Tooltip("Description text to display under the block node")] + [SerializeField] protected string description = ""; + + [Tooltip("An optional Event Handler which can execute the block when an event occurs")] + [SerializeField] protected EventHandler eventHandler; + + [SerializeField] protected List commandList = new List(); + + protected ExecutionState executionState; + + protected Command activeCommand; + + protected Action lastOnCompleteAction; + + /// + // Index of last command executed before the current one. + // -1 indicates no previous command. + /// + protected int previousActiveCommandIndex = -1; + + public int PreviousActiveCommandIndex { get { return previousActiveCommandIndex; } } + + protected int jumpToCommandIndex = -1; + + protected int executionCount; + + protected bool executionInfoSet = false; + + /// + /// If set, flowchart will not auto select when it is next executed, used by eventhandlers. + /// Only effects the editor. + /// + public bool SuppressNextAutoSelection { get; set; } + + [SerializeField] bool suppressAllAutoSelections = false; + + + protected virtual void Awake() + { + SetExecutionInfo(); + } + + /// + /// Populate the command metadata used to control execution. + /// + protected virtual void SetExecutionInfo() + { + // Give each child command a reference back to its parent block + // and tell each command its index in the list. + int index = 0; + for (int i = 0; i < commandList.Count; i++) + { + var command = commandList[i]; + if (command == null) + { + continue; + } + command.ParentBlock = this; + command.CommandIndex = index++; + } + + // Ensure all commands are at their correct indent level + // This should have already happened in the editor, but may be necessary + // if commands are added to the Block at runtime. + UpdateIndentLevels(); + + executionInfoSet = true; + } + +#if UNITY_EDITOR + // The user can modify the command list order while playing in the editor, + // so we keep the command indices updated every frame. There's no need to + // do this in player builds so we compile this bit out for those builds. + protected virtual void Update() + { + int index = 0; + for (int i = 0; i < commandList.Count; i++) + { + var command = commandList[i]; + if (command == null)// Null entry will be deleted automatically later + + { + continue; + } + command.CommandIndex = index++; + } + } + +#endif + //editor only state for speeding up flowchart window drawing + public bool IsSelected { get; set; } //local cache of selectedness + public enum FilteredState { Full, Partial, None} + public FilteredState FilterState { get; set; } //local cache of filteredness + public bool IsControlSelected { get; set; } //local cache of being part of the control exclusion group + + #region Public members + + /// + /// The execution state of the Block. + /// + public virtual ExecutionState State { get { return executionState; } } + + /// + /// Unique identifier for the Block. + /// + public virtual int ItemId { get { return itemId; } set { itemId = value; } } + + /// + /// The name of the block node as displayed in the Flowchart window. + /// + public virtual string BlockName { get { return blockName; } set { blockName = value; } } + + /// + /// Description text to display under the block node + /// + public virtual string Description { get { return description; } } + + /// + /// An optional Event Handler which can execute the block when an event occurs. + /// Note: Using the concrete class instead of the interface here because of weird editor behaviour. + /// + public virtual EventHandler _EventHandler { get { return eventHandler; } set { eventHandler = value; } } + + /// + /// The currently executing command. + /// + public virtual Command ActiveCommand { get { return activeCommand; } } + + /// + /// Timer for fading Block execution icon. + /// + public virtual float ExecutingIconTimer { get; set; } + + /// + /// The list of commands in the sequence. + /// + public virtual List CommandList { get { return commandList; } } + + /// + /// Controls the next command to execute in the block execution coroutine. + /// + public virtual int JumpToCommandIndex { set { jumpToCommandIndex = value; } } + + /// + /// Returns the parent Flowchart for this Block. + /// + public virtual Flowchart GetFlowchart() + { + return GetComponent(); + } + + /// + /// Returns true if the Block is executing a command. + /// + public virtual bool IsExecuting() + { + return (executionState == ExecutionState.Executing); + } + + /// + /// Returns the number of times this Block has executed. + /// + public virtual int GetExecutionCount() + { + return executionCount; + } + + /// + /// Start a coroutine which executes all commands in the Block. Only one running instance of each Block is permitted. + /// + public virtual void StartExecution() + { + StartCoroutine(Execute()); + } + + /// + /// A coroutine method that executes all commands in the Block. Only one running instance of each Block is permitted. + /// + /// Index of command to start execution at + /// Delegate function to call when execution completes + public virtual IEnumerator Execute(int commandIndex = 0, Action onComplete = null) + { + if (executionState != ExecutionState.Idle) + { + Debug.LogWarning(BlockName + " cannot be executed, it is already running."); + yield break; + } + + lastOnCompleteAction = onComplete; + + if (!executionInfoSet) + { + SetExecutionInfo(); + } + + executionCount++; + var executionCountAtStart = executionCount; + + var flowchart = GetFlowchart(); + executionState = ExecutionState.Executing; + BlockSignals.DoBlockStart(this); + + bool suppressSelectionChanges = false; + + #if UNITY_EDITOR + // Select the executing block & the first command + if (suppressAllAutoSelections || SuppressNextAutoSelection) + { + SuppressNextAutoSelection = false; + suppressSelectionChanges = true; + } + else + { + flowchart.SelectedBlock = this; + if (commandList.Count > 0) + { + flowchart.ClearSelectedCommands(); + flowchart.AddSelectedCommand(commandList[0]); + } + } + #endif + + jumpToCommandIndex = commandIndex; + + int i = 0; + while (true) + { + // Executing commands specify the next command to skip to by setting jumpToCommandIndex using Command.Continue() + if (jumpToCommandIndex > -1) + { + i = jumpToCommandIndex; + jumpToCommandIndex = -1; + } + + // Skip disabled commands, comments and labels + while (i < commandList.Count && + (!commandList[i].enabled || + commandList[i].GetType() == typeof(Comment) || + commandList[i].GetType() == typeof(Label))) + { + i = commandList[i].CommandIndex + 1; + } + + if (i >= commandList.Count) + { + break; + } + + // The previous active command is needed for if / else / else if commands + if (activeCommand == null) + { + previousActiveCommandIndex = -1; + } + else + { + previousActiveCommandIndex = activeCommand.CommandIndex; + } + + var command = commandList[i]; + activeCommand = command; + + if (flowchart.IsActive() && !suppressSelectionChanges) + { + // Auto select a command in some situations + if ((flowchart.SelectedCommands.Count == 0 && i == 0) || + (flowchart.SelectedCommands.Count == 1 && flowchart.SelectedCommands[0].CommandIndex == previousActiveCommandIndex)) + { + flowchart.ClearSelectedCommands(); + flowchart.AddSelectedCommand(commandList[i]); + } + } + + command.IsExecuting = true; + // This icon timer is managed by the FlowchartWindow class, but we also need to + // set it here in case a command starts and finishes execution before the next window update. + command.ExecutingIconTimer = Time.realtimeSinceStartup + FungusConstants.ExecutingIconFadeTime; + BlockSignals.DoCommandExecute(this, command, i, commandList.Count); + command.Execute(); + + // Wait until the executing command sets another command to jump to via Command.Continue() + while (jumpToCommandIndex == -1) + { + yield return null; + } + + #if UNITY_EDITOR + if (flowchart.StepPause > 0f) + { + yield return new WaitForSeconds(flowchart.StepPause); + } + #endif + + command.IsExecuting = false; + } + + if(State == ExecutionState.Executing && + //ensure we aren't dangling from a previous stopage and stopping a future run + executionCountAtStart == executionCount) + { + ReturnToIdle(); + } + } + + private void ReturnToIdle() + { + executionState = ExecutionState.Idle; + activeCommand = null; + BlockSignals.DoBlockEnd(this); + + if (lastOnCompleteAction != null) + { + lastOnCompleteAction(); + } + lastOnCompleteAction = null; + } + + /// + /// Stop executing commands in this Block. + /// + public virtual void Stop() + { + // Tell the executing command to stop immediately + if (activeCommand != null) + { + activeCommand.IsExecuting = false; + activeCommand.OnStopExecuting(); + } + + // This will cause the execution loop to break on the next iteration + jumpToCommandIndex = int.MaxValue; + + //force idle here so other commands that rely on block not executing are informed this frame rather than next + ReturnToIdle(); + } + + /// + /// Returns a list of all Blocks connected to this one. + /// + public virtual List GetConnectedBlocks() + { + var connectedBlocks = new List(); + GetConnectedBlocks(ref connectedBlocks); + return connectedBlocks; + } + + public virtual void GetConnectedBlocks(ref List connectedBlocks) + { + for (int i = 0; i < commandList.Count; i++) + { + var command = commandList[i]; + if (command != null) + { + command.GetConnectedBlocks(ref connectedBlocks); + } + } + } + + /// + /// Returns the type of the previously executing command. + /// + /// The previous active command type. + public virtual System.Type GetPreviousActiveCommandType() + { + if (previousActiveCommandIndex >= 0 && + previousActiveCommandIndex < commandList.Count) + { + return commandList[previousActiveCommandIndex].GetType(); + } + + return null; + } + + public virtual int GetPreviousActiveCommandIndent() + { + if (previousActiveCommandIndex >= 0 && + previousActiveCommandIndex < commandList.Count) + { + return commandList[previousActiveCommandIndex].IndentLevel; + } + + return -1; + } + + public virtual Command GetPreviousActiveCommand() + { + if (previousActiveCommandIndex >= 0 && + previousActiveCommandIndex < commandList.Count) + { + return commandList[previousActiveCommandIndex]; + } + + return null; + } + + /// + /// Recalculate the indent levels for all commands in the list. + /// + public virtual void UpdateIndentLevels() + { + int indentLevel = 0; + for (int i = 0; i < commandList.Count; i++) + { + var command = commandList[i]; + if (command == null) + { + continue; + } + if (command.CloseBlock()) + { + indentLevel--; + } + // Negative indent level is not permitted + indentLevel = Math.Max(indentLevel, 0); + command.IndentLevel = indentLevel; + if (command.OpenBlock()) + { + indentLevel++; + } + } + } + + /// + /// Returns the index of the Label command with matching key, or -1 if not found. + /// + public virtual int GetLabelIndex(string labelKey) + { + if (labelKey.Length == 0) + { + return -1; + } + + for (int i = 0; i < commandList.Count; i++) + { + var command = commandList[i]; + var labelCommand = command as Label; + if (labelCommand != null && String.Compare(labelCommand.Key, labelKey, true) == 0) + { + return i; + } + } + + return -1; + } + + #endregion + } +} diff --git a/Assets/Fungus/Scripts/Components/Block.cs.meta b/Assets/Fungus/Scripts/Components/Block.cs.meta new file mode 100644 index 0000000..96e1216 --- /dev/null +++ b/Assets/Fungus/Scripts/Components/Block.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 3d3d73aef2cfc4f51abf34ac00241f60 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Fungus/Scripts/Components/CameraManager.cs b/Assets/Fungus/Scripts/Components/CameraManager.cs new file mode 100644 index 0000000..30467e6 --- /dev/null +++ b/Assets/Fungus/Scripts/Components/CameraManager.cs @@ -0,0 +1,426 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; +using System; +using System.Collections; +using System.Collections.Generic; +using Fungus; + +namespace Fungus +{ + /// + /// Manager for main camera. Supports several types of camera transition including snap, pan & fade. + /// + public class CameraManager : MonoBehaviour + { + [Tooltip("Full screen texture used for screen fade effect.")] + [SerializeField] protected Texture2D screenFadeTexture; + + [Tooltip("Icon to display when swipe pan mode is active.")] + [SerializeField] protected Texture2D swipePanIcon; + + [Tooltip("Position of continue and swipe icons in normalized screen space coords. (0,0) = top left, (1,1) = bottom right")] + [SerializeField] protected Vector2 swipeIconPosition = new Vector2(1,0); + + [Tooltip("Set the camera z coordinate to a fixed value every frame.")] + [SerializeField] protected bool setCameraZ = true; + + [Tooltip("Fixed Z coordinate of main camera.")] + [SerializeField] protected float cameraZ = -10f; + + [Tooltip("Camera to use when in swipe mode")] + [SerializeField] protected Camera swipeCamera; + + protected float fadeAlpha = 0f; + + // Swipe panning control + protected bool swipePanActive; + + protected float swipeSpeedMultiplier = 1f; + protected View swipePanViewA; + protected View swipePanViewB; + protected Vector3 previousMousePos; + + //Coroutine handles for panning and fading commands + protected LTDescr fadeTween, sizeTween, camPosTween, camRotTween; + + protected class CameraView + { + public Vector3 cameraPos; + public Quaternion cameraRot; + public float cameraSize; + }; + + protected Dictionary storedViews = new Dictionary(); + + protected virtual void OnGUI() + { + if (swipePanActive) + { + // Draw the swipe panning icon + if (swipePanIcon) + { + float x = Screen.width * swipeIconPosition.x; + float y = Screen.height * swipeIconPosition.y; + float width = swipePanIcon.width; + float height = swipePanIcon.height; + + x = Mathf.Max(x, 0); + y = Mathf.Max(y, 0); + x = Mathf.Min(x, Screen.width - width); + y = Mathf.Min(y, Screen.height - height); + + Rect rect = new Rect(x, y, width, height); + GUI.DrawTexture(rect, swipePanIcon); + } + } + + // Draw full screen fade texture + if (fadeAlpha > 0f && + screenFadeTexture != null) + { + // 1 = scene fully visible + // 0 = scene fully obscured + GUI.color = new Color(1,1,1, fadeAlpha); + GUI.depth = -1000; + GUI.DrawTexture(new Rect(0, 0, Screen.width, Screen.height), screenFadeTexture); + } + } + + protected virtual void SetCameraZ(Camera camera) + { + if (!setCameraZ) + { + return; + } + + if (camera == null) + { + Debug.LogWarning("Camera is null"); + return; + } + + camera.transform.position = new Vector3(camera.transform.position.x, camera.transform.position.y, cameraZ); + } + + protected virtual void Update() + { + if (!swipePanActive) + { + return; + } + + if (swipeCamera == null) + { + Debug.LogWarning("Camera is null"); + return; + } + + Vector3 delta = Vector3.zero; + + if (Input.touchCount > 0) + { + if (Input.GetTouch(0).phase == TouchPhase.Moved) + { + delta = Input.GetTouch(0).deltaPosition; + } + } + + if (Input.GetMouseButtonDown(0)) + { + previousMousePos = Input.mousePosition; + } + else if (Input.GetMouseButton(0)) + { + delta = Input.mousePosition - previousMousePos; + previousMousePos = Input.mousePosition; + } + + Vector3 cameraDelta = swipeCamera.ScreenToViewportPoint(delta); + cameraDelta.x *= -2f * swipeSpeedMultiplier; + cameraDelta.y *= -2f * swipeSpeedMultiplier; + cameraDelta.z = 0f; + + Vector3 cameraPos = swipeCamera.transform.position; + + cameraPos += cameraDelta; + + swipeCamera.transform.position = CalcCameraPosition(cameraPos, swipePanViewA, swipePanViewB); + swipeCamera.orthographicSize = CalcCameraSize(cameraPos, swipePanViewA, swipePanViewB); + } + + // Clamp camera position to region defined by the two views + protected virtual Vector3 CalcCameraPosition(Vector3 pos, View viewA, View viewB) + { + Vector3 safePos = pos; + + // Clamp camera position to region defined by the two views + safePos.x = Mathf.Max(safePos.x, Mathf.Min(viewA.transform.position.x, viewB.transform.position.x)); + safePos.x = Mathf.Min(safePos.x, Mathf.Max(viewA.transform.position.x, viewB.transform.position.x)); + safePos.y = Mathf.Max(safePos.y, Mathf.Min(viewA.transform.position.y, viewB.transform.position.y)); + safePos.y = Mathf.Min(safePos.y, Mathf.Max(viewA.transform.position.y, viewB.transform.position.y)); + + return safePos; + } + + // Smoothly interpolate camera orthographic size based on relative position to two views + protected virtual float CalcCameraSize(Vector3 pos, View viewA, View viewB) + { + // Get ray and point in same space + Vector3 toViewB = viewB.transform.position - viewA.transform.position; + Vector3 localPos = pos - viewA.transform.position; + + // Normalize + float distance = toViewB.magnitude; + toViewB /= distance; + localPos /= distance; + + // Project point onto ray + float t = Vector3.Dot(toViewB, localPos); + t = Mathf.Clamp01(t); // Not really necessary but no harm + + float cameraSize = Mathf.Lerp(viewA.ViewSize, viewB.ViewSize, t); + + return cameraSize; + } + + #region Public members + + /// + /// Creates a flat colored texture. + /// + public static Texture2D CreateColorTexture(Color color, int width, int height) + { + Color[] pixels = new Color[width * height]; + for (int i = 0; i < pixels.Length; i++) + { + pixels[i] = color; + } + Texture2D texture = new Texture2D(width, height, TextureFormat.ARGB32, false); + texture.SetPixels(pixels); + texture.Apply(); + + return texture; + } + + /// + /// Full screen texture used for screen fade effect. + /// + /// The screen fade texture. + public Texture2D ScreenFadeTexture { set { screenFadeTexture = value; } } + + /// + /// Perform a fullscreen fade over a duration. + /// + public virtual void Fade(float targetAlpha, float fadeDuration, Action fadeAction, LeanTweenType leanTweenType = LeanTweenType.easeInOutQuad) + { + StopFadeTween(); + + if (Mathf.Approximately(fadeDuration, 0)) + { + fadeAlpha = targetAlpha; + if (fadeAction != null) fadeAction(); + } + else + { + fadeTween = LeanTween.value(fadeAlpha, targetAlpha, fadeDuration) + .setEase(leanTweenType) + .setOnUpdate((x) => fadeAlpha = x) + .setOnComplete(() => + { + fadeAlpha = targetAlpha; + if (fadeAction != null) fadeAction(); + fadeTween = null; + }); + } + } + + /// + /// Fade out, move camera to view and then fade back in. + /// + public virtual void FadeToView(Camera camera, View view, float fadeDuration, bool fadeOut, Action fadeAction, + LeanTweenType fadeType = LeanTweenType.easeInOutQuad, LeanTweenType sizeTweenType = LeanTweenType.easeInOutQuad, + LeanTweenType posTweenType = LeanTweenType.easeInOutQuad, LeanTweenType rotTweenType = LeanTweenType.easeInOutQuad) + { + swipePanActive = false; + fadeAlpha = 0f; + + float outDuration; + float inDuration; + + if (fadeOut) + { + outDuration = fadeDuration / 2f; + inDuration = fadeDuration / 2f; + } + else + { + outDuration = 0; + inDuration = fadeDuration; + } + + // Fade out + Fade(1f, outDuration, delegate { + + // Snap to new view + PanToPosition(camera, view.transform.position, view.transform.rotation, view.ViewSize, 0f, null, sizeTweenType, posTweenType, rotTweenType); + + // Fade in + Fade(0f, inDuration, delegate { + if (fadeAction != null) + { + fadeAction(); + } + }, fadeType); + }, fadeType); + } + + /// + /// Stop all camera tweening. + /// + public virtual void Stop() + { + StopFadeTween(); + StopPosTweens(); + } + + protected void StopFadeTween() + { + if (fadeTween != null) + { + LeanTween.cancel(fadeTween.id, true); + fadeTween = null; + } + } + + protected void StopPosTweens() + { + if (sizeTween != null) + { + LeanTween.cancel(sizeTween.id, true); + sizeTween = null; + } + if (camPosTween != null) + { + LeanTween.cancel(camPosTween.id, true); + camPosTween = null; + } + if (camRotTween != null) + { + LeanTween.cancel(camRotTween.id, true); + camRotTween = null; + } + } + + /// + /// Moves camera from current position to a target position over a period of time. + /// + public virtual void PanToPosition(Camera camera, Vector3 targetPosition, Quaternion targetRotation, float targetSize, float duration, Action arriveAction, + LeanTweenType sizeTweenType = LeanTweenType.easeInOutQuad, LeanTweenType posTweenType = LeanTweenType.easeInOutQuad, LeanTweenType rotTweenType = LeanTweenType.easeInOutQuad) + { + if (camera == null) + { + Debug.LogWarning("Camera is null"); + return; + } + + if(setCameraZ) + { + targetPosition.z = camera.transform.position.z; + } + + // Stop any pan that is currently active + StopPosTweens(); + swipePanActive = false; + + if (Mathf.Approximately(duration, 0f)) + { + // Move immediately + camera.orthographicSize = targetSize; + camera.transform.position = targetPosition; + camera.transform.rotation = targetRotation; + + SetCameraZ(camera); + + if (arriveAction != null) + { + arriveAction(); + } + } + else + { + sizeTween = LeanTween.value(camera.orthographicSize, targetSize, duration) + .setEase(sizeTweenType) + .setOnUpdate(x => camera.orthographicSize = x) + .setOnComplete(() => + { + camera.orthographicSize = targetSize; + if (arriveAction != null) arriveAction(); + sizeTween = null; + }); + + camPosTween = LeanTween.move(camera.gameObject, targetPosition, duration) + .setEase(posTweenType) + .setOnComplete(() => + { + camera.transform.position = targetPosition; + camPosTween = null; + }); + + camRotTween = LeanTween.rotate(camera.gameObject, targetRotation.eulerAngles, duration) + .setEase(rotTweenType) + .setOnComplete(() => + { + camera.transform.rotation = targetRotation; + camRotTween = null; + }); + } + } + + /// + /// Activates swipe panning mode. The player can pan the camera within the area between viewA & viewB. + /// + public virtual void StartSwipePan(Camera camera, View viewA, View viewB, float duration, float speedMultiplier, Action arriveAction) + { + if (camera == null) + { + Debug.LogWarning("Camera is null"); + return; + } + + swipePanViewA = viewA; + swipePanViewB = viewB; + swipeSpeedMultiplier = speedMultiplier; + + Vector3 cameraPos = camera.transform.position; + + Vector3 targetPosition = CalcCameraPosition(cameraPos, swipePanViewA, swipePanViewB); + float targetSize = CalcCameraSize(cameraPos, swipePanViewA, swipePanViewB); + + PanToPosition(camera, targetPosition, Quaternion.identity, targetSize, duration, delegate { + + swipePanActive = true; + swipeCamera = camera; + + if (arriveAction != null) + { + arriveAction(); + } + }); + } + + /// + /// Deactivates swipe panning mode. + /// + public virtual void StopSwipePan() + { + swipePanActive = false; + swipePanViewA = null; + swipePanViewB = null; + swipeCamera = null; + } + + #endregion + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Components/CameraManager.cs.meta b/Assets/Fungus/Scripts/Components/CameraManager.cs.meta new file mode 100644 index 0000000..9c68508 --- /dev/null +++ b/Assets/Fungus/Scripts/Components/CameraManager.cs.meta @@ -0,0 +1,10 @@ +fileFormatVersion: 2 +guid: efb7bb24722d4469bbd789bd2e01db19 +MonoImporter: + serializedVersion: 2 + defaultReferences: + - screenFadeTexture: {fileID: 2800000, guid: f6c7b1f3a78a24703b70c746d8b9c768, type: 3} + - swipePanIcon: {fileID: 2800000, guid: 41bc737f4dc1b40db872aca00bcd7d4b, type: 3} + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Fungus/Scripts/Components/Character.cs b/Assets/Fungus/Scripts/Components/Character.cs new file mode 100644 index 0000000..5d45ce3 --- /dev/null +++ b/Assets/Fungus/Scripts/Components/Character.cs @@ -0,0 +1,203 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; +using UnityEngine.Serialization; +using System.Collections.Generic; +using System.Globalization; + +namespace Fungus +{ + /// + /// A Character that can be used in dialogue via the Say, Conversation and Portrait commands. + /// + [ExecuteInEditMode] + public class Character : MonoBehaviour, ILocalizable, IComparer + { + [Tooltip("Character name as displayed in Say Dialog.")] + [SerializeField] protected string nameText; // We need a separate name as the object name is used for character variations (e.g. "Smurf Happy", "Smurf Sad") + + [Tooltip("Color to display the character name in Say Dialog.")] + [SerializeField] protected Color nameColor = Color.white; + + [Tooltip("Sound effect to play when this character is speaking.")] + [SerializeField] protected AudioClip soundEffect; + + [Tooltip("List of portrait images that can be displayed for this character.")] + [SerializeField] protected List portraits; + + [Tooltip("Direction that portrait sprites face.")] + [SerializeField] protected FacingDirection portraitsFace; + + [Tooltip("Sets the active Say dialog with a reference to a Say Dialog object in the scene. This Say Dialog will be used whenever the character speaks.")] + [SerializeField] protected SayDialog setSayDialog; + + [FormerlySerializedAs("notes")] + [TextArea(5,10)] + [SerializeField] protected string description; + + protected PortraitState portaitState = new PortraitState(); + + protected static List activeCharacters = new List(); + + protected virtual void OnEnable() + { + if (!activeCharacters.Contains(this)) + { + activeCharacters.Add(this); + activeCharacters.Sort(this); + } + } + + protected virtual void OnDisable() + { + activeCharacters.Remove(this); + } + + #region Public members + + /// + /// Gets the list of active characters. + /// + public static List ActiveCharacters { get { return activeCharacters; } } + + /// + /// Character name as displayed in Say Dialog. + /// + public virtual string NameText { get { return nameText; } } + + /// + /// Color to display the character name in Say Dialog. + /// + public virtual Color NameColor { get { return nameColor; } } + + /// + /// Sound effect to play when this character is speaking. + /// + /// The sound effect. + public virtual AudioClip SoundEffect { get { return soundEffect; } } + + /// + /// List of portrait images that can be displayed for this character. + /// + public virtual List Portraits { get { return portraits; } } + + /// + /// Direction that portrait sprites face. + /// + public virtual FacingDirection PortraitsFace { get { return portraitsFace; } } + + /// + /// Currently display profile sprite for this character. + /// + /// The profile sprite. + public virtual Sprite ProfileSprite { get; set; } + + /// + /// Current display state of this character's portrait. + /// + /// The state. + public virtual PortraitState State { get { return portaitState; } } + + /// + /// Sets the active Say dialog with a reference to a Say Dialog object in the scene. This Say Dialog will be used whenever the character speaks. + /// + public virtual SayDialog SetSayDialog { get { return setSayDialog; } } + + /// + /// Returns the name of the game object. + /// + public string GetObjectName() { return gameObject.name; } + + /// + /// Returns true if the character name starts with the specified string. Case insensitive. + /// + public virtual bool NameStartsWith(string matchString) + { +#if NETFX_CORE + return name.StartsWith(matchString, StringComparison.CurrentCultureIgnoreCase) + || nameText.StartsWith(matchString, StringComparison.CurrentCultureIgnoreCase); +#else + return name.StartsWith(matchString, true, System.Globalization.CultureInfo.CurrentCulture) + || nameText.StartsWith(matchString, true, System.Globalization.CultureInfo.CurrentCulture); +#endif + } + + /// + /// Returns true if the character name is a complete match to the specified string. Case insensitive. + /// + public virtual bool NameMatch(string matchString) + { + return string.Compare(name, matchString, true, CultureInfo.CurrentCulture) == 0 + || string.Compare(nameText, matchString, true, CultureInfo.CurrentCulture) == 0; + } + + public int Compare(Character x, Character y) + { + if (x == y) + return 0; + if (y == null) + return 1; + if (x == null) + return -1; + + return x.name.CompareTo(y.name); + } + + /// + /// Looks for a portrait by name on a character + /// If none is found, give a warning and return a blank sprite + /// + public virtual Sprite GetPortrait(string portraitString) + { + if (string.IsNullOrEmpty(portraitString)) + { + return null; + } + + for (int i = 0; i < portraits.Count; i++) + { + if (portraits[i] != null && string.Compare(portraits[i].name, portraitString, true) == 0) + { + return portraits[i]; + } + } + return null; + } + + #endregion + + #region ILocalizable implementation + + public virtual string GetStandardText() + { + return nameText; + } + + public virtual void SetStandardText(string standardText) + { + nameText = standardText; + } + + public virtual string GetDescription() + { + return description; + } + + public virtual string GetStringId() + { + // String id for character names is CHARACTER. + return "CHARACTER." + nameText; + } + + #endregion + + protected virtual void OnValidate() + { + if (portraits != null && portraits.Count > 1) + { + portraits.Sort(PortraitUtil.PortraitCompareTo); + } + } + } +} diff --git a/Assets/Fungus/Scripts/Components/Character.cs.meta b/Assets/Fungus/Scripts/Components/Character.cs.meta new file mode 100644 index 0000000..b3029da --- /dev/null +++ b/Assets/Fungus/Scripts/Components/Character.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 25fb867d2049d41f597aefdd6b19f598 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Fungus/Scripts/Components/Clickable2D.cs b/Assets/Fungus/Scripts/Components/Clickable2D.cs new file mode 100644 index 0000000..7f74583 --- /dev/null +++ b/Assets/Fungus/Scripts/Components/Clickable2D.cs @@ -0,0 +1,131 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; +using UnityEngine.EventSystems; + +namespace Fungus +{ + /// + /// Detects mouse clicks and touches on a Game Object, and sends an event to all Flowchart event handlers in the scene. + /// The Game Object must have a Collider or Collider2D component attached. + /// Use in conjunction with the ObjectClicked Flowchart event handler. + /// + public class Clickable2D : MonoBehaviour, IPointerClickHandler, IPointerEnterHandler, IPointerExitHandler + { + [Tooltip("Is object clicking enabled")] + [SerializeField] protected bool clickEnabled = true; + + [Tooltip("Mouse texture to use when hovering mouse over object")] + [SerializeField] protected Texture2D hoverCursor; + + [Tooltip("Use the UI Event System to check for clicks. Clicks that hit an overlapping UI object will be ignored. Camera must have a PhysicsRaycaster component, or a Physics2DRaycaster for 2D colliders.")] + [SerializeField] protected bool useEventSystem; + + protected virtual void ChangeCursor(Texture2D cursorTexture) + { + if (!clickEnabled) + { + return; + } + + Cursor.SetCursor(cursorTexture, Vector2.zero, CursorMode.Auto); + } + + protected virtual void DoPointerClick() + { + if (!clickEnabled) + { + return; + } + + var eventDispatcher = FungusManager.Instance.EventDispatcher; + + eventDispatcher.Raise(new ObjectClicked.ObjectClickedEvent(this)); + } + + protected virtual void DoPointerEnter() + { + ChangeCursor(hoverCursor); + } + + protected virtual void DoPointerExit() + { + // Always reset the mouse cursor to be on the safe side + SetMouseCursor.ResetMouseCursor(); + } + + #region Legacy OnMouseX methods + + protected virtual void OnMouseDown() + { + if (!useEventSystem) + { + DoPointerClick(); + } + } + + protected virtual void OnMouseEnter() + { + if (!useEventSystem) + { + DoPointerEnter(); + } + } + + protected virtual void OnMouseExit() + { + if (!useEventSystem) + { + DoPointerExit(); + } + } + + #endregion + + #region Public members + + /// + /// Is object clicking enabled. + /// + public bool ClickEnabled { set { clickEnabled = value; } } + + #endregion + + #region IPointerClickHandler implementation + + public void OnPointerClick(PointerEventData eventData) + { + if (useEventSystem) + { + DoPointerClick(); + } + } + + #endregion + + #region IPointerEnterHandler implementation + + public void OnPointerEnter(PointerEventData eventData) + { + if (useEventSystem) + { + DoPointerEnter(); + } + } + + #endregion + + #region IPointerExitHandler implementation + + public void OnPointerExit(PointerEventData eventData) + { + if (useEventSystem) + { + DoPointerExit(); + } + } + + #endregion + } +} diff --git a/Assets/Fungus/Scripts/Components/Clickable2D.cs.meta b/Assets/Fungus/Scripts/Components/Clickable2D.cs.meta new file mode 100644 index 0000000..45e3309 --- /dev/null +++ b/Assets/Fungus/Scripts/Components/Clickable2D.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: cc03961113fa349c09cb06ef2911013d +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Fungus/Scripts/Components/Command.cs b/Assets/Fungus/Scripts/Components/Command.cs new file mode 100644 index 0000000..fca8395 --- /dev/null +++ b/Assets/Fungus/Scripts/Components/Command.cs @@ -0,0 +1,336 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; +using UnityEngine.Serialization; +using System; +using System.Collections.Generic; + +namespace Fungus +{ + /// + /// Attribute class for Fungus commands. + /// + /// + [AttributeUsage(AttributeTargets.Class, AllowMultiple = true)] + public class CommandInfoAttribute : Attribute + { + /// + /// Metadata atribute for the Command class. + /// + /// The category to place this command in. + /// The display name of the command. + /// Help information to display in the inspector. + /// If two command classes have the same name, the one with highest priority is listed. Negative priority removess the command from the list./// + public CommandInfoAttribute(string category, string commandName, string helpText, int priority = 0) + { + this.Category = category; + this.CommandName = commandName; + this.HelpText = helpText; + this.Priority = priority; + } + + public string Category { get; set; } + public string CommandName { get; set; } + public string HelpText { get; set; } + public int Priority { get; set; } + } + + /// + /// Base class for Commands. Commands can be added to Blocks to create an execution sequence. + /// + public abstract class Command : MonoBehaviour, IVariableReference + { + [FormerlySerializedAs("commandId")] + [HideInInspector] + [SerializeField] protected int itemId = -1; // Invalid flowchart item id + + [HideInInspector] + [SerializeField] protected int indentLevel; + + protected string errorMessage = ""; + + #region Editor caches +#if UNITY_EDITOR + // + protected List referencedVariables = new List(); + + //used by var list adapter to highlight variables + public bool IsVariableReferenced(Variable variable) + { + return referencedVariables.Contains(variable) || HasReference(variable); + } + + /// + /// Called by OnValidate + /// + /// Child classes to specialise to add variable references to referencedVariables, either directly or + /// via the use of Flowchart.DetermineSubstituteVariables + /// + protected virtual void RefreshVariableCache() + { + referencedVariables.Clear(); + } +#endif + #endregion Editor caches + + #region Public members + + /// + /// Unique identifier for this command. + /// Unique for this Flowchart. + /// + public virtual int ItemId { get { return itemId; } set { itemId = value; } } + + /// + /// Error message to display in the command inspector. + /// + public virtual string ErrorMessage { get { return errorMessage; } } + + /// + /// Indent depth of the current commands. + /// Commands are indented inside If, While, etc. sections. + /// + public virtual int IndentLevel { get { return indentLevel; } set { indentLevel = value; } } + + /// + /// Index of the command in the parent block's command list. + /// + public virtual int CommandIndex { get; set; } + + /// + /// Set to true by the parent block while the command is executing. + /// + public virtual bool IsExecuting { get; set; } + + /// + /// Timer used to control appearance of executing icon in inspector. + /// + public virtual float ExecutingIconTimer { get; set; } + + /// + /// Reference to the Block object that this command belongs to. + /// This reference is only populated at runtime and in the editor when the + /// block is selected. + /// + public virtual Block ParentBlock { get; set; } + + /// + /// Returns the Flowchart that this command belongs to. + /// + public virtual Flowchart GetFlowchart() + { + var flowchart = GetComponent(); + if (flowchart == null && + transform.parent != null) + { + flowchart = transform.parent.GetComponent(); + } + return flowchart; + } + + /// + /// Execute the command. + /// + public virtual void Execute() + { + OnEnter(); + } + + /// + /// End execution of this command and continue execution at the next command. + /// + public virtual void Continue() + { + // This is a noop if the Block has already been stopped + if (IsExecuting) + { + Continue(CommandIndex + 1); + } + } + + /// + /// End execution of this command and continue execution at a specific command index. + /// + /// Next command index. + public virtual void Continue(int nextCommandIndex) + { + OnExit(); + if (ParentBlock != null) + { + ParentBlock.JumpToCommandIndex = nextCommandIndex; + } + } + + /// + /// Stops the parent Block executing. + /// + public virtual void StopParentBlock() + { + OnExit(); + if (ParentBlock != null) + { + ParentBlock.Stop(); + } + } + + /// + /// Called when the parent block has been requested to stop executing, and + /// this command is the currently executing command. + /// Use this callback to terminate any asynchronous operations and + /// cleanup state so that the command is ready to execute again later on. + /// + public virtual void OnStopExecuting() + {} + + /// + /// Called when the new command is added to a block in the editor. + /// + public virtual void OnCommandAdded(Block parentBlock) + {} + + /// + /// Called when the command is deleted from a block in the editor. + /// + public virtual void OnCommandRemoved(Block parentBlock) + {} + + /// + /// Called when this command starts execution. + /// + public virtual void OnEnter() + {} + + /// + /// Called when this command ends execution. + /// + public virtual void OnExit() + {} + + /// + /// Called when this command is reset. This happens when the Reset command is used. + /// + public virtual void OnReset() + {} + + /// + /// Populates a list with the Blocks that this command references. + /// + public virtual void GetConnectedBlocks(ref List connectedBlocks) + {} + + /// + /// Returns true if this command references the variable. + /// Used to highlight variables in the variable list when a command is selected. + /// + public virtual bool HasReference(Variable variable) + { + return false; + } + + public virtual string GetLocationIdentifier() + { + return ParentBlock.GetFlowchart().GetName() + ":" + ParentBlock.BlockName + "." + this.GetType().Name + "#" + CommandIndex.ToString(); + } + + /// + /// Called by unity when script is loaded or its data changed by editor + /// + public virtual void OnValidate() + { +#if UNITY_EDITOR + RefreshVariableCache(); +#endif + } + + /// + /// Returns the summary text to display in the command inspector. + /// + public virtual string GetSummary() + { + return ""; + } + + /// + /// Returns the searchable content for searches on the flowchart window. + /// + public virtual string GetSearchableContent() + { + return GetSummary(); + } + + /// + /// Returns the help text to display for this command. + /// + public virtual string GetHelpText() + { + return ""; + } + + /// + /// Return true if this command opens a block of commands. Used for indenting commands. + /// + public virtual bool OpenBlock() + { + return false; + } + + /// + /// Return true if this command closes a block of commands. Used for indenting commands. + /// + public virtual bool CloseBlock() + { + return false; + } + + /// + /// Return the color for the command background in inspector. + /// + /// The button color. + public virtual Color GetButtonColor() + { + return Color.white; + } + + /// + /// Returns true if the specified property should be displayed in the inspector. + /// This is useful for hiding certain properties based on the value of another property. + /// + public virtual bool IsPropertyVisible(string propertyName) + { + return true; + } + + /// + /// Returns true if the specified property should be displayed as a reorderable list in the inspector. + /// This only applies for array properties and has no effect for non-array properties. + /// + public virtual bool IsReorderableArray(string propertyName) + { + return false; + } + + /// + /// Returns the localization id for the Flowchart that contains this command. + /// + public virtual string GetFlowchartLocalizationId() + { + // If no localization id has been set then use the Flowchart name + var flowchart = GetFlowchart(); + if (flowchart == null) + { + return ""; + } + + string localizationId = GetFlowchart().LocalizationId; + if (localizationId.Length == 0) + { + localizationId = flowchart.GetName(); + } + + return localizationId; + } + + #endregion + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Components/Command.cs.meta b/Assets/Fungus/Scripts/Components/Command.cs.meta new file mode 100644 index 0000000..5496c01 --- /dev/null +++ b/Assets/Fungus/Scripts/Components/Command.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 8e206154a3e694fb2bfc9e518a474603 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Fungus/Scripts/Components/CommandCopyBuffer.cs b/Assets/Fungus/Scripts/Components/CommandCopyBuffer.cs new file mode 100644 index 0000000..157ac42 --- /dev/null +++ b/Assets/Fungus/Scripts/Components/CommandCopyBuffer.cs @@ -0,0 +1,75 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; + +namespace Fungus +{ + /// + /// Temporary buffer object used when copying and pasting commands. + /// + [AddComponentMenu("")] + public class CommandCopyBuffer : Block + { + protected static CommandCopyBuffer instance; + + protected virtual void Start() + { + if (Application.isPlaying) + { + Destroy(this.gameObject); + } + } + + #region Public members + + /// + /// Returns the CommandCopyBuffer singleton instance. + /// Will create a CommandCopyBuffer game object if none currently exists. + /// + public static CommandCopyBuffer GetInstance() + { + if (instance == null) + { + // Static variables are not serialized (e.g. when playing in the editor) + // We need to reaquire the static reference to the game object in this case + GameObject go = GameObject.Find("_CommandCopyBuffer"); + if (go == null) + { + go = new GameObject("_CommandCopyBuffer"); + go.hideFlags = HideFlags.HideAndDontSave; + } + + instance = go.GetComponent(); + if (instance == null) + { + instance = go.AddComponent(); + } + } + + return instance; + } + + public virtual bool HasCommands() + { + return GetCommands().Length > 0; + } + + public virtual Command[] GetCommands() + { + return GetComponents(); + } + + public virtual void Clear() + { + var commands = GetCommands(); + for (int i = 0; i < commands.Length; i++) + { + var command = commands[i]; + DestroyImmediate(command); + } + } + + #endregion + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Components/CommandCopyBuffer.cs.meta b/Assets/Fungus/Scripts/Components/CommandCopyBuffer.cs.meta new file mode 100644 index 0000000..6960f81 --- /dev/null +++ b/Assets/Fungus/Scripts/Components/CommandCopyBuffer.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 28859462f29464188bb29cc9f1f6e92c +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Fungus/Scripts/Components/CustomTag.cs b/Assets/Fungus/Scripts/Components/CustomTag.cs new file mode 100644 index 0000000..f56bbdc --- /dev/null +++ b/Assets/Fungus/Scripts/Components/CustomTag.cs @@ -0,0 +1,66 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; +using System.Collections.Generic; + +namespace Fungus +{ + /// + /// Create custom tags for use in Say text. + /// + [ExecuteInEditMode] + public class CustomTag : MonoBehaviour + { + [Tooltip("String that defines the start of the tag.")] + [SerializeField] protected string tagStartSymbol; + + [Tooltip("String that defines the end of the tag.")] + [SerializeField] protected string tagEndSymbol; + + [Tooltip("String to replace the start tag with.")] + [SerializeField] protected string replaceTagStartWith; + + [Tooltip("String to replace the end tag with.")] + [SerializeField] protected string replaceTagEndWith; + + protected virtual void OnEnable() + { + if (!activeCustomTags.Contains(this)) + { + activeCustomTags.Add(this); + } + } + + protected virtual void OnDisable() + { + activeCustomTags.Remove(this); + } + + #region Public members + + public static List activeCustomTags = new List(); + + /// + /// String that defines the start of the tag. + /// + public virtual string TagStartSymbol { get { return tagStartSymbol; } } + + /// + /// String that defines the end of the tag. + /// + public virtual string TagEndSymbol { get { return tagEndSymbol; } } + + /// + /// String to replace the start tag with. + /// + public virtual string ReplaceTagStartWith { get { return replaceTagStartWith; } } + + /// + /// String to replace the end tag with. + /// + public virtual string ReplaceTagEndWith { get { return replaceTagEndWith; } } + + #endregion + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Components/CustomTag.cs.meta b/Assets/Fungus/Scripts/Components/CustomTag.cs.meta new file mode 100644 index 0000000..6ca7e39 --- /dev/null +++ b/Assets/Fungus/Scripts/Components/CustomTag.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 335e04fbdd5260043abb299a991dcbe8 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Fungus/Scripts/Components/DialogInput.cs b/Assets/Fungus/Scripts/Components/DialogInput.cs new file mode 100644 index 0000000..514c7e4 --- /dev/null +++ b/Assets/Fungus/Scripts/Components/DialogInput.cs @@ -0,0 +1,188 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; +using UnityEngine.EventSystems; + +namespace Fungus +{ + /// + /// Supported modes for clicking through a Say Dialog. + /// + public enum ClickMode + { + /// Clicking disabled. + Disabled, + /// Click anywhere on screen to advance. + ClickAnywhere, + /// Click anywhere on Say Dialog to advance. + ClickOnDialog, + /// Click on continue button to advance. + ClickOnButton + } + + /// + /// Input handler for say dialogs. + /// + public class DialogInput : MonoBehaviour + { + [Tooltip("Click to advance story")] + [SerializeField] protected ClickMode clickMode; + + [Tooltip("Delay between consecutive clicks. Useful to prevent accidentally clicking through story.")] + [SerializeField] protected float nextClickDelay = 0f; + + [Tooltip("Allow holding Cancel to fast forward text")] + [SerializeField] protected bool cancelEnabled = true; + + [Tooltip("Ignore input if a Menu dialog is currently active")] + [SerializeField] protected bool ignoreMenuClicks = true; + + protected bool dialogClickedFlag; + + protected bool nextLineInputFlag; + + protected float ignoreClickTimer; + + protected StandaloneInputModule currentStandaloneInputModule; + + protected Writer writer; + + protected virtual void Awake() + { + writer = GetComponent(); + + CheckEventSystem(); + } + + // There must be an Event System in the scene for Say and Menu input to work. + // This method will automatically instantiate one if none exists. + protected virtual void CheckEventSystem() + { + EventSystem eventSystem = GameObject.FindObjectOfType(); + if (eventSystem == null) + { + // Auto spawn an Event System from the prefab + GameObject prefab = Resources.Load("Prefabs/EventSystem"); + if (prefab != null) + { + GameObject go = Instantiate(prefab) as GameObject; + go.name = "EventSystem"; + } + } + } + + protected virtual void Update() + { + if (EventSystem.current == null) + { + return; + } + + if (currentStandaloneInputModule == null) + { + currentStandaloneInputModule = EventSystem.current.GetComponent(); + } + + if (writer != null && writer.IsWriting) + { + if (Input.GetButtonDown(currentStandaloneInputModule.submitButton) || + (cancelEnabled && Input.GetButton(currentStandaloneInputModule.cancelButton))) + { + SetNextLineFlag(); + } + } + + switch (clickMode) + { + case ClickMode.Disabled: + break; + case ClickMode.ClickAnywhere: + if (Input.GetMouseButtonDown(0)) + { + SetNextLineFlag(); + } + break; + case ClickMode.ClickOnDialog: + if (dialogClickedFlag) + { + SetNextLineFlag(); + dialogClickedFlag = false; + } + break; + } + + if (ignoreClickTimer > 0f) + { + ignoreClickTimer = Mathf.Max (ignoreClickTimer - Time.deltaTime, 0f); + } + + if (ignoreMenuClicks) + { + // Ignore input events if a Menu is being displayed + if (MenuDialog.ActiveMenuDialog != null && + MenuDialog.ActiveMenuDialog.IsActive() && + MenuDialog.ActiveMenuDialog.DisplayedOptionsCount > 0) + { + dialogClickedFlag = false; + nextLineInputFlag = false; + } + } + + // Tell any listeners to move to the next line + if (nextLineInputFlag) + { + var inputListeners = gameObject.GetComponentsInChildren(); + for (int i = 0; i < inputListeners.Length; i++) + { + var inputListener = inputListeners[i]; + inputListener.OnNextLineEvent(); + } + nextLineInputFlag = false; + } + } + + #region Public members + + /// + /// Trigger next line input event from script. + /// + public virtual void SetNextLineFlag() + { + nextLineInputFlag = true; + } + + /// + /// Set the dialog clicked flag (usually from an Event Trigger component in the dialog UI). + /// + public virtual void SetDialogClickedFlag() + { + // Ignore repeat clicks for a short time to prevent accidentally clicking through the character dialogue + if (ignoreClickTimer > 0f) + { + return; + } + ignoreClickTimer = nextClickDelay; + + // Only applies in Click On Dialog mode + if (clickMode == ClickMode.ClickOnDialog) + { + dialogClickedFlag = true; + } + } + + /// + /// Sets the button clicked flag. + /// + public virtual void SetButtonClickedFlag() + { + // Only applies if clicking is not disabled + if (clickMode != ClickMode.Disabled) + { + SetNextLineFlag(); + } + } + + #endregion + } +} diff --git a/Assets/Fungus/Scripts/Components/DialogInput.cs.meta b/Assets/Fungus/Scripts/Components/DialogInput.cs.meta new file mode 100644 index 0000000..1d34ea4 --- /dev/null +++ b/Assets/Fungus/Scripts/Components/DialogInput.cs.meta @@ -0,0 +1,12 @@ +fileFormatVersion: 2 +guid: 43b85556abd314f3f870c18c013fdcef +timeCreated: 1439996546 +licenseType: Store +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Components/Draggable2D.cs b/Assets/Fungus/Scripts/Components/Draggable2D.cs new file mode 100644 index 0000000..73f8b0a --- /dev/null +++ b/Assets/Fungus/Scripts/Components/Draggable2D.cs @@ -0,0 +1,300 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; +using UnityEngine.EventSystems; +using UnityEngine.Serialization; +using System.Collections.Generic; + +namespace Fungus +{ + /// + /// Detects drag and drop interactions on a Game Object, and sends events to all Flowchart event handlers in the scene. + /// The Game Object must have Collider2D & RigidBody components attached. + /// The Collider2D must have the Is Trigger property set to true. + /// The RigidBody would typically have the Is Kinematic property set to true, unless you want the object to move around using physics. + /// Use in conjunction with the Drag Started, Drag Completed, Drag Cancelled, Drag Entered & Drag Exited event handlers. + /// + public class Draggable2D : MonoBehaviour, IBeginDragHandler, IDragHandler, IEndDragHandler, IPointerEnterHandler, IPointerExitHandler + { + [Tooltip("Is object dragging enabled")] + [SerializeField] protected bool dragEnabled = true; + + [Tooltip("Move object back to its starting position when drag is cancelled")] + [FormerlySerializedAs("returnToStartPos")] + [SerializeField] protected bool returnOnCancelled = true; + + [Tooltip("Move object back to its starting position when drag is completed")] + [SerializeField] protected bool returnOnCompleted = true; + + [Tooltip("Time object takes to return to its starting position")] + [SerializeField] protected float returnDuration = 1f; + + [Tooltip("Mouse texture to use when hovering mouse over object")] + [SerializeField] protected Texture2D hoverCursor; + + [Tooltip("Use the UI Event System to check for drag events. Clicks that hit an overlapping UI object will be ignored. Camera must have a PhysicsRaycaster component, or a Physics2DRaycaster for 2D colliders.")] + [SerializeField] protected bool useEventSystem; + + protected Vector3 startingPosition; + protected bool updatePosition = false; + protected Vector3 newPosition; + protected Vector3 delta = Vector3.zero; + + #region DragCompleted handlers + protected List dragCompletedHandlers = new List(); + + public void RegisterHandler(DragCompleted handler) + { + dragCompletedHandlers.Add(handler); + } + + public void UnregisterHandler(DragCompleted handler) + { + if(dragCompletedHandlers.Contains(handler)) + { + dragCompletedHandlers.Remove(handler); + } + } + #endregion + + protected virtual void LateUpdate() + { + // iTween will sometimes override the object position even if it should only be affecting the scale, rotation, etc. + // To make sure this doesn't happen, we force the position change to happen in LateUpdate. + if (updatePosition) + { + transform.position = newPosition; + updatePosition = false; + } + } + + protected virtual void OnTriggerEnter2D(Collider2D other) + { + if (!dragEnabled) + { + return; + } + + var eventDispatcher = FungusManager.Instance.EventDispatcher; + + eventDispatcher.Raise(new DragEntered.DragEnteredEvent(this, other)); + } + + protected virtual void OnTriggerExit2D(Collider2D other) + { + if (!dragEnabled) + { + return; + } + + var eventDispatcher = FungusManager.Instance.EventDispatcher; + + eventDispatcher.Raise(new DragExited.DragExitedEvent(this, other)); + } + + protected virtual void DoBeginDrag() + { + // Offset the object so that the drag is anchored to the exact point where the user clicked it + float x = Input.mousePosition.x; + float y = Input.mousePosition.y; + delta = Camera.main.ScreenToWorldPoint(new Vector3(x, y, 10f)) - transform.position; + delta.z = 0f; + + startingPosition = transform.position; + + var eventDispatcher = FungusManager.Instance.EventDispatcher; + + eventDispatcher.Raise(new DragStarted.DragStartedEvent(this)); + } + + protected virtual void DoDrag() + { + if (!dragEnabled) + { + return; + } + + float x = Input.mousePosition.x; + float y = Input.mousePosition.y; + float z = transform.position.z; + + newPosition = Camera.main.ScreenToWorldPoint(new Vector3(x, y, 10f)) - delta; + newPosition.z = z; + updatePosition = true; + } + + protected virtual void DoEndDrag() + { + if (!dragEnabled) + { + return; + } + + var eventDispatcher = FungusManager.Instance.EventDispatcher; + bool dragCompleted = false; + + for (int i = 0; i < dragCompletedHandlers.Count; i++) + { + var handler = dragCompletedHandlers[i]; + if (handler != null && handler.DraggableObjects.Contains(this)) + { + if (handler.IsOverTarget()) + { + dragCompleted = true; + + eventDispatcher.Raise(new DragCompleted.DragCompletedEvent(this)); + } + } + } + + if (!dragCompleted) + { + eventDispatcher.Raise(new DragCancelled.DragCancelledEvent(this)); + + if (returnOnCancelled) + { + LeanTween.move(gameObject, startingPosition, returnDuration).setEase(LeanTweenType.easeOutExpo); + } + } + else if(returnOnCompleted) + { + LeanTween.move(gameObject, startingPosition, returnDuration).setEase(LeanTweenType.easeOutExpo); + } + } + + protected virtual void DoPointerEnter() + { + ChangeCursor(hoverCursor); + } + + protected virtual void DoPointerExit() + { + SetMouseCursor.ResetMouseCursor(); + } + + protected virtual void ChangeCursor(Texture2D cursorTexture) + { + if (!dragEnabled) + { + return; + } + + Cursor.SetCursor(cursorTexture, Vector2.zero, CursorMode.Auto); + } + + #region Legacy OnMouseX methods + + protected virtual void OnMouseDown() + { + if (!useEventSystem) + { + DoBeginDrag(); + } + } + + protected virtual void OnMouseDrag() + { + if (!useEventSystem) + { + DoDrag(); + } + } + + protected virtual void OnMouseUp() + { + if (!useEventSystem) + { + DoEndDrag(); + } + } + + protected virtual void OnMouseEnter() + { + if (!useEventSystem) + { + DoPointerEnter(); + } + } + + protected virtual void OnMouseExit() + { + if (!useEventSystem) + { + DoPointerExit(); + } + } + + #endregion + + #region Public members + + /// + /// Is object drag and drop enabled. + /// + /// true if drag enabled; otherwise, false. + public virtual bool DragEnabled { get { return dragEnabled; } set { dragEnabled = value; } } + + #endregion + + #region IBeginDragHandler implementation + + public void OnBeginDrag(PointerEventData eventData) + { + if (useEventSystem) + { + DoBeginDrag(); + } + } + + #endregion + + #region IDragHandler implementation + + public void OnDrag(PointerEventData eventData) + { + if (useEventSystem) + { + DoDrag(); + } + } + + #endregion + + #region IEndDragHandler implementation + + public void OnEndDrag(PointerEventData eventData) + { + if (useEventSystem) + { + DoEndDrag(); + } + } + + #endregion + + #region IPointerEnterHandler implementation + + public void OnPointerEnter(PointerEventData eventData) + { + if (useEventSystem) + { + DoPointerEnter(); + } + } + + #endregion + + #region IPointerExitHandler implementation + + public void OnPointerExit(PointerEventData eventData) + { + if (useEventSystem) + { + DoPointerExit(); + } + } + + #endregion + } +} diff --git a/Assets/Fungus/Scripts/Components/Draggable2D.cs.meta b/Assets/Fungus/Scripts/Components/Draggable2D.cs.meta new file mode 100644 index 0000000..88948ac --- /dev/null +++ b/Assets/Fungus/Scripts/Components/Draggable2D.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 18a0e492e94664ec0ac44d252c40e3a7 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Fungus/Scripts/Components/EventHandler.cs b/Assets/Fungus/Scripts/Components/EventHandler.cs new file mode 100644 index 0000000..06653ec --- /dev/null +++ b/Assets/Fungus/Scripts/Components/EventHandler.cs @@ -0,0 +1,95 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; +using UnityEngine.Serialization; +using System; + +namespace Fungus +{ + /// + /// Attribute class for Fungus event handlers. + /// + public class EventHandlerInfoAttribute : Attribute + { + public EventHandlerInfoAttribute(string category, string eventHandlerName, string helpText) + { + this.Category = category; + this.EventHandlerName = eventHandlerName; + this.HelpText = helpText; + } + + public string Category { get; set; } + public string EventHandlerName { get; set; } + public string HelpText { get; set; } + } + + /// + /// A Block may have an associated Event Handler which starts executing commands when + /// a specific event occurs. + /// To create a custom Event Handler, simply subclass EventHandler and call the ExecuteBlock() method + /// when the event occurs. + /// Add an EventHandlerInfo attibute and your new EventHandler class will automatically appear in the + /// 'Execute On Event' dropdown menu when a block is selected. + /// + [RequireComponent(typeof(Block))] + [RequireComponent(typeof(Flowchart))] + [AddComponentMenu("")] + public class EventHandler : MonoBehaviour + { + [HideInInspector] + [FormerlySerializedAs("parentSequence")] + [SerializeField] protected Block parentBlock; + + [Tooltip("If true, the flowchart window will not auto select the Block when the Event Handler fires. Affects Editor only.")] + [SerializeField] protected bool suppressBlockAutoSelect = false; + + #region Public members + + /// + /// The parent Block which owns this Event Handler. + /// + public virtual Block ParentBlock { get { return parentBlock; } set { parentBlock = value; } } + + /// + /// The Event Handler should call this method when the event is detected to start executing the Block. + /// + public virtual bool ExecuteBlock() + { + if (ParentBlock == null) + { + return false; + } + + if (ParentBlock._EventHandler != this) + { + return false; + } + + var flowchart = ParentBlock.GetFlowchart(); + + //if somehow the flowchart is invalid or has been disabled we don't want to continue + if(flowchart == null || !flowchart.isActiveAndEnabled) + { + return false; + } + + if (suppressBlockAutoSelect) + { + ParentBlock.SuppressNextAutoSelection = true; + } + + return flowchart.ExecuteBlock(ParentBlock); + } + + /// + /// Returns custom summary text for the event handler. + /// + public virtual string GetSummary() + { + return ""; + } + + #endregion + } +} diff --git a/Assets/Fungus/Scripts/Components/EventHandler.cs.meta b/Assets/Fungus/Scripts/Components/EventHandler.cs.meta new file mode 100644 index 0000000..0314674 --- /dev/null +++ b/Assets/Fungus/Scripts/Components/EventHandler.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 33263015c61344280b425bd04afb7ff3 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Fungus/Scripts/Components/Flowchart.cs b/Assets/Fungus/Scripts/Components/Flowchart.cs new file mode 100644 index 0000000..3743293 --- /dev/null +++ b/Assets/Fungus/Scripts/Components/Flowchart.cs @@ -0,0 +1,1416 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; +using UnityEngine.EventSystems; +using System; +using System.Text; +using System.Linq; +using System.Collections.Generic; +using System.Text.RegularExpressions; + +namespace Fungus +{ + /// + /// Visual scripting controller for the Flowchart programming language. + /// Flowchart objects may be edited visually using the Flowchart editor window. + /// + [ExecuteInEditMode] + public class Flowchart : MonoBehaviour, ISubstitutionHandler + { + public const string SubstituteVariableRegexString = "{\\$.*?}"; + + [HideInInspector] + [SerializeField] protected int version = 0; // Default to 0 to always trigger an update for older versions of Fungus. + + [HideInInspector] + [SerializeField] protected Vector2 scrollPos; + + [HideInInspector] + [SerializeField] protected Vector2 variablesScrollPos; + + [HideInInspector] + [SerializeField] protected bool variablesExpanded = true; + + [HideInInspector] + [SerializeField] protected float blockViewHeight = 400; + + [HideInInspector] + [SerializeField] protected float zoom = 1f; + + [HideInInspector] + [SerializeField] protected Rect scrollViewRect; + + [HideInInspector] + [SerializeField] protected List selectedBlocks = new List(); + + [HideInInspector] + [SerializeField] protected List selectedCommands = new List(); + + [HideInInspector] + [SerializeField] protected List variables = new List(); + + [TextArea(3, 5)] + [Tooltip("Description text displayed in the Flowchart editor window")] + [SerializeField] protected string description = ""; + + [Range(0f, 5f)] + [Tooltip("Adds a pause after each execution step to make it easier to visualise program flow. Editor only, has no effect in platform builds.")] + [SerializeField] protected float stepPause = 0f; + + [Tooltip("Use command color when displaying the command list in the Fungus Editor window")] + [SerializeField] protected bool colorCommands = true; + + [Tooltip("Hides the Flowchart block and command components in the inspector. Deselect to inspect the block and command components that make up the Flowchart.")] + [SerializeField] protected bool hideComponents = true; + + [Tooltip("Saves the selected block and commands when saving the scene. Helps avoid version control conflicts if you've only changed the active selection.")] + [SerializeField] protected bool saveSelection = true; + + [Tooltip("Unique identifier for this flowchart in localized string keys. If no id is specified then the name of the Flowchart object will be used.")] + [SerializeField] protected string localizationId = ""; + + [Tooltip("Display line numbers in the command list in the Block inspector.")] + [SerializeField] protected bool showLineNumbers = false; + + [Tooltip("List of commands to hide in the Add Command menu. Use this to restrict the set of commands available when editing a Flowchart.")] + [SerializeField] protected List hideCommands = new List(); + + [Tooltip("Lua Environment to be used by default for all Execute Lua commands in this Flowchart")] + [SerializeField] protected LuaEnvironment luaEnvironment; + + [Tooltip("The ExecuteLua command adds a global Lua variable with this name bound to the flowchart prior to executing.")] + [SerializeField] protected string luaBindingName = "flowchart"; + + protected static List cachedFlowcharts = new List(); + + protected static bool eventSystemPresent; + + protected StringSubstituter stringSubstituer; + +#if UNITY_EDITOR + public bool SelectedCommandsStale { get; set; } +#endif + + #if UNITY_5_4_OR_NEWER + #else + protected virtual void OnLevelWasLoaded(int level) + { + LevelWasLoaded(); + } + #endif + + protected virtual void LevelWasLoaded() + { + // Reset the flag for checking for an event system as there may not be one in the newly loaded scene. + eventSystemPresent = false; + } + + protected virtual void Start() + { + CheckEventSystem(); + } + + // There must be an Event System in the scene for Say and Menu input to work. + // This method will automatically instantiate one if none exists. + protected virtual void CheckEventSystem() + { + if (eventSystemPresent) + { + return; + } + + EventSystem eventSystem = GameObject.FindObjectOfType(); + if (eventSystem == null) + { + // Auto spawn an Event System from the prefab + GameObject prefab = Resources.Load("Prefabs/EventSystem"); + if (prefab != null) + { + GameObject go = Instantiate(prefab) as GameObject; + go.name = "EventSystem"; + } + } + + eventSystemPresent = true; + } + + private void SceneManager_activeSceneChanged(UnityEngine.SceneManagement.Scene arg0, UnityEngine.SceneManagement.Scene arg1) + { + LevelWasLoaded(); + } + + protected virtual void OnEnable() + { + if (!cachedFlowcharts.Contains(this)) + { + cachedFlowcharts.Add(this); + //TODO these pairs could be replaced by something static that manages all active flowcharts + #if UNITY_5_4_OR_NEWER + UnityEngine.SceneManagement.SceneManager.activeSceneChanged += SceneManager_activeSceneChanged; + #endif + } + + CheckItemIds(); + CleanupComponents(); + UpdateVersion(); + + StringSubstituter.RegisterHandler(this); + } + + protected virtual void OnDisable() + { + cachedFlowcharts.Remove(this); + + #if UNITY_5_4_OR_NEWER + UnityEngine.SceneManagement.SceneManager.activeSceneChanged -= SceneManager_activeSceneChanged; + #endif + + StringSubstituter.UnregisterHandler(this); + } + + protected virtual void UpdateVersion() + { + if (version == FungusConstants.CurrentVersion) + { + // No need to update + return; + } + + // Tell all components that implement IUpdateable to update to the new version + var components = GetComponents(); + for (int i = 0; i < components.Length; i++) + { + var component = components[i]; + IUpdateable u = component as IUpdateable; + if (u != null) + { + u.UpdateToVersion(version, FungusConstants.CurrentVersion); + } + } + + version = FungusConstants.CurrentVersion; + } + + protected virtual void CheckItemIds() + { + // Make sure item ids are unique and monotonically increasing. + // This should always be the case, but some legacy Flowcharts may have issues. + List usedIds = new List(); + var blocks = GetComponents(); + for (int i = 0; i < blocks.Length; i++) + { + var block = blocks[i]; + if (block.ItemId == -1 || usedIds.Contains(block.ItemId)) + { + block.ItemId = NextItemId(); + } + usedIds.Add(block.ItemId); + } + + var commands = GetComponents(); + for (int i = 0; i < commands.Length; i++) + { + var command = commands[i]; + if (command.ItemId == -1 || usedIds.Contains(command.ItemId)) + { + command.ItemId = NextItemId(); + } + usedIds.Add(command.ItemId); + } + } + + protected virtual void CleanupComponents() + { + // Delete any unreferenced components which shouldn't exist any more + // Unreferenced components don't have any effect on the flowchart behavior, but + // they waste memory so should be cleared out periodically. + + // Remove any null entries in the variables list + // It shouldn't happen but it seemed to occur for a user on the forum + variables.RemoveAll(item => item == null); + + if (selectedBlocks == null) selectedBlocks = new List(); + if (selectedCommands == null) selectedCommands = new List(); + + selectedBlocks.RemoveAll(item => item == null); + selectedCommands.RemoveAll(item => item == null); + + var allVariables = GetComponents(); + for (int i = 0; i < allVariables.Length; i++) + { + var variable = allVariables[i]; + if (!variables.Contains(variable)) + { + DestroyImmediate(variable); + } + } + + var blocks = GetComponents(); + var commands = GetComponents(); + for (int i = 0; i < commands.Length; i++) + { + var command = commands[i]; + bool found = false; + for (int j = 0; j < blocks.Length; j++) + { + var block = blocks[j]; + if (block.CommandList.Contains(command)) + { + found = true; + break; + } + } + if (!found) + { + DestroyImmediate(command); + } + } + + var eventHandlers = GetComponents(); + for (int i = 0; i < eventHandlers.Length; i++) + { + var eventHandler = eventHandlers[i]; + bool found = false; + for (int j = 0; j < blocks.Length; j++) + { + var block = blocks[j]; + if (block._EventHandler == eventHandler) + { + found = true; + break; + } + } + if (!found) + { + DestroyImmediate(eventHandler); + } + } + } + + protected virtual Block CreateBlockComponent(GameObject parent) + { + Block block = parent.AddComponent(); + return block; + } + + #region Public members + + /// + /// Cached list of flowchart objects in the scene for fast lookup. + /// + public static List CachedFlowcharts { get { return cachedFlowcharts; } } + + /// + /// Sends a message to all Flowchart objects in the current scene. + /// Any block with a matching MessageReceived event handler will start executing. + /// + public static void BroadcastFungusMessage(string messageName) + { + var eventHandlers = UnityEngine.Object.FindObjectsOfType(); + for (int i = 0; i < eventHandlers.Length; i++) + { + var eventHandler = eventHandlers[i]; + eventHandler.OnSendFungusMessage(messageName); + } + } + + /// + /// Scroll position of Flowchart editor window. + /// + public virtual Vector2 ScrollPos { get { return scrollPos; } set { scrollPos = value; } } + + /// + /// Scroll position of Flowchart variables window. + /// + public virtual Vector2 VariablesScrollPos { get { return variablesScrollPos; } set { variablesScrollPos = value; } } + + /// + /// Show the variables pane. + /// + public virtual bool VariablesExpanded { get { return variablesExpanded; } set { variablesExpanded = value; } } + + /// + /// Height of command block view in inspector. + /// + public virtual float BlockViewHeight { get { return blockViewHeight; } set { blockViewHeight = value; } } + + /// + /// Zoom level of Flowchart editor window. + /// + public virtual float Zoom { get { return zoom; } set { zoom = value; } } + + /// + /// Scrollable area for Flowchart editor window. + /// + public virtual Rect ScrollViewRect { get { return scrollViewRect; } set { scrollViewRect = value; } } + + /// + /// Current actively selected block in the Flowchart editor. + /// + public virtual Block SelectedBlock + { + get + { + if (selectedBlocks == null || selectedBlocks.Count == 0) + return null; + + return selectedBlocks[0]; + } + set + { + ClearSelectedBlocks(); + AddSelectedBlock(value); + } + } + + public virtual List SelectedBlocks { get { return selectedBlocks; } set { selectedBlocks = value; } } + + /// + /// Currently selected command in the Flowchart editor. + /// + public virtual List SelectedCommands { get { return selectedCommands; } } + + /// + /// The list of variables that can be accessed by the Flowchart. + /// + public virtual List Variables { get { return variables; } } + + public virtual int VariableCount { get { return variables.Count; } } + + /// + /// Description text displayed in the Flowchart editor window + /// + public virtual string Description { get { return description; } } + + /// + /// Slow down execution in the editor to make it easier to visualise program flow. + /// + public virtual float StepPause { get { return stepPause; } } + + /// + /// Use command color when displaying the command list in the inspector. + /// + public virtual bool ColorCommands { get { return colorCommands; } } + + /// + /// Saves the selected block and commands when saving the scene. Helps avoid version control conflicts if you've only changed the active selection. + /// + public virtual bool SaveSelection { get { return saveSelection; } } + + /// + /// Unique identifier for identifying this flowchart in localized string keys. + /// + public virtual string LocalizationId { get { return localizationId; } } + + /// + /// Display line numbers in the command list in the Block inspector. + /// + public virtual bool ShowLineNumbers { get { return showLineNumbers; } } + + /// + /// Lua Environment to be used by default for all Execute Lua commands in this Flowchart. + /// + public virtual LuaEnvironment LuaEnv { get { return luaEnvironment; } } + + /// + /// The ExecuteLua command adds a global Lua variable with this name bound to the flowchart prior to executing. + /// + public virtual string LuaBindingName { get { return luaBindingName; } } + + /// + /// Position in the center of all blocks in the flowchart. + /// + public virtual Vector2 CenterPosition { set; get; } + + /// + /// Variable to track flowchart's version so components can update to new versions. + /// + public int Version { set { version = value; } } + + /// + /// Returns true if the Flowchart gameobject is active. + /// + public bool IsActive() + { + return gameObject.activeInHierarchy; + } + + /// + /// Returns the Flowchart gameobject name. + /// + public string GetName() + { + return gameObject.name; + } + + /// + /// Returns the next id to assign to a new flowchart item. + /// Item ids increase monotically so they are guaranteed to + /// be unique within a Flowchart. + /// + public int NextItemId() + { + int maxId = -1; + var blocks = GetComponents(); + for (int i = 0; i < blocks.Length; i++) + { + var block = blocks[i]; + maxId = Math.Max(maxId, block.ItemId); + } + + var commands = GetComponents(); + for (int i = 0; i < commands.Length; i++) + { + var command = commands[i]; + maxId = Math.Max(maxId, command.ItemId); + } + return maxId + 1; + } + + /// + /// Create a new block node which you can then add commands to. + /// + public virtual Block CreateBlock(Vector2 position) + { + Block b = CreateBlockComponent(gameObject); + b._NodeRect = new Rect(position.x, position.y, 0, 0); + b.BlockName = GetUniqueBlockKey(b.BlockName, b); + b.ItemId = NextItemId(); + + return b; + } + + /// + /// Returns the named Block in the flowchart, or null if not found. + /// + public virtual Block FindBlock(string blockName) + { + var blocks = GetComponents(); + for (int i = 0; i < blocks.Length; i++) + { + var block = blocks[i]; + if (block.BlockName == blockName) + { + return block; + } + } + + return null; + } + + /// + /// Checks availability of the block in the Flowchart. + /// You can use this method in a UI event. e.g. to test availability block, before handle it. + public virtual bool HasBlock(string blockName) + { + var block = FindBlock(blockName); + return block != null; + } + + /// + /// Executes the block if it is available in the Flowchart. + /// You can use this method in a UI event. e.g. to try executing block without confidence in its existence. + public virtual bool ExecuteIfHasBlock(string blockName) + { + if (HasBlock(blockName)) + { + ExecuteBlock(blockName); + return true; + } + else + { + return false; + } + } + + /// + /// Execute a child block in the Flowchart. + /// You can use this method in a UI event. e.g. to handle a button click. + public virtual void ExecuteBlock(string blockName) + { + var block = FindBlock(blockName); + + if (block == null) + { + Debug.LogError("Block " + blockName + " does not exist"); + return; + } + + if (!ExecuteBlock(block)) + { + Debug.LogWarning("Block " + blockName + " failed to execute"); + } + } + + /// + /// Stops an executing Block in the Flowchart. + /// + public virtual void StopBlock(string blockName) + { + var block = FindBlock(blockName); + + if (block == null) + { + Debug.LogError("Block " + blockName + " does not exist"); + return; + } + + if (block.IsExecuting()) + { + block.Stop(); + } + } + + /// + /// Execute a child block in the flowchart. + /// The block must be in an idle state to be executed. + /// This version provides extra options to control how the block is executed. + /// Returns true if the Block started execution. + /// + public virtual bool ExecuteBlock(Block block, int commandIndex = 0, Action onComplete = null) + { + if (block == null) + { + Debug.LogError("Block must not be null"); + return false; + } + + if (((Block)block).gameObject != gameObject) + { + Debug.LogError("Block must belong to the same gameobject as this Flowchart"); + return false; + } + + // Can't restart a running block, have to wait until it's idle again + if (block.IsExecuting()) + { + Debug.LogWarning(block.BlockName + " cannot be called/executed, it is already running."); + return false; + } + + // Start executing the Block as a new coroutine + StartCoroutine(block.Execute(commandIndex, onComplete)); + + return true; + } + + /// + /// Stop all executing Blocks in this Flowchart. + /// + public virtual void StopAllBlocks() + { + var blocks = GetComponents(); + for (int i = 0; i < blocks.Length; i++) + { + var block = blocks[i]; + if (block.IsExecuting()) + { + block.Stop(); + } + } + } + + /// + /// Sends a message to this Flowchart only. + /// Any block with a matching MessageReceived event handler will start executing. + /// + public virtual void SendFungusMessage(string messageName) + { + var eventHandlers = GetComponents(); + for (int i = 0; i < eventHandlers.Length; i++) + { + var eventHandler = eventHandlers[i]; + eventHandler.OnSendFungusMessage(messageName); + } + } + + /// + /// Returns a new variable key that is guaranteed not to clash with any existing variable in the list. + /// + public virtual string GetUniqueVariableKey(string originalKey, Variable ignoreVariable = null) + { + int suffix = 0; + string baseKey = originalKey; + + // Only letters and digits allowed + char[] arr = baseKey.Where(c => (char.IsLetterOrDigit(c) || c == '_')).ToArray(); + baseKey = new string(arr); + + // No leading digits allowed + baseKey = baseKey.TrimStart('0','1','2','3','4','5','6','7','8','9'); + + // No empty keys allowed + if (baseKey.Length == 0) + { + baseKey = "Var"; + } + + string key = baseKey; + while (true) + { + bool collision = false; + for (int i = 0; i < variables.Count; i++) + { + var variable = variables[i]; + if (variable == null || variable == ignoreVariable || variable.Key == null) + { + continue; + } + if (variable.Key.Equals(key, StringComparison.CurrentCultureIgnoreCase)) + { + collision = true; + suffix++; + key = baseKey + suffix; + } + } + + if (!collision) + { + return key; + } + } + } + + /// + /// Returns a new Block key that is guaranteed not to clash with any existing Block in the Flowchart. + /// + public virtual string GetUniqueBlockKey(string originalKey, Block ignoreBlock = null) + { + int suffix = 0; + string baseKey = originalKey.Trim(); + + // No empty keys allowed + if (baseKey.Length == 0) + { + baseKey = FungusConstants.DefaultBlockName; + } + + var blocks = GetComponents(); + + string key = baseKey; + while (true) + { + bool collision = false; + for (int i = 0; i < blocks.Length; i++) + { + var block = blocks[i]; + if (block == ignoreBlock || block.BlockName == null) + { + continue; + } + if (block.BlockName.Equals(key, StringComparison.CurrentCultureIgnoreCase)) + { + collision = true; + suffix++; + key = baseKey + suffix; + } + } + + if (!collision) + { + return key; + } + } + } + + /// + /// Returns a new Label key that is guaranteed not to clash with any existing Label in the Block. + /// + public virtual string GetUniqueLabelKey(string originalKey, Label ignoreLabel) + { + int suffix = 0; + string baseKey = originalKey.Trim(); + + // No empty keys allowed + if (baseKey.Length == 0) + { + baseKey = "New Label"; + } + + var block = ignoreLabel.ParentBlock; + + string key = baseKey; + while (true) + { + bool collision = false; + var commandList = block.CommandList; + for (int i = 0; i < commandList.Count; i++) + { + var command = commandList[i]; + Label label = command as Label; + if (label == null || label == ignoreLabel) + { + continue; + } + if (label.Key.Equals(key, StringComparison.CurrentCultureIgnoreCase)) + { + collision = true; + suffix++; + key = baseKey + suffix; + } + } + + if (!collision) + { + return key; + } + } + } + + /// + /// Returns the variable with the specified key, or null if the key is not found. + /// You will need to cast the returned variable to the correct sub-type. + /// You can then access the variable's value using the Value property. e.g. + /// BooleanVariable boolVar = flowchart.GetVariable("MyBool") as BooleanVariable; + /// boolVar.Value = false; + /// + public Variable GetVariable(string key) + { + for (int i = 0; i < variables.Count; i++) + { + var variable = variables[i]; + if (variable != null && variable.Key == key) + { + return variable; + } + } + + return null; + } + + /// + /// Returns the variable with the specified key, or null if the key is not found. + /// You can then access the variable's value using the Value property. e.g. + /// BooleanVariable boolVar = flowchart.GetVariable("MyBool"); + /// boolVar.Value = false; + /// + public T GetVariable(string key) where T : Variable + { + for (int i = 0; i < variables.Count; i++) + { + var variable = variables[i]; + if (variable != null && variable.Key == key) + { + return variable as T; + } + } + + Debug.LogWarning("Variable " + key + " not found."); + return null; + } + + /// + /// Returns a list of variables matching the specified type. + /// + public virtual List GetVariables() where T: Variable + { + var varsFound = new List(); + + for (int i = 0; i < Variables.Count; i++) + { + var currentVar = Variables[i]; + if (currentVar is T) + varsFound.Add(currentVar as T); + } + + return varsFound; + } + + /// + /// Register a new variable with the Flowchart at runtime. + /// The variable should be added as a component on the Flowchart game object. + /// + public void SetVariable(string key, T newvariable) where T : Variable + { + for (int i = 0; i < variables.Count; i++) + { + var v = variables[i]; + if (v != null && v.Key == key) + { + T variable = v as T; + if (variable != null) + { + variable = newvariable; + return; + } + } + } + + Debug.LogWarning("Variable " + key + " not found."); + } + + /// + /// Checks if a given variable exists in the flowchart. + /// + public virtual bool HasVariable(string key) + { + for (int i = 0; i < variables.Count; i++) + { + var v = variables[i]; + if (v != null && v.Key == key) + { + return true; + } + } + return false; + } + + /// + /// Returns the list of variable names in the Flowchart. + /// + public virtual string[] GetVariableNames() + { + var vList = new string[variables.Count]; + + for (int i = 0; i < variables.Count; i++) + { + var v = variables[i]; + if (v != null) + { + vList[i] = v.Key; + } + } + return vList; + } + + /// + /// Gets a list of all variables with public scope in this Flowchart. + /// + public virtual List GetPublicVariables() + { + var publicVariables = new List(); + for (int i = 0; i < variables.Count; i++) + { + var v = variables[i]; + if (v != null && v.Scope == VariableScope.Public) + { + publicVariables.Add(v); + } + } + + return publicVariables; + } + + /// + /// Gets the value of a boolean variable. + /// Returns false if the variable key does not exist. + /// + public virtual bool GetBooleanVariable(string key) + { + var variable = GetVariable(key); + if(variable != null) + { + return GetVariable(key).Value; + } + else + { + return false; + } + } + + /// + /// Sets the value of a boolean variable. + /// The variable must already be added to the list of variables for this Flowchart. + /// + public virtual void SetBooleanVariable(string key, bool value) + { + var variable = GetVariable(key); + if(variable != null) + { + variable.Value = value; + } + } + + /// + /// Gets the value of an integer variable. + /// Returns 0 if the variable key does not exist. + /// + public virtual int GetIntegerVariable(string key) + { + var variable = GetVariable(key); + if (variable != null) + { + return GetVariable(key).Value; + } + else + { + return 0; + } + } + + /// + /// Sets the value of an integer variable. + /// The variable must already be added to the list of variables for this Flowchart. + /// + public virtual void SetIntegerVariable(string key, int value) + { + var variable = GetVariable(key); + if (variable != null) + { + variable.Value = value; + } + } + + /// + /// Gets the value of a float variable. + /// Returns 0 if the variable key does not exist. + /// + public virtual float GetFloatVariable(string key) + { + var variable = GetVariable(key); + if (variable != null) + { + return GetVariable(key).Value; + } + else + { + return 0f; + } + } + + /// + /// Sets the value of a float variable. + /// The variable must already be added to the list of variables for this Flowchart. + /// + public virtual void SetFloatVariable(string key, float value) + { + var variable = GetVariable(key); + if (variable != null) + { + variable.Value = value; + } + } + + /// + /// Gets the value of a string variable. + /// Returns the empty string if the variable key does not exist. + /// + public virtual string GetStringVariable(string key) + { + var variable = GetVariable(key); + if (variable != null) + { + return GetVariable(key).Value; + } + else + { + return ""; + } + } + + /// + /// Sets the value of a string variable. + /// The variable must already be added to the list of variables for this Flowchart. + /// + public virtual void SetStringVariable(string key, string value) + { + var variable = GetVariable(key); + if (variable != null) + { + variable.Value = value; + } + } + + /// + /// Gets the value of a GameObject variable. + /// Returns null if the variable key does not exist. + /// + public virtual GameObject GetGameObjectVariable(string key) + { + var variable = GetVariable(key); + + if (variable != null) + { + return GetVariable(key).Value; + } + else + { + return null; + } + } + + /// + /// Sets the value of a GameObject variable. + /// The variable must already be added to the list of variables for this Flowchart. + /// + public virtual void SetGameObjectVariable(string key, GameObject value) + { + var variable = GetVariable(key); + if (variable != null) + { + variable.Value = value; + } + } + + /// + /// Gets the value of a Transform variable. + /// Returns null if the variable key does not exist. + /// + public virtual Transform GetTransformVariable(string key) + { + var variable = GetVariable(key); + + if (variable != null) + { + return GetVariable(key).Value; + } + else + { + return null; + } + } + + /// + /// Sets the value of a Transform variable. + /// The variable must already be added to the list of variables for this Flowchart. + /// + public virtual void SetTransformVariable(string key, Transform value) + { + var variable = GetVariable(key); + if (variable != null) + { + variable.Value = value; + } + } + + /// + /// Set the block objects to be hidden or visible depending on the hideComponents property. + /// + public virtual void UpdateHideFlags() + { + if (hideComponents) + { + var blocks = GetComponents(); + for (int i = 0; i < blocks.Length; i++) + { + var block = blocks[i]; + block.hideFlags = HideFlags.HideInInspector; + if (block.gameObject != gameObject) + { + block.hideFlags = HideFlags.HideInHierarchy; + } + } + + var commands = GetComponents(); + for (int i = 0; i < commands.Length; i++) + { + var command = commands[i]; + command.hideFlags = HideFlags.HideInInspector; + } + + var eventHandlers = GetComponents(); + for (int i = 0; i < eventHandlers.Length; i++) + { + var eventHandler = eventHandlers[i]; + eventHandler.hideFlags = HideFlags.HideInInspector; + } + } + else + { + var monoBehaviours = GetComponents(); + for (int i = 0; i < monoBehaviours.Length; i++) + { + var monoBehaviour = monoBehaviours[i]; + if (monoBehaviour == null) + { + continue; + } + monoBehaviour.hideFlags = HideFlags.None; + monoBehaviour.gameObject.hideFlags = HideFlags.None; + } + } + } + + /// + /// Clears the list of selected commands. + /// + public virtual void ClearSelectedCommands() + { + selectedCommands.Clear(); +#if UNITY_EDITOR + SelectedCommandsStale = true; +#endif + } + + /// + /// Adds a command to the list of selected commands. + /// + public virtual void AddSelectedCommand(Command command) + { + if (!selectedCommands.Contains(command)) + { + selectedCommands.Add(command); +#if UNITY_EDITOR + SelectedCommandsStale = true; +#endif + } + } + + /// + /// Clears the list of selected blocks. + /// + public virtual void ClearSelectedBlocks() + { + if(selectedBlocks == null) + { + selectedBlocks = new List(); + } + + for (int i = 0; i < selectedBlocks.Count; i++) + { + var item = selectedBlocks[i]; + + if(item != null) + { + item.IsSelected = false; + } + } + selectedBlocks.Clear(); + } + + /// + /// Adds a block to the list of selected blocks. + /// + public virtual void AddSelectedBlock(Block block) + { + if (!selectedBlocks.Contains(block)) + { + block.IsSelected = true; + selectedBlocks.Add(block); + } + } + + public virtual bool DeselectBlock(Block block) + { + if (selectedBlocks.Contains(block)) + { + DeselectBlockNoCheck(block); + return true; + } + return false; + } + + public virtual void DeselectBlockNoCheck(Block b) + { + b.IsSelected = false; + selectedBlocks.Remove(b); + } + + public void UpdateSelectedCache() + { + selectedBlocks.Clear(); + var res = gameObject.GetComponents(); + selectedBlocks = res.Where(x => x.IsSelected).ToList(); + } + + public void ReverseUpdateSelectedCache() + { + for (int i = 0; i < selectedBlocks.Count; i++) + { + if(selectedBlocks[i] != null) + { + selectedBlocks[i].IsSelected = true; + } + } + } + + /// + /// Reset the commands and variables in the Flowchart. + /// + public virtual void Reset(bool resetCommands, bool resetVariables) + { + if (resetCommands) + { + var commands = GetComponents(); + for (int i = 0; i < commands.Length; i++) + { + var command = commands[i]; + command.OnReset(); + } + } + + if (resetVariables) + { + for (int i = 0; i < variables.Count; i++) + { + var variable = variables[i]; + variable.OnReset(); + } + } + } + + /// + /// Override this in a Flowchart subclass to filter which commands are shown in the Add Command list. + /// + public virtual bool IsCommandSupported(CommandInfoAttribute commandInfo) + { + for (int i = 0; i < hideCommands.Count; i++) + { + // Match on category or command name (case insensitive) + var key = hideCommands[i]; + if (String.Compare(commandInfo.Category, key, StringComparison.OrdinalIgnoreCase) == 0 || String.Compare(commandInfo.CommandName, key, StringComparison.OrdinalIgnoreCase) == 0) + { + return false; + } + } + + return true; + } + + /// + /// Returns true if there are any executing blocks in this Flowchart. + /// + public virtual bool HasExecutingBlocks() + { + var blocks = GetComponents(); + for (int i = 0; i < blocks.Length; i++) + { + var block = blocks[i]; + if (block.IsExecuting()) + { + return true; + } + } + return false; + } + + /// + /// Returns a list of all executing blocks in this Flowchart. + /// + public virtual List GetExecutingBlocks() + { + var executingBlocks = new List(); + var blocks = GetComponents(); + for (int i = 0; i < blocks.Length; i++) + { + var block = blocks[i]; + if (block.IsExecuting()) + { + executingBlocks.Add(block); + } + } + + return executingBlocks; + } + + /// + /// Substitute variables in the input text with the format {$VarName} + /// This will first match with private variables in this Flowchart, and then + /// with public variables in all Flowcharts in the scene (and any component + /// in the scene that implements StringSubstituter.ISubstitutionHandler). + /// + public virtual string SubstituteVariables(string input) + { + if (stringSubstituer == null) + { + stringSubstituer = new StringSubstituter(); + } + + // Use the string builder from StringSubstituter for efficiency. + StringBuilder sb = stringSubstituer._StringBuilder; + sb.Length = 0; + sb.Append(input); + + // Instantiate the regular expression object. + Regex r = new Regex(SubstituteVariableRegexString); + + bool changed = false; + + // Match the regular expression pattern against a text string. + var results = r.Matches(input); + for (int i = 0; i < results.Count; i++) + { + Match match = results[i]; + string key = match.Value.Substring(2, match.Value.Length - 3); + // Look for any matching private variables in this Flowchart first + for (int j = 0; j < variables.Count; j++) + { + var variable = variables[j]; + if (variable == null) + continue; + if (variable.Scope == VariableScope.Private && variable.Key == key) + { + string value = variable.ToString(); + sb.Replace(match.Value, value); + changed = true; + } + } + } + + // Now do all other substitutions in the scene + changed |= stringSubstituer.SubstituteStrings(sb); + + if (changed) + { + return sb.ToString(); + } + else + { + return input; + } + } + + public virtual void DetermineSubstituteVariables(string str, List vars) + { + Regex r = new Regex(Flowchart.SubstituteVariableRegexString); + + // Match the regular expression pattern against a text string. + var results = r.Matches(str); + for (int i = 0; i < results.Count; i++) + { + var match = results[i]; + var v = GetVariable(match.Value.Substring(2, match.Value.Length - 3)); + if (v != null) + { + vars.Add(v); + } + } + } + + #endregion + + #region IStringSubstituter implementation + + /// + /// Implementation of StringSubstituter.ISubstitutionHandler which matches any public variable in the Flowchart. + /// To perform full variable substitution with all substitution handlers in the scene, you should + /// use the SubstituteVariables() method instead. + /// + [MoonSharp.Interpreter.MoonSharpHidden] + public virtual bool SubstituteStrings(StringBuilder input) + { + // Instantiate the regular expression object. + Regex r = new Regex(SubstituteVariableRegexString); + + bool modified = false; + + // Match the regular expression pattern against a text string. + var results = r.Matches(input.ToString()); + for (int i = 0; i < results.Count; i++) + { + Match match = results[i]; + string key = match.Value.Substring(2, match.Value.Length - 3); + // Look for any matching public variables in this Flowchart + for (int j = 0; j < variables.Count; j++) + { + var variable = variables[j]; + if (variable == null) + { + continue; + } + if (variable.Scope == VariableScope.Public && variable.Key == key) + { + string value = variable.ToString(); + input.Replace(match.Value, value); + modified = true; + } + } + } + + return modified; + } + + #endregion + } +} diff --git a/Assets/Fungus/Scripts/Components/Flowchart.cs.meta b/Assets/Fungus/Scripts/Components/Flowchart.cs.meta new file mode 100644 index 0000000..c6e53bd --- /dev/null +++ b/Assets/Fungus/Scripts/Components/Flowchart.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 7a334fe2ffb574b3583ff3b18b4792d3 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Fungus/Scripts/Components/FungusManager.cs b/Assets/Fungus/Scripts/Components/FungusManager.cs new file mode 100644 index 0000000..477ef9b --- /dev/null +++ b/Assets/Fungus/Scripts/Components/FungusManager.cs @@ -0,0 +1,121 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; +using System.Collections; + +namespace Fungus +{ + /// + /// Fungus manager singleton. Manages access to all Fungus singletons in a consistent manner. + /// + [RequireComponent(typeof(CameraManager))] + [RequireComponent(typeof(MusicManager))] + [RequireComponent(typeof(EventDispatcher))] + [RequireComponent(typeof(GlobalVariables))] +#if UNITY_5_3_OR_NEWER + [RequireComponent(typeof(SaveManager))] + [RequireComponent(typeof(NarrativeLog))] + #endif + public sealed class FungusManager : MonoBehaviour + { + volatile static FungusManager instance; // The keyword "volatile" is friendly to the multi-thread. + static bool applicationIsQuitting = false; + readonly static object _lock = new object(); // The keyword "readonly" is friendly to the multi-thread. + + void Awake() + { + CameraManager = GetComponent(); + MusicManager = GetComponent(); + EventDispatcher = GetComponent(); + GlobalVariables = GetComponent(); +#if UNITY_5_3_OR_NEWER + SaveManager = GetComponent(); + NarrativeLog = GetComponent(); + #endif + } + + /// + /// When Unity quits, it destroys objects in a random order. + /// In principle, a Singleton is only destroyed when application quits. + /// If any script calls Instance after it have been destroyed, + /// it will create a buggy ghost object that will stay on the Editor scene + /// even after stopping playing the Application. Really bad! + /// So, this was made to be sure we're not creating that buggy ghost object. + /// + void OnDestroy () + { + applicationIsQuitting = true; + } + + #region Public methods + + /// + /// Gets the camera manager singleton instance. + /// + public CameraManager CameraManager { get; private set; } + + /// + /// Gets the music manager singleton instance. + /// + public MusicManager MusicManager { get; private set; } + + /// + /// Gets the event dispatcher singleton instance. + /// + public EventDispatcher EventDispatcher { get; private set; } + + /// + /// Gets the global variable singleton instance. + /// + public GlobalVariables GlobalVariables { get; private set; } + +#if UNITY_5_3_OR_NEWER + /// + /// Gets the save manager singleton instance. + /// + public SaveManager SaveManager { get; private set; } + + /// + /// Gets the history manager singleton instance. + /// + public NarrativeLog NarrativeLog { get; private set; } + + #endif + + /// + /// Gets the FungusManager singleton instance. + /// + public static FungusManager Instance + { + get + { + if (applicationIsQuitting) + { + Debug.LogWarning("FungusManager.Instance() was called while application is quitting. Returning null instead."); + return null; + } + + // Use "double checked locking" algorithm to implement the singleton for this "FungusManager" class, which can improve performance. + if (instance == null) + { + lock (_lock) + { + if (instance == null) + { + var go = new GameObject(); + go.name = "FungusManager"; + DontDestroyOnLoad(go); + instance = go.AddComponent(); + } + + } + } + + return instance; + } + } + + #endregion + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Components/FungusManager.cs.meta b/Assets/Fungus/Scripts/Components/FungusManager.cs.meta new file mode 100644 index 0000000..e5c9214 --- /dev/null +++ b/Assets/Fungus/Scripts/Components/FungusManager.cs.meta @@ -0,0 +1,12 @@ +fileFormatVersion: 2 +guid: fa59a268bb22b4646bd9a89fa66582b1 +timeCreated: 1475164406 +licenseType: Store +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Components/FungusState.cs b/Assets/Fungus/Scripts/Components/FungusState.cs new file mode 100644 index 0000000..4d2a351 --- /dev/null +++ b/Assets/Fungus/Scripts/Components/FungusState.cs @@ -0,0 +1,26 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; + +namespace Fungus +{ + /// + /// Used by the Flowchart window to serialize the currently active Flowchart object + /// so that the same Flowchart can be displayed while editing & playing. + /// + [AddComponentMenu("")] + public class FungusState : MonoBehaviour + { + [SerializeField] protected Flowchart selectedFlowchart; + + #region Public members + + /// + /// The currently selected Flowchart. + /// + public virtual Flowchart SelectedFlowchart { get { return selectedFlowchart; } set { selectedFlowchart = value; } } + + #endregion + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Components/FungusState.cs.meta b/Assets/Fungus/Scripts/Components/FungusState.cs.meta new file mode 100644 index 0000000..73f9adb --- /dev/null +++ b/Assets/Fungus/Scripts/Components/FungusState.cs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 61dddfdc5e0e44ca298d8f46f7f5a915 +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: diff --git a/Assets/Fungus/Scripts/Components/Localization.cs b/Assets/Fungus/Scripts/Components/Localization.cs new file mode 100644 index 0000000..f8c296b --- /dev/null +++ b/Assets/Fungus/Scripts/Components/Localization.cs @@ -0,0 +1,587 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; +#if UNITY_EDITOR +using UnityEditor; +#endif +using System.Collections.Generic; +using System.Text.RegularExpressions; +using System.Text; +using Ideafixxxer.CsvParser; + +namespace Fungus +{ + /// + /// Multi-language localization support. + /// + public class Localization : MonoBehaviour, ISubstitutionHandler + { + /// + /// Temp storage for a single item of standard text and its localizations. + /// + protected class TextItem + { + public string description = ""; + public string standardText = ""; + public Dictionary localizedStrings = new Dictionary(); + } + + [Tooltip("Language to use at startup, usually defined by a two letter language code (e.g DE = German)")] + [SerializeField] protected string activeLanguage = ""; + + [Tooltip("CSV file containing localization data which can be easily edited in a spreadsheet tool")] + [SerializeField] protected TextAsset localizationFile; + + protected Dictionary localizeableObjects = new Dictionary(); + + protected string notificationText = ""; + + protected bool initialized; + + protected static Dictionary localizedStrings = new Dictionary(); + + #if UNITY_5_4_OR_NEWER + #else + public virtual void OnLevelWasLoaded(int level) + { + LevelWasLoaded(); + } + #endif + + protected virtual void LevelWasLoaded() + { + // Check if a language has been selected using the Set Language command in a previous scene. + if (SetLanguage.mostRecentLanguage != "") + { + // This language will be used when Start() is called + activeLanguage = SetLanguage.mostRecentLanguage; + } + } + + private void SceneManager_activeSceneChanged(UnityEngine.SceneManagement.Scene arg0, UnityEngine.SceneManagement.Scene arg1) + { + LevelWasLoaded(); + } + + protected virtual void OnEnable() + { + StringSubstituter.RegisterHandler(this); + #if UNITY_5_4_OR_NEWER + UnityEngine.SceneManagement.SceneManager.activeSceneChanged += SceneManager_activeSceneChanged; + #endif + } + + protected virtual void OnDisable() + { + StringSubstituter.UnregisterHandler(this); + #if UNITY_5_4_OR_NEWER + UnityEngine.SceneManagement.SceneManager.activeSceneChanged -= SceneManager_activeSceneChanged; + #endif + } + + protected virtual void Start() + { + Init(); + } + + /// + /// String subsitution can happen during the Start of another component, so we + /// may need to call Init() from other methods. + /// + protected virtual void Init() + { + if (initialized) + { + return; + } + + CacheLocalizeableObjects(); + + if (localizationFile != null && + localizationFile.text.Length > 0) + { + SetActiveLanguage(activeLanguage); + } + + initialized = true; + } + + // Build a cache of all the localizeable objects in the scene + protected virtual void CacheLocalizeableObjects() + { + UnityEngine.Object[] objects = Resources.FindObjectsOfTypeAll(typeof(Component)); + for (int i = 0; i < objects.Length; i++) + { + var o = objects[i]; + ILocalizable localizable = o as ILocalizable; + if (localizable != null) + { + localizeableObjects[localizable.GetStringId()] = localizable; + } + } + } + + /// + /// Builds a dictionary of localizable text items in the scene. + /// + protected Dictionary FindTextItems() + { + Dictionary textItems = new Dictionary(); + + // Add localizable commands in same order as command list to make it + // easier to localise / edit standard text. + var flowcharts = GameObject.FindObjectsOfType(); + for (int i = 0; i < flowcharts.Length; i++) + { + var flowchart = flowcharts[i]; + var blocks = flowchart.GetComponents(); + + for (int j = 0; j < blocks.Length; j++) + { + var block = blocks[j]; + var commandList = block.CommandList; + for (int k = 0; k < commandList.Count; k++) + { + var command = commandList[k]; + ILocalizable localizable = command as ILocalizable; + if (localizable != null) + { + TextItem textItem = new TextItem(); + textItem.standardText = localizable.GetStandardText(); + textItem.description = localizable.GetDescription(); + textItems[localizable.GetStringId()] = textItem; + } + } + } + } + + // Add everything else that's localizable (including inactive objects) + UnityEngine.Object[] objects = Resources.FindObjectsOfTypeAll(typeof(Component)); + for (int i = 0; i < objects.Length; i++) + { + var o = objects[i]; + ILocalizable localizable = o as ILocalizable; + if (localizable != null) + { + string stringId = localizable.GetStringId(); + if (textItems.ContainsKey(stringId)) + { + // Already added + continue; + } + TextItem textItem = new TextItem(); + textItem.standardText = localizable.GetStandardText(); + textItem.description = localizable.GetDescription(); + textItems[stringId] = textItem; + } + } + + return textItems; + } + + /// + /// Adds localized strings from CSV file data to a dictionary of text items in the scene. + /// + protected virtual void AddCSVDataItems(Dictionary textItems, string csvData) + { + CsvParser csvParser = new CsvParser(); + string[][] csvTable = csvParser.Parse(csvData); + + if (csvTable.Length <= 1) + { + // No data rows in file + return; + } + + // Parse header row + string[] columnNames = csvTable[0]; + + for (int i = 1; i < csvTable.Length; ++i) + { + string[] fields = csvTable[i]; + if (fields.Length < 3) + { + // No standard text or localized string fields present + continue; + } + + string stringId = fields[0]; + + if (!textItems.ContainsKey(stringId)) + { + if (stringId.StartsWith("CHARACTER.") || + stringId.StartsWith("SAY.") || + stringId.StartsWith("MENU.") || + stringId.StartsWith("WRITE.") || + stringId.StartsWith("SETTEXT.")) + { + // If it's a 'built-in' type this probably means that item has been deleted from its flowchart, + // so there's no need to add a text item for it. + continue; + } + + // Key not found. Assume it's a custom string that we want to retain, so add a text item for it. + TextItem newTextItem = new TextItem(); + newTextItem.description = CSVSupport.Unescape(fields[1]); + newTextItem.standardText = CSVSupport.Unescape(fields[2]); + textItems[stringId] = newTextItem; + } + + TextItem textItem = textItems[stringId]; + + for (int j = 3; j < fields.Length; ++j) + { + if (j >= columnNames.Length) + { + continue; + } + string languageCode = columnNames[j]; + string languageEntry = CSVSupport.Unescape(fields[j]); + + if (languageEntry.Length > 0) + { + textItem.localizedStrings[languageCode] = languageEntry; + } + } + } + } + + #region Public members + + /// + /// Looks up the specified string in the localized strings table. + /// For this to work, a localization file and active language must have been set previously. + /// Return null if the string is not found. + /// + public static string GetLocalizedString(string stringId) + { + if (localizedStrings == null) + { + return null; + } + + if (localizedStrings.ContainsKey(stringId)) + { + return localizedStrings[stringId]; + } + + return null; + } + + /// + /// Language to use at startup, usually defined by a two letter language code (e.g DE = German). + /// + public virtual string ActiveLanguage { get { return activeLanguage; } } + + /// + /// CSV file containing localization data which can be easily edited in a spreadsheet tool. + /// + public virtual TextAsset LocalizationFile { get { return localizationFile; } set { localizationFile = value; } } + + /// + /// Stores any notification message from export / import methods. + /// + public virtual string NotificationText { get { return notificationText; } set { notificationText = value; } } + + /// + /// Clears the cache of localizeable objects. + /// + public virtual void ClearLocalizeableCache() + { + localizeableObjects.Clear(); + } + + /// + /// Convert all text items and localized strings to an easy to edit CSV format. + /// + public virtual string GetCSVData() + { + // Collect all the text items present in the scene + Dictionary textItems = FindTextItems(); + + // Update text items with localization data from CSV file + if (localizationFile != null && + localizationFile.text.Length > 0) + { + AddCSVDataItems(textItems, localizationFile.text); + } + + // Build CSV header row and a list of the language codes currently in use + string csvHeader = "Key,Description,Standard"; + var languageCodes = new List(); + var values = textItems.Values; + foreach (var textItem in values) + { + foreach (string languageCode in textItem.localizedStrings.Keys) + { + if (!languageCodes.Contains(languageCode)) + { + languageCodes.Add(languageCode); + csvHeader += "," + languageCode; + } + } + } + + // Build the CSV file using collected text items + int rowCount = 0; + string csvData = csvHeader + "\n"; + var keys = textItems.Keys; + foreach (var stringId in keys) + { + TextItem textItem = textItems[stringId]; + + string row = CSVSupport.Escape(stringId); + row += "," + CSVSupport.Escape(textItem.description); + row += "," + CSVSupport.Escape(textItem.standardText); + + for (int i = 0; i < languageCodes.Count; i++) + { + var languageCode = languageCodes[i]; + if (textItem.localizedStrings.ContainsKey(languageCode)) + { + row += "," + CSVSupport.Escape(textItem.localizedStrings[languageCode]); + } + else + { + row += ","; + // Empty field + } + } + + csvData += row + "\n"; + rowCount++; + } + + notificationText = "Exported " + rowCount + " localization text items."; + + return csvData; + } + + /// + /// Scan a localization CSV file and copies the strings for the specified language code + /// into the text properties of the appropriate scene objects. + /// + public virtual void SetActiveLanguage(string languageCode, bool forceUpdateSceneText = false) + { + if (!Application.isPlaying) + { + // This function should only ever be called when the game is playing (not in editor). + return; + } + + if (localizationFile == null) + { + // No localization file set + return; + } + + localizedStrings.Clear(); + + CsvParser csvParser = new CsvParser(); + string[][] csvTable = csvParser.Parse(localizationFile.text); + + if (csvTable.Length <= 1) + { + // No data rows in file + return; + } + + // Parse header row + string[] columnNames = csvTable[0]; + + if (columnNames.Length < 3) + { + // No languages defined in CSV file + return; + } + + // First assume standard text column and then look for a matching language column + int languageIndex = 2; + for (int i = 3; i < columnNames.Length; ++i) + { + if (columnNames[i] == languageCode) + { + languageIndex = i; + break; + } + } + + if (languageIndex == 2) + { + // Using standard text column + // Add all strings to the localized strings dict, but don't replace standard text in the scene. + // This allows string substitution to work for both standard and localized text strings. + for (int i = 1; i < csvTable.Length; ++i) + { + string[] fields = csvTable[i]; + if (fields.Length < 3) + { + continue; + } + + localizedStrings[fields[0]] = fields[languageIndex]; + } + + // Early out unless we've been told to force the scene text to update. + // This happens when the Set Language command is used to reset back to the standard language. + if (!forceUpdateSceneText) + { + return; + } + } + + // Using a localized language text column + // 1. Add all localized text to the localized strings dict + // 2. Update all scene text properties with localized versions + for (int i = 1; i < csvTable.Length; ++i) + { + string[] fields = csvTable[i]; + + if (fields.Length < languageIndex + 1) + { + continue; + } + + string stringId = fields[0]; + string languageEntry = CSVSupport.Unescape(fields[languageIndex]); + + if (languageEntry.Length > 0) + { + localizedStrings[stringId] = languageEntry; + PopulateTextProperty(stringId, languageEntry); + } + } + } + + /// + /// Populates the text property of a single scene object with a new text value. + /// + public virtual bool PopulateTextProperty(string stringId, string newText) + { + // Ensure that all localizeable objects have been cached + if (localizeableObjects.Count == 0) + { + CacheLocalizeableObjects(); + } + + ILocalizable localizable = null; + localizeableObjects.TryGetValue(stringId, out localizable); + if (localizable != null) + { + localizable.SetStandardText(newText); + return true; + } + + return false; + } + + /// + /// Returns all standard text for localizeable text in the scene using an + /// easy to edit custom text format. + /// + public virtual string GetStandardText() + { + // Collect all the text items present in the scene + Dictionary textItems = FindTextItems(); + + string textData = ""; + int rowCount = 0; + var keys = textItems.Keys; + foreach (var stringId in keys) + { + TextItem languageItem = textItems[stringId]; + + textData += "#" + stringId + "\n"; + textData += languageItem.standardText.Trim() + "\n\n"; + rowCount++; + } + + notificationText = "Exported " + rowCount + " standard text items."; + + return textData; + } + + /// + /// Sets standard text on scene objects by parsing a text data file. + /// + public virtual void SetStandardText(string textData) + { + var lines = textData.Split('\n'); + + int updatedCount = 0; + + string stringId = ""; + string buffer = ""; + for (int i = 0; i < lines.Length; i++) + { + // Check for string id line + var line = lines[i]; + if (line.StartsWith("#")) + { + if (stringId.Length > 0) + { + // Write buffered text to the appropriate text property + if (PopulateTextProperty(stringId, buffer.Trim())) + { + updatedCount++; + } + } + // Set the string id for the follow text lines + stringId = line.Substring(1, line.Length - 1); + buffer = ""; + } + else + { + buffer += line + "\n"; + } + } + + // Handle last buffered entry + if (stringId.Length > 0) + { + if (PopulateTextProperty(stringId, buffer.Trim())) + { + updatedCount++; + } + } + + notificationText = "Updated " + updatedCount + " standard text items."; + } + + #endregion + + #region StringSubstituter.ISubstitutionHandler imlpementation + + public virtual bool SubstituteStrings(StringBuilder input) + { + // This method could be called from the Start method of another component, so we + // may need to initilize the localization system. + Init(); + + // Instantiate the regular expression object. + Regex r = new Regex(Flowchart.SubstituteVariableRegexString); + + bool modified = false; + + // Match the regular expression pattern against a text string. + var results = r.Matches(input.ToString()); + for (int i = 0; i < results.Count; i++) + { + Match match = results[i]; + string key = match.Value.Substring(2, match.Value.Length - 3); + // Next look for matching localized string + string localizedString = Localization.GetLocalizedString(key); + if (localizedString != null) + { + input.Replace(match.Value, localizedString); + modified = true; + } + } + + return modified; + } + + #endregion + } +} \ No newline at end of file diff --git a/Assets/Fungus/Scripts/Components/Localization.cs.meta b/Assets/Fungus/Scripts/Components/Localization.cs.meta new file mode 100644 index 0000000..69f77a4 --- /dev/null +++ b/Assets/Fungus/Scripts/Components/Localization.cs.meta @@ -0,0 +1,12 @@ +fileFormatVersion: 2 +guid: e5724422a635e425bae0af9ffe2615d6 +timeCreated: 1427886378 +licenseType: Store +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Scripts/Components/MenuDialog.cs b/Assets/Fungus/Scripts/Components/MenuDialog.cs new file mode 100644 index 0000000..f2f2be5 --- /dev/null +++ b/Assets/Fungus/Scripts/Components/MenuDialog.cs @@ -0,0 +1,431 @@ +// This code is part of the Fungus library (https://github.com/snozbot/fungus) +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; +using UnityEngine.UI; +using System.Collections; +using UnityEngine.EventSystems; +using System.Linq; +using MoonSharp.Interpreter; + +namespace Fungus +{ + /// + /// Presents multiple choice buttons to the players. + /// + public class MenuDialog : MonoBehaviour + { + [Tooltip("Automatically select the first interactable button when the menu is shown.")] + [SerializeField] protected bool autoSelectFirstButton = false; + + protected Button[] cachedButtons; + + protected Slider cachedSlider; + private int nextOptionIndex; + + #region Public members + + /// + /// Currently active Menu Dialog used to display Menu options + /// + public static MenuDialog ActiveMenuDialog { get; set; } + + /// + /// A cached list of button objects in the menu dialog. + /// + /// The cached buttons. + public virtual Button[] CachedButtons { get { return cachedButtons; } } + + /// + /// A cached slider object used for the timer in the menu dialog. + /// + /// The cached slider. + public virtual Slider CachedSlider { get { return cachedSlider; } } + + /// + /// Sets the active state of the Menu Dialog gameobject. + /// + public virtual void SetActive(bool state) + { + gameObject.SetActive(state); + } + + + + /// + /// Returns a menu dialog by searching for one in the scene or creating one if none exists. + /// + public static MenuDialog GetMenuDialog() + { + if (ActiveMenuDialog == null) + { + // Use first Menu Dialog found in the scene (if any) + var md = GameObject.FindObjectOfType(); + if (md != null) + { + ActiveMenuDialog = md; + } + + if (ActiveMenuDialog == null) + { + // Auto spawn a menu dialog object from the prefab + GameObject prefab = Resources.Load("Prefabs/MenuDialog"); + if (prefab != null) + { + GameObject go = Instantiate(prefab) as GameObject; + go.SetActive(false); + go.name = "MenuDialog"; + ActiveMenuDialog = go.GetComponent(); + } + } + } + + return ActiveMenuDialog; + } + + protected virtual void Awake() + { + Button[] optionButtons = GetComponentsInChildren