Skip to Main Content

BTD_Mod_Helper​.Api​.Bloons​.ModBloon


BloonsTD6 Mod Helper

BTD_Mod_Helper.Api.Bloons

ModBloon Class

Class for adding in a new Bloon to the game

public abstract class ModBloon : BTD_Mod_Helper.Api.NamedModContent

Inheritance System.ObjectModContentNamedModContent  ModBloon

Derived
ModBloon<T>

Properties

ModBloon.BaseBloon Property

The Bloon in the game that this should copy from as a base. Use BloonType.[Name]

public abstract string BaseBloon { get; }

Property Value

System.String

ModBloon.BaseModBloon Property

The ModBloon that this is based off of, or null if not based on a ModBloon

protected virtual BTD_Mod_Helper.Api.Bloons.ModBloon BaseModBloon { get; }

Property Value

ModBloon

ModBloon.Camo Property

Add the necessary properties to make this a Camo Bloon

public virtual bool Camo { get; }

Property Value

System.Boolean

ModBloon.DamageStates Property

The list of displays to use as DamageStates for this Bloon

public virtual System.Collections.Generic.IEnumerable<string> DamageStates { get; }

Property Value

System.Collections.Generic.IEnumerable<System.String>

ModBloon.Fortified Property

Add the necessary properties to make this a Fortified Bloon

public virtual bool Fortified { get; }

Property Value

System.Boolean

ModBloon.Icon Property

The Icon for the Bloon within the UI, by default looking for the same name as the file

public virtual string Icon { get; }

Property Value

System.String

ModBloon.IconReference Property

If you're not going to use a custom .png for your Icon, use this to directly control its SpriteReference

public virtual SpriteReference IconReference { get; }

Property Value

Il2CppNinjaKiwi.Common.ResourceUtils.SpriteReference

ModBloon.KeepBaseId Property

Set this to true if you're making another version of the BaseBloon, like a Fortified Red Bloon

public virtual bool KeepBaseId { get; }

Property Value

System.Boolean

ModBloon.PixelsPerUnit Property

For 2D bloons, the ratio between pixels and display units. Higher number -> smaller Bloon.

public virtual float PixelsPerUnit { get; }

Property Value

System.Single

ModBloon.Regrow Property

Add the necessary properties to make this a Regrow Bloon

public virtual bool Regrow { get; }

Property Value

System.Boolean

ModBloon.RegrowRate Property

The regrow rate

public virtual float RegrowRate { get; }

Property Value

System.Single

ModBloon.RegrowsTo Property

The ID of the bloon that this should regrow into

public virtual string RegrowsTo { get; }

Property Value

System.String

ModBloon.Scale Property

For bloons with UseIconAsDisplay, the scale for the texture to use

public virtual float Scale { get; }

Property Value

System.Single

ModBloon.UseIconAsDisplay Property

Whether this Bloon should use its Icon as its display

public virtual bool UseIconAsDisplay { get; }

Property Value

System.Boolean

Methods

ModBloon.ModifyBaseBloonModel(BloonModel) Method

Apply your custom modifications to the base bloon

public abstract void ModifyBaseBloonModel(BloonModel bloonModel);

Parameters

bloonModel Il2CppAssets.Scripts.Models.Bloons.BloonModel

ModBloon.ModifyBloonModelForMatch(BloonModel, IReadOnlyList) Method

Further modifies this bloon when you go into a new match.
Useful for making conditional effects happen based on settings.

public virtual void ModifyBloonModelForMatch(BloonModel model, System.Collections.Generic.IReadOnlyList<ModModel> gameModes);

Parameters

model Il2CppAssets.Scripts.Models.Bloons.BloonModel

The Base bloon model

gameModes System.Collections.Generic.IReadOnlyList<Il2CppAssets.Scripts.Models.ModModel>

What GameModes are active for the match

ModBloon.Tick(int, Simulation, Bloon) Method

Runs each tick of the simulation for each bloon currently alive. Be sure to override DoesTick to true as it is false by default.

protected virtual void Tick(int ticks, Simulation sim, Bloon bloon);

Parameters

ticks System.Int32

The number of ticks run through the simulation (60/s)

sim Il2CppAssets.Scripts.Simulation.Simulation

The current simulation

bloon Il2CppAssets.Scripts.Simulation.Bloons.Bloon

The current bloon

ModBloon.Tick(int, Simulation) Method

Runs each tick of the simulation assuming DoesTick is true (false by default).

protected sealed override void Tick(int ticks, Simulation sim);

Parameters

ticks System.Int32

The number of ticks run through the simulation (60/s)

sim Il2CppAssets.Scripts.Simulation.Simulation

The current simulation.