From a4d0b45c5eee55a8b728b43b901032121e043fe0 Mon Sep 17 00:00:00 2001 From: Estevao Date: Fri, 16 Apr 2021 01:01:34 -0300 Subject: [PATCH] fixed the invisible wall code --- src/main.py | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/main.py b/src/main.py index 878f044..91a8e9f 100644 --- a/src/main.py +++ b/src/main.py @@ -332,10 +332,12 @@ def post_solve_pig_wood(arbiter, space, _): elif event.type == pygame.KEYDOWN and event.key == pygame.K_w: # Toggle wall if wall: - space.remove(static_lines1) + for line in static_lines1: + space.remove(line) wall = False else: - space.add(static_lines1) + for line in static_lines1: + space.add(line) wall = True elif event.type == pygame.KEYDOWN and event.key == pygame.K_s: