Skip to content

Commit 08dc836

Browse files
committed
Fix pylint issues
1 parent d1c09dc commit 08dc836

File tree

2 files changed

+12
-3
lines changed

2 files changed

+12
-3
lines changed

Metro/Metro_RP2350_Matching_Game/code.py

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -142,7 +142,14 @@ def get_color_index(color, shader=None):
142142
main_group.append(ui_group)
143143

144144
# Create the game logic object
145-
game_logic = GameLogic(display, game_grid, swap_piece, selected_piece_group, GAME_PIECES) # pylint: disable=no-value-for-parameter
145+
# pylint: disable=no-value-for-parameter, too-many-function-args
146+
game_logic = GameLogic(
147+
display,
148+
game_grid,
149+
swap_piece,
150+
selected_piece_group,
151+
GAME_PIECES
152+
)
146153

147154
# Create the mouse graphics and add to the main group
148155
mouse = find_and_init_boot_mouse("/bitmaps/mouse_cursor.bmp")

Metro/Metro_RP2350_Matching_Game/gamelogic.py

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -386,7 +386,8 @@ def check_match_after_move(self, row, column, direction, move_type='horizontal')
386386

387387
return True, len(all_matches) > 0
388388

389-
def check_horizontal_match(self, grid, row, column, piece):
389+
@staticmethod
390+
def check_horizontal_match(grid, row, column, piece):
390391
"""Check for horizontal 3-in-a-row matches centered
391392
around or including the given position."""
392393
matches = []
@@ -404,7 +405,8 @@ def check_horizontal_match(self, grid, row, column, piece):
404405

405406
return matches
406407

407-
def check_vertical_match(self, grid, row, column, piece):
408+
@staticmethod
409+
def check_vertical_match(grid, row, column, piece):
408410
"""Check for vertical 3-in-a-row matches centered around or including the given position."""
409411
matches = []
410412
rows = len(grid)

0 commit comments

Comments
 (0)