Commit 564b5d13 authored by Chunchi Che's avatar Chunchi Che

fix small

parent 4b9f3813
Pipeline #22615 passed with stages
in 13 minutes and 31 seconds
......@@ -10,6 +10,7 @@
"cardImgUrl":"https://cdn02.moecube.com:444/images/ygopro-images-zh-CN",
"cardsDbUrl":"https://cdn02.moecube.com:444/ygopro-database/zh-CN/cards.cdb",
"stringsUrl":"https://cdn02.moecube.com:444/ygopro-database/zh-CN/strings.conf",
"replayUrl":"replay.neos.moe",
"chainALL":false,
"streamInterval":20,
"startDelay":1000,
......
......@@ -10,6 +10,7 @@
"cardImgUrl":"https://cdn02.moecube.com:444/images/ygopro-images-zh-CN",
"cardsDbUrl":"https://cdn02.moecube.com:444/ygopro-database/zh-CN/cards.cdb",
"stringsUrl":"https://cdn02.moecube.com:444/ygopro-database/zh-CN/strings.conf",
"replayUrl":"replay.neos.moe",
"chainALL":false,
"streamInterval":20,
"startDelay":1000,
......
......@@ -72,7 +72,7 @@ export default async (start: ygopro.StocGameMessage.MsgStart) => {
// 设置自己的额外卡组,信息是在waitroom之中拿到的
cardStore
.at(ygopro.CardZone.EXTRA, 1 - opponent)
.forEach((card) => (card.code = myExtraDeckCodes.pop()!));
.forEach((card) => (card.code = myExtraDeckCodes.pop() ?? 0));
// 初始化完后,sleep 1s,让UI初始化完成,
// 否则在和AI对战时,由于后端给传给前端的`MSG`频率太高,会导致一些问题。
......
......@@ -53,7 +53,7 @@ const ReplayModal: React.FC = () => {
cmd: socketCmd.CONNECT,
isReplay: true,
replayInfo: {
Url: "replay.neos.moe", // TODO: useConfig
Url: NeosConfig.replayUrl,
data: replay,
},
});
......@@ -67,8 +67,11 @@ const ReplayModal: React.FC = () => {
// 初始化文案
await initStrings();
// 初始化额外卡组
window.myExtraDeckCodes = [];
// 跳转
navigate("/duel/neos/replay/replay.neos.moe");
navigate(`/duel/neos/replay/${NeosConfig.replayUrl}`);
}
}}
onCancel={() => {
......
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