Skip to content
Version 2.11.0
↓ Get the launcher

ICombatSpec.TryGetTalentSpec method

Returns true only while the entity’s spec is talent-derived: a spec root buff is present, OR the entity is inside a same-class swap gap (≤ 10 s) and still holds its last talent-derived spec. Returns false when the spec is cast-derived or unknown — including after a class change with no root buff of the new class yet, and once the entity has left view (its last value may still be returned by GetSubProfession until it reappears or the scene changes). Use this when only an authoritative spec is acceptable (e.g. uploading it); a cast guess never satisfies it.

public bool TryGetTalentSpec(EntityId entityId, out int subProfessionId)
parameter description
entityId The entity to query.
subProfessionId The talent-derived sub-profession id when the method returns true; otherwise 0.