Anonymous avatar Anonymous committed feb2ad6

yak shaving

Comments (0)

Files changed (1)

src/main/java/net/fishbulb/jcod/fov/Basic.java

         map.clearFov();
 
         xo = xmin; yo = ymin;
-        while (xo < xmax) {
+        while (xo < xmax)
             castRay(x, y, xo++, yo, r2, walls);
-        }
+
         xo = xmax - 1; yo = ymin + 1;
-        while (yo < ymax) {
+        while (yo < ymax)
             castRay(x, y, xo, yo++, r2, walls);
-        }
+
         xo = xmax - 2; yo = ymax - 1;
-        while (xo >= 0) {
+        while (xo >= 0)
             castRay(x, y, xo--, yo, r2, walls);
-        }
+
         xo = xmin; yo = ymax - 2;
-        while (yo > 0) {
+        while (yo > 0)
             castRay(x, y, xo, yo--, r2, walls);
-        }
+
         if (walls) {
             // post-processing artefact fix
             postProcess(xmin, ymin, x, y, -1, -1);
         }
     }
 
-
     void postProcess(int x0, int y0, int x1, int y1, int dx, int dy) {
-        int cx, cy;
-        for (cx = x0; cx <= x1; cx++) {
-            for (cy = y0; cy <= y1; cy++) {
+        for (int cx = x0; cx <= x1; cx++) {
+            for (int cy = y0; cy <= y1; cy++) {
                 int x2 = cx + dx;
                 int y2 = cy + dy;
                 if (!(map.contains(cx, cy) && map.isFov(cx, cy) && map.isTransparent(cx, cy)))
             }
         }
     }
-
-
 }
Tip: Filter by directory path e.g. /media app.js to search for public/media/app.js.
Tip: Use camelCasing e.g. ProjME to search for ProjectModifiedEvent.java.
Tip: Filter by extension type e.g. /repo .js to search for all .js files in the /repo directory.
Tip: Separate your search with spaces e.g. /ssh pom.xml to search for src/ssh/pom.xml.
Tip: Use ↑ and ↓ arrow keys to navigate and return to view the file.
Tip: You can also navigate files with Ctrl+j (next) and Ctrl+k (previous) and view the file with Ctrl+o.
Tip: You can also navigate files with Alt+j (next) and Alt+k (previous) and view the file with Alt+o.