对战界面&3d模型
This commit is contained in:
1 parent
4665feab7c
commit
597929cd32
130 files changed
+48220
-20627
No files matched your search
@@ -0,0 +1,40 @@
|
||||
|
||||
using Assets.Scripts;
|
||||
using System.Threading.Tasks;
|
||||
using UnityEngine;
|
||||
using UnityEngine.EventSystems;
|
||||
using UnityEngine.UI;
|
||||
|
||||
public class GameRoomListController : PFUIPanel
|
||||
{
|
||||
private RawImage Avatar;
|
||||
private GameObject CreateRoomBtn;
|
||||
private GameObject MapList;
|
||||
protected override void Awake()
|
||||
{
|
||||
base.Awake();
|
||||
}
|
||||
|
||||
protected override void Start()
|
||||
{
|
||||
base.Start();
|
||||
Avatar = transform.Find("Avatar").GetComponent<RawImage>();
|
||||
CreateRoomBtn = transform.Find("SwitchMode/GoList").gameObject;
|
||||
MapList = transform.Find("MapList").gameObject;
|
||||
Utils.DisplayImage(Avatar, App.CurrentUser.WxHeadImg);
|
||||
|
||||
|
||||
UIManager.AddEvent(CreateRoomBtn, UnityEngine.EventSystems.EventTriggerType.PointerClick, CreateGameRoom);
|
||||
}
|
||||
|
||||
private void Update()
|
||||
{
|
||||
|
||||
}
|
||||
//创建房间
|
||||
private void CreateGameRoom(BaseEventData data)
|
||||
{
|
||||
MapList.SetActive(true);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -0,0 +1,11 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 91e95d79d64980640a8c089210e5572c
|
||||
MonoImporter:
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
@@ -29,6 +29,7 @@ public class HomeController : PFUIPanel
|
||||
[SerializeField] Button BtnRide;
|
||||
[SerializeField] Transform userInfo;
|
||||
Transform BtnMatch, BtnTraining;
|
||||
Transform BtnBattle;
|
||||
private MainNav mainNav;
|
||||
private Dictionary<string, Sprite[]> dict;
|
||||
// Start is called before the first frame update
|
||||
@@ -55,6 +56,15 @@ public class HomeController : PFUIPanel
|
||||
});
|
||||
mainNav = this.transform.Find("MainNav").GetComponent<MainNav>();
|
||||
mainNav.ShowExit();
|
||||
|
||||
UIManager.AddEvent(transform.Find("TodayData/ChangePlayerBtn").gameObject, EventTriggerType.PointerClick, b =>
|
||||
{
|
||||
UIManager.ShowChangePlayerPanel();
|
||||
});
|
||||
BtnBattle = transform.Find("MainFuncContainer/BtnBattle");
|
||||
UIManager.AddEvent(BtnBattle.gameObject, EventTriggerType.PointerClick, GoGameRoom);
|
||||
UIManager.AddEvent(BtnBattle.gameObject, EventTriggerType.PointerEnter, OnHover);
|
||||
UIManager.AddEvent(BtnBattle.gameObject, EventTriggerType.PointerExit, OnExit);
|
||||
#endif
|
||||
var BtnContainer = transform.Find("MainFuncContainer");
|
||||
UIManager.AddEvent(BtnRide.gameObject, EventTriggerType.PointerClick, GoRide);
|
||||
@@ -118,6 +128,10 @@ public class HomeController : PFUIPanel
|
||||
};
|
||||
|
||||
}
|
||||
private void GoGameRoom(BaseEventData e)
|
||||
{
|
||||
UIManager.ShowGameRoomListPanel();
|
||||
}
|
||||
private void GoRide(BaseEventData e)
|
||||
{
|
||||
Debug.Log(App.firstEnter.ToString());
|
||||
|
||||
Reference in new issue
Block a user