Main Page | Namespace List | Class Hierarchy | Alphabetical List | Class List | File List | Namespace Members | Class Members | File Members | Related Pages

GameMap Class Reference

The map. THE central structure of ASC, which holds everything not globally available together. More...

#include <gamemap.h>

List of all members.

Turn Management

These methods control the game advance of a player to the next player

void startGame ()
 prepares a new game for being played
void beginTurn ()
 called when a player starts his turn
void endTurn ()
 called after a player ends his turn
void endRound ()
 called between endTurn() of player 7 and the next turn of player 0
SigC::Signal1< void, Player & > sigPlayerTurnBegins
SigC::Signal1< void, Player & > sigPlayerUserInteractionBegins
SigC::Signal1< void, Player & > sigPlayerUserInteractionEnds
SigC::Signal1< void, Player & > sigPlayerTurnEnds
SigC::Signal1< void, Player & > sigPlayerTurnHasEnded
SigC::Signal0< void > newRound
 called when a new round starts (after switching from player 7 to player 0 )
bool continueplaying
 if a player has won a singleplayer map, but wants to continue playing without any enemies, this will be set to 1
static SigC::Signal1< void,
GameMap & > 
sigMapDeletion

Public Types

typedef map< int, Vehicle * > VehicleLookupCache
typedef PointerList< Event * > Events
enum  State { Normal, Replay, Destruction }

Public Member Functions

int getPlayerCount () const
PlayergetPlayer (PlayerID p)
const PlayergetPlayer (PlayerID p) const
PlayergetCurrentPlayer ()
int getNeutralPlayerNum () const
MapCoordinategetCursor ()
int eventpassed (int saveas, int action, int mapid)
int eventpassed (int id, int mapid)
int getNewNetworkID ()
void allocateFields (int x, int y, TerrainType::Weather *terrain=NULL)
int getPlayerView () const
 the player which is currently viewing the map.
void setPlayerView (int player)
 GameMap (void)
VehiclegetUnit (int x, int y, int nwid)
VehiclegetUnit (int nwid)
ContainerBasegetContainer (int nwid)
int getgameparameter (GameParameter num) const
void setgameparameter (GameParameter num, int value)
void cleartemps (int b=-1, int value=0)
bool isResourceGlobal (int resource)
tfieldgetField (int x, int y)
tfieldgetField (const MapCoordinate &pos)
VisibilityStates getInitialMapVisibility (int player)
int resize (int top, int bottom, int left, int right)
 resizes the map. Positive numbers enlarge the map in that direction
void calculateAllObjects (void)
void read (tnstream &stream)
void write (tnstream &stream)
 ~GameMap ()
int random (int max)
 generated a pseudo-random number with the map-internal seed
void guiHooked ()
bool getGuiHooked ()
int getMemoryFootprint () const
Access to item types
pterraintype getterraintype_byid (int id)
ObjectTypegetobjecttype_byid (int id)
Vehicletypegetvehicletype_byid (int id)
BuildingTypegetbuildingtype_byid (int id)
const Technologygettechnology_byid (int id)
pterraintype getterraintype_bypos (int pos)
ObjectTypegetobjecttype_bypos (int pos)
Vehicletypegetvehicletype_bypos (int pos)
BuildingTypegetbuildingtype_bypos (int pos)
const Technologygettechnology_bypos (int pos)
int getTerrainTypeNum ()
int getObjectTypeNum ()
int getVehicleTypeNum ()
int getBuildingTypeNum ()
int getTechnologyNum ()

Public Attributes

int xsize
 the size of the map
int ysize
 the size of the map
tfieldfield
 the array of fields
ASCString codeWord
 the codeword for accessing a map in a campaign
ASCString maptitle
 the title of the map
GameMap::Campaign campaign
signed char actplayer
 the player who is currently making his moves (may be human or AI)
GameTime time
 the time in the game, mesured in a turns and moves
GameMap::Weather weather
int _resourcemode
 how are Resources handled on this map 0= "ASC mode": complex system with mineral resources etc 1= "BI mode": simpler system like in Battle Isle
Player player [9]
VehicleLookupCache vehicleLookupCache
int eventID
Events events
vector< GameTimeeventTimes
char levelfinished
enum GameMap::State state
GameMap::ResourceTribute tribute
 The tribute can not only be used to demand resources from enemies but also to transfer resources to allies.
