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

NPC object representing the player and additional player data. More...

#include <player.hpp>

Collaboration diagram for MWWorld::Player:

Public Member Functions

 Player (const ESM::NPC *player)
 
void saveSkillsAttributes ()
 
void restoreSkillsAttributes ()
 
void setWerewolfSkillsAttributes ()
 
void markPosition (CellStore *markedCell, ESM::Position markedPosition)
 
void getMarkedPosition (CellStore *&markedCell, ESM::Position &markedPosition) const
 
void setLastKnownExteriorPosition (const osg::Vec3f &position)
 
osg::Vec3f getLastKnownExteriorPosition () const
 
void set (const ESM::NPC *player)
 
void setCell (MWWorld::CellStore *cellStore)
 
MWWorld::Ptr getPlayer ()
 
void setBirthSign (const std::string &sign)
 
const std::string & getBirthSign () const
 
void setDrawState (MWMechanics::DrawState_ state)
 
MWMechanics::DrawState_ getDrawState ()
 
void activate ()
 Activate the object under the crosshair, if any. More...
 
bool getAutoMove () const
 
void setAutoMove (bool enable)
 
void setLeftRight (int value)
 
void setForwardBackward (int value)
 
void setUpDown (int value)
 
void setRunState (bool run)
 
void setSneak (bool sneak)
 
void yaw (float yaw)
 
void pitch (float pitch)
 
void roll (float roll)
 
bool wasTeleported () const
 
void setTeleported (bool teleported)
 
void setAttackingOrSpell (bool attackingOrSpell)
 
bool getAttackingOrSpell () const
 
bool isInCombat ()
 Checks all nearby actors to see if anyone has an aipackage against you. More...
 
bool enemiesNearby ()
 
void clear ()
 
void write (ESM::ESMWriter &writer, Loading::Listener &progress) const
 
bool readRecord (ESM::ESMReader &reader, uint32_t type)
 
int getNewCrimeId ()
 
void recordCrimeId ()
 
int getCrimeId () const
 

Private Attributes

LiveCellRef< ESM::NPCmPlayer
 
MWWorld::CellStoremCellStore
 
std::string mSign
 
osg::Vec3f mLastKnownExteriorPosition
 
ESM::Position mMarkedPosition
 
CellStoremMarkedCell
 
bool mAutoMove
 
int mForwardBackward
 
bool mTeleported
 
int mCurrentCrimeId
 
int mPaidCrimeId
 
MWMechanics::SkillValue mSaveSkills [ESM::Skill::Length]
 
MWMechanics::AttributeValue mSaveAttributes [ESM::Attribute::Length]
 
bool mAttackingOrSpell
 

Detailed Description

NPC object representing the player and additional player data.

Constructor & Destructor Documentation

MWWorld::Player::Player ( const ESM::NPC player)

Here is the call graph for this function:

Member Function Documentation

void MWWorld::Player::activate ( )

Activate the object under the crosshair, if any.

Todo:
constness

Here is the call graph for this function:

Here is the caller graph for this function:

void MWWorld::Player::clear ( )

Here is the caller graph for this function:

bool MWWorld::Player::enemiesNearby ( )

Here is the call graph for this function:

Here is the caller graph for this function:

bool MWWorld::Player::getAttackingOrSpell ( ) const
bool MWWorld::Player::getAutoMove ( ) const

Here is the caller graph for this function:

const std::string & MWWorld::Player::getBirthSign ( ) const

Here is the caller graph for this function:

int MWWorld::Player::getCrimeId ( ) const

Here is the caller graph for this function:

MWMechanics::DrawState_ MWWorld::Player::getDrawState ( )

Here is the call graph for this function:

Here is the caller graph for this function:

osg::Vec3f MWWorld::Player::getLastKnownExteriorPosition ( ) const
inline

Here is the caller graph for this function:

void MWWorld::Player::getMarkedPosition ( CellStore *&  markedCell,
ESM::Position markedPosition 
) const

Here is the caller graph for this function:

int MWWorld::Player::getNewCrimeId ( )

Here is the caller graph for this function:

MWWorld::Ptr MWWorld::Player::getPlayer ( )

Here is the caller graph for this function:

