Page 1 of 1

Unhandled exception

Posted: Sat Feb 09, 2008 9:34 am
by Szilard
On the latest rev of a scenario I'm tinkering with, I get a .NET exception on the first AI turn:

System.NullReferenceException: Object reference not set to an instance of an object.
at WindowsApplication1.AIClass.IsAreaNeighbour(Int32 area1, Int32 area2)
at WindowsApplication1.AIClass.SetMatrixHQ(SimpleList UL, Int32 hqnr, Int32 onlysanr)
at WindowsApplication1.AIClass.ExecuteMovement(Int32 PlanNr, Int32 MovePhaseNr)
at WindowsApplication1.AIClass.ExecuteAI()
at WindowsApplication1.GameLoopMainWindowClass.handleTimer()
at WindowsApplication1.ScreenClass.HandleTimer()
at WindowsApplication1.Form1.Timer1_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)


RE: Unhandled exception

Posted: Sat Feb 09, 2008 6:03 pm
by Vic
hi there,
 
whats the AT version?
 
kind regards,
Vic

RE: Unhandled exception

Posted: Sat Feb 09, 2008 8:24 pm
by Szilard
ORIGINAL: Vic

hi there,

whats the AT version?

kind regards,
Vic

Hi Vic - It's 1.10L.

RE: Unhandled exception

Posted: Sun Feb 10, 2008 9:16 am
by Szilard
I think I've nailed this. I changed an island with a couple of cities to sea. I deleted the city locations, but I didn't delete the victory points for the hexes (now in the middle of the ocean). When I delete the VPs, the problem disappears.

So worth remembering - if you "Atlantis" a city, remove remember to remove any VPs associated with it.

Maybe deleting a location should automatically delete the VPs?



RE: Unhandled exception

Posted: Sun Feb 10, 2008 10:37 am
by Vic
yes that was it.
thanks for reporting that issue!
in the next version the AI will delete any VP accidently placed in the sea.
 
kind regards,
Vic