lvjincheng 3 éve
szülő
commit
787bac6609

+ 80 - 4
Assets/BowArrow/Modules/NewUserGuider/NewUserGuider.prefab

@@ -187,7 +187,7 @@ RectTransform:
   m_Children:
   - {fileID: 3835120306900162602}
   m_Father: {fileID: 3835120308163295950}
-  m_RootOrder: 6
+  m_RootOrder: 7
   m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
   m_AnchorMin: {x: 0.5, y: 0.5}
   m_AnchorMax: {x: 0.5, y: 0.5}
@@ -302,7 +302,7 @@ RectTransform:
   m_LocalScale: {x: 1, y: 1, z: 1}
   m_Children: []
   m_Father: {fileID: 3835120308163295950}
-  m_RootOrder: 4
+  m_RootOrder: 5
   m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
   m_AnchorMin: {x: 0.5, y: 0.5}
   m_AnchorMax: {x: 0.5, y: 0.5}
@@ -565,7 +565,7 @@ RectTransform:
   m_LocalScale: {x: 1, y: 1, z: 1}
   m_Children: []
   m_Father: {fileID: 3835120308163295950}
-  m_RootOrder: 5
+  m_RootOrder: 6
   m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
   m_AnchorMin: {x: 0.5, y: 0.5}
   m_AnchorMax: {x: 0.5, y: 0.5}
@@ -645,6 +645,7 @@ RectTransform:
   - {fileID: 3835120308048927399}
   - {fileID: 3835120307437960352}
   - {fileID: 5494588147348624848}
+  - {fileID: 4142167951803109672}
   - {fileID: 3835120307137106929}
   - {fileID: 3835120308157238170}
   - {fileID: 3835120307076861217}
@@ -844,7 +845,7 @@ RectTransform:
   - {fileID: 3751494608507439364}
   - {fileID: 8617761934889499988}
   m_Father: {fileID: 3835120308163295950}
-  m_RootOrder: 7
+  m_RootOrder: 8
   m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
   m_AnchorMin: {x: 0, y: 1}
   m_AnchorMax: {x: 0, y: 1}
@@ -1171,3 +1172,78 @@ MonoBehaviour:
   textKey: new-user-guider_btn_skip
   layoutRebuildObject: {fileID: 0}
   languageFontSizes: []
+--- !u!1 &9045994492052768067
+GameObject:
+  m_ObjectHideFlags: 0
+  m_CorrespondingSourceObject: {fileID: 0}
+  m_PrefabInstance: {fileID: 0}
+  m_PrefabAsset: {fileID: 0}
+  serializedVersion: 6
+  m_Component:
+  - component: {fileID: 4142167951803109672}
+  - component: {fileID: 7251119255213309761}
+  - component: {fileID: 6871737440918261}
+  m_Layer: 5
+  m_Name: CrossHair-Light
+  m_TagString: Untagged
+  m_Icon: {fileID: 0}
+  m_NavMeshLayer: 0
+  m_StaticEditorFlags: 0
+  m_IsActive: 0
+--- !u!224 &4142167951803109672
+RectTransform:
+  m_ObjectHideFlags: 0
+  m_CorrespondingSourceObject: {fileID: 0}
+  m_PrefabInstance: {fileID: 0}
+  m_PrefabAsset: {fileID: 0}
+  m_GameObject: {fileID: 9045994492052768067}
+  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_Children: []
+  m_Father: {fileID: 3835120308163295950}
+  m_RootOrder: 4
+  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: 0, y: 0}
+  m_SizeDelta: {x: 199, y: 199}
+  m_Pivot: {x: 0.5, y: 0.5}
+--- !u!222 &7251119255213309761
+CanvasRenderer:
+  m_ObjectHideFlags: 0
+  m_CorrespondingSourceObject: {fileID: 0}
+  m_PrefabInstance: {fileID: 0}
+  m_PrefabAsset: {fileID: 0}
+  m_GameObject: {fileID: 9045994492052768067}
+  m_CullTransparentMesh: 1
+--- !u!114 &6871737440918261
+MonoBehaviour:
+  m_ObjectHideFlags: 0
+  m_CorrespondingSourceObject: {fileID: 0}
+  m_PrefabInstance: {fileID: 0}
+  m_PrefabAsset: {fileID: 0}
+  m_GameObject: {fileID: 9045994492052768067}
+  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: 21300000, guid: f7d4f2aadb3a74c489fe71273425bfdf, type: 3}
+  m_Type: 0
+  m_PreserveAspect: 0
+  m_FillCenter: 1
+  m_FillMethod: 4
+  m_FillAmount: 1
+  m_FillClockwise: 1
+  m_FillOrigin: 0
+  m_UseSpriteMesh: 0
+  m_PixelsPerUnitMultiplier: 1