bool MWWorld::Player::isInCombat ( )

Checks all nearby actors to see if anyone has an aipackage against you.

Here is the call graph for this function:

Here is the caller graph for this function:

void MWWorld::Player::markPosition ( CellStore markedCell,
ESM::Position  markedPosition 
)

Here is the caller graph for this function:

void MWWorld::Player::pitch ( float  pitch)

Here is the call graph for this function:

Here is the caller graph for this function:

bool MWWorld::Player::readRecord ( ESM::ESMReader reader,
uint32_t  type 
)

Here is the call graph for this function:

Here is the caller graph for this function:

void MWWorld::Player::recordCrimeId ( )

Here is the caller graph for this function:

void MWWorld::Player::restoreSkillsAttributes ( )

Here is the call graph for this function:

Here is the caller graph for this function:

void MWWorld::Player::roll ( float  roll)

Here is the call graph for this function:

void MWWorld::Player::saveSkillsAttributes ( )

Here is the call graph for this function:

Here is the caller graph for this function:

void MWWorld::Player::set ( const ESM::NPC player)

Here is the caller graph for this function:

void MWWorld::Player::setAttackingOrSpell ( bool  attackingOrSpell)

Here is the caller graph for this function:

void MWWorld::Player::setAutoMove ( bool  enable)

Here is the call graph for this function:

Here is the caller graph for this function:

void MWWorld::Player::setBirthSign ( const std::string &  sign)

Here is the caller graph for this function:

void MWWorld::Player::setCell ( MWWorld::CellStore cellStore)

Here is the caller graph for this function:

void MWWorld::Player::setDrawState ( MWMechanics::DrawState_  state)

Here is the call graph for this function:

Here is the caller graph for this function:

void MWWorld::Player::setForwardBackward ( int  value)

Here is the call graph for this function:

Here is the caller graph for this function:

void MWWorld::Player::setLastKnownExteriorPosition ( const osg::Vec3f &  position)
inline

Interiors can not always be mapped to a world position. However world position is still required for divine / almsivi magic effects and the player arrow on the global map.

Here is the caller graph for this function:

void MWWorld::Player::setLeftRight ( int  value)

Here is the call graph for this function:

Here is the caller graph for this function:

void MWWorld::Player::setRunState ( bool  run)

Here is the call graph for this function:

Here is the caller graph for this function:

void MWWorld::Player::setSneak ( bool  sneak)

Here is the call graph for this function:

Here is the caller graph for this function:

void MWWorld::Player::setTeleported ( bool  teleported)

Here is the caller graph for this function:

void MWWorld::Player::setUpDown ( int  value)

Here is the call graph for this function:

Here is the caller graph for this function:

void MWWorld::Player::setWerewolfSkillsAttributes ( )

Here is the call graph for this function:

Here is the caller graph for this function:

bool MWWorld::Player::wasTeleported ( ) const

Here is the caller graph for this function:

void MWWorld::Player::write ( ESM::ESMWriter writer,
Loading::Listener progress 
) const

Here is the call graph for this function:

Here is the caller graph for this function:

void MWWorld::Player::yaw ( float  yaw)

Here is the call graph for this function:

Here is the caller graph for this function:

Member Data Documentation

bool MWWorld::Player::mAttackingOrSpell
private
bool MWWorld::Player::mAutoMove
private
MWWorld::CellStore* MWWorld::Player::mCellStore
private
int MWWorld::Player::mCurrentCrimeId
private
int MWWorld::Player::mForwardBackward
private
osg::Vec3f MWWorld::Player::mLastKnownExteriorPosition
private
CellStore* MWWorld::Player::mMarkedCell
private
ESM::Position MWWorld::Player::mMarkedPosition
private
int MWWorld::Player::mPaidCrimeId
private
LiveCellRef<ESM::NPC> MWWorld::Player::mPlayer
private
MWMechanics::AttributeValue MWWorld::Player::mSaveAttributes[ESM::Attribute::Length]
private
MWMechanics::SkillValue MWWorld::Player::mSaveSkills[ESM::Skill::Length]
private
std::string MWWorld::Player::mSign
private
bool MWWorld::Player::mTeleported
private

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