NewUserGuiderManager.cs 21 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516
  1. using System;
  2. using System.Collections;
  3. using System.Collections.Generic;
  4. using UnityEngine;
  5. using UnityEngine.UI;
  6. using UnityEngine.SceneManagement;
  7. using JC.Unity.UI;
  8. public class NewUserGuiderManager : MonoBehaviour
  9. {
  10. [SerializeField] GameObject prefab_NewUserGuider;
  11. public static NewUserGuiderManager ins;
  12. void Awake()
  13. {
  14. if (ins) {
  15. Destroy(gameObject);
  16. return;
  17. }
  18. ins = this;
  19. DontDestroyOnLoad(gameObject);
  20. }
  21. void OnDestroy()
  22. {
  23. if (ins == this) ins = null;
  24. if (onSceneLoaded_added) SceneManager.sceneLoaded -= onSceneLoaded;
  25. }
  26. void Start()
  27. {
  28. SceneManager.sceneLoaded += onSceneLoaded; onSceneLoaded_added = true;
  29. if (!IsUserGuideFinished()) {
  30. ExecuteCurConfig();
  31. SaveUserGuideFinished(true);
  32. }
  33. }
  34. bool onSceneLoaded_added = false;
  35. void onSceneLoaded(Scene scene, LoadSceneMode loadSceneMode) { //初始话的场景不会触发
  36. if (scene.name == "Game" && GameMgr.gameType == 1) {
  37. switch (curConfigKey) {
  38. case "开始-限时游戏":
  39. OnClickedDestroyed(curConfigKey);
  40. break;
  41. case "限时游戏-选择距离":
  42. ExecuteCurConfig();
  43. break;
  44. }
  45. }
  46. }
  47. public void OnSkip()
  48. {
  49. curConfigKey = null;
  50. SaveUserGuideFinished(true);
  51. }
  52. public void OnEnd()
  53. {
  54. curConfigKey = null;
  55. SaveUserGuideFinished(true);
  56. }
  57. public void ReviewNewUserGuide()
  58. {
  59. int viewCount = PersistenHandler.ins.menuBackCtr.views.Count;
  60. for (int i = 0; i < viewCount; i++) {
  61. PersistenHandler.ins.menuBackCtr.OnOnceBack();
  62. }
  63. curConfigKey = "模块开机";
  64. ExecuteCurConfig();
  65. }
  66. void SaveUserGuideFinished(bool finished) {
  67. PlayerPrefs.SetInt("NewUserGuiderFinished", finished ? 1 : 0);
  68. }
  69. bool IsUserGuideFinished() {
  70. return PlayerPrefs.GetInt("NewUserGuiderFinished", 0) == 1 ? true : false;
  71. }
  72. void InitConfigs()
  73. {
  74. if (configsInited) return;
  75. configsInited = true;
  76. NewUserGuiderConfig config = new NewUserGuiderConfig();
  77. config.key = "模块开机";
  78. config.hitPosType = 1;
  79. config.hitPos = new Vector2(-86.4f, -70.3f);
  80. config.pointerRotZ = 120;
  81. config.pointerPosType = 1;
  82. config.pointerPos = new Vector2(-155, -31);
  83. config.frameTipPosType = 1;
  84. config.frameTipPos = new Vector2(-73.5f, 106);
  85. config.onStart = (g) => g.transform.Find("IconModule").gameObject.SetActive(true);
  86. configs.Add(config.key, config);
  87. config = new NewUserGuiderConfig();
  88. config.key = "连接设备";
  89. config.frameTipPivot = "lb";
  90. config.frameTipText = TextAutoLanguage2.GetTextByKey("new-user-guider_tip_" + config.key);
  91. config.onPrepare = (g) => {
  92. RectTransform btn = GameObject.Find("HomeView/HomeViewRenderBow/Btn").GetComponent<RectTransform>();
  93. g.hollowOutMask.SetTarget(btn);
  94. g.hollowOutMask.isTargetRectCanThrough = false;
  95. g.SetIconPointerHitOpacity(0.5f);
  96. g.config.hitPos = btn.position;
  97. g.config.pointerPos = btn.position + RectTransformUtils.CanvasV3ToScreenV3(Vector3.up * 80f, btn);
  98. g.config.frameTipPos = btn.position + RectTransformUtils.CanvasV3ToScreenV3(Vector3.up * 150f, btn);
  99. };
  100. configs.Add(config.key, config);
  101. config = new NewUserGuiderConfig();
  102. config.key = "弓箭详情";
  103. config.frameTipPivot = "lt";
  104. config.onPrepare = (g) => {
  105. RectTransform btn = GameObject.Find("HomeView/HomeViewRenderBow/BtnShowDetail").GetComponent<RectTransform>();
  106. g.hollowOutMask.SetTarget(btn);
  107. g.hollowOutMask.isTargetRectCanThrough = false;
  108. g.config.hitPos = RectTransformUtils.GetPositionByPivot(btn, Vector2.one * 0.5f);
  109. g.config.pointerPos = RectTransformUtils.GetPositionByPivot(btn, new Vector2(0.8f, 0.7f));
  110. g.config.frameTipPos = RectTransformUtils.GetPositionByPivot(btn, new Vector2(0.8f, 0.5f));
  111. HomeViewRenderBow homeViewRenderBow = FindObjectOfType<HomeViewRenderBow>();
  112. if (homeViewRenderBow) {
  113. g.clickedWillPlayAudioBtn = false;
  114. g.GetMaskClickedEvent().AddListener(homeViewRenderBow.OnClick_ShowDeviceView);
  115. }
  116. };
  117. configs.Add(config.key, config);
  118. config = new NewUserGuiderConfig();
  119. config.key = "设备-陀螺仪校准";
  120. config.frameTipPivot = "rt";
  121. config.onPrepare = (g) => {
  122. if (!DeviceView1.ins) {
  123. g.customPreparePass = false;
  124. return;
  125. }
  126. g.customPreparePass = true;
  127. RectTransform btn = DeviceView1.ins.transform.Find("ItemInfo/BowOptions/GyrCalibrate") as RectTransform;
  128. g.hollowOutMask.SetTarget(btn);
  129. g.hollowOutMask.isTargetRectCanThrough = false;
  130. g.SetIconPointerHitOpacity(0.8f);
  131. g.config.hitPos = RectTransformUtils.GetPositionByPivot(btn, Vector2.one * 0.5f);
  132. g.config.pointerRotZ = 180;
  133. g.config.pointerPos = RectTransformUtils.GetPositionByPivot(btn, new Vector2(-0.1f, 0.2f));
  134. g.config.frameTipPos = RectTransformUtils.GetPositionByPivot(btn, new Vector2(0.3f, 0))
  135. + RectTransformUtils.CanvasV3ToScreenV3(Vector3.down * 80f, g.iconPointer);
  136. };
  137. configs.Add(config.key, config);
  138. config = new NewUserGuiderConfig();
  139. config.key = "设备-地磁计校准";
  140. config.frameTipPivot = "rt";
  141. config.onPrepare = (g) => {
  142. if (!DeviceView1.ins) {
  143. g.customPreparePass = false;
  144. return;
  145. }
  146. g.customPreparePass = true;
  147. RectTransform btn = DeviceView1.ins.transform.Find("ItemInfo/BowOptions/MagCalibrate") as RectTransform;
  148. g.hollowOutMask.SetTarget(btn);
  149. g.hollowOutMask.isTargetRectCanThrough = false;
  150. g.SetIconPointerHitOpacity(0.8f);
  151. g.config.hitPos = RectTransformUtils.GetPositionByPivot(btn, Vector2.one * 0.5f);
  152. g.config.pointerRotZ = 180;
  153. g.config.pointerPos = RectTransformUtils.GetPositionByPivot(btn, new Vector2(-0.1f, 0.2f));
  154. g.config.frameTipPos = RectTransformUtils.GetPositionByPivot(btn, new Vector2(0.3f, 0))
  155. + RectTransformUtils.CanvasV3ToScreenV3(Vector3.down * 60f, g.iconPointer);
  156. DeviceView1 deviceView1 = FindObjectOfType<DeviceView1>();
  157. if (deviceView1) {
  158. g.clickedWillPlayAudioBtn = false;
  159. g.GetMaskClickedEvent().AddListener(deviceView1.OnClick_Back);
  160. }
  161. };
  162. configs.Add(config.key, config);
  163. config = new NewUserGuiderConfig();
  164. config.key = "查看设置";
  165. config.frameTipPivot = "rt";
  166. config.onPrepare = (g) => {
  167. RectTransform btn = GameObject.Find("TopBarView/TopBar/IconSetUp").GetComponent<RectTransform>();
  168. g.hollowOutMask.SetTarget(btn);
  169. g.hollowOutMask.isTargetRectCanThrough = false;
  170. g.SetIconPointerHitOpacity(0.6f);
  171. g.config.hitPos = RectTransformUtils.GetPositionByPivot(btn, Vector2.one * 0.5f);
  172. g.config.pointerRotZ = 180;
  173. g.config.pointerPos = RectTransformUtils.GetPositionByPivot(btn, Vector2.one * -0.1f);
  174. g.config.frameTipPos = RectTransformUtils.GetPositionByPivot(btn, Vector2.zero)
  175. + RectTransformUtils.CanvasV3ToScreenV3(Vector3.down * 80f, g.iconPointer);
  176. };
  177. configs.Add(config.key, config);
  178. config = new NewUserGuiderConfig();
  179. config.key = "查看商城";
  180. config.frameTipPivot = "rt";
  181. config.onPrepare = (g) => {
  182. RectTransform btn = GameObject.Find("TopBarView/TopBar/IconShop").GetComponent<RectTransform>();
  183. g.hollowOutMask.SetTarget(btn);
  184. g.hollowOutMask.isTargetRectCanThrough = false;
  185. g.SetIconPointerHitOpacity(0.6f);
  186. g.config.hitPos = RectTransformUtils.GetPositionByPivot(btn, Vector2.one * 0.5f);
  187. g.config.pointerRotZ = 180;
  188. g.config.pointerPos = RectTransformUtils.GetPositionByPivot(btn, Vector2.one * -0.1f);
  189. g.config.frameTipPos = RectTransformUtils.GetPositionByPivot(btn, Vector2.zero)
  190. + RectTransformUtils.CanvasV3ToScreenV3(Vector3.down * 80f, g.iconPointer);
  191. };
  192. configs.Add(config.key, config);
  193. config = new NewUserGuiderConfig();
  194. config.key = "切换好友/排行榜";
  195. config.frameTipPivot = "lt";
  196. config.onPrepare = (g) => {
  197. RectTransform btn = GameObject.Find("HomeView/FriendBar/FrameBtnTop").GetComponent<RectTransform>();
  198. g.hollowOutMask.SetTarget(btn);
  199. g.hollowOutMask.isTargetRectCanThrough = false;
  200. g.SetIconPointerHitOpacity(0.6f);
  201. g.config.hitPos = RectTransformUtils.GetPositionByPivot(btn, Vector2.one * 0.5f);
  202. g.config.pointerRotZ = -30;
  203. g.config.pointerPos = RectTransformUtils.GetPositionByPivot(btn, new Vector2(1.2f, 0.9f));
  204. g.config.frameTipPos = RectTransformUtils.GetPositionByPivot(btn, new Vector2(1.2f, 0));
  205. };
  206. configs.Add(config.key, config);
  207. config = new NewUserGuiderConfig();
  208. config.key = "展开好友/排行榜";
  209. config.frameTipPivot = "lc";
  210. config.onPrepare = (g) => {
  211. RectTransform btn = GameObject.Find("HomeView/FriendBar/FrameBtnBottom").GetComponent<RectTransform>();
  212. g.hollowOutMask.SetTarget(btn);
  213. g.hollowOutMask.isTargetRectCanThrough = false;
  214. g.SetIconPointerHitOpacity(0.8f);
  215. g.config.hitPos = RectTransformUtils.GetPositionByPivot(btn, Vector2.one * 0.5f);
  216. g.config.pointerRotZ = -30;
  217. g.config.pointerPos = RectTransformUtils.GetPositionByPivot(btn, new Vector2(1, 0.9f));
  218. g.config.frameTipPos = RectTransformUtils.GetPositionByPivot(btn, new Vector2(1.5f, 0.5f));
  219. };
  220. configs.Add(config.key, config);
  221. config = new NewUserGuiderConfig();
  222. config.key = "联机游戏";
  223. config.frameTipPivot = "lt";
  224. config.onPrepare = (g) => {
  225. RectTransform btn = GameObject.Find("HomeView/RightPanel/Item (1)").GetComponent<RectTransform>();
  226. g.hollowOutMask.SetTarget(btn);
  227. g.hollowOutMask.isTargetRectCanThrough = false;
  228. g.config.hitPos = RectTransformUtils.GetPositionByPivot(btn, new Vector2(0.5f, 0.6f));
  229. g.config.pointerPos = RectTransformUtils.GetPositionByPivot(btn, new Vector2(0.8f, 0.9f));
  230. g.config.frameTipPos = RectTransformUtils.GetPositionByPivot(btn, Vector2.zero);
  231. };
  232. configs.Add(config.key, config);
  233. config = new NewUserGuiderConfig();
  234. config.key = "开始游戏";
  235. config.frameTipPivot = "lt";
  236. config.onPrepare = (g) => {
  237. RectTransform btn = GameObject.Find("HomeView/RightPanel/Item").GetComponent<RectTransform>();
  238. g.hollowOutMask.SetTarget(btn);
  239. g.hollowOutMask.isTargetRectCanThrough = false;
  240. g.config.hitPos = RectTransformUtils.GetPositionByPivot(btn, new Vector2(0.5f, 0.6f));
  241. g.config.pointerPos = RectTransformUtils.GetPositionByPivot(btn, new Vector2(0.8f, 0.9f));
  242. g.config.frameTipPos = RectTransformUtils.GetPositionByPivot(btn, Vector2.zero);
  243. g.GetMaskClickedEvent().AddListener(() => {
  244. GameObject.Instantiate(SceneResMgr.ins.GetPrefab("GameStartView"));
  245. });
  246. };
  247. configs.Add(config.key, config);
  248. config = new NewUserGuiderConfig();
  249. config.key = "开始-限时游戏";
  250. config.frameTipPivot = "lt";
  251. config.onPrepare = (g) => {
  252. if (!GameStartView.ins) {
  253. g.customPreparePass = false;
  254. return;
  255. }
  256. g.customPreparePass = true;
  257. RectTransform btn = GameStartView.ins.transform.Find("EntryList/Item (1)") as RectTransform;
  258. g.hollowOutMask.SetTarget(btn);
  259. g.hollowOutMask.isTargetRectCanThrough = false;
  260. g.config.hitPos = RectTransformUtils.GetPositionByPivot(btn, Vector2.one * 0.5f);
  261. g.config.pointerRotZ = 180;
  262. g.config.pointerPos = RectTransformUtils.GetPositionByPivot(btn, new Vector2(0.2f, 0.3f));
  263. g.config.frameTipPos = RectTransformUtils.GetPositionByPivot(btn, new Vector2(0.4f, 0.15f));
  264. };
  265. config.onStart = (g) => {
  266. GameStartView gameStartView = FindObjectOfType<GameStartView>();
  267. if (gameStartView) {
  268. string ck = g.config.key;
  269. g.GetMaskClickedEvent().RemoveAllListeners();
  270. g.GetMaskClickedEvent().AddListener(() => {
  271. gameStartView.GoTo("限时");
  272. //后续在NewUserGuiderManager.onSceneLoaded触发
  273. });
  274. }
  275. };
  276. configs.Add(config.key, config);
  277. config = new NewUserGuiderConfig();
  278. config.key = "限时游戏-选择距离";
  279. config.frameTipPivot = "lc";
  280. config.onPrepare = (g) => {
  281. if (g.hollowOutMask.enabled) g.hollowOutMask.enabled = false;
  282. if (!TimeLimitGameDistanceSelectView.ins) {
  283. g.customPreparePass = false;
  284. return;
  285. }
  286. g.customPreparePass = true;
  287. g.hollowOutMask.enabled = true;
  288. RectTransform btn = TimeLimitGameDistanceSelectView.ins.transform.Find("Layout/Item") as RectTransform;
  289. g.hollowOutMask.SetTarget(btn);
  290. g.hollowOutMask.isTargetRectCanThrough = false;
  291. g.config.hitPos = RectTransformUtils.GetPositionByPivot(btn, Vector2.one * 0.5f);
  292. g.config.pointerRotZ = -30;
  293. g.config.pointerPos = RectTransformUtils.GetPositionByPivot(btn, new Vector2(0.85f, 0.5f));
  294. g.config.frameTipPos = RectTransformUtils.GetPositionByPivot(btn, new Vector2(1.15f, 0.4f));
  295. g.clickedWillPlayAudioBtn = false;
  296. g.GetMaskClickedEvent().AddListener(() => {
  297. btn.GetComponent<Button>().onClick.Invoke();
  298. });
  299. };
  300. configs.Add(config.key, config);
  301. config = new NewUserGuiderConfig();
  302. config.key = "视角归位-触发";
  303. config.frameTipPivot = "rb";
  304. config.frameTipPos = Vector2.zero;
  305. config.onPrepare = (g) => {
  306. if (!GameAssistUI.ins) {
  307. g.customPreparePass = false;
  308. return;
  309. }
  310. g.customPreparePass = true;
  311. g.hollowOutMask.isTargetRectCanThrough = false;
  312. RectTransform btn4 = GameAssistUI.ins.transform.Find("Button4") as RectTransform;
  313. g.hollowOutMask.SetTarget(btn4);
  314. RectTransform btn4_img = btn4.Find("Image") as RectTransform;
  315. g.config.hitPos = btn4_img.position;
  316. g.config.pointerRotZ = 120;
  317. g.config.pointerPos = btn4_img.position + RectTransformUtils.CanvasV3ToScreenV3(new Vector3(-60, 60), btn4);
  318. g.config.frameTipPos = btn4_img.position + RectTransformUtils.CanvasV3ToScreenV3(new Vector3(-120, 120), btn4);
  319. // g.clickedWillPlayAudioBtn = false;
  320. // g.GetMaskClickedEvent().AddListener(() => {
  321. // btn4.GetComponent<Button>().onClick.Invoke();
  322. // });
  323. GameMode gameMode = GameMgr.ins.gameMode;
  324. if (gameMode.GetType().Equals(typeof(TimeLimitGameMode))) {
  325. gameMode.PauseTimeCounting(g);
  326. g.action_OnDestroy += () => gameMode.ResumeTimeCounting(g);
  327. }
  328. };
  329. config.onStart = (g) => {
  330. g.GetMaskClickedEvent().RemoveAllListeners();
  331. g.GetNewUserGuiderButton().onClick += g.OnClick_ToNext;
  332. };
  333. configs.Add(config.key, config);
  334. config = new NewUserGuiderConfig();
  335. config.key = "视角归位-瞄准";
  336. config.frameTipPivot = "lc";
  337. config.onPrepare = (g) => {
  338. float rectSideLen = RectTransformUtils.ScreenV3ToCanvasV3(Vector3.right * Screen.height * 100 / 720f, g.GetComponent<RectTransform>()).x;
  339. Vector2 rectSize = new Vector2(rectSideLen, rectSideLen);
  340. RectTransform iconRect = g.transform.Find("IconRect") as RectTransform;
  341. iconRect.sizeDelta = rectSize;
  342. iconRect.gameObject.SetActive(true);
  343. g.hollowOutMask.isTargetRectCanThrough = false;
  344. g.hollowOutMask.SetTarget(iconRect);
  345. g.config.hitPosType = 1;
  346. g.config.hitPos = Vector2.zero;
  347. g.config.pointerPosType = 1;
  348. g.config.pointerRotZ = 120;
  349. g.config.pointerPos = new Vector2(-rectSideLen / 2 * 1.2f, rectSideLen / 2 * 1.1f);
  350. RectTransform iconHumanShoot = g.transform.Find("IconHumanShoot") as RectTransform;
  351. iconHumanShoot.anchoredPosition = g.config.pointerPos;
  352. iconHumanShoot.gameObject.SetActive(true);
  353. g.config.frameTipPosType = 1;
  354. g.config.frameTipPos = new Vector2(rectSideLen / 2 * 1.3f, 0);
  355. GameMode gameMode = GameMgr.ins.gameMode;
  356. if (gameMode.GetType().Equals(typeof(TimeLimitGameMode))) {
  357. gameMode.PauseTimeCounting(g);
  358. g.action_OnDestroy += () => gameMode.ResumeTimeCounting(g);
  359. }
  360. };
  361. configs.Add(config.key, config);
  362. config = new NewUserGuiderConfig();
  363. config.key = "教程结束";
  364. config.hitActive = false;
  365. config.pointerActive = false;
  366. config.frameTipPivot = "ct";
  367. config.frameTipPosType = 1;
  368. config.frameTipPos = Vector2.zero;
  369. config.onStart = (g) => {
  370. g.GetMaskClickedEvent().AddListener(() => {
  371. OnEnd();
  372. });
  373. GameMode gameMode = GameMgr.ins.gameMode;
  374. if (gameMode.GetType().Equals(typeof(TimeLimitGameMode))) {
  375. gameMode.PauseTimeCounting(g);
  376. g.action_OnDestroy += () => gameMode.ResumeTimeCounting(g);
  377. }
  378. };
  379. configs.Add(config.key, config);
  380. }
  381. #if UNITY_EDITOR
  382. bool warn_test = false;
  383. void Update() {
  384. if (!warn_test) {
  385. warn_test = true;
  386. Debug.LogWarning("F3-重置设备校准引导,规则引导");
  387. Debug.LogWarning("F4-重置新手引导记录");
  388. }
  389. if (Input.GetKeyDown(KeyCode.F3)) {
  390. Debug.Log("重置设备校准引导,规则引导");
  391. AimHandler.ins.MagCalibrater = new o0._9Axis.MagnetometerAutoCalibrater();
  392. UserSettings.ins.deviceCalibrateGuideFinish = false;
  393. UserSettings.ins.gameRuleGuideFinish = new HashSet<int>();
  394. }
  395. if (Input.GetKeyDown(KeyCode.F4)) {
  396. Debug.Log("重置新手引导记录");
  397. SaveUserGuideFinished(false);
  398. }
  399. }
  400. #endif
  401. private Dictionary<string, NewUserGuiderConfig> configs = new Dictionary<string, NewUserGuiderConfig>();
  402. private bool configsInited = false;
  403. [SerializeField] public string curConfigKey = "模块开机";
  404. private List<string> configKeyList = new List<string>(new string[]{
  405. "模块开机",
  406. "连接设备",
  407. "弓箭详情",
  408. "设备-陀螺仪校准",
  409. "设备-地磁计校准",
  410. "查看设置",
  411. "查看商城",
  412. "切换好友/排行榜",
  413. "展开好友/排行榜",
  414. "联机游戏",
  415. "开始游戏",
  416. "开始-限时游戏",
  417. "限时游戏-选择距离",
  418. "视角归位-触发",
  419. "视角归位-瞄准",
  420. "教程结束",
  421. });
  422. void ExecuteCurConfig() {
  423. InitConfigs();
  424. NewUserGuiderConfig config = configs[curConfigKey];
  425. NewUserGuider guider = Instantiate(prefab_NewUserGuider).GetComponent<NewUserGuider>();
  426. guider.config = config;
  427. }
  428. public void OnClickedDestroyed(string configKey) {
  429. int nextIndex = configKeyList.IndexOf(configKey) + 1;
  430. if (nextIndex >= configKeyList.Count) return;
  431. curConfigKey = configKeyList[nextIndex];
  432. ExecuteCurConfig();
  433. }
  434. }
  435. public class NewUserGuiderConfig
  436. {
  437. public string key;
  438. //0:position,1:anchoredPosition
  439. public int hitPosType = 0;
  440. public Vector2 hitPos;
  441. public bool hitActive = true;
  442. //icon pointer rotation z
  443. public float pointerRotZ;
  444. public int pointerPosType = 0;
  445. public Vector2 pointerPos;
  446. public bool pointerActive = true;
  447. //frameTip-Pivot l:left,r:right,t:top,b:bottom,ct:center
  448. public string frameTipPivot = "lt";
  449. public int frameTipPosType = 0;
  450. public Vector2 frameTipPos;
  451. //frameTip text
  452. public string frameTipText = null;
  453. public string frameTipTextKey = null;
  454. public Action<NewUserGuider> onPrepare;
  455. public Action<NewUserGuider> onStart;
  456. }