Fixup migration to wesnoth.map module

This commit is contained in:
Gunter Labes 2021-03-24 08:53:12 +01:00 committed by GitHub
parent fd37a05ffe
commit e4a803360d
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -58,7 +58,7 @@ function set_terrain_impl(data)
local d = data[i]
local chance = d.per_thousand
local terrains = d.terrain
local layer = d.layer
local layer = d.layer or 'both'
local num_tiles = d.nlocs and math.min(#locs[i], d.nlocs) or #locs[i]
if d.exact then
num_tiles = math.ceil(num_tiles * chance / 1000)