IProjectVAlliancePresenter interface
The Alliance presenter: the player's allies, ally selection, leveling with EXP items, weapon skill upgrades and level resets. Pages should use IProjectVAllianceScreen instead; use the presenter only for what the screen contract does not cover.
Namespace: SilverTiger.ProjectV.Unity.Presentation.Alliance
public interface IProjectVAlliancePresenter
Properties
| Property | Type | Description |
|---|---|---|
Current | ProjectVAllianceSnapshot | The latest snapshot; never null. |
PendingProgression | Character.ProjectVCharacterProgressionPending? | An ally or character upgrade that was started but not confirmed, or null. While it is set, no other ally can change level; finish it with RetryPendingProgressionAsync. |
Methods
GetUpgradeState(ProjectVCharacterId allyId)
Tells whether an ally can be upgraded now and what the upgrade costs.
ProjectVCharacterUpgradeState GetUpgradeState(ProjectVCharacterId allyId);
Parameters
| Name | Type | Description |
|---|---|---|
allyId | ProjectVCharacterId | The ID of an owned ally. |
Returns
ProjectVCharacterUpgradeState: The upgrade state; when CanUpgrade is false, Message says why.
GetXpUpgradePreview(ProjectVCharacterId allyId, IReadOnlyList<ProjectVCharacterXpItemSelection> items)
Shows what leveling an ally with these EXP items would do, without changing anything.
ProjectVCharacterXpUpgradePreview GetXpUpgradePreview(ProjectVCharacterId allyId, IReadOnlyList<ProjectVCharacterXpItemSelection> items);
Parameters
| Name | Type | Description |
|---|---|---|
allyId | ProjectVCharacterId | The ID of an owned ally. |
items | IReadOnlyList<ProjectVCharacterXpItemSelection> | The EXP items and quantities to use; may be empty. |
Returns
ProjectVCharacterXpUpgradePreview: The preview with the EXP gained and the resulting EXP. CanSubmit is false, with a Message to show, when the ally is not owned or the selection cannot be used.
Exceptions
| Exception | When |
|---|---|
ArgumentNullException | items is null. |
GetLevelResetPreview(ProjectVCharacterId allyId)
Shows what resetting an ally to level 1 would refund, without changing anything.
ProjectVCharacterLevelResetPreview GetLevelResetPreview(ProjectVCharacterId allyId);
Parameters
| Name | Type | Description |
|---|---|---|
allyId | ProjectVCharacterId | The ID of an owned ally. |
Returns
ProjectVCharacterLevelResetPreview: The preview with the items to refund. CanReset is false, with a Message to show, when the reset is not possible or the data must be synchronised first.