Jump to content

  • Log In with Google      Sign In   
  • Create Account


#ActualMrFraggs

Posted 10 July 2013 - 12:19 PM

Like I said, that has nothing to do with the actual FPS/UPS calculations. The FPS/UPS variable it updates to is STRICTLY for display purposes. I added that code in after I had the rates updating at the same time as it had after I added that code. It has NOTHING to do with the actual fps/ups calculations, just the display of information that tells me how many times per second the game is updating. If I run the game, which is just a blue screen still, it updates the title of the window with that information, telling me that i'm getting about 4000-4500 FPS, and about 60-62 UPS right now. But instead of that number in the title bar changing 60 times per second, which is how many times Update() get's called per second (UPS), it checks to see if a second in time has passed, and if so, updates the title bar. Nothing more, nothing less. I can't stress that enough. It has absolutely NOTHING to do with the actual game loop. tongue.png

 

I used Pokemon as more of an example of the display I was going for, with a kind of top down approach with a full 2D world, and not a 2D side scroller. I have no intentions of emulating Pokemon gameplay at all, but at the time, that was the first game that popped into my head to use as an example of the type of display I was looking for. I should have said, not a 2D side scroller, but a 2D tile based world. 

 

GafferonGames' link is the only other link I used that I actually tried to implement the gameplay, but it almost seemed a little too complicated for a smaller indie title. Not only that, but I was having trouble trying to decipher the actual game loop in terms of FPS/UPS. Going for a time based Update() is my goal here, I guess i'm just implementing it wrong. I'll have to look over it again, for a third day in a row, and see if I can grasp it any better than I previously had. One question about this article though, is the integrate() function basically the Update() function i'm trying to use? Keep in mind, my game logic hasn't really been born yet, which is why I don't even pass a gameTime variable into Update(). It will eventually, but like I said, I need to get the main game loop running in a way I'm happy with and know it SHOULD run about the same on MOST systems first.


#1MrFraggs

Posted 10 July 2013 - 12:02 PM

Like I said, that has nothing to do with the actual FPS/UPS calculations. The FPS/UPS variable it updates to is STRICTLY for display purposes. I added that code in after I had the rates updating at the same time as it had after I added that code. It has NOTHING to do with the actual fps/ups calculations, just the display of information that tells me how many times per second the game is updating. If I run the game, which is just a blue screen still, it updates the title of the window with that information, telling me that i'm getting about 4000-4500 FPS, and about 60-62 UPS right now. But instead of that number in the title bar changing 60 times per second, which is how many times Update() get's called per second (UPS), it checks to see if a second in time has passed, and if so, updates the title bar. Nothing more, nothing less. I can't stress that enough. It has absolutely NOTHING to do with the actual game loop. :P

 

I used Pokemon as more of an example of the display I was going for, with a kind of top down approach with a full 2D world, and not a 2D side scroller. I have no intentions of emulating Pokemon gameplay at all, but at the time, that was the first game that popped into my head to use as an example of the type of display I was looking for. I should have said, not a 2D side scroller, but a 2D tile based world. 

 

GafferonGames' link is the only other link I used that I actually tried to implement the gameplay, but it almost seemed a little too complicated for a smaller indie title. Not only that, but I was having trouble trying to decipher the actual game loop in terms of FPS/UPS. Going for a time based Update() is my goal here, I guess i'm just implementing it wrong. I'll have to look over it again, for a third day in a row, and see if I can grasp it any better than I previously had.


PARTNERS