New features done #450

Merged
glencelow merged 2 commits from PlayerController into main 2023-04-01 00:42:19 +08:00
21 changed files with 718 additions and 80 deletions

View File

@ -0,0 +1,8 @@
- VertexShader: 46580970
FragmentShader: 35983630
SubPass: UI
Properties:
data.color: {x: 1, y: 1, z: 1, w: 1}
data.textureIndex: 55490391
data.alpha: 1
data.beta: {x: 1, y: 1, z: 1}

View File

@ -0,0 +1,3 @@
Name: UI_Result
ID: 130179375
Type: 7

View File

@ -2420,7 +2420,7 @@
Components:
Transform Component:
Translate: {x: 0, y: 0, z: 0}
Rotate: {x: -0.0818509459, y: 0.5, z: -11.5662012}
Rotate: {x: 50.5, y: 175.5, z: 0.899999976}
Scale: {x: 1, y: 1, z: 1}
IsActive: true
Renderable Component:
@ -7594,7 +7594,6 @@
- Type: GameManager
Enabled: true
winScene: 86098106
loseScene: 91685359
currGameState: 0
totalItemCount: 4
Score: 0
@ -7602,6 +7601,7 @@
scoreText: 237
timeText: 131278
minusTimerText: 131211
Results: 626
multiplierText: 66055
maxMultiplierDuration: 5
maxMultiplierCombo: 10
@ -9274,6 +9274,7 @@
- Type: SHADE_Scripting.Gameplay.AIBehaviour.AIRework.HomeOwnerAI
Enabled: true
idleDuration: 1
caughtDuration: 2
timeoutDuration: 2
patrolPointParent: 234
patrolSpeed: 1
@ -9320,6 +9321,7 @@
- Type: SHADE_Scripting.Gameplay.AIBehaviour.AIRework.HomeOwnerAttackHitbox
Enabled: true
aiGO: 65771
raccoonFound: false
- EID: 131271
Name: Gameplay Canvas
IsActive: true
@ -9506,3 +9508,164 @@
Clicked: false
IsActive: true
Scripts: ~
- EID: 626
Name: Result Canvas
IsActive: false
NumberOfChildren: 6
Components:
Canvas Component:
Canvas Width: 1920
Canvas Height: 1080
Scale by canvas width: false
IsActive: false
Scripts:
- Type: Results
Enabled: true
score: 623
timeLeft: 622
maxCombo: 621
finalScore: 620
contiuneBtn: 624
nextScene: 86098106
scoreTweenDur: 2
- EID: 624
Name: Contiune_BTN
IsActive: true
NumberOfChildren: 0
Components:
Transform Component:
Translate: {x: 300, y: -400, z: 0.400000006}
Rotate: {x: 0, y: 0, z: 0}
Scale: {x: 344, y: 166, z: 1}
IsActive: true
Renderable Component:
Mesh: 141771688
Material: 129340704
IsActive: true
Button Component:
Default Texture: 59330417
Hovered Texture: 55195346
Clicked Texture: 56163414
IsActive: true
UI Component:
Canvas ID: 626
Hovered: false
Clicked: false
IsActive: true
Scripts:
- Type: SHADE_Scripting.UI.ButtonFX
Enabled: true
onHoverEnterSound: event:/UI/botton_hover
onHoverExitSound: Empty
onClickSound: event:/UI/button_success
onReleaseSound: event:/UI/button_fail
hoverScale: 1.10000002
clickScale: 0.899999976
- EID: 625
Name: Result_BG
IsActive: true
NumberOfChildren: 0
Components:
Transform Component:
Translate: {x: 0, y: 0, z: 0.5}
Rotate: {x: 0, y: 0, z: 0}
Scale: {x: 1024, y: 1024, z: 1}
IsActive: true
Renderable Component:
Mesh: 141771688
Material: 130179375
IsActive: true
UI Component:
Canvas ID: 626
Hovered: false
Clicked: false
IsActive: true
Scripts: ~
- EID: 623
Name: Score_text
IsActive: true
NumberOfChildren: 0
Components:
Transform Component:
Translate: {x: 50, y: 175, z: 0.400000006}
Rotate: {x: 0, y: 0, z: 0}
Scale: {x: 1, y: 1, z: 1}
IsActive: true
Text Renderer Component:
Text: 0
Font: 174412429
Color: {x: 1, y: 1, z: 1, w: 1}
Text Size: {x: 80, y: 80, z: 80}
IsActive: true
UI Component:
Canvas ID: 626
Hovered: false
Clicked: false
IsActive: true
Scripts: ~
- EID: 622
Name: TimeLeft_Text
IsActive: true
NumberOfChildren: 0
Components:
Transform Component:
Translate: {x: 50, y: 45, z: 0.400000006}
Rotate: {x: 0, y: 0, z: 0}
Scale: {x: 1, y: 1, z: 1}
IsActive: true
Text Renderer Component:
Text: 0
Font: 174412429
Color: {x: 1, y: 1, z: 1, w: 1}
Text Size: {x: 80, y: 80, z: 80}
IsActive: true
UI Component:
Canvas ID: 626
Hovered: false
Clicked: false
IsActive: true
Scripts: ~
- EID: 621
Name: MaxCombo_Text
IsActive: true
NumberOfChildren: 0
Components:
Transform Component:
Translate: {x: 50, y: -80, z: 0.400000006}
Rotate: {x: 0, y: 0, z: 0}
Scale: {x: 1, y: 1, z: 1}
IsActive: true
Text Renderer Component:
Text: 0
Font: 174412429
Color: {x: 1, y: 1, z: 1, w: 1}
Text Size: {x: 80, y: 80, z: 80}
IsActive: true
UI Component:
Canvas ID: 626
Hovered: false
Clicked: false
IsActive: true
Scripts: ~
- EID: 620
Name: FinalScore_Text
IsActive: true
NumberOfChildren: 0
Components:
Transform Component:
Translate: {x: 0, y: -285, z: 0.400000006}
Rotate: {x: 0, y: 0, z: 0}
Scale: {x: 1, y: 1, z: 1}
IsActive: true
Text Renderer Component:
Text: 0
Font: 174412429
Color: {x: 1, y: 1, z: 1, w: 1}
Text Size: {x: 160, y: 160, z: 160}
IsActive: true
UI Component:
Canvas ID: 626
Hovered: false
Clicked: false
IsActive: true
Scripts: ~

