diff options
Diffstat (limited to 'src/window.c')
-rw-r--r-- | src/window.c | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/src/window.c b/src/window.c new file mode 100644 index 0000000..9eebb36 --- /dev/null +++ b/src/window.c @@ -0,0 +1,19 @@ +#include "entityimpl.h" +#include "lzr.h" + +IMPL(draw) { + const LZR_ImageDrawSettings stg = + {0, 0, -1, -1, 1.0, 1.0, 0.0, true, false, false}; + LZR_DrawSetColor(1, 1, 1, 1); + LZR_DrawImageEx(LZR_IMAGE(this->broken ? "res/window.bmp" : "res/windowclean.bmp"), + this->pos[0], this->pos[1], stg); +} + +IMPL(smash) { + LZR_PlaySound(1); + this->broken = 1; +} + +IMPL_INIT(window) { + this->width = this->height = 64; +} |