Jump to content
  • Advertisement
Sign in to follow this  
  • entries
  • comments
  • views

Age of da Grub (too much Gears of War)

Sign in to follow this  


Well, I completed everything on that list that I posted last time.

I added the ability for entities to be deleted in the level editor. This wasn't so much for my sake, but I want this game to be easy to create levels for when it is finished. So yeah, it works. It required me to use a linked list to store all editor entities(it was painful), but it works.

Second, I now use a timer to handle frames rather than SDL_delay. The function I use is:

bool NextFrame(int t)
static Uint32 cur_time = SDL_GetTicks();

if((SDL_GetTicks() - cur_time) > t)
cur_time = SDL_GetTicks();
return true;

return false;

And then:

// do stuff

So now what is happening is that the program is still running in between frames, rather than being forced to wait until the next frame. I didn't know if this would make a difference, but I always thought using SDL_Delay was just not a good idea. The game now feels, noticeably smoother. I might just be imagining things, but to me the game seems to run slicker. I guess I'll let you all be the judge when you play the next demo.
Sign in to follow this  


Recommended Comments

There are no comments to display.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Advertisement

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

GameDev.net is your game development community. Create an account for your GameDev Portfolio and participate in the largest developer community in the games industry.

Sign me up!