From af9e523da95ad41753fb8970d3d7433d45e16665 Mon Sep 17 00:00:00 2001 From: maverickdgg Date: Fri, 31 Mar 2023 14:50:25 +0800 Subject: [PATCH] Gameplay UI Update --- Assets/Scenes/Level2.shade | 213 +++++++++++++++++++++- Assets/Scripts/Gameplay/SC_GameManager.cs | 2 +- Assets/Scripts/UI/SC_GameTimer.cs | 57 ++++++ Assets/Scripts/UI/SC_GameTimer.cs.shmeta | 3 + Assets/Scripts/UI/SC_MultiplierTextFx.cs | 88 +++------ Assets/Scripts/UI/SC_ScaleBounce.cs | 4 +- 6 files changed, 299 insertions(+), 68 deletions(-) create mode 100644 Assets/Scripts/UI/SC_GameTimer.cs create mode 100644 Assets/Scripts/UI/SC_GameTimer.cs.shmeta diff --git a/Assets/Scenes/Level2.shade b/Assets/Scenes/Level2.shade index 4355b33e..7a131e4b 100644 --- a/Assets/Scenes/Level2.shade +++ b/Assets/Scenes/Level2.shade @@ -122,8 +122,12 @@ Rotation Speed: 0.100000001 Rotation Decay: 0 Texture Asset ID: 0 + Custom Vertex Shader Asset ID: 0 + Custom Fragment Shader Asset ID: 0 Custom Update Shader Asset ID: 0 Color Tint: {x: 0.876652002, y: 0.485357881, z: 0.166061834, w: 1} + Color Tint Range: {x: 0, y: 0, z: 0, w: 0} + Color Decay: {x: 0, y: 0, z: 0, w: 0} Acceleration: {x: 0, y: 0, z: 0} IsActive: true Scripts: @@ -193,8 +197,12 @@ Rotation Speed: 0.100000001 Rotation Decay: 0 Texture Asset ID: 0 + Custom Vertex Shader Asset ID: 0 + Custom Fragment Shader Asset ID: 0 Custom Update Shader Asset ID: 0 Color Tint: {x: 0.876652002, y: 0.485357881, z: 0.166061834, w: 1} + Color Tint Range: {x: 0, y: 0, z: 0, w: 0} + Color Decay: {x: 0, y: 0, z: 0, w: 0} Acceleration: {x: 0, y: 0, z: 0} IsActive: true Scripts: @@ -264,8 +272,12 @@ Rotation Speed: 0.100000001 Rotation Decay: 0 Texture Asset ID: 0 + Custom Vertex Shader Asset ID: 0 + Custom Fragment Shader Asset ID: 0 Custom Update Shader Asset ID: 0 Color Tint: {x: 0.977993011, y: 1, z: 0.286343634, w: 1} + Color Tint Range: {x: 0, y: 0, z: 0, w: 0} + Color Decay: {x: 0, y: 0, z: 0, w: 0} Acceleration: {x: 0, y: -0.0199999996, z: 0} IsActive: true Scripts: @@ -335,8 +347,12 @@ Rotation Speed: 0.100000001 Rotation Decay: 0 Texture Asset ID: 0 + Custom Vertex Shader Asset ID: 0 + Custom Fragment Shader Asset ID: 0 Custom Update Shader Asset ID: 0 Color Tint: {x: 0.977993011, y: 1, z: 0.286343634, w: 1} + Color Tint Range: {x: 0, y: 0, z: 0, w: 0} + Color Decay: {x: 0, y: 0, z: 0, w: 0} Acceleration: {x: 0, y: -0.0199999996, z: 0} IsActive: true Scripts: @@ -406,8 +422,12 @@ Rotation Speed: 0.100000001 Rotation Decay: 0 Texture Asset ID: 0 + Custom Vertex Shader Asset ID: 0 + Custom Fragment Shader Asset ID: 0 Custom Update Shader Asset ID: 0 Color Tint: {x: 0.279913902, y: 0.845814943, z: 0.0856993049, w: 1} + Color Tint Range: {x: 0, y: 0, z: 0, w: 0} + Color Decay: {x: 0, y: 0, z: 0, w: 0} Acceleration: {x: 0, y: -0.0199999996, z: 0} IsActive: true Scripts: @@ -477,8 +497,12 @@ Rotation Speed: 0.100000001 Rotation Decay: 0 Texture Asset ID: 0 + Custom Vertex Shader Asset ID: 0 + Custom Fragment Shader Asset ID: 0 Custom Update Shader Asset ID: 0 Color Tint: {x: 0.279913902, y: 0.845814943, z: 0.0856993049, w: 1} + Color Tint Range: {x: 0, y: 0, z: 0, w: 0} + Color Decay: {x: 0, y: 0, z: 0, w: 0} Acceleration: {x: 0, y: -0.0199999996, z: 0} IsActive: true Scripts: @@ -548,8 +572,12 @@ Rotation Speed: 0.100000001 Rotation Decay: 0 Texture Asset ID: 0 + Custom Vertex Shader Asset ID: 0 + Custom Fragment Shader Asset ID: 0 Custom Update Shader Asset ID: 0 Color Tint: {x: 0.279913902, y: 0.845814943, z: 0.0856993049, w: 1} + Color Tint Range: {x: 0, y: 0, z: 0, w: 0} + Color Decay: {x: 0, y: 0, z: 0, w: 0} Acceleration: {x: 0, y: -0.0199999996, z: 0} IsActive: true Scripts: @@ -619,8 +647,12 @@ Rotation Speed: 0.100000001 Rotation Decay: 0 Texture Asset ID: 0 + Custom Vertex Shader Asset ID: 0 + Custom Fragment Shader Asset ID: 0 Custom Update Shader Asset ID: 0 Color Tint: {x: 1, y: 1, z: 1, w: 1} + Color Tint Range: {x: 0, y: 0, z: 0, w: 0} + Color Decay: {x: 0, y: 0, z: 0, w: 0} Acceleration: {x: 0, y: -0.00999999978, z: 0} IsActive: true Scripts: @@ -863,8 +895,12 @@ Rotation Speed: 0.100000001 Rotation Decay: 0 Texture Asset ID: 0 + Custom Vertex Shader Asset ID: 0 + Custom Fragment Shader Asset ID: 0 Custom Update Shader Asset ID: 0 Color Tint: {x: 0.876652002, y: 0.485357881, z: 0.166061834, w: 1} + Color Tint Range: {x: 0, y: 0, z: 0, w: 0} + Color Decay: {x: 0, y: 0, z: 0, w: 0} Acceleration: {x: 0, y: 0, z: 0} IsActive: true Scripts: @@ -934,8 +970,12 @@ Rotation Speed: 0.100000001 Rotation Decay: 0 Texture Asset ID: 0 + Custom Vertex Shader Asset ID: 0 + Custom Fragment Shader Asset ID: 0 Custom Update Shader Asset ID: 0 Color Tint: {x: 0.279913902, y: 0.845814943, z: 0.0856993049, w: 1} + Color Tint Range: {x: 0, y: 0, z: 0, w: 0} + Color Decay: {x: 0, y: 0, z: 0, w: 0} Acceleration: {x: 0, y: -0.0199999996, z: 0} IsActive: true Scripts: @@ -1005,8 +1045,12 @@ Rotation Speed: 0.100000001 Rotation Decay: 0 Texture Asset ID: 0 + Custom Vertex Shader Asset ID: 0 + Custom Fragment Shader Asset ID: 0 Custom Update Shader Asset ID: 0 Color Tint: {x: 0.279913902, y: 0.845814943, z: 0.0856993049, w: 1} + Color Tint Range: {x: 0, y: 0, z: 0, w: 0} + Color Decay: {x: 0, y: 0, z: 0, w: 0} Acceleration: {x: 0, y: -0.0199999996, z: 0} IsActive: true Scripts: @@ -1076,8 +1120,12 @@ Rotation Speed: 0.100000001 Rotation Decay: 0 Texture Asset ID: 0 + Custom Vertex Shader Asset ID: 0 + Custom Fragment Shader Asset ID: 0 Custom Update Shader Asset ID: 0 Color Tint: {x: 0.279913902, y: 0.845814943, z: 0.0856993049, w: 1} + Color Tint Range: {x: 0, y: 0, z: 0, w: 0} + Color Decay: {x: 0, y: 0, z: 0, w: 0} Acceleration: {x: 0, y: -0.0199999996, z: 0} IsActive: true Scripts: @@ -1147,8 +1195,12 @@ Rotation Speed: 0.100000001 Rotation Decay: 0 Texture Asset ID: 0 + Custom Vertex Shader Asset ID: 0 + Custom Fragment Shader Asset ID: 0 Custom Update Shader Asset ID: 0 Color Tint: {x: 0.977993011, y: 1, z: 0.286343634, w: 1} + Color Tint Range: {x: 0, y: 0, z: 0, w: 0} + Color Decay: {x: 0, y: 0, z: 0, w: 0} Acceleration: {x: 0, y: -0.0199999996, z: 0} IsActive: true Scripts: @@ -1218,8 +1270,12 @@ Rotation Speed: 0.100000001 Rotation Decay: 0 Texture Asset ID: 0 + Custom Vertex Shader Asset ID: 0 + Custom Fragment Shader Asset ID: 0 Custom Update Shader Asset ID: 0 Color Tint: {x: 0.876652002, y: 0.485357881, z: 0.166061834, w: 1} + Color Tint Range: {x: 0, y: 0, z: 0, w: 0} + Color Decay: {x: 0, y: 0, z: 0, w: 0} Acceleration: {x: 0, y: 0, z: 0} IsActive: true Scripts: @@ -1289,8 +1345,12 @@ Rotation Speed: 0.100000001 Rotation Decay: 0 Texture Asset ID: 0 + Custom Vertex Shader Asset ID: 0 + Custom Fragment Shader Asset ID: 0 Custom Update Shader Asset ID: 0 Color Tint: {x: 0.876652002, y: 0.485357881, z: 0.166061834, w: 1} + Color Tint Range: {x: 0, y: 0, z: 0, w: 0} + Color Decay: {x: 0, y: 0, z: 0, w: 0} Acceleration: {x: 0, y: 0, z: 0} IsActive: true Scripts: @@ -1360,8 +1420,12 @@ Rotation Speed: 0.100000001 Rotation Decay: 0 Texture Asset ID: 0 + Custom Vertex Shader Asset ID: 0 + Custom Fragment Shader Asset ID: 0 Custom Update Shader Asset ID: 0 Color Tint: {x: 0.876652002, y: 0.485357881, z: 0.166061834, w: 1} + Color Tint Range: {x: 0, y: 0, z: 0, w: 0} + Color Decay: {x: 0, y: 0, z: 0, w: 0} Acceleration: {x: 0, y: 0, z: 0} IsActive: true Scripts: @@ -1431,8 +1495,12 @@ Rotation Speed: 0.100000001 Rotation Decay: 0 Texture Asset ID: 0 + Custom Vertex Shader Asset ID: 0 + Custom Fragment Shader Asset ID: 0 Custom Update Shader Asset ID: 0 Color Tint: {x: 0.279913902, y: 0.845814943, z: 0.0856993049, w: 1} + Color Tint Range: {x: 0, y: 0, z: 0, w: 0} + Color Decay: {x: 0, y: 0, z: 0, w: 0} Acceleration: {x: 0, y: -0.0199999996, z: 0} IsActive: true Scripts: @@ -1502,8 +1570,12 @@ Rotation Speed: 0.100000001 Rotation Decay: 0 Texture Asset ID: 0 + Custom Vertex Shader Asset ID: 0 + Custom Fragment Shader Asset ID: 0 Custom Update Shader Asset ID: 0 Color Tint: {x: 0.279913902, y: 0.845814943, z: 0.0856993049, w: 1} + Color Tint Range: {x: 0, y: 0, z: 0, w: 0} + Color Decay: {x: 0, y: 0, z: 0, w: 0} Acceleration: {x: 0, y: -0.0199999996, z: 0} IsActive: true Scripts: @@ -1573,8 +1645,12 @@ Rotation Speed: 0.100000001 Rotation Decay: 0 Texture Asset ID: 0 + Custom Vertex Shader Asset ID: 0 + Custom Fragment Shader Asset ID: 0 Custom Update Shader Asset ID: 0 Color Tint: {x: 0.279913902, y: 0.845814943, z: 0.0856993049, w: 1} + Color Tint Range: {x: 0, y: 0, z: 0, w: 0} + Color Decay: {x: 0, y: 0, z: 0, w: 0} Acceleration: {x: 0, y: -0.0199999996, z: 0} IsActive: true Scripts: @@ -1644,8 +1720,12 @@ Rotation Speed: 0.100000001 Rotation Decay: 0 Texture Asset ID: 0 + Custom Vertex Shader Asset ID: 0 + Custom Fragment Shader Asset ID: 0 Custom Update Shader Asset ID: 0 Color Tint: {x: 0.279913902, y: 0.845814943, z: 0.0856993049, w: 1} + Color Tint Range: {x: 0, y: 0, z: 0, w: 0} + Color Decay: {x: 0, y: 0, z: 0, w: 0} Acceleration: {x: 0, y: -0.0199999996, z: 0} IsActive: true Scripts: @@ -1715,8 +1795,12 @@ Rotation Speed: 0.100000001 Rotation Decay: 0 Texture Asset ID: 0 + Custom Vertex Shader Asset ID: 0 + Custom Fragment Shader Asset ID: 0 Custom Update Shader Asset ID: 0 Color Tint: {x: 0.279913902, y: 0.845814943, z: 0.0856993049, w: 1} + Color Tint Range: {x: 0, y: 0, z: 0, w: 0} + Color Decay: {x: 0, y: 0, z: 0, w: 0} Acceleration: {x: 0, y: -0.0199999996, z: 0} IsActive: true Scripts: @@ -1786,8 +1870,12 @@ Rotation Speed: 0.100000001 Rotation Decay: 0 Texture Asset ID: 0 + Custom Vertex Shader Asset ID: 0 + Custom Fragment Shader Asset ID: 0 Custom Update Shader Asset ID: 0 Color Tint: {x: 0.279913902, y: 0.845814943, z: 0.0856993049, w: 1} + Color Tint Range: {x: 0, y: 0, z: 0, w: 0} + Color Decay: {x: 0, y: 0, z: 0, w: 0} Acceleration: {x: 0, y: -0.0199999996, z: 0} IsActive: true Scripts: @@ -1857,8 +1945,12 @@ Rotation Speed: 0.100000001 Rotation Decay: 0 Texture Asset ID: 0 + Custom Vertex Shader Asset ID: 0 + Custom Fragment Shader Asset ID: 0 Custom Update Shader Asset ID: 0 Color Tint: {x: 0.876652002, y: 0.485357881, z: 0.166061834, w: 1} + Color Tint Range: {x: 0, y: 0, z: 0, w: 0} + Color Decay: {x: 0, y: 0, z: 0, w: 0} Acceleration: {x: 0, y: 0, z: 0} IsActive: true Scripts: @@ -1928,8 +2020,12 @@ Rotation Speed: 0.100000001 Rotation Decay: 0 Texture Asset ID: 0 + Custom Vertex Shader Asset ID: 0 + Custom Fragment Shader Asset ID: 0 Custom Update Shader Asset ID: 0 Color Tint: {x: 0.977993011, y: 1, z: 0.286343634, w: 1} + Color Tint Range: {x: 0, y: 0, z: 0, w: 0} + Color Decay: {x: 0, y: 0, z: 0, w: 0} Acceleration: {x: 0, y: -0.0199999996, z: 0} IsActive: true Scripts: @@ -1999,8 +2095,12 @@ Rotation Speed: 0.100000001 Rotation Decay: 0 Texture Asset ID: 0 + Custom Vertex Shader Asset ID: 0 + Custom Fragment Shader Asset ID: 0 Custom Update Shader Asset ID: 0 Color Tint: {x: 0.279913902, y: 0.845814943, z: 0.0856993049, w: 1} + Color Tint Range: {x: 0, y: 0, z: 0, w: 0} + Color Decay: {x: 0, y: 0, z: 0, w: 0} Acceleration: {x: 0, y: -0.0199999996, z: 0} IsActive: true Scripts: @@ -2070,8 +2170,12 @@ Rotation Speed: 0.100000001 Rotation Decay: 0 Texture Asset ID: 0 + Custom Vertex Shader Asset ID: 0 + Custom Fragment Shader Asset ID: 0 Custom Update Shader Asset ID: 0 Color Tint: {x: 0.279913902, y: 0.845814943, z: 0.0856993049, w: 1} + Color Tint Range: {x: 0, y: 0, z: 0, w: 0} + Color Decay: {x: 0, y: 0, z: 0, w: 0} Acceleration: {x: 0, y: -0.0199999996, z: 0} IsActive: true Scripts: @@ -2141,8 +2245,12 @@ Rotation Speed: 0.100000001 Rotation Decay: 0 Texture Asset ID: 0 + Custom Vertex Shader Asset ID: 0 + Custom Fragment Shader Asset ID: 0 Custom Update Shader Asset ID: 0 Color Tint: {x: 0.279913902, y: 0.845814943, z: 0.0856993049, w: 1} + Color Tint Range: {x: 0, y: 0, z: 0, w: 0} + Color Decay: {x: 0, y: 0, z: 0, w: 0} Acceleration: {x: 0, y: -0.0199999996, z: 0} IsActive: true Scripts: @@ -2212,8 +2320,12 @@ Rotation Speed: 0.100000001 Rotation Decay: 0 Texture Asset ID: 0 + Custom Vertex Shader Asset ID: 0 + Custom Fragment Shader Asset ID: 0 Custom Update Shader Asset ID: 0 Color Tint: {x: 0.290321946, y: 0.823788524, z: 0.323222876, w: 1} + Color Tint Range: {x: 0, y: 0, z: 0, w: 0} + Color Decay: {x: 0, y: 0, z: 0, w: 0} Acceleration: {x: 0, y: 0, z: 0} IsActive: true Scripts: @@ -2288,8 +2400,12 @@ Rotation Speed: 0.100000001 Rotation Decay: 0 Texture Asset ID: 0 + Custom Vertex Shader Asset ID: 0 + Custom Fragment Shader Asset ID: 0 Custom Update Shader Asset ID: 0 Color Tint: {x: 0.290321946, y: 0.823788524, z: 0.323222876, w: 1} + Color Tint Range: {x: 0, y: 0, z: 0, w: 0} + Color Decay: {x: 0, y: 0, z: 0, w: 0} Acceleration: {x: 0, y: 0, z: 0} IsActive: true Scripts: @@ -2359,8 +2475,12 @@ Rotation Speed: 0.100000001 Rotation Decay: 0 Texture Asset ID: 0 + Custom Vertex Shader Asset ID: 0 + Custom Fragment Shader Asset ID: 0 Custom Update Shader Asset ID: 0 Color Tint: {x: 0.290321946, y: 0.823788524, z: 0.323222876, w: 1} + Color Tint Range: {x: 0, y: 0, z: 0, w: 0} + Color Decay: {x: 0, y: 0, z: 0, w: 0} Acceleration: {x: 0, y: 0, z: 0} IsActive: true Scripts: @@ -2430,8 +2550,12 @@ Rotation Speed: 0.100000001 Rotation Decay: 0 Texture Asset ID: 0 + Custom Vertex Shader Asset ID: 0 + Custom Fragment Shader Asset ID: 0 Custom Update Shader Asset ID: 0 Color Tint: {x: 0.290321946, y: 0.823788524, z: 0.323222876, w: 1} + Color Tint Range: {x: 0, y: 0, z: 0, w: 0} + Color Decay: {x: 0, y: 0, z: 0, w: 0} Acceleration: {x: 0, y: 0, z: 0} IsActive: true Scripts: @@ -2501,8 +2625,12 @@ Rotation Speed: 0.100000001 Rotation Decay: 0 Texture Asset ID: 0 + Custom Vertex Shader Asset ID: 0 + Custom Fragment Shader Asset ID: 0 Custom Update Shader Asset ID: 0 Color Tint: {x: 0.290321946, y: 0.823788524, z: 0.323222876, w: 1} + Color Tint Range: {x: 0, y: 0, z: 0, w: 0} + Color Decay: {x: 0, y: 0, z: 0, w: 0} Acceleration: {x: 0, y: 0, z: 0} IsActive: true Scripts: @@ -2572,8 +2700,12 @@ Rotation Speed: 0.100000001 Rotation Decay: 0 Texture Asset ID: 0 + Custom Vertex Shader Asset ID: 0 + Custom Fragment Shader Asset ID: 0 Custom Update Shader Asset ID: 0 Color Tint: {x: 0.290321946, y: 0.823788524, z: 0.323222876, w: 1} + Color Tint Range: {x: 0, y: 0, z: 0, w: 0} + Color Decay: {x: 0, y: 0, z: 0, w: 0} Acceleration: {x: 0, y: 0, z: 0} IsActive: true Scripts: @@ -2643,8 +2775,12 @@ Rotation Speed: 0.100000001 Rotation Decay: 0 Texture Asset ID: 0 + Custom Vertex Shader Asset ID: 0 + Custom Fragment Shader Asset ID: 0 Custom Update Shader Asset ID: 0 Color Tint: {x: 0.290321946, y: 0.823788524, z: 0.323222876, w: 1} + Color Tint Range: {x: 0, y: 0, z: 0, w: 0} + Color Decay: {x: 0, y: 0, z: 0, w: 0} Acceleration: {x: 0, y: 0, z: 0} IsActive: true Scripts: @@ -2719,8 +2855,12 @@ Rotation Speed: 0.100000001 Rotation Decay: 0 Texture Asset ID: 0 + Custom Vertex Shader Asset ID: 0 + Custom Fragment Shader Asset ID: 0 Custom Update Shader Asset ID: 0 Color Tint: {x: 0.290321946, y: 0.823788524, z: 0.323222876, w: 1} + Color Tint Range: {x: 0, y: 0, z: 0, w: 0} + Color Decay: {x: 0, y: 0, z: 0, w: 0} Acceleration: {x: 0, y: 0, z: 0} IsActive: true Scripts: @@ -2790,8 +2930,12 @@ Rotation Speed: 0.100000001 Rotation Decay: 0 Texture Asset ID: 0 + Custom Vertex Shader Asset ID: 0 + Custom Fragment Shader Asset ID: 0 Custom Update Shader Asset ID: 0 Color Tint: {x: 0.290321946, y: 0.823788524, z: 0.323222876, w: 1} + Color Tint Range: {x: 0, y: 0, z: 0, w: 0} + Color Decay: {x: 0, y: 0, z: 0, w: 0} Acceleration: {x: 0, y: 0, z: 0} IsActive: true Scripts: @@ -2861,8 +3005,12 @@ Rotation Speed: 0.100000001 Rotation Decay: 0 Texture Asset ID: 0 + Custom Vertex Shader Asset ID: 0 + Custom Fragment Shader Asset ID: 0 Custom Update Shader Asset ID: 0 Color Tint: {x: 0.290321946, y: 0.823788524, z: 0.323222876, w: 1} + Color Tint Range: {x: 0, y: 0, z: 0, w: 0} + Color Decay: {x: 0, y: 0, z: 0, w: 0} Acceleration: {x: 0, y: 0, z: 0} IsActive: true Scripts: @@ -2932,8 +3080,12 @@ Rotation Speed: 0.100000001 Rotation Decay: 0 Texture Asset ID: 0 + Custom Vertex Shader Asset ID: 0 + Custom Fragment Shader Asset ID: 0 Custom Update Shader Asset ID: 0 Color Tint: {x: 0.290321946, y: 0.823788524, z: 0.323222876, w: 1} + Color Tint Range: {x: 0, y: 0, z: 0, w: 0} + Color Decay: {x: 0, y: 0, z: 0, w: 0} Acceleration: {x: 0, y: 0, z: 0} IsActive: true Scripts: @@ -3003,8 +3155,12 @@ Rotation Speed: 0.100000001 Rotation Decay: 0 Texture Asset ID: 0 + Custom Vertex Shader Asset ID: 0 + Custom Fragment Shader Asset ID: 0 Custom Update Shader Asset ID: 0 Color Tint: {x: 0.290321946, y: 0.823788524, z: 0.323222876, w: 1} + Color Tint Range: {x: 0, y: 0, z: 0, w: 0} + Color Decay: {x: 0, y: 0, z: 0, w: 0} Acceleration: {x: 0, y: 0, z: 0} IsActive: true Scripts: @@ -3074,8 +3230,12 @@ Rotation Speed: 0.100000001 Rotation Decay: 0 Texture Asset ID: 0 + Custom Vertex Shader Asset ID: 0 + Custom Fragment Shader Asset ID: 0 Custom Update Shader Asset ID: 0 Color Tint: {x: 1, y: 1, z: 1, w: 1} + Color Tint Range: {x: 0, y: 0, z: 0, w: 0} + Color Decay: {x: 0, y: 0, z: 0, w: 0} Acceleration: {x: 0, y: -0.00999999978, z: 0} IsActive: true Scripts: @@ -3318,8 +3478,12 @@ Rotation Speed: 0.100000001 Rotation Decay: 0 Texture Asset ID: 0 + Custom Vertex Shader Asset ID: 0 + Custom Fragment Shader Asset ID: 0 Custom Update Shader Asset ID: 0 Color Tint: {x: 1, y: 1, z: 1, w: 1} + Color Tint Range: {x: 0, y: 0, z: 0, w: 0} + Color Decay: {x: 0, y: 0, z: 0, w: 0} Acceleration: {x: 0, y: -0.00999999978, z: 0} IsActive: true Scripts: @@ -3601,8 +3765,12 @@ Rotation Speed: 0.0500000007 Rotation Decay: 0 Texture Asset ID: 0 + Custom Vertex Shader Asset ID: 0 + Custom Fragment Shader Asset ID: 0 Custom Update Shader Asset ID: 37407233 Color Tint: {x: 0, y: 0, z: 0, w: 1} + Color Tint Range: {x: 0, y: 0, z: 0, w: 0} + Color Decay: {x: 0, y: 0, z: 0, w: 0} Acceleration: {x: 0, y: -0.0299999993, z: 0} IsActive: true Scripts: ~ @@ -3695,8 +3863,12 @@ Rotation Speed: 0.0500000007 Rotation Decay: 0 Texture Asset ID: 0 + Custom Vertex Shader Asset ID: 0 + Custom Fragment Shader Asset ID: 0 Custom Update Shader Asset ID: 37407233 Color Tint: {x: 0, y: 0, z: 0, w: 1} + Color Tint Range: {x: 0, y: 0, z: 0, w: 0} + Color Decay: {x: 0, y: 0, z: 0, w: 0} Acceleration: {x: 0, y: -0.0299999993, z: 0} IsActive: true Scripts: ~ @@ -3980,8 +4152,12 @@ Rotation Speed: 0.805999994 Rotation Decay: 0 Texture Asset ID: 56224060 + Custom Vertex Shader Asset ID: 0 + Custom Fragment Shader Asset ID: 0 Custom Update Shader Asset ID: 42141152 Color Tint: {x: 1, y: 1, z: 1, w: 1} + Color Tint Range: {x: 0, y: 0, z: 0, w: 0} + Color Decay: {x: 0, y: 0, z: 0, w: 0} Acceleration: {x: 0, y: 0.0500000007, z: 0} IsActive: true Scripts: ~ @@ -4010,8 +4186,12 @@ Rotation Speed: 0.805999994 Rotation Decay: 0 Texture Asset ID: 56224060 + Custom Vertex Shader Asset ID: 0 + Custom Fragment Shader Asset ID: 0 Custom Update Shader Asset ID: 42141152 Color Tint: {x: 1, y: 1, z: 1, w: 1} + Color Tint Range: {x: 0, y: 0, z: 0, w: 0} + Color Decay: {x: 0, y: 0, z: 0, w: 0} Acceleration: {x: 0, y: 0.0500000007, z: 0} IsActive: true Scripts: ~ @@ -17034,14 +17214,24 @@ Hovered: false Clicked: false IsActive: true - Scripts: ~ + Scripts: + - Type: SHADE_Scripting.UI.GameTimer + Enabled: true + criticalTime: 30 + timer: 0 + - Type: SHADE_Scripting.UI.ScaleBounce + Enabled: true + minScale: 1 + maxScale: 1.20000005 + duration: 1 + isActive: false - EID: 520 Name: Timer BG IsActive: true NumberOfChildren: 0 Components: Transform Component: - Translate: {x: 0.5, y: 0.300000012, z: 0.98999995} + Translate: {x: 0, y: 0.300000012, z: 0.98999995} Rotate: {x: 0, y: 0, z: 0} Scale: {x: 5, y: 2, z: 1} IsActive: true @@ -17086,7 +17276,7 @@ NumberOfChildren: 1 Components: Transform Component: - Translate: {x: -800, y: 250, z: 0.100000001} + Translate: {x: -800, y: 200, z: 0.100000001} Rotate: {x: 0, y: 0, z: 0} Scale: {x: 50, y: 50, z: 60} IsActive: true @@ -17104,9 +17294,8 @@ Scripts: - Type: SHADE_Scripting.UI.MultiplierTextFx Enabled: true - maxSize: 1 - minSize: 0.300000012 - minAlpha: 0.300000012 + maxSize: 1.5 + minSize: 1 - EID: 131593 Name: Multiplier BG IsActive: true @@ -17180,8 +17369,12 @@ Rotation Speed: 0 Rotation Decay: 0 Texture Asset ID: 0 + Custom Vertex Shader Asset ID: 0 + Custom Fragment Shader Asset ID: 0 Custom Update Shader Asset ID: 0 Color Tint: {x: 0.0187467411, y: 0.627120614, z: 0.709251106, w: 1} + Color Tint Range: {x: 0, y: 0, z: 0, w: 0} + Color Decay: {x: 0, y: 0, z: 0, w: 0} Acceleration: {x: 0, y: -0.899999976, z: 0} IsActive: true Scripts: ~ @@ -17210,8 +17403,12 @@ Rotation Speed: 0 Rotation Decay: 0 Texture Asset ID: 0 + Custom Vertex Shader Asset ID: 0 + Custom Fragment Shader Asset ID: 0 Custom Update Shader Asset ID: 0 Color Tint: {x: 0.0187467411, y: 0.627120614, z: 0.709251106, w: 1} + Color Tint Range: {x: 0, y: 0, z: 0, w: 0} + Color Decay: {x: 0, y: 0, z: 0, w: 0} Acceleration: {x: 0, y: 0.100000001, z: 0} IsActive: true Scripts: ~ @@ -17240,8 +17437,12 @@ Rotation Speed: 0 Rotation Decay: 0 Texture Asset ID: 0 + Custom Vertex Shader Asset ID: 0 + Custom Fragment Shader Asset ID: 0 Custom Update Shader Asset ID: 0 Color Tint: {x: 0.0187467411, y: 0.627120614, z: 0.709251106, w: 1} + Color Tint Range: {x: 0, y: 0, z: 0, w: 0} + Color Decay: {x: 0, y: 0, z: 0, w: 0} Acceleration: {x: 0, y: -0.100000001, z: 0} IsActive: true Scripts: ~ diff --git a/Assets/Scripts/Gameplay/SC_GameManager.cs b/Assets/Scripts/Gameplay/SC_GameManager.cs index b4e17d29..0579abd9 100644 --- a/Assets/Scripts/Gameplay/SC_GameManager.cs +++ b/Assets/Scripts/Gameplay/SC_GameManager.cs @@ -136,7 +136,7 @@ public class GameManager : Script if(scoreText) scoreText.GetComponent().Text = $"{Score}"; if(timeText) - timeText.GetComponent().Text = $"{timer.ToString("0.00")}"; + timeText.GetComponent().Text = $"{timer.ToString("0")}"; if (itemScored) { diff --git a/Assets/Scripts/UI/SC_GameTimer.cs b/Assets/Scripts/UI/SC_GameTimer.cs new file mode 100644 index 00000000..86247f88 --- /dev/null +++ b/Assets/Scripts/UI/SC_GameTimer.cs @@ -0,0 +1,57 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; +using SHADE; + +namespace SHADE_Scripting.UI +{ + public class GameTimer: Script + { + private ScaleBounce scaleBounce; + private TextRenderable text; + public float criticalTime = 30; + + public float timer; + + + protected override void awake() + { + text = GetComponent(); + if(!text) + { + Debug.Log("GameTimer: No text renderable found"); + } + + scaleBounce = GetScript(); + if(!scaleBounce) + { + Debug.Log("GameTimer: No Scalebounce found in children"); + } + else + { + scaleBounce.isActive = false; + } + + } + + + protected override void update() + { + timer = GameManager.Instance.timer; + + if (timer <= criticalTime) + { + scaleBounce.isActive = true; + text.TextColor = new Color(1.0f, 0.0f, 0.0f, 1.0f); + } + + + + } + + + + } +} diff --git a/Assets/Scripts/UI/SC_GameTimer.cs.shmeta b/Assets/Scripts/UI/SC_GameTimer.cs.shmeta new file mode 100644 index 00000000..ed4b185f --- /dev/null +++ b/Assets/Scripts/UI/SC_GameTimer.cs.shmeta @@ -0,0 +1,3 @@ +Name: SC_GameTimer +ID: 158823052 +Type: 9 diff --git a/Assets/Scripts/UI/SC_MultiplierTextFx.cs b/Assets/Scripts/UI/SC_MultiplierTextFx.cs index ccd2a4a8..d49eddf4 100644 --- a/Assets/Scripts/UI/SC_MultiplierTextFx.cs +++ b/Assets/Scripts/UI/SC_MultiplierTextFx.cs @@ -12,98 +12,66 @@ namespace SHADE_Scripting.UI [NonSerialized] private TweenThread sizeThread; private TweenThread sizeInvertThread; - private TweenThread alphaThread; + public float maxSize = 1.0f; public float minSize = 0.3f; - public float minAlpha = 0.3f; - - private bool showMultiplier = false; const float sizeUpDuration = 0.1f; [NonSerialized] private Vector3 defaultScale; + private bool tweenUp = false; + protected override void start() { - sizeThread = TweenManager.CreateTweenThread(0.0f, maxSize, minSize, EASING_METHOD.EASE_IN_SINE); + sizeThread = TweenManager.CreateTweenThread(0.01f, maxSize, minSize, EASING_METHOD.EASE_IN_SINE); sizeInvertThread = TweenManager.CreateTweenThread(sizeUpDuration, minSize, maxSize, EASING_METHOD.EASE_IN_SINE); - alphaThread = TweenManager.CreateTweenThread(0.0f, 1.0f, minAlpha, EASING_METHOD.EASE_OUT_SINE); + Transform transform = GetComponent(); if (transform != null) { defaultScale = transform.LocalScale; transform.LocalScale = Vector3.Zero; } - - - showMultiplier = false; - } - protected override void update() + protected override void update() + { + Transform transform = GetComponent(); + + + if (transform != null) + { + if (tweenUp == false) { - Transform transform = GetComponent(); - - - if (transform != null && showMultiplier == true) - { - if(!sizeInvertThread.IsCompleted()) - { - transform.LocalScale = defaultScale * sizeInvertThread.GetValue(); - - Renderable rend = GetComponentInChildren(); - if(rend) - { - rend.Material.SetProperty("data.alpha", 1.0f); - } - - TextRenderable text = GetComponent(); - if (text) - { - Color clr = text.TextColor; - text.TextColor = new Color(clr.r, clr.g, clr.b, 1.0f); - } - return; - } - - if(sizeThread.IsCompleted()) - { - transform.LocalScale = Vector3.Zero; - showMultiplier = false; - } - else - { - transform.LocalScale = defaultScale * sizeThread.GetValue(); - - Renderable rend = GetComponentInChildren(); - if (rend) - { - rend.Material.SetProperty("data.alpha", alphaThread.GetValue()); - } - TextRenderable text = GetComponent(); - if(text) - { - Color clr = text.TextColor; - text.TextColor = new Color(clr.r,clr.g,clr.b,alphaThread.GetValue() * 1.3f); - } - } - } + transform.LocalScale = defaultScale * sizeThread.GetValue(); } + else + { + if (sizeInvertThread.IsCompleted()) + { + tweenUp = false; + sizeThread.Reset(); + } + + transform.LocalScale = defaultScale * sizeInvertThread.GetValue(); + + } + } + } public void ShowMultiplier(int multiplier, float duration) { GetComponent().Text = $"X {multiplier}"; sizeThread.duration = duration + sizeUpDuration; - alphaThread.duration = duration + sizeUpDuration; sizeInvertThread.Reset(); sizeThread.Reset(); - alphaThread.Reset(); - showMultiplier = true; + tweenUp = true; } diff --git a/Assets/Scripts/UI/SC_ScaleBounce.cs b/Assets/Scripts/UI/SC_ScaleBounce.cs index 0d5ca381..31b43671 100644 --- a/Assets/Scripts/UI/SC_ScaleBounce.cs +++ b/Assets/Scripts/UI/SC_ScaleBounce.cs @@ -19,6 +19,8 @@ namespace SHADE_Scripting.UI private Vector3 defaultScale; + public bool isActive = true; + protected override void start() { thread = TweenManager.CreateTweenThread(duration, minScale, maxScale, EASING_METHOD.EASE_IN_SINE); @@ -32,7 +34,7 @@ namespace SHADE_Scripting.UI protected override void update() { Transform trans = GetComponent(); - if(trans != null) + if(trans != null && isActive) { trans.LocalScale = defaultScale * thread.GetValue(); }