update step 3 times
This commit is contained in:
parent
b74536b057
commit
65203c309f
@ -22,7 +22,7 @@ void step3(void) {
|
|||||||
switch (puzzle) {
|
switch (puzzle) {
|
||||||
case 0: {
|
case 0: {
|
||||||
lcd_print(&lcd, "Clear");
|
lcd_print(&lcd, "Clear");
|
||||||
set_module_time(10000);
|
set_module_time(15000);
|
||||||
start_module_timer();
|
start_module_timer();
|
||||||
|
|
||||||
std::uniform_int_distribution<> green_indicators_dist(2, 15);
|
std::uniform_int_distribution<> green_indicators_dist(2, 15);
|
||||||
@ -94,7 +94,7 @@ void step3(void) {
|
|||||||
}
|
}
|
||||||
case 1: {
|
case 1: {
|
||||||
lcd_print(&lcd, "Blank");
|
lcd_print(&lcd, "Blank");
|
||||||
set_module_time(10000);
|
set_module_time(20000);
|
||||||
start_module_timer();
|
start_module_timer();
|
||||||
|
|
||||||
std::uniform_int_distribution<> on_indicators_dist(16, 21);
|
std::uniform_int_distribution<> on_indicators_dist(16, 21);
|
||||||
@ -155,7 +155,7 @@ void step3(void) {
|
|||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
case 2: {
|
case 2: {
|
||||||
set_module_time(10000);
|
set_module_time(20000);
|
||||||
start_module_timer();
|
start_module_timer();
|
||||||
|
|
||||||
std::uniform_int_distribution<> lit_led_dist(0, 1);
|
std::uniform_int_distribution<> lit_led_dist(0, 1);
|
||||||
@ -342,7 +342,7 @@ void step3(void) {
|
|||||||
}
|
}
|
||||||
case 4: {
|
case 4: {
|
||||||
lcd_print(&lcd, "Blink");
|
lcd_print(&lcd, "Blink");
|
||||||
set_module_time(10000);
|
set_module_time(25000);
|
||||||
start_module_timer();
|
start_module_timer();
|
||||||
|
|
||||||
// buttons
|
// buttons
|
||||||
@ -469,7 +469,7 @@ void step3(void) {
|
|||||||
}
|
}
|
||||||
case 5: {
|
case 5: {
|
||||||
lcd_print(&lcd, "Ummm");
|
lcd_print(&lcd, "Ummm");
|
||||||
set_module_time(30000);
|
set_module_time(20000);
|
||||||
start_module_timer();
|
start_module_timer();
|
||||||
|
|
||||||
std::uniform_int_distribution<> indicator_number_dist(0, 5);
|
std::uniform_int_distribution<> indicator_number_dist(0, 5);
|
||||||
@ -527,18 +527,21 @@ void step3(void) {
|
|||||||
green_pressed++;
|
green_pressed++;
|
||||||
if (green_pressed > green_indicators) {
|
if (green_pressed > green_indicators) {
|
||||||
strike("Green button pressed too many times! (step 3, puzzle 5)");
|
strike("Green button pressed too many times! (step 3, puzzle 5)");
|
||||||
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if ((button_state & 0b10) == 0b10) {
|
if ((button_state & 0b10) == 0b10) {
|
||||||
red_pressed++;
|
red_pressed++;
|
||||||
if (red_pressed > red_indicators) {
|
if (red_pressed > red_indicators) {
|
||||||
strike("Red button pressed too many times! (step 3, puzzle 5)");
|
strike("Red button pressed too many times! (step 3, puzzle 5)");
|
||||||
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if ((button_state & 0b100) == 0b100) {
|
if ((button_state & 0b100) == 0b100) {
|
||||||
yellow_pressed++;
|
yellow_pressed++;
|
||||||
if (yellow_pressed > yellow_indicators) {
|
if (yellow_pressed > yellow_indicators) {
|
||||||
strike("Yellow button pressed too many times! (step 3, puzzle 5)");
|
strike("Yellow button pressed too many times! (step 3, puzzle 5)");
|
||||||
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if ((button_state & 0b1000) == 0b1000) {
|
if ((button_state & 0b1000) == 0b1000) {
|
||||||
@ -575,7 +578,7 @@ void step3(void) {
|
|||||||
}
|
}
|
||||||
case 6: {
|
case 6: {
|
||||||
lcd_print(&lcd, "Plank");
|
lcd_print(&lcd, "Plank");
|
||||||
set_module_time(10000);
|
set_module_time(15000);
|
||||||
start_module_timer();
|
start_module_timer();
|
||||||
|
|
||||||
// red, purple, blue, white, green, yellow
|
// red, purple, blue, white, green, yellow
|
||||||
@ -674,7 +677,7 @@ void step3(void) {
|
|||||||
}
|
}
|
||||||
case 7: {
|
case 7: {
|
||||||
lcd_print(&lcd, "What");
|
lcd_print(&lcd, "What");
|
||||||
set_module_time(30000);
|
set_module_time(20000);
|
||||||
start_module_timer();
|
start_module_timer();
|
||||||
|
|
||||||
std::uniform_int_distribution<> math_number_dist(1, 9);
|
std::uniform_int_distribution<> math_number_dist(1, 9);
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user