staticskizzles
Member
I'm using vertex buffers to draw grass sprites around the room, and I want to be able to remove triangle positions for specific grass sprites, effectively removing specific grass sprites form the room. This data is held in a "vertex_buffer" so I'm trying to find a way around removing vertex positions without having to create a new vertex buffer each time I want a sprite to disappear, because I imagine that would cause the game to freeze each time.
I obviously have very minimal knowledge when it comes to vertex buffers and I feel like there are no functions to make changes to vertex buffers looking at docs.yoyogames.com. I just want to remove individual grasses from the room.
I did a little reading and assume I could use buffer_create_from_vertex_buffer but there's no certainty this code will work since I assume vertex buffers have more / less data than ordinary buffers,
and how would I delete vertex_position() of the specific grass sprite inside this vertex buffer?
I'm basically working with this code:
Any advice would be very much appreciated :3
Previous thread when I had different vertex buffers for instances at each room tile, then just drawing vbuffers at each x y without instances (both methods impacting performance greatly, hence why I'm trying to keep it as one vbuffer):
I obviously have very minimal knowledge when it comes to vertex buffers and I feel like there are no functions to make changes to vertex buffers looking at docs.yoyogames.com. I just want to remove individual grasses from the room.
I did a little reading and assume I could use buffer_create_from_vertex_buffer but there's no certainty this code will work since I assume vertex buffers have more / less data than ordinary buffers,
and how would I delete vertex_position() of the specific grass sprite inside this vertex buffer?
I'm basically working with this code:
Any advice would be very much appreciated :3
Previous thread when I had different vertex buffers for instances at each room tile, then just drawing vbuffers at each x y without instances (both methods impacting performance greatly, hence why I'm trying to keep it as one vbuffer):
GMS 2.3+ - Game slowing down when moving around the room, slowly returns to normal after staying still
Hello guys, I'll try to explain my scenario. I've been working on a game with a room that's 4000 by 4000. I don't know if that room size is overkill or not but I guess I'm trying to see what limits I can push with my game. I modified an asset that fills the room with grass vertex buffers...
forum.yoyogames.com
Last edited: