修改提示

This commit is contained in:
YangHua 2024-08-21 20:28:02 +08:00
parent f44a56289c
commit b4bacd0332
12 changed files with 231 additions and 15 deletions

View File

@ -2106,6 +2106,7 @@ GameObject:
- component: {fileID: 1711813855422086855}
- component: {fileID: 3469287837270444558}
- component: {fileID: 3469287837270444559}
- component: {fileID: 3469287837270444560}
m_Layer: 0
m_Name: "\u68B3\u5986\u955C"
m_TagString: Untagged
@ -2881,6 +2882,178 @@ MonoBehaviour:
triggerID: 5012
triggerName: "\u955C\u5B50"
_highlight: {fileID: 0}
--- !u!114 &3469287837270444560
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 919132149367037714}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: 888380afc233049ce9e618f9f36c8ba8, type: 3}
m_Name:
m_EditorClassIdentifier:
profile: {fileID: 0}
profileSync: 0
camerasLayerMask:
serializedVersion: 2
m_Bits: 4294967295
effectGroup: 0
effectGroupLayer:
serializedVersion: 2
m_Bits: 4294967295
effectNameFilter:
combineMeshes: 0
alphaCutOff: 0
cullBackFaces: 1
ignoreObjectVisibility: 0
reflectionProbes: 0
GPUInstancing: 1
optimizeSkinnedMesh: 1
depthClip: 0
cameraDistanceFade: 0
cameraDistanceFadeNear: 0
cameraDistanceFadeFar: 1000
normalsOption: 0
ignore: 0
_highlighted: 0
fadeInDuration: 0
fadeOutDuration: 0
flipY: 0
constantWidth: 1
subMeshMask: -1
overlay: 0
overlayMode: 0
overlayColor: {r: 1, g: 0.92156863, b: 0.015686275, a: 1}
overlayAnimationSpeed: 1
overlayMinIntensity: 0.5
overlayBlending: 1
overlayTexture: {fileID: 0}
overlayTextureUVSpace: 0
overlayTextureScale: 1
overlayVisibility: 0
outline: 1
outlineColor: {r: 0.8080046, g: 1.6417967, b: 0.36961916, a: 1}
outlineColorStyle: 0
outlineGradient:
serializedVersion: 2
key0: {r: 1, g: 1, b: 1, a: 1}
key1: {r: 1, g: 1, b: 1, a: 1}
key2: {r: 0, g: 0, b: 0, a: 0}
key3: {r: 0, g: 0, b: 0, a: 0}
key4: {r: 0, g: 0, b: 0, a: 0}
key5: {r: 0, g: 0, b: 0, a: 0}
key6: {r: 0, g: 0, b: 0, a: 0}
key7: {r: 0, g: 0, b: 0, a: 0}
ctime0: 0
ctime1: 65535
ctime2: 0
ctime3: 0
ctime4: 0
ctime5: 0
ctime6: 0
ctime7: 0
atime0: 0
atime1: 65535
atime2: 0
atime3: 0
atime4: 0
atime5: 0
atime6: 0
atime7: 0
m_Mode: 0
m_NumColorKeys: 2
m_NumAlphaKeys: 2
outlineGradientInLocalSpace: 0
outlineWidth: 0.45
outlineBlurPasses: 2
outlineQuality: 3
outlineEdgeMode: 0
outlineEdgeThreshold: 0.995
outlineDownsampling: 2
outlineVisibility: 0
glowBlendMode: 0
outlineBlitDebug: 0
outlineIndependent: 0
outlineContourStyle: 0
glow: 0.48
glowWidth: 0.4
glowQuality: 3
glowBlurMethod: 0
glowDownsampling: 2
glowHQColor: {r: 0.64, g: 1, b: 0, a: 1}
glowDithering: 1
glowMagicNumber1: 0.75
glowMagicNumber2: 0.5
glowAnimationSpeed: 1
glowVisibility: 0
glowBlitDebug: 0
glowBlendPasses: 1
glowPasses:
- offset: 4
alpha: 0.1
color: {r: 0.64, g: 1, b: 0, a: 1}
- offset: 3
alpha: 0.2
color: {r: 0.64, g: 1, b: 0, a: 1}
- offset: 2
alpha: 0.3
color: {r: 0.64, g: 1, b: 0, a: 1}
- offset: 1
alpha: 0.4
color: {r: 0.64, g: 1, b: 0, a: 1}
glowIgnoreMask: 0
innerGlow: 0
innerGlowWidth: 1
innerGlowColor: {r: 1, g: 1, b: 1, a: 1}
innerGlowBlendMode: 0
innerGlowVisibility: 0
targetFX: 0
targetFXTexture: {fileID: 0}
targetFXColor: {r: 1, g: 1, b: 1, a: 1}
targetFXCenter: {fileID: 0}
targetFXRotationSpeed: 50
targetFXInitialScale: 4
targetFXEndScale: 1.5
targetFXScaleToRenderBounds: 1
targetFXAlignToGround: 0
targetFXFadePower: 32
targetFXGroundMaxDistance: 10
targetFXGroundLayerMask:
serializedVersion: 2
m_Bits: 4294967295
targetFXTransitionDuration: 0.5
targetFXStayDuration: 1.5
targetFXVisibility: 1
seeThrough: 2
seeThroughOccluderMask:
serializedVersion: 2
m_Bits: 4294967295
seeThroughOccluderThreshold: 0.3
seeThroughOccluderMaskAccurate: 0
seeThroughOccluderCheckInterval: 1
seeThroughOccluderCheckIndividualObjects: 0
seeThroughDepthOffset: 0
seeThroughMaxDepth: 0
seeThroughIntensity: 0.8
seeThroughTintAlpha: 0.5
seeThroughTintColor: {r: 1, g: 0, b: 0, a: 1}
seeThroughNoise: 1
seeThroughBorder: 0
seeThroughBorderColor: {r: 0, g: 0, b: 0, a: 1}
seeThroughBorderOnly: 0
seeThroughBorderWidth: 0.45
seeThroughOrdered: 0
seeThroughTexture: {fileID: 0}
seeThroughTextureUVSpace: 0
seeThroughTextureScale: 1
rmsCount: 2
hitFxInitialIntensity: 0
hitFxMode: 0
hitFxFadeOutDuration: 0.25
hitFxColor: {r: 1, g: 1, b: 1, a: 1}
hitFxRadius: 0.5
--- !u!4 &3498687524961745019
Transform:
m_ObjectHideFlags: 0

