Commits

Troels Damgaard committed f7605e6

Only pull new noise when space is pressed

  • Participants
  • Parent commits d9ecadd

Comments (0)

Files changed (1)

 libtcod.console_print(0, 3, SCREEN_HEIGHT - 5, chr(24) + ', ' + chr(25) + ' - change scale')
 libtcod.console_print(0, 3, SCREEN_HEIGHT - 4, 'PgUp, PgDn - change octaves')
 libtcod.console_print(0, 3, SCREEN_HEIGHT - 3, 'ESC - exit')
-libtcod.console_print(0, 3, SCREEN_HEIGHT - 2, 'Any other key - redraw')
+libtcod.console_print(0, 3, SCREEN_HEIGHT - 2, 'Space - new noise')
 
 while not libtcod.console_is_window_closed():
     render_noise_based_consoles()
         noise_octaves += 0.1
     elif key.vk == libtcod.KEY_PAGEDOWN:
         noise_octaves -= 0.1
-
-    noise = libtcod.noise_new(2)
+    elif key.vk == libtcod.KEY_SPACE:
+        noise = libtcod.noise_new(2)