玩家位置
This commit is contained in:
parent
023dd663e1
commit
d13685c99e
@ -233,10 +233,10 @@ public class test : MonoBehaviour
|
|||||||
|
|
||||||
|
|
||||||
//11.开始计时
|
//11.开始计时
|
||||||
void RoomStartTime()
|
void RoomStartTime(string rooid)
|
||||||
{
|
{
|
||||||
JoinRoomRequest data = new JoinRoomRequest();
|
JoinRoomRequest data = new JoinRoomRequest();
|
||||||
data.RoomId = "168888";
|
data.RoomId = rooid;
|
||||||
WSMessage msg = new WSMessage();
|
WSMessage msg = new WSMessage();
|
||||||
msg.Module = "hall";
|
msg.Module = "hall";
|
||||||
msg.ServiceName = "RoomStartTime";
|
msg.ServiceName = "RoomStartTime";
|
||||||
@ -644,7 +644,8 @@ public class test : MonoBehaviour
|
|||||||
byte[] joinByte = joinRoomResponse.Data.ToByteArray();
|
byte[] joinByte = joinRoomResponse.Data.ToByteArray();
|
||||||
PlayerJoinResponse playerJoinResponse = ProtoBufffer.DeSerialize<PlayerJoinResponse>(joinByte);
|
PlayerJoinResponse playerJoinResponse = ProtoBufffer.DeSerialize<PlayerJoinResponse>(joinByte);
|
||||||
Debug.Log("玩家:" + playerJoinResponse.UserName + "加入房间:" + playerJoinResponse.RoomId.ToString());
|
Debug.Log("玩家:" + playerJoinResponse.UserName + "加入房间:" + playerJoinResponse.RoomId.ToString());
|
||||||
|
GameObject.Find("Player").transform.position = new Vector3((float)playerJoinResponse.X, (float)playerJoinResponse.Y, (float)playerJoinResponse.Z);
|
||||||
|
Debug.Log("鯤소貫零");
|
||||||
|
|
||||||
break;
|
break;
|
||||||
|
|
||||||
|
@ -76,6 +76,7 @@ public class ReadRoom : MonoBehaviour
|
|||||||
//Player.CSZS.SetPlayerID(room.PlayerList[i].RoleId);
|
//Player.CSZS.SetPlayerID(room.PlayerList[i].RoleId);
|
||||||
Debug.Log("可以直接进入房间");
|
Debug.Log("可以直接进入房间");
|
||||||
SceneManager.LoadScene("Tmap 1");
|
SceneManager.LoadScene("Tmap 1");
|
||||||
|
Debug.Log(room.RoomId);
|
||||||
test.JoinRoom(room.RoomId);
|
test.JoinRoom(room.RoomId);
|
||||||
//if,(GlobalData.ServerData.data.openId==)
|
//if,(GlobalData.ServerData.data.openId==)
|
||||||
//isenter = true;
|
//isenter = true;
|
||||||
@ -182,6 +183,7 @@ public class ReadRoom : MonoBehaviour
|
|||||||
//传人物职业ID
|
//传人物职业ID
|
||||||
//Player.CSZS.SetPlayerID(room.PlayerList[i].RoleId);
|
//Player.CSZS.SetPlayerID(room.PlayerList[i].RoleId);
|
||||||
Debug.Log("可以直接进入房间");
|
Debug.Log("可以直接进入房间");
|
||||||
|
test.JoinRoom(room.RoomId);
|
||||||
SceneManager.LoadScene("Tmap 1");
|
SceneManager.LoadScene("Tmap 1");
|
||||||
//if(GlobalData.ServerData.data.openId==)
|
//if(GlobalData.ServerData.data.openId==)
|
||||||
//.isenter = true;
|
//.isenter = true;
|
||||||
|
@ -4908,7 +4908,7 @@ MonoBehaviour:
|
|||||||
m_Name:
|
m_Name:
|
||||||
m_EditorClassIdentifier:
|
m_EditorClassIdentifier:
|
||||||
token:
|
token:
|
||||||
wEBScriptListener: {fileID: 0}
|
wEBScriptListener: {fileID: 7695717545649794845}
|
||||||
--- !u!222 &7801660036457041520
|
--- !u!222 &7801660036457041520
|
||||||
CanvasRenderer:
|
CanvasRenderer:
|
||||||
m_ObjectHideFlags: 0
|
m_ObjectHideFlags: 0
|
||||||
|
Loading…
Reference in New Issue
Block a user