fix:1、添加H5
This commit is contained in:
@@ -9,6 +9,8 @@ using UnityEngine;
|
||||
using System;
|
||||
using System.Threading;
|
||||
using System.Threading.Tasks;
|
||||
using DontConfuse;
|
||||
|
||||
namespace RedHotRoast
|
||||
|
||||
{
|
||||
@@ -61,6 +63,7 @@ namespace RedHotRoast
|
||||
|
||||
protected override void OnClose()
|
||||
{
|
||||
WebviewManager.Instance.SetDarkThough(true);
|
||||
foreach (var t in loader_list)
|
||||
if (t != null && !t.isDisposed && t.texture != null)
|
||||
{
|
||||
@@ -98,6 +101,7 @@ namespace RedHotRoast
|
||||
public SmartInvoker invoker;
|
||||
protected override void OnOpenBefore(object args)
|
||||
{
|
||||
WebviewManager.Instance.SetDarkThough(false);
|
||||
invoker = new SmartInvoker(() =>
|
||||
{
|
||||
for (int i = 0; i < UpDatatime.Length; i++)
|
||||
|
||||
@@ -45,7 +45,6 @@ namespace RedHotRoast
|
||||
{
|
||||
ChatHelper.chat_red_list[chat_index] = false;
|
||||
GameDispatcher.Instance.Dispatch(GameMsg.RefreshRedDot);
|
||||
UnityManager.ShezhiACT(true);
|
||||
}
|
||||
|
||||
protected override void OnBind()
|
||||
@@ -79,7 +78,6 @@ namespace RedHotRoast
|
||||
{
|
||||
GameHelper.ShowTips("launching_soon", true);
|
||||
});
|
||||
UnityManager.ShezhiACT(false);
|
||||
}
|
||||
public static bool IsSameDay(long timestamp)
|
||||
{
|
||||
|
||||
@@ -0,0 +1,3 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 9795db4075134685acdc143801219dd6
|
||||
timeCreated: 1779352795
|
||||
@@ -0,0 +1,27 @@
|
||||
|
||||
|
||||
using RedHotRoast;
|
||||
|
||||
namespace RedHotRoast
|
||||
{
|
||||
public class H5Ctrl : BaseCtrl
|
||||
{
|
||||
public static H5Ctrl Instance { get; private set; }
|
||||
|
||||
private H5Model model;
|
||||
|
||||
#region 生命周期
|
||||
protected override void OnInit()
|
||||
{
|
||||
Instance = this;
|
||||
//model = ModuleManager.Instance..GetModel(ModelConst.H5Model) as H5Model;
|
||||
}
|
||||
|
||||
protected override void OnDispose()
|
||||
{
|
||||
Instance = null;
|
||||
}
|
||||
|
||||
#endregion
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,11 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 9f0d89ff894a1074494420d446333bfc
|
||||
MonoImporter:
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
@@ -0,0 +1,21 @@
|
||||
|
||||
using RedHotRoast;
|
||||
|
||||
namespace RedHotRoast
|
||||
{
|
||||
public class H5Model : BaseModel
|
||||
{
|
||||
#region 生命周期
|
||||
|
||||
protected override void OnInit()
|
||||
{
|
||||
}
|
||||
|
||||
protected override void OnDispose()
|
||||
{
|
||||
}
|
||||
|
||||
|
||||
#endregion
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,11 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 2ad9b45c44f492b4a97fc9845e2972a8
|
||||
MonoImporter:
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
@@ -0,0 +1,249 @@
|
||||
|
||||
using DontConfuse;
|
||||
using FGUI.ZM_H5_15;
|
||||
using RedHotRoast;
|
||||
using SGModule.NetKit;
|
||||
|
||||
namespace RedHotRoast
|
||||
{
|
||||
public class H5UI : BaseUI
|
||||
{
|
||||
private H5UICtrl ctrl;
|
||||
private H5Model model;
|
||||
private com_webview ui;
|
||||
|
||||
public H5UI(H5UICtrl ctrl) : base(ctrl)
|
||||
{
|
||||
uiName = UIConst.H5UI;
|
||||
this.ctrl = ctrl;
|
||||
}
|
||||
|
||||
protected override void SetUIInfo(UIInfo uiInfo)
|
||||
{
|
||||
uiInfo.packageName = "ZM_H5_15";
|
||||
uiInfo.assetName = "com_webview";
|
||||
uiInfo.layerType = UILayerType.Popup;
|
||||
uiInfo.isNeedOpenAnim = false;
|
||||
uiInfo.isNeedCloseAnim = false;
|
||||
uiInfo.isNeedUIMask = true;
|
||||
}
|
||||
|
||||
#region 生命周期
|
||||
protected override void OnInit()
|
||||
{
|
||||
//model = ModuleManager.Instance.GetModel(ModelConst.H5Model) as H5Model;
|
||||
}
|
||||
|
||||
protected override void OnClose()
|
||||
{
|
||||
GameDispatcher.Instance.Dispatch(GameMsg.showBroadCast);
|
||||
WebviewManager.Instance.setInH5View(false);
|
||||
WebviewManager.Instance.ShowH5View(false);
|
||||
}
|
||||
|
||||
protected override void OnBind()
|
||||
{
|
||||
ui = baseUI as FGUI.ZM_H5_15.com_webview;
|
||||
}
|
||||
|
||||
protected override void OnOpenBefore(object args)
|
||||
{
|
||||
|
||||
WebviewManager.Instance.setInH5View(true);
|
||||
GameDispatcher.Instance.Dispatch(GameMsg.hideBroadCast);
|
||||
// delayedCall = DOVirtual.DelayedCall(0.3f, () =>
|
||||
// {
|
||||
WebviewManager.Instance.ShowH5View(true);
|
||||
|
||||
ui.btn_close.SetClick(() =>
|
||||
{
|
||||
UICtrlDispatcher.Instance.Dispatch(UICtrlMsg.H5UI_Close);
|
||||
});
|
||||
InitView();
|
||||
|
||||
}
|
||||
|
||||
protected override void OnOpen(object args)
|
||||
{
|
||||
}
|
||||
|
||||
protected override void OnHide()
|
||||
{
|
||||
}
|
||||
|
||||
protected override void OnDisplay(object args)
|
||||
{
|
||||
}
|
||||
#endregion
|
||||
|
||||
#region 消息
|
||||
protected override void AddListener()
|
||||
{
|
||||
|
||||
}
|
||||
protected override void RemoveListener()
|
||||
{
|
||||
|
||||
}
|
||||
#endregion
|
||||
|
||||
//初始化页面逻辑
|
||||
private void InitView()
|
||||
{
|
||||
|
||||
}
|
||||
public void ClickBtn(string name)
|
||||
{
|
||||
// // Debug.Log("[UNITY] Click btn: " + name);
|
||||
// FGUIHelper.PlayClickSound();
|
||||
if (name == "flyBtn")
|
||||
{
|
||||
OnClickFlyCash();
|
||||
//NetworkKit.BuriedPoint(BuriedPointEvent.Hall_behavior,BuriedPointEvent.collect_fly_people,1);
|
||||
|
||||
TrackKit.SendEvent(HallBehaviorTrack.Event, HallBehaviorTrack.Property.collect_fly_number);
|
||||
|
||||
}
|
||||
else if (name == "rewardBtn")
|
||||
{
|
||||
OnClickIcon();
|
||||
|
||||
}
|
||||
}
|
||||
private void OnClickFlyCash()
|
||||
{
|
||||
// PreferencesMgr.Instance.AdCashFlyShowTime =
|
||||
// GameHelper.GetNowTime() + ConfigSystem.GetConfig<CommonModel>().flyCD;
|
||||
// var rewardData = new RewardData();
|
||||
|
||||
// var singleValue =
|
||||
// (decimal)Math.Round(
|
||||
// UnityEngine.Random.Range(ConfigSystem.GetConfig<CommonModel>().flyReward[0],
|
||||
// ConfigSystem.GetConfig<CommonModel>().flyReward[1]), 2);
|
||||
|
||||
|
||||
// decimal rewardValue;
|
||||
|
||||
|
||||
// if (flyClickCount >= flyNeedClickCount)
|
||||
// {
|
||||
// flyClickCount = -1;
|
||||
// //var rate = GameHelper.GetVideoRate();
|
||||
// rewardValue = singleValue;
|
||||
// GameHelper.ShowVideoAd("reward_fly", isCompleted =>
|
||||
// {
|
||||
// if (isCompleted)
|
||||
// {
|
||||
// GameDispatcher.Instance.Dispatch(GameMsg.GetReward, rewardData);
|
||||
// GameDispatcher.Instance.Dispatch(GameMsg.RefreshMakeupData);
|
||||
// }
|
||||
// });
|
||||
// }
|
||||
// else
|
||||
// {
|
||||
// rewardValue = singleValue;
|
||||
// }
|
||||
|
||||
// var startPosition = GameHelper.GetUICenterPosition(ui.com_fly);
|
||||
// var endPosition = GameHelper.GetUICenterPosition(ui.com_top.text_num);
|
||||
|
||||
// var rewardSingleData = new RewardSingleData(102, rewardValue, RewardOrigin.H5Fly101)
|
||||
// {
|
||||
// startPosition = startPosition,
|
||||
// endPosition = new Vector2(endPosition.x - 150, endPosition.y - 106)
|
||||
// };
|
||||
|
||||
// rewardData.AddReward(rewardSingleData);
|
||||
// rewardData.displayType = RewardDisplayType.RewardFly | RewardDisplayType.ValueChange;
|
||||
// rewardData.AddCompleted(isSuccess =>
|
||||
// {
|
||||
// if (isSuccess)
|
||||
// {
|
||||
// flyClickCount++;
|
||||
// }
|
||||
|
||||
// SetMakeup();
|
||||
// });
|
||||
// //GameHelper.addMoney((float)rewardValue);
|
||||
// GameDispatcher.Instance.Dispatch(GameMsg.GetReward, rewardData);
|
||||
// GameDispatcher.Instance.Dispatch(GameMsg.RefreshMakeupData);
|
||||
// CheckShowFly();
|
||||
}
|
||||
private void OnClickIcon()
|
||||
{
|
||||
// //WebThroughUtil.WebThroughClick(H5WebThroughType.OnlineH5, ui.btn_icon);
|
||||
// if (iconTime < ConfigSystem.GetConfig<CommonModel>().ThroughRewardCD)
|
||||
// {
|
||||
// return;
|
||||
// }
|
||||
|
||||
// #if UNITY_IOS && !UNITY_EDITOR
|
||||
// WebviewManager.Instance.ShowH5View(false);
|
||||
// #endif
|
||||
|
||||
// float[] cash_array = GameHelper.GetRewardValue(2);
|
||||
|
||||
// // var temp = new { is_success = true, cash_number = cash_array[0], rate = cash_array[1], is_level_success = false, is_h5_reward = true };
|
||||
// SuccessData temp = new SuccessData();
|
||||
// temp.IsWin = true;
|
||||
// temp.cash_number = cash_array[0];
|
||||
// temp.rate = (int)cash_array[1];
|
||||
// temp.IsLevelSuccess = false;
|
||||
// temp.IsH5Reward = true;
|
||||
// UICtrlDispatcher.Instance.Dispatch(UICtrlMsg.LevelSuccessUI_Open, temp);
|
||||
|
||||
// //UICtrlDispatcher.Instance.Dispatch(UICtrlMsg.RewardUI_Open);
|
||||
// // var rewardData = new RewardData();
|
||||
|
||||
// // var rewardType = 111;
|
||||
// // decimal rewardValue = (decimal)GameHelper.GetRewardValue(3)[0];
|
||||
|
||||
// // var rewardSingleData = new RewardSingleData(rewardType, rewardValue, RewardOrigin.H5Icon)
|
||||
// // {
|
||||
// // startPosition = GameHelper.GetUICenterPosition(ui.btn_icon),
|
||||
// // endPosition = GameHelper.GetUICenterPosition(ui.com_top.text_num)
|
||||
// // };
|
||||
// // rewardData.AddReward(rewardSingleData);
|
||||
// // rewardData.AddCompleted(isSuccess =>
|
||||
// // {
|
||||
// // ui.btn_icon.cont_state.selectedIndex = btn_icon.State_none;
|
||||
// // iconTime = 0;
|
||||
// // SetMakeup();
|
||||
// // });
|
||||
// // rewardData.condition = RewardCondition.AD;
|
||||
// // rewardData.displayType =
|
||||
// // RewardDisplayType.Dialog | RewardDisplayType.RewardFly | RewardDisplayType.ValueChange;
|
||||
|
||||
// // GameDispatcher.Instance.Dispatch(GameMsg.GetReward, rewardData);
|
||||
|
||||
// // GameHelper.addMoney((float)rewardValue);
|
||||
// // GameDispatcher.Instance.Dispatch(GameMsg.GetReward, rewardData);
|
||||
// // GameDispatcher.Instance.Dispatch(GameMsg.RefreshMakeupData);
|
||||
|
||||
|
||||
// iconTime = 0;
|
||||
// // SetMakeup();
|
||||
// NetworkKit.BuriedPoint(BuriedPointEvent.Hall_behavior, BuriedPointEvent.annular_get_number, 1);
|
||||
}
|
||||
private void CheckShowFly()
|
||||
{
|
||||
// var nowTime = GameHelper.GetNowTime();
|
||||
// var leftTime = (int)(PreferencesMgr.Instance.AdCashFlyShowTime - nowTime);
|
||||
|
||||
// ui.com_fly.visible = false;
|
||||
// ui.com_fly.visible = leftTime <= 0;
|
||||
// if (leftTime > 0)
|
||||
// {
|
||||
// WebviewManager.Instance.ShowFlyBtn(false);
|
||||
// isFlyShow = false;
|
||||
// }
|
||||
// else
|
||||
// {
|
||||
// //StartFly();
|
||||
// if (!isFlyShow) WebviewManager.Instance.ShowFlyBtn(true);
|
||||
// isFlyShow = true;
|
||||
|
||||
// }
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,11 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 345404ec69f13b84c9ce0415061b717b
|
||||
MonoImporter:
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
@@ -0,0 +1,80 @@
|
||||
|
||||
|
||||
using RedHotRoast;
|
||||
|
||||
namespace RedHotRoast
|
||||
{
|
||||
public class H5UICtrl : BaseUICtrl
|
||||
{
|
||||
private H5UI ui;
|
||||
private H5Model model;
|
||||
|
||||
private uint openUIMsg = UICtrlMsg.H5UI_Open;
|
||||
private uint closeUIMsg = UICtrlMsg.H5UI_Close;
|
||||
|
||||
#region 生命周期
|
||||
protected override void OnInit()
|
||||
{
|
||||
//model = ModuleManager.Instance.GetModel(ModelConst.H5Model) as H5Model;
|
||||
}
|
||||
|
||||
protected override void OnDispose()
|
||||
{
|
||||
}
|
||||
|
||||
public override void OpenUI(object args = null)
|
||||
{
|
||||
if (ui == null)
|
||||
{
|
||||
ui = new H5UI(this);
|
||||
ui.Open(args);
|
||||
}
|
||||
}
|
||||
|
||||
public override void CloseUI(object args = null)
|
||||
{
|
||||
if (ui != null && !ui.isClose)
|
||||
{
|
||||
ui.Close();
|
||||
}
|
||||
ui = null;
|
||||
}
|
||||
#endregion
|
||||
|
||||
#region 消息
|
||||
public override uint GetOpenUIMsg(string uiName)
|
||||
{
|
||||
return openUIMsg;
|
||||
}
|
||||
public override uint GetCloseUIMsg(string uiName)
|
||||
{
|
||||
return closeUIMsg;
|
||||
}
|
||||
|
||||
protected override void AddListener()
|
||||
{
|
||||
uiCtrlDispatcher.AddListener(openUIMsg, OpenUI);
|
||||
uiCtrlDispatcher.AddListener(closeUIMsg, CloseUI);
|
||||
gameDispatcher.AddListener(GameMsg.H5ViewClickBtn, OnH5ClickBtn);
|
||||
}
|
||||
protected override void RemoveListener()
|
||||
{
|
||||
uiCtrlDispatcher.RemoveListener(openUIMsg, OpenUI);
|
||||
uiCtrlDispatcher.RemoveListener(closeUIMsg, CloseUI);
|
||||
gameDispatcher.RemoveListener(GameMsg.H5ViewClickBtn, OnH5ClickBtn);
|
||||
}
|
||||
void OnH5ClickBtn(object arg)
|
||||
{
|
||||
ui?.ClickBtn((string)arg);
|
||||
}
|
||||
protected override void AddServerListener()
|
||||
{
|
||||
|
||||
}
|
||||
protected override void RemoveServerListener()
|
||||
{
|
||||
|
||||
}
|
||||
#endregion
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,11 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 74ecd6e2beb102e4e9eee8ad48c987d6
|
||||
MonoImporter:
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
@@ -16,6 +16,7 @@ using System.Net;
|
||||
using SGModule.Net;
|
||||
using System.IO;
|
||||
using System.Linq;
|
||||
using DontConfuse;
|
||||
|
||||
|
||||
namespace RedHotRoast
|
||||
@@ -209,6 +210,9 @@ namespace RedHotRoast
|
||||
}
|
||||
void Setbg(object a = null)
|
||||
{
|
||||
return;
|
||||
|
||||
|
||||
if (!GameHelper.IsGiftSwitch())
|
||||
{
|
||||
return;
|
||||
@@ -483,6 +487,13 @@ namespace RedHotRoast
|
||||
ui.btn_shop.SetClick(OnClickShop);
|
||||
// ui.btn_secret.SetClick(OnClickSecretAlbums);
|
||||
ui.btn_vip.SetClick(onClickVip);
|
||||
|
||||
WebviewManager.Instance.SetDarkThough(true);
|
||||
|
||||
ui.btn_wv.SetClick(() =>
|
||||
{
|
||||
UICtrlDispatcher.Instance.Dispatch(UICtrlMsg.H5UI_Open);
|
||||
});
|
||||
|
||||
ui.btn_egg.SetClick(OnClickEgg);
|
||||
btn_noads.SetClick(() =>
|
||||
@@ -546,6 +557,12 @@ namespace RedHotRoast
|
||||
|
||||
});
|
||||
|
||||
if (!GameHelper.IsGiftSwitch())
|
||||
{
|
||||
WebviewManager.Instance.SetDarkThough(false);
|
||||
}
|
||||
|
||||
|
||||
// ui.btn_task_times.SetClick(() => { OnClickTask(false); });
|
||||
|
||||
ui.btn_task.SetClick(() => { OnClickTask(false); });
|
||||
@@ -581,7 +598,7 @@ namespace RedHotRoast
|
||||
ui.state.selectedIndex = GameHelper.IsGiftSwitch() ? 1 : 0;
|
||||
ui.btn_three_day.SetClick(() =>
|
||||
{
|
||||
uiCtrlDispatcher.Dispatch(UICtrlMsg.ThreeDaysGiftUI_Open);
|
||||
// uiCtrlDispatcher.Dispatch(UICtrlMsg.ThreeDaysGiftUI_Open);
|
||||
});
|
||||
for (int i = 0; i < BtnNum; i++)
|
||||
{
|
||||
|
||||
@@ -2,6 +2,7 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.IO;
|
||||
using DontConfuse;
|
||||
|
||||
// using System.IO;
|
||||
|
||||
@@ -91,6 +92,7 @@ namespace RedHotRoast
|
||||
|
||||
protected override void OnClose()
|
||||
{
|
||||
WebviewManager.Instance.SetDarkThough(true);
|
||||
// 归还所有播放器
|
||||
foreach (var kvp in dictionary_)
|
||||
VideoPlayerPool.Instance.ReturnPlayer(kvp.Value);
|
||||
@@ -123,6 +125,8 @@ namespace RedHotRoast
|
||||
|
||||
protected override void OnOpenBefore(object args)
|
||||
{
|
||||
WebviewManager.Instance.SetDarkThough(false);
|
||||
|
||||
LiveConfig = ConfigSystem.GetLiveConfig();
|
||||
|
||||
ui.list_.itemRenderer = RendererList;
|
||||
|
||||
@@ -4,6 +4,7 @@ using FairyGUI;
|
||||
using FGUI.ZM_Tasks_13;
|
||||
using DG.Tweening;
|
||||
using System;
|
||||
using DontConfuse;
|
||||
using FGUI.ZM_Common_01;
|
||||
|
||||
namespace RedHotRoast
|
||||
@@ -52,7 +53,8 @@ namespace RedHotRoast
|
||||
{
|
||||
GameHelper.showGameUI = true;
|
||||
|
||||
|
||||
WebviewManager.Instance.SetDarkThough(true);
|
||||
|
||||
}
|
||||
|
||||
protected override void OnBind()
|
||||
@@ -67,6 +69,8 @@ namespace RedHotRoast
|
||||
ui.gold.y += Screen.safeArea.y;
|
||||
}
|
||||
CommonHelper.CheckAdTimes();
|
||||
|
||||
WebviewManager.Instance.SetDarkThough(false);
|
||||
|
||||
|
||||
|
||||
|
||||
@@ -4,6 +4,7 @@ using FairyGUI;
|
||||
using FGUI.ZM_Pass_14;
|
||||
using DG.Tweening;
|
||||
using System;
|
||||
using DontConfuse;
|
||||
using FGUI.ZM_Common_01;
|
||||
using Spine.Unity;
|
||||
|
||||
@@ -41,6 +42,9 @@ namespace RedHotRoast {
|
||||
protected override void OnClose() {
|
||||
GameHelper.showGameUI = true;
|
||||
HallManager.Instance.UpdateSecondEvent -= upData;
|
||||
|
||||
WebviewManager.Instance.SetDarkThough(true);
|
||||
|
||||
|
||||
}
|
||||
|
||||
@@ -57,6 +61,8 @@ namespace RedHotRoast {
|
||||
// ui.top_bg.height += Screen.safeArea.y;
|
||||
ui.group_.y += 66;
|
||||
}
|
||||
WebviewManager.Instance.SetDarkThough(false);
|
||||
|
||||
|
||||
if (GameHelper.GetGameday() != DateTime.Now.Day) {
|
||||
DataMgr.GameTime.Value = 0;
|
||||
|
||||
@@ -42,7 +42,6 @@ namespace RedHotRoast
|
||||
protected override void OnClose()
|
||||
{
|
||||
CommonHelper.FadeOut(ui);
|
||||
UnityManager.ShezhiACT(true);
|
||||
|
||||
}
|
||||
|
||||
@@ -58,7 +57,6 @@ namespace RedHotRoast
|
||||
// ui.title.y += Screen.safeArea.y;
|
||||
// }
|
||||
selectIndex = DataMgr.PlayerAvatarId.Value;
|
||||
UnityManager.ShezhiACT(false);
|
||||
InitView();
|
||||
|
||||
|
||||
|
||||
@@ -118,6 +118,7 @@ namespace RedHotRoast
|
||||
if (Screen.safeArea.y != 0)
|
||||
{
|
||||
ui.group_.y += Screen.safeArea.y - 15;
|
||||
ui.btn_wv.y += 20;
|
||||
}
|
||||
GameHelper.IsShowFirstReward();
|
||||
ui.gift_switch.selectedIndex = GameHelper.IsGiftSwitch() ? 1 : 0;
|
||||
@@ -442,6 +443,11 @@ namespace RedHotRoast
|
||||
ui.btn_refresh.SetClick(RefreshFunc);
|
||||
|
||||
|
||||
ui.btn_wv.SetClick(() =>
|
||||
{
|
||||
UICtrlDispatcher.Instance.Dispatch(UICtrlMsg.H5UI_Open);
|
||||
});
|
||||
|
||||
ui.btn_back.SetClick(() =>
|
||||
{
|
||||
UICtrlDispatcher.Instance.Dispatch(UICtrlMsg.SheepwindowUI_Open, 1);
|
||||
@@ -581,7 +587,7 @@ namespace RedHotRoast
|
||||
|
||||
ui.btn_three_day.SetClick(() =>
|
||||
{
|
||||
uiCtrlDispatcher.Dispatch(UICtrlMsg.ThreeDaysGiftUI_Open);
|
||||
// uiCtrlDispatcher.Dispatch(UICtrlMsg.ThreeDaysGiftUI_Open);
|
||||
});
|
||||
ui.btn_look_ad.SetClick(() => { LookAd(); });
|
||||
Setbg();
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
using DontConfuse;
|
||||
using SGModule.MarkdownKit;
|
||||
|
||||
namespace RedHotRoast
|
||||
@@ -42,6 +43,9 @@ namespace RedHotRoast
|
||||
protected override void OnClose()
|
||||
{
|
||||
ui?.FadeOut();
|
||||
|
||||
WebviewManager.Instance.SetDarkThough(true);
|
||||
|
||||
}
|
||||
|
||||
protected override void OnBind()
|
||||
@@ -58,6 +62,8 @@ namespace RedHotRoast
|
||||
|
||||
}
|
||||
|
||||
WebviewManager.Instance.SetDarkThough(false);
|
||||
|
||||
InitView();
|
||||
|
||||
ui.show.selectedIndex = isTerm != 2 ? 0 : 1;
|
||||
|
||||
@@ -6,6 +6,7 @@ using FairyGUI;
|
||||
using FGUI.ZM_Common_01;
|
||||
using System;
|
||||
using DG.Tweening;
|
||||
using DontConfuse;
|
||||
using FGUI.bkg_jilu;
|
||||
using SGModule.Common.Extensions;
|
||||
using Unity.VisualScripting;
|
||||
@@ -42,6 +43,8 @@ namespace RedHotRoast
|
||||
|
||||
protected override void OnClose()
|
||||
{
|
||||
WebviewManager.Instance.SetDarkThough(true);
|
||||
|
||||
if (coroutine != null)
|
||||
{
|
||||
CrazyAsyKit.StopCoroutine(coroutine);
|
||||
@@ -55,6 +58,9 @@ namespace RedHotRoast
|
||||
|
||||
protected override void OnOpenBefore(object args)
|
||||
{
|
||||
|
||||
WebviewManager.Instance.SetDarkThough(false);
|
||||
|
||||
InitView();
|
||||
|
||||
ui.btn_close.onClick.Add(() =>
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
using DontConfuse;
|
||||
using Spine.Unity;
|
||||
|
||||
namespace RedHotRoast
|
||||
@@ -44,6 +45,11 @@ namespace RedHotRoast
|
||||
|
||||
protected override void OnClose()
|
||||
{
|
||||
if (UIManager.Instance.IsExistUI(UIConst.H5UI))
|
||||
{
|
||||
WebviewManager.Instance.SetDarkThough(true);
|
||||
}
|
||||
|
||||
tween?.Kill();
|
||||
CommonHelper.FadeOut(ui);
|
||||
}
|
||||
@@ -56,6 +62,11 @@ namespace RedHotRoast
|
||||
protected override void OnOpenBefore(object args)
|
||||
{
|
||||
|
||||
if (UIManager.Instance.IsExistUI(UIConst.H5UI))
|
||||
{
|
||||
WebviewManager.Instance.SetDarkThough(false);
|
||||
}
|
||||
|
||||
InitData();
|
||||
InitView();
|
||||
ui.btn_null.SetClick(() => { });
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.IO;
|
||||
using DontConfuse;
|
||||
using FairyGUI;
|
||||
using FGUI.LG_secretAlbums;
|
||||
using SGModule.NetKit;
|
||||
@@ -277,6 +278,7 @@ namespace RedHotRoast
|
||||
|
||||
protected override void OnClose()
|
||||
{
|
||||
WebviewManager.Instance.SetDarkThough(true);
|
||||
// 1. 解除 UI 对 Loader 的引用
|
||||
for (var i = 0; i < ui.sc_list.numChildren; i++)
|
||||
{
|
||||
@@ -312,6 +314,7 @@ namespace RedHotRoast
|
||||
ui.sc_list.y += 38;
|
||||
}
|
||||
|
||||
WebviewManager.Instance.SetDarkThough(false);
|
||||
var eventName = GameHelper.IsAdModelOfPay() ? ADEventTrack.Event : ADEventTrack.MaxPayEvent;
|
||||
TrackKit.SendEvent(eventName, ADEventTrack.Property.shop_show);
|
||||
|
||||
|
||||
@@ -2,6 +2,7 @@ using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using DG.Tweening;
|
||||
using DontConfuse;
|
||||
using FairyGUI;
|
||||
using FGUI.LG_secretAlbums;
|
||||
using SGModule.Common.Helper;
|
||||
@@ -41,6 +42,8 @@ namespace RedHotRoast
|
||||
|
||||
protected override void OnClose()
|
||||
{
|
||||
WebviewManager.Instance.SetDarkThough(true);
|
||||
|
||||
HallManager.Instance.UpdateSecondEvent -= UpWatchAdsBtn;
|
||||
|
||||
// 清理 Loader 的材质和贴图
|
||||
@@ -80,6 +83,8 @@ namespace RedHotRoast
|
||||
{
|
||||
if (args == null) return;
|
||||
|
||||
WebviewManager.Instance.SetDarkThough(false);
|
||||
|
||||
_albumPreviewData = (AlbumPreviewData)args;
|
||||
|
||||
InitView();
|
||||
|
||||
@@ -4,6 +4,7 @@ using FairyGUI;
|
||||
using FGUI.ZM_store_17;
|
||||
using System;
|
||||
using DG.Tweening;
|
||||
using DontConfuse;
|
||||
using FGUI.ZM_Common_01;
|
||||
using SGModule.NetKit;
|
||||
using Spine.Unity;
|
||||
@@ -44,6 +45,8 @@ namespace RedHotRoast
|
||||
|
||||
protected override void OnClose()
|
||||
{
|
||||
WebviewManager.Instance.SetDarkThough(true);
|
||||
|
||||
GameHelper.showGameUI = true;
|
||||
HallManager.Instance.UpdateSecondEvent -= initList;
|
||||
HallManager.Instance.UpdateSecondEvent -= upWatchAdsBtn;
|
||||
@@ -71,6 +74,8 @@ namespace RedHotRoast
|
||||
//刘海屏
|
||||
ui.top_gold.y += Screen.safeArea.y - 15;
|
||||
}
|
||||
WebviewManager.Instance.SetDarkThough(false);
|
||||
|
||||
|
||||
var eventName = GameHelper.IsAdModelOfPay() ? ADEventTrack.Event : ADEventTrack.MaxPayEvent;
|
||||
TrackKit.SendEvent(eventName, ADEventTrack.Property.shop_show);
|
||||
|
||||
@@ -10,6 +10,7 @@ using Newtonsoft.Json;
|
||||
// using SGModule.ApplePay;
|
||||
using SGModule.Net;
|
||||
using System.Linq;
|
||||
using DontConfuse;
|
||||
using SGModule.Common.Extensions;
|
||||
|
||||
public enum VipDay
|
||||
@@ -57,6 +58,7 @@ namespace RedHotRoast
|
||||
|
||||
protected override void OnClose()
|
||||
{
|
||||
WebviewManager.Instance.SetDarkThough(true);
|
||||
if (_loader != null && !_loader.isDisposed && _loader.texture != null)
|
||||
{
|
||||
_loader.texture = null;
|
||||
@@ -82,6 +84,7 @@ namespace RedHotRoast
|
||||
{
|
||||
ui.group_.y += 68;
|
||||
}
|
||||
WebviewManager.Instance.SetDarkThough(false);
|
||||
if (GameHelper.IsGiftSwitch())
|
||||
{
|
||||
var fileName = GameHelper.GetBackgroundName(4);
|
||||
|
||||
Reference in New Issue
Block a user