C# Class DivineRightGame.LocalMap

Afficher le fichier Open project: Haedrian/Divine-Right

Méthodes publiques

Свойство Type Description
localGameMap DRObjects.MapBlock[

Méthodes publiques

Méthode Description
AddToLocalMap ( MapBlock block ) : void

Add a block to a local map

DeserialiseLocalMap ( System.Guid uniqueGuid ) : LocalMap

Loads a local map from the file it was saved in. Will not load it into the gamestate thoughs

GeneratePathfindingMap ( ) : void

Generates the map required for pathfinding, and assign it to the Interface

GetBlockAtCoordinate ( MapCoordinate coordinate ) : MapBlock

Gets a block which is at a particular coordinate. If there is no block marked on the map, it will return an Air block.

GetBlocksAroundPoint ( MapCoordinate centre, int radius ) : DRObjects.MapBlock[]
HasDirectPath ( MapCoordinate source, MapCoordinate target ) : bool

Returns true if there is a direct path between the source and the target

LocalMap ( int sizeX, int sizeY, int sizeZ, int groundLevel ) : System

Creates a new Local map with x,y,z as size. The ground level determines the entry level for the map (generally 0)

MapGenerated ( System.Guid uniqueGuid ) : bool

Determines whether a map has been generated already or not

MinuteChanged ( object sender, EventArgs e ) : void

Performs the summoning of creatures for Dungeons, as well as handles events

SerialiseLocalMap ( ) : void

Saves the Local Map into the folder as per its guid

Tick ( ) : ActionFeedback[]

Perform a tick. Checks all actors and allow them an action

Method Details

AddToLocalMap() public méthode

Add a block to a local map
public AddToLocalMap ( MapBlock block ) : void
block DRObjects.MapBlock
Résultat void

DeserialiseLocalMap() public static méthode

Loads a local map from the file it was saved in. Will not load it into the gamestate thoughs
public static DeserialiseLocalMap ( System.Guid uniqueGuid ) : LocalMap
uniqueGuid System.Guid
Résultat LocalMap

GeneratePathfindingMap() public méthode

Generates the map required for pathfinding, and assign it to the Interface
public GeneratePathfindingMap ( ) : void
Résultat void

GetBlockAtCoordinate() public méthode

Gets a block which is at a particular coordinate. If there is no block marked on the map, it will return an Air block.
public GetBlockAtCoordinate ( MapCoordinate coordinate ) : MapBlock
coordinate MapCoordinate
Résultat DRObjects.MapBlock

GetBlocksAroundPoint() public méthode

public GetBlocksAroundPoint ( MapCoordinate centre, int radius ) : DRObjects.MapBlock[]
centre MapCoordinate
radius int
Résultat DRObjects.MapBlock[]

HasDirectPath() public méthode

Returns true if there is a direct path between the source and the target
public HasDirectPath ( MapCoordinate source, MapCoordinate target ) : bool
source MapCoordinate
target MapCoordinate
Résultat bool

LocalMap() public méthode

Creates a new Local map with x,y,z as size. The ground level determines the entry level for the map (generally 0)
public LocalMap ( int sizeX, int sizeY, int sizeZ, int groundLevel ) : System
sizeX int
sizeY int
sizeZ int
groundLevel int
Résultat System

MapGenerated() public static méthode

Determines whether a map has been generated already or not
public static MapGenerated ( System.Guid uniqueGuid ) : bool
uniqueGuid System.Guid
Résultat bool

MinuteChanged() public méthode

Performs the summoning of creatures for Dungeons, as well as handles events
public MinuteChanged ( object sender, EventArgs e ) : void
sender object
e System.EventArgs
Résultat void

SerialiseLocalMap() public méthode

Saves the Local Map into the folder as per its guid
public SerialiseLocalMap ( ) : void
Résultat void

Tick() public méthode

Perform a tick. Checks all actors and allow them an action
public Tick ( ) : ActionFeedback[]
Résultat ActionFeedback[]

Property Details

localGameMap public_oe property

public MapBlock[,DRObjects localGameMap
Résultat DRObjects.MapBlock[