Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Y
ygopro2
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Locked Files
Issues
0
Issues
0
List
Boards
Labels
Service Desk
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Security & Compliance
Security & Compliance
Dependency List
License Compliance
Packages
Packages
List
Container Registry
Analytics
Analytics
CI / CD
Code Review
Insights
Issues
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Xu Chenxi
ygopro2
Commits
7cdf01df
Commit
7cdf01df
authored
Apr 30, 2019
by
Unicorn369
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
支持使用自定义链接更换头像
parent
12876032
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
25 additions
and
17 deletions
+25
-17
Assets/SibylSystem/Servant.cs
Assets/SibylSystem/Servant.cs
+17
-9
Assets/transUI/prefab/trans_ES_face.prefab
Assets/transUI/prefab/trans_ES_face.prefab
+8
-8
No files found.
Assets/SibylSystem/Servant.cs
View file @
7cdf01df
...
...
@@ -392,12 +392,8 @@ public class Servant
public
string
currentMShash
;
public
string
nameFace
;
private
GameObject
currentMSwindow
=
null
;
private
GameObject
currentMSwindow_Face
=
null
;
public
class
messageSystemValue
{
public
string
value
=
""
;
...
...
@@ -769,6 +765,12 @@ public class Servant
Program
.
I
().
cardDescription
.
mLog
(
hint
);
}
UIInput
inputUrl
;
public
string
nameFace
;
private
GameObject
currentMSwindow_Face
=
null
;
public
void
RMSshow_face
(
string
hashCode
,
string
name
)
{
RMSshow_clear
();
...
...
@@ -787,6 +789,7 @@ public class Servant
nameFace
=
name
;
currentMSwindow_Face
=
currentMSwindow
;
UIHelper
.
InterGameObject
(
currentMSwindow
);
inputUrl
=
UIHelper
.
getByName
<
UIInput
>(
currentMSwindow
,
"input_"
);
UIHelper
.
getByName
<
UITexture
>(
currentMSwindow
,
"face_"
).
mainTexture
=
UIHelper
.
getFace
(
name
);
UIHelper
.
registEvent
(
currentMSwindow
,
"exit_"
,
ES_RMSpremono
,
new
messageSystemValue
());
UIHelper
.
registEvent
(
currentMSwindow
,
"yes_"
,
DownloadFace
);
...
...
@@ -794,14 +797,19 @@ public class Servant
public
void
DownloadFace
()
{
//获取QQ号
UIInput
inputHttp
=
UIHelper
.
getByName
<
UIInput
>(
currentMSwindow_Face
,
"input_"
);
//如果使用自定义url,而不是QQ头像,请修改url,改为:string url = inputHttp.value;
string
url
=
"http://q1.qlogo.cn/headimg_dl?dst_uin="
+
inputHttp
.
value
+
"&spec=100"
;
string
url
=
"http://q1.qlogo.cn/headimg_dl?dst_uin="
+
inputUrl
.
value
+
"&spec=100"
;
string
face
=
"texture/face/"
+
nameFace
+
".jpg"
;
//开始下载
HttpDldFile
df
=
new
HttpDldFile
();
df
.
Download
(
url
,
face
);
if
(
inputUrl
.
value
.
Substring
(
0
,
4
)
==
"http"
)
{
url
=
inputUrl
.
value
;
df
.
Download
(
url
,
face
);
//使用自定义Url
}
else
{
df
.
Download
(
url
,
face
);
//使用QQ头像
}
//刷新头像
if
(
File
.
Exists
(
face
))
{
...
...
Assets/transUI/prefab/trans_ES_face.prefab
View file @
7cdf01df
...
...
@@ -890,7 +890,7 @@ Transform:
m_PrefabInternal
:
{
fileID
:
100100000
}
m_GameObject
:
{
fileID
:
1720769508036278
}
m_LocalRotation
:
{
x
:
0
,
y
:
0
,
z
:
0
,
w
:
1
}
m_LocalPosition
:
{
x
:
-
14
0
,
y
:
12
,
z
:
0
}
m_LocalPosition
:
{
x
:
-
20
0
,
y
:
12
,
z
:
0
}
m_LocalScale
:
{
x
:
1
,
y
:
1
,
z
:
1
}
m_Children
:
[]
m_Father
:
{
fileID
:
4473934484648920
}
...
...
@@ -919,7 +919,7 @@ BoxCollider:
m_IsTrigger
:
1
m_Enabled
:
1
serializedVersion
:
2
m_Size
:
{
x
:
28
0
,
y
:
40
,
z
:
0
}
m_Size
:
{
x
:
40
0
,
y
:
40
,
z
:
0
}
m_Center
:
{
x
:
0
,
y
:
0
,
z
:
0
}
---
!u!65
&65634783695434124
BoxCollider
:
...
...
@@ -978,13 +978,13 @@ MonoBehaviour:
updateAnchors
:
1
mColor
:
{
r
:
1
,
g
:
1
,
b
:
1
,
a
:
1
}
mPivot
:
4
mWidth
:
28
0
mWidth
:
40
0
mHeight
:
40
mDepth
:
30
autoResizeBoxCollider
:
1
hideIfOffScreen
:
0
keepAspectRatio
:
0
aspectRatio
:
7
aspectRatio
:
10
mType
:
1
mFillDirection
:
4
mFillAmount
:
1
...
...
@@ -1014,7 +1014,7 @@ MonoBehaviour:
onReturnKey
:
0
keyboardType
:
0
hideInput
:
0
validation
:
1
validation
:
0
characterLimit
:
0
savedAs
:
selectOnTab
:
{
fileID
:
0
}
...
...
@@ -1135,17 +1135,17 @@ MonoBehaviour:
updateAnchors
:
1
mColor
:
{
r
:
1
,
g
:
1
,
b
:
1
,
a
:
0.40392157
}
mPivot
:
0
mWidth
:
28
0
mWidth
:
40
0
mHeight
:
32
mDepth
:
21
autoResizeBoxCollider
:
0
hideIfOffScreen
:
0
keepAspectRatio
:
0
aspectRatio
:
8.7
5
aspectRatio
:
12.
5
keepCrispWhenShrunk
:
1
mTrueTypeFont
:
{
fileID
:
12800000
,
guid
:
f775853fdfd14bb47934543e95c3bae3
,
type
:
3
}
mFont
:
{
fileID
:
0
}
mText
:
"
\u5728\u6B64\u8F93\u5165
QQ
\u53F7
"
mText
:
"
QQ
\u53F7
\u6216
\u56FE\u7247\u94FE\u63A5
"
mFontSize
:
27
mFontStyle
:
0
mAlignment
:
2
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment