Skip to content

Commit b798888

Browse files
authored
fixing postgame scene to use 3d background. (#243)
1 parent 47052b8 commit b798888

File tree

3 files changed

+13
-7
lines changed

3 files changed

+13
-7
lines changed
Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
version https://git-lfs.github.com/spec/v1
2-
oid sha256:64a4184a01b6890606bd419078a59a22fd1a48cea2112371faf171c8d6784e55
3-
size 43996
2+
oid sha256:bcd44a1e6ae36de42401214be6c01359047c90466ae4a519357a688cbee18a46
3+
size 44040

Assets/BossRoom/Scripts/Client/UI/PostGameUI.cs

Lines changed: 10 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -11,10 +11,10 @@ namespace BossRoom.Visual
1111
public class PostGameUI : MonoBehaviour
1212
{
1313
[SerializeField]
14-
private RawImage m_Background;
14+
private Image m_EndMessage;
1515

1616
[SerializeField]
17-
private Image m_EndMessage;
17+
private Light m_SceneLight;
1818

1919
[SerializeField]
2020
private GameObject m_ReplayButton;
@@ -30,6 +30,12 @@ public class PostGameUI : MonoBehaviour
3030
[SerializeField]
3131
private Sprite m_LoseSprite;
3232

33+
[SerializeField]
34+
private Color m_WinLightColor;
35+
36+
[SerializeField]
37+
private Color m_LoseLightColor;
38+
3339
void Start()
3440
{
3541
GameObject GamePortalGO = GameObject.FindGameObjectWithTag("GameNetPortal");
@@ -60,13 +66,13 @@ private void OnGameWonChanged(byte prevVal, byte currentVal)
6066
if (m_PostGameData.GameBannerState.Value == (byte)PostGameData.BannerState.Won )
6167
{
6268
m_EndMessage.sprite = m_WinSprite;
63-
m_Background.color = Color.white;
69+
m_SceneLight.color = m_WinLightColor;
6470
m_EndMessage.color = Color.white;
6571
}
6672
else if( m_PostGameData.GameBannerState.Value == (byte)PostGameData.BannerState.Lost )
6773
{
6874
m_EndMessage.sprite = m_LoseSprite;
69-
m_Background.color = new Color(1.0f, 0.5f, 0.5f);
75+
m_SceneLight.color = m_LoseLightColor;
7076
m_EndMessage.color = Color.white;
7177
}
7278
}

Assets/BossRoom/Scripts/Server/Game/State/ServerBossRoomState.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@ public class ServerBossRoomState : GameStateBehaviour
4444
private ServerGameNetPortal m_ServerNetPortal;
4545

4646
// Wait time constants for switching to post game after the game is won or lost
47-
private const float k_WinDelay = 5.0f;
47+
private const float k_WinDelay = 7.0f;
4848
private const float k_LoseDelay = 2.5f;
4949

5050
/// <summary>

0 commit comments

Comments
 (0)