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

The game world and its visual representation. More...

#include <worldimp.hpp>

Inheritance diagram for MWWorld::World:
Collaboration diagram for MWWorld::World:

Public Member Functions

void removeContainerScripts (const Ptr &reference) override
 
 World (osgViewer::Viewer *viewer, osg::ref_ptr< osg::Group > rootNode, Resource::ResourceSystem *resourceSystem, SceneUtil::WorkQueue *workQueue, const Files::Collections &fileCollections, const std::vector< std::string > &contentFiles, ToUTF8::Utf8Encoder *encoder, const std::map< std::string, std::string > &fallbackMap, int activationDistanceOverride, const std::string &startCell, const std::string &startupScript, const std::string &resourcePath, const std::string &userDataPath)
 
virtual ~World ()
 
void startNewGame (bool bypass) override
 
void clear () override
 
int countSavedGameRecords () const override
 
int countSavedGameCells () const override
 
void write (ESM::ESMWriter &writer, Loading::Listener &progress) const override
 
void readRecord (ESM::ESMReader &reader, uint32_t type, const std::map< int, int > &contentFileMap) override
 
CellStoregetExterior (int x, int y) override
 
CellStoregetInterior (const std::string &name) override
 
CellStoregetCell (const ESM::CellId &id) override
 
void useDeathCamera () override
 
void setWaterHeight (const float height) override
 
void rotateWorldObject (const MWWorld::Ptr &ptr, osg::Quat rotate) override
 
bool toggleWater () override
 
bool toggleWorld () override
 
bool toggleBorders () override
 
void adjustSky () override
 
const Fallback::MapgetFallback () const override
 
PlayergetPlayer () override
 
MWWorld::Ptr getPlayerPtr () override
 
const MWWorld::ESMStoregetStore () const override
 
std::vector< ESM::ESMReader > & getEsmReader () override
 
LocalScriptsgetLocalScripts () override
 
bool hasCellChanged () const override
 Has the set of active cells changed, since the last frame? More...
 
bool isCellExterior () const override
 
bool isCellQuasiExterior () const override
 
osg::Vec2f getNorthVector (const CellStore *cell) override
 get north vector for given interior cell More...
 
void getDoorMarkers (MWWorld::CellStore *cell, std::vector< DoorMarker > &out) override
 get a list of teleport door markers for a given cell, to be displayed on the local map More...
 
void setGlobalInt (const std::string &name, int value) override
 Set value independently from real type. More...
 
void setGlobalFloat (const std::string &name, float value) override
 Set value independently from real type. More...
 
int getGlobalInt (const std::string &name) const override
 Get value independently from real type. More...
 
float getGlobalFloat (const std::string &name) const override
 Get value independently from real type. More...
 
char getGlobalVariableType (const std::string &name) const override
 Return ' ', if there is no global variable with this name. More...
 
std::string getCellName (const MWWorld::CellStore *cell=0) const override
 
void removeRefScript (MWWorld::RefData *ref) override
 
Ptr getPtr (const std::string &name, bool activeOnly) override
 
Ptr searchPtr (const std::string &name, bool activeOnly) override
 
Ptr searchPtrViaActorId (int actorId) override
 Search is limited to the active cells. More...
 
MWWorld::Ptr findContainer (const MWWorld::ConstPtr &ptr) override
 
void adjustPosition (const Ptr &ptr, bool force) override
 
void fixPosition (const Ptr &actor) override
 Attempt to fix position so that the Ptr is no longer inside collision geometry. More...
 
void enable (const Ptr &ptr) override
 
void disable (const Ptr &ptr) override
 
void advanceTime (double hours, bool incremental=false) override
 Advance in-game time. More...
 
void setHour (double hour) override
 Set in-game time hour. More...
 
void setMonth (int month) override
 Set in-game time month. More...
 
void setDay (int day) override
 Set in-game time day. More...
 
int getDay () const override
 
int getMonth () const override
 
int getYear () const override
 
std::string getMonthName (int month=-1) const override
 Return name of month (-1: current month) More...
 
TimeStamp getTimeStamp () const override
 Return current in-game time stamp. More...
 
bool toggleSky () override
 
void changeWeather (const std::string &region, const unsigned int id) override
 
int getCurrentWeather () const override
 
int getMasserPhase () const override
 
int getSecundaPhase () const override
 
void setMoonColour (bool red) override
 
void modRegion (const std::string &regionid, const std::vector< char > &chances) override
 
float getTimeScaleFactor () const override
 
void changeToInteriorCell (const std::string &cellName, const ESM::Position &position, bool adjustPlayerPos, bool changeEvent=true) override
 
void changeToExteriorCell (const ESM::Position &position, bool adjustPlayerPos, bool changeEvent=true) override
 
void changeToCell (const ESM::CellId &cellId, const ESM::Position &position, bool adjustPlayerPos, bool changeEvent=true) override
 
const ESM::CellgetExterior (const std::string &cellName) const override
 Return a cell matching the given name or a 0-pointer, if there is no such cell. More...
 
void markCellAsUnchanged () override
 
MWWorld::Ptr getFacedObject () override
 Return pointer to the object the player is looking at, if it is within activation range. More...
 
float getDistanceToFacedObject () override
 
std::pair< MWWorld::Ptr,
osg::Vec3f > 
getHitContact (const MWWorld::ConstPtr &ptr, float distance, std::vector< MWWorld::Ptr > &targets) override
 
void deleteObject (const Ptr &ptr) override
 
void undeleteObject (const Ptr &ptr) override
 
MWWorld::Ptr moveObject (const Ptr &ptr, float x, float y, float z) override
 
MWWorld::Ptr moveObject (const Ptr &ptr, CellStore *newCell, float x, float y, float z, bool movePhysics=true) override
 
void scaleObject (const Ptr &ptr, float scale) override
 
void rotateObject (const Ptr &ptr, float x, float y, float z, bool adjust=false) override
 
MWWorld::Ptr placeObject (const MWWorld::ConstPtr &ptr, MWWorld::CellStore *cell, ESM::Position pos) override
 Place an object. Makes a copy of the Ptr. More...
 
MWWorld::Ptr safePlaceObject (const MWWorld::ConstPtr &ptr, const MWWorld::ConstPtr &referenceObject, MWWorld::CellStore *referenceCell, int direction, float distance) override
 
float getMaxActivationDistance () override
 
void indexToPosition (int cellX, int cellY, float &x, float &y, bool centre=false) const override
 Convert cell numbers to position. More...
 
void positionToIndex (float x, float y, int &cellX, int &cellY) const override
 Convert position to cell numbers. More...
 
void queueMovement (const Ptr &ptr, const osg::Vec3f &velocity) override
 
bool castRay (float x1, float y1, float z1, float x2, float y2, float z2, bool ignoreDoors=false) override
 cast a Ray and return true if there is an object in the ray path. More...
 
bool toggleCollisionMode () override
 
bool toggleRenderMode (MWRender::RenderMode mode) override
 
const ESM::PotioncreateRecord (const ESM::Potion &record) override
 
const ESM::SpellcreateRecord (const ESM::Spell &record) override
 
const ESM::ClasscreateRecord (const ESM::Class &record) override
 
const ESM::CellcreateRecord (const ESM::Cell &record) override
 
const ESM::NPCcreateRecord (const ESM::NPC &record) override
 
const ESM::ArmorcreateRecord (const ESM::Armor &record) override
 
const ESM::WeaponcreateRecord (const ESM::Weapon &record) override
 
const ESM::ClothingcreateRecord (const ESM::Clothing &record) override
 
const ESM::EnchantmentcreateRecord (const ESM::Enchantment &record) override
 
const ESM::BookcreateRecord (const ESM::Book &record) override
 
const ESM::CreatureLevListcreateOverrideRecord (const ESM::CreatureLevList &record) override
 
const ESM::ItemLevListcreateOverrideRecord (const ESM::ItemLevList &record) override
 
void update (float duration, bool paused) override
 
