Tiebreaker is now functional, and accounts for retries and three-way ties.

This commit is contained in:
2025-07-13 02:23:25 -04:00
parent 6de4cef1aa
commit c3c6c51f47
16 changed files with 3699 additions and 473 deletions
@@ -44,7 +44,7 @@ MonoBehaviour:
Data:
- Name:
Entry: 12
Data: 17
Data: 20
- Name:
Entry: 7
Data:
@@ -290,40 +290,46 @@ MonoBehaviour:
Data:
- Name: $k
Entry: 1
Data: _GameHasBegun
Data: _TiebreakerData
- Name: $v
Entry: 7
Data: 18|UdonSharp.Compiler.FieldDefinition, UdonSharp.Editor
- Name: <Name>k__BackingField
Entry: 1
Data: _GameHasBegun
Data: _TiebreakerData
- Name: <UserType>k__BackingField
Entry: 9
Data: 8
Entry: 7
Data: 19|System.RuntimeType, mscorlib
- Name:
Entry: 1
Data: VRC.SDKBase.VRCUrl, VRCSDKBase
- Name:
Entry: 8
Data:
- Name: <SystemType>k__BackingField
Entry: 9
Data: 8
Data: 19
- Name: <SyncMode>k__BackingField
Entry: 7
Data: System.Nullable`1[[UdonSharp.UdonSyncMode, UdonSharp.Runtime]], mscorlib
- Name:
Entry: 3
Data: 1
Entry: 6
Data:
- Name:
Entry: 8
Data:
- Name: <IsSerialized>k__BackingField
Entry: 5
Data: false
Data: true
- Name: _fieldAttributes
Entry: 7
Data: 19|System.Collections.Generic.List`1[[System.Attribute, mscorlib]], mscorlib
Data: 20|System.Collections.Generic.List`1[[System.Attribute, mscorlib]], mscorlib
- Name:
Entry: 12
Data: 1
- Name:
Entry: 7
Data: 20|UdonSharp.UdonSyncedAttribute, UdonSharp.Runtime
Data: 21|UnityEngine.SerializeField, UnityEngine.CoreModule
- Name:
Entry: 8
Data:
@@ -344,25 +350,19 @@ MonoBehaviour:
Data:
- Name: $k
Entry: 1
Data: _QuestionIndex
Data: _GameHasBegun
- Name: $v
Entry: 7
Data: 21|UdonSharp.Compiler.FieldDefinition, UdonSharp.Editor
Data: 22|UdonSharp.Compiler.FieldDefinition, UdonSharp.Editor
- Name: <Name>k__BackingField
Entry: 1
Data: _QuestionIndex
Data: _GameHasBegun
- Name: <UserType>k__BackingField
Entry: 7
Data: 22|System.RuntimeType, mscorlib
- Name:
Entry: 1
Data: System.Int32, mscorlib
- Name:
Entry: 8
Data:
Entry: 9
Data: 8
- Name: <SystemType>k__BackingField
Entry: 9
Data: 22
Data: 8
- Name: <SyncMode>k__BackingField
Entry: 7
Data: System.Nullable`1[[UdonSharp.UdonSyncMode, UdonSharp.Runtime]], mscorlib
@@ -404,19 +404,79 @@ MonoBehaviour:
Data:
- Name: $k
Entry: 1
Data: _QuestionStage
Data: _QuestionIndex
- Name: $v
Entry: 7
Data: 25|UdonSharp.Compiler.FieldDefinition, UdonSharp.Editor
- Name: <Name>k__BackingField
Entry: 1
Data: _QuestionIndex
- Name: <UserType>k__BackingField
Entry: 7
Data: 26|System.RuntimeType, mscorlib
- Name:
Entry: 1
Data: System.Int32, mscorlib
- Name:
Entry: 8
Data:
- Name: <SystemType>k__BackingField
Entry: 9
Data: 26
- Name: <SyncMode>k__BackingField
Entry: 7
Data: System.Nullable`1[[UdonSharp.UdonSyncMode, UdonSharp.Runtime]], mscorlib
- Name:
Entry: 3
Data: 1
- Name:
Entry: 8
Data:
- Name: <IsSerialized>k__BackingField
Entry: 5
Data: false
- Name: _fieldAttributes
Entry: 7
Data: 27|System.Collections.Generic.List`1[[System.Attribute, mscorlib]], mscorlib
- Name:
Entry: 12
Data: 1
- Name:
Entry: 7
Data: 28|UdonSharp.UdonSyncedAttribute, UdonSharp.Runtime
- Name:
Entry: 8
Data:
- Name:
Entry: 13
Data:
- Name:
Entry: 8
Data:
- Name:
Entry: 8
Data:
- Name:
Entry: 8
Data:
- Name:
Entry: 7
Data:
- Name: $k
Entry: 1
Data: _QuestionStage
- Name: $v
Entry: 7
Data: 29|UdonSharp.Compiler.FieldDefinition, UdonSharp.Editor
- Name: <Name>k__BackingField
Entry: 1
Data: _QuestionStage
- Name: <UserType>k__BackingField
Entry: 9
Data: 22
Data: 26
- Name: <SystemType>k__BackingField
Entry: 9
Data: 22
Data: 26
- Name: <SyncMode>k__BackingField
Entry: 7
Data: System.Nullable`1[[UdonSharp.UdonSyncMode, UdonSharp.Runtime]], mscorlib
@@ -431,13 +491,13 @@ MonoBehaviour:
Data: false
- Name: _fieldAttributes
Entry: 7
Data: 26|System.Collections.Generic.List`1[[System.Attribute, mscorlib]], mscorlib
Data: 30|System.Collections.Generic.List`1[[System.Attribute, mscorlib]], mscorlib
- Name:
Entry: 12
Data: 1
- Name:
Entry: 7
Data: 27|UdonSharp.UdonSyncedAttribute, UdonSharp.Runtime
Data: 31|UdonSharp.UdonSyncedAttribute, UdonSharp.Runtime
- Name:
Entry: 8
Data:
@@ -461,16 +521,16 @@ MonoBehaviour:
Data: _QuestionSubstage
- Name: $v
Entry: 7
Data: 28|UdonSharp.Compiler.FieldDefinition, UdonSharp.Editor
Data: 32|UdonSharp.Compiler.FieldDefinition, UdonSharp.Editor
- Name: <Name>k__BackingField
Entry: 1
Data: _QuestionSubstage
- Name: <UserType>k__BackingField
Entry: 9
Data: 22
Data: 26
- Name: <SystemType>k__BackingField
Entry: 9
Data: 22
Data: 26
- Name: <SyncMode>k__BackingField
Entry: 7
Data: System.Nullable`1[[UdonSharp.UdonSyncMode, UdonSharp.Runtime]], mscorlib
@@ -485,13 +545,13 @@ MonoBehaviour:
Data: false
- Name: _fieldAttributes
Entry: 7
Data: 29|System.Collections.Generic.List`1[[System.Attribute, mscorlib]], mscorlib
Data: 33|System.Collections.Generic.List`1[[System.Attribute, mscorlib]], mscorlib
- Name:
Entry: 12
Data: 1
- Name:
Entry: 7
Data: 30|UdonSharp.UdonSyncedAttribute, UdonSharp.Runtime
Data: 34|UdonSharp.UdonSyncedAttribute, UdonSharp.Runtime
- Name:
Entry: 8
Data:
@@ -515,16 +575,16 @@ MonoBehaviour:
Data: _QuestionCorrectResponse
- Name: $v
Entry: 7
Data: 31|UdonSharp.Compiler.FieldDefinition, UdonSharp.Editor
Data: 35|UdonSharp.Compiler.FieldDefinition, UdonSharp.Editor
- Name: <Name>k__BackingField
Entry: 1
Data: _QuestionCorrectResponse
- Name: <UserType>k__BackingField
Entry: 9
Data: 22
Data: 26
- Name: <SystemType>k__BackingField
Entry: 9
Data: 22
Data: 26
- Name: <SyncMode>k__BackingField
Entry: 7
Data: System.Nullable`1[[UdonSharp.UdonSyncMode, UdonSharp.Runtime]], mscorlib
@@ -537,72 +597,18 @@ MonoBehaviour:
- Name: <IsSerialized>k__BackingField
Entry: 5
Data: false
- Name: _fieldAttributes
Entry: 7
Data: 32|System.Collections.Generic.List`1[[System.Attribute, mscorlib]], mscorlib
- Name:
Entry: 12
Data: 1
- Name:
Entry: 7
Data: 33|UdonSharp.UdonSyncedAttribute, UdonSharp.Runtime
- Name:
Entry: 8
Data:
- Name:
Entry: 13
Data:
- Name:
Entry: 8
Data:
- Name:
Entry: 8
Data:
- Name:
Entry: 8
Data:
- Name:
Entry: 7
Data:
- Name: $k
Entry: 1
Data: _QuestionsList
- Name: $v
Entry: 7
Data: 34|UdonSharp.Compiler.FieldDefinition, UdonSharp.Editor
- Name: <Name>k__BackingField
Entry: 1
Data: _QuestionsList
- Name: <UserType>k__BackingField
Entry: 7
Data: 35|System.RuntimeType, mscorlib
- Name:
Entry: 1
Data: VRC.SDK3.Data.DataList, VRCSDK3
- Name:
Entry: 8
Data:
- Name: <SystemType>k__BackingField
Entry: 9
Data: 35
- Name: <SyncMode>k__BackingField
Entry: 7
Data: System.Nullable`1[[UdonSharp.UdonSyncMode, UdonSharp.Runtime]], mscorlib
- Name:
Entry: 6
Data:
- Name:
Entry: 8
Data:
- Name: <IsSerialized>k__BackingField
Entry: 5
Data: false
- Name: _fieldAttributes
Entry: 7
Data: 36|System.Collections.Generic.List`1[[System.Attribute, mscorlib]], mscorlib
- Name:
Entry: 12
Data: 0
Data: 1
- Name:
Entry: 7
Data: 37|UdonSharp.UdonSyncedAttribute, UdonSharp.Runtime
- Name:
Entry: 8
Data:
- Name:
Entry: 13
Data:
@@ -620,25 +626,25 @@ MonoBehaviour:
Data:
- Name: $k
Entry: 1
Data: _CurrentQuestion
Data: _QuestionsList
- Name: $v
Entry: 7
Data: 37|UdonSharp.Compiler.FieldDefinition, UdonSharp.Editor
Data: 38|UdonSharp.Compiler.FieldDefinition, UdonSharp.Editor
- Name: <Name>k__BackingField
Entry: 1
Data: _CurrentQuestion
Data: _QuestionsList
- Name: <UserType>k__BackingField
Entry: 7
Data: 38|System.RuntimeType, mscorlib
Data: 39|System.RuntimeType, mscorlib
- Name:
Entry: 1
Data: VRC.SDK3.Data.DataDictionary, VRCSDK3
Data: VRC.SDK3.Data.DataList, VRCSDK3
- Name:
Entry: 8
Data:
- Name: <SystemType>k__BackingField
Entry: 9
Data: 38
Data: 39
- Name: <SyncMode>k__BackingField
Entry: 7
Data: System.Nullable`1[[UdonSharp.UdonSyncMode, UdonSharp.Runtime]], mscorlib
@@ -653,7 +659,115 @@ MonoBehaviour:
Data: false
- Name: _fieldAttributes
Entry: 7
Data: 39|System.Collections.Generic.List`1[[System.Attribute, mscorlib]], mscorlib
Data: 40|System.Collections.Generic.List`1[[System.Attribute, mscorlib]], mscorlib
- Name:
Entry: 12
Data: 0
- Name:
Entry: 13
Data:
- Name:
Entry: 8
Data:
- Name:
Entry: 8
Data:
- Name:
Entry: 8
Data:
- Name:
Entry: 7
Data:
- Name: $k
Entry: 1
Data: _CurrentQuestion
- Name: $v
Entry: 7
Data: 41|UdonSharp.Compiler.FieldDefinition, UdonSharp.Editor
- Name: <Name>k__BackingField
Entry: 1
Data: _CurrentQuestion
- Name: <UserType>k__BackingField
Entry: 7
Data: 42|System.RuntimeType, mscorlib
- Name:
Entry: 1
Data: VRC.SDK3.Data.DataDictionary, VRCSDK3
- Name:
Entry: 8
Data:
- Name: <SystemType>k__BackingField
Entry: 9
Data: 42
- Name: <SyncMode>k__BackingField
Entry: 7
Data: System.Nullable`1[[UdonSharp.UdonSyncMode, UdonSharp.Runtime]], mscorlib
- Name:
Entry: 6
Data:
- Name:
Entry: 8
Data:
- Name: <IsSerialized>k__BackingField
Entry: 5
Data: false
- Name: _fieldAttributes
Entry: 7
Data: 43|System.Collections.Generic.List`1[[System.Attribute, mscorlib]], mscorlib
- Name:
Entry: 12
Data: 0
- Name:
Entry: 13
Data:
- Name:
Entry: 8
Data:
- Name:
Entry: 8
Data:
- Name:
Entry: 8
Data:
- Name:
Entry: 7
Data:
- Name: $k
Entry: 1
Data: _CurrentQuestionType
- Name: $v
Entry: 7
Data: 44|UdonSharp.Compiler.FieldDefinition, UdonSharp.Editor
- Name: <Name>k__BackingField
Entry: 1
Data: _CurrentQuestionType
- Name: <UserType>k__BackingField
Entry: 7
Data: 45|System.RuntimeType, mscorlib
- Name:
Entry: 1
Data: RoundSegmentType, Assembly-CSharp
- Name:
Entry: 8
Data:
- Name: <SystemType>k__BackingField
Entry: 9
Data: 26
- Name: <SyncMode>k__BackingField
Entry: 7
Data: System.Nullable`1[[UdonSharp.UdonSyncMode, UdonSharp.Runtime]], mscorlib
- Name:
Entry: 6
Data:
- Name:
Entry: 8
Data:
- Name: <IsSerialized>k__BackingField
Entry: 5
Data: false
- Name: _fieldAttributes
Entry: 7
Data: 46|System.Collections.Generic.List`1[[System.Attribute, mscorlib]], mscorlib
- Name:
Entry: 12
Data: 0
@@ -677,7 +791,7 @@ MonoBehaviour:
Data: _BuzzInAllowed
- Name: $v
Entry: 7
Data: 40|UdonSharp.Compiler.FieldDefinition, UdonSharp.Editor
Data: 47|UdonSharp.Compiler.FieldDefinition, UdonSharp.Editor
- Name: <Name>k__BackingField
Entry: 1
Data: _BuzzInAllowed
@@ -699,120 +813,6 @@ MonoBehaviour:
- Name: <IsSerialized>k__BackingField
Entry: 5
Data: false
- Name: _fieldAttributes
Entry: 7
Data: 41|System.Collections.Generic.List`1[[System.Attribute, mscorlib]], mscorlib
- Name:
Entry: 12
Data: 1
- Name:
Entry: 7
Data: 42|UdonSharp.UdonSyncedAttribute, UdonSharp.Runtime
- Name:
Entry: 8
Data:
- Name:
Entry: 13
Data:
- Name:
Entry: 8
Data:
- Name:
Entry: 8
Data:
- Name:
Entry: 8
Data:
- Name:
Entry: 7
Data:
- Name: $k
Entry: 1
Data: _PlayerBuzzInAllowed
- Name: $v
Entry: 7
Data: 43|UdonSharp.Compiler.FieldDefinition, UdonSharp.Editor
- Name: <Name>k__BackingField
Entry: 1
Data: _PlayerBuzzInAllowed
- Name: <UserType>k__BackingField
Entry: 7
Data: 44|System.RuntimeType, mscorlib
- Name:
Entry: 1
Data: System.Boolean[], mscorlib
- Name:
Entry: 8
Data:
- Name: <SystemType>k__BackingField
Entry: 9
Data: 44
- Name: <SyncMode>k__BackingField
Entry: 7
Data: System.Nullable`1[[UdonSharp.UdonSyncMode, UdonSharp.Runtime]], mscorlib
- Name:
Entry: 3
Data: 1
- Name:
Entry: 8
Data:
- Name: <IsSerialized>k__BackingField
Entry: 5
Data: false
- Name: _fieldAttributes
Entry: 7
Data: 45|System.Collections.Generic.List`1[[System.Attribute, mscorlib]], mscorlib
- Name:
Entry: 12
Data: 1
- Name:
Entry: 7
Data: 46|UdonSharp.UdonSyncedAttribute, UdonSharp.Runtime
- Name:
Entry: 8
Data:
- Name:
Entry: 13
Data:
- Name:
Entry: 8
Data:
- Name:
Entry: 8
Data:
- Name:
Entry: 8
Data:
- Name:
Entry: 7
Data:
- Name: $k
Entry: 1
Data: _BuzzedInPlayer
- Name: $v
Entry: 7
Data: 47|UdonSharp.Compiler.FieldDefinition, UdonSharp.Editor
- Name: <Name>k__BackingField
Entry: 1
Data: _BuzzedInPlayer
- Name: <UserType>k__BackingField
Entry: 9
Data: 22
- Name: <SystemType>k__BackingField
Entry: 9
Data: 22
- Name: <SyncMode>k__BackingField
Entry: 7
Data: System.Nullable`1[[UdonSharp.UdonSyncMode, UdonSharp.Runtime]], mscorlib
- Name:
Entry: 3
Data: 1
- Name:
Entry: 8
Data:
- Name: <IsSerialized>k__BackingField
Entry: 5
Data: false
- Name: _fieldAttributes
Entry: 7
Data: 48|System.Collections.Generic.List`1[[System.Attribute, mscorlib]], mscorlib
@@ -842,16 +842,130 @@ MonoBehaviour:
Data:
- Name: $k
Entry: 1
Data: _FinalRoundPlayersSortedByScore
Data: _PlayerBuzzInAllowed
- Name: $v
Entry: 7
Data: 50|UdonSharp.Compiler.FieldDefinition, UdonSharp.Editor
- Name: <Name>k__BackingField
Entry: 1
Data: _FinalRoundPlayersSortedByScore
Data: _PlayerBuzzInAllowed
- Name: <UserType>k__BackingField
Entry: 7
Data: 51|System.RuntimeType, mscorlib
- Name:
Entry: 1
Data: System.Boolean[], mscorlib
- Name:
Entry: 8
Data:
- Name: <SystemType>k__BackingField
Entry: 9
Data: 51
- Name: <SyncMode>k__BackingField
Entry: 7
Data: System.Nullable`1[[UdonSharp.UdonSyncMode, UdonSharp.Runtime]], mscorlib
- Name:
Entry: 3
Data: 1
- Name:
Entry: 8
Data:
- Name: <IsSerialized>k__BackingField
Entry: 5
Data: false
- Name: _fieldAttributes
Entry: 7
Data: 52|System.Collections.Generic.List`1[[System.Attribute, mscorlib]], mscorlib
- Name:
Entry: 12
Data: 1
- Name:
Entry: 7
Data: 53|UdonSharp.UdonSyncedAttribute, UdonSharp.Runtime
- Name:
Entry: 8
Data:
- Name:
Entry: 13
Data:
- Name:
Entry: 8
Data:
- Name:
Entry: 8
Data:
- Name:
Entry: 8
Data:
- Name:
Entry: 7
Data:
- Name: $k
Entry: 1
Data: _BuzzedInPlayer
- Name: $v
Entry: 7
Data: 54|UdonSharp.Compiler.FieldDefinition, UdonSharp.Editor
- Name: <Name>k__BackingField
Entry: 1
Data: _BuzzedInPlayer
- Name: <UserType>k__BackingField
Entry: 9
Data: 26
- Name: <SystemType>k__BackingField
Entry: 9
Data: 26
- Name: <SyncMode>k__BackingField
Entry: 7
Data: System.Nullable`1[[UdonSharp.UdonSyncMode, UdonSharp.Runtime]], mscorlib
- Name:
Entry: 3
Data: 1
- Name:
Entry: 8
Data:
- Name: <IsSerialized>k__BackingField
Entry: 5
Data: false
- Name: _fieldAttributes
Entry: 7
Data: 55|System.Collections.Generic.List`1[[System.Attribute, mscorlib]], mscorlib
- Name:
Entry: 12
Data: 1
- Name:
Entry: 7
Data: 56|UdonSharp.UdonSyncedAttribute, UdonSharp.Runtime
- Name:
Entry: 8
Data:
- Name:
Entry: 13
Data:
- Name:
Entry: 8
Data:
- Name:
Entry: 8
Data:
- Name:
Entry: 8
Data:
- Name:
Entry: 7
Data:
- Name: $k
Entry: 1
Data: _FinalRoundPlayersSortedByScore
- Name: $v
Entry: 7
Data: 57|UdonSharp.Compiler.FieldDefinition, UdonSharp.Editor
- Name: <Name>k__BackingField
Entry: 1
Data: _FinalRoundPlayersSortedByScore
- Name: <UserType>k__BackingField
Entry: 7
Data: 58|System.RuntimeType, mscorlib
- Name:
Entry: 1
Data: System.Int32[], mscorlib
@@ -860,7 +974,7 @@ MonoBehaviour:
Data:
- Name: <SystemType>k__BackingField
Entry: 9
Data: 51
Data: 58
- Name: <SyncMode>k__BackingField
Entry: 7
Data: System.Nullable`1[[UdonSharp.UdonSyncMode, UdonSharp.Runtime]], mscorlib
@@ -875,7 +989,55 @@ MonoBehaviour:
Data: false
- Name: _fieldAttributes
Entry: 7
Data: 52|System.Collections.Generic.List`1[[System.Attribute, mscorlib]], mscorlib
Data: 59|System.Collections.Generic.List`1[[System.Attribute, mscorlib]], mscorlib
- Name:
Entry: 12
Data: 0
- Name:
Entry: 13
Data:
- Name:
Entry: 8
Data:
- Name:
Entry: 8
Data:
- Name:
Entry: 8
Data:
- Name:
Entry: 7
Data:
- Name: $k
Entry: 1
Data: _TiebreakerPlayerNumbers
- Name: $v
Entry: 7
Data: 60|UdonSharp.Compiler.FieldDefinition, UdonSharp.Editor
- Name: <Name>k__BackingField
Entry: 1
Data: _TiebreakerPlayerNumbers
- Name: <UserType>k__BackingField
Entry: 9
Data: 58
- Name: <SystemType>k__BackingField
Entry: 9
Data: 58
- Name: <SyncMode>k__BackingField
Entry: 7
Data: System.Nullable`1[[UdonSharp.UdonSyncMode, UdonSharp.Runtime]], mscorlib
- Name:
Entry: 6
Data:
- Name:
Entry: 8
Data:
- Name: <IsSerialized>k__BackingField
Entry: 5
Data: false
- Name: _fieldAttributes
Entry: 7
Data: 61|System.Collections.Generic.List`1[[System.Attribute, mscorlib]], mscorlib
- Name:
Entry: 12
Data: 0
@@ -899,13 +1061,13 @@ MonoBehaviour:
Data: _PlayerPodiums
- Name: $v
Entry: 7
Data: 53|UdonSharp.Compiler.FieldDefinition, UdonSharp.Editor
Data: 62|UdonSharp.Compiler.FieldDefinition, UdonSharp.Editor
- Name: <Name>k__BackingField
Entry: 1
Data: _PlayerPodiums
- Name: <UserType>k__BackingField
Entry: 7
Data: 54|System.RuntimeType, mscorlib
Data: 63|System.RuntimeType, mscorlib
- Name:
Entry: 1
Data: PlayerPodium[], Assembly-CSharp
@@ -914,7 +1076,7 @@ MonoBehaviour:
Data:
- Name: <SystemType>k__BackingField
Entry: 7
Data: 55|System.RuntimeType, mscorlib
Data: 64|System.RuntimeType, mscorlib
- Name:
Entry: 1
Data: UnityEngine.Component[], UnityEngine.CoreModule
@@ -935,13 +1097,13 @@ MonoBehaviour:
Data: true
- Name: _fieldAttributes
Entry: 7
Data: 56|System.Collections.Generic.List`1[[System.Attribute, mscorlib]], mscorlib
Data: 65|System.Collections.Generic.List`1[[System.Attribute, mscorlib]], mscorlib
- Name:
Entry: 12
Data: 1
- Name:
Entry: 7
Data: 57|UnityEngine.SerializeField, UnityEngine.CoreModule
Data: 66|UnityEngine.SerializeField, UnityEngine.CoreModule
- Name:
Entry: 8
Data:
@@ -965,13 +1127,13 @@ MonoBehaviour:
Data: _AudioManager
- Name: $v
Entry: 7
Data: 58|UdonSharp.Compiler.FieldDefinition, UdonSharp.Editor
Data: 67|UdonSharp.Compiler.FieldDefinition, UdonSharp.Editor
- Name: <Name>k__BackingField
Entry: 1
Data: _AudioManager
- Name: <UserType>k__BackingField
Entry: 7
Data: 59|System.RuntimeType, mscorlib
Data: 68|System.RuntimeType, mscorlib
- Name:
Entry: 1
Data: AudioManager, Assembly-CSharp
@@ -995,13 +1157,13 @@ MonoBehaviour:
Data: true
- Name: _fieldAttributes
Entry: 7
Data: 60|System.Collections.Generic.List`1[[System.Attribute, mscorlib]], mscorlib
Data: 69|System.Collections.Generic.List`1[[System.Attribute, mscorlib]], mscorlib
- Name:
Entry: 12
Data: 1
- Name:
Entry: 7
Data: 61|UnityEngine.SerializeField, UnityEngine.CoreModule
Data: 70|UnityEngine.SerializeField, UnityEngine.CoreModule
- Name:
Entry: 8
Data:
@@ -5,6 +5,10 @@ using VRC.SDK3.Data;
using VRC.SDK3.UdonNetworkCalling;
using VRC.Udon.Common.Interfaces;
using VRC.SDKBase;
using Newtonsoft.Json.Converters;
using VRC.Udon.Wrapper.Modules;
using VRC.SDK3.StringLoading;
using System.Collections.Generic;
public enum PresentationMedium
@@ -21,6 +25,8 @@ public class GameManagerRound1 : GameManagerBase
[SerializeField] private CaseManager _CaseManager;
[SerializeField] private CaseVideoSyncPlayer _VideoPlayer;
[SerializeField] private VRCUrl _TiebreakerData;
[UdonSynced] protected bool _GameHasBegun = false;
[UdonSynced] private int _QuestionIndex = 0;
@@ -29,12 +35,14 @@ public class GameManagerRound1 : GameManagerBase
[UdonSynced] private int _QuestionCorrectResponse = 0;
private DataList _QuestionsList = new DataList();
private DataDictionary _CurrentQuestion;
private RoundSegmentType _CurrentQuestionType = RoundSegmentType.BetweenSegments;
[UdonSynced] private bool _BuzzInAllowed = false;
[UdonSynced] private bool[] _PlayerBuzzInAllowed;
[UdonSynced] private int _BuzzedInPlayer = 0;
private int[] _FinalRoundPlayersSortedByScore;
private int[] _TiebreakerPlayerNumbers;
[SerializeField] private PlayerPodium[] _PlayerPodiums;
@@ -104,10 +112,17 @@ public class GameManagerRound1 : GameManagerBase
EnableInteraction("Assign Points");
}
private void AssignStarterPoints()
private void InitialiseQuestion()
{
_CurrentQuestion = _QuestionsList[_QuestionIndex].DataDictionary;
// Again, why does this work, but not just casting to an enum?
_CurrentQuestionType = (RoundSegmentType)(int)_CurrentQuestion["Type"].Number;
_QuestionStage = 0;
}
private void AssignStarterPoints()
{
InitialiseQuestion();
for (int i = 0; i < _PlayerPodiums.Length; i++)
{
@@ -212,7 +227,7 @@ public class GameManagerRound1 : GameManagerBase
ResetMultipleChoiceInterface(Interface);
Interface.HeaderUI.text = RoundSegmentTypeToString((RoundSegmentType)((int)_CurrentQuestion["Type"].Number));
Interface.HeaderUI.text = RoundSegmentTypeToString(_CurrentQuestionType);
DataList ClueStrings = _CurrentQuestion["Clues"].DataList;
for (int i = 0; i < Interface.CluesUI.Length && i < ClueStrings.Count; i++)
@@ -371,7 +386,7 @@ public class GameManagerRound1 : GameManagerBase
HostCardLightningRoundInterface Interface =
(HostCardLightningRoundInterface)GetHostCardInterface(RoundSegmentType.LightningRound);
Interface.HeaderUI.text = RoundSegmentTypeToString((RoundSegmentType)((int)_CurrentQuestion["Type"].Number)) + " | " + _CurrentQuestion["Location"].ToString();
Interface.HeaderUI.text = RoundSegmentTypeToString(_CurrentQuestionType) + " | " + _CurrentQuestion["Location"].ToString();
for (int i = 0; i < Interface.ChoiceUI.Length && i < Interface.ChoiceButtons.Length; i++)
{
Interface.ChoiceUI[i].text = "";
@@ -461,7 +476,7 @@ public class GameManagerRound1 : GameManagerBase
HostCardTheChaseInterface Interface =
(HostCardTheChaseInterface)GetHostCardInterface(RoundSegmentType.TheChase);
Interface.HeaderUI.text = RoundSegmentTypeToString((RoundSegmentType)((int)_CurrentQuestion["Type"].Number));
Interface.HeaderUI.text = RoundSegmentTypeToString(_CurrentQuestionType);
Interface.ClueUI.text = "";
for (int i = 0; i < Interface.ChoiceUI.Length && i < Interface.ChoiceButtons.Length; i++)
{
@@ -518,8 +533,6 @@ public class GameManagerRound1 : GameManagerBase
private void TheChaseCheckAnswer(int Answer)
{
Debug.LogError("Answer is " + Answer + ", correct response is " + _QuestionCorrectResponse);
if (_QuestionCorrectResponse == Answer)
{
int PodiumIndex = _BuzzedInPlayer - 1;
@@ -611,7 +624,7 @@ public class GameManagerRound1 : GameManagerBase
HostCardMultipleChoiceInterface Interface =
(HostCardMultipleChoiceInterface)GetHostCardInterface(RoundSegmentType.FinalRound);
Interface.HeaderUI.text = RoundSegmentTypeToString((RoundSegmentType)((int)_CurrentQuestion["Type"].Number));
Interface.HeaderUI.text = RoundSegmentTypeToString(_CurrentQuestionType);
DataList ClueStrings = _CurrentQuestion["Clues"].DataList;
for (int i = 0; i < Interface.CluesUI.Length && i < ClueStrings.Count; i++)
@@ -788,7 +801,7 @@ public class GameManagerRound1 : GameManagerBase
// about to finish up, so just move on to determining winners.
if (PlayerPlace == 1)
{
FinalRoundDetermineWinners();
EnableInteraction("End Of Round");
}
else
{
@@ -796,8 +809,14 @@ public class GameManagerRound1 : GameManagerBase
}
}
private void FinalRoundDetermineWinners()
private bool FinalRoundCheckNeedForTiebreaker()
{
DisableChoiceCards();
DisableRiskCards();
DisableBuzzers();
_VideoPlayer.ClearScreen();
SortPlayersHighToLowScore();
int[] SortedPlayerScores = new int[_PlayerPodiums.Length];
@@ -809,50 +828,60 @@ public class GameManagerRound1 : GameManagerBase
HostCardBetweenRoundsInterface Interface =
(HostCardBetweenRoundsInterface)GetHostCardInterface(RoundSegmentType.BetweenSegments);
PlayerPodium Number1Podium = _PlayerPodiums[_FinalRoundPlayersSortedByScore[0] - 1];
PlayerPodium Number2Podium = _PlayerPodiums[_FinalRoundPlayersSortedByScore[1] - 1];
PlayerPodium Number3Podium = _PlayerPodiums[_FinalRoundPlayersSortedByScore[2] - 1];
VRCPlayerApi Number1 = Networking.GetOwner(Number1Podium.gameObject);
VRCPlayerApi Number2 = Networking.GetOwner(Number2Podium.gameObject);
VRCPlayerApi Number3 = Networking.GetOwner(Number3Podium.gameObject);
bool TiebreakerNeeded = false;
if (SortedPlayerScores[1] == SortedPlayerScores[2])
{
if (SortedPlayerScores[0] == SortedPlayerScores[1])
{
Interface.HeaderUI.text = "Three-way tie; two tiebreakers will appear here in the final version.";
Interface.HeaderUI.text = "We have a three-way tie. We'll start with a tiebreaker between " + Number2.displayName + " and " + Number3.displayName + ".";
}
else
{
Interface.HeaderUI.text = "Tie for second place between [[PLAYER]] and [[PLAYER]]; tiebreaker will appear here in the final version.";
Interface.HeaderUI.text = Number1.displayName + " is in first place and will be moving on to the next round. There is a tie for second place between " + Number2.displayName + " and " + Number3.displayName + ", so we will move on to a tiebreaker.";
}
TiebreakerNeeded = true;
PrepareTiebreakerRound(Number2Podium.PlayerNumber, Number3Podium.PlayerNumber);
}
else
{
VRCPlayerApi Number1 = Networking.GetOwner(_PlayerPodiums[_FinalRoundPlayersSortedByScore[0] - 1].gameObject);
VRCPlayerApi Number2 = Networking.GetOwner(_PlayerPodiums[_FinalRoundPlayersSortedByScore[1] - 1].gameObject);
if (SortedPlayerScores[0] == SortedPlayerScores[1])
{
// Tag both players as being tied for first place
Number1.SetPlayerTag("Round1State", "TiedForFirstPlace");
Number2.SetPlayerTag("Round2State", "TiedForFirstPlace");
// Randomly choose which player gets the first turn in the next round.
Random.InitState(Networking.GetServerTimeInMilliseconds());
VRCPlayerApi[] Randomiser = new VRCPlayerApi[2];
Randomiser[0] = Number1;
Randomiser[1] = Number2;
int RandomIndex = Random.Range(0, 2);
Randomiser[RandomIndex].SetPlayerTag("Round1State", "FirstPlace");
Interface.HeaderUI.text = "[[PLAYER]] and [[PLAYER]] are tied for first; both will move on to the next round.";
Interface.HeaderUI.text = Number1.displayName + " and " + Number2.displayName + " are tied for first place; both will move on to the next round.";
}
else
{
// Tag first place player as first place, and second place as second
// Tag first place player as first place.
Number1.SetPlayerTag("Round1State", "FirstPlace");
Number2.SetPlayerTag("Round2State", "SecondPlace");
Interface.HeaderUI.text = "[[FIRSTPLACEPLAYER]] and [[SECONDPLACEPLAYER]] will move on to the next round.";
Interface.HeaderUI.text = Number1.displayName + " and " + Number2.displayName + " will move on to the next round.";
}
}
if (TiebreakerNeeded)
{
EnableInteraction("Advance To Tiebreaker");
}
else
{
EnableInteraction("End Game");
}
return TiebreakerNeeded;
}
private void PrepareTiebreakerRound(int FirstPlayer, int SecondPlayer)
{
_QuestionStage = 0;
_TiebreakerPlayerNumbers = new int[2];
_TiebreakerPlayerNumbers[0] = FirstPlayer;
_TiebreakerPlayerNumbers[1] = SecondPlayer;
}
@@ -864,24 +893,152 @@ public class GameManagerRound1 : GameManagerBase
_VideoPlayer.ClearScreen();
HostCardBetweenRoundsInterface Interface = ShowBetweenQuestionsInterface();
_QuestionIndex++;
if (_QuestionIndex >= _QuestionsList.Count)
{
Interface.HeaderUI.text = "Round is over. Move to the loot recovery area.";
_CaseManager.ContinueToRound2();
return;
PrepareEndGame();
}
else
{
PrepareNextQuestion();
}
}
private void PrepareNextQuestion()
{
InitialiseQuestion();
_CurrentQuestion = _QuestionsList[_QuestionIndex].DataDictionary;
_QuestionStage = 0;
// Again, why does this work, but not just casting to an enum?
Interface.HeaderUI.text = "Upcoming Question: " + RoundSegmentTypeToString((RoundSegmentType)((int)_CurrentQuestion["Type"].Number));
ShowBetweenQuestionsInterface();
EnableInteraction("Show Next Question");
}
private void PrepareEndGame()
{
bool TiebreakerNeeded = FinalRoundCheckNeedForTiebreaker();
if (TiebreakerNeeded)
{
_CurrentQuestionType = RoundSegmentType.Tiebreaker;
EnableInteraction("Advance To Tiebreaker");
}
else
{
HostCardBetweenRoundsInterface Interface =
(HostCardBetweenRoundsInterface)GetHostCardInterface(RoundSegmentType.BetweenSegments);
Interface.HeaderUI.text = "Round is over. Move to the loot recovery area.";
_CaseManager.ContinueToRound2();
EnableInteraction("End Game");
}
}
private void BeginTiebreakerRound()
{
HostCardBetweenRoundsInterface Interface =
(HostCardBetweenRoundsInterface)GetHostCardInterface(RoundSegmentType.BetweenSegments);
Interface.HeaderUI.text = "Preparing tiebreaker...";
VRCStringDownloader.LoadUrl(_TiebreakerData, (IUdonEventReceiver)this);
}
public override void OnStringLoadSuccess(IVRCStringDownload TiebreakerString)
{
HostCardTiebreakerInterface Interface =
(HostCardTiebreakerInterface)GetHostCardInterface(RoundSegmentType.Tiebreaker);
string ErrorString = "";
string JSONString = TiebreakerString.Result;
if (VRCJson.TryDeserializeFromJson(JSONString, out DataToken JSONResult))
{
if (JSONResult.TokenType == TokenType.DataDictionary)
{
DataDictionary TiebreakerDictionary = JSONResult.DataDictionary;
DataList TiebreakerRegions = TiebreakerDictionary.GetKeys();
Random.InitState(Networking.GetServerTimeInMilliseconds());
int TiebreakerIndex = Random.Range(0, TiebreakerRegions.Count);
string TiebreakerRegion = TiebreakerRegions[TiebreakerIndex].String;
Interface.ChoiceUI[1].text = TiebreakerRegion;
if (TiebreakerDictionary[TiebreakerRegion].TokenType == TokenType.DataDictionary)
{
DataDictionary RegionDictionary = TiebreakerDictionary[TiebreakerRegion].DataDictionary;
if (RegionDictionary.ContainsKey("Type") && RegionDictionary.ContainsKey("Key Locations"))
{
Interface.HeaderUI.text = "Tiebreaker | " + RegionDictionary["Type"].String;
if (RegionDictionary["Key Locations"].TokenType == TokenType.DataList)
{
DataList KeyLocations = RegionDictionary["Key Locations"].DataList;
for (int i = 0; i < KeyLocations.Count && i < Interface.CluesUI.Length; i++)
{
Interface.CluesUI[i].text = KeyLocations[i].String;
}
EnableBuzzInPeriodForPlayer(_TiebreakerPlayerNumbers[0]);
EnableBuzzInPeriodForPlayer(_TiebreakerPlayerNumbers[1]);
}
else
{
ErrorString = "The Key Locations key should be a list of locations.";
}
}
else
{
ErrorString = "Each region entry should have a region type and a list of key locations.";
}
}
else
{
ErrorString = "Ensure the elements of the root dictionary are all dictionaries.";
}
}
else
{
ErrorString = "Ensure the first element is a dictionary.";
}
}
else
{
ErrorString = "Could not parse JSON document.";
}
if (ErrorString != "")
{
Debug.LogError("Malformed tiebreaker data file. " + ErrorString);
}
}
public void TiebreakerIncorrectResponse()
{
int PodiumIndex = _BuzzedInPlayer - 1;
if (PodiumIndex >= 0 && PodiumIndex < _PlayerPodiums.Length)
{
NetworkCalling.SendCustomNetworkEvent(
(IUdonEventReceiver)_PlayerPodiums[PodiumIndex],
NetworkEventTarget.All,
"EnableBuzzInEffect", false);
}
_BuzzedInPlayer = -1;
_BuzzInAllowed = true;
RequestSerialization();
}
public void TiebreakerCorrectResponse()
{
int PodiumIndex = _BuzzedInPlayer - 1;
if (PodiumIndex >= 0 && PodiumIndex < _PlayerPodiums.Length)
{
_PlayerPodiums[PodiumIndex].AdjustScore(5);
}
_BuzzedInPlayer = -1;
DisableBuzzers();
EndBuzzInPeriod();
EnableInteraction("End Tiebreaker");
}
private void ResetMultipleChoiceInterface(HostCardMultipleChoiceInterface Interface)
{
@@ -960,6 +1117,21 @@ public class GameManagerRound1 : GameManagerBase
ResetBuzzers();
}
private void EnableBuzzInPeriodForPlayer(int PlayerNumber)
{
for (int i = 0; i < _PlayerPodiums.Length; i++)
{
if (_PlayerPodiums[i].PlayerNumber == PlayerNumber)
{
_PlayerBuzzInAllowed[i] = true;
NetworkCalling.SendCustomNetworkEvent((IUdonEventReceiver)_PlayerPodiums[i], NetworkEventTarget.All, "EnableBuzzer", true);
_BuzzedInPlayer = -1;
break;
}
}
_BuzzInAllowed = true;
}
private void WaitForBuzzInsWithoutLastPlayer()
{
_BuzzInAllowed = true;
@@ -967,12 +1139,13 @@ public class GameManagerRound1 : GameManagerBase
if (PodiumIndex >= 0 && PodiumIndex < _PlayerPodiums.Length)
{
NetworkCalling.SendCustomNetworkEvent(
(IUdonEventReceiver)_PlayerPodiums[_BuzzedInPlayer - 1],
(IUdonEventReceiver)_PlayerPodiums[PodiumIndex],
NetworkEventTarget.All,
"EnableBuzzInEffect", false);
_BuzzedInPlayer = -1;
RequestSerialization();
}
RequestSerialization();
}
[NetworkCallable]
@@ -1038,12 +1211,13 @@ public class GameManagerRound1 : GameManagerBase
// are just fucking terrible languages. C++ figured this problem out in at
// least 1985, and it turns out the proper solution was "it's not a problem,
// it's two numbers, they're the same fucking thing".
switch ((int)_CurrentQuestion["Type"].Number)
switch (_CurrentQuestionType)
{
case (int)RoundSegmentType.MultipleChoice: AdvanceMultipleChoiceStage(); break;
case (int)RoundSegmentType.LightningRound: AdvanceLightningRoundQuestion(); break;
case (int)RoundSegmentType.TheChase: AdvanceTheChase(); break;
case (int)RoundSegmentType.FinalRound: AdvanceFinalRound(); break;
case RoundSegmentType.MultipleChoice: AdvanceMultipleChoiceStage(); break;
case RoundSegmentType.LightningRound: AdvanceLightningRoundQuestion(); break;
case RoundSegmentType.TheChase: AdvanceTheChase(); break;
case RoundSegmentType.FinalRound: AdvanceFinalRound(); break;
case RoundSegmentType.Tiebreaker: AdvanceTiebreaker(); break;
}
RequestSerialization();
@@ -1126,6 +1300,16 @@ public class GameManagerRound1 : GameManagerBase
}
}
private void AdvanceTiebreaker()
{
switch(_QuestionStage)
{
case 1: BeginTiebreakerRound(); break;
case 2: AdvanceToNextQuestion(); break;
default: break;
}
}
public VRCUrl GetMapURL(int MapIndex)
{
@@ -1147,7 +1331,9 @@ public class GameManagerRound1 : GameManagerBase
{
HostCardBetweenRoundsInterface Interface =
(HostCardBetweenRoundsInterface)GetHostCardInterface(RoundSegmentType.BetweenSegments);
Interface.HeaderUI.text = "Upcoming Question: " + RoundSegmentTypeToString((RoundSegmentType)((int)_CurrentQuestion["Type"].Number));
Interface.HeaderUI.text = "Upcoming Question: " + RoundSegmentTypeToString(_CurrentQuestionType);
return Interface;
}
}
@@ -197,6 +197,15 @@ public class GameManagerRound2 : GameManagerBase
}
private void EndRound()
{
HostCardBetweenRoundsInterface Interface =
(HostCardBetweenRoundsInterface)GetHostCardInterface(RoundSegmentType.BetweenSegments);
Interface.HeaderUI.text = "Round is over. Let's go to the map!";
_CaseManager.ContinueToRound3();
}
public void LocationBoardReset()
{
NetworkCalling.SendCustomNetworkEvent(
@@ -253,9 +262,9 @@ public class GameManagerRound2 : GameManagerBase
_StageIndex++;
switch(_StageIndex)
{
case 1: DisplayBriefing(); break;
case 2: BeginRound(); break;
case 3: _CaseManager.ContinueToRound3(); break;
case 1: DisplayBriefing(); break;
case 2: BeginRound(); break;
case 3: EndRound(); break;
}
}