Closed Vampurica closed 10 years ago
Getting the length of a side of the map is proving impossible for anything dynamic. Some maps are irregular shaped, and some maps don't have the grid coordinates starting at the top left.
The next idea is to get the distance from the center point to 0,0, and then using the Pythagorean Theorem on it to get a rough radius. Needs testing.
Errors are occuring. Getting missions spawning slightly in debug on Chernarus since the defined center point in the map config is farther left than the true center.
Need to revert this until we can find a better way to do this.
Need to hardcode this per map until a better way is found.
Mostly completed with 16506f7a5970c91b89c4043a4ddc297eeb6adf6c.
Going to close this unless we experience issues with it.
findSafePos is hard-coded to search 5500m to prevent Chernarus spawning missions in Debug.
It should instead be unique per-map.
Islands it would be from the center point to the farthest shoreline.
Inland maps, it must be from the center to the nearest map boundary.