暂时把过提示取消

master
罗家炜 2025-05-07 16:49:21 +08:00
parent 62c85471b9
commit 0f4131e125
6 changed files with 47 additions and 31 deletions

View File

@ -656,13 +656,13 @@ function M:__FangziTip(tip, weight)
if index == tip.tip_num then
type.selectedIndex = 0
obj.onClick:Set(function()
local guo_msg = MsgWindow.new(self._root_view, "确定要点过吗?", MsgWindow.MsgMode.OkAndCancel)
guo_msg.onOk:Add(function()
_gamectr:SendAction(0)
_ctr_tips.selectedIndex = 0
guo_msg:Close()
end)
guo_msg:Show()
-- local guo_msg = MsgWindow.new(self._root_view, "确定要点过吗?", MsgWindow.MsgMode.OkAndCancel)
-- guo_msg.onOk:Add(function()
_gamectr:SendAction(0)
_ctr_tips.selectedIndex = 0
-- guo_msg:Close()
-- end)
-- guo_msg:Show()
end)
else
index = index + 1

View File

@ -655,13 +655,13 @@ function M:__FangziTip(tip, weight)
if index == tip.tip_num then
type.selectedIndex = 0
obj.onClick:Set(function()
local guo_msg = MsgWindow.new(self._root_view, "确定要点过吗?", MsgWindow.MsgMode.OkAndCancel)
guo_msg.onOk:Add(function()
_gamectr:SendAction(0)
_ctr_tips.selectedIndex = 0
guo_msg:Close()
end)
guo_msg:Show()
-- local guo_msg = MsgWindow.new(self._root_view, "确定要点过吗?", MsgWindow.MsgMode.OkAndCancel)
-- guo_msg.onOk:Add(function()
_gamectr:SendAction(0)
_ctr_tips.selectedIndex = 0
-- guo_msg:Close()
-- end)
-- guo_msg:Show()
end)
else
index = index + 1

View File

@ -654,13 +654,13 @@ function M:__FangziTip(tip, weight)
if index == tip.tip_num then
type.selectedIndex = 0
obj.onClick:Set(function()
local guo_msg = MsgWindow.new(self._root_view, "确定要点过吗?", MsgWindow.MsgMode.OkAndCancel)
guo_msg.onOk:Add(function()
_gamectr:SendAction(0)
_ctr_tips.selectedIndex = 0
guo_msg:Close()
end)
guo_msg:Show()
-- local guo_msg = MsgWindow.new(self._root_view, "确定要点过吗?", MsgWindow.MsgMode.OkAndCancel)
-- guo_msg.onOk:Add(function()
_gamectr:SendAction(0)
_ctr_tips.selectedIndex = 0
-- guo_msg:Close()
-- end)
-- guo_msg:Show()
end)
else
index = index + 1

View File

@ -657,13 +657,13 @@ function M:__FangziTip(tip, weight)
if index == tip.tip_num then
type.selectedIndex = 0
obj.onClick:Set(function()
local guo_msg = MsgWindow.new(self._root_view, "确定要点过吗?", MsgWindow.MsgMode.OkAndCancel)
guo_msg.onOk:Add(function()
_gamectr:SendAction(0)
_ctr_tips.selectedIndex = 0
guo_msg:Close()
end)
guo_msg:Show()
-- local guo_msg = MsgWindow.new(self._root_view, "确定要点过吗?", MsgWindow.MsgMode.OkAndCancel)
-- guo_msg.onOk:Add(function()
_gamectr:SendAction(0)
_ctr_tips.selectedIndex = 0
-- guo_msg:Close()
-- end)
-- guo_msg:Show()
end)
else
index = index + 1

View File

@ -1,3 +1,5 @@
local RunFast_CardType = import('.RunFast_CardType')
local CardCheck = {
cardList = {},
@ -27,12 +29,15 @@ function M:initFlag()
return self
end
function M:initCards(cardList, flag, flag_allCards)
function M:initCards(cardList, flag, flag_allCards, lastCards)
print("lingmenginitCards")
pt(cardList)
local temp_long = 0
self:Clear()
self._flag_allCards = flag_allCards or false
self.cardType = lastCards.type or -1
self.cardMaxNum = lastCards.maxNum or 0
self.length = lastCards.length or 0
if flag then
for i = 1, #cardList do
local number = math.floor(cardList[i][1].card_code_number / 10)
@ -79,6 +84,8 @@ function M:initCards(cardList, flag, flag_allCards)
end
function M:CheckCards()
-- local zha
print("lingmengCheckAloneOrLong")
if self:CheckAloneOrLong() then
return true

View File

@ -745,7 +745,7 @@ function M:TouchMoveEnd(context)
if #send_card > 0 then
table.sort(send_card, tableSortNumber)
send_card = #xuan_card > 0 and xuan_card or send_card
self._cardCheck:initCards(send_card, #xuan_card > 0, #send_card == self._view_handCard.numItems)
self._cardCheck:initCards(send_card, #xuan_card > 0, #send_card == self._view_handCard.numItems, self.lastCard)
self._ctr_canSendCard.selectedIndex = self._cardCheck:CheckCards() and 1 or 0
else
self._ctr_canSendCard.selectedIndex = 0
@ -796,6 +796,7 @@ function M:ShowOutCardOption(ctr_select, type, number, length, mustPutMaxCard, p
self.send_card = {}
self.tips_card_list = self:GetCardTips(type, number, length, mustPutMaxCard)
self._ctr_canSendCard.selectedIndex = 0
self.lastCard = self.newLastCardTable(type, number, length)
if #self.tips_card_list >= 1 then
-- body --在这个方法里添加判断抬起牌是否符合出牌类型(少跑一次手牌循环)
@ -826,6 +827,14 @@ function M:ShowOutCardOption(ctr_select, type, number, length, mustPutMaxCard, p
self.ctr_put_card_option.selectedIndex = ctr_select
end
function M.newLastCardTable(type, number, length)
local newtable = {}
newtable.type = type
newtable.maxNum = number
newtable.length = length
return newtable
end
-- function M:SetOutCardInfo(cardlist, isPass, isAnim)
-- self.ctr_put_card_option.selectedIndex = 0
-- for i = 1, #self.out_card_list do
@ -1043,7 +1052,7 @@ function M:UpdateHandCardsColor()
end
if #send_card > 0 then
table.sort(send_card, tableSortNumber)
self._cardCheck:initCards(send_card, false, #send_card == self._view_handCard.numItems)
self._cardCheck:initCards(send_card, false, #send_card == self._view_handCard.numItems, self.lastCard)
self._ctr_canSendCard.selectedIndex = self._cardCheck:CheckCards() and 1 or 0
else
self._ctr_canSendCard.selectedIndex = 0