View File

@ -3881,7 +3881,6 @@
- Type: GameManager
Enabled: true
winScene: 88928066
loseScene: 91685359
currGameState: 0
totalItemCount: 0
Score: 0
@ -3889,6 +3888,7 @@
scoreText: 237
timeText: 131278
minusTimerText: 131211
Results: 624
multiplierText: 66055
maxMultiplierDuration: 5
maxMultiplierCombo: 10
@ -17474,3 +17474,164 @@
Enabled: true
aiGO: 158
raccoonFound: false
- EID: 624
Name: Result Canvas
IsActive: false
NumberOfChildren: 6
Components:
Canvas Component:
Canvas Width: 1920
Canvas Height: 1080
Scale by canvas width: false
IsActive: false
Scripts:
- Type: Results
Enabled: true
score: 621
timeLeft: 620
maxCombo: 612
finalScore: 610
contiuneBtn: 623
nextScene: 88928066
scoreTweenDur: 2
- EID: 623
Name: Contiune_BTN
IsActive: true
NumberOfChildren: 0
Components:
Transform Component:
Translate: {x: 300, y: -400, z: 0.400000006}
Rotate: {x: 0, y: 0, z: 0}
Scale: {x: 344, y: 166, z: 1}
IsActive: true
Renderable Component:
Mesh: 141771688
Material: 129340704
IsActive: true
Button Component:
Default Texture: 59330417
Hovered Texture: 55195346
Clicked Texture: 56163414
IsActive: true
UI Component:
Canvas ID: 624
Hovered: false
Clicked: false
IsActive: true
Scripts:
- Type: SHADE_Scripting.UI.ButtonFX
Enabled: true
onHoverEnterSound: event:/UI/botton_hover
onHoverExitSound: Empty
onClickSound: event:/UI/button_success
onReleaseSound: event:/UI/button_fail
hoverScale: 1.10000002
clickScale: 0.899999976
- EID: 622
Name: Result_BG
IsActive: true
NumberOfChildren: 0
Components:
Transform Component:
Translate: {x: 0, y: 0, z: 0.5}
Rotate: {x: 0, y: 0, z: 0}
Scale: {x: 1024, y: 1024, z: 1}
IsActive: true
Renderable Component:
Mesh: 141771688
Material: 130179375
IsActive: true
UI Component:
Canvas ID: 624
Hovered: false
Clicked: false
IsActive: true
Scripts: ~
- EID: 621
Name: Score_text
IsActive: true
NumberOfChildren: 0
Components:
Transform Component:
Translate: {x: 50, y: 175, z: 0.400000006}
Rotate: {x: 0, y: 0, z: 0}
Scale: {x: 1, y: 1, z: 1}
IsActive: true
Text Renderer Component:
Text: 0
Font: 174412429
Color: {x: 1, y: 1, z: 1, w: 1}
Text Size: {x: 80, y: 80, z: 80}
IsActive: true
UI Component:
Canvas ID: 624
Hovered: false
Clicked: false
IsActive: true
Scripts: ~
- EID: 620
Name: TimeLeft_Text
IsActive: true
NumberOfChildren: 0
Components:
Transform Component:
Translate: {x: 50, y: 45, z: 0.400000006}
Rotate: {x: 0, y: 0, z: 0}
Scale: {x: 1, y: 1, z: 1}
IsActive: true
Text Renderer Component:
Text: 0
Font: 174412429
Color: {x: 1, y: 1, z: 1, w: 1}
Text Size: {x: 80, y: 80, z: 80}
IsActive: true
UI Component:
Canvas ID: 624
Hovered: false
Clicked: false
IsActive: true
Scripts: ~
- EID: 612
Name: MaxCombo_Text
IsActive: true
NumberOfChildren: 0
Components:
Transform Component:
Translate: {x: 50, y: -80, z: 0.400000006}
Rotate: {x: 0, y: 0, z: 0}
Scale: {x: 1, y: 1, z: 1}
IsActive: true
Text Renderer Component:
Text: 0
Font: 174412429
Color: {x: 1, y: 1, z: 1, w: 1}
Text Size: {x: 80, y: 80, z: 80}
IsActive: true
UI Component:
Canvas ID: 624
Hovered: false
Clicked: false
IsActive: true
Scripts: ~
- EID: 610
Name: FinalScore_Text
IsActive: true
NumberOfChildren: 0
Components:
Transform Component:
Translate: {x: 0, y: -285, z: 0.400000006}
Rotate: {x: 0, y: 0, z: 0}
Scale: {x: 1, y: 1, z: 1}
IsActive: true
Text Renderer Component:
Text: 0
Font: 174412429
Color: {x: 1, y: 1, z: 1, w: 1}
Text Size: {x: 160, y: 160, z: 160}
IsActive: true
UI Component:
Canvas ID: 624
Hovered: false
Clicked: false
IsActive: true
Scripts: ~

