diff --git a/packages/website/src/components/Tankopedia/HeroSection/components/TankSandbox/components/SceneProps.tsx b/packages/website/src/components/Tankopedia/HeroSection/components/TankSandbox/components/SceneProps.tsx index c5c85cafc..35e45c353 100644 --- a/packages/website/src/components/Tankopedia/HeroSection/components/TankSandbox/components/SceneProps.tsx +++ b/packages/website/src/components/Tankopedia/HeroSection/components/TankSandbox/components/SceneProps.tsx @@ -32,6 +32,7 @@ export function SceneProps() { (state) => state.showGrid && !state.showEnvironment, ); const targetCircle = useRef(null); + const targetCircleDots = useRef(null); const texture = useLoader(TextureLoader, 'https://i.imgur.com/C28Z8nU.png'); texture.anisotropy = 2; @@ -93,7 +94,8 @@ export function SceneProps() { !playground.current || !shellPathHelper.current || !targetCircle.current || - DEBUG_disable + DEBUG_disable || + !targetCircleDots.current ) { return; } @@ -171,6 +173,10 @@ export function SceneProps() { targetCircle.current.position.copy(gunTarget); + const targetCircleDotsSize = `${gunTarget.distanceTo(shellOrigin)}px`; + targetCircleDots.current.style.width = targetCircleDotsSize; + targetCircleDots.current.style.height = targetCircleDotsSize; + // window.addEventListener('keydown', (event) => { // if (event.key === 'Enter') { // DEBUG_disable = true; @@ -192,25 +198,24 @@ export function SceneProps() { - - {/* + {/* */} - - - - + + +