Welcome, Guest. Please login or register. Did you miss your activation email?

Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Topics - comfyquest

Pages: [1]
1
SFML projects / Roguelike
« on: March 13, 2018, 10:04:19 pm »
Hello.
I am making a classical roguelike using SFML in c++.

It is my first time making a game in c++, and using SFML, so progress is slow, both in learning game programming, the SFML library, and the c++ language. However, I am enjoying the process, even though it is all a bit overwhelming, and there is much I struggle with.

In-Game Screenshot:


Rendering the screen above takes a total of three draw calls, one for the tilemap and the wizard (single sf::vertexArray), one for the ui (sf::vertexArray), and one for the text (sf::Text) showing various values. The gui and its text uses the default view of the window when drawing so that it is always drawn in the same position on the screen.

I am considering rendering the text as a texture, part of the gui's vertexarray, since the tileset I am using comes with its own font. However, it is quite a bit more work then using sf::Text. That said, I am not sure how well using sf::Text will scale as I need more text displayed on the screen, but I have a feeling rendering it as part of the ui's vertex array is the way to go, even if I lose the flexibility of using a truetype font, and it will be more cpu intensive. Does anyone have experience writing up a method to map strings of text to uv coordinates and vertex positions?

Anyway, thanks for creating SFML. It feels very clean, simple, unbloated, and easy to work with it for a beginner like me, unlike so many other frameworks (like popular game engines).

Pages: [1]