Game time and pausing

I am writing a simple game where some things happen after some amount of time. I used simple time analog of the framework I use to schedule these events, however, I have found that I will not be able to pause the game because the time is continuously increasing and nothing can stop it. So … Read more

C++/OpenGL Game – How to Make it Compatible with Screen Recorders?

I’m developing a 3D tower defense-like game in C++/OpenGL on Windows. The problem I’m having isn’t about the game itself (the game runs fine), but it’s about using screen recording software to record gameplay. For some reason, whenever I try to record the screen (I’ve tried both Camtasia Studio 8 and Fraps 3.5.9), it slows … Read more

Time critical events based on framerate

Problem Description Basically, I’ve made a “programming game” in which I’ve made my own scripting language. It is a completely standard Lunar Lander game, though instead of directly controlling the lander using keyboard input, it instead fires a sequence of commands you have provided through the scripting language I made. This all works, and I’ve … Read more

Creating the concept of Time

So I’ve reached the point in my exploration of gaming where I’d like to implement the concept of time into my little demo I’ve been building. What are some common methodologies for creating the concept of time passing within a game? My thoughts so far: My game loop tends to spend a fair amount of … Read more

Is running cron jobs every minute a good practice for browser-based games?

I’m trying to create a browser-based game (made in PHP, MySQL, Js, HTML, and CSS) that is heavily dependent on user’s actions being carried out after a certain amount of time passed whether online or offline. Will running cron jobs every second/minute a good practice or a solution to my problem? Please check out this … Read more

Execute code at specific intervals, only once?

I am having an issue with XNA, where I want to execute some code in my Update method, but only at a given interval, and only once. I would like to avoid booleans to check if I’ve already called it once, if possible. My code is here: if ((gameTime.TotalGameTime.TotalMilliseconds % 500) == 0) { Caret.Visible … Read more