生态树宠物界面的修改

This commit is contained in:
liuliang 2024-12-19 15:24:14 +08:00
parent 8fb8460d04
commit d47eda3d04
3 changed files with 50 additions and 14 deletions

View File

@ -30802,6 +30802,22 @@ CanvasRenderer:
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 406765329}
m_CullTransparentMesh: 1
--- !u!1 &409865873 stripped
GameObject:
m_CorrespondingSourceObject: {fileID: 7550977465218709257, guid: aa401e2ce6d8c5847a9a32a4ac92f0f0, type: 3}
m_PrefabInstance: {fileID: 509057630}
m_PrefabAsset: {fileID: 0}
--- !u!114 &409865874 stripped
MonoBehaviour:
m_CorrespondingSourceObject: {fileID: 1477323885709186674, guid: aa401e2ce6d8c5847a9a32a4ac92f0f0, type: 3}
m_PrefabInstance: {fileID: 509057630}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 1696037413}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: 4e29b1a8efbd4b44bb3f3716e73f07ff, type: 3}
m_Name:
m_EditorClassIdentifier:
--- !u!1 &410861473
GameObject:
m_ObjectHideFlags: 0
@ -38464,6 +38480,18 @@ PrefabInstance:
propertyPath: m_IsActive
value: 1
objectReference: {fileID: 0}
- target: {fileID: 7550977464649123549, guid: aa401e2ce6d8c5847a9a32a4ac92f0f0, type: 3}
propertyPath: m_FillAmount
value: 0
objectReference: {fileID: 0}
- target: {fileID: 7550977465218709257, guid: aa401e2ce6d8c5847a9a32a4ac92f0f0, type: 3}
propertyPath: m_Name
value: Pet
objectReference: {fileID: 0}
- target: {fileID: 7550977465218709257, guid: aa401e2ce6d8c5847a9a32a4ac92f0f0, type: 3}
propertyPath: m_IsActive
value: 1
objectReference: {fileID: 0}
m_RemovedComponents:
- {fileID: 1477323886558972013, guid: aa401e2ce6d8c5847a9a32a4ac92f0f0, type: 3}
- {fileID: 1477323886558972012, guid: aa401e2ce6d8c5847a9a32a4ac92f0f0, type: 3}
@ -46485,6 +46513,8 @@ MonoBehaviour:
petLevel: {fileID: 946414134}
petLevelshow: {fileID: 101230186}
petExpFill: {fileID: 1319096889}
feedBtn: {fileID: 409865874}
Pet: {fileID: 409865873}
--- !u!1 &622223219
GameObject:
m_ObjectHideFlags: 0

View File

@ -30,6 +30,9 @@ public class WaterPanel : MonoBehaviour
public Text petLevelshow;
public Image petExpFill;
public Button feedBtn;
public GameObject Pet;
// Start is called before the first frame update
async void Start()
{
@ -69,10 +72,20 @@ public class WaterPanel : MonoBehaviour
public void Updated_petinfo(petBettleInfoResponse info)
{
if (info.data.Info == null)
{
Pet.gameObject.SetActive(false);
feedBtn.gameObject.SetActive(false);
}
else
{
Pet.gameObject.SetActive(true);
feedBtn.gameObject.SetActive(true);
petLevel.text = "³èÎïµÈ¼¶Lv." + info.data.Info.level;
petLevelshow.text = info.data.Info.exp + "/" + info.data.Info.upgrade_exp;
petExpFill.fillAmount = info.data.Info.exp / info.data.Info.upgrade_exp;
}
}

View File

@ -83,7 +83,8 @@ public class Logo_in : mount
bool issucceffull = await loading_Jiekou.RealNameAuthentications(boxTypes[1].content, boxTypes[2].content);
if (issucceffull)
{
gameObject.SetActive(false);
gameObject.GetComponent<input_box_pop_up_window>().destroy();
Promptmgr.Instance.PromptBubble("登录成功");
sceneslider.gameObject.SetActive(true);
StartCoroutine(jiaLoading());
@ -194,15 +195,7 @@ public class Logo_in : mount
GameObject gameObject = add_pop_up(true);//生成弹窗母体
List<GameObject> gameObjects = gameObject.GetComponent<input_box_pop_up_window>().updateUI(boxTypes, "登录");//测试输入框回调处理
//gameObjects[0].GetComponent<input_box_pop_up_window_item>().register_click((BoxType boxType, int type) =>//手机号获取验证码点击
//{
// if (boxType.is_required && string.IsNullOrWhiteSpace(boxType.content))
// {
// Promptmgr.Instance.PromptBubble("请不要" + boxType.textName + "为空");
// return;
// }
// Debug.Log("获取验证码");
//});
gameObjects[1].GetComponent<input_box_pop_up_window_item>().register_click(async (BoxType boxType, int type) =>//登录确定或取消
{
if (type == 0)