completionId: cgen-def3fbf2d6c148acb19283cfb26ab636
cgen-def3fbf2d6c148acb19283cfb26ab636
This commit is contained in:
parent
d3a45639d2
commit
a9a793f416
1 changed files with 4 additions and 3 deletions
|
|
@ -14,11 +14,12 @@ import {
|
|||
import { useNavigate } from "react-router-dom";
|
||||
import { useEffect, useState, useRef } from "react";
|
||||
import LoadingScreen from "@/components/LoadingScreen";
|
||||
import { aethexToast } from "@/lib/aethex-toast";
|
||||
import { useArmToast } from "@/hooks/use-arm-toast";
|
||||
|
||||
export default function GameForge() {
|
||||
const navigate = useNavigate();
|
||||
const { theme } = useArmTheme();
|
||||
const armToast = useArmToast();
|
||||
const [isLoading, setIsLoading] = useState(true);
|
||||
const toastShownRef = useRef(false);
|
||||
|
||||
|
|
@ -26,13 +27,13 @@ export default function GameForge() {
|
|||
const timer = setTimeout(() => {
|
||||
setIsLoading(false);
|
||||
if (!toastShownRef.current) {
|
||||
aethexToast.system("GameForge engine initialized");
|
||||
armToast.system("GameForge engine initialized");
|
||||
toastShownRef.current = true;
|
||||
}
|
||||
}, 900);
|
||||
|
||||
return () => clearTimeout(timer);
|
||||
}, []);
|
||||
}, [armToast]);
|
||||
|
||||
if (isLoading) {
|
||||
return (
|
||||
|
|
|
|||
Loading…
Reference in a new issue