change on PDA replaced DEVICE by RUNTIME
This commit is contained in:
parent
1fec4e780d
commit
55faff3b82
@ -12,6 +12,6 @@ MonoBehaviour:
|
|||||||
m_Script: {fileID: 11500000, guid: 8721e912e8f648bc96a79bb3228a01bb, type: 3}
|
m_Script: {fileID: 11500000, guid: 8721e912e8f648bc96a79bb3228a01bb, type: 3}
|
||||||
m_Name: '# PDA Application Library'
|
m_Name: '# PDA Application Library'
|
||||||
m_EditorClassIdentifier:
|
m_EditorClassIdentifier:
|
||||||
applicationPrefabs:
|
apps:
|
||||||
- {fileID: 8445778930960300939, guid: 601c65c6fcf8e4c088c890a9d3f74a1e, type: 3}
|
- {fileID: 8445778930960300939, guid: 601c65c6fcf8e4c088c890a9d3f74a1e, type: 3}
|
||||||
- {fileID: 2125927707020507478, guid: 0e9dba8caea034cdeb8b71bc4edc522d, type: 3}
|
- {fileID: 2125927707020507478, guid: 0e9dba8caea034cdeb8b71bc4edc522d, type: 3}
|
||||||
|
|||||||
@ -162,8 +162,8 @@ MonoBehaviour:
|
|||||||
m_Script: {fileID: 11500000, guid: 6c87cfb5e9bf432d8c74e9b1b1cecf17, type: 3}
|
m_Script: {fileID: 11500000, guid: 6c87cfb5e9bf432d8c74e9b1b1cecf17, type: 3}
|
||||||
m_Name:
|
m_Name:
|
||||||
m_EditorClassIdentifier:
|
m_EditorClassIdentifier:
|
||||||
|
generateRandomId: 0
|
||||||
id: 263651a6ab724288adae0d8f571f529e
|
id: 263651a6ab724288adae0d8f571f529e
|
||||||
device: {fileID: 11400000, guid: 5851ff4beee4547de8bb37a91c321af0, type: 2}
|
|
||||||
contentTag: {fileID: 11400000, guid: d3c3f76d56e994ca1a0fec7b4c2dee8b, type: 2}
|
contentTag: {fileID: 11400000, guid: d3c3f76d56e994ca1a0fec7b4c2dee8b, type: 2}
|
||||||
currentThemeSelectionAreaUI: {fileID: 3606088870277292810}
|
currentThemeSelectionAreaUI: {fileID: 3606088870277292810}
|
||||||
themeSelectorUI: {fileID: 5133641343740112976}
|
themeSelectorUI: {fileID: 5133641343740112976}
|
||||||
@ -331,6 +331,30 @@ PrefabInstance:
|
|||||||
propertyPath: m_AnchoredPosition.y
|
propertyPath: m_AnchoredPosition.y
|
||||||
value: 0
|
value: 0
|
||||||
objectReference: {fileID: 0}
|
objectReference: {fileID: 0}
|
||||||
|
- target: {fileID: 2274582946839607471, guid: 5719fba5951fb4652873e5abe0395622, type: 3}
|
||||||
|
propertyPath: m_AnchorMax.y
|
||||||
|
value: 0
|
||||||
|
objectReference: {fileID: 0}
|
||||||
|
- target: {fileID: 2274582946839607471, guid: 5719fba5951fb4652873e5abe0395622, type: 3}
|
||||||
|
propertyPath: m_AnchorMin.y
|
||||||
|
value: 0
|
||||||
|
objectReference: {fileID: 0}
|
||||||
|
- target: {fileID: 2274582946839607471, guid: 5719fba5951fb4652873e5abe0395622, type: 3}
|
||||||
|
propertyPath: m_SizeDelta.x
|
||||||
|
value: 0
|
||||||
|
objectReference: {fileID: 0}
|
||||||
|
- target: {fileID: 2274582946839607471, guid: 5719fba5951fb4652873e5abe0395622, type: 3}
|
||||||
|
propertyPath: m_SizeDelta.y
|
||||||
|
value: 0
|
||||||
|
objectReference: {fileID: 0}
|
||||||
|
- target: {fileID: 2274582946839607471, guid: 5719fba5951fb4652873e5abe0395622, type: 3}
|
||||||
|
propertyPath: m_AnchoredPosition.x
|
||||||
|
value: 0
|
||||||
|
objectReference: {fileID: 0}
|
||||||
|
- target: {fileID: 2274582946839607471, guid: 5719fba5951fb4652873e5abe0395622, type: 3}
|
||||||
|
propertyPath: m_AnchoredPosition.y
|
||||||
|
value: 0
|
||||||
|
objectReference: {fileID: 0}
|
||||||
- target: {fileID: 3369383829443116588, guid: 5719fba5951fb4652873e5abe0395622, type: 3}
|
- target: {fileID: 3369383829443116588, guid: 5719fba5951fb4652873e5abe0395622, type: 3}
|
||||||
propertyPath: m_AnchorMax.y
|
propertyPath: m_AnchorMax.y
|
||||||
value: 0
|
value: 0
|
||||||
@ -511,6 +535,30 @@ PrefabInstance:
|
|||||||
propertyPath: m_LocalEulerAnglesHint.z
|
propertyPath: m_LocalEulerAnglesHint.z
|
||||||
value: 0
|
value: 0
|
||||||
objectReference: {fileID: 0}
|
objectReference: {fileID: 0}
|
||||||
|
- target: {fileID: 7073260830788580152, guid: 5719fba5951fb4652873e5abe0395622, type: 3}
|
||||||
|
propertyPath: m_AnchorMax.y
|
||||||
|
value: 0
|
||||||
|
objectReference: {fileID: 0}
|
||||||
|
- target: {fileID: 7073260830788580152, guid: 5719fba5951fb4652873e5abe0395622, type: 3}
|
||||||
|
propertyPath: m_AnchorMin.y
|
||||||
|
value: 0
|
||||||
|
objectReference: {fileID: 0}
|
||||||
|
- target: {fileID: 7073260830788580152, guid: 5719fba5951fb4652873e5abe0395622, type: 3}
|
||||||
|
propertyPath: m_SizeDelta.x
|
||||||
|
value: 0
|
||||||
|
objectReference: {fileID: 0}
|
||||||
|
- target: {fileID: 7073260830788580152, guid: 5719fba5951fb4652873e5abe0395622, type: 3}
|
||||||
|
propertyPath: m_SizeDelta.y
|
||||||
|
value: 0
|
||||||
|
objectReference: {fileID: 0}
|
||||||
|
- target: {fileID: 7073260830788580152, guid: 5719fba5951fb4652873e5abe0395622, type: 3}
|
||||||
|
propertyPath: m_AnchoredPosition.x
|
||||||
|
value: 0
|
||||||
|
objectReference: {fileID: 0}
|
||||||
|
- target: {fileID: 7073260830788580152, guid: 5719fba5951fb4652873e5abe0395622, type: 3}
|
||||||
|
propertyPath: m_AnchoredPosition.y
|
||||||
|
value: 0
|
||||||
|
objectReference: {fileID: 0}
|
||||||
- target: {fileID: 7305453120782626341, guid: 5719fba5951fb4652873e5abe0395622, type: 3}
|
- target: {fileID: 7305453120782626341, guid: 5719fba5951fb4652873e5abe0395622, type: 3}
|
||||||
propertyPath: m_AnchorMax.y
|
propertyPath: m_AnchorMax.y
|
||||||
value: 0
|
value: 0
|
||||||
|
|||||||
@ -49,7 +49,7 @@ GameObject:
|
|||||||
- component: {fileID: 5189104512823423114}
|
- component: {fileID: 5189104512823423114}
|
||||||
- component: {fileID: 5172885852129304430}
|
- component: {fileID: 5172885852129304430}
|
||||||
m_Layer: 3
|
m_Layer: 3
|
||||||
m_Name: PDA Device
|
m_Name: PDADeviceUI
|
||||||
m_TagString: Untagged
|
m_TagString: Untagged
|
||||||
m_Icon: {fileID: 0}
|
m_Icon: {fileID: 0}
|
||||||
m_NavMeshLayer: 0
|
m_NavMeshLayer: 0
|
||||||
@ -180,7 +180,7 @@ MonoBehaviour:
|
|||||||
m_EditorClassIdentifier:
|
m_EditorClassIdentifier:
|
||||||
subscriptionId: event-listener.pda-device-ui
|
subscriptionId: event-listener.pda-device-ui
|
||||||
managedWindow: {fileID: 5189104512823423114}
|
managedWindow: {fileID: 5189104512823423114}
|
||||||
device: {fileID: 11400000, guid: 5851ff4beee4547de8bb37a91c321af0, type: 2}
|
runtime: {fileID: 0}
|
||||||
operationalSystem: {fileID: 6195836449349636204}
|
operationalSystem: {fileID: 6195836449349636204}
|
||||||
loadingProcess: {fileID: 6090578839837176443}
|
loadingProcess: {fileID: 6090578839837176443}
|
||||||
--- !u!1 &5189104512904093456
|
--- !u!1 &5189104512904093456
|
||||||
@ -432,7 +432,7 @@ RectTransform:
|
|||||||
m_LocalScale: {x: 1, y: 1, z: 1}
|
m_LocalScale: {x: 1, y: 1, z: 1}
|
||||||
m_ConstrainProportionsScale: 0
|
m_ConstrainProportionsScale: 0
|
||||||
m_Children:
|
m_Children:
|
||||||
- {fileID: 7197876000195360075}
|
- {fileID: 227485419669739136}
|
||||||
m_Father: {fileID: 0}
|
m_Father: {fileID: 0}
|
||||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||||
m_AnchorMin: {x: 0.5, y: 0.5}
|
m_AnchorMin: {x: 0.5, y: 0.5}
|
||||||
@ -452,7 +452,7 @@ MonoBehaviour:
|
|||||||
m_Script: {fileID: 11500000, guid: 603e9d5617d74657b44a765c22b3c52c, type: 3}
|
m_Script: {fileID: 11500000, guid: 603e9d5617d74657b44a765c22b3c52c, type: 3}
|
||||||
m_Name:
|
m_Name:
|
||||||
m_EditorClassIdentifier:
|
m_EditorClassIdentifier:
|
||||||
dialog: {fileID: 1558540297844798833}
|
panel: {fileID: 8338704736818780985}
|
||||||
title: {fileID: 255223171885326068}
|
title: {fileID: 255223171885326068}
|
||||||
description: {fileID: 1277390162049044817}
|
description: {fileID: 1277390162049044817}
|
||||||
palettes:
|
palettes:
|
||||||
@ -461,7 +461,7 @@ MonoBehaviour:
|
|||||||
- {fileID: 8473506677830965403}
|
- {fileID: 8473506677830965403}
|
||||||
- {fileID: 3860455122155657020}
|
- {fileID: 3860455122155657020}
|
||||||
- {fileID: 6760503043117943428}
|
- {fileID: 6760503043117943428}
|
||||||
theme: {fileID: 11400000, guid: 17516c994301f4620bcb1383d4f04cb6, type: 2}
|
protocol: {fileID: 0}
|
||||||
--- !u!1 &3784333515902507553
|
--- !u!1 &3784333515902507553
|
||||||
GameObject:
|
GameObject:
|
||||||
m_ObjectHideFlags: 0
|
m_ObjectHideFlags: 0
|
||||||
@ -646,19 +646,19 @@ RectTransform:
|
|||||||
m_PrefabInstance: {fileID: 0}
|
m_PrefabInstance: {fileID: 0}
|
||||||
m_PrefabAsset: {fileID: 0}
|
m_PrefabAsset: {fileID: 0}
|
||||||
m_GameObject: {fileID: 6716902540114609045}
|
m_GameObject: {fileID: 6716902540114609045}
|
||||||
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
|
m_LocalRotation: {x: -0, y: -0, z: -0, w: 1}
|
||||||
m_LocalPosition: {x: 0, y: 0, z: 0}
|
m_LocalPosition: {x: 0, y: 0, z: 0}
|
||||||
m_LocalScale: {x: 1, y: 1, z: 1}
|
m_LocalScale: {x: 1, y: 1, z: 1}
|
||||||
m_ConstrainProportionsScale: 0
|
m_ConstrainProportionsScale: 0
|
||||||
m_Children:
|
m_Children:
|
||||||
- {fileID: 2274582946839607471}
|
- {fileID: 2274582946839607471}
|
||||||
- {fileID: 7073260830788580152}
|
- {fileID: 7073260830788580152}
|
||||||
m_Father: {fileID: 2636253603181931612}
|
m_Father: {fileID: 3903991783760124170}
|
||||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||||
m_AnchorMin: {x: 0, y: 0}
|
m_AnchorMin: {x: 0, y: 0}
|
||||||
m_AnchorMax: {x: 1, y: 1}
|
m_AnchorMax: {x: 1, y: 1}
|
||||||
m_AnchoredPosition: {x: 0, y: 0}
|
m_AnchoredPosition: {x: 0, y: 0}
|
||||||
m_SizeDelta: {x: 0, y: 0}
|
m_SizeDelta: {x: -6, y: -6}
|
||||||
m_Pivot: {x: 0.5, y: 0.5}
|
m_Pivot: {x: 0.5, y: 0.5}
|
||||||
--- !u!114 &2354857897493377708
|
--- !u!114 &2354857897493377708
|
||||||
MonoBehaviour:
|
MonoBehaviour:
|
||||||
@ -761,7 +761,7 @@ MonoBehaviour:
|
|||||||
m_FillOrigin: 0
|
m_FillOrigin: 0
|
||||||
m_UseSpriteMesh: 0
|
m_UseSpriteMesh: 0
|
||||||
m_PixelsPerUnitMultiplier: 1
|
m_PixelsPerUnitMultiplier: 1
|
||||||
--- !u!1001 &6545589296576142606
|
--- !u!1001 &612321642549273984
|
||||||
PrefabInstance:
|
PrefabInstance:
|
||||||
m_ObjectHideFlags: 0
|
m_ObjectHideFlags: 0
|
||||||
serializedVersion: 2
|
serializedVersion: 2
|
||||||
@ -769,119 +769,119 @@ PrefabInstance:
|
|||||||
serializedVersion: 3
|
serializedVersion: 3
|
||||||
m_TransformParent: {fileID: 6879196895299910792}
|
m_TransformParent: {fileID: 6879196895299910792}
|
||||||
m_Modifications:
|
m_Modifications:
|
||||||
- target: {fileID: 4122311943219390533, guid: 18f44b986d2754181a3a9695f6898774, type: 3}
|
- target: {fileID: 817218075505996544, guid: 819a22e651d254aeaa6271a8a5008be5, type: 3}
|
||||||
propertyPath: m_Pivot.x
|
propertyPath: m_Pivot.x
|
||||||
value: 0.5
|
value: 0.5
|
||||||
objectReference: {fileID: 0}
|
objectReference: {fileID: 0}
|
||||||
- target: {fileID: 4122311943219390533, guid: 18f44b986d2754181a3a9695f6898774, type: 3}
|
- target: {fileID: 817218075505996544, guid: 819a22e651d254aeaa6271a8a5008be5, type: 3}
|
||||||
propertyPath: m_Pivot.y
|
propertyPath: m_Pivot.y
|
||||||
value: 0
|
value: 0
|
||||||
objectReference: {fileID: 0}
|
objectReference: {fileID: 0}
|
||||||
- target: {fileID: 4122311943219390533, guid: 18f44b986d2754181a3a9695f6898774, type: 3}
|
- target: {fileID: 817218075505996544, guid: 819a22e651d254aeaa6271a8a5008be5, type: 3}
|
||||||
propertyPath: m_AnchorMax.x
|
propertyPath: m_AnchorMax.x
|
||||||
value: 1
|
value: 1
|
||||||
objectReference: {fileID: 0}
|
objectReference: {fileID: 0}
|
||||||
- target: {fileID: 4122311943219390533, guid: 18f44b986d2754181a3a9695f6898774, type: 3}
|
- target: {fileID: 817218075505996544, guid: 819a22e651d254aeaa6271a8a5008be5, type: 3}
|
||||||
propertyPath: m_AnchorMax.y
|
propertyPath: m_AnchorMax.y
|
||||||
value: 1
|
value: 1
|
||||||
objectReference: {fileID: 0}
|
objectReference: {fileID: 0}
|
||||||
- target: {fileID: 4122311943219390533, guid: 18f44b986d2754181a3a9695f6898774, type: 3}
|
- target: {fileID: 817218075505996544, guid: 819a22e651d254aeaa6271a8a5008be5, type: 3}
|
||||||
propertyPath: m_AnchorMin.x
|
propertyPath: m_AnchorMin.x
|
||||||
value: 0
|
value: 0
|
||||||
objectReference: {fileID: 0}
|
objectReference: {fileID: 0}
|
||||||
- target: {fileID: 4122311943219390533, guid: 18f44b986d2754181a3a9695f6898774, type: 3}
|
- target: {fileID: 817218075505996544, guid: 819a22e651d254aeaa6271a8a5008be5, type: 3}
|
||||||
propertyPath: m_AnchorMin.y
|
propertyPath: m_AnchorMin.y
|
||||||
value: 0
|
value: 0
|
||||||
objectReference: {fileID: 0}
|
objectReference: {fileID: 0}
|
||||||
- target: {fileID: 4122311943219390533, guid: 18f44b986d2754181a3a9695f6898774, type: 3}
|
- target: {fileID: 817218075505996544, guid: 819a22e651d254aeaa6271a8a5008be5, type: 3}
|
||||||
propertyPath: m_SizeDelta.x
|
propertyPath: m_SizeDelta.x
|
||||||
value: 0
|
value: 0
|
||||||
objectReference: {fileID: 0}
|
objectReference: {fileID: 0}
|
||||||
- target: {fileID: 4122311943219390533, guid: 18f44b986d2754181a3a9695f6898774, type: 3}
|
- target: {fileID: 817218075505996544, guid: 819a22e651d254aeaa6271a8a5008be5, type: 3}
|
||||||
propertyPath: m_SizeDelta.y
|
propertyPath: m_SizeDelta.y
|
||||||
value: 0
|
value: 0
|
||||||
objectReference: {fileID: 0}
|
objectReference: {fileID: 0}
|
||||||
- target: {fileID: 4122311943219390533, guid: 18f44b986d2754181a3a9695f6898774, type: 3}
|
- target: {fileID: 817218075505996544, guid: 819a22e651d254aeaa6271a8a5008be5, type: 3}
|
||||||
propertyPath: m_LocalPosition.x
|
propertyPath: m_LocalPosition.x
|
||||||
value: 0
|
value: 0
|
||||||
objectReference: {fileID: 0}
|
objectReference: {fileID: 0}
|
||||||
- target: {fileID: 4122311943219390533, guid: 18f44b986d2754181a3a9695f6898774, type: 3}
|
- target: {fileID: 817218075505996544, guid: 819a22e651d254aeaa6271a8a5008be5, type: 3}
|
||||||
propertyPath: m_LocalPosition.y
|
propertyPath: m_LocalPosition.y
|
||||||
value: 0
|
value: 0
|
||||||
objectReference: {fileID: 0}
|
objectReference: {fileID: 0}
|
||||||
- target: {fileID: 4122311943219390533, guid: 18f44b986d2754181a3a9695f6898774, type: 3}
|
- target: {fileID: 817218075505996544, guid: 819a22e651d254aeaa6271a8a5008be5, type: 3}
|
||||||
propertyPath: m_LocalPosition.z
|
propertyPath: m_LocalPosition.z
|
||||||
value: 0
|
value: 0
|
||||||
objectReference: {fileID: 0}
|
objectReference: {fileID: 0}
|
||||||
- target: {fileID: 4122311943219390533, guid: 18f44b986d2754181a3a9695f6898774, type: 3}
|
- target: {fileID: 817218075505996544, guid: 819a22e651d254aeaa6271a8a5008be5, type: 3}
|
||||||
propertyPath: m_LocalRotation.w
|
propertyPath: m_LocalRotation.w
|
||||||
value: 1
|
value: 1
|
||||||
objectReference: {fileID: 0}
|
objectReference: {fileID: 0}
|
||||||
- target: {fileID: 4122311943219390533, guid: 18f44b986d2754181a3a9695f6898774, type: 3}
|
- target: {fileID: 817218075505996544, guid: 819a22e651d254aeaa6271a8a5008be5, type: 3}
|
||||||
propertyPath: m_LocalRotation.x
|
propertyPath: m_LocalRotation.x
|
||||||
value: 0
|
value: 0
|
||||||
objectReference: {fileID: 0}
|
objectReference: {fileID: 0}
|
||||||
- target: {fileID: 4122311943219390533, guid: 18f44b986d2754181a3a9695f6898774, type: 3}
|
- target: {fileID: 817218075505996544, guid: 819a22e651d254aeaa6271a8a5008be5, type: 3}
|
||||||
propertyPath: m_LocalRotation.y
|
propertyPath: m_LocalRotation.y
|
||||||
value: 0
|
value: 0
|
||||||
objectReference: {fileID: 0}
|
objectReference: {fileID: 0}
|
||||||
- target: {fileID: 4122311943219390533, guid: 18f44b986d2754181a3a9695f6898774, type: 3}
|
- target: {fileID: 817218075505996544, guid: 819a22e651d254aeaa6271a8a5008be5, type: 3}
|
||||||
propertyPath: m_LocalRotation.z
|
propertyPath: m_LocalRotation.z
|
||||||
value: 0
|
value: 0
|
||||||
objectReference: {fileID: 0}
|
objectReference: {fileID: 0}
|
||||||
- target: {fileID: 4122311943219390533, guid: 18f44b986d2754181a3a9695f6898774, type: 3}
|
- target: {fileID: 817218075505996544, guid: 819a22e651d254aeaa6271a8a5008be5, type: 3}
|
||||||
propertyPath: m_AnchoredPosition.x
|
propertyPath: m_AnchoredPosition.x
|
||||||
value: 0
|
value: 0
|
||||||
objectReference: {fileID: 0}
|
objectReference: {fileID: 0}
|
||||||
- target: {fileID: 4122311943219390533, guid: 18f44b986d2754181a3a9695f6898774, type: 3}
|
- target: {fileID: 817218075505996544, guid: 819a22e651d254aeaa6271a8a5008be5, type: 3}
|
||||||
propertyPath: m_AnchoredPosition.y
|
propertyPath: m_AnchoredPosition.y
|
||||||
value: 0
|
value: 0
|
||||||
objectReference: {fileID: 0}
|
objectReference: {fileID: 0}
|
||||||
- target: {fileID: 4122311943219390533, guid: 18f44b986d2754181a3a9695f6898774, type: 3}
|
- target: {fileID: 817218075505996544, guid: 819a22e651d254aeaa6271a8a5008be5, type: 3}
|
||||||
propertyPath: m_LocalEulerAnglesHint.x
|
propertyPath: m_LocalEulerAnglesHint.x
|
||||||
value: 0
|
value: 0
|
||||||
objectReference: {fileID: 0}
|
objectReference: {fileID: 0}
|
||||||
- target: {fileID: 4122311943219390533, guid: 18f44b986d2754181a3a9695f6898774, type: 3}
|
- target: {fileID: 817218075505996544, guid: 819a22e651d254aeaa6271a8a5008be5, type: 3}
|
||||||
propertyPath: m_LocalEulerAnglesHint.y
|
propertyPath: m_LocalEulerAnglesHint.y
|
||||||
value: 0
|
value: 0
|
||||||
objectReference: {fileID: 0}
|
objectReference: {fileID: 0}
|
||||||
- target: {fileID: 4122311943219390533, guid: 18f44b986d2754181a3a9695f6898774, type: 3}
|
- target: {fileID: 817218075505996544, guid: 819a22e651d254aeaa6271a8a5008be5, type: 3}
|
||||||
propertyPath: m_LocalEulerAnglesHint.z
|
propertyPath: m_LocalEulerAnglesHint.z
|
||||||
value: 0
|
value: 0
|
||||||
objectReference: {fileID: 0}
|
objectReference: {fileID: 0}
|
||||||
- target: {fileID: 6354229259033361249, guid: 18f44b986d2754181a3a9695f6898774, type: 3}
|
- target: {fileID: 1093900508746780041, guid: 819a22e651d254aeaa6271a8a5008be5, type: 3}
|
||||||
propertyPath: m_Name
|
propertyPath: m_Name
|
||||||
value: DialogMinimalUI
|
value: CodexPanelComponentUI
|
||||||
objectReference: {fileID: 0}
|
objectReference: {fileID: 0}
|
||||||
m_RemovedComponents: []
|
m_RemovedComponents: []
|
||||||
m_RemovedGameObjects: []
|
m_RemovedGameObjects: []
|
||||||
m_AddedGameObjects:
|
m_AddedGameObjects:
|
||||||
- targetCorrespondingSourceObject: {fileID: 9098186480249319762, guid: 18f44b986d2754181a3a9695f6898774, type: 3}
|
- targetCorrespondingSourceObject: {fileID: 4490832776911535242, guid: 819a22e651d254aeaa6271a8a5008be5, type: 3}
|
||||||
insertIndex: -1
|
insertIndex: -1
|
||||||
addedObject: {fileID: 3246175779987903493}
|
addedObject: {fileID: 3246175779987903493}
|
||||||
m_AddedComponents: []
|
m_AddedComponents: []
|
||||||
m_SourcePrefab: {fileID: 100100000, guid: 18f44b986d2754181a3a9695f6898774, type: 3}
|
m_SourcePrefab: {fileID: 100100000, guid: 819a22e651d254aeaa6271a8a5008be5, type: 3}
|
||||||
--- !u!114 &1558540297844798833 stripped
|
--- !u!224 &227485419669739136 stripped
|
||||||
|
RectTransform:
|
||||||
|
m_CorrespondingSourceObject: {fileID: 817218075505996544, guid: 819a22e651d254aeaa6271a8a5008be5, type: 3}
|
||||||
|
m_PrefabInstance: {fileID: 612321642549273984}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
--- !u!224 &3903991783760124170 stripped
|
||||||
|
RectTransform:
|
||||||
|
m_CorrespondingSourceObject: {fileID: 4490832776911535242, guid: 819a22e651d254aeaa6271a8a5008be5, type: 3}
|
||||||
|
m_PrefabInstance: {fileID: 612321642549273984}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
--- !u!114 &8338704736818780985 stripped
|
||||||
MonoBehaviour:
|
MonoBehaviour:
|
||||||
m_CorrespondingSourceObject: {fileID: 5726211398848915583, guid: 18f44b986d2754181a3a9695f6898774, type: 3}
|
m_CorrespondingSourceObject: {fileID: 8918922271643254457, guid: 819a22e651d254aeaa6271a8a5008be5, type: 3}
|
||||||
m_PrefabInstance: {fileID: 6545589296576142606}
|
m_PrefabInstance: {fileID: 612321642549273984}
|
||||||
m_PrefabAsset: {fileID: 0}
|
m_PrefabAsset: {fileID: 0}
|
||||||
m_GameObject: {fileID: 0}
|
m_GameObject: {fileID: 0}
|
||||||
m_Enabled: 1
|
m_Enabled: 1
|
||||||
m_EditorHideFlags: 0
|
m_EditorHideFlags: 0
|
||||||
m_Script: {fileID: 11500000, guid: 4e18be9fb855467faaccf816be3291c7, type: 3}
|
m_Script: {fileID: 11500000, guid: d3124472724d4e3c84499514f80267f6, type: 3}
|
||||||
m_Name:
|
m_Name:
|
||||||
m_EditorClassIdentifier:
|
m_EditorClassIdentifier: Gameplay::Intrepid.Gameplay.Codex.UI.CodexPanelUI
|
||||||
--- !u!224 &2636253603181931612 stripped
|
|
||||||
RectTransform:
|
|
||||||
m_CorrespondingSourceObject: {fileID: 9098186480249319762, guid: 18f44b986d2754181a3a9695f6898774, type: 3}
|
|
||||||
m_PrefabInstance: {fileID: 6545589296576142606}
|
|
||||||
m_PrefabAsset: {fileID: 0}
|
|
||||||
--- !u!224 &7197876000195360075 stripped
|
|
||||||
RectTransform:
|
|
||||||
m_CorrespondingSourceObject: {fileID: 4122311943219390533, guid: 18f44b986d2754181a3a9695f6898774, type: 3}
|
|
||||||
m_PrefabInstance: {fileID: 6545589296576142606}
|
|
||||||
m_PrefabAsset: {fileID: 0}
|
|
||||||
--- !u!1001 &7187118986409248990
|
--- !u!1001 &7187118986409248990
|
||||||
PrefabInstance:
|
PrefabInstance:
|
||||||
m_ObjectHideFlags: 0
|
m_ObjectHideFlags: 0
|
||||||
|
|||||||
File diff suppressed because one or more lines are too long
@ -3,6 +3,8 @@ using System.Collections.Generic;
|
|||||||
using Intrepid.GameManagers;
|
using Intrepid.GameManagers;
|
||||||
using Intrepid.Gameplay.Codex.Knowledge;
|
using Intrepid.Gameplay.Codex.Knowledge;
|
||||||
using Intrepid.Gameplay.Codex.Knowledge.Events;
|
using Intrepid.Gameplay.Codex.Knowledge.Events;
|
||||||
|
using Intrepid.Gameplay.Codex.Music;
|
||||||
|
using Intrepid.Gameplay.Codex.Music.Events;
|
||||||
using Intrepid.Gameplay.Codex.Visual;
|
using Intrepid.Gameplay.Codex.Visual;
|
||||||
using Intrepid.Gameplay.Codex.Visual.Events;
|
using Intrepid.Gameplay.Codex.Visual.Events;
|
||||||
using Intrepid.SimpleEvents;
|
using Intrepid.SimpleEvents;
|
||||||
@ -10,23 +12,23 @@ using UnityEngine;
|
|||||||
|
|
||||||
namespace Intrepid.Gameplay.Codex
|
namespace Intrepid.Gameplay.Codex
|
||||||
{
|
{
|
||||||
/// <summary>
|
|
||||||
/// Runtime owner of what the CODEX currently knows.
|
|
||||||
/// This is intentionally separated from PDA runtime state.
|
|
||||||
/// </summary>
|
|
||||||
public class CodexRuntime : EventListener
|
public class CodexRuntime : EventListener
|
||||||
{
|
{
|
||||||
[SerializeField] private CodexOntology ontology = new();
|
[SerializeField] private CodexKnowledgeInventory knowledgeInventory = new();
|
||||||
[SerializeField] private PictorialProtocolInventory pictorialProtocols = new();
|
[SerializeField] private CodexMusicInventory musicInventory = new();
|
||||||
|
[SerializeField] private PictorialProtocolInventory pictorialProtocolInventory = new();
|
||||||
|
|
||||||
public CodexOntology Ontology => ontology;
|
public CodexKnowledgeInventory KnowledgeInventory => knowledgeInventory;
|
||||||
public PictorialProtocolInventory PictorialProtocols => pictorialProtocols;
|
public CodexMusicInventory MusicInventory => musicInventory;
|
||||||
|
public PictorialProtocolInventory PictorialProtocolInventory => pictorialProtocolInventory;
|
||||||
|
|
||||||
public IReadOnlyList<CodexConceptTag> KnownConcepts => ontology.KnownConcepts;
|
public IReadOnlyList<CodexConceptTag> KnownConcepts => knowledgeInventory.KnownConcepts;
|
||||||
public IReadOnlyList<PictorialProtocolTag> KnownPictorialProtocols => pictorialProtocols.KnownProtocols;
|
public IReadOnlyList<CodexMusicTag> KnownMusic => musicInventory.KnownMusics;
|
||||||
|
public IReadOnlyList<PictorialProtocolTag> KnownPictorialProtocols => pictorialProtocolInventory.KnownProtocols;
|
||||||
|
|
||||||
public bool Knows(CodexConceptTag concept) => ontology.Knows(concept);
|
public bool Knows(CodexConceptTag concept) => knowledgeInventory.Knows(concept);
|
||||||
public bool Knows(PictorialProtocolTag protocol) => pictorialProtocols.Knows(protocol);
|
public bool Knows(CodexMusicTag music) => musicInventory.Knows(music);
|
||||||
|
public bool Knows(PictorialProtocolTag protocol) => pictorialProtocolInventory.Knows(protocol);
|
||||||
|
|
||||||
protected override void InitializeVariables()
|
protected override void InitializeVariables()
|
||||||
{
|
{
|
||||||
@ -46,7 +48,7 @@ namespace Intrepid.Gameplay.Codex
|
|||||||
|
|
||||||
if (Knows(concept)) return;
|
if (Knows(concept)) return;
|
||||||
|
|
||||||
ontology.Learn(concept);
|
knowledgeInventory.Learn(concept);
|
||||||
|
|
||||||
if (!raiseEvent) return;
|
if (!raiseEvent) return;
|
||||||
Proxy.Instance.EventBus.Raise(new CodexConceptLearnedEvent
|
Proxy.Instance.EventBus.Raise(new CodexConceptLearnedEvent
|
||||||
@ -55,13 +57,28 @@ namespace Intrepid.Gameplay.Codex
|
|||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public void Unlock(CodexMusicTag music, bool raiseEvent = true)
|
||||||
|
{
|
||||||
|
if (music.IsNull()) return;
|
||||||
|
|
||||||
|
if (Knows(music)) return;
|
||||||
|
|
||||||
|
musicInventory.Unlock(music);
|
||||||
|
|
||||||
|
if (!raiseEvent) return;
|
||||||
|
Proxy.Instance.EventBus.Raise(new CodexMusicUnlockedEvent
|
||||||
|
{
|
||||||
|
Music = music,
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
public void Unlock(PictorialProtocolTag protocol, bool raiseEvent = true)
|
public void Unlock(PictorialProtocolTag protocol, bool raiseEvent = true)
|
||||||
{
|
{
|
||||||
if (protocol.IsNull()) return;
|
if (protocol.IsNull()) return;
|
||||||
|
|
||||||
if (Knows(protocol)) return;
|
if (Knows(protocol)) return;
|
||||||
|
|
||||||
pictorialProtocols.Unlock(protocol);
|
pictorialProtocolInventory.Unlock(protocol);
|
||||||
|
|
||||||
if (!raiseEvent) return;
|
if (!raiseEvent) return;
|
||||||
Proxy.Instance.EventBus.Raise(new PictorialProtocolUnlockedEvent
|
Proxy.Instance.EventBus.Raise(new PictorialProtocolUnlockedEvent
|
||||||
|
|||||||
@ -1,12 +1,11 @@
|
|||||||
using System;
|
using System;
|
||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
using System.Linq;
|
|
||||||
using Intrepid.Utilities;
|
using Intrepid.Utilities;
|
||||||
using Sirenix.OdinInspector;
|
using Sirenix.OdinInspector;
|
||||||
|
using UnityEngine;
|
||||||
#if UNITY_EDITOR
|
#if UNITY_EDITOR
|
||||||
using UnityEditor;
|
using UnityEditor;
|
||||||
#endif
|
#endif
|
||||||
using UnityEngine;
|
|
||||||
|
|
||||||
namespace Intrepid.Gameplay.Codex.Knowledge
|
namespace Intrepid.Gameplay.Codex.Knowledge
|
||||||
{
|
{
|
||||||
@ -16,8 +15,6 @@ namespace Intrepid.Gameplay.Codex.Knowledge
|
|||||||
{
|
{
|
||||||
[GroupInjections, SerializeField] private List<CodexConceptTag> concepts = new();
|
[GroupInjections, SerializeField] private List<CodexConceptTag> concepts = new();
|
||||||
|
|
||||||
public IReadOnlyList<CodexConceptTag> Concepts => concepts.Where(c => c.IsNotNull()).Distinct().ToList();
|
|
||||||
|
|
||||||
public bool Contains(CodexConceptTag concept)
|
public bool Contains(CodexConceptTag concept)
|
||||||
{
|
{
|
||||||
return concept.IsNotNull() && concepts.Contains(concept);
|
return concept.IsNotNull() && concepts.Contains(concept);
|
||||||
@ -33,8 +30,8 @@ namespace Intrepid.Gameplay.Codex.Knowledge
|
|||||||
foreach (var guid in guids)
|
foreach (var guid in guids)
|
||||||
{
|
{
|
||||||
var path = AssetDatabase.GUIDToAssetPath(guid);
|
var path = AssetDatabase.GUIDToAssetPath(guid);
|
||||||
var protocol = AssetDatabase.LoadAssetAtPath<CodexConceptTag>(path);
|
var concept = AssetDatabase.LoadAssetAtPath<CodexConceptTag>(path);
|
||||||
concepts.Add(protocol);
|
concepts.Add(concept);
|
||||||
}
|
}
|
||||||
EditorUtility.SetDirty(this);
|
EditorUtility.SetDirty(this);
|
||||||
}
|
}
|
||||||
|
|||||||
@ -8,8 +8,8 @@ using UnityEngine;
|
|||||||
namespace Intrepid.Gameplay.Codex.Knowledge
|
namespace Intrepid.Gameplay.Codex.Knowledge
|
||||||
{
|
{
|
||||||
[Serializable]
|
[Serializable]
|
||||||
[GroupConfigurations("Codex Ontology"), HideLabel]
|
[GroupConfigurations("Codex Knowledge Inventory"), HideLabel]
|
||||||
public class CodexOntology
|
public class CodexKnowledgeInventory
|
||||||
{
|
{
|
||||||
[SerializeField] private List<CodexConceptTag> knownConcepts = new();
|
[SerializeField] private List<CodexConceptTag> knownConcepts = new();
|
||||||
|
|
||||||
3
Assets/Scripts/Intrepid/Gameplay/Codex/Music.meta
Normal file
3
Assets/Scripts/Intrepid/Gameplay/Codex/Music.meta
Normal file
@ -0,0 +1,3 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: f43308bff5f5431aa61f3756ccc3fb6d
|
||||||
|
timeCreated: 1783412469
|
||||||
@ -0,0 +1,13 @@
|
|||||||
|
using System;
|
||||||
|
using Intrepid.Sound;
|
||||||
|
using UnityEngine;
|
||||||
|
|
||||||
|
namespace Intrepid.Gameplay.Codex.Music
|
||||||
|
{
|
||||||
|
[Serializable]
|
||||||
|
[CreateAssetMenu(fileName = "New Codex Music Data", menuName = "GON/CODEX/Music/Music Data")]
|
||||||
|
public class CodexMusicData : SoundArtifactData
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
}
|
||||||
@ -0,0 +1,3 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: ed051ecaf077411f9c01477b445009a9
|
||||||
|
timeCreated: 1783412622
|
||||||
@ -0,0 +1,45 @@
|
|||||||
|
using System;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using System.Linq;
|
||||||
|
using Intrepid.Utilities;
|
||||||
|
using Sirenix.OdinInspector;
|
||||||
|
using UnityEngine;
|
||||||
|
|
||||||
|
namespace Intrepid.Gameplay.Codex.Music
|
||||||
|
{
|
||||||
|
[Serializable]
|
||||||
|
[GroupConfigurations("Codex Music Inventory"), HideLabel]
|
||||||
|
public class CodexMusicInventory
|
||||||
|
{
|
||||||
|
[SerializeField] private List<CodexMusicTag> knownMusics = new();
|
||||||
|
|
||||||
|
public IReadOnlyList<CodexMusicTag> KnownMusics => knownMusics.Where(c => c.IsNotNull()).Distinct().ToList();
|
||||||
|
|
||||||
|
public bool Knows(CodexMusicTag music)
|
||||||
|
{
|
||||||
|
return music.IsNotNull() && knownMusics.Contains(music);
|
||||||
|
}
|
||||||
|
|
||||||
|
public bool Unlock(CodexMusicTag music)
|
||||||
|
{
|
||||||
|
if (music.IsNull()) return false;
|
||||||
|
if (knownMusics.Contains(music)) return false;
|
||||||
|
knownMusics.Add(music);
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
|
||||||
|
public bool Forget(CodexMusicTag music)
|
||||||
|
{
|
||||||
|
if (music.IsNull()) return false;
|
||||||
|
return knownMusics.Remove(music);
|
||||||
|
}
|
||||||
|
|
||||||
|
#if UNITY_EDITOR
|
||||||
|
[GroupDebug, Button(ButtonSizes.Medium)]
|
||||||
|
private void CleanupKnownConcepts()
|
||||||
|
{
|
||||||
|
knownMusics = knownMusics.Where(c => c.IsNotNull()).Distinct().ToList();
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
}
|
||||||
|
}
|
||||||
@ -0,0 +1,3 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 62309ec39bb24dc38dea18416bdff64c
|
||||||
|
timeCreated: 1783413096
|
||||||
@ -0,0 +1,40 @@
|
|||||||
|
using System;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using Intrepid.Utilities;
|
||||||
|
using Sirenix.OdinInspector;
|
||||||
|
using UnityEngine;
|
||||||
|
#if UNITY_EDITOR
|
||||||
|
using UnityEditor;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
namespace Intrepid.Gameplay.Codex.Music
|
||||||
|
{
|
||||||
|
[Serializable]
|
||||||
|
[CreateAssetMenu(fileName = "Codex - Music Library", menuName = "GON/CODEX/Music/Music Library")]
|
||||||
|
public class CodexMusicLibrary : SingletonScriptableObject<CodexMusicLibrary>
|
||||||
|
{
|
||||||
|
[GroupInjections, SerializeField] private List<CodexMusicTag> musics = new();
|
||||||
|
|
||||||
|
public bool Contains(CodexMusicTag music)
|
||||||
|
{
|
||||||
|
return music.IsNotNull() && musics.Contains(music);
|
||||||
|
}
|
||||||
|
|
||||||
|
#if UNITY_EDITOR
|
||||||
|
[PropertyOrder(-10)]
|
||||||
|
[GroupInjections, Button(ButtonSizes.Large), GUIColor(0.35f, 0.8f, .35f)]
|
||||||
|
protected void FindAll()
|
||||||
|
{
|
||||||
|
musics.Clear();
|
||||||
|
var guids = AssetDatabase.FindAssets($"t:{nameof(CodexMusicTag)}");
|
||||||
|
foreach (var guid in guids)
|
||||||
|
{
|
||||||
|
var path = AssetDatabase.GUIDToAssetPath(guid);
|
||||||
|
var music = AssetDatabase.LoadAssetAtPath<CodexMusicTag>(path);
|
||||||
|
musics.Add(music);
|
||||||
|
}
|
||||||
|
EditorUtility.SetDirty(this);
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
}
|
||||||
|
}
|
||||||
@ -0,0 +1,3 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: b8faf070b3de45e486795f961bda3811
|
||||||
|
timeCreated: 1783412488
|
||||||
@ -0,0 +1,21 @@
|
|||||||
|
using System;
|
||||||
|
using Intrepid.Localization;
|
||||||
|
using Intrepid.TagSystem;
|
||||||
|
using Intrepid.Utilities;
|
||||||
|
using UnityEngine;
|
||||||
|
|
||||||
|
namespace Intrepid.Gameplay.Codex.Music
|
||||||
|
{
|
||||||
|
[Serializable]
|
||||||
|
[CreateAssetMenu(fileName = "New Music Tag", menuName = "GON/CODEX/Music/Music Tag")]
|
||||||
|
public class CodexMusicTag : Tag
|
||||||
|
{
|
||||||
|
[GroupConfigurations, SerializeField] private LocalizationTag localization;
|
||||||
|
[GroupConfigurations, SerializeField] private LocalizationTag description;
|
||||||
|
[GroupInjections, SerializeField] private CodexMusicData musicData;
|
||||||
|
|
||||||
|
public LocalizationTag Localization => localization;
|
||||||
|
public LocalizationTag Description => description;
|
||||||
|
public CodexMusicData MusicData => musicData;
|
||||||
|
}
|
||||||
|
}
|
||||||
@ -0,0 +1,3 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: e42018e806cf41858031e58910aff21f
|
||||||
|
timeCreated: 1783412564
|
||||||
3
Assets/Scripts/Intrepid/Gameplay/Codex/Music/Events.meta
Normal file
3
Assets/Scripts/Intrepid/Gameplay/Codex/Music/Events.meta
Normal file
@ -0,0 +1,3 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: cb6a93e361df492b9a1b353061b061bf
|
||||||
|
timeCreated: 1783413404
|
||||||
@ -0,0 +1,9 @@
|
|||||||
|
using Intrepid.SimpleEvents;
|
||||||
|
|
||||||
|
namespace Intrepid.Gameplay.Codex.Music.Events
|
||||||
|
{
|
||||||
|
public class CodexMusicUnlockedEvent : IEventBase
|
||||||
|
{
|
||||||
|
public CodexMusicTag Music { get; set; }
|
||||||
|
}
|
||||||
|
}
|
||||||
@ -0,0 +1,3 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 8761bae5d84540c3ac3ebcb8d80953bd
|
||||||
|
timeCreated: 1783413408
|
||||||
@ -37,7 +37,7 @@ namespace Intrepid.Gameplay.Codex.Visual
|
|||||||
}
|
}
|
||||||
|
|
||||||
[GroupDebug, Button(ButtonSizes.Medium, ButtonStyle.FoldoutButton)]
|
[GroupDebug, Button(ButtonSizes.Medium, ButtonStyle.FoldoutButton)]
|
||||||
public void ApplyTheme(PictorialProtocolTag protocol)
|
public void ApplyProtocol(PictorialProtocolTag protocol)
|
||||||
{
|
{
|
||||||
if (CurrentPictorialProtocol == protocol) return;
|
if (CurrentPictorialProtocol == protocol) return;
|
||||||
currentProtocol = protocol;
|
currentProtocol = protocol;
|
||||||
|
|||||||
@ -1,27 +1,20 @@
|
|||||||
using System;
|
using System;
|
||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
using System.Linq;
|
|
||||||
using Intrepid.Utilities;
|
using Intrepid.Utilities;
|
||||||
using Sirenix.OdinInspector;
|
using Sirenix.OdinInspector;
|
||||||
|
using UnityEngine;
|
||||||
#if UNITY_EDITOR
|
#if UNITY_EDITOR
|
||||||
using UnityEditor;
|
using UnityEditor;
|
||||||
#endif
|
#endif
|
||||||
using UnityEngine;
|
|
||||||
|
|
||||||
namespace Intrepid.Gameplay.Codex.Visual
|
namespace Intrepid.Gameplay.Codex.Visual
|
||||||
{
|
{
|
||||||
/// <summary>
|
|
||||||
/// Catalog of all pictorial protocols available in the game.
|
|
||||||
/// Currently uses the existing Theme asset as the concrete protocol asset.
|
|
||||||
/// </summary>
|
|
||||||
[Serializable]
|
[Serializable]
|
||||||
[CreateAssetMenu(fileName = "Codex - Pictorial Protocol Library", menuName = "GON/CODEX/Visual/Pictorial Protocol Library")]
|
[CreateAssetMenu(fileName = "Codex - Pictorial Protocol Library", menuName = "GON/CODEX/Visual/Pictorial Protocol Library")]
|
||||||
public class PictorialProtocolLibrary : SingletonScriptableObject<PictorialProtocolLibrary>
|
public class PictorialProtocolLibrary : SingletonScriptableObject<PictorialProtocolLibrary>
|
||||||
{
|
{
|
||||||
[GroupInjections, SerializeField, ReadOnly] private List<PictorialProtocolTag> protocols;
|
[GroupInjections, SerializeField, ReadOnly] private List<PictorialProtocolTag> protocols;
|
||||||
|
|
||||||
public IReadOnlyList<PictorialProtocolTag> Protocols => protocols.Where(p => p.IsNotNull()).Distinct().ToList();
|
|
||||||
|
|
||||||
public bool Contains(PictorialProtocolTag protocol)
|
public bool Contains(PictorialProtocolTag protocol)
|
||||||
{
|
{
|
||||||
return protocol is not null && protocols.Contains(protocol);
|
return protocol is not null && protocols.Contains(protocol);
|
||||||
|
|||||||
@ -7,7 +7,7 @@ using UnityEngine;
|
|||||||
|
|
||||||
namespace Intrepid.Gameplay.Entities.Player.ActionBelt
|
namespace Intrepid.Gameplay.Entities.Player.ActionBelt
|
||||||
{
|
{
|
||||||
public class ActionBeltManager : EventListener
|
public class ActionBeltRuntime : EventListener
|
||||||
{
|
{
|
||||||
[GroupConfigurations, SerializeField] private bool nextRight = true;
|
[GroupConfigurations, SerializeField] private bool nextRight = true;
|
||||||
|
|
||||||
@ -12,7 +12,7 @@ namespace Intrepid.Gameplay.Entities.Player.ActionBelt.UI
|
|||||||
{
|
{
|
||||||
public class CodexActionBeltUI : CodexWindowUI
|
public class CodexActionBeltUI : CodexWindowUI
|
||||||
{
|
{
|
||||||
[GroupInjections, SerializeField] private ActionBeltManager actionBeltManager;
|
[GroupInjections, SerializeField] private ActionBeltRuntime actionBeltRuntime;
|
||||||
[GroupInjections, SerializeField] private CodexActionBeltSlotControllerUI left;
|
[GroupInjections, SerializeField] private CodexActionBeltSlotControllerUI left;
|
||||||
[GroupInjections, SerializeField] private CodexActionBeltSlotControllerUI right;
|
[GroupInjections, SerializeField] private CodexActionBeltSlotControllerUI right;
|
||||||
[GroupInjections, SerializeField] private CodexActionBeltControllerUI center;
|
[GroupInjections, SerializeField] private CodexActionBeltControllerUI center;
|
||||||
@ -27,10 +27,10 @@ namespace Intrepid.Gameplay.Entities.Player.ActionBelt.UI
|
|||||||
protected override void InitializeVariables()
|
protected override void InitializeVariables()
|
||||||
{
|
{
|
||||||
base.InitializeVariables();
|
base.InitializeVariables();
|
||||||
GetFocus = () => actionBeltManager.Focus;
|
GetFocus = () => actionBeltRuntime.Focus;
|
||||||
SneakPeekRight = () => actionBeltManager.PeekRight;
|
SneakPeekRight = () => actionBeltRuntime.PeekRight;
|
||||||
SneakPeekLeft = () => actionBeltManager.PeekLeft;
|
SneakPeekLeft = () => actionBeltRuntime.PeekLeft;
|
||||||
GetNumberOfActionsInBelt = () => actionBeltManager.Count;
|
GetNumberOfActionsInBelt = () => actionBeltRuntime.Count;
|
||||||
}
|
}
|
||||||
|
|
||||||
protected override void Subscriptions()
|
protected override void Subscriptions()
|
||||||
@ -72,7 +72,7 @@ namespace Intrepid.Gameplay.Entities.Player.ActionBelt.UI
|
|||||||
|
|
||||||
private void WhenActionBeltUIDrop(ActionBeltUIDropEvent e)
|
private void WhenActionBeltUIDrop(ActionBeltUIDropEvent e)
|
||||||
{
|
{
|
||||||
if (!actionBeltManager.IsOperational) return;
|
if (!actionBeltRuntime.IsOperational) return;
|
||||||
center.Drop();
|
center.Drop();
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -92,7 +92,7 @@ namespace Intrepid.Gameplay.Entities.Player.ActionBelt.UI
|
|||||||
|
|
||||||
private void WhenActionBeltNextRight(ActionBeltUIToRightEvent e)
|
private void WhenActionBeltNextRight(ActionBeltUIToRightEvent e)
|
||||||
{
|
{
|
||||||
if (!actionBeltManager.IsOperational) return;
|
if (!actionBeltRuntime.IsOperational) return;
|
||||||
if (!IsOptionActive) return;
|
if (!IsOptionActive) return;
|
||||||
SwitchRight();
|
SwitchRight();
|
||||||
center.Reset();
|
center.Reset();
|
||||||
@ -101,7 +101,7 @@ namespace Intrepid.Gameplay.Entities.Player.ActionBelt.UI
|
|||||||
|
|
||||||
private void WhenActionBeltNextLeft(ActionBeltUIToLeftEvent e)
|
private void WhenActionBeltNextLeft(ActionBeltUIToLeftEvent e)
|
||||||
{
|
{
|
||||||
if (!actionBeltManager.IsOperational) return;
|
if (!actionBeltRuntime.IsOperational) return;
|
||||||
if (!IsOptionActive) return;
|
if (!IsOptionActive) return;
|
||||||
SwitchLeft();
|
SwitchLeft();
|
||||||
center.Reset();
|
center.Reset();
|
||||||
@ -110,7 +110,7 @@ namespace Intrepid.Gameplay.Entities.Player.ActionBelt.UI
|
|||||||
|
|
||||||
private void WhenActionBeltUITakeAction(ActionBeltUITakeActionEvent e)
|
private void WhenActionBeltUITakeAction(ActionBeltUITakeActionEvent e)
|
||||||
{
|
{
|
||||||
if (!actionBeltManager.IsOperational) return;
|
if (!actionBeltRuntime.IsOperational) return;
|
||||||
activationProgress.ResetProgress();
|
activationProgress.ResetProgress();
|
||||||
center.ActionTaken();
|
center.ActionTaken();
|
||||||
StartCoroutine(UpdateContentNextFrame());
|
StartCoroutine(UpdateContentNextFrame());
|
||||||
@ -118,7 +118,7 @@ namespace Intrepid.Gameplay.Entities.Player.ActionBelt.UI
|
|||||||
|
|
||||||
private void Update()
|
private void Update()
|
||||||
{
|
{
|
||||||
if (!actionBeltManager.IsOperational)
|
if (!actionBeltRuntime.IsOperational)
|
||||||
{
|
{
|
||||||
activationProgress.ResetProgress();
|
activationProgress.ResetProgress();
|
||||||
Proxy.Instance.EventBus.Raise(new ActionBeltUICloseEvent());
|
Proxy.Instance.EventBus.Raise(new ActionBeltUICloseEvent());
|
||||||
|
|||||||
@ -0,0 +1,10 @@
|
|||||||
|
using Intrepid.SimpleEvents;
|
||||||
|
|
||||||
|
namespace Intrepid.Gameplay.Entities.Player.PDA.Events
|
||||||
|
{
|
||||||
|
public class PDAInstallExternalAppEvent : IEventBase
|
||||||
|
{
|
||||||
|
public PDAContentTag ContentTag { get; set; }
|
||||||
|
public (string, object)[] Parameters { get; set; }
|
||||||
|
}
|
||||||
|
}
|
||||||
@ -0,0 +1,3 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 7031b1dbe8d445c7863f664da86db4a3
|
||||||
|
timeCreated: 1783414438
|
||||||
@ -0,0 +1,9 @@
|
|||||||
|
using Intrepid.SimpleEvents;
|
||||||
|
|
||||||
|
namespace Intrepid.Gameplay.Entities.Player.PDA.Events
|
||||||
|
{
|
||||||
|
public class PDARemoveExternalAppEvent : IEventBase
|
||||||
|
{
|
||||||
|
public PDAContentTag ContentTag { get; set; }
|
||||||
|
}
|
||||||
|
}
|
||||||
@ -0,0 +1,3 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 6cb5ede05ad94f83b1154326fdf86862
|
||||||
|
timeCreated: 1783414485
|
||||||
@ -2,22 +2,24 @@ using System;
|
|||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
using Intrepid.Gameplay.Entities.Player.PDA.UI;
|
using Intrepid.Gameplay.Entities.Player.PDA.UI;
|
||||||
using Intrepid.Structures;
|
using Intrepid.Structures;
|
||||||
|
using Intrepid.Utilities;
|
||||||
|
using Sirenix.OdinInspector;
|
||||||
using UnityEngine;
|
using UnityEngine;
|
||||||
|
|
||||||
namespace Intrepid.Gameplay.Entities.Player.PDA
|
namespace Intrepid.Gameplay.Entities.Player.PDA
|
||||||
{
|
{
|
||||||
[Serializable]
|
[Serializable]
|
||||||
[CreateAssetMenu(fileName = "Application Library", menuName = "Intrepid/PDA/Application Library")]
|
[CreateAssetMenu(fileName = "Application Library", menuName = "Intrepid/PDA/Application Library")]
|
||||||
public class PDAApplicationLibraryData : ScriptableObject
|
public class PDAApplicationLibrary : ScriptableObject
|
||||||
{
|
{
|
||||||
[SerializeField] private List<PDAApplicationUI> applicationPrefabs;
|
[GroupInjections("Prefabs"), SerializeField] private List<PDAApplicationUI> apps;
|
||||||
|
|
||||||
private SDictionary<PDAContentTag, PDAApplicationUI> ApplicationPrefabs { get; } = new();
|
private SDictionary<PDAContentTag, PDAApplicationUI> ApplicationPrefabs { get; } = new();
|
||||||
|
|
||||||
private void OnEnable()
|
private void OnEnable()
|
||||||
{
|
{
|
||||||
ApplicationPrefabs.Clear();
|
ApplicationPrefabs.Clear();
|
||||||
foreach (var prefab in applicationPrefabs)
|
foreach (var prefab in apps)
|
||||||
{
|
{
|
||||||
ApplicationPrefabs.Add(prefab.ContentTag, prefab);
|
ApplicationPrefabs.Add(prefab.ContentTag, prefab);
|
||||||
}
|
}
|
||||||
@ -1,101 +1,101 @@
|
|||||||
using System;
|
// using System;
|
||||||
using System.Collections.Generic;
|
// using System.Collections.Generic;
|
||||||
using System.Linq;
|
// using System.Linq;
|
||||||
using Intrepid.Gameplay.Entities.Player.PDA.Inputs;
|
// using Intrepid.Gameplay.Entities.Player.PDA.Inputs;
|
||||||
using Intrepid.Gameplay.Themes;
|
// using Intrepid.Gameplay.Themes;
|
||||||
using Intrepid.Sound;
|
// using Intrepid.Sound;
|
||||||
using Intrepid.Structures;
|
// using Intrepid.Structures;
|
||||||
using Intrepid.Utilities;
|
// using Intrepid.Utilities;
|
||||||
using Sirenix.OdinInspector;
|
// using Sirenix.OdinInspector;
|
||||||
using UnityEngine;
|
// using UnityEngine;
|
||||||
|
//
|
||||||
namespace Intrepid.Gameplay.Entities.Player.PDA
|
// namespace Intrepid.Gameplay.Entities.Player.PDA
|
||||||
{
|
// {
|
||||||
[Serializable]
|
// [Serializable]
|
||||||
[CreateAssetMenu(fileName = "PDA Device", menuName = "GON/PDA/PDA Device")]
|
// [CreateAssetMenu(fileName = "PDA Device", menuName = "GON/PDA/PDA Device")]
|
||||||
public class PDADevice : ScriptableObject
|
// public class PDADevice : ScriptableObject
|
||||||
{
|
// {
|
||||||
[GroupConfigurations("Prefabs"), SerializeField] private PDAApplicationLibraryData applicationLibrary;
|
// [GroupConfigurations("Prefabs"), SerializeField] private PDAApplicationLibrary applicationLibrary;
|
||||||
|
//
|
||||||
[GroupConfigurations("Music"), SerializeField] private List<SoundMusicData> musicKnown;
|
// [GroupConfigurations("Music"), SerializeField] private List<SoundMusicData> musicKnown;
|
||||||
[GroupConfigurations("Themes"), SerializeField] private List<Theme> themesKnown;
|
// [GroupConfigurations("Themes"), SerializeField] private List<Theme> themesKnown;
|
||||||
|
//
|
||||||
[GroupConfigurations("Apps"), SerializeField] private PDAContentTag overrideApp;
|
// [GroupConfigurations("Apps"), SerializeField] private PDAContentTag overrideApp;
|
||||||
[GroupConfigurations("Apps"), SerializeField] private List<PDAContentTag> inMemoryApps;
|
// [GroupConfigurations("Apps"), SerializeField] private List<PDAContentTag> inMemoryApps;
|
||||||
[GroupConfigurations("Apps"), SerializeField] private List<PDAContentTag> externalApps;
|
// [GroupConfigurations("Apps"), SerializeField] private List<PDAContentTag> externalApps;
|
||||||
|
//
|
||||||
[GroupDebug, ShowInInspector, ReadOnly] public ParameterStore ParameterStore { get; private set; } = new();
|
// [GroupDebug, ShowInInspector, ReadOnly] public ParameterStore ParameterStore { get; private set; } = new();
|
||||||
private List<PDAContentTag> InMemoryApps => inMemoryApps;
|
// private List<PDAContentTag> InMemoryApps => inMemoryApps;
|
||||||
private List<PDAContentTag> ExternalApps => externalApps;
|
// private List<PDAContentTag> ExternalApps => externalApps;
|
||||||
public PDAContentTag OverrideApp => overrideApp;
|
// public PDAContentTag OverrideApp => overrideApp;
|
||||||
public PDAInputs PDAInputs => PlayerInputResolver.Instance.PDA;
|
// public PDAInputs PDAInputs => PlayerInputResolver.Instance.PDA;
|
||||||
|
//
|
||||||
private void OnEnable()
|
// private void OnEnable()
|
||||||
{
|
// {
|
||||||
ExternalApps.Clear();
|
// ExternalApps.Clear();
|
||||||
ParameterStore.Clear();
|
// ParameterStore.Clear();
|
||||||
}
|
// }
|
||||||
|
//
|
||||||
public Func<MonoBehaviour> ApplicationLoader(PDAContentTag contentTag, Transform parent)
|
// public Func<MonoBehaviour> ApplicationLoader(PDAContentTag contentTag, Transform parent)
|
||||||
{
|
// {
|
||||||
return () => applicationLibrary.Load(contentTag, parent);
|
// return () => applicationLibrary.Load(contentTag, parent);
|
||||||
}
|
// }
|
||||||
|
//
|
||||||
public List<SoundMusicData> GetMusicKnown()
|
// public List<SoundMusicData> GetMusicKnown()
|
||||||
{
|
// {
|
||||||
return musicKnown;
|
// return musicKnown;
|
||||||
}
|
// }
|
||||||
|
//
|
||||||
public List<Theme> GetThemesKnown()
|
// public List<Theme> GetThemesKnown()
|
||||||
{
|
// {
|
||||||
return themesKnown;
|
// return themesKnown;
|
||||||
}
|
// }
|
||||||
|
//
|
||||||
public PDAContentTag GetOverrideContentTag()
|
// public PDAContentTag GetOverrideContentTag()
|
||||||
{
|
// {
|
||||||
if (OverrideApp.IsNull()) return null;
|
// if (OverrideApp.IsNull()) return null;
|
||||||
return OverrideApp;
|
// return OverrideApp;
|
||||||
}
|
// }
|
||||||
|
//
|
||||||
public List<PDAContentTag> GetAvailableContentTags()
|
// public List<PDAContentTag> GetAvailableContentTags()
|
||||||
{
|
// {
|
||||||
return InMemoryApps.Concat(ExternalApps).ToList();
|
// return InMemoryApps.Concat(ExternalApps).ToList();
|
||||||
}
|
// }
|
||||||
|
//
|
||||||
public void InstallExternalApp(PDAContentTag contentTag, params Parameter[] parameters)
|
// public void InstallExternalApp(PDAContentTag contentTag, params Parameter[] parameters)
|
||||||
{
|
// {
|
||||||
if (contentTag.IsNull())
|
// if (contentTag.IsNull())
|
||||||
{
|
// {
|
||||||
throw new ArgumentException("Content tag cannot be null");
|
// throw new ArgumentException("Content tag cannot be null");
|
||||||
}
|
// }
|
||||||
if (!applicationLibrary.Contains(contentTag))
|
// if (!applicationLibrary.Contains(contentTag))
|
||||||
{
|
// {
|
||||||
throw new ArgumentException($"Content tag {contentTag} not found in library");
|
// throw new ArgumentException($"Content tag {contentTag} not found in library");
|
||||||
}
|
// }
|
||||||
if (parameters is null || parameters.Length != contentTag.Parameters.Count)
|
// if (parameters is null || parameters.Length != contentTag.Parameters.Count)
|
||||||
{
|
// {
|
||||||
throw new ArgumentException("Invalid number of parameters");
|
// throw new ArgumentException("Invalid number of parameters");
|
||||||
}
|
// }
|
||||||
if (!parameters.Select(p => p.Key).Distinct().All(k => contentTag.Parameters.Contains(k)))
|
// if (!parameters.Select(p => p.Key).Distinct().All(k => contentTag.Parameters.Contains(k)))
|
||||||
{
|
// {
|
||||||
throw new ArgumentException("parameters should fit the request");
|
// throw new ArgumentException("parameters should fit the request");
|
||||||
}
|
// }
|
||||||
foreach (var parameter in parameters)
|
// foreach (var parameter in parameters)
|
||||||
{
|
// {
|
||||||
ParameterStore.Add(parameter);
|
// ParameterStore.Add(parameter);
|
||||||
}
|
// }
|
||||||
ExternalApps.Add(contentTag);
|
// ExternalApps.Add(contentTag);
|
||||||
}
|
// }
|
||||||
|
//
|
||||||
public void RemoveExternalApp(PDAContentTag contentTag)
|
// public void RemoveExternalApp(PDAContentTag contentTag)
|
||||||
{
|
// {
|
||||||
if (contentTag.IsNull()) return;
|
// if (contentTag.IsNull()) return;
|
||||||
if (!applicationLibrary.Contains(contentTag)) return;
|
// if (!applicationLibrary.Contains(contentTag)) return;
|
||||||
foreach (var key in contentTag.Parameters)
|
// foreach (var key in contentTag.Parameters)
|
||||||
{
|
// {
|
||||||
ParameterStore.Delete(key);
|
// ParameterStore.Delete(key);
|
||||||
}
|
// }
|
||||||
ExternalApps.Remove(contentTag);
|
// ExternalApps.Remove(contentTag);
|
||||||
}
|
// }
|
||||||
}
|
// }
|
||||||
}
|
// }
|
||||||
@ -0,0 +1,116 @@
|
|||||||
|
using System;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using System.Linq;
|
||||||
|
using Intrepid.Gameplay.Codex;
|
||||||
|
using Intrepid.Gameplay.Codex.Music;
|
||||||
|
using Intrepid.Gameplay.Codex.Visual;
|
||||||
|
using Intrepid.Gameplay.Entities.Player.PDA.Events;
|
||||||
|
using Intrepid.Gameplay.Entities.Player.PDA.Inputs;
|
||||||
|
using Intrepid.Gameplay.Entities.Player.PDA.UI;
|
||||||
|
using Intrepid.Gameplay.Themes;
|
||||||
|
using Intrepid.SimpleEvents;
|
||||||
|
using Intrepid.Sound;
|
||||||
|
using Intrepid.Structures;
|
||||||
|
using Intrepid.Utilities;
|
||||||
|
using Sirenix.OdinInspector;
|
||||||
|
using UnityEngine;
|
||||||
|
|
||||||
|
namespace Intrepid.Gameplay.Entities.Player.PDA
|
||||||
|
{
|
||||||
|
public class PDARuntime : EventListener
|
||||||
|
{
|
||||||
|
[GroupInjections("Prefabs"), SerializeField] private PDAApplicationLibrary applicationLibrary;
|
||||||
|
[GroupInjections, SerializeField] private CodexRuntime codexRuntime;
|
||||||
|
|
||||||
|
[GroupConfigurations("Apps"), SerializeField] private PDAContentTag overrideApp;
|
||||||
|
[GroupConfigurations("Apps"), SerializeField] private List<PDAContentTag> inMemoryApps;
|
||||||
|
[GroupConfigurations("Apps"), SerializeField] private List<PDAContentTag> externalApps;
|
||||||
|
|
||||||
|
private PDAContentTag OverrideApp => overrideApp;
|
||||||
|
private List<PDAContentTag> InMemoryApps => inMemoryApps;
|
||||||
|
private List<PDAContentTag> ExternalApps => externalApps;
|
||||||
|
|
||||||
|
[GroupDebug, ShowInInspector, ReadOnly] public ParameterStore ParameterStore { get; private set; } = new();
|
||||||
|
public static PDAInputs PDAInputs => PlayerInputResolver.Instance.PDA;
|
||||||
|
|
||||||
|
protected override void InitializeVariables()
|
||||||
|
{
|
||||||
|
ExternalApps.Clear();
|
||||||
|
}
|
||||||
|
|
||||||
|
protected override void OnBootstrap()
|
||||||
|
{
|
||||||
|
}
|
||||||
|
|
||||||
|
protected override void Subscriptions()
|
||||||
|
{
|
||||||
|
Subscribe<PDAInstallExternalAppEvent>(WhenInstallExternalApp);
|
||||||
|
Subscribe<PDARemoveExternalAppEvent>(WhenRemoveExternalApp);
|
||||||
|
}
|
||||||
|
|
||||||
|
public Func<PDAApplicationUI> ApplicationLoader(PDAContentTag contentTag, Transform parent)
|
||||||
|
{
|
||||||
|
return () => applicationLibrary.Load(contentTag, parent);
|
||||||
|
}
|
||||||
|
|
||||||
|
public IReadOnlyList<PDAContentTag> GetAvailableContentTags()
|
||||||
|
{
|
||||||
|
return InMemoryApps.Concat(ExternalApps).ToList();
|
||||||
|
}
|
||||||
|
|
||||||
|
private void WhenInstallExternalApp(PDAInstallExternalAppEvent e)
|
||||||
|
{
|
||||||
|
var contentTag = e.ContentTag;
|
||||||
|
var parameters = e.Parameters;
|
||||||
|
if (contentTag.IsNull())
|
||||||
|
{
|
||||||
|
throw new ArgumentException("Content tag cannot be null");
|
||||||
|
}
|
||||||
|
if (!applicationLibrary.Contains(contentTag))
|
||||||
|
{
|
||||||
|
throw new ArgumentException($"Content tag {contentTag} not found in library");
|
||||||
|
}
|
||||||
|
if (parameters is null || parameters.Length != contentTag.Parameters.Count)
|
||||||
|
{
|
||||||
|
throw new ArgumentException("Invalid number of parameters");
|
||||||
|
}
|
||||||
|
if (!parameters.Select(v => v.Item1).Distinct().All(k => contentTag.Parameters.Contains(k)))
|
||||||
|
{
|
||||||
|
throw new ArgumentException("parameters should fit the request");
|
||||||
|
}
|
||||||
|
foreach (var parameter in parameters)
|
||||||
|
{
|
||||||
|
ParameterStore.Add(Parameter.With(parameter.Item1, parameter.Item2));
|
||||||
|
}
|
||||||
|
ExternalApps.Add(contentTag);
|
||||||
|
}
|
||||||
|
|
||||||
|
private void WhenRemoveExternalApp(PDARemoveExternalAppEvent e)
|
||||||
|
{
|
||||||
|
var contentTag = e.ContentTag;
|
||||||
|
if (contentTag.IsNull()) return;
|
||||||
|
if (!applicationLibrary.Contains(contentTag)) return;
|
||||||
|
foreach (var key in contentTag.Parameters)
|
||||||
|
{
|
||||||
|
ParameterStore.Delete(key);
|
||||||
|
}
|
||||||
|
ExternalApps.Remove(contentTag);
|
||||||
|
}
|
||||||
|
|
||||||
|
public PDAContentTag GetOverrideContentTag()
|
||||||
|
{
|
||||||
|
if (OverrideApp.IsNull()) return null;
|
||||||
|
return OverrideApp;
|
||||||
|
}
|
||||||
|
|
||||||
|
public IReadOnlyList<CodexMusicTag> GetMusicKnown()
|
||||||
|
{
|
||||||
|
return codexRuntime.KnownMusic;
|
||||||
|
}
|
||||||
|
|
||||||
|
public IReadOnlyList<PictorialProtocolTag> GetPictorialProtocolKnown()
|
||||||
|
{
|
||||||
|
return codexRuntime.KnownPictorialProtocols;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
@ -0,0 +1,3 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 69cd01c7f7fa43b3ac93d3677a6996c2
|
||||||
|
timeCreated: 1783412347
|
||||||
@ -1,3 +1,4 @@
|
|||||||
|
using System.Linq;
|
||||||
using Intrepid.GameManagers;
|
using Intrepid.GameManagers;
|
||||||
using Intrepid.Gameplay.Entities.Player.PDA.Events;
|
using Intrepid.Gameplay.Entities.Player.PDA.Events;
|
||||||
using Intrepid.Gameplay.Entities.Player.PDA.Inputs;
|
using Intrepid.Gameplay.Entities.Player.PDA.Inputs;
|
||||||
@ -42,7 +43,7 @@ namespace Intrepid.Gameplay.Entities.Player.PDA.UI.Applications.MusicPlayer
|
|||||||
|
|
||||||
protected override void WhenStarting(ParameterStore parameters)
|
protected override void WhenStarting(ParameterStore parameters)
|
||||||
{
|
{
|
||||||
musicSelection.Feed(Device.GetMusicKnown());
|
musicSelection.Feed(Runtime.GetMusicKnown());
|
||||||
musicSelection.WhenStarting();
|
musicSelection.WhenStarting();
|
||||||
musicPlayer.WhenStarting();
|
musicPlayer.WhenStarting();
|
||||||
}
|
}
|
||||||
|
|||||||
@ -1,6 +1,7 @@
|
|||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
using Intrepid.Diagnostics;
|
using Intrepid.Diagnostics;
|
||||||
using Intrepid.GameManagers;
|
using Intrepid.GameManagers;
|
||||||
|
using Intrepid.Gameplay.Codex.Music;
|
||||||
using Intrepid.Gameplay.Entities.Player.PDA.Inputs;
|
using Intrepid.Gameplay.Entities.Player.PDA.Inputs;
|
||||||
using Intrepid.Sound;
|
using Intrepid.Sound;
|
||||||
using TMPro;
|
using TMPro;
|
||||||
@ -53,7 +54,7 @@ namespace Intrepid.Gameplay.Entities.Player.PDA.UI.Applications.MusicPlayer
|
|||||||
[SerializeField] private float volumeStep = 0.05f;
|
[SerializeField] private float volumeStep = 0.05f;
|
||||||
[SerializeField] private float positionStep = 0.05f;
|
[SerializeField] private float positionStep = 0.05f;
|
||||||
|
|
||||||
private SoundMusicData SoundMusicData { get; set; }
|
private CodexMusicTag CodexMusicTag { get; set; }
|
||||||
public SoundObject SoundObject { get; set; }
|
public SoundObject SoundObject { get; set; }
|
||||||
|
|
||||||
private MusicPlayerStatus Status { get; set; } = MusicPlayerStatus.None;
|
private MusicPlayerStatus Status { get; set; } = MusicPlayerStatus.None;
|
||||||
@ -65,7 +66,7 @@ namespace Intrepid.Gameplay.Entities.Player.PDA.UI.Applications.MusicPlayer
|
|||||||
stop.interactable = false;
|
stop.interactable = false;
|
||||||
volume.interactable = false;
|
volume.interactable = false;
|
||||||
position.interactable = false;
|
position.interactable = false;
|
||||||
SoundMusicData = null;
|
CodexMusicTag = null;
|
||||||
Status = MusicPlayerStatus.None;
|
Status = MusicPlayerStatus.None;
|
||||||
DisplayNoMusic();
|
DisplayNoMusic();
|
||||||
}
|
}
|
||||||
@ -117,7 +118,7 @@ namespace Intrepid.Gameplay.Entities.Player.PDA.UI.Applications.MusicPlayer
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
public void SelectedMusic(SoundMusicData soundMusicData)
|
public void SelectedMusic(CodexMusicTag soundMusicData)
|
||||||
{
|
{
|
||||||
if (soundMusicData is null)
|
if (soundMusicData is null)
|
||||||
{
|
{
|
||||||
@ -132,7 +133,7 @@ namespace Intrepid.Gameplay.Entities.Player.PDA.UI.Applications.MusicPlayer
|
|||||||
volume.interactable = true;
|
volume.interactable = true;
|
||||||
position.interactable = true;
|
position.interactable = true;
|
||||||
position.value = 0;
|
position.value = 0;
|
||||||
SoundMusicData = soundMusicData;
|
CodexMusicTag = soundMusicData;
|
||||||
SoundObject?.Stop();
|
SoundObject?.Stop();
|
||||||
SoundObject = null;
|
SoundObject = null;
|
||||||
DisplayMusic();
|
DisplayMusic();
|
||||||
@ -145,7 +146,7 @@ namespace Intrepid.Gameplay.Entities.Player.PDA.UI.Applications.MusicPlayer
|
|||||||
|
|
||||||
private void DisplayMusic()
|
private void DisplayMusic()
|
||||||
{
|
{
|
||||||
textMesh.text = Proxy.Instance.I18N.Localise(SoundMusicData.Localization);
|
textMesh.text = Proxy.Instance.I18N.Localise(CodexMusicTag.Localization);
|
||||||
}
|
}
|
||||||
|
|
||||||
public void ChangeVolume(float v)
|
public void ChangeVolume(float v)
|
||||||
@ -170,7 +171,7 @@ namespace Intrepid.Gameplay.Entities.Player.PDA.UI.Applications.MusicPlayer
|
|||||||
position.interactable = true;
|
position.interactable = true;
|
||||||
if (SoundObject is null)
|
if (SoundObject is null)
|
||||||
{
|
{
|
||||||
SoundObject = Proxy.Instance.SoundSystem.PlayMusic(SoundMusicData.soundId, true, _ => { });
|
SoundObject = Proxy.Instance.SoundSystem.PlayMusic(CodexMusicTag.MusicData.soundId, true, _ => { });
|
||||||
SoundObject.AudioSource.volume = volume.value;
|
SoundObject.AudioSource.volume = volume.value;
|
||||||
position.value = 0;
|
position.value = 0;
|
||||||
return;
|
return;
|
||||||
|
|||||||
@ -1,7 +1,7 @@
|
|||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
using Intrepid.GameManagers;
|
using Intrepid.GameManagers;
|
||||||
|
using Intrepid.Gameplay.Codex.Music;
|
||||||
using Intrepid.Gameplay.Entities.Player.PDA.Inputs;
|
using Intrepid.Gameplay.Entities.Player.PDA.Inputs;
|
||||||
using Intrepid.Sound;
|
|
||||||
using TMPro;
|
using TMPro;
|
||||||
using UnityEngine;
|
using UnityEngine;
|
||||||
using UnityEngine.UI;
|
using UnityEngine.UI;
|
||||||
@ -15,10 +15,10 @@ namespace Intrepid.Gameplay.Entities.Player.PDA.UI.Applications.MusicPlayer
|
|||||||
[SerializeField] private Button previous;
|
[SerializeField] private Button previous;
|
||||||
[SerializeField] private Button next;
|
[SerializeField] private Button next;
|
||||||
|
|
||||||
private List<SoundMusicData> Musics { get; } = new();
|
private List<CodexMusicTag> Musics { get; } = new();
|
||||||
private int Index { get; set; }
|
private int Index { get; set; }
|
||||||
|
|
||||||
public SoundMusicData SelectedMusic => Musics.Count == 0 ? null : Musics[Index];
|
public CodexMusicTag SelectedMusic => Musics.Count == 0 ? null : Musics[Index];
|
||||||
|
|
||||||
public void WhenStarting()
|
public void WhenStarting()
|
||||||
{
|
{
|
||||||
@ -53,7 +53,7 @@ namespace Intrepid.Gameplay.Entities.Player.PDA.UI.Applications.MusicPlayer
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
public void Feed(List<SoundMusicData> musicKnown)
|
public void Feed(IReadOnlyList<CodexMusicTag> musicKnown)
|
||||||
{
|
{
|
||||||
Index = 0;
|
Index = 0;
|
||||||
Musics.Clear();
|
Musics.Clear();
|
||||||
|
|||||||
@ -1,7 +1,7 @@
|
|||||||
using Intrepid.GameManagers;
|
using Intrepid.GameManagers;
|
||||||
|
using Intrepid.Gameplay.Codex.Visual;
|
||||||
using Intrepid.Gameplay.Entities.Player.PDA.Events;
|
using Intrepid.Gameplay.Entities.Player.PDA.Events;
|
||||||
using Intrepid.Gameplay.Entities.Player.PDA.Inputs;
|
using Intrepid.Gameplay.Entities.Player.PDA.Inputs;
|
||||||
using Intrepid.Gameplay.Themes;
|
|
||||||
using Intrepid.Structures;
|
using Intrepid.Structures;
|
||||||
using Intrepid.Utilities;
|
using Intrepid.Utilities;
|
||||||
using UnityEngine;
|
using UnityEngine;
|
||||||
@ -19,8 +19,8 @@ namespace Intrepid.Gameplay.Entities.Player.PDA.UI.Applications.ThemeChanger
|
|||||||
|
|
||||||
public override void UpdateTheme()
|
public override void UpdateTheme()
|
||||||
{
|
{
|
||||||
currentThemeSelectionAreaUI.Theme = ThemeManager.Instance.CurrentTheme;
|
currentThemeSelectionAreaUI.Protocol = CodexVisualService.Instance.CurrentPictorialProtocol;
|
||||||
background.color = currentThemeSelectionAreaUI.Theme.PDAThemes.AppTheme.Background;
|
background.color = currentThemeSelectionAreaUI.Protocol.GetSurfaceColor(PictorialSurfaceType.Base);
|
||||||
}
|
}
|
||||||
|
|
||||||
public override void UpdateApplication(PDAInputs inputs)
|
public override void UpdateApplication(PDAInputs inputs)
|
||||||
@ -59,7 +59,7 @@ namespace Intrepid.Gameplay.Entities.Player.PDA.UI.Applications.ThemeChanger
|
|||||||
|
|
||||||
protected override void WhenStarting(ParameterStore parameters)
|
protected override void WhenStarting(ParameterStore parameters)
|
||||||
{
|
{
|
||||||
themeSelectorUI.Load(Device);
|
themeSelectorUI.Load(Runtime);
|
||||||
}
|
}
|
||||||
|
|
||||||
protected override void WhenFinishing()
|
protected override void WhenFinishing()
|
||||||
|
|||||||
@ -1,7 +1,7 @@
|
|||||||
using Intrepid.Core.UI;
|
using Intrepid.Core.UI;
|
||||||
using Intrepid.Core.UI.Dialog;
|
|
||||||
using Intrepid.GameManagers;
|
using Intrepid.GameManagers;
|
||||||
using Intrepid.Gameplay.Themes;
|
using Intrepid.Gameplay.Codex.UI.Components;
|
||||||
|
using Intrepid.Gameplay.Codex.Visual;
|
||||||
using Intrepid.Utilities;
|
using Intrepid.Utilities;
|
||||||
using Sirenix.OdinInspector;
|
using Sirenix.OdinInspector;
|
||||||
using UnityEngine;
|
using UnityEngine;
|
||||||
@ -11,46 +11,51 @@ namespace Intrepid.Gameplay.Entities.Player.PDA.UI.Applications.ThemeChanger
|
|||||||
{
|
{
|
||||||
public class ThemeSelectionAreaUI : MonoBehaviour
|
public class ThemeSelectionAreaUI : MonoBehaviour
|
||||||
{
|
{
|
||||||
[GroupInjections, SerializeField] private DialogMinimalUI dialog;
|
[GroupInjections, SerializeField] private CodexPanelComponentUI panel;
|
||||||
[GroupInjections, SerializeField] private NewsTickerUI title;
|
[GroupInjections, SerializeField] private NewsTickerUI title;
|
||||||
[GroupInjections, SerializeField] private NewsTickerUI description;
|
[GroupInjections, SerializeField] private NewsTickerUI description;
|
||||||
[GroupInjections, SerializeField] private Image[] palettes;
|
[GroupInjections, SerializeField] private Image[] palettes;
|
||||||
[GroupDebug, SerializeField, ReadOnly] private Theme theme;
|
[GroupDebug, SerializeField, ReadOnly] private PictorialProtocolTag protocol;
|
||||||
|
|
||||||
public DialogMinimalUI Dialog => dialog;
|
public PictorialProtocolTag Protocol
|
||||||
public NewsTickerUI Title => title;
|
|
||||||
public NewsTickerUI Description => description;
|
|
||||||
|
|
||||||
public Theme Theme
|
|
||||||
{
|
{
|
||||||
get => theme;
|
get => protocol;
|
||||||
[GroupDebug, Button(ButtonStyle.FoldoutButton)]
|
[GroupDebug, Button(ButtonStyle.FoldoutButton)]
|
||||||
set
|
set
|
||||||
{
|
{
|
||||||
theme = value;
|
protocol = value;
|
||||||
dialog.Theme = theme.PDAThemes.DialogTheme;
|
panel.SetSurface(PictorialSurfaceType.Base);
|
||||||
title.TextMesh.color = theme.PDAThemes.AppTheme.Text;
|
panel.SetBorder(PictorialSignalType.Primary);
|
||||||
description.TextMesh.color = theme.PDAThemes.AppTheme.Text;
|
title.TextMesh.color = protocol.GetTextColor(PictorialTextType.Primary);
|
||||||
for (var i = 0; i < theme.Summary.Length; i++)
|
description.TextMesh.color = protocol.GetTextColor(PictorialTextType.Secondary);
|
||||||
|
var summary = new[]
|
||||||
{
|
{
|
||||||
palettes[i].color = theme.Summary[i];
|
protocol.GetSignalColor(PictorialSignalType.Primary),
|
||||||
|
protocol.GetSignalColor(PictorialSignalType.Focus),
|
||||||
|
protocol.GetSignalColor(PictorialSignalType.Selected),
|
||||||
|
protocol.GetSignalColor(PictorialSignalType.Disabled),
|
||||||
|
protocol.GetSignalColor(PictorialSignalType.Corruption),
|
||||||
|
};
|
||||||
|
for (var i = 0; i < summary.Length; i++)
|
||||||
|
{
|
||||||
|
palettes[i].color = summary[i];
|
||||||
}
|
}
|
||||||
if (Proxy.Instance is null) return;
|
if (Proxy.Instance is null) return;
|
||||||
title.Text = Proxy.Instance.I18N.Localise(theme.LocalizationName);
|
title.Text = Proxy.Instance.I18N.Localise(protocol.Localization);
|
||||||
description.Text = Proxy.Instance.I18N.Localise(theme.LocalizationDescription);
|
description.Text = Proxy.Instance.I18N.Localise(protocol.Description);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
public void Operational(bool forceReset = false)
|
public void Operational(bool forceReset = false)
|
||||||
{
|
{
|
||||||
title.Operational(Proxy.Instance.I18N.Localise(Theme.LocalizationName), forceReset);
|
title.Operational(Proxy.Instance.I18N.Localise(Protocol.Localization), forceReset);
|
||||||
description.Operational(Proxy.Instance.I18N.Localise(Theme.LocalizationDescription), forceReset);
|
description.Operational(Proxy.Instance.I18N.Localise(Protocol.Description), forceReset);
|
||||||
}
|
}
|
||||||
|
|
||||||
public void NotOperational()
|
public void NotOperational()
|
||||||
{
|
{
|
||||||
title.Text = Proxy.Instance.I18N.Localise(Theme.LocalizationName);
|
title.Text = Proxy.Instance.I18N.Localise(Protocol.Localization);
|
||||||
description.Text = Proxy.Instance.I18N.Localise(Theme.LocalizationDescription);
|
description.Text = Proxy.Instance.I18N.Localise(Protocol.Description);
|
||||||
|
|
||||||
title.TextMesh.text = title.Text;
|
title.TextMesh.text = title.Text;
|
||||||
description.TextMesh.text = description.Text;
|
description.TextMesh.text = description.Text;
|
||||||
|
|||||||
@ -1,4 +1,4 @@
|
|||||||
using Intrepid.Gameplay.Themes;
|
using Intrepid.Gameplay.Codex.Visual;
|
||||||
using Intrepid.Structures;
|
using Intrepid.Structures;
|
||||||
using Intrepid.Utilities;
|
using Intrepid.Utilities;
|
||||||
using UnityEngine;
|
using UnityEngine;
|
||||||
@ -12,30 +12,29 @@ namespace Intrepid.Gameplay.Entities.Player.PDA.UI.Applications.ThemeChanger
|
|||||||
[GroupInjections, SerializeField] private ThemeSelectionAreaUI down;
|
[GroupInjections, SerializeField] private ThemeSelectionAreaUI down;
|
||||||
[GroupInjections, SerializeField] private ThemeSelectionAreaUI focus;
|
[GroupInjections, SerializeField] private ThemeSelectionAreaUI focus;
|
||||||
|
|
||||||
private StackBelt<Theme> StackThemes { get; } = new();
|
private StackBelt<PictorialProtocolTag> StackProtocols { get; } = new();
|
||||||
|
|
||||||
public void Load(PDADevice device)
|
public void Load(PDARuntime runtime)
|
||||||
{
|
{
|
||||||
var currentTheme = ThemeManager.Instance.CurrentTheme;
|
foreach (var protocol in runtime.GetPictorialProtocolKnown())
|
||||||
foreach (var theme in device.GetThemesKnown())// .Where(t => !currentTheme.Equals(t)))
|
|
||||||
{
|
{
|
||||||
StackThemes.Push(theme);
|
StackProtocols.Push(protocol);
|
||||||
}
|
}
|
||||||
UpdateContent();
|
UpdateContent();
|
||||||
}
|
}
|
||||||
|
|
||||||
private void Switch()
|
private void Switch()
|
||||||
{
|
{
|
||||||
up.Dialog.Downy();
|
// up.Dialog.Downy();
|
||||||
down.Dialog.Upy();
|
// down.Dialog.Upy();
|
||||||
focus.Dialog.BlinkBorderSelected();
|
// focus.Dialog.BlinkBorderSelected();
|
||||||
}
|
}
|
||||||
|
|
||||||
private void UpdateContent()
|
private void UpdateContent()
|
||||||
{
|
{
|
||||||
focus.Theme = StackThemes.Focus;
|
focus.Protocol = StackProtocols.Focus;
|
||||||
up.Theme = StackThemes.PeekLeft;
|
up.Protocol = StackProtocols.PeekLeft;
|
||||||
down.Theme = StackThemes.PeekRight;
|
down.Protocol = StackProtocols.PeekRight;
|
||||||
|
|
||||||
up.NotOperational();
|
up.NotOperational();
|
||||||
down.NotOperational();
|
down.NotOperational();
|
||||||
@ -45,20 +44,20 @@ namespace Intrepid.Gameplay.Entities.Player.PDA.UI.Applications.ThemeChanger
|
|||||||
public void SwitchUp()
|
public void SwitchUp()
|
||||||
{
|
{
|
||||||
Switch();
|
Switch();
|
||||||
StackThemes.NextLeft();
|
StackProtocols.NextLeft();
|
||||||
UpdateContent();
|
UpdateContent();
|
||||||
}
|
}
|
||||||
|
|
||||||
public void SwitchDown()
|
public void SwitchDown()
|
||||||
{
|
{
|
||||||
Switch();
|
Switch();
|
||||||
StackThemes.NextRight();
|
StackProtocols.NextRight();
|
||||||
UpdateContent();
|
UpdateContent();
|
||||||
}
|
}
|
||||||
|
|
||||||
public void Select()
|
public void Select()
|
||||||
{
|
{
|
||||||
ThemeManager.Instance.CurrentTheme = StackThemes.Focus;
|
CodexVisualService.Instance.ApplyProtocol(StackProtocols.Focus);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -58,7 +58,7 @@ namespace Intrepid.Gameplay.Entities.Player.PDA.UI
|
|||||||
contents.WhenFinishing();
|
contents.WhenFinishing();
|
||||||
}
|
}
|
||||||
|
|
||||||
public void PrepareEnvironment(List<PDAContentTag> availableContentTags)
|
public void PrepareEnvironment(IReadOnlyList<PDAContentTag> availableContentTags)
|
||||||
{
|
{
|
||||||
ContentTagsBySectionTag.Clear();
|
ContentTagsBySectionTag.Clear();
|
||||||
foreach (var contentTag in availableContentTags)
|
foreach (var contentTag in availableContentTags)
|
||||||
|
|||||||
@ -11,10 +11,9 @@ namespace Intrepid.Gameplay.Entities.Player.PDA.UI
|
|||||||
{
|
{
|
||||||
public abstract class PDAApplicationUI : Identification, IPDAApplicationUpdater, IPDASystemBootEvents, IPDASystemShutdownEvents
|
public abstract class PDAApplicationUI : Identification, IPDAApplicationUpdater, IPDASystemBootEvents, IPDASystemShutdownEvents
|
||||||
{
|
{
|
||||||
[SerializeField, GroupConfigurations] private PDADevice device;
|
|
||||||
[SerializeField, GroupConfigurations] private PDAContentTag contentTag;
|
[SerializeField, GroupConfigurations] private PDAContentTag contentTag;
|
||||||
|
|
||||||
protected PDADevice Device => device;
|
protected PDARuntime Runtime { get; private set; }
|
||||||
public PDAContentTag ContentTag => contentTag;
|
public PDAContentTag ContentTag => contentTag;
|
||||||
|
|
||||||
public abstract bool IsLoading { get; }
|
public abstract bool IsLoading { get; }
|
||||||
@ -25,11 +24,12 @@ namespace Intrepid.Gameplay.Entities.Player.PDA.UI
|
|||||||
protected abstract void WhenStarting(ParameterStore parameters);
|
protected abstract void WhenStarting(ParameterStore parameters);
|
||||||
protected abstract void WhenFinishing();
|
protected abstract void WhenFinishing();
|
||||||
|
|
||||||
public void WhenEntering()
|
public void WhenEntering(PDARuntime runtime)
|
||||||
{
|
{
|
||||||
|
Runtime = runtime;
|
||||||
Subscribing();
|
Subscribing();
|
||||||
UpdateTheme();
|
UpdateTheme();
|
||||||
WhenStarting(device.ParameterStore);
|
WhenStarting(Runtime.ParameterStore);
|
||||||
}
|
}
|
||||||
|
|
||||||
public void WhenExiting()
|
public void WhenExiting()
|
||||||
|
|||||||
@ -209,14 +209,14 @@ namespace Intrepid.Gameplay.Entities.Player.PDA.UI
|
|||||||
ContentUnFocus();
|
ContentUnFocus();
|
||||||
if (currentIndex >= numberOfContents - 1)
|
if (currentIndex >= numberOfContents - 1)
|
||||||
{
|
{
|
||||||
currentIndex = ++currentIndex % numberOfContents;
|
currentIndex = numberOfContents > 0 ? ++currentIndex % numberOfContents : 0;
|
||||||
var x = UpdatePosition();
|
var x = UpdatePosition();
|
||||||
ContentFocus();
|
ContentFocus();
|
||||||
StartCoroutine(AnimateUpdatePositionRight(x));
|
StartCoroutine(AnimateUpdatePositionRight(x));
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
currentIndex = ++currentIndex % numberOfContents;
|
currentIndex = numberOfContents > 0 ? ++currentIndex % numberOfContents : 0;
|
||||||
var x = UpdatePosition();
|
var x = UpdatePosition();
|
||||||
ContentFocus();
|
ContentFocus();
|
||||||
StartCoroutine(AnimateUpdatePositionLeft(x));
|
StartCoroutine(AnimateUpdatePositionLeft(x));
|
||||||
|
|||||||
@ -9,11 +9,11 @@ namespace Intrepid.Gameplay.Entities.Player.PDA.UI
|
|||||||
{
|
{
|
||||||
public class PDADeviceUI : ManagedWindowUI, IPDASystemBootEvents, IPDASystemShutdownEvents
|
public class PDADeviceUI : ManagedWindowUI, IPDASystemBootEvents, IPDASystemShutdownEvents
|
||||||
{
|
{
|
||||||
[GroupInjections, SerializeField] private PDADevice device;
|
[GroupInjections, SerializeField] private PDARuntime runtime;
|
||||||
[GroupInjections, SerializeField] private PDAOperationalSystemUI operationalSystem;
|
[GroupInjections, SerializeField] private PDAOperationalSystemUI operationalSystem;
|
||||||
[GroupInjections, SerializeField] private PDALoadingProcessUI loadingProcess;
|
[GroupInjections, SerializeField] private PDALoadingProcessUI loadingProcess;
|
||||||
|
|
||||||
private Func<MonoBehaviour> TargetApplicationLoader { get; set; }
|
private Func<PDAApplicationUI> TargetApplicationLoader { get; set; }
|
||||||
private PDAApplicationUI _targetApplication;
|
private PDAApplicationUI _targetApplication;
|
||||||
private PDAApplicationUI TargetApplication => _targetApplication ?? operationalSystem;
|
private PDAApplicationUI TargetApplication => _targetApplication ?? operationalSystem;
|
||||||
private bool DeviceRunning { get; set; }
|
private bool DeviceRunning { get; set; }
|
||||||
@ -24,14 +24,14 @@ namespace Intrepid.Gameplay.Entities.Player.PDA.UI
|
|||||||
{
|
{
|
||||||
if (!DeviceRunning) return;
|
if (!DeviceRunning) return;
|
||||||
loadingProcess.UpdateLoadingProcess();
|
loadingProcess.UpdateLoadingProcess();
|
||||||
TargetApplication.UpdateApplication(device.PDAInputs);
|
TargetApplication.UpdateApplication(PDARuntime.PDAInputs);
|
||||||
}
|
}
|
||||||
|
|
||||||
private void LateUpdate()
|
private void LateUpdate()
|
||||||
{
|
{
|
||||||
if (!DeviceRunning) return;
|
if (!DeviceRunning) return;
|
||||||
TargetApplication.UpdateTheme();
|
TargetApplication.UpdateTheme();
|
||||||
TargetApplication.LateUpdateApplication(device.PDAInputs);
|
TargetApplication.LateUpdateApplication(PDARuntime.PDAInputs);
|
||||||
}
|
}
|
||||||
|
|
||||||
protected override void InitializeVariables()
|
protected override void InitializeVariables()
|
||||||
@ -52,7 +52,7 @@ namespace Intrepid.Gameplay.Entities.Player.PDA.UI
|
|||||||
private void WhenPDAEnterApplication(PDAEnterApplicationEvent e)
|
private void WhenPDAEnterApplication(PDAEnterApplicationEvent e)
|
||||||
{
|
{
|
||||||
operationalSystem.WhenExiting();
|
operationalSystem.WhenExiting();
|
||||||
TargetApplicationLoader = device.ApplicationLoader(e.ContentTag, operationalSystem.transform.parent);
|
TargetApplicationLoader = runtime.ApplicationLoader(e.ContentTag, operationalSystem.transform.parent);
|
||||||
loadingProcess.StartLoading(LoadingProcess);
|
loadingProcess.StartLoading(LoadingProcess);
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -74,7 +74,7 @@ namespace Intrepid.Gameplay.Entities.Player.PDA.UI
|
|||||||
{
|
{
|
||||||
if (TargetApplicationLoader is not null)
|
if (TargetApplicationLoader is not null)
|
||||||
{
|
{
|
||||||
_targetApplication = (PDAApplicationUI)TargetApplicationLoader();
|
_targetApplication = TargetApplicationLoader();
|
||||||
TargetApplicationLoader = null;
|
TargetApplicationLoader = null;
|
||||||
operationalSystem.gameObject.SetActive(false);
|
operationalSystem.gameObject.SetActive(false);
|
||||||
TargetApplication.gameObject.SetActive(true);
|
TargetApplication.gameObject.SetActive(true);
|
||||||
@ -82,9 +82,9 @@ namespace Intrepid.Gameplay.Entities.Player.PDA.UI
|
|||||||
else if (!ApplicationOverriding)
|
else if (!ApplicationOverriding)
|
||||||
{
|
{
|
||||||
TargetApplication.gameObject.SetActive(true);
|
TargetApplication.gameObject.SetActive(true);
|
||||||
operationalSystem.PrepareEnvironment(device.GetAvailableContentTags());
|
operationalSystem.PrepareEnvironment(runtime.GetAvailableContentTags());
|
||||||
}
|
}
|
||||||
TargetApplication.WhenEntering();
|
TargetApplication.WhenEntering(runtime);
|
||||||
return () => TargetApplication.IsLoading;
|
return () => TargetApplication.IsLoading;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -93,12 +93,11 @@ namespace Intrepid.Gameplay.Entities.Player.PDA.UI
|
|||||||
{
|
{
|
||||||
loadingProcess.StraightBlock();
|
loadingProcess.StraightBlock();
|
||||||
|
|
||||||
var overrideContentTag = device.GetOverrideContentTag();
|
var overrideContentTag = runtime.GetOverrideContentTag();
|
||||||
if (overrideContentTag is not null)
|
if (overrideContentTag is not null)
|
||||||
{
|
{
|
||||||
ApplicationOverriding = true;
|
ApplicationOverriding = true;
|
||||||
_targetApplication = (PDAApplicationUI)device
|
_targetApplication = runtime.ApplicationLoader(overrideContentTag, operationalSystem.transform.parent)();
|
||||||
.ApplicationLoader(overrideContentTag, operationalSystem.transform.parent)();
|
|
||||||
operationalSystem.gameObject.SetActive(false);
|
operationalSystem.gameObject.SetActive(false);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
|
|||||||
@ -52,7 +52,7 @@ namespace Intrepid.Gameplay.Entities.Player.PDA.UI
|
|||||||
WhenExiting();
|
WhenExiting();
|
||||||
}
|
}
|
||||||
|
|
||||||
public void PrepareEnvironment(List<PDAContentTag> availableContentTags)
|
public void PrepareEnvironment(IReadOnlyList<PDAContentTag> availableContentTags)
|
||||||
{
|
{
|
||||||
applicationSelection.PrepareEnvironment(availableContentTags);
|
applicationSelection.PrepareEnvironment(availableContentTags);
|
||||||
}
|
}
|
||||||
|
|||||||
@ -24,7 +24,7 @@ namespace Intrepid.Gameplay.Entities.Player.Sentinel
|
|||||||
[GroupInjections, SerializeField] private SentinelConfig config;
|
[GroupInjections, SerializeField] private SentinelConfig config;
|
||||||
[GroupInjections, SerializeField] private PlayerInputResolver inputResolver;
|
[GroupInjections, SerializeField] private PlayerInputResolver inputResolver;
|
||||||
[GroupInjections, SerializeField] private SentinelControls controls;
|
[GroupInjections, SerializeField] private SentinelControls controls;
|
||||||
[GroupInjections, SerializeField] private ActionBeltManager actionBeltManager;
|
[GroupInjections, SerializeField] private ActionBeltRuntime actionBeltRuntime;
|
||||||
[GroupInjections, SerializeField] private Cadences cadences;
|
[GroupInjections, SerializeField] private Cadences cadences;
|
||||||
|
|
||||||
private bool StateFirstFrame { get; set; }
|
private bool StateFirstFrame { get; set; }
|
||||||
@ -35,7 +35,7 @@ namespace Intrepid.Gameplay.Entities.Player.Sentinel
|
|||||||
public SentinelConfig Config => config;
|
public SentinelConfig Config => config;
|
||||||
public PlayerInputResolver InputResolver => inputResolver;
|
public PlayerInputResolver InputResolver => inputResolver;
|
||||||
public SentinelControls Controls => controls;
|
public SentinelControls Controls => controls;
|
||||||
public ActionBeltManager ActionBeltManager => actionBeltManager;
|
public ActionBeltRuntime ActionBeltRuntime => actionBeltRuntime;
|
||||||
public Cadences Cadences => cadences;
|
public Cadences Cadences => cadences;
|
||||||
public static bool IsCoreStable => !CoreStabilityService.Instance.IsCollapsed;
|
public static bool IsCoreStable => !CoreStabilityService.Instance.IsCollapsed;
|
||||||
public bool IsEnabled { get; private set; }
|
public bool IsEnabled { get; private set; }
|
||||||
|
|||||||
@ -47,13 +47,13 @@ namespace Intrepid.Gameplay.Entities.Player.Sentinel.StateMachine
|
|||||||
|
|
||||||
protected void VerifyInteraction()
|
protected void VerifyInteraction()
|
||||||
{
|
{
|
||||||
if (!Brain.ActionBeltManager.IsOperational || Brain.ActionBeltManager.IsEmpty)
|
if (!Brain.ActionBeltRuntime.IsOperational || Brain.ActionBeltRuntime.IsEmpty)
|
||||||
{
|
{
|
||||||
ResetActionBeltHoldActivation();
|
ResetActionBeltHoldActivation();
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
var actionEnvelope = Brain.ActionBeltManager.Focus;
|
var actionEnvelope = Brain.ActionBeltRuntime.Focus;
|
||||||
if (ActionActivationMode.Hold == actionEnvelope.ActivationMode)
|
if (ActionActivationMode.Hold == actionEnvelope.ActivationMode)
|
||||||
{
|
{
|
||||||
VerifyHoldInteraction(actionEnvelope);
|
VerifyHoldInteraction(actionEnvelope);
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user