tcod 18.0.0__tar.gz → 18.1.0__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (213) hide show
  1. {tcod-18.0.0 → tcod-18.1.0}/CHANGELOG.md +10 -0
  2. {tcod-18.0.0 → tcod-18.1.0}/PKG-INFO +1 -1
  3. {tcod-18.0.0 → tcod-18.1.0}/tcod/console.py +28 -1
  4. {tcod-18.0.0 → tcod-18.1.0}/tcod/noise.py +2 -2
  5. {tcod-18.0.0 → tcod-18.1.0}/tcod/path.py +150 -7
  6. {tcod-18.0.0 → tcod-18.1.0}/tcod/version.py +2 -2
  7. {tcod-18.0.0 → tcod-18.1.0}/tcod.egg-info/PKG-INFO +1 -1
  8. {tcod-18.0.0 → tcod-18.1.0}/CONTRIBUTING.md +0 -0
  9. {tcod-18.0.0 → tcod-18.1.0}/LICENSE.txt +0 -0
  10. {tcod-18.0.0 → tcod-18.1.0}/MANIFEST.in +0 -0
  11. {tcod-18.0.0 → tcod-18.1.0}/README.rst +0 -0
  12. {tcod-18.0.0 → tcod-18.1.0}/build_libtcod.py +0 -0
  13. {tcod-18.0.0 → tcod-18.1.0}/build_sdl.py +0 -0
  14. {tcod-18.0.0 → tcod-18.1.0}/libtcod/CHANGELOG.md +0 -0
  15. {tcod-18.0.0 → tcod-18.1.0}/libtcod/CMakeLists.txt +0 -0
  16. {tcod-18.0.0 → tcod-18.1.0}/libtcod/CONTRIBUTING.md +0 -0
  17. {tcod-18.0.0 → tcod-18.1.0}/libtcod/LIBTCOD-CREDITS.txt +0 -0
  18. {tcod-18.0.0 → tcod-18.1.0}/libtcod/LICENSE.txt +0 -0
  19. {tcod-18.0.0 → tcod-18.1.0}/libtcod/README.md +0 -0
  20. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/libtcod/bresenham.h +0 -0
  21. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/libtcod/bresenham_c.c +0 -0
  22. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/libtcod/bsp.h +0 -0
  23. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/libtcod/bsp_c.c +0 -0
  24. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/libtcod/color.c +0 -0
  25. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/libtcod/color.h +0 -0
  26. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/libtcod/config.h +0 -0
  27. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/libtcod/console.c +0 -0
  28. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/libtcod/console.h +0 -0
  29. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/libtcod/console_drawing.c +0 -0
  30. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/libtcod/console_drawing.h +0 -0
  31. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/libtcod/console_etc.c +0 -0
  32. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/libtcod/console_etc.h +0 -0
  33. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/libtcod/console_init.c +0 -0
  34. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/libtcod/console_init.h +0 -0
  35. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/libtcod/console_printing.c +0 -0
  36. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/libtcod/console_printing.h +0 -0
  37. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/libtcod/console_rexpaint.c +0 -0
  38. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/libtcod/console_rexpaint.h +0 -0
  39. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/libtcod/console_types.h +0 -0
  40. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/libtcod/context.c +0 -0
  41. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/libtcod/context.h +0 -0
  42. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/libtcod/context_init.c +0 -0
  43. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/libtcod/context_init.h +0 -0
  44. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/libtcod/context_viewport.c +0 -0
  45. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/libtcod/context_viewport.h +0 -0
  46. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/libtcod/error.c +0 -0
  47. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/libtcod/error.h +0 -0
  48. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/libtcod/fov.h +0 -0
  49. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/libtcod/fov_c.c +0 -0
  50. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/libtcod/fov_circular_raycasting.c +0 -0
  51. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/libtcod/fov_diamond_raycasting.c +0 -0
  52. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/libtcod/fov_permissive2.c +0 -0
  53. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/libtcod/fov_recursive_shadowcasting.c +0 -0
  54. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/libtcod/fov_restrictive.c +0 -0
  55. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/libtcod/fov_symmetric_shadowcast.c +0 -0
  56. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/libtcod/fov_types.h +0 -0
  57. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/libtcod/globals.c +0 -0
  58. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/libtcod/globals.h +0 -0
  59. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/libtcod/heapq.c +0 -0
  60. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/libtcod/heapq.h +0 -0
  61. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/libtcod/heightmap.h +0 -0
  62. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/libtcod/heightmap_c.c +0 -0
  63. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/libtcod/image.h +0 -0
  64. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/libtcod/image_c.c +0 -0
  65. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/libtcod/lex.h +0 -0
  66. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/libtcod/lex_c.c +0 -0
  67. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/libtcod/libtcod.h +0 -0
  68. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/libtcod/libtcod_int.h +0 -0
  69. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/libtcod/list.h +0 -0
  70. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/libtcod/list_c.c +0 -0
  71. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/libtcod/logging.c +0 -0
  72. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/libtcod/logging.h +0 -0
  73. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/libtcod/mersenne.h +0 -0
  74. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/libtcod/mersenne_c.c +0 -0
  75. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/libtcod/mersenne_types.h +0 -0
  76. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/libtcod/mouse.h +0 -0
  77. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/libtcod/mouse_types.h +0 -0
  78. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/libtcod/namegen.h +0 -0
  79. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/libtcod/namegen_c.c +0 -0
  80. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/libtcod/noise.h +0 -0
  81. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/libtcod/noise_c.c +0 -0
  82. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/libtcod/noise_defaults.h +0 -0
  83. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/libtcod/parser.h +0 -0
  84. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/libtcod/parser_c.c +0 -0
  85. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/libtcod/path.h +0 -0
  86. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/libtcod/path_c.c +0 -0
  87. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/libtcod/pathfinder.c +0 -0
  88. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/libtcod/pathfinder.h +0 -0
  89. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/libtcod/pathfinder_frontier.c +0 -0
  90. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/libtcod/pathfinder_frontier.h +0 -0
  91. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/libtcod/portability.h +0 -0
  92. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/libtcod/random.c +0 -0
  93. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/libtcod/random.h +0 -0
  94. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/libtcod/renderer_sdl2.c +0 -0
  95. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/libtcod/renderer_sdl2.h +0 -0
  96. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/libtcod/renderer_xterm.c +0 -0
  97. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/libtcod/renderer_xterm.h +0 -0
  98. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/libtcod/sdl2/console_grid.glslf +0 -0
  99. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/libtcod/sdl2/console_grid.glslv +0 -0
  100. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/libtcod/sdl2/event.h +0 -0
  101. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/libtcod/sys.h +0 -0
  102. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/libtcod/sys_c.c +0 -0
  103. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/libtcod/sys_sdl_c.c +0 -0
  104. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/libtcod/sys_sdl_img_bmp.c +0 -0
  105. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/libtcod/sys_sdl_img_png.c +0 -0
  106. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/libtcod/tileset.c +0 -0
  107. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/libtcod/tileset.h +0 -0
  108. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/libtcod/tileset_bdf.c +0 -0
  109. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/libtcod/tileset_bdf.h +0 -0
  110. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/libtcod/tileset_fallback.c +0 -0
  111. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/libtcod/tileset_fallback.h +0 -0
  112. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/libtcod/tileset_render.c +0 -0
  113. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/libtcod/tileset_render.h +0 -0
  114. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/libtcod/tileset_truetype.c +0 -0
  115. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/libtcod/tileset_truetype.h +0 -0
  116. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/libtcod/timer.h +0 -0
  117. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/libtcod/tree.h +0 -0
  118. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/libtcod/tree_c.c +0 -0
  119. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/libtcod/txtfield.h +0 -0
  120. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/libtcod/txtfield_c.c +0 -0
  121. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/libtcod/utility.h +0 -0
  122. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/libtcod/version.h +0 -0
  123. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/libtcod/wrappers.c +0 -0
  124. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/libtcod/wrappers.h +0 -0
  125. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/libtcod/zip.h +0 -0
  126. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/libtcod/zip_c.c +0 -0
  127. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/libtcod.h +0 -0
  128. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/libtcod_c.c +0 -0
  129. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/vendor/khrplatform.h +0 -0
  130. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/vendor/lodepng.c +0 -0
  131. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/vendor/lodepng.h +0 -0
  132. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/vendor/stb.c +0 -0
  133. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/vendor/stb_ds.h +0 -0
  134. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/vendor/stb_truetype.h +0 -0
  135. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/vendor/utf8proc/utf8proc.c +0 -0
  136. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/vendor/utf8proc/utf8proc.h +0 -0
  137. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/vendor/utf8proc/utf8proc_data.c +0 -0
  138. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/vendor/zlib/adler32.c +0 -0
  139. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/vendor/zlib/compress.c +0 -0
  140. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/vendor/zlib/crc32.c +0 -0
  141. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/vendor/zlib/crc32.h +0 -0
  142. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/vendor/zlib/deflate.c +0 -0
  143. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/vendor/zlib/deflate.h +0 -0
  144. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/vendor/zlib/gzclose.c +0 -0
  145. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/vendor/zlib/gzguts.h +0 -0
  146. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/vendor/zlib/gzlib.c +0 -0
  147. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/vendor/zlib/gzread.c +0 -0
  148. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/vendor/zlib/gzwrite.c +0 -0
  149. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/vendor/zlib/infback.c +0 -0
  150. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/vendor/zlib/inffast.c +0 -0
  151. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/vendor/zlib/inffast.h +0 -0
  152. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/vendor/zlib/inffixed.h +0 -0
  153. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/vendor/zlib/inflate.c +0 -0
  154. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/vendor/zlib/inflate.h +0 -0
  155. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/vendor/zlib/inftrees.c +0 -0
  156. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/vendor/zlib/inftrees.h +0 -0
  157. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/vendor/zlib/trees.c +0 -0
  158. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/vendor/zlib/trees.h +0 -0
  159. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/vendor/zlib/uncompr.c +0 -0
  160. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/vendor/zlib/zconf.h +0 -0
  161. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/vendor/zlib/zlib.h +0 -0
  162. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/vendor/zlib/zutil.c +0 -0
  163. {tcod-18.0.0 → tcod-18.1.0}/libtcod/src/vendor/zlib/zutil.h +0 -0
  164. {tcod-18.0.0 → tcod-18.1.0}/libtcodpy.py +0 -0
  165. {tcod-18.0.0 → tcod-18.1.0}/pyproject.toml +0 -0
  166. {tcod-18.0.0 → tcod-18.1.0}/requirements.txt +0 -0
  167. {tcod-18.0.0 → tcod-18.1.0}/setup.cfg +0 -0
  168. {tcod-18.0.0 → tcod-18.1.0}/setup.py +0 -0
  169. {tcod-18.0.0 → tcod-18.1.0}/tcod/__init__.py +0 -0
  170. {tcod-18.0.0 → tcod-18.1.0}/tcod/__pyinstaller/__init__.py +0 -0
  171. {tcod-18.0.0 → tcod-18.1.0}/tcod/__pyinstaller/hook-tcod.py +0 -0
  172. {tcod-18.0.0 → tcod-18.1.0}/tcod/_internal.py +0 -0
  173. {tcod-18.0.0 → tcod-18.1.0}/tcod/bsp.py +0 -0
  174. {tcod-18.0.0 → tcod-18.1.0}/tcod/cdef.h +0 -0
  175. {tcod-18.0.0 → tcod-18.1.0}/tcod/cffi.h +0 -0
  176. {tcod-18.0.0 → tcod-18.1.0}/tcod/cffi.py +0 -0
  177. {tcod-18.0.0 → tcod-18.1.0}/tcod/color.py +0 -0
  178. {tcod-18.0.0 → tcod-18.1.0}/tcod/constants.py +0 -0
  179. {tcod-18.0.0 → tcod-18.1.0}/tcod/context.py +0 -0
  180. {tcod-18.0.0 → tcod-18.1.0}/tcod/event.py +0 -0
  181. {tcod-18.0.0 → tcod-18.1.0}/tcod/event_constants.py +0 -0
  182. {tcod-18.0.0 → tcod-18.1.0}/tcod/image.py +0 -0
  183. {tcod-18.0.0 → tcod-18.1.0}/tcod/libtcodpy.py +0 -0
  184. {tcod-18.0.0 → tcod-18.1.0}/tcod/los.py +0 -0
  185. {tcod-18.0.0 → tcod-18.1.0}/tcod/map.py +0 -0
  186. {tcod-18.0.0 → tcod-18.1.0}/tcod/noise.c +0 -0
  187. {tcod-18.0.0 → tcod-18.1.0}/tcod/noise.h +0 -0
  188. {tcod-18.0.0 → tcod-18.1.0}/tcod/path.c +0 -0
  189. {tcod-18.0.0 → tcod-18.1.0}/tcod/path.h +0 -0
  190. {tcod-18.0.0 → tcod-18.1.0}/tcod/py.typed +0 -0
  191. {tcod-18.0.0 → tcod-18.1.0}/tcod/random.h +0 -0
  192. {tcod-18.0.0 → tcod-18.1.0}/tcod/random.py +0 -0
  193. {tcod-18.0.0 → tcod-18.1.0}/tcod/render.py +0 -0
  194. {tcod-18.0.0 → tcod-18.1.0}/tcod/sdl/__init__.py +0 -0
  195. {tcod-18.0.0 → tcod-18.1.0}/tcod/sdl/_internal.py +0 -0
  196. {tcod-18.0.0 → tcod-18.1.0}/tcod/sdl/audio.py +0 -0
  197. {tcod-18.0.0 → tcod-18.1.0}/tcod/sdl/joystick.py +0 -0
  198. {tcod-18.0.0 → tcod-18.1.0}/tcod/sdl/mouse.py +0 -0
  199. {tcod-18.0.0 → tcod-18.1.0}/tcod/sdl/render.py +0 -0
  200. {tcod-18.0.0 → tcod-18.1.0}/tcod/sdl/sys.py +0 -0
  201. {tcod-18.0.0 → tcod-18.1.0}/tcod/sdl/video.py +0 -0
  202. {tcod-18.0.0 → tcod-18.1.0}/tcod/tcod.c +0 -0
  203. {tcod-18.0.0 → tcod-18.1.0}/tcod/tcod.h +0 -0
  204. {tcod-18.0.0 → tcod-18.1.0}/tcod/tcod.py +0 -0
  205. {tcod-18.0.0 → tcod-18.1.0}/tcod/tdl.c +0 -0
  206. {tcod-18.0.0 → tcod-18.1.0}/tcod/tdl.h +0 -0
  207. {tcod-18.0.0 → tcod-18.1.0}/tcod/tileset.py +0 -0
  208. {tcod-18.0.0 → tcod-18.1.0}/tcod.egg-info/SOURCES.txt +0 -0
  209. {tcod-18.0.0 → tcod-18.1.0}/tcod.egg-info/dependency_links.txt +0 -0
  210. {tcod-18.0.0 → tcod-18.1.0}/tcod.egg-info/entry_points.txt +0 -0
  211. {tcod-18.0.0 → tcod-18.1.0}/tcod.egg-info/requires.txt +0 -0
  212. {tcod-18.0.0 → tcod-18.1.0}/tcod.egg-info/top_level.txt +0 -0
  213. {tcod-18.0.0 → tcod-18.1.0}/tox.ini +0 -0
