1
0
mirror of https://gitlab.com/OpenMW/openmw.git synced 2025-01-30 03:32:36 +00:00

3856 Commits

Author SHA1 Message Date
Andrei Kortunov
38042fd7a2 Init missing variables 2022-07-05 17:47:52 +04:00
elsid
bef15edf0b
Remove redundant ostream, istream, iostream and sstream includes
* Replace by std::to_string and operator+ where possible.
* Move the code requiring to include <sstream> from .hpp to .cpp files.
2022-07-05 01:41:28 +02:00
elsid
20c15b30de
Move getLuaType out of MWWorld::PtrBase
This function is used only for Lua related code and don't need to be present
everywhere ptr.hpp is included.
2022-07-05 00:53:19 +02:00
elsid
4613840914
Use single implementation to check whether marker is hidden 2022-07-05 00:36:37 +02:00
elsid
1b117af5e1
Use descriptive names for range elements
iter does not describe the nature of the object. Range-based for loop provides
elements of the iterator range, not iterators.
2022-07-04 21:03:45 +02:00
jvoisin
498a835b77 Merge branch 'coverity' into 'master'
Fix some Coverity issues

See merge request OpenMW/openmw!2082
2022-07-03 16:29:05 +00:00
Cody Glassman
051832d7ae [Lua] Set simulation time scale 2022-07-03 12:51:28 +00:00
Andrei Kortunov
14b5674d32 Init missing data members 2022-07-03 15:44:50 +04:00
Andrei Kortunov
aa349f2ed9 Initialize some missing variables 2022-07-03 15:44:50 +04:00
elsid
7e6c13630a Use target_precompile_headers for the most expensive headers 2022-07-01 14:05:17 +00:00
elsid
ce263af393
Use existing functions and objects to call correctMeshPath etc
Remove WindowManager wrappers.

It's not safe to use WindowManager in all places and it's not required.
Environment stores resource system providing VFS required to call these
functions. In the case of ObjectPaging it's available from the member variable.
Also ObjectPaging::createChunk may access WindowManager when it's already
destructed when exiting the game because it's destructed before CellPreloader
finishes all background jobs. Engine::mResourceSystem is destructed after all
other systems so it's safe to use it.
2022-06-29 00:58:49 +02:00
jvoisin
3403ea1d9e Merge branch 'FixUBOnDoubleMove' into 'master'
Avoid double move when an area with same coordinates already exists

See merge request OpenMW/openmw!2059
2022-06-27 16:28:17 +00:00
psi29a
a814d11a39 Merge branch 'move_left_shift_to_cpp' into 'master'
Move std::ostream& operator<< to .cpp

See merge request OpenMW/openmw!2058
2022-06-27 09:24:01 +00:00
elsid
1a5932a669
Move std::ostream& operator<< to .cpp 2022-06-26 22:43:53 +02:00
elsid
ffd1bd30ef
Remove redundant includes from groundcoverstore.hpp 2022-06-26 22:28:10 +02:00
Cédric Mocquillon
cbf48b4382 Avoid double move when an area with same coordinates already exists 2022-06-26 21:45:42 +02:00
elsid
fdf6e58ea3
Split apps/openmw/mwmechanics/actorutil.hpp 2022-06-26 16:42:29 +02:00
psi29a
ede09309a6 Merge branch 'groundcover_progress' into 'master'
Show groundcover loading progress

See merge request OpenMW/openmw!1978
2022-06-22 13:02:22 +00:00
elsid
1a12c453d6
Support different agent collision shape type for pathfinding
Actors may have different collision shapes. Currently there are axis-aligned
bounding boxes and rotating bounding boxes. With AABB it's required to use
bounding cylinder for navmesh agent to avoid providing paths where actor can't
pass. But for rotating bounding boxes cylinder with diameter equal to the front
face width should be used to not reduce of available paths. For example rats
have rotating bounding box as collision shape because of the difference between
front and side faces width.

* Add agent bounds to navmesh tile db cache key. This is required to distinguish
  tiles for agents with different bounds.
* Increase navmesh version because navmesh tile db cache key and data has changed.
* Move navmesh version to the code to avoid misconfiguration by users.
* Fix all places where wrong half extents were used for pathfinding.
2022-06-21 12:57:32 +02:00
Petr Mikheev
e466a812d8 Merge branch 'lua_consume' into 'master'
Refactor consuming mechanics, improve Lua onConsume handler

See merge request OpenMW/openmw!1848
2022-06-20 12:12:50 +00:00
Evil Eye
aa2fab8db5 Enable collision for postponed objects when any object is disabled 2022-06-19 20:16:31 +02:00
uramer
c1f8d7c20a Make comment style consistently inconsistent 2022-06-19 17:31:18 +02:00
uramer
c3c48f21d7 Consolidate item consumption code 2022-06-18 11:13:54 +02:00
Alexei Kotov
a5d8286cf2 Reject models that don't have grass\ prefix from groundcover cache 2022-06-16 16:26:25 +03:00
uramer
fd7965d77f Use correctMeshPath instead of string constants 2022-06-12 11:30:29 +02:00
psi29a
9c1970dce4 Merge branch 'lua_esm' into 'master'
Advanced Lua scripts configuration in omwaddon

See merge request OpenMW/openmw!1947
2022-06-11 18:48:23 +00:00
psi29a
8bce0a1bcf Merge branch 'classy' into 'master'
Replace empty NPC class with fallback

Closes #6799

See merge request OpenMW/openmw!1982
2022-06-06 18:18:20 +00:00
Evil Eye
f41e46db64 Replace empty NPC class with fallback 2022-06-06 10:59:26 +02:00
elsid
f8eafe0dfd
Fix checking whether content file is master file 2022-06-06 00:57:44 +02:00
elsid
9c93de65be
Show groundcover loading progress 2022-06-05 22:21:12 +02:00
psi29a
c7449dc272 Merge branch 'bullet_includes' into 'master'
Clean up bullet includes

See merge request OpenMW/openmw!1974
2022-06-05 10:17:57 +00:00
Petr Mikheev
a70d5831c5 Lua scripts configuration in omwaddon 2022-06-05 01:36:39 +02:00
jvoisin
72a6d1f69f Clean up bullet includes 2022-06-04 20:15:10 +02:00
elsid
3affe9913f
Limit the number of simultaneously open not actively used content files
Use LRU cache for ESMReaders. When cache capacity is reached close least
recently used ESMReader. Remember the file name if a reader was open. Once the
reader requested again open the file if there is stored name for it. Put
released ESMReader to the back of the free items list. Close ESMReader's from
the front of the free items list.

Cached item can be used only by one client at the same time. If the same item is
requested twice exception is thrown. This should never happen in practice. If
this happens need to fix the client logic.

It's allowed to go over the capacity limit when requesting different readers.
Ideally this should never happen but there will be system error anyway
signalizing about too many open files. Need to fix client logic in this case.

All places that were using a vector of ESMReaders now using the cache. Cache is
local for each use case and there is no need for a thread safety.
2022-06-03 01:29:03 +02:00
psi29a
af82140dda Merge branch 'filter_physics_actors' into 'master'
Do not perform physics simulation for actors outside processing range

See merge request OpenMW/openmw!1934
2022-05-29 19:19:35 +00:00
Evil Eye
3c83117e99 Replace new with make_unique in openmw 2022-05-29 13:24:48 +02:00
elsid
ac5844cad2
Do not perform physics simulation for actors outside processing range
Actors with disabled collisions still have physics simulations. Assuming they
should not be processed at all instead of disabling collision add a new flag to
make them inactive.
2022-05-26 10:36:03 +02:00
elsid
639bdd5801
Use free function instead of virtual MWBase::World::positionToIndex
The virtual function does the same thing.

* Change return type to osg::Vec2i to avoid dependency on ESM3.
* Rename to positionToCellIndex to make it clear what is the index.
2022-05-24 19:31:23 +02:00
psi29a
e3f891c0b0 Merge branch 'fix_boost' into 'master'
Fix build with lld linker

See merge request OpenMW/openmw!1903
2022-05-22 20:53:57 +00:00
Evil Eye
5146d9fc55 Fix 2022-05-22 09:51:08 +02:00
Evil Eye
ac78b537d2 Address feedback 2022-05-22 09:29:03 +02:00
elsid
9abfaef7a1
Use std::any instead of boost::any 2022-05-22 02:42:01 +02:00
Evil Eye
c6ca0e78c9 Make getStringLiteral return a string_view 2022-05-21 01:21:55 +02:00
ζeh Matt
b2fab5f5ad
Use World prng for weather system as it influences actors 2022-05-17 18:22:45 +03:00
ζeh Matt
cb99e8643a
Use World prng for selection of random creature spawning 2022-05-17 18:22:45 +03:00
psi29a
3e3cb133bc Merge branch 'fix_unity_build' into 'master'
Fix unity build

See merge request OpenMW/openmw!1860
2022-05-16 20:12:17 +00:00
elsid
c33966c4a4
Fix unity build
In file included from /home/elsid/dev/openmw/build/clang/unity/apps/openmw/ub_mwworld.cpp:41:
/home/elsid/dev/openmw/apps/openmw/mwworld/groundcoverstore.cpp:10:9: error: no type named 'Query' in 'MWWorld::EsmLoader'; did you mean '::EsmLoader::Query'?
        EsmLoader::Query query;
        ^~~~~~~~~~~~~~~~
        ::EsmLoader::Query
/home/elsid/dev/openmw/./components/esmloader/load.hpp:23:12: note: '::EsmLoader::Query' declared here
    struct Query
           ^
2022-05-16 15:04:47 +02:00
cody glassman
0cb63ca4e6 experimental point light bindings 2022-05-15 10:03:58 -07:00
cody glassman
04843fed6d moddable post-processing pipeline 2022-05-15 10:03:58 -07:00
elsid
31bd87936f
Remove redundant virtual World::adjustSky function 2022-05-08 15:41:53 +02:00