mirror of
https://github.com/OpenMW/openmw.git
synced 2025-12-01 23:04:30 +00:00
less preprocessed code lines
This commit is contained in:
parent
d20a56517b
commit
27adbf0cde
6 changed files with 10 additions and 8 deletions
|
|
@ -16,13 +16,13 @@
|
||||||
#include "../mwworld/globalvariablename.hpp"
|
#include "../mwworld/globalvariablename.hpp"
|
||||||
#include "../mwworld/ptr.hpp"
|
#include "../mwworld/ptr.hpp"
|
||||||
#include "../mwworld/spellcaststate.hpp"
|
#include "../mwworld/spellcaststate.hpp"
|
||||||
#include "../mwworld/weather.hpp"
|
|
||||||
|
|
||||||
#include "../mwrender/rendermode.hpp"
|
#include "../mwrender/rendermode.hpp"
|
||||||
|
|
||||||
namespace osg
|
namespace osg
|
||||||
{
|
{
|
||||||
class Vec3f;
|
class Vec3f;
|
||||||
|
class Vec4f;
|
||||||
class Matrixf;
|
class Matrixf;
|
||||||
class Quat;
|
class Quat;
|
||||||
class Image;
|
class Image;
|
||||||
|
|
@ -94,6 +94,7 @@ namespace MWWorld
|
||||||
class RefData;
|
class RefData;
|
||||||
class Cell;
|
class Cell;
|
||||||
class DateTimeManager;
|
class DateTimeManager;
|
||||||
|
class Weather;
|
||||||
|
|
||||||
typedef std::vector<std::pair<MWWorld::Ptr, MWMechanics::Movement>> PtrMovementList;
|
typedef std::vector<std::pair<MWWorld::Ptr, MWMechanics::Movement>> PtrMovementList;
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -18,6 +18,7 @@
|
||||||
#include "../mwworld/class.hpp"
|
#include "../mwworld/class.hpp"
|
||||||
#include "../mwworld/esmstore.hpp"
|
#include "../mwworld/esmstore.hpp"
|
||||||
#include "../mwworld/inventorystore.hpp"
|
#include "../mwworld/inventorystore.hpp"
|
||||||
|
#include "../mwworld/weather.hpp"
|
||||||
|
|
||||||
#include "../mwmechanics/actorutil.hpp"
|
#include "../mwmechanics/actorutil.hpp"
|
||||||
#include "../mwmechanics/creaturestats.hpp"
|
#include "../mwmechanics/creaturestats.hpp"
|
||||||
|
|
|
||||||
|
|
@ -8,6 +8,8 @@
|
||||||
#include "../mwworld/esmstore.hpp"
|
#include "../mwworld/esmstore.hpp"
|
||||||
#include "../mwworld/weather.hpp"
|
#include "../mwworld/weather.hpp"
|
||||||
|
|
||||||
|
#include "context.hpp"
|
||||||
|
|
||||||
namespace
|
namespace
|
||||||
{
|
{
|
||||||
class WeatherStore
|
class WeatherStore
|
||||||
|
|
@ -123,11 +125,8 @@ namespace MWLua
|
||||||
|
|
||||||
api["changeWeather"] = [](std::string_view regionId, const MWWorld::Weather& weather) {
|
api["changeWeather"] = [](std::string_view regionId, const MWWorld::Weather& weather) {
|
||||||
ESM::RefId region = ESM::RefId::deserializeText(regionId);
|
ESM::RefId region = ESM::RefId::deserializeText(regionId);
|
||||||
const ESM::Region* reg = MWBase::Environment::get().getESMStore()->get<ESM::Region>().search(region);
|
MWBase::Environment::get().getESMStore()->get<ESM::Region>().find(region);
|
||||||
if (reg)
|
|
||||||
MWBase::Environment::get().getWorld()->changeWeather(region, weather.mId);
|
MWBase::Environment::get().getWorld()->changeWeather(region, weather.mId);
|
||||||
else
|
|
||||||
throw std::runtime_error("Region not found");
|
|
||||||
};
|
};
|
||||||
|
|
||||||
sol::usertype<WeatherStore> storeT = lua.new_usertype<WeatherStore>("WeatherWorldStore");
|
sol::usertype<WeatherStore> storeT = lua.new_usertype<WeatherStore>("WeatherWorldStore");
|
||||||
|
|
|
||||||
|
|
@ -3,10 +3,9 @@
|
||||||
|
|
||||||
#include <sol/forward.hpp>
|
#include <sol/forward.hpp>
|
||||||
|
|
||||||
#include "context.hpp"
|
|
||||||
|
|
||||||
namespace MWLua
|
namespace MWLua
|
||||||
{
|
{
|
||||||
|
struct Context;
|
||||||
|
|
||||||
sol::table initCoreWeatherBindings(const Context&);
|
sol::table initCoreWeatherBindings(const Context&);
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -60,6 +60,7 @@
|
||||||
#include "../mwworld/class.hpp"
|
#include "../mwworld/class.hpp"
|
||||||
#include "../mwworld/groundcoverstore.hpp"
|
#include "../mwworld/groundcoverstore.hpp"
|
||||||
#include "../mwworld/scene.hpp"
|
#include "../mwworld/scene.hpp"
|
||||||
|
#include "../mwworld/weather.hpp"
|
||||||
|
|
||||||
#include "../mwgui/postprocessorhud.hpp"
|
#include "../mwgui/postprocessorhud.hpp"
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -14,6 +14,7 @@
|
||||||
#include "../mwbase/world.hpp"
|
#include "../mwbase/world.hpp"
|
||||||
|
|
||||||
#include "../mwworld/esmstore.hpp"
|
#include "../mwworld/esmstore.hpp"
|
||||||
|
#include "../mwworld/weather.hpp"
|
||||||
|
|
||||||
namespace MWScript
|
namespace MWScript
|
||||||
{
|
{
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue