Ongoing spell effects crashing combat?

Any bugs found while playing or testing the engines for both PC and Android

Ongoing spell effects crashing combat?

Postby zach_holbrook » Thu May 04, 2017 4:09 pm

I've been experimenting with some new spells, and I keep running into crash difficulties when trying them out in combat. I'm not sure, though, what the culprit is -- no spell or effect seems to trigger the crash consistently, at least as far as I can tell. The error message for my most recent crash was this, and from my cursory reading of other crash messages, it's usually along the same lines.


System.InvalidOperationException: Collection was modified; enumeration operation may not execute.
at System.ThrowHelper.ThrowInvalidOperationException(ExceptionResource resource)
at System.Collections.Generic.List`1.Enumerator.MoveNextRare()
at IceBlink2.ScreenCombat.applyEffectsCombat(Creature crtr)
at IceBlink2.ScreenCombat.turnController()
at IceBlink2.ScreenCombat.endPcTurn(Boolean endStealthMode)
at IceBlink2.ScreenCombat.Update(Int32 elapsed)
at IceBlink2.GameView.Update(Int32 elapsed)
at IceBlink2.GameView.gameTimer_Tick(Object sender, EventArgs e)
at System.Windows.Forms.Timer.OnTick(EventArgs e)
at System.Windows.Forms.Timer.TimerNativeWindow.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.6.1637.0 built by: NETFXREL3STAGE
CodeBase: file:///C:/Windows/Microsoft.NET/Framework64/v4.0.30319/mscorlib.dll
----------------------------------------
IceBlink2
Assembly Version: 1.0.0.0
Win32 Version: 1.0.0.0
CodeBase: file:///C:/Users/zholbrook/OneDrive/IB2_Beta_v38/IB2_Beta_v38/IceBlink2.exe
----------------------------------------
System.Windows.Forms
Assembly Version: 4.0.0.0
Win32 Version: 4.6.1586.0 built by: NETFXREL2
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.6.1637.0 built by: NETFXREL3STAGE
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.6.1586.0 built by: NETFXREL2
CodeBase: file:///C:/WINDOWS/Microsoft.Net/assembly/GAC_MSIL/System.Drawing/v4.0_4.0.0.0__b03f5f7f11d50a3a/System.Drawing.dll
----------------------------------------
SharpDX
Assembly Version: 2.6.3.0
Win32 Version: 2.6.3
CodeBase: file:///C:/Users/zholbrook/OneDrive/IB2_Beta_v38/IB2_Beta_v38/SharpDX.DLL
----------------------------------------
SharpDX.Direct2D1
Assembly Version: 2.6.3.0
Win32 Version: 2.6.3
CodeBase: file:///C:/Users/zholbrook/OneDrive/IB2_Beta_v38/IB2_Beta_v38/SharpDX.Direct2D1.DLL
----------------------------------------
SharpDX.DXGI
Assembly Version: 2.6.3.0
Win32 Version: 2.6.3
CodeBase: file:///C:/Users/zholbrook/OneDrive/IB2_Beta_v38/IB2_Beta_v38/SharpDX.DXGI.DLL
----------------------------------------
SharpDX.Direct3D11
Assembly Version: 2.6.3.0
Win32 Version: 2.6.3
CodeBase: file:///C:/Users/zholbrook/OneDrive/IB2_Beta_v38/IB2_Beta_v38/SharpDX.Direct3D11.DLL
----------------------------------------
System.Core
Assembly Version: 4.0.0.0
Win32 Version: 4.6.1638.0 built by: NETFXREL3STAGE
CodeBase: file:///C:/WINDOWS/Microsoft.Net/assembly/GAC_MSIL/System.Core/v4.0_4.0.0.0__b77a5c561934e089/System.Core.dll
----------------------------------------
Newtonsoft.Json
Assembly Version: 7.0.0.0
Win32 Version: 7.0.1.18622
CodeBase: file:///C:/Users/zholbrook/OneDrive/IB2_Beta_v38/IB2_Beta_v38/Newtonsoft.Json.DLL
----------------------------------------
System.Numerics
Assembly Version: 4.0.0.0
Win32 Version: 4.6.1586.0 built by: NETFXREL2
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.6.1637.0 built by: NETFXREL3STAGE
CodeBase: file:///C:/WINDOWS/Microsoft.Net/assembly/GAC_MSIL/System.Runtime.Serialization/v4.0_4.0.0.0__b77a5c561934e089/System.Runtime.Serialization.dll
----------------------------------------
System.Xml.Linq
Assembly Version: 4.0.0.0
Win32 Version: 4.6.1586.0 built by: NETFXREL2
CodeBase: file:///C:/WINDOWS/Microsoft.Net/assembly/GAC_MSIL/System.Xml.Linq/v4.0_4.0.0.0__b77a5c561934e089/System.Xml.Linq.dll
----------------------------------------
System.Xml
Assembly Version: 4.0.0.0
Win32 Version: 4.6.1586.0 built by: NETFXREL2
CodeBase: file:///C:/WINDOWS/Microsoft.Net/assembly/GAC_MSIL/System.Xml/v4.0_4.0.0.0__b77a5c561934e089/System.Xml.dll
----------------------------------------
System.Data
Assembly Version: 4.0.0.0
Win32 Version: 4.6.1636.0 built by: NETFXREL3STAGE
CodeBase: file:///C:/WINDOWS/Microsoft.Net/assembly/GAC_64/System.Data/v4.0_4.0.0.0__b77a5c561934e089/System.Data.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:

<configuration>
<system.windows.forms jitDebugging="true" />
</configuration>

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.
zach_holbrook
 
Posts: 131
Joined: Mon Dec 26, 2016 5:52 am

Re: Ongoing spell effects crashing combat?

Postby youngneil1 » Thu May 04, 2017 4:42 pm

Thank you, Zach, and my apologies for the trouble. I have an idea what might cause this (badly constructed loop of mine), uploading a fix attempt now...
User avatar
youngneil1
Backer
Backer
 
Posts: 4570
Joined: Sat Dec 08, 2012 7:51 am

Re: Ongoing spell effects crashing combat?

Postby youngneil1 » Thu May 04, 2017 4:52 pm

And it's up, see main thread with the IB2 beta versions.
User avatar
youngneil1
Backer
Backer
 
Posts: 4570
Joined: Sat Dec 08, 2012 7:51 am

Re: Ongoing spell effects crashing combat?

Postby zach_holbrook » Thu May 04, 2017 4:52 pm

Amazing! Thank you so much! I'll test it out and let you know how it goes.
zach_holbrook
 
Posts: 131
Joined: Mon Dec 26, 2016 5:52 am

Re: Ongoing spell effects crashing combat?

Postby zach_holbrook » Thu May 04, 2017 5:24 pm

Alas, I'm still getting a crash. The error message is similar to the other I posted but not identical:

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

************** Exception Text **************
System.InvalidOperationException: Collection was modified; enumeration operation may not execute.
at System.ThrowHelper.ThrowInvalidOperationException(ExceptionResource resource)
at System.Collections.Generic.List`1.Enumerator.MoveNextRare()
at IceBlink2.ScreenCombat.applyEffectsCombat(Player pc)
at IceBlink2.ScreenCombat.turnController()
at IceBlink2.ScreenCombat.endPcTurn(Boolean endStealthMode)
at IceBlink2.ScreenCombat.Update(Int32 elapsed)
at IceBlink2.GameView.Update(Int32 elapsed)
at IceBlink2.GameView.gameTimer_Tick(Object sender, EventArgs e)
at System.Windows.Forms.Timer.OnTick(EventArgs e)
at System.Windows.Forms.Timer.TimerNativeWindow.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.6.1637.0 built by: NETFXREL3STAGE
CodeBase: file:///C:/Windows/Microsoft.NET/Framework64/v4.0.30319/mscorlib.dll
----------------------------------------
IceBlink2
Assembly Version: 1.0.0.0
Win32 Version: 1.0.0.0
CodeBase: file:///C:/Users/zholbrook/OneDrive/IB2_Beta_v40/IB2_Beta_v40/IceBlink2.exe
----------------------------------------
System.Windows.Forms
Assembly Version: 4.0.0.0
Win32 Version: 4.6.1586.0 built by: NETFXREL2
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.6.1637.0 built by: NETFXREL3STAGE
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.6.1586.0 built by: NETFXREL2
CodeBase: file:///C:/WINDOWS/Microsoft.Net/assembly/GAC_MSIL/System.Drawing/v4.0_4.0.0.0__b03f5f7f11d50a3a/System.Drawing.dll
----------------------------------------
SharpDX
Assembly Version: 2.6.3.0
Win32 Version: 2.6.3
CodeBase: file:///C:/Users/zholbrook/OneDrive/IB2_Beta_v40/IB2_Beta_v40/SharpDX.DLL
----------------------------------------
SharpDX.Direct2D1
Assembly Version: 2.6.3.0
Win32 Version: 2.6.3
CodeBase: file:///C:/Users/zholbrook/OneDrive/IB2_Beta_v40/IB2_Beta_v40/SharpDX.Direct2D1.DLL
----------------------------------------
SharpDX.DXGI
Assembly Version: 2.6.3.0
Win32 Version: 2.6.3
CodeBase: file:///C:/Users/zholbrook/OneDrive/IB2_Beta_v40/IB2_Beta_v40/SharpDX.DXGI.DLL
----------------------------------------
SharpDX.Direct3D11
Assembly Version: 2.6.3.0
Win32 Version: 2.6.3
CodeBase: file:///C:/Users/zholbrook/OneDrive/IB2_Beta_v40/IB2_Beta_v40/SharpDX.Direct3D11.DLL
----------------------------------------
System.Core
Assembly Version: 4.0.0.0
Win32 Version: 4.6.1638.0 built by: NETFXREL3STAGE
CodeBase: file:///C:/WINDOWS/Microsoft.Net/assembly/GAC_MSIL/System.Core/v4.0_4.0.0.0__b77a5c561934e089/System.Core.dll
----------------------------------------
Newtonsoft.Json
Assembly Version: 7.0.0.0
Win32 Version: 7.0.1.18622
CodeBase: file:///C:/Users/zholbrook/OneDrive/IB2_Beta_v40/IB2_Beta_v40/Newtonsoft.Json.DLL
----------------------------------------
System.Numerics
Assembly Version: 4.0.0.0
Win32 Version: 4.6.1586.0 built by: NETFXREL2
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.6.1637.0 built by: NETFXREL3STAGE
CodeBase: file:///C:/WINDOWS/Microsoft.Net/assembly/GAC_MSIL/System.Runtime.Serialization/v4.0_4.0.0.0__b77a5c561934e089/System.Runtime.Serialization.dll
----------------------------------------
System.Xml.Linq
Assembly Version: 4.0.0.0
Win32 Version: 4.6.1586.0 built by: NETFXREL2
CodeBase: file:///C:/WINDOWS/Microsoft.Net/assembly/GAC_MSIL/System.Xml.Linq/v4.0_4.0.0.0__b77a5c561934e089/System.Xml.Linq.dll
----------------------------------------
System.Xml
Assembly Version: 4.0.0.0
Win32 Version: 4.6.1586.0 built by: NETFXREL2
CodeBase: file:///C:/WINDOWS/Microsoft.Net/assembly/GAC_MSIL/System.Xml/v4.0_4.0.0.0__b77a5c561934e089/System.Xml.dll
----------------------------------------
System.Data
Assembly Version: 4.0.0.0
Win32 Version: 4.6.1636.0 built by: NETFXREL3STAGE
CodeBase: file:///C:/WINDOWS/Microsoft.Net/assembly/GAC_64/System.Data/v4.0_4.0.0.0__b77a5c561934e089/System.Data.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:

