FloodFill #2

Merged
FisionX merged 16 commits from floodfill into main 2024-08-09 18:29:49 -06:00
3 changed files with 8 additions and 4 deletions
Showing only changes of commit b9e87379b9 - Show all commits

View File

@ -1,4 +1,4 @@
#include "API.h" #include "api.h"
#include <cstdlib> #include <cstdlib>
#include <iostream> #include <iostream>

View File

View File

@ -1,19 +1,23 @@
#include <iostream> #include <iostream>
#include <string> #include <string>
#include "API.h" #include "api.h"
void log(const std::string& text) { void log(const std::string& text) {
std::cerr << text << std::endl; std::cerr << text << std::endl;
} }
void log(const int& num) {
std::cerr << num << std::endl;
}
int main(int argc, char* argv[]) { int main(int argc, char* argv[]) {
log("Running..."); log("Running...");
API::setColor(0, 0, 'G'); API::setColor(0, 0, 'G');
API::setText(0, 0, "abc"); // API::setText(0, 0, "abc");
API::setWall(1, 0, 'e');
while (true) { while (true) {
if (!API::wallLeft()) { if (!API::wallLeft()) {
API::turnLeft(); API::turnLeft();
//std::cerr << API::mazeWidth() << std::endl;
} }
while (API::wallFront()) { while (API::wallFront()) {
API::turnRight(); API::turnRight();