View File

@ -9053,7 +9053,6 @@
- Type: GameManager
Enabled: true
winScene: 84606951
loseScene: 91685359
currGameState: 0
totalItemCount: 0
Score: 0
@ -9061,6 +9060,7 @@
scoreText: 237
timeText: 66135
minusTimerText: 66057
Results: 505
multiplierText: 66055
maxMultiplierDuration: 5
maxMultiplierCombo: 10
@ -15578,6 +15578,7 @@
- Type: SHADE_Scripting.Gameplay.AIBehaviour.AIRework.HomeOwnerAI
Enabled: true
idleDuration: 1
caughtDuration: 2
timeoutDuration: 2
patrolPointParent: 541
patrolSpeed: 1
@ -15624,6 +15625,7 @@
- Type: SHADE_Scripting.Gameplay.AIBehaviour.AIRework.HomeOwnerAttackHitbox
Enabled: true
aiGO: 66078
raccoonFound: false
- EID: 66062
Name: Gameplay Canvas
IsActive: true
@ -15810,3 +15812,164 @@
Clicked: false
IsActive: true
Scripts: ~
- EID: 505
Name: Result Canvas
IsActive: false
NumberOfChildren: 6
Components:
Canvas Component:
Canvas Width: 1920
Canvas Height: 1080
Scale by canvas width: false
IsActive: false
Scripts:
- Type: Results
Enabled: true
score: 486
timeLeft: 485
maxCombo: 484
finalScore: 274
contiuneBtn: 488
nextScene: 84606951
scoreTweenDur: 2
- EID: 488
Name: Contiune_BTN
IsActive: true
NumberOfChildren: 0
Components:
Transform Component:
Translate: {x: 300, y: -400, z: 0.400000006}
Rotate: {x: 0, y: 0, z: 0}
Scale: {x: 344, y: 166, z: 1}
IsActive: true
Renderable Component:
Mesh: 141771688
Material: 129340704
IsActive: true
Button Component:
Default Texture: 59330417
Hovered Texture: 55195346
Clicked Texture: 56163414
IsActive: true
UI Component:
Canvas ID: 505
Hovered: false
Clicked: false
IsActive: true
Scripts:
- Type: SHADE_Scripting.UI.ButtonFX
Enabled: true
onHoverEnterSound: event:/UI/botton_hover
onHoverExitSound: Empty
onClickSound: event:/UI/button_success
onReleaseSound: event:/UI/button_fail
hoverScale: 1.10000002
clickScale: 0.899999976
- EID: 487
Name: Result_BG
IsActive: true
NumberOfChildren: 0
Components:
Transform Component:
Translate: {x: 0, y: 0, z: 0.5}
Rotate: {x: 0, y: 0, z: 0}
Scale: {x: 1024, y: 1024, z: 1}
IsActive: true
Renderable Component:
Mesh: 141771688
Material: 130179375
IsActive: true
UI Component:
Canvas ID: 505
Hovered: false
Clicked: false
IsActive: true
Scripts: ~
- EID: 486
Name: Score_text
IsActive: true
NumberOfChildren: 0
Components:
Transform Component:
Translate: {x: 50, y: 175, z: 0.400000006}
Rotate: {x: 0, y: 0, z: 0}
Scale: {x: 1, y: 1, z: 1}
IsActive: true
Text Renderer Component:
Text: 0
Font: 174412429
Color: {x: 1, y: 1, z: 1, w: 1}
Text Size: {x: 80, y: 80, z: 80}
IsActive: true
UI Component:
Canvas ID: 505
Hovered: false
Clicked: false
IsActive: true
Scripts: ~
- EID: 485
Name: TimeLeft_Text
IsActive: true
NumberOfChildren: 0
Components:
Transform Component:
Translate: {x: 50, y: 45, z: 0.400000006}
Rotate: {x: 0, y: 0, z: 0}
Scale: {x: 1, y: 1, z: 1}
IsActive: true
Text Renderer Component:
Text: 0
Font: 174412429
Color: {x: 1, y: 1, z: 1, w: 1}
Text Size: {x: 80, y: 80, z: 80}
IsActive: true
UI Component:
Canvas ID: 505
Hovered: false
Clicked: false
IsActive: true
Scripts: ~
- EID: 484
Name: MaxCombo_Text
IsActive: true
NumberOfChildren: 0
Components:
Transform Component:
Translate: {x: 50, y: -80, z: 0.400000006}
Rotate: {x: 0, y: 0, z: 0}
Scale: {x: 1, y: 1, z: 1}
IsActive: true
Text Renderer Component:
Text: 0
Font: 174412429
Color: {x: 1, y: 1, z: 1, w: 1}
Text Size: {x: 80, y: 80, z: 80}
IsActive: true
UI Component:
Canvas ID: 505
Hovered: false
Clicked: false
IsActive: true
Scripts: ~
- EID: 274
Name: FinalScore_Text
IsActive: true
NumberOfChildren: 0
Components:
Transform Component:
Translate: {x: 0, y: -285, z: 0.400000006}
Rotate: {x: 0, y: 0, z: 0}
Scale: {x: 1, y: 1, z: 1}
IsActive: true
Text Renderer Component:
Text: 0
Font: 174412429
Color: {x: 1, y: 1, z: 1, w: 1}
Text Size: {x: 160, y: 160, z: 160}
IsActive: true
UI Component:
Canvas ID: 505
Hovered: false
Clicked: false
IsActive: true
Scripts: ~

