C# 클래스 Beyond_Beyaan.Galaxy

파일 보기 프로젝트 열기: Beyonders/Beyond-Beyaan 1 사용 예제들

공개 프로퍼티들

프로퍼티 타입 설명
OnGenerateComplete System.Action

공개 메소드들

메소드 설명
GenerateGalaxy ( GALAXYTYPE galaxyType, int minPlanets, int maxPlanets, Random r, string &reason ) : bool

Set up the galaxy

GenerateTravelNode ( StarSystem origin, StarSystem destination ) : TravelNode
GenerateTravelNode ( float xPos, float yPos, StarSystem destination ) : TravelNode
GetAllStars ( ) : List
GetPath ( float currentX, float currentY, StarSystem currentDestination, StarSystem newDestination, bool hasExtended, Empire whichEmpire ) : List

Pathfinding function

GetStarAtPoint ( Point point ) : StarSystem
GetStarWithID ( int id ) : StarSystem
GetStarsInArea ( float left, float top, float width, float height ) : List

Get all stars in the area for drawing purposes

Load ( System.Xml.Linq.XElement root, GameMain gameMain ) : bool
Reconcilate ( EmpireManager empireManager ) : void
Save ( XmlWriter writer ) : void
SetHomeworld ( Empire empire, Planet &homePlanet ) : StarSystem
Update ( float frameDeltaTime, Random r ) : void

비공개 메소드들

메소드 설명
FillGalaxyWithStars ( int numberOfStars, int minPlanets, int maxPlanets, bool grid, Random r ) : void
GenerateGalaxyCompleted ( object sender, RunWorkerCompletedEventArgs e ) : void
GenerateGalaxyThread ( object sender, DoWorkEventArgs e ) : void
GenerateRandom ( GALAXYTYPE type ) : bool[][]
IsDestinationValid ( StarSystem destination, bool hasExtended, Empire whichEmpire ) : bool

메소드 상세

GenerateGalaxy() 공개 메소드

Set up the galaxy
public GenerateGalaxy ( GALAXYTYPE galaxyType, int minPlanets, int maxPlanets, Random r, string &reason ) : bool
galaxyType GALAXYTYPE
minPlanets int
maxPlanets int
r System.Random
reason string
리턴 bool

GenerateTravelNode() 공개 메소드

public GenerateTravelNode ( StarSystem origin, StarSystem destination ) : TravelNode
origin StarSystem
destination StarSystem
리턴 TravelNode

GenerateTravelNode() 공개 메소드

public GenerateTravelNode ( float xPos, float yPos, StarSystem destination ) : TravelNode
xPos float
yPos float
destination StarSystem
리턴 TravelNode

GetAllStars() 공개 메소드

public GetAllStars ( ) : List
리턴 List

GetPath() 공개 메소드

Pathfinding function
public GetPath ( float currentX, float currentY, StarSystem currentDestination, StarSystem newDestination, bool hasExtended, Empire whichEmpire ) : List
currentX float Fleet's Galaxy X
currentY float Fleet's Galaxy Y
currentDestination StarSystem Fleet's current destination for when empire don't have hyperspace communications
newDestination StarSystem New destination
hasExtended bool
whichEmpire Empire For fuel range and other info
리턴 List

GetStarAtPoint() 공개 메소드

public GetStarAtPoint ( Point point ) : StarSystem
point Point
리턴 StarSystem

GetStarWithID() 공개 메소드

public GetStarWithID ( int id ) : StarSystem
id int
리턴 StarSystem

GetStarsInArea() 공개 메소드

Get all stars in the area for drawing purposes
public GetStarsInArea ( float left, float top, float width, float height ) : List
left float
top float
width float
height float
리턴 List

Load() 공개 메소드

public Load ( System.Xml.Linq.XElement root, GameMain gameMain ) : bool
root System.Xml.Linq.XElement
gameMain GameMain
리턴 bool

Reconcilate() 공개 메소드

public Reconcilate ( EmpireManager empireManager ) : void
empireManager EmpireManager
리턴 void

Save() 공개 메소드

public Save ( XmlWriter writer ) : void
writer System.Xml.XmlWriter
리턴 void

SetHomeworld() 공개 메소드

public SetHomeworld ( Empire empire, Planet &homePlanet ) : StarSystem
empire Empire
homePlanet Planet
리턴 StarSystem

Update() 공개 메소드

public Update ( float frameDeltaTime, Random r ) : void
frameDeltaTime float
r System.Random
리턴 void

프로퍼티 상세

OnGenerateComplete 공개적으로 프로퍼티

public Action,System OnGenerateComplete
리턴 System.Action