Skip to Main Content
Table of Contents

BTD_Mod_Helper​.Extensions​.AddBehaviorToBloonModelBehaviorExt


BloonsTD6 Mod Helper

BTD_Mod_Helper.Extensions

AddBehaviorToBloonModelBehaviorExt Class

Extensions for AddBehaviorToBloonModels

public static class AddBehaviorToBloonModelBehaviorExt

Inheritance System.Object  AddBehaviorToBloonModelBehaviorExt

Methods

AddBehaviorToBloonModelBehaviorExt.AddBehavior(this AddBehaviorToBloonModel, ModelHelper) Method

Adds a wrapped behavior from a ModelHelper to this tower

public static void AddBehavior(this AddBehaviorToBloonModel model, BTD_Mod_Helper.Api.Helpers.ModelHelper behavior);

Parameters

model Il2CppAssets.Scripts.Models.Towers.Projectiles.Behaviors.AddBehaviorToBloonModel

behavior ModelHelper

AddBehaviorToBloonModelBehaviorExt.AddBehavior(this AddBehaviorToBloonModel, T) Method

Add a Behavior to this model

public static void AddBehavior<T>(this AddBehaviorToBloonModel model, T behavior)
    where T : Model;

Type parameters

T

Parameters

model Il2CppAssets.Scripts.Models.Towers.Projectiles.Behaviors.AddBehaviorToBloonModel

behavior T

AddBehaviorToBloonModelBehaviorExt.GetBehavior(this AddBehaviorToBloonModel) Method

Return the first Behavior of type T, or null if there isn't one

public static T GetBehavior<T>(this AddBehaviorToBloonModel model)
    where T : Model;

Type parameters

T

The Behavior you want

Parameters

model Il2CppAssets.Scripts.Models.Towers.Projectiles.Behaviors.AddBehaviorToBloonModel

Returns

T

AddBehaviorToBloonModelBehaviorExt.GetBehavior(this AddBehaviorToBloonModel, int) Method

Return the index'th Behavior of type T, or null

public static T GetBehavior<T>(this AddBehaviorToBloonModel model, int index)
    where T : Model;

Type parameters

T

The Behavior you want

Parameters

model Il2CppAssets.Scripts.Models.Towers.Projectiles.Behaviors.AddBehaviorToBloonModel

index System.Int32

Returns

T

AddBehaviorToBloonModelBehaviorExt.GetBehavior(this AddBehaviorToBloonModel, string) Method

Return the first Behavior of type T whose name contains the given string, or null

public static T GetBehavior<T>(this AddBehaviorToBloonModel model, string nameContains)
    where T : Model;

Type parameters

T

The Behavior you want

Parameters

model Il2CppAssets.Scripts.Models.Towers.Projectiles.Behaviors.AddBehaviorToBloonModel

nameContains System.String

Returns

T

AddBehaviorToBloonModelBehaviorExt.GetBehaviors(this AddBehaviorToBloonModel) Method

Return all Behaviors of type T

public static System.Collections.Generic.List<T> GetBehaviors<T>(this AddBehaviorToBloonModel model)
    where T : Model;

Type parameters

T

The Behavior you want

Parameters

model Il2CppAssets.Scripts.Models.Towers.Projectiles.Behaviors.AddBehaviorToBloonModel

Returns

System.Collections.Generic.List<T>

AddBehaviorToBloonModelBehaviorExt.HasBehavior(this AddBehaviorToBloonModel) Method

Check if this has a specific Behavior

public static bool HasBehavior<T>(this AddBehaviorToBloonModel model)
    where T : Model;

Type parameters

T

The Behavior you're checking for

Parameters

model Il2CppAssets.Scripts.Models.Towers.Projectiles.Behaviors.AddBehaviorToBloonModel

Returns

System.Boolean

AddBehaviorToBloonModelBehaviorExt.HasBehavior(this AddBehaviorToBloonModel, string, T) Method

Check if this has a specific named Behavior and return it

public static bool HasBehavior<T>(this AddBehaviorToBloonModel model, string nameContains, out T behavior)
    where T : Model;

Type parameters

T

The Behavior you're checking for

Parameters

model Il2CppAssets.Scripts.Models.Towers.Projectiles.Behaviors.AddBehaviorToBloonModel

nameContains System.String

behavior T

Returns

System.Boolean

AddBehaviorToBloonModelBehaviorExt.HasBehavior(this AddBehaviorToBloonModel, T) Method

Check if this has a specific Behavior and return it

public static bool HasBehavior<T>(this AddBehaviorToBloonModel model, out T behavior)
    where T : Model;

Type parameters

T

The Behavior you're checking for

Parameters

model Il2CppAssets.Scripts.Models.Towers.Projectiles.Behaviors.AddBehaviorToBloonModel

behavior T

Returns

System.Boolean

AddBehaviorToBloonModelBehaviorExt.RemoveBehavior(this AddBehaviorToBloonModel) Method

Remove the first Behavior of Type T

public static void RemoveBehavior<T>(this AddBehaviorToBloonModel model)
    where T : Model;

Type parameters

T

The Behavior you want to remove

Parameters

model Il2CppAssets.Scripts.Models.Towers.Projectiles.Behaviors.AddBehaviorToBloonModel

AddBehaviorToBloonModelBehaviorExt.RemoveBehavior(this AddBehaviorToBloonModel, int) Method

Remove the index'th Behavior of Type T

public static void RemoveBehavior<T>(this AddBehaviorToBloonModel model, int index)
    where T : Model;

Type parameters

T

The Behavior you want to remove

Parameters

model Il2CppAssets.Scripts.Models.Towers.Projectiles.Behaviors.AddBehaviorToBloonModel

index System.Int32

AddBehaviorToBloonModelBehaviorExt.RemoveBehavior(this AddBehaviorToBloonModel, string) Method

Remove the first Behavior of Type T whose name contains a certain string

public static void RemoveBehavior<T>(this AddBehaviorToBloonModel model, string nameContains)
    where T : Model;

Type parameters

T

The Behavior you want to remove

Parameters

model Il2CppAssets.Scripts.Models.Towers.Projectiles.Behaviors.AddBehaviorToBloonModel

nameContains System.String

AddBehaviorToBloonModelBehaviorExt.RemoveBehavior(this AddBehaviorToBloonModel, T) Method

Removes a specific behavior from a tower

public static void RemoveBehavior<T>(this AddBehaviorToBloonModel model, T behavior)
    where T : Model;

Type parameters

T

Parameters

model Il2CppAssets.Scripts.Models.Towers.Projectiles.Behaviors.AddBehaviorToBloonModel

behavior T

AddBehaviorToBloonModelBehaviorExt.RemoveBehaviors(this AddBehaviorToBloonModel) Method

Remove all Behaviors of type T

public static void RemoveBehaviors(this AddBehaviorToBloonModel model);

Parameters

model Il2CppAssets.Scripts.Models.Towers.Projectiles.Behaviors.AddBehaviorToBloonModel

AddBehaviorToBloonModelBehaviorExt.RemoveBehaviors(this AddBehaviorToBloonModel) Method

Remove all Behaviors of type T

public static void RemoveBehaviors<T>(this AddBehaviorToBloonModel model)
    where T : Model;

Type parameters

T

Parameters

model Il2CppAssets.Scripts.Models.Towers.Projectiles.Behaviors.AddBehaviorToBloonModel

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