Commit dc12d558 authored by Chunchi Che's avatar Chunchi Che

update

parent 7b46d5c0
Pipeline #20700 passed with stages
in 17 minutes and 5 seconds
......@@ -31,8 +31,6 @@ import {
selectMeInitInfo,
selectOpInitInfo,
} from "../../reducers/duel/initInfoSlice";
//@ts-ignore
import rustInit from "rust-src";
// Ref: https://github.com/brianzinn/react-babylonjs/issues/126
const NeosDuel = () => {
......@@ -41,8 +39,6 @@ const NeosDuel = () => {
useEffect(() => {
const init = async () => {
await initStrings();
const wasm = await rustInit();
console.log(wasm);
};
if (initialRender.current) {
......
......@@ -44,6 +44,8 @@ import { useParams } from "react-router-dom";
import { selectDuelStart } from "../reducers/moraSlice";
import NeosConfig from "../../neos.config.json";
import YGOProDeck from "ygopro-deck-encode";
//@ts-ignore
import rustInit from "rust-src";
const READY_STATE = "ready";
......@@ -75,6 +77,10 @@ const WaitRoom = () => {
cmd: sqliteCmd.INIT,
initInfo: { dbUrl: NeosConfig.cardsDbUrl },
});
// 初始化wasm
const wasm = await rustInit();
console.log(wasm);
};
init();
......
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