mirror of
https://gitlab.com/OpenMW/openmw.git
synced 2025-02-28 12:40:06 +00:00
Merge branch 'free_range_containers' into 'master'
FEAT: Add organic/respawning flags to containers (Close #8038) Closes #8038 See merge request OpenMW/openmw!4205
This commit is contained in:
commit
4da35c7e7f
@ -246,6 +246,7 @@
|
|||||||
Feature #7964: Add Lua read access to MW Dialogue records
|
Feature #7964: Add Lua read access to MW Dialogue records
|
||||||
Feature #7971: Make save's Time Played value display hours instead of days
|
Feature #7971: Make save's Time Played value display hours instead of days
|
||||||
Feature #7985: Support dark mode on Windows
|
Feature #7985: Support dark mode on Windows
|
||||||
|
Feature #8034: (Lua) Containers should have respawning/organic flags
|
||||||
Task #5896: Do not use deprecated MyGUI properties
|
Task #5896: Do not use deprecated MyGUI properties
|
||||||
Task #6085: Replace boost::filesystem with std::filesystem
|
Task #6085: Replace boost::filesystem with std::filesystem
|
||||||
Task #6149: Dehardcode Lua API_REVISION
|
Task #6149: Dehardcode Lua API_REVISION
|
||||||
|
@ -54,5 +54,9 @@ namespace MWLua
|
|||||||
record["mwscript"] = sol::readonly_property(
|
record["mwscript"] = sol::readonly_property(
|
||||||
[](const ESM::Container& rec) -> std::string { return rec.mScript.serializeText(); });
|
[](const ESM::Container& rec) -> std::string { return rec.mScript.serializeText(); });
|
||||||
record["weight"] = sol::readonly_property([](const ESM::Container& rec) -> float { return rec.mWeight; });
|
record["weight"] = sol::readonly_property([](const ESM::Container& rec) -> float { return rec.mWeight; });
|
||||||
|
record["isOrganic"] = sol::readonly_property(
|
||||||
|
[](const ESM::Container& rec) -> bool { return rec.mFlags & ESM::Container::Organic; });
|
||||||
|
record["isRespawning"] = sol::readonly_property(
|
||||||
|
[](const ESM::Container& rec) -> bool { return rec.mFlags & ESM::Container::Respawn; });
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -2109,7 +2109,8 @@
|
|||||||
-- @field #string model VFS path to the model
|
-- @field #string model VFS path to the model
|
||||||
-- @field #string mwscript MWScript on this container (can be empty)
|
-- @field #string mwscript MWScript on this container (can be empty)
|
||||||
-- @field #number weight capacity of this container
|
-- @field #number weight capacity of this container
|
||||||
|
-- @field #boolean isOrganic Whether items can be placed in the container
|
||||||
|
-- @field #boolean isRespawning Whether the container respawns its contents
|
||||||
|
|
||||||
--------------------------------------------------------------------------------
|
--------------------------------------------------------------------------------
|
||||||
-- @{#Door} functions
|
-- @{#Door} functions
|
||||||
|
Loading…
x
Reference in New Issue
Block a user