View File

@ -74,6 +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]);
});
}
}

View File

@ -14,13 +14,19 @@ public class Tool_Base : PermanentTriggerBase
protected override void OnMEnter()
{
base.OnMEnter();
Debug.Log(gameObject.name);
_highlight.highlighted = true;
if (GameManager.RunModelMgr == null && GameManager.RunModelMgr.SceneType == E_SceneType.Site)
{
base.OnMEnter();
Debug.Log(gameObject.name);
_highlight.highlighted = true;
}
}
protected override void OnMExit()
{
base.OnMExit();
_highlight.highlighted = false;
if (GameManager.RunModelMgr == null && GameManager.RunModelMgr.SceneType == E_SceneType.Site)
{
base.OnMExit();
_highlight.highlighted = false;
}
}
}

View File

@ -8,7 +8,6 @@ using UnityEngine;
/// </summary>
public class OfficeManager : MonoBehaviour
{
public HighlightEffect[] _highlight;
public int currentProcessID;
public int currentSubProcessID;
public int currentSubProcessStepID;
@ -18,6 +17,7 @@ public class OfficeManager : MonoBehaviour
{
GameManager.EventMgr.AddEventListener(Enum_EventType.OfficeTimeLineOver, OfficeTimeLineOver);
GameManager.EventMgr.AddEventListener(Enum_EventType.InitializationUI, InitializationUI);
}
@ -47,6 +47,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]);
}

View File

@ -205,6 +205,7 @@ public class ProcessManager : BaseManager<ProcessManager>
CheckSubProcessSteps(GameManager.ProcessMgr.subProcessStepId);
Debug.Log($"<color=red>triggersId空了</color>");
}
GameManager.EventMgr.EventTrigger<int>(Enum_EventType.SwitchSubProcessStepTriggerID, d_Scheme.CurrentProcess.CurrentSubProcess.CurrentSubProcessStep.triggersId[0]);
return 0;
}
else

View File

@ -24,6 +24,7 @@ public class TooRoomlMannger : SingletonMono<TooRoomlMannger>
{
tmd.GetInfo();
}
}

View File

@ -25,7 +25,7 @@ public class MobileController : PermanentTriggerBase
switch (downIndex)
{
case 0:
_highlight.highlighted = false;
_highlight.SetHighlighted(false);
if (GameManager.ProcessMgr.IsRightSubProcessStepsTriggerID(triggerID, false) == 0)
{
GameManager.UIMgr.ShowPanel<UI_ReceiveTaskPanel>(E_UI_Layer.Mid, (panel) =>
@ -43,7 +43,7 @@ public class MobileController : PermanentTriggerBase
panel.Init(triggerID);
});
//GameManager.ProcessMgr.CheckSubProcessSteps(GameManager.ProcessMgr.subProcessStepId);
_highlight.highlighted = false;
_highlight.SetHighlighted(false);
downIndex ++;
}
break;

View File

@ -31,9 +31,14 @@ public class PermanentTriggerBase : MonoBehaviour
{
if (triggerID == arg0)
{
_highlight.highlighted = true;
_highlight.SetHighlighted(true);
//_highlight.highlighted = true;
Debug.Log("我应该提示");
}
else
{
_highlight.SetHighlighted(false);
}
}
/// <summary>
/// Awake

View File

@ -29,13 +29,25 @@ public abstract class BaseToolOrDevice : MonoBehaviour
private void Start()
{
_highlight = GetComponent<HighlightEffect>();
//GetInfo();
GameManager.EventMgr.AddEventListener<int>(Enum_EventType.SwitchSubProcessStepTriggerID, SwitchSubProcessStepTriggerID);
}
private void SwitchSubProcessStepTriggerID(int arg0)
{
if (itemInfo.triggerID == arg0)
{
_highlight.SetHighlighted(true);
//_highlight.highlighted = true;
Debug.Log("我应该提示");
}
else
{
_highlight.SetHighlighted(false);
}
}
public void GetInfo()
{
_highlight = GetComponent<HighlightEffect>();
D_ToolAndMaterialData dTMD = GameManager.ToolAndmaterialMgr.GetToolOrMaterialOrDeviceInfoByObjName(gameObject.name);
if (dTMD != null)
{
@ -90,4 +102,13 @@ public abstract class BaseToolOrDevice : MonoBehaviour
{
Debug.Log("离开");
}
private void OnDestroy()
{
GameManager.EventMgr.RemoveEventListener<int>(Enum_EventType.SwitchSubProcessStepTriggerID, SwitchSubProcessStepTriggerID);
}
private void OnDisable()
{
GameManager.EventMgr.RemoveEventListener<int>(Enum_EventType.SwitchSubProcessStepTriggerID, SwitchSubProcessStepTriggerID);
}
}

View File

@ -14,7 +14,10 @@ public class Tool_SelectComponent : BaseToolOrDevice
// panel.Init(gameObject.name, pos);
//});
///高亮
_highlight.highlighted = true;
if (GameManager.RunModelMgr.ModeType != E_ModeType.Study)
{
_highlight.highlighted = true;
}
}
public override void OnDown()
{
@ -32,6 +35,7 @@ public class Tool_SelectComponent : BaseToolOrDevice
///关闭高亮
GameManager.UIMgr.HidePanel<ItemTips>();//提示面板
base.OnExit();
_highlight.highlighted = false;
if (GameManager.RunModelMgr.ModeType != E_ModeType.Study)
_highlight.highlighted = false;
}
}

View File

@ -19,7 +19,7 @@ public class UI_SubProcessItem : BaseItem
gameObject.name = subProcessID.ToString();
SwitchSubProcess(subProcessID);
ShowMe();
}
public override void ShowMe()
@ -52,6 +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]);
break;
}
}

View File

@ -118,6 +118,7 @@ public class UI_MenuBar : BasePanel
{
GameManager.EventMgr.EventTrigger<float>(Enum_EventType.UpdateProgress, 0.9f);
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]);
});
});
break;
@ -130,6 +131,7 @@ public class UI_MenuBar : BasePanel
{
GameManager.EventMgr.EventTrigger<float>(Enum_EventType.UpdateProgress, 0.9f);
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]);
});
});
break;