Separate names with a comma.
Discussion in 'Support Center' started by Travis, Feb 15, 2015.
Thanks! I think I can track this down. Did you colonize a planet just before this error?
I colonized two, aye.
Ok. I will fix what I believe to be the issue and push a .411a out tonight. Thanks!
Well, I could not reproduce this issue so far. It has something to do with when a planet needs resources (food or materials) it makes a check in this procedure. The problem is that this is a terribly written routine with a bunch of if then loops basically checking for relief from a system hub, then a sector hub, then the empire hub. The tortorous part is checking that these objects exist - there is not always a system capital or even a sector capital, and in VB you can't declare a conditional as 'If .... and If curPlanet.SystemCapital IsNot Nothing Then... no, you have to test the IsNot conditional first, and then write an additional conditional if the object exists, and then another loop if the object does not exist, to look for the next eligible object (a system or empire capital). I think I have the issue found but I will need to do what I've been putting off for a while and rewrite this plate of spaghetti, cooked much earlier in my programming development.
TMI answer for ya?
I understand the thought process behind programming. I get it. Should be safe to start up a new save, then?
Yes, but you may get the same error depending on the resource situation.
OK. Not only do I think I fixed it, I also knocked out almost 500 lines(!) of code doing so! Yay for experience! Anyway, I'll test it tomorrow and if it works I'll send it as .411b.