Add a new performance viewing extension#2519
Conversation
This extension allows you to view FPS, ping, and if not browser restricted, memory usage all from 3 reporter blocks.
| this.lastFrameTime = performance.now(); | ||
| this.fps = 0; | ||
|
|
||
| const updateFPS = () => { |
There was a problem hiding this comment.
- the framerate this computes is largely meaningless for Scratch projects because Scratch projects generally do not use rAF
- a fixed version already exists in delta time extension
|
|
||
| getFps() { return this.fps; } | ||
|
|
||
| getMemory() { |
There was a problem hiding this comment.
this is not super meaningful
| } | ||
|
|
||
| async getPing() { | ||
| const startTime = performance.now(); |
There was a problem hiding this comment.
- you have syntax errors in this one, indicating that it was not tested
- the ping this computes is again not meaningful (ping to google.com implies nothing about ping to other services) and also won't work in China where a significant portion of our (desktop app) users are.
|
Hi @greenkidneybeans, we appreciate your enthusiasm to submit extensions here but we are going to ask that you use the "issues" tab on GitHub to suggest ideas and get initial feedback on your ideas before you submit another extension here. Every extension that we add here is a promise that we will maintain it forever, otherwise real projects by real people will stop working. It also can directly affect my wallet due to our security bug bounty program. Adding new things is thus a large step, not something we do on a whim for every tiny little idea someone has. You are also always able to use custom extensions that fulfill your own needs, regardless of what we merge here. |
Alright, I will make sure to know that my code works. Thanks for the advice. |
This extension allows you to view FPS, ping, and if not browser restricted, memory usage all from 3 reporter blocks.