Class GetGeneratorUnitsForGeneratorsGoal
A IGoal that is complete when the player buys a certain number of units for a specified number of IGeneratorEntity.
Any active IGeneratorEntity within the current IStage.
The IGoal progresses by 1 whenever a IGeneratorEntity reaches the target number of units until the specified number of IGeneratorEntity have reached that many customers at which point the IGoal is complete.
IGeneratorEntity units that have been accumulated before the IGoal becomes active will count towards the target. A IGeneratorEntity purchased by the player after the IGoal becomes active will also still be eligible for contribution toward the target. See GetGeneratorUnitsForGeneratorsGoalDataInherited Members
Namespace: IdleKit.Gameplay
Assembly: cs.temp.dll.dll
Syntax
public class GetGeneratorUnitsForGeneratorsGoal : Goal<GetGeneratorUnitsForGeneratorsGoalData>, IGoal, IActivatable, IEntity, IInjectable
Constructors
GetGeneratorUnitsForGeneratorsGoal(String)
Declaration
public GetGeneratorUnitsForGeneratorsGoal(string id)
Parameters
| Type | Name | Description |
|---|---|---|
| String | id |
Properties
TargetProgression
Declaration
public override double TargetProgression { get; }
Property Value
| Type | Description |
|---|---|
| Double |
Overrides
IdleKit.Gameplay.Goal<IdleKit.Gameplay.GetGeneratorUnitsForGeneratorsGoalData>.TargetProgression
Methods
Activate()
Declaration
public override void Activate()
Overrides
IdleKit.Gameplay.Goal<IdleKit.Gameplay.GetGeneratorUnitsForGeneratorsGoalData>.Activate()
GeneratorUnitIncreased(IGeneratorEntity)
Declaration
protected virtual void GeneratorUnitIncreased(IGeneratorEntity generatorEntity)
Parameters
| Type | Name | Description |
|---|---|---|
| IGeneratorEntity | generatorEntity |
OnBuyGenerator(BuyGeneratorStateAction)
Declaration
protected virtual void OnBuyGenerator(BuyGeneratorStateAction stateAction)
Parameters
| Type | Name | Description |
|---|---|---|
| BuyGeneratorStateAction | stateAction |
OnIncrementGeneratorUnit(IncrementGeneratorUnitStateAction)
Declaration
protected virtual void OnIncrementGeneratorUnit(IncrementGeneratorUnitStateAction stateAction)
Parameters
| Type | Name | Description |
|---|---|---|
| IncrementGeneratorUnitStateAction | stateAction |
SubscribeActionListener(IEntity)
We need to listen to both BuyGeneratorStateAction and IncrementGeneratorUnitStateAction actions as both actions can increase the progress.
Declaration
protected override void SubscribeActionListener(IEntity target)
Parameters
| Type | Name | Description |
|---|---|---|
| IEntity | target |
Overrides
IdleKit.Gameplay.Goal<IdleKit.Gameplay.GetGeneratorUnitsForGeneratorsGoalData>.SubscribeActionListener(IdleKit.Gameplay.IEntity)
UnsubscribeActionListener(IEntity)
Declaration
protected override void UnsubscribeActionListener(IEntity target)
Parameters
| Type | Name | Description |
|---|---|---|
| IEntity | target |
Overrides
IdleKit.Gameplay.Goal<IdleKit.Gameplay.GetGeneratorUnitsForGeneratorsGoalData>.UnsubscribeActionListener(IdleKit.Gameplay.IEntity)
Implements
IInjectable