Unity Web Player Tips and Tricks
Unity Web Player Tips and Tricks
So are you making unity games for the web player build? Least to say, you have already realized that the development process of web builds is slightly different from the usual Desktop builds and has its own set of pitfalls. So I tried compiling some Unity web player tips and tricks that might help someone else in need:
- Dynamic Resizeable Unity Web Player
Most often, you would be deploying your games and want it full screen. That too, resizeable. So, you can basically change the default html’s css to make it full screen. You can visit THIS link to proceed further. Basically you download a package and it will install custom WebTemplates in your Assets Folder. Go to Player Settings and choose the custom Template to have Full-screen Dynamic resizeable Unity Web Player.
- Web Build Logging
Also, if this all seems a hassle for you, try navigating to THIS link and download this wonderful and free unity asset package. All you need to do is Go to Menu > Reporter > Reporter. This will create a game object on the current scene. And also, Set the execution order (Edit > Project Settings > Script Execution Order), add the Reporter.cs file and set its order to the highest. Thats it. When you run the scene, try to draw a circle (clockwise) on the screen and kabam, the Reporter will throw useful information at your screen. Also, the navigation bar is scrollable ( if you missed it).
- Browser Communication
- FREE Publishing
Okay so, you need to show a quick game to your clients or boss? This is a pretty sleek trick ( and pretty old one imho):
- Make a Web Build Target
- Register at Dropbox (FREE)
- Upload your game files to your account’s public folder
- Right click on the html file you just copied and select “Copy Public Link”.
- Copy the link and share with your Client or boss
* You may need to Enable Public Folders manually.
** You may want to use Google’s URL shortner to make your shareable Game link “Pretty”.
- Optimization for Low Connection Speeds
Try making multiple Sub unity3D files as a single massive untiy3d file will take forever to load and you don’t want to loose your precious players on the excuse if they are using low connection speed. Use this stupidly easy tool to easily load Assets over internet/external file and many more stuff.
- Optimization for Low end Computer Memory
You must have the experience that almost all of the time, textures take up to 90% of all the space in the final build. As said by many people, always try to have the textures in 128×128 / 256×256 / 512 x 512 .. etc resolutions. Its just the way Unity compresses them more effectively. Also, you need to understand to make balance between Low Quality + Lower Size -AND- High Quality + Higher Size. Ofcourse the choice is not that easy but it will surely come with experience and rigorous game-play testing. Try having a quality manger script that automatically detects the target environment and loads texture assets conditionally (will be updating on the script very soon).
- coming soon
Comment below to let me know if any of the above tips are helpful to you. Will keep adding more and more unity web player tips and tricks …
The dropbox trick was shamelessly taken from this wonderful site.