12345678910111213141516171819202122232425262728293031323334 |
- using LitJson;
- using SUIFW;
- using System.Collections;
- using System.Collections.Generic;
- using UnityEngine;
- public class StartProject : BaseUIForms
- {
- // Start is called before the first frame update
- void Start()
- {
- WSHandler.Office.OnInvitee += Invitee;
- ShowUIForms(SysConst.StarAppForms);
- }
- private void Invitee(JsonData data)
- {
- WSHandler.Office.ChangeUserType(UserInfo.BusyType);
- string peerId = data["data"]["peerId"].ToString();
- string nickName = data["data"]["nickName"].ToString();
- string roomId = data["data"]["roomId"].ToString();
- string avatar = data["data"]["avatar"].ToString();
- ShowUIForms(SysConst.ListenForms);
- if (ListenForms.Instance)
- {
- ListenForms.Instance.Init(peerId, roomId, nickName, avatar, true);
- }
- }
- private void OnDestroy()
- {
- WSHandler.Office.OnInvitee -= Invitee;
- }
- }
|