Commits

Anonymous committed 031f215

added lightWalls toggle

Comments (0)

Files changed (1)

src/main/java/net/fishbulb/jcod/demo/Fov.java

         console.clear();
         console.setDefaultForeground(Color.BLACK);
         console.putChar(px, py, '@', BlendMode.None);
-        algo.computeFov(px, py, 0, true);
+        algo.computeFov(px, py, 0, lightWalls);
 
         for (int y = 0; y < height; y++) {
             for (int x = 0; x < width; x++) {
             case Input.Keys.D:
                 moveTo(px+1, py);
                 return true;
+            case Input.Keys.T:
+                // TODO: torch effect
+            case Input.Keys.L:
+                lightWalls = !lightWalls;
+                return true;
         }
         return false;
     }