Legacy Documentation: Version 4.5.0

Script language:

  • JS
  • C#
  • Boo
Script language

Select your preferred scripting language. All code snippets will be displayed in this language.

Editor.RenderStaticPreview

RenderStaticPreview(assetPath: string, subAssets: Object[], width: int, height: int): Texture2D;
Texture2D RenderStaticPreview(string assetPath, Object[] subAssets, int width, int height);
def RenderStaticPreview(assetPath as string, subAssets as Object[], width as int, height as int) as Texture2D

Description

Override this method if you want to render a static preview that shows.

If null is returned the builtin icon for the class type is used.