C# Class GalaxyStorm.Services.Data.BuildingService

Inheritance: IBuildingsService
Afficher le fichier Open project: Pip3r4o/GalaxyStorm-MVC

Méthodes publiques

Méthode Description
BuildingService ( IRepository users, ILogicProvider logic ) : System
CompleteBuilding ( string userId ) : void
GetPlayerBuildings ( string userId ) : Buildings
ScheduleBuildBarracks ( string userId ) : TimeSpan?
ScheduleBuildHeadQuarters ( string userId ) : TimeSpan?

Perform necessary checks and then take resources from player, set end date and return timespan for the background worker to trigger an even when time has elapsed

ScheduleCrystalExtractor ( string userId ) : TimeSpan?
ScheduleMetalScrapper ( string userId ) : TimeSpan?
ScheduleResearchCentre ( string userId ) : TimeSpan?
ScheduleSolarCollector ( string userId ) : TimeSpan?

Private Methods

Méthode Description
CanBuild ( PlayerObject pO, int toLevel, IBuilding buildingLogic ) : bool
SubstractResources ( PlayerObject pO, int resources ) : void

Method Details

BuildingService() public méthode

public BuildingService ( IRepository users, ILogicProvider logic ) : System
users IRepository
logic ILogicProvider
Résultat System

CompleteBuilding() public méthode

public CompleteBuilding ( string userId ) : void
userId string
Résultat void

GetPlayerBuildings() public méthode

public GetPlayerBuildings ( string userId ) : Buildings
userId string
Résultat GalaxyStorm.Data.Models.PlayerObjects.Buildings

ScheduleBuildBarracks() public méthode

public ScheduleBuildBarracks ( string userId ) : TimeSpan?
userId string
Résultat TimeSpan?

ScheduleBuildHeadQuarters() public méthode

Perform necessary checks and then take resources from player, set end date and return timespan for the background worker to trigger an even when time has elapsed
public ScheduleBuildHeadQuarters ( string userId ) : TimeSpan?
userId string
Résultat TimeSpan?

ScheduleCrystalExtractor() public méthode

public ScheduleCrystalExtractor ( string userId ) : TimeSpan?
userId string
Résultat TimeSpan?

ScheduleMetalScrapper() public méthode

public ScheduleMetalScrapper ( string userId ) : TimeSpan?
userId string
Résultat TimeSpan?

ScheduleResearchCentre() public méthode

public ScheduleResearchCentre ( string userId ) : TimeSpan?
userId string
Résultat TimeSpan?

ScheduleSolarCollector() public méthode

public ScheduleSolarCollector ( string userId ) : TimeSpan?
userId string
Résultat TimeSpan?