Skip to content

Commit cef3f97

Browse files
committed
feat(runtime gameobjects): replaced game object overrides with a send message action API
GameObject overrdies were wonky at best and should be replaced with a full blackboard solution to be properly implemented. The current code to maintain them is also creating quite a mess. For now they've been replaced with a simple SendMessage API that takes a string to find a GameObject and support sending over messages. The SetActive hook should handle a majority of use cases. BREAKING CHANGE: You should remove all references to GameObject overrides, be ready to replace the game object names with paths (write them down). After upgrading you'll need to swap or remove all references to game object overrides from your project.
1 parent 45585fe commit cef3f97

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

44 files changed

+359
-344
lines changed

Assets/Examples/BasicConversation/BasicConversation.unity

Lines changed: 63 additions & 27 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ OcclusionCullingSettings:
1313
--- !u!104 &2
1414
RenderSettings:
1515
m_ObjectHideFlags: 0
16-
serializedVersion: 9
16+
serializedVersion: 10
1717
m_Fog: 0
1818
m_FogColor: {r: 0.5, g: 0.5, b: 0.5, a: 1}
1919
m_FogMode: 3
@@ -38,13 +38,12 @@ RenderSettings:
3838
m_ReflectionIntensity: 1
3939
m_CustomReflection: {fileID: 0}
4040
m_Sun: {fileID: 705507994}
41-
m_IndirectSpecularColor: {r: 0.44657898, g: 0.4964133, b: 0.5748178, a: 1}
41+
m_IndirectSpecularColor: {r: 0, g: 0, b: 0, a: 1}
4242
m_UseRadianceAmbientProbe: 0
4343
--- !u!157 &3
4444
LightmapSettings:
4545
m_ObjectHideFlags: 0
4646
serializedVersion: 12
47-
m_GIWorkflowMode: 0
4847
m_GISettings:
4948
serializedVersion: 2
5049
m_BounceScale: 1
@@ -67,9 +66,6 @@ LightmapSettings:
6766
m_LightmapParameters: {fileID: 0}
6867
m_LightmapsBakeMode: 1
6968
m_TextureCompression: 1
70-
m_FinalGather: 0
71-
m_FinalGatherFiltering: 1
72-
m_FinalGatherRayCount: 256
7369
m_ReflectionCompression: 2
7470
m_MixedBakeMode: 2
7571
m_BakeBackend: 1
@@ -105,7 +101,7 @@ NavMeshSettings:
105101
serializedVersion: 2
106102
m_ObjectHideFlags: 0
107103
m_BuildSettings:
108-
serializedVersion: 2
104+
serializedVersion: 3
109105
agentTypeID: 0
110106
agentRadius: 0.5
111107
agentHeight: 2
@@ -118,7 +114,7 @@ NavMeshSettings:
118114
cellSize: 0.16666667
119115
manualTileSize: 0
120116
tileSize: 256
121-
accuratePlacement: 0
117+
buildHeightMesh: 0
122118
maxJobWorkers: 0
123119
preserveTilesOutsideBounds: 0
124120
debug:
@@ -154,7 +150,6 @@ RectTransform:
154150
m_ConstrainProportionsScale: 0
155151
m_Children: []
156152
m_Father: {fileID: 1854390184}
157-
m_RootOrder: 1
158153
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
159154
m_AnchorMin: {x: 0, y: 0}
160155
m_AnchorMax: {x: 0, y: 0}
@@ -218,7 +213,6 @@ RectTransform:
218213
m_ConstrainProportionsScale: 0
219214
m_Children: []
220215
m_Father: {fileID: 1987331376}
221-
m_RootOrder: 1
222216
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
223217
m_AnchorMin: {x: 0, y: 1}
224218
m_AnchorMax: {x: 0, y: 1}
@@ -289,9 +283,8 @@ Light:
289283
m_PrefabAsset: {fileID: 0}
290284
m_GameObject: {fileID: 705507993}
291285
m_Enabled: 1
292-
serializedVersion: 10
286+
serializedVersion: 11
293287
m_Type: 1
294-
m_Shape: 0
295288
m_Color: {r: 1, g: 0.95686275, b: 0.8392157, a: 1}
296289
m_Intensity: 1
297290
m_Range: 10
@@ -350,13 +343,13 @@ Transform:
350343
m_PrefabInstance: {fileID: 0}
351344
m_PrefabAsset: {fileID: 0}
352345
m_GameObject: {fileID: 705507993}
346+
serializedVersion: 2
353347
m_LocalRotation: {x: 0.40821788, y: -0.23456968, z: 0.10938163, w: 0.8754261}
354348
m_LocalPosition: {x: 0, y: 3, z: 0}
355349
m_LocalScale: {x: 1, y: 1, z: 1}
356350
m_ConstrainProportionsScale: 0
357351
m_Children: []
358352
m_Father: {fileID: 0}
359-
m_RootOrder: 4
360353
m_LocalEulerAnglesHint: {x: 50, y: -30, z: 0}
361354
--- !u!82 &705507996
362355
AudioSource:
@@ -369,6 +362,7 @@ AudioSource:
369362
serializedVersion: 4
370363
OutputAudioMixerGroup: {fileID: 0}
371364
m_audioClip: {fileID: 8300000, guid: 68d5592cda1d5bd429da0481390f1a6a, type: 3}
365+
m_Resource: {fileID: 8300000, guid: 68d5592cda1d5bd429da0481390f1a6a, type: 3}
372366
m_PlayOnAwake: 1
373367
m_Volume: 1
374368
m_Pitch: 1
@@ -454,6 +448,37 @@ AudioSource:
454448
m_PreInfinity: 2
455449
m_PostInfinity: 2
456450
m_RotationOrder: 4
451+
--- !u!1 &894268022
452+
GameObject:
453+
m_ObjectHideFlags: 0
454+
m_CorrespondingSourceObject: {fileID: 0}
455+
m_PrefabInstance: {fileID: 0}
456+
m_PrefabAsset: {fileID: 0}
457+
serializedVersion: 6
458+
m_Component:
459+
- component: {fileID: 894268023}
460+
m_Layer: 0
461+
m_Name: SetActiveTest
462+
m_TagString: Untagged
463+
m_Icon: {fileID: 0}
464+
m_NavMeshLayer: 0
465+
m_StaticEditorFlags: 0
466+
m_IsActive: 0
467+
--- !u!4 &894268023
468+
Transform:
469+
m_ObjectHideFlags: 0
470+
m_CorrespondingSourceObject: {fileID: 0}
471+
m_PrefabInstance: {fileID: 0}
472+
m_PrefabAsset: {fileID: 0}
473+
m_GameObject: {fileID: 894268022}
474+
serializedVersion: 2
475+
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
476+
m_LocalPosition: {x: 0, y: 0, z: 0}
477+
m_LocalScale: {x: 1, y: 1, z: 1}
478+
m_ConstrainProportionsScale: 0
479+
m_Children: []
480+
m_Father: {fileID: 0}
481+
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
457482
--- !u!1 &963194225
458483
GameObject:
459484
m_ObjectHideFlags: 0
@@ -494,9 +519,17 @@ Camera:
494519
m_projectionMatrixMode: 1
495520
m_GateFitMode: 2
496521
m_FOVAxisMode: 0
522+
m_Iso: 200
523+
m_ShutterSpeed: 0.005
524+
m_Aperture: 16
525+
m_FocusDistance: 10
526+
m_FocalLength: 50
527+
m_BladeCount: 5
528+
m_Curvature: {x: 2, y: 11}
529+
m_BarrelClipping: 0.25
530+
m_Anamorphism: 0
497531
m_SensorSize: {x: 36, y: 24}
498532
m_LensShift: {x: 0, y: 0}
499-
m_FocalLength: 50
500533
m_NormalizedViewPortRect:
501534
serializedVersion: 2
502535
x: 0
@@ -530,13 +563,13 @@ Transform:
530563
m_PrefabInstance: {fileID: 0}
531564
m_PrefabAsset: {fileID: 0}
532565
m_GameObject: {fileID: 963194225}
566+
serializedVersion: 2
533567
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
534568
m_LocalPosition: {x: 0, y: 1, z: -10}
535569
m_LocalScale: {x: 1, y: 1, z: 1}
536570
m_ConstrainProportionsScale: 0
537571
m_Children: []
538572
m_Father: {fileID: 0}
539-
m_RootOrder: 3
540573
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
541574
--- !u!1 &991365858
542575
GameObject:
@@ -569,7 +602,6 @@ RectTransform:
569602
m_ConstrainProportionsScale: 0
570603
m_Children: []
571604
m_Father: {fileID: 1987331376}
572-
m_RootOrder: 0
573605
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
574606
m_AnchorMin: {x: 0, y: 1}
575607
m_AnchorMax: {x: 0, y: 1}
@@ -694,6 +726,7 @@ Canvas:
694726
m_OverrideSorting: 0
695727
m_OverridePixelPerfect: 0
696728
m_SortingBucketNormalizedSize: 0
729+
m_VertexColorAlwaysGammaSpace: 0
697730
m_AdditionalShaderChannelsFlag: 0
698731
m_UpdateRectTransformForStandalone: 0
699732
m_SortingLayerID: 0
@@ -715,7 +748,6 @@ RectTransform:
715748
- {fileID: 1854390184}
716749
- {fileID: 1217128673}
717750
m_Father: {fileID: 0}
718-
m_RootOrder: 1
719751
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
720752
m_AnchorMin: {x: 0, y: 0}
721753
m_AnchorMax: {x: 0, y: 0}
@@ -739,7 +771,7 @@ GameObject:
739771
m_Icon: {fileID: 0}
740772
m_NavMeshLayer: 0
741773
m_StaticEditorFlags: 0
742-
m_IsActive: 1
774+
m_IsActive: 0
743775
--- !u!224 &1217128673
744776
RectTransform:
745777
m_ObjectHideFlags: 0
@@ -753,7 +785,6 @@ RectTransform:
753785
m_ConstrainProportionsScale: 0
754786
m_Children: []
755787
m_Father: {fileID: 1037096126}
756-
m_RootOrder: 2
757788
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
758789
m_AnchorMin: {x: 0.5, y: 0.5}
759790
m_AnchorMax: {x: 0.5, y: 0.5}
@@ -828,6 +859,7 @@ MonoBehaviour:
828859
m_Script: {fileID: 11500000, guid: 4f231c4fb786f3946a6b90b886c48677, type: 3}
829860
m_Name:
830861
m_EditorClassIdentifier:
862+
m_SendPointerHoverToParent: 1
831863
m_HorizontalAxis: Horizontal
832864
m_VerticalAxis: Vertical
833865
m_SubmitButton: Submit
@@ -857,13 +889,13 @@ Transform:
857889
m_PrefabInstance: {fileID: 0}
858890
m_PrefabAsset: {fileID: 0}
859891
m_GameObject: {fileID: 1578604058}
892+
serializedVersion: 2
860893
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
861894
m_LocalPosition: {x: 0, y: 0, z: 0}
862895
m_LocalScale: {x: 1, y: 1, z: 1}
863896
m_ConstrainProportionsScale: 0
864897
m_Children: []
865898
m_Father: {fileID: 0}
866-
m_RootOrder: 2
867899
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
868900
--- !u!1 &1854390183
869901
GameObject:
@@ -896,7 +928,6 @@ RectTransform:
896928
- {fileID: 1987331376}
897929
- {fileID: 8172351}
898930
m_Father: {fileID: 1037096126}
899-
m_RootOrder: 1
900931
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
901932
m_AnchorMin: {x: 0, y: 0}
902933
m_AnchorMax: {x: 1, y: 1}
@@ -933,9 +964,6 @@ MonoBehaviour:
933964
m_Name:
934965
m_EditorClassIdentifier:
935966
dialogue: {fileID: 11400000, guid: 9ee08f7122b445246ba6e627bb67b59a, type: 2}
936-
gameObjectOverrides:
937-
- _variable: {fileID: 11400000, guid: 9f63ecc07e0124045b2c27d0dfb67d38, type: 2}
938-
_gameObject: {fileID: 1217128672}
939967
speakerContainer: {fileID: 1854390183}
940968
portrait: {fileID: 62754277}
941969
lines: {fileID: 991365860}
@@ -949,13 +977,13 @@ Transform:
949977
m_PrefabInstance: {fileID: 0}
950978
m_PrefabAsset: {fileID: 0}
951979
m_GameObject: {fileID: 1965669758}
980+
serializedVersion: 2
952981
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
953982
m_LocalPosition: {x: 0, y: 0, z: 0}
954983
m_LocalScale: {x: 1, y: 1, z: 1}
955984
m_ConstrainProportionsScale: 0
956985
m_Children: []
957986
m_Father: {fileID: 0}
958-
m_RootOrder: 0
959987
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
960988
--- !u!1 &1987331375
961989
GameObject:
@@ -990,7 +1018,6 @@ RectTransform:
9901018
- {fileID: 991365859}
9911019
- {fileID: 62754276}
9921020
m_Father: {fileID: 1854390184}
993-
m_RootOrder: 0
9941021
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
9951022
m_AnchorMin: {x: 0, y: 0}
9961023
m_AnchorMax: {x: 0, y: 0}
@@ -1066,7 +1093,6 @@ RectTransform:
10661093
m_ConstrainProportionsScale: 0
10671094
m_Children: []
10681095
m_Father: {fileID: 1037096126}
1069-
m_RootOrder: 0
10701096
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
10711097
m_AnchorMin: {x: 0, y: 0}
10721098
m_AnchorMax: {x: 1, y: 1}
@@ -1111,3 +1137,13 @@ CanvasRenderer:
11111137
m_PrefabAsset: {fileID: 0}
11121138
m_GameObject: {fileID: 2077554726}
11131139
m_CullTransparentMesh: 0
1140+
--- !u!1660057539 &9223372036854775807
1141+
SceneRoots:
1142+
m_ObjectHideFlags: 0
1143+
m_Roots:
1144+
- {fileID: 1965669760}
1145+
- {fileID: 1037096126}
1146+
- {fileID: 1578604061}
1147+
- {fileID: 963194228}
1148+
- {fileID: 705507995}
1149+
- {fileID: 894268023}

0 commit comments

Comments
 (0)