From 529e95ad2e425a52fa0f51773da5e50f17f6e78d Mon Sep 17 00:00:00 2001 From: JappaWakka Date: Sun, 15 Jan 2023 20:01:59 +0100 Subject: [PATCH] Fixed Fishing Rod encounter crash --- P3D/Pokemon/Wild/Spawner.vb | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/P3D/Pokemon/Wild/Spawner.vb b/P3D/Pokemon/Wild/Spawner.vb index f83a0f10a..f760811d6 100644 --- a/P3D/Pokemon/Wild/Spawner.vb +++ b/P3D/Pokemon/Wild/Spawner.vb @@ -145,8 +145,12 @@ Public Class Spawner If r < x Then Dim levelCap() As String = LevelCaps(i).Split(CChar(",")) Dim minLevel As Integer = CInt(levelCap(0)) - Dim maxLevel As Integer = CInt(levelCap(1)) - + Dim maxLevel As Integer + If levelCap.Count > 1 Then + maxLevel = CInt(levelCap(1)) + Else + maxLevel = minLevel + End If If maxLevel < minLevel Then maxLevel = minLevel End If