Position markers on pedestals now activate when a podium is manually claimed.
This commit is contained in:
@@ -144,9 +144,15 @@ public class GameManagerBase : UdonSharpBehaviour
|
||||
EnableAudienceSilencer(false);
|
||||
|
||||
_HostPositionMarker.SetPlayer(_CaseManager.GetHostOwner().displayName);
|
||||
|
||||
string[] WinningPlayers = _CaseManager.GetCurrentWinningPlayers();
|
||||
for (int i = 0; i < _PlayerPositionMarkers.Length; i++)
|
||||
{
|
||||
if (_PlayerPositionMarkers[i].IsSet())
|
||||
{
|
||||
continue;
|
||||
}
|
||||
|
||||
string PlayerName = "";
|
||||
if (i < WinningPlayers.Length)
|
||||
{
|
||||
|
||||
@@ -44,7 +44,7 @@ MonoBehaviour:
|
||||
Data:
|
||||
- Name:
|
||||
Entry: 12
|
||||
Data: 24
|
||||
Data: 25
|
||||
- Name:
|
||||
Entry: 7
|
||||
Data:
|
||||
@@ -1028,19 +1028,19 @@ MonoBehaviour:
|
||||
Data:
|
||||
- Name: $k
|
||||
Entry: 1
|
||||
Data: _OwnershipInteract
|
||||
Data: _PositionMarker
|
||||
- Name: $v
|
||||
Entry: 7
|
||||
Data: 68|UdonSharp.Compiler.FieldDefinition, UdonSharp.Editor
|
||||
- Name: <Name>k__BackingField
|
||||
Entry: 1
|
||||
Data: _OwnershipInteract
|
||||
Data: _PositionMarker
|
||||
- Name: <UserType>k__BackingField
|
||||
Entry: 7
|
||||
Data: 69|System.RuntimeType, mscorlib
|
||||
- Name:
|
||||
Entry: 1
|
||||
Data: CustomEventInteraction, Assembly-CSharp
|
||||
Data: PositionMarker, Assembly-CSharp
|
||||
- Name:
|
||||
Entry: 8
|
||||
Data:
|
||||
@@ -1088,10 +1088,70 @@ MonoBehaviour:
|
||||
Data:
|
||||
- Name: $k
|
||||
Entry: 1
|
||||
Data: _HighlightEffect
|
||||
Data: _OwnershipInteract
|
||||
- Name: $v
|
||||
Entry: 7
|
||||
Data: 72|UdonSharp.Compiler.FieldDefinition, UdonSharp.Editor
|
||||
- Name: <Name>k__BackingField
|
||||
Entry: 1
|
||||
Data: _OwnershipInteract
|
||||
- Name: <UserType>k__BackingField
|
||||
Entry: 7
|
||||
Data: 73|System.RuntimeType, mscorlib
|
||||
- Name:
|
||||
Entry: 1
|
||||
Data: CustomEventInteraction, Assembly-CSharp
|
||||
- Name:
|
||||
Entry: 8
|
||||
Data:
|
||||
- Name: <SystemType>k__BackingField
|
||||
Entry: 9
|
||||
Data: 7
|
||||
- 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: true
|
||||
- Name: _fieldAttributes
|
||||
Entry: 7
|
||||
Data: 74|System.Collections.Generic.List`1[[System.Attribute, mscorlib]], mscorlib
|
||||
- Name:
|
||||
Entry: 12
|
||||
Data: 1
|
||||
- Name:
|
||||
Entry: 7
|
||||
Data: 75|UnityEngine.SerializeField, UnityEngine.CoreModule
|
||||
- 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: _HighlightEffect
|
||||
- Name: $v
|
||||
Entry: 7
|
||||
Data: 76|UdonSharp.Compiler.FieldDefinition, UdonSharp.Editor
|
||||
- Name: <Name>k__BackingField
|
||||
Entry: 1
|
||||
Data: _HighlightEffect
|
||||
@@ -1115,13 +1175,13 @@ MonoBehaviour:
|
||||
Data: true
|
||||
- Name: _fieldAttributes
|
||||
Entry: 7
|
||||
Data: 73|System.Collections.Generic.List`1[[System.Attribute, mscorlib]], mscorlib
|
||||
Data: 77|System.Collections.Generic.List`1[[System.Attribute, mscorlib]], mscorlib
|
||||
- Name:
|
||||
Entry: 12
|
||||
Data: 3
|
||||
- Name:
|
||||
Entry: 7
|
||||
Data: 74|UnityEngine.SpaceAttribute, UnityEngine.CoreModule
|
||||
Data: 78|UnityEngine.SpaceAttribute, UnityEngine.CoreModule
|
||||
- Name: height
|
||||
Entry: 4
|
||||
Data: 8
|
||||
@@ -1130,7 +1190,7 @@ MonoBehaviour:
|
||||
Data:
|
||||
- Name:
|
||||
Entry: 7
|
||||
Data: 75|UnityEngine.HeaderAttribute, UnityEngine.CoreModule
|
||||
Data: 79|UnityEngine.HeaderAttribute, UnityEngine.CoreModule
|
||||
- Name: header
|
||||
Entry: 1
|
||||
Data: Effects
|
||||
@@ -1139,7 +1199,7 @@ MonoBehaviour:
|
||||
Data:
|
||||
- Name:
|
||||
Entry: 7
|
||||
Data: 76|UnityEngine.SerializeField, UnityEngine.CoreModule
|
||||
Data: 80|UnityEngine.SerializeField, UnityEngine.CoreModule
|
||||
- Name:
|
||||
Entry: 8
|
||||
Data:
|
||||
@@ -1163,7 +1223,7 @@ MonoBehaviour:
|
||||
Data: _ScorecardObject
|
||||
- Name: $v
|
||||
Entry: 7
|
||||
Data: 77|UdonSharp.Compiler.FieldDefinition, UdonSharp.Editor
|
||||
Data: 81|UdonSharp.Compiler.FieldDefinition, UdonSharp.Editor
|
||||
- Name: <Name>k__BackingField
|
||||
Entry: 1
|
||||
Data: _ScorecardObject
|
||||
@@ -1185,66 +1245,6 @@ MonoBehaviour:
|
||||
- Name: <IsSerialized>k__BackingField
|
||||
Entry: 5
|
||||
Data: true
|
||||
- Name: _fieldAttributes
|
||||
Entry: 7
|
||||
Data: 78|System.Collections.Generic.List`1[[System.Attribute, mscorlib]], mscorlib
|
||||
- Name:
|
||||
Entry: 12
|
||||
Data: 1
|
||||
- Name:
|
||||
Entry: 7
|
||||
Data: 79|UnityEngine.SerializeField, UnityEngine.CoreModule
|
||||
- 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: _NameplateUI
|
||||
- Name: $v
|
||||
Entry: 7
|
||||
Data: 80|UdonSharp.Compiler.FieldDefinition, UdonSharp.Editor
|
||||
- Name: <Name>k__BackingField
|
||||
Entry: 1
|
||||
Data: _NameplateUI
|
||||
- Name: <UserType>k__BackingField
|
||||
Entry: 7
|
||||
Data: 81|System.RuntimeType, mscorlib
|
||||
- Name:
|
||||
Entry: 1
|
||||
Data: TMPro.TextMeshProUGUI, Unity.TextMeshPro
|
||||
- Name:
|
||||
Entry: 8
|
||||
Data:
|
||||
- Name: <SystemType>k__BackingField
|
||||
Entry: 9
|
||||
Data: 81
|
||||
- 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: true
|
||||
- Name: _fieldAttributes
|
||||
Entry: 7
|
||||
Data: 82|System.Collections.Generic.List`1[[System.Attribute, mscorlib]], mscorlib
|
||||
@@ -1274,19 +1274,25 @@ MonoBehaviour:
|
||||
Data:
|
||||
- Name: $k
|
||||
Entry: 1
|
||||
Data: _ScorecardUI
|
||||
Data: _NameplateUI
|
||||
- Name: $v
|
||||
Entry: 7
|
||||
Data: 84|UdonSharp.Compiler.FieldDefinition, UdonSharp.Editor
|
||||
- Name: <Name>k__BackingField
|
||||
Entry: 1
|
||||
Data: _ScorecardUI
|
||||
Data: _NameplateUI
|
||||
- Name: <UserType>k__BackingField
|
||||
Entry: 9
|
||||
Data: 81
|
||||
Entry: 7
|
||||
Data: 85|System.RuntimeType, mscorlib
|
||||
- Name:
|
||||
Entry: 1
|
||||
Data: TMPro.TextMeshProUGUI, Unity.TextMeshPro
|
||||
- Name:
|
||||
Entry: 8
|
||||
Data:
|
||||
- Name: <SystemType>k__BackingField
|
||||
Entry: 9
|
||||
Data: 81
|
||||
Data: 85
|
||||
- Name: <SyncMode>k__BackingField
|
||||
Entry: 7
|
||||
Data: System.Nullable`1[[UdonSharp.UdonSyncMode, UdonSharp.Runtime]], mscorlib
|
||||
@@ -1301,13 +1307,13 @@ MonoBehaviour:
|
||||
Data: true
|
||||
- Name: _fieldAttributes
|
||||
Entry: 7
|
||||
Data: 85|System.Collections.Generic.List`1[[System.Attribute, mscorlib]], mscorlib
|
||||
Data: 86|System.Collections.Generic.List`1[[System.Attribute, mscorlib]], mscorlib
|
||||
- Name:
|
||||
Entry: 12
|
||||
Data: 1
|
||||
- Name:
|
||||
Entry: 7
|
||||
Data: 86|UnityEngine.SerializeField, UnityEngine.CoreModule
|
||||
Data: 87|UnityEngine.SerializeField, UnityEngine.CoreModule
|
||||
- Name:
|
||||
Entry: 8
|
||||
Data:
|
||||
@@ -1328,25 +1334,19 @@ MonoBehaviour:
|
||||
Data:
|
||||
- Name: $k
|
||||
Entry: 1
|
||||
Data: _ScorecardBackground
|
||||
Data: _ScorecardUI
|
||||
- Name: $v
|
||||
Entry: 7
|
||||
Data: 87|UdonSharp.Compiler.FieldDefinition, UdonSharp.Editor
|
||||
Data: 88|UdonSharp.Compiler.FieldDefinition, UdonSharp.Editor
|
||||
- Name: <Name>k__BackingField
|
||||
Entry: 1
|
||||
Data: _ScorecardBackground
|
||||
Data: _ScorecardUI
|
||||
- Name: <UserType>k__BackingField
|
||||
Entry: 7
|
||||
Data: 88|System.RuntimeType, mscorlib
|
||||
- Name:
|
||||
Entry: 1
|
||||
Data: UnityEngine.UI.Image, UnityEngine.UI
|
||||
- Name:
|
||||
Entry: 8
|
||||
Data:
|
||||
Entry: 9
|
||||
Data: 85
|
||||
- Name: <SystemType>k__BackingField
|
||||
Entry: 9
|
||||
Data: 88
|
||||
Data: 85
|
||||
- Name: <SyncMode>k__BackingField
|
||||
Entry: 7
|
||||
Data: System.Nullable`1[[UdonSharp.UdonSyncMode, UdonSharp.Runtime]], mscorlib
|
||||
@@ -1388,10 +1388,70 @@ MonoBehaviour:
|
||||
Data:
|
||||
- Name: $k
|
||||
Entry: 1
|
||||
Data: _SpawnPoint
|
||||
Data: _ScorecardBackground
|
||||
- Name: $v
|
||||
Entry: 7
|
||||
Data: 91|UdonSharp.Compiler.FieldDefinition, UdonSharp.Editor
|
||||
- Name: <Name>k__BackingField
|
||||
Entry: 1
|
||||
Data: _ScorecardBackground
|
||||
- Name: <UserType>k__BackingField
|
||||
Entry: 7
|
||||
Data: 92|System.RuntimeType, mscorlib
|
||||
- Name:
|
||||
Entry: 1
|
||||
Data: UnityEngine.UI.Image, UnityEngine.UI
|
||||
- Name:
|
||||
Entry: 8
|
||||
Data:
|
||||
- Name: <SystemType>k__BackingField
|
||||
Entry: 9
|
||||
Data: 92
|
||||
- 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: true
|
||||
- Name: _fieldAttributes
|
||||
Entry: 7
|
||||
Data: 93|System.Collections.Generic.List`1[[System.Attribute, mscorlib]], mscorlib
|
||||
- Name:
|
||||
Entry: 12
|
||||
Data: 1
|
||||
- Name:
|
||||
Entry: 7
|
||||
Data: 94|UnityEngine.SerializeField, UnityEngine.CoreModule
|
||||
- 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: _SpawnPoint
|
||||
- Name: $v
|
||||
Entry: 7
|
||||
Data: 95|UdonSharp.Compiler.FieldDefinition, UdonSharp.Editor
|
||||
- Name: <Name>k__BackingField
|
||||
Entry: 1
|
||||
Data: _SpawnPoint
|
||||
@@ -1415,13 +1475,13 @@ MonoBehaviour:
|
||||
Data: true
|
||||
- Name: _fieldAttributes
|
||||
Entry: 7
|
||||
Data: 92|System.Collections.Generic.List`1[[System.Attribute, mscorlib]], mscorlib
|
||||
Data: 96|System.Collections.Generic.List`1[[System.Attribute, mscorlib]], mscorlib
|
||||
- Name:
|
||||
Entry: 12
|
||||
Data: 3
|
||||
- Name:
|
||||
Entry: 7
|
||||
Data: 93|UnityEngine.SpaceAttribute, UnityEngine.CoreModule
|
||||
Data: 97|UnityEngine.SpaceAttribute, UnityEngine.CoreModule
|
||||
- Name: height
|
||||
Entry: 4
|
||||
Data: 8
|
||||
@@ -1430,7 +1490,7 @@ MonoBehaviour:
|
||||
Data:
|
||||
- Name:
|
||||
Entry: 7
|
||||
Data: 94|UnityEngine.HeaderAttribute, UnityEngine.CoreModule
|
||||
Data: 98|UnityEngine.HeaderAttribute, UnityEngine.CoreModule
|
||||
- Name: header
|
||||
Entry: 1
|
||||
Data: Miscellaneous
|
||||
@@ -1439,7 +1499,7 @@ MonoBehaviour:
|
||||
Data:
|
||||
- Name:
|
||||
Entry: 7
|
||||
Data: 95|UnityEngine.SerializeField, UnityEngine.CoreModule
|
||||
Data: 99|UnityEngine.SerializeField, UnityEngine.CoreModule
|
||||
- Name:
|
||||
Entry: 8
|
||||
Data:
|
||||
@@ -1463,7 +1523,7 @@ MonoBehaviour:
|
||||
Data: _FlashingScoreboardCounter
|
||||
- Name: $v
|
||||
Entry: 7
|
||||
Data: 96|UdonSharp.Compiler.FieldDefinition, UdonSharp.Editor
|
||||
Data: 100|UdonSharp.Compiler.FieldDefinition, UdonSharp.Editor
|
||||
- Name: <Name>k__BackingField
|
||||
Entry: 1
|
||||
Data: _FlashingScoreboardCounter
|
||||
@@ -1487,7 +1547,8 @@ MonoBehaviour:
|
||||
Data: false
|
||||
- Name: _fieldAttributes
|
||||
Entry: 7
|
||||
Data: 97|System.Collections.Generic.List`1[[System.Attribute, mscorlib]], mscorlib
|
||||
Data: 101|System.Collections.Generic.List`1[[System.Attribute, mscorlib]],
|
||||
mscorlib
|
||||
- Name:
|
||||
Entry: 12
|
||||
Data: 0
|
||||
|
||||
@@ -19,6 +19,7 @@ public class PlayerPodium : UdonSharpBehaviour
|
||||
[UdonSynced, FieldChangeCallback(nameof(PlayerName))] private string _PlayerName = "";
|
||||
[UdonSynced] private int _PlayerID = -1;
|
||||
[UdonSynced, FieldChangeCallback(nameof(PlayerScore))] private int _PlayerScore = 50;
|
||||
|
||||
[UdonSynced, FieldChangeCallback(nameof(ShowScoreCard))] private bool _ShowScoreCard = false;
|
||||
[UdonSynced, FieldChangeCallback(nameof(FlashScoreboard))] private bool _FlashScoreboard = false;
|
||||
|
||||
@@ -34,6 +35,7 @@ public class PlayerPodium : UdonSharpBehaviour
|
||||
[SerializeField] private VideoLoadIndicator _VideoLoadIndicator;
|
||||
[SerializeField] private Transform _AuxiliaryVideoScreen;
|
||||
[SerializeField] private Transform _AuxiliaryMapScreen;
|
||||
[SerializeField] private PositionMarker _PositionMarker;
|
||||
|
||||
[SerializeField] private CustomEventInteraction _OwnershipInteract;
|
||||
|
||||
@@ -111,6 +113,7 @@ public class PlayerPodium : UdonSharpBehaviour
|
||||
|
||||
_Pedestal.EnableStandInteractLocally(true);
|
||||
_Pedestal.AdjustHeight(Networking.LocalPlayer);
|
||||
_PositionMarker.SetPlayer(PlayerName);
|
||||
|
||||
EnableOwnershipTransfer = false;
|
||||
|
||||
@@ -124,6 +127,7 @@ public class PlayerPodium : UdonSharpBehaviour
|
||||
_PlayerID = -1;
|
||||
|
||||
_Pedestal.EnableStandInteractLocally(false);
|
||||
_PositionMarker.ClearPlayer();
|
||||
|
||||
EnableOwnershipTransfer = true;
|
||||
|
||||
|
||||
@@ -44,7 +44,7 @@ MonoBehaviour:
|
||||
Data:
|
||||
- Name:
|
||||
Entry: 12
|
||||
Data: 5
|
||||
Data: 6
|
||||
- Name:
|
||||
Entry: 7
|
||||
Data:
|
||||
@@ -245,25 +245,25 @@ MonoBehaviour:
|
||||
Data:
|
||||
- Name: $k
|
||||
Entry: 1
|
||||
Data: _OwnershipTransferInteract
|
||||
Data: _PositionMarker
|
||||
- Name: $v
|
||||
Entry: 7
|
||||
Data: 16|UdonSharp.Compiler.FieldDefinition, UdonSharp.Editor
|
||||
- Name: <Name>k__BackingField
|
||||
Entry: 1
|
||||
Data: _OwnershipTransferInteract
|
||||
Data: _PositionMarker
|
||||
- Name: <UserType>k__BackingField
|
||||
Entry: 7
|
||||
Data: 17|System.RuntimeType, mscorlib
|
||||
- Name:
|
||||
Entry: 1
|
||||
Data: UnityEngine.GameObject, UnityEngine.CoreModule
|
||||
Data: PositionMarker, Assembly-CSharp
|
||||
- Name:
|
||||
Entry: 8
|
||||
Data:
|
||||
- Name: <SystemType>k__BackingField
|
||||
Entry: 9
|
||||
Data: 17
|
||||
Data: 12
|
||||
- Name: <SyncMode>k__BackingField
|
||||
Entry: 7
|
||||
Data: System.Nullable`1[[UdonSharp.UdonSyncMode, UdonSharp.Runtime]], mscorlib
|
||||
@@ -305,19 +305,19 @@ MonoBehaviour:
|
||||
Data:
|
||||
- Name: $k
|
||||
Entry: 1
|
||||
Data: _SpawnPoint
|
||||
Data: _OwnershipTransferInteract
|
||||
- Name: $v
|
||||
Entry: 7
|
||||
Data: 20|UdonSharp.Compiler.FieldDefinition, UdonSharp.Editor
|
||||
- Name: <Name>k__BackingField
|
||||
Entry: 1
|
||||
Data: _SpawnPoint
|
||||
Data: _OwnershipTransferInteract
|
||||
- Name: <UserType>k__BackingField
|
||||
Entry: 7
|
||||
Data: 21|System.RuntimeType, mscorlib
|
||||
- Name:
|
||||
Entry: 1
|
||||
Data: UnityEngine.Transform, UnityEngine.CoreModule
|
||||
Data: UnityEngine.GameObject, UnityEngine.CoreModule
|
||||
- Name:
|
||||
Entry: 8
|
||||
Data:
|
||||
@@ -339,12 +339,72 @@ MonoBehaviour:
|
||||
- Name: _fieldAttributes
|
||||
Entry: 7
|
||||
Data: 22|System.Collections.Generic.List`1[[System.Attribute, mscorlib]], mscorlib
|
||||
- Name:
|
||||
Entry: 12
|
||||
Data: 1
|
||||
- Name:
|
||||
Entry: 7
|
||||
Data: 23|UnityEngine.SerializeField, UnityEngine.CoreModule
|
||||
- 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: _SpawnPoint
|
||||
- Name: $v
|
||||
Entry: 7
|
||||
Data: 24|UdonSharp.Compiler.FieldDefinition, UdonSharp.Editor
|
||||
- Name: <Name>k__BackingField
|
||||
Entry: 1
|
||||
Data: _SpawnPoint
|
||||
- Name: <UserType>k__BackingField
|
||||
Entry: 7
|
||||
Data: 25|System.RuntimeType, mscorlib
|
||||
- Name:
|
||||
Entry: 1
|
||||
Data: UnityEngine.Transform, UnityEngine.CoreModule
|
||||
- Name:
|
||||
Entry: 8
|
||||
Data:
|
||||
- Name: <SystemType>k__BackingField
|
||||
Entry: 9
|
||||
Data: 25
|
||||
- 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: true
|
||||
- Name: _fieldAttributes
|
||||
Entry: 7
|
||||
Data: 26|System.Collections.Generic.List`1[[System.Attribute, mscorlib]], mscorlib
|
||||
- Name:
|
||||
Entry: 12
|
||||
Data: 3
|
||||
- Name:
|
||||
Entry: 7
|
||||
Data: 23|UnityEngine.SpaceAttribute, UnityEngine.CoreModule
|
||||
Data: 27|UnityEngine.SpaceAttribute, UnityEngine.CoreModule
|
||||
- Name: height
|
||||
Entry: 4
|
||||
Data: 8
|
||||
@@ -353,7 +413,7 @@ MonoBehaviour:
|
||||
Data:
|
||||
- Name:
|
||||
Entry: 7
|
||||
Data: 24|UnityEngine.HeaderAttribute, UnityEngine.CoreModule
|
||||
Data: 28|UnityEngine.HeaderAttribute, UnityEngine.CoreModule
|
||||
- Name: header
|
||||
Entry: 1
|
||||
Data: Miscellaneous
|
||||
@@ -362,7 +422,7 @@ MonoBehaviour:
|
||||
Data:
|
||||
- Name:
|
||||
Entry: 7
|
||||
Data: 25|UnityEngine.SerializeField, UnityEngine.CoreModule
|
||||
Data: 29|UnityEngine.SerializeField, UnityEngine.CoreModule
|
||||
- Name:
|
||||
Entry: 8
|
||||
Data:
|
||||
|
||||
@@ -15,6 +15,7 @@ public class PlayerPodiumRound2 : UdonSharpBehaviour
|
||||
|
||||
[Header("Objects")]
|
||||
[SerializeField] private PlayerPedestal _Pedestal;
|
||||
[SerializeField] private PositionMarker _PositionMarker;
|
||||
[SerializeField] private GameObject _OwnershipTransferInteract;
|
||||
|
||||
[Space]
|
||||
@@ -58,8 +59,7 @@ public class PlayerPodiumRound2 : UdonSharpBehaviour
|
||||
|
||||
public bool SetPlayer(string Player, bool EnableOwnershipInteract = false)
|
||||
{
|
||||
VRCPlayerApi[] Players = new VRCPlayerApi[VRCPlayerApi.GetPlayerCount()];
|
||||
VRCPlayerApi.GetPlayers(Players);
|
||||
VRCPlayerApi[] Players = VRCPlayerApi.GetPlayers();
|
||||
for (int i = 0; i < Players.Length; i++)
|
||||
{
|
||||
VRCPlayerApi PlayerObject = Players[i];
|
||||
@@ -96,6 +96,8 @@ public class PlayerPodiumRound2 : UdonSharpBehaviour
|
||||
_Pedestal.EnableStandInteractLocally(true);
|
||||
_Pedestal.AdjustHeight(Networking.LocalPlayer);
|
||||
|
||||
_PositionMarker.SetPlayer(_PlayerName);
|
||||
|
||||
_SetPlayer_Synced();
|
||||
RequestSerialization();
|
||||
}
|
||||
@@ -133,6 +135,7 @@ public class PlayerPodiumRound2 : UdonSharpBehaviour
|
||||
_EnableOwnershipInteract = EnableOwnershipInteract;
|
||||
|
||||
_Pedestal.EnableStandInteractLocally(false);
|
||||
_PositionMarker.ClearPlayer();
|
||||
_OwnershipTransferInteract.SetActive(_EnableOwnershipInteract);
|
||||
|
||||
RequestSerialization();
|
||||
|
||||
@@ -10,7 +10,7 @@ public class PositionMarker : UdonSharpBehaviour
|
||||
{
|
||||
[SerializeField] private GameObject _Marker;
|
||||
|
||||
[UdonSynced] private string _PlayerName;
|
||||
[UdonSynced] private string _PlayerName = "";
|
||||
|
||||
|
||||
public override void OnDeserialization(DeserializationResult Result)
|
||||
@@ -21,6 +21,8 @@ public class PositionMarker : UdonSharpBehaviour
|
||||
|
||||
public void SetPlayer(string Name)
|
||||
{
|
||||
Networking.SetOwner(Networking.LocalPlayer, gameObject);
|
||||
|
||||
_PlayerName = Name;
|
||||
_SetPlayer_Synced();
|
||||
RequestSerialization();
|
||||
@@ -32,8 +34,15 @@ public class PositionMarker : UdonSharpBehaviour
|
||||
|
||||
public void ClearPlayer()
|
||||
{
|
||||
Networking.SetOwner(Networking.LocalPlayer, gameObject);
|
||||
|
||||
_PlayerName = "";
|
||||
_SetPlayer_Synced();
|
||||
RequestSerialization();
|
||||
}
|
||||
|
||||
public bool IsSet()
|
||||
{
|
||||
return _PlayerName != "";
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user