Browse Source

修改bug

lzx 4 ngày trước cách đây
mục cha
commit
8377e24da9

+ 1 - 1
Assets/Res/UI/DialoguePanel/DialoguePanel.prefab

@@ -2769,7 +2769,7 @@ MonoBehaviour:
   m_PrefabInstance: {fileID: 0}
   m_PrefabAsset: {fileID: 0}
   m_GameObject: {fileID: 9062071681843881045}
-  m_Enabled: 0
+  m_Enabled: 1
   m_EditorHideFlags: 0
   m_Script: {fileID: 11500000, guid: 3c247620ca3a1fd4ab2a2f3a5b287e07, type: 3}
   m_Name: 

+ 6 - 6
Assets/Res/UI/DivineSence/ShengShiEventWidgetType2.prefab

@@ -1565,11 +1565,11 @@ RectTransform:
   m_Children: []
   m_Father: {fileID: 7566769296908980725}
   m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
-  m_AnchorMin: {x: 1, y: 1}
-  m_AnchorMax: {x: 1, y: 1}
-  m_AnchoredPosition: {x: -88.17052, y: -3.0117188}
+  m_AnchorMin: {x: 0, y: 1}
+  m_AnchorMax: {x: 0, y: 1}
+  m_AnchoredPosition: {x: -27.6, y: -5.6}
   m_SizeDelta: {x: 25, y: 26}
-  m_Pivot: {x: 1, y: 1}
+  m_Pivot: {x: 0, y: 1}
 --- !u!222 &5844111507754799144
 CanvasRenderer:
   m_ObjectHideFlags: 0
@@ -2130,8 +2130,8 @@ RectTransform:
   m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
   m_AnchorMin: {x: 0.5, y: 0.5}
   m_AnchorMax: {x: 0.5, y: 0.5}
-  m_AnchoredPosition: {x: 222.6, y: 104.2}
-  m_SizeDelta: {x: 83.741, y: 36.6236}
+  m_AnchoredPosition: {x: 224.25584, y: 106.1}
+  m_SizeDelta: {x: 151.6817, y: 36.6236}
   m_Pivot: {x: 0.5, y: 0.5}
 --- !u!222 &3905264220941356025
 CanvasRenderer:

+ 25 - 2
Assets/Scripts/GameUI/EventManager/EventSystemManager.cs

