Jump to content
Pokémon Vortex
tipsyturtle

Both Introducing an FPS cap

Recommended Posts

I have a 144Hz monitor so the game runs at 144 fps for me. I don't need it to run at that level because usually I'm doing something else on the side as I play the game. Introducing different levels of FPS caps (eg. 30, 60, 120, Max) can help ease unnecessary strain on our system's resources. 
 

CPU usage when map searching during the current Christmas event (high settings): 

w79E3Be.png

 

CPU usage when map searching during the current Christmas event (high settings) with the refresh rate of my monitor changed to 30Hz through the Settings app:

 oBlpmPx.png

 

 

Uhhh yes plz and thanks, don't wanna heat up my room more than Summer already is.

  • Thanks 1
  • Confused 1
  • Upvote 4
Link to post
Share on other sites
  • Developer

Hi tipsy,

 

It's a good idea - I'll take a look into it. An FPS-cap is not something the engine supports natively, but I'll see if I can hack one on.

 

In the world of browser-games, the game doesn't directly control the framerate - usually the game will ask the browser for an opportunity to draw a frame to the screen and the browser will dictate the framerate. (This is the only way to get high-resolution timers in web games - it wouldn't be possible to deliver smooth gameplay using ordinary timers).

 

The browser will usually try to draw frames to match your monitor's refresh rate and no more than that. It'll also do some other clever stuff like not requesting a frame if the browser is minimized or switched to another tab, saving resources.  If you can find a way to limit the framerate of the browser, then the game should follow suit.

 

Anyway, I'll see if there's a way I can monitor the framerate and then skip a render pass if the browser asks for a frame too often.

  • Thanks 1
Link to post
Share on other sites

Hey flay,

 

Thank you so much for the very informative response, I appreciate it a tonne.

On 12/21/2020 at 11:40 PM, flamescape said:

If you can find a way to limit the framerate of the browser, then the game should follow suit.

For now, I've taken this information and found a simple browser extension that is able to control the framerates of each tab I'm on so that I don't have to experience anything below 144 fps on different sites/apps (which is what other methods caused). It's called 'FPS Control' and it works as you'd expect. It would be really nice if it was possible to somehow hack a method in so that I don't have to use another browser extension for this, but I understand that it might be difficult to do through the website. I appreciate you looking into it. Thank you again~   

Edited by tipsyturtle
Link to post
Share on other sites

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

  • Recently Browsing   0 members

    No registered users viewing this page.

×
×
  • Create New...