@@ -6,6 +6,16 @@ This project adheres to [Semantic Versioning](https://semver.org/) since version
6
6
 
7
7
  ## [Unreleased]
8
8
 
9
+ ## [18.1.0] - 2025-05-05
10
+
11
+ ### Added
12
+
13
+ - `tcod.path.path2d` to compute paths for the most basic cases.
14
+
15
+ ### Fixed
16
+
17
+ - `tcod.noise.grid` would raise `TypeError` when given a plain integer for scale.
18
+
9
19
  ## [18.0.0] - 2025-04-08
10
20
 
11
21
  ### Changed
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: tcod
3
- Version: 18.0.0
3
+ Version: 18.1.0
4
4
  Summary: The official Python port of libtcod.
5
5
  Author-email: Kyle Benesch <4b796c65+tcod@gmail.com>
6
6
  License: Simplified BSD License
@@ -335,6 +335,33 @@ class Console:
335
335
  The :any:`rgb_graphic` dtype can be used to make arrays compatible
336
336
  with this attribute that are independent of a :any:`Console`.
337
337
 
338
+ Example:
339
+ >>> tile_graphics = np.array( # Tile graphics lookup table
340
+ ... [ # (Unicode, foreground, background)
341
+ ... (ord("."), (255, 255, 255), (0, 0, 0)), # Tile 0
342
+ ... (ord("#"), (255, 255, 255), (0, 0, 0)), # Tile 1
343
+ ... (ord("^"), (255, 255, 255), (0, 0, 0)), # Tile 2
344
+ ... (ord("~"), (255, 255, 255), (0, 0, 0)), # Tile 3
345
+ ... ],
346
+ ... dtype=tcod.console.rgb_graphic,
347
+ ... )
348
+ >>> console = tcod.console.Console(6, 5)
349
+ >>> console.rgb[:] = tile_graphics[ # Convert 2D array of indexes to tile graphics
350
+ ... [
351
+ ... [1, 1, 1, 1, 1, 1],
352
+ ... [1, 0, 2, 0, 0, 1],
353
+ ... [1, 0, 0, 3, 3, 1],
354
+ ... [1, 0, 0, 3, 3, 1],
355
+ ... [1, 1, 1, 1, 1, 1],
356
+ ... ],
357
+ ... ]
358
+ >>> print(console)
359
+ <######
360
+ #.^..#
361
+ #..~~#
362
+ #..~~#
363
+ ######>
364
+
338
365
  Example:
339
366
  >>> con = tcod.console.Console(10, 2)
340
367
  >>> BLUE, YELLOW, BLACK = (0, 0, 255), (255, 255, 0), (0, 0, 0)
@@ -1368,7 +1395,7 @@ Consider one of the following:
1368
1395
  ) -> None: ...
1369
1396
 
1370
1397
  @overload
1371
- @deprecated("Parameters cg, fg, bg, bg_blend should be keyword arguments")
1398
+ @deprecated("Parameters ch, fg, bg, bg_blend should be keyword arguments")
1372
1399
  def draw_rect(
1373
1400
  self,
1374
1401
  x: int,
@@ -411,7 +411,7 @@ def grid(
411
411
  scale: tuple[float, ...] | float,
412
412
  origin: tuple[int, ...] | None = None,
413
413
  indexing: Literal["ij", "xy"] = "xy",
414
- ) -> tuple[NDArray[Any], ...]:
414
+ ) -> tuple[NDArray[np.number], ...]:
415
415
  """Generate a mesh-grid of sample points to use with noise sampling.
416
416
 
417
417
  Args:
@@ -449,7 +449,7 @@ def grid(
449
449
 
450
450
  .. versionadded:: 12.2
451
451
  """
452
- if isinstance(scale, float):
452
+ if isinstance(scale, (int, float)):
453
453
  scale = (scale,) * len(shape)
454
454
  if origin is None:
455
455
  origin = (0,) * len(shape)
@@ -21,7 +21,7 @@ from __future__ import annotations
21
21
  import functools
22
22
  import itertools
23
23
  import warnings
