├── .gitattributes
├── .gitignore
├── .idea
├── fileTemplates
│ ├── includes
│ │ └── C File Header.h
│ └── internal
│ │ └── JavaScript File.js
├── libtcod-tutorial.iml
├── libtcod-tutorial.iml___jb_tmp___
├── misc.xml
├── modules.xml
├── vcs.xml
└── workspace.xml
├── CMakeLists.txt
├── README.md
├── cmake-build-debug
├── libtcod-tutorial.cbp
├── libtcod-tutorial.exe.stackdump
├── rl1.cbp
├── rl1.exe.stackdump
└── terminal16x16_gs_ro.png
├── lib
└── libtcod-1.9.0-x86_64-msvc
│ ├── CHANGELOG.md
│ ├── LIBTCOD-CREDITS.txt
│ ├── LIBTCOD-LICENSE.txt
│ ├── README.md
│ ├── data
│ ├── cfg
│ │ └── sample.cfg
│ ├── fonts
│ │ ├── README.txt
│ │ ├── arial10x10.png
│ │ ├── arial12x12.png
│ │ ├── arial8x8.png
│ │ ├── caeldera8x8_gs_tc.png
│ │ ├── celtic_garamond_10x10_gs_tc.png
│ │ ├── consolas10x10_gs_tc.png
│ │ ├── consolas12x12_gs_tc.png
│ │ ├── consolas8x8_gs_tc.png
│ │ ├── consolas_unicode_10x10.png
│ │ ├── consolas_unicode_12x12.png
│ │ ├── consolas_unicode_16x16.png
│ │ ├── consolas_unicode_8x8.png
│ │ ├── courier10x10_aa_tc.png
│ │ ├── courier12x12_aa_tc.png
│ │ ├── courier8x8_aa_tc.png
│ │ ├── dejavu10x10_gs_tc.png
│ │ ├── dejavu12x12_gs_tc.png
│ │ ├── dejavu16x16_gs_tc.png
│ │ ├── dejavu8x8_gs_tc.png
│ │ ├── dejavu_wide12x12_gs_tc.png
│ │ ├── dejavu_wide16x16_gs_tc.png
│ │ ├── dundalk12x12_gs_tc.png
│ │ ├── lucida10x10_gs_tc.png
│ │ ├── lucida12x12_gs_tc.png
│ │ ├── lucida8x8_gs_tc.png
│ │ ├── prestige10x10_gs_tc.png
│ │ ├── prestige12x12_gs_tc.png
│ │ ├── prestige8x8_gs_tc.png
│ │ ├── terminal10x10_gs_tc.png
│ │ ├── terminal10x16_gs_ro.png
│ │ ├── terminal10x16_gs_tc.png
│ │ ├── terminal10x18_gs_ro.png
│ │ ├── terminal12x12_gs_ro.png
│ │ ├── terminal16x16_gs_ro.png
│ │ ├── terminal7x7_gs_tc.png
│ │ ├── terminal8x12_gs_ro.png
│ │ ├── terminal8x12_gs_tc.png
│ │ ├── terminal8x14_gs_ro.png
│ │ ├── terminal8x8_aa_as.png
│ │ ├── terminal8x8_aa_ro.png
│ │ ├── terminal8x8_aa_tc.png
│ │ ├── terminal8x8_gs_as.png
│ │ ├── terminal8x8_gs_ro.png
│ │ └── terminal8x8_gs_tc.png
│ ├── img
│ │ ├── circle.png
│ │ └── skull.png
│ ├── namegen
│ │ ├── README.txt
│ │ ├── jice_celtic.cfg
│ │ ├── jice_fantasy.cfg
│ │ ├── jice_mesopotamian.cfg
│ │ ├── jice_norse.cfg
│ │ ├── jice_region.cfg
│ │ ├── jice_town.cfg
│ │ ├── mingos_demon.cfg
│ │ ├── mingos_dwarf.cfg
│ │ ├── mingos_norse.cfg
│ │ ├── mingos_standard.cfg
│ │ └── mingos_town.cfg
│ └── rexpaint
│ │ └── test.xp
│ ├── include
│ ├── libtcod.h
│ ├── libtcod.hpp
│ └── libtcod
│ │ ├── bresenham.h
│ │ ├── bresenham.hpp
│ │ ├── bsp.h
│ │ ├── bsp.hpp
│ │ ├── color.h
│ │ ├── color.hpp
│ │ ├── color
│ │ ├── canvas.h
│ │ └── color.h
│ │ ├── console.h
│ │ ├── console.hpp
│ │ ├── console
│ │ ├── printing.h
│ │ └── rexpaint.h
│ │ ├── console_types.h
│ │ ├── engine
│ │ ├── backend.h
│ │ ├── display.h
│ │ └── globals.h
│ │ ├── fov.h
│ │ ├── fov.hpp
│ │ ├── fov_types.h
│ │ ├── gui
│ │ ├── button.hpp
│ │ ├── container.hpp
│ │ ├── flatlist.hpp
│ │ ├── gui.hpp
│ │ ├── gui_portability.hpp
│ │ ├── hbox.hpp
│ │ ├── image.hpp
│ │ ├── label.hpp
│ │ ├── radiobutton.hpp
│ │ ├── slider.hpp
│ │ ├── statusbar.hpp
│ │ ├── textbox.hpp
│ │ ├── togglebutton.hpp
│ │ ├── toolbar.hpp
│ │ ├── vbox.hpp
│ │ └── widget.hpp
│ │ ├── heightmap.h
│ │ ├── heightmap.hpp
│ │ ├── image.h
│ │ ├── image.hpp
│ │ ├── lex.h
│ │ ├── lex.hpp
│ │ ├── libtcod.h
│ │ ├── libtcod.hpp
│ │ ├── libtcod_int.h
│ │ ├── list.h
│ │ ├── list.hpp
│ │ ├── mersenne.h
│ │ ├── mersenne.hpp
│ │ ├── mersenne_types.h
│ │ ├── mouse.h
│ │ ├── mouse.hpp
│ │ ├── mouse_types.h
│ │ ├── namegen.h
│ │ ├── namegen.hpp
│ │ ├── noise.h
│ │ ├── noise.hpp
│ │ ├── noise_defaults.h
│ │ ├── parser.h
│ │ ├── parser.hpp
│ │ ├── path.h
│ │ ├── path.hpp
│ │ ├── portability.h
│ │ ├── sdl2
│ │ ├── gl2_display.h
│ │ ├── gl2_ext_.h
│ │ ├── gl2_raii.h
│ │ ├── gl2_renderer.h
│ │ ├── gl_alias.h
│ │ ├── legacy_backend.h
│ │ ├── sdl2_alias.h
│ │ ├── sdl2_display.h
│ │ └── sdl2_renderer.h
│ │ ├── sys.h
│ │ ├── sys.hpp
│ │ ├── tileset
│ │ ├── observer.h
│ │ ├── tile.h
│ │ ├── tileset.h
│ │ └── tilesheet.h
│ │ ├── tree.h
│ │ ├── tree.hpp
│ │ ├── txtfield.h
│ │ ├── txtfield.hpp
│ │ ├── utility.h
│ │ ├── utility
│ │ └── vector2.h
│ │ ├── version.h
│ │ ├── wrappers.h
│ │ ├── zip.h
│ │ └── zip.hpp
│ ├── lua
│ ├── libtcodlua.lua
│ └── samples_lua.lua
│ ├── python
│ ├── MANIFEST.in
│ ├── libtcodpy
│ │ ├── __init__.py
│ │ └── cprotos.py
│ ├── python.pyproj
│ ├── samples_py.py
│ ├── setup.cfg
│ ├── setup.py
│ └── tests
│ │ ├── conftest.py
│ │ └── test_libtcodpy.py
│ ├── samples
│ ├── apfviewer.cpp
│ ├── frost
│ │ └── frost.cpp
│ ├── hmtool
│ │ ├── README.txt
│ │ ├── hmtool.cpp
│ │ ├── operation.cpp
│ │ └── operation.hpp
│ ├── navier
│ │ ├── main.cpp
│ │ └── main.hpp
│ ├── rad
│ │ ├── README.txt
│ │ ├── bsp_helper.cpp
│ │ ├── bsp_helper.hpp
│ │ ├── main.cpp
│ │ ├── rad_shader.cpp
│ │ ├── rad_shader.hpp
│ │ ├── rad_shader_photon.cpp
│ │ ├── rad_shader_standard.cpp
│ │ └── terminal.png
│ ├── ripples
│ │ ├── main.cpp
│ │ ├── main.hpp
│ │ ├── util_ripples.cpp
│ │ └── util_ripples.hpp
│ ├── samples_c.c
│ ├── samples_cpp.cpp
│ ├── weather
│ │ ├── main.cpp
│ │ ├── main.hpp
│ │ ├── util_weather.cpp
│ │ └── util_weather.hpp
│ └── worldgen
│ │ ├── README.txt
│ │ ├── main.cpp
│ │ ├── main.hpp
│ │ ├── terminal.png
│ │ ├── util_worldgen.cpp
│ │ └── util_worldgen.hpp
│ └── terminal.png
└── src
├── components
├── fighter.c
└── fighter.h
├── data
├── enums.h
├── list.c
└── list.h
├── engine.c
├── entity.c
├── entity.h
├── input_handlers.c
├── input_handlers.h
├── map
├── fov.c
├── fov.h
├── game_map.c
├── game_map.h
├── rectangle.c
├── rectangle.h
├── tile.c
└── tile.h
├── render_functions.c
└── render_functions.h
/.gitattributes:
--------------------------------------------------------------------------------
1 | # Auto detect text files and perform LF normalization
2 | * text=auto
3 |
--------------------------------------------------------------------------------
/.gitignore:
--------------------------------------------------------------------------------
1 | # Prerequisites
2 | *.d
3 |
4 | # Object files
5 | *.o
6 | *.ko
7 | *.obj
8 | *.elf
9 |
10 | # Linker output
11 | *.ilk
12 | *.map
13 | *.exp
14 |
15 | # Precompiled Headers
16 | *.gch
17 | *.pch
18 |
19 | # Libraries
20 | *.lib
21 | *.a
22 | *.la
23 | *.lo
24 |
25 | # Shared objects (inc. Windows DLLs)
26 | *.dll
27 | *.so
28 | *.so.*
29 | *.dylib
30 |
31 | # Executables
32 | *.exe
33 | *.out
34 | *.app
35 | *.i*86
36 | *.x86_64
37 | *.hex
38 |
39 | # Debug files
40 | *.dSYM/
41 | *.su
42 | *.idb
43 | *.pdb
44 |
45 | # Kernel Module Compile Results
46 | *.mod*
47 | *.cmd
48 | .tmp_versions/
49 | modules.order
50 | Module.symvers
51 | Mkfile.old
52 | dkms.conf
53 | cmake-build-debug/cmake_install.cmake
54 | cmake-build-debug/CMakeCache.txt
55 | cmake-build-debug/CMakeFiles
56 | cmake-build-debug/Makefile
57 | cmake-build-debug/libtcod_tutorial.cbp
58 | cmake-build-debug/libtcod_tutorial.exe.stackdump
59 |
60 | .idea/workspace.xml
61 |
--------------------------------------------------------------------------------
/.idea/fileTemplates/includes/C File Header.h:
--------------------------------------------------------------------------------
1 | #if ($HEADER_COMMENTS)
2 | //
3 | // Created by Saturnation on ${DATE}.
4 | #if ($ORGANIZATION_NAME && $ORGANIZATION_NAME != "")
5 | // Copyright (c) $YEAR ${ORGANIZATION_NAME}#if (!$ORGANIZATION_NAME.endsWith(".")).#end All rights reserved.
6 | #end
7 | //
8 | #end
9 |
10 |
--------------------------------------------------------------------------------
/.idea/fileTemplates/internal/JavaScript File.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Created by Saturnation on ${DATE}.
3 | */
4 |
--------------------------------------------------------------------------------
/.idea/libtcod-tutorial.iml:
--------------------------------------------------------------------------------
1 |
2 |
--------------------------------------------------------------------------------
/.idea/libtcod-tutorial.iml___jb_tmp___:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/saturnation/libtcod-tutorial/cae06e2b50a3705adad15fee43b5d66eaa08be92/.idea/libtcod-tutorial.iml___jb_tmp___
--------------------------------------------------------------------------------
/.idea/misc.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
--------------------------------------------------------------------------------
/.idea/modules.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
--------------------------------------------------------------------------------
/.idea/vcs.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
--------------------------------------------------------------------------------
/CMakeLists.txt:
--------------------------------------------------------------------------------
1 | cmake_minimum_required(VERSION 3.7)
2 | project(libtcod-tutorial)
3 |
4 | set(CMAKE_C_STANDARD 11)
5 |
6 | include_directories(lib/libtcod-1.9.0-x86_64-msvc/include)
7 |
8 | #https://stackoverflow.com/questions/8774593/cmake-link-to-external-library/41909627#41909627
9 | link_directories(lib/libtcod-1.9.0-x86_64-msvc/)
10 | find_library( LIBTCOD_LIB libtcod )
11 |
12 | set(SOURCE_FILES src/engine.c
13 | src/input_handlers.c
14 | src/input_handlers.h
15 | src/entity.c
16 | src/entity.h
17 | src/render_functions.c
18 | src/render_functions.h
19 | src/map/tile.c
20 | src/map/tile.h
21 | src/map/game_map.c
22 | src/map/game_map.h
23 | src/map/rectangle.c
24 | src/map/rectangle.h
25 | src/map/fov.c
26 | src/map/fov.h
27 | src/data/list.h
28 | src/data/list.c
29 | src/data/enums.h
30 | src/components/fighter.c
31 | src/components/fighter.h)
32 |
33 | add_executable(libtcod-tutorial ${SOURCE_FILES})
34 | target_link_libraries(libtcod-tutorial libtcod)
35 |
--------------------------------------------------------------------------------
/README.md:
--------------------------------------------------------------------------------
1 | # libtcod-tutorial
2 | A C implementation of the code from the Python libtcod tutorial from http://www.rogueliketutorials.com/
3 |
4 | This implemenation is Windows based, but only in that it includes the Window's libtcod. Hopefully you can just delete that and drop in your OS'es libtcod and it should still work with cmake?
5 |
--------------------------------------------------------------------------------
/cmake-build-debug/libtcod-tutorial.exe.stackdump:
--------------------------------------------------------------------------------
1 | Exception: STATUS_ACCESS_VIOLATION at rip=0010040204D
2 | rax=0000000000000000 rbx=00000000FFFFCA70 rcx=00002BA9E8AE55A1
3 | rdx=0000000000000002 rsi=000000000000001E rdi=0000000000000000
4 | r8 =0000000004CA09F0 r9 =0000000004CA0A24 r10=0000000100000000
5 | r11=00000001004024A7 r12=0000000000000000 r13=0000000000000000
6 | r14=0000000000000000 r15=0000000000000000
7 | rbp=00000000FFFFC840 rsp=00000000FFFFC7C0
8 | program=E:\code\c\libtcod-tutorial\cmake-build-debug\libtcod-tutorial.exe, pid 10652, thread main
9 | cs=0033 ds=002B es=002B fs=0053 gs=002B ss=002B
10 | Stack trace:
11 | Frame Function Args
12 | 000FFFFC840 0010040204D (00600003270, 00600000340, 00000000003, 02300000013)
13 | 000FFFFCAF0 001004024C4 (0010000001E, 00000000006, 0010000000A, 00100000050)
14 | 000FFFFCB90 001004012F9 (00000000020, FF0700010302FF00, 00180049DAA, 00000310000)
15 | 000FFFFCCD0 00180049E16 (00000000000, 00000000000, 00000000000, 00000000000)
16 | 00000000000 00180047973 (00000000000, 00000000000, 00000000000, 00000000000)
17 | 000FFFFFFF0 00180047A24 (00000000000, 00000000000, 00000000000, 00000000000)
18 | End of stack trace
19 |
--------------------------------------------------------------------------------
/cmake-build-debug/rl1.exe.stackdump:
--------------------------------------------------------------------------------
1 | Stack trace:
2 | Frame Function Args
3 | 000FFFFCBA0 0018005F64E (0018023C500, 0018022E0D9, 00000000000, 000FFFFBB20)
4 | 000FFFFCBA0 00180048869 (00100000050, 00600000032, 000FFFFCB8C, 00000000003)
5 | 000FFFFCBA0 001800488A2 (006000233F0, 000FFFF9000, 00000000000, 02000000000)
6 | 000FFFFCBA0 0018005CD8A (03200000050, 00100000050, 00000000000, 000FFFFCCD0)
7 | 000FFFFCBA0 0060000001E (00100000050, 00000000000, 000FFFFCCD0, 00180049E16)
8 | 000FFFFCBA0 02D0000000A (00000000000, 000FFFFCCD0, 00180049E16, 00000000000)
9 | 000FFFFCBA0 03200000050 (000FFFFCCD0, 00180049E16, 00000000000, 00000000020)
10 | 000FFFFCBA0 00100000050 (000FFFFCCD0, 00180049E16, 00000000000, 00000000020)
11 | End of stack trace
12 |
--------------------------------------------------------------------------------
/cmake-build-debug/terminal16x16_gs_ro.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/saturnation/libtcod-tutorial/cae06e2b50a3705adad15fee43b5d66eaa08be92/cmake-build-debug/terminal16x16_gs_ro.png
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/LIBTCOD-CREDITS.txt:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/saturnation/libtcod-tutorial/cae06e2b50a3705adad15fee43b5d66eaa08be92/lib/libtcod-1.9.0-x86_64-msvc/LIBTCOD-CREDITS.txt
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/LIBTCOD-LICENSE.txt:
--------------------------------------------------------------------------------
1 | /* libtcod
2 | * Copyright © 2008-2018 Jice and the libtcod contributers.
3 | * All rights reserved.
4 | *
5 | * libtcod 'The Doryen library' is a cross-platform C/C++ library for roguelike
6 | * developers.
7 | * Its source code is available from:
8 | * https://github.com/libtcod/libtcod
9 | *
10 | * Redistribution and use in source and binary forms, with or without
11 | * modification, are permitted provided that the following conditions are met:
12 | * * Redistributions of source code must retain the above copyright
13 | * notice, this list of conditions and the following disclaimer.
14 | * * Redistributions in binary form must reproduce the above copyright
15 | * notice, this list of conditions and the following disclaimer in the
16 | * documentation and/or other materials provided with the distribution.
17 | * * The name of copyright holder nor the names of its contributors may not
18 | * be used to endorse or promote products derived from this software
19 | * without specific prior written permission.
20 | *
21 | * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
22 | * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
23 | * TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
24 | * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
25 | * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
26 | * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
27 | * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
28 | * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
29 | * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
30 | * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
31 | * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
32 | */
33 |
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/data/cfg/sample.cfg:
--------------------------------------------------------------------------------
1 | myStruct "struct_name" {
2 | //
3 | bool_field=true
4 | char_field='Z'
5 | int_field=24
6 | float_field=3.14
7 | string_field="hello"
8 | color_field="255,128,128"
9 | dice_field="0.5x3d5+2"
10 |
11 | // dynamically declared fields
12 | bool bool_field2=false
13 | char char_field2='@'
14 | int int_field2=4
15 | float float_field2=4.3
16 | string string_field2="world"
17 | color color_field2=#FF22CC
18 | dice dice_field2="3d20"
19 |
20 | bool_list=[true, false, true]
21 | char_list=['a', 'b', 'z']
22 | integer_list=[13,2,-3]
23 | float_list=[5.0,2.0,-3.5]
24 | string_list=["item one","time_two"]
25 | color_list=["42,42,142","128,64,128"]
26 | // dice_list=["3d4","2d4+2","0.75x4d6-1"]
27 |
28 | // dynamically declared list fields
29 | bool[] bool_list2=[true, false, true]
30 | char[] char_list2=['a', 'b', 'z']
31 | int[] integer_list2=[13,2,-3]
32 | float[] float_list2=[5.0,2.0,-3.5]
33 | string[] string_list2=["item one","time_two"]
34 | color[] color_list2=["42,42,142","128,64,128"]
35 |
36 | }
37 | // a completely dynamic structure (not declared at compile time)
38 | struct dynStruct {
39 | int someVar=4
40 | struct subStruct {
41 | float anotherVar=4.3
42 | }
43 | }
44 |
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/data/fonts/README.txt:
--------------------------------------------------------------------------------
1 | This directory contains antialiased fonts for libtcod.
2 | These fonts are in public domain.
3 |
4 | The file names are composed with :
5 | __.png
6 | : aa 32 bits png with alpha channel
7 | gs 24 bits or greyscale PNG
8 | : as standard ASCII layout
9 | ro standard ASCII layout in row
10 | tc TCOD layout
11 |
12 | The terminal8x8 font is provided is every possible format as en example.
13 | You can try them with the provided samples :
14 |
15 | ./samples_c -font fonts/terminal8x8_aa_as.png -font-nb-char 16 16
16 | ./samples_c -font fonts/terminal8x8_aa_ro.png -font-nb-char 16 16 -font-in-row
17 | ./samples_c -font fonts/terminal8x8_aa_tc.png -font-nb-char 32 8 -font-tcod
18 | ./samples_c -font fonts/terminal8x8_gs_as.png -font-nb-char 16 16 -font-greyscale
19 | ./samples_c -font fonts/terminal8x8_gs_ro.png -font-nb-char 16 16 -font-greyscale -font-in-row
20 | ./samples_c -font fonts/terminal8x8_gs_tc.png -font-nb-char 32 8 -font-greyscale -font-tcod
21 |
22 | The libtcod 1.3.2 (non antialiased) terminal font is still there and still works :
23 | ./samples_c -font terminal.png -font-nb-char 16 16
24 |
25 | All other fonts are provided only in gs_tc format (greyscale, TCOD layout).
26 | To try them :
27 |
28 | Terminal fonts with different size (you can use them as template to create new fonts) :
29 | ./samples_c -font fonts/terminal7x7_gs_tc.png -font-nb-char 32 8 -font-greyscale -font-tcod
30 | ./samples_c -font fonts/terminal10x10_gs_tc.png -font-nb-char 32 8 -font-greyscale -font-tcod
31 |
32 | Custom fonts :
33 | ./samples_c -font fonts/caeldera8x8_gs_tc.png -font-nb-char 32 8 -font-greyscale -font-tcod
34 | ./samples_c -font fonts/lucida8x8_gs_tc.png -font-nb-char 32 8 -font-greyscale -font-tcod
35 | ./samples_c -font fonts/celtic_garamond_10x10_gs_tc.png -font-nb-char 32 8 -font-greyscale -font-tcod
36 | ./samples_c -font fonts/dundalk12x12_gs_tc.png -font-nb-char 32 8 -font-greyscale -font-tcod
37 |
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/data/fonts/arial10x10.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/saturnation/libtcod-tutorial/cae06e2b50a3705adad15fee43b5d66eaa08be92/lib/libtcod-1.9.0-x86_64-msvc/data/fonts/arial10x10.png
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/data/fonts/arial12x12.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/saturnation/libtcod-tutorial/cae06e2b50a3705adad15fee43b5d66eaa08be92/lib/libtcod-1.9.0-x86_64-msvc/data/fonts/arial12x12.png
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/data/fonts/arial8x8.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/saturnation/libtcod-tutorial/cae06e2b50a3705adad15fee43b5d66eaa08be92/lib/libtcod-1.9.0-x86_64-msvc/data/fonts/arial8x8.png
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/data/fonts/caeldera8x8_gs_tc.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/saturnation/libtcod-tutorial/cae06e2b50a3705adad15fee43b5d66eaa08be92/lib/libtcod-1.9.0-x86_64-msvc/data/fonts/caeldera8x8_gs_tc.png
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/data/fonts/celtic_garamond_10x10_gs_tc.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/saturnation/libtcod-tutorial/cae06e2b50a3705adad15fee43b5d66eaa08be92/lib/libtcod-1.9.0-x86_64-msvc/data/fonts/celtic_garamond_10x10_gs_tc.png
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/data/fonts/consolas10x10_gs_tc.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/saturnation/libtcod-tutorial/cae06e2b50a3705adad15fee43b5d66eaa08be92/lib/libtcod-1.9.0-x86_64-msvc/data/fonts/consolas10x10_gs_tc.png
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/data/fonts/consolas12x12_gs_tc.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/saturnation/libtcod-tutorial/cae06e2b50a3705adad15fee43b5d66eaa08be92/lib/libtcod-1.9.0-x86_64-msvc/data/fonts/consolas12x12_gs_tc.png
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/data/fonts/consolas8x8_gs_tc.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/saturnation/libtcod-tutorial/cae06e2b50a3705adad15fee43b5d66eaa08be92/lib/libtcod-1.9.0-x86_64-msvc/data/fonts/consolas8x8_gs_tc.png
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/data/fonts/consolas_unicode_10x10.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/saturnation/libtcod-tutorial/cae06e2b50a3705adad15fee43b5d66eaa08be92/lib/libtcod-1.9.0-x86_64-msvc/data/fonts/consolas_unicode_10x10.png
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/data/fonts/consolas_unicode_12x12.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/saturnation/libtcod-tutorial/cae06e2b50a3705adad15fee43b5d66eaa08be92/lib/libtcod-1.9.0-x86_64-msvc/data/fonts/consolas_unicode_12x12.png
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/data/fonts/consolas_unicode_16x16.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/saturnation/libtcod-tutorial/cae06e2b50a3705adad15fee43b5d66eaa08be92/lib/libtcod-1.9.0-x86_64-msvc/data/fonts/consolas_unicode_16x16.png
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/data/fonts/consolas_unicode_8x8.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/saturnation/libtcod-tutorial/cae06e2b50a3705adad15fee43b5d66eaa08be92/lib/libtcod-1.9.0-x86_64-msvc/data/fonts/consolas_unicode_8x8.png
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/data/fonts/courier10x10_aa_tc.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/saturnation/libtcod-tutorial/cae06e2b50a3705adad15fee43b5d66eaa08be92/lib/libtcod-1.9.0-x86_64-msvc/data/fonts/courier10x10_aa_tc.png
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/data/fonts/courier12x12_aa_tc.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/saturnation/libtcod-tutorial/cae06e2b50a3705adad15fee43b5d66eaa08be92/lib/libtcod-1.9.0-x86_64-msvc/data/fonts/courier12x12_aa_tc.png
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/data/fonts/courier8x8_aa_tc.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/saturnation/libtcod-tutorial/cae06e2b50a3705adad15fee43b5d66eaa08be92/lib/libtcod-1.9.0-x86_64-msvc/data/fonts/courier8x8_aa_tc.png
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/data/fonts/dejavu10x10_gs_tc.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/saturnation/libtcod-tutorial/cae06e2b50a3705adad15fee43b5d66eaa08be92/lib/libtcod-1.9.0-x86_64-msvc/data/fonts/dejavu10x10_gs_tc.png
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/data/fonts/dejavu12x12_gs_tc.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/saturnation/libtcod-tutorial/cae06e2b50a3705adad15fee43b5d66eaa08be92/lib/libtcod-1.9.0-x86_64-msvc/data/fonts/dejavu12x12_gs_tc.png
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/data/fonts/dejavu16x16_gs_tc.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/saturnation/libtcod-tutorial/cae06e2b50a3705adad15fee43b5d66eaa08be92/lib/libtcod-1.9.0-x86_64-msvc/data/fonts/dejavu16x16_gs_tc.png
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/data/fonts/dejavu8x8_gs_tc.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/saturnation/libtcod-tutorial/cae06e2b50a3705adad15fee43b5d66eaa08be92/lib/libtcod-1.9.0-x86_64-msvc/data/fonts/dejavu8x8_gs_tc.png
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/data/fonts/dejavu_wide12x12_gs_tc.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/saturnation/libtcod-tutorial/cae06e2b50a3705adad15fee43b5d66eaa08be92/lib/libtcod-1.9.0-x86_64-msvc/data/fonts/dejavu_wide12x12_gs_tc.png
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/data/fonts/dejavu_wide16x16_gs_tc.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/saturnation/libtcod-tutorial/cae06e2b50a3705adad15fee43b5d66eaa08be92/lib/libtcod-1.9.0-x86_64-msvc/data/fonts/dejavu_wide16x16_gs_tc.png
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/data/fonts/dundalk12x12_gs_tc.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/saturnation/libtcod-tutorial/cae06e2b50a3705adad15fee43b5d66eaa08be92/lib/libtcod-1.9.0-x86_64-msvc/data/fonts/dundalk12x12_gs_tc.png
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/data/fonts/lucida10x10_gs_tc.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/saturnation/libtcod-tutorial/cae06e2b50a3705adad15fee43b5d66eaa08be92/lib/libtcod-1.9.0-x86_64-msvc/data/fonts/lucida10x10_gs_tc.png
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/data/fonts/lucida12x12_gs_tc.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/saturnation/libtcod-tutorial/cae06e2b50a3705adad15fee43b5d66eaa08be92/lib/libtcod-1.9.0-x86_64-msvc/data/fonts/lucida12x12_gs_tc.png
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/data/fonts/lucida8x8_gs_tc.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/saturnation/libtcod-tutorial/cae06e2b50a3705adad15fee43b5d66eaa08be92/lib/libtcod-1.9.0-x86_64-msvc/data/fonts/lucida8x8_gs_tc.png
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/data/fonts/prestige10x10_gs_tc.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/saturnation/libtcod-tutorial/cae06e2b50a3705adad15fee43b5d66eaa08be92/lib/libtcod-1.9.0-x86_64-msvc/data/fonts/prestige10x10_gs_tc.png
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/data/fonts/prestige12x12_gs_tc.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/saturnation/libtcod-tutorial/cae06e2b50a3705adad15fee43b5d66eaa08be92/lib/libtcod-1.9.0-x86_64-msvc/data/fonts/prestige12x12_gs_tc.png
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/data/fonts/prestige8x8_gs_tc.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/saturnation/libtcod-tutorial/cae06e2b50a3705adad15fee43b5d66eaa08be92/lib/libtcod-1.9.0-x86_64-msvc/data/fonts/prestige8x8_gs_tc.png
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/data/fonts/terminal10x10_gs_tc.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/saturnation/libtcod-tutorial/cae06e2b50a3705adad15fee43b5d66eaa08be92/lib/libtcod-1.9.0-x86_64-msvc/data/fonts/terminal10x10_gs_tc.png
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/data/fonts/terminal10x16_gs_ro.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/saturnation/libtcod-tutorial/cae06e2b50a3705adad15fee43b5d66eaa08be92/lib/libtcod-1.9.0-x86_64-msvc/data/fonts/terminal10x16_gs_ro.png
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/data/fonts/terminal10x16_gs_tc.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/saturnation/libtcod-tutorial/cae06e2b50a3705adad15fee43b5d66eaa08be92/lib/libtcod-1.9.0-x86_64-msvc/data/fonts/terminal10x16_gs_tc.png
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/data/fonts/terminal10x18_gs_ro.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/saturnation/libtcod-tutorial/cae06e2b50a3705adad15fee43b5d66eaa08be92/lib/libtcod-1.9.0-x86_64-msvc/data/fonts/terminal10x18_gs_ro.png
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/data/fonts/terminal12x12_gs_ro.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/saturnation/libtcod-tutorial/cae06e2b50a3705adad15fee43b5d66eaa08be92/lib/libtcod-1.9.0-x86_64-msvc/data/fonts/terminal12x12_gs_ro.png
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/data/fonts/terminal16x16_gs_ro.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/saturnation/libtcod-tutorial/cae06e2b50a3705adad15fee43b5d66eaa08be92/lib/libtcod-1.9.0-x86_64-msvc/data/fonts/terminal16x16_gs_ro.png
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/data/fonts/terminal7x7_gs_tc.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/saturnation/libtcod-tutorial/cae06e2b50a3705adad15fee43b5d66eaa08be92/lib/libtcod-1.9.0-x86_64-msvc/data/fonts/terminal7x7_gs_tc.png
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/data/fonts/terminal8x12_gs_ro.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/saturnation/libtcod-tutorial/cae06e2b50a3705adad15fee43b5d66eaa08be92/lib/libtcod-1.9.0-x86_64-msvc/data/fonts/terminal8x12_gs_ro.png
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/data/fonts/terminal8x12_gs_tc.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/saturnation/libtcod-tutorial/cae06e2b50a3705adad15fee43b5d66eaa08be92/lib/libtcod-1.9.0-x86_64-msvc/data/fonts/terminal8x12_gs_tc.png
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/data/fonts/terminal8x14_gs_ro.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/saturnation/libtcod-tutorial/cae06e2b50a3705adad15fee43b5d66eaa08be92/lib/libtcod-1.9.0-x86_64-msvc/data/fonts/terminal8x14_gs_ro.png
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/data/fonts/terminal8x8_aa_as.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/saturnation/libtcod-tutorial/cae06e2b50a3705adad15fee43b5d66eaa08be92/lib/libtcod-1.9.0-x86_64-msvc/data/fonts/terminal8x8_aa_as.png
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/data/fonts/terminal8x8_aa_ro.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/saturnation/libtcod-tutorial/cae06e2b50a3705adad15fee43b5d66eaa08be92/lib/libtcod-1.9.0-x86_64-msvc/data/fonts/terminal8x8_aa_ro.png
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/data/fonts/terminal8x8_aa_tc.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/saturnation/libtcod-tutorial/cae06e2b50a3705adad15fee43b5d66eaa08be92/lib/libtcod-1.9.0-x86_64-msvc/data/fonts/terminal8x8_aa_tc.png
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/data/fonts/terminal8x8_gs_as.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/saturnation/libtcod-tutorial/cae06e2b50a3705adad15fee43b5d66eaa08be92/lib/libtcod-1.9.0-x86_64-msvc/data/fonts/terminal8x8_gs_as.png
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/data/fonts/terminal8x8_gs_ro.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/saturnation/libtcod-tutorial/cae06e2b50a3705adad15fee43b5d66eaa08be92/lib/libtcod-1.9.0-x86_64-msvc/data/fonts/terminal8x8_gs_ro.png
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/data/fonts/terminal8x8_gs_tc.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/saturnation/libtcod-tutorial/cae06e2b50a3705adad15fee43b5d66eaa08be92/lib/libtcod-1.9.0-x86_64-msvc/data/fonts/terminal8x8_gs_tc.png
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/data/img/circle.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/saturnation/libtcod-tutorial/cae06e2b50a3705adad15fee43b5d66eaa08be92/lib/libtcod-1.9.0-x86_64-msvc/data/img/circle.png
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/data/img/skull.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/saturnation/libtcod-tutorial/cae06e2b50a3705adad15fee43b5d66eaa08be92/lib/libtcod-1.9.0-x86_64-msvc/data/img/skull.png
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/data/namegen/jice_celtic.cfg:
--------------------------------------------------------------------------------
1 | //Celtic names from Jice's "The Cave"
2 | name "Celtic male" {
3 | syllablesStart = "Aen, Agno, All, Ba, Beo, Brig, Ci, Cre, Dan, Del, Ela, Eo, En, Er, Et, In, Io, Morr, Nem, Nu, Og, Or, Ta"
4 | syllablesMiddle = "a, ar, ba, bo, ch, d, ig"
5 | syllablesEnd = "aid, ain, an, and, th, ed, eth, gus, lam, lor, man, od, t, thach"
6 | rules = "$s$m$e, $s$e"
7 | }
8 |
9 | name "Celtic female" {
10 | syllablesStart = "Aen, Agno, All, Ba, Beo, Brig, Ci, Cre, Dan, Del, Ela, Eo, En, Er, Et, In, Io, Morr, Nem, Nu, Og, Or, Ta"
11 | syllablesMiddle = "a, ar, ba, bo, ch, d, ig"
12 | syllablesEnd = "ai, an, da, id, iu, ma, me, na, ne, tha"
13 | rules = "$s$m$e, $s$e"
14 | }
15 |
16 |
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/data/namegen/jice_fantasy.cfg:
--------------------------------------------------------------------------------
1 | //Fantasy names from Jice's "The Cave"
2 | name "Fantasy male" {
3 | syllablesStart = "Aer, An, Ar, Ban, Bar, Ber, Beth, Bett, Cut, Dan, Dar, Dell, Der, Edr, Er, Eth, Ett, Fin, Ian, Iarr, Ill, Jed, Kan, Kar, Ker, Kurr, Kyr, Man, Mar, Mer, Mir, Tsal, Tser, Tsir, Van, Var, Yur, Yyr"
4 | syllablesMiddle = "al, an, ar, el, en, ess, ian, onn, or"
5 | syllablesEnd = "ai, an, ar, ath, en, eo, ian, is, u, or"
6 | illegal = "orar, arrar"
7 | rules = "$s$m$e, $s$e"
8 | }
9 |
10 | name "Fantasy female" {
11 | syllablesStart = "Aer, An, Ar, Ban, Bar, Ber, Beth, Bett, Cut, Dan, Dar, Dell, Der, Edr, Er, Eth, Ett, Fin, Ian, Iarr, Ill, Jed, Kan, Kar, Ker, Kurr, Kyr, Man, Mar, Mer, Mir, Tsal, Tser, Tsir, Van, Var, Yur, Yyr"
12 | syllablesMiddle = "al, an, ar, el, en, ess, ian, onn, or"
13 | syllablesEnd = "a, ae, aelle, ai, ea, i, ia, u, wen, wyn"
14 | illegal = "arrar"
15 | rules = "$s$m$e, $s$e"
16 | }
17 |
18 |
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/data/namegen/jice_mesopotamian.cfg:
--------------------------------------------------------------------------------
1 | //Mesopotamian names from Jice's "The Cave"
2 | name "Mesopotamian male" {
3 | syllablesStart = "A, Ann, Ash, E', En, Er, Gil, In, Ir, Ish, Mar, Ni, Nin, Re, Ti, Ur"
4 | syllablesMiddle = "am, an, du, esh, gam, gir, ka, ki, li, un, ur, ta"
5 | syllablesEnd = "aki, al, ar, at, du, eph, esh, il, im, ki, nu, uk, ur, uz"
6 | illegal = "aa, e'e"
7 | rules = "$s$m$e, $s$e"
8 | }
9 |
10 | name "Mesopotamian female" {
11 | syllablesStart = "A, Ann, Ash, E', En, Er, Gil, In, Ir, Ish, Mar, Ni, Nin, Re, Ti, Ur"
12 | syllablesMiddle = "am, an, du, esh, gam, gir, ka, ki, li, un, ur, ta"
13 | syllablesEnd = "ag, il, la, na, sag, su, ta"
14 | illegal = "aa, e'e"
15 | rules = "$s$m$e, $s$e"
16 | }
17 |
18 |
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/data/namegen/jice_norse.cfg:
--------------------------------------------------------------------------------
1 | //Norse names from Jice's "The Cave"
2 | name "Norse male" {
3 | syllablesStart = "Al, Ae, As, Bi, Fen, Ha, Hag, Ho, Hu, Iv, Jot, Ma, Mio, Mu, Nid, Ors, Ra, Sta, Svar, Tys, Vae, Van, Vol, Y, Ygg"
4 | syllablesMiddle = "an, ar, ba, da, dra, gar, na, tal"
5 | syllablesEnd = "ad, ald, agr, ar, ard, eyr, far, frost, heim, hogg, in, mir, nar, nir, or, osk, rir, sil, sir, ttir, urd"
6 | illegal = "yor, yar, yad, yin"
7 | rules = "$s$m$e, $s$e"
8 | }
9 |
10 | name "Norse female" {
11 | syllablesStart = "Al, Ae, As, Bi, Fen, Ha, Hag, Ho, Hu, Iv, Jot, Ma, Mio, Mu, Nid, Ors, Ra, Sta, Svar, Tys, Vae, Van, Vol, Y, Ygg"
12 | syllablesMiddle = "an, ar, ba, da, dra, gar, na, tal"
13 | syllablesEnd = "a, la, li, va"
14 | illegal = "raa, ya, aea, aea"
15 | rules = "$s$m$e, $s$e"
16 | }
17 |
18 |
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/data/namegen/jice_region.cfg:
--------------------------------------------------------------------------------
1 | //Region names from Jice's "The Cave"
2 | name "region" {
3 | syllablesStart = "Act, Afr, Ag, Agr, Alb, Am, An, Angl, Ant, As, Asys, Asis, At, Atl, Brund, Cath, Cor, Dan, Eb, Eg, Er, Esc, Esp, Est, Eth, Eur, Flor, It, Lyr, Mal, Mir, Myr, Nor, Pel, Rom, Seg, Sib, Sylv, Terr, Tir, Tr, Tyr, Xan"
4 | syllablesMiddle = "ad, ag, al, an, and, ant, anth, ar, ard, as, at, atr, eg, en, ent, ern, et, ian, in, itr, on, op, ov, ur, ymn, yr"
5 | syllablesEnd = "a, aia, ana, as, ea, ene, eos, esia, ia, iad, ias, is, ium, ius, on, ona, or, ova, um, us, ya"
6 | rules = "$s$m$e, $s$e"
7 | }
8 |
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/data/namegen/jice_town.cfg:
--------------------------------------------------------------------------------
1 | //Town names from Jice's "The Cave"
2 | name "town" {
3 | syllablesStart = "Ael, Ash, Barrow, Bel, Black, Clear, Cold, Crystal, Deep, Edge, Falcon, Fair, Fall, Glass, Gold, Ice, Iron, Mill, Moon, Mor, Ray, Red, Rock, Rose, Shadow, Silver, Spell, Spring, Stone, Strong, Summer, Swyn, Wester, Winter"
4 | syllablesEnd = "ash, burn, barrow, bridge, castle, cliff, coast, crest, dale, dell, dor, fall, field, ford, fort, gate, haven, hill, hold, hollow, iron, lake, marsh, mill, mist, mount, moor, pond, shade, shore, summer, town, wick"
5 | rules = "$s$e"
6 | }
7 |
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/data/namegen/mingos_demon.cfg:
--------------------------------------------------------------------------------
1 | //Demon names
2 | name "demon male" {
3 | phonemesVocals = "a, e, i, o, u"
4 | syllablesStart = "Aam, Ab, Ad, Ahr, Alas, Al-A'w, All, Al-M, Ap, As, Ast, Az, Bal, Bal S, Bag, Balb, Ban, Bansh, Baph, Barb, Bath, Bazt, Be'L, Beel, Beelz, Bel, Belph, Ber, Bh, Bifr, Biul, Bush, Caac, Cagn, Caim, Chalk, Char, Chem, Coal, Dag, Dant, Decer, Demog, Dev, Dj, Dragh, Elig, Emp, Errt, Etr, Ett, Eur, Euryn, Gorg, Graph, Grig, Haag, Halph, Haur, Hoeth, Ifr, Inc, Ibl, Ith, Kabh, Kas, Kokb', Kray, Lab, Lam, Lech, Leg, Lil, Lioth, Lix, Luc, Mal, Malph, Mamm, March, Mast, Math, Meph, Merm, Mol, Murm, Naam, Naph, Nek, Neph, Neq, Nix, Noud, Onom, Onos, Orc, Orob, Oul, Paim, Phen, Pont, Proc, Rah, Rak, Raksh, Ram, Rang, Raum, Raz, Rimm, Rub, Rus, Sabn, Salps, Sam, Sat, Sc, Scarm, Seer, Sem, Set, Shait, Shax, Shed, Shez, Sidr, Sitr, Sth, Succ, Surg, Tann, Tart, Tch, Teer, Thamm, Thub, Tlal, Tsab, Val, Vap, Vass, Vep, Verr, Vin, Vol, Vual, Xaph, Xiph, Xitr, Zaeb, Zim, Ziz, Zaln"
5 | syllablesMiddle = "b'ae, ba, be, chi, dra, du, ga, ghi, go, lia, ma, mba, mu, n'e, na, nti, nzu, phe, pho, r'e, rba, rgo, ssa, thi, tryu, ttu, tzi, v-e, vna, xra, ya"
6 | syllablesEnd = "b'ael, bel, bub, bur, bus, ces, chus, dai, ddon, des, dhaka, el, fer, flas, gion, gon, gor, klet, kor, ksha, kuth, laas, lech, les, lion, lith, loch, lsu, mael, math, mejes, meus, mon, moth, mmut, mosh, nai, nar, neus, nex, nias, nnin, nomos, phas, r'el, raal, rept, res, rgon, riax, rith, rius, rous, rus, ruth, sias, stor, swath, tath, than, the, thra, tryus, tura, vart, ztuk"
7 | rules = "$s$v$35m$10m$e"
8 | }
9 |
10 | name "demon female" {
11 | phonemesVocals = "a, e, i, o, u"
12 | syllablesStart = "Aam, Ab, Ad, Ahr, Alas, Al-A'w, All, Al-M, Ap, As, Ast, Az, Bal, Bal S, Bag, Balb, Ban, Bansh, Baph, Barb, Bath, Bazt, Be'L, Beel, Beelz, Bel, Belph, Ber, Bh, Bifr, Biul, Bush, Caac, Cagn, Caim, Chalk, Char, Chem, Coal, Dag, Dant, Decer, Demog, Dev, Dj, Dragh, Elig, Emp, Errt, Etr, Ett, Eur, Euryn, Gorg, Graph, Grig, Haag, Halph, Haur, Hoeth, Ifr, Inc, Ibl, Ith, Kabh, Kas, Kokb', Kray, Lab, Lam, Lech, Leg, Lil, Lioth, Lix, Luc, Mal, Malph, Mamm, March, Mast, Math, Meph, Merm, Mol, Murm, Naam, Naph, Nek, Neph, Neq, Nix, Noud, Onom, Onos, Orc, Orob, Oul, Paim, Phen, Pont, Proc, Rah, Rak, Raksh, Ram, Rang, Raum, Raz, Rimm, Rub, Rus, Sabn, Salps, Sam, Sat, Sc, Scarm, Seer, Sem, Set, Shait, Shax, Shed, Shez, Sidr, Sitr, Sth, Succ, Surg, Tann, Tart, Tch, Teer, Thamm, Thub, Tlal, Tsab, Val, Vap, Vass, Vep, Verr, Vin, Vol, Vual, Xaph, Xiph, Xitr, Zaeb, Zim, Ziz, Zaln"
13 | syllablesMiddle = "b'ae, ba, be, chi, dra, du, ga, ghi, go, lia, ma, mba, mu, n'e, na, nti, nzu, phe, pho, r'e, rba, rgo, ssa, thi, tryu, ttu, tzi, v-e, vna, xra, ya"
14 | syllablesEnd = "b'a, bel, bua, bure, buth, cess, chia, dai, ddea, dea, dhaka, el, fea, fla, gia, goa, gora, klath, kore, ksha, kua, laal, lexa, less, lia, lith, loth, lsa, mara, math, maja, mea, moa, moth, mmuth, mosh, na, nai, neuth, nex, nia, nnine, nomoa, pha, r'el, raala, repte, reshe, rgona, riaxe, rith, rish, rothe, rushe, ruth, sia, stora, swath, tath, thann, the, thra, trya, tura, varte, ztura"
15 | rules = "$s$v$35m$10m$e"
16 | }
17 |
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/data/namegen/mingos_dwarf.cfg:
--------------------------------------------------------------------------------
1 | //dwarf names
2 | name "dwarf male" {
3 | syllablesStart = "A, An, Ba, Bi, Bo, Bom, Da, Dar, De, Do, Du, Due, Duer, Dwa, Fa, Fal, Fi, Fre, Fun, Ga, Gar, Gim, Glo, Go, Gom, Gro, Gwar, Ib, Jor, Ka, Ki, Kil, Lo, Mar, Na, Nal, O, Ras, Ren, Ro, Ta, Tar, Tel, Thi, Tho, Thon, Thra, Tor, Von, We, Wer, Yen, Yur"
4 | syllablesEnd = "bil, bin, bur, char, den, dir, dur, fri, fur, in, li, lin, mil, mur, ni, nur, ran, ri, ril, rimm, rin, thur, tri, ulf, un, ur, vi, vil, vim, vin, vri"
5 | rules = "$s$e"
6 | illegal = "rur, ueu"
7 | }
8 |
9 | name "dwarf female" {
10 | syllablesStart = "A, An, Ba, Bi, Bo, Bom, Da, Dar, De, Do, Du, Due, Duer, Dwa, Fa, Fal, Fi, Fre, Fun, Ga, Gar, Gim, Glo, Go, Gom, Gro, Gwar, Ib, Jor, Ka, Ki, Kil, Lo, Mar, Na, Nal, O, Ras, Ren, Ro, Ta, Tar, Tel, Thi, Tho, Thon, Thra, Tor, Von, We, Wer, Yen, Yur"
11 | syllablesEnd = "al, ali, ba, bida, bra, da, deth, di, fra, gret, hild, iess, kala, la, laani, li, lona, ma, mae, mala, na, nuda, ra, ta, tala, tu, tuna, vada, vara, ya"
12 | rules = "$s$e"
13 | illegal = "dueal, frefra, grogret"
14 | }
15 |
16 | //surnames have semantic information. Here, they're separated into three
17 | //somewhat coherent sets and either is chosen
18 | name "dwarf surname" {
19 | //1st set - smith & Mr.Muscle surnames
20 | syllablesPre = "Boulder, Bronze, Coal, Copper, Gem, Granite, Hammer, Iron, Marble, Metal, Rock, Steel, Stone, Thunder"
21 | syllablesPost = "bender, breaker, carver, club, crusher, cutter, digger, fist, foot, forger, heart, smasher, smith"
22 | //2nd set - warrior surnames
23 | syllablesStart = "Bear, Boar, Dragon, Giant, Goblin, Elf, Ettin, Foe, Kobold, Ogre, Orc,Spider, Troll, Wolf"
24 | syllablesEnd = "bane, basher, _Battler, _Beheader, boxer, _Butcher, choker, cleaver, crusher, cutter, doom, eater, _Executioner, _Fighter, _Garrotter, grapple, _Gutter, hammer, killer, mauler, masher, ripper, slasher, slayer, slicer, smasher, _Strangler, striker, _Wrestler"
25 | //3rd set - heroic and general
26 | phonemesVocals = "Black, Blood, Bronze, Fire, Firm, Grey, Hard, Ice, Iron, Moon, Oak, Onyx, Red, Steel, Stone, Strong, Thunder, White"
27 | phonemesConsonants = "axe, beard, blade, brand, cheek, fist, foot, hair, hammer, hand, head, heart, pick, shield, spear, spike, sword"
28 | rules = "$P$p, $s$e, $v$c"
29 | }
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/data/namegen/mingos_standard.cfg:
--------------------------------------------------------------------------------
1 | //Names based on syllables from J.R.R. Tolkien's and David Eddings' novels.
2 | name "male" {
3 | phonemesVocals = "a, e, i, o, u, y"
4 | phonemesConsonants = "b, c, ch, ck, cz, d, dh, f, g, gh, h, j, k, kh, l, m, n, p, ph, q, r, rh, s, sh, t, th, ts, tz, v, w, x, z, zh"
5 | syllablesStart = "Aer, Al, Am, An, Ar, Arm, Arth, B, Bal, Bar, Be, Bel, Ber, Bok, Bor, Bran, Breg, Bren, Brod, Cam, Chal, Cham, Ch, Cuth, Dag, Daim, Dair, Del, Dr, Dur, Duv, Ear, Elen, Er, Erel, Erem, Fal, Ful, Gal, G, Get, Gil, Gor, Grin, Gun, H, Hal, Han, Har, Hath, Hett, Hur, Iss, Khel, K, Kor, Lel, Lor, M, Mal, Man, Mard, N, Ol, Radh, Rag, Relg, Rh, Run, Sam, Tarr, T, Tor, Tul, Tur, Ul, Ulf, Unr, Ur, Urth, Yar, Z, Zan, Zer"
6 | syllablesMiddle = "de, do, dra, du, duna, ga, go, hara, kaltho, la, latha, le, ma, nari, ra, re, rego, ro, rodda, romi, rui, sa, to, ya, zila"
7 | syllablesEnd = "bar, bers, blek, chak, chik, dan, dar, das, dig, dil, din, dir, dor, dur, fang, fast, gar, gas, gen, gorn, grim, gund, had, hek, hell, hir, hor, kan, kath, khad, kor, lach, lar, ldil, ldir, leg, len, lin, mas, mnir, ndil, ndur, neg, nik, ntir, rab, rach, rain, rak, ran, rand, rath, rek, rig, rim, rin, rion, sin, sta, stir, sus, tar, thad, thel, tir, von, vor, yon, zor"
8 | rules = "$s$v$35m$10m$e"
9 | }
10 |
11 | name "female" {
12 | phonemesVocals = "a, e, i, o, u, y"
13 | syllablesStart = "Ad, Aer, Ar, Bel, Bet, Beth, Ce'N, Cyr, Eilin, El, Em, Emel, G, Gl, Glor, Is, Isl, Iv, Lay, Lis, May, Ner, Pol, Por, Sal, Sil, Vel, Vor, X, Xan, Xer, Yv, Zub"
14 | syllablesMiddle = "bre, da, dhe, ga, lda, le, lra, mi, ra, ri, ria, re, se, ya"
15 | syllablesEnd = "ba, beth, da, kira, laith, lle, ma, mina, mira, na, nn, nne, nor, ra, rin, ssra, ta, th, tha, thra, tira, tta, vea, vena, we, wen, wyn"
16 | rules = "$s$v$35m$10m$e"
17 | }
18 |
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/data/namegen/mingos_town.cfg:
--------------------------------------------------------------------------------
1 | //Town names. The town name construction is based on real British town names,
2 | //although many starting syllables are made up.
3 | name "Mingos town" {
4 | syllablesPre = "East, Fort, Great, High, Lower, Middle, Mount, New, North, Old, Royal, Saint, South, Upper, West"
5 | syllablesStart = "Ales, Apple, Ash, Bald, Bay, Bed, Bell, Birdling, Black, Blue, Bow, Bran, Brass, Bright, Brown, Bruns, Bulls, Camp, Cherry, Clark, Clarks, Clay, Clear, Copper, Corn, Cross, Crystal, Dark, Deep, Deer, Drac, Eagle, Earth, Elk, Elles, Elm, Ester, Ewes, Fair, Falcon, Ferry, Fire, Fleet, Fox, Gold, Grand, Green, Grey, Guild, Hammer, Hart, Hawks, Hay, Haze, Hazel, Hemlock, Ice, Iron, Kent, Kings, Knox, Layne, Lint, Lor, Mable, Maple, Marble, Mare, Marsh, Mist, Mor, Mud, Nor, Oak, Orms, Ox, Oxen, Pear, Pine, Pitts, Port, Purple, Red, Rich, Roch, Rock, Rose, Ross, Rye, Salis, Salt, Shadow, Silver, Skeg, Smith, Snow, Sows, Spring, Spruce, Staff, Star, Steel, Still, Stock, Stone, Strong, Summer, Swan, Swine, Sword, Yellow, Val, Wart, Water, Well, Wheat, White, Wild, Winter, Wolf, Wool, Wor"
6 | syllablesEnd = "bank, borne, borough, brook, burg, burgh, bury, castle, cester, cliff, crest, croft, dale, dam, dorf, edge, field, ford, gate, grad, hall, ham, hollow, holm, hurst, keep, kirk, land, ley, lyn, mere, mill, minster, mont, moor, mouth, ness, pool, river, shire, shore, side, stead, stoke, ston, thorpe, ton, town, vale, ville, way, wich, wick, wood, worth"
7 | syllablesPost = "Annex, Barrens, Barrow, Corner, Cove, Crossing, Dell, Dales, Estates, Forest, Furnace, Grove, Haven, Heath, Hill, Junction, Landing, Meadow, Park, Plain, Point, Reserve, Retreat, Ridge, Springs, View, Village, Wells, Woods"
8 | rules = "$15P_$s$e_$15p"
9 | }
10 |
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/data/rexpaint/test.xp:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/saturnation/libtcod-tutorial/cae06e2b50a3705adad15fee43b5d66eaa08be92/lib/libtcod-1.9.0-x86_64-msvc/data/rexpaint/test.xp
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/include/libtcod.h:
--------------------------------------------------------------------------------
1 | /* libtcod
2 | * Copyright © 2008-2018 Jice and the libtcod contributers.
3 | * All rights reserved.
4 | *
5 | * libtcod 'The Doryen library' is a cross-platform C/C++ library for roguelike
6 | * developers.
7 | * Its source code is available from:
8 | * https://github.com/libtcod/libtcod
9 | *
10 | * Redistribution and use in source and binary forms, with or without
11 | * modification, are permitted provided that the following conditions are met:
12 | * * Redistributions of source code must retain the above copyright
13 | * notice, this list of conditions and the following disclaimer.
14 | * * Redistributions in binary form must reproduce the above copyright
15 | * notice, this list of conditions and the following disclaimer in the
16 | * documentation and/or other materials provided with the distribution.
17 | * * The name of copyright holder nor the names of its contributors may not
18 | * be used to endorse or promote products derived from this software
19 | * without specific prior written permission.
20 | *
21 | * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
22 | * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
23 | * TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
24 | * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
25 | * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
26 | * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
27 | * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
28 | * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
29 | * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
30 | * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
31 | * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
32 | */
33 | #include "libtcod/libtcod.h"
34 |
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/include/libtcod.hpp:
--------------------------------------------------------------------------------
1 | /* libtcod
2 | * Copyright © 2008-2018 Jice and the libtcod contributers.
3 | * All rights reserved.
4 | *
5 | * libtcod 'The Doryen library' is a cross-platform C/C++ library for roguelike
6 | * developers.
7 | * Its source code is available from:
8 | * https://github.com/libtcod/libtcod
9 | *
10 | * Redistribution and use in source and binary forms, with or without
11 | * modification, are permitted provided that the following conditions are met:
12 | * * Redistributions of source code must retain the above copyright
13 | * notice, this list of conditions and the following disclaimer.
14 | * * Redistributions in binary form must reproduce the above copyright
15 | * notice, this list of conditions and the following disclaimer in the
16 | * documentation and/or other materials provided with the distribution.
17 | * * The name of copyright holder nor the names of its contributors may not
18 | * be used to endorse or promote products derived from this software
19 | * without specific prior written permission.
20 | *
21 | * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
22 | * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
23 | * TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
24 | * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
25 | * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
26 | * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
27 | * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
28 | * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
29 | * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
30 | * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
31 | * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
32 | */
33 | #include "libtcod.h"
34 |
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/include/libtcod/color/canvas.h:
--------------------------------------------------------------------------------
1 | /* libtcod
2 | * Copyright © 2008-2018 Jice and the libtcod contributers.
3 | * All rights reserved.
4 | *
5 | * libtcod 'The Doryen library' is a cross-platform C/C++ library for roguelike
6 | * developers.
7 | * Its source code is available from:
8 | * https://github.com/libtcod/libtcod
9 | *
10 | * Redistribution and use in source and binary forms, with or without
11 | * modification, are permitted provided that the following conditions are met:
12 | * * Redistributions of source code must retain the above copyright
13 | * notice, this list of conditions and the following disclaimer.
14 | * * Redistributions in binary form must reproduce the above copyright
15 | * notice, this list of conditions and the following disclaimer in the
16 | * documentation and/or other materials provided with the distribution.
17 | * * The name of copyright holder nor the names of its contributors may not
18 | * be used to endorse or promote products derived from this software
19 | * without specific prior written permission.
20 | *
21 | * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
22 | * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
23 | * TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
24 | * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
25 | * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
26 | * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
27 | * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
28 | * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
29 | * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
30 | * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
31 | * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
32 | */
33 | #ifndef LIBTCOD_COLOR_CANVAS_H_
34 | #define LIBTCOD_COLOR_CANVAS_H_
35 | #ifdef __cplusplus
36 | #include
37 | #endif // __cplusplus
38 |
39 | #include "color.h"
40 | #include "../utility/vector2.h"
41 | #ifdef __cplusplus
42 | namespace tcod {
43 | namespace image {
44 | /**
45 | * A Common Vector2 type used for 2d images.
46 | */
47 | typedef Vector2 Image;
48 | Image load(const std::string& filename);
49 | } // namespace image
50 | } // namespace tcod
51 | #endif /* __cplusplus */
52 | #endif /* LIBTCOD_COLOR_CANVAS_H_ */
53 |
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/include/libtcod/color/color.h:
--------------------------------------------------------------------------------
1 | /* libtcod
2 | * Copyright © 2008-2018 Jice and the libtcod contributers.
3 | * All rights reserved.
4 | *
5 | * libtcod 'The Doryen library' is a cross-platform C/C++ library for roguelike
6 | * developers.
7 | * Its source code is available from:
8 | * https://github.com/libtcod/libtcod
9 | *
10 | * Redistribution and use in source and binary forms, with or without
11 | * modification, are permitted provided that the following conditions are met:
12 | * * Redistributions of source code must retain the above copyright
13 | * notice, this list of conditions and the following disclaimer.
14 | * * Redistributions in binary form must reproduce the above copyright
15 | * notice, this list of conditions and the following disclaimer in the
16 | * documentation and/or other materials provided with the distribution.
17 | * * The name of copyright holder nor the names of its contributors may not
18 | * be used to endorse or promote products derived from this software
19 | * without specific prior written permission.
20 | *
21 | * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
22 | * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
23 | * TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
24 | * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
25 | * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
26 | * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
27 | * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
28 | * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
29 | * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
30 | * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
31 | * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
32 | */
33 | #ifndef LIBTCOD_COLOR_COLOR_H_
34 | #define LIBTCOD_COLOR_COLOR_H_
35 | #include
36 | #ifdef __cplusplus
37 | namespace tcod {
38 | struct ColorRGBA {
39 | uint8_t r, g, b, a;
40 | };
41 | } // namespace tcod
42 | #endif /* __cplusplus */
43 | #endif /* LIBTCOD_COLOR_COLOR_H_ */
44 |
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/include/libtcod/console/rexpaint.h:
--------------------------------------------------------------------------------
1 | /* libtcod
2 | * Copyright © 2008-2018 Jice and the libtcod contributers.
3 | * All rights reserved.
4 | *
5 | * libtcod 'The Doryen library' is a cross-platform C/C++ library for roguelike
6 | * developers.
7 | * Its source code is available from:
8 | * https://github.com/libtcod/libtcod
9 | *
10 | * Redistribution and use in source and binary forms, with or without
11 | * modification, are permitted provided that the following conditions are met:
12 | * * Redistributions of source code must retain the above copyright
13 | * notice, this list of conditions and the following disclaimer.
14 | * * Redistributions in binary form must reproduce the above copyright
15 | * notice, this list of conditions and the following disclaimer in the
16 | * documentation and/or other materials provided with the distribution.
17 | * * The name of copyright holder nor the names of its contributors may not
18 | * be used to endorse or promote products derived from this software
19 | * without specific prior written permission.
20 | *
21 | * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
22 | * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
23 | * TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
24 | * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
25 | * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
26 | * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
27 | * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
28 | * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
29 | * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
30 | * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
31 | * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
32 | */
33 | #ifndef TCOD_CONSOLE_REXPAINT_H_
34 | #define TCOD_CONSOLE_REXPAINT_H_
35 |
36 | #include "../portability.h"
37 | #include "../console.h"
38 |
39 | #ifdef __cplusplus
40 | extern "C" {
41 | #endif
42 |
43 | TCODLIB_API TCOD_console_t TCOD_console_from_xp(const char *filename);
44 | TCODLIB_API bool TCOD_console_load_xp(TCOD_Console* con, const char *filename);
45 | TCODLIB_API bool TCOD_console_save_xp(const TCOD_Console* con,
46 | const char *filename, int compress_level);
47 | TCODLIB_API TCOD_list_t TCOD_console_list_from_xp(const char *filename);
48 | TCODLIB_API bool TCOD_console_list_save_xp(
49 | TCOD_list_t console_list, const char *filename, int compress_level);
50 |
51 | #ifdef __cplusplus
52 | }
53 | #endif
54 |
55 | #endif /* TCOD_CONSOLE_REXPAINT_H_ */
56 |
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/include/libtcod/engine/backend.h:
--------------------------------------------------------------------------------
1 | /* libtcod
2 | * Copyright © 2008-2018 Jice and the libtcod contributers.
3 | * All rights reserved.
4 | *
5 | * libtcod 'The Doryen library' is a cross-platform C/C++ library for roguelike
6 | * developers.
7 | * Its source code is available from:
8 | * https://github.com/libtcod/libtcod
9 | *
10 | * Redistribution and use in source and binary forms, with or without
11 | * modification, are permitted provided that the following conditions are met:
12 | * * Redistributions of source code must retain the above copyright
13 | * notice, this list of conditions and the following disclaimer.
14 | * * Redistributions in binary form must reproduce the above copyright
15 | * notice, this list of conditions and the following disclaimer in the
16 | * documentation and/or other materials provided with the distribution.
17 | * * The name of copyright holder nor the names of its contributors may not
18 | * be used to endorse or promote products derived from this software
19 | * without specific prior written permission.
20 | *
21 | * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
22 | * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
23 | * TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
24 | * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
25 | * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
26 | * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
27 | * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
28 | * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
29 | * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
30 | * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
31 | * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
32 | */
33 | #ifndef LIBTCOD_ENGINE_BACKEND_H_
34 | #define LIBTCOD_ENGINE_BACKEND_H_
35 |
36 | #ifdef __cplusplus
37 | #include
38 | #endif /* __cplusplus */
39 |
40 | #include "../console_types.h"
41 | #include "../mouse_types.h"
42 | #include "../sys.h"
43 |
44 | #ifdef __cplusplus
45 | namespace tcod {
46 | namespace engine {
47 | class Backend {
48 | public:
49 | virtual ~Backend() = default;
50 | /**
51 | * Legacy wait for event virtual function.
52 | */
53 | virtual TCOD_event_t legacy_wait_for_event(
54 | int eventMask, TCOD_key_t *key, TCOD_mouse_t *mouse, bool flush) {
55 | return TCOD_EVENT_NONE;
56 | }
57 | /**
58 | * Legacy check for event virtual function.
59 | */
60 | virtual TCOD_event_t legacy_check_for_event(
61 | int eventMask, TCOD_key_t *key, TCOD_mouse_t *mouse) {
62 | return TCOD_EVENT_NONE;
63 | }
64 | };
65 | } // namespace engine
66 | } // namespace tcod
67 | #endif /* __cplusplus */
68 | #endif /* LIBTCOD_ENGINE_BACKEND_H_ */
69 |
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/include/libtcod/engine/globals.h:
--------------------------------------------------------------------------------
1 | /* libtcod
2 | * Copyright © 2008-2018 Jice and the libtcod contributers.
3 | * All rights reserved.
4 | *
5 | * libtcod 'The Doryen library' is a cross-platform C/C++ library for roguelike
6 | * developers.
7 | * Its source code is available from:
8 | * https://github.com/libtcod/libtcod
9 | *
10 | * Redistribution and use in source and binary forms, with or without
11 | * modification, are permitted provided that the following conditions are met:
12 | * * Redistributions of source code must retain the above copyright
13 | * notice, this list of conditions and the following disclaimer.
14 | * * Redistributions in binary form must reproduce the above copyright
15 | * notice, this list of conditions and the following disclaimer in the
16 | * documentation and/or other materials provided with the distribution.
17 | * * The name of copyright holder nor the names of its contributors may not
18 | * be used to endorse or promote products derived from this software
19 | * without specific prior written permission.
20 | *
21 | * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
22 | * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
23 | * TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
24 | * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
25 | * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
26 | * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
27 | * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
28 | * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
29 | * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
30 | * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
31 | * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
32 | */
33 | #ifndef LIBTCOD_ENGINE_GLOBALS_H_
34 | #define LIBTCOD_ENGINE_GLOBALS_H_
35 |
36 | #ifdef __cplusplus
37 | #include
38 | #endif // __cplusplus
39 |
40 | #include "backend.h"
41 | #include "display.h"
42 | #include "../tileset/tileset.h"
43 | #include "../tileset/tilesheet.h"
44 |
45 | #ifdef __cplusplus
46 | namespace tcod {
47 | namespace engine {
48 | using tileset::Tileset;
49 | using tileset::Tilesheet;
50 | /**
51 | * Replace the active backend with a new instance, can be nullptr.
52 | */
53 | void set_backend(std::shared_ptr backend);
54 | /**
55 | * Return a shared pointer to the active backend. Might be nullptr.
56 | */
57 | std::shared_ptr get_backend();
58 | /**
59 | * Replace the active display with a new instance, can be nullptr.
60 | */
61 | void set_display(std::shared_ptr display);
62 | /**
63 | * Return a shared pointer to the active display. Might be nullptr.
64 | */
65 | std::shared_ptr get_display();
66 |
67 | void set_tileset(std::shared_ptr tileset);
68 | auto get_tileset() -> std::shared_ptr;
69 | void set_tilesheet(std::shared_ptr sheet);
70 | auto get_tilesheet() -> std::shared_ptr;
71 | } // namespace sdl2
72 | } // namespace tcod
73 | #endif // __cplusplus
74 | #endif // LIBTCOD_ENGINE_GLOBALS_H_
75 |
76 |
77 |
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/include/libtcod/fov.h:
--------------------------------------------------------------------------------
1 | /* libtcod
2 | * Copyright © 2008-2018 Jice and the libtcod contributers.
3 | * All rights reserved.
4 | *
5 | * libtcod 'The Doryen library' is a cross-platform C/C++ library for roguelike
6 | * developers.
7 | * Its source code is available from:
8 | * https://github.com/libtcod/libtcod
9 | *
10 | * Redistribution and use in source and binary forms, with or without
11 | * modification, are permitted provided that the following conditions are met:
12 | * * Redistributions of source code must retain the above copyright
13 | * notice, this list of conditions and the following disclaimer.
14 | * * Redistributions in binary form must reproduce the above copyright
15 | * notice, this list of conditions and the following disclaimer in the
16 | * documentation and/or other materials provided with the distribution.
17 | * * The name of copyright holder nor the names of its contributors may not
18 | * be used to endorse or promote products derived from this software
19 | * without specific prior written permission.
20 | *
21 | * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
22 | * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
23 | * TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
24 | * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
25 | * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
26 | * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
27 | * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
28 | * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
29 | * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
30 | * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
31 | * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
32 | */
33 | #ifndef _TCOD_FOV_H
34 | #define _TCOD_FOV_H
35 |
36 | #include "portability.h"
37 | #include "fov_types.h"
38 |
39 | #ifdef __cplusplus
40 | extern "C" {
41 | #endif
42 | /* allocate a new map */
43 | TCODLIB_API TCOD_Map *TCOD_map_new(int width, int height);
44 | /* set all cells as solid rock (cannot see through nor walk) */
45 | TCODLIB_API void TCOD_map_clear(TCOD_Map *map,
46 | bool transparent, bool walkable);
47 | /* copy a map to another, reallocating it when needed */
48 | TCODLIB_API void TCOD_map_copy(const TCOD_Map *source, TCOD_Map *dest);
49 | /* change a cell properties */
50 | TCODLIB_API void TCOD_map_set_properties(
51 | TCOD_Map *map, int x, int y, bool is_transparent, bool is_walkable);
52 | /* destroy a map */
53 | TCODLIB_API void TCOD_map_delete(TCOD_Map *map);
54 |
55 | /* calculate the field of view (potentially visible cells from player_x,player_y) */
56 | TCODLIB_API void TCOD_map_compute_fov(
57 | TCOD_Map *map, int player_x, int player_y, int max_radius,
58 | bool light_walls, TCOD_fov_algorithm_t algo);
59 | /* check if a cell is in the last computed field of view */
60 | TCODLIB_API bool TCOD_map_is_in_fov(const TCOD_Map *map, int x, int y);
61 | TCODLIB_API void TCOD_map_set_in_fov(TCOD_Map *map, int x, int y, bool fov);
62 |
63 | /* retrieve properties from the map */
64 | TCODLIB_API bool TCOD_map_is_transparent(const TCOD_Map *map, int x, int y);
65 | TCODLIB_API bool TCOD_map_is_walkable(TCOD_Map *map, int x, int y);
66 | TCODLIB_API int TCOD_map_get_width(const TCOD_Map *map);
67 | TCODLIB_API int TCOD_map_get_height(const TCOD_Map *map);
68 | TCODLIB_API int TCOD_map_get_nb_cells(const TCOD_Map *map);
69 | #ifdef __cplusplus
70 | }
71 | #endif
72 | #endif
73 |
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/include/libtcod/fov_types.h:
--------------------------------------------------------------------------------
1 | /* libtcod
2 | * Copyright © 2008-2018 Jice and the libtcod contributers.
3 | * All rights reserved.
4 | *
5 | * libtcod 'The Doryen library' is a cross-platform C/C++ library for roguelike
6 | * developers.
7 | * Its source code is available from:
8 | * https://github.com/libtcod/libtcod
9 | *
10 | * Redistribution and use in source and binary forms, with or without
11 | * modification, are permitted provided that the following conditions are met:
12 | * * Redistributions of source code must retain the above copyright
13 | * notice, this list of conditions and the following disclaimer.
14 | * * Redistributions in binary form must reproduce the above copyright
15 | * notice, this list of conditions and the following disclaimer in the
16 | * documentation and/or other materials provided with the distribution.
17 | * * The name of copyright holder nor the names of its contributors may not
18 | * be used to endorse or promote products derived from this software
19 | * without specific prior written permission.
20 | *
21 | * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
22 | * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
23 | * TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
24 | * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
25 | * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
26 | * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
27 | * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
28 | * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
29 | * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
30 | * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
31 | * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
32 | */
33 | #ifndef TCOD_FOV_TYPES_H_
34 | #define TCOD_FOV_TYPES_H_
35 | #include "portability.h"
36 | /**
37 | * Private map cell struct.
38 | */
39 | struct TCOD_MapCell {
40 | bool transparent;
41 | bool walkable;
42 | bool fov;
43 | };
44 | /**
45 | * Private map struct.
46 | */
47 | typedef struct TCOD_Map {
48 | int width;
49 | int height;
50 | int nbcells;
51 | struct TCOD_MapCell *cells;
52 | } TCOD_Map;
53 | typedef TCOD_Map *TCOD_map_t;
54 | /**
55 | * Field-of-view options.
56 | */
57 | typedef enum {
58 | /**
59 | * Basic: http://roguebasin.roguelikedevelopment.org/index.php?title=Ray_casting
60 | */
61 | FOV_BASIC,
62 | /**
63 | * Diamond: http://www.geocities.com/temerra/los_rays.html
64 | */
65 | FOV_DIAMOND,
66 | /**
67 | * Shadow casting: http://roguebasin.roguelikedevelopment.org/index.php?title=FOV_using_recursive_shadowcasting
68 | */
69 | FOV_SHADOW,
70 | /**
71 | * Permissive: http://roguebasin.roguelikedevelopment.org/index.php?title=Precise_Permissive_Field_of_View
72 | */
73 | FOV_PERMISSIVE_0,
74 | FOV_PERMISSIVE_1,
75 | FOV_PERMISSIVE_2,
76 | FOV_PERMISSIVE_3,
77 | FOV_PERMISSIVE_4,
78 | FOV_PERMISSIVE_5,
79 | FOV_PERMISSIVE_6,
80 | FOV_PERMISSIVE_7,
81 | FOV_PERMISSIVE_8,
82 | /**
83 | * Mingos' Restrictive Precise Angle Shadowcasting (contribution by Mingos)
84 | */
85 | FOV_RESTRICTIVE,
86 | NB_FOV_ALGORITHMS } TCOD_fov_algorithm_t;
87 | #define FOV_PERMISSIVE(x) ((TCOD_fov_algorithm_t)(FOV_PERMISSIVE_0 + (x)))
88 | #endif /* TCOD_FOV_TYPES_H_ */
89 |
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/include/libtcod/gui/button.hpp:
--------------------------------------------------------------------------------
1 | /* libtcod
2 | * Copyright © 2008-2018 Jice and the libtcod contributers.
3 | * All rights reserved.
4 | *
5 | * libtcod 'The Doryen library' is a cross-platform C/C++ library for roguelike
6 | * developers.
7 | * Its source code is available from:
8 | * https://github.com/libtcod/libtcod
9 | *
10 | * Redistribution and use in source and binary forms, with or without
11 | * modification, are permitted provided that the following conditions are met:
12 | * * Redistributions of source code must retain the above copyright
13 | * notice, this list of conditions and the following disclaimer.
14 | * * Redistributions in binary form must reproduce the above copyright
15 | * notice, this list of conditions and the following disclaimer in the
16 | * documentation and/or other materials provided with the distribution.
17 | * * The name of copyright holder nor the names of its contributors may not
18 | * be used to endorse or promote products derived from this software
19 | * without specific prior written permission.
20 | *
21 | * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
22 | * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
23 | * TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
24 | * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
25 | * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
26 | * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
27 | * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
28 | * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
29 | * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
30 | * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
31 | * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
32 | */
33 | #ifndef TCOD_GUI_BUTTON_HPP
34 | #define TCOD_GUI_BUTTON_HPP
35 | #include "widget.hpp"
36 | class TCODLIB_GUI_API Button : public Widget {
37 | public :
38 | Button(const char *label, const char *tip, widget_callback_t cbk, void *userData=NULL);
39 | Button(int x, int y, int width, int height, const char *label, const char *tip, widget_callback_t cbk, void *userData=NULL);
40 | virtual ~Button();
41 | void render();
42 | void setLabel(const char *newLabel);
43 | void computeSize();
44 | inline bool isPressed() { return pressed; }
45 | protected :
46 | bool pressed;
47 | char *label;
48 | widget_callback_t cbk;
49 |
50 | void onButtonPress();
51 | void onButtonRelease();
52 | void onButtonClick();
53 | void expand(int width, int height);
54 | };
55 | #endif /* TCOD_GUI_BUTTON_HPP */
56 |
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/include/libtcod/gui/container.hpp:
--------------------------------------------------------------------------------
1 | /* libtcod
2 | * Copyright © 2008-2018 Jice and the libtcod contributers.
3 | * All rights reserved.
4 | *
5 | * libtcod 'The Doryen library' is a cross-platform C/C++ library for roguelike
6 | * developers.
7 | * Its source code is available from:
8 | * https://github.com/libtcod/libtcod
9 | *
10 | * Redistribution and use in source and binary forms, with or without
11 | * modification, are permitted provided that the following conditions are met:
12 | * * Redistributions of source code must retain the above copyright
13 | * notice, this list of conditions and the following disclaimer.
14 | * * Redistributions in binary form must reproduce the above copyright
15 | * notice, this list of conditions and the following disclaimer in the
16 | * documentation and/or other materials provided with the distribution.
17 | * * The name of copyright holder nor the names of its contributors may not
18 | * be used to endorse or promote products derived from this software
19 | * without specific prior written permission.
20 | *
21 | * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
22 | * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
23 | * TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
24 | * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
25 | * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
26 | * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
27 | * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
28 | * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
29 | * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
30 | * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
31 | * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
32 | */
33 | #ifndef TCOD_GUI_CONTAINER_HPP
34 | #define TCOD_GUI_CONTAINER_HPP
35 | #include "widget.hpp"
36 | class TCODLIB_GUI_API Container : public Widget {
37 | public :
38 | Container(int x, int y, int w, int h) : Widget(x,y,w,h) {}
39 | virtual ~Container();
40 | void addWidget(Widget *wid);
41 | void removeWidget(Widget *wid);
42 | void setVisible(bool val);
43 | void render();
44 | void clear();
45 | void update(const TCOD_key_t k);
46 | protected :
47 | TCODList content;
48 | };
49 | #endif /* TCOD_GUI_CONTAINER_HPP */
50 |
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/include/libtcod/gui/flatlist.hpp:
--------------------------------------------------------------------------------
1 | /* libtcod
2 | * Copyright © 2008-2018 Jice and the libtcod contributers.
3 | * All rights reserved.
4 | *
5 | * libtcod 'The Doryen library' is a cross-platform C/C++ library for roguelike
6 | * developers.
7 | * Its source code is available from:
8 | * https://github.com/libtcod/libtcod
9 | *
10 | * Redistribution and use in source and binary forms, with or without
11 | * modification, are permitted provided that the following conditions are met:
12 | * * Redistributions of source code must retain the above copyright
13 | * notice, this list of conditions and the following disclaimer.
14 | * * Redistributions in binary form must reproduce the above copyright
15 | * notice, this list of conditions and the following disclaimer in the
16 | * documentation and/or other materials provided with the distribution.
17 | * * The name of copyright holder nor the names of its contributors may not
18 | * be used to endorse or promote products derived from this software
19 | * without specific prior written permission.
20 | *
21 | * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
22 | * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
23 | * TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
24 | * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
25 | * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
26 | * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
27 | * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
28 | * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
29 | * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
30 | * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
31 | * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
32 | */
33 | #ifndef TCOD_GUI_FLATLIST_HPP
34 | #define TCOD_GUI_FLATLIST_HPP
35 | #include "textbox.hpp"
36 | class TCODLIB_GUI_API FlatList : public TextBox {
37 | public :
38 | FlatList(int x,int y,int w, const char **list, const char *label, const char *tip=NULL);
39 | virtual ~FlatList();
40 | void render();
41 | void update(const TCOD_key_t k);
42 | void setCallback(void (*cbk)(Widget *wid, const char * val, void *data), void *data) { this->cbk=cbk; this->data=data;}
43 | void setValue(const char * value);
44 | void setList(const char **list);
45 | protected :
46 | const char **value;
47 | const char **list;
48 | bool onLeftArrow;
49 | bool onRightArrow;
50 | void (*cbk)(Widget *wid, const char *val, void *data);
51 | void *data;
52 |
53 | void valueToText();
54 | void textToValue();
55 | void onButtonClick();
56 | };
57 | #endif /* TCOD_GUI_FLATLIST_HPP */
58 |
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/include/libtcod/gui/gui.hpp:
--------------------------------------------------------------------------------
1 | /* libtcod
2 | * Copyright © 2008-2018 Jice and the libtcod contributers.
3 | * All rights reserved.
4 | *
5 | * libtcod 'The Doryen library' is a cross-platform C/C++ library for roguelike
6 | * developers.
7 | * Its source code is available from:
8 | * https://github.com/libtcod/libtcod
9 | *
10 | * Redistribution and use in source and binary forms, with or without
11 | * modification, are permitted provided that the following conditions are met:
12 | * * Redistributions of source code must retain the above copyright
13 | * notice, this list of conditions and the following disclaimer.
14 | * * Redistributions in binary form must reproduce the above copyright
15 | * notice, this list of conditions and the following disclaimer in the
16 | * documentation and/or other materials provided with the distribution.
17 | * * The name of copyright holder nor the names of its contributors may not
18 | * be used to endorse or promote products derived from this software
19 | * without specific prior written permission.
20 | *
21 | * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
22 | * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
23 | * TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
24 | * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
25 | * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
26 | * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
27 | * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
28 | * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
29 | * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
30 | * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
31 | * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
32 | */
33 | #ifndef _GUI_HPP
34 | #define _GUI_HPP
35 |
36 | #include "../libtcod.hpp"
37 |
38 | #include "widget.hpp"
39 | #include "button.hpp"
40 | #include "radiobutton.hpp"
41 | #include "container.hpp"
42 | #include "label.hpp"
43 | #include "statusbar.hpp"
44 | #include "textbox.hpp"
45 | #include "flatlist.hpp"
46 | #include "slider.hpp"
47 | #include "togglebutton.hpp"
48 | #include "toolbar.hpp"
49 | #include "vbox.hpp"
50 | #include "hbox.hpp"
51 | #include "image.hpp"
52 |
53 | #endif
54 |
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/include/libtcod/gui/gui_portability.hpp:
--------------------------------------------------------------------------------
1 | /* libtcod
2 | * Copyright © 2008-2018 Jice and the libtcod contributers.
3 | * All rights reserved.
4 | *
5 | * libtcod 'The Doryen library' is a cross-platform C/C++ library for roguelike
6 | * developers.
7 | * Its source code is available from:
8 | * https://github.com/libtcod/libtcod
9 | *
10 | * Redistribution and use in source and binary forms, with or without
11 | * modification, are permitted provided that the following conditions are met:
12 | * * Redistributions of source code must retain the above copyright
13 | * notice, this list of conditions and the following disclaimer.
14 | * * Redistributions in binary form must reproduce the above copyright
15 | * notice, this list of conditions and the following disclaimer in the
16 | * documentation and/or other materials provided with the distribution.
17 | * * The name of copyright holder nor the names of its contributors may not
18 | * be used to endorse or promote products derived from this software
19 | * without specific prior written permission.
20 | *
21 | * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
22 | * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
23 | * TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
24 | * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
25 | * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
26 | * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
27 | * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
28 | * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
29 | * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
30 | * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
31 | * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
32 | */
33 | #ifndef TCOD_GUI_PORTABILITY_HPP
34 | #define TCOD_GUI_PORTABILITY_HPP
35 |
36 | #include "../portability.h"
37 |
38 | #ifdef TCOD_VISUAL_STUDIO
39 | #pragma warning(disable:4996)
40 | #pragma warning(disable:4251)
41 | #endif
42 |
43 | // DLL export
44 | #define TCODLIB_GUI_API TCODLIB_API
45 |
46 | #endif /* TCOD_GUI_PORTABILITY_HPP */
47 |
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/include/libtcod/gui/hbox.hpp:
--------------------------------------------------------------------------------
1 | /* libtcod
2 | * Copyright © 2008-2018 Jice and the libtcod contributers.
3 | * All rights reserved.
4 | *
5 | * libtcod 'The Doryen library' is a cross-platform C/C++ library for roguelike
6 | * developers.
7 | * Its source code is available from:
8 | * https://github.com/libtcod/libtcod
9 | *
10 | * Redistribution and use in source and binary forms, with or without
11 | * modification, are permitted provided that the following conditions are met:
12 | * * Redistributions of source code must retain the above copyright
13 | * notice, this list of conditions and the following disclaimer.
14 | * * Redistributions in binary form must reproduce the above copyright
15 | * notice, this list of conditions and the following disclaimer in the
16 | * documentation and/or other materials provided with the distribution.
17 | * * The name of copyright holder nor the names of its contributors may not
18 | * be used to endorse or promote products derived from this software
19 | * without specific prior written permission.
20 | *
21 | * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
22 | * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
23 | * TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
24 | * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
25 | * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
26 | * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
27 | * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
28 | * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
29 | * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
30 | * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
31 | * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
32 | */
33 | #ifndef TCOD_GUI_HBOX_HPP
34 | #define TCOD_GUI_HBOX_HPP
35 | #include "vbox.hpp"
36 | class TCODLIB_GUI_API HBox : public VBox {
37 | public :
38 | HBox(int x, int y, int padding);
39 | void computeSize();
40 | };
41 | #endif /* TCOD_GUI_HBOX_HPP */
42 |
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/include/libtcod/gui/image.hpp:
--------------------------------------------------------------------------------
1 | /* libtcod
2 | * Copyright © 2008-2018 Jice and the libtcod contributers.
3 | * All rights reserved.
4 | *
5 | * libtcod 'The Doryen library' is a cross-platform C/C++ library for roguelike
6 | * developers.
7 | * Its source code is available from:
8 | * https://github.com/libtcod/libtcod
9 | *
10 | * Redistribution and use in source and binary forms, with or without
11 | * modification, are permitted provided that the following conditions are met:
12 | * * Redistributions of source code must retain the above copyright
13 | * notice, this list of conditions and the following disclaimer.
14 | * * Redistributions in binary form must reproduce the above copyright
15 | * notice, this list of conditions and the following disclaimer in the
16 | * documentation and/or other materials provided with the distribution.
17 | * * The name of copyright holder nor the names of its contributors may not
18 | * be used to endorse or promote products derived from this software
19 | * without specific prior written permission.
20 | *
21 | * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
22 | * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
23 | * TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
24 | * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
25 | * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
26 | * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
27 | * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
28 | * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
29 | * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
30 | * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
31 | * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
32 | */
33 | #ifndef TCOD_GUI_IMAGE_HPP
34 | #define TCOD_GUI_IMAGE_HPP
35 | #include "widget.hpp"
36 | class TCODLIB_GUI_API Image : public Widget {
37 | public :
38 | Image(int x,int y,int w, int h, const char *tip=NULL);
39 | virtual ~Image();
40 | void setBackgroundColor(const TCODColor col);
41 | void render();
42 | protected :
43 | void expand(int width, int height);
44 |
45 | TCODColor back;
46 | };
47 | #endif /* TCOD_GUI_IMAGE_HPP */
48 |
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/include/libtcod/gui/label.hpp:
--------------------------------------------------------------------------------
1 | /* libtcod
2 | * Copyright © 2008-2018 Jice and the libtcod contributers.
3 | * All rights reserved.
4 | *
5 | * libtcod 'The Doryen library' is a cross-platform C/C++ library for roguelike
6 | * developers.
7 | * Its source code is available from:
8 | * https://github.com/libtcod/libtcod
9 | *
10 | * Redistribution and use in source and binary forms, with or without
11 | * modification, are permitted provided that the following conditions are met:
12 | * * Redistributions of source code must retain the above copyright
13 | * notice, this list of conditions and the following disclaimer.
14 | * * Redistributions in binary form must reproduce the above copyright
15 | * notice, this list of conditions and the following disclaimer in the
16 | * documentation and/or other materials provided with the distribution.
17 | * * The name of copyright holder nor the names of its contributors may not
18 | * be used to endorse or promote products derived from this software
19 | * without specific prior written permission.
20 | *
21 | * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
22 | * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
23 | * TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
24 | * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
25 | * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
26 | * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
27 | * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
28 | * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
29 | * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
30 | * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
31 | * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
32 | */
33 | #ifndef TCOD_GUI_LABEL_HPP
34 | #define TCOD_GUI_LABEL_HPP
35 | #include "widget.hpp"
36 | class TCODLIB_GUI_API Label : public Widget {
37 | public :
38 | Label(int x, int y, const char *label, const char *tip=NULL );
39 | void render();
40 | void computeSize();
41 | void setValue(const char *label) { this->label=label; }
42 | protected :
43 | const char *label;
44 |
45 | void expand(int width, int height);
46 | };
47 | #endif /* TCOD_GUI_LABEL_HPP */
48 |
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/include/libtcod/gui/radiobutton.hpp:
--------------------------------------------------------------------------------
1 | /* libtcod
2 | * Copyright © 2008-2018 Jice and the libtcod contributers.
3 | * All rights reserved.
4 | *
5 | * libtcod 'The Doryen library' is a cross-platform C/C++ library for roguelike
6 | * developers.
7 | * Its source code is available from:
8 | * https://github.com/libtcod/libtcod
9 | *
10 | * Redistribution and use in source and binary forms, with or without
11 | * modification, are permitted provided that the following conditions are met:
12 | * * Redistributions of source code must retain the above copyright
13 | * notice, this list of conditions and the following disclaimer.
14 | * * Redistributions in binary form must reproduce the above copyright
15 | * notice, this list of conditions and the following disclaimer in the
16 | * documentation and/or other materials provided with the distribution.
17 | * * The name of copyright holder nor the names of its contributors may not
18 | * be used to endorse or promote products derived from this software
19 | * without specific prior written permission.
20 | *
21 | * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
22 | * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
23 | * TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
24 | * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
25 | * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
26 | * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
27 | * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
28 | * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
29 | * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
30 | * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
31 | * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
32 | */
33 | #ifndef TCOD_GUI_RADIOBUTTON_HPP
34 | #define TCOD_GUI_RADIOBUTTON_HPP
35 | #include "button.hpp"
36 | class TCODLIB_GUI_API RadioButton : public Button {
37 | public :
38 | RadioButton(const char *label, const char *tip, widget_callback_t cbk, void *userData=NULL)
39 | : Button(label,tip,cbk,userData),group(defaultGroup) {}
40 | RadioButton(int x, int y, int width, int height, const char *label, const char *tip, widget_callback_t cbk, void *userData=NULL)
41 | : Button(x,y,width,height,label,tip,cbk,userData),group(defaultGroup) {}
42 |
43 | void setGroup(int group) { this->group=group; }
44 | void render();
45 | void select();
46 | void unSelect();
47 | static void unSelectGroup(int group);
48 | static void setDefaultGroup(int group) { defaultGroup=group; }
49 | protected :
50 | static int defaultGroup;
51 | int group;
52 | static RadioButton *groupSelect[512];
53 |
54 | void onButtonClick();
55 | };
56 | #endif /* TCOD_GUI_RADIOBUTTON_HPP */
57 |
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/include/libtcod/gui/slider.hpp:
--------------------------------------------------------------------------------
1 | /* libtcod
2 | * Copyright © 2008-2018 Jice and the libtcod contributers.
3 | * All rights reserved.
4 | *
5 | * libtcod 'The Doryen library' is a cross-platform C/C++ library for roguelike
6 | * developers.
7 | * Its source code is available from:
8 | * https://github.com/libtcod/libtcod
9 | *
10 | * Redistribution and use in source and binary forms, with or without
11 | * modification, are permitted provided that the following conditions are met:
12 | * * Redistributions of source code must retain the above copyright
13 | * notice, this list of conditions and the following disclaimer.
14 | * * Redistributions in binary form must reproduce the above copyright
15 | * notice, this list of conditions and the following disclaimer in the
16 | * documentation and/or other materials provided with the distribution.
17 | * * The name of copyright holder nor the names of its contributors may not
18 | * be used to endorse or promote products derived from this software
19 | * without specific prior written permission.
20 | *
21 | * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
22 | * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
23 | * TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
24 | * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
25 | * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
26 | * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
27 | * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
28 | * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
29 | * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
30 | * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
31 | * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
32 | */
33 | #ifndef TCOD_GUI_SLIDER_HPP
34 | #define TCOD_GUI_SLIDER_HPP
35 | #include "textbox.hpp"
36 | class TCODLIB_GUI_API Slider : public TextBox {
37 | public :
38 | Slider(int x,int y,int w, float min, float max, const char *label, const char *tip=NULL);
39 | virtual ~Slider();
40 | void render();
41 | void update(const TCOD_key_t k);
42 | void setMinMax(float min, float max) { this->min=min;this->max=max; }
43 | void setCallback(void (*cbk)(Widget *wid, float val, void *data), void *data) { this->cbk=cbk; this->data=data;}
44 | void setFormat(const char *fmt);
45 | void setValue(float value);
46 | void setSensitivity(float sensitivity) { this->sensitivity=sensitivity;}
47 | protected :
48 | float min,max,value,sensitivity;
49 | bool onArrows;
50 | bool drag;
51 | int dragx;
52 | int dragy;
53 | float dragValue;
54 | char *fmt;
55 | void (*cbk)(Widget *wid, float val, void *data);
56 | void *data;
57 |
58 | void valueToText();
59 | void textToValue();
60 | void onButtonPress();
61 | void onButtonRelease();
62 | };
63 | #endif /* TCOD_GUI_SLIDER_HPP */
64 |
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/include/libtcod/gui/statusbar.hpp:
--------------------------------------------------------------------------------
1 | /* libtcod
2 | * Copyright © 2008-2018 Jice and the libtcod contributers.
3 | * All rights reserved.
4 | *
5 | * libtcod 'The Doryen library' is a cross-platform C/C++ library for roguelike
6 | * developers.
7 | * Its source code is available from:
8 | * https://github.com/libtcod/libtcod
9 | *
10 | * Redistribution and use in source and binary forms, with or without
11 | * modification, are permitted provided that the following conditions are met:
12 | * * Redistributions of source code must retain the above copyright
13 | * notice, this list of conditions and the following disclaimer.
14 | * * Redistributions in binary form must reproduce the above copyright
15 | * notice, this list of conditions and the following disclaimer in the
16 | * documentation and/or other materials provided with the distribution.
17 | * * The name of copyright holder nor the names of its contributors may not
18 | * be used to endorse or promote products derived from this software
19 | * without specific prior written permission.
20 | *
21 | * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
22 | * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
23 | * TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
24 | * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
25 | * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
26 | * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
27 | * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
28 | * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
29 | * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
30 | * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
31 | * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
32 | */
33 | #ifndef TCOD_GUI_STATUSBAR_HPP
34 | #define TCOD_GUI_STATUSBAR_HPP
35 | #include "widget.hpp"
36 | class TCODLIB_GUI_API StatusBar : public Widget {
37 | public :
38 | StatusBar(int x,int y,int w, int h):Widget(x,y,w,h) {}
39 | void render();
40 | };
41 | #endif /* TCOD_GUI_STATUSBAR_HPP */
42 |
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/include/libtcod/gui/textbox.hpp:
--------------------------------------------------------------------------------
1 | /* libtcod
2 | * Copyright © 2008-2018 Jice and the libtcod contributers.
3 | * All rights reserved.
4 | *
5 | * libtcod 'The Doryen library' is a cross-platform C/C++ library for roguelike
6 | * developers.
7 | * Its source code is available from:
8 | * https://github.com/libtcod/libtcod
9 | *
10 | * Redistribution and use in source and binary forms, with or without
11 | * modification, are permitted provided that the following conditions are met:
12 | * * Redistributions of source code must retain the above copyright
13 | * notice, this list of conditions and the following disclaimer.
14 | * * Redistributions in binary form must reproduce the above copyright
15 | * notice, this list of conditions and the following disclaimer in the
16 | * documentation and/or other materials provided with the distribution.
17 | * * The name of copyright holder nor the names of its contributors may not
18 | * be used to endorse or promote products derived from this software
19 | * without specific prior written permission.
20 | *
21 | * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
22 | * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
23 | * TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
24 | * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
25 | * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
26 | * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
27 | * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
28 | * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
29 | * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
30 | * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
31 | * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
32 | */
33 | #ifndef TCOD_GUI_TEXTBOX_HPP
34 | #define TCOD_GUI_TEXTBOX_HPP
35 | #include "widget.hpp"
36 | class TCODLIB_GUI_API TextBox : public Widget {
37 | public :
38 | TextBox(int x,int y,int w, int maxw, const char *label, const char *value, const char *tip=NULL);
39 | virtual ~TextBox();
40 | void render();
41 | void update(const TCOD_key_t k);
42 | void setText(const char *txt);
43 | const char *getValue() { return txt; }
44 | void setCallback(void (*cbk)(Widget *wid, char * val, void * data), void *data) { txtcbk=cbk; this->data=data; }
45 | static void setBlinkingDelay(float delay) { blinkingDelay=delay; }
46 | protected :
47 | static float blinkingDelay;
48 | char *label;
49 | char *txt;
50 | float blink;
51 | int pos, offset;
52 | int boxx,boxw,maxw;
53 | bool insert;
54 | void (*txtcbk)(Widget *wid, char * val, void *data);
55 | void *data;
56 |
57 | void onButtonClick();
58 | };
59 | #endif /* TCOD_GUI_TEXTBOX_HPP */
60 |
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/include/libtcod/gui/togglebutton.hpp:
--------------------------------------------------------------------------------
1 | /* libtcod
2 | * Copyright © 2008-2018 Jice and the libtcod contributers.
3 | * All rights reserved.
4 | *
5 | * libtcod 'The Doryen library' is a cross-platform C/C++ library for roguelike
6 | * developers.
7 | * Its source code is available from:
8 | * https://github.com/libtcod/libtcod
9 | *
10 | * Redistribution and use in source and binary forms, with or without
11 | * modification, are permitted provided that the following conditions are met:
12 | * * Redistributions of source code must retain the above copyright
13 | * notice, this list of conditions and the following disclaimer.
14 | * * Redistributions in binary form must reproduce the above copyright
15 | * notice, this list of conditions and the following disclaimer in the
16 | * documentation and/or other materials provided with the distribution.
17 | * * The name of copyright holder nor the names of its contributors may not
18 | * be used to endorse or promote products derived from this software
19 | * without specific prior written permission.
20 | *
21 | * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
22 | * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
23 | * TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
24 | * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
25 | * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
26 | * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
27 | * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
28 | * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
29 | * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
30 | * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
31 | * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
32 | */
33 | #ifndef TCOD_GUI_TOGGLEBUTTON_HPP
34 | #define TCOD_GUI_TOGGLEBUTTON_HPP
35 | #include "button.hpp"
36 | class TCODLIB_GUI_API ToggleButton : public Button {
37 | public :
38 | ToggleButton(const char *label, const char *tip, widget_callback_t cbk, void *userData=NULL)
39 | :Button(label, tip, cbk, userData) {}
40 | ToggleButton(int x, int y, int width, int height, const char *label, const char *tip, widget_callback_t cbk, void *userData=NULL)
41 | :Button(x, y, width, height, label, tip, cbk, userData) {}
42 | void render();
43 | bool isPressed() { return pressed; }
44 | void setPressed(bool val) { pressed=val; }
45 | protected :
46 | void onButtonPress();
47 | void onButtonRelease();
48 | void onButtonClick();
49 | };
50 | #endif /* TCOD_GUI_TOGGLEBUTTON_HPP */
51 |
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/include/libtcod/gui/toolbar.hpp:
--------------------------------------------------------------------------------
1 | /* libtcod
2 | * Copyright © 2008-2018 Jice and the libtcod contributers.
3 | * All rights reserved.
4 | *
5 | * libtcod 'The Doryen library' is a cross-platform C/C++ library for roguelike
6 | * developers.
7 | * Its source code is available from:
8 | * https://github.com/libtcod/libtcod
9 | *
10 | * Redistribution and use in source and binary forms, with or without
11 | * modification, are permitted provided that the following conditions are met:
12 | * * Redistributions of source code must retain the above copyright
13 | * notice, this list of conditions and the following disclaimer.
14 | * * Redistributions in binary form must reproduce the above copyright
15 | * notice, this list of conditions and the following disclaimer in the
16 | * documentation and/or other materials provided with the distribution.
17 | * * The name of copyright holder nor the names of its contributors may not
18 | * be used to endorse or promote products derived from this software
19 | * without specific prior written permission.
20 | *
21 | * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
22 | * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
23 | * TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
24 | * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
25 | * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
26 | * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
27 | * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
28 | * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
29 | * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
30 | * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
31 | * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
32 | */
33 | #ifndef TCOD_GUI_TOOLBAR_HPP
34 | #define TCOD_GUI_TOOLBAR_HPP
35 | #include "container.hpp"
36 | class TCODLIB_GUI_API ToolBar : public Container {
37 | public :
38 | ToolBar(int x, int y, const char *name, const char *tip=NULL);
39 | ToolBar(int x, int y, int w, const char *name, const char *tip=NULL);
40 | ~ToolBar();
41 | void render();
42 | void setName(const char *name);
43 | void addSeparator(const char *txt, const char *tip=NULL);
44 | void computeSize();
45 | protected :
46 | char *name;
47 | int fixedWidth;
48 | };
49 | #endif /* TCOD_GUI_TOOLBAR_HPP */
50 |
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/include/libtcod/gui/vbox.hpp:
--------------------------------------------------------------------------------
1 | /* libtcod
2 | * Copyright © 2008-2018 Jice and the libtcod contributers.
3 | * All rights reserved.
4 | *
5 | * libtcod 'The Doryen library' is a cross-platform C/C++ library for roguelike
6 | * developers.
7 | * Its source code is available from:
8 | * https://github.com/libtcod/libtcod
9 | *
10 | * Redistribution and use in source and binary forms, with or without
11 | * modification, are permitted provided that the following conditions are met:
12 | * * Redistributions of source code must retain the above copyright
13 | * notice, this list of conditions and the following disclaimer.
14 | * * Redistributions in binary form must reproduce the above copyright
15 | * notice, this list of conditions and the following disclaimer in the
16 | * documentation and/or other materials provided with the distribution.
17 | * * The name of copyright holder nor the names of its contributors may not
18 | * be used to endorse or promote products derived from this software
19 | * without specific prior written permission.
20 | *
21 | * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
22 | * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
23 | * TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
24 | * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
25 | * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
26 | * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
27 | * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
28 | * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
29 | * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
30 | * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
31 | * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
32 | */
33 | #ifndef TCOD_GUI_VBOX_HPP
34 | #define TCOD_GUI_VBOX_HPP
35 | #include "container.hpp"
36 | class TCODLIB_GUI_API VBox : public Container {
37 | public :
38 | VBox(int x, int y, int padding) : Container(x,y,0,0),padding(padding) {}
39 | void computeSize();
40 | protected :
41 | int padding;
42 | };
43 | #endif /* TCOD_GUI_VBOX_HPP */
44 |
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/include/libtcod/libtcod.h:
--------------------------------------------------------------------------------
1 | /* libtcod
2 | * Copyright © 2008-2018 Jice and the libtcod contributers.
3 | * All rights reserved.
4 | *
5 | * libtcod 'The Doryen library' is a cross-platform C/C++ library for roguelike
6 | * developers.
7 | * Its source code is available from:
8 | * https://github.com/libtcod/libtcod
9 | *
10 | * Redistribution and use in source and binary forms, with or without
11 | * modification, are permitted provided that the following conditions are met:
12 | * * Redistributions of source code must retain the above copyright
13 | * notice, this list of conditions and the following disclaimer.
14 | * * Redistributions in binary form must reproduce the above copyright
15 | * notice, this list of conditions and the following disclaimer in the
16 | * documentation and/or other materials provided with the distribution.
17 | * * The name of copyright holder nor the names of its contributors may not
18 | * be used to endorse or promote products derived from this software
19 | * without specific prior written permission.
20 | *
21 | * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
22 | * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
23 | * TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
24 | * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
25 | * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
26 | * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
27 | * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
28 | * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
29 | * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
30 | * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
31 | * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
32 | */
33 | #ifndef _LIBTCOD_H
34 | #define _LIBTCOD_H
35 |
36 | #include "portability.h"
37 | #include "utility.h"
38 | #include "version.h"
39 |
40 | #include "bresenham.h"
41 | #include "bsp.h"
42 | #include "color.h"
43 | #include "console.h"
44 | #include "fov.h"
45 | #include "heightmap.h"
46 | #include "image.h"
47 | #include "lex.h"
48 | #include "list.h"
49 | #include "mersenne.h"
50 | #include "mouse.h"
51 | #include "namegen.h"
52 | #include "noise.h"
53 | #include "path.h"
54 | #include "parser.h"
55 | #include "sys.h"
56 | #include "tree.h"
57 | #include "txtfield.h"
58 | #include "zip.h"
59 |
60 | #include "console/printing.h"
61 | #include "console/rexpaint.h"
62 |
63 | #include "tileset/observer.h"
64 | #include "tileset/tileset.h"
65 | #include "tileset/tile.h"
66 |
67 | #ifdef __cplusplus
68 | #include "bresenham.hpp"
69 | #include "bsp.hpp"
70 | #include "color.hpp"
71 | #include "console.hpp"
72 | #include "fov.hpp"
73 | #include "heightmap.hpp"
74 | #include "image.hpp"
75 | #include "lex.hpp"
76 | #include "list.hpp"
77 | #include "mersenne.hpp"
78 | #include "mouse.hpp"
79 | #include "namegen.hpp"
80 | #include "noise.hpp"
81 | #include "parser.hpp"
82 | #include "path.hpp"
83 | #include "sys.hpp"
84 | #include "tree.hpp"
85 | #include "txtfield.hpp"
86 | #include "zip.hpp"
87 | #endif // __cplusplus
88 |
89 | #endif
90 |
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/include/libtcod/libtcod.hpp:
--------------------------------------------------------------------------------
1 | /* libtcod
2 | * Copyright © 2008-2018 Jice and the libtcod contributers.
3 | * All rights reserved.
4 | *
5 | * libtcod 'The Doryen library' is a cross-platform C/C++ library for roguelike
6 | * developers.
7 | * Its source code is available from:
8 | * https://github.com/libtcod/libtcod
9 | *
10 | * Redistribution and use in source and binary forms, with or without
11 | * modification, are permitted provided that the following conditions are met:
12 | * * Redistributions of source code must retain the above copyright
13 | * notice, this list of conditions and the following disclaimer.
14 | * * Redistributions in binary form must reproduce the above copyright
15 | * notice, this list of conditions and the following disclaimer in the
16 | * documentation and/or other materials provided with the distribution.
17 | * * The name of copyright holder nor the names of its contributors may not
18 | * be used to endorse or promote products derived from this software
19 | * without specific prior written permission.
20 | *
21 | * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
22 | * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
23 | * TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
24 | * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
25 | * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
26 | * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
27 | * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
28 | * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
29 | * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
30 | * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
31 | * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
32 | */
33 | #include "libtcod.h"
34 |
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/include/libtcod/mersenne.h:
--------------------------------------------------------------------------------
1 | /* libtcod
2 | * Copyright © 2008-2018 Jice and the libtcod contributers.
3 | * All rights reserved.
4 | *
5 | * libtcod 'The Doryen library' is a cross-platform C/C++ library for roguelike
6 | * developers.
7 | * Its source code is available from:
8 | * https://github.com/libtcod/libtcod
9 | *
10 | * Redistribution and use in source and binary forms, with or without
11 | * modification, are permitted provided that the following conditions are met:
12 | * * Redistributions of source code must retain the above copyright
13 | * notice, this list of conditions and the following disclaimer.
14 | * * Redistributions in binary form must reproduce the above copyright
15 | * notice, this list of conditions and the following disclaimer in the
16 | * documentation and/or other materials provided with the distribution.
17 | * * The name of copyright holder nor the names of its contributors may not
18 | * be used to endorse or promote products derived from this software
19 | * without specific prior written permission.
20 | *
21 | * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
22 | * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
23 | * TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
24 | * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
25 | * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
26 | * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
27 | * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
28 | * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
29 | * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
30 | * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
31 | * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
32 | */
33 | #ifndef _TCOD_RANDOM_H
34 | #define _TCOD_RANDOM_H
35 |
36 | #include "portability.h"
37 | #include "mersenne_types.h"
38 |
39 | #ifdef __cplusplus
40 | extern "C" {
41 | #endif
42 | TCODLIB_API TCOD_random_t TCOD_random_get_instance(void);
43 | TCODLIB_API TCOD_random_t TCOD_random_new(TCOD_random_algo_t algo);
44 | TCODLIB_API TCOD_random_t TCOD_random_save(TCOD_random_t mersenne);
45 | TCODLIB_API void TCOD_random_restore(TCOD_random_t mersenne, TCOD_random_t backup);
46 | TCODLIB_API TCOD_random_t TCOD_random_new_from_seed(TCOD_random_algo_t algo, uint32_t seed);
47 | TCODLIB_API void TCOD_random_delete(TCOD_random_t mersenne);
48 |
49 | TCODLIB_API void TCOD_random_set_distribution (TCOD_random_t mersenne, TCOD_distribution_t distribution);
50 |
51 | TCODLIB_API int TCOD_random_get_int (TCOD_random_t mersenne, int min, int max);
52 | TCODLIB_API float TCOD_random_get_float (TCOD_random_t mersenne, float min, float max);
53 | TCODLIB_API double TCOD_random_get_double (TCOD_random_t mersenne, double min, double max);
54 |
55 | TCODLIB_API int TCOD_random_get_int_mean (TCOD_random_t mersenne, int min, int max, int mean);
56 | TCODLIB_API float TCOD_random_get_float_mean (TCOD_random_t mersenne, float min, float max, float mean);
57 | TCODLIB_API double TCOD_random_get_double_mean (TCOD_random_t mersenne, double min, double max, double mean);
58 |
59 | TCODLIB_API TCOD_dice_t TCOD_random_dice_new (const char * s);
60 | TCODLIB_API int TCOD_random_dice_roll (TCOD_random_t mersenne, TCOD_dice_t dice);
61 | TCODLIB_API int TCOD_random_dice_roll_s (TCOD_random_t mersenne, const char * s);
62 | #ifdef __cplusplus
63 | }
64 | #endif
65 | #endif
66 |
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/include/libtcod/mersenne_types.h:
--------------------------------------------------------------------------------
1 | /* libtcod
2 | * Copyright © 2008-2018 Jice and the libtcod contributers.
3 | * All rights reserved.
4 | *
5 | * libtcod 'The Doryen library' is a cross-platform C/C++ library for roguelike
6 | * developers.
7 | * Its source code is available from:
8 | * https://github.com/libtcod/libtcod
9 | *
10 | * Redistribution and use in source and binary forms, with or without
11 | * modification, are permitted provided that the following conditions are met:
12 | * * Redistributions of source code must retain the above copyright
13 | * notice, this list of conditions and the following disclaimer.
14 | * * Redistributions in binary form must reproduce the above copyright
15 | * notice, this list of conditions and the following disclaimer in the
16 | * documentation and/or other materials provided with the distribution.
17 | * * The name of copyright holder nor the names of its contributors may not
18 | * be used to endorse or promote products derived from this software
19 | * without specific prior written permission.
20 | *
21 | * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
22 | * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
23 | * TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
24 | * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
25 | * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
26 | * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
27 | * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
28 | * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
29 | * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
30 | * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
31 | * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
32 | */
33 | #ifndef _TCOD_RANDOM_TYPES_H
34 | #define _TCOD_RANDOM_TYPES_H
35 | struct TCOD_Random;
36 | typedef struct TCOD_Random *TCOD_random_t;
37 |
38 | /* dice roll */
39 | typedef struct {
40 | int nb_rolls;
41 | int nb_faces;
42 | float multiplier;
43 | float addsub;
44 | } TCOD_dice_t;
45 |
46 | /* PRNG algorithms */
47 | typedef enum {
48 | TCOD_RNG_MT,
49 | TCOD_RNG_CMWC
50 | } TCOD_random_algo_t;
51 |
52 | typedef enum {
53 | TCOD_DISTRIBUTION_LINEAR,
54 | TCOD_DISTRIBUTION_GAUSSIAN,
55 | TCOD_DISTRIBUTION_GAUSSIAN_RANGE,
56 | TCOD_DISTRIBUTION_GAUSSIAN_INVERSE,
57 | TCOD_DISTRIBUTION_GAUSSIAN_RANGE_INVERSE
58 | } TCOD_distribution_t;
59 | #endif /* _TCOD_RANDOM_TYPES_H */
60 |
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/include/libtcod/mouse.h:
--------------------------------------------------------------------------------
1 | /* libtcod
2 | * Copyright © 2008-2018 Jice and the libtcod contributers.
3 | * All rights reserved.
4 | *
5 | * libtcod 'The Doryen library' is a cross-platform C/C++ library for roguelike
6 | * developers.
7 | * Its source code is available from:
8 | * https://github.com/libtcod/libtcod
9 | *
10 | * Redistribution and use in source and binary forms, with or without
11 | * modification, are permitted provided that the following conditions are met:
12 | * * Redistributions of source code must retain the above copyright
13 | * notice, this list of conditions and the following disclaimer.
14 | * * Redistributions in binary form must reproduce the above copyright
15 | * notice, this list of conditions and the following disclaimer in the
16 | * documentation and/or other materials provided with the distribution.
17 | * * The name of copyright holder nor the names of its contributors may not
18 | * be used to endorse or promote products derived from this software
19 | * without specific prior written permission.
20 | *
21 | * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
22 | * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
23 | * TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
24 | * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
25 | * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
26 | * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
27 | * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
28 | * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
29 | * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
30 | * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
31 | * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
32 | */
33 | #ifndef _TCOD_MOUSE_H
34 | #define _TCOD_MOUSE_H
35 |
36 | #include "portability.h"
37 |
38 | #ifdef TCOD_CONSOLE_SUPPORT
39 |
40 | #include "mouse_types.h"
41 |
42 | #ifdef __cplusplus
43 | extern "C" {
44 | #endif
45 | TCODLIB_API void TCOD_mouse_show_cursor(bool visible);
46 | TCODLIB_API TCOD_mouse_t TCOD_mouse_get_status(void);
47 | TCODLIB_API bool TCOD_mouse_is_cursor_visible(void);
48 | TCODLIB_API void TCOD_mouse_move(int x, int y);
49 | TCODLIB_API void TCOD_mouse_includes_touch(bool enable);
50 | #ifdef __cplusplus
51 | }
52 | #endif
53 |
54 | #endif /* TCOD_CONSOLE_SUPPORT */
55 |
56 | #endif /* _TCOD_MOUSE_H */
57 |
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/include/libtcod/mouse_types.h:
--------------------------------------------------------------------------------
1 | /* libtcod
2 | * Copyright © 2008-2018 Jice and the libtcod contributers.
3 | * All rights reserved.
4 | *
5 | * libtcod 'The Doryen library' is a cross-platform C/C++ library for roguelike
6 | * developers.
7 | * Its source code is available from:
8 | * https://github.com/libtcod/libtcod
9 | *
10 | * Redistribution and use in source and binary forms, with or without
11 | * modification, are permitted provided that the following conditions are met:
12 | * * Redistributions of source code must retain the above copyright
13 | * notice, this list of conditions and the following disclaimer.
14 | * * Redistributions in binary form must reproduce the above copyright
15 | * notice, this list of conditions and the following disclaimer in the
16 | * documentation and/or other materials provided with the distribution.
17 | * * The name of copyright holder nor the names of its contributors may not
18 | * be used to endorse or promote products derived from this software
19 | * without specific prior written permission.
20 | *
21 | * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
22 | * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
23 | * TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
24 | * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
25 | * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
26 | * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
27 | * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
28 | * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
29 | * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
30 | * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
31 | * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
32 | */
33 | #ifndef _TCOD_MOUSE_TYPES_H
34 | #define _TCOD_MOUSE_TYPES_H
35 |
36 | #include "portability.h"
37 | /* mouse data */
38 | typedef struct {
39 | int x,y; /* absolute position */
40 | int dx,dy; /* movement since last update in pixels */
41 | int cx,cy; /* cell coordinates in the root console */
42 | int dcx,dcy; /* movement since last update in console cells */
43 | bool lbutton ; /* left button status */
44 | bool rbutton ; /* right button status */
45 | bool mbutton ; /* middle button status */
46 | bool lbutton_pressed ; /* left button pressed event */
47 | bool rbutton_pressed ; /* right button pressed event */
48 | bool mbutton_pressed ; /* middle button pressed event */
49 | bool wheel_up ; /* wheel up event */
50 | bool wheel_down ; /* wheel down event */
51 | } TCOD_mouse_t;
52 | #endif /* _TCOD_MOUSE_TYPES_H */
53 |
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/include/libtcod/namegen.h:
--------------------------------------------------------------------------------
1 | /* libtcod
2 | * Copyright © 2008-2018 Jice and the libtcod contributers.
3 | * All rights reserved.
4 | *
5 | * libtcod 'The Doryen library' is a cross-platform C/C++ library for roguelike
6 | * developers.
7 | * Its source code is available from:
8 | * https://github.com/libtcod/libtcod
9 | *
10 | * Redistribution and use in source and binary forms, with or without
11 | * modification, are permitted provided that the following conditions are met:
12 | * * Redistributions of source code must retain the above copyright
13 | * notice, this list of conditions and the following disclaimer.
14 | * * Redistributions in binary form must reproduce the above copyright
15 | * notice, this list of conditions and the following disclaimer in the
16 | * documentation and/or other materials provided with the distribution.
17 | * * The name of copyright holder nor the names of its contributors may not
18 | * be used to endorse or promote products derived from this software
19 | * without specific prior written permission.
20 | *
21 | * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
22 | * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
23 | * TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
24 | * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
25 | * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
26 | * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
27 | * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
28 | * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
29 | * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
30 | * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
31 | * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
32 | */
33 | /*
34 | * Mingos' NameGen
35 | * This file was written by Dominik "Mingos" Marczuk.
36 | */
37 |
38 | #ifndef _TCOD_NAMEGEN_H
39 | #define _TCOD_NAMEGEN_H
40 |
41 | #include "portability.h"
42 | #include "list.h"
43 | #include "mersenne.h"
44 |
45 | #ifdef __cplusplus
46 | extern "C" {
47 | #endif
48 | /* the generator typedef */
49 | struct TCOD_NameGen;
50 | typedef struct TCOD_NameGen *TCOD_namegen_t;
51 |
52 | /* parse a file with syllable sets */
53 | TCODLIB_API void TCOD_namegen_parse (const char * filename, TCOD_random_t random);
54 | /* generate a name */
55 | TCODLIB_API char * TCOD_namegen_generate (char * name, bool allocate);
56 | /* generate a name using a custom generation rule */
57 | TCODLIB_API char * TCOD_namegen_generate_custom (char * name, char * rule, bool allocate);
58 | /* retrieve the list of all available syllable set names */
59 | TCODLIB_API TCOD_list_t TCOD_namegen_get_sets (void);
60 | /* delete a generator */
61 | TCODLIB_API void TCOD_namegen_destroy (void);
62 | #ifdef __cplusplus
63 | }
64 | #endif
65 | #endif
66 |
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/include/libtcod/noise_defaults.h:
--------------------------------------------------------------------------------
1 | /* libtcod
2 | * Copyright © 2008-2018 Jice and the libtcod contributers.
3 | * All rights reserved.
4 | *
5 | * libtcod 'The Doryen library' is a cross-platform C/C++ library for roguelike
6 | * developers.
7 | * Its source code is available from:
8 | * https://github.com/libtcod/libtcod
9 | *
10 | * Redistribution and use in source and binary forms, with or without
11 | * modification, are permitted provided that the following conditions are met:
12 | * * Redistributions of source code must retain the above copyright
13 | * notice, this list of conditions and the following disclaimer.
14 | * * Redistributions in binary form must reproduce the above copyright
15 | * notice, this list of conditions and the following disclaimer in the
16 | * documentation and/or other materials provided with the distribution.
17 | * * The name of copyright holder nor the names of its contributors may not
18 | * be used to endorse or promote products derived from this software
19 | * without specific prior written permission.
20 | *
21 | * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
22 | * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
23 | * TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
24 | * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
25 | * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
26 | * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
27 | * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
28 | * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
29 | * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
30 | * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
31 | * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
32 | */
33 | #ifndef _TCOD_NOISE_DEFAULTS
34 | #define _TCOD_NOISE_DEFAULTS
35 |
36 | #define TCOD_NOISE_MAX_OCTAVES 128
37 | #define TCOD_NOISE_MAX_DIMENSIONS 4
38 | #define TCOD_NOISE_DEFAULT_HURST 0.5f
39 | #define TCOD_NOISE_DEFAULT_LACUNARITY 2.0f
40 |
41 | #endif /* _TCOD_NOISE_DEFAULTS */
42 |
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/include/libtcod/sdl2/gl2_display.h:
--------------------------------------------------------------------------------
1 | /* libtcod
2 | * Copyright © 2008-2018 Jice and the libtcod contributers.
3 | * All rights reserved.
4 | *
5 | * libtcod 'The Doryen library' is a cross-platform C/C++ library for roguelike
6 | * developers.
7 | * Its source code is available from:
8 | * https://github.com/libtcod/libtcod
9 | *
10 | * Redistribution and use in source and binary forms, with or without
11 | * modification, are permitted provided that the following conditions are met:
12 | * * Redistributions of source code must retain the above copyright
13 | * notice, this list of conditions and the following disclaimer.
14 | * * Redistributions in binary form must reproduce the above copyright
15 | * notice, this list of conditions and the following disclaimer in the
16 | * documentation and/or other materials provided with the distribution.
17 | * * The name of copyright holder nor the names of its contributors may not
18 | * be used to endorse or promote products derived from this software
19 | * without specific prior written permission.
20 | *
21 | * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
22 | * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
23 | * TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
24 | * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
25 | * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
26 | * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
27 | * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
28 | * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
29 | * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
30 | * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
31 | * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
32 | */
33 | #ifndef LIBTCOD_SDL2_GL2_DISPLAY_H_
34 | #define LIBTCOD_SDL2_GL2_DISPLAY_H_
35 |
36 | #include "gl2_renderer.h"
37 | #include "sdl2_display.h"
38 |
39 | namespace tcod {
40 | namespace sdl2 {
41 | class OpenGL2Display: public WindowedDisplay {
42 | public:
43 | explicit OpenGL2Display(
44 | std::shared_ptr tileset,
45 | std::pair window_size,
46 | int window_flags,
47 | const std::string& title);
48 | virtual void set_tileset(std::shared_ptr tileset) override;
49 | virtual void present(const TCOD_Console*) override;
50 | private:
51 | std::shared_ptr glcontext_;
52 | OpenGL2Renderer tcod_renderer_;
53 | };
54 | } // namespace sdl2
55 | } // namespace tcod
56 | #endif //LIBTCOD_SDL2_GL2_DISPLAY_H_
57 |
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/include/libtcod/sdl2/gl2_ext_.h:
--------------------------------------------------------------------------------
1 | /* libtcod
2 | * Copyright © 2008-2018 Jice and the libtcod contributers.
3 | * All rights reserved.
4 | *
5 | * libtcod 'The Doryen library' is a cross-platform C/C++ library for roguelike
6 | * developers.
7 | * Its source code is available from:
8 | * https://github.com/libtcod/libtcod
9 | *
10 | * Redistribution and use in source and binary forms, with or without
11 | * modification, are permitted provided that the following conditions are met:
12 | * * Redistributions of source code must retain the above copyright
13 | * notice, this list of conditions and the following disclaimer.
14 | * * Redistributions in binary form must reproduce the above copyright
15 | * notice, this list of conditions and the following disclaimer in the
16 | * documentation and/or other materials provided with the distribution.
17 | * * The name of copyright holder nor the names of its contributors may not
18 | * be used to endorse or promote products derived from this software
19 | * without specific prior written permission.
20 | *
21 | * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
22 | * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
23 | * TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
24 | * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
25 | * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
26 | * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
27 | * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
28 | * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
29 | * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
30 | * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
31 | * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
32 | */
33 | #ifndef LIBTCOD_SDL2_GL2_EXT_H_
34 | #define LIBTCOD_SDL2_GL2_EXT_H_
35 | #include
36 |
37 | #include
38 | namespace tcod {
39 | namespace sdl2 {
40 | class opengl_error : public std::runtime_error {
41 | public:
42 | explicit opengl_error(const std::string& what_arg)
43 | : runtime_error(what_arg)
44 | {};
45 | };
46 | inline void gl_check() {
47 | #ifndef NDEBUG
48 | switch(glGetError()) {
49 | case GL_NO_ERROR:
50 | return;
51 | case GL_INVALID_ENUM:
52 | throw opengl_error("GL_INVALID_ENUM");
53 | case GL_INVALID_VALUE:
54 | throw opengl_error("GL_INVALID_VALUE");
55 | case GL_INVALID_OPERATION:
56 | throw opengl_error("GL_INVALID_OPERATION");
57 | //case GL_INVALID_FRAMEBUFFER_OPERATION:
58 | // throw opengl_error("GL_INVALID_FRAMEBUFFER_OPERATION");
59 | case GL_OUT_OF_MEMORY:
60 | throw opengl_error("GL_OUT_OF_MEMORY");
61 | default:
62 | throw opengl_error("Unknown OpenGL error.");
63 | }
64 | #endif // NDEBUG
65 | }
66 | } // namespace sdl2
67 | } // namespace tcod
68 | #endif // LIBTCOD_SDL2_GL2_EXT_H_
69 |
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/include/libtcod/sdl2/gl2_renderer.h:
--------------------------------------------------------------------------------
1 | /* libtcod
2 | * Copyright © 2008-2018 Jice and the libtcod contributers.
3 | * All rights reserved.
4 | *
5 | * libtcod 'The Doryen library' is a cross-platform C/C++ library for roguelike
6 | * developers.
7 | * Its source code is available from:
8 | * https://github.com/libtcod/libtcod
9 | *
10 | * Redistribution and use in source and binary forms, with or without
11 | * modification, are permitted provided that the following conditions are met:
12 | * * Redistributions of source code must retain the above copyright
13 | * notice, this list of conditions and the following disclaimer.
14 | * * Redistributions in binary form must reproduce the above copyright
15 | * notice, this list of conditions and the following disclaimer in the
16 | * documentation and/or other materials provided with the distribution.
17 | * * The name of copyright holder nor the names of its contributors may not
18 | * be used to endorse or promote products derived from this software
19 | * without specific prior written permission.
20 | *
21 | * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
22 | * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
23 | * TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
24 | * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
25 | * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
26 | * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
27 | * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
28 | * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
29 | * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
30 | * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
31 | * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
32 | */
33 | #ifndef LIBTCOD_SDL2_GL2_RENDERER_H_
34 | #define LIBTCOD_SDL2_GL2_RENDERER_H_
35 | #ifdef __cplusplus
36 | #endif /* __cplusplus */
37 | #include
38 |
39 | #include "gl_alias.h"
40 | #include "gl2_raii.h"
41 | #include "../color/color.h"
42 | #include "../console_types.h"
43 | #include "../tileset/observer.h"
44 | #include "../tileset/tileset.h"
45 | #include "../utility/vector2.h"
46 | #ifdef __cplusplus
47 | namespace tcod {
48 | namespace sdl2 {
49 | using tcod::tileset::Tileset;
50 | class OpenGL2Renderer {
51 | public:
52 | explicit OpenGL2Renderer(OpenGLTilesetAlias alias);
53 | explicit OpenGL2Renderer(std::shared_ptr tileset)
54 | : OpenGL2Renderer(OpenGLTilesetAlias(tileset))
55 | {}
56 | OpenGL2Renderer(const OpenGL2Renderer&) = delete;
57 | OpenGL2Renderer& operator=(const OpenGL2Renderer&) = delete;
58 | OpenGL2Renderer(OpenGL2Renderer&&) noexcept;
59 | OpenGL2Renderer& operator=(OpenGL2Renderer&&) noexcept;
60 | ~OpenGL2Renderer() noexcept;
61 |
62 | void render(const TCOD_Console* console);
63 | private:
64 | class impl;
65 | std::unique_ptr impl_;
66 | };
67 | } // namespace sdl2
68 | } // namespace tcod
69 | #endif // __cplusplus
70 | #endif // LIBTCOD_SDL2_GL2_RENDERER_H_
71 |
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/include/libtcod/sdl2/gl_alias.h:
--------------------------------------------------------------------------------
1 | /* libtcod
2 | * Copyright © 2008-2018 Jice and the libtcod contributers.
3 | * All rights reserved.
4 | *
5 | * libtcod 'The Doryen library' is a cross-platform C/C++ library for roguelike
6 | * developers.
7 | * Its source code is available from:
8 | * https://github.com/libtcod/libtcod
9 | *
10 | * Redistribution and use in source and binary forms, with or without
11 | * modification, are permitted provided that the following conditions are met:
12 | * * Redistributions of source code must retain the above copyright
13 | * notice, this list of conditions and the following disclaimer.
14 | * * Redistributions in binary form must reproduce the above copyright
15 | * notice, this list of conditions and the following disclaimer in the
16 | * documentation and/or other materials provided with the distribution.
17 | * * The name of copyright holder nor the names of its contributors may not
18 | * be used to endorse or promote products derived from this software
19 | * without specific prior written permission.
20 | *
21 | * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
22 | * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
23 | * TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
24 | * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
25 | * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
26 | * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
27 | * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
28 | * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
29 | * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
30 | * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
31 | * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
32 | */
33 | #ifndef LIBTCOD_SDL2_GL_ALIAS_H_
34 | #define LIBTCOD_SDL2_GL_ALIAS_H_
35 | #include
36 | #include
37 | #include
38 |
39 | #include "../tileset/observer.h"
40 | #ifdef __cplusplus
41 | struct SDL_Renderer;
42 | struct SDL_Texture;
43 | struct SDL_Rect;
44 |
45 | namespace tcod {
46 | namespace sdl2 {
47 | using tileset::Tile;
48 | using tileset::Tileset;
49 | using tileset::TilesetObserver;
50 |
51 | class OpenGLTilesetAlias {
52 | public:
53 | OpenGLTilesetAlias() = default;
54 | explicit OpenGLTilesetAlias(std::shared_ptr tileset);
55 | ~OpenGLTilesetAlias() = default;
56 |
57 | const std::shared_ptr& get_tileset();
58 |
59 | uint32_t get_alias_texture();
60 | std::array get_alias_shape();
61 | std::array get_alias_size();
62 | std::array get_tile_position(int codepoint);
63 | private:
64 | std::shared_ptr alias_;
65 | };
66 | } // namespace sdl2
67 | } // namespace tcod
68 | #endif // __cplusplus
69 | #endif // LIBTCOD_SDL2_GL_ALIAS_H_
70 |
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/include/libtcod/sdl2/legacy_backend.h:
--------------------------------------------------------------------------------
1 | /* libtcod
2 | * Copyright © 2008-2018 Jice and the libtcod contributers.
3 | * All rights reserved.
4 | *
5 | * libtcod 'The Doryen library' is a cross-platform C/C++ library for roguelike
6 | * developers.
7 | * Its source code is available from:
8 | * https://github.com/libtcod/libtcod
9 | *
10 | * Redistribution and use in source and binary forms, with or without
11 | * modification, are permitted provided that the following conditions are met:
12 | * * Redistributions of source code must retain the above copyright
13 | * notice, this list of conditions and the following disclaimer.
14 | * * Redistributions in binary form must reproduce the above copyright
15 | * notice, this list of conditions and the following disclaimer in the
16 | * documentation and/or other materials provided with the distribution.
17 | * * The name of copyright holder nor the names of its contributors may not
18 | * be used to endorse or promote products derived from this software
19 | * without specific prior written permission.
20 | *
21 | * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
22 | * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
23 | * TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
24 | * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
25 | * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
26 | * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
27 | * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
28 | * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
29 | * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
30 | * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
31 | * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
32 | */
33 | #ifndef LIBTCOD_SDL2_LEGACY_BACKEND_H_
34 | #define LIBTCOD_SDL2_LEGACY_BACKEND_H_
35 |
36 | #ifdef __cplusplus
37 | namespace tcod {
38 | namespace sdl2 {
39 | } // namespace sdl2
40 | } // namespace tcod
41 | #endif /* __cplusplus */
42 | #endif /* LIBTCOD_SDL2_LEGACY_BACKEND_H_ */
43 |
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/include/libtcod/sdl2/sdl2_alias.h:
--------------------------------------------------------------------------------
1 | /* libtcod
2 | * Copyright © 2008-2018 Jice and the libtcod contributers.
3 | * All rights reserved.
4 | *
5 | * libtcod 'The Doryen library' is a cross-platform C/C++ library for roguelike
6 | * developers.
7 | * Its source code is available from:
8 | * https://github.com/libtcod/libtcod
9 | *
10 | * Redistribution and use in source and binary forms, with or without
11 | * modification, are permitted provided that the following conditions are met:
12 | * * Redistributions of source code must retain the above copyright
13 | * notice, this list of conditions and the following disclaimer.
14 | * * Redistributions in binary form must reproduce the above copyright
15 | * notice, this list of conditions and the following disclaimer in the
16 | * documentation and/or other materials provided with the distribution.
17 | * * The name of copyright holder nor the names of its contributors may not
18 | * be used to endorse or promote products derived from this software
19 | * without specific prior written permission.
20 | *
21 | * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
22 | * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
23 | * TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
24 | * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
25 | * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
26 | * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
27 | * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
28 | * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
29 | * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
30 | * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
31 | * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
32 | */
33 | #ifndef LIBTCOD_SDL2_SDL2_ALIAS_H_
34 | #define LIBTCOD_SDL2_SDL2_ALIAS_H_
35 | #include
36 |
37 | #include "../tileset/observer.h"
38 | #ifdef __cplusplus
39 | struct SDL_Renderer;
40 | struct SDL_Texture;
41 | struct SDL_Rect;
42 |
43 | namespace tcod {
44 | namespace sdl2 {
45 | using tileset::Tile;
46 | using tileset::Tileset;
47 | using tileset::TilesetObserver;
48 | class SDL2InternalTilesetAlias_;
49 |
50 | class SDL2TilesetAlias {
51 | public:
52 | SDL2TilesetAlias() = default;
53 | SDL2TilesetAlias(struct SDL_Renderer* renderer,
54 | std::shared_ptr tileset);
55 |
56 | std::shared_ptr& get_tileset();
57 |
58 | SDL_Texture* get_texture_alias();
59 | SDL_Rect get_char_rect(int codepoint);
60 | private:
61 | std::shared_ptr alias_;
62 | };
63 | } // namespace sdl2
64 | } // namespace tcod
65 | #endif // __cplusplus
66 | #endif // LIBTCOD_SDL2_SDL2_ALIAS_H_
67 |
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/include/libtcod/sdl2/sdl2_display.h:
--------------------------------------------------------------------------------
1 | /* libtcod
2 | * Copyright © 2008-2018 Jice and the libtcod contributers.
3 | * All rights reserved.
4 | *
5 | * libtcod 'The Doryen library' is a cross-platform C/C++ library for roguelike
6 | * developers.
7 | * Its source code is available from:
8 | * https://github.com/libtcod/libtcod
9 | *
10 | * Redistribution and use in source and binary forms, with or without
11 | * modification, are permitted provided that the following conditions are met:
12 | * * Redistributions of source code must retain the above copyright
13 | * notice, this list of conditions and the following disclaimer.
14 | * * Redistributions in binary form must reproduce the above copyright
15 | * notice, this list of conditions and the following disclaimer in the
16 | * documentation and/or other materials provided with the distribution.
17 | * * The name of copyright holder nor the names of its contributors may not
18 | * be used to endorse or promote products derived from this software
19 | * without specific prior written permission.
20 | *
21 | * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
22 | * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
23 | * TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
24 | * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
25 | * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
26 | * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
27 | * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
28 | * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
29 | * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
30 | * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
31 | * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
32 | */
33 | #ifndef LIBTCOD_SDL2_SDL2_DISPLAY_H_
34 | #define LIBTCOD_SDL2_SDL2_DISPLAY_H_
35 |
36 | #ifdef __cplusplus
37 | #include
38 | #include
39 | #include
40 | #endif // __cplusplus
41 |
42 | #include "sdl2_renderer.h"
43 | #include "../engine/display.h"
44 |
45 | struct SDL_Window;
46 | struct SDL_Renderer;
47 | #ifdef __cplusplus
48 | namespace tcod {
49 | namespace sdl2 {
50 | /**
51 | * Incomplete interface for subclasses expecting an SDL2 window.
52 | */
53 | class WindowedDisplay: public engine::Display {
54 | public:
55 | WindowedDisplay(std::pair window_size, int window_flags,
56 | const std::string& title);
57 | virtual void set_title(const std::string title) override;
58 | virtual std::string get_title() override;
59 | virtual void set_fullscreen(bool fullscreen) override;
60 | virtual int get_fullscreen() override;
61 | SDL_Window* get_window() { return window_.get(); }
62 | private:
63 | std::shared_ptr window_;
64 | };
65 | /**
66 | * Display interface using a basic SDL2 renderer.
67 | */
68 | class SDL2Display: public WindowedDisplay {
69 | public:
70 | SDL2Display(
71 | std::shared_ptr tileset,
72 | std::pair window_size,
73 | int window_flags,
74 | const std::string& title);
75 | virtual void set_tileset(std::shared_ptr tileset) override;
76 | virtual void present(const TCOD_Console*) override;
77 | private:
78 | std::shared_ptr renderer_;
79 | SDL2Renderer tcod_renderer_;
80 | };
81 | } // namespace sdl2
82 | } // namespace tcod
83 | #endif // __cplusplus
84 | #endif // LIBTCOD_SDL2_SDL2_DISPLAY_H_
85 |
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/include/libtcod/sdl2/sdl2_renderer.h:
--------------------------------------------------------------------------------
1 | /* libtcod
2 | * Copyright © 2008-2018 Jice and the libtcod contributers.
3 | * All rights reserved.
4 | *
5 | * libtcod 'The Doryen library' is a cross-platform C/C++ library for roguelike
6 | * developers.
7 | * Its source code is available from:
8 | * https://github.com/libtcod/libtcod
9 | *
10 | * Redistribution and use in source and binary forms, with or without
11 | * modification, are permitted provided that the following conditions are met:
12 | * * Redistributions of source code must retain the above copyright
13 | * notice, this list of conditions and the following disclaimer.
14 | * * Redistributions in binary form must reproduce the above copyright
15 | * notice, this list of conditions and the following disclaimer in the
16 | * documentation and/or other materials provided with the distribution.
17 | * * The name of copyright holder nor the names of its contributors may not
18 | * be used to endorse or promote products derived from this software
19 | * without specific prior written permission.
20 | *
21 | * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
22 | * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
23 | * TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
24 | * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
25 | * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
26 | * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
27 | * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
28 | * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
29 | * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
30 | * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
31 | * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
32 | */
33 | #ifndef LIBTCOD_SDL2_SDL2_RENDERER_H_
34 | #define LIBTCOD_SDL2_SDL2_RENDERER_H_
35 | #ifdef __cplusplus
36 | #include
37 | #endif /* __cplusplus */
38 |
39 | #include "sdl2_alias.h"
40 | #include "../color/color.h"
41 | #include "../console_types.h"
42 | #include "../tileset/observer.h"
43 | #include "../tileset/tileset.h"
44 | #include "../utility/vector2.h"
45 | #ifdef __cplusplus
46 | struct SDL_Renderer;
47 | struct SDL_Texture;
48 | namespace tcod {
49 | namespace sdl2 {
50 | using tcod::tileset::Tileset;
51 | class SDL2Renderer: public TilesetObserver {
52 | public:
53 | SDL2Renderer()
54 | {}
55 | SDL2Renderer(struct SDL_Renderer* renderer, SDL2TilesetAlias alias)
56 | : TilesetObserver(alias.get_tileset()), alias_{alias}, renderer_{renderer}
57 | {}
58 |
59 | SDL2Renderer(struct SDL_Renderer* renderer,
60 | std::shared_ptr tileset)
61 | : SDL2Renderer(renderer, SDL2TilesetAlias(renderer, tileset))
62 | {}
63 |
64 | ~SDL2Renderer();
65 |
66 | struct SDL_Texture* render(const TCOD_Console* console);
67 | private:
68 | using cache_type = Vector2>;
69 | SDL2TilesetAlias alias_;
70 | cache_type cache_;
71 | struct SDL_Renderer* renderer_;
72 | struct SDL_Texture* texture_ = nullptr;
73 | };
74 | } // namespace sdl2
75 | } // namespace tcod
76 | #endif /* __cplusplus */
77 | #endif /* LIBTCOD_SDL2_SDL2_RENDERER_H_ */
78 |
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/include/libtcod/tileset/tile.h:
--------------------------------------------------------------------------------
1 | /* libtcod
2 | * Copyright © 2008-2018 Jice and the libtcod contributers.
3 | * All rights reserved.
4 | *
5 | * libtcod 'The Doryen library' is a cross-platform C/C++ library for roguelike
6 | * developers.
7 | * Its source code is available from:
8 | * https://github.com/libtcod/libtcod
9 | *
10 | * Redistribution and use in source and binary forms, with or without
11 | * modification, are permitted provided that the following conditions are met:
12 | * * Redistributions of source code must retain the above copyright
13 | * notice, this list of conditions and the following disclaimer.
14 | * * Redistributions in binary form must reproduce the above copyright
15 | * notice, this list of conditions and the following disclaimer in the
16 | * documentation and/or other materials provided with the distribution.
17 | * * The name of copyright holder nor the names of its contributors may not
18 | * be used to endorse or promote products derived from this software
19 | * without specific prior written permission.
20 | *
21 | * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
22 | * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
23 | * TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
24 | * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
25 | * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
26 | * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
27 | * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
28 | * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
29 | * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
30 | * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
31 | * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
32 | */
33 | #ifndef LIBTCOD_TILESET_TILE_H_
34 | #define LIBTCOD_TILESET_TILE_H_
35 | #include
36 | #ifdef __cplusplus
37 | #include
38 | #include
39 | #endif
40 |
41 | #include "../portability.h"
42 | #include "../color/canvas.h"
43 | #ifdef __cplusplus
44 | namespace tcod {
45 | namespace tileset {
46 | using image::Image;
47 |
48 | class Tile {
49 | public:
50 | Tile();
51 | explicit Tile(int codepoint, const Image &image)
52 | : codepoint(codepoint), image_(image)
53 | {}
54 | explicit Tile(int codepoint, int width, int height)
55 | : Tile(codepoint, Image(width, height))
56 | {}
57 |
58 | int width(void) const { return image_.width(); }
59 | int height(void) const { return image_.height(); }
60 | Image get_image() const {
61 | return image_;
62 | }
63 | const int codepoint;
64 | private:
65 | Image image_;
66 | };
67 | } // namespace tileset
68 | } // namespace tcod
69 | #endif // __cplusplus
70 | #endif // LIBTCOD_TILESET_TILE_H_
71 |
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/include/libtcod/tree.h:
--------------------------------------------------------------------------------
1 | /* libtcod
2 | * Copyright © 2008-2018 Jice and the libtcod contributers.
3 | * All rights reserved.
4 | *
5 | * libtcod 'The Doryen library' is a cross-platform C/C++ library for roguelike
6 | * developers.
7 | * Its source code is available from:
8 | * https://github.com/libtcod/libtcod
9 | *
10 | * Redistribution and use in source and binary forms, with or without
11 | * modification, are permitted provided that the following conditions are met:
12 | * * Redistributions of source code must retain the above copyright
13 | * notice, this list of conditions and the following disclaimer.
14 | * * Redistributions in binary form must reproduce the above copyright
15 | * notice, this list of conditions and the following disclaimer in the
16 | * documentation and/or other materials provided with the distribution.
17 | * * The name of copyright holder nor the names of its contributors may not
18 | * be used to endorse or promote products derived from this software
19 | * without specific prior written permission.
20 | *
21 | * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
22 | * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
23 | * TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
24 | * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
25 | * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
26 | * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
27 | * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
28 | * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
29 | * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
30 | * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
31 | * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
32 | */
33 | #ifndef _TCOD_TREE_H
34 | #define _TCOD_TREE_H
35 |
36 | #include "portability.h"
37 |
38 | #ifdef __cplusplus
39 | extern "C" {
40 | #endif
41 | typedef struct _TCOD_tree_t {
42 | struct _TCOD_tree_t *next;
43 | struct _TCOD_tree_t *father;
44 | struct _TCOD_tree_t *sons;
45 | } TCOD_tree_t;
46 |
47 | TCODLIB_API TCOD_tree_t *TCOD_tree_new(void);
48 | TCODLIB_API void TCOD_tree_add_son(TCOD_tree_t *node, TCOD_tree_t *son);
49 | #ifdef __cplusplus
50 | }
51 | #endif
52 | #endif
53 |
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/include/libtcod/tree.hpp:
--------------------------------------------------------------------------------
1 | /* libtcod
2 | * Copyright © 2008-2018 Jice and the libtcod contributers.
3 | * All rights reserved.
4 | *
5 | * libtcod 'The Doryen library' is a cross-platform C/C++ library for roguelike
6 | * developers.
7 | * Its source code is available from:
8 | * https://github.com/libtcod/libtcod
9 | *
10 | * Redistribution and use in source and binary forms, with or without
11 | * modification, are permitted provided that the following conditions are met:
12 | * * Redistributions of source code must retain the above copyright
13 | * notice, this list of conditions and the following disclaimer.
14 | * * Redistributions in binary form must reproduce the above copyright
15 | * notice, this list of conditions and the following disclaimer in the
16 | * documentation and/or other materials provided with the distribution.
17 | * * The name of copyright holder nor the names of its contributors may not
18 | * be used to endorse or promote products derived from this software
19 | * without specific prior written permission.
20 | *
21 | * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
22 | * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
23 | * TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
24 | * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
25 | * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
26 | * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
27 | * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
28 | * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
29 | * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
30 | * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
31 | * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
32 | */
33 | #ifndef _TCOD_TREE_HPP
34 | #define _TCOD_TREE_HPP
35 |
36 | #include "tree.h"
37 |
38 | class TCODLIB_API TCODTree {
39 | public :
40 | TCODTree *next;
41 | TCODTree *father;
42 | TCODTree *sons;
43 |
44 | TCODTree() : next(NULL),father(NULL),sons(NULL){}
45 | void addSon(TCODTree *data) {
46 | data->father=this;
47 | TCODTree *lastson = sons;
48 | while ( lastson && lastson->next ) lastson=lastson->next;
49 | if ( lastson ) {
50 | lastson->next=data;
51 | } else {
52 | sons=data;
53 | }
54 | }
55 |
56 | };
57 |
58 | #endif
59 |
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/include/libtcod/txtfield.h:
--------------------------------------------------------------------------------
1 | /* libtcod
2 | * Copyright © 2008-2018 Jice and the libtcod contributers.
3 | * All rights reserved.
4 | *
5 | * libtcod 'The Doryen library' is a cross-platform C/C++ library for roguelike
6 | * developers.
7 | * Its source code is available from:
8 | * https://github.com/libtcod/libtcod
9 | *
10 | * Redistribution and use in source and binary forms, with or without
11 | * modification, are permitted provided that the following conditions are met:
12 | * * Redistributions of source code must retain the above copyright
13 | * notice, this list of conditions and the following disclaimer.
14 | * * Redistributions in binary form must reproduce the above copyright
15 | * notice, this list of conditions and the following disclaimer in the
16 | * documentation and/or other materials provided with the distribution.
17 | * * The name of copyright holder nor the names of its contributors may not
18 | * be used to endorse or promote products derived from this software
19 | * without specific prior written permission.
20 | *
21 | * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
22 | * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
23 | * TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
24 | * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
25 | * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
26 | * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
27 | * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
28 | * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
29 | * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
30 | * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
31 | * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
32 | */
33 | #ifndef _TCOD_TEXT_H_
34 | #define _TCOD_TEXT_H_
35 |
36 | #include "portability.h"
37 |
38 | #ifdef TCOD_CONSOLE_SUPPORT
39 |
40 | #include "color.h"
41 | #include "console_types.h"
42 |
43 | #ifdef __cplusplus
44 | extern "C" {
45 | #endif
46 | struct TCOD_Text;
47 | typedef struct TCOD_Text *TCOD_text_t;
48 |
49 | TCODLIB_API TCOD_text_t TCOD_text_init(int x, int y, int w, int h, int max_chars);
50 | TCODLIB_API TCOD_text_t TCOD_text_init2(int w, int h, int max_chars);
51 | TCODLIB_API void TCOD_text_set_pos(TCOD_text_t txt, int x, int y);
52 | TCODLIB_API void TCOD_text_set_properties(TCOD_text_t txt, int cursor_char, int blink_interval, const char * prompt, int tab_size);
53 | TCODLIB_API void TCOD_text_set_colors(TCOD_text_t txt, TCOD_color_t fore, TCOD_color_t back, float back_transparency);
54 | TCODLIB_API bool TCOD_text_update(TCOD_text_t txt, TCOD_key_t key);
55 | TCODLIB_API void TCOD_text_render(TCOD_text_t txt, TCOD_console_t con);
56 | TCODLIB_API const char * TCOD_text_get(TCOD_text_t txt);
57 | TCODLIB_API void TCOD_text_reset(TCOD_text_t txt);
58 | TCODLIB_API void TCOD_text_delete(TCOD_text_t txt);
59 | #ifdef __cplusplus
60 | }
61 | #endif
62 |
63 | #endif /* TCOD_CONSOLE_SUPPORT */
64 |
65 | #endif /* _TCOD_TEXT_H_ */
66 |
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/include/libtcod/txtfield.hpp:
--------------------------------------------------------------------------------
1 | /* libtcod
2 | * Copyright © 2008-2018 Jice and the libtcod contributers.
3 | * All rights reserved.
4 | *
5 | * libtcod 'The Doryen library' is a cross-platform C/C++ library for roguelike
6 | * developers.
7 | * Its source code is available from:
8 | * https://github.com/libtcod/libtcod
9 | *
10 | * Redistribution and use in source and binary forms, with or without
11 | * modification, are permitted provided that the following conditions are met:
12 | * * Redistributions of source code must retain the above copyright
13 | * notice, this list of conditions and the following disclaimer.
14 | * * Redistributions in binary form must reproduce the above copyright
15 | * notice, this list of conditions and the following disclaimer in the
16 | * documentation and/or other materials provided with the distribution.
17 | * * The name of copyright holder nor the names of its contributors may not
18 | * be used to endorse or promote products derived from this software
19 | * without specific prior written permission.
20 | *
21 | * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
22 | * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
23 | * TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
24 | * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
25 | * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
26 | * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
27 | * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
28 | * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
29 | * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
30 | * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
31 | * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
32 | */
33 | #ifndef _TCOD_TEXT_HPP_
34 | #define _TCOD_TEXT_HPP_
35 |
36 | #include "color.hpp"
37 | #include "console.hpp"
38 | #include "txtfield.h"
39 |
40 | #ifdef TCOD_CONSOLE_SUPPORT
41 |
42 | class TCODLIB_API TCODText {
43 | public :
44 | TCODText(int x, int y, int w, int h, int max_chars);
45 | TCODText(int w, int h, int max_chars);
46 | ~TCODText();
47 | void setProperties(int cursor_char, int blink_interval, const char * prompt, int tab_size);
48 | void setColors(TCODColor fore, TCODColor back, float back_transparency);
49 | void setPos(int x, int y);
50 | bool update(TCOD_key_t key);
51 | void render(TCODConsole * con);
52 | const char *getText();
53 | void reset();
54 | protected :
55 | TCOD_text_t data;
56 | };
57 |
58 | #endif /* TCOD_CONSOLE_SUPPORT */
59 |
60 | #endif
61 |
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/include/libtcod/utility.h:
--------------------------------------------------------------------------------
1 | /* libtcod
2 | * Copyright © 2008-2018 Jice and the libtcod contributers.
3 | * All rights reserved.
4 | *
5 | * libtcod 'The Doryen library' is a cross-platform C/C++ library for roguelike
6 | * developers.
7 | * Its source code is available from:
8 | * https://github.com/libtcod/libtcod
9 | *
10 | * Redistribution and use in source and binary forms, with or without
11 | * modification, are permitted provided that the following conditions are met:
12 | * * Redistributions of source code must retain the above copyright
13 | * notice, this list of conditions and the following disclaimer.
14 | * * Redistributions in binary form must reproduce the above copyright
15 | * notice, this list of conditions and the following disclaimer in the
16 | * documentation and/or other materials provided with the distribution.
17 | * * The name of copyright holder nor the names of its contributors may not
18 | * be used to endorse or promote products derived from this software
19 | * without specific prior written permission.
20 | *
21 | * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
22 | * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
23 | * TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
24 | * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
25 | * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
26 | * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
27 | * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
28 | * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
29 | * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
30 | * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
31 | * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
32 | */
33 | #ifndef LIBTCOD_UTILITY_H
34 | #define LIBTCOD_UTILITY_H
35 | /******************************************
36 | utility macros
37 | ******************************************/
38 | #define MAX(a,b) (((a)>(b))?(a):(b))
39 | #define MIN(a,b) (((a)<(b))?(a):(b))
40 | #define ABS(a) ((a)<0?-(a):(a))
41 | #define CLAMP(a, b, x) ((x) < (a) ? (a) : ((x) > (b) ? (b) : (x)))
42 | #define LERP(a, b, x) ( (a) + (x) * ((b) - (a)) )
43 |
44 | #endif
45 |
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/include/libtcod/version.h:
--------------------------------------------------------------------------------
1 | /* libtcod
2 | * Copyright © 2008-2018 Jice and the libtcod contributers.
3 | * All rights reserved.
4 | *
5 | * libtcod 'The Doryen library' is a cross-platform C/C++ library for roguelike
6 | * developers.
7 | * Its source code is available from:
8 | * https://github.com/libtcod/libtcod
9 | *
10 | * Redistribution and use in source and binary forms, with or without
11 | * modification, are permitted provided that the following conditions are met:
12 | * * Redistributions of source code must retain the above copyright
13 | * notice, this list of conditions and the following disclaimer.
14 | * * Redistributions in binary form must reproduce the above copyright
15 | * notice, this list of conditions and the following disclaimer in the
16 | * documentation and/or other materials provided with the distribution.
17 | * * The name of copyright holder nor the names of its contributors may not
18 | * be used to endorse or promote products derived from this software
19 | * without specific prior written permission.
20 | *
21 | * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
22 | * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
23 | * TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
24 | * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
25 | * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
26 | * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
27 | * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
28 | * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
29 | * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
30 | * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
31 | * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
32 | */
33 | #ifndef LIBTCOD_VERSION_H
34 | #define LIBTCOD_VERSION_H
35 |
36 | #define TCOD_MAJOR_VERSION 1
37 | #define TCOD_MINOR_VERSION 9
38 | #define TCOD_PATCHLEVEL 0
39 |
40 | #define TCOD_STRVERSION "1.9.0"
41 |
42 | #define TCOD_HEXVERSION (0x010000 * TCOD_MAJOR_VERSION \
43 | + 0x0100 * TCOD_MINOR_VERSION \
44 | + 0x01 * TCOD_PATCHLEVEL)
45 | #define TCOD_TECHVERSION (TCOD_HEXVERSION * 0x100)
46 |
47 | #define TCOD_STRVERSIONNAME "libtcod " TCOD_STRVERSION
48 |
49 | #endif /* LIBTCOD_VERSION_H */
50 |
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/lua/libtcodlua.lua:
--------------------------------------------------------------------------------
1 | -- load libtcod wrapper
2 | if type(loadlib) == "function" then
3 | init=loadlib
4 | else
5 | init=package.loadlib
6 | end
7 | a,b,c=init("./liblibtcod-lua.so","luaopen_libtcod")
8 | if a == nil then
9 | a,b,c=init("./liblibtcod-lua.dll","luaopen_libtcod")
10 | end
11 | a()
12 |
13 | -- improve the wrapper
14 | tcod = { }
15 | for key, value in pairs(libtcod) do
16 | if type(key) == "string" then
17 | local library, name = key:match("^TCOD([^_]*)_(.*)")
18 | if library ~= nil then
19 | -- replace libtcod.TCODConsole_bla() with tcod.console.bla()
20 | library = library:lower( )
21 | tcod[library] = tcod[library] or { }
22 | tcod[library][name] = value
23 | else
24 | library = key:match("^TCOD([^_]*)")
25 | if library ~= nil then
26 | -- replace libtcod.TCODConsole() with tcod.Console()
27 | tcod[library]=value
28 | else
29 | tcod[key] = value
30 | end
31 | end
32 | else
33 | tcod[key] = value
34 | end
35 | end
36 | -- now rename userdata imported from C++
37 | for key,value in pairs(getmetatable(libtcod)[".get"]) do
38 | if type(key) == "string" then
39 | local library, name = key:match("^TCOD([^_]*)_(.*)")
40 | if library ~= nil then
41 | -- replace libtcod.TCODColor_grey with tcod.color.grey
42 | library = library:lower( )
43 | tcod[library] = tcod[library] or { }
44 | tcod[library][name] = value()
45 | end
46 | end
47 | end
48 | function _alpha(alpha)
49 | return tcod.Alpha + math.floor(alpha*255)*(2^8)
50 | end
51 | function _addAlpha(alpha)
52 | return tcod.AddAlpha + math.floor(alpha*255)*(2^8)
53 | end
54 | tcod.console.Alpha=_alpha
55 | tcod.console.AddAlpha=_addAlpha
56 |
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/python/MANIFEST.in:
--------------------------------------------------------------------------------
1 | recursive-include data *
2 | recursive-include dependencies *
3 | recursive-include makefiles *
4 | recursive-include include *
5 | recursive-include src *
6 | recursive-include python *.py
7 | include lib/donotremove
8 | include *.py
9 | include *.cfg
10 | include *.in
11 | include *.txt
12 | include *.png
13 | include SDL2.dll
14 | exclude python/setup.py
15 | exclude python/setup.cfg
16 | exclude python/MANIFEST.in
17 |
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/python/python.pyproj:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | Debug
5 | 2.0
6 | {9f5a5967-268c-4d0d-a182-4112a94abe4b}
7 |
8 | tests\test_libtcodpy.py
9 |
10 |
11 | .
12 | .
13 | {888888a0-9f3d-457c-b088-3a5042f75d52}
14 | Standard Python launcher
15 | Global|PythonCore|2.7
16 | True
17 | LIBTCOD_DLL_PATH=$(SolutionDir)..\dependencies\x64\$(Configuration);$(SolutionDir)\libtcod\x64\$(Configuration)
18 | False
19 |
20 |
21 |
22 |
23 | 10.0
24 |
25 |
26 |
27 |
28 |
29 |
30 |
31 |
32 |
33 |
34 |
35 |
36 |
37 |
38 |
39 |
40 |
41 |
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/python/setup.cfg:
--------------------------------------------------------------------------------
1 | [bdist_wheel]
2 | ; this ctypes module works on both Python 2 and 3
3 | universal = 1
4 |
5 | [build_make]
6 | ; the make command raises errors on DLL's that are already built
7 | ignore_errors = 1
8 |
9 | [aliases]
10 | test=pytest
11 |
12 | [tool:pytest]
13 | addopts = tests/ --cov=libtcodpy
14 |
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/python/tests/conftest.py:
--------------------------------------------------------------------------------
1 |
2 | import random
3 |
4 | import pytest
5 |
6 | import libtcodpy
7 |
8 | FONT_FILE = '../terminal.png'
9 | WIDTH = 12
10 | HEIGHT = 10
11 | TITLE = 'libtcodpy tests'
12 | FULLSCREEN = False
13 | RENDERER = libtcodpy.RENDERER_SDL
14 |
15 | @pytest.fixture(scope="module")
16 | def session_console():
17 | libtcodpy.console_set_custom_font(FONT_FILE)
18 | console = libtcodpy.console_init_root(WIDTH, HEIGHT, TITLE, FULLSCREEN)
19 |
20 | assert libtcodpy.console_get_width(console) == WIDTH
21 | assert libtcodpy.console_get_height(console) == HEIGHT
22 | assert libtcodpy.console_is_fullscreen() == FULLSCREEN
23 | libtcodpy.console_set_window_title(TITLE)
24 | assert not libtcodpy.console_is_window_closed()
25 |
26 | libtcodpy.sys_get_current_resolution()
27 | libtcodpy.sys_get_char_size()
28 | libtcodpy.sys_set_renderer(RENDERER)
29 | libtcodpy.sys_get_renderer()
30 |
31 | yield console
32 | libtcodpy.console_delete(console)
33 |
34 | @pytest.fixture(scope="function")
35 | def console(session_console):
36 | """Return a root console.
37 |
38 | Be sure to use this fixture if the GUI needs to be initialized for a test.
39 | """
40 | console = session_console
41 | libtcodpy.console_flush()
42 | libtcodpy.console_set_default_foreground(console, libtcodpy.white)
43 | libtcodpy.console_set_default_background(console, libtcodpy.black)
44 | libtcodpy.console_set_background_flag(console, libtcodpy.BKGND_SET)
45 | libtcodpy.console_set_alignment(console, libtcodpy.LEFT)
46 | libtcodpy.console_clear(console)
47 | return console
48 |
49 | @pytest.fixture()
50 | def offscreen(console):
51 | """Return an off-screen console with the same size as the root console."""
52 | offscreen = libtcodpy.console_new(
53 | libtcodpy.console_get_width(console),
54 | libtcodpy.console_get_height(console),
55 | )
56 | yield offscreen
57 | libtcodpy.console_delete(offscreen)
58 |
59 | @pytest.fixture()
60 | def fg():
61 | return libtcodpy.Color(random.randint(0, 255),
62 | random.randint(0, 255),
63 | random.randint(0, 255))
64 |
65 | @pytest.fixture()
66 | def bg():
67 | return libtcodpy.Color(random.randint(0, 255),
68 | random.randint(0, 255),
69 | random.randint(0, 255))
70 |
71 | try:
72 | unichr
73 | except NameError:
74 | unichr = chr
75 |
76 | def ch_ascii_int():
77 | return random.randint(0x21, 0x7f)
78 |
79 | def ch_ascii_str():
80 | return chr(ch_ascii_int())
81 |
82 | def ch_latin1_int():
83 | return random.randint(0x80, 0xff)
84 |
85 | def ch_latin1_str():
86 | return chr(ch_latin1_int())
87 |
88 | def ch_bmp_int():
89 | # Basic Multilingual Plane, before surrogates
90 | return random.randint(0x100, 0xd7ff)
91 |
92 | def ch_bmp_str():
93 | return unichr(ch_bmp_int())
94 |
95 | def ch_smp_int():
96 | return random.randint(0x10000, 0x1f9ff)
97 |
98 | def ch_smp_str():
99 | return unichr(ch_bmp_int())
100 |
101 | @pytest.fixture(params=['ascii_int', 'ascii_str',
102 | 'latin1_int', 'latin1_str',
103 | #'bmp_int', 'bmp_str', # causes crashes
104 | ])
105 | def ch(request):
106 | """Test with multiple types of ascii/latin1 characters"""
107 | return globals()['ch_%s' % request.param]()
108 |
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/samples/apfviewer.cpp:
--------------------------------------------------------------------------------
1 | #include
2 | #include "libtcod.hpp"
3 |
4 | static float version=1.0f;
5 |
6 | int main(int argc, char *argv[]) {
7 | TCODConsole * rootcon = NULL;
8 | TCOD_key_t keyPress;
9 | TCOD_renderer_t renderer = TCOD_RENDERER_SDL;
10 |
11 | int row=50;
12 | int col=80;
13 | if ( argc < 2) {
14 | printf ("apfviewer ...\nversion %g\n",version);
15 | return 1;
16 | }
17 | TCODConsole::initRoot(col,row,"apfviewer",false,renderer );
18 | TCODConsole con(1,1);
19 | for (int i=1; i < argc; i++) {
20 | if (strstr(argv[i],".asc")) con.loadAsc(argv[1]);
21 | else con.loadApf(argv[i]);
22 | delete TCODConsole::root;
23 | TCODConsole::root=NULL;
24 | TCODConsole::initRoot(con.getWidth(),con.getHeight(),argv[i],false,renderer );
25 | TCODConsole::blit(&con,0,0,0,0,TCODConsole::root,0,0);
26 | TCODConsole::root->flush();
27 | TCODSystem::waitForEvent(TCOD_EVENT_KEY_RELEASE|TCOD_EVENT_MOUSE_PRESS,NULL,NULL,true);
28 | }
29 |
30 | return 0;
31 | }
32 |
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/samples/hmtool/README.txt:
--------------------------------------------------------------------------------
1 | libtcod height map tool
2 |
3 | Actually this is currently more a curiosity than a real useful tool.
4 | It allows you to tweak a heightmap by hand and generate the corresponding C,C++ or Python code.
5 |
6 | The heightmap tool source code is public domain. Do whatever you want with it.
7 |
8 | NB : this tool has not been upgraded to the latest libtcod API so the generated code won't compile.
9 |
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/samples/navier/main.hpp:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2010 Jice
3 | * All rights reserved.
4 | *
5 | * Redistribution and use in source and binary forms, with or without
6 | * modification, are permitted provided that the following conditions are met:
7 | * * Redistributions of source code must retain the above copyright
8 | * notice, this list of conditions and the following disclaimer.
9 | * * Redistributions in binary form must reproduce the above copyright
10 | * notice, this list of conditions and the following disclaimer in the
11 | * documentation and/or other materials provided with the distribution.
12 | * * The name of Jice may not be used to endorse or promote products
13 | * derived from this software without specific prior written permission.
14 | *
15 | * THIS SOFTWARE IS PROVIDED BY JICE ``AS IS'' AND ANY
16 | * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
17 | * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
18 | * DISCLAIMED. IN NO EVENT SHALL JICE BE LIABLE FOR ANY
19 | * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
20 | * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
21 | * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
22 | * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
23 | * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
24 | * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
25 | */
26 | #include "libtcod.hpp"
27 |
28 |
29 | #define VERSION "0.1.1"
30 |
31 | // console size
32 | #define CON_W 80
33 | #define CON_H 50
34 |
35 | #define IN_RECTANGLE(x,y,w,h) ((unsigned)(x) < (unsigned)(w) && (unsigned)(y) < (unsigned)(h))
36 | #define SQRDIST(x1,y1,x2,y2) (((x1)-(x2))*((x1)-(x2))+((y1)-(y2))*((y1)-(y2)))
37 |
38 |
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/samples/rad/README.txt:
--------------------------------------------------------------------------------
1 |
2 | Radiosity 0.1.0
3 |
4 | “Radiosity” engine
5 |
6 | Simple light diffusion using some sort of radiosity algorithm
7 | Not fast, not clean code… To be improved
8 |
9 | http://doryen.eptalys.net/demos/
10 |
11 |
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/samples/rad/bsp_helper.hpp:
--------------------------------------------------------------------------------
1 | /*
2 | * Umbra
3 | * Copyright (c) 2009, 2010 Mingos, Jice
4 | * All rights reserved.
5 | *
6 | * Redistribution and use in source and binary forms, with or without
7 | * modification, are permitted provided that the following conditions are met:
8 | * * Redistributions of source code must retain the above copyright
9 | * notice, this list of conditions and the following disclaimer.
10 | * * Redistributions in binary form must reproduce the above copyright
11 | * notice, this list of conditions and the following disclaimer in the
12 | * documentation and/or other materials provided with the distribution.
13 | * * The names of Mingos or Jice may not be used to endorse or promote products
14 | * derived from this software without specific prior written permission.
15 | *
16 | * THIS SOFTWARE IS PROVIDED BY MINGOS & JICE ``AS IS'' AND ANY
17 | * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
18 | * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
19 | * DISCLAIMED. IN NO EVENT SHALL MINGOS OR JICE BE LIABLE FOR ANY
20 | * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
21 | * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
22 | * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
23 | * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
24 | * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
25 | * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
26 | */
27 |
28 | class BspHelper : public ITCODBspCallback {
29 | public :
30 | BspHelper();
31 | int bspDepth;
32 | int minRoomSize;
33 | bool randomRoom;
34 | bool roomWalls;
35 | void createBspDungeon(TCODMap *map, TCODRandom *rng);
36 | // libtcod bsp callback stuff
37 | bool visitNode(TCODBsp *node, void *userData);
38 | private :
39 | void vline(TCODMap *map,int x, int y1, int y2);
40 | void vline_up(TCODMap *map,int x, int y);
41 | void vline_down(TCODMap *map,int x, int y);
42 | void hline(TCODMap *map,int x1, int y, int x2);
43 | void hline_left(TCODMap *map,int x, int y);
44 | void hline_right(TCODMap *map,int x, int y);
45 | };
46 |
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/samples/rad/rad_shader.cpp:
--------------------------------------------------------------------------------
1 | /*
2 | * Photon reactor
3 | * Copyright (c) 2011 Jice
4 | * All rights reserved.
5 | *
6 | * Redistribution and use in source and binary forms, with or without
7 | * modification, are permitted provided that the following conditions are met:
8 | * * Redistributions of source code must retain the above copyright
9 | * notice, this list of conditions and the following disclaimer.
10 | * * Redistributions in binary form must reproduce the above copyright
11 | * notice, this list of conditions and the following disclaimer in the
12 | * documentation and/or other materials provided with the distribution.
13 | * * The names of Jice may not be used to endorse or promote products
14 | * derived from this software without specific prior written permission.
15 | *
16 | * THIS SOFTWARE IS PROVIDED BY JICE ``AS IS'' AND ANY
17 | * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
18 | * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
19 | * DISCLAIMED. IN NO EVENT SHALL JICE BE LIABLE FOR ANY
20 | * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
21 | * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
22 | * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
23 | * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
24 | * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
25 | * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
26 | */
27 |
28 | #include "libtcod.hpp"
29 | #include "rad_shader.hpp"
30 |
31 | void Shader::init(TCODMap *map) {
32 | this->map=map;
33 | int size=map->getWidth()*map->getHeight();
34 | lightmap=new TCODColor[size];
35 | }
36 |
37 | int Shader::addLight(int x, int y, int radius, const TCODColor &col) {
38 | int id=lights.size();
39 | Light l;
40 | l.x=x;
41 | l.y=y;
42 | l.radius=radius;
43 | l.col=col;
44 | lights.push(l);
45 | return id;
46 | }
47 |
48 | void Shader::updateLight(int id, int x, int y, int radius, const TCODColor &col) {
49 | Light *l=lights.begin()+id;
50 | l->x=x;
51 | l->y=y;
52 | l->radius=radius;
53 | l->col=col;
54 | }
55 |
56 |
57 | const TCODColor &Shader::getLightColor(int x, int y) {
58 | return lightmap[ x + y * map->getWidth()];
59 | }
60 |
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/samples/rad/rad_shader_standard.cpp:
--------------------------------------------------------------------------------
1 | /*
2 | * Photon reactor
3 | * Copyright (c) 2011 Jice
4 | * All rights reserved.
5 | *
6 | * Redistribution and use in source and binary forms, with or without
7 | * modification, are permitted provided that the following conditions are met:
8 | * * Redistributions of source code must retain the above copyright
9 | * notice, this list of conditions and the following disclaimer.
10 | * * Redistributions in binary form must reproduce the above copyright
11 | * notice, this list of conditions and the following disclaimer in the
12 | * documentation and/or other materials provided with the distribution.
13 | * * The names of Jice may not be used to endorse or promote products
14 | * derived from this software without specific prior written permission.
15 | *
16 | * THIS SOFTWARE IS PROVIDED BY JICE ``AS IS'' AND ANY
17 | * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
18 | * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
19 | * DISCLAIMED. IN NO EVENT SHALL JICE BE LIABLE FOR ANY
20 | * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
21 | * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
22 | * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
23 | * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
24 | * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
25 | * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
26 | */
27 |
28 | #include "libtcod.hpp"
29 | #include "rad_shader.hpp"
30 |
31 | void StandardShader::compute() {
32 | // turn off all lights
33 | memset(lightmap,0,sizeof(TCODColor)*map->getWidth()*map->getHeight());
34 | for ( Light *l=lights.begin(); l != lights.end(); l++) {
35 | // compute the potential visible set for this light
36 | int minx=l->x-l->radius;
37 | int miny=l->y-l->radius;
38 | int maxx=l->x+l->radius;
39 | int maxy=l->y+l->radius;
40 | minx=MAX(0,minx);
41 | miny=MAX(0,miny);
42 | maxx=MIN(maxx,map->getWidth()-1);
43 | maxy=MIN(maxy,map->getHeight()-1);
44 | float offset = 1.0f/(1.0f+(float)(l->radius*l->radius)/20);
45 | float factor = 1.0f/(1.0f-offset);
46 | // compute the light's fov
47 | TCODMap lmap(maxx-minx+1,maxy-miny+1);
48 | for (int x=minx; x <= maxx; x++) {
49 | for (int y=miny; y <= maxy; y++) {
50 | lmap.setProperties(x-minx,y-miny,map->isWalkable(x,y),map->isTransparent(x,y));
51 | }
52 | }
53 | lmap.computeFov(l->x-minx,l->y-miny,l->radius);
54 | // compute the light's contribution
55 | //double invSquaredRadius=1.0 / (l->radius*l->radius);
56 | for (int x=minx; x <= maxx; x++) {
57 | for (int y=miny; y <= maxy; y++) {
58 | if ( lmap.isInFov(x-minx,y-miny)) {
59 | int squaredDist = (l->x-x)*(l->x-x)+(l->y-y)*(l->y-y);
60 | // basic
61 | //double coef = 1.0-squaredDist*invSquaredRadius;
62 | // invsqr1
63 | //double coef=(1.0f/(1.0f+(float)(squaredDist)));
64 | // invsqr2
65 | double coef=(1.0f/(1.0f+(float)(squaredDist)/20)- offset)*factor;
66 | TCODColor *col=&lightmap[x+y*map->getWidth()];
67 | *col = *col + l->col * coef;
68 | }
69 | }
70 | }
71 | }
72 | }
73 |
74 |
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/samples/rad/terminal.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/saturnation/libtcod-tutorial/cae06e2b50a3705adad15fee43b5d66eaa08be92/lib/libtcod-1.9.0-x86_64-msvc/samples/rad/terminal.png
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/samples/ripples/main.hpp:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2010 Jice
3 | * All rights reserved.
4 | *
5 | * Redistribution and use in source and binary forms, with or without
6 | * modification, are permitted provided that the following conditions are met:
7 | * * Redistributions of source code must retain the above copyright
8 | * notice, this list of conditions and the following disclaimer.
9 | * * Redistributions in binary form must reproduce the above copyright
10 | * notice, this list of conditions and the following disclaimer in the
11 | * documentation and/or other materials provided with the distribution.
12 | * * The name of Jice may not be used to endorse or promote products
13 | * derived from this software without specific prior written permission.
14 | *
15 | * THIS SOFTWARE IS PROVIDED BY JICE ``AS IS'' AND ANY
16 | * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
17 | * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
18 | * DISCLAIMED. IN NO EVENT SHALL JICE BE LIABLE FOR ANY
19 | * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
20 | * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
21 | * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
22 | * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
23 | * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
24 | * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
25 | */
26 | #include "libtcod.hpp"
27 | #include "util_ripples.hpp"
28 |
29 | #define VERSION "0.1.0"
30 |
31 | // console size
32 | #define CON_W 80
33 | #define CON_H 50
34 |
35 | #define IN_RECTANGLE(x,y,w,h) ((unsigned)(x) < (unsigned)(w) && (unsigned)(y) < (unsigned)(h))
36 | #define SQRDIST(x1,y1,x2,y2) (((x1)-(x2))*((x1)-(x2))+((y1)-(y2))*((y1)-(y2)))
37 |
38 | #ifndef NDEBUG
39 | #define DBG(x) printf x
40 | #else
41 | #define DBG(x)
42 | #endif
43 |
44 | extern TCODNoise noise3d;
45 |
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/samples/ripples/util_ripples.hpp:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2010 Jice
3 | * All rights reserved.
4 | *
5 | * Redistribution and use in source and binary forms, with or without
6 | * modification, are permitted provided that the following conditions are met:
7 | * * Redistributions of source code must retain the above copyright
8 | * notice, this list of conditions and the following disclaimer.
9 | * * Redistributions in binary form must reproduce the above copyright
10 | * notice, this list of conditions and the following disclaimer in the
11 | * documentation and/or other materials provided with the distribution.
12 | * * The name of Jice may not be used to endorse or promote products
13 | * derived from this software without specific prior written permission.
14 | *
15 | * THIS SOFTWARE IS PROVIDED BY Jice ``AS IS'' AND ANY
16 | * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
17 | * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
18 | * DISCLAIMED. IN NO EVENT SHALL Jice BE LIABLE FOR ANY
19 | * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
20 | * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
21 | * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
22 | * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
23 | * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
24 | * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
25 | */
26 |
27 | struct WaterZone {
28 | float cumulatedElapsed; // to control the ripples framerate
29 | float *data; // water height data after update
30 | float *oldData; // water height data before update
31 | bool isActive; // not to use CPU is there are no ripples
32 | };
33 |
34 | class RippleManager {
35 | public :
36 | RippleManager(TCODMap *waterMap);
37 | void startRipple(int dungeonx, int dungeony);
38 | bool updateRipples(float elapsed);
39 | void renderRipples(const TCODImage *ground, TCODImage *groundWithRipples);
40 | protected :
41 | int width,height;
42 | WaterZone zone;
43 | void init(TCODMap *waterMap);
44 | float getData(int x, int y) const { return zone.data[x+y*width]; }
45 | };
46 |
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/samples/weather/main.hpp:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2010 Jice
3 | * All rights reserved.
4 | *
5 | * Redistribution and use in source and binary forms, with or without
6 | * modification, are permitted provided that the following conditions are met:
7 | * * Redistributions of source code must retain the above copyright
8 | * notice, this list of conditions and the following disclaimer.
9 | * * Redistributions in binary form must reproduce the above copyright
10 | * notice, this list of conditions and the following disclaimer in the
11 | * documentation and/or other materials provided with the distribution.
12 | * * The name of Jice may not be used to endorse or promote products
13 | * derived from this software without specific prior written permission.
14 | *
15 | * THIS SOFTWARE IS PROVIDED BY JICE ``AS IS'' AND ANY
16 | * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
17 | * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
18 | * DISCLAIMED. IN NO EVENT SHALL JICE BE LIABLE FOR ANY
19 | * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
20 | * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
21 | * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
22 | * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
23 | * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
24 | * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
25 | */
26 | #include "libtcod.hpp"
27 | #include "util_weather.hpp"
28 |
29 | #define VERSION "0.1.0"
30 |
31 | // console size
32 | #define CON_W 80
33 | #define CON_H 50
34 |
35 | #define IN_RECTANGLE(x,y,w,h) ((unsigned)(x) < (unsigned)(w) && (unsigned)(y) < (unsigned)(h))
36 | #define SQRDIST(x1,y1,x2,y2) (((x1)-(x2))*((x1)-(x2))+((y1)-(y2))*((y1)-(y2)))
37 |
38 | #ifndef NDEBUG
39 | #define DBG(x) printf x
40 | #else
41 | #define DBG(x)
42 | #endif
43 |
44 | extern TCODNoise noise1d;
45 | extern TCODNoise noise2d;
46 |
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/samples/weather/util_weather.hpp:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2010 Jice
3 | * All rights reserved.
4 | *
5 | * Redistribution and use in source and binary forms, with or without
6 | * modification, are permitted provided that the following conditions are met:
7 | * * Redistributions of source code must retain the above copyright
8 | * notice, this list of conditions and the following disclaimer.
9 | * * Redistributions in binary form must reproduce the above copyright
10 | * notice, this list of conditions and the following disclaimer in the
11 | * documentation and/or other materials provided with the distribution.
12 | * * The name of Jice may not be used to endorse or promote products
13 | * derived from this software without specific prior written permission.
14 | *
15 | * THIS SOFTWARE IS PROVIDED BY JICE ``AS IS'' AND ANY
16 | * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
17 | * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
18 | * DISCLAIMED. IN NO EVENT SHALL JICE BE LIABLE FOR ANY
19 | * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
20 | * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
21 | * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
22 | * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
23 | * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
24 | * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
25 | */
26 |
27 | class Weather {
28 | public :
29 | void init(int width, int height);
30 | void update(float elapsed);
31 | float getCloud(int x, int y); // 0.0 : dark cloud, 1.0 : no cloud
32 | float getLightning(int x, int y); // 0.0 : no lightning. 1.0 : full lightning light
33 | bool hasRainDrop(); // call for each cell on the map
34 | // when scrolling the map on the game side
35 | void move(int dx, int dy);
36 | // description of current weather
37 | const char *getWeather();
38 | const TCODColor &getAmbientLightColor() { return ambientColor; }
39 | // timeInSecond : between 0 and 3600*24
40 | void calculateAmbient(float timeInSeconds);
41 | // how fast the weather is changing. 0 : never changes, 1 : default > 1 : faster...
42 | void setChangeFactor(float f) { changeFactor = f; }
43 | // 0 : bad weather. 1 : good weather
44 | float getIndicator() { return indicator; }
45 | // to alter the weather
46 | float getIndicatorDelta() { return indicatorDelta; }
47 | void setIndicatorDelta(float v) { indicatorDelta=CLAMP(-1.0f,1.0f,v); }
48 | protected :
49 | typedef struct {
50 | int posx,posy;
51 | float intensity; // 0-1
52 | float life; // in seconds
53 | int radius; // squared
54 | float noisex;
55 | } lightning_t;
56 |
57 | float indicator; // 0 : bad, 1 : good
58 | float indicatorDelta;
59 | float noisex,noisey; // position in the noise space
60 | float dx,dy; // sub cell cloud map position
61 | float changeFactor;
62 | TCODHeightMap *map;
63 | TCODList lightnings;
64 | TCODColor ambientColor;
65 | };
66 |
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/samples/worldgen/README.txt:
--------------------------------------------------------------------------------
1 |
2 | World generator 0.1.0
3 |
4 | Fast (< 1 sec for a 400×400 map)
5 | Heightmap, precipitation map, latitude-dependant temperature map, biome map
6 | Rain erosion
7 | Rapidely Exploring Random Tree rivers
8 |
9 | http://doryen.eptalys.net/demos/
10 |
11 |
12 |
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/samples/worldgen/main.hpp:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2010 Jice
3 | * All rights reserved.
4 | *
5 | * Redistribution and use in source and binary forms, with or without
6 | * modification, are permitted provided that the following conditions are met:
7 | * * Redistributions of source code must retain the above copyright
8 | * notice, this list of conditions and the following disclaimer.
9 | * * Redistributions in binary form must reproduce the above copyright
10 | * notice, this list of conditions and the following disclaimer in the
11 | * documentation and/or other materials provided with the distribution.
12 | * * The name of Jice may not be used to endorse or promote products
13 | * derived from this software without specific prior written permission.
14 | *
15 | * THIS SOFTWARE IS PROVIDED BY JICE ``AS IS'' AND ANY
16 | * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
17 | * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
18 | * DISCLAIMED. IN NO EVENT SHALL JICE BE LIABLE FOR ANY
19 | * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
20 | * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
21 | * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
22 | * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
23 | * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
24 | * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
25 | */
26 | #include "libtcod.hpp"
27 | #include "util_worldgen.hpp"
28 |
29 | #define VERSION "World generator v0.1.0"
30 |
31 | // console size
32 | #define CON_W 80
33 | #define CON_H 50
34 |
35 | #define IN_RECTANGLE(x,y,w,h) ((unsigned)(x) < (unsigned)(w) && (unsigned)(y) < (unsigned)(h))
36 | #define SQRDIST(x1,y1,x2,y2) (((x1)-(x2))*((x1)-(x2))+((y1)-(y2))*((y1)-(y2)))
37 |
38 | #ifndef NDEBUG
39 | #define DBG(x) printf x
40 | #else
41 | #define DBG(x)
42 | #endif
43 |
44 | extern TCODNoise noise1d;
45 | extern TCODNoise noise2d;
46 |
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/samples/worldgen/terminal.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/saturnation/libtcod-tutorial/cae06e2b50a3705adad15fee43b5d66eaa08be92/lib/libtcod-1.9.0-x86_64-msvc/samples/worldgen/terminal.png
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/samples/worldgen/util_worldgen.cpp:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/saturnation/libtcod-tutorial/cae06e2b50a3705adad15fee43b5d66eaa08be92/lib/libtcod-1.9.0-x86_64-msvc/samples/worldgen/util_worldgen.cpp
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/samples/worldgen/util_worldgen.hpp:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/saturnation/libtcod-tutorial/cae06e2b50a3705adad15fee43b5d66eaa08be92/lib/libtcod-1.9.0-x86_64-msvc/samples/worldgen/util_worldgen.hpp
--------------------------------------------------------------------------------
/lib/libtcod-1.9.0-x86_64-msvc/terminal.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/saturnation/libtcod-tutorial/cae06e2b50a3705adad15fee43b5d66eaa08be92/lib/libtcod-1.9.0-x86_64-msvc/terminal.png
--------------------------------------------------------------------------------
/src/components/fighter.c:
--------------------------------------------------------------------------------
1 | //
2 | // Created by Saturnation on 4/11/2018.
3 | //
4 |
5 | #include
6 | #include "fighter.h"
7 |
8 | struct fighter *create_fighter(int hp, int defense, int power) {
9 | struct fighter *f = malloc(sizeof(struct fighter));
10 | f->hp = hp;
11 | f->defense = defense;
12 | f->power = power;
13 | return f;
14 | }
15 |
16 | void take_damage(struct fighter *fighter, int amount) {
17 | fighter->hp -= amount;
18 | }
19 |
20 | void attack(struct entity *attacker, struct entity* target) {
21 | int damage = attacker->fighter->power - target->fighter->defense;
22 |
23 | if (damage > 0) {
24 | take_damage(target->fighter, damage);
25 | printf("%s attack %s for %d hit points.\n", attacker->name, target->name, damage);
26 | }
27 | }
28 |
29 |
30 |
--------------------------------------------------------------------------------
/src/components/fighter.h:
--------------------------------------------------------------------------------
1 | //
2 | // Created by Saturnation on 4/11/2018.
3 | //
4 |
5 | #ifndef LIBTCOD_TUTORIAL_FIGHTER_H
6 | #define LIBTCOD_TUTORIAL_FIGHTER_H
7 |
8 | #include
9 | #include "../entity.h"
10 |
11 | struct fighter{
12 | int max_hp;
13 | int hp;
14 | int defense;
15 | int power;
16 | };
17 |
18 | struct fighter* create_fighter(int hp, int defense, int power);
19 |
20 | void take_damage(struct fighter *fighter, int amount);
21 |
22 | void attack(struct entity *attacker, struct entity* target);
23 |
24 | #endif //LIBTCOD_TUTORIAL_FIGHTER_H
25 |
--------------------------------------------------------------------------------
/src/data/enums.h:
--------------------------------------------------------------------------------
1 | //
2 | // Created by Saturnation on 3/11/2018.
3 | //
4 |
5 | #ifndef LIBTCOD_TUTORIAL_ENUMS_H
6 | #define LIBTCOD_TUTORIAL_ENUMS_H
7 | enum game_states {PLAYERS_TURN, ENEMY_TURN};
8 | #endif //LIBTCOD_TUTORIAL_ENUMS_H
9 |
--------------------------------------------------------------------------------
/src/data/list.c:
--------------------------------------------------------------------------------
1 | //
2 | // Created by Saturnation on 4/11/2018.
3 | //
4 | #include "list.h"
5 |
6 | struct entity *get_blocking_entities_at_location(struct entity_list *e, int destination_x, int destination_y) {
7 | struct entity_list *curr = e;
8 | while (curr != NULL) {
9 | struct entity curr_e = *curr->data;
10 | if (curr_e.blocks && curr_e.x == destination_x && curr_e.y == destination_y) {
11 | return curr->data;
12 | }
13 | curr = curr->next;
14 | }
15 | return NULL;
16 | }
17 |
--------------------------------------------------------------------------------
/src/data/list.h:
--------------------------------------------------------------------------------
1 | //
2 | // Created by Saturnation on 3/11/2018.
3 | //
4 |
5 | #ifndef LIBTCOD_TUTORIAL_LIST_H
6 | #define LIBTCOD_TUTORIAL_LIST_H
7 |
8 |
9 | struct entity;
10 |
11 | struct entity_list {
12 | struct entity *data;
13 | struct entity_list *next;
14 | };
15 |
16 | #include "../entity.h"
17 |
18 | struct entity *get_blocking_entities_at_location(struct entity_list *e, int destination_x, int destination_y);
19 |
20 | #endif //LIBTCOD_TUTORIAL_LIST_H
21 |
--------------------------------------------------------------------------------
/src/entity.c:
--------------------------------------------------------------------------------
1 | //
2 | // Created by Saturnation on 2/11/2018.
3 | //
4 |
5 | #include
6 | #include
7 | #include "entity.h"
8 |
9 | void move(struct entity *e, int dx, int dy) {
10 | e->x += dx;
11 | e->y += dy;
12 | }
13 |
14 | struct entity *create_entity(int x,
15 | int y,
16 | char c,
17 | TCOD_color_t color,
18 | char *name,
19 | bool blocks,
20 | struct fighter *fighter,
21 | void (*ai_action)(struct entity *, struct entity *, TCOD_Map *, struct game_map *, struct entity_list *)) {
22 | struct entity *e = malloc(sizeof(struct entity));
23 | e->x = x;
24 | e->y = y;
25 | e->c = c;
26 | e->color = color;
27 | e->name = name;
28 | e->blocks = blocks;
29 | e->fighter = fighter;
30 | e->ai_action = ai_action;
31 | return e;
32 | }
33 |
34 |
--------------------------------------------------------------------------------
/src/entity.h:
--------------------------------------------------------------------------------
1 | //
2 | // Created by Saturnation on 2/11/2018.
3 | //
4 |
5 | #ifndef LIBTCOD_TUTORIAL_ENTITY_H
6 | #define LIBTCOD_TUTORIAL_ENTITY_H
7 |
8 | #include
9 | #include
10 |
11 | struct game_map;
12 | struct entity_list;
13 |
14 | struct entity {
15 | int x;
16 | int y;
17 | char c;
18 | TCOD_color_t color;
19 | char *name;
20 | bool blocks;
21 | struct fighter *fighter;
22 |
23 | void (*ai_action)(struct entity *, struct entity *, TCOD_Map *, struct game_map *, struct entity_list *);
24 | };
25 |
26 | #include "components/fighter.h"
27 | #include "map/game_map.h"
28 | #include "data/list.h"
29 |
30 | struct entity *create_entity(int x,
31 | int y,
32 | char c,
33 | TCOD_color_t color,
34 | char *name,
35 | bool blocks,
36 | struct fighter *fighter,
37 | void(*ai_action)(struct entity *,
38 | struct entity *, TCOD_Map *,
39 | struct game_map *,
40 | struct entity_list *));
41 |
42 | void move(struct entity *e, int dx, int dy);
43 |
44 | #endif //LIBTCOD_TUTORIAL_ENTITY_H
45 |
--------------------------------------------------------------------------------
/src/input_handlers.c:
--------------------------------------------------------------------------------
1 | //
2 | // Created by Saturnation on 2/11/2018.
3 | //
4 |
5 | #include
6 | #include
7 | #include "input_handlers.h"
8 |
9 |
10 |
11 | void handle_keys(TCOD_key_t *k, struct action *a) {
12 |
13 | if (k->vk == TCODK_UP || k->c == 'k') {
14 | a->type = MOVE;
15 | a->data.move.dx = 0;
16 | a->data.move.dy = -1;
17 | } else if (k->vk == TCODK_DOWN || k->c == 'j') {
18 | a->type = MOVE;
19 | a->data.move.dx = 0;
20 | a->data.move.dy = 1;
21 | } else if (k->vk == TCODK_LEFT || k->c == 'h') {
22 | a->type = MOVE;
23 | a->data.move.dx = -1;
24 | a->data.move.dy = 0;
25 | } else if (k->vk == TCODK_RIGHT || k->c == 'l') {
26 | a->type = MOVE;
27 | a->data.move.dx = 1;
28 | a->data.move.dy = 0;
29 | } else if (k->c == 'y') {
30 | a->type = MOVE;
31 | a->data.move.dx = -1;
32 | a->data.move.dy = -1;
33 | } else if (k->c == 'u') {
34 | a->type = MOVE;
35 | a->data.move.dx = 1;
36 | a->data.move.dy = -1;
37 | } else if (k->c == 'b') {
38 | a->type = MOVE;
39 | a->data.move.dx = -1;
40 | a->data.move.dy = 1;
41 | } else if (k->c == 'n') {
42 | a->type = MOVE;
43 | a->data.move.dx = 1;
44 | a->data.move.dy = 1;
45 | } else if (k->vk == TCODK_ENTER && k->lalt) {
46 | a->type = FULLSCREEN;
47 | a->data.logic = true;
48 | } else if (k->vk == TCODK_ESCAPE) {
49 | a->type = EXIT;
50 | a->data.logic = true;
51 | } else {
52 | a->type = NO_ACTION;
53 | }
54 | }
55 |
--------------------------------------------------------------------------------
/src/input_handlers.h:
--------------------------------------------------------------------------------
1 | //
2 | // Created by Saturnation on 2/11/2018.
3 | //
4 |
5 | #include
6 |
7 | #ifndef LIBTCOD_TUTORIAL_INPUT_HANDLERS_H
8 | #define LIBTCOD_TUTORIAL_INPUT_HANDLERS_H
9 |
10 | #define NO_ACTION 0
11 |
12 | #define MOVE 1
13 | #define FULLSCREEN 2
14 | #define EXIT 3
15 |
16 | typedef struct move_action {
17 | int dx;
18 | int dy;
19 | } move_action;
20 |
21 | typedef union union_action {
22 | move_action move;
23 | bool logic;
24 | } union_action;
25 |
26 | struct action {
27 | int type;
28 | union_action data;
29 | };
30 |
31 | void handle_keys(TCOD_key_t *k, struct action *a);
32 |
33 | #endif //LIBTCOD_TUTORIAL_INPUT_HANDLERS_H
34 |
--------------------------------------------------------------------------------
/src/map/fov.c:
--------------------------------------------------------------------------------
1 | //
2 | // Created by Saturnation on 3/11/2018.
3 | //
4 |
5 | #include
6 | #include "fov.h"
7 | #include "game_map.h"
8 | #include "tile.h"
9 |
10 | TCOD_Map* initialize_fov(struct game_map *map) {
11 | TCOD_Map *fov_map = TCOD_map_new(map->width, map->height);
12 | for (int y = 0; y < map->height; y++) {
13 | for (int x = 0; x < map->width; x++) {
14 | TCOD_map_set_properties(fov_map, x, y, !map->map[y][x].blocked_sight, !map->map[y][x].blocked_sight);
15 | }
16 | }
17 | return fov_map;
18 | }
19 |
20 | void recompute_fov(TCOD_Map *fov_map, int x, int y, int radius, bool light_walls, int algorithm) {
21 | TCOD_map_compute_fov(fov_map, x, y, radius, light_walls, algorithm);
22 |
23 | }
24 |
--------------------------------------------------------------------------------
/src/map/fov.h:
--------------------------------------------------------------------------------
1 | //
2 | // Created by Saturnation on 3/11/2018.
3 | //
4 |
5 | #include
6 | #include "game_map.h"
7 |
8 | #ifndef LIBTCOD_TUTORIAL_FOV_H
9 | #define LIBTCOD_TUTORIAL_FOV_H
10 |
11 | TCOD_Map* initialize_fov(struct game_map *map);
12 | void recompute_fov(TCOD_Map* fov_map, int x, int y, int radius, bool light_walls, int algorithm);
13 |
14 | #endif //LIBTCOD_TUTORIAL_FOV_H
15 |
--------------------------------------------------------------------------------
/src/map/game_map.h:
--------------------------------------------------------------------------------
1 | //
2 | // Created by Saturnation on 2/11/2018.
3 | //
4 |
5 | #ifndef LIBTCOD_TUTORIAL_GAME_MAP_H
6 | #define LIBTCOD_TUTORIAL_GAME_MAP_H
7 |
8 | #include
9 |
10 | struct tile;
11 |
12 | struct game_map {
13 | int width;
14 | int height;
15 | struct tile **map;
16 | } ;
17 |
18 | #include "tile.h"
19 | #include "rectangle.h"
20 | #include "../data/list.h"
21 |
22 | struct game_map *create_game_map(int width, int height);
23 |
24 | bool is_blocked(struct game_map *map, int x, int y);
25 |
26 | void create_room(struct game_map *map, struct rectangle *room);
27 |
28 | void make_map(struct game_map *map,
29 | int make_rooms,
30 | int room_min_size,
31 | int room_max_size,
32 | int map_width,
33 | int map_height,
34 | struct entity *player,
35 | struct entity_list *e,
36 | int max_monsters_per_room);
37 |
38 | void create_h_tunnel(struct game_map *map, int x1, int x2, int y);
39 |
40 | void create_v_tunnel(struct game_map *map, int x, int y1, int y2);
41 |
42 | void move_toward(struct entity *e, struct entity *target, struct game_map *map, struct entity_list *entity_list);
43 |
44 | void basic_ai_monster_turn(struct entity* e, struct entity *target, TCOD_Map *fov_map, struct game_map *map, struct entity_list *entity_list);
45 |
46 | double distance_to(struct entity *e, struct entity *target);
47 |
48 | void move_astar(struct entity *e, struct entity *target, struct entity_list *entity_list, struct game_map *map);
49 | #endif //LIBTCOD_TUTORIAL_GAME_MAP_H
50 |
--------------------------------------------------------------------------------
/src/map/rectangle.c:
--------------------------------------------------------------------------------
1 | //
2 | // Created by Saturnation on 2/11/2018.
3 | //
4 |
5 | #include
6 | #include
7 | #include "rectangle.h"
8 |
9 | struct rectangle *create_rectangle(int x, int y, int width, int height) {
10 | struct rectangle* rect = malloc(sizeof(struct rectangle));
11 | rect->x1 = x;
12 | rect->y1 = y;
13 | rect->x2 = x + width;
14 | rect->y2 = y + height;
15 | }
16 |
17 | int* center(struct rectangle *rectangle) {
18 | int* result = malloc(sizeof(int) * 2);
19 | result[0] = (rectangle->x1 + rectangle->x2) / 2;
20 | result[1] = (rectangle->y1 + rectangle->y2) / 2;
21 | return result;
22 | }
23 |
24 | bool intersect(struct rectangle *r1, struct rectangle *r2) {
25 | return (r1->x1 <= r2->x2 && r1->x2 >= r2->x1
26 | && r1->y1 <= r2->y2 && r1->y2 >= r2->y1);
27 | }
28 |
--------------------------------------------------------------------------------
/src/map/rectangle.h:
--------------------------------------------------------------------------------
1 | //
2 | // Created by Saturnation on 2/11/2018.
3 | //
4 |
5 | #include
6 |
7 | #ifndef LIBTCOD_TUTORIAL_RECTANGLE_H
8 | #define LIBTCOD_TUTORIAL_RECTANGLE_H
9 |
10 | struct rectangle {
11 | int x1;
12 | int y1;
13 | int x2;
14 | int y2;
15 | };
16 |
17 | struct rectangle* create_rectangle(int x, int y, int width, int height);
18 | int* center(struct rectangle* rectangle);
19 | bool intersect(struct rectangle* r1, struct rectangle* r2);
20 |
21 | #endif //LIBTCOD_TUTORIAL_RECTANGLE_H
22 |
--------------------------------------------------------------------------------
/src/map/tile.c:
--------------------------------------------------------------------------------
1 | //
2 | // Created by Saturnation on 2/11/2018.
3 | //
4 |
5 | #include "tile.h"
6 |
7 | void create_tile(struct tile *t, bool blocked, bool blocked_sight) {
8 | t->blocked = blocked;
9 | t->blocked_sight = blocked_sight;
10 | }
11 |
--------------------------------------------------------------------------------
/src/map/tile.h:
--------------------------------------------------------------------------------
1 | //
2 | // Created by Saturnation on 2/11/2018.
3 | //
4 |
5 | #include
6 | #include
7 |
8 | #ifndef LIBTCOD_TUTORIAL_TILE_H
9 | #define LIBTCOD_TUTORIAL_TILE_H
10 |
11 | #define DARK_WALL 0
12 | #define DARK_GROUND 1
13 | #define LIGHT_WALL 2
14 | #define LIGHT_GROUND 3
15 |
16 | struct tile {
17 | bool blocked;
18 | bool blocked_sight;
19 | bool explored;
20 | } tile;
21 |
22 | void create_tile(struct tile* t, bool blocked, bool blocked_sight);
23 | #endif //LIBTCOD_TUTORIAL_TILE_H
24 |
--------------------------------------------------------------------------------
/src/render_functions.c:
--------------------------------------------------------------------------------
1 | //
2 | // Created by Saturnation on 2/11/2018.
3 | //
4 |
5 | #include
6 | #include
7 | #include
8 | #include "render_functions.h"
9 | #include "entity.h"
10 | #include "map/game_map.h"
11 | #include "map/tile.h"
12 |
13 | void clear_entity(TCOD_console_t con, struct entity *e) {
14 | TCOD_console_put_char(con, e->x, e->y, ' ', TCOD_BKGND_NONE);
15 | }
16 |
17 | void draw_entity(TCOD_console_t con, struct entity *e, TCOD_Map* fov_map) {
18 | if (TCOD_map_is_in_fov(fov_map, e->x, e->y)) {
19 | TCOD_console_set_default_foreground(con, e->color);
20 | TCOD_console_put_char(con, e->x, e->y, e->c, TCOD_BKGND_NONE);
21 | }
22 | }
23 |
24 | void clear_all(TCOD_console_t con, struct entity_list *e) {
25 | struct entity_list *curr = e;
26 | while (curr != NULL) {
27 | clear_entity(con, curr->data);
28 | curr = curr->next;
29 | }
30 | }
31 |
32 | void render_all(TCOD_console_t con,
33 | struct entity_list *e,
34 | struct game_map *map,
35 | TCOD_Map *fov_map,
36 | bool fov_recompute,
37 | int width,
38 | int height,
39 | TCOD_color_t *color) {
40 | if (fov_recompute) {
41 | for (int y = 0; y < map->height; y++) {
42 | for (int x = 0; x < map->width; x++) {
43 | bool visible = TCOD_map_is_in_fov(fov_map, x, y);
44 | bool wall = map->map[y][x].blocked_sight;
45 | if (visible) {
46 | if (wall) {
47 | TCOD_console_set_char_background(con, x, y, color[LIGHT_WALL], TCOD_BKGND_SET);
48 | } else {
49 | TCOD_console_set_char_background(con, x, y, color[LIGHT_GROUND], TCOD_BKGND_SET);
50 | }
51 | map->map[y][x].explored = true;
52 | } else if (map->map[y][x].explored){
53 | if (wall) {
54 | TCOD_console_set_char_background(con, x, y, color[DARK_WALL], TCOD_BKGND_SET);
55 | } else {
56 | TCOD_console_set_char_background(con, x, y, color[DARK_GROUND], TCOD_BKGND_SET);
57 | }
58 | }
59 | }
60 | }
61 | }
62 |
63 | struct entity_list *curr = e;
64 | while (curr != NULL) {
65 | draw_entity(con, curr->data, fov_map);
66 | curr = curr->next;
67 | }
68 | // blit from con to root console
69 | TCOD_console_blit(con, 0, 0, width, height, 0, 0, 0, 1.0, 1.0);
70 | }
71 |
72 |
73 |
--------------------------------------------------------------------------------
/src/render_functions.h:
--------------------------------------------------------------------------------
1 | //
2 | // Created by Saturnation on 2/11/2018.
3 | //
4 |
5 | #include
6 | #include
7 | #include "entity.h"
8 | #include "map/game_map.h"
9 | #include "data/list.h"
10 |
11 | #ifndef LIBTCOD_TUTORIAL_RENDER_FUNCTIONS_H
12 | #define LIBTCOD_TUTORIAL_RENDER_FUNCTIONS_H
13 |
14 | void render_all(TCOD_console_t con,
15 | struct entity_list *e,
16 | struct game_map* map,
17 | TCOD_Map* fov_map,
18 | bool fov_recompute,
19 | int width,
20 | int height,
21 | TCOD_color_t* colors);
22 | void clear_all(TCOD_console_t con, struct entity_list *e);
23 | void draw_entity(TCOD_console_t con, struct entity* e, TCOD_Map* fov_map);
24 | void clear_entity(TCOD_console_t con, struct entity* e);
25 |
26 | #endif //LIBTCOD_TUTORIAL_RENDER_FUNCTIONS_H
27 |
--------------------------------------------------------------------------------