MessagePntrContainer unsentmessage
 the list of messages that were written this turn and are waiting to be processed at the end of the turn
bool __loadunsentmessage
MessageContainer messages
 these are the messages themselfs. A MessagePntrContainer only stores pointers to message body which are archived here
bool __loadmessages
int messageid
 each message has an identification number (which is incremented with each message) for referencing it in files. The id of the last message is stored here
bool ___loadJournal
 temporary variables for loading the map
bool ___loadNewJournal
 temporary variables for loading the map
bool ___loadtitle
 temporary variables for loading the map
bool ___loadLegacyNetwork
 temporary variables for loading the map
ASCString gameJournal
ASCString newJournal
Password supervisorpasswordcrc
ReplayInforeplayinfo
bool __loadreplayinfo
 a helper variable to store some information during the loading process. No usage outside.
GameTime lastjournalchange
Resources bi_resource [8]
 in BI resource mode ( see _resourcemode , isResourceGlobal ) , this is where the globally available resources are stored. Note that not all resources are globally available.
GameMap::PreferredFilenames preferredFileNames
int graphicset
 the ID of the graphic set
int gameparameter_num
int * game_parameter
int mineralResourcesDisplayed
GameMap::ArchivalInformation archivalInformation
GameMap::UnitProduction unitProduction
 specifies which vehicle types can be constructed by construction units
OverviewMapHolder overviewMapHolder
bool loadOldEvents
 just a helper variable for loading the map; no function outside;
GameTransferMechanismnetwork

Classes

class  ArchivalInformation
struct  Campaign
struct  PreferredFilenames
class  ReplayInfo
class  ResourceTribute
 The tribute can not only be used to demand resources from enemies but also to transfer resources to allies. More...
class  UnitProduction
 specifies which vehicle types can be constructed by construction units More...
struct  Weather


Detailed Description

The map. THE central structure of ASC, which holds everything not globally available together.

Definition at line 166 of file gamemap.h.


Member Typedef Documentation

typedef PointerList<Event*> GameMap::Events
 

Definition at line 249 of file gamemap.h.

typedef map<int, Vehicle*> GameMap::VehicleLookupCache
 

Definition at line 244 of file gamemap.h.


Member Enumeration Documentation

enum GameMap::State
 

Enumeration values:
Normal 
Replay  map is currently used to run a replay. Some ingame events are deactivated
Destruction  only to be used by units and buildings. To speed up map destruction, the view won't be recalculated. No signals will be send when units & buildings are destroyed, either

Definition at line 263 of file gamemap.h.


Constructor & Destructor Documentation

GameMap::GameMap void   ) 
 

Definition at line 220 of file gamemap.cpp.

References _resourcemode, GameTime::abstime, actplayer, cgp_objectsDestroyedByTerrain, Research::chainToMap(), Player::computer, continueplaying, eventID, field, game_parameter, gameparameter_num, graphicset, Player::human, lastjournalchange, levelfinished, messageid, mineralResourcesDisplayed, Normal, player, replayinfo, Player::research, setgameparameter(), Player::setParentMap(), Player::stat, state, time, xsize, and ysize.

GameMap::~GameMap  ) 
 

Definition at line 1327 of file gamemap.cpp.

References actmap, Player::ai, tfield::building, cbbuildingentry, Destruction, field, game_parameter, getTerrainBitType(), network, player, replayinfo, sigMapDeletion, state, tfield::vehicle, xsize, and ysize.


Member Function Documentation

void GameMap::allocateFields int  x,
int  y,
TerrainType::Weather terrain = NULL
 

Definition at line 898 of file gamemap.cpp.

References OverviewMapHolder::connect(), field, overviewMapHolder, tfield::setMap(), tfield::setparams(), tfield::typ, xsize, and ysize.

Referenced by buildemptymap(), generatemap(), and tspfldloaders::readfields().

void GameMap::beginTurn  ) 
 

called when a player starts his turn

Definition at line 1129 of file gamemap.cpp.

References actplayer, exist(), Player::off, player, replayinfo, and sigPlayerTurnBegins.

Referenced by continuenetworkgame(), and skipTurn().

void GameMap::calculateAllObjects void   ) 
 

Definition at line 914 of file gamemap.cpp.

