Add bombs and explodable bricks
This commit is contained in:
parent
23f034a868
commit
feb5b8f3d6
6 changed files with 86 additions and 2 deletions
9
game.scm
9
game.scm
|
@ -365,6 +365,10 @@
|
|||
(_ (draw-tile context tileset 3 x y)))
|
||||
(draw-wire-state pos type)))
|
||||
|
||||
(define (draw-brick pos exploding?)
|
||||
;; TODO use exploding for different sprite?
|
||||
(draw-tile context tileset 22 (vec2-x pos) (vec2-y pos)))
|
||||
|
||||
(define (draw-clock-emitter pos)
|
||||
(draw-tile context tileset 48 (vec2-x pos) (vec2-y pos)))
|
||||
|
||||
|
@ -374,6 +378,9 @@
|
|||
(define (draw-floor-switch pos on?)
|
||||
(draw-tile context tileset (if on? 25 24) (vec2-x pos) (vec2-y pos)))
|
||||
|
||||
(define (draw-bomb pos exploding?)
|
||||
(draw-tile context tileset (if exploding? 51 50) (vec2-x pos) (vec2-y pos)))
|
||||
|
||||
(define (draw-gem pos)
|
||||
(draw-tile context tileset 28 (vec2-x pos) (vec2-y pos)))
|
||||
|
||||
|
@ -410,9 +417,11 @@
|
|||
(('exit pos) #t) ; drawn via background
|
||||
(('wall pos type) (draw-wall pos type))
|
||||
(('block pos type) (draw-block pos type))
|
||||
(('brick pos exploding?) (draw-brick pos exploding?))
|
||||
(('clock-emitter pos) (draw-clock-emitter pos))
|
||||
(('switched-emitter pos on?) (draw-switched-emitter pos on?))
|
||||
(('floor-switch pos on?) (draw-floor-switch pos on?))
|
||||
(('bomb pos exploding?) (draw-bomb pos exploding?))
|
||||
(('gem pos) (draw-gem pos))
|
||||
(('ghost-gem pos) (draw-ghost-gem pos))
|
||||
(('gate pos open?) (draw-gate pos open?))
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue