A SDL roguelike in a non-euclidean world.
Go to file
Zeno Rogue ba03d33959 embedding:: a simple general implementation of radar 2023-01-29 16:09:00 +01:00
.github/workflows Enable -Werror for CI 2022-06-29 21:58:11 +03:00
contrib add desktop file 2022-09-14 09:44:01 +02:00
devmods rulegen-tests:: show seq-stats for 3D 2022-08-26 12:42:55 +02:00
dll Add cross-compile support 2015-08-22 13:43:16 +02:00
generators removed BUILDZEBRA from drawcell 2019-10-25 09:22:19 +02:00
honeycombs new system for honeycombs in action 2022-08-26 12:27:57 +02:00
hyperroid Android version fixed for API 31 2022-07-17 14:48:08 +02:00
music fixed the ogg files 2022-10-27 16:06:39 +02:00
rogueviz removed functions which were moved elsewhere 2023-01-23 22:14:59 +01:00
sounds license specified for the recorded sounds 2022-09-15 11:24:44 +02:00
tessellations a sample with mirrors and apeirogons 2022-10-07 22:19:10 +02:00
.gitignore Eliminate autotools/automake/configure. 2021-03-21 17:19:41 -04:00
.travis.yml Enable -Werror for CI 2022-06-29 21:58:11 +03:00
3d-models.cpp rewritten the embeddings more nicely 2023-01-27 00:27:10 +01:00
CITATION.cff improved citation metadata 2021-09-15 17:21:56 +02:00
COPYING Initialization with hyperrogue-66 2015-08-08 15:57:52 +02:00
DejaVuSans-Bold.ttf Initialization with hyperrogue-66 2015-08-08 15:57:52 +02:00
Doxyfile Doxygen files added 2019-09-12 23:35:04 +02:00
FUNDING.yml GitHub sponsor added 2019-11-02 15:45:42 +01:00
Makefile Makefile rulegen fix again 2022-07-23 16:43:02 +02:00
Makefile.rv French language translation by @3raven 2022-07-01 14:11:14 -04:00
README.md docs: drop version from README 2022-08-28 16:23:05 +02:00
achievement.cpp ineligible_starting_land disables achievements 2022-10-27 16:06:39 +02:00
arbitrile.cpp rewritten the embeddings more nicely 2023-01-27 00:27:10 +01:00
archimedean.cpp disabled Archimedean check in embedded_plane 2022-12-09 02:33:15 +01:00
asonov.cpp made background screen darkening consistent and optional 2022-07-05 11:51:06 +02:00
attack.cpp savemem:: removed some more potential crashes 2022-07-17 14:41:57 +02:00
barriers.cpp Big change: spatial_embedding option 2022-12-09 02:33:15 +01:00
basegraph.cpp embedding:: a simple general implementation of radar 2023-01-29 16:09:00 +01:00
bigstuff.cpp fixed horo_ok to use mhyperbolic 2022-12-15 21:03:36 +01:00
binary-tiling.cpp fixup to coordinates 2023-01-29 14:17:03 +01:00
blizzard.cpp used cyclefix and raddif in more places; (c)spin90, (c)spin180 and spin180 functions; rephrased M_PI in terms of TAU and x._deg when applicable 2022-11-13 16:22:55 +01:00
cell.cpp rewritten the embeddings more nicely 2023-01-27 00:27:10 +01:00
celldrawer.cpp rewritten the embeddings more nicely 2023-01-27 00:27:10 +01:00
changelog.txt 12.1h changelog 2023-01-08 16:44:42 +01:00
checkmove.cpp removed redundant pre-changes orbused rollback, and made it more elegant in movegolem 2022-09-09 12:24:21 +02:00
classes.cpp fixup to nicer apply_always3 2023-01-29 11:56:26 +01:00
colors.cpp used cyclefix and raddif in more places; (c)spin90, (c)spin180 and spin180 functions; rephrased M_PI in terms of TAU and x._deg when applicable 2022-11-13 16:22:55 +01:00
commandline.cpp used cyclefix and raddif in more places; (c)spin90, (c)spin180 and spin180 functions; rephrased M_PI in terms of TAU and x._deg when applicable 2022-11-13 16:22:55 +01:00
complex.cpp Big change: spatial_embedding option 2022-12-09 02:33:15 +01:00
complex2.cpp refactored the vertical movement functions 2022-12-09 02:33:15 +01:00
config.cpp CLI option -seo 2023-01-28 04:08:32 +01:00
content.cpp Give the Plane of Fire a redder floor than CR4. 2022-11-28 19:10:42 -08:00
control.cpp embedding:: a simple general implementation of radar 2023-01-29 16:09:00 +01:00
crystal.cpp used cyclefix and raddif in more places; (c)spin90, (c)spin180 and spin180 functions; rephrased M_PI in terms of TAU and x._deg when applicable 2022-11-13 16:22:55 +01:00
debug.cpp CLI option -each-random 2023-01-04 23:27:27 +01:00
dialogs.cpp fixed a crash when no last 2023-01-04 23:24:52 +01:00
direntx.h Add "inline" to silence GCC's -Wunused-function warnings in direntx.h. 2018-06-29 16:26:20 -07:00
drawing.cpp rewritten the embeddings more nicely 2023-01-27 00:27:10 +01:00
earcut.hpp Remove extra semis in struct defs 2021-06-28 22:33:08 -07:00
embeddings.cpp embedding:: a simple general implementation of radar 2023-01-29 16:09:00 +01:00
embuild.sh emscripten uses ZLIB 2020-03-07 04:47:10 +01:00
environment.cpp fixed Princess using boat 2023-01-08 15:59:28 +01:00
euclid.cpp rewritten the embeddings more nicely 2023-01-27 00:27:10 +01:00
expansion.cpp expansion improved again: auto_extend can be disabled 2022-10-27 16:06:39 +02:00
fake-mobile.cpp savefile selection / an option to use no savefile 2022-09-15 12:38:39 +02:00
fake.cpp used cyclefix and raddif in more places; (c)spin90, (c)spin180 and spin180 functions; rephrased M_PI in terms of TAU and x._deg when applicable 2022-11-13 16:22:55 +01:00
fieldpattern.cpp Big change: spatial_embedding option 2022-12-09 02:33:15 +01:00
flags.cpp added flags for Dice 2021-06-01 13:07:56 +02:00
floorshapes.cpp moved kleinize from floorshapes to hyperpoint 2023-01-29 14:16:50 +01:00
game.cpp Orb of Choice now works with Orb of Safety 2022-10-06 12:32:06 +02:00
geom-exp.cpp rewritten the embeddings more nicely 2023-01-27 00:27:10 +01:00
geometry.cpp rewritten the embeddings more nicely 2023-01-27 00:27:10 +01:00
geometry2.cpp embeddings:: implemented the cylinderHE embedding 2023-01-27 11:16:34 +01:00
glhr.cpp fixed SDL2 (with GLEW) on Windows 2022-06-10 18:45:15 +02:00
goldberg.cpp rewritten the embeddings more nicely 2023-01-27 00:27:10 +01:00
graph.cpp embedding:: a simple general implementation of radar 2023-01-29 16:09:00 +01:00
help.cpp dialog:: lists in help extensions 2022-12-04 14:49:06 +01:00
heptagon.cpp Big change: spatial_embedding option 2022-12-09 02:33:15 +01:00
history.cpp Big change: spatial_embedding option 2022-12-09 02:33:15 +01:00
hprint.cpp kz added for shiftmatrix and shiftpoint 2023-01-06 00:24:58 +01:00
hr-icon.ico Initialization with hyperrogue-66 2015-08-08 15:57:52 +02:00
hud.cpp fixed context help getting stuck in corner stats mode 2023-01-08 15:59:28 +01:00
hyper-main.cpp savefile selection / an option to use no savefile 2022-09-15 12:38:39 +02:00
hyper.cpp rewritten the embeddings more nicely 2023-01-27 00:27:10 +01:00
hyper.h 12.1h 2023-01-08 16:44:28 +01:00
hyper.rc 10.0n 2017-09-04 20:43:45 +02:00
hyper_function.h Add `explicit` and `override` consistently everywhere else. NFCI. 2021-07-11 18:03:08 -04:00
hyperpoint.cpp moved kleinize from floorshapes to hyperpoint 2023-01-29 14:16:50 +01:00
hyperrogue-music.txt fixed the new music 2021-06-09 05:49:54 +02:00
hyperweb.cpp made background screen darkening consistent and optional 2022-07-05 11:51:06 +02:00
hypgraph.cpp embeddings:: simplified and fixed euc_in_sl2 2023-01-27 10:17:54 +01:00
inforder.cpp Add `explicit` and `override` consistently everywhere else. NFCI. 2021-07-11 18:03:08 -04:00
intra.cpp rewritten the embeddings more nicely 2023-01-27 00:27:10 +01:00
inventory.cpp inventory:: added missing outlines 2022-12-04 15:35:58 +01:00
irregular.cpp rewritten the embeddings more nicely 2023-01-27 00:27:10 +01:00
items.cpp Grammar fix to Alt-to-highlight message. 2022-10-05 20:26:17 -07:00
kite.cpp rewritten the embeddings more nicely 2023-01-27 00:27:10 +01:00
landgen.cpp fixed random walls to appear in embedded_plane 2022-12-15 09:59:02 +01:00
landlock.cpp cheatdest_list 2022-12-13 19:05:39 +01:00
langen.cpp FRENCH: gender flags, fixed a bunch of small stuff 2022-07-05 19:57:02 +02:00
language-cz.cpp Grammar fix to Alt-to-highlight message. 2022-10-05 20:26:17 -07:00
language-de.cpp fixed message about 9 types 2021-10-01 08:00:42 +02:00
language-fr.cpp Grammar fix to Alt-to-highlight message. 2022-10-05 20:26:17 -07:00
language-pl.cpp Grammar fix to Alt-to-highlight message. 2022-10-05 20:26:17 -07:00
language-ptbr.cpp fixed 'Orb of the Love' 2021-12-12 20:41:11 +01:00
language-ru.cpp Grammar fix to Alt-to-highlight message. 2022-10-05 20:26:17 -07:00
language-tr.cpp fixed message about 9 types 2021-10-01 08:00:42 +02:00
language.cpp FRENCH: added "de" / "d'" 2022-07-05 23:16:56 +02:00
legacy.cpp fixed extra semicolon 2022-02-27 01:16:42 +01:00
locations.cpp increased the value of special-move constants to >100 so that the limit on sides is indeed 120 2022-04-24 22:57:35 +02:00
makeh.cpp one more update for older compilers 2019-09-13 18:33:15 +02:00
mapeditor.cpp Big change: spatial_embedding option 2022-12-09 02:33:15 +01:00
mapeffects.cpp An option to play on a disk (and use bounded space rules). Also renamed 'bounded' flag to 'closed' or similar, and improved Halloween 2022-05-21 13:08:42 +02:00
menus.cpp used cyclefix and raddif in more places; (c)spin90, (c)spin180 and spin180 functions; rephrased M_PI in terms of TAU and x._deg when applicable 2022-11-13 16:22:55 +01:00
mingw.condition_variable.h fixed the thread locking 2020-01-28 17:58:55 +01:00
mingw.invoke.h threads in MinGW 2020-01-16 18:11:59 +01:00
mingw.mutex.h threads in MinGW 2020-01-16 18:11:59 +01:00
mingw.shared_mutex.h fixed the thread locking 2020-01-28 17:58:55 +01:00
mingw.thread.h threads in MinGW 2020-01-16 18:11:59 +01:00
mobile.cpp updated mobile for menu changes 2022-07-12 14:46:31 +02:00
models.cpp Big change: spatial_embedding option 2022-12-09 02:33:15 +01:00
monstergen.cpp Big change: spatial_embedding option 2022-12-09 02:33:15 +01:00
monstermove.cpp shmup:: fixed Gadflies appearing forever 2022-11-04 23:15:00 +01:00
multi.cpp added some missing guards for CAP_RACING and CAP_COMMANDLINE 2022-07-12 14:46:31 +02:00
multigame.cpp Big change: spatial_embedding option 2022-12-09 02:33:15 +01:00
mymake.cpp Use master's mymake.cpp 2022-09-17 14:42:46 -07:00
netgen.cpp used cyclefix and raddif in more places; (c)spin90, (c)spin180 and spin180 functions; rephrased M_PI in terms of TAU and x._deg when applicable 2022-11-13 16:22:55 +01:00
nofont.cpp mymake now works with Emscripten 2020-10-12 01:28:50 +02:00
nonisotropic.cpp embeddings:: implemented the cylinderHE embedding 2023-01-27 11:16:34 +01:00
orbgen.cpp Orb of Earth no longer marked useless in Wetland 2022-09-17 11:23:13 +02:00
orbs.cpp fixed Orb of Teleport/Illusion thinking that they are unusable 2022-09-16 22:35:37 +02:00
papermodeldata-help.txt papermodeldata files added 2019-05-16 09:42:22 +02:00
papermodeldata.txt papermodeldata files added 2019-05-16 09:42:22 +02:00
passable.cpp fixed Princess using boat 2023-01-08 15:59:28 +01:00
pattern2.cpp Big change: spatial_embedding option 2022-12-09 02:33:15 +01:00
patterns.cpp exporting necessary stuff all over (in progress) 2019-09-12 22:50:16 +02:00
pcmove.cpp fixed 'orb used' flags not being rolled back in some cases 2022-09-09 12:22:49 +02:00
polygons.cpp rewritten the embeddings more nicely 2023-01-27 00:27:10 +01:00
quit.cpp extra exports 2022-08-14 19:25:10 +02:00
quotient.cpp new geometry gHalfBring 2021-09-30 12:04:26 +02:00
racing.cpp Big change: spatial_embedding option 2022-12-09 02:33:15 +01:00
radar.cpp embedding:: a simple general implementation of radar 2023-01-29 16:09:00 +01:00
raycaster.cpp rewritten the embeddings more nicely 2023-01-27 00:27:10 +01:00
reg3.cpp final_coords now refers to cgi.emb->logical_to_base 2023-01-29 14:17:41 +01:00
renderbuffer.cpp fixed renderbuffer from SDL 2022-04-26 16:19:02 +02:00
rug.cpp auto-configure Clifford Torus embedding 2023-01-05 16:12:23 +01:00
rulegen.cpp tes:: split get_adj into two functions, one with connection specified (inlcuding mirror), and one not 2022-10-08 01:53:02 +02:00
rulegen3.cpp some fixes for older compilers 2022-08-26 14:24:58 +02:00
savemem.cpp savemem:: correct delete functions used 2022-07-17 12:36:21 +02:00
savepng.cpp fixup to mymake/savepng 2021-03-07 14:06:11 +01:00
savepng.h Updated to 8.3j 2016-08-26 11:58:03 +02:00
scores.cpp dialog:: improvements to list dialogs 2022-10-27 16:06:39 +02:00
screenshot.cpp a and b are now param_f 2023-01-04 23:31:55 +01:00
shaders.cpp rewritten the embeddings more nicely 2023-01-27 00:27:10 +01:00
shmup.cpp rewritten the embeddings more nicely 2023-01-27 00:27:10 +01:00
shyp-geodesics.dat updated geodesic tables 2020-04-17 21:01:31 +02:00
sky.cpp fixup to new embeddings, pointer cgi1 in sky 2023-01-27 10:18:19 +01:00
solv-geodesics.dat updated geodesic tables 2020-04-17 21:01:31 +02:00
sound.cpp find_file to find files in HYPERPATH 2022-08-26 12:23:58 +02:00
source-doc.md Doxygen files added 2019-09-12 23:35:04 +02:00
sphere.cpp Eliminate -Woverloaded-virtual warnings from Clang. NFCI. 2021-07-12 17:51:39 -04:00
ssol-geodesics.dat updated geodesic tables 2020-04-17 21:01:31 +02:00
surface.cpp used cyclefix and raddif in more places; (c)spin90, (c)spin180 and spin180 functions; rephrased M_PI in terms of TAU and x._deg when applicable 2022-11-13 16:22:55 +01:00
sysconfig.h dialog:: find_highlight 2022-11-04 23:14:59 +01:00
system.cpp switching nisot::geodesic_movement now automatically switches the perspective -- basically, light also moves as chosen 2022-12-16 23:08:54 +01:00
textures.cpp used cyclefix and raddif in more places; (c)spin90, (c)spin180 and spin180 functions; rephrased M_PI in terms of TAU and x._deg when applicable 2022-11-13 16:22:55 +01:00
tour.cpp slide text improvements 2022-08-13 22:44:44 +02:00
usershapes.cpp used cyclefix and raddif in more places; (c)spin90, (c)spin180 and spin180 functions; rephrased M_PI in terms of TAU and x._deg when applicable 2022-11-13 16:22:55 +01:00
util.cpp used cyclefix and raddif in more places; (c)spin90, (c)spin180 and spin180 functions; rephrased M_PI in terms of TAU and x._deg when applicable 2022-11-13 16:22:55 +01:00
vr.cpp Improved the UI for 'geodesic movement' setting, and also make it work correctly in SL2 and hyperbolic geometries 2022-12-25 12:14:36 +01:00
wfcgen.cpp made background screen darkening consistent and optional 2022-07-05 11:51:06 +02:00
yendor.cpp tactic:: fixed page buttons 2022-11-04 23:15:00 +01:00

README.md

HyperRogue

TravisCI badge TravisCI badge TravisCI badge

A puzzle roguelike in the hyperbolic plane. See the HyperRogue website for detailed and most up-to-date information. Compiled executables can be downloaded from itch.io and from the HyperRogue website.

Released under GNU General Public License, version 2. As such, it comes without any warranty.

If you would like to thank me for HyperRogue, you can support the development by buying paid versions (with more up-to-date content and some social and competitive features), or in other ways. You can contact me at zeno@attnam.com, or at my blog, or via Twitter.

The game

You are a lone outsider in a strange, non-Euclidean world. You can move with the numpad, vi keys (hjklyubn), or mouse. You can also skip turns by pressing ".".

As a Rogue, your goal is to collect as many treasures as possible. However, collecting treasures attracts dangerous monsters (on the other hand, killing the monsters allows more treasures to be generated).

You can kill most monsters by moving into them. Similarly, if the monster was next to you at the end of your turn, it would kill you. The game protects you from getting yourself killed accidentally by ignoring moves which lead to instant death (similar to the check rule from Chess).

Ultimately, you will probably run into a situation where monsters surround you. That means that your adventure is over, and you will have to teleport back to the Euclidean world to survive by pressing Escape (quit).

Collecting enough treasure also allows you to find rare magical orbs, which grant you one-time or time-limited special abilities.

The world is a combination of over 60 types of lands. Each land type has specific style (monsters, treasure, magical orbs, terrain features). Collecting treasures only attracts more monsters in lands of the same type, so you can try to collect lots of treasure in several different lands!

Some of these lands are available from the beginning, others can be found only if you have proven yourself (press ESC to know what you should do to access more lands). Ultimately, you will be able to access Hell, and look for the fabulous Orbs of Yendor which are hidden there. Get at least one of them to prove that you are a true winner! Only the best players will be able to face the challenges of Hell, but both the monsters and the challenges associated with the Orbs of Yendor are different than in the rest of the game, so it should be worth it.

You can see tooltips by placing the mouse over stuff. You can also right click to get more information about game objects.

Press v to configure the game. You can also rotate the world by pressing arrow keys, PageUp and PageDn (not numpad). You can center on the PC by pressing Home.

Your scores and other stats about your games are recorded to file hyperrogue.log (in Linux, ~/.hyperrogue.log). You can save your configuration to file hyperrogue.ini (in Linux, ~/.hyperrogue.ini).

The surface the game is played on is called a hyperbolic plane. It seems there is just a very small amount of games and other works of art which use hyperbolic geometry (the most well known are some works of M.C. Escher).

The game dynamically generates new parts of the world as you move. Due to nature of the hyperbolic plane, the chances that you get back to a place where you have been before are very low (unless you go back exactly the same way). See more information about the geometry used on the blog.

