Advanced Strategic Command
Public Member Functions | Public Attributes | List of all members
TerrainType::Weather Class Reference

#include <terraintype.h>

Inheritance diagram for TerrainType::Weather:
Inheritance graph
[legend]

Public Member Functions

void paint (Surface &s, SPoint pos)
 displays the image on the screen coordinates x1/y1 More...
 
const OverviewMapImagegetQuickView ()
 
 Weather (TerrainType *base)
 
 ~Weather ()
 
void runTextIO (PropertyContainer &pc)
 registers the properties of this item for loading/writing into asctxt files More...
 
void read (tnstream &stream)
 read the binary representation of this item from the given stream More...
 
void read (tnstream &stream, int version)
 
void write (tnstream &stream) const
 write the binary representation of this item to the given stream More...
 
int getMemoryFootprint () const
 
- Public Member Functions inherited from LoadableItemType
virtual ~LoadableItemType ()
 

Public Attributes

Surface image
 the image of the field More...
 
int defensebonus
 the defense bonus for the unit standing on this field. More...
 
int attackbonus
 the attack bonus for the unit standing on this field. More...
 
int basicjamming
 the view obstraction of the field More...
 
TerrainType::MoveMalus move_malus
 the movement cost for the various units to move across this field More...
 
int bi_pict
 the image index from the graphic set. -1 if graphics is not from graphic set. More...
 
TerrainBits art
 the properties defining which unit can move onto this field and which not More...
 
TerrainTypeterraintype
 pointer to the outer structure More...
 
- Public Attributes inherited from LoadableItemType
ASCString filename
 The name of the file from which the item was loaded. More...
 
ASCString location
 The filename and location on disk (including containerfiles) of the object. More...
 
ASCString archive
 

Detailed Description

Definition at line 97 of file terraintype.h.

Constructor & Destructor Documentation

TerrainType::Weather::Weather ( TerrainType base)
inline

Definition at line 132 of file terraintype.h.

TerrainType::Weather::~Weather ( )

Definition at line 165 of file terraintype.cpp.

Member Function Documentation

int TerrainType::Weather::getMemoryFootprint ( ) const

Definition at line 372 of file terraintype.cpp.

Referenced by TerrainType::getMemoryFootprint().

const OverviewMapImage * TerrainType::Weather::getQuickView ( )

Definition at line 153 of file terraintype.cpp.

Referenced by OverviewMapHolder::updateField().

void TerrainType::Weather::paint ( Surface s,
SPoint  pos 
)

displays the image on the screen coordinates x1/y1

Definition at line 137 of file terraintype.cpp.

References megaBlitter(), and nullParam.

Referenced by TerrainItem::display(), and MapRenderer::paintSingleField().

void TerrainType::Weather::read ( tnstream stream)
virtual

read the binary representation of this item from the given stream

Implements LoadableItemType.

Definition at line 217 of file terraintype.cpp.

References TerrainType::read(), and terrain_version.

Referenced by TerrainType::read().

void TerrainType::Weather::read ( tnstream stream,
int  version 
)
void TerrainType::Weather::runTextIO ( PropertyContainer pc)
virtual
void TerrainType::Weather::write ( tnstream stream) const
virtual

write the binary representation of this item to the given stream

Implements LoadableItemType.

Definition at line 279 of file terraintype.cpp.

References tnstream::writeInt(), tnstream::writeString(), and tnstream::writeUint8().

Referenced by TerrainType::write().

Member Data Documentation

TerrainBits TerrainType::Weather::art

the properties defining which unit can move onto this field and which not

Definition at line 125 of file terraintype.h.

Referenced by MapField::setparams(), and terrainComp().

int TerrainType::Weather::attackbonus

the attack bonus for the unit standing on this field.

See Also
AttackFormula::strength_attackbonus(int)

Definition at line 109 of file terraintype.h.

Referenced by MapField::getattackbonus().

int TerrainType::Weather::basicjamming

the view obstraction of the field

Definition at line 112 of file terraintype.h.

Referenced by MapField::getjamming().

int TerrainType::Weather::bi_pict

the image index from the graphic set. -1 if graphics is not from graphic set.

See Also
GraphicSet

Definition at line 122 of file terraintype.h.

Referenced by ForestCalculation::Smoothing::GetNeighbourMask(), and ForestCalculation::Smoothing::SmoothIt().

int TerrainType::Weather::defensebonus

the defense bonus for the unit standing on this field.

See Also
AttackFormula::defense_defensebonus(int)

Definition at line 106 of file terraintype.h.

Referenced by MapField::getdefensebonus().

Surface TerrainType::Weather::image

the image of the field

Definition at line 103 of file terraintype.h.

TerrainType::MoveMalus TerrainType::Weather::move_malus

the movement cost for the various units to move across this field

Definition at line 115 of file terraintype.h.

Referenced by MapField::setparams().

TerrainType* TerrainType::Weather::terraintype

The documentation for this class was generated from the following files: