kwsch / pkNX

Pokémon (Nintendo Switch) ROM Editor & Randomizer
https://projectpokemon.org/home/forums/topic/48647-pknx-nintendo-switch-rom-editor-randomizer/
GNU General Public License v3.0
352 stars 108 forks source link

Any time i try to randomize trainers pokemon I get this error #45

Closed nightcorefeels1222 closed 4 years ago

nightcorefeels1222 commented 4 years ago

See the end of this message for details on invoking just-in-time (JIT) debugging instead of this dialog box.

** Exception Text ** System.IndexOutOfRangeException: Index was outside the bounds of the array. at pkNX.Randomization.MoveRandomizer.GetRandomSTABMove(Int32[] types) at pkNX.Randomization.MoveRandomizer.GetRandomMoves(Int32[] Types, Int32 movecount) at pkNX.Randomization.MoveRandomizer.GetRandomMoveset(Int32[] Types, Int32 movecount) at pkNX.Randomization.MoveRandomizer.GetRandomMoveset(Int32 index, Int32 movecount) at pkNX.Randomization.TrainerRandomizer.RandomizeEntryMoves(TrainerPoke pk) at pkNX.Randomization.TrainerRandomizer.UpdatePKMFromSettings(TrainerPoke pk) at pkNX.Randomization.TrainerRandomizer.Execute() at pkNX.WinForms.BTTE.B_Randomize_Click(Object sender, EventArgs e) in C:\Users\Lewis\Source\Repos\pkNX24\pkNX.WinForms\Subforms\BTTE.cs:line 558 at System.Windows.Forms.Control.OnClick(EventArgs e) at System.Windows.Forms.Button.OnClick(EventArgs e) at System.Windows.Forms.Button.OnMouseUp(MouseEventArgs mevent) at System.Windows.Forms.Control.WmMouseUp(Message& m, MouseButtons button, Int32 clicks) at System.Windows.Forms.Control.WndProc(Message& m) at System.Windows.Forms.ButtonBase.WndProc(Message& m) at System.Windows.Forms.Button.WndProc(Message& m) at System.Windows.Forms.NativeWindow.Callback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)

** Loaded Assemblies ** mscorlib Assembly Version: 4.0.0.0 Win32 Version: 4.8.4075.0 built by: NET48REL1LAST CodeBase: file:///C:/Windows/Microsoft.NET/Framework64/v4.0.30319/mscorlib.dll

pkNX Assembly Version: 1.0.0.0 Win32 Version: 1.0.0.0 CodeBase: file:///C:/Users/Lewis/source/repos/pkNX24/pkNX.WinForms/bin/Debug/pkNX.exe

System.Windows.Forms Assembly Version: 4.0.0.0 Win32 Version: 4.8.4042.0 built by: NET48REL1LAST_C CodeBase: file:///C:/WINDOWS/Microsoft.Net/assembly/GAC_MSIL/System.Windows.Forms/v4.0_4.0.0.0__b77a5c561934e089/System.Windows.Forms.dll

System Assembly Version: 4.0.0.0 Win32 Version: 4.8.4001.0 built by: NET48REL1LAST_C CodeBase: file:///C:/WINDOWS/Microsoft.Net/assembly/GAC_MSIL/System/v4.0_4.0.0.0__b77a5c561934e089/System.dll

System.Drawing Assembly Version: 4.0.0.0 Win32 Version: 4.8.3761.0 built by: NET48REL1 CodeBase: file:///C:/WINDOWS/Microsoft.Net/assembly/GAC_MSIL/System.Drawing/v4.0_4.0.0.0__b03f5f7f11d50a3a/System.Drawing.dll

System.Configuration Assembly Version: 4.0.0.0 Win32 Version: 4.8.3761.0 built by: NET48REL1 CodeBase: file:///C:/WINDOWS/Microsoft.Net/assembly/GAC_MSIL/System.Configuration/v4.0_4.0.0.0__b03f5f7f11d50a3a/System.Configuration.dll

System.Core Assembly Version: 4.0.0.0 Win32 Version: 4.8.4075.0 built by: NET48REL1LAST CodeBase: file:///C:/WINDOWS/Microsoft.Net/assembly/GAC_MSIL/System.Core/v4.0_4.0.0.0__b77a5c561934e089/System.Core.dll

System.Xml Assembly Version: 4.0.0.0 Win32 Version: 4.8.3761.0 built by: NET48REL1 CodeBase: file:///C:/WINDOWS/Microsoft.Net/assembly/GAC_MSIL/System.Xml/v4.0_4.0.0.0__b77a5c561934e089/System.Xml.dll

