diff --git a/src/components/three/interaction/VillageoisHelperObject.tsx b/src/components/three/interaction/NPCHelper.tsx similarity index 71% rename from src/components/three/interaction/VillageoisHelperObject.tsx rename to src/components/three/interaction/NPCHelper.tsx index e10f156..1bda30e 100644 --- a/src/components/three/interaction/VillageoisHelperObject.tsx +++ b/src/components/three/interaction/NPCHelper.tsx @@ -3,21 +3,17 @@ import { useGameStore } from "@/managers/stores/useGameStore"; import { Debug } from "@/utils/debug/Debug"; import type { Vector3Tuple } from "@/types/three/three"; -interface VillageoisHelperObjectProps { +interface NPCHelperProps { position: Vector3Tuple; } -export function VillageoisHelperObject({ - position, -}: VillageoisHelperObjectProps): React.JSX.Element { +export function NPCHelper({ position }: NPCHelperProps): React.JSX.Element { const step = useGameStore((state) => state.missionFlow.step); const setStep = useGameStore((state) => state.setFlowStep); const debug = Debug.getInstance(); const handlePress = (): void => { - console.log("[VillageoisHelper] handlePress called, current step:", step); if (step === "searching") { - console.log("[VillageoisHelper] Transitioning to helped"); setStep("helped"); } }; @@ -28,13 +24,6 @@ export function VillageoisHelperObject({ return <>; } - console.log( - "[VillageoisHelper] Rendering, step:", - step, - "position:", - position, - ); - return ( state.missionFlow.step); const setStep = useGameStore((state) => state.setFlowStep); const setCanMove = useGameStore((state) => state.setCanMove); @@ -17,19 +17,13 @@ export function CentralObject({ const debug = Debug.getInstance(); const handlePress = (): void => { - console.log("[CentralObject] handlePress called, current step:", step); - if (step === "helped") { - console.log("[CentralObject] Transitioning to manipulation"); setCanMove(false); setStep("manipulation"); } else if (step === "searching") { - console.log("[CentralObject] Showing help message"); showDialog( "Cet objet est trop lourd pour le porter tout seul, trouve de l'aide", ); - } else { - console.log("[CentralObject] Step is not helped or searching, skipping"); } }; @@ -40,8 +34,6 @@ export function CentralObject({ return <>; } - console.log("[CentralObject] Rendering, step:", step, "position:", position); - return ( - - + + {noMusic ? null : } {noCinematics ? null : } {noDialogues ? null : }