网上演练贵港万达广场(人员密集)
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 

38 lines
1.2 KiB

using System.Collections;
using System.Collections.Generic;
using UnityEngine;
using UnityEngine.UI;
public class RoomInfoPanel : MonoBehaviour
{
public Image SelectSceneImage;
public Text SceneName;
public Text IntroduceText;
public Text Creater;
public Text ScenceType;
public Text RoomNum;
// Use this for initialization
void Start()
{
//:ToDo
//房间缩略图
Texture2D tex= Resources.Load<Texture2D>("Common/DongYouLiQing");
SelectSceneImage.sprite = Sprite.Create(tex, new Rect(0, 0, tex.width, tex.height), Vector2.one * 0.5f);
SetRoomInfo();
}
public void SetRoomInfo()
{
SceneName.text = CurrentUserInfo.room.Map.name;
IntroduceText.text = CurrentUserInfo.room.Map.introduction;
Creater.text = CurrentUserInfo.room.Owner.UserInfo.Username;
ScenceType.text = CurrentUserInfo.room.Map.sceneType.ToString();
if (ScenceType.text== "堆场_仓库_厂房")
{
ScenceType.text = "堆场,仓库,厂房";
}
RoomNum.text = CurrentUserInfo.room.UserList.Count.ToString() + "/" + CurrentUserInfo.room.MaxPersons;
}
}