Spaces:
Running
Running
cutechicken
commited on
Commit
โข
ca1e346
1
Parent(s):
e17e33c
Update game.js
Browse files
game.js
CHANGED
@@ -336,7 +336,8 @@ class Game {
|
|
336 |
|
337 |
// ํ์๊ด ์ค์ - ๊ทธ๋ฆผ์ ํ์ง ๋ฎ์ถค
|
338 |
const directionalLight = new THREE.DirectionalLight(0xffffff, 1.2);
|
339 |
-
directionalLight.position.set(
|
|
|
340 |
directionalLight.castShadow = true;
|
341 |
directionalLight.shadow.mapSize.width = 1024; // ๊ทธ๋ฆผ์ ํด์๋ ๋ฎ์ถค
|
342 |
directionalLight.shadow.mapSize.height = 1024;
|
@@ -370,8 +371,7 @@ class Game {
|
|
370 |
for (let i = 0; i < vertices.length; i += 3) {
|
371 |
const x = vertices[i] / 100;
|
372 |
const y = vertices[i + 1] / 100;
|
373 |
-
vertices[i + 2] =
|
374 |
-
(Math.sin(x + seed) * Math.cos(y + seed) * 1.0);
|
375 |
}
|
376 |
ground.geometry.attributes.position.needsUpdate = true;
|
377 |
ground.geometry.computeVertexNormals();
|
|
|
336 |
|
337 |
// ํ์๊ด ์ค์ - ๊ทธ๋ฆผ์ ํ์ง ๋ฎ์ถค
|
338 |
const directionalLight = new THREE.DirectionalLight(0xffffff, 1.2);
|
339 |
+
directionalLight.position.set(0, 300, 0); // ๋ ์์์ ๋น์ถ๋๋ก
|
340 |
+
directionalLight.intensity = 2.0; // ๊ฐ๋ ์ฆ๊ฐ
|
341 |
directionalLight.castShadow = true;
|
342 |
directionalLight.shadow.mapSize.width = 1024; // ๊ทธ๋ฆผ์ ํด์๋ ๋ฎ์ถค
|
343 |
directionalLight.shadow.mapSize.height = 1024;
|
|
|
371 |
for (let i = 0; i < vertices.length; i += 3) {
|
372 |
const x = vertices[i] / 100;
|
373 |
const y = vertices[i + 1] / 100;
|
374 |
+
vertices[i + 2] = (Math.sin(x + seed) * Math.cos(y + seed) * 0.3); // ๋์ด๋ฅผ 0.3๋ฐฐ๋ก ์ค์
|
|
|
375 |
}
|
376 |
ground.geometry.attributes.position.needsUpdate = true;
|
377 |
ground.geometry.computeVertexNormals();
|