ProjectVCharacterXpUpgradePreview class
What leveling a character with a set of EXP items would do: whether it can be sent, the EXP gained, and the level and stats it would reach. Read-only.
Namespace: SilverTiger.ProjectV.Unity.Presentation.Character
public sealed class ProjectVCharacterXpUpgradePreview
Constructors
ProjectVCharacterXpUpgradePreview(bool canSubmit, string message, long grantedExperience, long projectedExperience)
Creates a preview with only the basic values, for example in tests. Level fields stay 0.
public ProjectVCharacterXpUpgradePreview(bool canSubmit, string message, long grantedExperience, long projectedExperience);
Parameters
| Name | Type | Description |
|---|---|---|
canSubmit | bool | True when the level-up can be sent. |
message | string | Text to show. |
grantedExperience | long | The EXP the selected items give. |
projectedExperience | long | The character's total EXP after the items. |
Properties
| Property | Type | Description |
|---|---|---|
CanSubmit | bool | True when the Level Up button can be enabled. Also true when the items add EXP but not enough for a level yet: the EXP is kept. |
Message | string | Text to show: what will happen, or why it cannot be sent. |
GrantedExperience | long | The EXP the selected items give. |
ProjectedExperience | long | The character's total EXP after the selected items. |
CurrentExperience | long | The character's total EXP now. |
CurrentLevel | int | The character's level now; 0 when the character is not found. |
TargetLevel | int | The highest level ProjectedExperience reaches; equals CurrentLevel when no level is gained. |
MaxLevel | int | The character's maximum level. |
AvailableLevelCount | int | How many levels the EXP reaches: TargetLevel minus CurrentLevel. The wallet may still limit it. |
CurrentLevelExperience | long | EXP earned inside the current level, for the current EXP bar. |
CurrentLevelRequiredExperience | long | EXP the current level needs in total to reach the next one; 0 at the maximum level. |
TargetLevelExperience | long | EXP inside the target level after the items, for the preview EXP bar. |
TargetLevelRequiredExperience | long | EXP the target level needs in total to reach the next one; 0 at the maximum level. |
RemainingExperience | long | The EXP left over inside the target level; same as TargetLevelExperience. |
CurrentStats | ProjectVCharacterStats? | The stats now; null when the character is not found. |
TargetStats | ProjectVCharacterStats? | The stats at TargetLevel; same as CurrentStats when no level is gained. |