@zsbzsb: Thanks! Glad you like it!
Hey Sleepless,
Very cool game you already made, I know its hard work, because I am working on a very similar thing too.
Did you make all the graphics your own? If so, you have some talent
Keep up your good work, I know its gonna be a great game!
Hi Geheim! Thanks for the compliment! No, I do not make all the graphics on my own, thankfully
.
that's impressive !
I was working on a similar project but I had problems with perspective when a player was between two tiles
how did you manage perspective ?
do you draw every tile in a loop or they are attached together and drown in one call ? do you use the sf::sprite class for tiles or vertices ?
thanks
Thanks! In Eleutheromania, the dynamic actors (like the player or NPCs) are not locked on a strict "grid-to-grid" movement. They are all free to move as they like and the world scrolls after the player on a pixel basis. You can find good articles on this by googling "Scrolling tiles" for example.
I only draw the tiles that are within the visible area of the screen. Those tiles are drawn in a loop. I will maybe write a caching function for this (when it can be applied) to save som CPU performance, but it's not really that big of a deal.
I use sprites for the tiles right now because I had trouble getting the texture blending to work otherwise. I re-use the tiles for the map, so the world map only consists of IDs that tells the tile engine which tile to render. That means that it only exists one copy of each unique tile type. This allows me to have a very big game world.
Hi !
I'm pretty impressed with what you have done !
I'm wondering : how do you manage the collision detections ? Is it just a grid or a more complex structure ?
thanks!
Hello lezebulon and thank you! I use two systems for collision detection, one for the player and one for the pathfinding. The player is checked against a complex structure of shapes. The NPCs are using the pathfinding algorithm I've written, and it checks for collisions when calculating a path. This algorithm uses a grid that is generated out of the complex structure that the player uses. This grid includes possible collisions from tiles that are not walkable (like water), and static actors (like trees). The grid is basicly a sparse matrix that is on a more detailed level than the ground tiles. Sorry if this explaination is hard to understand
.