You can aim for the Orb of Yendor, or you can simply aim for as high score as possible.

Modifications

OK, now lots of the above can be changed. You can change the geometry and topology (to Euclidean, spherical, or even to nonisotropic 3D geometries). You can play challenges based on various in-game quests, and even try some other game genres in non-Euclidean spaces (roguelite aka shmup, racing, peaceful puzzles).

RogueViz

HyperRogue uses RogueViz, which is our engine for non-Euclidean games, computations and visualizations. This repo includes the source code of RogueViz demos in subdirectory rogueviz, but not the data, which is available on itch.io. RogueViz is funded by the National Science Centre, Poland, grant UMO-2019/35/B/ST6/04456.

Development

Build prerequisites

On Linux with apt-get:

sudo apt-get install make g++ libsdl1.2-dev libsdl-ttf2.0-dev libsdl-gfx1.2-dev libsdl-mixer1.2-dev libglew-dev

On macOS with Homebrew:

brew install sdl sdl_ttf sdl_gfx sdl_mixer glew

macOS users might also have to edit /usr/local/include/SDL/SDL_gfxPrimitives.h at line 38 to use quote include.

Building HyperRogue from source

git clone https://github.com/zenorogue/hyperrogue.git hyperrogue
cd hyperrogue
make

The mymake program builds HyperRogue in parts. It takes longer than the method shown above, but it uses significantly less memory during compilation, and when you change something, mymake will only recompile the changed file. Additionally, it can be easily configured, e.g., to produce an optimized build, or to include addons (see mymake.cpp for some example invocations, and devmods for some example addons). Most useful parameters include -O3 (optimized build), -rv (include the RogueViz demos), -vr (build the VR version). Compiler flags like -Werror (treat warnings as errors) and -march=native work too.

make mymake && ./mymake

The source code is not documented very well. You can see the current state of the documentation, as generated by Doxygen, here.