void updateWindowManager () override
 
MWWorld::Ptr placeObject (const MWWorld::ConstPtr &object, float cursorX, float cursorY, int amount) override
 
MWWorld::Ptr dropObjectOnGround (const MWWorld::Ptr &actor, const MWWorld::ConstPtr &object, int amount) override
 
bool canPlaceObject (float cursorX, float cursorY) override
 
void processChangedSettings (const Settings::CategorySettingVector &settings) override
 
bool isFlying (const MWWorld::Ptr &ptr) const override
 
bool isSlowFalling (const MWWorld::Ptr &ptr) const override
 
bool isSubmerged (const MWWorld::ConstPtr &object) const override
 Is the head of the creature underwater? More...
 
bool isSwimming (const MWWorld::ConstPtr &object) const override
 
bool isUnderwater (const MWWorld::CellStore *cell, const osg::Vec3f &pos) const override
 
bool isUnderwater (const MWWorld::ConstPtr &object, const float heightRatio) const override
 
bool isWading (const MWWorld::ConstPtr &object) const override
 
bool isWaterWalkingCastableOnTarget (const MWWorld::ConstPtr &target) const override
 
bool isOnGround (const MWWorld::Ptr &ptr) const override
 
osg::Matrixf getActorHeadTransform (const MWWorld::ConstPtr &actor) const override
 
void togglePOV () override
 
bool isFirstPerson () const override
 
void togglePreviewMode (bool enable) override
 
bool toggleVanityMode (bool enable) override
 
void allowVanityMode (bool allow) override
 
void togglePlayerLooking (bool enable) override
 
void changeVanityModeScale (float factor) override
 
bool vanityRotateCamera (float *rot) override
 
void setCameraDistance (float dist, bool adjust=false, bool override=true) override
 
void setupPlayer () override
 
void renderPlayer () override
 
void activateDoor (const MWWorld::Ptr &door) override
 open or close a non-teleport door (depending on current state) More...
 
void activateDoor (const MWWorld::Ptr &door, int state) override
 
void getActorsStandingOn (const MWWorld::ConstPtr &object, std::vector< MWWorld::Ptr > &actors) override
 get a list of actors standing on object More...
 
bool getPlayerStandingOn (const MWWorld::ConstPtr &object) override
 
bool getActorStandingOn (const MWWorld::ConstPtr &object) override
 
bool getPlayerCollidingWith (const MWWorld::ConstPtr &object) override
 
bool getActorCollidingWith (const MWWorld::ConstPtr &object) override
 
void hurtStandingActors (const MWWorld::ConstPtr &object, float dmgPerSecond) override
 
void hurtCollidingActors (const MWWorld::ConstPtr &object, float dmgPerSecond) override
 
float getWindSpeed () override
 
void getContainersOwnedBy (const MWWorld::ConstPtr &npc, std::vector< MWWorld::Ptr > &out) override
 get all containers in active cells owned by this Npc More...
 
void getItemsOwnedBy (const MWWorld::ConstPtr &npc, std::vector< MWWorld::Ptr > &out) override
 get all items in active cells owned by this Npc More...
 
bool getLOS (const MWWorld::ConstPtr &actor, const MWWorld::ConstPtr &targetActor) override
 get Line of Sight (morrowind stupid implementation) More...
 
float getDistToNearestRayHit (const osg::Vec3f &from, const osg::Vec3f &dir, float maxDist, bool includeWater=false) override
 
void enableActorCollision (const MWWorld::Ptr &actor, bool enable) override
 
RestPermitted canRest () const override
 check if the player is allowed to rest More...
 
void rest () override
 
MWRender::AnimationgetAnimation (const MWWorld::Ptr &ptr) override
 
const MWRender::AnimationgetAnimation (const MWWorld::ConstPtr &ptr) const override
 
void reattachPlayerCamera () override
 
void screenshot (osg::Image *image, int w, int h) override
 
bool screenshot360 (osg::Image *image, std::string settingStr) override
 
bool findExteriorPosition (const std::string &name, ESM::Position &pos) override
 
bool findInteriorPosition (const std::string &name, ESM::Position &pos) override
 
void enableTeleporting (bool enable) override
 Enables or disables use of teleport spell effects (recall, intervention, etc). More...
 
bool isTeleportingEnabled () const override
 Returns true if teleport spell effects are allowed. More...
 
void enableLevitation (bool enable) override
 Enables or disables use of levitation spell effect. More...
 
bool isLevitationEnabled () const override
 Returns true if levitation spell effect is allowed. More...
 
bool getGodModeState () override
 
bool toggleGodMode () override
 
bool toggleScripts () override
 
bool getScriptsEnabled () const override
 
bool startSpellCast (const MWWorld::Ptr &actor) override
 startSpellCast attempt to start casting a spell. Might fail immediately if conditions are not met. More...
 
void castSpell (const MWWorld::Ptr &actor, bool manualSpell=false) override
 Cast the actual spell, should be called mid-animation. More...
 
void launchMagicBolt (const std::string &spellId, const MWWorld::Ptr &caster, const osg::Vec3f &fallbackDirection) override
 
void launchProjectile (MWWorld::Ptr &actor, MWWorld::Ptr &projectile, const osg::Vec3f &worldPos, const osg::Quat &orient, MWWorld::Ptr &bow, float speed, float attackStrength) override
 
void applyLoopingParticles (const MWWorld::Ptr &ptr) override
 
const std::vector< std::string > & getContentFiles () const override
 
void breakInvisibility (const MWWorld::Ptr &actor) override
 
bool useTorches () const override
 
bool findInteriorPositionInWorldSpace (const MWWorld::CellStore *cell, osg::Vec3f &result) override
 
void teleportToClosestMarker (const MWWorld::Ptr &ptr, const std::string &id) override
 
void listDetectedReferences (const MWWorld::Ptr &ptr, std::vector< MWWorld::Ptr > &out, DetectionType type) override
 
void updateDialogueGlobals () override
 
void confiscateStolenItems (const MWWorld::Ptr &ptr) override
 Moves all stolen items from ptr to the closest evidence chest. More...
 
void goToJail () override
 
void spawnRandomCreature (const std::string &creatureList) override
 Spawn a random creature from a levelled list next to the player. More...
 
void spawnBloodEffect (const MWWorld::Ptr &ptr, const osg::Vec3f &worldPosition) override
 Spawn a blood effect for ptr at worldPosition. More...
 
void spawnEffect (const std::string &model, const std::string &textureOverride, const osg::Vec3f &worldPos, float scale=1.f, bool isMagicVFX=true) override
 
void explodeSpell (const osg::Vec3f &origin, const ESM::EffectList &effects, const MWWorld::Ptr &caster, const MWWorld::Ptr &ignore, ESM::RangeType rangeType, const std::string &id, const std::string &sourceName, const bool fromProjectile=false) override
 
void activate (const MWWorld::Ptr &object, const MWWorld::Ptr &actor) override
 
bool isInStorm () const override
 
osg::Vec3f getStormDirection () const override
 
void resetActors () override
 Resets all actors in the current active cells to their original location within that cell. More...
 
bool isWalkingOnWater (const MWWorld::ConstPtr &actor) const override
 
osg::Vec3f aimToTarget (const MWWorld::ConstPtr &actor, const MWWorld::ConstPtr &target) override
 
float getHitDistance (const MWWorld::ConstPtr &actor, const MWWorld::ConstPtr &target) override
 Return the distance between actor's weapon and target's collision box. More...
 
bool isPlayerInJail () const override
 
void setPlayerTraveling (bool traveling) override
 
bool isPlayerTraveling () const override
 
float getTerrainHeightAt (const osg::Vec3f &worldPos) const override
 Return terrain height at worldPos position. More...
 
osg::Vec3f getHalfExtents (const MWWorld::ConstPtr &actor, bool rendering=false) const override
 Return physical or rendering half extents of the given actor. More...
 
