From 719ecf18aad97148015f52b7b95d7236d5f69270 Mon Sep 17 00:00:00 2001 From: ProtoSharkk Date: Sun, 27 Oct 2024 19:16:35 -0700 Subject: [PATCH] Ratbots now spawn around player instead of around (0, 0) --- Assets/Scripts C#/GameState.cs | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/Assets/Scripts C#/GameState.cs b/Assets/Scripts C#/GameState.cs index d994bdc..6f6b41e 100644 --- a/Assets/Scripts C#/GameState.cs +++ b/Assets/Scripts C#/GameState.cs @@ -52,7 +52,11 @@ public class GameState : MonoBehaviour for (uint _ = 0; _ <= wave; _++) { GameObject newRatbot = Instantiate( SpawnRatbot(), - Random.insideUnitCircle.normalized*20, + Random.insideUnitCircle.normalized*20 + + new Vector2 ( + playerPosition.x, + playerPosition.y + ), Quaternion.identity ); newRatbot.GetComponent().damageStrength