Auto full-combo Koibumi2000 in Taiko no Tatsujin CS5
Dependencies: fll mbed-rtos mbed
Diff: main.cpp
- Revision:
- 9:0d6631edfc32
- Parent:
- 8:d16a0fcc2735
- Child:
- 10:79bb44beb08b
--- a/main.cpp Sat Feb 14 16:51:25 2015 +0000 +++ b/main.cpp Sat Feb 14 17:10:12 2015 +0000 @@ -1,34 +1,17 @@ #include "mbed.h" #include "rtos.h" #include "fll.h" - -#define FRAME 1.0 / 60 // 1 frame (sec) - -// [ Up, Right, Down, ... ] -// +--- OrFoldFlow ---> [ Up|Circle, Right, Down|Triangle, Up, Right|Circle, ... ] -// [ Circle, none, Triangle, none, ... ] -class OrFoldFlow : public FoldFlow { - public: - OrFoldFlow(Producer **srcs, int srcs_size) : FoldFlow(srcs, srcs_size) {} - virtual button_t fold(button_t *bs, int bs_size) { - button_t b = 0x00; - for(int i = 0; i < bs_size; i++) { - b |= bs[i]; - } - return b; - } -}; +#include "fll_producers.h" int main(void) { button_t array0[] = {R1, 0}; button_t array1[] = {CIRCLE, 0}; - // fll user must make a Producer Producer* source0 = new RepeaterSource(array0, sizeof(array0)/sizeof(button_t)); Producer* source1 = new RepeaterSource(array1, sizeof(array1)/sizeof(button_t)); Producer* ss[] = {source0, source1}; - Producer* source = new OrFoldFlow(ss, 2); + Producer* source = new MergeFlow(ss, 2); fll_run(source); }