std::string exportSceneGraph (const MWWorld::Ptr &ptr) override
 
void preloadEffects (const ESM::EffectList *effectList) override
 Preload VFX associated with this effect list. More...
 
- Public Member Functions inherited from MWBase::World
 World ()
 
virtual void processChangedSettings (const std::set< std::pair< std::string, std::string > > &settings)=0
 

Private Member Functions

 World (const World &)
 
Worldoperator= (const World &)
 
void updateWeather (float duration, bool paused=false)
 
int getDaysPerMonth (int month) const
 
void rotateObjectImp (const Ptr &ptr, const osg::Vec3f &rot, bool adjust)
 
Ptr moveObjectImp (const Ptr &ptr, float x, float y, float z, bool movePhysics=true)
 
Ptr copyObjectToCell (const ConstPtr &ptr, CellStore *cell, ESM::Position pos, int count, bool adjustPos)
 
void updateSoundListener ()
 
void updatePlayer ()
 
void preloadSpells ()
 
MWWorld::Ptr getFacedObject (float maxDistance, bool ignorePlayer=true)
 
void addContainerScripts (const Ptr &reference, CellStore *cell)
 
void PCDropped (const Ptr &item)
 
void processDoors (float duration)
 Run physics simulation and modify world accordingly. More...
 
void doPhysics (float duration)
 Run physics simulation and modify world accordingly. More...
 
void ensureNeededRecords ()
 
void fillGlobalVariables ()
 
void loadContentFiles (const Files::Collections &fileCollections, const std::vector< std::string > &content, ContentLoader &contentLoader)
 loadContentFiles - Loads content files (esm,esp,omwgame,omwaddon) More...
 
float feetToGameUnits (float feet)
 
float getActivationDistancePlusTelekinesis ()
 
MWWorld::ConstPtr getClosestMarker (const MWWorld::Ptr &ptr, const std::string &id)
 
MWWorld::ConstPtr getClosestMarkerFromExteriorPosition (const osg::Vec3f &worldPos, const std::string &id)
 

Private Attributes

Resource::ResourceSystemmResourceSystem
 
Fallback::Map mFallback
 
std::vector< ESM::ESMReadermEsm
 
MWWorld::ESMStore mStore
 
LocalScripts mLocalScripts
 
MWWorld::Globals mGlobalVariables
 
bool mSky
 
ESM::VariantmGameHour
 
ESM::VariantmDaysPassed
 
ESM::VariantmDay
 
ESM::VariantmMonth
 
ESM::VariantmYear
 
ESM::VariantmTimeScale
 
Cells mCells
 
std::string mCurrentWorldSpace
 
std::unique_ptr< MWWorld::PlayermPlayer
 
std::unique_ptr
< MWPhysics::PhysicsSystem
mPhysics
 
std::unique_ptr
< MWRender::RenderingManager
mRendering
 
std::unique_ptr< MWWorld::ScenemWorldScene
 
std::unique_ptr
< MWWorld::WeatherManager
mWeatherManager
 
std::shared_ptr
< ProjectileManager
mProjectileManager
 
bool mGodMode
 
bool mScriptsEnabled
 
std::vector< std::string > mContentFiles
 
std::string mUserDataPath
 
int mActivationDistanceOverride
 
std::string mStartupScript
 
std::map< MWWorld::Ptr, intmDoorStates
 only holds doors that are currently moving. 1 = opening, 2 = closing More...
 
std::string mStartCell
 
float mSwimHeightScale
 
float mDistanceToFacedObject
 
bool mTeleportEnabled
 
bool mLevitationEnabled
 
bool mGoToJail
 
int mDaysInPrison
 
bool mPlayerTraveling
 
bool mPlayerInJail
 
float mSpellPreloadTimer
 

Additional Inherited Members

- Public Types inherited from MWBase::World
enum  RestPermitted { Rest_Allowed = 0, Rest_OnlyWaiting = 1, Rest_PlayerIsUnderwater = 2, Rest_EnemiesAreNearby = 3 }
 
enum  DetectionType { Detect_Enchantment, Detect_Key, Detect_Creature }
 

Detailed Description

The game world and its visual representation.

Constructor & Destructor Documentation

MWWorld::World::World ( const World )
private
MWWorld::World::World ( osgViewer::Viewer *  viewer,
osg::ref_ptr< osg::Group >  rootNode,
Resource::ResourceSystem resourceSystem,
SceneUtil::WorkQueue workQueue,
const Files::Collections fileCollections,
const std::vector< std::string > &  contentFiles,
ToUTF8::Utf8Encoder encoder,
const std::map< std::string, std::string > &  fallbackMap,
int  activationDistanceOverride,
const std::string &  startCell,
const std::string &  startupScript,
const std::string &  resourcePath,
const std::string &  userDataPath 
)

Here is the call graph for this function:

MWWorld::World::~World ( )
virtual

Reimplemented from MWBase::World.

Member Function Documentation

void MWWorld::World::activate ( const MWWorld::Ptr object,
const MWWorld::Ptr actor 
)
overridevirtual

Implements MWBase::World.

Here is the call graph for this function:

void MWWorld::World::activateDoor ( const MWWorld::Ptr door)
overridevirtual

open or close a non-teleport door (depending on current state)

Implements MWBase::World.

Here is the call graph for this function:

void MWWorld::World::activateDoor ( const MWWorld::Ptr door,
int  state 
)
overridevirtual

update movement state of a non-teleport door as specified

Parameters
statesee MWClass::setDoorState
Note
throws an exception when invoked on a teleport door

Implements MWBase::World.

Here is the call graph for this function:

void MWWorld::World::addContainerScripts ( const Ptr reference,
CellStore cell 
)
private

Here is the call graph for this function:

Here is the caller graph for this function:

void MWWorld::World::adjustPosition ( const Ptr ptr,
bool  force 
)
overridevirtual

Adjust position after load to be on ground. Must be called after model load.

Parameters
forcedo this even if the ptr is flying

Implements MWBase::World.

Here is the call graph for this function:

Here is the caller graph for this function:

void MWWorld::World::adjustSky ( )
overridevirtual

Implements MWBase::World.

Here is the call graph for this function:

void MWWorld::World::advanceTime ( double  hours,
bool  incremental = false 
)
overridevirtual

Advance in-game time.

Implements MWBase::World.

Here is the call graph for this function:

osg::Vec3f MWWorld::World::aimToTarget ( const MWWorld::ConstPtr actor,
const MWWorld::ConstPtr target 
)
overridevirtual

Return a vector aiming the actor's weapon towards a target.

Note
The length of the vector is the distance between actor and target.

Implements MWBase::World.

Here is the call graph for this function:

void MWWorld::World::allowVanityMode ( bool  allow)
overridevirtual

Implements MWBase::World.

void MWWorld::World::applyLoopingParticles ( const MWWorld::Ptr ptr)
overridevirtual

Implements MWBase::World.

Here is the call graph for this function:

Here is the caller graph for this function:

void MWWorld::World::breakInvisibility ( const MWWorld::Ptr actor)
overridevirtual

Implements MWBase::World.

Here is the call graph for this function:

Here is the caller graph for this function:

bool MWWorld::World::canPlaceObject ( float  cursorX,
float  cursorY 
)
overridevirtual
Returns
true if it is possible to place on object at specified cursor location

Implements MWBase::World.

World::RestPermitted MWWorld::World::canRest ( ) const
overridevirtual

check if the player is allowed to rest

Implements MWBase::World.

Here is the call graph for this function:

bool MWWorld::World::castRay ( float  x1,
float  y1,
float  z1,
float  x2,
float  y2,
float  z2,
bool  ignoreDoors = false 
)
overridevirtual

cast a Ray and return true if there is an object in the ray path.

Implements MWBase::World.

Here is the caller graph for this function:

void MWWorld::World::castSpell ( const MWWorld::Ptr actor,
bool  manualSpell = false 
)
overridevirtual

Cast the actual spell, should be called mid-animation.

Parameters
actor

