Commit 69822b0f authored by timel's avatar timel

refactor: rename to graveyardSlice.ts

parent 100e9f96
......@@ -15,13 +15,6 @@ import {
initBanishedZoneImpl,
removeBanishedZoneImpl,
} from "./banishedZoneSlice";
import {
addGraveyardIdleInteractivitiesImpl,
graveyardCase,
GraveyardState,
initGraveyardImpl,
removeGraveyardImpl,
} from "./cemeretySlice";
import {
clearAllIdleInteractivitiesImpl,
clearAllPlaceInteractivitiesImpl,
......@@ -35,6 +28,13 @@ import {
ExtraDeckState,
removeExtraDeckImpl,
} from "./extraDeckSlice";
import {
addGraveyardIdleInteractivitiesImpl,
graveyardCase,
GraveyardState,
initGraveyardImpl,
removeGraveyardImpl,
} from "./graveyardSlice";
import {
addHandsIdleInteractivityImpl,
clearHandsIdleInteractivityImpl,
......
import { ygopro } from "@/api/ocgcore/idl/ocgcore";
import MsgMove = ygopro.StocGameMessage.MsgMove;
import { fetchBanishedZoneMeta } from "@/reducers/duel/banishedZoneSlice";
import { fetchGraveyardMeta } from "@/reducers/duel/cemeretySlice";
import { fetchExtraDeckMeta } from "@/reducers/duel/extraDeckSlice";
import { fetchGraveyardMeta } from "@/reducers/duel/graveyardSlice";
import { insertHandMeta } from "@/reducers/duel/handsSlice";
import { fetchMagicMeta } from "@/reducers/duel/magicSlice";
import {
......
import { ygopro } from "@/api/ocgcore/idl/ocgcore";
import { player0DeckInfo, player1DeckInfo } from "@/reducers/playerSlice";
import { store } from "@/store";
import { playerStore } from "@/valtioStores";
// FIXME: player0 不一定是当前玩家
......
import { ygopro } from "@/api/ocgcore/idl/ocgcore";
import { duelStart } from "@/reducers/moraSlice";
import { store } from "@/store";
import { moraStore } from "@/valtioStores";
export default function handleDuelStart(_pb: ygopro.YgoStocMsg) {
......
......@@ -6,8 +6,8 @@ import {
player1Leave,
player1Update,
} from "@/reducers/playerSlice";
import { playerStore } from "@/valtioStores";
import { store } from "@/store";
import { playerStore } from "@/valtioStores";
const READY_STATE = "ready";
const NO_READY_STATE = "not ready";
......
import { ygopro } from "@/api/ocgcore/idl/ocgcore";
import { setJoined } from "@/reducers/joinSlice";
import { store } from "@/store";
import { joinStore } from "@/valtioStores";
export default function handleJoinGame(pb: ygopro.YgoStocMsg) {
......
import { MessageOutlined } from "@ant-design/icons";
import { Timeline, TimelineItemProps } from "antd";
import React, { useEffect, useState, useContext } from "react";
import React, { useContext, useEffect, useState } from "react";
import { useSnapshot } from "valtio";
import { useAppSelector } from "@/hook";
import { selectChat } from "@/reducers/chatSlice";
import { valtioContext } from "@/valtioStores";
import { useSnapshot } from "valtio";
export const DuelTimeLine = () => {
const [items, setItems] = useState<TimelineItemProps[]>([]);
......
import { MessageOutlined } from "@ant-design/icons";
import { Timeline, TimelineItemProps } from "antd";
import React, { useEffect, useState, useContext } from "react";
import React, { useContext, useEffect, useState } from "react";
import { useSnapshot } from "valtio";
import { useAppSelector } from "@/hook";
import { selectChat } from "@/reducers/chatSlice";
import { valtioContext } from "@/valtioStores";
import { useSnapshot } from "valtio";
export const DuelTimeLine = () => {
const [items, setItems] = useState<TimelineItemProps[]>([]);
......
......@@ -5,7 +5,7 @@ import { useAppSelector } from "@/hook";
import {
selectMeGraveyard,
selectOpGraveyard,
} from "@/reducers/duel/cemeretySlice";
} from "@/reducers/duel/graveyardSlice";
import { cardSlotRotation } from "../utils";
import { Depth, SingleSlot } from "./SingleSlot";
......
......@@ -6,6 +6,7 @@ import {
import { Button, Modal } from "antd";
import React, { useContext, useEffect } from "react";
import { useNavigate, useParams } from "react-router-dom";
import { useSnapshot } from "valtio";
import { sendHandResult, sendTpResult } from "@/api/ocgcore/ocgHelper";
import { useConfig } from "@/config";
......@@ -19,7 +20,6 @@ import {
} from "@/reducers/moraSlice";
import { store } from "@/store";
import { valtioContext } from "@/valtioStores";
import { useSnapshot } from "valtio";
const {
automation: { isAiMode, isAiFirst },
......
......@@ -19,9 +19,10 @@ import {
Space,
Upload,
} from "antd";
import React, { useEffect, useState, useContext } from "react";
import React, { useContext, useEffect, useState } from "react";
import { useNavigate, useParams } from "react-router-dom";
import rustInit from "rust-src";
import { useSnapshot } from "valtio";
import YGOProDeck from "ygopro-deck-encode";
import { DeckManager, fetchDeck, type IDeck } from "@/api/deck";
......@@ -46,7 +47,6 @@ import {
} from "@/reducers/playerSlice";
import { store } from "@/store";
import { valtioContext } from "@/valtioStores";
import { useSnapshot } from "valtio";
const NeosConfig = useConfig();
......
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