References calculateallobjects().

Referenced by Building::chainbuildingtofield().

void GameMap::cleartemps int  b = -1,
int  value = 0
 

Definition at line 876 of file gamemap.cpp.

References tfield::a, field, tfield::temp3, tfield::temp4, xsize, and ysize.

Referenced by destructbuildinglevel2(), GuiFunctions::InternalAmmoTransferDialog::execute(), GuiFunctions::BuildingConstruction::execute(), GuiFunctions::VehicleBuildingGui::execute(), GuiFunctions::ObjectBuildingGui::execute(), GuiFunctions::RefuelUnitDialog::execute(), GuiFunctions::RefuelUnit::execute(), GuiFunctions::RepairUnit::execute(), GuiFunctions::JumpDriveIcon::execute(), GuiFunctions::DestructBuilding::execute(), GuiFunctions::Descend::execute(), GuiFunctions::Ascend::execute(), GuiFunctions::Movement::execute(), GuiFunctions::Cancel::execute(), GuiFunctions::AttackGui::execute(), CargoGuiFunctions::Movement::execute(), AStar3D::findAllAccessibleFields(), AStar::findAllAccessibleFields(), AStar::findPath(), importbattleislemap(), tsearchdestructbuildingfields::initdestructbuilding(), insertbattleislemap(), putMine(), GuiFunctions::BuildingConstruction::setBuilding(), SelectFromMap::showFieldMarking(), MapNetwork::start(), testDebugFunction(), AStar::~AStar(), AStar3D::~AStar3D(), and SelectFromMap::~SelectFromMap().

void GameMap::endRound  ) 
 

called between endTurn() of player 7 and the next turn of player 0

Definition at line 1215 of file gamemap.cpp.

References actplayer, Player::buildingList, cgp_objectGrowthMultiplier, doresearch(), exist(), getField(), getgameparameter(), getPlayer(), getPlayerCount(), Player::off, player, tfield::resetView(), GameTime::set(), time, GameTime::turn(), Player::vehicleList, xsize, and ysize.

void GameMap::endTurn  ) 
 

called after a player ends his turn

Definition at line 1148 of file gamemap.cpp.

References actplayer, Player::ASCversion, Player::buildingList, UnitHooveringLogic::calcFuelUsage(), checkunitsforremoval(), chhochfliegend, chtieffliegend, Player::PlayTime::date, Resources::Fuel, getfield(), getmaxwindspeedforunit(), getNumericVersion(), getUnitReference(), Vehicle::height, maxwindspeed, player, Player::playTime, replayinfo, sigPlayerTurnEnds, sigPlayerTurnHasEnded, time, GameTime::turn(), Player::PlayTime::turn, Player::vehicleList, weather, GameMap::Weather::windSpeed, Vehicle::xpos, and Vehicle::ypos.

Referenced by next_turn(), and skipTurn().

int GameMap::eventpassed int  id,
int  mapid
 

Definition at line 1043 of file gamemap.cpp.

int GameMap::eventpassed int  saveas,
int  action,
int  mapid
 

Definition at line 1036 of file gamemap.cpp.

BuildingType * GameMap::getbuildingtype_byid int  id  ) 
 

Definition at line 1608 of file gamemap.cpp.

References buildingTypeRepository.

Referenced by execaction_pg(), and Building::newFromStream().

BuildingType * GameMap::getbuildingtype_bypos int  pos  ) 
 

Definition at line 1634 of file gamemap.cpp.

References buildingTypeRepository.

int GameMap::getBuildingTypeNum  ) 
 

Definition at line 1659 of file gamemap.cpp.

References buildingTypeRepository.

ContainerBase * GameMap::getContainer int  nwid  ) 
 

Definition at line 1112 of file gamemap.cpp.

References tfield::building, getfield(), and getUnit().

Referenced by compareMapResources(), trunreplay::execnextreplaymove(), and getCursor().

Player& GameMap::getCurrentPlayer  )  [inline]
 

Definition at line 235 of file gamemap.h.

References actplayer, and player.

Referenced by checkType(), ASC_MainScreenWidget::eventKeyDown(), execuseraction2(), getInstances(), tshownewtanks::init(), loadGame(), showCargoSummary(), VehicleCounterFactory::spawnNextItem(), AvailableProductionItemFactory::spawnNextItem(), vehicleOwned(), and viewMiningPower().