pkNX.Structures Assembly Version: 1.0.0.0 Win32 Version: 1.0.0.0 CodeBase: file:///C:/Users/Lewis/source/repos/pkNX24/pkNX.WinForms/bin/Debug/pkNX.exe

pkNX.Game Assembly Version: 1.0.0.0 Win32 Version: 1.0.0.0 CodeBase: file:///C:/Users/Lewis/source/repos/pkNX24/pkNX.WinForms/bin/Debug/pkNX.exe

pkNX.Containers Assembly Version: 1.0.0.0 Win32 Version: 1.0.0.0 CodeBase: file:///C:/Users/Lewis/source/repos/pkNX24/pkNX.WinForms/bin/Debug/pkNX.exe

pkNX.Sprites Assembly Version: 1.0.0.0 Win32 Version: 1.0.0.0 CodeBase: file:///C:/Users/Lewis/source/repos/pkNX24/pkNX.WinForms/bin/Debug/pkNX.exe

pkNX.Randomization Assembly Version: 1.0.0.0 Win32 Version: 1.0.0.0 CodeBase: file:///C:/Users/Lewis/source/repos/pkNX24/pkNX.WinForms/bin/Debug/pkNX.exe

Microsoft.GeneratedCode Assembly Version: 1.0.0.0 Win32 Version: 4.8.3761.0 built by: NET48REL1 CodeBase: file:///C:/WINDOWS/Microsoft.Net/assembly/GAC_MSIL/System.Xml/v4.0_4.0.0.0__b77a5c561934e089/System.Xml.dll

LZ4 Assembly Version: 1.0.15.93 Win32 Version: 1.0.0.0 CodeBase: file:///C:/Users/Lewis/source/repos/pkNX24/pkNX.WinForms/bin/Debug/pkNX.exe

LZ4mm Assembly Version: 1.0.15.93 Win32 Version: 1.0.15.93 CodeBase: file:///C:/Users/Lewis/AppData/Local/Temp/f82a68ada1d833f8838dd859bcb27a61/44b09ced47d1340e4b5af5cc6f2fc8b2.dll

LZ4cc Assembly Version: 1.0.15.93 Win32 Version: 1.0.15.93 CodeBase: file:///C:/Users/Lewis/AppData/Local/Temp/f82a68ada1d833f8838dd859bcb27a61/bed5714f0a00711677483c138938e914.dll

LZ4pn Assembly Version: 1.0.15.93 Win32 Version: 1.0.15.93 CodeBase: file:///C:/Users/Lewis/AppData/Local/Temp/f82a68ada1d833f8838dd859bcb27a61/50495300240756128a79c0c0850f98e5.dll

Newtonsoft.Json Assembly Version: 12.0.0.0 Win32 Version: 1.0.0.0 CodeBase: file:///C:/Users/Lewis/source/repos/pkNX24/pkNX.WinForms/bin/Debug/pkNX.exe

System.Numerics Assembly Version: 4.0.0.0 Win32 Version: 4.8.3761.0 built by: NET48REL1 CodeBase: file:///C:/WINDOWS/Microsoft.Net/assembly/GAC_MSIL/System.Numerics/v4.0_4.0.0.0__b77a5c561934e089/System.Numerics.dll

System.Runtime.Serialization Assembly Version: 4.0.0.0 Win32 Version: 4.8.3928.0 built by: NET48REL1 CodeBase: file:///C:/WINDOWS/Microsoft.Net/assembly/GAC_MSIL/System.Runtime.Serialization/v4.0_4.0.0.0__b77a5c561934e089/System.Runtime.Serialization.dll

System.Data Assembly Version: 4.0.0.0 Win32 Version: 4.8.3761.0 built by: NET48REL1 CodeBase: file:///C:/WINDOWS/Microsoft.Net/assembly/GAC_64/System.Data/v4.0_4.0.0.0__b77a5c561934e089/System.Data.dll

Accessibility Assembly Version: 4.0.0.0 Win32 Version: 4.8.3761.0 built by: NET48REL1 CodeBase: file:///C:/WINDOWS/Microsoft.Net/assembly/GAC_MSIL/Accessibility/v4.0_4.0.0.0__b03f5f7f11d50a3a/Accessibility.dll

** JIT Debugging ** To enable just-in-time (JIT) debugging, the .config file for this application or computer (machine.config) must have the jitDebugging value set in the system.windows.forms section. The application must also be compiled with debugging enabled.

For example:

When JIT debugging is enabled, any unhandled exception will be sent to the JIT debugger registered on the computer rather than be handled by this dialog box.

kwsch commented 4 years ago

Duplicate with https://github.com/kwsch/pkNX/issues/23