Commit 308273e4 authored by maxiaoliang's avatar maxiaoliang

修改提现弹窗

parent c1b01fc5
...@@ -178,7 +178,7 @@ public class UnityPhoneUtils ...@@ -178,7 +178,7 @@ public class UnityPhoneUtils
string vc = ""; string vc = "";
#if UNITY_EDITOR #if UNITY_EDITOR
vc = "9"; vc = "10";
#elif UNITY_ANDROID #elif UNITY_ANDROID
vc = GetPhoneUtil().Call<int>("getAppVersionCode", GetActivity())+""; vc = GetPhoneUtil().Call<int>("getAppVersionCode", GetActivity())+"";
#elif UNITY_IOS #elif UNITY_IOS
......
...@@ -24,7 +24,7 @@ public class LeeMainController : MonoBehaviour ...@@ -24,7 +24,7 @@ public class LeeMainController : MonoBehaviour
public void UpdateTitleBG2Info() public void UpdateTitleBG2Info()
{ {
DialogControl.Instance.NetWorkRequest<HomeTitleInfo>(true, "/app/v3/cscmnq/first_info", null, (model) => DialogControl.Instance.NetWorkRequest<HomeTitleInfo>(true, "app/v3/cscmnq/first_info", null, (model) =>
{ {
TitleBG2.Find("btnRedBag").GetComponent<Button>().onClick.RemoveAllListeners(); TitleBG2.Find("btnRedBag").GetComponent<Button>().onClick.RemoveAllListeners();
TitleBG2.Find("btnRedBag").GetComponent<Button>().onClick.AddListener(() => TitleBG2.Find("btnRedBag").GetComponent<Button>().onClick.AddListener(() =>
...@@ -70,7 +70,7 @@ public class LeeMainController : MonoBehaviour ...@@ -70,7 +70,7 @@ public class LeeMainController : MonoBehaviour
public void UpdateZhongCaiTiXianPanel() public void UpdateZhongCaiTiXianPanel()
{ {
DialogControl.Instance.NetWorkRequest<CashOutInfo>(true, "/app/v3/cscmnq/info", null, (model) => DialogControl.Instance.NetWorkRequest<CashOutInfo>(true, "app/v3/cscmnq/info", null, (model) =>
{ {
Transform Content = ZhongCaiTiXian.Find("MainBK/SV/Viewport/Content"); Transform Content = ZhongCaiTiXian.Find("MainBK/SV/Viewport/Content");
......
using System.Collections; using System;
using System.Collections;
using System.Collections.Generic; using System.Collections.Generic;
using ToastPlugin; using ToastPlugin;
using UnityEngine; using UnityEngine;
...@@ -7,12 +8,47 @@ using UnityEngine.UI; ...@@ -7,12 +8,47 @@ using UnityEngine.UI;
public class TiXianCell : BasePanel public class TiXianCell : BasePanel
{ {
private HomeTitleInfo info; private HomeTitleInfo info;
public GameObject bg; public Image bg;
public GameObject fruitList,countdown,withdraw;
public Sprite[] sprites;
public Image img_process;
public Text tv_process,tv_countdown;
public void Init(HomeTitleInfo info) public void Init(HomeTitleInfo info)
{ {
GetControl<Text>("txtMoney").text = info.yuan.ToString(); GetControl<Text>("txtMoney").text = info.yuan.ToString();
if (info.countdown > 0)
{
countdown.SetActive(true);
fruitList.SetActive(false);
withdraw.SetActive(false);
countTime = (int)info.countdown;
setCountTime(info.countdown);
tv_countdown.text = UnityUtil.getCountdown((int)info.countdown);
}
else
{
if (info.type == 0)
{
countdown.SetActive(false);
fruitList.SetActive(true);
withdraw.SetActive(false);
}else if (info.type == 3)
{
countdown.SetActive(false);
fruitList.SetActive(false);
withdraw.SetActive(true);
img_process.fillAmount = (float)((float)info.nowYuan / info.yuan);
tv_process.text = info.nowYuan + "/" + info.yuan;
}
}
if (info.selected == 0)
{
bg.sprite = sprites[0];
}
else
{
bg.sprite = sprites[1];
}
switch (info.status) switch (info.status)
{ {
case 0: case 0:
...@@ -68,16 +104,43 @@ public class TiXianCell : BasePanel ...@@ -68,16 +104,43 @@ public class TiXianCell : BasePanel
for (int i = 0; i < info.infoList.Count; i++) for (int i = 0; i < info.infoList.Count; i++)
{ {
transform.Find("SubCell" + i.ToString() + "/imgPic").GetComponent<Image>().sprite = transform.Find("fruitlist/SubCell" + i.ToString() + "/imgPic").GetComponent<Image>().sprite =
Resources.Load<Sprite>("Fruit/" + info.infoList[i].woodId.ToString()); Resources.Load<Sprite>("Fruit/" + info.infoList[i].woodId.ToString());
transform.Find("SubCell" + i.ToString() + "/imgProcess").GetComponent<Image>().fillAmount = transform.Find("fruitlist/SubCell" + i.ToString() + "/imgProcess").GetComponent<Image>().fillAmount =
(float)info.infoList[i].current / (float)info.infoList[i].targetNum; (float)info.infoList[i].current / (float)info.infoList[i].targetNum;
transform.Find("SubCell" + i.ToString() + "/txtProcess").GetComponent<Text>().text = transform.Find("fruitlist/SubCell" + i.ToString() + "/txtProcess").GetComponent<Text>().text =
string.Format("{0}/{1}", info.infoList[i].current, info.infoList[i].targetNum); string.Format("{0}/{1}", info.infoList[i].current, info.infoList[i].targetNum);
} }
} }
private Coroutine lotteryControl;
private void setCountTime(int? countdown)
{
if (lotteryControl != null)
{
StopCoroutine(lotteryControl);
}
tv_countdown.text = UnityUtil.getCountdown((int)countdown);
lotteryControl = StartCoroutine(IELotteryIimer());
}
private int countTime;
private IEnumerator IELotteryIimer()
{
while (countTime >= 0)
{
yield return new WaitForSeconds(1f);
if (countTime <= 0)
{
// RefreshHomeInfo();
StopCoroutine(lotteryControl);
break;
}
else
{
countTime--;
tv_countdown.text = UnityUtil.getCountdown(countTime);
}
}
}
} }
...@@ -38690,7 +38690,7 @@ GameObject: ...@@ -38690,7 +38690,7 @@ GameObject:
m_Icon: {fileID: 0} m_Icon: {fileID: 0}
m_NavMeshLayer: 0 m_NavMeshLayer: 0
m_StaticEditorFlags: 0 m_StaticEditorFlags: 0
m_IsActive: 1 m_IsActive: 0
--- !u!224 &1282799107 --- !u!224 &1282799107
RectTransform: RectTransform:
m_ObjectHideFlags: 0 m_ObjectHideFlags: 0
...@@ -18,6 +18,10 @@ public class HomeTitleInfo ...@@ -18,6 +18,10 @@ public class HomeTitleInfo
public double? yuan; public double? yuan;
public int? status; public int? status;
public List<SimpleHomeTitleInfo> infoList; public List<SimpleHomeTitleInfo> infoList;
public int? type;
public int? countdown;
public double? nowYuan;
public int? selected;
} }
public class CashOutInfo public class CashOutInfo
......
...@@ -31,7 +31,7 @@ public class PlantTreeControl : MonoBehaviour ...@@ -31,7 +31,7 @@ public class PlantTreeControl : MonoBehaviour
//提现商城数据 //提现商城数据
private void getWithDrawData() private void getWithDrawData()
{ {
HttpTool.Instance._Get("app/v1/wdlc/wd/info", null, new Action<WithDrawBean>((bean) => HttpTool.Instance._Get("app/v3/wdlc/wd/info", null, new Action<WithDrawBean>((bean) =>
{ {
InitWithDrawInfo(bean); InitWithDrawInfo(bean);
//ShowCashOut(); //ShowCashOut();
......
...@@ -168,7 +168,7 @@ GameObject: ...@@ -168,7 +168,7 @@ GameObject:
m_Icon: {fileID: 0} m_Icon: {fileID: 0}
m_NavMeshLayer: 0 m_NavMeshLayer: 0
m_StaticEditorFlags: 0 m_StaticEditorFlags: 0
m_IsActive: 1 m_IsActive: 0
--- !u!224 &9074873368491070519 --- !u!224 &9074873368491070519
RectTransform: RectTransform:
m_ObjectHideFlags: 0 m_ObjectHideFlags: 0
...@@ -434,7 +434,16 @@ MonoBehaviour: ...@@ -434,7 +434,16 @@ MonoBehaviour:
m_Script: {fileID: 11500000, guid: 92eec9a1cfb661340b4db8b2bedfcbb2, type: 3} m_Script: {fileID: 11500000, guid: 92eec9a1cfb661340b4db8b2bedfcbb2, type: 3}
m_Name: m_Name:
m_EditorClassIdentifier: m_EditorClassIdentifier:
bg: {fileID: 0} bg: {fileID: 996605790905112307}
fruitList: {fileID: 477978980361730870}
countdown: {fileID: 6447204647793095335}
withdraw: {fileID: 7752375703414735778}
sprites:
- {fileID: 21300000, guid: 87bd69ddaefeb51499b29739a7258483, type: 3}
- {fileID: 21300000, guid: c5b6f259535934fe590c6be2094e4d9c, type: 3}
img_process: {fileID: 6884567047368652589}
tv_process: {fileID: 7169505402414716405}
tv_countdown: {fileID: 793209000852770342}
--- !u!1 &996605791157629920 --- !u!1 &996605791157629920
GameObject: GameObject:
m_ObjectHideFlags: 0 m_ObjectHideFlags: 0
...@@ -2289,7 +2298,7 @@ GameObject: ...@@ -2289,7 +2298,7 @@ GameObject:
m_Icon: {fileID: 0} m_Icon: {fileID: 0}
m_NavMeshLayer: 0 m_NavMeshLayer: 0
m_StaticEditorFlags: 0 m_StaticEditorFlags: 0
m_IsActive: 0 m_IsActive: 1
--- !u!224 &1276012472267649164 --- !u!224 &1276012472267649164
RectTransform: RectTransform:
m_ObjectHideFlags: 0 m_ObjectHideFlags: 0
......
...@@ -17,7 +17,7 @@ MonoBehaviour: ...@@ -17,7 +17,7 @@ MonoBehaviour:
m_Registries: m_Registries:
- m_Id: main - m_Id: main
m_Name: m_Name:
m_Url: https://packages.unity.com m_Url: https://packages.unity.cn
m_Scopes: [] m_Scopes: []
m_IsDefault: 1 m_IsDefault: 1
m_UserSelectedRegistryName: m_UserSelectedRegistryName:
......
...@@ -41,6 +41,12 @@ PlayerSettings: ...@@ -41,6 +41,12 @@ PlayerSettings:
height: 1 height: 1
m_SplashScreenLogos: [] m_SplashScreenLogos: []
m_VirtualRealitySplashScreen: {fileID: 0} m_VirtualRealitySplashScreen: {fileID: 0}
m_ShowUnitySplashAds: 0
m_AdsAndroidGameId:
m_AdsIosGameId:
m_ShowSplashAdsSlogan: 0
m_SloganImage: {fileID: 0}
m_SloganHeight: 150
m_HolographicTrackingLossScreen: {fileID: 0} m_HolographicTrackingLossScreen: {fileID: 0}
defaultScreenWidth: 1024 defaultScreenWidth: 1024
defaultScreenHeight: 768 defaultScreenHeight: 768
...@@ -118,13 +124,14 @@ PlayerSettings: ...@@ -118,13 +124,14 @@ PlayerSettings:
vulkanNumSwapchainBuffers: 3 vulkanNumSwapchainBuffers: 3
vulkanEnableSetSRGBWrite: 0 vulkanEnableSetSRGBWrite: 0
vulkanEnableLateAcquireNextImage: 0 vulkanEnableLateAcquireNextImage: 0
useSecurityBuild: 0
m_SupportedAspectRatios: m_SupportedAspectRatios:
4:3: 1 4:3: 1
5:4: 1 5:4: 1
16:10: 1 16:10: 1
16:9: 1 16:9: 1
Others: 1 Others: 1
bundleVersion: 1.0.8 bundleVersion: 1.0.9
preloadedAssets: [] preloadedAssets: []
metroInputSource: 0 metroInputSource: 0
wsaTransparentSwapchain: 0 wsaTransparentSwapchain: 0
...@@ -172,7 +179,7 @@ PlayerSettings: ...@@ -172,7 +179,7 @@ PlayerSettings:
iPhone: com.ym.simulator iPhone: com.ym.simulator
buildNumber: buildNumber:
iPhone: 6 iPhone: 6
AndroidBundleVersionCode: 9 AndroidBundleVersionCode: 10
AndroidMinSdkVersion: 21 AndroidMinSdkVersion: 21
AndroidTargetSdkVersion: 0 AndroidTargetSdkVersion: 0
AndroidPreferredInstallLocation: 1 AndroidPreferredInstallLocation: 1
...@@ -501,6 +508,7 @@ PlayerSettings: ...@@ -501,6 +508,7 @@ PlayerSettings:
m_Kind: 4 m_Kind: 4
m_SubKind: App Store m_SubKind: App Store
m_BuildTargetBatching: [] m_BuildTargetBatching: []
m_BuildTargetEncrypting: []
m_BuildTargetGraphicsJobs: m_BuildTargetGraphicsJobs:
- m_BuildTarget: MacStandaloneSupport - m_BuildTarget: MacStandaloneSupport
m_GraphicsJobs: 0 m_GraphicsJobs: 0
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment