Skip to Main Content

BTD_Mod_Helper​.Extensions​.SpriteExt


BloonsTD6 Mod Helper

BTD_Mod_Helper.Extensions

SpriteExt Class

Extensions for Sprites

public static class SpriteExt

Inheritance System.Object  SpriteExt

Methods

SpriteExt.SetTexture(this Sprite, Texture2D) Method

Set this Sprite's texture

public static void SetTexture(this Sprite sprite, Texture2D newTexture);

Parameters

sprite UnityEngine.Sprite

newTexture UnityEngine.Texture2D

SpriteExt.TrySaveToPNG(this Sprite, string) Method

Attempts to save a Sprite to a PNG at the given filePath, even if it isn't marked as readable

public static bool TrySaveToPNG(this Sprite sprite, string filePath);

Parameters

sprite UnityEngine.Sprite

filePath System.String

Returns

System.Boolean

To learn how to download BTD Mod Helper and install mods, click here