From 8ebad6ef6ae5b2c878bee8b8dafd73823b690a85 Mon Sep 17 00:00:00 2001 From: Chris Gregan Date: Mon, 9 May 2016 08:21:17 +0100 Subject: [PATCH] Added more examples --- .../FungusLua/Bindings/SpawnPrefab.unity | 398 +++++++++++ .../FungusLua/Bindings/SpawnPrefab.unity.meta | 8 + .../FungusLua/Bindings/TestSprite.prefab | 104 +++ .../FungusLua/Bindings/TestSprite.prefab.meta | 8 + .../FungusExamples/FungusLua/Flowchart.meta | 9 + .../FungusLua/Flowchart/Variables.unity | 668 ++++++++++++++++++ .../FungusLua/Flowchart/Variables.unity.meta | 8 + Assets/FungusExamples/FungusLua/Trigger.meta | 9 + .../FungusLua/{ => Trigger}/Trigger.unity | 101 +-- .../{ => Trigger}/Trigger.unity.meta | 0 10 files changed, 1265 insertions(+), 48 deletions(-) create mode 100644 Assets/FungusExamples/FungusLua/Bindings/SpawnPrefab.unity create mode 100644 Assets/FungusExamples/FungusLua/Bindings/SpawnPrefab.unity.meta create mode 100644 Assets/FungusExamples/FungusLua/Bindings/TestSprite.prefab create mode 100644 Assets/FungusExamples/FungusLua/Bindings/TestSprite.prefab.meta create mode 100644 Assets/FungusExamples/FungusLua/Flowchart.meta create mode 100644 Assets/FungusExamples/FungusLua/Flowchart/Variables.unity create mode 100644 Assets/FungusExamples/FungusLua/Flowchart/Variables.unity.meta create mode 100644 Assets/FungusExamples/FungusLua/Trigger.meta rename Assets/FungusExamples/FungusLua/{ => Trigger}/Trigger.unity (96%) rename Assets/FungusExamples/FungusLua/{ => Trigger}/Trigger.unity.meta (100%) diff --git a/Assets/FungusExamples/FungusLua/Bindings/SpawnPrefab.unity b/Assets/FungusExamples/FungusLua/Bindings/SpawnPrefab.unity new file mode 100644 index 00000000..386d5e7a --- /dev/null +++ b/Assets/FungusExamples/FungusLua/Bindings/SpawnPrefab.unity @@ -0,0 +1,398 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!29 &1 +SceneSettings: + m_ObjectHideFlags: 0 + m_PVSData: + m_PVSObjectsArray: [] + m_PVSPortalsArray: [] + m_OcclusionBakeSettings: + smallestOccluder: 5 + smallestHole: 0.25 + backfaceThreshold: 100 +--- !u!104 &2 +RenderSettings: + m_ObjectHideFlags: 0 + serializedVersion: 6 + m_Fog: 0 + m_FogColor: {r: 0.5, g: 0.5, b: 0.5, a: 1} + m_FogMode: 3 + m_FogDensity: 0.01 + m_LinearFogStart: 0 + m_LinearFogEnd: 300 + m_AmbientSkyColor: {r: 0.212, g: 0.227, b: 0.259, a: 1} + m_AmbientEquatorColor: {r: 0.114, g: 0.125, b: 0.133, a: 1} + m_AmbientGroundColor: {r: 0.047, g: 0.043, b: 0.035, a: 1} + m_AmbientIntensity: 1 + m_AmbientMode: 3 + m_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} +--- !u!157 &3 +LightmapSettings: + m_ObjectHideFlags: 0 + serializedVersion: 6 + m_GIWorkflowMode: 1 + m_LightmapsMode: 1 + m_GISettings: + serializedVersion: 2 + m_BounceScale: 1 + m_IndirectOutputScale: 1 + m_AlbedoBoost: 1 + m_TemporalCoherenceThreshold: 1 + m_EnvironmentLightingMode: 0 + m_EnableBakedLightmaps: 0 + m_EnableRealtimeLightmaps: 0 + m_LightmapEditorSettings: + serializedVersion: 3 + m_Resolution: 2 + m_BakeResolution: 40 + m_TextureWidth: 1024 + m_TextureHeight: 1024 + m_AOMaxDistance: 1 + m_Padding: 2 + m_CompAOExponent: 0 + m_LightmapParameters: {fileID: 0} + m_TextureCompression: 1 + m_FinalGather: 0 + m_FinalGatherRayCount: 1024 + m_ReflectionCompression: 2 + m_LightingDataAsset: {fileID: 0} + m_RuntimeCPUUsage: 25 +--- !u!196 &4 +NavMeshSettings: + serializedVersion: 2 + m_ObjectHideFlags: 0 + m_BuildSettings: + serializedVersion: 2 + agentRadius: 0.5 + agentHeight: 2 + agentSlope: 45 + agentClimb: 0.4 + ledgeDropHeight: 0 + maxJumpAcrossDistance: 0 + accuratePlacement: 0 + minRegionArea: 2 + cellSize: 0.16666667 + manualCellSize: 0 + m_NavMeshData: {fileID: 0} +--- !u!1 &520292961 +GameObject: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + serializedVersion: 4 + m_Component: + - 4: {fileID: 520292966} + - 20: {fileID: 520292965} + - 92: {fileID: 520292964} + - 124: {fileID: 520292963} + - 81: {fileID: 520292962} + 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 &520292962 +AudioListener: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_GameObject: {fileID: 520292961} + m_Enabled: 1 +--- !u!124 &520292963 +Behaviour: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_GameObject: {fileID: 520292961} + m_Enabled: 1 +--- !u!92 &520292964 +Behaviour: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_GameObject: {fileID: 520292961} + m_Enabled: 1 +--- !u!20 &520292965 +Camera: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_GameObject: {fileID: 520292961} + m_Enabled: 1 + serializedVersion: 2 + m_ClearFlags: 1 + m_BackGroundColor: {r: 0.19215687, g: 0.3019608, b: 0.4745098, a: 0.019607844} + m_NormalizedViewPortRect: + serializedVersion: 2 + x: 0 + y: 0 + width: 1 + height: 1 + near clip plane: 0.3 + far clip plane: 1000 + field of view: 60 + orthographic: 1 + orthographic size: 5 + m_Depth: -1 + m_CullingMask: + serializedVersion: 2 + m_Bits: 4294967295 + m_RenderingPath: -1 + m_TargetTexture: {fileID: 0} + m_TargetDisplay: 0 + m_TargetEye: 3 + m_HDR: 0 + m_OcclusionCulling: 1 + m_StereoConvergence: 10 + m_StereoSeparation: 0.022 + m_StereoMirrorMode: 0 +--- !u!4 &520292966 +Transform: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_GameObject: {fileID: 520292961} + 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 +--- !u!1 &866988388 +GameObject: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 179118, guid: 3ddf9f33ba98e4b31ba4d2b9722bea00, type: 2} + m_PrefabInternal: {fileID: 0} + serializedVersion: 4 + m_Component: + - 4: {fileID: 866988394} + - 114: {fileID: 866988393} + - 114: {fileID: 866988392} + - 114: {fileID: 866988391} + - 114: {fileID: 866988390} + - 114: {fileID: 866988389} + m_Layer: 0 + m_Name: Lua + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!114 &866988389 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 11437776, guid: 3ddf9f33ba98e4b31ba4d2b9722bea00, + type: 2} + m_PrefabInternal: {fileID: 0} + m_GameObject: {fileID: 866988388} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: c10f0b861365b42b0928858f7b086ff3, type: 3} + m_Name: + m_EditorClassIdentifier: + fungusModule: 0 + activeLanguage: en + stringTables: [] + registerTypes: + - {fileID: 4900000, guid: 9c3ab7a98d51241bbb499643399fa761, type: 3} + - {fileID: 4900000, guid: 93fddea8208764a2dbb189cc238aed40, type: 3} +--- !u!114 &866988390 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 11483650, guid: 3ddf9f33ba98e4b31ba4d2b9722bea00, + type: 2} + m_PrefabInternal: {fileID: 0} + m_GameObject: {fileID: 866988388} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: ba19c26c1ba7243d2b57ebc4329cc7c6, type: 3} + m_Name: + m_EditorClassIdentifier: + remoteDebugger: 0 +--- !u!114 &866988391 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 11499092, guid: 3ddf9f33ba98e4b31ba4d2b9722bea00, + type: 2} + m_PrefabInternal: {fileID: 0} + m_GameObject: {fileID: 866988388} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 4cc8a659e950044b69d7c62696c36962, type: 3} + m_Name: + m_EditorClassIdentifier: + allEnvironments: 0 + luaEnvironment: {fileID: 866988390} + tableName: + registerTypes: 1 + boundTypes: + - UnityEngine.GameObject, UnityEngine, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null + - UnityEngine.PrimitiveType, UnityEngine, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null + - UnityEngine.Component, UnityEngine, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null + - System.Type, mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + - System.Boolean, mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + - System.Int32, mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + - UnityEngine.SendMessageOptions, UnityEngine, Version=0.0.0.0, Culture=neutral, + PublicKeyToken=null + - UnityEngine.SceneManagement.Scene, UnityEngine, Version=0.0.0.0, Culture=neutral, + PublicKeyToken=null + - UnityEngine.Object, UnityEngine, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null + - System.Single, mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + boundObjects: + - key: testsprite + obj: {fileID: 120068, guid: 78100db42249d407787823d1e5719214, type: 2} + component: {fileID: 0} +--- !u!114 &866988392 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 11417560, guid: 3ddf9f33ba98e4b31ba4d2b9722bea00, + type: 2} + m_PrefabInternal: {fileID: 0} + m_GameObject: {fileID: 866988388} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 446caeace65234baaacd52095d24f101, type: 3} + m_Name: + m_EditorClassIdentifier: + luaEnvironment: {fileID: 866988390} + luaFile: {fileID: 0} + luaScript: luautils.Instantiate(testsprite) + runAsCoroutine: 1 +--- !u!114 &866988393 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 11415008, guid: 3ddf9f33ba98e4b31ba4d2b9722bea00, + type: 2} + m_PrefabInternal: {fileID: 0} + m_GameObject: {fileID: 866988388} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 6ee79785811ba49399c1b56d7309e3df, type: 3} + m_Name: + m_EditorClassIdentifier: + executeAfterTime: 1 + repeatExecuteTime: 1 + repeatEveryTime: 0.5 + executeAfterFrames: 1 + repeatExecuteFrame: 1 + repeatEveryFrame: 1 + hasFailed: 0 + executeMethods: 1 + executeMethodName: OnExecute +--- !u!4 &866988394 +Transform: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 466848, guid: 3ddf9f33ba98e4b31ba4d2b9722bea00, type: 2} + m_PrefabInternal: {fileID: 0} + m_GameObject: {fileID: 866988388} + 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: 2 +--- !u!1 &1842064384 +GameObject: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + serializedVersion: 4 + m_Component: + - 4: {fileID: 1842064386} + - 114: {fileID: 1842064385} + m_Layer: 0 + m_Name: InfoText + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!114 &1842064385 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_GameObject: {fileID: 1842064384} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 8c0cbb63e218a4414a796a60ffe37dd3, type: 3} + m_Name: + m_EditorClassIdentifier: + info: 'This example shows how to instantiate a prefab from Lua. + + + In the LuaBindings component of the Lua object, a binding has been added to a + prefab asset with the key ''testsprite'' + + + The Execute Handler has been set to execute every 0.5 seconds, and we use the + luautils.Instantiate() method to instantiate the prefab gameobject. + + + There''s also a luautils.Spawn() method if you want to spawn a prefab just from + the asset name, see the docs for details.' +--- !u!4 &1842064386 +Transform: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_GameObject: {fileID: 1842064384} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: 0, y: 0, z: 0} + m_LocalScale: {x: 1, y: 1, z: 1} + m_Children: [] + m_Father: {fileID: 0} + m_RootOrder: 3 +--- !u!1 &1943384371 +GameObject: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + serializedVersion: 4 + m_Component: + - 4: {fileID: 1943384373} + - 114: {fileID: 1943384372} + m_Layer: 0 + m_Name: _FungusState + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!114 &1943384372 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_GameObject: {fileID: 1943384371} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 61dddfdc5e0e44ca298d8f46f7f5a915, type: 3} + m_Name: + m_EditorClassIdentifier: + selectedFlowchart: {fileID: 0} +--- !u!4 &1943384373 +Transform: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_GameObject: {fileID: 1943384371} + 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: 1 diff --git a/Assets/FungusExamples/FungusLua/Bindings/SpawnPrefab.unity.meta b/Assets/FungusExamples/FungusLua/Bindings/SpawnPrefab.unity.meta new file mode 100644 index 00000000..4c5eaa81 --- /dev/null +++ b/Assets/FungusExamples/FungusLua/Bindings/SpawnPrefab.unity.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 9b7832786954140ba9f55ba65fcd9d94 +timeCreated: 1462774373 +licenseType: Free +DefaultImporter: + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/FungusExamples/FungusLua/Bindings/TestSprite.prefab b/Assets/FungusExamples/FungusLua/Bindings/TestSprite.prefab new file mode 100644 index 00000000..026168f3 --- /dev/null +++ b/Assets/FungusExamples/FungusLua/Bindings/TestSprite.prefab @@ -0,0 +1,104 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!1 &120068 +GameObject: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + serializedVersion: 4 + m_Component: + - 4: {fileID: 428828} + - 212: {fileID: 21207198} + - 50: {fileID: 5063608} + - 61: {fileID: 6194652} + m_Layer: 0 + m_Name: TestSprite + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &428828 +Transform: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 120068} + 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: 0 +--- !u!50 &5063608 +Rigidbody2D: + serializedVersion: 2 + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 120068} + m_UseAutoMass: 0 + m_Mass: 1 + m_LinearDrag: 0 + m_AngularDrag: 0.05 + m_GravityScale: 1 + m_IsKinematic: 0 + m_Interpolate: 0 + m_SleepingMode: 1 + m_CollisionDetection: 0 + m_Constraints: 0 +--- !u!61 &6194652 +BoxCollider2D: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 120068} + 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!212 &21207198 +SpriteRenderer: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 120068} + m_Enabled: 1 + m_CastShadows: 0 + m_ReceiveShadows: 0 + m_Materials: + - {fileID: 10754, guid: 0000000000000000e000000000000000, type: 0} + m_SubsetIndices: + m_StaticBatchRoot: {fileID: 0} + m_UseLightProbes: 0 + m_ReflectionProbeUsage: 0 + m_ProbeAnchor: {fileID: 0} + m_ScaleInLightmap: 1 + m_PreserveUVs: 0 + m_IgnoreNormalsForChartDetection: 0 + m_ImportantGI: 0 + 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: 120068} + m_IsPrefabParent: 1 diff --git a/Assets/FungusExamples/FungusLua/Bindings/TestSprite.prefab.meta b/Assets/FungusExamples/FungusLua/Bindings/TestSprite.prefab.meta new file mode 100644 index 00000000..00099f15 --- /dev/null +++ b/Assets/FungusExamples/FungusLua/Bindings/TestSprite.prefab.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 78100db42249d407787823d1e5719214 +timeCreated: 1462774531 +licenseType: Free +NativeFormatImporter: + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/FungusExamples/FungusLua/Flowchart.meta b/Assets/FungusExamples/FungusLua/Flowchart.meta new file mode 100644 index 00000000..0d0ab5c0 --- /dev/null +++ b/Assets/FungusExamples/FungusLua/Flowchart.meta @@ -0,0 +1,9 @@ +fileFormatVersion: 2 +guid: 33cf9f75cbecd4438a2464596aa02247 +folderAsset: yes +timeCreated: 1462775148 +licenseType: Free +DefaultImporter: + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/FungusExamples/FungusLua/Flowchart/Variables.unity b/Assets/FungusExamples/FungusLua/Flowchart/Variables.unity new file mode 100644 index 00000000..a2e8f6d3 --- /dev/null +++ b/Assets/FungusExamples/FungusLua/Flowchart/Variables.unity @@ -0,0 +1,668 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!29 &1 +SceneSettings: + m_ObjectHideFlags: 0 + m_PVSData: + m_PVSObjectsArray: [] + m_PVSPortalsArray: [] + m_OcclusionBakeSettings: + smallestOccluder: 5 + smallestHole: 0.25 + backfaceThreshold: 100 +--- !u!104 &2 +RenderSettings: + m_ObjectHideFlags: 0 + serializedVersion: 6 + m_Fog: 0 + m_FogColor: {r: 0.5, g: 0.5, b: 0.5, a: 1} + m_FogMode: 3 + m_FogDensity: 0.01 + m_LinearFogStart: 0 + m_LinearFogEnd: 300 + m_AmbientSkyColor: {r: 0.212, g: 0.227, b: 0.259, a: 1} + m_AmbientEquatorColor: {r: 0.114, g: 0.125, b: 0.133, a: 1} + m_AmbientGroundColor: {r: 0.047, g: 0.043, b: 0.035, a: 1} + m_AmbientIntensity: 1 + m_AmbientMode: 3 + m_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} +--- !u!157 &3 +LightmapSettings: + m_ObjectHideFlags: 0 + serializedVersion: 6 + m_GIWorkflowMode: 1 + m_LightmapsMode: 1 + m_GISettings: + serializedVersion: 2 + m_BounceScale: 1 + m_IndirectOutputScale: 1 + m_AlbedoBoost: 1 + m_TemporalCoherenceThreshold: 1 + m_EnvironmentLightingMode: 0 + m_EnableBakedLightmaps: 0 + m_EnableRealtimeLightmaps: 0 + m_LightmapEditorSettings: + serializedVersion: 3 + m_Resolution: 2 + m_BakeResolution: 40 + m_TextureWidth: 1024 + m_TextureHeight: 1024 + m_AOMaxDistance: 1 + m_Padding: 2 + m_CompAOExponent: 0 + m_LightmapParameters: {fileID: 0} + m_TextureCompression: 1 + m_FinalGather: 0 + m_FinalGatherRayCount: 1024 + m_ReflectionCompression: 2 + m_LightingDataAsset: {fileID: 0} + m_RuntimeCPUUsage: 25 +--- !u!196 &4 +NavMeshSettings: + serializedVersion: 2 + m_ObjectHideFlags: 0 + m_BuildSettings: + serializedVersion: 2 + agentRadius: 0.5 + agentHeight: 2 + agentSlope: 45 + agentClimb: 0.4 + ledgeDropHeight: 0 + maxJumpAcrossDistance: 0 + accuratePlacement: 0 + minRegionArea: 2 + cellSize: 0.16666667 + manualCellSize: 0 + m_NavMeshData: {fileID: 0} +--- !u!1 &364295471 +GameObject: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 179118, guid: 3ddf9f33ba98e4b31ba4d2b9722bea00, type: 2} + m_PrefabInternal: {fileID: 0} + serializedVersion: 4 + m_Component: + - 4: {fileID: 364295477} + - 114: {fileID: 364295476} + - 114: {fileID: 364295475} + - 114: {fileID: 364295474} + - 114: {fileID: 364295473} + - 114: {fileID: 364295472} + m_Layer: 0 + m_Name: Lua + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!114 &364295472 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 11437776, guid: 3ddf9f33ba98e4b31ba4d2b9722bea00, + type: 2} + m_PrefabInternal: {fileID: 0} + m_GameObject: {fileID: 364295471} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: c10f0b861365b42b0928858f7b086ff3, type: 3} + m_Name: + m_EditorClassIdentifier: + fungusModule: 0 + activeLanguage: en + stringTables: [] + registerTypes: + - {fileID: 4900000, guid: 9c3ab7a98d51241bbb499643399fa761, type: 3} + - {fileID: 4900000, guid: 93fddea8208764a2dbb189cc238aed40, type: 3} +--- !u!114 &364295473 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 11483650, guid: 3ddf9f33ba98e4b31ba4d2b9722bea00, + type: 2} + m_PrefabInternal: {fileID: 0} + m_GameObject: {fileID: 364295471} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: ba19c26c1ba7243d2b57ebc4329cc7c6, type: 3} + m_Name: + m_EditorClassIdentifier: + remoteDebugger: 0 +--- !u!114 &364295474 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 11499092, guid: 3ddf9f33ba98e4b31ba4d2b9722bea00, + type: 2} + m_PrefabInternal: {fileID: 0} + m_GameObject: {fileID: 364295471} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 4cc8a659e950044b69d7c62696c36962, type: 3} + m_Name: + m_EditorClassIdentifier: + allEnvironments: 0 + luaEnvironment: {fileID: 364295473} + tableName: + registerTypes: 1 + boundTypes: + - UnityEngine.GameObject, UnityEngine, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null + - UnityEngine.PrimitiveType, UnityEngine, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null + - UnityEngine.Component, UnityEngine, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null + - System.Type, mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + - System.Boolean, mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + - System.Int32, mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + - UnityEngine.SendMessageOptions, UnityEngine, Version=0.0.0.0, Culture=neutral, + PublicKeyToken=null + - UnityEngine.SceneManagement.Scene, UnityEngine, Version=0.0.0.0, Culture=neutral, + PublicKeyToken=null + - UnityEngine.Object, UnityEngine, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null + - System.Single, mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + - Fungus.Flowchart, Assembly-CSharp, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null + - Fungus.Block, Assembly-CSharp, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null + - UnityEngine.Vector2, UnityEngine, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null + - System.Action, System.Core, Version=3.5.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + - Fungus.Variable, Assembly-CSharp, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null + - Fungus.Label, Assembly-CSharp, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null + - Fungus.Command, Assembly-CSharp, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null + - Fungus.CommandInfoAttribute, Assembly-CSharp, Version=0.0.0.0, Culture=neutral, + PublicKeyToken=null + - UnityEngine.Rect, UnityEngine, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null + boundObjects: + - key: flowchart + obj: {fileID: 2088062867} + component: {fileID: 2088062874} +--- !u!114 &364295475 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 11417560, guid: 3ddf9f33ba98e4b31ba4d2b9722bea00, + type: 2} + m_PrefabInternal: {fileID: 0} + m_GameObject: {fileID: 364295471} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 446caeace65234baaacd52095d24f101, type: 3} + m_Name: + m_EditorClassIdentifier: + luaEnvironment: {fileID: 364295473} + luaFile: {fileID: 0} + luaScript: "local changename = getvar(flowchart, \"ChangeName\")\nlocal myname = + getvar(flowchart, \"MyName\")\n\nif (changename.value) then\n myname.value + = \"Darth John\"\nend\n" + runAsCoroutine: 1 +--- !u!114 &364295476 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 11415008, guid: 3ddf9f33ba98e4b31ba4d2b9722bea00, + type: 2} + m_PrefabInternal: {fileID: 0} + m_GameObject: {fileID: 364295471} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 6ee79785811ba49399c1b56d7309e3df, type: 3} + m_Name: + m_EditorClassIdentifier: + executeAfterTime: 1 + repeatExecuteTime: 1 + repeatEveryTime: 1 + executeAfterFrames: 1 + repeatExecuteFrame: 1 + repeatEveryFrame: 1 + hasFailed: 0 + executeMethods: 2 + executeMethodName: OnExecute +--- !u!4 &364295477 +Transform: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 466848, guid: 3ddf9f33ba98e4b31ba4d2b9722bea00, type: 2} + m_PrefabInternal: {fileID: 0} + m_GameObject: {fileID: 364295471} + 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: 2 +--- !u!1 &700669203 +GameObject: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + serializedVersion: 4 + m_Component: + - 4: {fileID: 700669208} + - 20: {fileID: 700669207} + - 92: {fileID: 700669206} + - 124: {fileID: 700669205} + - 81: {fileID: 700669204} + 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 &700669204 +AudioListener: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_GameObject: {fileID: 700669203} + m_Enabled: 1 +--- !u!124 &700669205 +Behaviour: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_GameObject: {fileID: 700669203} + m_Enabled: 1 +--- !u!92 &700669206 +Behaviour: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_GameObject: {fileID: 700669203} + m_Enabled: 1 +--- !u!20 &700669207 +Camera: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_GameObject: {fileID: 700669203} + m_Enabled: 1 + serializedVersion: 2 + m_ClearFlags: 1 + m_BackGroundColor: {r: 0.19215687, g: 0.3019608, b: 0.4745098, a: 0.019607844} + m_NormalizedViewPortRect: + serializedVersion: 2 + x: 0 + y: 0 + width: 1 + height: 1 + near clip plane: 0.3 + far clip plane: 1000 + field of view: 60 + orthographic: 1 + orthographic size: 5 + m_Depth: -1 + m_CullingMask: + serializedVersion: 2 + m_Bits: 4294967295 + m_RenderingPath: -1 + m_TargetTexture: {fileID: 0} + m_TargetDisplay: 0 + m_TargetEye: 3 + m_HDR: 0 + m_OcclusionCulling: 1 + m_StereoConvergence: 10 + m_StereoSeparation: 0.022 + m_StereoMirrorMode: 0 +--- !u!4 &700669208 +Transform: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_GameObject: {fileID: 700669203} + 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 +--- !u!1 &712898800 +GameObject: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + serializedVersion: 4 + m_Component: + - 4: {fileID: 712898802} + - 114: {fileID: 712898801} + m_Layer: 0 + m_Name: _FungusState + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!114 &712898801 +MonoBehaviour: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_GameObject: {fileID: 712898800} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 61dddfdc5e0e44ca298d8f46f7f5a915, type: 3} + m_Name: + m_EditorClassIdentifier: + selectedFlowchart: {fileID: 2088062874} +--- !u!4 &712898802 +Transform: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_GameObject: {fileID: 712898800} + 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: 1 +--- !u!1 &941829309 +GameObject: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + serializedVersion: 4 + m_Component: + - 4: {fileID: 941829313} + - 114: {fileID: 941829312} + - 114: {fileID: 941829311} + - 114: {fileID: 941829310} + m_Layer: 0 + m_Name: EventSystem + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!114 &941829310 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_GameObject: {fileID: 941829309} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 1997211142, guid: f5f67c52d1564df4a8936ccd202a3bd8, type: 3} + m_Name: + m_EditorClassIdentifier: + m_ForceModuleActive: 0 +--- !u!114 &941829311 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_GameObject: {fileID: 941829309} + 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 &941829312 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_GameObject: {fileID: 941829309} + 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!4 &941829313 +Transform: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_GameObject: {fileID: 941829309} + 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 +--- !u!1 &1703486016 +GameObject: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 105822, guid: d6f174e740b5040c68466fb971c4cec2, type: 2} + m_PrefabInternal: {fileID: 0} + serializedVersion: 4 + m_Component: + - 4: {fileID: 1703486018} + - 114: {fileID: 1703486017} + m_Layer: 0 + m_Name: InfoText + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!114 &1703486017 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 11442554, guid: d6f174e740b5040c68466fb971c4cec2, + type: 2} + m_PrefabInternal: {fileID: 0} + m_GameObject: {fileID: 1703486016} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 8c0cbb63e218a4414a796a60ffe37dd3, type: 3} + m_Name: + m_EditorClassIdentifier: + info: 'This example shows how to access the variables in a Flowchart from Lua. + + + The Flowchart object has 2 variables added to it. The Lua object has a binding + to the Flowchart. + + + The Lua script uses the getvar() function to get a reference to the 2 FLowchart + variables, and then uses the .value property accessor to access the values of + the variables. + + + Try setting the ChangeName variable in the Flowchart to false, to see how it affects + the Lua script.' +--- !u!4 &1703486018 +Transform: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 438292, guid: d6f174e740b5040c68466fb971c4cec2, type: 2} + m_PrefabInternal: {fileID: 0} + m_GameObject: {fileID: 1703486016} + 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 +--- !u!1 &2088062867 +GameObject: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 142980, guid: 5e7fbc8d4eb714b279eeeef2262c1e1a, type: 2} + m_PrefabInternal: {fileID: 0} + serializedVersion: 4 + m_Component: + - 4: {fileID: 2088062875} + - 114: {fileID: 2088062874} + - 114: {fileID: 2088062873} + - 114: {fileID: 2088062872} + - 114: {fileID: 2088062871} + - 114: {fileID: 2088062870} + - 114: {fileID: 2088062869} + - 114: {fileID: 2088062868} + m_Layer: 0 + m_Name: Flowchart + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!114 &2088062868 +MonoBehaviour: + m_ObjectHideFlags: 2 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_GameObject: {fileID: 2088062867} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: ec422cd568a9c4a31ad7c36d0572b9da, type: 3} + m_Name: + m_EditorClassIdentifier: + itemId: 2 + errorMessage: + indentLevel: 0 + storyText: Name is {$MyName} + description: + character: {fileID: 0} + portrait: {fileID: 0} + voiceOverClip: {fileID: 0} + showAlways: 1 + showCount: 1 + extendPrevious: 0 + fadeWhenDone: 1 + waitForClick: 1 + stopVoiceover: 1 + setSayDialog: {fileID: 0} +--- !u!114 &2088062869 +MonoBehaviour: + m_ObjectHideFlags: 2 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_GameObject: {fileID: 2088062867} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 3315ad2ebb85443909a1203d56d9344e, type: 3} + m_Name: + m_EditorClassIdentifier: + itemId: 1 + errorMessage: + indentLevel: 0 + _duration: + floatRef: {fileID: 0} + floatVal: 1 + durationOLD: 0 +--- !u!114 &2088062870 +MonoBehaviour: + m_ObjectHideFlags: 2 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_GameObject: {fileID: 2088062867} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 5d02d9822eec54c98afe95bb497211b3, type: 3} + m_Name: + m_EditorClassIdentifier: + scope: 1 + key: ChangeName + value: 1 +--- !u!114 &2088062871 +MonoBehaviour: + m_ObjectHideFlags: 2 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_GameObject: {fileID: 2088062867} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 4580f28dd8581476b810b38eea2f1316, type: 3} + m_Name: + m_EditorClassIdentifier: + scope: 1 + key: MyName + value: John +--- !u!114 &2088062872 +MonoBehaviour: + m_ObjectHideFlags: 2 + m_PrefabParentObject: {fileID: 11462346, guid: 5e7fbc8d4eb714b279eeeef2262c1e1a, + type: 2} + m_PrefabInternal: {fileID: 0} + m_GameObject: {fileID: 2088062867} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: d2f6487d21a03404cb21b245f0242e79, type: 3} + m_Name: + m_EditorClassIdentifier: + parentBlock: {fileID: 2088062873} +--- !u!114 &2088062873 +MonoBehaviour: + m_ObjectHideFlags: 2 + m_PrefabParentObject: {fileID: 11433304, guid: 5e7fbc8d4eb714b279eeeef2262c1e1a, + type: 2} + m_PrefabInternal: {fileID: 0} + m_GameObject: {fileID: 2088062867} + 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: Start + description: + eventHandler: {fileID: 2088062872} + commandList: + - {fileID: 2088062869} + - {fileID: 2088062868} +--- !u!114 &2088062874 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 11430050, guid: 5e7fbc8d4eb714b279eeeef2262c1e1a, + type: 2} + m_PrefabInternal: {fileID: 0} + m_GameObject: {fileID: 2088062867} + 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: 2088062873} + selectedCommands: + - {fileID: 2088062868} + variables: + - {fileID: 2088062870} + - {fileID: 2088062871} + description: + stepPause: 0 + colorCommands: 1 + hideComponents: 1 + saveSelection: 1 + localizationId: + showLineNumbers: 0 + hideCommands: [] +--- !u!4 &2088062875 +Transform: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 467082, guid: 5e7fbc8d4eb714b279eeeef2262c1e1a, type: 2} + m_PrefabInternal: {fileID: 0} + m_GameObject: {fileID: 2088062867} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: 0, y: 0, z: 0} + m_LocalScale: {x: 1, y: 1, z: 1} + m_Children: [] + m_Father: {fileID: 0} + m_RootOrder: 3 diff --git a/Assets/FungusExamples/FungusLua/Flowchart/Variables.unity.meta b/Assets/FungusExamples/FungusLua/Flowchart/Variables.unity.meta new file mode 100644 index 00000000..b6d69b53 --- /dev/null +++ b/Assets/FungusExamples/FungusLua/Flowchart/Variables.unity.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 3878571bd7de84feb892061f72d83965 +timeCreated: 1462775164 +licenseType: Free +DefaultImporter: + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/FungusExamples/FungusLua/Trigger.meta b/Assets/FungusExamples/FungusLua/Trigger.meta new file mode 100644 index 00000000..e124548f --- /dev/null +++ b/Assets/FungusExamples/FungusLua/Trigger.meta @@ -0,0 +1,9 @@ +fileFormatVersion: 2 +guid: 0d16233e345464bbf9ac190ec03b5f75 +folderAsset: yes +timeCreated: 1462556807 +licenseType: Free +DefaultImporter: + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/FungusExamples/FungusLua/Trigger.unity b/Assets/FungusExamples/FungusLua/Trigger/Trigger.unity similarity index 96% rename from Assets/FungusExamples/FungusLua/Trigger.unity rename to Assets/FungusExamples/FungusLua/Trigger/Trigger.unity index 8336a287..f9268f00 100644 --- a/Assets/FungusExamples/FungusLua/Trigger.unity +++ b/Assets/FungusExamples/FungusLua/Trigger/Trigger.unity @@ -221,7 +221,7 @@ Transform: m_LocalScale: {x: 1, y: 1, z: 1} m_Children: [] m_Father: {fileID: 0} - m_RootOrder: 5 + m_RootOrder: 4 --- !u!54 &141306355 Rigidbody: m_ObjectHideFlags: 0 @@ -237,6 +237,50 @@ Rigidbody: m_Interpolate: 0 m_Constraints: 0 m_CollisionDetection: 0 +--- !u!1 &229439457 +GameObject: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + serializedVersion: 4 + m_Component: + - 4: {fileID: 229439459} + - 114: {fileID: 229439458} + m_Layer: 0 + m_Name: InfoText + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!114 &229439458 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_GameObject: {fileID: 229439457} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 8c0cbb63e218a4414a796a60ffe37dd3, type: 3} + m_Name: + m_EditorClassIdentifier: + info: "This example shows how to execute a Lua script form a trigger event.\n\nThe + CubeTrigger object has ExecuteHandler and LuaScript components attached. The ExecuteHandler + has been set to execute the LuaScript component when a trigger enter event happens. + \n\nThe LuaBindings object looks after registering the Flowchart and SayDialog + objects so we can access them from Lua." +--- !u!4 &229439459 +Transform: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_GameObject: {fileID: 229439457} + 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: 9 --- !u!1 &517355049 GameObject: m_ObjectHideFlags: 1 @@ -276,7 +320,7 @@ Transform: m_LocalScale: {x: 1, y: 1, z: 1} m_Children: [] m_Father: {fileID: 0} - m_RootOrder: 8 + m_RootOrder: 7 --- !u!1 &775333277 GameObject: m_ObjectHideFlags: 0 @@ -305,6 +349,8 @@ MonoBehaviour: m_Script: {fileID: 11500000, guid: 4cc8a659e950044b69d7c62696c36962, type: 3} m_Name: m_EditorClassIdentifier: + allEnvironments: 1 + luaEnvironment: {fileID: 0} tableName: registerTypes: 1 boundTypes: @@ -357,7 +403,7 @@ Transform: m_LocalScale: {x: 1, y: 1, z: 1} m_Children: [] m_Father: {fileID: 0} - m_RootOrder: 4 + m_RootOrder: 3 --- !u!1 &913136538 GameObject: m_ObjectHideFlags: 0 @@ -474,7 +520,7 @@ Transform: m_LocalScale: {x: 1, y: 1, z: 1} m_Children: [] m_Father: {fileID: 0} - m_RootOrder: 7 + m_RootOrder: 6 --- !u!1 &974098819 GameObject: m_ObjectHideFlags: 0 @@ -1208,7 +1254,7 @@ Transform: m_LocalScale: {x: 1.1810303, y: 1.1810303, z: 1.1810303} m_Children: [] m_Father: {fileID: 0} - m_RootOrder: 6 + m_RootOrder: 5 --- !u!114 &1437227280 MonoBehaviour: m_ObjectHideFlags: 0 @@ -1248,48 +1294,7 @@ MonoBehaviour: repeatEveryFrame: 1 hasFailed: 0 executeMethods: 8192 ---- !u!1001 &1575311449 -Prefab: - m_ObjectHideFlags: 0 - serializedVersion: 2 - m_Modification: - m_TransformParent: {fileID: 0} - m_Modifications: - - target: {fileID: 495584, guid: 49031c561e16d4fcf91c12153f8e0b25, type: 2} - propertyPath: m_LocalPosition.x - value: 0 - objectReference: {fileID: 0} - - target: {fileID: 495584, guid: 49031c561e16d4fcf91c12153f8e0b25, type: 2} - propertyPath: m_LocalPosition.y - value: 0 - objectReference: {fileID: 0} - - target: {fileID: 495584, guid: 49031c561e16d4fcf91c12153f8e0b25, type: 2} - propertyPath: m_LocalPosition.z - value: 0 - objectReference: {fileID: 0} - - target: {fileID: 495584, guid: 49031c561e16d4fcf91c12153f8e0b25, type: 2} - propertyPath: m_LocalRotation.x - value: 0 - objectReference: {fileID: 0} - - target: {fileID: 495584, guid: 49031c561e16d4fcf91c12153f8e0b25, type: 2} - propertyPath: m_LocalRotation.y - value: 0 - objectReference: {fileID: 0} - - target: {fileID: 495584, guid: 49031c561e16d4fcf91c12153f8e0b25, type: 2} - propertyPath: m_LocalRotation.z - value: 0 - objectReference: {fileID: 0} - - target: {fileID: 495584, guid: 49031c561e16d4fcf91c12153f8e0b25, type: 2} - propertyPath: m_LocalRotation.w - value: 1 - objectReference: {fileID: 0} - - target: {fileID: 495584, guid: 49031c561e16d4fcf91c12153f8e0b25, type: 2} - propertyPath: m_RootOrder - value: 3 - objectReference: {fileID: 0} - m_RemovedComponents: [] - m_ParentPrefab: {fileID: 100100000, guid: 49031c561e16d4fcf91c12153f8e0b25, type: 2} - m_IsPrefabParent: 0 + executeMethodName: OnExecute --- !u!1 &1882312847 GameObject: m_ObjectHideFlags: 0 @@ -1363,7 +1368,7 @@ Transform: m_LocalScale: {x: 1, y: 1, z: 1} m_Children: [] m_Father: {fileID: 0} - m_RootOrder: 9 + m_RootOrder: 8 --- !u!1 &1918243061 GameObject: m_ObjectHideFlags: 0 diff --git a/Assets/FungusExamples/FungusLua/Trigger.unity.meta b/Assets/FungusExamples/FungusLua/Trigger/Trigger.unity.meta similarity index 100% rename from Assets/FungusExamples/FungusLua/Trigger.unity.meta rename to Assets/FungusExamples/FungusLua/Trigger/Trigger.unity.meta