]> git.pond.sub.org Git - empserver/commit - tests/fairland/plain.xdump
fairland: Prefer placing islands away from the edge of the sphere
authorMarkus Armbruster <armbru@pond.sub.org>
Mon, 14 Sep 2020 05:27:45 +0000 (07:27 +0200)
committerMarkus Armbruster <armbru@pond.sub.org>
Tue, 19 Jan 2021 07:27:34 +0000 (08:27 +0100)
commitfd164c5860ec0d08209724c5c4b531056a65592a
tree7ccd73498ffb0ccf3b34ca5bb3755b2f3d949ee8
parent56c014806ee7fe35908e5b09e97f31ce08245d21
fairland: Prefer placing islands away from the edge of the sphere

When an island gets placed too close to the edge of the sphere of
influence, its side facing the edge will likely be formed by the edge.
Looks unnatural, and can give a clue on the location of the other
continent.

Make place_island() prefer sectors away from the edge: instead of
picking one of the admissible sectors with equal probability, reduce
the probability as we get closer to the edge.

Signed-off-by: Markus Armbruster <armbru@pond.sub.org>
src/util/fairland.c
tests/fairland/no-spike.out
tests/fairland/no-spike.xdump
tests/fairland/plain.out
tests/fairland/plain.xdump
tests/fairland/spike.out
tests/fairland/spike.xdump