Skip to content

Commit

Permalink
fixed an issue with a default argument being an int instead of a list
Browse files Browse the repository at this point in the history
  • Loading branch information
Faraphel committed Feb 10, 2022
1 parent 3286f7e commit 409fa2d
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions source/Game.py
Original file line number Diff line number Diff line change
Expand Up @@ -526,7 +526,7 @@ def get_layer_size(layer: dict) -> tuple:
image = Image.new(
generator.get("format", "RGB"),
(generator["width"], generator["height"]),
tuple(generator.get("color", 0))
tuple(generator.get("color", [0]))
)
draw = ImageDraw.Draw(image)

Expand All @@ -535,7 +535,7 @@ def get_layer_size(layer: dict) -> tuple:
if layer["type"] == "color":
draw.rectangle(
get_layer_bbox(layer),
tuple(layer.get("color", 0))
tuple(layer.get("color", [0]))
)
if layer["type"] == "image":
layer_image = Image.open(f'{self.common.ct_config.pack_path}/file/{layer["path"]}')
Expand Down

0 comments on commit 409fa2d

Please sign in to comment.