The new code stream is below. It doesn't place anything yet. All it does is draw REALLY COOL stuff on the whiteboard. To see how cool it is, start a luabot, make yourself one of the old world 4 and make the other 3 enemies.

Everything it plots on the whiteboard is a viable ground installation that is:
1. not ocean
2. on my own territory
3. is > 1.83 from a city
4. is > 20.1 away from enemy territory

...and it works pretty fast too!! all extra functions have been removed for brevity.

-- is it too close to one of our cities? for j, city in ipairs(myCities) do if GetRealDistance(x +dx, y+dy, myCities[j]:GetLongitude(), myCities[j]:GetLatitude() ) < valtoocloseCity then drawflag = false end end

-- is it too close to one of our enemies? DrawRadiatingSpokes(x +dx, y+dy,20.1)

end

-- if it isn't in the ocean, on someone else's land, too close to one of our cities -- or too close to enemy territory, then it's a good spot!!! if drawflag == true and drawflag1 == true then DrawWhiteboardCross(x + dx, y + dy, 0.2) end

I didn't let the Europe simulator run long enough. I am thinking that if the Bot is Europe, some "special case" heuristics will need to happen.... with both russia and africa as enemies, there's now way to place 6 silos and 4 airbases without <something> showing up.

If you ignore the Europe/Africa/Russia screenshot, the rest of it is exactly what I want to do for placing the first silo....
then clear the board and rerun and find good spots for more silos, airbases, radar.