From f730aa709a3021910fdb68a8dd8be61dcb8a36da Mon Sep 17 00:00:00 2001 From: LeeJaeHyun Date: Thu, 12 Sep 2024 15:36:18 +0900 Subject: [PATCH] . --- Assets/02_Scripts/WeaponController.cs | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/Assets/02_Scripts/WeaponController.cs b/Assets/02_Scripts/WeaponController.cs index f5e8f6b..6c0e6aa 100644 --- a/Assets/02_Scripts/WeaponController.cs +++ b/Assets/02_Scripts/WeaponController.cs @@ -55,7 +55,13 @@ public class WeaponController : MonoBehaviour Random.Range(0, 10) : 0, 1, 2, ..., 9 Random.Range(0.0f, 10.0f) : 0.0f ~ 10.0f */ - Vector2 offset = new Vector2(Random.Range(0, 2), Random.Range(0, 2)) + Vector2 offset = new Vector2(Random.Range(0, 2), Random.Range(0, 2)) * 0.5f; + // 텍스처의 오프셋 변경 + muzzleFlash.material.mainTextureOffset = offset; + + // 스케일 변경 + Vector3 scale = Vector3.one * Random.Range(1.0f, 3.0f); + muzzleFlash.transform.localScale = scale; // Waiting... yield return new WaitForSeconds(0.2f);