24
- from typing import TYPE_CHECKING, Any, Callable, Final
24
+ from typing import TYPE_CHECKING, Any, Callable, Final, Sequence
25
25
 
26
26
  import numpy as np
27
27
  from typing_extensions import Literal, Self
@@ -324,7 +324,7 @@ def _export_dict(array: NDArray[Any]) -> dict[str, Any]:
324
324
  }
325
325
 
326
326
 
327
- def _export(array: NDArray[np.number]) -> Any: # noqa: ANN401
327
+ def _export(array: NDArray[np.integer]) -> Any: # noqa: ANN401
328
328
  """Convert a NumPy array into a cffi object."""
329
329
  return ffi.new("struct NArray*", _export_dict(array))
330
330
 
@@ -355,8 +355,8 @@ def dijkstra2d( # noqa: PLR0913
355
355
  diagonal: int | None = None,
356
356
  *,
357
357
  edge_map: ArrayLike | None = None,
358
- out: NDArray[np.number] | None = ..., # type: ignore[assignment, unused-ignore]
359
- ) -> NDArray[Any]:
358
+ out: NDArray[np.integer] | None = ..., # type: ignore[assignment, unused-ignore]
359
+ ) -> NDArray[np.integer]:
360
360
  """Return the computed distance of all nodes on a 2D Dijkstra grid.
361
361
 
362
362
  `distance` is an input array of node distances. Is this often an
@@ -528,7 +528,7 @@ def hillclimb2d(
528
528
  diagonal: bool | None = None,
529
529
  *,
530
530
  edge_map: ArrayLike | None = None,
531
- ) -> NDArray[Any]:
531
+ ) -> NDArray[np.intc]:
532
532
  """Return a path on a grid from `start` to the lowest point.