@@ -641,12 +641,35 @@ public class EventSystemManager : Singleton<EventSystemManager>
         {
             if (eventConfig.SmallPlacesId != PlayerManager.Instance.CurrentsmallPlaces.id)
             {
-                SmallPlacesConfig lastSmallPlacesConfig =
+                
+                
+                AccountFileInfo.SmallPlacesData lastSmallPlacesData = PlayerManager.Instance.GetSmallPlacesData(eventConfig.SmallPlacesId - 1);
+                SmallPlacesConfig lastSmallPlacesConfig = ConfigComponent.Instance.Get<SmallPlacesConfig>(eventConfig.SmallPlacesId - 1);
+                
+                SmallPlacesConfig currentSmallPlacesConfig = ConfigComponent.Instance.Get<SmallPlacesConfig>(eventConfig.SmallPlacesId);
+                if (currentSmallPlacesConfig.ID > 1 && (lastSmallPlacesData == null || lastSmallPlacesData.completionEventCount < lastSmallPlacesConfig.CompletionEventCount))
+                {
+                    TipMessagePanel.OpenTipMessagePanel($"该任务需要先解锁[{LanguageManager.Instance.Text(lastSmallPlacesConfig.placeName)}], 完成{ lastSmallPlacesConfig.CompletionEventCount}个任务后, 可解锁.");
+                    return;
+                }
+
+                if (lastSmallPlacesConfig.UnlockEnvetid != 0)
+                {
+                    AccountFileInfo.EventList eventList = AccountFileInfo.Instance.playerData.completeEvents.FirstOrDefault(ce => ce.eventID == lastSmallPlacesConfig.UnlockEnvetid);
+                    if (eventList == null || !eventList.isCompleted)
+                    {
+                        var econfig = ConfigComponent.Instance.Get<EventConfig>( lastSmallPlacesConfig.UnlockEnvetid);
+                        TipMessagePanel.OpenTipMessagePanel($"该任务需要先解锁[{LanguageManager.Instance.Text(lastSmallPlacesConfig.placeName)}], 完成{ econfig.EventName}任务后, 可解锁.");
+                        return;
+                    }
+                }
+                
+                SmallPlacesConfig SmallPlacesConfig =
                     ConfigComponent.Instance.Get<SmallPlacesConfig>(eventConfig.SmallPlacesId);
 
                 CTask<bool> cT = CTask<bool>.Create();
 
-                PlacesInfoPanel.OpenPanel(lastSmallPlacesConfig.PlacesId, (b) => { cT.SetResult(b); });
+                PlacesInfoPanel.OpenPanel(SmallPlacesConfig.PlacesId, (b) => { cT.SetResult(b); });
 
                 await cT;
                 if (eventConfig.SmallPlacesId != PlayerManager.Instance.CurrentsmallPlaces.id)

+ 3 - 2
Assets/Scripts/GameUI/UI/LevelChoosePanel/PlacesInfoPanel.cs

@@ -184,12 +184,13 @@ namespace Fort23.Mono
             //解锁下一个地图
             if (nextSmallPlacesData == null && IsSmallPlacesDataUlock(smallPlacesConfig.ID + 1))
             {
+                isChange = true;
                 UIManager.Instance.HideUIUIPanel<LevelChoosePanel>();
                 UIManager.Instance.HideUIUIPanel(this);
 
                 //切换下一个地图
                 PlayerManager.Instance.ChangeMap(smallPlacesConfig.ID + 1);
-                isChange = true;
+               
                 UIManager.Instance.HindCurrAllShowPanel();
                 CombatDrive.Instance.CombatController.ChangeState(CombatController.update);
                 CombatController.currActiveCombat.CombatHeroController.Flight(2, -90, 10);
@@ -274,7 +275,7 @@ namespace Fort23.Mono
 
             _shopBtnWidgets.Clear();
 
-            smallPlacesConfig = default;
+            // smallPlacesConfig = default;
 
             if (!isChange)
             {

+ 1 - 0
XiuXianGame.sln.DotSettings.user

@@ -30,6 +30,7 @@
 	<s:String x:Key="/Default/CodeInspection/ExcludedFiles/FilesAndFoldersToSkip2/=7020124F_002D9FFC_002D4AC3_002D8F3D_002DAAB8E0240759_002Ff_003AINotifyCompletion_002Ecs_002Fl_003AC_0021_003FUsers_003FAdministrator_003FAppData_003FRoaming_003FJetBrains_003FRider2024_002E3_003Fresharper_002Dhost_003FDecompilerCache_003Fdecompiler_003F9c2967a135e648bdb993c5397a44991b573620_003F64_003Fbb31faf9_003FINotifyCompletion_002Ecs/@EntryIndexedValue">ForceIncluded</s:String>
 	<s:String x:Key="/Default/CodeInspection/ExcludedFiles/FilesAndFoldersToSkip2/=7020124F_002D9FFC_002D4AC3_002D8F3D_002DAAB8E0240759_002Ff_003AInt32_002Ecs_002Fl_003AC_0021_003FUsers_003FAdministrator_003FAppData_003FRoaming_003FJetBrains_003FRider2024_002E3_003Fresharper_002Dhost_003FDecompilerCache_003Fdecompiler_003Fe4df6db7850b4c40b72002ff5da8188846ac00_003F6f_003F6f797d5f_003FInt32_002Ecs/@EntryIndexedValue">ForceIncluded</s:String>
 	<s:String x:Key="/Default/CodeInspection/ExcludedFiles/FilesAndFoldersToSkip2/=7020124F_002D9FFC_002D4AC3_002D8F3D_002DAAB8E0240759_002Ff_003AInt64_002Ecs_002Fl_003AC_0021_003FUsers_003FAdministrator_003FAppData_003FRoaming_003FJetBrains_003FRider2024_002E3_003Fresharper_002Dhost_003FDecompilerCache_003Fdecompiler_003Fe4df6db7850b4c40b72002ff5da8188846ac00_003Fc2_003Fd9090dcf_003FInt64_002Ecs/@EntryIndexedValue">ForceIncluded</s:String>
+	<s:String x:Key="/Default/CodeInspection/ExcludedFiles/FilesAndFoldersToSkip2/=7020124F_002D9FFC_002D4AC3_002D8F3D_002DAAB8E0240759_002Ff_003AInvokableCall_002Ecs_002Fl_003AC_0021_003FUsers_003FAdministrator_003FAppData_003FRoaming_003FJetBrains_003FRider2024_002E3_003Fresharper_002Dhost_003FDecompilerCache_003Fdecompiler_003F5c4a01f363eb46748231fc41bd9bdd8517e000_003F9e_003F8ce0e7b8_003FInvokableCall_002Ecs/@EntryIndexedValue">ForceIncluded</s:String>
 	<s:String x:Key="/Default/CodeInspection/ExcludedFiles/FilesAndFoldersToSkip2/=7020124F_002D9FFC_002D4AC3_002D8F3D_002DAAB8E0240759_002Ff_003AIStyle_002Ecs_002Fl_003AC_0021_003FUsers_003FAdministrator_003FAppData_003FRoaming_003FJetBrains_003FRider2024_002E3_003Fresharper_002Dhost_003FDecompilerCache_003Fdecompiler_003F56d039fe633a4adf8fb266a0b1797e6c17a000_003F0f_003F32e1f086_003FIStyle_002Ecs/@EntryIndexedValue">ForceIncluded</s:String>
 	<s:String x:Key="/Default/CodeInspection/ExcludedFiles/FilesAndFoldersToSkip2/=7020124F_002D9FFC_002D4AC3_002D8F3D_002DAAB8E0240759_002Ff_003AJsonMapper_002Ecs_002Fl_003AC_0021_003FUsers_003FAdministrator_003FAppData_003FRoaming_003FJetBrains_003FRider2024_002E3_003Fresharper_002Dhost_003FDecompilerCache_003Fdecompiler_003Fc7c8498c81c94b1b853dfc7fe4d8d7fbec00_003F05_003F3709212d_003FJsonMapper_002Ecs/@EntryIndexedValue">ForceIncluded</s:String>
 	<s:String x:Key="/Default/CodeInspection/ExcludedFiles/FilesAndFoldersToSkip2/=7020124F_002D9FFC_002D4AC3_002D8F3D_002DAAB8E0240759_002Ff_003ALayerMask_002Ecs_002Fl_003AC_0021_003FUsers_003FAdministrator_003FAppData_003FRoaming_003FJetBrains_003FRider2024_002E3_003Fresharper_002Dhost_003FDecompilerCache_003Fdecompiler_003F5c4a01f363eb46748231fc41bd9bdd8517e000_003F6c_003F2226b399_003FLayerMask_002Ecs/@EntryIndexedValue">ForceIncluded</s:String>