diff --git a/src/render_with_Makie.jl b/src/render_with_Makie.jl index da6bc77..3b16b51 100644 --- a/src/render_with_Makie.jl +++ b/src/render_with_Makie.jl @@ -23,13 +23,7 @@ function init_screen(w::Observable{<:AbstractGridWorld}; resolution=(1000,1000)) # 2. paint each kind of object for o in get_object(w[]) - if o === WALL - poly!(scene, @lift(boxes(findall($w.world[WALL, :, :]), $tile_size)), color=:darkgray,) - elseif o === GOAL - scatter!(scene, @lift(centers(findall($w.world[GOAL,:,:]), $tile_size)), color=get_color(GOAL), marker=convert(Char, GOAL), markersize=@lift(minimum($tile_size))) - elseif o isa Door - scatter!(scene, @lift(centers(findall($w.world[o,:,:]), $tile_size)), color=get_color(o), marker=convert(Char, o), markersize=@lift(minimum($tile_size))) - elseif o isa Key + if o !== EMPTY scatter!(scene, @lift(centers(findall($w.world[o,:,:]), $tile_size)), color=get_color(o), marker=convert(Char, o), markersize=@lift(minimum($tile_size))) end end