C# Class MingStar.SimUniversity.Game.University

Inheritance: IUniversity
显示文件 Open project: MingStar/SimUniversity Class Usage Examples

Public Properties

Property Type Description
PlayerIndex int

Public Methods

Method Description
AddCampus ( IVertex vertex, CampusType type ) : void
HasStudentsFor ( ) : bool
RemoveCampus ( IVertex vertex ) : void
ToString ( ) : string
University ( Game game, System.Color color, int playerIndex ) : System

Private Methods

Method Description
AcquireInitialStudents ( VertexPosition vertexPosition ) : void
AddBackStudents ( DegreeType degreeType ) : void
AddLink ( IEdge edge ) : void
AddProductionChances ( IVertex vertex ) : void

Don't need to check campus type, because each change (none -> tranditional OR tranditional -> super) will increase chances by 1 times only. (NOT 2 times)

AddTradingSite ( IVertex vertex ) : void
CheckLongestLinkForOtherUniversities ( IVertex vertex ) : void
CompareLongestLink ( int count ) : void
ConsumeStudents ( IPlayerMove move ) : void
CutStudents ( ) : DegreeType[]
EnrolStudents ( DegreeType degree, int number ) : void
FullSearchLongestLink ( ) : void
GetDegreeTradingRates ( ) : IEnumerable
GetLongestLink ( IEdge currentEdge, IVertex useVertex, HashSet visitedEdges ) : int
GetLongestLink ( IEdge edge ) : void
HashAllDegrees ( ) : void
RemoveExtraStudents ( DegreeCount roll ) : void
RemoveLink ( IEdge edge ) : void
RemoveProductionChances ( IVertex vertex ) : void

Don't need to check campus type, same reason as AddProductionChances()

RemoveTradingSite ( IVertex vertex ) : void
Reset ( ) : void
ResetStudentCounts ( ) : void
ResumeStudents ( IPlayerMove move ) : void
UntradeInStudents ( DegreeType tradedIn ) : void

Method Details

AddCampus() public method

public AddCampus ( IVertex vertex, CampusType type ) : void
vertex IVertex
type CampusType
return void

HasStudentsFor() public method

public HasStudentsFor ( ) : bool
return bool

RemoveCampus() public method

public RemoveCampus ( IVertex vertex ) : void
vertex IVertex
return void

ToString() public method

public ToString ( ) : string
return string

University() public method

public University ( Game game, System.Color color, int playerIndex ) : System
game Game
color System.Color
playerIndex int
return System

Property Details

PlayerIndex public_oe property

public int PlayerIndex
return int