Table of Contents
Most modern web browsers include integrated tools that you can use to analyse the performance of the webclient.
Although the steps for doing so are similar between browsers, for simplicity this page will only show the steps for Chrome.
Setup
- Open
Developer Tools
- Go to
Performance
tab - Click
Record
button
Measuring
Now perform the actions that you are trying to measure the performance of. (e.g. joining a large world, rendering a map with many entities)
Once you've finished, click Stop
on the recording dialog.
Analysing results
Initially a summary of the time spent is shown:
The two main areas that should be noted are
- Scripting
- Rendering
Scripting
should usually take up more time than Rendering
.
If you switch to the Call Tree tab, you can see a top down view of what specifically takes the most time to execute
For example:
Here you can see that the majority of the time spent in Animation Frame Fired
.
If you then expand Animation Frame Fired
:
Here you can see that the majority of the time spent rendering frames (5718 ms) was spent rendering the 3D parts of the game in Game_Render3D
(4032 ms).
In turn, the majority of the time spent rendering the 3D parts of the game (4032 ms) was spent rendering the blocks in the world in MapRenderer_RenderNormal
(2221 ms) + MapRenderer_RenderTranslucent
(559 ms).
If you switch to the Bottom-Up tab, you can see a bottom up view of what specifically takes the most time to execute.
(Note: for analysing webclient's performance, this is usually less useful than the top down view, but can still provide some insight)
For example:
Here you can see that
- 737 ms was spent in
drawElements
(actually drawing vertices) - 728 ms was spent in
vertexAttribPointer
(setting up for drawing) - 526 ms was spent in
bindBuffer
(setting active vertex buffer) - 357 ms was spent in
_RenderNormalBatch
Wiki & Documentation
Users (WIP)
- Frequently Asked Questions
- Setting up a MC Classic Server
Developers
- MC Classic Lava Animation
- Dig Animation Detail
- MC Classic Map Generation
- Physics
- Position of the player's arm
- Directional Blocks & Auto Rotate