1
0
mirror of https://github.com/Refactorio/RedMew.git synced 2024-12-12 10:04:40 +02:00
RedMew/map_gen/presets/factorio_logo2.lua

24 lines
638 B
Lua
Raw Normal View History

2018-01-29 19:43:10 +02:00
-- Size of the logo.
local scale_factor = 6
-- Distance between islands.
local island_distance_x = 256
local island_distance_y = 128
2018-05-08 22:23:07 +02:00
local b = require "map_gen.shared.builders"
2018-01-29 19:43:10 +02:00
local pic = require "map_gen.data.presets.factorio_logo2"
2018-05-08 22:23:07 +02:00
local pic = b.decompress(pic)
2018-01-29 19:43:10 +02:00
2018-05-08 22:23:07 +02:00
local shape = b.picture(pic)
shape = b.scale(shape, scale_factor, scale_factor)
2018-01-29 19:43:10 +02:00
local pattern_width = scale_factor * pic.width + island_distance_x
local pattern_height = scale_factor * pic.height + island_distance_y
2018-05-08 22:23:07 +02:00
shape = b.single_pattern(shape, pattern_width, pattern_height)
2018-01-29 19:43:10 +02:00
2018-05-08 22:23:07 +02:00
shape = b.change_tile(shape, false, "water")
2018-01-29 19:43:10 +02:00
2018-05-08 22:23:07 +02:00
shape = b.fish(shape, 0.008)
2018-01-29 19:43:10 +02:00
return shape