+ 12 - 4
Assets/BowArrow/Modules/NewUserGuider/NewUserGuiderManager.cs

@@ -285,7 +285,7 @@ public class NewUserGuiderManager : MonoBehaviour
             g.config.pointerRotZ = 180;
             g.config.pointerPos = RectTransformUtils.GetPositionByPivot(btn, new Vector2(-0.1f, 0.2f));
             g.config.frameTipPos = RectTransformUtils.GetPositionByPivot(btn, new Vector2(0.3f, 0))
-                + RectTransformUtils.CanvasV3ToScreenV3(Vector3.down * 60f, g.iconPointer);
+                + RectTransformUtils.CanvasV3ToScreenV3(Vector3.down * 45f, g.iconPointer);
         };
         config.onStart = (g) => {
             g.GetMaskClickedEvent().RemoveAllListeners();
@@ -612,8 +612,7 @@ public class NewUserGuiderManager : MonoBehaviour
 
         config = new NewUserGuiderConfig();
         config.key = "准心高亮";
-        config.hitPosType = 1;
-        config.hitPos = Vector2.zero;
+        config.hitActive = false;
         config.pointerActive = false;
         config.frameTipText = "";
         config.onStart = (g) => {
@@ -633,6 +632,9 @@ public class NewUserGuiderManager : MonoBehaviour
             Transform centerPoint = TargetBody.ins.transform.Find("CenterPoint");
             Transform sidePoint = TargetBody.ins.transform.Find("SidePoint");
 
+            RectTransform crossHairLight = g.transform.Find("CrossHair-Light") as RectTransform;
+            crossHairLight.gameObject.SetActive(true);
+
             float countDown = 5;
             g.action_Update += () => {
                 Vector3 centerPos = RectTransformUtility.WorldToScreenPoint(Camera.main, centerPoint.position);
@@ -646,7 +648,13 @@ public class NewUserGuiderManager : MonoBehaviour
                     g.clickedWillPlayAudioBtn = false;
                     g.OnClick_ToNext();
                 }
-                g.iconPointerHit.transform.position = CrossHair.ins.transform.position;
+            };
+            Action a_updateCrossHair = () => {
+                crossHairLight.position = CrossHair.ins.transform.position;
+            };
+            CrossHair.ins.action_UpdatePostionWhenFixedCamera += a_updateCrossHair;
+            g.action_OnDestroy += () => {
+                if (CrossHair.ins) CrossHair.ins.action_UpdatePostionWhenFixedCamera -= a_updateCrossHair;
             };
         };
         configs.Add(config.key, config);

BIN
Assets/BowArrow/Modules/NewUserGuider/Textures/CrossHair-Light.png


+ 120 - 0
Assets/BowArrow/Modules/NewUserGuider/Textures/CrossHair-Light.png.meta

@@ -0,0 +1,120 @@
+fileFormatVersion: 2
+guid: f7d4f2aadb3a74c489fe71273425bfdf
+TextureImporter:
+  internalIDToNameTable: []
+  externalObjects: {}
+  serializedVersion: 11
+  mipmaps:
+    mipMapMode: 0
+    enableMipMap: 0
+    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
+  grayScaleToAlpha: 0
+  generateCubemap: 6
+  cubemapConvolution: 0
+  seamlessCubemap: 0
+  textureFormat: 1
+  maxTextureSize: 2048
+  textureSettings:
+    serializedVersion: 2
+    filterMode: 1
+    aniso: 1
+    mipBias: 0
+    wrapU: 1
+    wrapV: 1
+    wrapW: 0
+  nPOTScale: 0
+  lightmap: 0
+  compressionQuality: 50
+  spriteMode: 1
+  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: 1
+  spriteTessellationDetail: -1
+  textureType: 8
+  textureShape: 1
+  singleChannelComponent: 0
+  flipbookRows: 1
+  flipbookColumns: 1
+  maxTextureSizeSet: 0
+  compressionQualitySet: 0
+  textureFormatSet: 0
+  ignorePngGamma: 0
+  applyGammaDecoding: 0
+  platformSettings:
+  - serializedVersion: 3
+    buildTarget: DefaultTexturePlatform
+    maxTextureSize: 2048
+    resizeAlgorithm: 0
+    textureFormat: -1
+    textureCompression: 1
+    compressionQuality: 50
+    crunchedCompression: 0
+    allowsAlphaSplitting: 0
+    overridden: 0
+    androidETC2FallbackOverride: 0
+    forceMaximumCompressionQuality_BC6H_BC7: 0
+  - serializedVersion: 3
+    buildTarget: Standalone
+    maxTextureSize: 2048
+    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: 2048
+    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: 5e97eb03825dee720800000000000000
+    internalID: 0
+    vertices: []
+    indices: 
+    edges: []
+    weights: []
+    secondaryTextures: []
+  spritePackingTag: 
+  pSDRemoveMatte: 0
+  pSDShowRemoveMatteOption: 0
+  userData: 
+  assetBundleName: 
+  assetBundleVariant: 