Implements MWBase::World.

Here is the call graph for this function:

void MWWorld::World::changeToCell ( const ESM::CellId cellId,
const ESM::Position position,
bool  adjustPlayerPos,
bool  changeEvent = true 
)
overridevirtual
Parameters
changeEventIf false, do not trigger cell change flag or detect worldspace changes

Implements MWBase::World.

Here is the call graph for this function:

void MWWorld::World::changeToExteriorCell ( const ESM::Position position,
bool  adjustPlayerPos,
bool  changeEvent = true 
)
overridevirtual

Move to exterior cell.

Parameters
changeEventIf false, do not trigger cell change flag or detect worldspace changes

Implements MWBase::World.

Here is the call graph for this function:

Here is the caller graph for this function:

void MWWorld::World::changeToInteriorCell ( const std::string &  cellName,
const ESM::Position position,
bool  adjustPlayerPos,
bool  changeEvent = true 
)
overridevirtual

Move to interior cell.

Parameters
changeEventIf false, do not trigger cell change flag or detect worldspace changes

Implements MWBase::World.

Here is the call graph for this function:

Here is the caller graph for this function:

void MWWorld::World::changeVanityModeScale ( float  factor)
overridevirtual

Implements MWBase::World.

void MWWorld::World::changeWeather ( const std::string &  region,
const unsigned int  id 
)
overridevirtual

Implements MWBase::World.

void MWWorld::World::clear ( )
overridevirtual

Implements MWBase::World.

Here is the call graph for this function:

void MWWorld::World::confiscateStolenItems ( const MWWorld::Ptr ptr)
overridevirtual

Moves all stolen items from ptr to the closest evidence chest.

Implements MWBase::World.

Here is the call graph for this function:

Here is the caller graph for this function:

Ptr MWWorld::World::copyObjectToCell ( const ConstPtr ptr,
CellStore cell,
ESM::Position  pos,
int  count,
bool  adjustPos 
)
private

Here is the call graph for this function:

Here is the caller graph for this function:

int MWWorld::World::countSavedGameCells ( ) const
overridevirtual

Implements MWBase::World.

Here is the call graph for this function:

int MWWorld::World::countSavedGameRecords ( ) const
overridevirtual

Implements MWBase::World.

Here is the call graph for this function:

const ESM::CreatureLevList * MWWorld::World::createOverrideRecord ( const ESM::CreatureLevList record)
overridevirtual

Write this record to the ESM store, allowing it to override a pre-existing record with the same ID.

Returns
pointer to created record

Implements MWBase::World.

Here is the call graph for this function:

const ESM::ItemLevList * MWWorld::World::createOverrideRecord ( const ESM::ItemLevList record)
overridevirtual

Write this record to the ESM store, allowing it to override a pre-existing record with the same ID.

Returns
pointer to created record

Implements MWBase::World.

Here is the call graph for this function:

const ESM::Potion * MWWorld::World::createRecord ( const ESM::Potion record)
overridevirtual

Create a new record (of type potion) in the ESM store.

Returns
pointer to created record

Implements MWBase::World.

Here is the call graph for this function:

Here is the caller graph for this function:

const ESM::Spell * MWWorld::World::createRecord ( const ESM::Spell record)
overridevirtual

Create a new record (of type spell) in the ESM store.

Returns
pointer to created record

Implements MWBase::World.

Here is the call graph for this function:

const ESM::Class * MWWorld::World::createRecord ( const ESM::Class record)
overridevirtual

Create a new record (of type class) in the ESM store.

Returns
pointer to created record

Implements MWBase::World.

Here is the call graph for this function:

const ESM::Cell * MWWorld::World::createRecord ( const ESM::Cell record)
overridevirtual

Create a new record (of type cell) in the ESM store.

Returns
pointer to created record

Implements MWBase::World.

Here is the call graph for this function:

const ESM::NPC * MWWorld::World::createRecord ( const ESM::NPC record)
overridevirtual

Create a new record (of type npc) in the ESM store.

Returns
pointer to created record

Implements MWBase::World.

Here is the call graph for this function:

const ESM::Armor * MWWorld::World::createRecord ( const ESM::Armor record)
overridevirtual

Create a new record (of type armor) in the ESM store.

Returns
pointer to created record

Implements MWBase::World.

Here is the call graph for this function:

const ESM::Weapon * MWWorld::World::createRecord ( const ESM::Weapon record)
overridevirtual

Create a new record (of type weapon) in the ESM store.

Returns
pointer to created record

Implements MWBase::World.

Here is the call graph for this function:

const ESM::Clothing * MWWorld::World::createRecord ( const ESM::Clothing record)
overridevirtual

Create a new record (of type clothing) in the ESM store.

Returns
pointer to created record

Implements MWBase::World.

Here is the call graph for this function:

const ESM::Enchantment * MWWorld::World::createRecord ( const ESM::Enchantment record)
overridevirtual

Create a new record (of type enchantment) in the ESM store.

Returns
pointer to created record

Implements MWBase::World.

Here is the call graph for this function:

const ESM::Book * MWWorld::World::createRecord ( const ESM::Book record)
overridevirtual

Create a new record (of type book) in the ESM store.

Returns
pointer to created record

Implements MWBase::World.

Here is the call graph for this function:

void MWWorld::World::deleteObject ( const Ptr ptr)
overridevirtual
Note
No-op for items in containers. Use ContainerStore::removeItem instead.

Implements MWBase::World.

Here is the call graph for this function:

Here is the caller graph for this function:

void MWWorld::World::disable ( const Ptr ptr)
overridevirtual

Implements MWBase::World.

Here is the call graph for this function:

void MWWorld::World::doPhysics ( float  duration)
private

Run physics simulation and modify world accordingly.

Here is the call graph for this function:

Here is the caller graph for this function:

MWWorld::Ptr MWWorld::World::dropObjectOnGround ( const MWWorld::Ptr actor,
const MWWorld::ConstPtr object,
int  amount 
)
overridevirtual

copy and place an object into the gameworld at the given actor's position

Parameters
actorgiving the dropped object position
object
numberof objects to place

Implements MWBase::World.

Here is the call graph for this function:

void MWWorld::World::enable ( const Ptr ptr)
overridevirtual

Implements MWBase::World.

Here is the call graph for this function:

Here is the caller graph for this function:

void MWWorld::World::enableActorCollision ( const MWWorld::Ptr actor,
bool  enable 
)
overridevirtual

Implements MWBase::World.

Here is the call graph for this function:

void MWWorld::World::enableLevitation ( bool  enable)
overridevirtual

Enables or disables use of levitation spell effect.

Implements MWBase::World.

Here is the call graph for this function:

void MWWorld::World::enableTeleporting ( bool  enable)
overridevirtual

Enables or disables use of teleport spell effects (recall, intervention, etc).

Implements MWBase::World.

Here is the call graph for this function:

void MWWorld::World::ensureNeededRecords ( )
private

Here is the call graph for this function:

Here is the caller graph for this function:

void MWWorld::World::explodeSpell ( const osg::Vec3f &  origin,
const ESM::EffectList effects,
const MWWorld::Ptr caster,
const MWWorld::Ptr ignore,
ESM::RangeType  rangeType,
const std::string &  id,
const std::string &  sourceName,
const bool  fromProjectile = false 
)
overridevirtual

Implements MWBase::World.

Here is the call graph for this function:

std::string MWWorld::World::exportSceneGraph ( const MWWorld::Ptr ptr)
overridevirtual

Export scene graph to a file and return the filename.

Parameters
ptrobject to export scene graph for (if empty, export entire scene graph)

Implements MWBase::World.

float MWWorld::World::feetToGameUnits ( float  feet)
private

Here is the caller graph for this function:

void MWWorld::World::fillGlobalVariables ( )
private

Here is the call graph for this function:

Here is the caller graph for this function:

Ptr MWWorld::World::findContainer ( const MWWorld::ConstPtr ptr)
overridevirtual

