Skip to Main Content

BTD_Mod_Helper​.Api​.Towers​.ModMutator


BloonsTD6 Mod Helper

BTD_Mod_Helper.Api.Towers

ModMutator Class

ModContent that implements a custom version of a Il2CppAssets.Scripts.Simulation.Objects.BehaviorMutator

public abstract class ModMutator : BTD_Mod_Helper.Api.ModContent

Inheritance System.ObjectModContent  ModMutator

Derived
ModMutator<T>

Properties

ModMutator.BuffIcon Property

Buff Icon to use for this mutator, if any

public virtual BuffIndicatorModel BuffIcon { get; }

Property Value

Il2CppAssets.Scripts.Models.GenericBehaviors.BuffIndicatorModel

ModMutator.CantBeAbsorbed Property

Whether this is immune to effects like Lych absorb

public virtual bool CantBeAbsorbed { get; }

Property Value

System.Boolean

ModMutator.IsUnique Property

Whether only one of this mutator can be applied to an entity at once

public virtual bool IsUnique { get; }

Property Value

System.Boolean

ModMutator.MutatorId Property

ID to use for the mutator. Defaults to Id, of course

public virtual string MutatorId { get; }

Property Value

System.String

ModMutator.OverrideStackCount Property

Whether to override the visual stack count of this mutator on a tower

public virtual bool OverrideStackCount { get; }

Property Value

System.Boolean

ModMutator.Priority Property

Mutator Priority to use. Higher values make the Mutator happen earlier in the process in relation to other mutators.
For reference, the Paths++ internal mutator is ~100 to be before pretty much all others

public virtual int Priority { get; }

Property Value

System.Int32

ModMutator.Saved Property

Whether this mutator should be manually saved

public virtual bool Saved { get; }

Property Value

System.Boolean

Methods

ModMutator.Create(JToken) Method

Creates a BehaviorMutator for use with the specified custom data

public BehaviorMutator Create(JToken data=null);

Parameters

data Newtonsoft.Json.Linq.JToken

custom data

Returns

Il2CppAssets.Scripts.Simulation.Objects.BehaviorMutator
BehaviorMutator

ModMutator.Get(Mutable, JToken) Method

Gets the TimedMutator for this ModMutator on an entity

public TimedMutator Get(Mutable mutable, out JToken data);

Parameters

mutable Il2CppAssets.Scripts.Simulation.Objects.Mutable

mutated entity

data Newtonsoft.Json.Linq.JToken

custom data

Returns

Il2CppAssets.Scripts.Simulation.Objects.TimedMutator
TimedMutator

ModMutator.Get(Mutable) Method

Gets the TimedMutator for this ModMutator on an entity

public TimedMutator Get(Mutable mutable);

Parameters

mutable Il2CppAssets.Scripts.Simulation.Objects.Mutable

mutated entity

Returns

Il2CppAssets.Scripts.Simulation.Objects.TimedMutator
TimedMutator

ModMutator.GetData(BehaviorMutator) Method

Gets the stored custom data for the behavior mutator

public virtual JToken GetData(BehaviorMutator mutator);

Parameters

mutator Il2CppAssets.Scripts.Simulation.Objects.BehaviorMutator

BehaviorMutator

Returns

Newtonsoft.Json.Linq.JToken
json token of custom data

ModMutator.LoadMutator(Mutable, MutatorSaveDataModel) Method

Loads this mutator back onto an entity from its MutatorSaveDataModel

public virtual void LoadMutator(Mutable mutable, MutatorSaveDataModel mutatorSaveDataModel);

Parameters

mutable Il2CppAssets.Scripts.Simulation.Objects.Mutable

entity to mutate

mutatorSaveDataModel Il2CppAssets.Scripts.Models.Profile.MutatorSaveDataModel

mutator save data

ModMutator.Mutate(Model, Model, JToken) Method

Applies this mutator to a model

public abstract bool Mutate(Model baseModel, Model model, JToken data);

Parameters

baseModel Il2CppAssets.Scripts.Models.Model

Version of the model with no mutators applied

model Il2CppAssets.Scripts.Models.Model

Current model, the one that should be mutated

data Newtonsoft.Json.Linq.JToken

any custom data for the mutator in the form of JSON

Returns

System.Boolean
whether any changes were actually made

ModMutator.SaveMutator(Mutable, TimedMutator) Method

Saves this mutator to a MutatorSaveDataModel

public virtual MutatorSaveDataModel SaveMutator(Mutable mutable, TimedMutator timedMutator);

Parameters

mutable Il2CppAssets.Scripts.Simulation.Objects.Mutable

mutated entity

timedMutator Il2CppAssets.Scripts.Simulation.Objects.TimedMutator

current mutator

Returns

Il2CppAssets.Scripts.Models.Profile.MutatorSaveDataModel
mutator save data

ModMutator.StackCount(JToken) Method

To what amount to override the visual stack count of this mutator on a tower
Requires OverrideStackCount to be true

public virtual int StackCount(JToken data);

Parameters

data Newtonsoft.Json.Linq.JToken

Returns

System.Int32