2024-11-25 14:37:44 +08:00
|
|
|
|
using System.Collections;
|
|
|
|
|
using System.Collections.Generic;
|
2024-11-25 15:57:15 +08:00
|
|
|
|
using System.Drawing;
|
2024-11-25 14:37:44 +08:00
|
|
|
|
using TMPro;
|
|
|
|
|
using UnityEngine;
|
|
|
|
|
|
|
|
|
|
public class JournalPanel : MonoBehaviour
|
|
|
|
|
{
|
|
|
|
|
public string gameNo;//<2F><>Ϸ<EFBFBD>ں<EFBFBD>
|
|
|
|
|
public float bet;//<2F><>ע<EFBFBD><D7A2><EFBFBD><EFBFBD>ţ<EFBFBD><C5A3>
|
2024-11-25 15:57:15 +08:00
|
|
|
|
public int roomNo;// <20><>ע<EFBFBD><D7A2><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
2024-11-25 14:37:44 +08:00
|
|
|
|
|
|
|
|
|
public string roomNoKill;// <20><>ɱ<EFBFBD><C9B1><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
|
|
|
|
public int outcome;//<2F><><EFBFBD>ֽ<EFBFBD><D6BD><EFBFBD><EFBFBD><EFBFBD>Ĭ<EFBFBD><C4AC>0<EFBFBD><30>δ<EFBFBD><CEB4><EFBFBD><EFBFBD><EFBFBD><EFBFBD>1ʤ<31><CAA4><EFBFBD><EFBFBD>2ʧ<32><CAA7>
|
|
|
|
|
public float beansCoin;// <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ջ<EFBFBD><D5BB>û<EFBFBD><C3BB>ֶ<EFBFBD>
|
|
|
|
|
public string createTime;// <20><><EFBFBD><EFBFBD>ʱ<EFBFBD><CAB1>
|
|
|
|
|
|
|
|
|
|
public TextMeshProUGUI gameNoText;//<2F><>Ϸ<EFBFBD>ں<EFBFBD>
|
|
|
|
|
public TextMeshProUGUI betText;//<2F><>ע<EFBFBD><D7A2><EFBFBD><EFBFBD>ţ<EFBFBD><C5A3>
|
2024-11-25 15:57:15 +08:00
|
|
|
|
public TextMeshProUGUI roomNoText;// <20><>ע<EFBFBD><D7A2><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
2024-11-25 14:37:44 +08:00
|
|
|
|
|
|
|
|
|
public TextMeshProUGUI roomNameKillText;// <20><>ɱ<EFBFBD><C9B1><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
|
|
|
|
public TextMeshProUGUI outcomeText;//<2F><><EFBFBD>ֽ<EFBFBD><D6BD><EFBFBD><EFBFBD><EFBFBD>Ĭ<EFBFBD><C4AC>0<EFBFBD><30>δ<EFBFBD><CEB4><EFBFBD><EFBFBD><EFBFBD><EFBFBD>1ʤ<31><CAA4><EFBFBD><EFBFBD>2ʧ<32><CAA7>
|
|
|
|
|
public TextMeshProUGUI beansCoinText;// <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ջ<EFBFBD><D5BB>û<EFBFBD><C3BB>ֶ<EFBFBD>
|
|
|
|
|
public TextMeshProUGUI createTimeText;// <20><><EFBFBD><EFBFBD>ʱ<EFBFBD><CAB1>
|
|
|
|
|
|
|
|
|
|
// Start is called before the first frame update
|
|
|
|
|
void Start()
|
|
|
|
|
{
|
2024-11-25 15:57:15 +08:00
|
|
|
|
SetOutcomeText();
|
2024-11-25 17:16:41 +08:00
|
|
|
|
JudgeRoomName();
|
|
|
|
|
SetKillRoomText();
|
2024-11-25 14:37:44 +08:00
|
|
|
|
}
|
|
|
|
|
|
2024-11-25 17:16:41 +08:00
|
|
|
|
|
|
|
|
|
// <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ɫ<EFBFBD><C9AB>ͨ<EFBFBD>÷<EFBFBD><C3B7><EFBFBD>
|
|
|
|
|
private void SetTextOutline(TextMeshProUGUI text, UnityEngine.Color outlineColor)
|
|
|
|
|
{
|
|
|
|
|
// ȷ<><C8B7><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ψһ<CEA8>ģ<EFBFBD><C4A3><EFBFBD><EFBFBD><EFBFBD>Ӱ<EFBFBD><D3B0><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ı<EFBFBD>
|
|
|
|
|
text.fontMaterial = new Material(text.fontMaterial);
|
|
|
|
|
|
|
|
|
|
// <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ɫ<EFBFBD>Ϳ<EFBFBD><CDBF><EFBFBD>
|
|
|
|
|
text.fontMaterial.SetColor("_OutlineColor", outlineColor);
|
2024-11-25 14:37:44 +08:00
|
|
|
|
|
|
|
|
|
}
|
2024-11-25 15:57:15 +08:00
|
|
|
|
public void SetOutcomeText()//<2F><><EFBFBD>óɹ<C3B3><C9B9><EFBFBD><EFBFBD><EFBFBD>ʧ<EFBFBD><CAA7><EFBFBD>ı<EFBFBD>
|
|
|
|
|
{
|
|
|
|
|
if (outcome == 1)
|
|
|
|
|
{
|
|
|
|
|
outcomeText.text = "<22><><EFBFBD>ѳɹ<D1B3>";
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
else if (outcome == 2)
|
|
|
|
|
{
|
|
|
|
|
outcomeText.text = "<22><><EFBFBD><EFBFBD>ʧ<EFBFBD><CAA7>";
|
2024-11-25 17:16:41 +08:00
|
|
|
|
// <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ϊ<EFBFBD><CEAA>ɫ<EFBFBD><C9AB>ʧ<EFBFBD>ܵ<EFBFBD><DCB5><EFBFBD>ɫ<EFBFBD><C9AB>
|
|
|
|
|
SetTextOutline(outcomeText, new UnityEngine.Color(1f, 0.5f, 0.5f));
|
2024-11-25 15:57:15 +08:00
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
2024-11-25 17:16:41 +08:00
|
|
|
|
public void JudgeRoomName()
|
2024-11-25 15:57:15 +08:00
|
|
|
|
{
|
|
|
|
|
if (roomNo == 1)
|
|
|
|
|
{
|
|
|
|
|
roomNoText.text = "<22><><EFBFBD>Ϲ<EFBFBD><CFB9>ݡ<EFBFBD>";
|
|
|
|
|
}
|
|
|
|
|
else if (roomNo == 2)
|
|
|
|
|
{
|
|
|
|
|
roomNoText.text = "<22><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>";
|
|
|
|
|
}
|
|
|
|
|
else if (roomNo == 3)
|
|
|
|
|
{
|
|
|
|
|
roomNoText.text = "<22><><EFBFBD><EFBFBD><EFBFBD>־ӡ<D6BE>";
|
|
|
|
|
}
|
|
|
|
|
else if (roomNo == 4)
|
|
|
|
|
{
|
|
|
|
|
roomNoText.text = "<22><><EFBFBD>ƶ<EFBFBD><C6B6>ҡ<EFBFBD>";
|
|
|
|
|
}
|
|
|
|
|
else if (roomNo == 5)
|
|
|
|
|
{
|
|
|
|
|
roomNoText.text = "<22><><EFBFBD><EFBFBD>Ц<EFBFBD>ߡ<EFBFBD>";
|
|
|
|
|
}
|
|
|
|
|
else if (roomNo == 6)
|
|
|
|
|
{
|
|
|
|
|
roomNoText.text = "<22><><EFBFBD><EFBFBD>Ȥ<EFBFBD><C8A4><EFBFBD><EFBFBD>";
|
|
|
|
|
}
|
|
|
|
|
}
|
2024-11-25 17:16:41 +08:00
|
|
|
|
public void JudgeKillRoomName(int roomNo)
|
|
|
|
|
{
|
|
|
|
|
if (roomNo == 1)
|
|
|
|
|
{
|
|
|
|
|
roomNameKillText.text += "<22><><EFBFBD>Ϲ<EFBFBD><CFB9>ݡ<EFBFBD>";
|
|
|
|
|
}
|
|
|
|
|
else if (roomNo == 2)
|
|
|
|
|
{
|
|
|
|
|
roomNameKillText.text += "<22><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>";
|
|
|
|
|
}
|
|
|
|
|
else if (roomNo == 3)
|
|
|
|
|
{
|
|
|
|
|
roomNameKillText.text += "<22><><EFBFBD><EFBFBD><EFBFBD>־ӡ<D6BE>";
|
|
|
|
|
}
|
|
|
|
|
else if (roomNo == 4)
|
|
|
|
|
{
|
|
|
|
|
roomNameKillText.text += "<22><><EFBFBD>ƶ<EFBFBD><C6B6>ҡ<EFBFBD>";
|
|
|
|
|
}
|
|
|
|
|
else if (roomNo == 5)
|
|
|
|
|
{
|
|
|
|
|
roomNameKillText.text += "<22><><EFBFBD><EFBFBD>Ц<EFBFBD>ߡ<EFBFBD>";
|
|
|
|
|
}
|
|
|
|
|
else if (roomNo == 6)
|
|
|
|
|
{
|
|
|
|
|
roomNameKillText.text += "<22><><EFBFBD><EFBFBD>Ȥ<EFBFBD><C8A4><EFBFBD><EFBFBD>";
|
|
|
|
|
}
|
|
|
|
|
}
|
2024-11-25 15:57:15 +08:00
|
|
|
|
public void SetKillRoomText()
|
|
|
|
|
{
|
|
|
|
|
string[] parts = roomNoKill.Split(",");
|
|
|
|
|
foreach (string part in parts)
|
|
|
|
|
{
|
2024-11-25 17:16:41 +08:00
|
|
|
|
JudgeKillRoomName(int.Parse(part));
|
2024-11-25 15:57:15 +08:00
|
|
|
|
}
|
|
|
|
|
}
|
2024-11-25 14:37:44 +08:00
|
|
|
|
}
|