using System; using System.Runtime.InteropServices; using Cpp2IlInjected; using Photon.Pun; using Photon.Realtime; using RecRoom.Networking.SynchronizedFields; using UnityEngine; using UnityEngine.UI; namespace RecRoom.Activities.Bowling { // Token: 0x02002766 RID: 10086 [Token(Token = "0x2002766")] [StructLayout(3)] public class BowlingScoreboard : MonoBehaviour { // Token: 0x17002F89 RID: 12169 // (get) Token: 0x060119D4 RID: 72148 RVA: 0x00432F38 File Offset: 0x00431138 [Token(Token = "0x17002F89")] public int PKNBFNIAMMH { [Token(Token = "0x60119D4")] [Address(RVA = "0x69E2D0", Offset = "0x69CCD0", VA = "0x18069E2D0")] get { return this.playerRows.Length; } } // Token: 0x060119D5 RID: 72149 RVA: 0x00432F58 File Offset: 0x00431158 [Token(Token = "0x60119D5")] [Address(RVA = "0x1100140", Offset = "0x10FEB40", VA = "0x181100140")] private void Awake() { GameManager instance = NetworkedSingletonMonoBehaviour.ONCPNMDGGKG; Action action = new Action(this.NJGKEJCHADK); instance.NJGCGNDOMBJ += action; if (!NetworkedSingletonMonoBehaviour.ONCPNMDGGKG.CIFKHPAHBHB) { this.bumpersInfo.SetActive(true); } } // Token: 0x060119D6 RID: 72150 RVA: 0x00432FA0 File Offset: 0x004311A0 [Token(Token = "0x60119D6")] [Address(RVA = "0x1100250", Offset = "0x10FEC50", VA = "0x181100250")] private void OnDestroy() { GameManager instance = NetworkedSingletonMonoBehaviour.ONCPNMDGGKG; int num = 0; if (instance != num) { GameManager instance2 = NetworkedSingletonMonoBehaviour.ONCPNMDGGKG; Action action = new Action(this.NJGKEJCHADK); instance2.NJGCGNDOMBJ -= action; } } // Token: 0x060119D7 RID: 72151 RVA: 0x00432FE0 File Offset: 0x004311E0 [Token(Token = "0x60119D7")] [Address(RVA = "0x1100220", Offset = "0x10FEC20", VA = "0x181100220")] private void NJGKEJCHADK() { GameObject gameObject = this.bumpersInfo; int num = 0; gameObject.SetActive(num != 0); } // Token: 0x060119D8 RID: 72152 RVA: 0x00433004 File Offset: 0x00431204 [Token(Token = "0x60119D8")] [Address(RVA = "0x1100360", Offset = "0x10FED60", VA = "0x181100360")] public void Refresh() { BowlingScoreboardPlayerRow[] array = this.playerRows; int num = 0; if (num < array.Length) { BowlingScoreboardPlayerRow bowlingScoreboardPlayerRow = array[num]; if (BowlingManager.ONCPNMDGGKG.EBDGHFCANCB.Get() == num) { } Color color = this.waitingColor; bowlingScoreboardPlayerRow.SetRowColor(color); Photon.Realtime.Player anyPlayerOnTeam = NetworkedSingletonMonoBehaviour.ONCPNMDGGKG.teamManager.GetAnyPlayerOnTeam((CGLKOJIMDIH)num); Text[] rowTexts = bowlingScoreboardPlayerRow.rowTexts; if (anyPlayerOnTeam == 0) { string text = rowTexts[0].text; string text2 = bowlingScoreboardPlayerRow.rowTexts[11].text; GameObject bumpersIcon = bowlingScoreboardPlayerRow.BumpersIcon; int num2 = 0; bumpersIcon.SetActive(num2 != 0); uint num3; int num4; int num5; int num6; bowlingScoreboardPlayerRow.SetFrame((int)num3, -1, -1, num4, num5, num6); num3 += (uint)1; while (num3 <= (uint)10) { } } GameObject bumpersIcon2 = bowlingScoreboardPlayerRow.BumpersIcon; BowlingManager instance = BowlingManager.ONCPNMDGGKG; bool flag; bumpersIcon2.SetActive(flag); BowlingManager instance2 = BowlingManager.ONCPNMDGGKG; SynchronizedField synchronizedField; int[] array2 = synchronizedField.Get(); int length = array2.Length; uint num8; int num7 = array2[(int)num8]; int totalScore; if (num7 != 10) { int num9 = 0; int num10 = Mathf.Clamp(num7, num9, 10); uint num11 = num8 - 1U; int num12 = array2[(int)num11]; int num13 = 0; int num14 = Mathf.Clamp(num12, num13, 10); int length2 = array2.Length; num14 += num10; num += num14; if (num14 == 10) { if (num8 >= (uint)length2) { goto IL_21F; } int num15 = array2[(int)num8]; if (num15 == -1) { goto IL_21F; } num += num15; } int num16 = BowlingManager.ONCPNMDGGKG.CHKNMGMOHJJ; CGLKOJIMDIH currentTeam = BowlingManager.ONCPNMDGGKG.GPJADJLNGDF; int length3 = array2.Length; uint num17 = num8 - 1U; int num18 = array2[(int)num17]; ulong num19; num16 = (int)((ulong)num16 - num19); int num20 = num16 * (int)num8; num20 -= num; num20 = (int)(num20 + currentTeam); int num21 = array2[(int)num8]; bowlingScoreboardPlayerRow.SetFrame((int)num19, (int)num17, num18, num21, num, num20); num19 += (ulong)1L; num8 += (uint)2; while (num8 <= (uint)20) { } if (PhotonNetwork.IsMasterClient) { GameScoreManager scoreManager = NetworkedSingletonMonoBehaviour.ONCPNMDGGKG.scoreManager; totalScore = bowlingScoreboardPlayerRow.TotalScore; scoreManager.MasterSetScore((CGLKOJIMDIH)num, totalScore); } num++; } IL_21F: uint num22; num22 += (uint)10; uint num24; uint num23 = num24 - 1U; if (-1 < totalScore && num24 > (uint)0) { num23 += (uint)1; } } } // Token: 0x060119D9 RID: 72153 RVA: 0x00433258 File Offset: 0x00431458 [Token(Token = "0x60119D9")] [Address(RVA = "0x3C1210", Offset = "0x3BFC10", VA = "0x1803C1210")] public BowlingScoreboard() { } // Token: 0x0400BCA0 RID: 48288 [global::Cpp2IlInjected.FieldOffset(Offset = "0x18")] [Token(Token = "0x400BCA0")] [SerializeField] private BowlingScoreboardPlayerRow[] playerRows; // Token: 0x0400BCA1 RID: 48289 [global::Cpp2IlInjected.FieldOffset(Offset = "0x20")] [Token(Token = "0x400BCA1")] [SerializeField] private GameObject bumpersInfo; // Token: 0x0400BCA2 RID: 48290 [global::Cpp2IlInjected.FieldOffset(Offset = "0x28")] [Token(Token = "0x400BCA2")] [SerializeField] private Color waitingColor; // Token: 0x0400BCA3 RID: 48291 [global::Cpp2IlInjected.FieldOffset(Offset = "0x38")] [Token(Token = "0x400BCA3")] [SerializeField] private Color turnColor; // Token: 0x0400BCA4 RID: 48292 [global::Cpp2IlInjected.FieldOffset(Offset = "0x48")] [Token(Token = "0x400BCA4")] public BowlingLane BowlingLane; } }