Skip to content

Commit

Permalink
Fix adding throw and changing the error that throws
Browse files Browse the repository at this point in the history
  • Loading branch information
NotZer0Two committed Aug 12, 2024
1 parent 4f79a6d commit 4ca5b35
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions EXILED/Exiled.API/Features/Map.cs
Original file line number Diff line number Diff line change
Expand Up @@ -425,13 +425,13 @@ public static void PlayGunSound(Vector3 position, ItemType firearmType, byte max
}

/// <summary>
/// Spawns a Mice inside the <see cref="RoomType.EzShelter"/>.
/// Spawns mice inside the <see cref="RoomType.EzShelter"/>.
/// </summary>
/// <param name="mice">The type of mice you want to spawn..</param>
public static void SpawnMice(byte mice = 1)
{
if (mice > SqueakSpawner.mice.Length)
new OverflowException($"The mice type are from 1 to {SqueakSpawner.mice.Length}");
throw new ArgumentOutOfRangeException($"Mouse type must be between 1 and {SqueakSpawner.mice.Length}.");

SqueakSpawner.NetworksyncSpawn = mice;
SqueakSpawner.SyncMouseSpawn(0, SqueakSpawner.NetworksyncSpawn);
Expand Down

0 comments on commit 4ca5b35

Please sign in to comment.