更多bugfix (#295)
- 修复了改判后没有锁视的bug - 回滚了颜色改变 - 修复了askForGeneral选单将时返回数组而不是单武将的bug
This commit is contained in:
parent
a6c750fac5
commit
6f7e64be09
|
@ -122,7 +122,7 @@ Item {
|
||||||
|
|
||||||
Image {
|
Image {
|
||||||
id: colorItem
|
id: colorItem
|
||||||
visible: known && (suit === "" || suit === "nosuit") // && number <= 0 // <- FIX ME:需要区分“黑色有点数”和“无色有点数”
|
visible: known && (suit === "" || suit === "nosuit") // && number <= 0 // <- FIXME: 需要区分“黑色有点数”和“无色有点数”
|
||||||
source: (visible && color !== "") ? SkinBank.CARD_SUIT_DIR + "/" + color : ""
|
source: (visible && color !== "") ? SkinBank.CARD_SUIT_DIR + "/" + color : ""
|
||||||
x: 1
|
x: 1
|
||||||
}
|
}
|
||||||
|
|
|
@ -1477,7 +1477,7 @@ function Room:askForGeneral(player, generals, n, noConvert)
|
||||||
return choices
|
return choices
|
||||||
end
|
end
|
||||||
|
|
||||||
return defaultChoice
|
return n == 1 and defaultChoice[1] or defaultChoice
|
||||||
end
|
end
|
||||||
|
|
||||||
--- 询问玩家若为神将、双势力需选择一个势力。
|
--- 询问玩家若为神将、双势力需选择一个势力。
|
||||||
|
@ -1954,6 +1954,7 @@ end
|
||||||
-- * exclusive_targets: integer[]
|
-- * exclusive_targets: integer[]
|
||||||
-- * bypass_distances: boolean
|
-- * bypass_distances: boolean
|
||||||
-- * bypass_times: boolean
|
-- * bypass_times: boolean
|
||||||
|
---
|
||||||
--- 询问玩家使用一张牌。
|
--- 询问玩家使用一张牌。
|
||||||
---@param player ServerPlayer @ 要询问的玩家
|
---@param player ServerPlayer @ 要询问的玩家
|
||||||
---@param card_name? string @ 使用牌的牌名,若pattern指定了则可随意写,它影响的是烧条的提示信息
|
---@param card_name? string @ 使用牌的牌名,若pattern指定了则可随意写,它影响的是烧条的提示信息
|
||||||
|
@ -1983,10 +1984,10 @@ function Room:askForUseCard(player, card_name, pattern, prompt, cancelable, extr
|
||||||
|
|
||||||
if extra_data then
|
if extra_data then
|
||||||
if extra_data.bypass_distances then
|
if extra_data.bypass_distances then
|
||||||
player.room:setPlayerMark(player, MarkEnum.BypassDistancesLimit .. "-tmp", 1)
|
player.room:setPlayerMark(player, MarkEnum.BypassDistancesLimit .. "-tmp", 1) -- FIXME: 缺少直接传入无限制的手段
|
||||||
end
|
end
|
||||||
if extra_data.bypass_times == nil or extra_data.bypass_times then
|
if extra_data.bypass_times == nil or extra_data.bypass_times then
|
||||||
player.room:setPlayerMark(player, MarkEnum.BypassTimesLimit .. "-tmp", 1)
|
player.room:setPlayerMark(player, MarkEnum.BypassTimesLimit .. "-tmp", 1) -- FIXME: 缺少直接传入无限制的手段
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
local command = "AskForUseCard"
|
local command = "AskForUseCard"
|
||||||
|
@ -2006,8 +2007,8 @@ function Room:askForUseCard(player, card_name, pattern, prompt, cancelable, extr
|
||||||
self.logic:trigger(fk.AskForCardUse, player, askForUseCardData)
|
self.logic:trigger(fk.AskForCardUse, player, askForUseCardData)
|
||||||
|
|
||||||
if askForUseCardData.result and type(askForUseCardData.result) == 'table' then
|
if askForUseCardData.result and type(askForUseCardData.result) == 'table' then
|
||||||
player.room:setPlayerMark(player, MarkEnum.BypassDistancesLimit .. "-tmp", 0)
|
player.room:setPlayerMark(player, MarkEnum.BypassDistancesLimit .. "-tmp", 0) -- FIXME: 缺少直接传入无限制的手段
|
||||||
player.room:setPlayerMark(player, MarkEnum.BypassTimesLimit .. "-tmp", 0)
|
player.room:setPlayerMark(player, MarkEnum.BypassTimesLimit .. "-tmp", 0) -- FIXME: 缺少直接传入无限制的手段
|
||||||
return askForUseCardData.result
|
return askForUseCardData.result
|
||||||
else
|
else
|
||||||
local useResult
|
local useResult
|
||||||
|
@ -2022,8 +2023,8 @@ function Room:askForUseCard(player, card_name, pattern, prompt, cancelable, extr
|
||||||
Fk.currentResponsePattern = nil
|
Fk.currentResponsePattern = nil
|
||||||
|
|
||||||
if result ~= "" then
|
if result ~= "" then
|
||||||
player.room:setPlayerMark(player, MarkEnum.BypassDistancesLimit .. "-tmp", 0)
|
player.room:setPlayerMark(player, MarkEnum.BypassDistancesLimit .. "-tmp", 0) -- FIXME: 缺少直接传入无限制的手段
|
||||||
player.room:setPlayerMark(player, MarkEnum.BypassTimesLimit .. "-tmp", 0)
|
player.room:setPlayerMark(player, MarkEnum.BypassTimesLimit .. "-tmp", 0) -- FIXME: 缺少直接传入无限制的手段
|
||||||
useResult = self:handleUseCardReply(player, result)
|
useResult = self:handleUseCardReply(player, result)
|
||||||
|
|
||||||
if type(useResult) == "string" and useResult ~= "" then
|
if type(useResult) == "string" and useResult ~= "" then
|
||||||
|
@ -2034,8 +2035,8 @@ function Room:askForUseCard(player, card_name, pattern, prompt, cancelable, extr
|
||||||
|
|
||||||
return useResult
|
return useResult
|
||||||
end
|
end
|
||||||
player.room:setPlayerMark(player, MarkEnum.BypassDistancesLimit .. "-tmp", 0)
|
player.room:setPlayerMark(player, MarkEnum.BypassDistancesLimit .. "-tmp", 0) -- FIXME: 缺少直接传入无限制的手段
|
||||||
player.room:setPlayerMark(player, MarkEnum.BypassTimesLimit .. "-tmp", 0)
|
player.room:setPlayerMark(player, MarkEnum.BypassTimesLimit .. "-tmp", 0) -- FIXME: 缺少直接传入无限制的手段
|
||||||
return nil
|
return nil
|
||||||
end
|
end
|
||||||
|
|
||||||
|
@ -3155,6 +3156,7 @@ function Room:retrial(card, player, judge, skillName, exchange)
|
||||||
}
|
}
|
||||||
|
|
||||||
self:moveCards(move2)
|
self:moveCards(move2)
|
||||||
|
Fk:filterCard(judge.card.id, judge.who, judge)
|
||||||
end
|
end
|
||||||
|
|
||||||
--- 弃置一名角色的牌。
|
--- 弃置一名角色的牌。
|
||||||
|
|
|
@ -87,8 +87,9 @@ fk.IceDamage = 4
|
||||||
|
|
||||||
--- askForUseCard中的extra_data
|
--- askForUseCard中的extra_data
|
||||||
---@class UseExtraData
|
---@class UseExtraData
|
||||||
---@field public must_targets? integer[] @ 必须选的目标(?)
|
---@field public must_targets? integer[] @ 必须选择这些目标?
|
||||||
---@field public exclusive_targets? integer[] @ ??
|
---@field public include_targets? integer[] @ 必须选其中一个目标?
|
||||||
|
---@field public exclusive_targets? integer[] @ 只能选择这些目标?
|
||||||
---@field public bypass_distances? boolean @ 无距离限制?
|
---@field public bypass_distances? boolean @ 无距离限制?
|
||||||
---@field public bypass_times? boolean @ 无次数限制?
|
---@field public bypass_times? boolean @ 无次数限制?
|
||||||
---@field public playing? boolean @ (AI专用) 出牌阶段?
|
---@field public playing? boolean @ (AI专用) 出牌阶段?
|
||||||
|
|
|
@ -4,9 +4,9 @@ Fk:loadTranslationTable({
|
||||||
["standard_cards"] = "Standard",
|
["standard_cards"] = "Standard",
|
||||||
|
|
||||||
["unknown_card"] = '<font color="#B5BA00"><b>Unknown card</b></font>',
|
["unknown_card"] = '<font color="#B5BA00"><b>Unknown card</b></font>',
|
||||||
["log_spade"] = '<font color="black">♠</font>',
|
["log_spade"] = '♠',
|
||||||
["log_heart"] = '<font color="#CC3131">♥</font>',
|
["log_heart"] = '<font color="#CC3131">♥</font>',
|
||||||
["log_club"] = '<font color="black">♣</font>',
|
["log_club"] = '♣',
|
||||||
["log_diamond"] = '<font color="#CC3131">♦</font>',
|
["log_diamond"] = '<font color="#CC3131">♦</font>',
|
||||||
["log_nosuit"] = "No suit",
|
["log_nosuit"] = "No suit",
|
||||||
-- ["spade"] = "Spade",
|
-- ["spade"] = "Spade",
|
||||||
|
@ -14,7 +14,7 @@ Fk:loadTranslationTable({
|
||||||
-- ["club"] = "Club",
|
-- ["club"] = "Club",
|
||||||
-- ["diamond"] = "Diamond",
|
-- ["diamond"] = "Diamond",
|
||||||
["nosuit"] = "No suit",
|
["nosuit"] = "No suit",
|
||||||
["black"] = '<font color="black">Black</font>',
|
["black"] = 'Black',
|
||||||
["red"] = '<font color="#CC3131">Red</font>',
|
["red"] = '<font color="#CC3131">Red</font>',
|
||||||
["nocolor"] = '<font color="grey">NoColor</font>',
|
["nocolor"] = '<font color="grey">NoColor</font>',
|
||||||
-- ["suit"] = "花色",
|
-- ["suit"] = "花色",
|
||||||
|
|
|
@ -4,9 +4,9 @@ Fk:loadTranslationTable{
|
||||||
["standard_cards"] = "标+EX",
|
["standard_cards"] = "标+EX",
|
||||||
|
|
||||||
["unknown_card"] = '<font color="#B5BA00"><b>未知牌</b></font>',
|
["unknown_card"] = '<font color="#B5BA00"><b>未知牌</b></font>',
|
||||||
["log_spade"] = '<font color="black">♠</font>',
|
["log_spade"] = '♠',
|
||||||
["log_heart"] = '<font color="#CC3131">♥</font>',
|
["log_heart"] = '<font color="#CC3131">♥</font>',
|
||||||
["log_club"] = '<font color="black">♣</font>',
|
["log_club"] = '♣',
|
||||||
["log_diamond"] = '<font color="#CC3131">♦</font>',
|
["log_diamond"] = '<font color="#CC3131">♦</font>',
|
||||||
["log_nosuit"] = "无花色",
|
["log_nosuit"] = "无花色",
|
||||||
["spade"] = "黑桃",
|
["spade"] = "黑桃",
|
||||||
|
@ -14,7 +14,7 @@ Fk:loadTranslationTable{
|
||||||
["club"] = "梅花",
|
["club"] = "梅花",
|
||||||
["diamond"] = "方块",
|
["diamond"] = "方块",
|
||||||
["nosuit"] = "无花色",
|
["nosuit"] = "无花色",
|
||||||
["black"] = '<font color="black">黑色</font>',
|
["black"] = '黑色',
|
||||||
["red"] = '<font color="#CC3131">红色</font>',
|
["red"] = '<font color="#CC3131">红色</font>',
|
||||||
["nocolor"] = '<font color="grey">无色</font>',
|
["nocolor"] = '<font color="grey">无色</font>',
|
||||||
["suit"] = "花色",
|
["suit"] = "花色",
|
||||||
|
|
Loading…
Reference in New Issue