533
533
 
534
534
  `distance` should be a fully computed distance array. This kind of array
@@ -1289,7 +1289,7 @@ class Pathfinder:
1289
1289
  self._update_heuristic(goal)
1290
1290
  self._graph._resolve(self)
1291
1291
 
1292
- def path_from(self, index: tuple[int, ...]) -> NDArray[Any]:
1292
+ def path_from(self, index: tuple[int, ...]) -> NDArray[np.intc]:
1293
1293
  """Return the shortest path from `index` to the nearest root.
1294
1294
 
1295
1295
  The returned array is of shape `(length, ndim)` where `length` is the
@@ -1343,7 +1343,7 @@ class Pathfinder:
1343
1343
  )
1344
1344
  return path[:, ::-1] if self._order == "F" else path
1345
1345
 
1346
- def path_to(self, index: tuple[int, ...]) -> NDArray[Any]:
1346
+ def path_to(self, index: tuple[int, ...]) -> NDArray[np.intc]:
1347
1347
  """Return the shortest path from the nearest root to `index`.
1348
1348
 
1349
1349
  See :any:`path_from`.
@@ -1370,3 +1370,146 @@ class Pathfinder:
1370
1370
  []
1371
1371
  """
1372
1372
  return self.path_from(index)[::-1]
1373
+
1374
+
1375
+ def path2d( # noqa: C901, PLR0912, PLR0913
1376
+ cost: ArrayLike,
1377
+ *,
1378
+ start_points: Sequence[tuple[int, int]],
1379
+ end_points: Sequence[tuple[int, int]],
1380
+ cardinal: int,
1381
+ diagonal: int | None = None,
1382
+ check_bounds: bool = True,
1383
+ ) -> NDArray[np.intc]:
1384
+ """Return a path between `start_points` and `end_points`.
1385
+
1386
+ If `start_points` or `end_points` has only one item then this is equivalent to A*.
1387
+ Otherwise it is equivalent to Dijkstra.
1388
+
1389
+ If multiple `start_points` or `end_points` are given then the single shortest path between them is returned.
1390
+
1391
+ Points placed on nodes with a cost of 0 are treated as always reachable from adjacent nodes.
1392
+
1393
+ Args:
1394
+ cost: A 2D array of integers with the cost of each node.
1395
+ start_points: A sequence of one or more starting points indexing `cost`.
1396
+ end_points: A sequence of one or more ending points indexing `cost`.
1397
+ cardinal: The relative cost to move a cardinal direction.
1398
+ diagonal: The relative cost to move a diagonal direction.
1399
+ `None` or `0` will disable diagonal movement.
1400
+ check_bounds: If `False` then out-of-bounds points are silently ignored.
1401
+ If `True` (default) then out-of-bounds points raise :any:`IndexError`.
1402
+
1403
+ Returns:
1404
+ A `(length, 2)` array of indexes of the path including the start and end points.
1405
+ If there is no path then an array with zero items will be returned.
1406
+
1407
+ Example::
1408
+
1409
+ # Note: coordinates in this example are (i, j), or (y, x)
1410
+ >>> cost = np.array([
1411
+ ... [1, 0, 1, 1, 1, 0, 1],
1412
+ ... [1, 0, 1, 1, 1, 0, 1],
1413
+ ... [1, 0, 1, 0, 1, 0, 1],
1414
+ ... [1, 1, 1, 1, 1, 0, 1],
1415
+ ... ])
1416
+
1417
+ # Endpoints are reachable even when endpoints are on blocked nodes
1418
+ >>> tcod.path.path2d(cost, start_points=[(0, 0)], end_points=[(2, 3)], cardinal=70, diagonal=99)
1419
+ array([[0, 0],
1420
+ [1, 0],
1421
+ [2, 0],
1422
+ [3, 1],
1423
+ [2, 2],
1424
+ [2, 3]], dtype=int...)
1425
+
1426
+ # Unreachable endpoints return a zero length array
1427
+ >>> tcod.path.path2d(cost, start_points=[(0, 0)], end_points=[(3, 6)], cardinal=70, diagonal=99)
1428
+ array([], shape=(0, 2), dtype=int...)
1429
+ >>> tcod.path.path2d(cost, start_points=[(0, 0), (3, 0)], end_points=[(0, 6), (3, 6)], cardinal=70, diagonal=99)
1430
+ array([], shape=(0, 2), dtype=int...)
1431
+ >>> tcod.path.path2d(cost, start_points=[], end_points=[], cardinal=70, diagonal=99)
1432
+ array([], shape=(0, 2), dtype=int...)
1433
+
1434
+ # Overlapping endpoints return a single step
1435
+ >>> tcod.path.path2d(cost, start_points=[(0, 0)], end_points=[(0, 0)], cardinal=70, diagonal=99)
1436
+ array([[0, 0]], dtype=int32)
1437
+
1438
+ # Multiple endpoints return the shortest path
1439
+ >>> tcod.path.path2d(
1440
+ ... cost, start_points=[(0, 0)], end_points=[(1, 3), (3, 3), (2, 2), (2, 4)], cardinal=70, diagonal=99)
1441
+ array([[0, 0],
1442
+ [1, 0],
1443
+ [2, 0],
1444
+ [3, 1],
1445
+ [2, 2]], dtype=int...)
1446
+ >>> tcod.path.path2d(
1447
+ ... cost, start_points=[(0, 0), (0, 2)], end_points=[(1, 3), (3, 3), (2, 2), (2, 4)], cardinal=70, diagonal=99)
1448
+ array([[0, 2],
1449
+ [1, 3]], dtype=int...)
1450
+ >>> tcod.path.path2d(cost, start_points=[(0, 0), (0, 2)], end_points=[(3, 2)], cardinal=1)
1451
+ array([[0, 2],
1452
+ [1, 2],
1453
+ [2, 2],
1454
+ [3, 2]], dtype=int...)
1455
+
1456
+ # Checking for out-of-bounds points may be toggled
1457
+ >>> tcod.path.path2d(cost, start_points=[(0, 0)], end_points=[(-1, -1), (3, 1)], cardinal=1)
1458
+ Traceback (most recent call last):
1459
+ ...
1460
+ IndexError: End point (-1, -1) is out-of-bounds of cost shape (4, 7)
1461
+ >>> tcod.path.path2d(cost, start_points=[(0, 0)], end_points=[(-1, -1), (3, 1)], cardinal=1, check_bounds=False)
1462
+ array([[0, 0],
1463
+ [1, 0],
1464
+ [2, 0],
1465
+ [3, 0],
1466
+ [3, 1]], dtype=int...)
1467
+
1468
+ .. versionadded:: 18.1
1469
+ """
1470
+ cost = np.copy(cost) # Copy array to later modify nodes to be always reachable
1471
+
1472
+ # Check bounds of endpoints
1473
+ if check_bounds:
1474
+ for points, name in [(start_points, "start"), (end_points, "end")]:
1475
+ for i, j in points:
1476
+ if not (0 <= i < cost.shape[0] and 0 <= j < cost.shape[1]):
1477
+ msg = f"{name.capitalize()} point {(i, j)!r} is out-of-bounds of cost shape {cost.shape!r}"
1478
+ raise IndexError(msg)
1479
+ else:
1480
+ start_points = [(i, j) for i, j in start_points if 0 <= i < cost.shape[0] and 0 <= j < cost.shape[1]]
1481
+ end_points = [(i, j) for i, j in end_points if 0 <= i < cost.shape[0] and 0 <= j < cost.shape[1]]
1482
+
1483
+ if not start_points or not end_points:
1484
+ return np.zeros((0, 2), dtype=np.intc) # Missing endpoints
1485
+
1486
+ # Check if endpoints can be manipulated to use A* for a one-to-many computation
1487
+ reversed_path = False
1488
+ if len(end_points) == 1 and len(start_points) > 1:
1489
+ # Swap endpoints to ensure single start point as the A* goal
1490
+ reversed_path = True
1491
+ start_points, end_points = end_points, start_points
1492
+
1493
+ for ij in start_points:
1494
+ cost[ij] = 1 # Enforce reachability of endpoint
1495
+
1496
+ graph = SimpleGraph(cost=cost, cardinal=cardinal, diagonal=diagonal or 0)
1497
+ pf = Pathfinder(graph)
1498
+ for ij in end_points:
1499
+ pf.add_root(ij)
1500
+
1501
+ if len(start_points) == 1: # Compute A* from possibly multiple roots to one goal
1502
+ out = pf.path_from(start_points[0])
1503
+ if pf.distance[start_points[0]] == np.iinfo(pf.distance.dtype).max:
1504
+ return np.zeros((0, 2), dtype=np.intc) # Unreachable endpoint
1505
+ if reversed_path:
1506
+ out = out[::-1]
1507
+ return out
1508
+
1509
+ # Crude Dijkstra implementation until issues with Pathfinder are fixed
1510
+ pf.resolve(None)
1511
+ best_distance, best_ij = min((pf.distance[ij], ij) for ij in start_points)
1512
+ if best_distance == np.iinfo(pf.distance.dtype).max:
1513
+ return np.zeros((0, 2), dtype=np.intc) # All endpoints unreachable
1514
+
1515
+ return hillclimb2d(pf.distance, best_ij, cardinal=bool(cardinal), diagonal=bool(diagonal))
@@ -17,5 +17,5 @@ __version__: str
17
17
  __version_tuple__: VERSION_TUPLE
18
18
  version_tuple: VERSION_TUPLE
19
19
 
20
- __version__ = version = '18.0.0'
21
- __version_tuple__ = version_tuple = (18, 0, 0)
20
+ __version__ = version = '18.1.0'
21
+ __version_tuple__ = version_tuple = (18, 1, 0)
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: tcod
3
- Version: 18.0.0
3
+ Version: 18.1.0
4
4
  Summary: The official Python port of libtcod.
5
5
  Author-email: Kyle Benesch <4b796c65+tcod@gmail.com>
6
6
  License: Simplified BSD License
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes