bit_gossip
Pathfinding library for calculating all node pairs' shortest paths in an unweighted undirected graph.
Multiplayer top-down shooter made from scratch in C++. Web version: https://play.hypersomnia.io Made in π΅π±
git clone https://github.com/TeamHypersomnia/Hypersomnia.gitTeamHypersomnia/Hypersomnia
The community-driven multiplayer shooter.
Challenge your friend to an intense duel, or gather two clans to fight a spectacular war.
Written in modern C++, without a game engine!
Forever free and open-source β€οΈ
Comes with an in-game map Editor!
| |
|
|
|
|---|---|---|---|
| Steam | Windows | Linux | macOS |
Only 29 MB!
The game will start with an interactive Tutorial!
Run the Server Docker
Or download Server AppImage
All archives are digitally signed. You can verify signatures.
![]() |
![]() |
||
|---|---|---|---|
| Liam @ GamingOnLinux | GitHub Blog | Linux Magazine, Issue 275 | Hacker News Discussion |
Hypersomnia has been online and playable since 2017. It brings together:
Today, we have 24 unique firearms, 10 community maps, and two game modes: Bomb defusal and Gun game.
We aim to become the ultimate open-source shooter - a grand community project extensible without limit.
Declare allegiance to one of the three factions whose apple of discord is a disparity between prevailing notions of moral excellence:
Metropolis. Atlantis. Resistance.
Will you take revenge for the unethical simulation of an inferior universe? Will you support the cruel experiments to win total control over metempsychosis? Or will you join the underground civilization that awaits the end of war in this dangerous afterlife reality?
rectpack2D, written for packing textures, became famous and was used in Assassin's Creed: Valhalla.
My Entity-Component-System idea from 2013 describes techniques similar to Unity Engine patent from 2018.
Networking is based on cross-platform simulation determinism. It is 100% deterministic even across browser and native clients (Windows, Linux, MacOS) and that includes native ARM builds (aarch64)!
clang - on all OSes. It's very nice of LLVM to be ieee754-compliant by default./fp:strict for Windows builds.-ffp-model=strict for the ARM builds.std::sin, std::sqrt by these from STREFLOP.streflop::sqrt became a huge bottleneck - thankfully, I found another efficient ieee754-compliant implementation.std::unordered_map - often replacing them with deterministically ordered std::map.<random> header (its implementation differs across OSes).40 kbit/s (= 5 KB/s) under a tickrate of 60 Hz. Only player-controlled characters contribute to traffic.
Browser clients and native clients can play on the same servers, thanks to libdatachannel and datachannel-wasm.
In the browser version, you can sign in with Discord and play ranked matches to compete on the global Leaderboards!
You can host a working game server from the main menu - the game is able to forward ports out of the box!
Cute fish and insect AI with flocking behaviors. Full source: movement_path_system.cpp.
Anyone can host the entire Hypersomnia server infrastructure.
Memory pool implementation with:
std::vector).
push_back).std::swap with the last element and pop_back - a very known idiom).indirection_array pointer (1).
indirection_array[identifier] (2).objects vector pointer (3).objects[indirection_array[identifier]] (4).objects and indirection_array will usually be cached already so subsequent dereferences will be reduced to two fetches from RAM at most).indirection_array is kept up-to-date whenever objects are allocated or removed.I.
I.I+1.I.undo_last_allocate apart from the standard free. It's used by the commands that have to undo creating a resource (which means deleting it). It will free the object in a way that the next allocation will result in an identical integer id and internal pool state (with allocated objects order) as before freeing the resource. It is an optional feature for the sake of editor commands that is never used during actual gameplay. Analogously, there is an undo_last_free.Built-in self-updater: the game will download and apply updates automatically.
ssh-keygen.
..and I'm signing builds offline with a Trezor hardware wallet. This is how every update looks like on my end:
Discord and Telegram notifications when:
Beautifully simple JSON format for the game maps. This short json:
{
"settings": {
"ambient_light_color": [53, 25, 102, 255]
},
"nodes": [
{
"id": "floor",
"type": "dev_floor_128",
"pos": [640, 0],
"size": [1536, 1536]
},
{
"id": "light",
"type": "point_light",
"color": [255, 165, 0, 255],
"pos": [100, 100],
"radius": 700
},
{
"id": "wall",
"type": "dev_wall_128",
"pos": [-384, 0],
"size": [512, 1536]
},
{
"id": "crate",
"type": "crate",
"pos": [64, 448]
},
{
"id": "wood1",
"type": "hard_wooden_wall",
"pos": [192, -192]
},
{
"id": "wood2",
"type": "hard_wooden_wall",
"pos": [561.819, 206.436],
"size": [384, 128],
"rotation": -15
},
{
"id": "aquarium",
"type": "aquarium",
"pos": [1408, 0],
"rotation": 90
},
{
"id": "baka1",
"type": "baka47",
"pos": [698, -8]
},
{
"id": "baka2",
"type": "baka47",
"pos": [454, -264]
}
]
}
Instantly produces:
And speaking of the Editor..
It's created with the excellent ImGui.
You're working directly on the game world. 100% WYSIWYG.
Supports custom resources. It's enough to paste folders with PNGs, WAVs, OGGs to the map directory..
Supports GIFs as well! Just drag&drop them on the scene and they will be animated in-game, right out of the box!
It's possible to playtest a work-in-progress map with a single click:
After which you instantly appear in the game's server browser:
You will enter the game as the host.
The connecting clients will automatically download the map in its current version with all its custom resources (like in CS 1.6).
ESC will let you stop the session and go back to the Editor exactly as you left it, enabling ultra-efficient iteration cycles.
This is possible because the server, the game and the editor are all within the same executable.
The official Discord will also be notified that you're playtesting a map, so others can join in on the fun!
The Editor took well over a year to implement.
It paid off big time - there is now a neat catalogue of community maps - every one of them downloadable.
(Main article: GUIDE.md)
(Main article: BUILDING.md)
(Also check out the AGENTS.md file - while a guide for the machines, humans should respect it just as well!)
Pull requests are welcomed, should they even be typo fixes or missing const guarantees. If you plan to add a completely new feature, create a relevant issue so that everybody knows about it, because the project is continuously in a very, very active development and may undergo a revolution when it is the least expected.
A WIP documentation can be found at wiki.
Make sure to check out TeamHypersomnia for other repositories that are useful when setting up your own custom servers.
If you have questions or you fail to build Hypersomnia, reach out on Discord. Or if you just can't wait to utter some brilliant ideas with regard to the game, please do so, too!
Hypersomnia has been in development since 2013 (as seen in the commit history).
It didn't take 10 years of uninterrupted coding, though - in the meantime, I worked commercially to cover my costs of living. I saved money to be able to work less and focus on Hypersomnia. My financial decisions now let me develop the game full-time.
I use a lot of 3rdparty libraries like Box2D (physics) or yojimbo (transport layer) - everything not on this list, however, is written pretty much from scratch, in pure C++.
Many believe that writing games without an engine is no more than reinventing the wheel, or put more bluntly, a complete waste of time.
I hope this project serves as a great testament to the opposite.
Had I never embarked on this journey, I would have never made some of the interesting discoveries detailed in Tech highlights section. Video game internals are just so vast and interdisciplinary that they have limitless potential for creative breakthroughs, and it is a waste to never even entertain the idea that some widely used solutions can be replaced by something absolutely ingenious.
To reach me on Matrix, you can hop onto FOSSGralnia chat (I'm friends with them) and ping @pythagoras.
more like this
Pathfinding library for calculating all node pairs' shortest paths in an unweighted undirected graph.
search projects, people, and tags