OpenMW
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
Public Member Functions | Static Public Member Functions | Private Attributes | List of all members
CSMWorld::CellCoordinates Class Reference

#include <cellcoordinates.hpp>

Collaboration diagram for CSMWorld::CellCoordinates:

Public Member Functions

 CellCoordinates ()
 
 CellCoordinates (int x, int y)
 
 CellCoordinates (const std::pair< int, int > &coordinates)
 
int getX () const
 
int getY () const
 
CellCoordinates move (int x, int y) const
 Return a copy of *this, moved by the given offset. More...
 
std::string getId (const std::string &worldspace) const
 Return the ID for the cell at these coordinates. More...
 

Static Public Member Functions

static bool isExteriorCell (const std::string &id)
 
static std::pair
< CellCoordinates, bool
fromId (const std::string &id)
 
static std::pair< int, intcoordinatesToCellIndex (float x, float y)
 

Private Attributes

int mX
 
int mY
 

Constructor & Destructor Documentation

CSMWorld::CellCoordinates::CellCoordinates ( )
CSMWorld::CellCoordinates::CellCoordinates ( int  x,
int  y 
)
CSMWorld::CellCoordinates::CellCoordinates ( const std::pair< int, int > &  coordinates)

Member Function Documentation

std::pair< int, int > CSMWorld::CellCoordinates::coordinatesToCellIndex ( float  x,
float  y 
)
static
Returns
cell coordinates such that given world coordinates are in it.

Here is the caller graph for this function:

std::pair< CSMWorld::CellCoordinates, bool > CSMWorld::CellCoordinates::fromId ( const std::string &  id)
static
Returns
first: CellCoordinates (or 0, 0 if cell does not have coordinates), second: is cell paged?
Note
The worldspace part of id is ignored

Here is the caller graph for this function:

std::string CSMWorld::CellCoordinates::getId ( const std::string &  worldspace) const

Return the ID for the cell at these coordinates.

Here is the caller graph for this function:

int CSMWorld::CellCoordinates::getX ( ) const

Here is the caller graph for this function:

int CSMWorld::CellCoordinates::getY ( ) const

Here is the caller graph for this function:

bool CSMWorld::CellCoordinates::isExteriorCell ( const std::string &  id)
static

Here is the caller graph for this function:

CSMWorld::CellCoordinates CSMWorld::CellCoordinates::move ( int  x,
int  y 
) const

Return a copy of *this, moved by the given offset.

Here is the caller graph for this function:

Member Data Documentation

int CSMWorld::CellCoordinates::mX
private
int CSMWorld::CellCoordinates::mY
private

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