修改数据名称
This commit is contained in:
parent
c1559e8a65
commit
ad25cb0d27
Binary file not shown.
|
@ -27665,7 +27665,7 @@ MonoBehaviour:
|
|||
m_Script: {fileID: 11500000, guid: 6b1cb0c16706db34f8a5d7111f1cd3a6, type: 3}
|
||||
m_Name:
|
||||
m_EditorClassIdentifier:
|
||||
triggerID: 0
|
||||
triggerName: "\u62C6\u88C5\u5DE5\u5355\u6309\u94AE"
|
||||
--- !u!1 &5092569754032104682
|
||||
GameObject:
|
||||
m_ObjectHideFlags: 0
|
||||
|
|
|
@ -15572,7 +15572,7 @@ MonoBehaviour:
|
|||
m_Script: {fileID: 11500000, guid: 9afaf08117c8e0b48bf05e12b69562db, type: 3}
|
||||
m_Name:
|
||||
m_EditorClassIdentifier:
|
||||
triggerID: 5013
|
||||
triggerName: "\u4F4E\u538B\u5DE5\u4F5C\u7968\u786E\u8BA4\u6309\u94AE"
|
||||
backpack: {fileID: 5749827229883739022}
|
||||
itemUIPrefab: {fileID: -4679764939652260833, guid: b5c6ed5e8d9749a438a8269c409f0390, type: 3}
|
||||
Content: {fileID: 107056970}
|
||||
|
|
|
@ -1929,9 +1929,9 @@ MonoBehaviour:
|
|||
ExpandSprite: {fileID: 21300000, guid: 4c690750a2bdfd846b732a727903f291, type: 3}
|
||||
CollapseSprite: {fileID: 21300000, guid: 352fb2f67e1311f42a17d4be24bd51b6, type: 3}
|
||||
countDown: 0
|
||||
workOrderID: 5006
|
||||
disassemblyAssemblyWorkOrderID: 5007
|
||||
toolKitID: 5019
|
||||
workOrderName: "\u5DE5\u4F5C\u7968\u6309\u94AE"
|
||||
disassemblyAssemblyWorkOrderName: "\u62C6\u88C5\u5DE5\u5355\u6309\u94AE"
|
||||
toolKitName: "\u80CC\u5305\u6309\u94AE"
|
||||
--- !u!1 &7034408565425647768
|
||||
GameObject:
|
||||
m_ObjectHideFlags: 0
|
||||
|
|
|
@ -33,7 +33,7 @@ public class JBQ_Test : MonoBehaviour
|
|||
UIManager.Instance.ShowPanel<UI_SelectWorkTicketPanel>(E_UI_Layer.System, (panel) =>
|
||||
{
|
||||
ProcessManager.Instance.mode = E_ModeType.Study;
|
||||
panel.Init(4);
|
||||
//panel.Init(4);
|
||||
|
||||
});
|
||||
|
||||
|
|
|
@ -0,0 +1,8 @@
|
|||
fileFormatVersion: 2
|
||||
guid: e5e15d40a26b4714681ceb168d621bfe
|
||||
folderAsset: yes
|
||||
DefaultImporter:
|
||||
externalObjects: {}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
|
@ -97,7 +97,7 @@ LightmapSettings:
|
|||
m_ExportTrainingData: 0
|
||||
m_TrainingDataDestination: TrainingData
|
||||
m_LightProbeSampleCountMultiplier: 4
|
||||
m_LightingDataAsset: {fileID: 0}
|
||||
m_LightingDataAsset: {fileID: 112000000, guid: af2023418f866804e931ff17ba48f7e7, type: 2}
|
||||
m_LightingSettings: {fileID: 0}
|
||||
--- !u!196 &4
|
||||
NavMeshSettings:
|
||||
|
@ -470,8 +470,8 @@ MonoBehaviour:
|
|||
m_Script: {fileID: 11500000, guid: fa45c24333cc9da47815471820b14336, type: 3}
|
||||
m_Name:
|
||||
m_EditorClassIdentifier:
|
||||
triggerID: 0
|
||||
triggerName:
|
||||
triggerID: 5021
|
||||
triggerName: "\u63D2\u5EA7"
|
||||
_highlight: {fileID: 0}
|
||||
deviceType: 2
|
||||
testPosAndRot: {fileID: 192342790}
|
||||
|
@ -2959,7 +2959,7 @@ MonoBehaviour:
|
|||
m_Script: {fileID: 11500000, guid: e83ad6c42a2ebf24191e9a0b21b2f7b5, type: 3}
|
||||
m_Name:
|
||||
m_EditorClassIdentifier:
|
||||
triggerID: 0
|
||||
triggerID: 5021
|
||||
triggerName:
|
||||
_highlight: {fileID: 0}
|
||||
deviceType: 4
|
||||
|
@ -3871,8 +3871,8 @@ MonoBehaviour:
|
|||
m_Script: {fileID: 11500000, guid: 3cd16809b5f7a5f4fbc9f6e63c91c9a4, type: 3}
|
||||
m_Name:
|
||||
m_EditorClassIdentifier:
|
||||
triggerID: 0
|
||||
triggerName:
|
||||
triggerID: 5022
|
||||
triggerName: "\u67DC\u95E8"
|
||||
_highlight: {fileID: 0}
|
||||
deviceType: 1
|
||||
testPosAndRot: {fileID: 248877667}
|
||||
|
@ -6310,6 +6310,22 @@ PrefabInstance:
|
|||
m_Modification:
|
||||
m_TransformParent: {fileID: 543450652271447145}
|
||||
m_Modifications:
|
||||
- target: {fileID: 2576541079831587447, guid: 10f4454f32eb20e4298912d896f6020e, type: 3}
|
||||
propertyPath: triggerID
|
||||
value: 5023
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 2576541079831587447, guid: 10f4454f32eb20e4298912d896f6020e, type: 3}
|
||||
propertyPath: triggerName
|
||||
value: "\u7535\u80FD\u8868\u5C01\u5370"
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 2576541079831587450, guid: 10f4454f32eb20e4298912d896f6020e, type: 3}
|
||||
propertyPath: triggerID
|
||||
value: 5023
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 2576541079831587450, guid: 10f4454f32eb20e4298912d896f6020e, type: 3}
|
||||
propertyPath: triggerName
|
||||
value: "\u7535\u80FD\u8868\u5C01\u5370"
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 2576541080106509928, guid: 10f4454f32eb20e4298912d896f6020e, type: 3}
|
||||
propertyPath: hasElectricity
|
||||
value: 1
|
||||
|
@ -6338,6 +6354,14 @@ PrefabInstance:
|
|||
propertyPath: hasElectricity
|
||||
value: 1
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 2576541080563400544, guid: 10f4454f32eb20e4298912d896f6020e, type: 3}
|
||||
propertyPath: triggerID
|
||||
value: 5025
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 2576541080563400544, guid: 10f4454f32eb20e4298912d896f6020e, type: 3}
|
||||
propertyPath: triggerName
|
||||
value: "\u7535\u80FD\u8868\u87BA\u4E1D"
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 2576541080563400545, guid: 10f4454f32eb20e4298912d896f6020e, type: 3}
|
||||
propertyPath: hasElectricity
|
||||
value: 1
|
||||
|
@ -6346,6 +6370,14 @@ PrefabInstance:
|
|||
propertyPath: hasElectricity
|
||||
value: 1
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 2576541080772862035, guid: 10f4454f32eb20e4298912d896f6020e, type: 3}
|
||||
propertyPath: triggerID
|
||||
value: 5025
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 2576541080772862035, guid: 10f4454f32eb20e4298912d896f6020e, type: 3}
|
||||
propertyPath: triggerName
|
||||
value: "\u7535\u80FD\u8868\u87BA\u4E1D"
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 2576541080794005323, guid: 10f4454f32eb20e4298912d896f6020e, type: 3}
|
||||
propertyPath: hasElectricity
|
||||
value: 1
|
||||
|
@ -6354,6 +6386,14 @@ PrefabInstance:
|
|||
propertyPath: hasElectricity
|
||||
value: 1
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 2576541080985544078, guid: 10f4454f32eb20e4298912d896f6020e, type: 3}
|
||||
propertyPath: triggerID
|
||||
value: 5024
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 2576541080985544078, guid: 10f4454f32eb20e4298912d896f6020e, type: 3}
|
||||
propertyPath: triggerName
|
||||
value: "\u7535\u80FD\u8868\u76D6\u5B50"
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 2576541081049590947, guid: 10f4454f32eb20e4298912d896f6020e, type: 3}
|
||||
propertyPath: hasElectricity
|
||||
value: 1
|
||||
|
|
Binary file not shown.
|
@ -0,0 +1,8 @@
|
|||
fileFormatVersion: 2
|
||||
guid: af2023418f866804e931ff17ba48f7e7
|
||||
NativeFormatImporter:
|
||||
externalObjects: {}
|
||||
mainObjectFileID: 112000000
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
Binary file not shown.
|
@ -0,0 +1,159 @@
|
|||
fileFormatVersion: 2
|
||||
guid: e20cb21fb5e398a4481df312e385f57a
|
||||
TextureImporter:
|
||||
internalIDToNameTable: []
|
||||
externalObjects: {}
|
||||
serializedVersion: 12
|
||||
mipmaps:
|
||||
mipMapMode: 0
|
||||
enableMipMap: 1
|
||||
sRGBTexture: 1
|
||||
linearTexture: 0
|
||||
fadeOut: 0
|
||||
borderMipMap: 0
|
||||
mipMapsPreserveCoverage: 0
|
||||
alphaTestReferenceValue: 0.5
|
||||
mipMapFadeDistanceStart: 1
|
||||
mipMapFadeDistanceEnd: 3
|
||||
bumpmap:
|
||||
convertToNormalMap: 0
|
||||
externalNormalMap: 0
|
||||
heightScale: 0.25
|
||||
normalMapFilter: 0
|
||||
isReadable: 0
|
||||
streamingMipmaps: 0
|
||||
streamingMipmapsPriority: 0
|
||||
vTOnly: 0
|
||||
ignoreMasterTextureLimit: 0
|
||||
grayScaleToAlpha: 0
|
||||
generateCubemap: 6
|
||||
cubemapConvolution: 1
|
||||
seamlessCubemap: 1
|
||||
textureFormat: 1
|
||||
maxTextureSize: 2048
|
||||
textureSettings:
|
||||
serializedVersion: 2
|
||||
filterMode: 2
|
||||
aniso: 0
|
||||
mipBias: 0
|
||||
wrapU: 1
|
||||
wrapV: 1
|
||||
wrapW: 1
|
||||
nPOTScale: 1
|
||||
lightmap: 0
|
||||
compressionQuality: 50
|
||||
spriteMode: 0
|
||||
spriteExtrude: 1
|
||||
spriteMeshType: 1
|
||||
alignment: 0
|
||||
spritePivot: {x: 0.5, y: 0.5}
|
||||
spritePixelsToUnits: 100
|
||||
spriteBorder: {x: 0, y: 0, z: 0, w: 0}
|
||||
spriteGenerateFallbackPhysicsShape: 1
|
||||
alphaUsage: 1
|
||||
alphaIsTransparency: 0
|
||||
spriteTessellationDetail: -1
|
||||
textureType: 0
|
||||
textureShape: 2
|
||||
singleChannelComponent: 0
|
||||
flipbookRows: 1
|
||||
flipbookColumns: 1
|
||||
maxTextureSizeSet: 0
|
||||
compressionQualitySet: 0
|
||||
textureFormatSet: 0
|
||||
ignorePngGamma: 0
|
||||
applyGammaDecoding: 0
|
||||
cookieLightType: 0
|
||||
platformSettings:
|
||||
- serializedVersion: 3
|
||||
buildTarget: DefaultTexturePlatform
|
||||
maxTextureSize: 2048
|
||||
resizeAlgorithm: 0
|
||||
textureFormat: -1
|
||||
textureCompression: 1
|
||||
compressionQuality: 100
|
||||
crunchedCompression: 0
|
||||
allowsAlphaSplitting: 0
|
||||
overridden: 0
|
||||
androidETC2FallbackOverride: 0
|
||||
forceMaximumCompressionQuality_BC6H_BC7: 0
|
||||
- serializedVersion: 3
|
||||
buildTarget: Standalone
|
||||
maxTextureSize: 8192
|
||||
resizeAlgorithm: 0
|
||||
textureFormat: -1
|
||||
textureCompression: 1
|
||||
compressionQuality: 50
|
||||
crunchedCompression: 0
|
||||
allowsAlphaSplitting: 0
|
||||
overridden: 0
|
||||
androidETC2FallbackOverride: 0
|
||||
forceMaximumCompressionQuality_BC6H_BC7: 0
|
||||
- serializedVersion: 3
|
||||
buildTarget: iPhone
|
||||
maxTextureSize: 8192
|
||||
resizeAlgorithm: 0
|
||||
textureFormat: -1
|
||||
textureCompression: 1
|
||||
compressionQuality: 50
|
||||
crunchedCompression: 0
|
||||
allowsAlphaSplitting: 0
|
||||
overridden: 0
|
||||
androidETC2FallbackOverride: 0
|
||||
forceMaximumCompressionQuality_BC6H_BC7: 0
|
||||
- serializedVersion: 3
|
||||
buildTarget: Android
|
||||
maxTextureSize: 8192
|
||||
resizeAlgorithm: 0
|
||||
textureFormat: -1
|
||||
textureCompression: 1
|
||||
compressionQuality: 50
|
||||
crunchedCompression: 0
|
||||
allowsAlphaSplitting: 0
|
||||
overridden: 0
|
||||
androidETC2FallbackOverride: 0
|
||||
forceMaximumCompressionQuality_BC6H_BC7: 0
|
||||
- serializedVersion: 3
|
||||
buildTarget: Windows Store Apps
|
||||
maxTextureSize: 8192
|
||||
resizeAlgorithm: 0
|
||||
textureFormat: -1
|
||||
textureCompression: 1
|
||||
compressionQuality: 50
|
||||
crunchedCompression: 0
|
||||
allowsAlphaSplitting: 0
|
||||
overridden: 0
|
||||
androidETC2FallbackOverride: 0
|
||||
forceMaximumCompressionQuality_BC6H_BC7: 0
|
||||
- serializedVersion: 3
|
||||
buildTarget: WebGL
|
||||
maxTextureSize: 8192
|
||||
resizeAlgorithm: 0
|
||||
textureFormat: -1
|
||||
textureCompression: 1
|
||||
compressionQuality: 50
|
||||
crunchedCompression: 0
|
||||
allowsAlphaSplitting: 0
|
||||
overridden: 0
|
||||
androidETC2FallbackOverride: 0
|
||||
forceMaximumCompressionQuality_BC6H_BC7: 0
|
||||
spriteSheet:
|
||||
serializedVersion: 2
|
||||
sprites: []
|
||||
outline: []
|
||||
physicsShape: []
|
||||
bones: []
|
||||
spriteID:
|
||||
internalID: 0
|
||||
vertices: []
|
||||
indices:
|
||||
edges: []
|
||||
weights: []
|
||||
secondaryTextures: []
|
||||
nameFileIdTable: {}
|
||||
spritePackingTag:
|
||||
pSDRemoveMatte: 0
|
||||
pSDShowRemoveMatteOption: 0
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
|
@ -24,7 +24,7 @@ public class Device_CabinetDoor : Device_Base
|
|||
{
|
||||
Debug.Log("开门");
|
||||
//开锁
|
||||
transform.Find("¼ÆÁ¿¹ñËø2/¼ÆÁ¿¹ñËø3").DOLocalRotate(new Vector3(-45f, 0, 0), 1).OnComplete(() =>
|
||||
transform.Find("¼ÆÁ¿¹ñËø2/¼ÆÁ¿¹ñËø3").DOLocalRotate(new Vector3(-45f, 0, 0), 1).OnComplete(() =>
|
||||
{
|
||||
//开门
|
||||
transform.DOLocalRotate(new Vector3(0, 0, 180), 3).OnComplete(() =>
|
||||
|
@ -32,24 +32,25 @@ public class Device_CabinetDoor : Device_Base
|
|||
isOpen = true;
|
||||
});
|
||||
});
|
||||
}
|
||||
}
|
||||
public void Close()
|
||||
{
|
||||
Debug.Log("关门");
|
||||
//关门
|
||||
transform.DOLocalRotate(new Vector3(0,0,0), 3).OnComplete(() =>
|
||||
{
|
||||
transform.DOLocalRotate(new Vector3(0, 0, 0), 3).OnComplete(() =>
|
||||
{
|
||||
//关锁
|
||||
transform.Find("¼ÆÁ¿¹ñËø2/¼ÆÁ¿¹ñËø3").DOLocalRotate(new Vector3(0, 0, 0), 1).OnComplete(() =>
|
||||
{
|
||||
isOpen = false;
|
||||
});
|
||||
});
|
||||
transform.Find("¼ÆÁ¿¹ñËø2/¼ÆÁ¿¹ñËø3").DOLocalRotate(new Vector3(0, 0, 0), 1).OnComplete(() =>
|
||||
{
|
||||
isOpen = false;
|
||||
});
|
||||
});
|
||||
}
|
||||
|
||||
private void OnMouseDown()
|
||||
{
|
||||
if(isOpen)
|
||||
if (LiveSceneManager.Instance.currentTool.name == "Ñéµç±Ê") return;
|
||||
if (isOpen)
|
||||
{
|
||||
Close();
|
||||
}
|
||||
|
|
|
@ -74,7 +74,7 @@ public class StepState : MonoBehaviour
|
|||
GameManager.UIMgr.HidePanel<UI_LoadingPanel>();
|
||||
GameManager.RunModelMgr.SceneType = initSceneType;
|
||||
GameManager.EventMgr.EventTrigger(Enum_EventType.SwitchScene, initSceneType);
|
||||
GameManager.EventMgr.EventTrigger<int>(Enum_EventType.SwitchSubProcessStepTriggerID, GameManager.ProcessMgr.d_Scheme.CurrentProcess.CurrentSubProcess.CurrentSubProcessStep.triggersId[0]);
|
||||
GameManager.EventMgr.EventTrigger<string>(Enum_EventType.SwitchSubProcessStepTriggerID, GameManager.ProcessMgr.d_Scheme.CurrentProcess.CurrentSubProcess.CurrentSubProcessStep.triggersName[0]);
|
||||
});
|
||||
}
|
||||
}
|
||||
|
|
|
@ -32,8 +32,8 @@ public class Tool_TestPen : Tool_Base
|
|||
}
|
||||
|
||||
//¹ñÃÅ
|
||||
Tool_Base tb= hit.transform.GetComponent<Tool_Base>();
|
||||
if(tb != null)
|
||||
Tool_Base tb = hit.transform.GetComponent<Tool_Base>();
|
||||
if (tb != null)
|
||||
{
|
||||
Test(tb);
|
||||
return;
|
||||
|
@ -41,14 +41,14 @@ public class Tool_TestPen : Tool_Base
|
|||
}
|
||||
}
|
||||
|
||||
if(isFlicker)
|
||||
if (isFlicker)
|
||||
{
|
||||
time += Time.deltaTime*3;
|
||||
time += Time.deltaTime * 3;
|
||||
if (time < 1)
|
||||
{
|
||||
screem.materials[0].color = Color.red;
|
||||
}
|
||||
else if(time>1 && time<2)
|
||||
else if (time > 1 && time < 2)
|
||||
{
|
||||
screem.materials[0].color = Color.white;
|
||||
}
|
||||
|
@ -64,26 +64,29 @@ public class Tool_TestPen : Tool_Base
|
|||
/// <param name="device_base">±»ÑéµçÉ豸</param>
|
||||
public void Test(Device_Base device_base)
|
||||
{
|
||||
if (device_base.deviceType == DeviceType.计量柜_插座)
|
||||
if (GameManager.ProcessMgr.IsRightSubProcessStepsTriggerID(device_base.triggerName, true) == 0)
|
||||
{
|
||||
var tmp = ((Device_Socket)device_base);
|
||||
//位置移动
|
||||
transform.position = tmp.testPosAndRot.position;
|
||||
transform.eulerAngles = tmp.testPosAndRot.eulerAngles;
|
||||
Debug.Log("计量柜_插座 已验电");
|
||||
isFlicker = tmp.hasElectricity;
|
||||
}
|
||||
else if(device_base.deviceType == DeviceType.计量柜_柜门)
|
||||
{
|
||||
var tmp = ((Device_CabinetDoor)device_base);
|
||||
//位置移动
|
||||
transform.position = tmp.testPosAndRot.position;
|
||||
transform.localEulerAngles = tmp.testPosAndRot.localEulerAngles;
|
||||
Debug.Log("计量柜_柜门 已验电");
|
||||
isFlicker = tmp.hasElectricity;
|
||||
}
|
||||
if (device_base.deviceType == DeviceType.计量柜_插座)
|
||||
{
|
||||
var tmp = ((Device_Socket)device_base);
|
||||
//位置移动
|
||||
transform.position = tmp.testPosAndRot.position;
|
||||
transform.eulerAngles = tmp.testPosAndRot.eulerAngles;
|
||||
Debug.Log("计量柜_插座 已验电");
|
||||
isFlicker = tmp.hasElectricity;
|
||||
}
|
||||
else if (device_base.deviceType == DeviceType.计量柜_柜门)
|
||||
{
|
||||
var tmp = ((Device_CabinetDoor)device_base);
|
||||
//位置移动
|
||||
transform.position = tmp.testPosAndRot.position;
|
||||
transform.localEulerAngles = tmp.testPosAndRot.localEulerAngles;
|
||||
Debug.Log("计量柜_柜门 已验电");
|
||||
isFlicker = tmp.hasElectricity;
|
||||
}
|
||||
|
||||
screem.materials[0].color = isFlicker ? Color.red : Color.white;
|
||||
screem.materials[0].color = isFlicker ? Color.red : Color.white;
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
|
@ -105,5 +108,5 @@ public class Tool_TestPen : Tool_Base
|
|||
screem.materials[0].color = isFlicker ? Color.red : Color.white;
|
||||
}
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
|
|
@ -18,12 +18,12 @@ public class D_SubProcessStep : I_Enter, I_Exit
|
|||
public string tipTitle;
|
||||
public float score;
|
||||
|
||||
public List<int> triggersId;
|
||||
public List<string> triggersName;
|
||||
|
||||
public void Init()
|
||||
{
|
||||
GetTriggerID();
|
||||
ProcessManager.Instance.subProcessStepTriggerID = triggersId[0];
|
||||
ProcessManager.Instance.subProcessStepTriggerID = triggersName[0];
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
|
@ -31,19 +31,19 @@ public class D_SubProcessStep : I_Enter, I_Exit
|
|||
/// </summary>
|
||||
public void GetTriggerID()
|
||||
{
|
||||
triggersId = new List<int>();
|
||||
triggersName = new List<string>();
|
||||
if (string.IsNullOrEmpty(triggerID)) return;
|
||||
if (triggerID.Contains(','))
|
||||
{
|
||||
string[] toolIdTemp = triggerID.Split(',');
|
||||
for (int i = 0; i < toolIdTemp.Length; i++)
|
||||
{
|
||||
triggersId.Add(int.Parse(toolIdTemp[i]));
|
||||
triggersName.Add(toolIdTemp[i]);
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
triggersId.Add(int.Parse(triggerID));
|
||||
triggersName.Add(triggerID);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -27,7 +27,7 @@ public class LiveSceneManager : SingletonMono<LiveSceneManager>
|
|||
{
|
||||
GameManager.UIMgr.ShowPanel<UI_PlayerSessionPanel>(E_UI_Layer.Mid, (p) =>
|
||||
{
|
||||
p.Init(0, "您好,我是xx供电公司员工,这是我的工作证。现在我们要对贵户更换电能计量表", (intTemp) => { Destroy(currentTool); });
|
||||
p.Init("", "您好,我是xx供电公司员工,这是我的工作证。现在我们要对贵户更换电能计量表", (intTemp) => { Destroy(currentTool); });
|
||||
});
|
||||
tMDTips.gameObject.SetActive(false);
|
||||
}
|
||||
|
|
|
@ -60,7 +60,7 @@ public class OfficeManager : MonoBehaviour
|
|||
panel.Init();
|
||||
GameManager.EventMgr.EventTrigger(Enum_EventType.SwitchScene, GameManager.RunModelMgr.SceneType);
|
||||
});
|
||||
GameManager.EventMgr.EventTrigger<int>(Enum_EventType.SwitchSubProcessStepTriggerID, GameManager.ProcessMgr.d_Scheme.CurrentProcess.CurrentSubProcess.CurrentSubProcessStep.triggersId[0]);
|
||||
GameManager.EventMgr.EventTrigger<string>(Enum_EventType.SwitchSubProcessStepTriggerID, GameManager.ProcessMgr.d_Scheme.CurrentProcess.CurrentSubProcess.CurrentSubProcessStep.triggersName[0]);
|
||||
}
|
||||
|
||||
|
||||
|
|
|
@ -7,14 +7,14 @@ using UnityEngine;
|
|||
/// </summary>
|
||||
public class PacksackBagMgr : BaseManager<PacksackBagMgr>
|
||||
{
|
||||
private readonly Dictionary<int, List<ItemInfo>> toolAndMaterialDic = new Dictionary<int, List<ItemInfo>>();
|
||||
public Dictionary<int, ItemInfo> wearDic = new Dictionary<int, ItemInfo>();
|
||||
private readonly Dictionary<string, List<ItemInfo>> toolAndMaterialDic = new Dictionary<string, List<ItemInfo>>();
|
||||
public Dictionary<string, ItemInfo> wearDic = new Dictionary<string, ItemInfo>();
|
||||
|
||||
private PacksackBagMgr()
|
||||
{
|
||||
}
|
||||
|
||||
public Dictionary<int, List<ItemInfo>> GetCurrentBagData()
|
||||
public Dictionary<string, List<ItemInfo>> GetCurrentBagData()
|
||||
{
|
||||
return toolAndMaterialDic;
|
||||
}
|
||||
|
@ -26,19 +26,19 @@ public class PacksackBagMgr : BaseManager<PacksackBagMgr>
|
|||
/// <param name="name"></param>
|
||||
public void AddOneToolOrMater(ItemInfo itemInfo)
|
||||
{
|
||||
if (toolAndMaterialDic.ContainsKey(itemInfo.toolId))
|
||||
if (toolAndMaterialDic.ContainsKey(itemInfo.toolName))
|
||||
{
|
||||
toolAndMaterialDic[itemInfo.toolId].Add(itemInfo);
|
||||
toolAndMaterialDic[itemInfo.toolName].Add(itemInfo);
|
||||
}
|
||||
else
|
||||
{
|
||||
toolAndMaterialDic.Add(itemInfo.toolId, new List<ItemInfo>() { itemInfo });
|
||||
toolAndMaterialDic.Add(itemInfo.toolName, new List<ItemInfo>() { itemInfo });
|
||||
}
|
||||
}
|
||||
|
||||
public Dictionary<int, List<ItemInfo>> GetItemsByE_TMDType(E_ToolOrDeviceOrMaterials tmdTpye)
|
||||
public Dictionary<string, List<ItemInfo>> GetItemsByE_TMDType(E_ToolOrDeviceOrMaterials tmdTpye)
|
||||
{
|
||||
Dictionary<int, List<ItemInfo>> tempNew = new Dictionary<int, List<ItemInfo>>();
|
||||
Dictionary<string, List<ItemInfo>> tempNew = new Dictionary<string, List<ItemInfo>>();
|
||||
|
||||
var dicTemp = toolAndMaterialDic;
|
||||
foreach (var item in dicTemp.Keys)
|
||||
|
@ -48,13 +48,13 @@ public class PacksackBagMgr : BaseManager<PacksackBagMgr>
|
|||
if (dicTemp[item][i].toolOrDeviceOrMaterial == tmdTpye)
|
||||
{
|
||||
|
||||
if (tempNew.ContainsKey(dicTemp[item][i].toolId))
|
||||
if (tempNew.ContainsKey(dicTemp[item][i].toolName))
|
||||
{
|
||||
tempNew[dicTemp[item][i].toolId].Add(dicTemp[item][i]);
|
||||
tempNew[dicTemp[item][i].toolName].Add(dicTemp[item][i]);
|
||||
}
|
||||
else
|
||||
{
|
||||
tempNew.Add(dicTemp[item][i].toolId, new List<ItemInfo>() { dicTemp[item][i] });
|
||||
tempNew.Add(dicTemp[item][i].toolName, new List<ItemInfo>() { dicTemp[item][i] });
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -69,15 +69,15 @@ public class PacksackBagMgr : BaseManager<PacksackBagMgr>
|
|||
/// <param name="name"></param>
|
||||
public void RemoveOneToolOrMater(ItemInfo itemInfo)
|
||||
{
|
||||
if (toolAndMaterialDic.ContainsKey(itemInfo.toolId))
|
||||
if (toolAndMaterialDic.ContainsKey(itemInfo.toolName))
|
||||
{
|
||||
if (toolAndMaterialDic[itemInfo.toolId].Count > 1)
|
||||
if (toolAndMaterialDic[itemInfo.toolName].Count > 1)
|
||||
{
|
||||
toolAndMaterialDic[itemInfo.toolId].Remove(itemInfo);
|
||||
toolAndMaterialDic[itemInfo.toolName].Remove(itemInfo);
|
||||
}
|
||||
else
|
||||
{
|
||||
toolAndMaterialDic.Remove(itemInfo.toolId);
|
||||
toolAndMaterialDic.Remove(itemInfo.toolName);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -87,9 +87,9 @@ public class PacksackBagMgr : BaseManager<PacksackBagMgr>
|
|||
/// <param name="itemInfo"></param>
|
||||
public void RemoveAllToolOrMater(ItemInfo itemInfo)
|
||||
{
|
||||
if (toolAndMaterialDic.ContainsKey(itemInfo.toolId))
|
||||
if (toolAndMaterialDic.ContainsKey(itemInfo.toolName))
|
||||
{
|
||||
toolAndMaterialDic.Remove(itemInfo.toolId);
|
||||
toolAndMaterialDic.Remove(itemInfo.toolName);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -110,13 +110,13 @@ public class PacksackBagMgr : BaseManager<PacksackBagMgr>
|
|||
{
|
||||
if (state)
|
||||
{
|
||||
if (!wearDic.ContainsKey(itemInfo.toolId))
|
||||
wearDic.Add(itemInfo.toolId, itemInfo);
|
||||
if (!wearDic.ContainsKey(itemInfo.toolName))
|
||||
wearDic.Add(itemInfo.toolName, itemInfo);
|
||||
}
|
||||
else
|
||||
{
|
||||
if (wearDic.ContainsKey(itemInfo.toolId))
|
||||
wearDic.Remove(itemInfo.toolId);
|
||||
if (wearDic.ContainsKey(itemInfo.toolName))
|
||||
wearDic.Remove(itemInfo.toolName);
|
||||
}
|
||||
}
|
||||
}
|
|
@ -48,7 +48,7 @@ public class ProcessManager : BaseManager<ProcessManager>
|
|||
/// </summary>
|
||||
public int subProcessStepId = -1;
|
||||
|
||||
public int subProcessStepTriggerID = -1;
|
||||
public string subProcessStepTriggerID = "-1";
|
||||
|
||||
/// <summary>
|
||||
/// 倒计时,剩余时长
|
||||
|
@ -180,25 +180,25 @@ public class ProcessManager : BaseManager<ProcessManager>
|
|||
/// </summary>
|
||||
/// <param name="triggerID"></param>
|
||||
/// <returns></returns>
|
||||
public int IsRightSubProcessStepsTriggerID(int triggerID, bool isRemove)
|
||||
public int IsRightSubProcessStepsTriggerID(string triggerID, bool isRemove)
|
||||
{
|
||||
if (d_Scheme.CurrentProcess.CurrentSubProcess.CurrentSubProcessStep.precondition == GameManager.RunModelMgr.SceneType.ToString())
|
||||
{
|
||||
if (d_Scheme.CurrentProcess.CurrentSubProcess.CurrentSubProcessStep.triggersId.Count > 0)
|
||||
if (d_Scheme.CurrentProcess.CurrentSubProcess.CurrentSubProcessStep.triggersName.Count > 0)
|
||||
{
|
||||
int currentSubProcessStepTriggerID = d_Scheme.CurrentProcess.CurrentSubProcess.CurrentSubProcessStep.triggersId[0];
|
||||
string currentSubProcessStepTriggerID = d_Scheme.CurrentProcess.CurrentSubProcess.CurrentSubProcessStep.triggersName[0];
|
||||
if (triggerID == currentSubProcessStepTriggerID)
|
||||
{
|
||||
if (isRemove)
|
||||
d_Scheme.CurrentProcess.CurrentSubProcess.CurrentSubProcessStep.triggersId.RemoveAt(0);
|
||||
if (d_Scheme.CurrentProcess.CurrentSubProcess.CurrentSubProcessStep.triggersId.Count == 0)
|
||||
d_Scheme.CurrentProcess.CurrentSubProcess.CurrentSubProcessStep.triggersName.RemoveAt(0);
|
||||
if (d_Scheme.CurrentProcess.CurrentSubProcess.CurrentSubProcessStep.triggersName.Count == 0)
|
||||
{
|
||||
CheckSubProcessSteps(GameManager.ProcessMgr.subProcessStepId);
|
||||
Debug.Log($"<color=red>triggersId空了</color>");
|
||||
}
|
||||
if (d_Scheme.CurrentProcess.CurrentSubProcess.CurrentSubProcessStep.triggersId.Count != 0)
|
||||
if (d_Scheme.CurrentProcess.CurrentSubProcess.CurrentSubProcessStep.triggersName.Count != 0)
|
||||
{
|
||||
GameManager.EventMgr.EventTrigger<int>(Enum_EventType.SwitchSubProcessStepTriggerID, d_Scheme.CurrentProcess.CurrentSubProcess.CurrentSubProcessStep.triggersId[0]);
|
||||
GameManager.EventMgr.EventTrigger<string>(Enum_EventType.SwitchSubProcessStepTriggerID, d_Scheme.CurrentProcess.CurrentSubProcess.CurrentSubProcessStep.triggersName[0]);
|
||||
}
|
||||
return 0;
|
||||
}
|
||||
|
|
|
@ -11,7 +11,7 @@ public class MirrorController : PermanentTriggerBase
|
|||
protected override void OnMDown()
|
||||
{
|
||||
base.OnMDown();
|
||||
if (GameManager.ProcessMgr.IsRightSubProcessStepsTriggerID(triggerID, true) == 0)
|
||||
if (GameManager.ProcessMgr.IsRightSubProcessStepsTriggerID(triggerName, true) == 0)
|
||||
{
|
||||
GameManager.UIMgr.ShowPanel<UI_CheckMyselfPanel>(E_UI_Layer.Mid);
|
||||
}
|
||||
|
|
|
@ -25,11 +25,11 @@ public class MobileController : PermanentTriggerBase
|
|||
switch (downIndex)
|
||||
{
|
||||
case 0:
|
||||
if (GameManager.ProcessMgr.IsRightSubProcessStepsTriggerID(triggerID, false) == 0)
|
||||
if (GameManager.ProcessMgr.IsRightSubProcessStepsTriggerID(triggerName, false) == 0)
|
||||
{
|
||||
GameManager.UIMgr.ShowPanel<UI_ReceiveTaskPanel>(E_UI_Layer.Mid, (panel) =>
|
||||
{
|
||||
panel.Init(triggerID);
|
||||
panel.Init(triggerName);
|
||||
});
|
||||
downIndex++;
|
||||
}
|
||||
|
@ -38,7 +38,7 @@ public class MobileController : PermanentTriggerBase
|
|||
case 1:
|
||||
GameManager.UIMgr.ShowPanel<UI_PlayerSessionPanel>(E_UI_Layer.Mid, (panel) =>
|
||||
{
|
||||
panel.Init(triggerID, "我是xxx供电所人员,到xxx地方开展经互感器接入式低压电能计量装置安装作业。", PlayerTalk);
|
||||
panel.Init(triggerName, "我是xxx供电所人员,到xxx地方开展经互感器接入式低压电能计量装置安装作业。", PlayerTalk);
|
||||
});
|
||||
_highlight.SetHighlighted(false);
|
||||
downIndex = 0;
|
||||
|
@ -46,7 +46,7 @@ public class MobileController : PermanentTriggerBase
|
|||
}
|
||||
}
|
||||
|
||||
private void PlayerTalk(int triggerID)
|
||||
private void PlayerTalk(string triggerID)
|
||||
{
|
||||
if (GameManager.ProcessMgr.IsRightSubProcessStepsTriggerID(triggerID, true) == 0)
|
||||
{
|
||||
|
|
|
@ -6,31 +6,41 @@ public class NPCController : PermanentTriggerBase
|
|||
{
|
||||
public List<string> npcSpeack;
|
||||
public int speackIndex = 0;
|
||||
private bool onSpeackOver;
|
||||
protected override void OnMDown()
|
||||
{
|
||||
base.OnMDown();
|
||||
if (GameManager.ProcessMgr.IsRightSubProcessStepsTriggerID(triggerID, true) == 0)
|
||||
if(npcSpeack.Count > 1)
|
||||
{
|
||||
onSpeackOver = false;
|
||||
}
|
||||
else
|
||||
{
|
||||
onSpeackOver = true;
|
||||
}
|
||||
if (GameManager.ProcessMgr.IsRightSubProcessStepsTriggerID(triggerName, onSpeackOver) == 0)
|
||||
{
|
||||
GameManager.UIMgr.ShowPanel<UI_CustomSessionPanel>(E_UI_Layer.Mid, (panel) =>
|
||||
{
|
||||
panel.Init(triggerID, npcSpeack[speackIndex], NextSpeack);
|
||||
panel.Init(triggerName, npcSpeack[speackIndex], NextSpeack);
|
||||
});
|
||||
_highlight.SetHighlighted(false);
|
||||
}
|
||||
}
|
||||
|
||||
private void NextSpeack(int id)
|
||||
private void NextSpeack(string id)
|
||||
{
|
||||
speackIndex++;
|
||||
if (speackIndex <= npcSpeack.Count - 1)
|
||||
{
|
||||
if (GameManager.UIMgr.GetPanel<UI_CustomSessionPanel>())
|
||||
{
|
||||
GameManager.UIMgr.GetPanel<UI_CustomSessionPanel>().Init(0, npcSpeack[speackIndex], NextSpeack);
|
||||
GameManager.UIMgr.GetPanel<UI_CustomSessionPanel>().Init("", npcSpeack[speackIndex], NextSpeack);
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
GameManager.ProcessMgr.IsRightSubProcessStepsTriggerID(triggerName, true);
|
||||
if (GameManager.UIMgr.GetPanel<UI_CustomSessionPanel>())
|
||||
GameManager.UIMgr.HidePanel<UI_CustomSessionPanel>();
|
||||
speackIndex = 0;
|
||||
|
|
|
@ -21,9 +21,9 @@ public class PermanentTriggerBase : MonoBehaviour
|
|||
{
|
||||
OnStart();
|
||||
}
|
||||
private void SwitchSubProcessStepTriggerID(int arg0)
|
||||
private void SwitchSubProcessStepTriggerID(string arg0)
|
||||
{
|
||||
if (triggerID == arg0)
|
||||
if (triggerName == arg0)
|
||||
{
|
||||
_highlight.SetHighlighted(true);
|
||||
Debug.Log("PermanentTriggerBase我应该提示");
|
||||
|
@ -45,7 +45,7 @@ public class PermanentTriggerBase : MonoBehaviour
|
|||
/// </summary>
|
||||
protected virtual void OnStart()
|
||||
{
|
||||
GameManager.EventMgr.AddEventListener<int>(Enum_EventType.SwitchSubProcessStepTriggerID, SwitchSubProcessStepTriggerID);
|
||||
GameManager.EventMgr.AddEventListener<string>(Enum_EventType.SwitchSubProcessStepTriggerID, SwitchSubProcessStepTriggerID);
|
||||
}
|
||||
private void OnMouseEnter()
|
||||
{
|
||||
|
@ -79,11 +79,11 @@ public class PermanentTriggerBase : MonoBehaviour
|
|||
|
||||
private void OnDestroy()
|
||||
{
|
||||
GameManager.EventMgr.RemoveEventListener<int>(Enum_EventType.SwitchSubProcessStepTriggerID, SwitchSubProcessStepTriggerID);
|
||||
GameManager.EventMgr.RemoveEventListener<string>(Enum_EventType.SwitchSubProcessStepTriggerID, SwitchSubProcessStepTriggerID);
|
||||
}
|
||||
private void OnDisable()
|
||||
{
|
||||
GameManager.EventMgr.RemoveEventListener<int>(Enum_EventType.SwitchSubProcessStepTriggerID, SwitchSubProcessStepTriggerID);
|
||||
GameManager.EventMgr.RemoveEventListener<string>(Enum_EventType.SwitchSubProcessStepTriggerID, SwitchSubProcessStepTriggerID);
|
||||
}
|
||||
|
||||
|
||||
|
|
|
@ -29,11 +29,11 @@ public abstract class BaseToolOrDevice : MonoBehaviour
|
|||
|
||||
private void Start()
|
||||
{
|
||||
GameManager.EventMgr.AddEventListener<int>(Enum_EventType.SwitchSubProcessStepTriggerID, SwitchSubProcessStepTriggerID);
|
||||
GameManager.EventMgr.AddEventListener<string>(Enum_EventType.SwitchSubProcessStepTriggerID, SwitchSubProcessStepTriggerID);
|
||||
}
|
||||
private void SwitchSubProcessStepTriggerID(int arg0)
|
||||
private void SwitchSubProcessStepTriggerID(string arg0)
|
||||
{
|
||||
if (itemInfo.triggerID == arg0)
|
||||
if (itemInfo.toolName == arg0)
|
||||
{
|
||||
_highlight.SetHighlighted(true);
|
||||
Debug.Log("BaseToolOrDevice我应该提示");
|
||||
|
@ -104,10 +104,10 @@ public abstract class BaseToolOrDevice : MonoBehaviour
|
|||
|
||||
private void OnDestroy()
|
||||
{
|
||||
GameManager.EventMgr.RemoveEventListener<int>(Enum_EventType.SwitchSubProcessStepTriggerID, SwitchSubProcessStepTriggerID);
|
||||
GameManager.EventMgr.RemoveEventListener<string>(Enum_EventType.SwitchSubProcessStepTriggerID, SwitchSubProcessStepTriggerID);
|
||||
}
|
||||
private void OnDisable()
|
||||
{
|
||||
GameManager.EventMgr.RemoveEventListener<int>(Enum_EventType.SwitchSubProcessStepTriggerID, SwitchSubProcessStepTriggerID);
|
||||
GameManager.EventMgr.RemoveEventListener<string>(Enum_EventType.SwitchSubProcessStepTriggerID, SwitchSubProcessStepTriggerID);
|
||||
}
|
||||
}
|
|
@ -22,7 +22,7 @@ public class Tool_SelectComponent : BaseToolOrDevice
|
|||
public override void OnDown()
|
||||
{
|
||||
base.OnDown();
|
||||
if (GameManager.ProcessMgr.IsRightSubProcessStepsTriggerID(itemInfo.triggerID, true) == 0)
|
||||
if (GameManager.ProcessMgr.IsRightSubProcessStepsTriggerID(itemInfo.toolName, true) == 0)
|
||||
{
|
||||
GameManager.PacksackBagMgr.AddOneToolOrMater(itemInfo);
|
||||
GameManager.UIMgr.HidePanel<ItemTips>();//ÌáÊ¾Ãæ°å
|
||||
|
|
|
@ -13,7 +13,7 @@ public class UI_CheckMyselfItem : BaseItem
|
|||
public void Init(ItemInfo _itemInfo)
|
||||
{
|
||||
itemInfo = _itemInfo;
|
||||
if (PacksackBagMgr.Instance.wearDic.ContainsKey(itemInfo.toolId))
|
||||
if (PacksackBagMgr.Instance.wearDic.ContainsKey(itemInfo.toolName))
|
||||
{
|
||||
isOn = true;
|
||||
tips.text = isOn ? "ÒÑ×°Åä" : "";
|
||||
|
@ -27,7 +27,7 @@ public class UI_CheckMyselfItem : BaseItem
|
|||
switch (btnName)
|
||||
{
|
||||
case "iconBtn":
|
||||
if (GameManager.ProcessMgr.IsRightSubProcessStepsTriggerID(itemInfo.triggerID, true) == 0)
|
||||
if (GameManager.ProcessMgr.IsRightSubProcessStepsTriggerID(itemInfo.toolName, true) == 0)
|
||||
{
|
||||
isOn = !isOn;
|
||||
tips.text = isOn ? "ÒÑ×°Åä" : "";
|
||||
|
|
|
@ -52,7 +52,7 @@ public class UI_SubProcessItem : BaseItem
|
|||
//ÖØÖÃÎïÌå
|
||||
StepStateControl.instance.InvokeInitStepState(GameManager.Instance.systemId, GameManager.ProcessMgr.d_Scheme.id, subProcessID);
|
||||
GameManager.EventMgr.EventTrigger<int>(Enum_EventType.SwitchSubProcess, subProcessID);
|
||||
GameManager.EventMgr.EventTrigger<int>(Enum_EventType.SwitchSubProcessStepTriggerID, GameManager.ProcessMgr.d_Scheme.CurrentProcess.CurrentSubProcess.CurrentSubProcessStep.triggersId[0]);
|
||||
GameManager.EventMgr.EventTrigger<string>(Enum_EventType.SwitchSubProcessStepTriggerID, GameManager.ProcessMgr.d_Scheme.CurrentProcess.CurrentSubProcess.CurrentSubProcessStep.triggersName[0]);
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -49,7 +49,7 @@ public class UI_ToolOrMaterialsOrDeviceItem : BaseItem
|
|||
Destroy(gameObject);
|
||||
break;
|
||||
case "iconBtn":
|
||||
if (GameManager.ProcessMgr.IsRightSubProcessStepsTriggerID(currentItem.triggerID, true) == 0)
|
||||
if (GameManager.ProcessMgr.IsRightSubProcessStepsTriggerID(currentItem.toolName, true) == 0)
|
||||
{
|
||||
GameManager.UIMgr.HidePanel<UI_ToolAndMaterialPanel>();
|
||||
GameObject currentTool = Instantiate(currentItem.objPrefab);
|
||||
|
|
|
@ -4,7 +4,7 @@ using UnityEngine.UI;
|
|||
|
||||
public class UI_CheckMyselfPanel : BasePanel
|
||||
{
|
||||
private int[] validToolNames = { 5008, 5010, 5011, 5009 };
|
||||
private string[] validToolNames = { "国网安全帽", "绝缘手套", "绝缘靴", "工作服" };
|
||||
public RectTransform _content;
|
||||
public UI_CheckMyselfItem ui_CheckMySelfItem;
|
||||
|
||||
|
|
|
@ -6,12 +6,12 @@ using UnityEngine.UI;
|
|||
|
||||
public class UI_CustomSessionPanel : BasePanel
|
||||
{
|
||||
private int triggerID;
|
||||
public Action<int> callBack;
|
||||
private string triggerID;
|
||||
public Action<string> callBack;
|
||||
/// <summary>
|
||||
/// 初始化,state 0 激活另一个操作
|
||||
/// </summary>
|
||||
public void Init(int triggerID, string clientTalk, Action<int> _callBack)
|
||||
public void Init(string triggerID, string clientTalk, Action<string> _callBack)
|
||||
{
|
||||
this.triggerID = triggerID;
|
||||
callBack += _callBack;
|
||||
|
|
|
@ -13,10 +13,10 @@ public class UI_InstallAndDismantleTicketPanel : BasePanel
|
|||
/// 是否已经按确认提交
|
||||
/// </summary>
|
||||
private bool submit=false;
|
||||
public int triggerID;
|
||||
public void Init(int triggerID)
|
||||
public string triggerName;
|
||||
public void Init(string triggerName)
|
||||
{
|
||||
this.triggerID = triggerID;
|
||||
this.triggerName = triggerName;
|
||||
if (submit==true)
|
||||
{
|
||||
Submit();
|
||||
|
@ -39,7 +39,7 @@ public class UI_InstallAndDismantleTicketPanel : BasePanel
|
|||
case "Button_Confirm":
|
||||
submit = true;
|
||||
Debug.Log(submit);
|
||||
if (GameManager.ProcessMgr.IsRightSubProcessStepsTriggerID(triggerID, true) == 0)
|
||||
if (GameManager.ProcessMgr.IsRightSubProcessStepsTriggerID(triggerName, true) == 0)
|
||||
{
|
||||
//GameManager.ProcessMgr.CheckSubProcessSteps(GameManager.ProcessMgr.subProcessStepId);
|
||||
GameManager.UIMgr.HidePanel<UI_InstallAndDismantleTicketPanel>();
|
||||
|
|
|
@ -5,7 +5,8 @@ using UnityEngine.UI;
|
|||
|
||||
public class UI_LowTensionWorkTicketPanel : BasePanel
|
||||
{
|
||||
public int triggerID = 5013;
|
||||
[Header("µÍѹ¹¤×÷ƱȷÈϰ´Å¥")]
|
||||
public string triggerName;
|
||||
public Transform backpack; // 교관UI돨만膠竟
|
||||
public WorkingLineNameOrEquipmentDualName itemUIPrefab; // 교관櫓鞫刻膠틔돨UI渡齡竟
|
||||
public Transform Content; // 교관UI돨만膠竟
|
||||
|
@ -34,7 +35,7 @@ public class UI_LowTensionWorkTicketPanel : BasePanel
|
|||
//GameManager.UIMgr.HidePanel<UI_LowTensionWorkTicketPanel>();
|
||||
break;
|
||||
case "ConfirmBtn":
|
||||
if (GameManager.ProcessMgr.IsRightSubProcessStepsTriggerID(triggerID, true) == 0)
|
||||
if (GameManager.ProcessMgr.IsRightSubProcessStepsTriggerID(triggerName, true) == 0)
|
||||
{
|
||||
//GameManager.ProcessMgr.CheckSubProcessSteps(GameManager.ProcessMgr.subProcessStepId);
|
||||
UIManager.Instance.HidePanel<UI_LowTensionWorkTicketPanel>();
|
||||
|
@ -56,7 +57,7 @@ public class UI_LowTensionWorkTicketPanel : BasePanel
|
|||
StartCoroutine(SetUIRect(obj));
|
||||
}
|
||||
|
||||
private IEnumerator SetUIRect(GameObject obj)
|
||||
private IEnumerator SetUIRect(GameObject obj)
|
||||
{
|
||||
Destroy(obj);
|
||||
yield return new WaitForEndOfFrame();
|
||||
|
|
|
@ -17,9 +17,12 @@ public class UI_MenuBar : BasePanel
|
|||
|
||||
private int time;
|
||||
|
||||
public int workOrderID = 5006;
|
||||
public int disassemblyAssemblyWorkOrderID = 5007;
|
||||
public int toolKitID = 5019;
|
||||
[Header("묏鱗튿객큐")]
|
||||
public string workOrderName;
|
||||
[Header("뀔陋묏데객큐")]
|
||||
public string disassemblyAssemblyWorkOrderName;
|
||||
[Header("교관객큐")]
|
||||
public string toolKitName;
|
||||
|
||||
/// <summary>
|
||||
/// 记录倒计时的协程
|
||||
|
@ -41,16 +44,16 @@ public class UI_MenuBar : BasePanel
|
|||
public override void ShowMe()
|
||||
{
|
||||
GameManager.EventMgr.AddEventListener<E_SceneType>(Enum_EventType.SwitchScene, CheckBtnBySceneName);
|
||||
GameManager.EventMgr.AddEventListener<int>(Enum_EventType.SwitchSubProcessStepTriggerID, SwitchSubProcessStepTriggerID);
|
||||
GameManager.EventMgr.AddEventListener<string>(Enum_EventType.SwitchSubProcessStepTriggerID, SwitchSubProcessStepTriggerID);
|
||||
}
|
||||
|
||||
private void SwitchSubProcessStepTriggerID(int triggerID)
|
||||
private void SwitchSubProcessStepTriggerID(string triggerID)
|
||||
{
|
||||
if (triggerID == workOrderID)
|
||||
if (triggerID == workOrderName)
|
||||
{
|
||||
Debug.Log("工作单提示");
|
||||
}
|
||||
if (triggerID == disassemblyAssemblyWorkOrderID)
|
||||
if (triggerID == disassemblyAssemblyWorkOrderName)
|
||||
{
|
||||
Debug.Log("拆装工单提示");
|
||||
}
|
||||
|
@ -59,7 +62,7 @@ public class UI_MenuBar : BasePanel
|
|||
public override void HideMe()
|
||||
{
|
||||
GameManager.EventMgr.RemoveEventListener<E_SceneType>(Enum_EventType.SwitchScene, CheckBtnBySceneName);
|
||||
GameManager.EventMgr.RemoveEventListener<int>(Enum_EventType.SwitchSubProcessStepTriggerID, SwitchSubProcessStepTriggerID);
|
||||
GameManager.EventMgr.RemoveEventListener<string>(Enum_EventType.SwitchSubProcessStepTriggerID, SwitchSubProcessStepTriggerID);
|
||||
}
|
||||
public void CheckBtnBySceneName(E_SceneType type)
|
||||
{
|
||||
|
@ -118,9 +121,9 @@ public class UI_MenuBar : BasePanel
|
|||
{
|
||||
GameManager.EventMgr.EventTrigger<float>(Enum_EventType.UpdateProgress, 0.9f);
|
||||
GameManager.EventMgr.EventTrigger(Enum_EventType.SwitchScene, GameManager.RunModelMgr.SceneType);
|
||||
if (GameManager.ProcessMgr.d_Scheme.CurrentProcess.CurrentSubProcess.CurrentSubProcessStep.triggersId.Count > 0)
|
||||
if (GameManager.ProcessMgr.d_Scheme.CurrentProcess.CurrentSubProcess.CurrentSubProcessStep.triggersName.Count > 0)
|
||||
{
|
||||
GameManager.EventMgr.EventTrigger<int>(Enum_EventType.SwitchSubProcessStepTriggerID, GameManager.ProcessMgr.d_Scheme.CurrentProcess.CurrentSubProcess.CurrentSubProcessStep.triggersId[0]);
|
||||
GameManager.EventMgr.EventTrigger<string>(Enum_EventType.SwitchSubProcessStepTriggerID, GameManager.ProcessMgr.d_Scheme.CurrentProcess.CurrentSubProcess.CurrentSubProcessStep.triggersName[0]);
|
||||
}
|
||||
});
|
||||
});
|
||||
|
@ -134,19 +137,19 @@ public class UI_MenuBar : BasePanel
|
|||
{
|
||||
GameManager.EventMgr.EventTrigger<float>(Enum_EventType.UpdateProgress, 0.9f);
|
||||
GameManager.EventMgr.EventTrigger(Enum_EventType.SwitchScene, GameManager.RunModelMgr.SceneType);
|
||||
if (GameManager.ProcessMgr.d_Scheme.CurrentProcess.CurrentSubProcess.CurrentSubProcessStep.triggersId.Count > 0)
|
||||
if (GameManager.ProcessMgr.d_Scheme.CurrentProcess.CurrentSubProcess.CurrentSubProcessStep.triggersName.Count > 0)
|
||||
{
|
||||
GameManager.EventMgr.EventTrigger<int>(Enum_EventType.SwitchSubProcessStepTriggerID, GameManager.ProcessMgr.d_Scheme.CurrentProcess.CurrentSubProcess.CurrentSubProcessStep.triggersId[0]);
|
||||
GameManager.EventMgr.EventTrigger<string>(Enum_EventType.SwitchSubProcessStepTriggerID, GameManager.ProcessMgr.d_Scheme.CurrentProcess.CurrentSubProcess.CurrentSubProcessStep.triggersName[0]);
|
||||
}
|
||||
});
|
||||
});
|
||||
break;
|
||||
case "WorkOrderBtn":
|
||||
if (GameManager.ProcessMgr.IsRightSubProcessStepsTriggerID(workOrderID, false) == 0)
|
||||
if (GameManager.ProcessMgr.IsRightSubProcessStepsTriggerID(workOrderName, false) == 0)
|
||||
{
|
||||
GameManager.UIMgr.ShowPanel<UI_SelectWorkTicketPanel>(E_UI_Layer.Mid, (panel) =>
|
||||
{
|
||||
panel.Init(workOrderID);
|
||||
panel.Init(workOrderName);
|
||||
});
|
||||
}
|
||||
break;
|
||||
|
@ -154,16 +157,16 @@ public class UI_MenuBar : BasePanel
|
|||
|
||||
break;
|
||||
case "DisassemblyAssemblyWorkOrderBtn":
|
||||
if (GameManager.ProcessMgr.IsRightSubProcessStepsTriggerID(disassemblyAssemblyWorkOrderID, false) == 0)
|
||||
if (GameManager.ProcessMgr.IsRightSubProcessStepsTriggerID(disassemblyAssemblyWorkOrderName, false) == 0)
|
||||
{
|
||||
GameManager.UIMgr.ShowPanel<UI_InstallAndDismantleTicketPanel>(E_UI_Layer.Mid, (panel) =>
|
||||
{
|
||||
panel.Init(disassemblyAssemblyWorkOrderID);
|
||||
panel.Init(disassemblyAssemblyWorkOrderName);
|
||||
});
|
||||
}
|
||||
break;
|
||||
case "ToolKitBtn":
|
||||
if (GameManager.ProcessMgr.IsRightSubProcessStepsTriggerID(toolKitID, true) == 0)
|
||||
if (GameManager.ProcessMgr.IsRightSubProcessStepsTriggerID(toolKitName, true) == 0)
|
||||
{
|
||||
GameManager.UIMgr.ShowPanel<UI_ToolAndMaterialPanel>(E_UI_Layer.Mid, (p) =>
|
||||
{
|
||||
|
|
|
@ -7,12 +7,12 @@ using UnityEngine.UI;
|
|||
|
||||
public class UI_PlayerSessionPanel : BasePanel
|
||||
{
|
||||
private int triggerID;
|
||||
public Action<int> callBack;
|
||||
private string triggerID;
|
||||
public Action<string> callBack;
|
||||
/// <summary>
|
||||
/// 初始化,state 0 激活另一个操作
|
||||
/// </summary>
|
||||
public void Init(int triggerID, string clientTalk, Action<int> _callBack)
|
||||
public void Init(string triggerID, string clientTalk, Action<string> _callBack)
|
||||
{
|
||||
this.triggerID = triggerID;
|
||||
callBack += _callBack;
|
||||
|
|
|
@ -5,17 +5,17 @@ using UnityEngine.UI;
|
|||
|
||||
public class UI_ReceiveTaskPanel : BasePanel
|
||||
{
|
||||
private int triggerID;
|
||||
public void Init(int triggerID)
|
||||
private string triggerName;
|
||||
public void Init(string triggerName)
|
||||
{
|
||||
this.triggerID = triggerID;
|
||||
this.triggerName = triggerName;
|
||||
}
|
||||
protected override void OnClick(string btnName)
|
||||
{
|
||||
switch (btnName)
|
||||
{
|
||||
case "Button_Accept":
|
||||
if (GameManager.ProcessMgr.IsRightSubProcessStepsTriggerID(triggerID, true) == 0)
|
||||
if (GameManager.ProcessMgr.IsRightSubProcessStepsTriggerID(triggerName, true) == 0)
|
||||
{
|
||||
//GameManager.ProcessMgr.CheckSubProcessSteps(GameManager.ProcessMgr.subProcessStepId);
|
||||
GameManager.UIMgr.HidePanel<UI_ReceiveTaskPanel>();
|
||||
|
|
|
@ -10,8 +10,8 @@ using UnityEngine.UI;
|
|||
public class UI_SelectWorkTicketPanel : BasePanel
|
||||
{
|
||||
private int number = 0;
|
||||
private int triggerID;
|
||||
public void Init(int triggerID)
|
||||
private string triggerID;
|
||||
public void Init(string triggerID)
|
||||
{
|
||||
number = 0;
|
||||
this.triggerID = triggerID;
|
||||
|
|
|
@ -4,7 +4,7 @@ using UnityEngine.UI;
|
|||
|
||||
public class UI_ToolAndMaterialPanel : BasePanel
|
||||
{
|
||||
private Dictionary<int, List<ItemInfo>> bagDatas;
|
||||
private Dictionary<string, List<ItemInfo>> bagDatas;
|
||||
public RectTransform _content;
|
||||
public UI_ToolOrMaterialsOrDeviceItem ui_TmdItem;
|
||||
|
||||
|
|
|
@ -8,10 +8,10 @@ public class Responser : MonoBehaviour
|
|||
|
||||
void Start()
|
||||
{
|
||||
GameManager.EventMgr.AddEventListener<int>(Enum_EventType.SwitchSubProcessStepTriggerID, SwitchSubProcessStepTriggerID);
|
||||
GameManager.EventMgr.AddEventListener<string>(Enum_EventType.SwitchSubProcessStepTriggerID, SwitchSubProcessStepTriggerID);
|
||||
}
|
||||
|
||||
private void SwitchSubProcessStepTriggerID(int arg0)
|
||||
private void SwitchSubProcessStepTriggerID(string arg0)
|
||||
{
|
||||
Debug.Log($"MenuClick ===== {arg0}");
|
||||
}
|
||||
|
|
Binary file not shown.
Binary file not shown.
Loading…
Reference in New Issue