Commit 735cfa03 authored by nanahira's avatar nanahira

Merge branch 'master' of git.mycard.moe:nanahira/windbot into no-errmsg

parents 21a209f2 5849f1dd
Pipeline #6177 passed with stage
in 49 seconds
......@@ -46,9 +46,7 @@ upload_to_minio:
- build
tags:
- linux
image: python
script:
- pip install -U -i https://mirrors.aliyun.com/pypi/simple/ awscli
- aws s3 --endpoint=https://minio.mycard.moe:9000 sync dist/ s3://mycard/windbot
only:
- master
......
......@@ -26,7 +26,7 @@ SUPPORT_MASTER_RULE_2020
!P2-自选卡组
Name=P2 Deck=Lucky Dialog=gugugu.zh-CN
人机卡组由你选择。随缘出牌。可将你的卡组文件(.ydk)复制到WindBot的对应文件夹。
人机卡组由你选择。随缘出牌。
SELECT_DECKFILE SUPPORT_MASTER_RULE_3 SUPPORT_NEW_MASTER_RULE SUPPORT_MASTER_RULE_2020
!谜之剑士LV4-龙骑星爆
......@@ -209,7 +209,7 @@ Name=朱露咲浅羽 Deck=Salamangreat Dialog=nlch.zh-CN
浅羽的香喷喷曲奇。
AI_LV3 SUPPORT_NEW_MASTER_RULE SUPPORT_MASTER_RULE_2020
!朱露咲浅羽-真红眼
!朱露咲浅羽-真红眼龙骑士
Name=朱露咲浅羽 Deck=Dragun Dialog=nlch.zh-CN
超魔导真红眼龙骑士卡组。
AI_LV3 SUPPORT_MASTER_RULE_3 SUPPORT_NEW_MASTER_RULE SUPPORT_MASTER_RULE_2020
......@@ -228,3 +228,8 @@ AI_ANTI_META SUPPORT_MASTER_RULE_3 SUPPORT_NEW_MASTER_RULE SUPPORT_MASTER_RULE_2
Name=璃璃子 Deck=TimeThief Dialog=default
时间潜行者卡组。
AI_LV2 SUPPORT_MASTER_RULE_3 SUPPORT_NEW_MASTER_RULE SUPPORT_MASTER_RULE_2020
!濑名歌铃
Name=濑名歌铃 Deck=Brave Dialog=wof-Sena-Karin
????? 卡组。
AI_LV3 SUPPORT_MASTER_RULE_2020
#created by ...
#main
2563463
81866673
72090076
63362460
30680659
30680659
30680659
26202165
26202165
26202165
91646304
14558127
14558127
14558127
72291078
72291078
23434538
23434538
9742784
97268402
3285551
3285551
3285551
18144506
52947044
52947044
52947044
81439173
83764718
24224830
24224830
65681983
65681983
39568067
38745520
10045474
10045474
10045474
40605147
40605147
#extra
15291624
60461804
84815190
92519087
27548199
42566602
90953320
98558751
21915012
44097050
50588353
70369116
98978921
98978921
60303245
!side
55063751
55063751
55063751
34267821
34267821
34267821
43534808
43534808
43534808
94145021
94145021
94145021
14532163
14532163
14532163
......@@ -12,7 +12,7 @@
"接下来就是我的舞台"
],
"endturn": [
"我的回合结束,试试来击溃我吧"
"每个人的目的不同,我更注重强度,我只想赢。"
],
"directattack": [
"老子上了,要你的命"
......
......@@ -22,7 +22,7 @@
"directattack": [
"{0},直接攻击!",
"不过如此嘛,直接攻击!",
"快走开,我要回去睡觉了。",
"快走开,我要回去睡觉了。"
],
"attack": [
"{0},攻击{1}!",
......
{
"welcome": [
"来来来,一起来娱乐一下啊!"
"新的男朋友候选人?!来来来一起来玩啊!"
],
"deckerror": [
"没有{0}就很不娱乐。"
"要做我的男朋友怎么能不带好{0}呢?"
],
"duelstart": [
"娱乐而已,放轻松就好。"
"之前都是唬你的,现在请做好被甩的心理准备。"
],
"newturn": [
"接下来就是我的舞台咯。",
......@@ -14,34 +14,34 @@
],
"endturn": [
"OK,该你了。",
"毕竟是娱乐,这布阵应该对你来说很轻松。"
"这道题应该对你来说很轻松。"
],
"directattack": [
"{0}直接攻击对手!",
"{0}拿你那个球去撞对手啊!",
"{0}冲鸭!",
"一个巴掌拍得响!"
],
"attack": [
"{0}日了那个{1}!",
"{0}去和{1}娱乐娱乐。",
"这个{1}看起来就不娱乐啊……"
"{0}去和{1}比比长度。",
"这个{1}看起来就太短了……"
],
"ondirectattack": [
"哎呀!",
"不是说好了娱乐一下就行吗?!"
"不是说好了只吃饭的吗?!"
],
"facedownmonstername": "怪兽",
"activate": [
"我发动{0}的效果,虽然卡图上面没写,但cdb里说了就是可以这样用。",
"所以{0}什么时候进去啊?"
"我发动{0}的效果,虽然卡图上面没写,但我老婆说了就是可以这样用。",
"所以{0}什么时候涨价涨到8700万啊?"
],
"summon": [
"通召{0},下略。",
"{0}也快进去了吧……"
"{0},下略。",
"{0}最近可是稀有货啊……"
],
"setmonster": [
"日常卡手。",
"让你一把。"
"多喝热水。"
],
"chaining": [
"千防万防防不住{0}。",
......
{
"welcome": [
"早上好……啊?现在不是早上?"
],
"deckerror": [
"嘶……我醒了,{0}没了,我睡了。"
],
"duelstart": [
"我反正无所谓,你喜欢就行。",
"嘛,无所谓了。"
],
"newturn": [
"啊,是我的回合……",
"抽一张卡。"
],
"endturn": [
"睡了睡了,到我了记得叫醒我。",
"来来来,请开始你的表演。"
],
"directattack": [
"用{0}进行攻击!",
"还行,就拿{0}攻击吧。",
"尝尝这个{0}!"
],
"attack": [
"{1},挨下{0}这一拳吧!",
"胜利属于{0}!",
"{1}给我下去!"
],
"ondirectattack": [
"唔……",
"呕啊……!",
"(摆出Daisuke的姿势挡脸)"
],
"facedownmonstername": "怪兽",
"activate": [
"一花前辈用过的{0}就是好啊……",
"{0}……似乎能行。"
],
"summon": [
"啊,是没见过的孩子{0}呢。",
"{0}:糖歌这么体弱多病就别打牌了……"
],
"setmonster": [
"嗯……"
],
"chaining": [
"发动{0}的效果进行连锁。",
"在你做那件事之前我先发动{0}!",
"对3?王炸!"
]
}
\ No newline at end of file
{
"welcome": [
"又来啦?还是来找美妙子的吗?"
"又来啦?还是来……办证的?"
],
"deckerror": [
"美妙子现在不在,改天再来吧。"
"你要办的证的负责人现在不在,改天再来吧。"
],
"duelstart": [
"既然这样的话,那就先过我这关!",
"美妙子就在里面,不过你得先打赢我才能去见她。"
"负责人就在里面,不过你得先打赢我才能去见她。"
],
"newturn": [
"到我了吗?那就抽牌。",
......@@ -27,6 +27,7 @@
],
"ondirectattack": [
"习惯了。",
"挫。",
"一般。"
],
"facedownmonstername": "怪兽",
......@@ -35,7 +36,7 @@
"啊等下,使用{0}的效果。"
],
"summon": [
"召唤{0}。",
"厚礼{0}。",
"总之,把{0}拉出来就对了。",
"让我召唤{0}。"
],
......
{
"welcome":[
"早晨一杯热牛奶……嗯?我的热牛奶呢?"
],
"deckerror":[
"昨天谁进我房间里把{0}拿走了?"
],
"duelstart":[
"把你那萝莉控的心脏收起来!",
"眼睛看哪儿呢?!"
],
"newturn":[
"抓一只卡。"
],
"endturn":[
"这位同学,请开始你的表演。",
"来点海龟或者翼神龙蛋?"
],
"directattack":[
"用{0}进行攻击!",
"还行,就拿{0}攻击吧。",
"尝尝这个{0}!"
],
"attack":[
"{1},挨下{0}这一拳吧!",
"胜利属于{0}!",
"{1}给我下地狱去!"
],
"ondirectattack":[
"……啊…………",
"喂!",
"不能欺负小孩子啊!"
],
"facedownmonstername":"怪兽",
"activate":[
"{0}……似乎能行。",
"来点无敌{0}。"
],
"summon":[
"啊,是没见过的孩子{0}呢。",
"我放出了一条{0}!"
],
"setmonster":[
"嗯……"
],
"chaining":[
"发动{0}的效果进行连锁。",
"在你做那件事之前我先发动{0}!",
"17张牌你能秒我?!"
]
}
\ No newline at end of file
{
"welcome": [
"久 等 了"
],
"deckerror": [
"噔 噔 咚"
],
"duelstart": [
"让我这个大姐姐来传授给你一点人生经验。"
],
"newturn": [
"……抽牌。",
"到我了吗?那就抽牌。"
],
"endturn": [
"You Jump I Jump。",
"来点上升气流。"
],
"directattack": [
"小老弟还能站起来吗?",
"完 全 胜 利",
"{0}扭的更用力了!"
],
"attack": [
"{0},先给这个{1}一点颜色看看!",
"{1} 无 惨",
"大事不好了!{1}的牛牛炸了!"
],
"ondirectattack": [
"B A T T L E F I E L D 5",
"你特么{0}劈我是吧!",
"……果然要考虑命运石之门的抉择啊……"
],
"facedownmonstername": "怪兽",
"activate": [
"这个{0}怎么样?",
"嗯……{0}……",
"{0}{0}{0}{0}!"
],
"summon": [
"火 {0} 火",
"酸 {0} 酸",
"爱 {0} 爱"
],
"setmonster": [
"先随便盖只鸡看看……"
],
"chaining": [
"急什么啊?",
"小老弟对{0}这么毫无防备的吗?",
"这是发动{0}的超稀有机会。"
]
}
\ No newline at end of file
{
"welcome": [
"嘶……似乎来了个极其麻烦的家伙啊……"
],
"deckerror": [
"艾蕾娜?{0}的库存看看是不是空了?"
],
"duelstart": [
"今天不是你付钱就是我没货。",
"从前有座山,山里有座庙,庙里有个老和尚……"
],
"newturn": [
"纯度太低了。",
"你这肥猪。"
],
"endturn": [
"撒,细数你的王牌吧!",
"开始你的行动吧,我无所谓!"
],
"directattack": [
"{0},再斩一刀!",
"我不想说的太失礼,你还是放弃吧。",
"你也不瞧瞧你那AC样……"
],
"attack": [
"你的{1}太软了。",
"暑期促销买{1}送{0}是吧……",
"如此{1},万不可长,必须制止。"
],
"ondirectattack": [
"必可活用于下一次……",
"这杀马特的{0}……",
"……没有爆衣可以看的!"
],
"facedownmonstername": "怪兽",
"activate": [
"{0},我的超人……",
"至福……",
"十八般武艺,此乃{0}。"
],
"summon": [
"这是便宜{0}。",
"{0}很大,你忍一下。",
"说得好,{0},谢谢。"
],
"setmonster": [
"法克。"
],
"chaining": [
"小老弟,根本不可能。",
"如果你非要做如此蠢事,就别用这种脑瘫办法。",
"本来想拒绝,但{0}实在是太强力了。"
]
}
\ No newline at end of file
......@@ -19,7 +19,7 @@
"directattack": [
"{0}的直接攻击!",
"畏惧{0}的力量吧!",
"已经无法阻止{0}了!"
"人类的力量已经无法阻止{0}了!"
],
"attack": [
"{0},打倒{1}!",
......
{
"welcome": [
"又迟到了……下次注意啊。"
"嗷嗷嗷!"
],
"deckerror": [
"啊,似乎忘记带{0}了……"
],
"duelstart": [
"上课咯!",
"我可是作为一条狗在跟你打牌。",
"就让我来教教你什么叫打牌。"
],
"newturn": [
......@@ -14,7 +14,7 @@
"总之先抽卡。"
],
"endturn": [
"差不多了……那就先休息一下喝杯茶吧。",
"差不多了……那就先休息一下吃个骨头吧。",
"下面轮到你了哦。"
],
"directattack": [
......@@ -31,7 +31,7 @@
"ondirectattack": [
"啊啊啊啊啊啊啊啊啊!!!",
"哎呀!痛痛痛痛痛痛痛痛……",
"停一下停一下我还没准备好啊!"
"杀狗啦!!!!!!"
],
"facedownmonstername": "怪兽",
"activate": [
......@@ -45,7 +45,7 @@
"出现吧,{0}!"
],
"setmonster": [
"我放置了一只怪兽。"
"一对情侣一条狗……"
],
"chaining": [
"等一下!我发动{0}!",
......
......@@ -19,7 +19,7 @@
],
"directattack": [
"{0},安心去吧!",
"去去去去去去{0}别挡路!",
"大王叫{0}来巡山啊!",
"Star Lock Explosion!"
],
"attack": [
......
{
"welcome": [
"这样啊……那好吧。"
"这样啊……那随你便了。"
],
"deckerror": [
"嗯?我的{0}呢?"
"嗯?我的{0}呢?被猪吃了?"
],
"duelstart": [
"考虑要不要给对面一点面子……"
"考虑要不要给对面一点面子……算了,懒得给。"
],
"newturn": [
"……抽牌。",
......
{
"welcome": [
"所为何事,速速道来。"
],
"deckerror": [
"啊,{0}又用不出来了。"
],
"duelstart": [
"我是不会手下留情的,请拿出你最佳的状态和实力。"
],
"newturn": [
"……抽牌。",
"到我了吗?那就抽牌。"
],
"endturn": [
"我要做的都已经完成了,下面就看你的了。",
"我已经没什么可做的了,换你来吧。"
],
"directattack": [
"还能站起来吗?",
"不知道能挨得住{0}这一下吗?",
"总之{0}直接一拳就对了。"
],
"attack": [
"{0},先给这个{1}一点颜色看看吧。",
"这个{1}在{0}面前实际上十分脆弱啊……",
"嗯……总之先让这个{1}消失。"
],
"ondirectattack": [
"这点小伤,不算什么。",
"只是{0}而已,还不足以置我于死地。",
"……我还能站起来!"
],
"facedownmonstername": "怪兽",
"activate": [
"先用这个{0}的能力看看。",
"嗯……{0}的能力应该管用。",
"总之,{0}的能力应该可以应付得了。"
],
"summon": [
"嗯……现在应该先出这个,{0}。",
"嘛……这种情况{0}应该能应付得过来。",
"{0}也许会迟到,但绝不会缺席。"
],
"setmonster": [
"先随便盖个东西看看……",
"总之先加强防御。"
],
"chaining": [
"别急,先让我把{0}发动了再说。",
"对{0}这么毫无防备的吗?",
"这是发动{0}的绝佳机会。"
]
}
\ No newline at end of file
This diff is collapsed.
......@@ -106,6 +106,7 @@ namespace WindBot.Game.AI
public const int MacroCosmos = 30241314;
public const int UpstartGoblin = 70368879;
public const int CyberEmergency = 60600126;
public const int TheAgentOfCreationVenus = 64734921;
public const int EaterOfMillions = 63845230;
......@@ -471,7 +472,8 @@ namespace WindBot.Game.AI
int[] ignoreList = {
_CardId.MacroCosmos,
_CardId.UpstartGoblin,
_CardId.CyberEmergency
_CardId.CyberEmergency,
_CardId.TheAgentOfCreationVenus
};
if (Util.GetLastChainCard().IsCode(ignoreList))
return false;
......@@ -500,8 +502,9 @@ namespace WindBot.Game.AI
/// </summary>
protected bool DefaultEffectVeiler()
{
if (Util.GetLastChainCard() != null && Util.GetLastChainCard().IsCode(_CardId.GalaxySoldier) && Enemy.Hand.Count >= 3) return false;
if (Util.ChainContainsCard(_CardId.EffectVeiler))
ClientCard LastChainCard = Util.GetLastChainCard();
if (LastChainCard != null && (LastChainCard.IsCode(_CardId.GalaxySoldier) && Enemy.Hand.Count >= 3
|| LastChainCard.IsCode(_CardId.EffectVeiler, _CardId.InfiniteImpermanence)))
return false;
return DefaultBreakthroughSkill();
}
......@@ -539,7 +542,9 @@ namespace WindBot.Game.AI
protected bool DefaultInfiniteImpermanence()
{
// TODO: disable s & t
if (!DefaultUniqueTrap())
ClientCard LastChainCard = Util.GetLastChainCard();
if (LastChainCard != null && (LastChainCard.IsCode(_CardId.GalaxySoldier) && Enemy.Hand.Count >= 3
|| LastChainCard.IsCode(_CardId.EffectVeiler, _CardId.InfiniteImpermanence)))
return false;
return DefaultDisableMonster();
}
......@@ -725,6 +730,9 @@ namespace WindBot.Game.AI
/// </summary>
protected bool DefaultMonsterRepos()
{
if (Card.IsMonsterInvincible())
return Card.IsDefense();
if (Card.Attack == 0)
{
if (Card.IsFaceup() && Card.IsAttack())
......@@ -787,14 +795,14 @@ namespace WindBot.Game.AI
_CardId.JudgmentDragon,
_CardId.TopologicTrisbaena
};
int[] destroyAllOpponentList =
int[] destroyAllOpponentSpellList =
{
_CardId.HarpiesFeatherDuster,
_CardId.DarkMagicAttack
};
if (Util.ChainContainsCard(destroyAllList)) return true;
if (Enemy.HasInSpellZone(destroyAllOpponentList, true)) return true;
if (Enemy.HasInSpellZone(destroyAllOpponentSpellList, true) && Card.Location == CardLocation.SpellZone) return true;
// TODO: ChainContainsCard(id, player)
return false;
}
......
......@@ -248,6 +248,11 @@ namespace WindBot.Game
return HasInHand(cardId) || HasInGraveyard(cardId);
}
public bool HasInGraveyardOrInBanished(int cardId)
{
return HasInBanished(cardId) || HasInGraveyard(cardId);
}
public bool HasInMonstersZoneOrInGraveyard(int cardId)
{
return HasInMonstersZone(cardId) || HasInGraveyard(cardId);
......
......@@ -464,13 +464,13 @@ namespace WindBot.Game
/// <returns>Index of the selected option.</returns>
public int OnSelectOption(IList<int> options)
{
if (m_option != -1 && m_option < options.Count)
return m_option;
int result = Executor.OnSelectOption(options);
if (result != -1)
return result;
if (m_option != -1 && m_option < options.Count)
return m_option;
return 0; // Always select the first option.
}
......
......@@ -1043,6 +1043,7 @@ namespace WindBot.Game
int seq = packet.ReadByte();
packet.ReadByte(); // pos
}
if (count2 == 0) cancelable = false;
IList<ClientCard> selected = func(cards, (finishable ? 0 : 1), 1, _select_hint, cancelable);
......
......@@ -79,6 +79,8 @@ WindBot can run as a "server", provide a http interface to create bot.
* BlueEyesMaxDragon
* Brave
* ChainBurn
* DarkMagician
......
......@@ -70,6 +70,7 @@
<Compile Include="Game\AI\DeckAttribute.cs" />
<Compile Include="Game\AI\DecksManager.cs" />
<Compile Include="Game\AI\Decks\AltergeistExecutor.cs" />
<Compile Include="Game\AI\Decks\BraveExecutor.cs" />
<Compile Include="Game\AI\Decks\FamiliarPossessedExecutor.cs" />
<Compile Include="Game\AI\Decks\BlackwingExecutor.cs" />
<Compile Include="Game\AI\Decks\LuckyExecutor.cs" />
......
......@@ -26,7 +26,7 @@ namespace WindBot
Host = "127.0.0.1";
Port = 7911;
HostInfo = "";
Version = 0x1352;
Version = 0x1353;
Hand = 0;
Debug = false;
Chat = true;
......
......@@ -26,9 +26,9 @@
"dialog": "wof-Ayase-Amu"
},
{
"name": "淡野晴",
"name": "埃莉丝·科菲",
"deck": "Level VIII",
"dialog": "wof-Awaya-Haru"
"dialog": "wof-Elyse-Coffey"
},
{
"name": "城崎千夏",
......@@ -46,9 +46,9 @@
"dialog": "wof-Sagisawa-Yui"
},
{
"name": "有栖川亚里沙",
"name": "十十六木花奏子",
"deck": "Qliphort",
"dialog": "wof-Arisugawa-Arisa"
"dialog": "wof-Todoroki-Kanako"
},
{
"name": "七草一花",
......@@ -101,9 +101,9 @@
"dialog": "wof-Tsukishiro-Isuzu"
},
{
"name": "糖歌",
"name": "晴海夏佳",
"deck": "OldSchool",
"dialog": "wof-Ameuta"
"dialog": "wof-Harumi-Natsuka"
},
{
"name": "濑名歌铃",
......@@ -126,14 +126,14 @@
"dialog": "wof-Helen-Virsaladze"
},
{
"name": "二宫爱丽丝",
"name": "蓝叶雾叶",
"deck": "Dragun",
"dialog": "wof-Ninomiya-Arisu"
"dialog": "wof-Aiha-Kiriha"
},
{
"name": "木村有容",
"name": "诺玛·林斯科特",
"deck": "MathMech",
"dialog": "wof-Kimura-Yuro"
"dialog": "wof-Norma-Linscott"
},
{
"name": "砂冢明音",
......@@ -141,9 +141,9 @@
"dialog": "wof-Sunazuka-Akane"
},
{
"name": "梦野",
"name": "早见虹羽",
"deck": "PureWinds",
"dialog": "wof-Yumeno"
"dialog": "wof-Hayami-Nijiha"
},
{
"name": "白雪安娜",
......@@ -161,9 +161,9 @@
"dialog": "wof-Asami-Sorako"
},
{
"name": "黑野紫",
"name": "佐佐木茜",
"deck": "Horus",
"dialog": "wof-Kurono-Yukari"
"dialog": "wof-Sasaki-Akane"
},
{
"name": "克里斯汀·罗森塔尔",
......@@ -189,6 +189,11 @@
"name": "黑崎智秋",
"deck": "FamiliarPossessed",
"dialog": "wof-Kurosaki-Chiaki"
},
{
"name": "神代心春",
"deck": "Brave",
"dialog": "wof-Kamishiro-Koharu"
}
]
}
......@@ -188,11 +188,6 @@
"deck": "Phantasm",
"dialog": "kiwi.zh-TW"
},
{
"name": "幻煌果",
"deck": "Phantasm",
"dialog": "kiwi.zh-TW"
},
{
"name": "報社鬥士",
"deck": "GrenMajuThunderBoarder",
......@@ -214,6 +209,11 @@
"name": "璃璃子",
"deck": "TimeThief",
"dialog": "default"
},
{
"name": "濑名歌铃",
"deck": "Brave",
"dialog": "wof-Sena-Karin"
}
]
}
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