Class HeroComponent
- Namespace
- TDMaker.Core.Components
- Assembly
- TDMaker.Core.dll
Independent hero progression and resurrection state.
public sealed class HeroComponent
- Inheritance
-
HeroComponent
- Inherited Members
Constructors
HeroComponent()
public HeroComponent()
Properties
Experience
Cumulative resolved experience.
public double Experience { get; }
Property Value
FreePoints
Remaining skill points at the current level.
public int FreePoints { get; }
Property Value
Level
One-based hero level.
public int Level { get; }
Property Value
Life
Current resurrection stage.
public HeroLife Life { get; }
Property Value
PendingExperience
Experience queued for the hero progression stage.
public double PendingExperience { get; }
Property Value
Profile
Immutable profile for this instance.
public HeroProfileDef Profile { get; }
Property Value
RespawnRemaining
Game seconds until the hero is active again; waiting includes the configured return duration. Active heroes return zero.
public float RespawnRemaining { get; }
Property Value
Examples
float seconds = entity.Hero.RespawnRemaining;
Remarks
Derived from fixed simulation time. A zero countdown can await the next eligible resurrection tick.
SpentPoints
Points already spent on skill ranks.
public int SpentPoints { get; }
Property Value
State
Read-only view alias for the existing resurrection stage.
public HeroLife State { get; }
Property Value
Methods
GetSkillRank(int)
Reads a purchased or unlocked skill rank.
public int GetSkillRank(int index)
Parameters
indexint