Return a pointer to a liveCellRef which contains ptr.

Note
Search is limited to the active cells.

Implements MWBase::World.

Here is the call graph for this function:

bool MWWorld::World::findExteriorPosition ( const std::string &  name,
ESM::Position pos 
)
overridevirtual

Find center of exterior cell above land surface

Returns
false if exterior with given name not exists, true otherwise

Implements MWBase::World.

Here is the call graph for this function:

Here is the caller graph for this function:

bool MWWorld::World::findInteriorPosition ( const std::string &  name,
ESM::Position pos 
)
overridevirtual

Find position in interior cell near door entrance

Returns
false if interior with given name not exists, true otherwise
Note
Using any door pointed to the interior, not the one pointed to current door.

Implements MWBase::World.

Here is the call graph for this function:

Here is the caller graph for this function:

bool MWWorld::World::findInteriorPositionInWorldSpace ( const MWWorld::CellStore cell,
osg::Vec3f &  result 
)
overridevirtual

Implements MWBase::World.

Here is the call graph for this function:

void MWWorld::World::fixPosition ( const Ptr actor)
overridevirtual

Attempt to fix position so that the Ptr is no longer inside collision geometry.

Implements MWBase::World.

Here is the call graph for this function:

float MWWorld::World::getActivationDistancePlusTelekinesis ( )
private

Here is the call graph for this function:

Here is the caller graph for this function:

bool MWWorld::World::getActorCollidingWith ( const MWWorld::ConstPtr object)
overridevirtual
Returns
true if any actor is colliding with object

Implements MWBase::World.

osg::Matrixf MWWorld::World::getActorHeadTransform ( const MWWorld::ConstPtr actor) const
overridevirtual

Implements MWBase::World.

Here is the call graph for this function:

Here is the caller graph for this function:

void MWWorld::World::getActorsStandingOn ( const MWWorld::ConstPtr object,
std::vector< MWWorld::Ptr > &  actors 
)
overridevirtual

get a list of actors standing on object

Implements MWBase::World.

bool MWWorld::World::getActorStandingOn ( const MWWorld::ConstPtr object)
overridevirtual
Returns
true if any actor is standing on object

Implements MWBase::World.

MWRender::Animation * MWWorld::World::getAnimation ( const MWWorld::Ptr ptr)
overridevirtual
Todo:
Probably shouldn't be here

Implements MWBase::World.

const MWRender::Animation * MWWorld::World::getAnimation ( const MWWorld::ConstPtr ptr) const
overridevirtual

Implements MWBase::World.

CellStore * MWWorld::World::getCell ( const ESM::CellId id)
overridevirtual

Implements MWBase::World.

Here is the call graph for this function:

Here is the caller graph for this function:

std::string MWWorld::World::getCellName ( const MWWorld::CellStore cell = 0) const
overridevirtual

Return name of the cell.

Note
If cell==0, the cell the player is currently in will be used instead to generate a name.

Implements MWBase::World.

Here is the call graph for this function:

MWWorld::ConstPtr MWWorld::World::getClosestMarker ( const MWWorld::Ptr ptr,
const std::string &  id 
)
private

Here is the call graph for this function:

Here is the caller graph for this function:

MWWorld::ConstPtr MWWorld::World::getClosestMarkerFromExteriorPosition ( const osg::Vec3f &  worldPos,
const std::string &  id 
)
private

Here is the call graph for this function:

Here is the caller graph for this function:

void MWWorld::World::getContainersOwnedBy ( const MWWorld::ConstPtr npc,
std::vector< MWWorld::Ptr > &  out 
)
overridevirtual

get all containers in active cells owned by this Npc

Implements MWBase::World.

const std::vector< std::string > & MWWorld::World::getContentFiles ( ) const
overridevirtual

Implements MWBase::World.

int MWWorld::World::getCurrentWeather ( ) const
overridevirtual

Implements MWBase::World.

int MWWorld::World::getDay ( ) const
overridevirtual

Implements MWBase::World.

Here is the call graph for this function:

int MWWorld::World::getDaysPerMonth ( int  month) const
private

Here is the caller graph for this function:

float MWWorld::World::getDistanceToFacedObject ( )
overridevirtual

Implements MWBase::World.

float MWWorld::World::getDistToNearestRayHit ( const osg::Vec3f &  from,
const osg::Vec3f &  dir,
float  maxDist,
bool  includeWater = false 
)
overridevirtual

Implements MWBase::World.

void MWWorld::World::getDoorMarkers ( MWWorld::CellStore cell,
std::vector< DoorMarker > &  out 
)
overridevirtual

get a list of teleport door markers for a given cell, to be displayed on the local map

Implements MWBase::World.

Here is the call graph for this function:

std::vector< ESM::ESMReader > & MWWorld::World::getEsmReader ( )
overridevirtual

Implements MWBase::World.

CellStore * MWWorld::World::getExterior ( int  x,
int  y 
)
overridevirtual

Implements MWBase::World.

Here is the call graph for this function:

Here is the caller graph for this function:

const ESM::Cell * MWWorld::World::getExterior ( const std::string &  cellName) const
overridevirtual

Return a cell matching the given name or a 0-pointer, if there is no such cell.

Implements MWBase::World.

Here is the call graph for this function:

MWWorld::Ptr MWWorld::World::getFacedObject ( float  maxDistance,
bool  ignorePlayer = true 
)
private

Here is the call graph for this function:

MWWorld::Ptr MWWorld::World::getFacedObject ( )
overridevirtual

Return pointer to the object the player is looking at, if it is within activation range.

Implements MWBase::World.

Here is the call graph for this function:

Here is the caller graph for this function:

const Fallback::Map * MWWorld::World::getFallback ( ) const
overridevirtual

Implements MWBase::World.

Here is the caller graph for this function:

float MWWorld::World::getGlobalFloat ( const std::string &  name) const
overridevirtual

Get value independently from real type.

Implements MWBase::World.

int MWWorld::World::getGlobalInt ( const std::string &  name) const
overridevirtual

Get value independently from real type.

Implements MWBase::World.

char MWWorld::World::getGlobalVariableType ( const std::string &  name) const
overridevirtual

Return ' ', if there is no global variable with this name.

Implements MWBase::World.

Here is the call graph for this function:

bool MWWorld::World::getGodModeState ( )
overridevirtual

Implements MWBase::World.

Here is the caller graph for this function:

osg::Vec3f MWWorld::World::getHalfExtents ( const MWWorld::ConstPtr actor,
bool  rendering = false 
) const
overridevirtual

Return physical or rendering half extents of the given actor.

Implements MWBase::World.

Here is the call graph for this function:

std::pair< MWWorld::Ptr, osg::Vec3f > MWWorld::World::getHitContact ( const MWWorld::ConstPtr ptr,
float  distance,
std::vector< MWWorld::Ptr > &  targets 
)
overridevirtual

Returns a pointer to the object the provided object would hit (if within the specified distance), and the point where the hit occurs. This will attempt to use the "Head" node as a basis.

Implements MWBase::World.

Here is the call graph for this function:

Here is the caller graph for this function:

float MWWorld::World::getHitDistance ( const MWWorld::ConstPtr actor,
const MWWorld::ConstPtr target 
)
overridevirtual

Return the distance between actor's weapon and target's collision box.

Implements MWBase::World.

Here is the call graph for this function:

CellStore * MWWorld::World::getInterior ( const std::string &  name)
overridevirtual

Implements MWBase::World.

Here is the call graph for this function:

Here is the caller graph for this function:

void MWWorld::World::getItemsOwnedBy ( const MWWorld::ConstPtr npc,
std::vector< MWWorld::Ptr > &  out 
)
overridevirtual

get all items in active cells owned by this Npc

Implements MWBase::World.

Here is the call graph for this function:

LocalScripts & MWWorld::World::getLocalScripts ( )
overridevirtual

Implements MWBase::World.

Here is the caller graph for this function:

bool MWWorld::World::getLOS ( const MWWorld::ConstPtr actor,
const MWWorld::ConstPtr targetActor 
)
overridevirtual

get Line of Sight (morrowind stupid implementation)

Implements MWBase::World.

Here is the call graph for this function:

int MWWorld::World::getMasserPhase ( ) const
overridevirtual

Implements MWBase::World.

float MWWorld::World::getMaxActivationDistance ( )
overridevirtual

Implements MWBase::World.

Here is the call graph for this function:

Here is the caller graph for this function:

int MWWorld::World::getMonth ( ) const
overridevirtual

Implements MWBase::World.

Here is the call graph for this function:

Here is the caller graph for this function:

std::string MWWorld::World::getMonthName ( int  month = -1) const
overridevirtual

Return name of month (-1: current month)

Implements MWBase::World.

Here is the call graph for this function:

osg::Vec2f MWWorld::World::getNorthVector ( const CellStore cell)
overridevirtual

get north vector for given interior cell

Implements MWBase::World.

Here is the call graph for this function:

MWWorld::Player & MWWorld::World::getPlayer ( )
overridevirtual

Implements MWBase::World.

bool MWWorld::World::getPlayerCollidingWith ( const MWWorld::ConstPtr object)
overridevirtual
Returns
true if the player is colliding with object

Implements MWBase::World.

Here is the call graph for this function:

MWWorld::Ptr MWWorld::World::getPlayerPtr ( )
overridevirtual

Implements MWBase::World.

Here is the caller graph for this function:

bool MWWorld::World::getPlayerStandingOn ( const MWWorld::ConstPtr object)
overridevirtual
Returns
true if the player is standing on object

Implements MWBase::World.

Here is the call graph for this function:

Ptr MWWorld::World::getPtr ( const std::string &  name,
bool  activeOnly 
)
overridevirtual

Return a pointer to a liveCellRef with the given name.

Parameters
activeOnlydo non search inactive cells.

Implements MWBase::World.

Here is the call graph for this function:

bool MWWorld::World::getScriptsEnabled ( ) const
overridevirtual

Implements MWBase::World.

int MWWorld::World::getSecundaPhase ( ) const
overridevirtual

Implements MWBase::World.

const MWWorld::ESMStore & MWWorld::World::getStore ( ) const
overridevirtual

Implements MWBase::World.

Here is the caller graph for this function:

osg::Vec3f MWWorld::World::getStormDirection ( ) const
overridevirtual
See Also
MWWorld::WeatherManager::getStormDirection

Implements MWBase::World.

Here is the call graph for this function:

float MWWorld::World::getTerrainHeightAt ( const osg::Vec3f &  worldPos) const
overridevirtual

Return terrain height at worldPos position.

Implements MWBase::World.

Here is the caller graph for this function:

float MWWorld::World::getTimeScaleFactor ( ) const
overridevirtual

Implements MWBase::World.

Here is the call graph for this function:

TimeStamp MWWorld::World::getTimeStamp ( ) const
overridevirtual

Return current in-game time stamp.

Implements MWBase::World.

Here is the call graph for this function:

Here is the caller graph for this function:

float MWWorld::World::getWindSpeed ( )
overridevirtual

Implements MWBase::World.

Here is the call graph for this function:

int MWWorld::World::getYear ( ) const
overridevirtual

Implements MWBase::World.

Here is the call graph for this function:

void MWWorld::World::goToJail ( )
overridevirtual

Implements MWBase::World.

Here is the call graph for this function:

Here is the caller graph for this function:

bool MWWorld::World::hasCellChanged ( ) const
overridevirtual

Has the set of active cells changed, since the last frame?

Implements MWBase::World.

void MWWorld::World::hurtCollidingActors ( const MWWorld::ConstPtr object,
float  dmgPerSecond 
)
overridevirtual

Apply a health difference to any actors colliding with object. To hurt actors, healthPerSecond should be a positive value. For a negative value, actors will be healed.

Implements MWBase::World.

Here is the call graph for this function:

void MWWorld::World::hurtStandingActors ( const MWWorld::ConstPtr object,
float  dmgPerSecond 
)
overridevirtual

Apply a health difference to any actors standing on object. To hurt actors, healthPerSecond should be a positive value. For a negative value, actors will be healed.

Implements MWBase::World.

Here is the call graph for this function:

void MWWorld::World::indexToPosition ( int  cellX,
int  cellY,
float &  x,
float &  y,
bool  centre = false 
) const
overridevirtual

Convert cell numbers to position.

Implements MWBase::World.

Here is the caller graph for this function:

bool MWWorld::World::isCellExterior ( ) const
overridevirtual

Implements MWBase::World.

Here is the call graph for this function:

Here is the caller graph for this function:

bool MWWorld::World::isCellQuasiExterior ( ) const
overridevirtual

Implements MWBase::World.

Here is the call graph for this function:

Here is the caller graph for this function:

bool MWWorld::World::isFirstPerson ( ) const
overridevirtual

Implements MWBase::World.

Here is the caller graph for this function:

bool MWWorld::World::isFlying ( const MWWorld::Ptr ptr) const
overridevirtual

Implements MWBase::World.

Here is the call graph for this function:

Here is the caller graph for this function:

bool MWWorld::World::isInStorm ( ) const
overridevirtual
See Also
MWWorld::WeatherManager::isInStorm

Implements MWBase::World.

Here is the call graph for this function:

bool MWWorld::World::isLevitationEnabled ( ) const
overridevirtual

Returns true if levitation spell effect is allowed.

Implements MWBase::World.

Here is the caller graph for this function:

bool MWWorld::World::isOnGround ( const MWWorld::Ptr ptr) const
overridevirtual

Implements MWBase::World.

bool MWWorld::World::isPlayerInJail ( ) const
overridevirtual

Implements MWBase::World.

bool MWWorld::World::isPlayerTraveling ( ) const
overridevirtual

Implements MWBase::World.

bool MWWorld::World::isSlowFalling ( const MWWorld::Ptr ptr) const
overridevirtual

Implements MWBase::World.

Here is the call graph for this function:

bool MWWorld::World::isSubmerged ( const MWWorld::ConstPtr object) const
overridevirtual

Is the head of the creature underwater?

Implements MWBase::World.

Here is the call graph for this function:

bool MWWorld::World::isSwimming ( const MWWorld::ConstPtr object) const
overridevirtual

Implements MWBase::World.

Here is the call graph for this function:

Here is the caller graph for this function:

bool MWWorld::World::isTeleportingEnabled ( ) const
overridevirtual

Returns true if teleport spell effects are allowed.

Implements MWBase::World.

bool MWWorld::World::isUnderwater ( const MWWorld::CellStore cell,
const osg::Vec3f &  pos 
) const
overridevirtual

Implements MWBase::World.

Here is the call graph for this function:

Here is the caller graph for this function:

bool MWWorld::World::isUnderwater ( const MWWorld::ConstPtr object,
const float  heightRatio 
) const
overridevirtual

Implements MWBase::World.

Here is the call graph for this function:

bool MWWorld::World::isWading ( const MWWorld::ConstPtr object) const
overridevirtual

Implements MWBase::World.

Here is the call graph for this function:

bool MWWorld::World::isWalkingOnWater ( const MWWorld::ConstPtr actor) const
overridevirtual

Implements MWBase::World.

Here is the call graph for this function:

Here is the caller graph for this function:

bool MWWorld::World::isWaterWalkingCastableOnTarget ( const MWWorld::ConstPtr target) const
overridevirtual

Implements MWBase::World.

Here is the call graph for this function:

void MWWorld::World::launchMagicBolt ( const std::string &  spellId,
const MWWorld::Ptr caster,
const osg::Vec3f &  fallbackDirection 
)
overridevirtual

Implements MWBase::World.

void MWWorld::World::launchProjectile ( MWWorld::Ptr actor,
MWWorld::Ptr projectile,
const osg::Vec3f &  worldPos,
const osg::Quat &  orient,
MWWorld::Ptr bow,
float  speed,
float  attackStrength 
)
overridevirtual

