-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
(Aegis) turn more industries into custom layouts
- Loading branch information
Showing
2 changed files
with
69 additions
and
4 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,9 +1,36 @@ | ||
import grf | ||
from industry.lib.industry import AIndustry | ||
from industry.lib.industry import AIndustry, transcribe, symmetrize | ||
|
||
medium_set = [ | ||
( | ||
"eed", | ||
"abd", | ||
"cff", | ||
), | ||
( | ||
"cddc", | ||
"eabf", | ||
"eeff", | ||
), | ||
( | ||
"ddee", | ||
"cffe", | ||
"abec", | ||
), | ||
] | ||
|
||
tile_map = { | ||
"a": grf.OldIndustryTileID(0x21), # house (left) | ||
"b": grf.OldIndustryTileID(0x22), # house (right) | ||
"c": grf.OldIndustryTileID(0x23), # warehouse with straws | ||
"d": grf.OldIndustryTileID(0x24), # warehouse | ||
"e": grf.OldIndustryTileID(0x25), # silo | ||
"f": grf.OldIndustryTileID(0x26), # piggery | ||
} | ||
|
||
the_industry = AIndustry( | ||
name="Farm", | ||
substitute_type=0x09, | ||
layouts=[[{"xofs": i, "yofs": j, "gfx": grf.NewIndustryTileID(0x23)} for i in range(4) for j in range(4)]], | ||
# layouts=[[{"xofs": i, "yofs": j, "gfx": grf.NewIndustryTileID(0x23)} for i in range(4) for j in range(4)]], | ||
layouts=transcribe(symmetrize(medium_set), tile_map), | ||
) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,42 @@ | ||
from industry.lib.industry import AIndustry | ||
import grf | ||
from industry.lib.industry import AIndustry, transcribe, symmetrize | ||
|
||
|
||
the_industry = AIndustry(name="Oil Wells", substitute_type=0x0B) | ||
medium_set = [ | ||
( | ||
"x ", | ||
"x ", | ||
"xxx", | ||
), | ||
( | ||
"x ", | ||
"xx ", | ||
" xx", | ||
), | ||
( | ||
"x ", | ||
"xx ", | ||
" xx", | ||
), | ||
( | ||
" x ", | ||
"xxx ", | ||
" x", | ||
), | ||
( | ||
" x ", | ||
"x x ", | ||
"x x", | ||
), | ||
( | ||
"x ", | ||
"x ", | ||
"x xx", | ||
), | ||
] | ||
|
||
the_industry = AIndustry( | ||
name="Oil Wells", | ||
substitute_type=0x0B, | ||
layouts=transcribe(symmetrize(medium_set), {"x": grf.OldIndustryTileID(0x1D)}), | ||
) |