Search Issue Tracker
By Design
Votes
0
Found in
5.6.0f3
Issue ID
900595
Regression
No
[WebGL] UnityLoader.instantiate width and height parameters do not resize canvas
To reproduce:
1. Open the project, attached by user
2. Build & Run for WebGL
3. Observe the size of the canvas
Expected: specifying width and height parameters in UnityLoader.instantiate should resize the canvas by the specified values
Actual: specifying width and height parameters in UnityLoader.instantiate does not resize the canvas by the specified values
Reproduced in 5.6.0f1, 5.6.0f2, 5.6.0f3, 5.6.0p1, 2017.1.0b1
Could not reproduce in 5.5 or lower, because this feature does not exist
By design: you need to specify whether width and height are pixel, percent values, etc.. for example:
var gameInstance = UnityLoader.instantiate("gameContainer", "Build/test.json", {width: "200px", height: "200px"});
or
var gameInstance = UnityLoader.instantiate("gameContainer", "Build/test.json", {width: "50%", height: "50%"});
All about bugs
View bugs we have successfully reproduced, and vote for the bugs you want to see fixed most urgently.
Latest issues
- Crash on nvoglv64.dll when opening a project
- [RenderGraph] [CameraStacking] Passes are failing when CameraStacking and RG are enabled
- Physics and Raycast have different behavior when enum is exposed in the Editor
- TextField's text is mixed up and overlapping when "Noto Sans-Display" font is used
- TutorialManager Warnings are thrown when creating Test Track, LEGO or 2D Platform microgame template projects
Add comment