1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
|
using System;
using UILib;
using UnityEngine;
using XMainClient.UI;
using XMainClient.UI.UICommon;
using XUpdater;
using XUtliPoolLib;
namespace XMainClient
{
internal class XCommandNoforceClick : XBaseCommand
{
private GameObject _finger;
private int orgWidth1;
private int orgHeight1;
private int orgWidth2;
private int orgHeight2;
public override bool Execute()
{
bool flag = this._cmd.param2 == "_canvas/SkillFrame/Skill0";
if (flag)
{
bool flag2 = DlgBase<BattleMain, BattleMainBehaviour>.singleton.IsLoaded();
if (flag2)
{
DlgBase<BattleMain, BattleMainBehaviour>.singleton.SkillHandler.AlwaysHot(0, true);
}
XSingleton<XEntityMgr>.singleton.Player.Skill.EndSkill(true, false);
}
Transform transform = XSingleton<XGameUI>.singleton.UIRoot.Find(this._cmd.param1 + "(Clone)");
bool flag3 = !transform || !transform.gameObject.activeInHierarchy;
bool result;
if (flag3)
{
result = false;
}
else
{
Transform transform2 = XSingleton<UiUtility>.singleton.FindChild(transform, this._cmd.param2);
bool flag4 = transform2 == null || !transform2.gameObject.activeInHierarchy;
if (flag4)
{
bool flag5 = transform2 == null && this._cmd.isOutError;
if (flag5)
{
this._cmd.isOutError = false;
XSingleton<XDebug>.singleton.AddErrorLog(string.Concat(new object[]
{
"TutorialId:",
this._cmd.TutorialID,
" Configuration File Path Error! tag:",
this._cmd.tag,
"\nPath:",
this._cmd.param1,
"(Clone)/",
this._cmd.param2
}), null, null, null, null, null);
}
result = false;
}
else
{
this._startTime = Time.time;
bool flag6 = this._finger == null;
if (flag6)
{
this._finger = (XSingleton<XResourceLoaderMgr>.singleton.CreateFromPrefab("UI/Common/Quan", true, false) as GameObject);
}
bool flag7 = this._cmd.param3 != null;
if (flag7)
{
float num = float.Parse(this._cmd.param3);
bool flag8 = num >= 0f;
if (flag8)
{
IXUISprite ixuisprite = this._finger.transform.Find("Quan1").GetComponent("XUISprite") as IXUISprite;
this.orgWidth1 = ixuisprite.spriteWidth;
this.orgHeight1 = ixuisprite.spriteHeight;
ixuisprite.spriteWidth = (int)((float)ixuisprite.spriteWidth * num);
ixuisprite.spriteHeight = (int)((float)ixuisprite.spriteHeight * num);
}
}
bool flag9 = this._cmd.param4 != null;
if (flag9)
{
float num2 = float.Parse(this._cmd.param4);
bool flag10 = num2 >= 0f;
if (flag10)
{
IXUISprite ixuisprite2 = this._finger.transform.Find("Quan2").GetComponent("XUISprite") as IXUISprite;
this.orgWidth2 = ixuisprite2.spriteWidth;
this.orgHeight2 = ixuisprite2.spriteHeight;
ixuisprite2.spriteWidth = (int)((float)ixuisprite2.spriteWidth * num2);
ixuisprite2.spriteHeight = (int)((float)ixuisprite2.spriteHeight * num2);
}
}
IXUIObject ixuiobject = transform2.GetComponent("XUIObject") as IXUIObject;
ixuiobject.Exculsive = true;
XSingleton<UiUtility>.singleton.AddChild(transform2, this._finger.transform);
bool flag11 = this._cmd.param5 == null;
if (flag11)
{
this._cmd.param5 = "0";
}
bool flag12 = this._cmd.param6 == null;
if (flag12)
{
this._cmd.param6 = "0";
}
this._finger.transform.localPosition += new Vector3(float.Parse(this._cmd.param5), float.Parse(this._cmd.param6), 0f);
this._finger.SetActive(false);
this._finger.SetActive(true);
base.SetTutorialText(this._cmd.textPos, transform2);
base.SetButtomText();
base.SetAilin();
bool pause = this._cmd.pause;
if (pause)
{
XSingleton<XShell>.singleton.Pause = true;
}
XSingleton<XTutorialMgr>.singleton.NoforceClick = true;
base.publicModule();
result = true;
}
}
return result;
}
public override void OnFinish()
{
this.Stop();
}
public override void Stop()
{
bool flag = this._finger != null;
if (flag)
{
bool flag2 = this._cmd.param3 != null;
if (flag2)
{
IXUISprite ixuisprite = this._finger.transform.Find("Quan1").GetComponent("XUISprite") as IXUISprite;
ixuisprite.spriteWidth = this.orgWidth1;
ixuisprite.spriteHeight = this.orgHeight1;
}
bool flag3 = this._cmd.param4 != null;
if (flag3)
{
IXUISprite ixuisprite2 = this._finger.transform.Find("Quan2").GetComponent("XUISprite") as IXUISprite;
ixuisprite2.spriteWidth = this.orgWidth2;
ixuisprite2.spriteHeight = this.orgHeight2;
}
XResourceLoaderMgr.SafeDestroy(ref this._finger, false);
}
base.DestroyAilin();
XSingleton<XShell>.singleton.Pause = false;
XSingleton<XTutorialMgr>.singleton.NoforceClick = false;
bool flag4 = DlgBase<BattleMain, BattleMainBehaviour>.singleton.IsLoaded() && DlgBase<BattleMain, BattleMainBehaviour>.singleton.SkillHandler != null;
if (flag4)
{
DlgBase<BattleMain, BattleMainBehaviour>.singleton.SkillHandler.AlwaysHot(0, false);
}
base.Stop();
}
}
}
|