맵 3D: 재질 · 텍스처(디퓨즈 256px) · 두 층 섞기 · 법선 포함 glb, 사이트가 glb 재질로 그림
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
@@ -159,8 +159,9 @@ export default function ReplayViewer({ m, replay, sync }: Props) {
|
||||
controls.update();
|
||||
};
|
||||
resetCam.current();
|
||||
scene.add(new THREE.HemisphereLight(0xffffff, 0x223344, 1.6));
|
||||
const sun = new THREE.DirectionalLight(0xffffff, 1.2);
|
||||
// 게임처럼 밝게: 하늘빛 + 해 (맵 텍스처가 어둡게 묻히지 않게)
|
||||
scene.add(new THREE.HemisphereLight(0xffffff, 0x8a8f99, 2.6));
|
||||
const sun = new THREE.DirectionalLight(0xfff4e0, 1.8);
|
||||
sun.position.set(30, 80, 20);
|
||||
scene.add(sun);
|
||||
|
||||
@@ -200,8 +201,8 @@ export default function ReplayViewer({ m, replay, sync }: Props) {
|
||||
.then((info) => {
|
||||
if (disposed) return;
|
||||
if (!info) return setMap3d({ state: 'none' });
|
||||
const mat = mapMaterial(clip, { lo: 0, hi: Math.max(8, (zTop - zBase + 600) * hPerCm) });
|
||||
return loadMap3d(info.url, mat, (p) => !disposed && setMap3d({ state: 'loading', progress: p })).then((obj) => {
|
||||
const fallback = () => mapMaterial(clip, { lo: 0, hi: Math.max(8, (zTop - zBase + 600) * hPerCm) });
|
||||
return loadMap3d(info.url, clip, fallback, (p) => !disposed && setMap3d({ state: 'loading', progress: p })).then((obj) => {
|
||||
if (disposed) return;
|
||||
mapGroup.add(obj);
|
||||
mapGroup.updateMatrixWorld(true);
|
||||
|
||||
Reference in New Issue
Block a user