C# Класс TheGame.Universe

Показать файл Открыть проект Примеры использования класса

Открытые свойства

Свойство Тип Описание
CurrentWorld List
NewBornShouldBeGrey bool
NextWorld List

Открытые методы

Метод Описание
AddAliveCellInNextGeneration ( Cell cell ) : void
AddCellInCurrentGeneration ( int i, int j ) : void
AddDeadCellInNextGeneration ( Cell cell ) : void
AliveCellRemainsAlive ( Cell cell ) : void
CellHasNeighboursOnRightAndLeftSide ( Cell cellToBeVerified, Cell cell ) : bool
CellHasNeighboursOnTop ( Cell cellToBeVerified, Cell unit ) : bool
CellHasNeighboursUnder ( Cell cellToBeVerified, Cell unit ) : bool
CountNumberOfWhiteAndBlackCells ( Cell cell, int &white, int &black ) : void
DeadCellRevives ( Cell cell ) : void
DecideIfCellBecomesDeadOrAlive ( Cell cell ) : void
DecideIfNewBornShouldBeGrey ( int black, int white ) : void
DrawWorld ( ) : void
IncreaseNumberOfAliveNeighbours ( int &numberOfAliveNeighbours ) : void
NumberOfAliveNeighbours ( Cell cellToBeVerified ) : int
Universe ( ) : System
WorldStillHasAliveCells ( ) : bool

Описание методов

AddAliveCellInNextGeneration() публичный Метод

public AddAliveCellInNextGeneration ( Cell cell ) : void
cell Cell
Результат void

AddCellInCurrentGeneration() публичный Метод

public AddCellInCurrentGeneration ( int i, int j ) : void
i int
j int
Результат void

AddDeadCellInNextGeneration() публичный Метод

public AddDeadCellInNextGeneration ( Cell cell ) : void
cell Cell
Результат void

AliveCellRemainsAlive() публичный Метод

public AliveCellRemainsAlive ( Cell cell ) : void
cell Cell
Результат void

CellHasNeighboursOnRightAndLeftSide() публичный Метод

public CellHasNeighboursOnRightAndLeftSide ( Cell cellToBeVerified, Cell cell ) : bool
cellToBeVerified Cell
cell Cell
Результат bool

CellHasNeighboursOnTop() публичный Метод

public CellHasNeighboursOnTop ( Cell cellToBeVerified, Cell unit ) : bool
cellToBeVerified Cell
unit Cell
Результат bool

CellHasNeighboursUnder() публичный Метод

public CellHasNeighboursUnder ( Cell cellToBeVerified, Cell unit ) : bool
cellToBeVerified Cell
unit Cell
Результат bool

CountNumberOfWhiteAndBlackCells() публичный Метод

public CountNumberOfWhiteAndBlackCells ( Cell cell, int &white, int &black ) : void
cell Cell
white int
black int
Результат void

DeadCellRevives() публичный Метод

public DeadCellRevives ( Cell cell ) : void
cell Cell
Результат void

DecideIfCellBecomesDeadOrAlive() публичный Метод

public DecideIfCellBecomesDeadOrAlive ( Cell cell ) : void
cell Cell
Результат void

DecideIfNewBornShouldBeGrey() публичный Метод

public DecideIfNewBornShouldBeGrey ( int black, int white ) : void
black int
white int
Результат void

DrawWorld() публичный Метод

public DrawWorld ( ) : void
Результат void

IncreaseNumberOfAliveNeighbours() публичный Метод

public IncreaseNumberOfAliveNeighbours ( int &numberOfAliveNeighbours ) : void
numberOfAliveNeighbours int
Результат void

NumberOfAliveNeighbours() публичный Метод

public NumberOfAliveNeighbours ( Cell cellToBeVerified ) : int
cellToBeVerified Cell
Результат int

Universe() публичный Метод

public Universe ( ) : System
Результат System

WorldStillHasAliveCells() публичный Метод

public WorldStillHasAliveCells ( ) : bool
Результат bool

Описание свойств

CurrentWorld публичное свойство

public List CurrentWorld
Результат List

NewBornShouldBeGrey публичное свойство

public bool NewBornShouldBeGrey
Результат bool

NextWorld публичное свойство

public List NextWorld
Результат List