- ensure atomic re-writing of savefile
-- FOV algorithm is buggy in large maps
-
CLIENT:
- enable toggling of window borders
-/* Number of degrees a circle is divided into. */
-#define CIRCLE 36000000
+/* Number of degrees a circle is divided into. The greater it is, the greater
+ * the angle precision. But make it one whole zero larger and bizarre FOV bugs
+ * appear on large maps, probably due to value overflows.
+ */
+#define CIRCLE 3600000
memset(visible_map, ' ', map_size);
if (player->fov_map) /* May fail if player thing was created / positioned */
{ /* by god command after turning off FOV building. */
- uint16_t pos_i;
+ uint32_t pos_i;
for (pos_i = 0; pos_i < map_size; pos_i++)
{
if (player->fov_map[pos_i] & VISIBLE)