Commit 45e27842 authored by nanahira's avatar nanahira

Merge branch 'master' into rd

parents ff7ab469 ebd93879
Pipeline #5602 passed with stage
in 35 seconds
...@@ -18,7 +18,7 @@ build: ...@@ -18,7 +18,7 @@ build:
- apt update && apt -y install p7zip-full tar - apt update && apt -y install p7zip-full tar
- msbuild /p:Configuration=Release /p:TargetFrameworkVersion=v4.6 - msbuild /p:Configuration=Release /p:TargetFrameworkVersion=v4.6
- mv -f bin/Release WindBot - mv -f bin/Release WindBot
- rm -rf WindBot/WindBot.exe.config #- rm -rf WindBot/WindBot.exe.config
- mv -f BotWrapper/bin/Release/Bot.exe . - mv -f BotWrapper/bin/Release/Bot.exe .
- mv -f BotWrapper/bin/Release/bot.conf . - mv -f BotWrapper/bin/Release/bot.conf .
- mv -f BotWrapper/BotWrapper.sh ./bot - mv -f BotWrapper/BotWrapper.sh ./bot
...@@ -46,9 +46,7 @@ upload_to_minio: ...@@ -46,9 +46,7 @@ upload_to_minio:
- build - build
tags: tags:
- linux - linux
image: python
script: 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 - aws s3 --endpoint=https://minio.mycard.moe:9000 sync dist/ s3://mycard/windbot
only: only:
- master - master
......
...@@ -220,11 +220,11 @@ Name=玻璃女巫 Deck=Witchcraft Dialog=verre.zh-CN ...@@ -220,11 +220,11 @@ Name=玻璃女巫 Deck=Witchcraft Dialog=verre.zh-CN
AI_LV3 SUPPORT_MASTER_RULE_3 SUPPORT_NEW_MASTER_RULE SUPPORT_MASTER_RULE_2020 AI_LV3 SUPPORT_MASTER_RULE_3 SUPPORT_NEW_MASTER_RULE SUPPORT_MASTER_RULE_2020
!源千雪-凭依装着 !源千雪-凭依装着
Name=源千雪 Deck=FamiliarPossessed Dialog=default.zh-CN Name=源千雪 Deck=FamiliarPossessed Dialog=default
凭依装着卡组。 凭依装着卡组。
AI_ANTI_META SUPPORT_MASTER_RULE_3 SUPPORT_NEW_MASTER_RULE SUPPORT_MASTER_RULE_2020 AI_ANTI_META SUPPORT_MASTER_RULE_3 SUPPORT_NEW_MASTER_RULE SUPPORT_MASTER_RULE_2020
!璃璃子-时劫者 !璃璃子-时劫者
Name=璃璃子 Deck=TimeThief Dialog=default.zh-CN Name=璃璃子 Deck=TimeThief Dialog=default
时间潜行者卡组。 时间潜行者卡组。
AI_LV2 SUPPORT_MASTER_RULE_3 SUPPORT_NEW_MASTER_RULE SUPPORT_MASTER_RULE_2020 AI_LV2 SUPPORT_MASTER_RULE_3 SUPPORT_NEW_MASTER_RULE SUPPORT_MASTER_RULE_2020
...@@ -725,6 +725,9 @@ namespace WindBot.Game.AI ...@@ -725,6 +725,9 @@ namespace WindBot.Game.AI
/// </summary> /// </summary>
protected bool DefaultMonsterRepos() protected bool DefaultMonsterRepos()
{ {
if (Card.IsMonsterInvincible())
return Card.IsDefense();
if (Card.Attack == 0) if (Card.Attack == 0)
{ {
if (Card.IsFaceup() && Card.IsAttack()) if (Card.IsFaceup() && Card.IsAttack())
......
...@@ -188,8 +188,8 @@ namespace WindBot.Game ...@@ -188,8 +188,8 @@ namespace WindBot.Game
int duel_rule = packet.ReadByte(); int duel_rule = packet.ReadByte();
_ai.Duel.IsNewRule = (duel_rule >= 4); _ai.Duel.IsNewRule = (duel_rule >= 4);
_ai.Duel.IsNewRule2020 = (duel_rule >= 5); _ai.Duel.IsNewRule2020 = (duel_rule >= 5);
BinaryWriter deck = buildUpdateDeck(pickDeckOnResult()); //BinaryWriter deck = buildUpdateDeck(pickDeckOnResult());
Connection.Send(deck); //Connection.Send(deck);
_ai.OnJoinGame(); _ai.OnJoinGame();
} }
...@@ -228,6 +228,8 @@ namespace WindBot.Game ...@@ -228,6 +228,8 @@ namespace WindBot.Game
_room.Position = pos; _room.Position = pos;
_room.IsHost = ((type >> 4) & 0xF) != 0; _room.IsHost = ((type >> 4) & 0xF) != 0;
_room.IsReady[pos] = true; _room.IsReady[pos] = true;
BinaryWriter deck = buildUpdateDeck(pickDeckOnResult());
Connection.Send(deck);
Connection.Send(CtosMessage.HsReady); Connection.Send(CtosMessage.HsReady);
} }
...@@ -353,7 +355,7 @@ namespace WindBot.Game ...@@ -353,7 +355,7 @@ namespace WindBot.Game
if (card != null) if (card != null)
_ai.OnDeckError(card.Name); _ai.OnDeckError(card.Name);
else else
_ai.OnDeckError("Unknown Card"); _ai.OnDeckError(code.ToString());
} }
else else
_ai.OnDeckError("DECK"); _ai.OnDeckError("DECK");
......
...@@ -26,7 +26,7 @@ namespace WindBot ...@@ -26,7 +26,7 @@ namespace WindBot
Host = "127.0.0.1"; Host = "127.0.0.1";
Port = 7911; Port = 7911;
HostInfo = ""; HostInfo = "";
Version = 0x1352; Version = 0x1353;
Hand = 0; Hand = 0;
Debug = false; Debug = false;
Chat = true; Chat = true;
......
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