aboutsummaryrefslogtreecommitdiff
path: root/bin/game/main.lua
diff options
context:
space:
mode:
authorchai <chaifix@163.com>2018-12-24 19:15:02 +0800
committerchai <chaifix@163.com>2018-12-24 19:15:02 +0800
commit039e2541207232e0a382a52a65122a15eed9257d (patch)
treeab378128b2c0b4f228e3312595d8b91bfa30cd63 /bin/game/main.lua
parent913e41baa76cf6b866b85137c85b89be34b2376c (diff)
+physics module
Diffstat (limited to 'bin/game/main.lua')
-rw-r--r--bin/game/main.lua12
1 files changed, 2 insertions, 10 deletions
diff --git a/bin/game/main.lua b/bin/game/main.lua
index 5582cfc..ce5b62c 100644
--- a/bin/game/main.lua
+++ b/bin/game/main.lua
@@ -160,18 +160,10 @@ function jin.core.onDraw()
jin.graphics.rect(jin.graphics.RenderMode.FILL, 300, 300, 100, 50)
jin.graphics.unuseShader()
- local stats = jin.graphics.getStats()
jin.graphics.setColor(100, 100, 100, 255)
jin.graphics.useShader(jin.graphics.Shaders.Shape)
- jin.graphics.rect(jin.graphics.RenderMode.FILL, 440, 0, 140, 150)
+ jin.graphics.rect(jin.graphics.RenderMode.FILL, 440, 0, 140, 120)
jin.graphics.unuseShader()
jin.graphics.setColor(255, 255, 255, 255)
- jin.graphics.print("draw call: " .. stats.drawCalls, 450, 10)
- jin.graphics.print("canvas switches: " .. stats.canvasSwitches, 450, 30)
- jin.graphics.print("shader switches: " .. stats.shaderSwitches, 450, 50)
- jin.graphics.print("font switches: " .. stats.fontSwitches, 450, 70)
- jin.graphics.print("textures: " .. stats.textures, 450, 90)
- jin.graphics.print("canvases: " .. stats.canvases, 450, 110)
- jin.graphics.print("fonts: " .. stats.fonts, 450, 130)
-
+ jin.graphics.print(jin.graphics.getStatsStr(), 450, 10)
end \ No newline at end of file