Skip to content

Commit

Permalink
fix: limit min and max distance
Browse files Browse the repository at this point in the history
  • Loading branch information
longtv2222 committed Dec 20, 2023
1 parent e8ca6e2 commit 2668302
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions prototype/src/App.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ export default function App() {
};

const setCarInterior = (interior: string) => {
const model = levaStore.get("Select") as Model;
const model = levaStore.get("Select") as Model;8
setCarsState({
...carsStateRef.current,
[model]: {
Expand Down Expand Up @@ -114,7 +114,7 @@ export default function App() {
blur={0.5}
/>
{stats ? <Stats /> : undefined}
<OrbitControls maxPolarAngle={7 * Math.PI / 18} maxDistance={20} autoRotate={Rotation} />
<OrbitControls maxPolarAngle={7 * Math.PI / 18} autoRotate={Rotation} minDistance={2} maxDistance={15} />
</Canvas>
<Loader />
<Leva
Expand Down

0 comments on commit 2668302

Please sign in to comment.