View File

@ -538,6 +538,46 @@ public class PlayerController : Script
}
}
public void Caught()
{
currentState = RaccoonStates.CAUGHT;
if (stateMachine && !stateMachine.IsState(typeof(PlayerCaughtState)))
stateMachine.SetState(typeof(PlayerCaughtState));
AudioHandler.audioClipHandlers["RaccoonCaught"].Play();
if (pat && pat.item)
{
if (holdItem)
{
holdItem = false;
pat.item.GetScript<Item>().returnBack = true;
pat.SetItemGravityBack();
pat.ResetItemObject();
}
if (isAiming)
{
isAiming = false;
cam.FOV = Settings.cameraFOV;
camArm.TargetOffset = pat.prevTargetOffSet;
camArm.ArmLength = pat.tpc.armLength;
}
}
}
public void Reset()
{
if (currentState == RaccoonStates.CAUGHT && tranform && respawnPoint)
{
currentState = RaccoonStates.IDLE;
if (stateMachine && !stateMachine.IsState(typeof(PlayerIdleState)))
stateMachine.SetState(typeof(PlayerIdleState));
tranform.GlobalPosition = respawnPoint.GetComponent<Transform>().GlobalPosition;
GameManager.Instance.RacoonCaught();
}
}
protected override void onCollisionEnter(CollisionInfo info)
{
}

