C# Класс idTech4.Game.idGame

Наследование: idBaseGame
Показать файл Открыть проект

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

Метод Описание
CacheDictionaryMedia ( idDict dict ) : void

This is called after parsing an EntityDef and for each entity spawnArgs before merging the entitydef. It could be done post-merge, but that would avoid the fast pre-cache check associated with each entityDef.

CalculateFieldOfView ( float baseFov, float &fovX, float &fovY ) : void

Calculates the horizontal and vertical field of view based on a horizontal field of view and custom aspect ratio.

Draw ( int clientIndex ) : bool
FindEntityDef ( string name, bool makeDefault ) : idDeclEntity
FindEntityDefDict ( string name, bool makeDefault ) : idDict
FindEntityUsingDef ( idEntity from, string match ) : idEntity

Searches all active entities for the next one using the specified entityDef.

Searches beginning at the entity after from, or the beginning if NULL NULL will be returned if the end of the list is reached.

GetBestGameType ( string map, string gameType ) : string
GetMapLoadingInterface ( string defaultInterface ) : string
GetTimeGroupTime ( int timeGroup ) : int
HandleGuiCommands ( string menuCommand ) : string
HandleMainMenuCommands ( string menuCommand, idUserInterface gui ) : void
Init ( ) : void
InitFromNewMap ( string mapName, idRenderWorld renderWorld, idSoundWorld soundWorld, bool isServer, bool isClient, int randomSeed ) : void
RegisterEntity ( idEntity entity ) : void
RunFrame ( idUserCommand userCommands ) : GameReturn
SelectInitialSpawnPoint ( idPlayer player ) : idEntity

spectators are spawned randomly anywhere. in-game clients are spawned based on distance to active players (randomized on the first half) upon map restart, initial spawns are used (randomized ordered list of spawns flagged "initial"). if there are more players than initial spots, overflow to regular spawning.

SelectTimeGroup ( int timeGroup ) : void
ServerClientBegin ( int clientIndex ) : void
ServerClientConnect ( int clientIndex, string guid ) : void
ServerSendChatMessage ( int to, string name, string text ) : void
SetLocalClient ( int clientIndex ) : void
SetPersistentPlayerInformation ( int clientIndex, idDict playerInfo ) : void
SetServerInfo ( idDict serverInfo ) : void
SetUserInformation ( int clientIndex, idDict userInfo, bool isClient, bool canModify ) : idDict
SpawnEntityDef ( idDict args, bool setDefaults = true ) : idEntity
SpawnPlayer ( int clientIndex ) : void
idGame ( ) : System

Приватные методы

Метод Описание
Clear ( ) : void
CreateGameRules ( ) : void
InhibitEntitySpawn ( idDict args ) : bool
InitAsyncNetwork ( ) : void
InitClientDeclRemap ( int clientIndex ) : void
InitConsoleCommands ( ) : void
InitCvars ( ) : void
LoadMap ( string mapName, int randomSeed ) : void
MapPopulate ( ) : void
RandomizeInitialSpawns ( ) : void
SpawnMapEntities ( ) : void

Parses textual entity definitions out of an entstring and spawns gentities.

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

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

This is called after parsing an EntityDef and for each entity spawnArgs before merging the entitydef. It could be done post-merge, but that would avoid the fast pre-cache check associated with each entityDef.
public CacheDictionaryMedia ( idDict dict ) : void
dict idDict
Результат void

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

Calculates the horizontal and vertical field of view based on a horizontal field of view and custom aspect ratio.
public CalculateFieldOfView ( float baseFov, float &fovX, float &fovY ) : void
baseFov float
fovX float
fovY float
Результат void

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

public Draw ( int clientIndex ) : bool
clientIndex int
Результат bool

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

public FindEntityDef ( string name, bool makeDefault ) : idDeclEntity
name string
makeDefault bool
Результат idTech4.Text.Decl.idDeclEntity

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

public FindEntityDefDict ( string name, bool makeDefault ) : idDict
name string
makeDefault bool
Результат idDict

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

Searches all active entities for the next one using the specified entityDef.
Searches beginning at the entity after from, or the beginning if NULL NULL will be returned if the end of the list is reached.
public FindEntityUsingDef ( idEntity from, string match ) : idEntity
from idEntity
match string
Результат idEntity

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

public GetBestGameType ( string map, string gameType ) : string
map string
gameType string
Результат string

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

public GetMapLoadingInterface ( string defaultInterface ) : string
defaultInterface string
Результат string

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

public GetTimeGroupTime ( int timeGroup ) : int
timeGroup int
Результат int

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

public HandleGuiCommands ( string menuCommand ) : string
menuCommand string
Результат string

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

public HandleMainMenuCommands ( string menuCommand, idUserInterface gui ) : void
menuCommand string
gui idTech4.UI.idUserInterface
Результат void

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

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

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

public InitFromNewMap ( string mapName, idRenderWorld renderWorld, idSoundWorld soundWorld, bool isServer, bool isClient, int randomSeed ) : void
mapName string
renderWorld idTech4.Renderer.idRenderWorld
soundWorld idTech4.Sound.idSoundWorld
isServer bool
isClient bool
randomSeed int
Результат void

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

public RegisterEntity ( idEntity entity ) : void
entity idEntity
Результат void

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

public RunFrame ( idUserCommand userCommands ) : GameReturn
userCommands idTech4.Input.idUserCommand
Результат GameReturn

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

spectators are spawned randomly anywhere. in-game clients are spawned based on distance to active players (randomized on the first half) upon map restart, initial spawns are used (randomized ordered list of spawns flagged "initial"). if there are more players than initial spots, overflow to regular spawning.
public SelectInitialSpawnPoint ( idPlayer player ) : idEntity
player idTech4.Game.Entities.idPlayer
Результат idEntity

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

public SelectTimeGroup ( int timeGroup ) : void
timeGroup int
Результат void

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

public ServerClientBegin ( int clientIndex ) : void
clientIndex int
Результат void

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

public ServerClientConnect ( int clientIndex, string guid ) : void
clientIndex int
guid string
Результат void

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

public ServerSendChatMessage ( int to, string name, string text ) : void
to int
name string
text string
Результат void

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

public SetLocalClient ( int clientIndex ) : void
clientIndex int
Результат void

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

public SetPersistentPlayerInformation ( int clientIndex, idDict playerInfo ) : void
clientIndex int
playerInfo idDict
Результат void

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

public SetServerInfo ( idDict serverInfo ) : void
serverInfo idDict
Результат void

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

public SetUserInformation ( int clientIndex, idDict userInfo, bool isClient, bool canModify ) : idDict
clientIndex int
userInfo idDict
isClient bool
canModify bool
Результат idDict

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

public SpawnEntityDef ( idDict args, bool setDefaults = true ) : idEntity
args idDict
setDefaults bool
Результат idEntity

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

public SpawnPlayer ( int clientIndex ) : void
clientIndex int
Результат void

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

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