From e74332781db0881ecf51b014cb3807f545121b44 Mon Sep 17 00:00:00 2001 From: Mark Joshwel Date: Sat, 10 Aug 2024 13:12:09 +0800 Subject: [PATCH] Revert "game(ai): use System.Random directly in ChangeState" This reverts commit 2c6ee68988f38502ba2db87afc38aa95e5355b9b. --- RunningLateGame/Assets/Scripts/AI.cs | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/RunningLateGame/Assets/Scripts/AI.cs b/RunningLateGame/Assets/Scripts/AI.cs index 895ab29..7fc0f8f 100644 --- a/RunningLateGame/Assets/Scripts/AI.cs +++ b/RunningLateGame/Assets/Scripts/AI.cs @@ -7,6 +7,7 @@ using System.Collections; using UnityEngine; using UnityEngine.AI; +using Random = System.Random; /// /// TODO @@ -98,7 +99,7 @@ private void ChangeState() /// private void SearchWalkPoint() { - var rand = new System.Random(); + var rand = new Random(); float randomX = rand.Next(-movingRange * 100, movingRange * 100); float randomZ = rand.Next(-movingRange * 100, movingRange * 100); destinationCoord = new Vector3(