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 - zachprinz

Pages: [1]
1
Graphics / Recreating Vertex Arrays vs. Adjusting Vertex Position
« on: December 09, 2013, 02:57:55 am »
When using vertex arrays to draw sprites, is it better to clear the vertex array at the beginning of every frame and then add all the objects again, or to give every object it's own vertex pointer and let it change the position of that quad every frame?

I recently stopped using sf::Sprites and drawing them onto panels every frame in favor of using a vertex array. After I did this I actually saw a drop in performance and I'm trying to figure out why.

2
General / RPG Data Serialization Methods
« on: August 16, 2013, 12:45:12 am »
I've come to a point in my current project where I will need to start adding "content" (stats on items, dialog for NPC's, skills, etc.) and I have been debating how best to implement the serialization of these values.

I've found a tutorial that uses Lua to manage NPC dialog, but I'm curious as to why they are using Lua instead of c++. It seems like I could just create c++ scripts with the same information that they are typing out in Lua.
Tutorial link below
http://www.raywenderlich.com/30561/how-to-make-a-rpg

I've never used data serialization in a project before (unless you count reading in strings from a txt file) but the first thing I thought of was XML, I've also seen people using SQLite for some stuff. I've read some other things being mentioned like Boost Serialization and Googles protobuf, but pretty much know nothing about those (but for that matter I don't have much knowledge on any of these topics/libraries.)

While I'm fairly sure that I could get everything I need done by simply reading in strings (which I know I could do from a text file.) I've kind of assumed that there must be advantages to using the aforementioned methods which I could take advantage of.

I guess what I'm trying to find out is what benefit these methods would offer someone who is trying to add "content" (in my previously defined usage of the word) for an RPG style game.

I hope my question isn't too vague, thanks for any help.

Pages: [1]