PlayerData.cs 681 B

1234567891011121314151617181920212223242526272829303132
  1. using UnityEngine;
  2. //客户端数据
  3. public class PlayerData
  4. {
  5. public string ClientIP;
  6. //临时的连接信息
  7. public bool IsConnected;
  8. public ulong ClientId;
  9. //todo,账号信息
  10. public string PlayerName;
  11. //是否视频流
  12. public bool IsVideoClient;
  13. public GameObject Anchor;
  14. public PlayerData(ulong clientID, ConnectionPayload connectionData, bool isConnected = false)
  15. {
  16. ClientIP = connectionData.ip;
  17. ClientId = clientID;
  18. IsConnected = isConnected;
  19. PlayerName = connectionData.playerName;
  20. IsVideoClient = connectionData.isVideo;
  21. }
  22. public void Reinitialize()
  23. {
  24. }
  25. }