+ 1 - 1
Assets/BowArrow/Scripts/Components/TextAutoLanguage2/Resources/TextAutoLanguage2/cn.json

@@ -37,7 +37,7 @@
     "new-user-guider_tip_连接设备": "点击<color=#FFA500>“连接”</color>等待设备提示连接成功,\n此时模块是绿灯常亮的状态。",
     "new-user-guider_tip_弓箭详情": "点击<color=#FFA500>弓箭</color>,进入设备界面进行模块校准。",
     "new-user-guider_tip_设备-陀螺仪校准": "将安装了模块的智能弓箭<color=#FFA500>静置在一个平面上</color>,\n再点击陀螺仪校准。",
-    "new-user-guider_tip_设备-地磁计校准": "将安装了模块的智能弓箭<color=#FFA500>沿着每一个轴旋转</color>,\n直到提示校准完成。",
+    "new-user-guider_tip_设备-地磁计校准": "将安装了模块的智能弓箭<color=#FFA500>沿着不同方向持续翻转</color>,\n直到提示校准完成为止。",
     "new-user-guider_tip_查看设置": "点击<color=#FFA500>设置</color>了解更多",
     "new-user-guider_tip_查看商城": "点击查看<color=#FFA500>商城</color>",
     "new-user-guider_tip_切换好友/排行榜": "点击切换<color=#FFA500>好友/排行榜</color>",

+ 1 - 1
Assets/BowArrow/Scripts/Components/TextAutoLanguage2/Resources/TextAutoLanguage2/en.json

@@ -37,7 +37,7 @@
     "new-user-guider_tip_连接设备": "Click <color=#FFA500>\"Connect\"</color> and wait for the device \nto prompt that the connection is \nsuccessful. At this time, the module \nis in the green state.",
     "new-user-guider_tip_弓箭详情": "Click the <color=#FFA500>arrow</color> to enter the device \ninterface for module calibration.",
     "new-user-guider_tip_设备-陀螺仪校准": "Place the smart bow with the module <color=#FFA500>installed \non a plane</color>, and then click GyrCalibrate.",
-    "new-user-guider_tip_设备-地磁计校准": "Rotate the smart bow with modules <color=#FFA500>installed along \neach axis</color>, until prompted that calibration is completed.",
+    "new-user-guider_tip_设备-地磁计校准": "Turn the smart bow and arrow with the module \n<color=#FFA500>installed in different directions</color> until it prompts \nthat the calibration is completed.",
     "new-user-guider_tip_查看设置": "Click <color=#FFA500>SetUp</color> to learn more",
     "new-user-guider_tip_查看商城": "Click to view the <color=#FFA500>Shop</color>",
     "new-user-guider_tip_切换好友/排行榜": "Click to switch <color=#FFA500>friend/rand</color>",

+ 2 - 0
Assets/BowArrow/Scripts/Game/CrossHair.cs

@@ -97,6 +97,8 @@ public class CrossHair : MonoBehaviour
             v3.y *= parentRTF.rect.height;
             v3.z = 0;
             this.transform.localPosition = v3;
+            action_UpdatePostionWhenFixedCamera?.Invoke();
         }
+        public System.Action action_UpdatePostionWhenFixedCamera;
     #endregion
 }