All Unity EditorStyles

Example of all EditorStyles
Examples of all options within EditorStyles

Reference image for the properties in EditorStyles when making custom inspectors.

Used the following code to generate it:

var width = EditorGUILayout.GetControlRect(GUILayout.Height(0f)).width;
foreach (var style in typeof(EditorStyles).GetProperties()) {
    if (style.GetValue(null) is GUIStyle guistyle) {
        var content = new GUIContent(style.Name);
        var rect = EditorGUILayout.GetControlRect(false, guistyle.CalcHeight(content, width), guistyle);
        GUI.Box(rect, content, guistyle);

Minimum code for Android Alert Dialog Box in Unity

This was difficult to find, so here it is; the smallest snippet of code to present an AlertDialog (with OK button callback) to the user:

private class OnClickListener : AndroidJavaProxy {
    public readonly Action Callback;
    public OnClickListener(Action callback) : base("android.content.DialogInterface$OnClickListener") {
        Callback = callback;
    public void onClick(AndroidJavaObject dialog, int id) {

public override void ShowAlert(string title, string content) {
    AndroidJavaObject activity = null;
    using (var unityPlayer = new AndroidJavaClass("com.unity3d.player.UnityPlayer")) {
        activity = unityPlayer.GetStatic<AndroidJavaObject>("currentActivity");
    activity.Call("runOnUiThread", new AndroidJavaRunnable(() => {
        AndroidJavaObject dialog = null;
        using (AndroidJavaObject builder = new AndroidJavaObject("$Builder", activity)) {
            builder.Call<AndroidJavaObject>("setTitle", title).Dispose();
            builder.Call<AndroidJavaObject>("setMessage", content).Dispose();
            builder.Call<AndroidJavaObject>("setPositiveButton", "OK", new OnClickListener(() => {
                Debug.Log("Button pressed");
            dialog = builder.Call<AndroidJavaObject>("create");

Note: I’m assuming all AndroidJavaObject objects need to be disposed (even when the same instance is returned in the case of the Builder), but that may not be the case.

You can remove the OnClickListener class and pass null as the final parameter for setPositiveButton if you do not need a callback.

BAR Extractor improvements

Texture support was (possibly) fixed for BTX (and DDT support added) to the BAR extractor. Just drag a BAR file into the page and it’ll load up thumbnails for all images within. I’m using it to look through the Age of Mythology files; I dont have Age of Empires 3 installed, but it should work with that too.


Visit here to use the tool.

Procedural Caustics

A few more under-the-hood fixes (mainly around value auto-swizzling). The newest version is here

I made a caustics generator in it (load the example project to see). Unfortunately PerlinNoise has a grid artifact, so cannot be used, and SimplexNoise does not wrap. I’ll need to add another noise generator once I find a suitable one.

Caustics (1).png


Distance fields

Added distance fields using an algorithm called “jump flooding”. It can be used to add bevels. The second output contains the distance values, ill swap them around at some stage.


I found this animation helpful in understanding the concept, they use a power of 2 when spreading values, but I found a power of 3 works great too, and is much cheaper – that is what the Quality slider controls.

Improved UI, set input types, Worley Noise

The UI is now much cleaner and easier to understand. The types of some parameters can be changed (for example making the frequency 2D for PerlinNoise, or changing blend to work with grayscale values). Worley Noise (aka cellular noise) has been added, which is useful for cutting out wedges from objects (like stone). Nodes that can be transformed can now wrap in Presentation space (ie. they still produce a tiling texture) or not at all. Tiles has some more properties, and offset was changed to be relative to the count (like in Substance).

Procedural Texture Generator – Shadows

Added a shadows node, made the Shape node more generic (all falloff functions work with all shapes), and optimised things a bunch. Also added FileSaver so large files export correctly.

Heres a perlin terrain:


Use this version here, it will automatically load the test surface now (just hit New to clear it).