SFML community forums

General => SFML projects => Topic started by: pvigier on June 10, 2019, 01:21:05 am

Title: Vagabond - a procedural 2D RPG
Post by: pvigier on June 10, 2019, 01:21:05 am
Hi everyone,

I am Pierre, I am a user of SFML for years and love it!

For two months, I am working on a procedural world generator for a 2D RPG and I am using SFML.

The first step was to generate maps:

(https://pvigier.github.io/media/img/attachments/rivers.gif)

Then I "rasterized" the polygonal maps to obtain tiles:

(https://pvigier.github.io/media/img/vagabond-generating-tiles/rasterization_results.gif)

And this week, I have started to procedurally place objects in the biomes:

(https://pvigier.github.io/media/img/vagabond-forest-generation/cell_generation.gif)

If you want more details on the procedural generation, I wrote weekly devlogs and the series starts here (https://pvigier.github.io/2019/05/12/vagabond-map-generation.html).

For now, there is no game, there is only an editor which is made with Qt and I integrated SFML to make the rendering. It looks like that:

(https://pvigier.github.io/media/img/attachments/editor.png)

The project is still in the early stages but I plan to add dungeon/cave generation, town generation, character generation, etc. until I have a playable RPG.

If you have any question or comment, feel free!
Title: Re: Vagabond - a procedural 2D RPG
Post by: Elias Daler on June 11, 2019, 12:58:06 pm
Nice job, looks pretty neat.
Title: Re: Vagabond - a procedural 2D RPG
Post by: pvigier on June 13, 2019, 11:36:52 pm
Thanks Elias!  :)
Title: Re: Vagabond - a procedural 2D RPG
Post by: Nexus on June 16, 2019, 01:15:17 pm
Looks really interesting. From your blog post, it seems like you came up with a sophisticated way of combining multiple terrain generation methods, and the results look quite cool 8) also, your editor looks highly customizable!

Thank you for sharing all the steps in detail, I might actually come back to this at some point :)
Title: Re: Vagabond - a procedural 2D RPG
Post by: pvigier on June 30, 2019, 11:08:24 pm
Thanks! If you have any question, feel free!

Since last time, I have worked on dungeon and cave generation.

Here is an animation describing the steps of the generation:

(https://pvigier.github.io/media/img/vagabond-dungeon-cave-generation/cave_generation.gif)

Then I worked on generating tiles from the output of the generator:

(https://pvigier.github.io/media/img/vagabond-dungeon-cave-generation-part2/tiles.gif)

(https://pvigier.github.io/media/img/vagabond-dungeon-cave-generation-part2/tilesets.gif)

If you are interested by the details, I have written two new devlogs: here (https://pvigier.github.io/2019/06/23/vagabond-dungeon-cave-generation.html) and there (https://pvigier.github.io/2019/06/30/vagabond-dungeon-cave-generation-part2.html).
Title: Re: Vagabond - a procedural 2D RPG
Post by: fallahn on July 01, 2019, 04:19:36 pm
Oh cool, this looks really interesting! I shall definitely have to read your devlogs  ;D
Title: Re: Vagabond - a procedural 2D RPG
Post by: pvigier on August 26, 2019, 10:13:23 pm
Thanks!

I have continued to work on the project since last time, mostly on the game engine.

I implemented an ECS library that is available on GitHub (https://github.com/pvigier/ecs). I also wrote two articles to describe its design, the series starts here (https://pvigier.github.io/2019/07/07/entity-component-system-part1.html). I have improved the code a bit since and I should write a new article.

Then, I worked on the foundations of a game engine: an input manager, a state manager, a basic render manager, etc. You can read more in this devlog (https://pvigier.github.io/2019/07/14/vagabond-game-engine-foundations.html). I also integrate Dear ImGui using Elias' binding.

Next, I worked on an OpenGL wrapper to be able to use floating-point textures, array textures and meshes with custom vertex definition. I was happy because everything works well with SFML graphics module. You can read some thoughts about its design here (https://pvigier.github.io/2019/07/21/vagabond-opengl-wrapper-metrics.html).

I used this wrapper to implement a light system, you can see some screenshots below. It is nothing as fancy as Let There Be Light but I am happy with the results and I have still some ideas to improve it. You can read more about it here (https://pvigier.github.io/2019/07/28/vagabond-2d-light-system.html).

(https://pvigier.github.io/media/img/vagabond-2d-light-system/banner.png)

(https://pvigier.github.io/media/img/others/light_cave.gif)

Then, I worked on the physics system. I implemented a quadtree and shared my implementation here (https://pvigier.github.io/2019/08/04/quadtree-collision-detection.html), the code is available there (https://github.com/pvigier/Quadtree). Next, I implemented a simple physics engine that works well for 2D top-down RPG, I shared its design there (https://pvigier.github.io/2019/08/11/vagabond-2d-physics-engine.html).

Last week, I worked on the audio engine. It is only a thin layer above SFML audio. You can read more about it here (https://pvigier.github.io/2019/08/18/vagabond-audio-engine.html).

Finally, this week, I have worked on the user interface. I tried several libraries and chose the one that suits my needs the best. A write-up is available here (https://pvigier.github.io/2019/08/25/vagabond-choosing-gui-library.html). I finally chose MyGUI and wrote a small wrapper to integrate it in SFML, it is available here (https://github.com/pvigier/MyGUI-SFML).

(https://pvigier.github.io/media/img/vagabond-choosing-gui-library/Vagabond_Menu.png)

The next steps are networking and then working on the game itself.
Title: Re: Vagabond - a procedural 2D RPG
Post by: Daniel Schreiber Mendes on September 01, 2019, 09:02:05 pm
Amazing!
Title: Re: Vagabond - a procedural 2D RPG
Post by: Hapax on September 04, 2019, 12:54:33 am
Looks really impressive. Nice work! :D
Title: Re: Vagabond - a procedural 2D RPG
Post by: pvigier on September 04, 2019, 03:34:58 pm
Thank you very much guys!  :)
Title: Re: Vagabond - a procedural 2D RPG
Post by: pvigier on November 18, 2019, 06:58:40 pm
Quick update of my game.

I greatly improved cave generation:

(https://pvigier.github.io/media/img/vagabond-let-s-fight/dungeon_generation_v3.gif)

I also worked on monsters, combat system and a bit on the in-game interface:

(https://pvigier.github.io/media/img/attachments/hud.png)

The game now has a multiplayer mode too. I wrote a guide which contains the resources I found the most useful to implement the multiplayer mode, it is available there (https://pvigier.github.io/2019/09/08/beginner-guide-game-networking.html).

If you want more info or in-game videos, you can have a look at my Twitter account (https://twitter.com/PierreVigier) or read the devlogs (https://pvigier.github.io/tag/vagabond).

Have a nice evening!