MapCoordinate & GameMap::getCursor  ) 
 

Definition at line 853 of file gamemap.cpp.

References actplayer, Player::cursorPos, getContainer(), getField(), player, xsize, and ysize.

Referenced by GuiIconHandler::checkForKey(), NewGuiHost::evalCursor(), ASC_MainScreenWidget::eventKeyDown(), execaction(), execuseraction(), execuseraction2(), getactfield(), getSelectedField(), loadGame(), ReinforcementSelector::mark(), SelectFromMap::mark(), DashboardPanel::painter(), BuildingItem::place(), placeCurrentItem(), MapDisplayPG::Cursor::pos(), removeCurrentItem(), trunreplay::run(), tputresourcesdlg::run(), showbdtbits(), MapSwitcher::toggle(), unitInfoDialog(), Maped_MainScreenWidget::updateStatusBar(), and viewUnitSetinfo().

tfield * GameMap::getField const MapCoordinate pos  ) 
 

Definition at line 927 of file gamemap.cpp.

References getField().

tfield * GameMap::getField int  x,
int  y
 

Definition at line 919 of file gamemap.cpp.

References field, xsize, and ysize.

Referenced by SelectUnitFromMap::accept(), SelectBuildingFromMap::accept(), SelectFromMap::accept(), BuildingSeen::arm(), BuildingLost::arm(), BuildingConquered::arm(), ContextMenu::DeleteAllObjects::available(), ContextMenu::DeleteTopObject::available(), ContextMenu::ChangeMineStrength::available(), ContextMenu::DeleteMine::available(), ContextMenu::ContainerProduction::available(), ContextMenu::DeleteBuilding::available(), ContextMenu::DeleteVehicle::available(), ContextMenu::ContainerCargo::available(), ContextMenu::ContainerProperties::available(), GuiFunctions::SelfDestructIcon::available(), GuiFunctions::ConstructBuilding::available(), GuiFunctions::BuildingConstruction::available(), GuiFunctions::BuildVehicle::available(), GuiFunctions::BuildObject::available(), GuiFunctions::RemoveMine::available(), GuiFunctions::PutAntiSubMine::available(), GuiFunctions::PutAntiShipMine::available(), GuiFunctions::PutGroundMine::available(), GuiFunctions::PutMine::available(), GuiFunctions::RefuelUnitDialog::available(), GuiFunctions::RefuelUnit::available(), GuiFunctions::RepairUnit::available(), GuiFunctions::JumpDriveIcon::available(), GuiFunctions::DisableReactionfire::available(), GuiFunctions::EnableReactionfire::available(), GuiFunctions::OpenContainer::available(), GuiFunctions::DestructBuilding::available(), GuiFunctions::UnitInfo::available(), GuiFunctions::PowerOff::available(), GuiFunctions::PowerOn::available(), GuiFunctions::Attack::available(), GuiFunctions::Descend::available(), GuiFunctions::Ascend::available(), GuiFunctions::Movement::available(), calculateobject(), Vehicle::canMove(), GuiIconHandler::checkForKey(), Vehicle::constructvehicle(), MapDisplayPG::displayMovementStep(), ReplayMapDisplay::displayMovingUnit(), PG_MapDisplay::displayMovingUnit(), Vehicle::endOwnTurn(), endRound(), DashboardPanel::eval(), NewGuiHost::evalCursor(), evaluateviewcalculation(), ASC_MainScreenWidget::eventKeyDown(), execaction_pg(), trunreplay::execnextreplaymove(), execuseraction(), execuseraction2(), ChangeVehicleHeight::execute(), VehicleMovement::execute(), GuiFunctions::SelfDestructIcon::execute(), GuiFunctions::ConstructBuilding::execute(), GuiFunctions::BuildingConstruction::execute(), GuiFunctions::BuildVehicle::execute(), GuiFunctions::BuildObject::execute(), GuiFunctions::ObjectBuildingGui::execute(), GuiFunctions::RefuelUnitDialog::execute(), GuiFunctions::RefuelUnit::execute(), GuiFunctions::RepairUnit::execute(), GuiFunctions::JumpDriveIcon::execute(), GuiFunctions::DisableReactionfire::execute(), GuiFunctions::EnableReactionfire::execute(), GuiFunctions::OpenContainer::execute(), GuiFunctions::PowerOff::execute(), GuiFunctions::PowerOn::execute(), GuiFunctions::Attack::execute(), GuiFunctions::Descend::execute(), GuiFunctions::Ascend::execute(), GuiFunctions::Movement::execute(), AddResources::execute(), AddProductionCapability::execute(), ChangeBuildingOwner::execute(), ChangeBuildingDamage::execute(), ResourceNet::fieldavail(), RemoveAllObjects::fieldOperator(), AddObject::fieldOperator(), MapChange::fieldOperator(), WeatherChange::fieldOperator(), AnyUnitEntersPolygon::fieldOperator(), SpecificUnitEntersPolygon::fieldOperator(), CopyMap::fieldOperator(), JumpDrive::fieldReachable(), tsearchreactionfireingunits::finalCheck(), AStar3D::findAllAccessibleFields(), AStar::findAllAccessibleFields(), AStar3D::findPath(), AStar::findPath(), Vehicle::freeWeight(), getactfield(), getCursor(), AStar::getDistance(), ForestCalculation::Smoothing::getfield(), getField(), Building::getField(), AStar3D::getMoveCost(), BaseVehicleMovement::PathFinder::getMovementFields(), GuiFunctions::RepairUnit::getName(), GuiFunctions::AttackGui::getName(), BuildingPositionTrigger::getName(), Vehicle::getPosition3D(), getSelectedField(), BuildingSeen::getState(), BuildingDestroyed::getState(), BuildingConquered::getState(), ContextMenu::ContainerCargo::getText(), ContextMenu::ContainerProperties::getText(), getUnit(), getVisibilityStatistics(), tcomputebuildingview::init(), tcomputevehicleview::init(), NewGuiHost::mapIconProcessing(), ReinforcementSelector::mark(), MirrorMap::mirrorX(), MirrorMap::mirrorY(), UnitInfoPanel::onClick(), UnitMovementRangeLayer::operateField(), UnitWeaponRangeLayer::operateField(), DashboardPanel::painter(), ShowPolygonUsingTemps::paintPolygon(), MapRenderer::paintTerrain(), CopyMap::paste(), MineItem::place(), TerrainItem::place(), ObjectItem::place(), BuildingItem::place(), VehicleItem::place(), ClipBoardBase::place(), ReplayMapDisplay::playPositionalSound(), putbuilding(), putbuilding2(), putMine(), tdrawgettempline::putpix8(), ObjectItem::remove(), WholeMapRenderer::renderVisibility(), resize(), resourceComparison(), GuiFunctions::BuildingConstruction::search(), GuiFunctions::VehicleBuildingGui::search(), GuiFunctions::ObjectBuildingGui::search(), MapNetwork::searchAllVehiclesNextToBuildings(), MapNetwork::searchbuilding(), MapNetwork::searchfield(), MapNetwork::searchvehicle(), selectunit(), setweatherall(), showbdtbits(), SelectFromMap::showFieldMarking(), Vehicle::spawnMoveObjects(), MapNetwork::start(), testDebugFunction(), tcomputeview::testfield(), tsearchforminablefields::testfield(), VehicleService::FieldSearch::testfield(), WeaponRange::testfield(), FindUnitPlacementPos::testfield(), tputresources::testfield(), tputmine::testfield(), tsearchdestructbuildingfields::testfield(), MiningStation::testfield(), GetMiningInfo::testfield(), SearchReconquerBuilding::testfield(), transformMap(), unitInfoDialog(), Vehicle::vehicleconstructable(), VehicleCounterFactory::VehicleCounterFactory(), viewUnitSetinfo(), trunreplay::wait(), and Vehicle::~Vehicle().

int GameMap::getgameparameter GameParameter  num  )  const
 

Definition at line 972 of file gamemap.cpp.

References GameParameterSettings::defaultValue, game_parameter, gameparameter_num, gameparameternum, and gameParameterSettings.

Referenced by AdminGameWindow::AdminGameWindow(), GuiFunctions::ConstructBuilding::available(), Vehicle::buildingconstructable(), tfight::calc(), Vehicle::canMove(), Event::check(), tsearchreactionfireingunits::checkfield(), AttackFormula::defense_experience(), ReplayMapDisplay::displayMovingUnit(), endRound(), evaluateviewcalculation(), trunreplay::execnextreplaymove(), execuseraction(), GuiFunctions::BuildingConstruction::execute(), Event::execute(), AStar3D::findPath(), GameParameterEditorWidget::GameParameterEditorWidget(), Building::getArmor(), getInitialMapVisibility(), isResourceGlobal(), Mine::Mine(), VehicleItem::place(), ClipBoardBase::place(), ContainerControls::produceUnit(), ContainerControls::produceUnitHypothetically(), tfield::putmine(), tspfldloaders::readfields(), GuiFunctions::VehicleBuildingGui::search(), tfield::setparams(), startGame(), AttackFormula::strength_experience(), tcomputeview::testfield(), tputmine::testfield(), ContainerControls::trainUnit(), ContainerControls::unitTrainingAvailable(), Vehicle::vehicleconstructable(), write(), and writeGameParametersToString().

