Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Sign in / Register
Toggle navigation
F
First_FKQCW
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Packages
Packages
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
王雪伟
First_FKQCW
Commits
fbdf378f
Commit
fbdf378f
authored
May 14, 2021
by
zxhljwl
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
修改
parent
48e8c2af
Expand all
Show whitespace changes
Inline
Side-by-side
Showing
12 changed files
with
323 additions
and
177 deletions
+323
-177
WithdrawShopItem.prefab
Assets/Game/Main/Prefabs/WithdrawShopItem.prefab
+56
-1
CrazyCar.unity
Assets/Game/Main/Scenes/CrazyCar.unity
+117
-133
TomorrowWithdrawBean.cs
Assets/Game/Main/Scripts/Model/TomorrowWithdrawBean.cs
+10
-0
TomorrowWithdrawBean.cs.meta
Assets/Game/Main/Scripts/Model/TomorrowWithdrawBean.cs.meta
+1
-1
WithdrawShopBean.cs
Assets/Game/Main/Scripts/Model/WithdrawShopBean.cs
+19
-0
WithdrawShopBean.cs.meta
Assets/Game/Main/Scripts/Model/WithdrawShopBean.cs.meta
+11
-0
TomorrowWithdrawDialog.cs
Assets/Game/Main/Scripts/View/TomorrowWithdrawDialog.cs
+18
-3
WithdrawShopControl.cs
Assets/Game/Main/Scripts/View/WithdrawShopControl.cs
+51
-0
WithdrawShopControl.cs.meta
Assets/Game/Main/Scripts/View/WithdrawShopControl.cs.meta
+11
-0
WithdrawShopDialog.cs
Assets/Game/Main/Scripts/View/WithdrawShopDialog.cs
+0
-39
WithdrawShopItem.cs
Assets/Game/Main/Scripts/View/WithdrawShopItem.cs
+18
-0
WithdrawShopItem.cs.meta
Assets/Game/Main/Scripts/View/WithdrawShopItem.cs.meta
+11
-0
No files found.
Assets/Game/Main/Prefabs/WithdrawShopItem.prefab
View file @
fbdf378f
...
@@ -242,7 +242,7 @@ GameObject:
...
@@ -242,7 +242,7 @@ GameObject:
-
component
:
{
fileID
:
3429054282211219241
}
-
component
:
{
fileID
:
3429054282211219241
}
-
component
:
{
fileID
:
3429054282211219240
}
-
component
:
{
fileID
:
3429054282211219240
}
m_Layer
:
5
m_Layer
:
5
m_Name
:
Text
m_Name
:
pb
Text
m_TagString
:
Untagged
m_TagString
:
Untagged
m_Icon
:
{
fileID
:
0
}
m_Icon
:
{
fileID
:
0
}
m_NavMeshLayer
:
0
m_NavMeshLayer
:
0
...
@@ -546,6 +546,7 @@ GameObject:
...
@@ -546,6 +546,7 @@ GameObject:
-
component
:
{
fileID
:
165009045593183178
}
-
component
:
{
fileID
:
165009045593183178
}
-
component
:
{
fileID
:
8678038750356840716
}
-
component
:
{
fileID
:
8678038750356840716
}
-
component
:
{
fileID
:
3843624365719166492
}
-
component
:
{
fileID
:
3843624365719166492
}
-
component
:
{
fileID
:
7977656313966607230
}
m_Layer
:
5
m_Layer
:
5
m_Name
:
button
m_Name
:
button
m_TagString
:
Untagged
m_TagString
:
Untagged
...
@@ -611,3 +612,57 @@ MonoBehaviour:
...
@@ -611,3 +612,57 @@ MonoBehaviour:
m_FillOrigin
:
0
m_FillOrigin
:
0
m_UseSpriteMesh
:
0
m_UseSpriteMesh
:
0
m_PixelsPerUnitMultiplier
:
1
m_PixelsPerUnitMultiplier
:
1
---
!u!114
&7977656313966607230
MonoBehaviour
:
m_ObjectHideFlags
:
0
m_CorrespondingSourceObject
:
{
fileID
:
0
}
m_PrefabInstance
:
{
fileID
:
0
}
m_PrefabAsset
:
{
fileID
:
0
}
m_GameObject
:
{
fileID
:
7109538115322957954
}
m_Enabled
:
1
m_EditorHideFlags
:
0
m_Script
:
{
fileID
:
11500000
,
guid
:
4e29b1a8efbd4b44bb3f3716e73f07ff
,
type
:
3
}
m_Name
:
m_EditorClassIdentifier
:
m_Navigation
:
m_Mode
:
3
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
:
3843624365719166492
}
m_OnClick
:
m_PersistentCalls
:
m_Calls
:
-
m_Target
:
{
fileID
:
0
}
m_MethodName
:
m_Mode
:
1
m_Arguments
:
m_ObjectArgument
:
{
fileID
:
0
}
m_ObjectArgumentAssemblyTypeName
:
m_IntArgument
:
0
m_FloatArgument
:
0
m_StringArgument
:
m_BoolArgument
:
0
m_CallState
:
2
Assets/Game/Main/Scenes/CrazyCar.unity
View file @
fbdf378f
This diff is collapsed.
Click to expand it.
Assets/Game/Main/Scripts/Model/TomorrowWithdrawBean.cs
0 → 100644
View file @
fbdf378f
public
class
TomorrowWithdrawBean
{
public
int
max
;
public
string
maxStr
;
public
int
now
;
public
string
nowStr
;
public
string
title
;
public
string
text
;
public
int
status
;
}
Assets/Game/Main/Scripts/
View/WithdrawShopDialog
.cs.meta
→
Assets/Game/Main/Scripts/
Model/TomorrowWithdrawBean
.cs.meta
View file @
fbdf378f
fileFormatVersion: 2
fileFormatVersion: 2
guid:
e937aa80eb39a4845884dcb7aa183ccb
guid:
535cf9f747f49c14a849816aa5ffb1e3
MonoImporter:
MonoImporter:
externalObjects: {}
externalObjects: {}
serializedVersion: 2
serializedVersion: 2
...
...
Assets/Game/Main/Scripts/Model/WithdrawShopBean.cs
0 → 100644
View file @
fbdf378f
using
System.Collections.Generic
;
public
class
WithdrawShopBean
{
public
List
<
WD
>
upgradeWdList
;
public
class
WD
{
public
int
id
;
public
string
showCash
;
public
ProgressData
progressData
;
}
public
class
ProgressData
{
public
string
title
;
public
int
currentProgress
;
public
int
maxProgress
;
}
}
Assets/Game/Main/Scripts/Model/WithdrawShopBean.cs.meta
0 → 100644
View file @
fbdf378f
fileFormatVersion: 2
guid: fe1fe5654b3ff8341a8cf34cb10fc495
MonoImporter:
externalObjects: {}
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {instanceID: 0}
userData:
assetBundleName:
assetBundleVariant:
Assets/Game/Main/Scripts/View/TomorrowWithdrawDialog.cs
View file @
fbdf378f
...
@@ -7,6 +7,8 @@ public class TomorrowWithdrawDialog : MonoBehaviour
...
@@ -7,6 +7,8 @@ public class TomorrowWithdrawDialog : MonoBehaviour
public
Text
contentText
,
pbText
;
public
Text
contentText
,
pbText
;
public
Image
pb
,
button
;
public
Image
pb
,
button
;
public
Sprite
[]
buttonImages
;
public
Sprite
[]
buttonImages
;
public
TomorrowWithdrawBean
mData
;
void
OnEnable
()
void
OnEnable
()
{
{
...
@@ -18,10 +20,14 @@ public class TomorrowWithdrawDialog : MonoBehaviour
...
@@ -18,10 +20,14 @@ public class TomorrowWithdrawDialog : MonoBehaviour
/// </summary>
/// </summary>
private
void
GetTomorrowWithdrawData
()
private
void
GetTomorrowWithdrawData
()
{
{
HttpTool
.
Instance
.
_Get
(
"app/v1/game/module/withdrawTomorrow"
,
null
,
new
Action
<
Empty
Bean
>((
bean
)
=>
HttpTool
.
Instance
.
_Get
(
"app/v1/game/module/withdrawTomorrow"
,
null
,
new
Action
<
TomorrowWithdraw
Bean
>((
bean
)
=>
{
{
if
(
null
!=
bean
)
{
if
(
null
!=
bean
)
{
contentText
.
text
=
bean
.
text
;
pb
.
fillAmount
=
(
float
)
Math
.
Round
(((
decimal
)
bean
.
now
/
bean
.
max
),
2
);
pbText
.
text
=
bean
.
nowStr
+
"/"
+
bean
.
maxStr
;
button
.
sprite
=
buttonImages
[
bean
.
status
];
this
.
mData
=
bean
;
}
}
}),
new
Action
<
string
,
string
>((
code
,
errMsg
)
=>
}),
new
Action
<
string
,
string
>((
code
,
errMsg
)
=>
{
{
...
@@ -34,6 +40,15 @@ public class TomorrowWithdrawDialog : MonoBehaviour
...
@@ -34,6 +40,15 @@ public class TomorrowWithdrawDialog : MonoBehaviour
*/
*/
public
void
withdraw
()
public
void
withdraw
()
{
{
HttpTool
.
Instance
.
_Post
(
"app/v1/game/module/withdrawTomorrow/wd"
,
null
,
new
Action
<
EmptyBean
>((
bean
)
=>
{
if
(
null
!=
bean
)
{
GameObject
.
Find
(
"Dialog"
).
GetComponent
<
DialogControl
>().
closeTomorrowWithdrawDialog
();
}
}),
new
Action
<
string
,
string
>((
code
,
errMsg
)
=>
{
Debug
.
unityLogger
.
Log
(
"Get 请求失败"
+
code
+
errMsg
);
}));
}
}
}
}
Assets/Game/Main/Scripts/View/WithdrawShopControl.cs
0 → 100644
View file @
fbdf378f
using
System
;
using
System.Collections.Generic
;
using
UnityEngine
;
public
class
WithdrawShopControl
:
MonoBehaviour
{
public
GameObject
item
;
public
void
OnEnable
()
{
getEverydayTaskList
();
}
/**
* 获取提现商店列表
*/
public
void
getEverydayTaskList
()
{
HttpTool
.
Instance
.
_Get
(
"app/v3/game/fkqcw/wd/info"
,
null
,
new
Action
<
WithdrawShopBean
>((
bean
)
=>
{
print
(
"请求成功==================: "
);
if
(
null
!=
bean
)
{
initData
(
bean
.
upgradeWdList
);
}
}),
new
Action
<
string
,
string
>((
code
,
errMsg
)
=>
{
print
(
"请求失败================="
);
Debug
.
unityLogger
.
Log
(
"Get 请求失败"
+
code
+
errMsg
);
}));
}
public
void
initData
(
List
<
WithdrawShopBean
.
WD
>
list
)
{
print
(
"1"
);
for
(
int
i
=
0
;
i
<
transform
.
childCount
;
i
++)
{
Destroy
(
transform
.
GetChild
(
i
).
gameObject
);
}
print
(
"2"
);
for
(
int
i
=
0
;
i
<
list
.
Count
;
i
++)
{
print
(
"3"
);
GameObject
game
=
Instantiate
(
item
,
transform
);
game
.
name
=
""
+
i
;
//game.GetComponent<TaskItemControl>().taskType = tabPosition;
game
.
GetComponent
<
WithdrawShopItem
>().
setItemData
(
list
[
i
]);
}
}
}
Assets/Game/Main/Scripts/View/WithdrawShopControl.cs.meta
0 → 100644
View file @
fbdf378f
fileFormatVersion: 2
guid: 4922b2a2f003a0a44894ee017008bdbc
MonoImporter:
externalObjects: {}
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {instanceID: 0}
userData:
assetBundleName:
assetBundleVariant:
Assets/Game/Main/Scripts/View/WithdrawShopDialog.cs
deleted
100644 → 0
View file @
48e8c2af
using
System
;
using
UnityEngine
;
using
UnityEngine.UI
;
public
class
WithdrawShopDialog
:
MonoBehaviour
{
public
Text
contentText
,
pbText
;
public
Image
pb
,
button
;
public
Sprite
[]
buttonImages
;
void
OnEnable
()
{
GetTomorrowWithdrawData
();
}
/// <summary>
/// 获取明日提钱罐数据
/// </summary>
private
void
GetTomorrowWithdrawData
()
{
HttpTool
.
Instance
.
_Get
(
"app/v1/game/module/withdrawTomorrow"
,
null
,
new
Action
<
EmptyBean
>((
bean
)
=>
{
if
(
null
!=
bean
)
{
}
}),
new
Action
<
string
,
string
>((
code
,
errMsg
)
=>
{
Debug
.
unityLogger
.
Log
(
"Get 请求失败"
+
code
+
errMsg
);
}));
}
/**
* 提现
*/
public
void
withdraw
()
{
}
}
Assets/Game/Main/Scripts/View/WithdrawShopItem.cs
0 → 100644
View file @
fbdf378f
using
System
;
using
UnityEngine
;
using
UnityEngine.UI
;
public
class
WithdrawShopItem
:
MonoBehaviour
{
public
Text
title
,
pbText
,
buttonText
;
public
Image
pb
;
public
void
setItemData
(
WithdrawShopBean
.
WD
data
)
{
title
.
text
=
data
.
progressData
.
title
;
pbText
.
text
=
data
.
progressData
.
currentProgress
+
"/"
+
data
.
progressData
.
maxProgress
;
buttonText
.
text
=
data
.
showCash
;
pb
.
fillAmount
=
(
float
)
Math
.
Round
(((
decimal
)
data
.
progressData
.
currentProgress
/
data
.
progressData
.
maxProgress
),
2
);
}
}
Assets/Game/Main/Scripts/View/WithdrawShopItem.cs.meta
0 → 100644
View file @
fbdf378f
fileFormatVersion: 2
guid: 01828f63f9434aa48adf1e8a049791bd
MonoImporter:
externalObjects: {}
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {instanceID: 0}
userData:
assetBundleName:
assetBundleVariant:
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