LoginFinish_CreateLobbyUI.cs 1.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142
  1. using FairyGUI;
  2. using Sirenix.Utilities;
  3. using UnityEngine;
  4. namespace ET.Client
  5. {
  6. //[Event(SceneType.None)]
  7. public class LoginFinish_CreateLobbyUI //: AEvent<EventType.LoginFinish>
  8. {
  9. /*protected override async ETTask Run(Scene scene, EventType.LoginFinish args)
  10. {
  11. EnterMapHelper.EnterMapAsync(scene, args.player, args.player.instanceId).Coroutine();
  12. Log.Debug("enter lobby.");
  13. var view = await UIHelper.Create("Lobby");
  14. InitView(scene, args.player, view);
  15. }
  16. private void InitView(Scene scene, Player player, GComponent view)
  17. {
  18. var name = view.GetChild("userName");
  19. var level = view.GetChild("UserLevel");
  20. var gem = view.GetChild("txt_gem");
  21. var gold = view.GetChild("txt_gold");
  22. var point = view.GetChild("txt_point");
  23. name.text = "大老板";
  24. level.text = "99";
  25. gem.text = "888";
  26. gold.text = "666";
  27. point.text = "777";
  28. var btn = view.GetChild("Btn_PVP");
  29. btn.onClick.Add(() =>
  30. {
  31. EnterMapHelper.EnterMapAsync(scene, player, player.instanceId).Coroutine();
  32. });
  33. btn = view.GetChild("Btn_PVE");
  34. btn.visible = false;
  35. }*/
  36. }
  37. }