<configuration>
<system.windows.forms jitDebugging="true" />
</configuration>

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.
zach_holbrook
 
Posts: 131
Joined: Mon Dec 26, 2016 5:52 am

Re: Ongoing spell effects crashing combat?

Postby youngneil1 » Thu May 04, 2017 5:47 pm

Oh dear, sorry again. This time its effects for player characters. I thozght to havecfixed this, too, though - either I missed something or it wasnt that loop (alone). Will look thoroughly later...
User avatar
youngneil1
Backer
Backer
 
Posts: 4570
Joined: Sat Dec 08, 2012 7:51 am

Re: Ongoing spell effects crashing combat?

Postby zach_holbrook » Thu May 04, 2017 6:55 pm

No worries! Luckily, there's tons of stuff beside combat I need to work on... :) Thanks again for all your hard work.

The crash bug also pops up in this way:

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

************** Exception Text **************
System.InvalidOperationException: Collection was modified; enumeration operation may not execute.
at System.ThrowHelper.ThrowInvalidOperationException(ExceptionResource resource)
at System.Collections.Generic.List`1.Enumerator.MoveNextRare()
at IceBlink2.ScreenCombat.applyEffectsCombat(Creature crtr)
at IceBlink2.ScreenCombat.turnController()
at IceBlink2.ScreenCombat.endCreatureTurn(Creature crt)
at IceBlink2.ScreenCombat.turnController()
at IceBlink2.ScreenCombat.endCreatureTurn(Creature crt)
at IceBlink2.ScreenCombat.Update(Int32 elapsed)
at IceBlink2.GameView.Update(Int32 elapsed)
at IceBlink2.GameView.gameTimer_Tick(Object sender, EventArgs e)
at System.Windows.Forms.Timer.OnTick(EventArgs e)
at System.Windows.Forms.Timer.TimerNativeWindow.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.6.1637.0 built by: NETFXREL3STAGE
CodeBase: file:///C:/Windows/Microsoft.NET/Framework64/v4.0.30319/mscorlib.dll
----------------------------------------
IceBlink2
Assembly Version: 1.0.0.0
Win32 Version: 1.0.0.0
CodeBase: file:///C:/Users/zholbrook/OneDrive/IB2_Beta_v40/IB2_Beta_v40/IceBlink2.exe
----------------------------------------
System.Windows.Forms
Assembly Version: 4.0.0.0
Win32 Version: 4.6.1586.0 built by: NETFXREL2
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.6.1637.0 built by: NETFXREL3STAGE
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.6.1586.0 built by: NETFXREL2
CodeBase: file:///C:/WINDOWS/Microsoft.Net/assembly/GAC_MSIL/System.Drawing/v4.0_4.0.0.0__b03f5f7f11d50a3a/System.Drawing.dll
----------------------------------------
SharpDX
Assembly Version: 2.6.3.0
Win32 Version: 2.6.3
CodeBase: file:///C:/Users/zholbrook/OneDrive/IB2_Beta_v40/IB2_Beta_v40/SharpDX.DLL
----------------------------------------
SharpDX.Direct2D1
Assembly Version: 2.6.3.0
Win32 Version: 2.6.3
CodeBase: file:///C:/Users/zholbrook/OneDrive/IB2_Beta_v40/IB2_Beta_v40/SharpDX.Direct2D1.DLL
----------------------------------------
SharpDX.DXGI
Assembly Version: 2.6.3.0
Win32 Version: 2.6.3
CodeBase: file:///C:/Users/zholbrook/OneDrive/IB2_Beta_v40/IB2_Beta_v40/SharpDX.DXGI.DLL
----------------------------------------
SharpDX.Direct3D11
Assembly Version: 2.6.3.0
Win32 Version: 2.6.3
CodeBase: file:///C:/Users/zholbrook/OneDrive/IB2_Beta_v40/IB2_Beta_v40/SharpDX.Direct3D11.DLL
----------------------------------------
System.Core
Assembly Version: 4.0.0.0
Win32 Version: 4.6.1638.0 built by: NETFXREL3STAGE
CodeBase: file:///C:/WINDOWS/Microsoft.Net/assembly/GAC_MSIL/System.Core/v4.0_4.0.0.0__b77a5c561934e089/System.Core.dll
----------------------------------------
Newtonsoft.Json
Assembly Version: 7.0.0.0
Win32 Version: 7.0.1.18622
CodeBase: file:///C:/Users/zholbrook/OneDrive/IB2_Beta_v40/IB2_Beta_v40/Newtonsoft.Json.DLL
----------------------------------------
System.Numerics
Assembly Version: 4.0.0.0
Win32 Version: 4.6.1586.0 built by: NETFXREL2
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.6.1637.0 built by: NETFXREL3STAGE
CodeBase: file:///C:/WINDOWS/Microsoft.Net/assembly/GAC_MSIL/System.Runtime.Serialization/v4.0_4.0.0.0__b77a5c561934e089/System.Runtime.Serialization.dll
----------------------------------------
System.Xml.Linq
Assembly Version: 4.0.0.0
Win32 Version: 4.6.1586.0 built by: NETFXREL2
CodeBase: file:///C:/WINDOWS/Microsoft.Net/assembly/GAC_MSIL/System.Xml.Linq/v4.0_4.0.0.0__b77a5c561934e089/System.Xml.Linq.dll
----------------------------------------
System.Xml
Assembly Version: 4.0.0.0
Win32 Version: 4.6.1586.0 built by: NETFXREL2
CodeBase: file:///C:/WINDOWS/Microsoft.Net/assembly/GAC_MSIL/System.Xml/v4.0_4.0.0.0__b77a5c561934e089/System.Xml.dll
----------------------------------------
System.Data
Assembly Version: 4.0.0.0
Win32 Version: 4.6.1636.0 built by: NETFXREL3STAGE
CodeBase: file:///C:/WINDOWS/Microsoft.Net/assembly/GAC_64/System.Data/v4.0_4.0.0.0__b77a5c561934e089/System.Data.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:

<configuration>
<system.windows.forms jitDebugging="true" />
</configuration>

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.


zach_holbrook
 
Posts: 131
Joined: Mon Dec 26, 2016 5:52 am

Re: Ongoing spell effects crashing combat?

Postby youngneil1 » Thu May 04, 2017 8:19 pm

Next attempt up in main thread - keep fingers crossed :) . There was another faulty loop in the same method, let's hope this was the reason. If not... we will find it anyway :) .
User avatar
youngneil1
Backer
Backer
 
Posts: 4570
Joined: Sat Dec 08, 2012 7:51 am

Re: Ongoing spell effects crashing combat?

Postby zach_holbrook » Thu May 04, 2017 8:57 pm

Great! I'll try it out in a bit and let you know how it goes. Thanks again.
zach_holbrook
 
Posts: 131
Joined: Mon Dec 26, 2016 5:52 am

Re: Ongoing spell effects crashing combat?

Postby zach_holbrook » Fri May 05, 2017 12:30 pm

I've run through five or so combats using lots of effects, and I've had no trouble. It seems like the fix worked. Thanks for all your hard work!
zach_holbrook
 
Posts: 131
Joined: Mon Dec 26, 2016 5:52 am

Next

Return to Engine Bugs

Who is online

Users browsing this forum: No registered users and 2 guests

cron