Implements MWBase::World.

Here is the call graph for this function:

void MWWorld::World::listDetectedReferences ( const MWWorld::Ptr ptr,
std::vector< MWWorld::Ptr > &  out,
DetectionType  type 
)
overridevirtual

List all references (filtered by type) detected by ptr. The range is determined by the current magnitude of the "Detect X" magic effect belonging to type.

Note
This also works for references in containers.

Implements MWBase::World.

Here is the call graph for this function:

void MWWorld::World::loadContentFiles ( const Files::Collections fileCollections,
const std::vector< std::string > &  content,
ContentLoader contentLoader 
)
private

loadContentFiles - Loads content files (esm,esp,omwgame,omwaddon)

Parameters
fileCollections-Container which holds content file names and their paths
content- Container which holds content file names
contentLoader-

Here is the call graph for this function:

Here is the caller graph for this function:

void MWWorld::World::markCellAsUnchanged ( )
overridevirtual

Implements MWBase::World.

void MWWorld::World::modRegion ( const std::string &  regionid,
const std::vector< char > &  chances 
)
overridevirtual

Implements MWBase::World.

MWWorld::Ptr MWWorld::World::moveObject ( const Ptr ptr,
float  x,
float  y,
float  z 
)
overridevirtual
Returns
an updated Ptr in case the Ptr's cell changes

Implements MWBase::World.

Here is the call graph for this function:

Here is the caller graph for this function:

MWWorld::Ptr MWWorld::World::moveObject ( const Ptr ptr,
CellStore newCell,
float  x,
float  y,
float  z,
bool  movePhysics = true 
)
overridevirtual
Returns
an updated Ptr

Implements MWBase::World.

Here is the call graph for this function:

MWWorld::Ptr MWWorld::World::moveObjectImp ( const Ptr ptr,
float  x,
float  y,
float  z,
bool  movePhysics = true 
)
private
Returns
an updated Ptr in case the Ptr's cell changes

Here is the call graph for this function:

Here is the caller graph for this function:

World& MWWorld::World::operator= ( const World )
private
void MWWorld::World::PCDropped ( const Ptr item)
private

Here is the call graph for this function:

Here is the caller graph for this function:

MWWorld::Ptr MWWorld::World::placeObject ( const MWWorld::ConstPtr ptr,
MWWorld::CellStore cell,
ESM::Position  pos 
)
overridevirtual

Place an object. Makes a copy of the Ptr.

Implements MWBase::World.

Here is the call graph for this function:

MWWorld::Ptr MWWorld::World::placeObject ( const MWWorld::ConstPtr object,
float  cursorX,
float  cursorY,
int  amount 
)
overridevirtual

copy and place an object into the gameworld at the specified cursor position

Parameters
object
cursorX (relative 0-1)
cursorY (relative 0-1)
numberof objects to place

Implements MWBase::World.

Here is the call graph for this function:

void MWWorld::World::positionToIndex ( float  x,
float  y,
int cellX,
int cellY 
) const
overridevirtual

Convert position to cell numbers.

Implements MWBase::World.

Here is the caller graph for this function:

void MWWorld::World::preloadEffects ( const ESM::EffectList effectList)
overridevirtual

Preload VFX associated with this effect list.

Implements MWBase::World.

Here is the call graph for this function:

Here is the caller graph for this function:

void MWWorld::World::preloadSpells ( )
private

Here is the call graph for this function:

Here is the caller graph for this function:

void MWWorld::World::processChangedSettings ( const Settings::CategorySettingVector settings)
override
void MWWorld::World::processDoors ( float  duration)
private

Run physics simulation and modify world accordingly.

Todo:
should use convexSweepTest here

Here is the call graph for this function:

Here is the caller graph for this function:

void MWWorld::World::queueMovement ( const Ptr ptr,
const osg::Vec3f &  velocity 
)
overridevirtual

Queues movement for ptr (in local space), to be applied in the next call to doPhysics.

Implements MWBase::World.

void MWWorld::World::readRecord ( ESM::ESMReader reader,
uint32_t  type,
const std::map< int, int > &  contentFileMap 
)
overridevirtual

Implements MWBase::World.

Here is the call graph for this function:

void MWWorld::World::reattachPlayerCamera ( )
overridevirtual

Implements MWBase::World.

Here is the call graph for this function:

void MWWorld::World::removeContainerScripts ( const Ptr reference)
overridevirtual

Implements MWBase::World.

Here is the call graph for this function:

Here is the caller graph for this function:

void MWWorld::World::removeRefScript ( MWWorld::RefData ref)
overridevirtual

Implements MWBase::World.

Here is the call graph for this function:

void MWWorld::World::renderPlayer ( )
overridevirtual

Implements MWBase::World.

Here is the call graph for this function:

Here is the caller graph for this function:

void MWWorld::World::resetActors ( )
overridevirtual

Resets all actors in the current active cells to their original location within that cell.

Implements MWBase::World.

Here is the call graph for this function:

void MWWorld::World::rest ( )
overridevirtual

Implements MWBase::World.

Here is the call graph for this function:

void MWWorld::World::rotateObject ( const Ptr ptr,
float  x,
float  y,
float  z,
bool  adjust = false 
)
overridevirtual

World rotates object, uses radians

Note
Rotations via this method use a different rotation order than the initial rotations in the CS. This could be considered a bug, but is needed for MW compatibility.
Parameters
adjustindicates rotation should be set or adjusted

Implements MWBase::World.

Here is the call graph for this function:

Here is the caller graph for this function:

void MWWorld::World::rotateObjectImp ( const Ptr ptr,
const osg::Vec3f &  rot,
bool  adjust 
)
private

Here is the call graph for this function:

Here is the caller graph for this function:

void MWWorld::World::rotateWorldObject ( const MWWorld::Ptr ptr,
osg::Quat  rotate 
)
overridevirtual

Implements MWBase::World.

Here is the call graph for this function:

MWWorld::Ptr MWWorld::World::safePlaceObject ( const MWWorld::ConstPtr ptr,
const MWWorld::ConstPtr referenceObject,
MWWorld::CellStore referenceCell,
int  direction,
float  distance 
)
overridevirtual

Place an object in a safe place next to referenceObject. direction and distance specify the wanted placement relative to referenceObject (but the object may be placed somewhere else if the wanted location is obstructed).

Implements MWBase::World.

Here is the call graph for this function:

Here is the caller graph for this function:

void MWWorld::World::scaleObject ( const Ptr ptr,
float  scale 
)
overridevirtual

Implements MWBase::World.

Here is the call graph for this function:

Here is the caller graph for this function:

void MWWorld::World::screenshot ( osg::Image *  image,
int  w,
int  h 
)
overridevirtual
Todo:
this does not belong here

Implements MWBase::World.

bool MWWorld::World::screenshot360 ( osg::Image *  image,
std::string  settingStr 
)
overridevirtual

Implements MWBase::World.

Ptr MWWorld::World::searchPtr ( const std::string &  name,
bool  activeOnly 
)
overridevirtual

Return a pointer to a liveCellRef with the given name.

Parameters
activeOnlydo non search inactive cells.

Implements MWBase::World.

Here is the call graph for this function:

Here is the caller graph for this function:

Ptr MWWorld::World::searchPtrViaActorId ( int  actorId)
overridevirtual

Search is limited to the active cells.

Implements MWBase::World.

Here is the call graph for this function:

void MWWorld::World::setCameraDistance ( float  dist,
bool  adjust = false,
bool  override = true 
)
overridevirtual

Implements MWBase::World.

void MWWorld::World::setDay ( int  day)
overridevirtual

Set in-game time day.

Implements MWBase::World.

Here is the call graph for this function:

Here is the caller graph for this function:

void MWWorld::World::setGlobalFloat ( const std::string &  name,
float  value 
)
overridevirtual

Set value independently from real type.

Implements MWBase::World.

Here is the call graph for this function:

void MWWorld::World::setGlobalInt ( const std::string &  name,
int  value 
)
overridevirtual

Set value independently from real type.

Implements MWBase::World.

Here is the call graph for this function:

void MWWorld::World::setHour ( double  hour)
overridevirtual

Set in-game time hour.

Implements MWBase::World.

Here is the call graph for this function:

Here is the caller graph for this function:

void MWWorld::World::setMonth ( int  month)
overridevirtual

Set in-game time month.

Implements MWBase::World.

Here is the call graph for this function:

Here is the caller graph for this function:

void MWWorld::World::setMoonColour ( bool  red)
overridevirtual

Implements MWBase::World.

void MWWorld::World::setPlayerTraveling ( bool  traveling)
overridevirtual

Implements MWBase::World.

void MWWorld::World::setupPlayer ( )
overridevirtual

Implements MWBase::World.

Here is the call graph for this function:

Here is the caller graph for this function:

void MWWorld::World::setWaterHeight ( const float  height)
overridevirtual

Implements MWBase::World.

void MWWorld::World::spawnBloodEffect ( const MWWorld::Ptr ptr,
const osg::Vec3f &  worldPosition 
)
overridevirtual

Spawn a blood effect for ptr at worldPosition.

Implements MWBase::World.

Here is the call graph for this function:

void MWWorld::World::spawnEffect ( const std::string &  model,
const std::string &  textureOverride,
const osg::Vec3f &  worldPos,
float  scale = 1.f,
bool  isMagicVFX = true 
)
overridevirtual

Implements MWBase::World.

void MWWorld::World::spawnRandomCreature ( const std::string &  creatureList)
overridevirtual

Spawn a random creature from a levelled list next to the player.

Implements MWBase::World.

Here is the call graph for this function:

void MWWorld::World::startNewGame ( bool  bypass)
overridevirtual
Parameters
bypassBypass regular game start.

Implements MWBase::World.

Here is the call graph for this function:

bool MWWorld::World::startSpellCast ( const MWWorld::Ptr actor)
overridevirtual

startSpellCast attempt to start casting a spell. Might fail immediately if conditions are not met.

Parameters
actor
Returns
true if the spell can be casted (i.e. the animation should start)

Implements MWBase::World.

Here is the call graph for this function:

void MWWorld::World::teleportToClosestMarker ( const MWWorld::Ptr ptr,
const std::string &  id 
)
overridevirtual

Teleports ptr to the closest reference of id (e.g. DivineMarker, PrisonMarker, TempleMarker)

Note
id must be lower case

Implements MWBase::World.

Here is the call graph for this function:

bool MWWorld::World::toggleBorders ( )
overridevirtual

Implements MWBase::World.

bool MWWorld::World::toggleCollisionMode ( )
overridevirtual

Toggle collision mode for player. If disabled player object should ignore collisions and gravity.

Returns
Resulting mode

Implements MWBase::World.

bool MWWorld::World::toggleGodMode ( )
overridevirtual

Implements MWBase::World.

void MWWorld::World::togglePlayerLooking ( bool  enable)
overridevirtual

Implements MWBase::World.

void MWWorld::World::togglePOV ( )
overridevirtual

Implements MWBase::World.

void MWWorld::World::togglePreviewMode ( bool  enable)
overridevirtual

Implements MWBase::World.

bool MWWorld::World::toggleRenderMode ( MWRender::RenderMode  mode)
overridevirtual

Toggle a render mode.

Returns
Resulting mode

Implements MWBase::World.

bool MWWorld::World::toggleScripts ( )
overridevirtual

Implements MWBase::World.

bool MWWorld::World::toggleSky ( )
overridevirtual
Returns
Resulting mode

Implements MWBase::World.

bool MWWorld::World::toggleVanityMode ( bool  enable)
overridevirtual

Implements MWBase::World.

bool MWWorld::World::toggleWater ( )
overridevirtual

Implements MWBase::World.

bool MWWorld::World::toggleWorld ( )
overridevirtual

Implements MWBase::World.

void MWWorld::World::undeleteObject ( const Ptr ptr)
overridevirtual

Implements MWBase::World.

Here is the call graph for this function:

void MWWorld::World::update ( float  duration,
bool  paused 
)
overridevirtual

Implements MWBase::World.

Here is the call graph for this function:

Here is the caller graph for this function:

void MWWorld::World::updateDialogueGlobals ( )
overridevirtual

Update the value of some globals according to the world state, which may be used by dialogue entries. This should be called when initiating a dialogue.

Implements MWBase::World.

Here is the call graph for this function:

void MWWorld::World::updatePlayer ( )
private

Here is the call graph for this function:

Here is the caller graph for this function:

void MWWorld::World::updateSoundListener ( )
private

Here is the call graph for this function:

Here is the caller graph for this function:

void MWWorld::World::updateWeather ( float  duration,
bool  paused = false 
)
private

Here is the call graph for this function:

Here is the caller graph for this function:

void MWWorld::World::updateWindowManager ( )
overridevirtual

Implements MWBase::World.

Here is the call graph for this function:

void MWWorld::World::useDeathCamera ( )
overridevirtual

Implements MWBase::World.

bool MWWorld::World::useTorches ( ) const
overridevirtual

Implements MWBase::World.

Here is the call graph for this function:

bool MWWorld::World::vanityRotateCamera ( float *  rot)
overridevirtual

Implements MWBase::World.

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

Implements MWBase::World.

Here is the call graph for this function:

Member Data Documentation

int MWWorld::World::mActivationDistanceOverride
private
Cells MWWorld::World::mCells
private
std::vector<std::string> MWWorld::World::mContentFiles
private
std::string MWWorld::World::mCurrentWorldSpace
private
ESM::Variant* MWWorld::World::mDay
private
int MWWorld::World::mDaysInPrison
private
ESM::Variant* MWWorld::World::mDaysPassed
private
float MWWorld::World::mDistanceToFacedObject
private
std::map<MWWorld::Ptr, int> MWWorld::World::mDoorStates
private

only holds doors that are currently moving. 1 = opening, 2 = closing

std::vector<ESM::ESMReader> MWWorld::World::mEsm
private
Fallback::Map MWWorld::World::mFallback
private
ESM::Variant* MWWorld::World::mGameHour
private
MWWorld::Globals MWWorld::World::mGlobalVariables
private
bool MWWorld::World::mGodMode
private
bool MWWorld::World::mGoToJail
private
bool MWWorld::World::mLevitationEnabled
private
LocalScripts MWWorld::World::mLocalScripts
private
ESM::Variant* MWWorld::World::mMonth
private
std::unique_ptr<MWPhysics::PhysicsSystem> MWWorld::World::mPhysics
private
std::unique_ptr<MWWorld::Player> MWWorld::World::mPlayer
private
bool MWWorld::World::mPlayerInJail
private
bool MWWorld::World::mPlayerTraveling
private
std::shared_ptr<ProjectileManager> MWWorld::World::mProjectileManager
private
std::unique_ptr<MWRender::RenderingManager> MWWorld::World::mRendering
private
Resource::ResourceSystem* MWWorld::World::mResourceSystem
private
bool MWWorld::World::mScriptsEnabled
private
bool MWWorld::World::mSky
private
float MWWorld::World::mSpellPreloadTimer
private
std::string MWWorld::World::mStartCell
private
std::string MWWorld::World::mStartupScript
private
MWWorld::ESMStore MWWorld::World::mStore
private
float MWWorld::World::mSwimHeightScale
private
bool MWWorld::World::mTeleportEnabled
private
ESM::Variant* MWWorld::World::mTimeScale
private
std::string MWWorld::World::mUserDataPath
private
std::unique_ptr<MWWorld::WeatherManager> MWWorld::World::mWeatherManager
private
std::unique_ptr<MWWorld::Scene> MWWorld::World::mWorldScene
private
ESM::Variant* MWWorld::World::mYear
private

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