diff --git a/Assets/PerfectWorld/Prefab/Task/UI/DlgTask.prefab b/Assets/PerfectWorld/Prefab/Task/UI/DlgTask.prefab index 3b67889af1..1cef0950df 100644 --- a/Assets/PerfectWorld/Prefab/Task/UI/DlgTask.prefab +++ b/Assets/PerfectWorld/Prefab/Task/UI/DlgTask.prefab @@ -31,9 +31,9 @@ RectTransform: - {fileID: 7068400949313321131} m_Father: {fileID: 1982628982857606432} m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} - m_AnchorMin: {x: 0, y: 0} - m_AnchorMax: {x: 0, y: 0} - m_AnchoredPosition: {x: 0, y: 0} + m_AnchorMin: {x: 0, y: 1} + m_AnchorMax: {x: 0, y: 1} + m_AnchoredPosition: {x: 119.34445, y: -50.05} m_SizeDelta: {x: 238.6889, y: 100} m_Pivot: {x: 0.5, y: 0.5} --- !u!1 &567730479829113918 @@ -1063,9 +1063,9 @@ RectTransform: - {fileID: 1673093633596208253} m_Father: {fileID: 6556814518920652147} m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} - m_AnchorMin: {x: 0, y: 0} - m_AnchorMax: {x: 0, y: 0} - m_AnchoredPosition: {x: 0, y: 0} + m_AnchorMin: {x: 0, y: 1} + m_AnchorMax: {x: 0, y: 1} + m_AnchoredPosition: {x: 744.2305, y: -49.72705} m_SizeDelta: {x: 72.1893, y: 73.4541} m_Pivot: {x: 0.5, y: 0.5} --- !u!222 &5696506275770781555 @@ -1782,9 +1782,9 @@ RectTransform: - {fileID: 3173262022725656255} m_Father: {fileID: 1802319080125745111} m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} - m_AnchorMin: {x: 0, y: 0} - m_AnchorMax: {x: 0, y: 0} - m_AnchoredPosition: {x: 0, y: 0} + m_AnchorMin: {x: 0, y: 1} + m_AnchorMax: {x: 0, y: 1} + m_AnchoredPosition: {x: 533.7858, y: -474.8956} m_SizeDelta: {x: 1067.5717, y: 53.7328} m_Pivot: {x: 0.5, y: 0.5} --- !u!222 &4979397800331147640 @@ -1832,9 +1832,9 @@ RectTransform: - {fileID: 5159105777246515782} m_Father: {fileID: 1802319080125745111} m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} - m_AnchorMin: {x: 0, y: 0} - m_AnchorMax: {x: 0, y: 0} - m_AnchoredPosition: {x: 0, y: 0} + m_AnchorMin: {x: 0, y: 1} + m_AnchorMax: {x: 0, y: 1} + m_AnchoredPosition: {x: 552.95, y: -697.9664} m_SizeDelta: {x: 1105.9, y: 100.1} m_Pivot: {x: 0.5, y: 0.5} --- !u!114 &3682686733385602497 @@ -2616,9 +2616,9 @@ RectTransform: - {fileID: 9038859519033147586} m_Father: {fileID: 3413131598704007284} m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} - m_AnchorMin: {x: 0, y: 0} - m_AnchorMax: {x: 0, y: 0} - m_AnchoredPosition: {x: 0, y: 0} + m_AnchorMin: {x: 0, y: 1} + m_AnchorMax: {x: 0, y: 1} + m_AnchoredPosition: {x: 160, y: -27.7372} m_SizeDelta: {x: 320, y: 55.4744} m_Pivot: {x: 0.5, y: 0.5} --- !u!114 &3633225552368495711 @@ -2786,9 +2786,9 @@ RectTransform: - {fileID: 6888331463719618182} m_Father: {fileID: 1802319080125745111} m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} - m_AnchorMin: {x: 0, y: 0} - m_AnchorMax: {x: 0, y: 0} - m_AnchoredPosition: {x: 0, y: 0} + m_AnchorMin: {x: 0, y: 1} + m_AnchorMax: {x: 0, y: 1} + m_AnchoredPosition: {x: 533.8, y: -181.5047} m_SizeDelta: {x: 1067.6, y: 147.0112} m_Pivot: {x: 0.5, y: 0.5} --- !u!222 &7637574953150164924 @@ -2992,9 +2992,9 @@ RectTransform: - {fileID: 466166190548844919} m_Father: {fileID: 1802319080125745111} m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} - m_AnchorMin: {x: 0, y: 0} - m_AnchorMax: {x: 0, y: 0} - m_AnchoredPosition: {x: 0, y: 0} + m_AnchorMin: {x: 0, y: 1} + m_AnchorMax: {x: 0, y: 1} + m_AnchoredPosition: {x: 533.7858, y: -287.3301} m_SizeDelta: {x: 1067.5717, y: 64.6396} m_Pivot: {x: 0.5, y: 0.5} --- !u!222 &5725159945352370057 @@ -3035,9 +3035,9 @@ RectTransform: m_Children: [] m_Father: {fileID: 1802319080125745111} m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} - m_AnchorMin: {x: 0, y: 0} - m_AnchorMax: {x: 0, y: 0} - m_AnchoredPosition: {x: 0, y: 0} + m_AnchorMin: {x: 0, y: 1} + m_AnchorMax: {x: 0, y: 1} + m_AnchoredPosition: {x: 50, y: -17.98135} m_SizeDelta: {x: 100, y: 35.9627} m_Pivot: {x: 0.5, y: 0.5} --- !u!1 &2640258873449426733 @@ -3495,9 +3495,9 @@ RectTransform: - {fileID: 1664656494516247222} m_Father: {fileID: 1802319080125745111} m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} - m_AnchorMin: {x: 0, y: 0} - m_AnchorMax: {x: 0, y: 0} - m_AnchoredPosition: {x: 0, y: 0} + m_AnchorMin: {x: 0, y: 1} + m_AnchorMax: {x: 0, y: 1} + m_AnchoredPosition: {x: 533.7858, y: -97.82885} m_SizeDelta: {x: 1067.5717, y: 20.3405} m_Pivot: {x: 0.5, y: 0.5} --- !u!222 &5366537333355115835 @@ -3540,9 +3540,9 @@ RectTransform: m_Children: [] m_Father: {fileID: 5935924508566653103} m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} - m_AnchorMin: {x: 0, y: 0} - m_AnchorMax: {x: 0, y: 0} - m_AnchoredPosition: {x: 0, y: 0} + m_AnchorMin: {x: 0, y: 1} + m_AnchorMax: {x: 0, y: 1} + m_AnchoredPosition: {x: 59.9817, y: -31.017} m_SizeDelta: {x: 119.9634, y: 62.034} m_Pivot: {x: 0.5, y: 0.5} --- !u!222 &8442116720262994404 @@ -3988,7 +3988,7 @@ RectTransform: m_Father: {fileID: 7958847946112668032} m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} m_AnchorMin: {x: 0, y: 0} - m_AnchorMax: {x: 0, y: 0} + m_AnchorMax: {x: 1, y: 1} m_AnchoredPosition: {x: 0, y: 0} m_SizeDelta: {x: 20, y: 20} m_Pivot: {x: 0.5, y: 0.5} @@ -4289,9 +4289,9 @@ RectTransform: - {fileID: 5935924508566653103} m_Father: {fileID: 1982628982857606432} m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} - m_AnchorMin: {x: 0, y: 0} - m_AnchorMax: {x: 0, y: 0} - m_AnchoredPosition: {x: 0, y: 0} + m_AnchorMin: {x: 0, y: 1} + m_AnchorMax: {x: 0, y: 1} + m_AnchoredPosition: {x: 981.0654, y: -50.05} m_SizeDelta: {x: 249.67, y: 100} m_Pivot: {x: 0.5, y: 0.5} --- !u!222 &3615902548841175383 @@ -4365,9 +4365,9 @@ RectTransform: - {fileID: 6664836867558571240} m_Father: {fileID: 6556814518920652147} m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} - m_AnchorMin: {x: 0, y: 0} - m_AnchorMax: {x: 0, y: 0} - m_AnchoredPosition: {x: 0, y: 0} + m_AnchorMin: {x: 0, y: 1} + m_AnchorMax: {x: 0, y: 1} + m_AnchoredPosition: {x: 632.0412, y: -49.72705} m_SizeDelta: {x: 72.1893, y: 73.4541} m_Pivot: {x: 0.5, y: 0.5} --- !u!222 &1719403314563710437 @@ -4441,9 +4441,9 @@ RectTransform: - {fileID: 3123454216176481580} m_Father: {fileID: 1982628982857606432} m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} - m_AnchorMin: {x: 0, y: 0} - m_AnchorMax: {x: 0, y: 0} - m_AnchoredPosition: {x: 0, y: 0} + m_AnchorMin: {x: 0, y: 1} + m_AnchorMax: {x: 0, y: 1} + m_AnchoredPosition: {x: 390.45966, y: -50.05} m_SizeDelta: {x: 103.5415, y: 42.7938} m_Pivot: {x: 0.5, y: 0.5} --- !u!114 &6244284104014817409 @@ -4529,9 +4529,9 @@ RectTransform: - {fileID: 4269318562826283412} m_Father: {fileID: 3413131598704007284} m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} - m_AnchorMin: {x: 0, y: 0} - m_AnchorMax: {x: 0, y: 0} - m_AnchoredPosition: {x: 0, y: 0} + m_AnchorMin: {x: 0, y: 1} + m_AnchorMax: {x: 0, y: 1} + m_AnchoredPosition: {x: 160, y: -392.4044} m_SizeDelta: {x: 320, y: 673.86} m_Pivot: {x: 0.5, y: 0.5} --- !u!222 &6982899544592245397 @@ -4714,9 +4714,9 @@ RectTransform: - {fileID: 2490029976799717816} m_Father: {fileID: 6556814518920652147} m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} - m_AnchorMin: {x: 0, y: 0} - m_AnchorMax: {x: 0, y: 0} - m_AnchoredPosition: {x: 0, y: 0} + m_AnchorMin: {x: 0, y: 1} + m_AnchorMax: {x: 0, y: 1} + m_AnchoredPosition: {x: 295.47327, y: -49.72705} m_SizeDelta: {x: 72.1893, y: 73.4541} m_Pivot: {x: 0.5, y: 0.5} --- !u!222 &7650172129678423862 @@ -4792,9 +4792,9 @@ RectTransform: m_Father: {fileID: 2214759022841903186} m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} m_AnchorMin: {x: 0, y: 0} - m_AnchorMax: {x: 0, y: 0} + m_AnchorMax: {x: 1, y: 1} m_AnchoredPosition: {x: 0, y: 0} - m_SizeDelta: {x: 0, y: 0} + m_SizeDelta: {x: -17, y: 0} m_Pivot: {x: 0, y: 1} --- !u!222 &4662246788448476486 CanvasRenderer: @@ -4883,7 +4883,7 @@ RectTransform: m_AnchorMin: {x: 0, y: 1} m_AnchorMax: {x: 0, y: 1} m_AnchoredPosition: {x: 0, y: 0.000024855137} - m_SizeDelta: {x: 1067.6, y: 0} + m_SizeDelta: {x: 1067.6, y: 44.66} m_Pivot: {x: 0, y: 1} --- !u!222 &8527806716735377849 CanvasRenderer: @@ -5163,9 +5163,9 @@ RectTransform: - {fileID: 7337732696262196210} m_Father: {fileID: 6556814518920652147} m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} - m_AnchorMin: {x: 0, y: 0} - m_AnchorMax: {x: 0, y: 0} - m_AnchoredPosition: {x: 0, y: 0} + m_AnchorMin: {x: 0, y: 1} + m_AnchorMax: {x: 0, y: 1} + m_AnchoredPosition: {x: 183.28395, y: -49.72705} m_SizeDelta: {x: 72.1893, y: 73.4541} m_Pivot: {x: 0.5, y: 0.5} --- !u!222 &665161835172153120 @@ -5238,9 +5238,9 @@ RectTransform: m_Children: [] m_Father: {fileID: 1982628982857606432} m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} - m_AnchorMin: {x: 0, y: 0} - m_AnchorMax: {x: 0, y: 0} - m_AnchoredPosition: {x: 0, y: 0} + m_AnchorMin: {x: 0, y: 1} + m_AnchorMax: {x: 0, y: 1} + m_AnchoredPosition: {x: 288.6889, y: -50.05} m_SizeDelta: {x: 100, y: 100} m_Pivot: {x: 0.5, y: 0.5} --- !u!222 &1142619112158729952 @@ -5375,9 +5375,9 @@ RectTransform: - {fileID: 464210832437986234} m_Father: {fileID: 6556814518920652147} m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} - m_AnchorMin: {x: 0, y: 0} - m_AnchorMax: {x: 0, y: 0} - m_AnchoredPosition: {x: 0, y: 0} + m_AnchorMin: {x: 0, y: 1} + m_AnchorMax: {x: 0, y: 1} + m_AnchoredPosition: {x: 71.09465, y: -49.72705} m_SizeDelta: {x: 72.1893, y: 73.4541} m_Pivot: {x: 0.5, y: 0.5} --- !u!222 &6131836957139812833 @@ -5486,9 +5486,9 @@ RectTransform: m_Children: [] m_Father: {fileID: 1802319080125745111} m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} - m_AnchorMin: {x: 0, y: 0} - m_AnchorMax: {x: 0, y: 0} - m_AnchoredPosition: {x: 0, y: 0} + m_AnchorMin: {x: 0, y: 1} + m_AnchorMax: {x: 0, y: 1} + m_AnchoredPosition: {x: 150, y: -61.81065} m_SizeDelta: {x: 300, y: 51.6959} m_Pivot: {x: 0.5, y: 0.5} --- !u!222 &4239296098804493253 @@ -5623,9 +5623,9 @@ RectTransform: - {fileID: 9160025208612689927} m_Father: {fileID: 6556814518920652147} m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} - m_AnchorMin: {x: 0, y: 0} - m_AnchorMax: {x: 0, y: 0} - m_AnchoredPosition: {x: 0, y: 0} + m_AnchorMin: {x: 0, y: 1} + m_AnchorMax: {x: 0, y: 1} + m_AnchoredPosition: {x: 856.41986, y: -49.72705} m_SizeDelta: {x: 72.1893, y: 73.4541} m_Pivot: {x: 0.5, y: 0.5} --- !u!222 &4153770864616565637 @@ -5700,9 +5700,9 @@ RectTransform: - {fileID: 3906960815437350628} m_Father: {fileID: 8174585228173147249} m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} - m_AnchorMin: {x: 0, y: 0} - m_AnchorMax: {x: 0, y: 0} - m_AnchoredPosition: {x: 0, y: 0} + m_AnchorMin: {x: 0, y: 1} + m_AnchorMax: {x: 0, y: 1} + m_AnchoredPosition: {x: 241.1868, y: -31.18805} m_SizeDelta: {x: 170.7912, y: 62.3761} m_Pivot: {x: 0.5, y: 0.5} --- !u!222 &7438076119085514817 @@ -5819,9 +5819,9 @@ RectTransform: m_Children: [] m_Father: {fileID: 7068400949313321131} m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} - m_AnchorMin: {x: 0, y: 0} - m_AnchorMax: {x: 0, y: 0} - m_AnchoredPosition: {x: 0, y: 0} + m_AnchorMin: {x: 0, y: 1} + m_AnchorMax: {x: 0, y: 1} + m_AnchoredPosition: {x: 76, y: -31.75005} m_SizeDelta: {x: 100, y: 100} m_Pivot: {x: 0.5, y: 0.5} --- !u!222 &2800332942966355020 @@ -6441,9 +6441,9 @@ RectTransform: m_Father: {fileID: 3760164886363293420} m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} m_AnchorMin: {x: 0, y: 0} - m_AnchorMax: {x: 0, y: 0} + m_AnchorMax: {x: 1, y: 1} m_AnchoredPosition: {x: 0, y: 0} - m_SizeDelta: {x: 0, y: 0} + m_SizeDelta: {x: -17, y: 0} m_Pivot: {x: 0, y: 1} --- !u!222 &5693552902337398956 CanvasRenderer: @@ -6617,7 +6617,7 @@ MonoBehaviour: m_HandleRect: {fileID: 2343337405992641122} m_Direction: 2 m_Value: 1 - m_Size: 1 + m_Size: 0.9999888 m_NumberOfSteps: 0 m_OnValueChanged: m_PersistentCalls: @@ -6657,9 +6657,9 @@ RectTransform: m_Father: {fileID: 8611061134879146475} m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} m_AnchorMin: {x: 0, y: 0} - m_AnchorMax: {x: 0, y: 0} + m_AnchorMax: {x: 1, y: 1} m_AnchoredPosition: {x: 0, y: 0} - m_SizeDelta: {x: 0, y: 0} + m_SizeDelta: {x: -17, y: 0} m_Pivot: {x: 0, y: 1} --- !u!222 &1301146549737279854 CanvasRenderer: @@ -6872,9 +6872,9 @@ RectTransform: - {fileID: 3960419512253178154} m_Father: {fileID: 1982628982857606432} m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} - m_AnchorMin: {x: 0, y: 0} - m_AnchorMax: {x: 0, y: 0} - m_AnchoredPosition: {x: 0, y: 0} + m_AnchorMin: {x: 0, y: 1} + m_AnchorMax: {x: 0, y: 1} + m_AnchoredPosition: {x: 752.7304, y: -50.05} m_SizeDelta: {x: 207, y: 77} m_Pivot: {x: 0.5, y: 0.5} --- !u!222 &5922293013674383484 @@ -6991,8 +6991,8 @@ RectTransform: m_Children: [] m_Father: {fileID: 5233116975597807035} m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} - m_AnchorMin: {x: 0, y: 0} - m_AnchorMax: {x: 0, y: 0} + m_AnchorMin: {x: 0, y: 0.000011205673} + m_AnchorMax: {x: 1, y: 1} m_AnchoredPosition: {x: 0, y: 0} m_SizeDelta: {x: 20, y: 20} m_Pivot: {x: 0.5, y: 0.5} @@ -7067,7 +7067,7 @@ RectTransform: m_Father: {fileID: 2825219564319673376} m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} m_AnchorMin: {x: 0, y: 0} - m_AnchorMax: {x: 0, y: 0} + m_AnchorMax: {x: 1, y: 1} m_AnchoredPosition: {x: 0, y: 0} m_SizeDelta: {x: 20, y: 20} m_Pivot: {x: 0.5, y: 0.5} @@ -7382,7 +7382,7 @@ GameObject: m_Icon: {fileID: 0} m_NavMeshLayer: 0 m_StaticEditorFlags: 0 - m_IsActive: 1 + m_IsActive: 0 --- !u!224 &5506476487848131018 RectTransform: m_ObjectHideFlags: 0 @@ -7477,9 +7477,9 @@ RectTransform: - {fileID: 8526229293534627480} m_Father: {fileID: 1802319080125745111} m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} - m_AnchorMin: {x: 0, y: 0} - m_AnchorMax: {x: 0, y: 0} - m_AnchoredPosition: {x: 0, y: 0} + m_AnchorMin: {x: 0, y: 1} + m_AnchorMax: {x: 0, y: 1} + m_AnchoredPosition: {x: 552.95, y: -574.8392} m_SizeDelta: {x: 1105.9, y: 146.1544} m_Pivot: {x: 0.5, y: 0.5} --- !u!1 &7362516739390317868 @@ -7516,9 +7516,9 @@ RectTransform: - {fileID: 8359974748112151041} m_Father: {fileID: 1982628982857606432} m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} - m_AnchorMin: {x: 0, y: 0} - m_AnchorMax: {x: 0, y: 0} - m_AnchoredPosition: {x: 0, y: 0} + m_AnchorMin: {x: 0, y: 1} + m_AnchorMax: {x: 0, y: 1} + m_AnchoredPosition: {x: 545.7304, y: -50.05} m_SizeDelta: {x: 207, y: 77} m_Pivot: {x: 0.5, y: 0.5} --- !u!222 &175839448811631403 @@ -7837,9 +7837,9 @@ RectTransform: - {fileID: 3546830409645517734} m_Father: {fileID: 6556814518920652147} m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} - m_AnchorMin: {x: 0, y: 0} - m_AnchorMax: {x: 0, y: 0} - m_AnchoredPosition: {x: 0, y: 0} + m_AnchorMin: {x: 0, y: 1} + m_AnchorMax: {x: 0, y: 1} + m_AnchoredPosition: {x: 519.85187, y: -49.72705} m_SizeDelta: {x: 72.1893, y: 73.4541} m_Pivot: {x: 0.5, y: 0.5} --- !u!222 &7535806629134762549 @@ -7915,9 +7915,9 @@ RectTransform: - {fileID: 3450901294667678815} m_Father: {fileID: 1802319080125745111} m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} - m_AnchorMin: {x: 0, y: 0} - m_AnchorMax: {x: 0, y: 0} - m_AnchoredPosition: {x: 0, y: 0} + m_AnchorMin: {x: 0, y: 1} + m_AnchorMax: {x: 0, y: 1} + m_AnchoredPosition: {x: 533.8, y: -383.83954} m_SizeDelta: {x: 1067.6, y: 128.3793} m_Pivot: {x: 0.5, y: 0.5} --- !u!222 &5632580526749397436 @@ -8021,9 +8021,9 @@ RectTransform: - {fileID: 6076870470824675401} m_Father: {fileID: 6556814518920652147} m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} - m_AnchorMin: {x: 0, y: 0} - m_AnchorMax: {x: 0, y: 0} - m_AnchoredPosition: {x: 0, y: 0} + m_AnchorMin: {x: 0, y: 1} + m_AnchorMax: {x: 0, y: 1} + m_AnchoredPosition: {x: 407.66254, y: -49.72705} m_SizeDelta: {x: 72.1893, y: 73.4541} m_Pivot: {x: 0.5, y: 0.5} --- !u!222 &5385847170717247365 @@ -8173,9 +8173,9 @@ RectTransform: - {fileID: 1805980451046698619} m_Father: {fileID: 8174585228173147249} m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} - m_AnchorMin: {x: 0, y: 0} - m_AnchorMax: {x: 0, y: 0} - m_AnchoredPosition: {x: 0, y: 0} + m_AnchorMin: {x: 0, y: 1} + m_AnchorMax: {x: 0, y: 1} + m_AnchoredPosition: {x: 80.3956, y: -31.18805} m_SizeDelta: {x: 170.7912, y: 62.3761} m_Pivot: {x: 0.5, y: 0.5} --- !u!222 &8101014133290532655 @@ -8367,9 +8367,9 @@ RectTransform: m_Children: [] m_Father: {fileID: 5935924508566653103} m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} - m_AnchorMin: {x: 0, y: 0} - m_AnchorMax: {x: 0, y: 0} - m_AnchoredPosition: {x: 0, y: 0} + m_AnchorMin: {x: 0, y: 1} + m_AnchorMax: {x: 0, y: 1} + m_AnchoredPosition: {x: 155.6889, y: -31.017} m_SizeDelta: {x: 71.451, y: 62.034} m_Pivot: {x: 0.5, y: 0.5} --- !u!222 &1158119712588225859 @@ -8864,7 +8864,7 @@ PrefabInstance: objectReference: {fileID: 0} - target: {fileID: 8395333742829132721, guid: 9456de25596014039bd4d0d3927b709a, type: 3} propertyPath: m_AnchoredPosition.y - value: 336.93002 + value: 336.92987 objectReference: {fileID: 0} - target: {fileID: 8395333742829132721, guid: 9456de25596014039bd4d0d3927b709a, type: 3} propertyPath: m_LocalEulerAnglesHint.x diff --git a/Assets/PerfectWorld/Prefab/UI/JumpBtn.prefab b/Assets/PerfectWorld/Prefab/UI/JumpBtn.prefab new file mode 100644 index 0000000000..1db10eff5a --- /dev/null +++ b/Assets/PerfectWorld/Prefab/UI/JumpBtn.prefab @@ -0,0 +1,272 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!1 &6426564401230013186 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 3325367652782365102} + - component: {fileID: 6868997766477093256} + - component: {fileID: 2867419621240194058} + m_Layer: 5 + m_Name: Text (TMP) + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!224 &3325367652782365102 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 6426564401230013186} + m_LocalRotation: {x: -0, y: -0, z: -0, w: 1} + m_LocalPosition: {x: 0, y: 0, z: 0} + m_LocalScale: {x: 1, y: 1, z: 1} + m_ConstrainProportionsScale: 0 + m_Children: [] + m_Father: {fileID: 266017875005995358} + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0, y: 0} + m_AnchorMax: {x: 1, y: 1} + m_AnchoredPosition: {x: 0.9228058, y: 0.69200134} + m_SizeDelta: {x: -78.8826, y: -78.8826} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!222 &6868997766477093256 +CanvasRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 6426564401230013186} + m_CullTransparentMesh: 1 +--- !u!114 &2867419621240194058 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 6426564401230013186} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: f4688fdb7df04437aeb418b961361dc5, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 1, g: 1, b: 1, a: 1} + m_RaycastTarget: 1 + m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0} + m_Maskable: 1 + m_OnCullStateChanged: + m_PersistentCalls: + m_Calls: [] + m_text: JUMP + m_isRightToLeft: 0 + m_fontAsset: {fileID: 11400000, guid: 8f586378b4e144a9851e7b34d9b748ee, type: 2} + m_sharedMaterial: {fileID: 2180264, guid: 8f586378b4e144a9851e7b34d9b748ee, type: 2} + m_fontSharedMaterials: [] + m_fontMaterial: {fileID: 0} + m_fontMaterials: [] + m_fontColor32: + serializedVersion: 2 + rgba: 4281479730 + m_fontColor: {r: 0.19607843, g: 0.19607843, b: 0.19607843, a: 1} + m_enableVertexGradient: 0 + m_colorMode: 3 + m_fontColorGradient: + topLeft: {r: 1, g: 1, b: 1, a: 1} + topRight: {r: 1, g: 1, b: 1, a: 1} + bottomLeft: {r: 1, g: 1, b: 1, a: 1} + bottomRight: {r: 1, g: 1, b: 1, a: 1} + m_fontColorGradientPreset: {fileID: 0} + m_spriteAsset: {fileID: 0} + m_tintAllSprites: 0 + m_StyleSheet: {fileID: 0} + m_TextStyleHashCode: -1183493901 + m_overrideHtmlColors: 0 + m_faceColor: + serializedVersion: 2 + rgba: 4294967295 + m_fontSize: 44.7 + m_fontSizeBase: 24 + m_fontWeight: 400 + m_enableAutoSizing: 1 + m_fontSizeMin: 18 + m_fontSizeMax: 72 + m_fontStyle: 0 + m_HorizontalAlignment: 2 + m_VerticalAlignment: 512 + m_textAlignment: 65535 + m_characterSpacing: 0 + m_wordSpacing: 0 + m_lineSpacing: 0 + m_lineSpacingMax: 0 + m_paragraphSpacing: 0 + m_charWidthMaxAdj: 0 + m_TextWrappingMode: 1 + m_wordWrappingRatios: 0.4 + m_overflowMode: 0 + m_linkedTextComponent: {fileID: 0} + parentLinkedComponent: {fileID: 0} + m_enableKerning: 0 + m_ActiveFontFeatures: 6e72656b + m_enableExtraPadding: 0 + checkPaddingRequired: 0 + m_isRichText: 1 + m_EmojiFallbackSupport: 1 + m_parseCtrlCharacters: 1 + m_isOrthographic: 1 + m_isCullingEnabled: 0 + m_horizontalMapping: 0 + m_verticalMapping: 0 + m_uvLineOffset: 0 + m_geometrySortingOrder: 0 + m_IsTextObjectScaleStatic: 0 + m_VertexBufferAutoSizeReduction: 0 + m_useMaxVisibleDescender: 1 + m_pageToDisplay: 1 + m_margin: {x: 0, y: 0, z: 0, w: 0} + m_isUsingLegacyAnimationComponent: 0 + m_isVolumetricText: 0 + m_hasFontAssetChanged: 0 + m_baseMaterial: {fileID: 0} + m_maskOffset: {x: 0, y: 0, z: 0, w: 0} +--- !u!1 &6792439420010771896 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 266017875005995358} + - component: {fileID: 5557092053757495849} + - component: {fileID: 3695308113943472152} + - component: {fileID: 1194531703109065144} + - component: {fileID: 4432331937269434665} + m_Layer: 5 + m_Name: JumpBtn + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!224 &266017875005995358 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 6792439420010771896} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: 0, y: 0, z: 0} + m_LocalScale: {x: 1, y: 1, z: 1} + m_ConstrainProportionsScale: 0 + m_Children: + - {fileID: 3325367652782365102} + m_Father: {fileID: 0} + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 1, y: 0} + m_AnchorMax: {x: 1, y: 0} + m_AnchoredPosition: {x: -61, y: 46} + m_SizeDelta: {x: 200, y: 200} + m_Pivot: {x: 1, y: 0} +--- !u!222 &5557092053757495849 +CanvasRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 6792439420010771896} + m_CullTransparentMesh: 1 +--- !u!114 &3695308113943472152 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 6792439420010771896} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: fe87c0e1cc204ed48ad3b37840f39efc, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 1, g: 1, b: 1, a: 1} + m_RaycastTarget: 1 + m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0} + m_Maskable: 1 + m_OnCullStateChanged: + m_PersistentCalls: + m_Calls: [] + m_Sprite: {fileID: 10913, guid: 0000000000000000f000000000000000, type: 0} + m_Type: 0 + m_PreserveAspect: 1 + m_FillCenter: 1 + m_FillMethod: 4 + m_FillAmount: 1 + m_FillClockwise: 1 + m_FillOrigin: 0 + m_UseSpriteMesh: 0 + m_PixelsPerUnitMultiplier: 1 +--- !u!114 &1194531703109065144 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 6792439420010771896} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 4e29b1a8efbd4b44bb3f3716e73f07ff, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Navigation: + m_Mode: 3 + m_WrapAround: 0 + m_SelectOnUp: {fileID: 0} + m_SelectOnDown: {fileID: 0} + m_SelectOnLeft: {fileID: 0} + m_SelectOnRight: {fileID: 0} + m_Transition: 1 + m_Colors: + m_NormalColor: {r: 1, g: 1, b: 1, a: 1} + m_HighlightedColor: {r: 0.9607843, g: 0.9607843, b: 0.9607843, a: 1} + m_PressedColor: {r: 0.78431374, g: 0.78431374, b: 0.78431374, a: 1} + m_SelectedColor: {r: 0.9607843, g: 0.9607843, b: 0.9607843, a: 1} + m_DisabledColor: {r: 0.78431374, g: 0.78431374, b: 0.78431374, a: 0.5019608} + m_ColorMultiplier: 1 + m_FadeDuration: 0.1 + m_SpriteState: + m_HighlightedSprite: {fileID: 0} + m_PressedSprite: {fileID: 0} + m_SelectedSprite: {fileID: 0} + m_DisabledSprite: {fileID: 0} + m_AnimationTriggers: + m_NormalTrigger: Normal + m_HighlightedTrigger: Highlighted + m_PressedTrigger: Pressed + m_SelectedTrigger: Selected + m_DisabledTrigger: Disabled + m_Interactable: 1 + m_TargetGraphic: {fileID: 3695308113943472152} + m_OnClick: + m_PersistentCalls: + m_Calls: [] +--- !u!114 &4432331937269434665 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 6792439420010771896} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: a6149141837cadc4baae427c4864833e, type: 3} + m_Name: + m_EditorClassIdentifier: diff --git a/Assets/PerfectWorld/Prefab/UI/JumpBtn.prefab.meta b/Assets/PerfectWorld/Prefab/UI/JumpBtn.prefab.meta new file mode 100644 index 0000000000..6f0963e6b7 --- /dev/null +++ b/Assets/PerfectWorld/Prefab/UI/JumpBtn.prefab.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: 0104938c092195b40ab7f3b6e5bf342e +PrefabImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/PerfectWorld/Resources/UI/DialogScriptTableObject.asset b/Assets/PerfectWorld/Resources/UI/DialogScriptTableObject.asset index 6e9766d861..31f1cdb26a 100644 --- a/Assets/PerfectWorld/Resources/UI/DialogScriptTableObject.asset +++ b/Assets/PerfectWorld/Resources/UI/DialogScriptTableObject.asset @@ -19,7 +19,7 @@ MonoBehaviour: prefab: {fileID: 8237288432181259026, guid: eaeb778b6aab3d74299373b3a96b72c4, type: 3} - id: Win_Award prefab: {fileID: 903595479696773158, guid: cf26d96ae7d984ba8a5b6cef44adffeb, type: 3} - - id: Win_Task + - id: Win_Quest prefab: {fileID: 6999114045547682248, guid: 8027cada0ef5e4a9f827001b4747174d, type: 3} - id: Win_SkillSubAction prefab: {fileID: 111271885693053298, guid: eb88919320b4229459c83b6b1f8f1e7b, type: 3} diff --git a/Assets/PerfectWorld/Scripts/Managers/EC_HostInputFilter.cs b/Assets/PerfectWorld/Scripts/Managers/EC_HostInputFilter.cs index 7ebe15b0b9..2ce3d28d84 100644 --- a/Assets/PerfectWorld/Scripts/Managers/EC_HostInputFilter.cs +++ b/Assets/PerfectWorld/Scripts/Managers/EC_HostInputFilter.cs @@ -19,27 +19,7 @@ namespace BrewMonster } if (Input.GetKeyDown(KeyCode.Space)) { - //if (bInAutoMode) return; - if (IsJumpInWater() || IsFlying()) - return; - - if (IsUnderWater()) - { - if (!CanTakeOffWater()) - return; - else if (_JumpTime <= 0) - { - _JumpTime = Time.realtimeSinceStartup; - return; - } - else if ((Time.realtimeSinceStartup - _JumpTime) < 1f) // logic in c++, _JumpTime is milisecond - return; - else - _JumpTime = -1f; - } - - m_GndInfo.bOnGround = GroundCheck(out lastGroundHit); - OnMsgHstJump(); + OnClickBtnJump(); } } @@ -208,5 +188,29 @@ namespace BrewMonster PlayAction((int)PLAYER_ACTION_TYPE.ACT_JUMP_LOOP, false, 0, true); } + public void OnClickBtnJump() + { + //if (bInAutoMode) return; + if (IsJumpInWater() || IsFlying()) + return; + + if (IsUnderWater()) + { + if (!CanTakeOffWater()) + return; + else if (_JumpTime <= 0) + { + _JumpTime = Time.realtimeSinceStartup; + return; + } + else if ((Time.realtimeSinceStartup - _JumpTime) < 1f) // logic in c++, _JumpTime is milisecond + return; + else + _JumpTime = -1f; + } + + m_GndInfo.bOnGround = GroundCheck(out lastGroundHit); + OnMsgHstJump(); + } } } diff --git a/Assets/PerfectWorld/Scripts/Move/EC_CDR.cs b/Assets/PerfectWorld/Scripts/Move/EC_CDR.cs index c32d5ba7c1..a6a60bede3 100644 --- a/Assets/PerfectWorld/Scripts/Move/EC_CDR.cs +++ b/Assets/PerfectWorld/Scripts/Move/EC_CDR.cs @@ -101,34 +101,44 @@ namespace BrewMonster pEnvTrc.fFraction = 100.0f; pEnvTrc.bStartSolid = false; pEnvTrc.dwClsFlag = 0; + Vector3 vStart = EC_Utility.ToVector3(pEnvTrc.vStart); + Vector3 vExt = EC_Utility.ToVector3(pEnvTrc.vExt); + Vector3 vDelta = EC_Utility.ToVector3(pEnvTrc.vDelta); + Vector3 vTerStart = EC_Utility.ToVector3(pEnvTrc.vTerStart); + Vector3 dir = Vector3.zero; + if ((pEnvTrc.dwCheckFlag & CDR_EVN.CDR_BRUSH) == CDR_EVN.CDR_BRUSH) { - BrushTraceInfo bruInfo = new BrushTraceInfo(); - bruInfo.Init(pEnvTrc.vStart, pEnvTrc.vDelta, pEnvTrc.vExt); - if (AABBCollideWithBrush(ref bruInfo)) + dir = vStart + vDelta; + if (Physics.BoxCast(vStart, vExt, dir, out RaycastHit hit, Quaternion.identity, vDelta.magnitude, 1 << 7)) { - pEnvTrc.fFraction = bruInfo.fFraction; - pEnvTrc.vHitNormal = bruInfo.ClipPlane.GetNormal(); - pEnvTrc.bStartSolid = bruInfo.bStartSolid; + pEnvTrc.fFraction = (hit.distance - vExt.x) / vDelta.magnitude; + pEnvTrc.vHitNormal = EC_Utility.ToA3DVECTOR3(hit.normal); pEnvTrc.dwClsFlag = CDR_EVN.CDR_BRUSH; } + else + { + pEnvTrc.fFraction = 1f; + } } if ((pEnvTrc.dwCheckFlag & CDR_EVN.CDR_TERRAIN) == CDR_EVN.CDR_TERRAIN) { - float fFraction = 0f; - A3DVECTOR3 vTerNormal = new A3DVECTOR3(); - bool bStart = false; - if (CollideWithTerrain(pEnvTrc.vTerStart, pEnvTrc.vDelta, ref fFraction, ref vTerNormal, ref bStart) - && (fFraction < pEnvTrc.fFraction)) + float fFractionTerrain = 0f; + dir = vDelta; + if (Physics.Raycast(vTerStart, dir.normalized, out RaycastHit hit, vDelta.magnitude, 1<<6)) { - //assert(fFraction >= 0.0f); - //pEnvTrc.fFraction = a_Max(0.0f, fFraction - 1E-4f); - pEnvTrc.fFraction = fFraction; - pEnvTrc.vHitNormal = vTerNormal; - pEnvTrc.bStartSolid = bStart; + fFractionTerrain = (hit.distance) / vDelta.magnitude; + pEnvTrc.vHitNormal = EC_Utility.ToA3DVECTOR3(hit.normal); pEnvTrc.dwClsFlag = CDR_EVN.CDR_TERRAIN; } - + else + { + fFractionTerrain = 1f; + } + if(fFractionTerrain < pEnvTrc.fFraction) + { + pEnvTrc.fFraction = fFractionTerrain; + } } if ((pEnvTrc.dwCheckFlag & CDR_EVN.CDR_WATER) == CDR_EVN.CDR_WATER) @@ -156,46 +166,6 @@ namespace BrewMonster return (pEnvTrc.fFraction < 1.0f + 1E-4f); } - // == Thay CollideWithEnv (C++) bằng BoxCast == - //static bool CollideWithEnv_BoxCast(Vector3 vStart, Vector3 vDelta, Vector3 vExt, - // LayerMask mask, - // out RaycastHit hit, out float fFraction, out Vector3 vHitNormal, out bool bStartSolid, - // float skin = 0.01f) - //{ - // hit = default; - // vHitNormal = Vector3.up; - // bStartSolid = false; - // fFraction = 0.0f; - - // float dist = vDelta.magnitude; - // if (dist <= 1e-6f) return false; - - // var hasHit = Physics.Raycast(vStart, vDelta,out hit, dist, mask); - // if (hasHit) - // { - // bStartSolid = true; - // fFraction = (t - 5E-4f) / vDelta.Normalize(); - // return true; - // } - // // start-in-solid - // var overlapped = Physics.OverlapBox(vStart, vExt - Vector3.one * skin, Quaternion.identity, mask, QueryTriggerInteraction.Ignore); - // if (overlapped != null && overlapped.Length > 0) - // { - // bStartSolid = true; - // return true; - // } - - // // sweep AABB - // Vector3 dir = vDelta / Mathf.Max(dist, 1e-6f); - // if (Physics.BoxCast(vStart, vExt - Vector3.one * skin, dir, out hit, Quaternion.identity, dist, mask, QueryTriggerInteraction.Ignore)) - // { - // fFraction = Mathf.Clamp01(hit.distance / Mathf.Max(dist, 1e-6f)); - // vHitNormal = hit.normal; - // return true; - // } - // return false; - //} - // == Thay RetrieveSupportPlane (C++) bằng Raycast xuống == static bool DoGroundProbe(Vector3 vStart, Vector3 vExt, float fDeltaY, LayerMask mask, out Vector3 vEnd, out Vector3 vHitNormal, out bool bSupport, @@ -280,6 +250,10 @@ namespace BrewMonster int nTry = 0; LayerMask mask = UsedMask_Ground(); + env_trace_t trcInfo = new env_trace_t(); + trcInfo.dwCheckFlag = CDR_EVN.CDR_TERRAIN | CDR_EVN.CDR_BRUSH; + trcInfo.vExt = CDRInfo.vExtent; + while (nTry < 1) { vDelta = vVelocity * fTime; @@ -290,41 +264,33 @@ namespace BrewMonster //bool hasHit = CollideWithEnv_BoxCast(vStart, vDelta, vExt, mask, // out RaycastHit hit, out float fFraction, out Vector3 hitNormal, out bool bStartSolid); Vector3 posFoot = vStart - Vector3.up * vExt.y; - //if (Physics.BoxCast(vStart, vExt, (vStart + Vector3.down).normalized, out RaycastHit hit1, Quaternion.identity, vExt.y, mask)) - //{ - // if (hit1.point.y > posFoot.y) - // { - // Debug.LogError("hit.point.y > posFoot.y"); - // posFoot.y = hit1.point.y; - // } - //} - if (Physics.Raycast(vStart, (vStart + Vector3.down).normalized, out RaycastHit hit1, vExt.y, mask)) + if (Physics.Raycast(vStart, (vStart + Vector3.down).normalized, out RaycastHit hit, vExt.y, mask)) { - if (hit1.point.y > posFoot.y) + if (hit.point.y > posFoot.y) { - posFoot.y = hit1.point.y; + posFoot.y = hit.point.y; } } - bool bClear = !Physics.Raycast(posFoot, (posFoot + vDelta).normalized, out RaycastHit hit, fDeltaDist, mask); + + bool bClear = !Physics.Raycast(posFoot, (posFoot + vDelta).normalized, out hit, fDeltaDist, mask); + + //trcInfo.vStart = CDRInfo.vCenter; + //trcInfo.vDelta = EC_Utility.ToA3DVECTOR3(vDelta); + //trcInfo.vTerStart = EC_Utility.ToA3DVECTOR3(posFoot); + ////trcInfo.vTerStart.y -= vExt.y; //foot + //bool bClear = !CollideWithEnv(ref trcInfo); nTry++; if (bClear) { - Debug.DrawLine(posFoot, posFoot + vDelta, Color.yellow, 10f); + //Debug.DrawLine(posFoot, posFoot + vDelta, Color.yellow, 10f); vFinalPos = vStart + vDelta; CDRInfo.fMoveDist += fDeltaDist; break; } - //if (trcInfo.bStartSolid) - //{ - // CDRInfo.fMoveDist = 0f; - // if (CDRInfo.vTPNormal.y < CDRInfo.fSlopeThresh) CDRInfo.vTPNormal = Vector3.up; - // return; - //} vStart = hit.point + Vector3.up * vExt.y; + //vStart += vDelta * trcInfo.fFraction + Vector3.up * vExt.y; + vFinalPos = vStart; - //CDRInfo.fMoveDist += (fDeltaDist * fFraction); - //fTime -= fTime * fFraction; - //vNormal = hitNormal; // Step-up (giữ tinh thần bản gốc) if (!bFreeFall && !bTryPull && !bJump) @@ -332,36 +298,38 @@ namespace BrewMonster //float skin = 0.01f; posFoot = vStart - Vector3.up * vExt.y + Vector3.up * CDRInfo.fStepHeight; Vector3 vStartUp = new Vector3(0f, CDRInfo.fStepHeight, 0f); - //if (Physics.Raycast(vStart, (vStart + Vector3.down).normalized, out hit1, vExt.y, mask)) - //{ - // if (hit1.point.y > posFoot.y) - // { - // Debug.LogError("hit.point.y > posFoot.y"); - // posFoot.y = hit1.point.y + CDRInfo.fStepHeight; - // } - //} bPull = !Physics.Raycast(posFoot, (Vector3.up).normalized, out hit, CDRInfo.fStepHeight, mask); + + //env_trace_t tmpInfo = new env_trace_t(); + //tmpInfo.vStart = EC_Utility.ToA3DVECTOR3(vStart); + //tmpInfo.vDelta = new A3DVECTOR3(0.0f, CDRInfo.fStepHeight, 0.0f); + //tmpInfo.vExt = CDRInfo.vExtent; + ////@note : need check terrain?? By Kuiwu[8/10/2005] + //tmpInfo.dwCheckFlag = CDR_EVN.CDR_BRUSH | CDR_EVN.CDR_TERRAIN; + //tmpInfo.vTerStart = EC_Utility.ToA3DVECTOR3(posFoot); + //bPull = !CollideWithEnv(ref tmpInfo); + if (bPull) { vStart += Vector3.up * CDRInfo.fStepHeight; posFoot = vStart - Vector3.up * vExt.y; - //Vector3 vDelta2 = vVelocity; bool bMove = !Physics.Raycast(posFoot, (posFoot + vVelocity).normalized, out hit, fDeltaDist, mask); + + //tmpInfo.vStart = EC_Utility.ToA3DVECTOR3(vStart); + //tmpInfo.vDelta = EC_Utility.ToA3DVECTOR3(vDelta); + //tmpInfo.vTerStart = EC_Utility.ToA3DVECTOR3(posFoot); + //bool bMove = !CollideWithEnv(ref tmpInfo); + if (!bMove) { - //vDelta2 *= frac2; vFinalPos = hit.point + Vector3.up * vExt.y; + //vFinalPos = vStart + vDelta * tmpInfo.fFraction + Vector3.up * vExt.y; } else { Debug.DrawLine(vFinalPos, vFinalPos + vDelta, Color.red, 10f); vFinalPos += vDelta; } - //if (vDelta2.sqrMagnitude < (vExt.x * vExt.x * 4f)) - //{ - // vStart -= Vector3.up * CDRInfo.fStepHeight; - // bPull = false; - //} } bTryPull = true; } @@ -680,7 +648,7 @@ namespace BrewMonster vFinalPos = new A3DVECTOR3(vStart); int nTry = 0; bool bClear = true; - env_trace_t trcInfo; + env_trace_t trcInfo = new env_trace_t(); trcInfo.bWaterSolid = true; trcInfo.dwCheckFlag = CDR_EVN.CDR_TERRAIN | CDR_EVN.CDR_BRUSH | CDR_EVN.CDR_WATER; trcInfo.vExt = vExt; diff --git a/Assets/PerfectWorld/Scripts/Task/ATaskTemplMan.cs b/Assets/PerfectWorld/Scripts/Task/ATaskTemplMan.cs index 11f773d71c..afbceb3d08 100644 --- a/Assets/PerfectWorld/Scripts/Task/ATaskTemplMan.cs +++ b/Assets/PerfectWorld/Scripts/Task/ATaskTemplMan.cs @@ -1394,13 +1394,16 @@ namespace BrewMonster.Scripts.Task BMLogger.LogError("[ATaskTemplMan] LoadTaskTemplFromSO returned null result"); return false; } + + if(!config.LoadAllTasksOnValidate) return false; var loadedTasks = config.TaskTemplates; - if (loadedTasks == null || loadedTasks.Count == 0) + if (loadedTasks == null ||loadedTasks.Count == 0) { BMLogger.LogError("[ATaskTemplMan] LoadTaskTemplFromSO, no task templates found in SO"); return false; } + for (int i = 0; i < loadedTasks.Count; i++) { diff --git a/Assets/PerfectWorld/Scripts/Task/TaskTemplContainerSO.cs b/Assets/PerfectWorld/Scripts/Task/TaskTemplContainerSO.cs index aea562221e..5ab534c6b9 100644 --- a/Assets/PerfectWorld/Scripts/Task/TaskTemplContainerSO.cs +++ b/Assets/PerfectWorld/Scripts/Task/TaskTemplContainerSO.cs @@ -12,10 +12,13 @@ namespace BrewMonster.Scripts.Task public const ulong TASK_PACK_MAGIC = 0x93858361; public const ulong _task_templ_cur_version = 121; + [SerializeField] private bool _loadAllTasksOnValidate = false; [SerializeField] private List _taskTemplates = new List(); public List TaskTemplates { get { return _taskTemplates; } } public int TaskLoadedCount; + public bool LoadAllTasksOnValidate => _loadAllTasksOnValidate; + private void OnValidate() { diff --git a/Assets/PerfectWorld/Scripts/Task/TaskTest.cs b/Assets/PerfectWorld/Scripts/Task/TaskTest.cs index b0ebffc15e..086fe1ab0b 100644 --- a/Assets/PerfectWorld/Scripts/Task/TaskTest.cs +++ b/Assets/PerfectWorld/Scripts/Task/TaskTest.cs @@ -56,7 +56,7 @@ namespace BrewMonster.Scripts.Task #if UNITY_EDITOR if (Input.GetKeyDown(KeyCode.Q)) { - var dlgTaskGO = CECUIManager.Instance.GetInGameUIMan().GetDialog("Win_Task"); + var dlgTaskGO = CECUIManager.Instance.GetInGameUIMan().GetDialog(CECUIHelper.DlgTaskName); var dlgTask = (dlgTaskGO) as DlgTask; if (dlgTask && !dlgTask.gameObject.activeInHierarchy) { diff --git a/Assets/PerfectWorld/Scripts/UI/EC_UIHelper.cs b/Assets/PerfectWorld/Scripts/UI/EC_UIHelper.cs index d1706dff49..4d8fb15f3d 100644 --- a/Assets/PerfectWorld/Scripts/UI/EC_UIHelper.cs +++ b/Assets/PerfectWorld/Scripts/UI/EC_UIHelper.cs @@ -5,6 +5,8 @@ namespace BrewMonster.Scripts.UI { public class CECUIHelper { + public static string DlgTaskName = "Win_Quest"; + public static A3DVECTOR3 GetTaskObjectCoordinates(int id, ref bool in_table) { in_table = false; diff --git a/Assets/PerfectWorld/Scripts/UI/GamePlay/EC_GameUIMan.cs b/Assets/PerfectWorld/Scripts/UI/GamePlay/EC_GameUIMan.cs index 3032b91397..8f434e0a1c 100644 --- a/Assets/PerfectWorld/Scripts/UI/GamePlay/EC_GameUIMan.cs +++ b/Assets/PerfectWorld/Scripts/UI/GamePlay/EC_GameUIMan.cs @@ -8,6 +8,7 @@ using System.IO; using System.Linq; using BrewMonster.Scripts.Task; using BrewMonster.Scripts.Task.UI; +using BrewMonster.Scripts.UI; using UnityEngine; namespace BrewMonster.UI @@ -117,7 +118,7 @@ namespace BrewMonster.UI { base.Init(); - m_pDlgTask = GetDialog("Win_Task").GetComponent(); + m_pDlgTask = GetDialog(CECUIHelper.DlgTaskName).GetComponent(); m_pDlgTask.Show(false); } } diff --git a/Assets/PerfectWorld/Scripts/UI/JumpBtn.cs b/Assets/PerfectWorld/Scripts/UI/JumpBtn.cs new file mode 100644 index 0000000000..e8ecd1d768 --- /dev/null +++ b/Assets/PerfectWorld/Scripts/UI/JumpBtn.cs @@ -0,0 +1,29 @@ +using BrewMonster.Network; +using UnityEngine; +using UnityEngine.UI; + +namespace BrewMonster.UI +{ + public class JumpBtn : MonoBehaviour + { + Button jumpBtn; + + // Start is called once before the first execution of Update after the MonoBehaviour is created + void Start() + { + if(jumpBtn == null) + { + jumpBtn = GetComponent