17
2021
Use custom Editor fonts
Go to Unity installation folder,Start notepad as an Administrator,then edit file: \Editor\Data\Resources\fontsettings.txt Add your custom fonts there:
4
2021
You are trying to replace or create a Prefab from the instance ‘…’ that references a missing script. This is not allowed. Please change the script or remove it from the GameObject.
Solution:– Open the prefab that it mentions in the error, then check for missing script and remove it.– It doesn’t help if you remove missing script in the scene from that prefab, or even if you unpack that prefab, need to remove it from the […]
18
2020
Debug.Log: Show actual color from Color variable
Had to debug what color is the script returning for mouse pixel position, but printing out the value didn’t really help:Debug.Log(col);Since the output is like this (you don’t know whats the actual color)RGBA(0,349, 0,204, 0,416, 0,000) Enter Debug.Log with <color></color> and utf8 block:Debug.Log(“<color=#”+ColorUtility.ToHtmlStringRGB(col)+”>██████████</color> = “+col); […]
13
2018
Adding Multiple Submit Keys to Input Manager
Had to make an UI button clickable by multiple different keyboard keys (like enter, space, left/right shift etc.) And almost started writing custom script to handle extra keys when selecting UI button.. but then realized that you can duplicate Input Manager keys, and sure enough […]
20
2018
Use adb logcat with Colors
Had problems finding some Debug.LogError messages in the android logcat output, so googled around and sure enough you can enable output colors easily! Just add -v color parameter: adb logcat -s Unity ActivityManager PackageManager dalvikvm DEBUG -v color Note: Default windows Command Prompt doesn’t support […]
7
2018
Faster Debug.Log
Debug.Log() slows down your editor or even hangs if it happens to run inside some long loop, but you can make it faster by disabling stacktrace from Debug.Log()! (see image above) Tested for-loop with 100000 iterations in editor (Unity 2018.1.6f1) – 25000ms with stacktrace enabled […]
5
2018
Upgrading old 5.5 project to 2017.4 LTS
So had to upgrade one old Android+iOS cardboard app into newer unity version.. (Due to old unity doesn’t support latest apple os updates [link], missing new app store image sizes [link], some plugins are getting fixes/updates to newer versions, Android google play has new requirements […]
21
2016
How to enable unsafe keyword for Unity C#
Enabling “unsafe” for unity c# is quite simple: – Add these 2 files to your project folder (inside Assets/ folder root) – “smcs.rsp” and “gmcs.rsp” – both files contain only 1 line of text: -unsafe – Then restart Unity and VisualStudio/Monodev *Note: Unity 5.5 wants […]
16
2016
[Script] Display Version Number in UI Text
Small script for displaying current app version number from Player Settings in UI Text component. *seems to work in Android, not ios..? Source: (Attach to UI Text component) https://github.com/UnityCommunity/UnityLibrary/blob/master/Scripts/Helpers/Version/GetVersion.cs
28
2016
Add Custom Explorer Context Menu Item for Opening a Folder as Project with Unity
You can add custom context menu items into Windows Explorer (more info), so you can create custom menu item that opens the current folder as a project in Unity. (it will still warn you about project version if its different) Example RegEdit file: *Note! you […]
Recent posts
- MotionVector Effect: Object “disappears” when paused
- [GreaseMonkey] Unity Forum Fixer
- UnityHub: Make Hub application background Translucent
- Customize SpriteShapeRenderer quality (but has issues)
- Editor tool: Copy selected gameobject’s names into clipboard as rows (for Excel)
- Editor tool: Replace string in selected gameobject’s names
- UnityHub: Enable built-in Login Dialog (no more browser login/logout issues!)
- Use TikTok-TTS in Unity (with WebRequest)
- Create Scene Thumbnail Image using OnSceneSaved & OnPreviewGUI
- webgl+javascript TTS
- Using Moonsharp (LUA) + Unity Webgl
- Using 3D gameobject prefabs with Unity Tilemap + NavMesh Surface
Recent Comments
- [Asset Store] Point Cloud Viewer & Tools on
- [Asset Store] Point Cloud Viewer & Tools on
- Vector3 maths for dummies! on
- UnityHub: Make Hub application background Translucent on
- UnityHub: Make Hub application background Translucent on
- Install Android SDK+JDK+NDK for Unity (without AndroidStudio or Unity Hub) on
- Install Android SDK+JDK+NDK for Unity (without AndroidStudio or Unity Hub) on
- [Asset Store] Point Cloud Viewer & Tools on