Skip to content

Commit dd51eac

Browse files
committed
Fix IM montage creating palettes with wrong colors
1 parent d064588 commit dd51eac

34 files changed

Lines changed: 11 additions & 11 deletions

rct-graphics-helper/magick_command.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,9 +12,9 @@ def __init__(self, input):
1212
# Replaces the command with a montage command for generating spritesheets
1313
def as_montage(self, inputs):
1414
self.use_repage = False
15-
self.full_command = "montage \"" + \
15+
self.full_command = "\"" + \
1616
"\" \"".join(inputs) + \
17-
"\" -tile x1 -geometry +0+0 -background none"
17+
"\" +append -background none"
1818

1919
# Writes the current result to the MPR for reuse in the same command. The cached result can be referenced using mpr:{id}
2020
def write_to_cache(self, id, delete_previous=False, next_file=""):

rct-graphics-helper/models/palette.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -237,7 +237,7 @@ def generate_output(self, renderer, output_path):
237237
cmd.as_montage(color_paths)
238238

239239
subprocess.check_output(cmd.get_command_string(
240-
renderer.magick_path, "PNG8:" + output_path), shell=True)
240+
renderer.magick_path, output_path), shell=True)
241241

242242
self.path = output_path
243243
self.generated = True

rct-graphics-helper/palette_manager.py

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515
from .models.palette import Palette, palette_base_path
1616

1717
default_full_palette = Palette(os.path.join(
18-
palette_base_path, "default_full_palette.png"), [
18+
palette_base_path, "default_full_palette.bmp"), [
1919
"black",
2020
"gray",
2121
"lavender_purple",
@@ -40,44 +40,44 @@
4040
])
4141

4242
default_vehicle_palette = Palette(os.path.join(
43-
palette_base_path, "default_vehicle_palette.png"), [
43+
palette_base_path, "default_vehicle_palette.bmp"), [
4444
"black",
4545
"gray",
4646
"transparent"
4747
])
4848

49-
rider_palette = Palette(os.path.join(palette_base_path, "peep_palette.png"), [
49+
rider_palette = Palette(os.path.join(palette_base_path, "peep_palette.bmp"), [
5050
"black",
5151
"salmon",
5252
"transparent"
5353
])
5454

5555
recolor_1_palette = Palette(os.path.join(
56-
palette_base_path, "recolor_1_palette.png"), [
56+
palette_base_path, "recolor_1_palette.bmp"), [
5757
"recolor_1",
5858
"transparent"
5959
])
6060

6161
recolor_1_orct2_palette = Palette(os.path.join(
62-
palette_base_path, "recolor_1_orct2_palette.png"), [
62+
palette_base_path, "recolor_1_orct2_palette.bmp"), [
6363
"recolor_1_orct2",
6464
"transparent"
6565
])
6666

6767
recolor_2_palette = Palette(os.path.join(
68-
palette_base_path, "recolor_2_palette.png"), [
68+
palette_base_path, "recolor_2_palette.bmp"), [
6969
"magenta",
7070
"transparent"
7171
])
7272

7373
recolor_3_palette = Palette(os.path.join(
74-
palette_base_path, "recolor_3_palette.png"), [
74+
palette_base_path, "recolor_3_palette.bmp"), [
7575
"yellow",
7676
"transparent"
7777
])
7878

7979
custom_palette = Palette(os.path.join(
80-
palette_base_path, "custom_palette.png"), [
80+
palette_base_path, "custom_palette.bmp"), [
8181
"yellow",
8282
])
8383

-280 Bytes
Binary file not shown.
986 Bytes
Binary file not shown.
206 Bytes
Binary file not shown.
-232 Bytes
Binary file not shown.
15 Bytes
Loading
37 Bytes
Loading
24 Bytes
Loading

0 commit comments

Comments
 (0)