This commit is contained in:
parent
b1c54e7f3f
commit
fb2d1ef9a5
|
@ -724,7 +724,7 @@ public class View_Panel2 : XUIPanel
|
|||
if (upsd.state)
|
||||
{
|
||||
submitInstruct.text = "提交成功";
|
||||
|
||||
GlobalFlag.practiceSeatId = practiceSeatId;
|
||||
}
|
||||
else
|
||||
{
|
||||
|
@ -843,7 +843,21 @@ public class View_Panel2 : XUIPanel
|
|||
{
|
||||
CreateAllUser(dataItemTemp);
|
||||
}
|
||||
}
|
||||
|
||||
private void OnDisable()
|
||||
{
|
||||
Debug.Log("OnDisable");
|
||||
AdamSync.SyncCreateRoom.createRoomRequset -= OnCreateRoom;
|
||||
AdamSync.SyncCreateRoom.joinRoomRequset += OnJoinRoom;
|
||||
AdamSync.SyncCreateRoom.getRoomsRequset += OnGetRooms;
|
||||
}
|
||||
private void OnDestory()
|
||||
{
|
||||
Debug.Log("OnDestory");
|
||||
AdamSync.SyncCreateRoom.createRoomRequset -= OnCreateRoom;
|
||||
AdamSync.SyncCreateRoom.joinRoomRequset -= OnJoinRoom;
|
||||
AdamSync.SyncCreateRoom.getRoomsRequset -= OnGetRooms;
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -24,7 +24,7 @@ public class GameManager : MonoBehaviour
|
|||
spt.gameObject.transform.position = spawnPos.position;
|
||||
spt.gameObject.transform.eulerAngles = spawnPos.eulerAngles;
|
||||
spt.SetPlayerInfo(ulong.Parse(GlobalFlag.currentUser.user_id), GlobalFlag.currentUser.login_name, ulong.Parse(GlobalFlag.roomID), true);
|
||||
if (UIBootstrap.Instance.GetRoleByIDPracticeId(GlobalFlag.roomID) == "0")
|
||||
if (UIBootstrap.Instance.GetRoleByIDPracticeId(GlobalFlag.practiceSeatId) == "0")
|
||||
{
|
||||
spt.GetComponent<Camera>().cullingMask = ~(1 << 11);
|
||||
}
|
||||
|
|
|
@ -46,7 +46,7 @@ public class UIBootstrap : MonoSingleton<UIBootstrap>
|
|||
{
|
||||
for (int i = 0; i < subjectInfo.Count; i++)
|
||||
{
|
||||
if (subjectInfo[i].SeatId == practiceID)
|
||||
if (subjectInfo[i].Id == practiceID)
|
||||
{
|
||||
return subjectInfo[i].Role;
|
||||
}
|
||||
|
|
|
@ -7,4 +7,5 @@ public class GlobalFlag
|
|||
public static UserInfo currentUser;
|
||||
public static string roomID;
|
||||
public static string practiceId;
|
||||
public static string practiceSeatId;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue