OpenMW
|
00001 #ifndef OPENMW_ESM_REGN_H 00002 #define OPENMW_ESM_REGN_H 00003 00004 #include <string> 00005 #include <vector> 00006 00007 #include "esmcommon.hpp" 00008 00009 namespace ESM 00010 { 00011 00012 class ESMReader; 00013 class ESMWriter; 00014 00015 /* 00016 * Region data 00017 */ 00018 00019 struct Region 00020 { 00021 static unsigned int sRecordId; 00022 00023 #pragma pack(push) 00024 #pragma pack(1) 00025 struct WEATstruct 00026 { 00027 // I guess these are probabilities 00028 char mClear, mCloudy, mFoggy, mOvercast, mRain, mThunder, mAsh, mBlight, 00029 // Unknown weather, probably snow and something. Only 00030 // present in file version 1.3. 00031 mA, mB; 00032 }; // 10 bytes 00033 00034 // Reference to a sound that is played randomly in this region 00035 struct SoundRef 00036 { 00037 NAME32 mSound; 00038 char mChance; 00039 }; // 33 bytes 00040 #pragma pack(pop) 00041 00042 WEATstruct mData; 00043 int mMapColor; // RGBA 00044 00045 // sleepList refers to a eveled list of creatures you can meet if 00046 // you sleep outside in this region. 00047 std::string mId, mName, mSleepList; 00048 00049 std::vector<SoundRef> mSoundList; 00050 00051 void load(ESMReader &esm); 00052 void save(ESMWriter &esm) const; 00053 00054 void blank(); 00056 }; 00057 } 00058 #endif