View File

@ -10,12 +10,10 @@ public class GameManager : Script
public enum GameState
{
START,
WIN,
LOSE
OVER
}
public uint winScene = 92009475;
public uint loseScene = 91685359;
[NonSerialized]
public GameState currGameState;
@ -30,6 +28,12 @@ public class GameManager : Script
public GameObject timeText;
public GameObject minusTimerText;
public GameObject Results;
public int MaxComboAccquired { get; set; }
public int finalTime { get; set; }
public int finalScore { get; set; }
//mulitpler info
public GameObject multiplierText;
public float maxMultiplierDuration = 5.0f;
@ -48,8 +52,7 @@ public class GameManager : Script
public bool itemShatter { get; set; }
//For scene transitions
private bool goingToWin;
private bool goingToLose;
private bool waitForTransition;
private bool playSpeedUp = false;
@ -79,8 +82,7 @@ public class GameManager : Script
loseAudio.DestroyOnSceneExit = false;
AudioHandler.audioClipHandlers["BGMLose"] = loseAudio;
goingToWin = false;
goingToLose = false;
waitForTransition = false;
if (scoreText)
scoreText.GetComponent<TextRenderable>().Text = $"{Score}";
@ -114,8 +116,6 @@ public class GameManager : Script
protected override void update()
{
if (GamePause || !stealFoodPopUpDone)
{
return;
@ -133,9 +133,9 @@ public class GameManager : Script
playSpeedUp = true;
}
if(scoreText)
if (scoreText)
scoreText.GetComponent<TextRenderable>().Text = $"{Score}";
if(timeText)
if (timeText)
timeText.GetComponent<TextRenderable>().Text = $"{timer.ToString("0")}";
if (itemScored)
@ -148,64 +148,42 @@ public class GameManager : Script
currMultiplierCombo = 1;
currMultiplierDuration = 0;
}
}
if (!goingToLose && ((timer > 0 && totalItemCount <= 0 && !itemShatter)))
if (timer <= 0 || (totalItemCount <= 0 && !itemShatter))
{
currGameState = GameState.WIN;
AudioHandler.StopAllSounds(false);
AudioHandler.audioClipHandlers["BGMWin"].Play();
goingToWin = true;
if (SceneFadeInOut.Instance != null)
SceneFadeInOut.Instance.CallFadeIn();
}
else if(!goingToWin && (timer < 0))
{
currGameState = GameState.LOSE;
AudioHandler.StopAllSounds(false);
if (timer <= 0)
AudioHandler.audioClipHandlers["BGMLose"].Play();
goingToLose = true;
if (SceneFadeInOut.Instance != null)
SceneFadeInOut.Instance.CallFadeIn();
else if (totalItemCount <= 0)
AudioHandler.audioClipHandlers["BGMWin"].Play();
currGameState = GameState.OVER;
finalTime = (int)timer;
Results.SetActive(true);
Input.SetMouseCentering(false);
Application.IsCursorVisible = true;
GamePause = true;
Application.FixDeltaTime = 0;
AnimationSystem.TimeScale = 0;
}
}
//Handling transitions
if (SceneFadeInOut.Instance != null)
{
if (SceneFadeInOut.Instance.FadeInFinished())
{
if (goingToWin)
{
if (SceneFadeInOut.Instance && SceneFadeInOut.Instance.FadeInFinished() && waitForTransition)
SceneManager.ChangeScene(winScene);
}
if (goingToLose)
{
SceneManager.ChangeScene(loseScene);
}
}
}
else
{
if (goingToWin)
{
SceneManager.ChangeScene(winScene);
}
if (goingToLose)
{
SceneManager.ChangeScene(loseScene);
}
}
}
public void RacoonCaught()
{
timer -= 10.0f;
if(minusTimerText != GameObject.Null)
if (minusTimerText != GameObject.Null)
{
MinusTimerText text =minusTimerText.GetScript<MinusTimerText>();
if(text)
MinusTimerText text = minusTimerText.GetScript<MinusTimerText>();
if (text)
{
text.Reset();
}
@ -216,19 +194,10 @@ public class GameManager : Script
{
if (Input.GetKeyUp(Input.KeyCode.F1))
{
currGameState = GameState.WIN;
currGameState = GameState.OVER;
AudioHandler.audioClipHandlers["BGMWin"].Play();
AudioHandler.StopAllSounds(false);
goingToWin = true;
if (SceneFadeInOut.Instance != null)
SceneFadeInOut.Instance.CallFadeIn();
}
else if (Input.GetKeyUp(Input.KeyCode.F2))
{
currGameState = GameState.LOSE;
AudioHandler.audioClipHandlers["BGMLose"].Play();
AudioHandler.StopAllSounds(false);
goingToLose = true;
waitForTransition = true;
if (SceneFadeInOut.Instance != null)
SceneFadeInOut.Instance.CallFadeIn();
}
@ -255,7 +224,11 @@ public class GameManager : Script
currMultiplierDuration = 0;
if (currMultiplierCombo < maxMultiplierCombo)
{
currMultiplierCombo += 1;
if (currMultiplierCombo > MaxComboAccquired)
MaxComboAccquired = currMultiplierCombo;
}
Audio.SetParameter("Multiplier", currMultiplierCombo);
AudioHandler.audioClipHandlers["SFXItemScore"].Play();

View File

@ -0,0 +1,112 @@
using SHADE;
using SHADE_Scripting.UI;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
public class Results : Script
{
public GameObject score;
public GameObject timeLeft;
public GameObject maxCombo;
public GameObject finalScore;
public GameObject contiuneBtn;
public uint nextScene;
public float scoreTweenDur = 2.0f;
private TextRenderable scoreText;
private TextRenderable timeLeftText;
private TextRenderable maxComboText;
private TextRenderable finalScoreText;
private int scoreCount = 0;
private bool once = true;
[NonSerialized]
private TweenThread scoreTween;
private bool waitForTransition;
protected override void awake()
{
scoreText = score.GetComponent<TextRenderable>();
if (!scoreText)
Debug.LogError("MISSING SCORE TEXT");
timeLeftText = timeLeft.GetComponent<TextRenderable>();
if (!timeLeftText)
Debug.LogError("MISSING TIME LEFT TEXT");
maxComboText = maxCombo.GetComponent<TextRenderable>();
if (!maxComboText)
Debug.LogError("MISSING MAX COMBO TEXT");
finalScoreText = finalScore.GetComponent<TextRenderable>();
if (!finalScoreText)
Debug.LogError("MISSING FINAL SCORE TEXT");
if (!contiuneBtn)
Debug.LogError("MISSING CONTIUNE BTN");
else
contiuneBtn.SetActive(false);
waitForTransition = false;
}
protected override void start()
{
scoreCount = GameManager.Instance.Score + (GameManager.Instance.finalTime * 100);
if(scoreText)
scoreText.Text = $"{GameManager.Instance.Score}";
if (timeLeftText)
timeLeftText.Text = $"{GameManager.Instance.finalTime}s";
if (maxComboText)
maxComboText.Text = $"X{GameManager.Instance.MaxComboAccquired}";
if (finalScoreText)
finalScoreText.Text = $"{scoreCount}";
UIElement contiune = contiuneBtn.GetComponent<UIElement>();
if (contiune != null)
{
contiune.OnRelease.RegisterAction(() =>
{
if (SceneFadeInOut.Instance != null)
SceneFadeInOut.Instance.CallFadeIn();
waitForTransition = true;
GameManager.Instance.GamePause = false;
Application.FixDeltaTime = Time.DefaultFixDeltaTime;
AnimationSystem.TimeScale = AnimationSystem.DefaultTimeScale;
});
}
else
{
Debug.LogError("Failed to register contiune button.");
}
scoreTween = TweenManager.CreateTweenThread(scoreTweenDur, 0, scoreCount, EASING_METHOD.EASE_IN_SINE);
}
protected override void update()
{
if (SceneFadeInOut.Instance && SceneFadeInOut.Instance.FadeInFinished() && waitForTransition)
{
Audio.StopAllSounds();
SceneManager.ChangeScene(nextScene);
}
if (finalScoreText && !scoreTween.IsCompleted())
finalScoreText.Text = $"{(int)scoreTween.GetValue()}";
else if(scoreTween.IsCompleted() && once)
{
contiuneBtn.SetActive(true);
finalScoreText.Text = $"{scoreCount}";
once = false;
}
}
}

View File

@ -0,0 +1,3 @@
Name: SC_Results
ID: 154482040
Type: 9

Binary file not shown.

Binary file not shown.

View File

@ -0,0 +1,3 @@
Name: Score_hover
ID: 55195346
Type: 3

Binary file not shown.

Binary file not shown.

View File

@ -0,0 +1,3 @@
Name: Score_idle
ID: 59330417
Type: 3

Binary file not shown.

Binary file not shown.

View File

@ -0,0 +1,3 @@
Name: Score_pressed
ID: 56163414
Type: 3

Binary file not shown.

Binary file not shown.

View File

@ -0,0 +1,3 @@
Name: ResultsUI
ID: 55490391
Type: 3