From 284fbac5332b3005254fcfb2ad1efe7ad1a6f6ca Mon Sep 17 00:00:00 2001 From: asklepios Date: Thu, 12 May 2011 20:16:14 +0000 Subject: [PATCH] first small animations for giga-borg --- Makefile | 4 ++-- animations/flyingdots.c | 2 +- config.in | 5 +++++ display_loop.c | 19 +++++++++++++++++++ 4 files changed, 27 insertions(+), 3 deletions(-) diff --git a/Makefile b/Makefile index d9c422a..c06b9a2 100644 --- a/Makefile +++ b/Makefile @@ -39,6 +39,7 @@ include defaults.mk .subdirs: autoconf.h @ echo "checking in which subdirs to build" @ $(RM) -f $@ + @ echo "SUBDIRS += smallani" >> $@ @ echo "SUBDIRS += animations" >> $@ @ (for subdir in `grep -e "^#define .*_SUPPORT" autoconf.h \ | sed -e "s/^#define //" -e "s/_SUPPORT.*//" \ @@ -72,7 +73,7 @@ compile-subdirs_avr: .PHONY: compile-$(TARGET) compile-$(TARGET): compile-subdirs_avr $(TARGET).hex $(TARGET).bin $(TARGET).lst - @ echo "foobar" + OBJECTS += $(patsubst %.c,./obj_avr/%.o,${SRC}) @@ -141,7 +142,6 @@ menuconfig: @echo "" @echo "Next, you can: " @echo " * 'make' to compile your borgware" - #%/menuconfig: # $(SH) "$(@D)/configure" diff --git a/animations/flyingdots.c b/animations/flyingdots.c index 041e460..7cf9bef 100644 --- a/animations/flyingdots.c +++ b/animations/flyingdots.c @@ -65,7 +65,7 @@ void flyingdots() //shift the picture right //(yes, shift_pixmap_l shifts the picture right) - shift_pixmap_l(); + shift_pixmap_l(); //wait a bit wait(100); diff --git a/config.in b/config.in index 7f9dc42..c54bddc 100644 --- a/config.in +++ b/config.in @@ -48,6 +48,7 @@ source can/config.in ### Borg Menu ################################################################# dep_bool "menu support" MENU_SUPPORT $JOYSTICK_SUPPORT +depends on JOYSTICK_SUPPORT ############################################################################### @@ -59,3 +60,7 @@ source games/config.in ### Animations Menu ########################################################### source animations/config.in ############################################################################### + +### small Animations Menu ########################################################### +source smallani/config.in +############################################################################### diff --git a/display_loop.c b/display_loop.c index 4e45dcf..33d3d66 100644 --- a/display_loop.c +++ b/display_loop.c @@ -24,6 +24,13 @@ #include "mcuf/mcuf.h" #include "menu/menu.h" #include "pixel.h" +#ifdef SMALLANIMATION_ROWWALK +#include "smallani/rowwalk.h" +#endif +#ifdef SMALLANIMATION_COLWALK +#include "smallani/colwalk.h" +#endif + #ifdef JOYSTICK_SUPPORT # include "joystick/joystick.h" #endif @@ -205,6 +212,18 @@ void display_loop(){ break; #endif +#ifdef SMALLANIMATION_ROWWALK + case 36: + rowwalk(10,50); + break; +#endif + +#ifdef SMALLANIMATION_COLWALK + case 37: + colwalk(10,50); + break; +#endif + #ifdef MENU_SUPPORT case 42: mode = 1;