TCX_dev_zeroFive_online
parent
4fd60c4cee
commit
b5f92d9ffb
|
@ -36,7 +36,7 @@ RectTransform:
|
|||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
m_AnchorMin: {x: 0.5, y: 0.5}
|
||||
m_AnchorMax: {x: 0.5, y: 0.5}
|
||||
m_AnchoredPosition: {x: 364.76, y: -8.9}
|
||||
m_AnchoredPosition: {x: 364.76, y: 15}
|
||||
m_SizeDelta: {x: 211.17, y: 77.51}
|
||||
m_Pivot: {x: 0.5, y: 0.5}
|
||||
--- !u!222 &181696933
|
||||
|
@ -373,7 +373,7 @@ GameObject:
|
|||
m_Icon: {fileID: 0}
|
||||
m_NavMeshLayer: 0
|
||||
m_StaticEditorFlags: 0
|
||||
m_IsActive: 1
|
||||
m_IsActive: 0
|
||||
--- !u!224 &532550089
|
||||
RectTransform:
|
||||
m_ObjectHideFlags: 0
|
||||
|
@ -570,7 +570,7 @@ GameObject:
|
|||
m_Icon: {fileID: 0}
|
||||
m_NavMeshLayer: 0
|
||||
m_StaticEditorFlags: 0
|
||||
m_IsActive: 1
|
||||
m_IsActive: 0
|
||||
--- !u!224 &1226409383
|
||||
RectTransform:
|
||||
m_ObjectHideFlags: 0
|
||||
|
@ -682,7 +682,7 @@ RectTransform:
|
|||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
m_AnchorMin: {x: 0.5, y: 0.5}
|
||||
m_AnchorMax: {x: 0.5, y: 0.5}
|
||||
m_AnchoredPosition: {x: 140.5, y: -25.6}
|
||||
m_AnchoredPosition: {x: 171, y: 18}
|
||||
m_SizeDelta: {x: 160, y: 30}
|
||||
m_Pivot: {x: 0.5, y: 0.5}
|
||||
--- !u!222 &1579231202
|
||||
|
@ -974,7 +974,7 @@ RectTransform:
|
|||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
m_AnchorMin: {x: 0.5, y: 0.5}
|
||||
m_AnchorMax: {x: 0.5, y: 0.5}
|
||||
m_AnchoredPosition: {x: -60.6, y: 21}
|
||||
m_AnchoredPosition: {x: -60.6, y: 18}
|
||||
m_SizeDelta: {x: 361.9, y: 30}
|
||||
m_Pivot: {x: 0.5, y: 0.5}
|
||||
--- !u!222 &1865435117
|
||||
|
@ -1012,13 +1012,13 @@ MonoBehaviour:
|
|||
m_BestFit: 0
|
||||
m_MinSize: 3
|
||||
m_MaxSize: 40
|
||||
m_Alignment: 0
|
||||
m_Alignment: 3
|
||||
m_AlignByGeometry: 0
|
||||
m_RichText: 1
|
||||
m_HorizontalOverflow: 0
|
||||
m_VerticalOverflow: 1
|
||||
m_LineSpacing: 1
|
||||
m_Text: "\u4F7F\u75281\u5143\u76F4\u5145\u5361\u53EF\u589E\u52A0\u4F59\u989D\u4ECA\u65E5\u8FD8\u53EF\u5B58\u5165"
|
||||
m_Text: "\u4ECA\u65E5\u8FD8\u53EF\u4F7F\u7528\u73B0\u91D1\u5238"
|
||||
--- !u!1 &2068929900
|
||||
GameObject:
|
||||
m_ObjectHideFlags: 0
|
||||
|
@ -1036,7 +1036,7 @@ GameObject:
|
|||
m_Icon: {fileID: 0}
|
||||
m_NavMeshLayer: 0
|
||||
m_StaticEditorFlags: 0
|
||||
m_IsActive: 1
|
||||
m_IsActive: 0
|
||||
--- !u!224 &2068929901
|
||||
RectTransform:
|
||||
m_ObjectHideFlags: 0
|
||||
|
|
|
@ -7102,9 +7102,10 @@ function NetManager.SendGmBuyGoodRequest(_id,func)
|
|||
end)
|
||||
end
|
||||
--优惠券购买物品
|
||||
function NetManager.SendYHQBuyGoodRequest(_id,func)
|
||||
function NetManager.SendYHQBuyGoodRequest(_id,_buyType,func)
|
||||
local data = PlayerInfoProto_pb.GmBuyGoodRequest()
|
||||
data.goodsId=_id
|
||||
data.buyType=_buyType
|
||||
LogError("id========================".._id)
|
||||
local msg = data:SerializeToString()
|
||||
Network:SendMessageWithCallBack(MessageTypeProto_pb.VouchersBuyGiftRequest,MessageTypeProto_pb.TEST_BUY_GIGT_GOODS_RESPONSE,msg,function(buffer)
|
||||
|
|
|
@ -64,11 +64,49 @@ function this.Pay(id, func)
|
|||
CheckRedPointStatus(RedPointType.GrowthPackage) --成长礼包的红点检测
|
||||
--直购商品
|
||||
local rechargeConfig = ConfigManager.GetConfigData(ConfigName.RechargeCommodityConfig, id)
|
||||
|
||||
if rechargeConfig.OtherBuy1 then
|
||||
local yhqNum = BagManager.GetItemCountById(1342)
|
||||
local useTime = PrivilegeManager.GetPrivilegeUsedTimes(PRIVILEGE_TYPE.GM_YI_YUAN_UP_TIME)
|
||||
local missions = ActivityGiftManager.GetActivityInfoByType(ActivityTypeDef.shuaChongTeQuan).mission
|
||||
local index = 1
|
||||
if missions then
|
||||
for i = 1, #missions do
|
||||
if missions[i].state ~= 0 then
|
||||
index = i
|
||||
end
|
||||
end
|
||||
end
|
||||
local privile = ConfigManager.GetConfigData(ConfigName.PrivilegeTypeConfig, 2101)
|
||||
local maxnum = privile.Condition[index][2]
|
||||
if yhqNum >= rechargeConfig.Price and rechargeConfig.Price > 0 and (maxnum - useTime) >= rechargeConfig.Price then
|
||||
local sureFunc = function()
|
||||
NetManager.SendYHQBuyGoodRequest(id, 1)
|
||||
end
|
||||
local cancelFunc = function()
|
||||
if AppConst.isSDKLogin and rechargeConfig.Price > 0 then
|
||||
PayManager.SdkPay({ Id = id, orderId = orderId })
|
||||
else
|
||||
NetManager.RequestBuyGiftGoods(id, function(msg)
|
||||
this.onSdkPayResult(id)
|
||||
end)
|
||||
end
|
||||
end
|
||||
local args = {}
|
||||
args[1] = "该礼包可通过消耗现金券获得,是否继续充值" ..
|
||||
"\n<color=\"#FF0000\">现金券剩余:" .. yhqNum .. "</color>\n可用余额" .. (maxnum - useTime)
|
||||
args[2] = "现金券购买"
|
||||
args[3] = "直接充值"
|
||||
args[4] = sureFunc
|
||||
args[5] = cancelFunc
|
||||
UIManager.OpenPanel(UIName.GMCommonConfirmPanel, args)
|
||||
return
|
||||
end
|
||||
end
|
||||
if rechargeConfig.OtherBuy then
|
||||
local yhqNum = BagManager.GetItemCountById(108)
|
||||
if yhqNum >= rechargeConfig.Price and rechargeConfig.Price > 0 then
|
||||
local sureFunc = function()
|
||||
NetManager.SendYHQBuyGoodRequest(id)
|
||||
NetManager.SendYHQBuyGoodRequest(id, 0)
|
||||
end
|
||||
local cancelFunc = function()
|
||||
if AppConst.isSDKLogin and rechargeConfig.Price > 0 then
|
||||
|
@ -88,6 +126,7 @@ function this.Pay(id, func)
|
|||
UIManager.OpenPanel(UIName.GMCommonConfirmPanel, args)
|
||||
return
|
||||
end
|
||||
end
|
||||
if rechargeConfig.BuyType == 1 then --人民币
|
||||
if AppConst.isSDKLogin and rechargeConfig.Price > 0 then
|
||||
PayManager.SdkPay({ Id = id, orderId = orderId })
|
||||
|
@ -148,11 +187,11 @@ function this.RequestPay(context)
|
|||
Log("onPayCallback::" .. payResp)
|
||||
local str = string.split(payResp, "#")
|
||||
local result = tonumber(str[1])
|
||||
if AppConst.SdkChannel == "TCXQUZB" or AppConst.SdkChannel == "TCXQUZB2" then
|
||||
LogError("太初行quick渠道支付参数回调")
|
||||
else
|
||||
LogError("太初行027渠道支付参数回调")
|
||||
end
|
||||
--if AppConst.SdkChannel == "TCXQUZB" or AppConst.SdkChannel == "TCXQUZB2" then
|
||||
--LogError("太初行quick渠道支付参数回调")
|
||||
--else
|
||||
--LogError("太初行027渠道支付参数回调")
|
||||
--end
|
||||
if result == SDK_RESULT.SUCCESS then
|
||||
|
||||
elseif result == SDK_RESULT.FAILED then
|
||||
|
@ -175,8 +214,8 @@ function this.RequestPay(context)
|
|||
params.serverName = PlayerManager.serverInfo.name
|
||||
local chanel = AppConst.SdkChannel
|
||||
-- 角色相关
|
||||
if chanel and (chanel == "TCXQKGM09" or chanel == "TCXQUZB" or chanel == "TCXQUZB2" or chanel == "TCXQKZB07") then
|
||||
LogError("太初行quick渠道支付参数"..PlayerManager.uid)
|
||||
--if chanel and (chanel == "TCXQKGM09" or chanel == "TCXQUZB" or chanel == "TCXQUZB2" or chanel == "TCXQKZB07") then
|
||||
--LogError("太初行quick渠道支付参数"..PlayerManager.uid)
|
||||
params.roleID = tostring(PlayerManager.uid) ..
|
||||
"_" ..
|
||||
tostring(context.Id) ..
|
||||
|
@ -193,13 +232,13 @@ function this.RequestPay(context)
|
|||
"_" ..
|
||||
AppConst
|
||||
.Platform --.."_"..tostring(context.orderId or "0").."_"..tostring(LoginManager.ServerId)
|
||||
else
|
||||
LogError("太初行027渠道支付参数"..PlayerManager.uid)
|
||||
params.roleID = PlayerManager.uid
|
||||
--else
|
||||
--LogError("太初行027渠道支付参数"..PlayerManager.uid)
|
||||
--params.roleID = PlayerManager.uid
|
||||
--LogError("太初行027渠道支付参数"..context.RechargeId)
|
||||
LogError("太初行027渠道支付参数"..context.RechargeId)
|
||||
params.extension = context.RechargeId
|
||||
end
|
||||
--LogError("太初行027渠道支付参数"..context.RechargeId)
|
||||
--params.extension = context.RechargeId
|
||||
--end
|
||||
params.roleName = PlayerManager.nickName
|
||||
params.roleLevel = PlayerManager.level
|
||||
params.vip = tostring(VipManager.GetVipLevel())
|
||||
|
|
|
@ -43,7 +43,6 @@ end
|
|||
|
||||
--界面打开时调用(用于子类重写)
|
||||
function PrayRewardItemPopup:OnOpen(_drop,_num,_chooseRewardId,_func)
|
||||
|
||||
isPlayerAniEnd = true
|
||||
chooseRewardId = _chooseRewardId
|
||||
func = _func
|
||||
|
|
Loading…
Reference in New Issue