Skip to main content

ProjectVCampaignData class

The Campaign missions and the player's total stars. Read-only; a change arrives as a new instance.

Namespace: SilverTiger.ProjectV.Unity.Presentation.Campaign

public sealed class ProjectVCampaignData

Constructors​

ProjectVCampaignData(IReadOnlyList<ProjectVCampaignMission> missions, long totalStars)​

Creates Campaign data, for example as test data.

public ProjectVCampaignData(IReadOnlyList<ProjectVCampaignMission> missions, long totalStars = 0);

Parameters

NameTypeDescription
missionsIReadOnlyList<ProjectVCampaignMission>The missions; not null.
totalStarslongThe player's total stars across all missions; 0 or more.

Exceptions

ExceptionWhen
ArgumentNullExceptionmissions is null.
ArgumentOutOfRangeExceptiontotalStars is negative.

Properties​

PropertyTypeDescription
MissionsIReadOnlyList<ProjectVCampaignMission>The missions, with the player's progress on each.
TotalStarslongThe sum of best-run stars across all missions, as confirmed by the server.
IsEmptyboolTrue when there are no missions.