首次提交
This commit is contained in:
43
Assets/Scripts/UI/Home/Com/HomeButtonGroups.Designer.cs
generated
Normal file
43
Assets/Scripts/UI/Home/Com/HomeButtonGroups.Designer.cs
generated
Normal file
@@ -0,0 +1,43 @@
|
||||
/**本脚本为自动生成,每次生成会覆盖!请勿手动修改,生成插件文档及项目地址:https://git.whoot.com/whoot-games/whoot.fguieditorplugin**/
|
||||
|
||||
|
||||
using FairyGUI;
|
||||
using FairyGUI.Utils;
|
||||
using NBC;
|
||||
|
||||
namespace NBF
|
||||
{
|
||||
public partial class HomeButtonGroups
|
||||
{
|
||||
public const string URL = "ui://hxr7rc7plvqln";
|
||||
|
||||
public GButton BtnGo;
|
||||
public GButton BtnMake;
|
||||
public GButton BtnExit;
|
||||
public GButton BtnSettings;
|
||||
public GButton BtnFishBag;
|
||||
public GButton BtnBag;
|
||||
public GButton BtnMap;
|
||||
public GButton BtnPass;
|
||||
public GButton BtnMission;
|
||||
public GButton BtnTournament;
|
||||
|
||||
public override void ConstructFromXML(XML xml)
|
||||
{
|
||||
base.ConstructFromXML(xml);
|
||||
|
||||
BtnGo = (GButton)GetChild("BtnGo");
|
||||
BtnMake = (GButton)GetChild("BtnMake");
|
||||
BtnExit = (GButton)GetChild("BtnExit");
|
||||
BtnSettings = (GButton)GetChild("BtnSettings");
|
||||
BtnFishBag = (GButton)GetChild("BtnFishBag");
|
||||
BtnBag = (GButton)GetChild("BtnBag");
|
||||
BtnMap = (GButton)GetChild("BtnMap");
|
||||
BtnPass = (GButton)GetChild("BtnPass");
|
||||
BtnMission = (GButton)GetChild("BtnMission");
|
||||
BtnTournament = (GButton)GetChild("BtnTournament");
|
||||
OnInited();
|
||||
UILanguage.TrySetComponentLanguage(this);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,2 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 008c0b556690f1a4f9ea76cb05b6746e
|
||||
49
Assets/Scripts/UI/Home/Com/HomeButtonGroups.cs
Normal file
49
Assets/Scripts/UI/Home/Com/HomeButtonGroups.cs
Normal file
@@ -0,0 +1,49 @@
|
||||
// 本脚本只在不存在时会生成一次。组件逻辑写在当前脚本内。已存在不会再次生成覆盖
|
||||
|
||||
using UnityEngine;
|
||||
using FairyGUI;
|
||||
using NBC;
|
||||
|
||||
namespace NBF
|
||||
{
|
||||
public partial class HomeButtonGroups : GComponent
|
||||
{
|
||||
private void OnInited()
|
||||
{
|
||||
this.AutoAddClick(OnClick);
|
||||
}
|
||||
|
||||
private void OnClick(GComponent btn)
|
||||
{
|
||||
if (btn == BtnExit)
|
||||
{
|
||||
MessageBox.Show("确定退出吗?", (b) =>
|
||||
{
|
||||
if (b) Application.Quit();
|
||||
});
|
||||
}
|
||||
else if (btn == BtnSettings)
|
||||
{
|
||||
SettingPanel.Show();
|
||||
}
|
||||
else if (btn == BtnBag)
|
||||
{
|
||||
BagPanel.Show();
|
||||
}
|
||||
else if (btn == BtnFishBag)
|
||||
{
|
||||
// FishBagPanel.Show();
|
||||
FishingShopPanel.Show();
|
||||
}
|
||||
else if (btn == BtnMake)
|
||||
{
|
||||
BagSlotPanel.Show();
|
||||
// MakePanel.Show();
|
||||
}
|
||||
else if (btn == BtnMap)
|
||||
{
|
||||
MapPanel.Show();
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
2
Assets/Scripts/UI/Home/Com/HomeButtonGroups.cs.meta
Normal file
2
Assets/Scripts/UI/Home/Com/HomeButtonGroups.cs.meta
Normal file
@@ -0,0 +1,2 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 52070c9a16d995346a51eb093365c170
|
||||
Reference in New Issue
Block a user