diff --git a/rogueviz/dynamic-wfc.cpp b/rogueviz/dynamic-wfc.cpp index 5553174d..dc607390 100644 --- a/rogueviz/dynamic-wfc.cpp +++ b/rogueviz/dynamic-wfc.cpp @@ -256,9 +256,6 @@ void wfc() { int ca=0, cb=0, cc=0, cd=0, ce=0; int cur1 = (cur+1) % 3; int cur2 = (cur+2) % 3; - int same = 0; - int in1 = 0; - int in2 = 0; for(int i=0; i= 2; // && in2 >= 2; + mul[a] = ca==1 && cb==1 && cc==1 && cd==1 && ce==0; if(mul[a]) println(hlog, v, cur, " => ", mul[a]); break; } diff --git a/rogueviz/highdim-demo.cpp b/rogueviz/highdim-demo.cpp index 175aa21a..a8998bdd 100644 --- a/rogueviz/highdim-demo.cpp +++ b/rogueviz/highdim-demo.cpp @@ -362,10 +362,10 @@ int mycanvas(cell *c) { case 10: /* house */ { d[0]--; - int is0 = 0, is1 = 0, is2 = 0, ismore = 0; + int is1 = 0, is2 = 0, ismore = 0; for(int a=0; a 2) ismore++; diff --git a/rogueviz/pentagonal.cpp b/rogueviz/pentagonal.cpp index af883dd2..2ed53e4d 100644 --- a/rogueviz/pentagonal.cpp +++ b/rogueviz/pentagonal.cpp @@ -233,11 +233,8 @@ void create_model() { transmatrix tester = spin(1.1) * xpush(1); - int idh = 0; - for(hyperpoint h: {ctr, tria[0], tria[1], tria[2], tria[3], tria[4], ctr}) { int good1 = 0, good2 = 0; - // printf("%d: ", idh); for(int i=0; i<5; i++) { array testplane; testplane[0] = tester * h; @@ -247,13 +244,9 @@ void create_model() { if(f[0] > -1e-6 || std::isnan(f[0])) good1++; if(f[0] < +1e-6 || std::isnan(f[0])) good2++; } - // printf("\n"); if(good1 == 5 || good2 == 5) {ctr = h; break; } - idh++; } - // printf("idh = %d\n", idh); - // printf("createmodel with ticks = %d\n", ticks); transmatrix t = hyperbolic ? hr::cspin180(0, 2) * xpush(sin(ticks * TAU / anims::period)) : hr::cspin(0, 2, ticks * TAU / anims::period); diff --git a/rogueviz/planets.cpp b/rogueviz/planets.cpp index 75529210..736b945a 100644 --- a/rogueviz/planets.cpp +++ b/rogueviz/planets.cpp @@ -162,7 +162,7 @@ bool kill_off(hyperpoint h1, hyperpoint h2, hyperpoint& h3) { int bad; void test_reverse() { - int ok = 0, killed = 0; + int killed = 0; bad = 0; for(int a=0; a<100; a++) { hyperpoint h = random_spin3() * C0; @@ -172,7 +172,7 @@ void test_reverse() { reverse_model(h1, h2, pmodel); bool ko = kill_off(h, h1, h2); if(hdist(h, h2) < 1e-5) - ok++; + ; else if(ko) killed++; else { @@ -180,7 +180,6 @@ void test_reverse() { println(hlog, h, " -> ", h1, " -> ", h2); } } - // println(hlog, "ok ", ok, " bad ", bad, " killed ", killed); } texture::texture_data *tgt_planet = &moon; diff --git a/rogueviz/simple-impossible.cpp b/rogueviz/simple-impossible.cpp index 00ea3958..2e86b8cb 100644 --- a/rogueviz/simple-impossible.cpp +++ b/rogueviz/simple-impossible.cpp @@ -151,8 +151,7 @@ void draw_ro() { transmatrix S = Id; if(spinning) S = cspin(0, 1, ticks * TAU / anims::period); - int bid = 0; - for(auto& b: bricks) { bid++; + for(auto& b: bricks) { transmatrix V = eupush(b.location); int which = b.walls; diff --git a/rogueviz/weirdmaze.cpp b/rogueviz/weirdmaze.cpp index 0eab41d8..852625cb 100644 --- a/rogueviz/weirdmaze.cpp +++ b/rogueviz/weirdmaze.cpp @@ -41,11 +41,9 @@ bool restrict(cell *c, const shiftmatrix& V) { cellwalker cw(c, i); cellwalker cw0 = cw; - int q = 0; int walls = 0; vector unknown; do { - q++; cw += wstep; cw++; if(cw.at->wall == waWaxWall) walls++;