Files
La-Fabrik/src/world/WorldPlane.tsx
T
2026-05-27 00:09:26 +02:00

22 lines
534 B
TypeScript

import { WORLD_BOUNDS_CONFIG } from "@/data/world/worldBoundsConfig";
export function WorldPlane(): React.JSX.Element | null {
if (!WORLD_BOUNDS_CONFIG.enabled) {
return null;
}
const { center, planeColor, planeY, size } = WORLD_BOUNDS_CONFIG;
return (
<mesh
name="world-plane"
position={[center[0], planeY, center[2]]}
receiveShadow
rotation={[-Math.PI / 2, 0, 0]}
>
<planeGeometry args={size} />
<meshStandardMaterial color={planeColor} roughness={1} />
</mesh>
);
}