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.


Messages - xy1qw1

Pages: [1]
1
Graphics / Re: Updating Tile Map?
« on: January 14, 2024, 12:03:50 pm »
Hapax thanks a lot for you response, yesterday i created a tilemap class. I researched some tutorials and i did something. Currently its working well. As you say i can modify tiles. That is the best tilemap system i have ever used :)

300 x 200 map (100 px per tile) is rendering with normal speed. Thanks for advices i ll keep it in my mind and apply in my project.
I m trying to make a little rpg project. If i finish the prototype of my game, i will share with forum.

Best regards.

https://ibb.co/fCbDV1k

2
Graphics / Updating Tile Map?
« on: January 12, 2024, 01:36:22 am »
Hi. I have a problem with tilemap. I used that example in my project.

https://www.sfml-dev.org/tutorials/2.6/graphics-vertex-array.php

Because i would like to create a tilemap like 100 X 100 or bigger. Previously i was trying without vertex array.
Like this code:

        int map[my][mx] = { 0,1,1,1,0,0...

}
/////////////////////////////////////////////////
        for (int h = 0; h < mx; h++)
        {
                for (int w = 0; w < my; w++)
                {
                        map[h + x][w + y] = 0;

                }
        }
 
////////////////////////////////////////////

my question is how can i update only 1 tile color, shape or another values in first example as on the top link. Please if you explain with a minimal code or share similar example links i will appreciate it. Thanks for all responses.

Pages: [1]
anything