bool GameMap::getGuiHooked  )  [inline]
 

Definition at line 483 of file gamemap.h.

Referenced by hookGuiToMap().

VisibilityStates GameMap::getInitialMapVisibility int  player  ) 
 

Definition at line 1748 of file gamemap.cpp.

References cgp_initialMapVisibility, getgameparameter(), and visible_ago.

Referenced by fieldVisibility(), and fieldvisiblenow().

int GameMap::getMemoryFootprint  )  const
 

Definition at line 1769 of file gamemap.cpp.

References tmemorystreambuf::getMemoryFootprint(), GameMap::ReplayInfo::guidata, GameMap::ReplayInfo::map, and replayinfo.

int GameMap::getNeutralPlayerNum  )  const [inline]
 

Definition at line 240 of file gamemap.h.

Referenced by GuiFunctions::OpenContainer::available().

int GameMap::getNewNetworkID  ) 
 

Definition at line 1049 of file gamemap.cpp.

Referenced by checkForUniqueUnitIDs(), Vehicle::newFromStream(), and Vehicle::Vehicle().

ObjectType * GameMap::getobjecttype_byid int  id  ) 
 

Definition at line 1598 of file gamemap.cpp.

References objectTypeRepository.

Referenced by calculateobject(), execaction_pg(), GuiFunctions::ObjectBuildingGui::search(), and Building::unchainbuildingfromfield().

ObjectType * GameMap::getobjecttype_bypos int  pos  ) 
 

Definition at line 1624 of file gamemap.cpp.

References objectTypeRepository.

int GameMap::getObjectTypeNum  ) 
 

Definition at line 1649 of file gamemap.cpp.

References objectTypeRepository.

const Player& GameMap::getPlayer PlayerID  p  )  const [inline]
 

Definition at line 229 of file gamemap.h.

References PlayerID::getID(), and player.

Player& GameMap::getPlayer PlayerID  p  )  [inline]
 

Definition at line 224 of file gamemap.h.

References PlayerID::getID(), and player.

Referenced by attackpossible(), checkForUniqueUnitIDs(), BuildingItem::display(), VehicleItem::display(), editPlayerData(), endRound(), trunreplay::execnextreplaymove(), ChangePlayerState::execute(), ChangeDiplomaticStatus::execute(), tsearchreactionfireingunits::finalCheck(), Player::getHumanPlayerNum(), AllEnemyBuildingsDestroyed::getState(), MessageLineWidget::MessageLineWidget(), BaseVehicleMovement::moveunitxy(), ResourceGraphLayer::paintSingleField(), VisibilityLayer::paintSingleField(), PlayerColorPanel::PlayerColorPanel(), WholeMapRenderer::renderVisibility(), tsearchforminablefields::run(), FileTransfer::send(), DisplayImmediateMessage::setup(), showAllUnitPositions(), transformMap(), ContainerBase::vehicleLoadable(), and viewUnitSetinfo().

int GameMap::getPlayerCount  )  const [inline]
 

Definition at line 222 of file gamemap.h.

Referenced by endRound(), findNextPlayer(), AllianceSetupWidget::linearize(), and transformMap().

int GameMap::getPlayerView  )  const
 

the player which is currently viewing the map.

During replays, for example, this will be different from the player that moves units -1 means: everything is visible -2 means: nothing is visible

Definition at line 932 of file gamemap.cpp.

