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
473f69ef
Commit
473f69ef
authored
May 19, 2021
by
maxiaoliang
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
修改动画效果和ui
parent
eefe9b12
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
21 changed files
with
539 additions
and
54 deletions
+539
-54
bg.anim
Assets/Game/Main/Animation/bg.anim
+12
-12
light.anim
Assets/Game/Main/Animation/light.anim
+2
-2
字魂151号-联盟综艺体的副本_min.ttf
Assets/Game/Main/Font/字魂151号-联盟综艺体的副本_min.ttf
+0
-0
字魂151号-联盟综艺体的副本_min.ttf.meta
Assets/Game/Main/Font/字魂151号-联盟综艺体的副本_min.ttf.meta
+22
-0
Car.prefab
Assets/Game/Main/Prefabs/Car.prefab
+4
-4
我的司机(1).png
Assets/Game/Main/Resource/Home/我的司机(1).png
+0
-0
组 5135.png
Assets/Game/Main/Resource/Home/组 5135.png
+0
-0
组 5164-2.png
Assets/Game/Main/Resource/Home/组 5164-2.png
+0
-0
组 5164-2.png.meta
Assets/Game/Main/Resource/Home/组 5164-2.png.meta
+1
-1
组 5165.png
Assets/Game/Main/Resource/Home/组 5165.png
+0
-0
组 5165.png.meta
Assets/Game/Main/Resource/Home/组 5165.png.meta
+1
-1
雇佣司机.png
Assets/Game/Main/Resource/Home/雇佣司机.png
+0
-0
雇佣司机.png.meta
Assets/Game/Main/Resource/Home/雇佣司机.png.meta
+92
-0
CrazyCar.unity
Assets/Game/Main/Scenes/CrazyCar.unity
+331
-29
MyEventType.cs
Assets/Game/Main/Scripts/EventUtil/MyEventType.cs
+2
-0
DialogControl.cs
Assets/Game/Main/Scripts/View/DialogControl.cs
+1
-0
DoubleIncomeDialog.cs
Assets/Game/Main/Scripts/View/DoubleIncomeDialog.cs
+1
-1
GoldInsufficientControl.cs
Assets/Game/Main/Scripts/View/GoldInsufficientControl.cs
+1
-0
HomeInfoControl.cs
Assets/Game/Main/Scripts/View/HomeInfoControl.cs
+29
-4
HomeFlyCoin.cs
Assets/Game/Main/Scripts/animation/HomeFlyCoin.cs
+29
-0
HomeFlyCoin.cs.meta
Assets/Game/Main/Scripts/animation/HomeFlyCoin.cs.meta
+11
-0
No files found.
Assets/Game/Main/Animation/bg.anim
View file @
473f69ef
...
@@ -30,7 +30,7 @@ AnimationClip:
...
@@ -30,7 +30,7 @@ AnimationClip:
inWeight
:
0.33333334
inWeight
:
0.33333334
outWeight
:
0.33333334
outWeight
:
0.33333334
-
serializedVersion
:
3
-
serializedVersion
:
3
time
:
1
time
:
2
value
:
1
value
:
1
inSlope
:
0
inSlope
:
0
outSlope
:
0
outSlope
:
0
...
@@ -58,7 +58,7 @@ AnimationClip:
...
@@ -58,7 +58,7 @@ AnimationClip:
inWeight
:
0.33333334
inWeight
:
0.33333334
outWeight
:
0.33333334
outWeight
:
0.33333334
-
serializedVersion
:
3
-
serializedVersion
:
3
time
:
1
time
:
2
value
:
1
value
:
1
inSlope
:
0
inSlope
:
0
outSlope
:
0
outSlope
:
0
...
@@ -86,7 +86,7 @@ AnimationClip:
...
@@ -86,7 +86,7 @@ AnimationClip:
inWeight
:
0.33333334
inWeight
:
0.33333334
outWeight
:
0.33333334
outWeight
:
0.33333334
-
serializedVersion
:
3
-
serializedVersion
:
3
time
:
1
time
:
2
value
:
1
value
:
1
inSlope
:
0
inSlope
:
0
outSlope
:
0
outSlope
:
0
...
@@ -114,7 +114,7 @@ AnimationClip:
...
@@ -114,7 +114,7 @@ AnimationClip:
inWeight
:
0.33333334
inWeight
:
0.33333334
outWeight
:
0.33333334
outWeight
:
0.33333334
-
serializedVersion
:
3
-
serializedVersion
:
3
time
:
0.5
time
:
1
value
:
0
value
:
0
inSlope
:
0
inSlope
:
0
outSlope
:
0
outSlope
:
0
...
@@ -123,7 +123,7 @@ AnimationClip:
...
@@ -123,7 +123,7 @@ AnimationClip:
inWeight
:
0.33333334
inWeight
:
0.33333334
outWeight
:
0.33333334
outWeight
:
0.33333334
-
serializedVersion
:
3
-
serializedVersion
:
3
time
:
1
time
:
2
value
:
1
value
:
1
inSlope
:
0
inSlope
:
0
outSlope
:
0
outSlope
:
0
...
@@ -139,7 +139,7 @@ AnimationClip:
...
@@ -139,7 +139,7 @@ AnimationClip:
classID
:
114
classID
:
114
script
:
{
fileID
:
11500000
,
guid
:
fe87c0e1cc204ed48ad3b37840f39efc
,
type
:
3
}
script
:
{
fileID
:
11500000
,
guid
:
fe87c0e1cc204ed48ad3b37840f39efc
,
type
:
3
}
m_PPtrCurves
:
[]
m_PPtrCurves
:
[]
m_SampleRate
:
6
0
m_SampleRate
:
3
0
m_WrapMode
:
0
m_WrapMode
:
0
m_Bounds
:
m_Bounds
:
m_Center
:
{
x
:
0
,
y
:
0
,
z
:
0
}
m_Center
:
{
x
:
0
,
y
:
0
,
z
:
0
}
...
@@ -180,7 +180,7 @@ AnimationClip:
...
@@ -180,7 +180,7 @@ AnimationClip:
m_AdditiveReferencePoseClip
:
{
fileID
:
0
}
m_AdditiveReferencePoseClip
:
{
fileID
:
0
}
m_AdditiveReferencePoseTime
:
0
m_AdditiveReferencePoseTime
:
0
m_StartTime
:
0
m_StartTime
:
0
m_StopTime
:
1
m_StopTime
:
2
m_OrientationOffsetY
:
0
m_OrientationOffsetY
:
0
m_Level
:
0
m_Level
:
0
m_CycleOffset
:
0
m_CycleOffset
:
0
...
@@ -209,7 +209,7 @@ AnimationClip:
...
@@ -209,7 +209,7 @@ AnimationClip:
inWeight
:
0.33333334
inWeight
:
0.33333334
outWeight
:
0.33333334
outWeight
:
0.33333334
-
serializedVersion
:
3
-
serializedVersion
:
3
time
:
1
time
:
2
value
:
1
value
:
1
inSlope
:
0
inSlope
:
0
outSlope
:
0
outSlope
:
0
...
@@ -237,7 +237,7 @@ AnimationClip:
...
@@ -237,7 +237,7 @@ AnimationClip:
inWeight
:
0.33333334
inWeight
:
0.33333334
outWeight
:
0.33333334
outWeight
:
0.33333334
-
serializedVersion
:
3
-
serializedVersion
:
3
time
:
1
time
:
2
value
:
1
value
:
1
inSlope
:
0
inSlope
:
0
outSlope
:
0
outSlope
:
0
...
@@ -265,7 +265,7 @@ AnimationClip:
...
@@ -265,7 +265,7 @@ AnimationClip:
inWeight
:
0.33333334
inWeight
:
0.33333334
outWeight
:
0.33333334
outWeight
:
0.33333334
-
serializedVersion
:
3
-
serializedVersion
:
3
time
:
1
time
:
2
value
:
1
value
:
1
inSlope
:
0
inSlope
:
0
outSlope
:
0
outSlope
:
0
...
@@ -293,7 +293,7 @@ AnimationClip:
...
@@ -293,7 +293,7 @@ AnimationClip:
inWeight
:
0.33333334
inWeight
:
0.33333334
outWeight
:
0.33333334
outWeight
:
0.33333334
-
serializedVersion
:
3
-
serializedVersion
:
3
time
:
0.5
time
:
1
value
:
0
value
:
0
inSlope
:
0
inSlope
:
0
outSlope
:
0
outSlope
:
0
...
@@ -302,7 +302,7 @@ AnimationClip:
...
@@ -302,7 +302,7 @@ AnimationClip:
inWeight
:
0.33333334
inWeight
:
0.33333334
outWeight
:
0.33333334
outWeight
:
0.33333334
-
serializedVersion
:
3
-
serializedVersion
:
3
time
:
1
time
:
2
value
:
1
value
:
1
inSlope
:
0
inSlope
:
0
outSlope
:
0
outSlope
:
0
...
...
Assets/Game/Main/Animation/light.anim
View file @
473f69ef
...
@@ -22,7 +22,7 @@ AnimationClip:
...
@@ -22,7 +22,7 @@ AnimationClip:
m_Curve
:
m_Curve
:
-
serializedVersion
:
3
-
serializedVersion
:
3
time
:
0
time
:
0
value
:
-
6
2
value
:
-
20
2
inSlope
:
0
inSlope
:
0
outSlope
:
0
outSlope
:
0
tangentMode
:
136
tangentMode
:
136
...
@@ -235,7 +235,7 @@ AnimationClip:
...
@@ -235,7 +235,7 @@ AnimationClip:
m_Curve
:
m_Curve
:
-
serializedVersion
:
3
-
serializedVersion
:
3
time
:
0
time
:
0
value
:
-
6
2
value
:
-
20
2
inSlope
:
0
inSlope
:
0
outSlope
:
0
outSlope
:
0
tangentMode
:
136
tangentMode
:
136
...
...
Assets/Game/Main/Font/字魂151号-联盟综艺体的副本_min.ttf
0 → 100644
View file @
473f69ef
File added
Assets/Game/Main/Font/字魂151号-联盟综艺体的副本_min.ttf.meta
0 → 100644
View file @
473f69ef
fileFormatVersion: 2
guid: 7b14def5b10e64b8cb31a048c57ed8b1
TrueTypeFontImporter:
externalObjects: {}
serializedVersion: 4
fontSize: 16
forceTextureCase: -2
characterSpacing: 0
characterPadding: 1
includeFontData: 1
fontName: zihun151hao-lianmengzongyiti
fontNames:
- zihun151hao-lianmengzongyiti
fallbackFontReferences: []
customCharacters:
fontRenderingMode: 0
ascentCalculationMode: 1
useLegacyBoundsCalculation: 0
shouldRoundAdvanceValue: 1
userData:
assetBundleName:
assetBundleVariant:
Assets/Game/Main/Prefabs/Car.prefab
View file @
473f69ef
...
@@ -285,7 +285,7 @@ CanvasGroup:
...
@@ -285,7 +285,7 @@ CanvasGroup:
m_PrefabAsset
:
{
fileID
:
0
}
m_PrefabAsset
:
{
fileID
:
0
}
m_GameObject
:
{
fileID
:
455528767290619782
}
m_GameObject
:
{
fileID
:
455528767290619782
}
m_Enabled
:
1
m_Enabled
:
1
m_Alpha
:
0
m_Alpha
:
1
m_Interactable
:
1
m_Interactable
:
1
m_BlocksRaycasts
:
1
m_BlocksRaycasts
:
1
m_IgnoreParentGroups
:
0
m_IgnoreParentGroups
:
0
...
@@ -1389,7 +1389,7 @@ RectTransform:
...
@@ -1389,7 +1389,7 @@ RectTransform:
m_LocalEulerAnglesHint
:
{
x
:
0
,
y
:
0
,
z
:
0
}
m_LocalEulerAnglesHint
:
{
x
:
0
,
y
:
0
,
z
:
0
}
m_AnchorMin
:
{
x
:
0.5
,
y
:
0.5
}
m_AnchorMin
:
{
x
:
0.5
,
y
:
0.5
}
m_AnchorMax
:
{
x
:
0.5
,
y
:
0.5
}
m_AnchorMax
:
{
x
:
0.5
,
y
:
0.5
}
m_AnchoredPosition
:
{
x
:
0
,
y
:
-54.4
}
m_AnchoredPosition
:
{
x
:
-32
,
y
:
-36
}
m_SizeDelta
:
{
x
:
202
,
y
:
35
}
m_SizeDelta
:
{
x
:
202
,
y
:
35
}
m_Pivot
:
{
x
:
0.5
,
y
:
0.5
}
m_Pivot
:
{
x
:
0.5
,
y
:
0.5
}
---
!u!222
&455528768205073264
---
!u!222
&455528768205073264
...
@@ -1853,7 +1853,7 @@ GameObject:
...
@@ -1853,7 +1853,7 @@ GameObject:
m_Icon
:
{
fileID
:
0
}
m_Icon
:
{
fileID
:
0
}
m_NavMeshLayer
:
0
m_NavMeshLayer
:
0
m_StaticEditorFlags
:
0
m_StaticEditorFlags
:
0
m_IsActive
:
0
m_IsActive
:
1
---
!u!224
&259696605779131939
---
!u!224
&259696605779131939
RectTransform
:
RectTransform
:
m_ObjectHideFlags
:
0
m_ObjectHideFlags
:
0
...
@@ -1870,7 +1870,7 @@ RectTransform:
...
@@ -1870,7 +1870,7 @@ RectTransform:
m_LocalEulerAnglesHint
:
{
x
:
0
,
y
:
0
,
z
:
0
}
m_LocalEulerAnglesHint
:
{
x
:
0
,
y
:
0
,
z
:
0
}
m_AnchorMin
:
{
x
:
0.5
,
y
:
0.5
}
m_AnchorMin
:
{
x
:
0.5
,
y
:
0.5
}
m_AnchorMax
:
{
x
:
0.5
,
y
:
0.5
}
m_AnchorMax
:
{
x
:
0.5
,
y
:
0.5
}
m_AnchoredPosition
:
{
x
:
-2
,
y
:
14
}
m_AnchoredPosition
:
{
x
:
-2
,
y
:
27
}
m_SizeDelta
:
{
x
:
345
,
y
:
255
}
m_SizeDelta
:
{
x
:
345
,
y
:
255
}
m_Pivot
:
{
x
:
0.5
,
y
:
0.5
}
m_Pivot
:
{
x
:
0.5
,
y
:
0.5
}
---
!u!222
&5770000278109398240
---
!u!222
&5770000278109398240
...
...
Assets/Game/Main/Resource/Home/我的司机(1).png
deleted
100644 → 0
View file @
eefe9b12
3.05 KB
Assets/Game/Main/Resource/Home/组 5135.png
deleted
100644 → 0
View file @
eefe9b12
2.96 KB
Assets/Game/Main/Resource/Home/组 5164-2.png
0 → 100644
View file @
473f69ef
5.15 KB
Assets/Game/Main/Resource/Home/
我的司机(1)
.png.meta
→
Assets/Game/Main/Resource/Home/
组 5164-2
.png.meta
View file @
473f69ef
fileFormatVersion: 2
fileFormatVersion: 2
guid: 6
af2c582097d10e41b5b9f381f565c8c
guid: 6
4f547b0a25c64bd3b63eeba23a3ef4e
TextureImporter:
TextureImporter:
internalIDToNameTable: []
internalIDToNameTable: []
externalObjects: {}
externalObjects: {}
...
...
Assets/Game/Main/Resource/Home/组 5165.png
0 → 100644
View file @
473f69ef
6.83 KB
Assets/Game/Main/Resource/Home/组 51
3
5.png.meta
→
Assets/Game/Main/Resource/Home/组 51
6
5.png.meta
View file @
473f69ef
fileFormatVersion: 2
fileFormatVersion: 2
guid:
89b5232c116451f44b2f0e1a2e784b03
guid:
991244ea250af4b5aadfc583bf994e49
TextureImporter:
TextureImporter:
internalIDToNameTable: []
internalIDToNameTable: []
externalObjects: {}
externalObjects: {}
...
...
Assets/Game/Main/Resource/Home/雇佣司机.png
0 → 100644
View file @
473f69ef
7.38 KB
Assets/Game/Main/Resource/Home/雇佣司机.png.meta
0 → 100644
View file @
473f69ef
fileFormatVersion: 2
guid: 439b00e9d97554a1480582443b1cc5bc
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
grayScaleToAlpha: 0
generateCubemap: 6
cubemapConvolution: 0
seamlessCubemap: 0
textureFormat: 1
maxTextureSize: 2048
textureSettings:
serializedVersion: 2
filterMode: -1
aniso: -1
mipBias: -100
wrapU: 1
wrapV: 1
wrapW: 1
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
maxTextureSizeSet: 0
compressionQualitySet: 0
textureFormatSet: 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
spriteSheet:
serializedVersion: 2
sprites: []
outline: []
physicsShape: []
bones: []
spriteID: 5e97eb03825dee720800000000000000
internalID: 0
vertices: []
indices:
edges: []
weights: []
secondaryTextures: []
spritePackingTag:
pSDRemoveMatte: 0
pSDShowRemoveMatteOption: 0
userData:
assetBundleName:
assetBundleVariant:
Assets/Game/Main/Scenes/CrazyCar.unity
View file @
473f69ef
This diff is collapsed.
Click to expand it.
Assets/Game/Main/Scripts/EventUtil/MyEventType.cs
View file @
473f69ef
...
@@ -122,4 +122,6 @@ public enum MyEventType
...
@@ -122,4 +122,6 @@ public enum MyEventType
END_LAND_LIGHT
,
END_LAND_LIGHT
,
//单个车播放动画
//单个车播放动画
ONE_CAR_PLAY_ANIMAL
,
ONE_CAR_PLAY_ANIMAL
,
//获得金币飞动画
GET_COIN_FLY
,
}
}
Assets/Game/Main/Scripts/View/DialogControl.cs
View file @
473f69ef
...
@@ -280,6 +280,7 @@ public class DialogControl : MonoBehaviour
...
@@ -280,6 +280,7 @@ public class DialogControl : MonoBehaviour
rewardDialogObj
.
SetActive
(
false
);
rewardDialogObj
.
SetActive
(
false
);
AudioUtils
.
ins
.
PlayBtnAudio
();
AudioUtils
.
ins
.
PlayBtnAudio
();
AdUtils
.
CloseFeedAd
();
AdUtils
.
CloseFeedAd
();
EventCenter
.
Broadcast
(
MyEventType
.
GET_COIN_FLY
);
}
}
...
...
Assets/Game/Main/Scripts/View/DoubleIncomeDialog.cs
View file @
473f69ef
...
@@ -71,7 +71,7 @@ public class DoubleIncomeDialog : MonoBehaviour
...
@@ -71,7 +71,7 @@ public class DoubleIncomeDialog : MonoBehaviour
AdUtils
.
PlayRewardAd
(
"fkqcw_protection"
,
new
Action
<
bool
>((
cb
)
=>
AdUtils
.
PlayRewardAd
(
"fkqcw_protection"
,
new
Action
<
bool
>((
cb
)
=>
{
{
EventUtils
.
OnEvent
(
"rewardVideo_doubleIncome"
);
EventUtils
.
OnEvent
(
"rewardVideo_doubleIncome"
);
EventUtils
.
OnEvent
(
"
rewardVideo_all
"
);
EventUtils
.
OnEvent
(
"
doubling_reward
"
);
if
(
cb
)
if
(
cb
)
{
{
HttpTool
.
Instance
.
_Post
(
"app/v1/game/fkqcw/doubling/incr_time_by_video"
,
null
,
new
Action
<
VideoStatusBean
>((
bean
)
=>
HttpTool
.
Instance
.
_Post
(
"app/v1/game/fkqcw/doubling/incr_time_by_video"
,
null
,
new
Action
<
VideoStatusBean
>((
bean
)
=>
...
...
Assets/Game/Main/Scripts/View/GoldInsufficientControl.cs
View file @
473f69ef
...
@@ -23,6 +23,7 @@ public class GoldInsufficientControl : MonoBehaviour
...
@@ -23,6 +23,7 @@ public class GoldInsufficientControl : MonoBehaviour
HttpTool
.
Instance
.
_Post
(
"app/v3/game/fkqcw/parking/addCoin"
,
null
,
new
Action
<
WithdrawShopBean
>((
bean
)
=>
HttpTool
.
Instance
.
_Post
(
"app/v3/game/fkqcw/parking/addCoin"
,
null
,
new
Action
<
WithdrawShopBean
>((
bean
)
=>
{
{
GameObject
.
Find
(
"Dialog"
).
GetComponent
<
DialogControl
>().
closeGoldInsufficientDialog
();
GameObject
.
Find
(
"Dialog"
).
GetComponent
<
DialogControl
>().
closeGoldInsufficientDialog
();
EventCenter
.
Broadcast
(
MyEventType
.
GET_COIN_FLY
);
GameObject
.
Find
(
"Main"
).
GetComponent
<
HomeInfoControl
>().
OnUpdateCarListData
();
GameObject
.
Find
(
"Main"
).
GetComponent
<
HomeInfoControl
>().
OnUpdateCarListData
();
}),
new
Action
<
string
,
string
>((
code
,
errMsg
)
=>
}),
new
Action
<
string
,
string
>((
code
,
errMsg
)
=>
{
{
...
...
Assets/Game/Main/Scripts/View/HomeInfoControl.cs
View file @
473f69ef
...
@@ -21,7 +21,8 @@ public class HomeInfoControl : MonoBehaviour, HomeContract.View
...
@@ -21,7 +21,8 @@ public class HomeInfoControl : MonoBehaviour, HomeContract.View
public
RawImage
avatar
;
public
RawImage
avatar
;
public
GameObject
shouyi_animal
;
public
GameObject
shouyi_animal
;
public
GameObject
img_pig_cash_trips
;
public
GameObject
img_pig_cash_trips
;
public
GameObject
flycoin
;
public
GameObject
Protv
;
private
void
Awake
()
private
void
Awake
()
{
{
mPresenter
=
new
HomePresenter
(
this
);
mPresenter
=
new
HomePresenter
(
this
);
...
@@ -30,13 +31,33 @@ public class HomeInfoControl : MonoBehaviour, HomeContract.View
...
@@ -30,13 +31,33 @@ public class HomeInfoControl : MonoBehaviour, HomeContract.View
EventCenter
.
AddListener
<
int
>(
MyEventType
.
ADD_COIN
,
OnAddCoin
);
EventCenter
.
AddListener
<
int
>(
MyEventType
.
ADD_COIN
,
OnAddCoin
);
EventCenter
.
AddListener
(
MyEventType
.
START_DOUBLE_INCOME_ANIMATION
,
startDoubleIncomeAnimal
);
EventCenter
.
AddListener
(
MyEventType
.
START_DOUBLE_INCOME_ANIMATION
,
startDoubleIncomeAnimal
);
EventCenter
.
AddListener
(
MyEventType
.
STOP_DOUBLE_INCOME_ANIMATION
,
stoptDoubleIncomeAnimal
);
EventCenter
.
AddListener
(
MyEventType
.
STOP_DOUBLE_INCOME_ANIMATION
,
stoptDoubleIncomeAnimal
);
EventCenter
.
AddListener
(
MyEventType
.
GET_COIN_FLY
,
flyCoin
);
startCountDown
();
if
(
PrefenceUtils
.
GetInstance
().
getIsFirst
()
==
0
)
{
if
(
PrefenceUtils
.
GetInstance
().
getIsFirst
()
==
0
)
{
PrefenceUtils
.
GetInstance
().
setIsFirst
(
1
);
PrefenceUtils
.
GetInstance
().
setIsFirst
(
1
);
EventUtils
.
OnEvent
(
"home_first"
);
EventUtils
.
OnEvent
(
"home_first"
);
}
}
}
}
private
void
flyCoin
()
{
flycoin
.
SetActive
(
true
);
for
(
int
i
=
0
;
i
<
6
;
i
++)
{
StartCoroutine
(
MoveVideoRedPack
(
flycoin
.
transform
.
localPosition
,
i
*
0.2f
));
}
}
IEnumerator
MoveVideoRedPack
(
Vector3
vector3
,
float
v
)
{
yield
return
new
WaitForSeconds
(
v
);
GameObject
grid
=
Instantiate
(
flycoin
,
transform
);
grid
.
transform
.
SetAsLastSibling
();
grid
.
transform
.
localPosition
=
vector3
;
grid
.
GetComponent
<
HomeFlyCoin
>().
OnFlyRedBack
();
}
private
void
startDoubleIncomeAnimal
()
private
void
startDoubleIncomeAnimal
()
{
{
shouyi_animal
.
SetActive
(
true
);
shouyi_animal
.
SetActive
(
true
);
...
@@ -53,6 +74,7 @@ public class HomeInfoControl : MonoBehaviour, HomeContract.View
...
@@ -53,6 +74,7 @@ public class HomeInfoControl : MonoBehaviour, HomeContract.View
EventCenter
.
RemoveListener
<
int
>(
MyEventType
.
ADD_COIN
,
OnAddCoin
);
EventCenter
.
RemoveListener
<
int
>(
MyEventType
.
ADD_COIN
,
OnAddCoin
);
EventCenter
.
RemoveListener
(
MyEventType
.
START_DOUBLE_INCOME_ANIMATION
,
startDoubleIncomeAnimal
);
EventCenter
.
RemoveListener
(
MyEventType
.
START_DOUBLE_INCOME_ANIMATION
,
startDoubleIncomeAnimal
);
EventCenter
.
RemoveListener
(
MyEventType
.
STOP_DOUBLE_INCOME_ANIMATION
,
stoptDoubleIncomeAnimal
);
EventCenter
.
RemoveListener
(
MyEventType
.
STOP_DOUBLE_INCOME_ANIMATION
,
stoptDoubleIncomeAnimal
);
EventCenter
.
RemoveListener
(
MyEventType
.
GET_COIN_FLY
,
flyCoin
);
}
}
private
void
Start
()
private
void
Start
()
...
@@ -120,13 +142,12 @@ public class HomeInfoControl : MonoBehaviour, HomeContract.View
...
@@ -120,13 +142,12 @@ public class HomeInfoControl : MonoBehaviour, HomeContract.View
tvrewardCashEveryMinute
.
text
=
"约"
+
mCarInfo
.
rewardCashEveryMinute
.
ToString
()+
"元/分钟"
;
tvrewardCashEveryMinute
.
text
=
"约"
+
mCarInfo
.
rewardCashEveryMinute
.
ToString
()+
"元/分钟"
;
levelTv
.
text
=
"Lv:"
+
mCarInfo
.
levelProgress
.
level
;
levelTv
.
text
=
"Lv:"
+
mCarInfo
.
levelProgress
.
level
;
withdrawBoxText
.
text
=
mCarInfo
.
wdTitle
;
withdrawBoxText
.
text
=
mCarInfo
.
wdTitle
;
startCountDown
();
}
}
private
int
time
=
5
;
private
int
time
=
5
;
private
void
startCountDown
()
private
void
startCountDown
()
{
{
Debug
.
Log
(
"开始计时"
);
StartCoroutine
(
showPigTrip
());
StartCoroutine
(
showPigTrip
());
}
}
...
@@ -167,6 +188,7 @@ public class HomeInfoControl : MonoBehaviour, HomeContract.View
...
@@ -167,6 +188,7 @@ public class HomeInfoControl : MonoBehaviour, HomeContract.View
if
(
protectionTime
>
0
)
if
(
protectionTime
>
0
)
{
{
procetTimeObj
.
SetActive
(
true
);
procetTimeObj
.
SetActive
(
true
);
Protv
.
SetActive
(
false
);
proTimerTv
.
text
=
UnityUtil
.
getCountdown
(
protectionTime
);
proTimerTv
.
text
=
UnityUtil
.
getCountdown
(
protectionTime
);
protionControl
=
StartCoroutine
(
IEProctionIimer
());
protionControl
=
StartCoroutine
(
IEProctionIimer
());
...
@@ -174,6 +196,7 @@ public class HomeInfoControl : MonoBehaviour, HomeContract.View
...
@@ -174,6 +196,7 @@ public class HomeInfoControl : MonoBehaviour, HomeContract.View
else
else
{
{
procetTimeObj
.
SetActive
(
false
);
procetTimeObj
.
SetActive
(
false
);
Protv
.
SetActive
(
true
);
}
}
}
}
...
@@ -186,12 +209,14 @@ public class HomeInfoControl : MonoBehaviour, HomeContract.View
...
@@ -186,12 +209,14 @@ public class HomeInfoControl : MonoBehaviour, HomeContract.View
{
{
procetTimeObj
.
SetActive
(
false
);
procetTimeObj
.
SetActive
(
false
);
Protv
.
SetActive
(
true
);
EventCenter
.
Broadcast
(
MyEventType
.
CLOSE_PROCTION
);
EventCenter
.
Broadcast
(
MyEventType
.
CLOSE_PROCTION
);
StopCoroutine
(
protionControl
);
StopCoroutine
(
protionControl
);
break
;
break
;
}
}
else
else
{
{
protectionTime
--;
protectionTime
--;
proTimerTv
.
text
=
UnityUtil
.
getCountdown
(
protectionTime
);
proTimerTv
.
text
=
UnityUtil
.
getCountdown
(
protectionTime
);
}
}
...
...
Assets/Game/Main/Scripts/animation/HomeFlyCoin.cs
0 → 100644
View file @
473f69ef
using
System.Collections
;
using
System.Collections.Generic
;
using
DG.Tweening
;
using
UnityEngine
;
public
class
HomeFlyCoin
:
MonoBehaviour
{
public
GameObject
targetObj
;
//飞行目标
public
GameObject
highcavs
;
public
GameObject
lowcavs
;
public
void
OnFlyRedBack
()
{
transform
.
parent
=
highcavs
.
transform
.
parent
;
transform
.
DOMove
(
targetObj
.
transform
.
position
,
0.8f
).
OnComplete
(
AnimEnd
);
//GameObject.Find("Music_Background").GetComponent<MusicControl>().playGetRedPackageAudio();
}
public
void
OnFlyPigBank
()
{
transform
.
DOMove
(
targetObj
.
transform
.
position
,
0.8f
).
OnComplete
(
AnimEnd
);
}
private
void
AnimEnd
()
{
transform
.
parent
=
lowcavs
.
transform
.
parent
;
Destroy
(
transform
.
gameObject
);
//AudioUtils.ins.PlayGetAudio();
}
}
Assets/Game/Main/Scripts/animation/HomeFlyCoin.cs.meta
0 → 100644
View file @
473f69ef
fileFormatVersion: 2
guid: 260fe0269e92c4842ae7f6cde5bd7c76
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