Referenced by tsearchreactionfireingunits::attack(), ReplayMapDisplay::displayActionCursor(), ReplayMapDisplay::displayMovingUnit(), PG_MapDisplay::displayMovingUnit(), ReplayMapDisplay::displayPosition(), MapDisplayPG::displayUnitMovement(), DashboardPanel::eval(), trunreplay::execnextreplaymove(), VehicleAttack::execute(), BaseVehicleMovement::moveunitxy(), DashboardPanel::painter(), VisibilityLayer::paintSingleField(), ReplayMapDisplay::playPositionalSound(), WholeMapRenderer::render(), WholeMapRenderer::renderVisibility(), tcomputeview::tcomputeview(), MapDisplayPG::updateMap(), and trunreplay::wait().

const Technology * GameMap::gettechnology_byid int  id  ) 
 

Definition at line 1613 of file gamemap.cpp.

References technologyRepository.

const Technology * GameMap::gettechnology_bypos int  pos  ) 
 

Definition at line 1639 of file gamemap.cpp.

References technologyRepository.

int GameMap::getTechnologyNum  ) 
 

Definition at line 1664 of file gamemap.cpp.

References technologyRepository.

pterraintype GameMap::getterraintype_byid int  id  ) 
 

Definition at line 1593 of file gamemap.cpp.

References terrainTypeRepository.

Referenced by resize().

pterraintype GameMap::getterraintype_bypos int  pos  ) 
 

Definition at line 1619 of file gamemap.cpp.

References terrainTypeRepository.

int GameMap::getTerrainTypeNum  ) 
 

Definition at line 1644 of file gamemap.cpp.

References terrainTypeRepository.

Vehicle * GameMap::getUnit int  nwid  ) 
 

Definition at line 1077 of file gamemap.cpp.

References displaymessage(), player, Player::vehicleList, and vehicleLookupCache.

Vehicle * GameMap::getUnit int  x,
int  y,
int  nwid
 

Definition at line 1096 of file gamemap.cpp.

References tfield::getContainer(), getField(), Vehicle::networkid, and tfield::vehicle.

Referenced by SpecificUnitEntersPolygon::arm(), UnitDestroyed::arm(), UnitConquered::arm(), UnitLost::arm(), compareMapResources(), trunreplay::execnextreplaymove(), BaseVehicleMovement::execute(), SpecificUnitEntersPolygon::fieldOperator(), tsearchreactionfireingunits::finalCheck(), getContainer(), SpecificUnitEntersPolygon::getDetailledName(), UnitTrigger::getName(), UnitDestroyed::getState(), UnitConquered::getState(), UnitLost::getState(), JumpDrive::jump(), logtoreplayinfo(), BaseVehicleMovement::moveunitxy(), and selectunit().

Vehicletype * GameMap::getvehicletype_byid int  id  ) 
 

Definition at line 1603 of file gamemap.cpp.

References vehicleTypeRepository.

Referenced by execaction_pg(), trunreplay::execnextreplaymove(), AddProductionCapability::execute(), Vehicle::newFromStream(), tchoosetechnology::run(), and GuiFunctions::VehicleBuildingGui::search().

Vehicletype * GameMap::getvehicletype_bypos int  pos  ) 
 

Definition at line 1629 of file gamemap.cpp.

References vehicleTypeRepository.

Referenced by ContainerBase::ContainerBase(), and ContainerControls::productionLinesBuyable().

int GameMap::getVehicleTypeNum  ) 
 

Definition at line 1654 of file gamemap.cpp.

References vehicleTypeRepository.

void GameMap::guiHooked  ) 
 

Definition at line 283 of file gamemap.cpp.

References OverviewMapHolder::connect(), and overviewMapHolder.

Referenced by hookGuiToMap().

bool GameMap::isResourceGlobal int  resource  ) 
 

Definition at line 949 of file gamemap.cpp.

References _resourcemode, cgp_globalfuel, and getgameparameter().

Referenced by Building::convert(), Building::execnetcontrol(), ResourceChangeNet::getresource(), StaticResourceNet::getresource(), resourceAnalysis(), transfer_all_outstanding_tribute(), and ResourceInfoWindow::update().

int GameMap::random int  max  ) 
 

generated a pseudo-random number with the map-internal seed

Definition at line 1276 of file